Displaying 1 result from an estimated 1 matches for "maybeerror".
Did you mean:
maybeerr
2020 Jan 26
2
[RFC] Replacing inalloca with llvm.call.setup and preallocated
...tself, or a normal
`llvm.call.teardown`.
### Non-exceptional call region exit
It is possible, using statement expressions, to exit a call setup region
with
normal control flow. In this case, the Clang should emit a normal cleanup to
call `llvm.eh.teardown`. Consider:
```c++
#define RETURN_IF_ERR(maybeError) \
({ \
auto val = maybeError; \
if (val.isError()) \
return val.getError(); \
val.getValue; \
})
ErrorOr<int> mayFail();
void use_callsetup(int, Foo);
void f(bool cond) {
use_callsetup(RETURN_IF_ERR(m...