1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-07-02 23:50:47 +02:00

module/language/lua/parser.scm: Rename #:dots to #:varargs

This commit is contained in:
Phil 2011-04-22 01:11:38 -05:00 committed by Ian Price
parent becaec9a4e
commit faa16f9989
6 changed files with 15 additions and 15 deletions

View file

@ -282,7 +282,7 @@ of an identifier"
(begin
(read-char)
(if (eqv? (peek-char) #\.)
(begin (read-char) #:dots)
(begin (read-char) #:varargs)
#:concat))
#\.)))

View file

@ -9,13 +9,13 @@ This is an org-mode todo list of stuff that needs to be done for Guile Lua.
** TODO Use prompt and abort instead of throw and catch
** TODO Standard library function: module
** TODO Standard library function: table.sort
** TODO Get the official test suite running
** TODO Get the official Lua 5.1 test suite running
* Eh
** TODO Standard library function: math.frexp
Pending some additions to Guile's numeric tower.
** TODO Better testing of standard library modules io, os
** TODO Function environments (getfenv and setfenv)
** TODO Parser should probably be rewritten
* Differences
Here are some difference in Guile Lua's behavior that should not cause

View file

@ -125,7 +125,7 @@
(define *special-tokens*
'(#\. #\( #\) #\, #\- #\< #\; #\+ #\{ #\} #\[ #\] #\: #\#
#:function #:end #:if #:return #:elseif #:then #:else #:true #:false
#:nil #:== #:~= #:= #\> #:>= #:<= #:local #:dots #:break #:do #:in
#:nil #:== #:~= #:= #\> #:>= #:<= #:local #:varargs #:break #:do #:in
#:and #:or))
(define (token/type t)
@ -466,7 +466,7 @@
(values (reverse! parameters) #f))))
((#\))
(values (reverse! parameters) #f))
((#:dots)
((#:varargs)
(advance!)
(values (reverse! parameters) #t))
(else
@ -532,7 +532,7 @@
;; table-literal
((#\{) (table-literal))
;; ...
((#:dots)
((#:varargs)
(unless *vararg-function*
(syntax-error src "cannot use '...' outside of a variable arguments function"))
(advance! (make-ast-variable-arguments src)))