Edit File by line
/home/barbar84/www/wp-inclu.../js/codemirr...
File: csslint.js
return typeMap[c];
[7000] Fix | Delete
};
[7001] Fix | Delete
[7002] Fix | Delete
return tokenData;
[7003] Fix | Delete
};
[7004] Fix | Delete
[7005] Fix | Delete
TokenStreamBase.prototype = {
[7006] Fix | Delete
[7007] Fix | Delete
//restore constructor
[7008] Fix | Delete
constructor: TokenStreamBase,
[7009] Fix | Delete
[7010] Fix | Delete
//-------------------------------------------------------------------------
[7011] Fix | Delete
// Matching methods
[7012] Fix | Delete
//-------------------------------------------------------------------------
[7013] Fix | Delete
[7014] Fix | Delete
/**
[7015] Fix | Delete
* Determines if the next token matches the given token type.
[7016] Fix | Delete
* If so, that token is consumed; if not, the token is placed
[7017] Fix | Delete
* back onto the token stream. You can pass in any number of
[7018] Fix | Delete
* token types and this will return true if any of the token
[7019] Fix | Delete
* types is found.
[7020] Fix | Delete
* @param {int|int[]} tokenTypes Either a single token type or an array of
[7021] Fix | Delete
* token types that the next token might be. If an array is passed,
[7022] Fix | Delete
* it's assumed that the token can be any of these.
[7023] Fix | Delete
* @param {variant} channel (Optional) The channel to read from. If not
[7024] Fix | Delete
* provided, reads from the default (unnamed) channel.
[7025] Fix | Delete
* @return {Boolean} True if the token type matches, false if not.
[7026] Fix | Delete
* @method match
[7027] Fix | Delete
*/
[7028] Fix | Delete
match: function(tokenTypes, channel) {
[7029] Fix | Delete
[7030] Fix | Delete
//always convert to an array, makes things easier
[7031] Fix | Delete
if (!(tokenTypes instanceof Array)) {
[7032] Fix | Delete
tokenTypes = [tokenTypes];
[7033] Fix | Delete
}
[7034] Fix | Delete
[7035] Fix | Delete
var tt = this.get(channel),
[7036] Fix | Delete
i = 0,
[7037] Fix | Delete
len = tokenTypes.length;
[7038] Fix | Delete
[7039] Fix | Delete
while (i < len) {
[7040] Fix | Delete
if (tt === tokenTypes[i++]) {
[7041] Fix | Delete
return true;
[7042] Fix | Delete
}
[7043] Fix | Delete
}
[7044] Fix | Delete
[7045] Fix | Delete
//no match found, put the token back
[7046] Fix | Delete
this.unget();
[7047] Fix | Delete
return false;
[7048] Fix | Delete
},
[7049] Fix | Delete
[7050] Fix | Delete
/**
[7051] Fix | Delete
* Determines if the next token matches the given token type.
[7052] Fix | Delete
* If so, that token is consumed; if not, an error is thrown.
[7053] Fix | Delete
* @param {int|int[]} tokenTypes Either a single token type or an array of
[7054] Fix | Delete
* token types that the next token should be. If an array is passed,
[7055] Fix | Delete
* it's assumed that the token must be one of these.
[7056] Fix | Delete
* @return {void}
[7057] Fix | Delete
* @method mustMatch
[7058] Fix | Delete
*/
[7059] Fix | Delete
mustMatch: function(tokenTypes) {
[7060] Fix | Delete
[7061] Fix | Delete
var token;
[7062] Fix | Delete
[7063] Fix | Delete
//always convert to an array, makes things easier
[7064] Fix | Delete
if (!(tokenTypes instanceof Array)) {
[7065] Fix | Delete
tokenTypes = [tokenTypes];
[7066] Fix | Delete
}
[7067] Fix | Delete
[7068] Fix | Delete
if (!this.match.apply(this, arguments)) {
[7069] Fix | Delete
token = this.LT(1);
[7070] Fix | Delete
throw new SyntaxError("Expected " + this._tokenData[tokenTypes[0]].name +
[7071] Fix | Delete
" at line " + token.startLine + ", col " + token.startCol + ".", token.startLine, token.startCol);
[7072] Fix | Delete
}
[7073] Fix | Delete
},
[7074] Fix | Delete
[7075] Fix | Delete
//-------------------------------------------------------------------------
[7076] Fix | Delete
// Consuming methods
[7077] Fix | Delete
//-------------------------------------------------------------------------
[7078] Fix | Delete
[7079] Fix | Delete
/**
[7080] Fix | Delete
* Keeps reading from the token stream until either one of the specified
[7081] Fix | Delete
* token types is found or until the end of the input is reached.
[7082] Fix | Delete
* @param {int|int[]} tokenTypes Either a single token type or an array of
[7083] Fix | Delete
* token types that the next token should be. If an array is passed,
[7084] Fix | Delete
* it's assumed that the token must be one of these.
[7085] Fix | Delete
* @param {variant} channel (Optional) The channel to read from. If not
[7086] Fix | Delete
* provided, reads from the default (unnamed) channel.
[7087] Fix | Delete
* @return {void}
[7088] Fix | Delete
* @method advance
[7089] Fix | Delete
*/
[7090] Fix | Delete
advance: function(tokenTypes, channel) {
[7091] Fix | Delete
[7092] Fix | Delete
while (this.LA(0) !== 0 && !this.match(tokenTypes, channel)) {
[7093] Fix | Delete
this.get();
[7094] Fix | Delete
}
[7095] Fix | Delete
[7096] Fix | Delete
return this.LA(0);
[7097] Fix | Delete
},
[7098] Fix | Delete
[7099] Fix | Delete
/**
[7100] Fix | Delete
* Consumes the next token from the token stream.
[7101] Fix | Delete
* @return {int} The token type of the token that was just consumed.
[7102] Fix | Delete
* @method get
[7103] Fix | Delete
*/
[7104] Fix | Delete
get: function(channel) {
[7105] Fix | Delete
[7106] Fix | Delete
var tokenInfo = this._tokenData,
[7107] Fix | Delete
i =0,
[7108] Fix | Delete
token,
[7109] Fix | Delete
info;
[7110] Fix | Delete
[7111] Fix | Delete
//check the lookahead buffer first
[7112] Fix | Delete
if (this._lt.length && this._ltIndex >= 0 && this._ltIndex < this._lt.length) {
[7113] Fix | Delete
[7114] Fix | Delete
i++;
[7115] Fix | Delete
this._token = this._lt[this._ltIndex++];
[7116] Fix | Delete
info = tokenInfo[this._token.type];
[7117] Fix | Delete
[7118] Fix | Delete
//obey channels logic
[7119] Fix | Delete
while ((info.channel !== undefined && channel !== info.channel) &&
[7120] Fix | Delete
this._ltIndex < this._lt.length) {
[7121] Fix | Delete
this._token = this._lt[this._ltIndex++];
[7122] Fix | Delete
info = tokenInfo[this._token.type];
[7123] Fix | Delete
i++;
[7124] Fix | Delete
}
[7125] Fix | Delete
[7126] Fix | Delete
//here be dragons
[7127] Fix | Delete
if ((info.channel === undefined || channel === info.channel) &&
[7128] Fix | Delete
this._ltIndex <= this._lt.length) {
[7129] Fix | Delete
this._ltIndexCache.push(i);
[7130] Fix | Delete
return this._token.type;
[7131] Fix | Delete
}
[7132] Fix | Delete
}
[7133] Fix | Delete
[7134] Fix | Delete
//call token retriever method
[7135] Fix | Delete
token = this._getToken();
[7136] Fix | Delete
[7137] Fix | Delete
//if it should be hidden, don't save a token
[7138] Fix | Delete
if (token.type > -1 && !tokenInfo[token.type].hide) {
[7139] Fix | Delete
[7140] Fix | Delete
//apply token channel
[7141] Fix | Delete
token.channel = tokenInfo[token.type].channel;
[7142] Fix | Delete
[7143] Fix | Delete
//save for later
[7144] Fix | Delete
this._token = token;
[7145] Fix | Delete
this._lt.push(token);
[7146] Fix | Delete
[7147] Fix | Delete
//save space that will be moved (must be done before array is truncated)
[7148] Fix | Delete
this._ltIndexCache.push(this._lt.length - this._ltIndex + i);
[7149] Fix | Delete
[7150] Fix | Delete
//keep the buffer under 5 items
[7151] Fix | Delete
if (this._lt.length > 5) {
[7152] Fix | Delete
this._lt.shift();
[7153] Fix | Delete
}
[7154] Fix | Delete
[7155] Fix | Delete
//also keep the shift buffer under 5 items
[7156] Fix | Delete
if (this._ltIndexCache.length > 5) {
[7157] Fix | Delete
this._ltIndexCache.shift();
[7158] Fix | Delete
}
[7159] Fix | Delete
[7160] Fix | Delete
//update lookahead index
[7161] Fix | Delete
this._ltIndex = this._lt.length;
[7162] Fix | Delete
}
[7163] Fix | Delete
[7164] Fix | Delete
/*
[7165] Fix | Delete
* Skip to the next token if:
[7166] Fix | Delete
* 1. The token type is marked as hidden.
[7167] Fix | Delete
* 2. The token type has a channel specified and it isn't the current channel.
[7168] Fix | Delete
*/
[7169] Fix | Delete
info = tokenInfo[token.type];
[7170] Fix | Delete
if (info &&
[7171] Fix | Delete
(info.hide ||
[7172] Fix | Delete
(info.channel !== undefined && channel !== info.channel))) {
[7173] Fix | Delete
return this.get(channel);
[7174] Fix | Delete
} else {
[7175] Fix | Delete
//return just the type
[7176] Fix | Delete
return token.type;
[7177] Fix | Delete
}
[7178] Fix | Delete
},
[7179] Fix | Delete
[7180] Fix | Delete
/**
[7181] Fix | Delete
* Looks ahead a certain number of tokens and returns the token type at
[7182] Fix | Delete
* that position. This will throw an error if you lookahead past the
[7183] Fix | Delete
* end of input, past the size of the lookahead buffer, or back past
[7184] Fix | Delete
* the first token in the lookahead buffer.
[7185] Fix | Delete
* @param {int} The index of the token type to retrieve. 0 for the
[7186] Fix | Delete
* current token, 1 for the next, -1 for the previous, etc.
[7187] Fix | Delete
* @return {int} The token type of the token in the given position.
[7188] Fix | Delete
* @method LA
[7189] Fix | Delete
*/
[7190] Fix | Delete
LA: function(index) {
[7191] Fix | Delete
var total = index,
[7192] Fix | Delete
tt;
[7193] Fix | Delete
if (index > 0) {
[7194] Fix | Delete
//TODO: Store 5 somewhere
[7195] Fix | Delete
if (index > 5) {
[7196] Fix | Delete
throw new Error("Too much lookahead.");
[7197] Fix | Delete
}
[7198] Fix | Delete
[7199] Fix | Delete
//get all those tokens
[7200] Fix | Delete
while (total) {
[7201] Fix | Delete
tt = this.get();
[7202] Fix | Delete
total--;
[7203] Fix | Delete
}
[7204] Fix | Delete
[7205] Fix | Delete
//unget all those tokens
[7206] Fix | Delete
while (total < index) {
[7207] Fix | Delete
this.unget();
[7208] Fix | Delete
total++;
[7209] Fix | Delete
}
[7210] Fix | Delete
} else if (index < 0) {
[7211] Fix | Delete
[7212] Fix | Delete
if (this._lt[this._ltIndex+index]) {
[7213] Fix | Delete
tt = this._lt[this._ltIndex+index].type;
[7214] Fix | Delete
} else {
[7215] Fix | Delete
throw new Error("Too much lookbehind.");
[7216] Fix | Delete
}
[7217] Fix | Delete
[7218] Fix | Delete
} else {
[7219] Fix | Delete
tt = this._token.type;
[7220] Fix | Delete
}
[7221] Fix | Delete
[7222] Fix | Delete
return tt;
[7223] Fix | Delete
[7224] Fix | Delete
},
[7225] Fix | Delete
[7226] Fix | Delete
/**
[7227] Fix | Delete
* Looks ahead a certain number of tokens and returns the token at
[7228] Fix | Delete
* that position. This will throw an error if you lookahead past the
[7229] Fix | Delete
* end of input, past the size of the lookahead buffer, or back past
[7230] Fix | Delete
* the first token in the lookahead buffer.
[7231] Fix | Delete
* @param {int} The index of the token type to retrieve. 0 for the
[7232] Fix | Delete
* current token, 1 for the next, -1 for the previous, etc.
[7233] Fix | Delete
* @return {Object} The token of the token in the given position.
[7234] Fix | Delete
* @method LA
[7235] Fix | Delete
*/
[7236] Fix | Delete
LT: function(index) {
[7237] Fix | Delete
[7238] Fix | Delete
//lookahead first to prime the token buffer
[7239] Fix | Delete
this.LA(index);
[7240] Fix | Delete
[7241] Fix | Delete
//now find the token, subtract one because _ltIndex is already at the next index
[7242] Fix | Delete
return this._lt[this._ltIndex+index-1];
[7243] Fix | Delete
},
[7244] Fix | Delete
[7245] Fix | Delete
/**
[7246] Fix | Delete
* Returns the token type for the next token in the stream without
[7247] Fix | Delete
* consuming it.
[7248] Fix | Delete
* @return {int} The token type of the next token in the stream.
[7249] Fix | Delete
* @method peek
[7250] Fix | Delete
*/
[7251] Fix | Delete
peek: function() {
[7252] Fix | Delete
return this.LA(1);
[7253] Fix | Delete
},
[7254] Fix | Delete
[7255] Fix | Delete
/**
[7256] Fix | Delete
* Returns the actual token object for the last consumed token.
[7257] Fix | Delete
* @return {Token} The token object for the last consumed token.
[7258] Fix | Delete
* @method token
[7259] Fix | Delete
*/
[7260] Fix | Delete
token: function() {
[7261] Fix | Delete
return this._token;
[7262] Fix | Delete
},
[7263] Fix | Delete
[7264] Fix | Delete
/**
[7265] Fix | Delete
* Returns the name of the token for the given token type.
[7266] Fix | Delete
* @param {int} tokenType The type of token to get the name of.
[7267] Fix | Delete
* @return {String} The name of the token or "UNKNOWN_TOKEN" for any
[7268] Fix | Delete
* invalid token type.
[7269] Fix | Delete
* @method tokenName
[7270] Fix | Delete
*/
[7271] Fix | Delete
tokenName: function(tokenType) {
[7272] Fix | Delete
if (tokenType < 0 || tokenType > this._tokenData.length) {
[7273] Fix | Delete
return "UNKNOWN_TOKEN";
[7274] Fix | Delete
} else {
[7275] Fix | Delete
return this._tokenData[tokenType].name;
[7276] Fix | Delete
}
[7277] Fix | Delete
},
[7278] Fix | Delete
[7279] Fix | Delete
/**
[7280] Fix | Delete
* Returns the token type value for the given token name.
[7281] Fix | Delete
* @param {String} tokenName The name of the token whose value should be returned.
[7282] Fix | Delete
* @return {int} The token type value for the given token name or -1
[7283] Fix | Delete
* for an unknown token.
[7284] Fix | Delete
* @method tokenName
[7285] Fix | Delete
*/
[7286] Fix | Delete
tokenType: function(tokenName) {
[7287] Fix | Delete
return this._tokenData[tokenName] || -1;
[7288] Fix | Delete
},
[7289] Fix | Delete
[7290] Fix | Delete
/**
[7291] Fix | Delete
* Returns the last consumed token to the token stream.
[7292] Fix | Delete
* @method unget
[7293] Fix | Delete
*/
[7294] Fix | Delete
unget: function() {
[7295] Fix | Delete
//if (this._ltIndex > -1) {
[7296] Fix | Delete
if (this._ltIndexCache.length) {
[7297] Fix | Delete
this._ltIndex -= this._ltIndexCache.pop();//--;
[7298] Fix | Delete
this._token = this._lt[this._ltIndex - 1];
[7299] Fix | Delete
} else {
[7300] Fix | Delete
throw new Error("Too much lookahead.");
[7301] Fix | Delete
}
[7302] Fix | Delete
}
[7303] Fix | Delete
[7304] Fix | Delete
};
[7305] Fix | Delete
[7306] Fix | Delete
[7307] Fix | Delete
},{"./StringReader":24,"./SyntaxError":25}],28:[function(require,module,exports){
[7308] Fix | Delete
"use strict";
[7309] Fix | Delete
[7310] Fix | Delete
module.exports = {
[7311] Fix | Delete
StringReader : require("./StringReader"),
[7312] Fix | Delete
SyntaxError : require("./SyntaxError"),
[7313] Fix | Delete
SyntaxUnit : require("./SyntaxUnit"),
[7314] Fix | Delete
EventTarget : require("./EventTarget"),
[7315] Fix | Delete
TokenStreamBase : require("./TokenStreamBase")
[7316] Fix | Delete
};
[7317] Fix | Delete
[7318] Fix | Delete
},{"./EventTarget":23,"./StringReader":24,"./SyntaxError":25,"./SyntaxUnit":26,"./TokenStreamBase":27}],"parserlib":[function(require,module,exports){
[7319] Fix | Delete
"use strict";
[7320] Fix | Delete
[7321] Fix | Delete
module.exports = {
[7322] Fix | Delete
css : require("./css"),
[7323] Fix | Delete
util : require("./util")
[7324] Fix | Delete
};
[7325] Fix | Delete
[7326] Fix | Delete
},{"./css":22,"./util":28}]},{},[]);
[7327] Fix | Delete
[7328] Fix | Delete
return require('parserlib');
[7329] Fix | Delete
})();
[7330] Fix | Delete
var clone = (function() {
[7331] Fix | Delete
'use strict';
[7332] Fix | Delete
[7333] Fix | Delete
var nativeMap;
[7334] Fix | Delete
try {
[7335] Fix | Delete
nativeMap = Map;
[7336] Fix | Delete
} catch(_) {
[7337] Fix | Delete
// maybe a reference error because no `Map`. Give it a dummy value that no
[7338] Fix | Delete
// value will ever be an instanceof.
[7339] Fix | Delete
nativeMap = function() {};
[7340] Fix | Delete
}
[7341] Fix | Delete
[7342] Fix | Delete
var nativeSet;
[7343] Fix | Delete
try {
[7344] Fix | Delete
nativeSet = Set;
[7345] Fix | Delete
} catch(_) {
[7346] Fix | Delete
nativeSet = function() {};
[7347] Fix | Delete
}
[7348] Fix | Delete
[7349] Fix | Delete
var nativePromise;
[7350] Fix | Delete
try {
[7351] Fix | Delete
nativePromise = Promise;
[7352] Fix | Delete
} catch(_) {
[7353] Fix | Delete
nativePromise = function() {};
[7354] Fix | Delete
}
[7355] Fix | Delete
[7356] Fix | Delete
/**
[7357] Fix | Delete
* Clones (copies) an Object using deep copying.
[7358] Fix | Delete
*
[7359] Fix | Delete
* This function supports circular references by default, but if you are certain
[7360] Fix | Delete
* there are no circular references in your object, you can save some CPU time
[7361] Fix | Delete
* by calling clone(obj, false).
[7362] Fix | Delete
*
[7363] Fix | Delete
* Caution: if `circular` is false and `parent` contains circular references,
[7364] Fix | Delete
* your program may enter an infinite loop and crash.
[7365] Fix | Delete
*
[7366] Fix | Delete
* @param `parent` - the object to be cloned
[7367] Fix | Delete
* @param `circular` - set to true if the object to be cloned may contain
[7368] Fix | Delete
* circular references. (optional - true by default)
[7369] Fix | Delete
* @param `depth` - set to a number if the object is only to be cloned to
[7370] Fix | Delete
* a particular depth. (optional - defaults to Infinity)
[7371] Fix | Delete
* @param `prototype` - sets the prototype to be used when cloning an object.
[7372] Fix | Delete
* (optional - defaults to parent prototype).
[7373] Fix | Delete
* @param `includeNonEnumerable` - set to true if the non-enumerable properties
[7374] Fix | Delete
* should be cloned as well. Non-enumerable properties on the prototype
[7375] Fix | Delete
* chain will be ignored. (optional - false by default)
[7376] Fix | Delete
*/
[7377] Fix | Delete
function clone(parent, circular, depth, prototype, includeNonEnumerable) {
[7378] Fix | Delete
if (typeof circular === 'object') {
[7379] Fix | Delete
depth = circular.depth;
[7380] Fix | Delete
prototype = circular.prototype;
[7381] Fix | Delete
includeNonEnumerable = circular.includeNonEnumerable;
[7382] Fix | Delete
circular = circular.circular;
[7383] Fix | Delete
}
[7384] Fix | Delete
// maintain two arrays for circular references, where corresponding parents
[7385] Fix | Delete
// and children have the same index
[7386] Fix | Delete
var allParents = [];
[7387] Fix | Delete
var allChildren = [];
[7388] Fix | Delete
[7389] Fix | Delete
var useBuffer = typeof Buffer != 'undefined';
[7390] Fix | Delete
[7391] Fix | Delete
if (typeof circular == 'undefined')
[7392] Fix | Delete
circular = true;
[7393] Fix | Delete
[7394] Fix | Delete
if (typeof depth == 'undefined')
[7395] Fix | Delete
depth = Infinity;
[7396] Fix | Delete
[7397] Fix | Delete
// recurse this function so we don't reset allParents and allChildren
[7398] Fix | Delete
function _clone(parent, depth) {
[7399] Fix | Delete
// cloning null always returns null
[7400] Fix | Delete
if (parent === null)
[7401] Fix | Delete
return null;
[7402] Fix | Delete
[7403] Fix | Delete
if (depth === 0)
[7404] Fix | Delete
return parent;
[7405] Fix | Delete
[7406] Fix | Delete
var child;
[7407] Fix | Delete
var proto;
[7408] Fix | Delete
if (typeof parent != 'object') {
[7409] Fix | Delete
return parent;
[7410] Fix | Delete
}
[7411] Fix | Delete
[7412] Fix | Delete
if (parent instanceof nativeMap) {
[7413] Fix | Delete
child = new nativeMap();
[7414] Fix | Delete
} else if (parent instanceof nativeSet) {
[7415] Fix | Delete
child = new nativeSet();
[7416] Fix | Delete
} else if (parent instanceof nativePromise) {
[7417] Fix | Delete
child = new nativePromise(function (resolve, reject) {
[7418] Fix | Delete
parent.then(function(value) {
[7419] Fix | Delete
resolve(_clone(value, depth - 1));
[7420] Fix | Delete
}, function(err) {
[7421] Fix | Delete
reject(_clone(err, depth - 1));
[7422] Fix | Delete
});
[7423] Fix | Delete
});
[7424] Fix | Delete
} else if (clone.__isArray(parent)) {
[7425] Fix | Delete
child = [];
[7426] Fix | Delete
} else if (clone.__isRegExp(parent)) {
[7427] Fix | Delete
child = new RegExp(parent.source, __getRegExpFlags(parent));
[7428] Fix | Delete
if (parent.lastIndex) child.lastIndex = parent.lastIndex;
[7429] Fix | Delete
} else if (clone.__isDate(parent)) {
[7430] Fix | Delete
child = new Date(parent.getTime());
[7431] Fix | Delete
} else if (useBuffer && Buffer.isBuffer(parent)) {
[7432] Fix | Delete
child = new Buffer(parent.length);
[7433] Fix | Delete
parent.copy(child);
[7434] Fix | Delete
return child;
[7435] Fix | Delete
} else if (parent instanceof Error) {
[7436] Fix | Delete
child = Object.create(parent);
[7437] Fix | Delete
} else {
[7438] Fix | Delete
if (typeof prototype == 'undefined') {
[7439] Fix | Delete
proto = Object.getPrototypeOf(parent);
[7440] Fix | Delete
child = Object.create(proto);
[7441] Fix | Delete
}
[7442] Fix | Delete
else {
[7443] Fix | Delete
child = Object.create(prototype);
[7444] Fix | Delete
proto = prototype;
[7445] Fix | Delete
}
[7446] Fix | Delete
}
[7447] Fix | Delete
[7448] Fix | Delete
if (circular) {
[7449] Fix | Delete
var index = allParents.indexOf(parent);
[7450] Fix | Delete
[7451] Fix | Delete
if (index != -1) {
[7452] Fix | Delete
return allChildren[index];
[7453] Fix | Delete
}
[7454] Fix | Delete
allParents.push(parent);
[7455] Fix | Delete
allChildren.push(child);
[7456] Fix | Delete
}
[7457] Fix | Delete
[7458] Fix | Delete
if (parent instanceof nativeMap) {
[7459] Fix | Delete
var keyIterator = parent.keys();
[7460] Fix | Delete
while(true) {
[7461] Fix | Delete
var next = keyIterator.next();
[7462] Fix | Delete
if (next.done) {
[7463] Fix | Delete
break;
[7464] Fix | Delete
}
[7465] Fix | Delete
var keyChild = _clone(next.value, depth - 1);
[7466] Fix | Delete
var valueChild = _clone(parent.get(next.value), depth - 1);
[7467] Fix | Delete
child.set(keyChild, valueChild);
[7468] Fix | Delete
}
[7469] Fix | Delete
}
[7470] Fix | Delete
if (parent instanceof nativeSet) {
[7471] Fix | Delete
var iterator = parent.keys();
[7472] Fix | Delete
while(true) {
[7473] Fix | Delete
var next = iterator.next();
[7474] Fix | Delete
if (next.done) {
[7475] Fix | Delete
break;
[7476] Fix | Delete
}
[7477] Fix | Delete
var entryChild = _clone(next.value, depth - 1);
[7478] Fix | Delete
child.add(entryChild);
[7479] Fix | Delete
}
[7480] Fix | Delete
}
[7481] Fix | Delete
[7482] Fix | Delete
for (var i in parent) {
[7483] Fix | Delete
var attrs;
[7484] Fix | Delete
if (proto) {
[7485] Fix | Delete
attrs = Object.getOwnPropertyDescriptor(proto, i);
[7486] Fix | Delete
}
[7487] Fix | Delete
[7488] Fix | Delete
if (attrs && attrs.set == null) {
[7489] Fix | Delete
continue;
[7490] Fix | Delete
}
[7491] Fix | Delete
child[i] = _clone(parent[i], depth - 1);
[7492] Fix | Delete
}
[7493] Fix | Delete
[7494] Fix | Delete
if (Object.getOwnPropertySymbols) {
[7495] Fix | Delete
var symbols = Object.getOwnPropertySymbols(parent);
[7496] Fix | Delete
for (var i = 0; i < symbols.length; i++) {
[7497] Fix | Delete
// Don't need to worry about cloning a symbol because it is a primitive,
[7498] Fix | Delete
// like a number or string.
[7499] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function