Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sun-barr!olivea!decwrl!mcnc!uvaarpa!mmdf From: worley@compass.com (Dale Worley) Newsgroups: comp.lang.perl Subject: Crock involving $^ Message-ID: <1991Feb8.174228.678@uvaarpa.Virginia.EDU> Date: 8 Feb 91 17:42:28 GMT Sender: mmdf@uvaarpa.Virginia.EDU (Uvaarpa Mail System) Reply-To: worley@compass.com Organization: The Internet Lines: 21 Beware when using the $^ variable to always follow it with a whitespace character! Otherwise the next character will be eaten and (probably) the variable misinterpreted. The culprint is the following two lines from scanreg() in toke.c: if (*d == '^' && !isspace(*s)) *d = *s++ & 31; It appears that these are to allow constructions like: $^T means "the variable whose name is control-T". Since there are no such variables anymore, these lines should probably be removed. (It would not be simple to restrict the third character of the construction to characters that can be legitimately controlized (letters, @, [, \, ], _, ^), because '^' is also an operator, leading to $^^ meaning either "the variable control-^" and "the variable $^ followed by the operator ^". Dale Worley Compass, Inc. worley@compass.com -- I try to make everyone's day a little more surreal.