Skip to content

Allow unsafe/native code #70

@monstermichl

Description

@monstermichl

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`)

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions