Comments (4)
I need some more information to able to help you here.
What OS are you using, compiler or build system. Would also be useful to know what version of Tileson you use as well :)
If your build system is somehow set to something lower than C++17, you'd probably get an error like this, but I really have nothing to go on to help you here, yet.
Edit: A small code snippet could also be useful, unless you can link me to a project.
from tileson.
I need some more information to able to help you here.
What OS are you using, compiler or build system. Would also be useful to know what version of Tileson you use as well :)
If your build system is somehow set to something lower than C++17, you'd probably get an error like this, but I really have nothing to go on to help you here, yet.Edit: A small code snippet could also be useful, unless you can link me to a project.
I'm using Windows 10 with the MinGW-w64 toolchain and using cmake,
I use the latest release from here as an hpp include (1.2.0)
My project c++ v is set to c++20 but i also tried c++ 17, it didn't change anything, snippet wise i'm not really sure what it would change as i get this error with the simple fact to include the hpp no matter the rest of the code even when not actually using it
from tileson.
Compiling with C++17 or higher should be fine, as long as your compiler supports it 🙂
This may sound like a stupid question, but are you able to compile and run a bare-bone program using just a simple program like this?
#include <string_view>
#include <iostream>
int main(int argc, char **argv)
{
std::string_view str{"Just a test"};
std::cout << "Test: " << str;
return 0;
}
For reference, you could use this simple CMakeLists.txt
for the above example:
cmake_minimum_required(VERSION 3.11)
project(Dummy)
set(CMAKE_CXX_STANDARD 17)
set(SOURCE_FILES main.cpp )
add_executable(Dummy ${SOURCE_FILES} )
Also, keep in mind the version of your MinGW-w64 toolchain must support the filesystem
and string_view
features of C++17.
Unfortunately Tileson has not been tested with MinGW, but it has been well tested using MSVC on Windows, GCC og Linux, and Clang on OSX. I also remember I've had some issues with MinGW in the past, experimenting with std::filesystem
stuff, so I'm suspecting that your current MinGW toolchain might not support string_view
(or maybe C++17 features in general).
Could you test the above code on your system using MinGW and report back the result? 🙂
Also: Which version of MinGW-w64 are you using?
from tileson.
Closing issue due to inactivity. Also tested newest release of Tileson with the supported compilers for all platforms with no issue, so assuming this is a MinGW issue with lack of support for needed C++17 features.
from tileson.
Related Issues (20)
- Parsing template objects and overriding properties HOT 2
- Can't retrieve tile data from a layer in a Tile Group Layer HOT 4
- Attributes of classes set as properties return zero where overridden HOT 1
- Tileset::getImagePath() doesn't return a valid path
- Tile::getDrawingRect() size is the map grid size, not the tile grid size
- Animated tile IDs, and nullptr returned by tileset->getTile(tileId), local vs global HOT 2
- Expected values removed from tiledmap data format version 1.10.2 HOT 12
- Local ID assigned global ID in flipped Tile constructor HOT 1
- Tiles rotated to 90 and 270 degrees display incorrectly HOT 1
- Const correctness of Tileson HOT 1
- Full image filepath for an embedded tileset is incorrect
- Revise Rotation, Scale, and Flip Transformations in SfmlDemoManager::drawObjectLayer
- Possible to modify tile data in place? HOT 3
- Make sure TiledEnum values can be properly read from Objects and Tiles
- Fix compression errors occuring on Clang 11 and newer HOT 1
- Object parse always assumes the current project is nullptr HOT 1
- Thanks for this project HOT 1
- Avoid including external_libs folder for library
- Isometric support? HOT 1
- Issues opening maps HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tileson.