1
0
Fork 0
mirror of https://github.com/sockspls/badfish synced 2025-04-30 08:43:09 +00:00

Make operator<< to return void

This should help preventing misuse.

No functional change.
This commit is contained in:
Marco Costalba 2014-04-03 10:34:25 +02:00
parent 0ba814b3ca
commit c15b132f03
2 changed files with 2 additions and 3 deletions

View file

@ -139,13 +139,12 @@ Option::operator std::string() const {
/// operator<<() inits options and assigns idx in the correct printing order
Option& Option::operator<<(const Option& o) {
void Option::operator<<(const Option& o) {
static size_t index = 0;
*this = o;
idx = index++;
return *this;
}

View file

@ -47,7 +47,7 @@ public:
Option(int v, int min, int max, OnChange = NULL);
Option& operator=(const std::string& v);
Option& operator<<(const Option& o);
void operator<<(const Option& o);
operator int() const;
operator std::string() const;