Boost logo

Boost :

Subject: Re: [boost] [contract] toward N3351 concepts
From: Felipe Magno de Almeida (felipe.m.almeida_at_[hidden])
Date: 2012-10-08 17:21:09


On Mon, Oct 8, 2012 at 4:40 PM, Lorenzo Caminiti <lorcaminiti_at_[hidden]> wrote:
> On Mon, Oct 8, 2012 at 12:02 PM, Evgeny Panasyuk
> <evgeny.panasyuk_at_[hidden]> wrote:
>> Currently, I inclined to following approach:
>> 1. Compiler MUST not do any checks on axioms besides syntactic.
>> 2. User has ALL responsibility on verifying axioms.
>> 3. Compiler has rights to exploit any knowledge which it gets from axioms,
>> regardless of fact if type fulfil them or not.
>
> IMO, this is a rather weak motivation to support axioms especially in
> the core language (just the syntax check of some code that could
> otherwise and almost equivalently be written using code comments) but
> it seems to be the only sensible thing to do with axioms.
>
> Despite the weak motivation, I'm thinking to support axioms in
> Boost.Contract so to check them syntactically. Ultimately, if users
> don't want to use axioms, they can just not use them (and maybe
> document the concept semantics via code comments).

You find compiler optimization from axioms a weak motivation (3)?
Why?

> --Lorenzo

Regards,

-- 
Felipe Magno de Almeida

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk