MCPcopy Index your code
hub / github.com/sql-js/sql.js / createCache

Function createCache

documentation/javascript/application.js:4601–4613  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

4599 },
4600
4601 createCache = function() {
4602 var cache = {},
4603 keys = [];
4604
4605 return markFunction(function( key, value ) {
4606 // Only keep the most recent entries
4607 if ( keys.push( key ) > Expr.cacheLength ) {
4608 delete cache[ keys.shift() ];
4609 }
4610
4611 return (cache[ key ] = value);
4612 }, cache );
4613 },
4614
4615 classCache = createCache(),
4616 tokenCache = createCache(),

Callers 1

application.jsFile · 0.85

Calls 1

markFunctionFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…