Skip to content
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

[mono] Unconditionally check llvm::Expected<T> for success #44908

Merged
merged 1 commit into from
Nov 19, 2020

Conversation

imhameed
Copy link
Contributor

@imhameed imhameed commented Nov 19, 2020

assert() will expand to a no-op if NDEBUG is defined, which can
cause an assertion-enabled LLVM to trap if an llvm::Expected<T> is
destroyed before having had operator bool applied to it.

`assert()` will expand to a no-op if NDEBUG isn't defined, which can
cause an assertion-enabled LLVM to trap if an `llvm::Expected<T>` is
destroyed before having had `operator bool` applied to it.
@ghost
Copy link

ghost commented Nov 19, 2020

Tagging subscribers to this area:
See info in area-owners.md if you want to be subscribed.

Issue Details

assert() will expand to a no-op if NDEBUG isn't defined, which can
cause an assertion-enabled LLVM to trap if an llvm::Expected<T> is
destroyed before having had operator bool applied to it.

Author: imhameed
Assignees: -
Labels:

area-Codegen-LLVM-mono

Milestone: -

@imhameed imhameed merged commit b5dffeb into dotnet:master Nov 19, 2020
@ghost ghost locked as resolved and limited conversation to collaborators Dec 19, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants