Sha256: 648edcc5ba1642dd47197010628350aa54722b0aad8ba9b0f6b8f24e0735e921

Contents?: true

Size: 523 Bytes

Versions: 11

Compression:

Stored size: 523 Bytes

Contents

"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = isScope;

var _generated = require("./generated");

function isScope(node, parent) {
  if ((0, _generated.isBlockStatement)(node) && ((0, _generated.isFunction)(parent) || (0, _generated.isCatchClause)(parent))) {
    return false;
  }

  if ((0, _generated.isPattern)(node) && ((0, _generated.isFunction)(parent) || (0, _generated.isCatchClause)(parent))) {
    return true;
  }

  return (0, _generated.isScopable)(node);
}

Version data entries

11 entries across 10 versions & 3 rubygems

Version Path
disco_app-0.16.1 test/dummy/node_modules/@babel/types/lib/validators/isScope.js
disco_app-0.15.2 test/dummy/node_modules/@babel/types/lib/validators/isScope.js
disco_app-0.18.4 test/dummy/node_modules/@babel/types/lib/validators/isScope.js
disco_app-0.18.1 test/dummy/node_modules/@babel/types/lib/validators/isScope.js
disco_app-0.12.7.pre.puma.pre.3 test/dummy/node_modules/@babel/types/lib/validators/isScope.js
disco_app-0.14.0 test/dummy/node_modules/@babel/types/lib/validators/isScope.js
disco_app-0.13.6.pre.puma.pre.3 test/dummy/node_modules/@babel/types/lib/validators/isScope.js
groonga-client-model-6.0.0 test/apps/rails6.1.3/node_modules/@babel/types/lib/validators/isScope.js
groonga-client-model-6.0.0 test/apps/rails6.0.3.5/node_modules/@babel/types/lib/validators/isScope.js
ruby2js-4.0.4 lib/tasks/testrails/node_modules/@babel/types/lib/validators/isScope.js
ruby2js-4.0.3 lib/tasks/testrails/node_modules/@babel/types/lib/validators/isScope.js