Alcaro wrote:

I agree the worst case would be bad; if I'm reading things correctly, it'd be 
quadratic for things like
```c
if (int* a = something()) return *a;
else if (int* b = something()) return *b;
else if (int* c = something()) return *c;
else if (int* d = something()) return *d;
else if (int* e = something()) return *e;
else return -1;
```
where it'd check the `return *e;` four times, \*d three times, etc.

Though I'd expect such code patterns to be rare in practice, and the constant 
factor to be good.

(Also github stop re-checking mergeability every single time someone updates 
main, it messes with the scrollbar)

https://github.com/llvm/llvm-project/pull/156436
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to