sslang-0.1.0.0
Safe HaskellNone
LanguageHaskell2010

IR.LambdaLift

Description

Lift lambda definitions into the global scope.

This pass is responsible for moving nested lambda definitions into the global scope and performing necessary callsite adjustments.

Synopsis

Documentation

liftProgramLambdas :: Program Type -> Pass (Program Type) Source #

Entry-point to lambda lifting.

Maps over top level definitions and lifts out lambda definitions to create a new Program with the relative order of user definitions preserved.