Add CInteger trait type
Offen
- Vorherrschende Sprache
- Python
- Sterne
- 653
- Forks
- 217
- Ø Merge
- 2 T. 21 Std.
- Gemergte PRs (30 T.)
- 2
Beschreibung
I think there is a need for a CInteger trait: A trait that converts anything you throw at it into a python integer if possible, without enforcing either `int` or `long` on python 2. In essence, it should simply call `int(value)` for coercion, which under python 2 only produces a `long` where needed. A typical situation is when numpy array scalars are assigned to a trait, which will be rejected by the non-coercing traits.
Beitragsleitfaden
Bewertung
Dieses Issue wurde noch nicht bewertet.