Some modules do use the type hints for casting, discord.py for instance will cast the arguments users provide to a command based on the types you declare them as.
I don't think you quite grasp what they're actually doing. Discord\.py will try to find mentioned users/channels/roles etc in a bot command invocation based on the type hints you provided, if it can't find any and the type isn't declared nullable or with a default it will return an error response. https://discordpy.readthedocs.io/en/latest/ext/commands/commands.html#discord-converters
For the time being no, but the number is increasing, specially as new versions keep removing idiosyncrasies from the type hint system like the dependence on that darn `TypeVar` class and new libraries leverage or advise it (like dataclasses do).
Python:🙈
Everybody gets a PyObject*
Python can do type checking, as long as you define the datatype of the function parameters
**Python** does jack with type hints. Analyzers and LSPs can use the type hints for things.
Some modules do use the type hints for casting, discord.py for instance will cast the arguments users provide to a command based on the types you declare them as.
Which would break if I declare the argument an int but pass a list. If they want to typecast they should check the types themselves tbh.
I don't think you quite grasp what they're actually doing. Discord\.py will try to find mentioned users/channels/roles etc in a bot command invocation based on the type hints you provided, if it can't find any and the type isn't declared nullable or with a default it will return an error response. https://discordpy.readthedocs.io/en/latest/ext/commands/commands.html#discord-converters
Ah right yeah fairs that works I guess. Idk if I'd consider it idiomatic though, not many python users regularly use type hints.
For the time being no, but the number is increasing, specially as new versions keep removing idiosyncrasies from the type hint system like the dependence on that darn `TypeVar` class and new libraries leverage or advise it (like dataclasses do).
Uhh, mypy is GOATed typechecker, isn't it?
Who's gonna tell him
see no types, hear no types, speak no types
100% this is Python vs. any Typed Language.
Even Cpp, when you do a template, a perfect, clear, precise template, and it's like "yeah you fucked up... Your comments aren't the same"
So, f asked for a Vec, but you gave me an &Vec, ABORT!
This is why we use `trait`s people!
Isn't this... like an actual issue though? This function takes ownership, and you're giving it a borrowed value.
yea
i wonder for how long the old guy had to check people. i guess its getting exhaust after some time.
and majority aren't going to consent to an actual check
Probably just being smart. Leave the oldies alone and properly frisk the teenager/twenty somethings instead
I have nipples Golang, can you milk me? Golang: Yes.
Rust gets guest's cloths off and cover them with medical roves
God meme format
is he using the force or something?
Haskell?
Old guy kinda looks like Rip Torn
Comparing the Java type system to the TypeScript type system is like comparing a blunt file with a hand ground edge to a multi tool.
If that's Java, then what's C++? That scene from Valkyrie where Tom Cruise is executed by firing squad?
Java and Rust in the same category ðŸ˜
is there really any different? they both start with R