> On 30 Apr 2015, at 21:47, stepharo <[email protected]> wrote:
>
> In nautilus I get an error MNU: RBBlockNode>>method
> When I select several groups and select merge
>
>
> mergeGroups: aCollection
>
> aCollection
> ifNotEmpty: [:groups || group |
> group := groups reduce: [:a :b | a or: [b]].
> ^^^^^^^^^^^^
>
> a is a dynamicClassGroup and
> its superclass defines or:
>
The mistake is the block around the b.
or: in DynamicGroup is defined as
or: aGroup
and if you do not put a block, the compiler will not optimise or: —> it will be
send.
(and the or: in DynamicGroup will just raise an error when it gets passed a
block, it
expects a group).
But there is a second error: the mustBeBooleanInMagic: normally should work.
(the VM executes the optimised construct —> raised an exception —> we recompile
the expression with no optimisation -> execute.
There is tiny bug there (it should be #methodNode).
I will commit a fix for that…
(I hope this is understandable.. as two bugs are involved this might be a bit
complex.
>
> RBBlockNode(Object)>>doesNotUnderstand: #method
> RBBlockNode>>sourceNodeForPC:
> DynamicClassGroup(Object)>>mustBeBooleanInMagic:
> D
Marcus