Index: src/dateparser-inl.h |
diff --git a/src/dateparser-inl.h b/src/dateparser-inl.h |
index 8973aa0d4ff286b20a8b3c4af57981d0bfa19d69..e0b5cf9c55a4308ea073c74791b091a6db30d3fd 100644 |
--- a/src/dateparser-inl.h |
+++ b/src/dateparser-inl.h |
@@ -7,6 +7,7 @@ |
#include "src/char-predicates-inl.h" |
#include "src/dateparser.h" |
+#include "src/unicode-cache-inl.h" |
namespace v8 { |
namespace internal { |
@@ -193,6 +194,29 @@ DateParser::DateToken DateParser::DateStringTokenizer<CharType>::Scan() { |
template <typename Char> |
+bool DateParser::InputReader<Char>::SkipWhiteSpace() { |
+ if (unicode_cache_->IsWhiteSpaceOrLineTerminator(ch_)) { |
+ Next(); |
+ return true; |
+ } |
+ return false; |
+} |
+ |
+ |
+template <typename Char> |
+bool DateParser::InputReader<Char>::SkipParentheses() { |
+ if (ch_ != '(') return false; |
+ int balance = 0; |
+ do { |
+ if (ch_ == ')') --balance; |
+ else if (ch_ == '(') ++balance; |
+ Next(); |
+ } while (balance > 0 && ch_); |
+ return true; |
+} |
+ |
+ |
+template <typename Char> |
DateParser::DateToken DateParser::ParseES6DateTime( |
DateStringTokenizer<Char>* scanner, |
DayComposer* day, |