Skip to content

Tutorial for calling C from pforth #220

@PaliDerek

Description

@PaliDerek

I see this description in the pforth Reference documentation:

You can call 'C' from pForth by adding your own custom 'C' functions to a dispatch table, and then adding Forth words to the dictionary that call those functions. See the file "pfcustom.c" for more information.

But when I look at the code, I'm still drawing a blank on what to do. I was hoping you could add to the Tutorial a section on how to call a trivial custom C function, that perhaps takes a single argument, then the steps to build it. Please?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions