FastLED 3.10.8
Loading...
Searching...
No Matches

◆ operator>>() [3/10]

istream_real & fl::istream_real::operator>> ( fl::i16 & n)

Definition at line 263 of file istream.cpp.hpp.

263 {
264 string token;
265 if (readToken(token)) {
266 fl::i32 temp;
267 if (parse_i32(token.c_str(), temp) && temp >= -32768 && temp <= 32767) {
268 n = static_cast<fl::i16>(temp);
269 } else {
270 mFailed = true;
271 }
272 } else {
273 mFailed = true;
274 }
275 return *this;
276}
bool readToken(string &token) FL_NO_EXCEPT
bool parse_i32(const char *str, fl::i32 &result) FL_NO_EXCEPT

References istream_real(), fl::basic_string::c_str(), fl::FL_NO_EXCEPT, mFailed, and readToken().

+ Here is the call graph for this function: