Changeset 282469 in webkit
- Timestamp:
- Sep 15, 2021, 1:18:25 PM (5 years ago)
- Location:
- trunk/Source/JavaScriptCore
- Files:
-
- 2 edited
-
ChangeLog (modified) (1 diff)
-
runtime/ISO8601.cpp (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ChangeLog
r282468 r282469 1 2021-09-15 Michael Catanzaro <mcatanzaro@gnome.org> 2 3 Avoid GCC warnings introduced in r282125 4 https://bugs.webkit.org/show_bug.cgi?id=230154 5 6 Reviewed by Fujii Hironori. 7 8 Yusuke suggested casting to UChar to avoid -Wswitch-out-of-range. This works! 9 10 Also, avoid -Wredundant-move by removing one unnecessary WTFMove. 11 12 * runtime/ISO8601.cpp: 13 (JSC::ISO8601::parseTimeZoneBracketedAnnotation): 14 (JSC::ISO8601::canBeTimeZone): 15 (JSC::ISO8601::parseTimeZone): 16 1 17 2021-09-15 Yusuke Suzuki <ysuzuki@apple.com> 2 18 -
trunk/Source/JavaScriptCore/runtime/ISO8601.cpp
r282125 r282469 449 449 buffer.advance(); 450 450 451 switch ( *buffer) {451 switch (static_cast<UChar>(*buffer)) { 452 452 case '+': 453 453 case '-': … … 577 577 return std::nullopt; 578 578 buffer.advance(); 579 return WTFMove(result);579 return result; 580 580 } 581 581 } … … 585 585 static bool canBeTimeZone(const StringParsingBuffer<CharacterType>& buffer, CharacterType character) 586 586 { 587 switch ( character) {587 switch (static_cast<UChar>(character)) { 588 588 // UTCDesignator 589 589 // https://tc39.es/proposal-temporal/#prod-UTCDesignator … … 616 616 if (buffer.atEnd()) 617 617 return std::nullopt; 618 switch ( *buffer) {618 switch (static_cast<UChar>(*buffer)) { 619 619 // UTCDesignator 620 620 // https://tc39.es/proposal-temporal/#prod-UTCDesignator
Note:
See TracChangeset
for help on using the changeset viewer.