Use number of procedure arguments function from util-proc in command-line.
This commit is contained in:
parent
147afa3ab4
commit
c2c19c2d6a
4 changed files with 16 additions and 9 deletions
|
@ -39,7 +39,8 @@
|
|||
(chicken process-context)
|
||||
(chicken format)
|
||||
util-list
|
||||
testing)
|
||||
testing
|
||||
util-proc)
|
||||
|
||||
;; Consumes given number of arguments from the list and returns the
|
||||
;; remainder of the list and a list of arguments consumed.
|
||||
|
@ -74,8 +75,7 @@
|
|||
(when (not specp)
|
||||
(error 'parse-command-line "Unknown argument" arg))
|
||||
(let* ((proc (caddr specp))
|
||||
(info (procedure-information proc))
|
||||
(nargs (- (length info) 1))
|
||||
(nargs (procedure-num-args proc))
|
||||
(aargsl (consume-args (cdr args) nargs))
|
||||
(args (car aargsl))
|
||||
(aargs (cadr aargsl)))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue