> On 07 Jan 2016, at 13:11, Denis Kudriashov <[email protected]> wrote: > > Hi > > I look at implementation of BlockClosure>>ifError: . I did't know that it > culls arguments to errorBlock. > But what is this arguments? It is not error instance but specific properties > from it. > > BlockClosure>>ifError: errorHandlerBlock > > ^ self on: Error do: [:ex | > errorHandlerBlock cull: ex description cull: ex receiver] > > Why people doing that? > Many users of it just pass given error like > > [...] ifError: [:msg :rcv | ... > rcv error: msg]. > > Especially it is commonly used scenario by senders of #critical:ifError:. > But it is different question. > > I propose change ifError: to cull error instance. > > What you think? Can be put it in Pharo 5? Such change can touch some packages
If think it makes more sense to #cull: the exception instance, it is more object oriented. And it is what I would expect.
