Author: svenvh Date: Fri Sep 27 06:31:29 2019 New Revision: 373088 URL: http://llvm.org/viewvc/llvm-project?rev=373088&view=rev Log: [OpenCL] Pass LangOptions as const ref
Modified: cfe/trunk/include/clang/Basic/OpenCLOptions.h Modified: cfe/trunk/include/clang/Basic/OpenCLOptions.h URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/OpenCLOptions.h?rev=373088&r1=373087&r2=373088&view=diff ============================================================================== --- cfe/trunk/include/clang/Basic/OpenCLOptions.h (original) +++ cfe/trunk/include/clang/Basic/OpenCLOptions.h Fri Sep 27 06:31:29 2019 @@ -42,7 +42,7 @@ public: // Is supported as either an extension or an (optional) core feature for // OpenCL version \p CLVer. - bool isSupported(llvm::StringRef Ext, LangOptions LO) const { + bool isSupported(llvm::StringRef Ext, const LangOptions &LO) const { // In C++ mode all extensions should work at least as in v2.0. auto CLVer = LO.OpenCLCPlusPlus ? 200 : LO.OpenCLVersion; auto I = OptMap.find(Ext)->getValue(); @@ -51,7 +51,7 @@ public: // Is supported (optional) OpenCL core features for OpenCL version \p CLVer. // For supported extension, return false. - bool isSupportedCore(llvm::StringRef Ext, LangOptions LO) const { + bool isSupportedCore(llvm::StringRef Ext, const LangOptions &LO) const { // In C++ mode all extensions should work at least as in v2.0. auto CLVer = LO.OpenCLCPlusPlus ? 200 : LO.OpenCLVersion; auto I = OptMap.find(Ext)->getValue(); @@ -60,7 +60,7 @@ public: // Is supported OpenCL extension for OpenCL version \p CLVer. // For supported (optional) core feature, return false. - bool isSupportedExtension(llvm::StringRef Ext, LangOptions LO) const { + bool isSupportedExtension(llvm::StringRef Ext, const LangOptions &LO) const { // In C++ mode all extensions should work at least as in v2.0. auto CLVer = LO.OpenCLCPlusPlus ? 200 : LO.OpenCLVersion; auto I = OptMap.find(Ext)->getValue(); _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits