Issue #481 - Exit if scm->c compilation fails

This commit is contained in:
Justin Ethier 2021-09-07 07:45:50 -04:00
parent bb861334f6
commit 67384621bc

View file

@ -1142,10 +1142,11 @@ Debug options:
;; Normal path is to run another instance of cyclone to generate
;; the .C file. This lets us immediately free those resources once
;; the Scheme compilation is done.
(system
(string-append
(calling-program) " -run-scm-compiler "
(string-join args " ")))))
(when (not (zero? (system
(string-append
(calling-program) " -run-scm-compiler "
(string-join args " ")))))
(exit 1))))
;; Call the C compiler
(run-external-compiler
non-opts append-dirs prepend-dirs