On 27 January 2017 at 00:28, Chris Cunningham <cunningham.cb@gmail.com> wrote:
On Thu, Jan 26, 2017 at 2:02 PM, stepharong <stepharong@free.fr> wrote:
On Thu, 26 Jan 2017 20:38:49 +0100, Torsten Bergmann <astares@gmx.de> wrote:
...
Instead it is sent to an object that afterwards is a constant within a method (so it will not be evaluated later at runtime again) so IMHO #asMethodConstant instead of #asMethodConst would be better.
I do not understand any of them.
In other words, this is creating a constant inside the method (#asMethodConstant) instead of making the method return a constant (which would be your #asConstantMethod). If I have that right. In any case, not having the contracted 'Const' would be nice.
ah.. that sounds similar to what i proposed for computed literals, that has been computed at compilation time and placed in method's literal frame, a simple catch by reserving special selector for it, i.e..:
mymethod ^ (something that should be computed , and takes a loong time) asMethodLiteral but that, of course, won't work if you would want to cache results based on method's input parameters.
-cbc
-- Using Opera's mail client: http://www.opera.com/mail/
-- Best regards, Igor Stasenko.