- fix: Alias a namespace to itself will create infinite loop.
This commit is contained in:
parent
396b6f42dc
commit
4f1cc3d50d
1
NEWS.md
1
NEWS.md
|
@ -129,6 +129,7 @@ Red Panda C++ Version 2.27
|
||||||
- change: Completion popup size settings are based on editor's char width/line height.
|
- change: Completion popup size settings are based on editor's char width/line height.
|
||||||
- change: Remove "limit for copy" and "limit for undo" options.
|
- change: Remove "limit for copy" and "limit for undo" options.
|
||||||
- fix: Can't find the correct type if current symbol is member of a class that has constructors.
|
- fix: Can't find the correct type if current symbol is member of a class that has constructors.
|
||||||
|
- fix: Alias a namespace to itself will create infinite loop.
|
||||||
|
|
||||||
Red Panda C++ Version 2.26
|
Red Panda C++ Version 2.26
|
||||||
- enhancement: Code suggestion for embedded std::vectors.
|
- enhancement: Code suggestion for embedded std::vectors.
|
||||||
|
|
|
@ -3203,6 +3203,8 @@ void CppParser::handleNamespace(KeywordType skipType, int maxIndex)
|
||||||
}
|
}
|
||||||
//qDebug()<<command<<aliasName;
|
//qDebug()<<command<<aliasName;
|
||||||
//namespace alias
|
//namespace alias
|
||||||
|
if (aliasName != command
|
||||||
|
&& aliasName != getFullStatementName(command, getCurrentScope())) {
|
||||||
addStatement(
|
addStatement(
|
||||||
getCurrentScope(),
|
getCurrentScope(),
|
||||||
mCurrentFile,
|
mCurrentFile,
|
||||||
|
@ -3217,6 +3219,7 @@ void CppParser::handleNamespace(KeywordType skipType, int maxIndex)
|
||||||
getScope(),
|
getScope(),
|
||||||
mCurrentMemberAccessibility,
|
mCurrentMemberAccessibility,
|
||||||
StatementProperty::HasDefinition);
|
StatementProperty::HasDefinition);
|
||||||
|
}
|
||||||
mIndex++; // skip ;
|
mIndex++; // skip ;
|
||||||
return;
|
return;
|
||||||
} else if (isInline) {
|
} else if (isInline) {
|
||||||
|
|
Loading…
Reference in New Issue