[PATCH] D48880: [Sema] Fix crash in getConstructorName.
Richard Smith - zygoloid via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Jul 3 14:44:32 PDT 2018
rsmith added a comment.
Looks fine, but please put the test case somewhere more appropriate (under SemaCXX, for instance).
Comment at: lib/Sema/SemaExprCXX.cpp:117
assert(InjectedClassName && "couldn't find injected class name");
We would be able to recover in more cases if we only bail out when the `InjectedClassName` is not found. Maybe instead of this change, you could weaken the assertion to only fail if the class is valid, and return `ParsedType` here if we don't find an `InjectedClassName`.
More information about the cfe-commits