Home | History | Annotate | Download | only in Lex

Lines Matching defs:Namespace

28 using namespace clang;
67 "A handler with this name is already registered in this namespace");
75 "Handler not registered in this namespace");
82 // Read the 'namespace' that the directive is in, e.g. STDC. Do not macro
116 // Invoke the first level of pragma handlers which reads the namespace id.
126 namespace {
727 /// If 'Namespace' is non-null, then it is a token required to exist on the
729 void Preprocessor::AddPragmaHandler(StringRef Namespace,
733 // If this is specified to be in a namespace, step down into it.
734 if (!Namespace.empty()) {
735 // If there is already a pragma handler with the name of this namespace,
736 // we either have an error (directive with the same name as a namespace) or
737 // we already have the namespace to insert into.
738 if (PragmaHandler *Existing = PragmaHandlers->FindHandler(Namespace)) {
740 assert(InsertNS != nullptr && "Cannot have a pragma namespace and pragma"
743 // Otherwise, this namespace doesn't exist yet, create and insert the
745 InsertNS = new PragmaNamespace(Namespace);
757 /// preprocessor. If \arg Namespace is non-null, then it should be the
758 /// namespace that \arg Handler was added to. It is an error to remove
760 void Preprocessor::RemovePragmaHandler(StringRef Namespace,
764 // If this is specified to be in a namespace, step down into it.
765 if (!Namespace.empty()) {
766 PragmaHandler *Existing = PragmaHandlers->FindHandler(Namespace);
767 assert(Existing && "Namespace containing handler does not exist!");
770 assert(NS && "Invalid namespace, registered as a regular pragma handler!");
775 // If this is a non-default namespace and it is now empty, remove
810 namespace {
941 const char *Namespace;
944 PragmaHandler("diagnostic"), Namespace(NS) {}
961 Callbacks->PragmaDiagnosticPop(DiagLoc, Namespace);
966 Callbacks->PragmaDiagnosticPush(DiagLoc, Namespace);
1006 Callbacks->PragmaDiagnostic(DiagLoc, Namespace, SV, WarningName);
1145 const StringRef Namespace;
1162 StringRef Namespace = StringRef())
1163 : PragmaHandler(PragmaKind(Kind, true)), Kind(Kind), Namespace(Namespace) {}
1210 Callbacks->PragmaMessage(MessageLoc, Namespace, Kind, MessageString);
1348 } // end anonymous namespace
1404 "Invalid namespace, registered as a regular pragma handler!");