diff options
author | Lars Knoll <lars.knoll@digia.com> | 2012-10-19 23:10:42 +0200 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@digia.com> | 2012-10-20 12:33:20 +0200 |
commit | 04b12a90b8ac5c44097bbf60a730f36b58578086 (patch) | |
tree | df8d21d87c75548aaa07d66b1fe3d2333c6387c4 /qv4isel_masm.cpp | |
parent | acfb62cc2e6a85a5546dec3f586cf0cdf3deb7ca (diff) |
Implement regexp support
Change-Id: I86c9bbe69c9ba4ae9d300b62e7d16b372f3478ea
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'qv4isel_masm.cpp')
-rw-r--r-- | qv4isel_masm.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/qv4isel_masm.cpp b/qv4isel_masm.cpp index 249817ea6e..9d01a8a9d2 100644 --- a/qv4isel_masm.cpp +++ b/qv4isel_masm.cpp @@ -376,6 +376,11 @@ void InstructionSelection::visitMove(IR::Move *s) Value v = Value::fromString(_engine->newString(*str->value)); storeValue(v, dest); return; + } else if (IR::RegExp *re = s->source->asRegExp()) { + Address dest = loadTempAddress(Gpr0, t); + Value v = Value::fromObject(_engine->newRegExpObject(*re->value, re->flags)); + storeValue(v, dest); + return; } else if (IR::Closure *clos = s->source->asClosure()) { generateFunctionCall(t, __qmljs_init_closure, TrustedImmPtr(clos->value), ContextRegister); return; |