LicenseGNU LGPLv3
Maintainerpaul.bittner@uni-ulm.de
Safe HaskellNone

DefaultFeatureTraceRecording

Description

Implementation of feature trace recording as proposed in the paper (Section 4.2).

Synopsis

Documentation

defaultFeatureTraceRecording :: (Grammar g, Show a, Eq a) => FeatureTraceRecording g a Source #

This is the default implementation of feature trace recording as proposed in our paper. For each type of edit, we choose one of the four recording functions from R_ins, R_del, R_mov, and R_up. Next to these four functions, we support two more default recording function in this library, r_id and r_trace. We use r_id for technical reasons (e.g., folds, printing) and it does not affect the mappings. We use r_trace to manually change the feature mappings of a set of nodes without changing the source code.

nullifyMandatory :: Grammar g => RecordingFunction g a -> RecordingFunction g a Source #

Sets the feature mapping of all mandatory AST nodes to null.

removeTheRedundanciesWeIntroduced :: (Grammar g, Eq a, Show a) => RecordingFunction g a -> RecordingFunction g a Source #

This simplifies feature traces with respect to presence conditions. See simplifyFeatureTrace and removeRedundancy for further information.

r_id :: RecordingFunction g a Source #

Feature trace recording for identity edit: When nothing is changed, nothing has to be recorded.

r_trace :: Eq a => RecordingFunction g a Source #

Feature trace recording on an identity edit with non-empty delta. This function allows changing feature traces manually (i.e., without actual source code changes). Have a look at edit_trace_only for further information.

r_ins :: (Show a, Eq a) => RecordingFunction g a Source #

Equation 2 in the paper: R_ins records feature traces upon insertions.

r_del :: (Grammar g, Eq a, Show a) => RecordingFunction g a Source #

Equation 2 in the paper: R_del records feature traces upon deletions.

r_move :: (Show a, Eq a) => RecordingFunction g a Source #

Equation 3 in the paper: R_move records feature traces upon moves.

r_up :: (Eq a, Show a) => RecordingFunction g a Source #

Equation 5 in the paper: R_up records feature traces upon updates.