Commit 2fe435b
committed
remake vector_set from inheritance from underlying container to aggregation
this makes it safer, as it disallows some of changes that could violate sorted contract
it also saves at least sizeof(void*) on most common comparators (due to empty struct optimization in compressed_pair)
con: it explicitly requires container class to follow vector API (almost all functions are exposed in vector_set)
to consider: remove non const front(), back(), at(), [] access.
Those are not safe either, left them only for compatibility1 parent 6a94249 commit 2fe435b
1 file changed
+112
-81
lines changed
0 commit comments