OLD | NEW |
1 // Copyright 2006-2009 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2009 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 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
49 #elif V8_TARGET_ARCH_X64 | 49 #elif V8_TARGET_ARCH_X64 |
50 #include "x64/macro-assembler-x64.h" | 50 #include "x64/macro-assembler-x64.h" |
51 #include "x64/regexp-macro-assembler-x64.h" | 51 #include "x64/regexp-macro-assembler-x64.h" |
52 #elif V8_TARGET_ARCH_ARM | 52 #elif V8_TARGET_ARCH_ARM |
53 #include "arm/regexp-macro-assembler-arm.h" | 53 #include "arm/regexp-macro-assembler-arm.h" |
54 #endif | 54 #endif |
55 | 55 |
56 #include "interpreter-irregexp.h" | 56 #include "interpreter-irregexp.h" |
57 | 57 |
58 | 58 |
59 namespace v8 { namespace internal { | 59 namespace v8 { |
| 60 namespace internal { |
60 | 61 |
61 | 62 |
62 Handle<Object> RegExpImpl::CreateRegExpLiteral(Handle<JSFunction> constructor, | 63 Handle<Object> RegExpImpl::CreateRegExpLiteral(Handle<JSFunction> constructor, |
63 Handle<String> pattern, | 64 Handle<String> pattern, |
64 Handle<String> flags, | 65 Handle<String> flags, |
65 bool* has_pending_exception) { | 66 bool* has_pending_exception) { |
66 // Ensure that the constructor function has been loaded. | 67 // Ensure that the constructor function has been loaded. |
67 if (!constructor->IsLoaded()) { | 68 if (!constructor->IsLoaded()) { |
68 LoadLazy(constructor, has_pending_exception); | 69 LoadLazy(constructor, has_pending_exception); |
69 if (*has_pending_exception) return Handle<Object>(); | 70 if (*has_pending_exception) return Handle<Object>(); |
(...skipping 4392 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4462 EmbeddedVector<byte, 1024> codes; | 4463 EmbeddedVector<byte, 1024> codes; |
4463 RegExpMacroAssemblerIrregexp macro_assembler(codes); | 4464 RegExpMacroAssemblerIrregexp macro_assembler(codes); |
4464 return compiler.Assemble(¯o_assembler, | 4465 return compiler.Assemble(¯o_assembler, |
4465 node, | 4466 node, |
4466 data->capture_count, | 4467 data->capture_count, |
4467 pattern); | 4468 pattern); |
4468 } | 4469 } |
4469 | 4470 |
4470 | 4471 |
4471 }} // namespace v8::internal | 4472 }} // namespace v8::internal |
OLD | NEW |