jscript: Added RegExp.multiline getter implementation.

Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Jacek Caban 2016-05-25 14:07:56 +02:00 committed by Alexandre Julliard
parent 2db1666096
commit 81cb13af7a
2 changed files with 9 additions and 2 deletions

View File

@ -290,8 +290,10 @@ static HRESULT RegExp_set_ignoreCase(script_ctx_t *ctx, jsdisp_t *jsthis, jsval_
static HRESULT RegExp_get_multiline(script_ctx_t *ctx, jsdisp_t *jsthis, jsval_t *r)
{
FIXME("\n");
return E_NOTIMPL;
TRACE("\n");
*r = jsval_bool(!!(regexp_from_jsdisp(jsthis)->jsregexp->flags & REG_MULTILINE));
return S_OK;
}
static HRESULT RegExp_set_multiline(script_ctx_t *ctx, jsdisp_t *jsthis, jsval_t value)

View File

@ -662,9 +662,14 @@ ok(/abc/.toString(1, false, "3") === "/abc/", "/abc/.toString(1, false, \"3\") =
re = /x/;
ok(re.ignoreCase === false, "re.ignoreCase = " + re.ignoreCase);
ok(re.multiline === false, "re.multiline = " + re.multiline);
re = /x/i;
ok(re.ignoreCase === true, "re.ignoreCase = " + re.ignoreCase);
ok(re.multiline === false, "re.multiline = " + re.multiline);
re = new RegExp("xxx", "gi");
ok(re.ignoreCase === true, "re.ignoreCase = " + re.ignoreCase);
ok(re.multiline === false, "re.multiline = " + re.multiline);
re = /x/mg;
ok(re.multiline === true, "re.multiline = " + re.multiline);
reportSuccess();