News for hackers. Stuff that matters.
Re:Felix - a fast scripting language by munificent on Friday January 04, 2013 @04:39PM (#5010110)
If you're coming from a type theory background (which, granted, few are), this operator is actually perfectly natural.

http://en.wikipedia.org/wiki/Product_type

Re:Felix - a fast scripting language by andrewflnr on Saturday January 05, 2013 @12:58AM (#5011824)
I don't come from much of a type theory background. I certainly have no formal education in the field. I just know how a Cartesian product works, and that's enough to make me get it.
Re:Felix - a fast scripting language by lambdaphage on Saturday January 05, 2013 @12:02AM (#5011682)
Aren't product types just tuples, whereas arrays correspond to list types? The '^' operator can only construct arrays whose elements are of a single type, right?
Re:Felix - a fast scripting language by Yttrill on Saturday January 05, 2013 @01:52AM (#5011947)
That's correct. However, somewhat problematically, Felix considers the tuple int * int to actually be an array int ^ 2. It's not entirely clear this "automatically applied isomorphism" is a good idea though. However it means arrays "drop out" of the notion of a tuple as a special case.

Internally such arrays have a special representation which allows arrays of 100,000 values, something which could never be represented by a tuple type (and still get reasonable compile times :)