ast-types
Advanced tools
Comparing version 0.4.3 to 0.4.4
@@ -307,2 +307,11 @@ var assert = require("assert"); | ||
// Note that the list returned by this function is a copy of the internal | ||
// supertypeList, *without* the typeName itself as the first element. | ||
exports.getSupertypeNames = function(typeName) { | ||
assert.ok(hasOwn.call(defCache, typeName)); | ||
var d = defCache[typeName]; | ||
assert.strictEqual(d.finalized, true); | ||
return d.supertypeList.slice(1); | ||
}; | ||
// Returns an object mapping from every known type in the defCache to the | ||
@@ -309,0 +318,0 @@ // most specific supertype whose name is an own property of the candidates |
@@ -26,2 +26,3 @@ var types = require("./lib/types"); | ||
exports.someField = types.someField; | ||
exports.getSupertypeNames = types.getSupertypeNames; | ||
exports.traverse = require("./lib/traverse"); | ||
@@ -28,0 +29,0 @@ exports.finalize = types.finalize; |
@@ -21,3 +21,3 @@ { | ||
], | ||
"version": "0.4.3", | ||
"version": "0.4.4", | ||
"homepage": "http://github.com/benjamn/ast-types", | ||
@@ -24,0 +24,0 @@ "repository": { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
92049
2329