To overcome limitations (especially for Batch), it could be a good idea to allow unsafe/native code. For that it could be possible to include a preprocessor to check for which platform to transpile the code and then only include the appropriate section.
This might be solved using special comments or by introducing a completely new pattern (e.g. like in C with #...). E.g.
// #if ${TYPESHELL_TARGET} == "batch"
// for %%F in (*) do @echo %%~tF %%~zF %%F
// #endif
It might also be possible to add a builtin like unsafe that receives a string that is then included in the code. E.g.
unsafe(`for %%F in (*) do @echo %%~tF %%~zF %%F`)
To overcome limitations (especially for Batch), it could be a good idea to allow unsafe/native code. For that it could be possible to include a preprocessor to check for which platform to transpile the code and then only include the appropriate section.
This might be solved using special comments or by introducing a completely new pattern (e.g. like in C with #...). E.g.
It might also be possible to add a builtin like unsafe that receives a string that is then included in the code. E.g.