• BUG in tclsh "BRE" is not accepted

    From aotto1968@21:1/5 to All on Thu May 8 09:07:44 2025
    docu


    An ARE may begin with embedded options: a sequence (?xyz) (where xyz is one or more alphabetic characters) specifies
    options affecting the rest of the RE. These supplement, and can override, any options specified by the application.
    The available option letters are:

    b rest of RE is a BRE

    echo 'regexp {(?b\<otto\>)} "hallo otto home"' | tclsh
    couldn't compile regular expression pattern: invalid embedded option


    → don't know HOWTO activate a BRE

    (the reason for this question is that BRE is the default RE of the "grep" command and
    if TCL and GREP work together they COULD share the BRE)

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From schmitzu@21:1/5 to All on Thu May 8 12:33:16 2025
    As the documentation says, the closing brace has to be rigth after the
    option character:

    regexp {(?b)\<otto\>} "hallo otto home"

    works for me.


    Am 08.05.2025 um 09:07 schrieb aotto1968:
    docu


           An ARE may begin with embedded options: a sequence (?xyz) (where
    xyz is one or more alphabetic characters) specifies
           options affecting the rest of the RE. These supplement, and can override, any options specified by  the  application.
           The available option letters are:

             b  rest of RE is a BRE

    echo 'regexp {(?b\<otto\>)} "hallo otto home"' | tclsh
    couldn't compile regular expression pattern: invalid embedded option


    → don't know HOWTO activate a BRE

    (the reason for this question is that BRE is the default RE of the
    "grep" command and
    if TCL and GREP work together they COULD share the BRE)

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)