diff options
Diffstat (limited to 'lib/Lex/Preprocessor.cpp')
-rw-r--r-- | lib/Lex/Preprocessor.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/Lex/Preprocessor.cpp b/lib/Lex/Preprocessor.cpp index 458eca640a..12f63d6444 100644 --- a/lib/Lex/Preprocessor.cpp +++ b/lib/Lex/Preprocessor.cpp @@ -425,6 +425,13 @@ static void InitializePredefinedMacros(Preprocessor &PP, Buf.push_back('\n'); } + if (const char *Prefix = PP.getTargetInfo().getUserLabelPrefix()) { + llvm::SmallString<20> TmpStr; + TmpStr += "__USER_LABEL_PREFIX__="; + TmpStr += Prefix; + DefineBuiltinMacro(Buf, TmpStr.c_str()); + } + // Get the target #defines. PP.getTargetInfo().getTargetDefines(Buf); |