summaryrefslogtreecommitdiffstats
path: root/lib/Parse/Parser.cpp
diff options
context:
space:
mode:
authored <ed@FreeBSD.org>2009-06-06 08:21:31 +0000
committered <ed@FreeBSD.org>2009-06-06 08:21:31 +0000
commit265c92560db8af7e64dc328cb612076086a62bd1 (patch)
tree06d57bb7679a2140aef96db7105a0bd5f16a4358 /lib/Parse/Parser.cpp
parent9e262ca77e924f9d84a864b031a1b931d03c5e38 (diff)
downloadFreeBSD-src-265c92560db8af7e64dc328cb612076086a62bd1.zip
FreeBSD-src-265c92560db8af7e64dc328cb612076086a62bd1.tar.gz
Import clang, at r72995.
Diffstat (limited to 'lib/Parse/Parser.cpp')
-rw-r--r--lib/Parse/Parser.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/Parse/Parser.cpp b/lib/Parse/Parser.cpp
index 1c2e8a6..a2a66f9 100644
--- a/lib/Parse/Parser.cpp
+++ b/lib/Parse/Parser.cpp
@@ -39,6 +39,10 @@ Parser::Parser(Preprocessor &pp, Action &actions)
PragmaUnusedHandler(&PP.getIdentifierTable().get("unused"), actions,
*this));
PP.AddPragmaHandler(0, UnusedHandler.get());
+
+ WeakHandler.reset(new
+ PragmaWeakHandler(&PP.getIdentifierTable().get("weak"), actions));
+ PP.AddPragmaHandler(0, WeakHandler.get());
}
/// If a crash happens while the parser is active, print out a line indicating
@@ -288,6 +292,8 @@ Parser::~Parser() {
PackHandler.reset();
PP.RemovePragmaHandler(0, UnusedHandler.get());
UnusedHandler.reset();
+ PP.RemovePragmaHandler(0, WeakHandler.get());
+ WeakHandler.reset();
}
/// Initialize - Warm up the parser.
OpenPOWER on IntegriCloud