diff options
Diffstat (limited to 'manual')
-rw-r--r-- | manual/manual.of | 21 |
1 files changed, 9 insertions, 12 deletions
diff --git a/manual/manual.of b/manual/manual.of index 5a8b1b2c..47a551bf 100644 --- a/manual/manual.of +++ b/manual/manual.of | |||
@@ -474,17 +474,7 @@ The result of the call is always converted to a boolean. | |||
474 | 474 | ||
475 | @item{@idx{__le}| | 475 | @item{@idx{__le}| |
476 | the less equal (@T{<=}) operation. | 476 | the less equal (@T{<=}) operation. |
477 | Unlike other operations, | 477 | Behavior similar to the less than operation. |
478 | the less-equal operation can use two different events. | ||
479 | First, Lua looks for the @idx{__le} metamethod in both operands, | ||
480 | like in the less than operation. | ||
481 | If it cannot find such a metamethod, | ||
482 | then it will try the @idx{__lt} metamethod, | ||
483 | assuming that @T{a <= b} is equivalent to @T{not (b < a)}. | ||
484 | As with the other comparison operators, | ||
485 | the result is always a boolean. | ||
486 | (This use of the @idx{__lt} event can be removed in future versions; | ||
487 | it is also slower than a real @idx{__le} metamethod.) | ||
488 | } | 478 | } |
489 | 479 | ||
490 | @item{@idx{__index}| | 480 | @item{@idx{__index}| |
@@ -1643,7 +1633,8 @@ all operations @emphx{wrap around}, | |||
1643 | according to the usual rules of two-complement arithmetic. | 1633 | according to the usual rules of two-complement arithmetic. |
1644 | (In other words, | 1634 | (In other words, |
1645 | they return the unique representable integer | 1635 | they return the unique representable integer |
1646 | that is equal modulo @M{2@sp{64}} to the mathematical result.) | 1636 | that is equal modulo @M{2@sp{n}} to the mathematical result, |
1637 | where @M{n} is the number of bits of the integer type.) | ||
1647 | } | 1638 | } |
1648 | 1639 | ||
1649 | @sect3{bitwise| @title{Bitwise Operators} | 1640 | @sect3{bitwise| @title{Bitwise Operators} |
@@ -8537,6 +8528,12 @@ For instance, the result of @T{"1" + "2"} now is an integer, | |||
8537 | not a float. | 8528 | not a float. |
8538 | } | 8529 | } |
8539 | 8530 | ||
8531 | @item{ | ||
8532 | The use of the @idx{__lt} metamethod to emulate @id{__le} | ||
8533 | has been removed. | ||
8534 | When needed, this metamethod must be explicitly defined. | ||
8535 | } | ||
8536 | |||
8540 | } | 8537 | } |
8541 | 8538 | ||
8542 | } | 8539 | } |