John Wellbelove
John Wellbelove
What is the definition of `ETL_HAS_INITIALIZER_LIST` for your project. Is it set to `0` or `1`? (This is not set by you; it is deduced in `platform.h`)
Note: The ETL's version of `std::initialiser_list` can only be used when _not_ using the STL `anywhere` in your project. `initializer_list` is special in that it _must_ exist in the `std`...
I can get an example to work using this code. **CMakeLists.txt** ``` cmake_minimum_required(VERSION 3.5.0) project(etl_initializer_list_unit_tests) add_definitions(-DETL_DEBUG) add_definitions(-DETL_NO_STL) add_definitions(-DETL_FORCE_ETL_INITIALIZER_LIST) include_directories(${PROJECT_SOURCE_DIR}/../../include) set(TEST_SOURCE_FILES test_initializer_list.cpp ) add_executable(etl_tests ${TEST_SOURCE_FILES} ) target_include_directories(etl_tests PUBLIC ${CMAKE_CURRENT_LIST_DIR} ) #...
Do you have `ETL_NO_STL` defined?
For `ETL_HAS_INITIALIZER_LIST` to be defined as `0` there are only two conditions where that is true. Are you able to tell which `#if/#else` it is selecting? ``` //************************************* // Determine...
Try changing `ETL_COMPILER_GENERIC` to `ETL_COMPILER_GCC` or let `platform.h` deduce it for itself. `platform.h` can deduce many of the configuration settings nowadays, specifically compiler type and C++ level support.
I'm going to be out for the afternoon, but I'll be back about 7pm UK time (UTC+1) to answer any more questions.
I'm closing this as there have been no updates.
I'll certainly put it on my ToDo list (which is a bit long at the moment!)
It may be possible to fork the library and modify it (where possible) to use the ETL, and include it in the ETL.