summaryrefslogtreecommitdiff
path: root/lldb/source/Plugins/ScriptInterpreter/Python/ScriptedProcessPythonInterface.cpp
diff options
context:
space:
mode:
authorRaphael Isemann <teemperor@gmail.com>2021-03-22 17:52:43 +0100
committerRaphael Isemann <teemperor@gmail.com>2021-03-22 18:05:50 +0100
commite421a74108ee86afec133c77258470d3ed7dcc90 (patch)
treeb1950632cff538de6f838c94533391ed15ea7626 /lldb/source/Plugins/ScriptInterpreter/Python/ScriptedProcessPythonInterface.cpp
parent1e01f2f4100ddde38d384ea3caf3a7690a8ab185 (diff)
[ASTImporter] Fix import of ObjCPropertyDecl that share the same name
Objective-C apparently allows name conflicts between instance and class properties, so this is valid code: ``` @protocol DupProp @property (class, readonly) int prop; @property (readonly) int prop; @end ``` The ASTImporter however isn't aware of this and will consider the two properties as if they are the same property because it just compares their name and types. This causes that when importing both properties we only end up with one property (whatever is imported first from what I can see). Beside generating a different AST this also leads to a bunch of asserts and crashes as we still correctly import the two different getters for both properties (the import code for methods does the correct check where it differentiated between instance and class methods). As one of the setters will not have its associated ObjCPropertyDecl imported, any call to `ObjCMethodDecl::findPropertyDecl` will just lead to an assert or crash. Fixes rdar://74322659 Reviewed By: shafik, kastiglione Differential Revision: https://reviews.llvm.org/D99077
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/ScriptedProcessPythonInterface.cpp')
0 files changed, 0 insertions, 0 deletions