ref: 9262fefd07ede247f5fbc226857875cecb69a44a
parent: 638d02404074f27af64f2cbf196fbac51cf81099
author: ISSOtm <eldredhabert0@gmail.com>
date: Fri Mar 4 20:27:05 EST 2022
Fix compiling with Clang Force version.c to be compiled as C++ (bodge, will need a proper fix for `version.c`) Remove user-defined `ProtoPalette` assignment operator (same as default, anyway)
--- a/Makefile
+++ b/Makefile
@@ -124,7 +124,7 @@
$Q${CC} ${REALLDFLAGS} -o $@ ${rgbfix_obj} ${REALCFLAGS} src/version.c
rgbgfx: ${rgbgfx_obj}
- $Q${CXX} ${REALLDFLAGS} ${PNGLDFLAGS} -o $@ ${rgbgfx_obj} ${REALCXXFLAGS} src/version.c ${PNGLDLIBS}
+ $Q${CXX} ${REALLDFLAGS} ${PNGLDFLAGS} -o $@ ${rgbgfx_obj} ${REALCXXFLAGS} -x c++ src/version.c ${PNGLDLIBS}
# Rules to process files
--- a/include/gfx/proto_palette.hpp
+++ b/include/gfx/proto_palette.hpp
@@ -33,8 +33,6 @@
};
ComparisonResult compare(ProtoPalette const &other) const;
- ProtoPalette &operator=(ProtoPalette const &other);
-
size_t size() const;
decltype(_colorIndices)::const_iterator begin() const;
--- a/src/gfx/proto_palette.cpp
+++ b/src/gfx/proto_palette.cpp
@@ -62,11 +62,6 @@
return theyBigger ? THEY_BIGGER : (weBigger ? WE_BIGGER : NEITHER);
}
-ProtoPalette &ProtoPalette::operator=(ProtoPalette const &other) {
- _colorIndices = other._colorIndices;
- return *this;
-}
-
size_t ProtoPalette::size() const {
return std::distance(begin(), end());
}