Thorin 1.9.0
The Higher ORder INtermediate representation
Loading...
Searching...
No Matches
thorin::Rewriter Class Reference

Recurseivly rewrites part of a program into the provided World. More...

#include <thorin/rewrite.h>

Inheritance diagram for thorin::Rewriter:
[legend]

Public Member Functions

 Rewriter (World &world)
 
Worldworld ()
 
Ref map (Ref old_def, Ref new_def)
 Map old_def to new_def and returns new_def;.
 
rewrite

Recursively rewrite old Defs.

virtual Ref rewrite (Ref)
 
virtual Ref rewrite_imm (Ref)
 
virtual Ref rewrite_mut (Def *)
 

Detailed Description

Recurseivly rewrites part of a program into the provided World.

This World may be different than the World we started with.

Definition at line 9 of file rewrite.h.

Constructor & Destructor Documentation

◆ Rewriter()

thorin::Rewriter::Rewriter ( World world)
inline

Definition at line 11 of file rewrite.h.

Member Function Documentation

◆ map()

Ref thorin::Rewriter::map ( Ref  old_def,
Ref  new_def 
)
inline

Map old_def to new_def and returns new_def;.

Definition at line 16 of file rewrite.h.

Referenced by rewrite(), rewrite_mut(), thorin::VarRewriter::rewrite_mut(), and thorin::VarRewriter::VarRewriter().

◆ rewrite()

◆ rewrite_imm()

◆ rewrite_mut()

Ref thorin::Rewriter::rewrite_mut ( Def old_mut)
virtual

◆ world()

World & thorin::Rewriter::world ( )
inline

The documentation for this class was generated from the following files: