Sign in Join
FPDoc Onlineexperiment

TParser.TokenFloat function

Member of TParserpublicIn unit Classes

Returns the current token as a float.

Declaration

pascal
function TokenFloat: Extended

Description

If current token type is toFloat, this method returns the token value as a float.

To specify a negative number, no space must exist between unary minus and number.

Floating point numbers can be postfixed with a character that specifies the floating point type. See FloatType for further information.

In the input stream the decimal separator, if present, must be a dot (.).

Errors

If Token isn't toFloat, an EParserError exception is raised.

See also

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