Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Unit Tests
Event Timeline
Thanks!
clang/lib/Sema/SemaDecl.cpp | ||
---|---|---|
17752 | What's happening during the crash:
As discussed, an alternative is to add a guard for incomplete-type EltTy (and assert that we only see this case for recovery-expr case), a disadvantage is that this might be narrow... The current solution also seems fine to me. | |
clang/test/Sema/enum.cpp | ||
1 | I'd put the test case in clang/test/SemaCXX/recovery-expr-type.cpp |
Hi, @sammccall thanks for the patch.
The precommit checks suggest that some test cases failing, could you please fix them. Thanks
Thanks, and sorry for sitting on this so long.
Addressed comments. I think the failing windows bots were implicit -fms-extensions or so that sometimes makes diagnosis more lazy. Moving the test to recovery-expr-type.cpp should take care of this as that test case specifies -triple. But waiting for the windows bot to finish before landing.
clang/test/Sema/enum.cpp | ||
---|---|---|
8–9 | Yeah, the thing we're testing is that we can const-evaluate these, and it neither crashes nor propagates dependence further. The static_assert checks the latter. Replaced with a static assert that isn't sensitive tot he actual value. |
What's happening during the crash:
As discussed, an alternative is to add a guard for incomplete-type EltTy (and assert that we only see this case for recovery-expr case), a disadvantage is that this might be narrow...
The current solution also seems fine to me.