| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "core/css/parser/CSSTokenizerInputStream.h" | 5 #include "core/css/parser/CSSTokenizerInputStream.h" |
| 6 | 6 |
| 7 #include "core/html/parser/InputStreamPreprocessor.h" | 7 #include "core/html/parser/InputStreamPreprocessor.h" |
| 8 #include "wtf/text/StringToNumber.h" |
| 8 | 9 |
| 9 namespace blink { | 10 namespace blink { |
| 10 | 11 |
| 11 CSSTokenizerInputStream::CSSTokenizerInputStream(String input) | 12 CSSTokenizerInputStream::CSSTokenizerInputStream(String input) |
| 12 : m_offset(0) | 13 : m_offset(0) |
| 13 , m_stringLength(input.length()) | 14 , m_stringLength(input.length()) |
| 14 , m_string(input.impl()) | 15 , m_string(input.impl()) |
| 15 { | 16 { |
| 16 } | 17 } |
| 17 | 18 |
| (...skipping 26 matching lines...) Expand all Loading... |
| 44 return isResultOK ? result : 0.0; | 45 return isResultOK ? result : 0.0; |
| 45 } | 46 } |
| 46 | 47 |
| 47 StringView CSSTokenizerInputStream::rangeAt(unsigned start, unsigned length) con
st | 48 StringView CSSTokenizerInputStream::rangeAt(unsigned start, unsigned length) con
st |
| 48 { | 49 { |
| 49 ASSERT(start + length <= m_stringLength); | 50 ASSERT(start + length <= m_stringLength); |
| 50 return StringView(m_string.get(), start, length); | 51 return StringView(m_string.get(), start, length); |
| 51 } | 52 } |
| 52 | 53 |
| 53 } // namespace blink | 54 } // namespace blink |
| OLD | NEW |