[Python-ideas] Structural type checking for PEP 484
rymg19 at gmail.com
Thu Sep 17 23:56:33 CEST 2015
Embedding type names in arguments and method names.
On Thu, Sep 17, 2015 at 4:45 PM, Sven R. Kunze <srkunze at mail.de> wrote:
> On 17.09.2015 23:19, Ryan Gonzalez wrote:
>> def process_integer_coordinate_tuples(integer_tuple_1, integer_tuple_2,
>> is_fast): ...
>> def process_coords(t1: Tuple[int, int], t2: Tuple[int, int], fast: bool):
>> Java's fatal mistake.
> Care to elaborate?
> Even good variable names can leave the type ambiguous.
These are names that don't leave anything ambiguous! :D
Really, though: relying on naming to make types explicit fails badly
whenever you start refactoring and makes hell for the users of the API you
[ERROR]: Your autotools build scripts are 200 lines longer than your
program. Something’s wrong.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Python-ideas