[clang] [clang][ASTImporter] Remove trailing return testing on lambda proto (PR #101031)
Ding Fei via cfe-commits
cfe-commits at lists.llvm.org
Tue Jul 30 19:41:00 PDT 2024
danix800 wrote:
> > Another PR would fix the crash when this one is landed.
>
> Can you land the fix for the crash first? If the other PR gets reverted it creates a lot of churn, so it would preferable to land that first. Assuming it is not somehow dependent on this fix.
This new crash is a false alarm caused by the first incorrect fix. Sorry about that!
Could you also take a look at the new fix for the first crash?
Previously we think that lambda without trailing return couldn't
have return type defined inside its body, but for
```c
[] { // no parentheses for parameters
struct X {};
return X();
};
```
the proto has trailing return deduced to the type defined inside.
So I think we should remove the trailing return test for lambdas.
https://github.com/llvm/llvm-project/pull/101031
More information about the cfe-commits
mailing list