Not even mentioning Eiffel in an article about contract
programming is weird..
Daniel Murphy:
Issue 519 is about classes, while 9454 is about structs. 9454
uses a struct
literal, not an autogenerated constructor call, so they are
different bugs.
519 is an actual bug, while 9454 is an enhancement.
Right, 9454 is tagged as enhancement since the beginning. But
learning
"bearophile" wrote in message
news:dklglravazsxxbvrl...@forum.dlang.org...
>
> They are very similar, the test case from Issue 519 uses a new:
>
[snip]
>
> While in Issue 9454 (just like in that Ada code) there is no new:
>
[snip]
>
> Maybe my Issue 9454 should be merged with Issue 519.
>
Issue
Walter Bright:
Invariants, per the spec, [...]
Right, I was proposing a little spec change.
Don:
Sounds like bug 519 to me.
http://d.puremagic.com/issues/show_bug.cgi?id=519
Hours ago I have added this:
http://d.puremagic.com/issues/show_bug.cgi?id=9454
They are ve
On Wednesday, 6 February 2013 at 04:05:23 UTC, Walter Bright
wrote:
On 2/5/2013 8:57 AM, bearophile wrote:
D doesn't call the invariant even in that second case, as you
see from this code
that doesn't assert:
Invariants, per the spec, are called on the end of
constructors, the beginning of d
On 2/5/2013 8:57 AM, bearophile wrote:
D doesn't call the invariant even in that second case, as you see from this code
that doesn't assert:
Invariants, per the spec, are called on the end of constructors, the beginning
of destructors, and the beginning and end of public functions. Foo does no
Am 05.02.2013 19:26, schrieb bearophile:
FG:
When should Dist's state validity be checked?
Maybe a good answer is written in the Ada2012 Standard.
Bye,
bearophile
A look should also be given to Eiffel, after all it is the
language that created the notion of design by contract, AFAIK.
--
P
FG:
When should Dist's state validity be checked?
Maybe a good answer is written in the Ada2012 Standard.
Bye,
bearophile
On 2013-02-05 17:57, bearophile wrote:
In D this code doesn't asserts:
struct Foo {
int x = 200;
invariant() { assert(x > 100); }
}
void main() {
auto f = Foo(10);
}
Maybe it's good to introduce in D as in Ada a call to the invariant when the
whole struct is assigned.
There'
An article about Contract-Driven Programming:
http://electronicdesign.com/contributing-technical-experts/contract-driven-programming-takes-specification-beyond-stone-age
The article presents a little problem to be solved with contracts
and the like:
<<
a simple system where physical objects a
10 matches
Mail list logo