summaryrefslogtreecommitdiff
path: root/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp
diff options
context:
space:
mode:
authorJan Svoboda <jan_svoboda@apple.com>2021-08-06 14:46:41 +0200
committerJan Svoboda <jan_svoboda@apple.com>2021-08-06 14:48:28 +0200
commit4aafd5f00c2a772337ec065d4542ef158453a343 (patch)
treea807fe44818e6a1bb155c49432d8245ea0b8d0e5 /lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp
parent3709822d2602b8b7db2d9bcc0e856f676582f25d (diff)
[clang] Remove misleading assertion in FullSourceLoc
D31709 added an assertion was added to `FullSourceLoc::hasManager()` that ensured a valid `SourceLocation` is always paired with a `SourceManager`, and missing `SourceManager` is always paired with an invalid `SourceLocation`. This appears to be incorrect, since clients never cared about constructing `FullSourceLoc` to uphold that invariant, or always checking `isValid()` before calling `hasManager()`. The assertion started failing when serializing diagnostics pointing into an explicit module. Explicit modules don't have valid `SourceLocation` for the `import` statement, since they are "imported" from the command-line argument `-fmodule-name=x.pcm`. This patch removes the assertion, since `FullSourceLoc` was never intended to uphold any kind of invariants between the validity of `SourceLocation` and presence of `SourceManager`. Reviewed By: arphaman Differential Revision: https://reviews.llvm.org/D106862
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp')
0 files changed, 0 insertions, 0 deletions