Quuxplusone added a comment.

In D119094#3301403 <https://reviews.llvm.org/D119094#3301403>, @sammccall wrote:

> In D119094#3301297 <https://reviews.llvm.org/D119094#3301297>, @Quuxplusone 
> wrote:
>
>> Unfortunately some existing tests fail: 
>> https://reviews.llvm.org/harbormaster/unit/view/2282838/
>> I haven't yet figured out why consteval functions are considered to have 
>> `FD->isInvalidDecl()`. There's also an Objective-C failure that I assume 
>> indicates sometimes (when this is a //method// not a //function//) we have 
>> no `FD` at all. I'd need to solve both of these problems (the former being 
>> the difficult one) before I can make progress here.
>
> The example seems to be invalid even apart from the missing return value. (I 
> assume on purpose).

Ohhh, wow, I had missed that. In that case, I'm shocked that Clang isn't giving 
any more serious error message: shouldn't it be considered invalid, and 
diagnosed as an error, to have a `constexpr` definition followed by a 
`consteval` redefinition?
https://godbolt.org/z/vKjGvEor8
However, I think the pattern of operators used (`++--*/*/`) indicates that the 
original author made a typo there, and it should always have been `+-+-*/*/`. 
So I'll feel good about changing that test.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D119094/new/

https://reviews.llvm.org/D119094

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to