type: std::bool
[contents]

Contents

Syntax

The syntax for std::bool definitions is:

f++:  
std::bool definitions
std::bool(definitions)
:=(std::bool, definitions)

n++:  
@std::bool definitions
@std::bool(definitions)
@:=(std::bool, definitions)

Note: If you are using the first syntax for variable definitions and want to have more code and/or text following on the same line then simply end the definition with ';'.

Description

The std::bool type is used for boolean values.

Note: ExprTk does not have direct access to variables of type std::bool, if you want the convenience and efficiency of direct access then use bool.

Note: If you need to define thousands of variables then := is faster, plus it has useful error messages for unrecognised types.

Options

The following options are available for std::bool definitions:

option description
const definition of a constant
layer="x" define variable at layer x
private definition of a private
scope+="x" add x to scopes variable can be accessed from
option description

f++ example

Examples of bool being defined with f++:

std::bool a=0, b=1
std::bool(x, y, z)
:=(std::bool, finished = 0)

n++ example

Examples of int being defined with n++:

@std::bool a=0, b=1
@std::bool(x, y, z)
@:=(std::bool, finished = 0)

Sponsors