You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Commit bceb817 made the following edits:
```
SILDeclRef method = i->getMember().getOverriddenVTableEntry();
auto methodType = i->getType().castTo<SILFunctionType>();
+ AccessLevel methodAccess = method.getDecl()->getEffectiveAccess();
auto *classDecl = cast<ClassDecl>(method.getDecl()->getDeclContext());
bool shouldUseDispatchThunk = false;
- if (IGM.hasResilientMetadata(classDecl, ResilienceExpansion::Maximal)) {
+ // Because typechecking for the debugger has more lax rules, check the access
+ // level of the getter to decide whether to use a dispatch thunk for the
+ // debugger.
+ bool shouldUseDispatchThunkIfInDebugger =
+ !classDecl->getASTContext().LangOpts.DebuggerSupport ||
+ methodAccess == AccessLevel::Public;
+ if (IGM.hasResilientMetadata(classDecl, ResilienceExpansion::Maximal) &&
+ shouldUseDispatchThunkIfInDebugger) {
shouldUseDispatchThunk = true;
} else if (IGM.getOptions().VirtualFunctionElimination) {
// For VFE, use a thunk if the target class is in another module. This
```
This commit refactors the conditional that make it more obvious that
only the LLDB code path is meant to be affected.
0 commit comments