! Copyright (C) 2004, 2005 Slava Pestov. ! See http://factor.sf.net/license.txt for BSD license. IN: compiler-frontend USING: compiler-backend errors generic lists inference kernel math namespaces prettyprint sequences strings words ; GENERIC: linearize-node* ( node -- ) M: f linearize-node* ( f -- ) drop ; M: node linearize-node* ( node -- ) drop ; : linearize-node ( node -- ) [ dup linearize-node* node-successor linearize-node ] when* ; : linearize ( dataflow -- linear ) #! Transform dataflow IR into linear IR. This strips out #! stack flow information, and flattens conditionals into #! jumps and labels. [ %prologue , linearize-node ] make-list ; M: #label linearize-node* ( node -- )