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

compatible c and c++ #18

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

tk-aria
Copy link

@tk-aria tk-aria commented Jun 16, 2021

Hey @velipso
Modified so that it can be used as a library from c++.
please merge this!

@velipso
Copy link
Owner

velipso commented Jun 16, 2021

I'm confused... isn't it possible to use as an external library from C++ via something like:

extern "C" {
#include "reverb.h"
}

?

@tk-aria
Copy link
Author

tk-aria commented Jun 16, 2021

sure. That way is also possible!
but I think many developers don't understand the difference between C and C++ about mangling and demangling, so I think it's better to use it simply.

don't you think so?

@velipso
Copy link
Owner

velipso commented Jun 16, 2021

I can leave the PR open and if someone wants it they can grab it

@tk-aria
Copy link
Author

tk-aria commented Jun 16, 2021

hmm...
Why don't you want to incorporate the changes?

@velipso
Copy link
Owner

velipso commented Jun 16, 2021

Well, it's a judgement call, so there isn't a hard rule... this does make it easier to incorporate into a C++ project, but it also makes the code more complicated. For this library, I've tried to keep the code as simple as possible, so I don't think the trade is worth it in this case. I like keeping the PR open so that if someone in the future asks for a C++ version, I can simply point to this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants