diff options
Diffstat (limited to 'lib/Frontend')
-rw-r--r-- | lib/Frontend/PCHReader.cpp | 7 | ||||
-rw-r--r-- | lib/Frontend/PCHWriter.cpp | 1 |
2 files changed, 7 insertions, 1 deletions
diff --git a/lib/Frontend/PCHReader.cpp b/lib/Frontend/PCHReader.cpp index cd08b13547..9c855eb26f 100644 --- a/lib/Frontend/PCHReader.cpp +++ b/lib/Frontend/PCHReader.cpp @@ -106,9 +106,11 @@ PCHValidator::ReadLanguageOptions(const LangOptions &LangOpts) { return true; } PARSE_LANGOPT_BENIGN(getVisibilityMode()); + PARSE_LANGOPT_IMPORTANT(getStackProtectorMode(), + diag::warn_pch_stack_protector); PARSE_LANGOPT_BENIGN(InstantiationDepth); PARSE_LANGOPT_IMPORTANT(OpenCL, diag::warn_pch_opencl); - PARSE_LANGOPT_IMPORTANT(ElideConstructors, diag::warn_elide_constructors); + PARSE_LANGOPT_IMPORTANT(ElideConstructors, diag::warn_pch_elide_constructors); #undef PARSE_LANGOPT_IRRELEVANT #undef PARSE_LANGOPT_BENIGN @@ -1720,6 +1722,9 @@ bool PCHReader::ParseLanguageOptions( ++Idx; LangOpts.setVisibilityMode((LangOptions::VisibilityMode)Record[Idx]); ++Idx; + LangOpts.setStackProtectorMode((LangOptions::StackProtectorMode) + Record[Idx]); + ++Idx; PARSE_LANGOPT(InstantiationDepth); PARSE_LANGOPT(OpenCL); #undef PARSE_LANGOPT diff --git a/lib/Frontend/PCHWriter.cpp b/lib/Frontend/PCHWriter.cpp index a6918e4c85..531c6f7818 100644 --- a/lib/Frontend/PCHWriter.cpp +++ b/lib/Frontend/PCHWriter.cpp @@ -625,6 +625,7 @@ void PCHWriter::WriteLanguageOptions(const LangOptions &LangOpts) { // unsigned type Record.push_back(LangOpts.getGCMode()); Record.push_back(LangOpts.getVisibilityMode()); + Record.push_back(LangOpts.getStackProtectorMode()); Record.push_back(LangOpts.InstantiationDepth); Record.push_back(LangOpts.OpenCL); Record.push_back(LangOpts.ElideConstructors); |