51 const IR::Node *replacement(
const IR::ITypeVar *original,
const IR::Node *node);
56 : bindings(bindings), replace(replace) {
57 setName(
"TypeVariableSubstitution");
60 const IR::Node *preorder(IR::TypeParameters *tps)
override;
61 const IR::Node *preorder(IR::Type_Any *tv)
override {
62 return replacement(getOriginal<IR::Type_Any>(), tv);
64 const IR::Node *preorder(IR::Type_Var *tv)
override {
65 return replacement(getOriginal<IR::Type_Var>(), tv);
67 const IR::Node *preorder(IR::Type_InfInt *ti)
override {
68 return replacement(getOriginal<IR::Type_InfInt>(), ti);
TODO: this is not really specific to BMV2, it should reside somewhere else.
Definition applyOptionsPragmas.cpp:24