main
Last change
on this file since 79a0317 was 79a0317, checked in by stefan toskovski <stefantoska84@…>, 3 days ago |
F4 Finalna Verzija
|
-
Property mode
set to
100644
|
File size:
451 bytes
|
Line | |
---|
1 | 'use strict';
|
---|
2 | var isObject = require('../internals/is-object');
|
---|
3 | var classof = require('../internals/classof-raw');
|
---|
4 | var wellKnownSymbol = require('../internals/well-known-symbol');
|
---|
5 |
|
---|
6 | var MATCH = wellKnownSymbol('match');
|
---|
7 |
|
---|
8 | // `IsRegExp` abstract operation
|
---|
9 | // https://tc39.es/ecma262/#sec-isregexp
|
---|
10 | module.exports = function (it) {
|
---|
11 | var isRegExp;
|
---|
12 | return isObject(it) && ((isRegExp = it[MATCH]) !== undefined ? !!isRegExp : classof(it) === 'RegExp');
|
---|
13 | };
|
---|
Note:
See
TracBrowser
for help on using the repository browser.