-
Sorry about formatting, it looked ok when I hit enter, no clue what happended then.
Regards,
David.
2009-11-10 19:56:57 UTC by dlebansais
-
I'll set aside the issue with LIST for now.
I assume we can use immutable types as parameters of a feature? If so, consider:
myquery(x: immutable T): BOOLEAN
do
-- Some stuff wih x here
end
test
local
callresult: BOOLEAN
do
callresult := myquery(global)
end
global: T -- Created somewhere
Am I correct if I say...
2009-11-10 19:54:20 UTC by dlebansais
-
helmut_brandl committed revision 319 to the tecomp: The Eiffel Compiler SVN repository, changing 4 files.
2009-11-10 18:55:12 UTC by helmut_brandl
-
helmut_brandl committed revision 318 to the tecomp: The Eiffel Compiler SVN repository, changing 16 files.
2009-11-10 16:23:13 UTC by helmut_brandl
-
ad 2) The concept does not invalidate existing code. LIST can be used as before. But if you have an immutable LIST, you cannot call features like start and forth on it. If some queries of LIST use that features, they change the object. But you can use them on immutable objects, because immutability just means "no commands possible". If a query internally uses start and forth and restores the...
2009-11-10 13:44:42 UTC by helmut_brandl
-
Forget about 3), I shouldn't be posting at 3am. :)
I think this could create a whole new class of CAT calls, but they can probably be detected as easily as others, and not happen with good design.
Regarding 2), if the new syntax can't accomodate existing libraries, or provide benefits sufficiently compelling to suggest a modification of these libraries, then it has low chances of success.
2009-11-10 10:12:49 UTC by dlebansais
-
ad 1) Clearly, creation procedures shall be availalbe. Otherwise it were not possible to create immutable objects. I don't consider creation as a modification.
ad 2) The problems of internal cursors..... I don't know how to solve this problem. But I am not very concerned about it either. I want to find a way to statically verify assertions. If the concept of immutability helps to achieve...
2009-11-10 02:15:47 UTC by helmut_brandl
-
Thanks for the clarification. The text at http://tecomp.sourceforge.net/index.php?file=doc/papers/lang/immutability.txt is unchanged for me, but no big deal I get the idea.
Three things:
1) You might want to consider making some commands available: creation procedures. I'm not saying they should or shouldn't be available, I'm just opening a new avenue for discussion.
2) Prohibiting...
2009-11-10 01:45:17 UTC by dlebansais
-
helmut_brandl committed revision 317 to the tecomp: The Eiffel Compiler SVN repository, changing 1 files.
2009-11-10 00:59:59 UTC by helmut_brandl
-
I have added some more description to the paper. Hope that it is clearer now.
Regards
Helmut.
2009-11-10 00:11:43 UTC by helmut_brandl