and it works as expected. But if instead of abcde I have a string with & inside,
set p=abcde call :mysub %p% exit /b :mysub echo %1
it does not work, as I understand because & is interpreted as escape character. I tried to put various numbers of ^ before & in line 1, but nothing works.
set p=ab&de call :mysub %p% exit /b :mysub echo %1