bjope wrote:

@cor3ntin , our downstream code is doing some extra semantic checks using code 
like this in Sema::CheckVariableDeclarationType:

```
  if (!T->isIncompleteType() && !isDependentOrGNUAutoType(T) && 
!T->isPlaceholderType()) {
    uint64_t Size = Context.getTypeSizeInChars(T).getQuantity();
   ...
  }
```
That is hitting the infinite recursion.

So we protect the type size calculation by checking if the type is incomplete, 
dependent, etc.
But as Bevin pointed out here 
https://github.com/llvm/llvm-project/pull/72644/files#r1469490392 the "broken" 
PackIndexingType isn't reported as isDependent, and neither as isIncomplete.

I must say that I don't know that much about this to say what is correct. Maybe 
out downstream semantic checks should be protected in some more way to avoid 
this problem.

https://github.com/llvm/llvm-project/pull/80439
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to