Skip to content

Commit

Permalink
Re-order function definitions in dump.cpp
Browse files Browse the repository at this point in the history
To be more aligned with the ordering in dump.h.

Signed-off-by: Bili Dong <qobilidop@gmail.com>
  • Loading branch information
qobilidop committed Sep 3, 2024
1 parent 2498571 commit ac5d936
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions ir/dump.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,9 @@ void dump(const IR::Node *n, unsigned maxdepth) { dump(std::cout, n, maxdepth);
void dump(const IR::Node *n) { dump(n, ~0U); }
void dump(const IR::INode *n, unsigned maxdepth) { dump(std::cout, n->getNode(), maxdepth); }
void dump(const IR::INode *n) { dump(n, ~0U); }
void dump(uintptr_t p, unsigned maxdepth) { dump(reinterpret_cast<const IR::Node *>(p), maxdepth); }
void dump(uintptr_t p) { dump(p, ~0U); }

void dump_notype(const IR::Node *n, unsigned maxdepth) {
n->apply(IRDumper(std::cout, maxdepth, "type"_cs, false));
}
Expand All @@ -92,6 +95,11 @@ void dump_notype(const IR::INode *n, unsigned maxdepth) {
n->getNode()->apply(IRDumper(std::cout, maxdepth, "type"_cs, false));
}
void dump_notype(const IR::INode *n) { dump_notype(n, ~0U); }
void dump_notype(uintptr_t p, unsigned maxdepth) {
dump_notype(reinterpret_cast<const IR::Node *>(p), maxdepth);
}
void dump_notype(uintptr_t p) { dump_notype(p, ~0U); }

void dump_src(const IR::Node *n, unsigned maxdepth) {
n->apply(IRDumper(std::cout, maxdepth, "type"_cs, true));
}
Expand All @@ -101,13 +109,6 @@ void dump_src(const IR::INode *n, unsigned maxdepth) {
}
void dump_src(const IR::INode *n) { dump_src(n, ~0U); }

void dump(uintptr_t p, unsigned maxdepth) { dump(reinterpret_cast<const IR::Node *>(p), maxdepth); }
void dump(uintptr_t p) { dump(p, ~0U); }
void dump_notype(uintptr_t p, unsigned maxdepth) {
dump_notype(reinterpret_cast<const IR::Node *>(p), maxdepth);
}
void dump_notype(uintptr_t p) { dump_notype(p, ~0U); }

void dump(std::ostream &out, const Visitor::Context *ctxt) {
if (!ctxt) return;
dump(ctxt->parent);
Expand Down

0 comments on commit ac5d936

Please sign in to comment.