Skip to content

Can Pen be Embedded in a Rust App? #2100

Answered by raviqqe
zicklag asked this question in Q&A
Discussion options

You must be logged in to vote

Currently, Pen does not support direct embedding in Rust. I'm assuming that what you want to do is to embed codes in Pen in .rs files in Rust using macros or something.

However, you can put .pen and .rs files side by side and make them coexist in Rust projects calling pen build in a build.rs script. The build script should build an archive library from source codes written in Pen and export functions using foreign directives and then link it into the final Rust binary.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by zicklag
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants