FoldOverExpressions<TState,TResult> Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Class that evaluates a fold on upon transforming an expression. If recur is set to true in the internal state of the transformation, the fold function given on initialization is applied to all subexpressions as well as the expression itself - i.e. the fold it take starting on inner expressions (from the inside out). Otherwise the specified folder is only applied to the expression itself. The result of the fold is accessible via the FoldResult property in the internal state of the transformation. The transformation itself merely walks expressions and rebuilding is disabled.
public class FoldOverExpressions<TState,TResult> : Microsoft.Quantum.QsCompiler.Transformations.Core.ExpressionTransformation<TState> where TState : FoldOverExpressions<TState,TResult>.IFoldingState
type FoldOverExpressions<'State, 'Result (requires 'State :> FoldOverExpressions<'State, 'Result>.IFoldingState)> = class
inherit ExpressionTransformation<'State (requires 'State :> FoldOverExpressions<'State, 'Result>.IFoldingState)>
Public Class FoldOverExpressions(Of TState, TResult)
Inherits ExpressionTransformation(Of TState)
Type Parameters
- TState
- TResult
- Inheritance
-
ExpressionTransformation<TState>FoldOverExpressions<TState,TResult>
Constructors
| FoldOverExpressions<TState,TResult>(SyntaxTreeTransformation<TState>) | |
| FoldOverExpressions<TState,TResult>(TState) |
Properties
| ExpressionKinds | (Inherited from ExpressionTransformationBase) |
| SharedState | (Inherited from ExpressionTransformation<T>) |
| Transformation | (Inherited from ExpressionTransformation<T>) |
| Types | (Inherited from ExpressionTransformationBase) |
Methods
| OnExpressionInformation(InferredExpressionInformation) | (Inherited from ExpressionTransformationBase) |
| OnRangeInformation(QsNullable<Range>) |
Obsolete.
(Inherited from ExpressionTransformationBase)
|
| OnTypedExpression(TypedExpression) | System.Object.OnTypedExpression(Microsoft.Quantum.QsCompiler.SyntaxTree.TypedExpression) |
| OnTypeParamResolutions(ImmutableDictionary<Tuple<QsQualifiedName,String>,ResolvedType>) | (Inherited from ExpressionTransformationBase) |