| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 875 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 886 #undef MAKE_TYPE_CASE | 886 #undef MAKE_TYPE_CASE |
| 887 | 887 |
| 888 #define MAKE_TYPE_CASE(Name) \ | 888 #define MAKE_TYPE_CASE(Name) \ |
| 889 RegExp##Name* RegExp##Name::As##Name() { \ | 889 RegExp##Name* RegExp##Name::As##Name() { \ |
| 890 return this; \ | 890 return this; \ |
| 891 } \ | 891 } \ |
| 892 bool RegExp##Name::Is##Name() { return true; } | 892 bool RegExp##Name::Is##Name() { return true; } |
| 893 FOR_EACH_REG_EXP_TREE_TYPE(MAKE_TYPE_CASE) | 893 FOR_EACH_REG_EXP_TREE_TYPE(MAKE_TYPE_CASE) |
| 894 #undef MAKE_TYPE_CASE | 894 #undef MAKE_TYPE_CASE |
| 895 | 895 |
| 896 RegExpEmpty RegExpEmpty::kInstance; | |
| 897 | |
| 898 | 896 |
| 899 static Interval ListCaptureRegisters(ZoneList<RegExpTree*>* children) { | 897 static Interval ListCaptureRegisters(ZoneList<RegExpTree*>* children) { |
| 900 Interval result = Interval::Empty(); | 898 Interval result = Interval::Empty(); |
| 901 for (int i = 0; i < children->length(); i++) | 899 for (int i = 0; i < children->length(); i++) |
| 902 result = result.Union(children->at(i)->CaptureRegisters()); | 900 result = result.Union(children->at(i)->CaptureRegisters()); |
| 903 return result; | 901 return result; |
| 904 } | 902 } |
| 905 | 903 |
| 906 | 904 |
| 907 Interval RegExpAlternative::CaptureRegisters() { | 905 Interval RegExpAlternative::CaptureRegisters() { |
| (...skipping 298 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1206 int pos) | 1204 int pos) |
| 1207 : label_(label), | 1205 : label_(label), |
| 1208 statements_(statements), | 1206 statements_(statements), |
| 1209 position_(pos), | 1207 position_(pos), |
| 1210 compare_type_(NONE), | 1208 compare_type_(NONE), |
| 1211 compare_id_(AstNode::GetNextId(isolate)), | 1209 compare_id_(AstNode::GetNextId(isolate)), |
| 1212 entry_id_(AstNode::GetNextId(isolate)) { | 1210 entry_id_(AstNode::GetNextId(isolate)) { |
| 1213 } | 1211 } |
| 1214 | 1212 |
| 1215 } } // namespace v8::internal | 1213 } } // namespace v8::internal |
| OLD | NEW |