source: frontend/node_modules/@babel/core/lib/parse.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: 1.4 KB
Line 
1"use strict";
2
3Object.defineProperty(exports, "__esModule", {
4 value: true
5});
6exports.parse = void 0;
7exports.parseAsync = parseAsync;
8exports.parseSync = parseSync;
9function _gensync() {
10 const data = require("gensync");
11 _gensync = function () {
12 return data;
13 };
14 return data;
15}
16var _index = require("./config/index.js");
17var _index2 = require("./parser/index.js");
18var _normalizeOpts = require("./transformation/normalize-opts.js");
19var _rewriteStackTrace = require("./errors/rewrite-stack-trace.js");
20const parseRunner = _gensync()(function* parse(code, opts) {
21 const config = yield* (0, _index.default)(opts);
22 if (config === null) {
23 return null;
24 }
25 return yield* (0, _index2.default)(config.passes, (0, _normalizeOpts.default)(config), code);
26});
27const parse = exports.parse = function parse(code, opts, callback) {
28 if (typeof opts === "function") {
29 callback = opts;
30 opts = undefined;
31 }
32 if (callback === undefined) {
33 return (0, _rewriteStackTrace.beginHiddenCallStack)(parseRunner.sync)(code, opts);
34 }
35 (0, _rewriteStackTrace.beginHiddenCallStack)(parseRunner.errback)(code, opts, callback);
36};
37function parseSync(...args) {
38 return (0, _rewriteStackTrace.beginHiddenCallStack)(parseRunner.sync)(...args);
39}
40function parseAsync(...args) {
41 return (0, _rewriteStackTrace.beginHiddenCallStack)(parseRunner.async)(...args);
42}
430 && 0;
44
45//# sourceMappingURL=parse.js.map
Note: See TracBrowser for help on using the repository browser.