source: frontend/node_modules/@babel/traverse/lib/cache.js

Last change on this file was 9af201e, checked in by MBK <marija.karapandzova@…>, 12 days ago

Fix frontend appearance

  • Property mode set to 100644
File size: 895 bytes
RevLine 
[9af201e]1"use strict";
2
3Object.defineProperty(exports, "__esModule", {
4 value: true
5});
6exports.clear = clear;
7exports.clearPath = clearPath;
8exports.clearScope = clearScope;
9exports.getCachedPaths = getCachedPaths;
10exports.getOrCreateCachedPaths = getOrCreateCachedPaths;
11exports.scope = exports.path = void 0;
12let pathsCache = exports.path = new WeakMap();
13let scope = exports.scope = new WeakMap();
14function clear() {
15 clearPath();
16 clearScope();
17}
18function clearPath() {
19 exports.path = pathsCache = new WeakMap();
20}
21function clearScope() {
22 exports.scope = scope = new WeakMap();
23}
24function getCachedPaths(path) {
25 const {
26 parent,
27 parentPath
28 } = path;
29 return pathsCache.get(parent);
30}
31function getOrCreateCachedPaths(node, parentPath) {
32 let paths = pathsCache.get(node);
33 if (!paths) pathsCache.set(node, paths = new Map());
34 return paths;
35}
36
37//# sourceMappingURL=cache.js.map
Note: See TracBrowser for help on using the repository browser.