|
1 | 1 | <!-- |
2 | | -%CopyrightBegin% |
| 2 | +%% %CopyrightBegin% |
| 3 | +%% |
| 4 | +%% SPDX-License-Identifier: Apache-2.0 |
| 5 | +%% |
| 6 | +%% Copyright Ericsson AB 2024-2025. All Rights Reserved. |
| 7 | +%% |
| 8 | +%% Licensed under the Apache License, Version 2.0 (the "License"); |
| 9 | +%% you may not use this file except in compliance with the License. |
| 10 | +%% You may obtain a copy of the License at |
| 11 | +%% |
| 12 | +%% http://www.apache.org/licenses/LICENSE-2.0 |
| 13 | +%% |
| 14 | +%% Unless required by applicable law or agreed to in writing, software |
| 15 | +%% distributed under the License is distributed on an "AS IS" BASIS, |
| 16 | +%% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 17 | +%% See the License for the specific language governing permissions and |
| 18 | +%% limitations under the License. |
| 19 | +%% |
| 20 | +%% %CopyrightEnd% |
| 21 | +--> |
3 | 22 |
|
4 | | -SPDX-License-Identifier: Apache-2.0 |
| 23 | +### Old aliases for type tests in guards |
| 24 | + |
| 25 | +The type test aliases `atom/1`, `binary/1`, `float/1`, `function/1`, |
| 26 | +`integer/1`, `list/1`, `number/1`, `pid/1`, `port/1`, `record/2`, |
| 27 | +`reference/1`, and `tuple/1`, for the respective tests `is_atom/1`, |
| 28 | +`is_binary/1`, `is_float/1`, ..., `is_tuple/2`, have been deprecated since |
| 29 | +before OTP R13 and have been scheduled for removal in OTP 30. Note that |
| 30 | +these aliases could only be used as guard tests at the top level. For |
| 31 | +example, in `{X, Y} when float(X), X =:= float(Y) -> ...` the first use of |
| 32 | +`float/1` is a type test alias, but the second use is the normal |
| 33 | +integer-to-float conversion BIF, because it occurs inside the `=:=`. The |
| 34 | +aliases were never recognized outside guards. |
5 | 35 |
|
6 | | -Copyright Ericsson AB 2025. All Rights Reserved. |
7 | 36 |
|
8 | | -%CopyrightEnd% |
9 | | ---> |
10 | 37 |
|
11 | 38 | ### Distribution Control Messages |
12 | 39 |
|
|
0 commit comments