mirror of
https://github.com/idanoo/GoScrobble
synced 2025-07-01 05:32:18 +00:00
0.2.0 - Mid migration
This commit is contained in:
parent
139e6a915e
commit
7e38fdbd7d
42393 changed files with 5358157 additions and 62 deletions
41
web/node_modules/@babel/helper-builder-binary-assignment-operator-visitor/lib/index.js
generated
vendored
Normal file
41
web/node_modules/@babel/helper-builder-binary-assignment-operator-visitor/lib/index.js
generated
vendored
Normal file
|
@ -0,0 +1,41 @@
|
|||
"use strict";
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
exports.default = _default;
|
||||
|
||||
var _helperExplodeAssignableExpression = require("@babel/helper-explode-assignable-expression");
|
||||
|
||||
var t = require("@babel/types");
|
||||
|
||||
function _default(opts) {
|
||||
const {
|
||||
build,
|
||||
operator
|
||||
} = opts;
|
||||
return {
|
||||
AssignmentExpression(path) {
|
||||
const {
|
||||
node,
|
||||
scope
|
||||
} = path;
|
||||
if (node.operator !== operator + "=") return;
|
||||
const nodes = [];
|
||||
const exploded = (0, _helperExplodeAssignableExpression.default)(node.left, nodes, this, scope);
|
||||
nodes.push(t.assignmentExpression("=", exploded.ref, build(exploded.uid, node.right)));
|
||||
path.replaceWith(t.sequenceExpression(nodes));
|
||||
},
|
||||
|
||||
BinaryExpression(path) {
|
||||
const {
|
||||
node
|
||||
} = path;
|
||||
|
||||
if (node.operator === operator) {
|
||||
path.replaceWith(build(node.left, node.right));
|
||||
}
|
||||
}
|
||||
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue