MCPcopy Index your code
hub / github.com/JsAaron/jQuery / createPositionalPseudo

Function createPositionalPseudo

2.1.1/test/sizzle.js:427–443  ·  view source on GitHub ↗

* Returns a function to use in pseudos for positionals * @param {Function} fn

( fn )

Source from the content-addressed store, hash-verified

425 * @param {Function} fn
426 */
427function createPositionalPseudo( fn ) {
428 return markFunction(function( argument ) {
429 argument = +argument;
430 return markFunction(function( seed, matches ) {
431 var j,
432 matchIndexes = fn( [], seed.length, argument ),
433 i = matchIndexes.length;
434
435 // Match elements found at the specified indexes
436 while ( i-- ) {
437 if ( seed[ (j = matchIndexes[i]) ] ) {
438 seed[j] = !(matches[j] = seed[j]);
439 }
440 }
441 });
442 });
443}
444
445/**
446 * Checks a node for validity as a Sizzle context

Callers 1

sizzle.jsFile · 0.70

Calls 2

markFunctionFunction · 0.70
fnFunction · 0.50

Tested by

no test coverage detected