Oldes / Rebol-wishes

Repository for keeping Rebol related wishes out of issues
0 stars 0 forks source link

WISH: implement VECTOR of PAIR values #9

Open Siskin-Bot opened 4 years ago

Siskin-Bot commented 4 years ago

Submitted by: Oldes

As internally pair! is stored as 2 32bit decimal numbers, it should be possible to have vector! of pair!s. Proposed possible behaviour:

>> points: make vector! [pair! 4]
== make vector! [pair! [0x0 0x0 0x0 0x0]]
>> points/1: random 100x100
== 65x23
>> points
== make vector! [pair! [65x23 0x0 0x0 0x0]]

Imported from: https://github.com/rebol/rebol-issues/issues/2356

Comments:

Oldes commented on Jan 24, 2019:

Unfortunately the original internal implementation has only one bit for storing the type (integer or decimal). So it would need some rework, but being able to work with array of points directly is probably worth the change.


Hostilefork added the Datatype.vector on Jan 24, 2019