| OLD | NEW |
| 1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 107 {% elif type == 'store_harmony_token_and_goto' %} | 107 {% elif type == 'store_harmony_token_and_goto' %} |
| 108 if (harmony_{{value[0]}}_) { | 108 if (harmony_{{value[0]}}_) { |
| 109 stored_token = Token::{{value[1]}}; | 109 stored_token = Token::{{value[1]}}; |
| 110 } else { | 110 } else { |
| 111 stored_token = Token::{{value[2]}}; | 111 stored_token = Token::{{value[2]}}; |
| 112 } | 112 } |
| 113 goto code_after_entry_{{value[3]}}; | 113 goto code_after_entry_{{value[3]}}; |
| 114 {% elif type == 'set_marker' %} | 114 {% elif type == 'set_marker' %} |
| 115 marker_ = cursor_ - {{value}}; | 115 marker_ = cursor_ - {{value}}; |
| 116 {% elif type == 'set_has_escapes' %} | 116 {% elif type == 'set_has_escapes' %} |
| 117 next_.has_escapes = true; | 117 next_.has_escapes = true; |
| 118 {% elif type == 'octal_number' %} |
| 119 last_octal_end_ = cursor_; |
| 120 DO_TOKEN(Token::NUMBER); |
| 121 {% elif type == 'octal_inside_string' %} |
| 122 last_octal_end_ = cursor_; |
| 123 next_.has_escapes = true; |
| 118 {% else %} | 124 {% else %} |
| 119 uncompilable code for {{type}} | 125 uncompilable code for {{type}} |
| 120 {% endif -%} | 126 {% endif -%} |
| 121 {%- endmacro -%} | 127 {%- endmacro -%} |
| 122 | 128 |
| 123 | 129 |
| 124 {%- macro long_char_check() -%} | 130 {%- macro long_char_check() -%} |
| 125 {%- if encoding == 'utf16'-%} | 131 {%- if encoding == 'utf16'-%} |
| 126 primary_char > {{upper_bound}} | 132 primary_char > {{upper_bound}} |
| 127 {%- elif encoding == 'utf8'-%} | 133 {%- elif encoding == 'utf8'-%} |
| (...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 314 FORWARD(); | 320 FORWARD(); |
| 315 goto code_start; | 321 goto code_start; |
| 316 | 322 |
| 317 fell_through: | 323 fell_through: |
| 318 ((void(*)())0)(); // crash | 324 ((void(*)())0)(); // crash |
| 319 // force use of stored_token | 325 // force use of stored_token |
| 320 stored_token = Token::ILLEGAL; | 326 stored_token = Token::ILLEGAL; |
| 321 } | 327 } |
| 322 } } | 328 } } |
| 323 | 329 |
| OLD | NEW |