1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

echo without trailing space incompatibility

Discussion in 'TCC/LE Support' started by libit, Nov 25, 2015.

  1. libit

    Joined:
    Jun 5, 2015
    Messages:
    9
    Likes Received:
    0
    Hi,
    I've found a cmd script (from syncany installation) that uses the following (arguable) syntax:
    echo | set /p=hello!
    to achieve an echo without trailing carriage return (like tcc's "echos").

    This doesn't work on my tcc/le though (TCC LE 14.00.6 x64 Windows 10 [Version 6.3.10240] TCC LE Build 6 Windows 10 Build 10240).

    The effect is not drammatic: you just get a dump of all variables instead of intended output; anyway it might be worth to try and replicate cmd's behavior.

    On the other hand, this would work on both cmd and tcc:
    echo | set /p nocr=hello!

    Cheers
    Lbit
     
  2. rconn

    rconn Administrator
    Staff Member

    Joined:
    May 14, 2008
    Messages:
    9,813
    Likes Received:
    82
    It's a CMD bug (the Microsoft docs say that the prompt can be empty, but the variable name cannot be). I will take a look at adding a kludge for the next build of TCC/LE.
     

Share This Page