Skip to content

How is ClangSharp compared to CppSharp? #482

Answered by tannergooding
ghost asked this question in Q&A
Discussion options

You must be logged in to vote

They are different projects with different goals.


ClangSharp's goal is to create 1-to-1 blittable bindings (such that they work with [assembly: DisableRuntimeMarshalling]), primarily over C code and supports a limited subset of C++ (such as Windows COM) where a stable ABI is possible.

There then exists some support for also processing a subset of #define macros that are declaring constant like data and for handling inline functions that use portable expressions/statements.

Even the ClangSharp AST provided is essentially as 1-to-1 as you can get over the corresponding Clang C++ API surface area.

CppSharp on the other hand is not so 1-to-1 and takes various creative liberties. It also aims…

Replies: 1 comment

Comment options

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