- May
- 239
- 2
Was just testing v15 and noticed that one of my batch-files did not work.
I narrowed it down to aliases not being recognized in command groups.
Demo:
Output:
1 - call alias, works
test
2 - alias on same line in command group - works
test
test
3 - no alias in command group and on separate lines, works
test no alias
test no alias
4 - alias on separate lines in command group, fails in v15, works in v12!
test
TCC: C:\Users\Niklas\test2.btm [22] Unknown command "echotest"
I narrowed it down to aliases not being recognized in command groups.
Demo:
Code:
@echo off
setlocal
alias echotest=`echo test`
echo 1 - call alias, works
echotest
echo 2 - alias on same line in command group - works
(echotest & echotest)
echo 3 - no alias in command group and on separate lines, works
(
echo test no alias
echo test no alias
)
echo 4 - alias on separate lines in command group, fails in v15, works in v12!
(
echotest
echotest
)
Output:
1 - call alias, works
test
2 - alias on same line in command group - works
test
test
3 - no alias in command group and on separate lines, works
test no alias
test no alias
4 - alias on separate lines in command group, fails in v15, works in v12!
test
TCC: C:\Users\Niklas\test2.btm [22] Unknown command "echotest"