Get the result type for conditional operation
Source position: fpexprpars.pp line 270
public function TIfOperation.NodeType: TResultType; override; |
Returns the result type of the conditional
The NodeType method determines and returns the result type for the conditional operation based on the types of the then-branch and else-branch expressions. The result type is typically the common type that both branches can be converted to.
The method analyzes both branch expressions to determine a compatible result type that can accommodate values from either branch, ensuring type safety in conditional expressions.