Skip to content

Commit 9212f42

Browse files
EmilyBourneyguclu
andauthored
Deprecate 'real' and 'integer' type annotations (pyccel#1813)
Deprecate 'real' and 'integer' type annotations. Fixes pyccel#1786 --------- Co-authored-by: Yaman Güçlü <[email protected]>
1 parent f657701 commit 9212f42

File tree

3 files changed

+2
-3
lines changed

3 files changed

+2
-3
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ All notable changes to this project will be documented in this file.
4040

4141
### Deprecated
4242

43+
- #1786 : Remove support for `real` and `integer` as type annotations.
4344
- \[INTERNALS\] Remove property `ast.basic.TypedAstNode.precision`.
4445
- \[INTERNALS\] Remove class `ast.datatypes.DataType` (replaced by `ast.datatypes.PrimitiveType` and `ast.datatypes.PyccelType`).
4546
- \[INTERNALS\] Remove unused properties `prefix` and `alias` from `CustomDataType`.

docs/type_annotations.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ For scalar variables Pyccel supports the following data types:
1818

1919
- built-in data types: `bool`, `int`, `float`, `complex`
2020
- NumPy integer types: `int8`, `int16`, `int32`, `int64`
21-
- NumPy real types: `float32`, `float64`, `double`
21+
- NumPy floating point types: `float32`, `float64`, `double`
2222
- NumPy complex types: `complex64`, `complex128`
2323

2424
## NumPy Arrays

pyccel/ast/type_annotations.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -339,10 +339,8 @@ def __eq__(self, o):
339339

340340
typenames_to_dtypes = { 'float' : PythonNativeFloat(),
341341
'double' : PythonNativeFloat(),
342-
'real' : PythonNativeFloat(),
343342
'complex' : PythonNativeComplex(),
344343
'int' : PythonNativeInt(),
345-
'integer' : PythonNativeInt(),
346344
'bool' : PythonNativeBool(),
347345
'b1' : PythonNativeBool(),
348346
'void' : VoidType(),

0 commit comments

Comments
 (0)