#2714 Parser not catching hanging "]" or "}"

obsolete: 8.4.2
closed-invalid
miguel sofer
5
2004-05-10
2004-05-10
Jeremy Gibson
No

Using the following commands:

set str 123
123
set str1 $str]
123]
set str1 $str}
123}

Is this how the parser is supposed to act? I was
expecting the parser to complain about missing a "{"
or "[" based on the error.

Discussion

  • miguel sofer
    miguel sofer
    2004-05-10

    • status: open --> closed-invalid
     
  • miguel sofer
    miguel sofer
    2004-05-10

    Logged In: YES
    user_id=148712

    This is correct and documented behavior, see the manual page
    Tcl(n).
    The symbols ] and } have special meaning only within words
    starting with [ and { respectively.