Software / code / prosody
Comparison
util/json.lua @ 4404:5356664ef9d4
util.json: Fix for single-line comments (thanks Norbert Kiesel)
| author | Matthew Wild <mwild1@gmail.com> |
|---|---|
| date | Wed, 26 Oct 2011 18:55:06 -0400 |
| parent | 4284:20979f124ad9 |
| child | 4474:b08a46cf06e6 |
comparison
equal
deleted
inserted
replaced
| 4403:eb688e4397a5 | 4404:5356664ef9d4 |
|---|---|
| 166 local function skipstuff() | 166 local function skipstuff() |
| 167 while true do | 167 while true do |
| 168 skipwhitespace(); | 168 skipwhitespace(); |
| 169 if ch == "/" and peek == "*" then | 169 if ch == "/" and peek == "*" then |
| 170 skipstarcomment(); | 170 skipstarcomment(); |
| 171 elseif ch == "/" and peek == "*" then | 171 elseif ch == "/" and peek == "/" then |
| 172 skiplinecomment(); | 172 skiplinecomment(); |
| 173 else | 173 else |
| 174 return; | 174 return; |
| 175 end | 175 end |
| 176 end | 176 end |