lib: fix unrecognized code blocks in doc units
authorAlexandre Terrasa <alexandre@moz-code.org>
Wed, 30 May 2018 14:14:20 +0000 (10:14 -0400)
committerAlexandre Terrasa <alexandre@moz-code.org>
Tue, 7 Aug 2018 22:38:03 +0000 (18:38 -0400)
Signed-off-by: Alexandre Terrasa <alexandre@moz-code.org>

lib/core/collection/abstract_collection.nit
lib/core/collection/union_find.nit
lib/core/kernel.nit
lib/perfect_hashing/perfect_hashing.nit
lib/trees/bintree.nit

index 04dabfa..b51cd22 100644 (file)
@@ -396,6 +396,7 @@ interface SimpleCollection[E]
        fun add(item: E) is abstract
 
        # Add each item of `coll`.
+       #
        #     var a = [1,2]
        #     a.add_all([3..5])
        #     assert a.has(4)  == true
index b44b7f9..6c74ca2 100644 (file)
@@ -14,6 +14,7 @@ module union_find
 import hash_collection
 
 # Data structure to keeps track of elements partitioned into disjoint subsets
+#
 #     var s = new DisjointSet[Int]
 #     s.add(1)
 #     s.add(2)
@@ -139,6 +140,7 @@ class DisjointSet[E]
        end
 
        # Are all elements of `es` in the same subset?
+       #
        #     var s = new DisjointSet[Int]
        #     s.add_all([1,2,3,4,5,6])
        #     s.union_all([1,2,3])
index 45c3ccd..39a5958 100644 (file)
@@ -858,8 +858,11 @@ universal Int
 
        # Return the corresponding digit character
        # If 0 <= `self` <= 9, return the corresponding character.
+       #
        #     assert 5.to_c    == '5'
+       #
        # If 10 <= `self` <= 36, return the corresponding letter [a..z].
+       #
        #     assert 15.to_c   == 'f'
        fun to_c: Char
        do
index d8ab3cb..585130e 100644 (file)
@@ -101,6 +101,7 @@ class Perfecthashing
        # n : number of required free identifiers
        # idc : This array will be filled with n free identifiers
        # return the size of hashTable to create for theses identifiers (mask + 1)
+       #
        #     var ph = new Perfecthashing
        #     var idc = new Array[Int]
        #     assert ph.pnand([3, 7, 10], 1, idc) == 6
index 610ec2e..447a33f 100644 (file)
@@ -36,6 +36,7 @@ import abstract_tree
 #  * delete average O(lg n) worst O(n)
 #
 # Usage:
+#
 #     var tree = new BinTreeMap[Int, String]
 #     tree[1] = "n1"
 #     assert tree.min == "n1"