1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 19:23:23 +01:00

Provide visit(Module&) and visitModule(Module&) functionality.

llvm-svn: 13353
This commit is contained in:
Misha Brukman 2004-05-04 18:30:38 +00:00
parent f3b62c562e
commit 4d6a3d4e1e

View File

@ -88,6 +88,10 @@ struct InstVisitor {
// Define visitors for functions and basic blocks...
//
void visit(Module &M) {
((SubClass*)this)->visitModule(M);
visit(M.begin(), M.end());
}
void visit(Function &F) {
((SubClass*)this)->visitFunction(F);
visit(F.begin(), F.end());
@ -127,6 +131,7 @@ struct InstVisitor {
// When visiting a module, function or basic block directly, these methods get
// called to indicate when transitioning into a new unit.
//
void visitModule (Module &M) {}
void visitFunction (Function &F) {}
void visitBasicBlock(BasicBlock &BB) {}