1 line
110 KiB
JSON
1 line
110 KiB
JSON
|
{"id":"node_modules/leakage/lib/index.js","dependencies":[{"name":"/Users/philkunz/gitlab/pushrocks_meta/smartlog-destination-devtools/package.json","includedInParent":true,"mtime":1542067438335},{"name":"/Users/philkunz/gitlab/pushrocks_meta/smartlog-destination-devtools/node_modules/leakage/package.json","includedInParent":true,"mtime":1542058764034},{"name":"fs","loc":{"line":23,"column":19},"parent":"/Users/philkunz/gitlab/pushrocks_meta/smartlog-destination-devtools/node_modules/leakage/lib/index.js","resolved":"/Users/philkunz/.nvm/versions/node/v10.13.0/lib/node_modules/parcel-bundler/src/builtins/_empty.js"},{"name":"@airbnb/node-memwatch","loc":{"line":24,"column":25},"parent":"/Users/philkunz/gitlab/pushrocks_meta/smartlog-destination-devtools/node_modules/leakage/lib/index.js","resolved":"/Users/philkunz/gitlab/pushrocks_meta/smartlog-destination-devtools/node_modules/@airbnb/node-memwatch/include.js"},{"name":"minimist","loc":{"line":25,"column":25},"parent":"/Users/philkunz/gitlab/pushrocks_meta/smartlog-destination-devtools/node_modules/leakage/lib/index.js","resolved":"/Users/philkunz/gitlab/pushrocks_meta/smartlog-destination-devtools/node_modules/minimist/index.js"},{"name":"path","loc":{"line":26,"column":21},"parent":"/Users/philkunz/gitlab/pushrocks_meta/smartlog-destination-devtools/node_modules/leakage/lib/index.js","resolved":"/Users/philkunz/.nvm/versions/node/v10.13.0/lib/node_modules/parcel-bundler/node_modules/path-browserify/index.js"},{"name":"./result","loc":{"line":27,"column":33},"parent":"/Users/philkunz/gitlab/pushrocks_meta/smartlog-destination-devtools/node_modules/leakage/lib/index.js","resolved":"/Users/philkunz/gitlab/pushrocks_meta/smartlog-destination-devtools/node_modules/leakage/lib/result.js"},{"name":"./testConstantHeapSize","loc":{"line":28,"column":58},"parent":"/Users/philkunz/gitlab/pushrocks_meta/smartlog-destination-devtools/node_modules/leakage/lib/index.js","resolved":"/Users/philkunz/gitlab/pushrocks_meta/smartlog-destination-devtools/node_modules/leakage/lib/testConstantHeapSize.js"},{"name":"process","parent":"/Users/philkunz/gitlab/pushrocks_meta/smartlog-destination-devtools/node_modules/leakage/lib/index.js","resolved":"/Users/philkunz/.nvm/versions/node/v10.13.0/lib/node_modules/parcel-bundler/node_modules/process/browser.js"}],"generated":{"js":"var process = require(\"process\");\n/*\n * Disclaimer:\n *\n * The code in this file is quite ugly. Usually in a review I would be very\n * unhappy if I saw something like this.\n * But it's not this code's job to look pleasant. It's job is to create heap\n * diffs while leaving the smallest possible heap footprint itself. To achieve\n * that we do a couple of things:\n *\n * - We create all objects (including functions and arrays) as early as possible\n * and only once\n * - We create arrays using the `Array` constructor and pass the size we need\n * to avoid re-allocations\n * - We never assign values of different types (number, object, ...) to a variable\n * - We try to avoid promises whereever possible, since they come with a big\n * heap footprint\n * - We use setImmediate() in the right places to create a new execution context\n * to allow garbage-collecting the old execution context's objects\n * - We have dedicated heap footprint tests (see `test/heap-footprint.test.js`)\n * and we test if changes to this code alter its heap footprint\n */\nvar fs = require('fs');\n\nvar memwatch = require('@airbnb/node-memwatch');\n\nvar minimist = require('minimist');\n\nvar path = require('path');\n\nvar {\n createResult: createResult\n} = require('./result');\n\nvar {\n MemoryLeakError: MemoryLeakError,\n testConstantHeapSize: testConstantHeapSize\n} = require('./testConstantHeapSize');\n\nvar argv = minimist(process.argv.slice(2));\nvar currentlyRunningTests = 0;\nmodule.exports = {\n iterate: iterate,\n MemoryLeakError: MemoryLeakError\n};\n\nfunction iterate(iteratorFn) {\n var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n\n var runAndHeapDiff = function () {\n m
|