Strafunski-StrategyLib-5.0.1.0: Library for strategic programming

MaintainerRalf Laemmel, Joost Visser
Stabilityexperimental
Portabilityportable
Safe HaskellNone
LanguageHaskell98

Data.Generics.Strafunski.StrategyLib.NameTheme

Contents

Description

This module is part of StrategyLib, a library of functional strategy combinators, including combinators for generic traversal. This module provides algorithms to collect names and their types.

Synopsis

Free name analysis

freeNames Source #

Arguments

:: (Eq name, Term t) 
=> TU [(name, tpe)] Identity

Identify declarations

-> TU [name] Identity

Identify references

-> t

Input term

-> [name]

Free names

Generic free name analysis algorithm (without types)

freeTypedNames Source #

Arguments

:: (Eq name, Term t) 
=> TU [(name, tpe)] Identity

Identify declarations

-> TU [name] Identity

Identify references

-> [(name, tpe)]

Derived declarations

-> t

Input term

-> [(name, tpe)]

Free names with types

Generic free name analysis algorithm with types

Bound name analysis

boundTypedNames :: (Term f, Term t, Eq name) => TU [(name, tpe)] Identity -> (f -> Maybe f) -> t -> Maybe ([(name, tpe)], f) Source #

Accumulate declarations for focus