diff options
Diffstat (limited to 'clang/include/clang/Basic/LangOptions.h')
-rw-r--r-- | clang/include/clang/Basic/LangOptions.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/clang/include/clang/Basic/LangOptions.h b/clang/include/clang/Basic/LangOptions.h index 41595ec..260a753 100644 --- a/clang/include/clang/Basic/LangOptions.h +++ b/clang/include/clang/Basic/LangOptions.h @@ -756,6 +756,15 @@ public: bool isTargetDevice() const { return OpenMPIsTargetDevice || CUDAIsDevice || SYCLIsDevice; } + + /// Returns the most applicable C standard-compliant language version code. + /// If none could be determined, returns \ref std::nullopt. + std::optional<uint32_t> getCLangStd() const; + + /// Returns the most applicable C++ standard-compliant language + /// version code. + /// If none could be determined, returns \ref std::nullopt. + std::optional<uint32_t> getCPlusPlusLangStd() const; }; /// Floating point control options |