From 57a56e00067b4546bb0da15fb00653ee0341f5af Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Thu, 25 Feb 2010 21:14:52 -0500 Subject: PR11075: -W option to turn warnings into errors * session.h * NEWS: Discuss it. * main.cxx: Parse it. * session.h (num_errors): Provide it. * semok/fortyeight.stp, semok/thirtyseven.stp: Test it. --- session.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'session.h') diff --git a/session.h b/session.h index d43b1f21..18d811e7 100644 --- a/session.h +++ b/session.h @@ -110,6 +110,7 @@ struct systemtap_session bool bulk_mode; bool unoptimized; bool suppress_warnings; + bool panic_warnings; int buffer_size; unsigned perfmon; bool symtab; /* true: emit symbol table at translation time; false: let staprun do it. */ @@ -214,7 +215,7 @@ struct systemtap_session std::set seen_errors; std::set seen_warnings; - unsigned num_errors () { return seen_errors.size(); } + unsigned num_errors () { return seen_errors.size() + (panic_warnings ? seen_warnings.size() : 0); } std::set rpms_to_install; -- cgit