On 12/3/20 12:07 PM, Andrew Sutton wrote:
> Attached is a new squashed revision of the patch sans ChangeLogs. The
> current work is now being done on github:
> https://github.com/lock3/gcc/tree/contracts-jac-alt
<https://github.com/lock3/gcc/tree/contracts-jac-alt>
I'm starting to review this now, sorry for the delay. Is this still the
branch you want me to consider for GCC 11? I notice that the
-constexpr
and -mangled-config branches are newer.
I think so. Jeff can answer more authoritatively. I know we had one set
of changes to the design (how contracts) work aimed at improving the
debugging experience for violated contracts. I'm not sure if that's in
the jac-alt branch though.
The -constexpr branch checks for trivially satisfied contracts (e.g.,
[[assert: true]]) and issues warnings. It also preemptively checks
preconditions against constant function arguments. It's probably worth
reviewing that separately.
I'm not sure the -manged-config branch is worth considering for merging
at this point. It's trying to solve a problem that might not be worth
solving.
OK, I'll start with -alt then, thanks.
Out of curiosity, are you concerned that future versions of contracts
might have considerably different syntax or configurability? I'd hope it
wouldn't, but who knows where SG21 is going :)
Not particularly; I figure that most of the implementation would be
unaffected.
Jason