Permalink
Browse files

Change comment char from `#` to `;`. (see bug #9)

  • Loading branch information...
1 parent f3eabd7 commit 70584dbfb90700272a7ab074bc448b2a0036c195 @Gozala committed Jun 26, 2012
Showing with 15 additions and 16 deletions.
  1. +2 −2 README.md
  2. +1 −1 examples/nodeserver.ls
  3. +6 −6 examples/snippets.ls
  4. +1 −1 lib/ls.js
  5. +1 −1 src/lispy.ls
  6. +2 −2 src/macros.ls
  7. +2 −3 src/repl.ls
View
@@ -271,8 +271,8 @@ Includes a file to be compiled with this compilation unit.
### Comments
-Comments in LispyScript start with a "#" and span the rest of the line.
+Comments in LispyScript start with a `;` and span the rest of the line.
### LispyScript was inspired by [Beating the averages](http://www.paulgraham.com/avg.html).
-### Discuss LispyScript at [https://groups.google.com/forum/#!forum/lispyscript](https://groups.google.com/forum/#!forum/lispyscript).
+### Discuss LispyScript at [https://groups.google.com/forum/#!forum/lispyscript](https://groups.google.com/forum/#!forum/lispyscript).
View
@@ -5,4 +5,4 @@
(response.writeHead 200 {'Content-Type': 'text/plain'})
(response.end "Hello World\n"))))
(server.listen 3000 "127.0.0.1")
-(console.log "Server running at http://127.0.0.1:3000/")
+(console.log "Server running at http://127.0.0.1:3000/")
View
@@ -1,4 +1,4 @@
-# Some example code snippets
+;; Some example code snippets
(var square
(function (n)
@@ -29,15 +29,15 @@
(console.log "console is an array")
(console.log "console is not an array"))
-# The example below shows the dangers of using a macro
+;; The example below shows the dangers of using a macro
(macro square (x)
(* ~x ~x))
(console.log (square 10))
-# The code above works fine. Now consider the code below
+;; The code above works fine. Now consider the code below
(var i 2)
(console.log (square i++))
-# Oops you got 6! An embarrassing square of a no. Thats because the macro
-# expanded to (* i++ i++) which is multiplying 2 and three!
+;; Oops you got 6! An embarrassing square of a no. Thats because the macro
+;; expanded to (* i++ i++) which is multiplying 2 and three!
(var _ (require 'underscore'))
(Array.prototype.forEach.call [1, 2, 3] (function (elem i list) (console.log elem)))
@@ -80,4 +80,4 @@
[{href:"/about", text:"About"},
{href:"/products", text:"Products"},
{href:"/contact", text:"Contact"}]))
-
+
View
@@ -120,7 +120,7 @@ var parse = function(code, filename) {
token += c;
continue;
}
- if (c == "#") {
+ if (c == ";") {
isComment = true;
continue;
}
View
@@ -1,4 +1,4 @@
-# The lispy command script
+;; The lispy command script
(var fs (require "fs"))
(var ls (require (+ __dirname "/ls")))
View
@@ -1,5 +1,5 @@
-# List of built in macros for LispyScript. This file is included by
-# default by the LispyScript compiler.
+;; List of built in macros for LispyScript. This file is included by
+;; default by the LispyScript compiler.
(macro object? (obj)
(= (typeof ~obj) "object"))
View
@@ -1,11 +1,10 @@
-# A very simple REPL written in LispyScript
-#
+;; A very simple REPL written in LispyScript
(var readline (require "readline"))
(var ls (require (+ __dirname "/ls")))
(var prefix "lispy> ")
-
+
(set exports.runrepl
(function ()
(var rl (readline.createInterface process.stdin process.stdout))

0 comments on commit 70584db

Please sign in to comment.