From c4aa3b20979ba9a6de64ce3b02281437687ce6ba Mon Sep 17 00:00:00 2001 From: Kaz Kylheku Date: Thu, 1 Mar 2012 16:33:01 -0800 Subject: * match.c (v_load): Check for errors during the parse and throw an exception. --- ChangeLog | 1 + match.c | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/ChangeLog b/ChangeLog index f92b4152..18d1e889 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2,6 +2,7 @@ * match.c (v_load): Fixed broken functionality. Failing to evaluate directives following the load and consume input properly. + Check for errors during the parse and throw an exception. 2012-03-01 Kaz Kylheku diff --git a/match.c b/match.c index 66325ddd..fc9746a0 100644 --- a/match.c +++ b/match.c @@ -3413,6 +3413,10 @@ static val v_load(match_files_ctx *c) parse_reset(path); yyparse(); gc_state(gc); + + if (errors) + sem_error(specline, lit("load: errors encountered in ~s"), path, nao); + { val spec = get_spec(); val result = match_files(mf_spec(*c, spec)); -- cgit v1.2.3