object states
Henning Pohl
henning at still-hidden.de
Sun Oct 7 11:44:08 PDT 2012
Imagine you want an image to keep the width of 512:
void func(Image img) {
assert(img.width == 512);
img.doSomething();
assert(img.width == 512);
while (img.somethingElse()) {
assert(img.width == 512)
someFunc(img);
assert(img.width == 512);
}
}
In theory, every call to a function can change the width of the
image. What do you think about this:
https://dl.dropbox.com/u/34762907/temp/prop1.html
I do know it can be implemented in D4 only.
More information about the Digitalmars-d
mailing list