Sign in Join
FPDoc Onlineexperiment

TFPSubtractOperation class

In unit fpExprPars

Internally used class for subtraction operations

Declaration

pascal
TFPSubtractOperation = class(TMathOperation)

Inheritance

  1. TFPSubtractOperation
  2. TMathOperation
  3. TFPBinaryOperation
  4. TFPExprNode
  5. TObject

Description

The TFPSubtractOperation class implements the subtraction operation between two numeric operands. It extends the binary operation framework to provide subtraction-specific functionality for integers, floats, and currency values.

The operation handles type conversion automatically when operands have different numeric types, promoting the result to the more precise type as needed. The result type follows standard numeric promotion rules.

The subtraction operation computes the difference between the left operand (minuend) and the right operand (subtrahend), returning left - right.

This class is used internally by the TFPExpressionParser class to construct an AST (Abstract Syntax Tree). There is normally no need for you to use or instantiate this class directly.

See also

Methods

CheckpublicValidate the subtraction operation for correctness
GetNodeValuepublicCalculate the result of subtraction operation
AsStringpublicGet string representation of subtraction operation

Inherited

From TMathOperation (1)

NodeType

From TFPBinaryOperation (8)

CheckSameNodeTypes Create Destroy HasAggregate InitAggregate left Right UpdateAggregate

From TFPExprNode (3)

CheckNodeType IsAggregate NodeValue

From TObject (40)

AfterConstruction BeforeDestruction CheckDisposed ClassInfo ClassName ClassNameIs ClassParent ClassType CleanupInstance DefaultHandler DefaultHandlerStr Dispatch DispatchStr Disposed DisposeOf Equals FieldAddress Free FreeInstance GetDisposed GetHashCode GetInterface GetInterfaceByStr GetInterfaceEntry GetInterfaceEntryByStr GetInterfaceTable GetInterfaceWeak GetLastCastErrorInfo InheritsFrom InitInstance InstanceSize MethodAddress MethodName newinstance QualifiedClassName SafeCallException StringMessageTable SystemHasExtendedRTTI ToString UnitName

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.