kees wrote: > > This prints a wrapped calculation instead of the expected "0". > > Shouldn't `getDefaultBuiltinObjectSizeResult` return `-1`? Have you tried > `-2` to see if it's returning the negative count value or it happens to be > equal to the default value?
Well, maybe it's not wrapped, but it should absolutely return 0, not -1. The return value of -1 means "I don't know how large this is". In this case we _do_ know, but it's nonsense, so we must return 0 so that anything checking lengths will not write anything to the array. https://github.com/llvm/llvm-project/pull/76348 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits