r3wp [groups: 83 posts: 189283]
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

World: r3wp

[!REBOL3-OLD1]

Henrik
6-May-2009
[13967]
I suppose that restricting console access for encapped apps would 
involve simply not including console code?
BrianH
6-May-2009
[13968x2]
Similar to R2, though the errors start disarmed and need to be armed 
with DO. CAUSE-ERROR wraps this.
Henrik, sure :)
Henrik
6-May-2009
[13970]
I have some radical ideas for a console. Carl will hate them. :-)
BrianH
6-May-2009
[13971]
Carl doesn't have to use them - behold the power of modules.
Henrik
6-May-2009
[13972]
That's good. Perhaps for R3/Plus
Rebolek
6-May-2009
[13973x4]
Ah, vector! fixed, great! :)
#460 not fixed
Now it's not possible to make signed/unsigned vectors using "make 
vector! [- 16 integer! 100]" ? Or is the syntax different? I cannot 
find it anywhere.
Ah, #460 is not fixed because maximum-of doesn't work at all. This 
should be first line in the 'maximum-of function: "if not skip [size: 
1]"
Pekr
6-May-2009
[13977]
Rebolek - by testing in console - you have wrong order of arguments, 
try:

make vector! [integer! 16 100]

make vector! [unsigned integer! 16 100] ; there was change from hyphen 
to work "unsigned", dunno why - http://curecode.org/rebol3/ticket.rsp?id=350
BrianH
6-May-2009
[13978x3]
The new syntax for unsigned vectors is to use the 'unsigned word, 
not the '+ word. The optional '- word for signed vectors is gone 
too.
The reason why is because people didn't understand that '+ was for 
unsigned, and '- was forr signed.
Bug #460 was a FORSKIP bug, not a MAXIMUM-OF bug. FORSKIP now works 
with vectors, so the bug is now fixed.
Pekr
6-May-2009
[13981]
why + was for unsigned and not the reverse? :-)
BrianH
6-May-2009
[13982]
Are you aware of any negative unsigned numbers? :)
Pekr
6-May-2009
[13983]
I don't work at that level of REBOL. So we now have vector! datatype 
mostly fixed. One thing I don't understand is, that we are heading 
for performance, and then we can see minimum-of and maximum-of becoming 
mezzanines. The other thing is - what now? What is now available 
at practical level? What can we do with vector! type?
BrianH
6-May-2009
[13984x2]
They can be mezzanines and still be as fast because FORSKIP is now 
native. Making the looping functions native makes REBOL faster overall. 
One thing people don't get is that mezzannes can be really fast in 
R3.
Vector types take up less space for the same data, and you don't 
have to use type tests when working on them. They're for fast processing 
of numeric data, conversions, all sorts of low-level goodness.
Pekr
6-May-2009
[13986]
Could vector type help with stuff like DLL interfacing?
Henrik
6-May-2009
[13987x2]
We could use some practical vector! recipes in the cookbook list. 
This will give people a good idea for what they can do.
I suspect things like audio samples and very large data sets (geographical 
data, 16-bit image data) could be used for this.
BrianH
6-May-2009
[13989x2]
Probably so, Pekr. The underlying data of vectors corresponds to 
arrays in lower-level languages.
Henrik, I'd be happy if the wiki were updated with the alpha 51 semantics, 
but if you want to aim higher, go ahead :)
Steeve
6-May-2009
[13991]
But we could have some vector maths innside Rebol too
ie. V + 15, could add 15 to all the cells inside a vector.
Currently math operations are not allowed with vectors... why ?
Henrik
6-May-2009
[13992]
BrianH, I can't aim at all. I've never worked with vectors before, 
which is why I asked. If there was a small practical example, say 
for loading an AIFF file into a vector! array, Carl could mention 
it in his blog.
BrianH
6-May-2009
[13993]
Why not math? Because all of the alpha 51 changes were implemented 
in one night (afaIct), and because noone has suggested it yet.
Steeve
6-May-2009
[13994x2]
i don't ask for matrix operations currently (like adding or multiplying 
2 vectors).

I just wonder why simple tricks like adding or multiplyings all the 
cells with a scalar is not allowed
ok, then i ask for it
BrianH
6-May-2009
[13996]
You'll have to wait for multiple-dimension vectors before we do matrix 
operations :)
Steeve
6-May-2009
[13997]
add/skip or multiply/skip not enough ?
Lol
BrianH
6-May-2009
[13998]
And asking for it here doesn't help. Put in a CureCode ticket with 
proposed semantics (equivalent REBOL code is fine).
Steeve
6-May-2009
[13999x3]
You know me,i'm bas with your language (even if we
*bad
i know more or less 30% of the English words come from the Frensh 
(thanks to the Normands) but it doesn't  help me
BrianH
6-May-2009
[14002]
Well, I don't have the time to write CureCode tickets :(
Steeve
6-May-2009
[14003]
so i keep the tuples to do vector operations.
1.2.3 * 5  = 5.10.15
but it's quite limited
Henrik
6-May-2009
[14004]
is it appropriate to specify which part you want to perform the operation 
on?
Steeve
6-May-2009
[14005]
like what ?
BrianH
6-May-2009
[14006]
Can you do scalar math with vectors with the restriction that the 
vector is only on the left side of the equation? Does the math work?
Steeve
6-May-2009
[14007]
i don't see your point guys
Henrik
6-May-2009
[14008]
Forget what I said. :-)
BrianH
6-May-2009
[14009]
My point is that it is much more likely to get implemented as an 
action!, and actions dispatch based on the type of their first argument.
Steeve
6-May-2009
[14010]
sometimes i use a second tuple using it as a mask:
1.2.3 * 5 * 1.0.1 = 5.0.15
BrianH
6-May-2009
[14011x2]
Double dispatch could do the work in most cases, I suppose.
Can that be expressed as 1.2.3 * 1.0.1 * 5?
Steeve
6-May-2009
[14013x2]
yep
it works too, in any direction
BrianH
6-May-2009
[14015x2]
That's what I mean. It's an implementation detail, but it could be 
the difference between having this feature and not having it. We'll 
see.
Basic math operations are polymorphic, but dispatch based on the 
type of the first argument.