Welcome!

By registering with us, you'll be able to discuss, share and private message with other members of our community.

SignUp Now!

Bug With Flow Control and/or Command Grouping

Jun
570
4
I just discovered a problem with flow control and/or command grouping. To illustrate it, consider the following alias definition:

alias zz=if not a eq a (echo one & echo two) & echo three

Since the IF clause is false, I expect the command group not to run, but I expect the additional command to run and echo "three" to the screen. That's exactly what happens with TCMD/TCC v.25.

TCC(25.00.30): C:\>zz
three

TCC(25.00.30): C:\>

With v.27, there is no output.

TCC(27.00.21): C:\>zz

TCC(27.00.21): C:\>

If I change the alias definition to make the IF test true, then three lines are echoed as expected.
 
That was it. I don't know how that setting got changed. Since I never use CMD and have no interest in having TCC reproduce its bugs, I always turn off that option. However, I just looked, and it had gotten turned on. During some of the wild TCMD crashed (reported on elsewhere), I had the feeling that some of my settings were getting scrambled. Maybe that's how it happened. Or maybe I just missed the setting. Anyway, I'm glad to have it fixed.
 
Back
Top
[FOX] Ultimate Translator
Translate