[clang] [SystemZ][z/OS] Implement #pragma export (PR #141671)
Erich Keane via cfe-commits
cfe-commits at lists.llvm.org
Thu Nov 20 07:50:02 PST 2025
================
@@ -1386,6 +1402,74 @@ bool Parser::HandlePragmaMSAllocText(StringRef PragmaName,
return true;
}
+bool Parser::zOSHandlePragmaHelper(tok::TokenKind PragmaKind) {
+ assert(Tok.is(PragmaKind));
+
+ StringRef PragmaName = "export";
+
+ using namespace clang::charinfo;
+ auto *TheTokens =
+ (std::pair<std::unique_ptr<Token[]>, size_t> *)Tok.getAnnotationValue();
+ PP.EnterTokenStream(std::move(TheTokens->first), TheTokens->second, true,
+ false);
+ ConsumeAnnotationToken();
+
+ do {
+ PP.Lex(Tok);
----------------
erichkeane wrote:
Rather than doing the lex directly, shouldn't we just be calling Parser::ConsumeToken?
https://github.com/llvm/llvm-project/pull/141671
More information about the cfe-commits
mailing list