Sign in Join
FPDoc Onlineexperiment

VarSameValue function

In unit Variants

Check if 2 variants are the same.

Declaration

pascal
function VarSameValue(const A: Variant; const B: Variant): Boolean

Arguments

A

First variant to compare.

B

Second variant to compare.

Function result

True of both variants are equal.

Description

varSameValue checks whether A and B have the same value. Here empty variants equal empty variants, and null variants equal null variants. For all other cases, the actual values are compared.

Errors

If the variants are of different types and they cannot be converted, an exception will be raised.

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