|
83 | 83 | 'char': 'c', # char
|
84 | 84 | }
|
85 | 85 |
|
86 |
| -iso_c2py_map = { |
87 |
| - 'int': 'int', |
88 |
| - 'short int': 'int', # forced casting |
89 |
| - 'long': 'int', |
90 |
| - 'long long': 'long', |
91 |
| - 'signed char': 'int', # forced casting |
92 |
| - 'size_t': 'int', # approx Python int |
93 |
| - 'int8_t': 'int', # forced casting |
94 |
| - 'int16_t': 'int', # forced casting |
95 |
| - 'int32_t': 'int', |
96 |
| - 'int64_t': 'long', |
97 |
| - 'int_least8_t': 'int', # forced casting |
98 |
| - 'int_least16_t': 'int', # forced casting |
99 |
| - 'int_least32_t': 'int', |
100 |
| - 'int_least64_t': 'long', |
101 |
| - 'int_fast8_t': 'int', # forced casting |
102 |
| - 'int_fast16_t': 'int', # forced casting |
103 |
| - 'int_fast32_t': 'int', |
104 |
| - 'int_fast64_t': 'long', |
105 |
| - 'intmax_t': 'long', |
106 |
| - 'intptr_t': 'long', |
107 |
| - 'ptrdiff_t': 'long', |
108 |
| - 'float': 'float', |
109 |
| - 'double': 'float', # forced casting |
110 |
| - 'long double': 'float', # forced casting |
111 |
| - 'float _Complex': 'complex', # forced casting |
112 |
| - 'double _Complex': 'complex', |
113 |
| - 'long double _Complex': 'complex', # forced casting |
114 |
| - '_Bool': 'bool', |
115 |
| - 'char': 'bytes', # approx Python bytes |
116 |
| -} |
| 86 | +# TODO: At some point these should be included, but then they'd need special |
| 87 | +# handling in cfuncs.py e.g. needs[int64_t_from_pyobj] These are not very hard |
| 88 | +# to add, since they all derive from the base `int_from_pyobj`, e.g. the way |
| 89 | +# `short_from_pyobj` and others do |
| 90 | +iso_c2py_map = {} |
| 91 | +# iso_c2py_map = { |
| 92 | +# 'int': 'int', |
| 93 | +# 'short int': 'int', # forced casting |
| 94 | +# 'long': 'int', |
| 95 | +# 'long long': 'long', |
| 96 | +# 'signed char': 'int', # forced casting |
| 97 | +# 'size_t': 'int', # approx Python int |
| 98 | +# 'int8_t': 'int', # forced casting |
| 99 | +# 'int16_t': 'int', # forced casting |
| 100 | +# 'int32_t': 'int', |
| 101 | +# 'int64_t': 'long', |
| 102 | +# 'int_least8_t': 'int', # forced casting |
| 103 | +# 'int_least16_t': 'int', # forced casting |
| 104 | +# 'int_least32_t': 'int', |
| 105 | +# 'int_least64_t': 'long', |
| 106 | +# 'int_fast8_t': 'int', # forced casting |
| 107 | +# 'int_fast16_t': 'int', # forced casting |
| 108 | +# 'int_fast32_t': 'int', |
| 109 | +# 'int_fast64_t': 'long', |
| 110 | +# 'intmax_t': 'long', |
| 111 | +# 'intptr_t': 'long', |
| 112 | +# 'ptrdiff_t': 'long', |
| 113 | +# 'float': 'float', |
| 114 | +# 'double': 'float', # forced casting |
| 115 | +# 'long double': 'float', # forced casting |
| 116 | +# 'float _Complex': 'complex', # forced casting |
| 117 | +# 'double _Complex': 'complex', |
| 118 | +# 'long double _Complex': 'complex', # forced casting |
| 119 | +# '_Bool': 'bool', |
| 120 | +# 'char': 'bytes', # approx Python bytes |
| 121 | +# } |
117 | 122 |
|
118 | 123 | isoc_kindmap = {}
|
119 | 124 | for fortran_type, c_type_dict in iso_c_binding_map.items():
|
|
0 commit comments