Perhaps using a name other than ZERO, like INTEGERZERO or ZERO4BYTES makes it clear what it is supposed to be addresses the documentation issue and makes only one place to fix in case 2-2 gets optimized at a later date. I'm sure a better name could be picked, but using 2-2 is also obscure and optimization may break it in the future. See the questions and discussion it has caused already?
Obviously there is a reason why just plane zero won't work. What size integer is needed? 32 bit, 64 bit? 2-2 could result in either, depending on the interpreter. On Thu, Oct 14, 2010 at 7:43 PM, bill lam <[email protected]> wrote: > Use 2-2 instead of some name ZERO is more self-documenting. ;-) > A more compelling reason is that sometime a constant cannot be used because > of aliasing in cd interface. > > Чтв, 14 Окт 2010, Martin Pelletier писал(а): > > Well, I'm not one to argue (wait, no, that's a lie, I am!), but isn't > > eventual porting a very good reason to abstract this and use a constant? > > By which I mean local to this script, nothing system wide. In this way, > > less code to maintain and update if the implementation of 0 changes. > > > > Just a thought. > > > > Martin Pelletier > > > > On 2010-10-14 19:37, bill lam wrote: > > [---=| TOFU protection by t-prot: 4 lines snipped |=---] > > -- > regards, > ==================================================== > GPG key 1024D/4434BAB3 2008-08-24 > gpg --keyserver subkeys.pgp.net --recv-keys 4434BAB3 > ---------------------------------------------------------------------- > For information about J forums see http://www.jsoftware.com/forums.htm > ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
