Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. | 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. |
| 3 * Copyright (C) 2010 Google, Inc. All Rights Reserved. | 3 * Copyright (C) 2010 Google, Inc. All Rights Reserved. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
| 7 * are met: | 7 * are met: |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 259 Vector<LChar, 32> m_temporaryBuffer; | 259 Vector<LChar, 32> m_temporaryBuffer; |
| 260 | 260 |
| 261 // We occationally want to emit both a character token and an end tag | 261 // We occationally want to emit both a character token and an end tag |
| 262 // token (e.g., when lexing script). We buffer the name of the end tag | 262 // token (e.g., when lexing script). We buffer the name of the end tag |
| 263 // token here so we remember it next time we re-enter the tokenizer. | 263 // token here so we remember it next time we re-enter the tokenizer. |
| 264 Vector<LChar, 32> m_bufferedEndTagName; | 264 Vector<LChar, 32> m_bufferedEndTagName; |
| 265 | 265 |
| 266 HTMLParserOptions m_options; | 266 HTMLParserOptions m_options; |
| 267 }; | 267 }; |
| 268 | 268 |
| 269 inline bool isEndTagBufferingState(HTMLTokenizer::State state) { | |
|
Charlie Harrison
2017/03/07 18:37:49
Can you just make this an inline static member fun
wanchang
2017/03/08 00:35:35
Done.
| |
| 270 switch (state) { | |
| 271 case HTMLTokenizer::RCDATAEndTagOpenState: | |
| 272 case HTMLTokenizer::RCDATAEndTagNameState: | |
| 273 case HTMLTokenizer::RAWTEXTEndTagOpenState: | |
| 274 case HTMLTokenizer::RAWTEXTEndTagNameState: | |
| 275 case HTMLTokenizer::ScriptDataEndTagOpenState: | |
| 276 case HTMLTokenizer::ScriptDataEndTagNameState: | |
| 277 case HTMLTokenizer::ScriptDataEscapedEndTagOpenState: | |
| 278 case HTMLTokenizer::ScriptDataEscapedEndTagNameState: | |
| 279 return true; | |
| 280 default: | |
| 281 return false; | |
| 282 } | |
| 283 } | |
| 284 | |
| 269 } // namespace blink | 285 } // namespace blink |
| 270 | 286 |
| 271 #endif | 287 #endif |
| OLD | NEW |