@harmoniclabs/plu-ts-onchain
Version:
An embedded DSL for Cardano smart contracts creation coupled with a library for Cardano transactions, all in Typescript
22 lines (21 loc) • 889 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.isForcedNative = void 0;
var index_1 = require("./index.js");
function isForcedNativeTag(tag) {
return (tag === 26 /* IRNativeTag.strictIfThenElse */ ||
tag === 27 /* IRNativeTag.chooseUnit */ ||
tag === 28 /* IRNativeTag.trace */ ||
tag === 32 /* IRNativeTag.mkCons */ ||
tag === 33 /* IRNativeTag.headList */ ||
tag === 34 /* IRNativeTag.tailList */ ||
tag === 35 /* IRNativeTag.nullList */ ||
tag === 36 /* IRNativeTag.chooseData */ ||
tag === 29 /* IRNativeTag.fstPair */ ||
tag === 30 /* IRNativeTag.sndPair */ ||
tag === 31 /* IRNativeTag.strictChooseList */);
}
function isForcedNative(node) {
return node instanceof index_1.IRNative && isForcedNativeTag(node.tag);
}
exports.isForcedNative = isForcedNative;