Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Come up with syntax to insert snippets of C# in the forth code #11

Open
lucabol opened this issue Jan 14, 2022 · 1 comment
Open

Come up with syntax to insert snippets of C# in the forth code #11

lucabol opened this issue Jan 14, 2022 · 1 comment
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@lucabol
Copy link
Owner

lucabol commented Jan 14, 2022

It is a bit like the assembler for Forth systems. In case you don't want to re-write the whole world in forth you can reuse some .net library classes.

You also need a way to refer to the stack and data segment in C#, i.e. calling the function in VmExt. Either we rename them to be more friendly, or we inject friendlier methods. This work can then also be used for source generators.

: aWordThatIsImplementedInC# {{
    var a = VmExt.pop(ref vm);
    CallACSharpMethod(a);
}}
@lucabol lucabol added enhancement New feature or request help wanted Extra attention is needed labels Jan 14, 2022
@lucabol
Copy link
Owner Author

lucabol commented Feb 21, 2022

I have now a way to call static methods, but this is still valid. We can use Roslyn.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant