Compare commits

..

No commits in common. "fea2a85b54f9d2782d2c358fbc03d247181dc9be" and "a94c6f4e8f18b4f8a523aae9a7718d32a8aef1b3" have entirely different histories.

3 changed files with 6 additions and 8 deletions

View file

@ -8,9 +8,7 @@
:finally (return start))))
(subseq string
start
(if (< start (length string))
(position #\Newline string :start (1+ start))
nil))))
(position #\Newline string :start (1+ start)))))
(defun point-out-source (source)
(if (null source)

View file

@ -11,4 +11,4 @@
(:export #:usc-init #:compile-string-to-bytes
;; Errors
#:usc-error #:tokenizer-error #:missing-function-error
#:parser-error #:source))
#:parser-error))

View file

@ -164,13 +164,13 @@ reading immediately. Should be a subset of *SPECIAL-TOKEN-CHARS*.")
(next-token))
;; Process and add a newline
((char= char #\Newline)
(setf in-comment-p nil
line (1+ line)
column 0)
(unless (zerop (length token-text-buffer))
(next-token))
(vector-push #\Newline token-text-buffer)
(next-token)
(setf in-comment-p nil
line (1+ line)
column 0))
(next-token))
;; Starting a comment
((and (member char *line-comment-chars* :test #'char=) (not in-comment-p))
(unless (zerop (length token-text-buffer))