[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] Reference for unit 'Classes' (#rtl)

TParser.TokenFloat

Returns the current token as a float.

Declaration

Source position: classesh.inc line 1555

public function TParser.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.

Remark:

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

TParser.FloatType

  

The type of a float token.

TParser.NextToken

  

Reads the next token and returns its type.

TParser.Token

  

The type of the current token.

toFloat

  

Value returned by TParser.Token when a floating point value was found in the input stream.


Documentation generated on: Mar 17 2017