aboutsummaryrefslogtreecommitdiffstats
path: root/lib/parsetools/test
diff options
context:
space:
mode:
authorTuncer Ayaz <[email protected]>2011-05-28 15:15:26 +0200
committerTuncer Ayaz <[email protected]>2011-06-01 11:41:59 +0200
commit69a2b05f717b9688dfb5c1aeb874499caf1026dd (patch)
tree9f246235b35083c96d0b1d4760ec04a50bbd4aa3 /lib/parsetools/test
parent8f9203ccd0c64cb4b03792e5599b27af26e2fcde (diff)
downloadotp-69a2b05f717b9688dfb5c1aeb874499caf1026dd.tar.gz
otp-69a2b05f717b9688dfb5c1aeb874499caf1026dd.tar.bz2
otp-69a2b05f717b9688dfb5c1aeb874499caf1026dd.zip
yecc: add warnings_as_errors option
Diffstat (limited to 'lib/parsetools/test')
-rw-r--r--lib/parsetools/test/yecc_SUITE.erl8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/parsetools/test/yecc_SUITE.erl b/lib/parsetools/test/yecc_SUITE.erl
index 1de87b3bff..0133524950 100644
--- a/lib/parsetools/test/yecc_SUITE.erl
+++ b/lib/parsetools/test/yecc_SUITE.erl
@@ -247,6 +247,14 @@ syntax(Config) when is_list(Config) ->
?line {ok,_,[{_,[{2,yecc,bad_declaration}]}]} =
yecc:file(Filename, Ret),
+ %% Bad declaration with warnings_as_errors.
+ error = yecc:file(Filename, [warnings_as_errors]),
+ error = yecc:file(Filename, [return_warnings,warnings_as_errors]),
+ {ok,_,[{_,[{2,yecc,bad_declaration}]}]} =
+ yecc:file(Filename, [return_warnings]),
+ {error,_,[{_,[{2,yecc,bad_declaration}]}]} =
+ yecc:file(Filename, [return_errors,warnings_as_errors]),
+
%% Bad declaration.
?line ok = file:write_file(Filename,
<<"Nonterminals nt. Terminals t.