From 31d0aa574b935b76fe9e2dcf0457fde2079433ee Mon Sep 17 00:00:00 2001 From: alex-eg Date: Tue, 5 Aug 2025 01:43:07 +0300 Subject: [PATCH] saner getting of c compiler args from the cmdline --- sexc.scm | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/sexc.scm b/sexc.scm index a8d4164..7f51748 100644 --- a/sexc.scm +++ b/sexc.scm @@ -17,6 +17,7 @@ getopt-long regex srfi-1 ; list routines + srfi-13 ; string routines tree) (define (unkebabify sym) @@ -248,10 +249,7 @@ (cdr (assoc '@ args))) (define (get-c-compiler-args args) - (do ((c-args (get-rest-args args) (cdr c-args))) - ((or (null? c-args) - (char=? #\- (string-ref (car c-args) 0))) - c-args))) + (filter (fn (string-prefix? "-" x)) (get-rest-args args))) (define (get-input-file args) (let ((rest-args (get-rest-args args)))