-
-
Notifications
You must be signed in to change notification settings - Fork 3
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
Fix some Compiling Errors #20
Fix some Compiling Errors #20
Conversation
Thank you for the merge request. This is the very first one ever :) Would you mind sharing your setup so I can prevent this issue in the future? It was probably because of multiple source files that include gaia.h, right? |
I'm sure there is something in the setup for more pedantic and stricter rules for explicit conversion, I will share more details later.
yes, I'm including |
From my experience, using these for Clang: It catches different things on my Linux in Docker, on my native MacOS and also on Godbolt even though the same compiler version is used. I need to figure this out somehow. For the time being, I managed to fix a bunch of other issues as well (hopefully all of them). |
For Context abeimler/ecs_benchmark#17 |
I see. Nice to see the framework doesn't fare bad against the rest even in its early stages. |
This specifically only happens (or rather, happened) when building with /std:c++20 or later. |
No need to bump compiler requirements. While std::span is a C++20 feature indeed, the project has a backwards-compatible version of span implemented. Thanks to that it can continue running on C++17. When native support is detected the project makes use of it. The issue is that the compatibility layer implementation differs slightly from the mainline. I'll look into it in the future. For the time being, I switched to building the project with later C++ versions as well to avoid similar issues missing my eye. |
@richardbiely Right, I didn't see the namespace std {using TCB_SPAN_NAMESPACE_NAME::span;} in span.h 😅 cool if a little bit unexpected. Does make the transition cleaner though! |
Exactly :) Although later standards bring many interesting new features to the table, I am aiming for C++17 because it is well adopted and also reasonably nice feature-wise. To me, std::span is the only obvious feature missing from 17. I could easily replace all occurrences of it with a pointer+size variables, but that makes the code way less readable (and spans are used a lot by the project). |
Hi,
I was trying out gaia-ecs in my Project and encountered some Compiler- and Linking-Error(s):
Can not convert to
std::span
Error:
Linking Error for
EntityBad
Error: