[Seaside-dev] Issue 268 in seaside: Introduce WAMessageSend

codesite-noreply at google.com codesite-noreply at google.com
Sat Jan 3 19:43:57 UTC 2009


Comment #9 on issue 268 by jfitzell: Introduce WAMessageSend
http://code.google.com/p/seaside/issues/detail?id=268

That's getting pretty fancy - do we have a use case that actually needs it?

I can imagine an implementation a bit like ROE using exactly the block you  
specify above:

instance := WAWhateverThisClassIsCalled
     selector: #foo:bar:zork:
     do: [:x :y | y foo: a1 bar: a2 zork: x]

the instance creation method would check how many arguments the block had  
and pass special objects in for
each one. Then it would evaluate the block and be able to tell which  
argument was the receiver and (since the
method gets called on it, what the parameters were). It's less clear what  
the implementation is if you want to
specify the receiver at creation time. I guess you have to add the receiver  
as a parameter to the block:

instance := WAWhateverThisClassIsCalled
     receiver: MyClass
     selector: #foo:bar:zork:
     do: [ :receiver :x :y | receiver foo: a1 bar: a2 zork: x]

It's a little wonky and given that it probably the more common use case,  
that's a shame. But it would work.

So, I think that's quite cool actually but... do we need it?

--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings


More information about the seaside-dev mailing list