Skip to content

How is C2CS compared to ClangSharp? #154

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

You must be logged in to vote

Hello @iahung3,

ClangSharp is provided by Microsoft and is highly used for scenarios where interop with Win32 from C#. I used ClangSharp (the C# API) directly in my earlier various of C2CS, but found it to be troublesome for returning some data in some contexts for purposes of cross-platform bindings. Later versions of C2CS used direct Clang bindings from ClangSharp, but now I use the NuGet package of ClangSharp for downloading Clang native libraries.

C2CS is intended for C libraries specifically made for purposes of libraries that are cross-platform. It's made to work on macOS, Linux, and Windows. The intended use case is that abstract syntax tree is parsed for each platform and then mer…

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