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

Header is imcompatible with c++ #7

Open
hq6 opened this issue Aug 16, 2018 · 2 comments
Open

Header is imcompatible with c++ #7

hq6 opened this issue Aug 16, 2018 · 2 comments

Comments

@hq6
Copy link
Contributor

hq6 commented Aug 16, 2018

The header is not c++ friendly.

Reproducing the problem

Put the following program into a file called main.cc

#include "mpscq.h"
int main(){}

Compile with g++ -c main.cc and get multiple errors that look like this.

usr/lib/gcc/x86_64-linux-gnu/4.9/include/stdatomic.h:68:9: error: ‘_Atomic’ does not name a type
 typedef _Atomic __UINT_FAST32_TYPE__ atomic_uint_fast32_t;
         ^
/usr/lib/gcc/x86_64-linux-gnu/4.9/include/stdatomic.h:69:9: error: ‘_Atomic’ does not name a type
 typedef _Atomic __INT_FAST64_TYPE__ atomic_int_fast64_t;

@dbittman
Copy link
Owner

This is actually something that bothers me in general in C++. Since this is a compiler-provided header, I kinda wished it worked fine on both languages.

@hq6
Copy link
Contributor Author

hq6 commented Aug 17, 2018

I agree that this is a silly compiler issue, but I think as our thread on the #8 shows, there are many solutions to achieving compatibility with C++, and I think it would make this implementation more broadly useable.

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

No branches or pull requests

2 participants