diff --git a/cpg-language-cxx/src/main/kotlin/de/fraunhofer/aisec/cpg/frontends/cxx/DeclaratorHandler.kt b/cpg-language-cxx/src/main/kotlin/de/fraunhofer/aisec/cpg/frontends/cxx/DeclaratorHandler.kt index 2e0b0356d2..783bbc2706 100644 --- a/cpg-language-cxx/src/main/kotlin/de/fraunhofer/aisec/cpg/frontends/cxx/DeclaratorHandler.kt +++ b/cpg-language-cxx/src/main/kotlin/de/fraunhofer/aisec/cpg/frontends/cxx/DeclaratorHandler.kt @@ -225,12 +225,17 @@ class DeclaratorHandler(lang: CXXLanguageFrontend) : /* * As always, there are some special cases to consider and one of those are C++ operators. * They are regarded as functions and eclipse CDT for some reason introduces a whitespace +<<<<<<< HEAD <<<<<<< HEAD * in the function name, which will complicate things later on. But we only want to replace * the whitespace for "standard" operators. ======= * in the function name, which will complicate things later on >>>>>>> a5d63345d6 (Added `OperatorDeclaration`) +======= + * in the function name, which will complicate things later on. But we only want to replace + * the whitespace for "standard" operators. +>>>>>>> 478c404aed (Checking operator names) */ if (nameDecl.name is CPPASTOperatorName && name.replace(" ", "").isKnownOperatorName) { name = name.replace(" ", "") @@ -515,9 +520,9 @@ class DeclaratorHandler(lang: CXXLanguageFrontend) : } /** Checks whether the [Name] for a function is a known operator name. */ - val Name.isKnownOperatorName: Boolean + private val Name.isKnownOperatorName: Boolean get() { - var language = language + val language = language if (language !is HasOperatorOverloading) { return false }