Hello, This is the first communication from the KEYSTROKE LIBERATION FRONT.
In these times, many keys re unnecessarily enslaved. We aim to liberate them. > > But we'd encourage this: > > > > TUPLE: color "red" "green" "blue" ; > > Why would you encourage that vs the version without quotes? The > version without quotes is nicer to read and easier to type. Let me make this even more concrete. The double-quote has a 2 keystroke cost. This means each field has a 4 keystroke cost. The tuple above has an overhead of 12 keys. A tuple with 4 slots? 20 keys. In my judgement, this is totally unacceptable. The double-quote has been thus far reserved for strings. I'm not a fan of overloading them for this case. I am OK with a "-based syntax for thing like path objects; p" etc. Now let's look at solutions. I like the idea of typed slots. I like the idea of a per-slot initial value. I want low keystroke overhead. Basic syntax: TUPLE: color red green blue ; Typed slots: TUPLE: color red/int green/int blue/int ; Slots with initial values: TUPLE: color red=0 green=0 blue=0 ; Typed slots with initial values: TUPLE: color red/int=0 green/int=0 blue/int=0 ; I'm fine with not allowing '/' and '=' as part of slot names. I'm in favor of using '/' to indicate type, not just for slots but in method signatures. I agree that a typed slot without a use specified default value should initialize with a value default for that type. Why / and = ? Both are commonly unshifted, except on some international keyboards. Ed ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk