all: fix broken docunits
authorJean Privat <jean@pryen.org>
Fri, 28 Nov 2014 01:34:35 +0000 (20:34 -0500)
committerJean Privat <jean@pryen.org>
Fri, 28 Nov 2014 01:41:59 +0000 (20:41 -0500)
Signed-off-by: Jean Privat <jean@pryen.org>

lib/geometry/boxes.nit
lib/json/dynamic.nit
lib/sax/helpers/sax_locator_impl.nit
lib/scene2d.nit
lib/signals.nit
lib/standard/string.nit

index 1596c1e..b8c9798 100644 (file)
@@ -75,12 +75,12 @@ interface Boxed[N: Numeric]
                        self.top >= other.bottom and other.top >= self.bottom
        end
 
-       # Create a bounding box that englobes the actual bounding box.
+       # Create a bounding box that encloses the actual bounding box.
        # `dist` is the distance between the inner boundaries and the outer boundaries.
        # ~~~
        # var p = new Point[Int](5,10)
        # var b = p.padded(3)
-       # assert b.top == 2 and b.bot = 8 and b.left == 7 and b.right == 13
+       # assert b.left == 2 and b.right == 8 and b.top == 13 and b.bottom == 7
        # ~~~
        fun padded(dist: N): Box[N] do return new Box[N].lrtb(left - dist, right + dist, top + dist, bottom - dist)
 end
index d15ceb7..2f73fea 100644 (file)
@@ -74,8 +74,8 @@ class JsonValue
        #
        # require: `self.is_numeric`
        #
-       #     assert "1.234".to_json_value.to_numeric = 1.234
-       #     assert "1234".to_json_value.to_numeric = 1234
+       #     assert "1.234".to_json_value.to_numeric == 1.234
+       #     assert "1234".to_json_value.to_numeric == 1234
        fun to_numeric: Numeric
        do
                if is_int then return to_i
index c736a46..eb04677 100644 (file)
@@ -19,24 +19,17 @@ import sax::sax_locator
 # can use it to make a persistent snapshot of a locator at any
 # point during a document parse:
 #
-#     module example
-#     #
-#     import sax::helpers::SAXLocatorImpl
-#     import sax::ContentHandler
-#     #
+#     import sax::helpers::sax_locator_impl
+#     import sax::content_handler
+#
 #     class Example super ContentHandler
-#      private var _locator: nullable SAXLocator = null
+#      private var locator: SAXLocator
 #      private var start_loc: nullable SAXLocator = null
-#     #
-#      fun locator=(Locator locator) do
-#              # note the locator
-#              _locator = locator
-#      end
-#     #
-#      fun start_document do
+#
+#      redef fun start_document do
 #              # save the location of the start of the document
 #              # for future use.
-#              start_loc = new SAXLocatorImpl.from(locator)
+#              start_loc = new SAXLocatorImpl.with(locator)
 #      end
 #     end
 #
index ac5a571..b01c3e5 100644 (file)
@@ -151,8 +151,8 @@ interface View
        # This method must be implemented for each specific view.
        # A traditional way of implementation is to use a double-dispatch mechanism
        #
-       # Exemple:
        #     class MyView
+       #         super View
        #         redef fun draw_sprite(s) do s.draw_on_myview(self)
        #     end
        #     redef class Sprite
index f1044e8..f9709da 100644 (file)
@@ -47,7 +47,7 @@
 # r.handle_signal(sigint, true)
 # r.handle_signal(sigalarm, true)
 #
-# Ask system to receive a `sigalarm` signal in 1 second
+# # Ask system to receive a `sigalarm` signal in 1 second
 # set_alarm(1)
 #
 # loop
index 26251ce..62d5ddc 100644 (file)
@@ -1405,7 +1405,7 @@ abstract class Buffer
        #
        # SEE: `Char::is_letter` for the definition of a letter.
        #
-       #    var b = new FlatBuffer.from("jAVAsCriPt")"
+       #    var b = new FlatBuffer.from("jAVAsCriPt")
        #    b.capitalize
        #    assert b == "Javascript"
        #    b = new FlatBuffer.from("i am root")