From a7de40ae5690c85277b15140544780070f93386a Mon Sep 17 00:00:00 2001 From: Araq Date: Mon, 20 Jul 2015 19:33:26 +0200 Subject: [PATCH] fixed typo ':' instead of ',' --- 1_intro.rst | 4 +- 2_meta.rst | 2 +- livedemo/demo.html | 1348 ++++++++++++++++++++++++++++++++++++-------- livedemo/demo.nim | 21 - 4 files changed, 1130 insertions(+), 245 deletions(-) diff --git a/1_intro.rst b/1_intro.rst index c6b05a1..a5b7791 100644 --- a/1_intro.rst +++ b/1_intro.rst @@ -155,7 +155,7 @@ More Code! echo decimalToRoman(1009) # MIX -- ``{"M": 1000, "CM": 900}`` sugar for ``[("M": 1000), ("CM": 900)]`` +- ``{"M": 1000, "CM": 900}`` sugar for ``[("M", 1000), ("CM", 900)]`` - ``result`` implicitly available @@ -236,6 +236,8 @@ Operators * No explicit distinction between binary and unary operators: .. code-block:: Nim + :number-lines: + proc `++`(x: var int; y: int = 1; z: int = 0) = x = x + y + z diff --git a/2_meta.rst b/2_meta.rst index c3489eb..22708bb 100644 --- a/2_meta.rst +++ b/2_meta.rst @@ -180,7 +180,7 @@ Code coverage # This is the code our macro will produce! var - track = [("line 9", false), ("line 13", false), ...] + track = [("line 11", false), ("line 15", false), ...] proc toTest(x, y: int) = try: diff --git a/livedemo/demo.html b/livedemo/demo.html index dd2ff2c..34d2f74 100644 --- a/livedemo/demo.html +++ b/livedemo/demo.html @@ -1,138 +1,787 @@ - - + + + + - Module demo - - - - - - -
- Nimrod logo -
- -

Module demo

-
-