[Pharo-dev] , for vector creation

Ben Coman btc at openinworld.com
Thu Oct 26 23:29:58 EDT 2017


On Thu, Oct 26, 2017 at 11:45 PM, Tudor Girba <tudor at tudorgirba.com> wrote:

> Thanks everyone for the nice discussion.
>
> So, after all arguments, we will remove Number>>, from Bloc.
>
> I think using Number>>, for vector creation makes quite some sense.
> However, we have already seen that we have a few places where we have
> vectors: Bloc, PolyMath and Moose-Algos. The Bloc needs are smaller than
> the needs from PolyMath (we need only a limited set of abilities). So,
> until we have one consensus of having one vector in the image, we can leave
> room for playing.
>
> In the meantime we have:
>
> 1.
> BlVector x: 10 y: 20
> BlVector x: 10 y: 20 z: 30
>
> or:
>
> 2.
> (10 at 20) asBlocVector
> (10 at 20@30) asBlocVector


> The 2nd option reads ok, but it has the downside that it needs an extra
> object (the point).
>

Would it be possible/desirable to have this as a single primitive backed
keyword message?
(10@:20@:30)
Perhaps a goal for the consensus on one-true-vector form integrated into
the Image?
Except at the moment "@:" doesn't parse.

cheers -ben



>
> An interesting thing about Number>>@ is that it is backed by a primitive.
> This can be quite relevant and I think it would be worthwhile thinking
> about vector/matrix specific optimizations as well. That is why, in the
> future, it would be interesting to consider primitives for vector/matrix
> creation.
>
> Cheers,
> Doru
>
>
> > On Oct 26, 2017, at 5:10 PM, Sean P. DeNigris <sean at clipperadams.com>
> wrote:
> >
> > Tudor Girba-2 wrote
> >> You mean like sending @ to a number, right? :)
> >
> > Ha ha, you got me ;)
> >
> >
> >
> > -----
> > Cheers,
> > Sean
> > --
> > Sent from: http://forum.world.st/Pharo-Smalltalk-Developers-f1294837.
> html
> >
>
> --
> www.tudorgirba.com
> www.feenk.com
>
> "Not knowing how to do something is not an argument for how it cannot be
> done."
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pharo.org/pipermail/pharo-dev_lists.pharo.org/attachments/20171027/c2e064aa/attachment-0002.html>


More information about the Pharo-dev mailing list