Skip to content

Fix compile errors in no-asserts configuration #8394

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 14, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions lldb/source/Plugins/TypeSystem/Swift/TypeSystemSwiftTypeRef.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2124,7 +2124,9 @@ template <typename T> bool Equivalent(std::optional<T> l, T r) {
} // namespace
#endif

#ifndef NDEBUG
constexpr ExecutionContextScope *g_no_exe_ctx = nullptr;
#endif

// This can be removed once the transition is complete.
#define FALLBACK(REFERENCE, ARGS, DEFAULT) \
Expand Down Expand Up @@ -2222,11 +2224,15 @@ constexpr ExecutionContextScope *g_no_exe_ctx = nullptr;

#else
#define VALIDATE_AND_RETURN_STATIC(IMPL, REFERENCE) \
FALLBACK(REFERENCE, ()); \
FALLBACK(REFERENCE, (), {}); \
return IMPL()
#define VALIDATE_AND_RETURN(IMPL, REFERENCE, TYPE, EXE_CTX, ARGS, \
FALLBACK_ARGS) \
FALLBACK(REFERENCE, FALLBACK_ARGS); \
FALLBACK(REFERENCE, FALLBACK_ARGS, {}); \
return IMPL();
#define VALIDATE_AND_RETURN_EXPECTED(IMPL, REFERENCE, TYPE, EXE_CTX, ARGS, \
FALLBACK_ARGS, DEFAULT) \
FALLBACK(REFERENCE, FALLBACK_ARGS, DEFAULT); \
return IMPL();
#endif

Expand Down