Skip to content

Commit

Permalink
Fix outdated notes in QgsExpression docs
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Feb 14, 2016
1 parent 6453907 commit 85b51fd
Showing 1 changed file with 1 addition and 12 deletions.
13 changes: 1 addition & 12 deletions src/core/qgsexpression.h
Original file line number Diff line number Diff line change
Expand Up @@ -60,13 +60,6 @@ The expressions try to follow both syntax and semantics of SQL expressions.
}
\endcode
Possible QVariant value types:
- invalid (null)
- int
- double
- string
- geometry
Three Value Logic
=================
Expand All @@ -90,15 +83,11 @@ Type conversion
Operators and functions that expect arguments to be of a particular
type automatically convert the arguments to that type, e.g. sin('2.1') will convert
the argument to a double, length(123) will first convert the number to a string.
Explicit conversion can be achieved with toint, toreal, tostring functions.
Explicit conversion can be achieved with to_int, to_real, to_string functions.
If implicit or explicit conversion is invalid, the evaluation returns an error.
Comparison operators do numeric comparison in case both operators are numeric (int/double)
or they can be converted to numeric types.
Arithmetic operators do integer arithmetics if both operands are integer. That is
2+2 yields integer 4, but 2.0+2 returns real number 4.0. There are also two versions of
division and modulo operators: 1.0/2 returns 0.5 while 1/2 returns 0.
Implicit sharing
================
Expand Down

0 comments on commit 85b51fd

Please sign in to comment.