46 Commits

Author SHA1 Message Date
John Wellbelove
aeb8e4f734 Formatted source files 2026-04-02 14:11:45 +01:00
Roland Reichwein
b83cef5668
Fix compilation with -Wsign-conversion (#1367)
* Fix compilation with -Wsign-conversion

For tests with GCC and Clang

Fixes https://github.com/ETLCPP/etl/issues/632

* Fix support of negative Id in type_lookup.h: type_from_id

* Fix element access arithmetic in atomic_gcc_sync.h fetch_add/fetch_sub

* Fix rounded_integral_division.h: divide_round_half_odd(): direction is always 1
2026-03-28 11:15:56 +00:00
Roland Reichwein
add42b6c87
Mark uninitialized use from std library (#1349)
* Print test names at test time (#1343)

* Mark uninitialized use from std library

Similar to other cases, adds compiler pragmas against warnings
caused by std library in optimized builds of tests

---------

Co-authored-by: John Wellbelove <jwellbelove@users.noreply.github.com>
2026-03-26 08:29:05 +00:00
Bo Rydberg
a843650649 Remove some UB in test_vector_non_trivial.cpp (#1268)
Some of the tests' UB are detectable by Gcc15 and thus give a compile error due to warnings-as-error flag.

Co-authored-by: John Wellbelove <jwellbelove@users.noreply.github.com>
2026-02-03 08:59:49 +00:00
mike919192
3206ac9feb
ivector swap (#1256)
* Etl vector swap implementation

* Implement swap function overload

* Fix nitpicks

* Add size check

* Remove unnessecary etl swap overloads

* Use swap_range and move range

---------

Co-authored-by: John Wellbelove <jwellbelove@users.noreply.github.com>
2026-01-11 18:05:21 +01:00
John Wellbelove
d884719098 Fixed all 'extra semicolon' warnings 2025-12-16 09:15:26 +00:00
mike919192
2bf512dd42 Vector checks (#1193)
* Add checks to vector and fix test failures

* Add tests to vector

* Add tests to external buffer and non trivial

* All tests should be implemented

* Add checks to vector_pointer and vector_pointer_ext

* Get bad iterators from a second vector
2025-10-03 10:49:23 +01:00
John Wellbelove
77513730e0 Fixed shadow warnings in all files
#823 Multiple variable shadowing warnings in private/bitset_new.h
2024-01-25 14:22:26 +00:00
John Wellbelove
61da85fa77 Removed float-equal warnings
Added functions is_nan, is_infinity, is_zero & is_exactly_equal
Fixed array-bounds warnings for GCC and -O2 optimisation
2023-11-21 15:13:24 +00:00
John Wellbelove
53084ae932 Added c++03 zero parameter emplace member functions 2023-08-25 02:05:46 +01:00
John Wellbelove
bcad53ebb2 Array bounds and maybe-uninitialized warning fixes
Array bounds and maybe-uninitialized warning fixes

Added GCC/clang diagnostic disable for array bounds

Fixed false positive array bounds failure in unit tests

Added -01 & -03 quick tests

Fixed constexpr for exception constructor

Made virtual functions protected

Updated project files

Updated generated file

Updated versions and release notes
2023-03-02 13:15:42 +00:00
John Wellbelove
8b0c2325af Improved emplace testing 2023-01-07 19:02:56 +00:00
John Wellbelove
044fc1b2ff Improved emplace testing
Changed unit test macro CHECK_FALSE_EQUAL to CHECK_NOT_EQUAL
2023-01-07 18:46:59 +00:00
John Wellbelove
a398207e3d emplace_front, emplace_back updates 2023-01-07 15:20:25 +00:00
John Wellbelove
cd18cc6af0 Eradicated all GCC and clang warnings 2022-07-27 10:42:03 +01:00
John Wellbelove
baa47d1c33 Updated copyright notice 2022-06-10 21:45:37 +01:00
John Wellbelove
740e490aed Tested ETL traits code. 2022-03-11 20:28:26 +00:00
John Wellbelove
d2ba5e9956 Multiple code changes, delegates & timers 2021-12-14 10:52:49 +00:00
John Wellbelove
343dabe7e2 Fixes for < GCC 8 2021-11-21 17:29:56 +00:00
John Wellbelove
a3eda2c2e1 Added 'make' functions to construct containers
Added tests for 'make' and 'template deduction'
2021-11-08 19:05:59 +00:00
CanastraRF
7c0f169b66
literal with suffix (#416) 2021-08-23 11:01:18 +01:00
John Wellbelove
b779696eb9 Refactoring of type traits for GCC compatibility 2021-08-04 18:47:42 +01:00
John Wellbelove
dbfa71944f Abstracted unit test framework header 2021-03-05 13:52:34 +00:00
John Wellbelove
bc671299b0 Added missing emplace functions from vector-of-pointers specialisation. 2020-10-21 13:22:34 +01:00
John Wellbelove
18d8236f91 Conditionally disable template deduction guide tests 2020-09-29 11:23:10 +01:00
John Wellbelove
509089c0e2 Added template deduction guides 2020-09-28 13:14:12 +01:00
John Wellbelove
f4d9476900 Simplified conditional macros 2020-05-09 19:40:44 +01:00
John Wellbelove
e323f2267f Changed http://www.etlcpp.com to https://www.etlcpp.com 2020-05-01 10:22:36 +01:00
John Wellbelove
af5a760d5d Merge remote-tracking branch 'origin/development' 2020-01-14 11:57:04 +00:00
John Wellbelove
83347ccfdd Work in progress 2020-01-09 11:15:50 +00:00
John Wellbelove
5803d928a1 Merge remote-tracking branch 'origin/feature/no_stl_unit_tests' into development
# Conflicts:
#	include/etl/stl/alternate/algorithm.h
#	include/etl/stl/alternate/iterator.h
#	include/etl/version.h
#	library.json
#	library.properties
#	support/Release notes.txt
#	test/test_no_stl_algorithm.cpp
#	test/test_no_stl_iterator.cpp
#	test/vs2017/etl.vcxproj
2019-12-01 18:21:10 +00:00
John Wellbelove
f0fcb78e24 Enabled emplace functions for C++03 2019-02-24 10:04:13 +01:00
John Wellbelove
6b165aee54 Added interface move assignment. 2019-01-01 14:02:43 +00:00
John Wellbelove
dc6f6796f6 Added move constructor & move assignment 2018-12-30 11:16:33 +00:00
John Wellbelove
9266920e2a Added rvalue reference push_back & insert. 2018-12-29 15:36:08 +00:00
John Wellbelove
6b29f4eaca Added C++03/C++11 emplace for deque, priority_queue, queues, stack, variant & vector. 2018-12-09 12:11:54 +00:00
Jonathan Pan
8e9eaf4f7c [#101] Adding non-const emplace overloads for vector (#102) 2018-11-04 11:51:55 +00:00
John Wellbelove
02987191a5 Removed push(void) push_back(void) and push_front(void) function for containers. 2018-09-15 08:58:08 +01:00
John Wellbelove
bd008350a2 Merge remote-tracking branch 'origin/feature/changed_include_paths' into development
# Conflicts:
#	include/etl/version.h
2018-07-28 21:55:27 +01:00
John Wellbelove
ab65a5abaa Added std::initializer_list constructors when ETL_CPP11_SUPPORTED is defined as 1 2018-03-25 14:34:28 +01:00
John Wellbelove
135506b534 Re-written to avoid 'undefined behavior' by allowing containers to be polymorphic or not base on a compile time macro. 2018-02-01 10:15:51 +00:00
John Wellbelove
eb222f54bb Containers are now deleteable through a pointer to their 'ixxxx' class. 2018-01-30 08:47:49 +00:00
John Wellbelove
044535d6d6 Merge branch 'Emplace' into development
# Conflicts:
#	src/CreateFSM.bat
#	src/CreateMessageRouter.bat
#	src/flat_map.h
#	src/fsm.h
#	src/fsm_generator.h
#	src/message_router.h
#	src/message_router_generator.h
#	src/queue.h
#	src/vector.h
#	test/codeblocks/ETL.depend
#	test/codeblocks/ETL.layout
#	test/data.h
#	test/test_fsm.cpp
#	test/test_message_router.cpp
#	test/vs2017/etl.vcxproj
#	test/vs2017/etl.vcxproj.filters
#	test/vs2017/random.csv
2017-07-26 10:06:23 +01:00
John Wellbelove
c981bd0c96 Added emplace functions supporting up to four parameters to the following containers.
forward_list
list
vector
queue
priority_queue
stack

# Conflicts:
#	src/vector.h
#	test/data.h
#	test/vs2017/random.csv
2017-07-21 11:59:40 +01:00
John Wellbelove
26b7326d72 Updated Code::Blocks project.
Changed test project include paths to use unittest++ as sub-module.
2017-05-08 20:48:22 +01:00
John Wellbelove
b2ba6badf7 Vector tests using non-trivial types. 2017-02-25 20:30:07 +00:00