Skip to content

Commit

Permalink
Treat # as line comment
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrey Kuzmin committed Sep 1, 2018
1 parent 4e3907b commit 0a02bcb
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions compiler/src/Parse/Shader.hs
Expand Up @@ -213,6 +213,9 @@ eatSomethingElse openCurly fp offset terminal row col =
else if word == 0x2F {- / -} then
eatComment (eatSomethingElse openCurly) fp offset terminal row col

else if word == 0x23 {- # -} then
eatLineComment (eatSomethingElse openCurly) fp (offset + 1) terminal row (col + 1)

else
let !newOffset = offset + I.getCharWidth fp offset terminal word in
eatSomethingElse openCurly fp newOffset terminal row (col + 1)
Expand Down

0 comments on commit 0a02bcb

Please sign in to comment.