News for hackers. Stuff that matters.
Re:Where do argc and argv come from? by loopz on Monday August 10, 2020 @02:30PM (#24112438)
For compiled languages, it's neat to get compiler error instead of a nasty bug.
Re:Where do argc and argv come from? by quietbritishjim on Monday August 10, 2020 @03:33PM (#24113123)
A bug is a problem that affects your users. If you're a library author then your users are developers of applications (and higher-level libraries), so an unintentional breaking change to your API is definitely a bug.
Re:Where do argc and argv come from? by kortilla on Monday August 10, 2020 @03:04PM (#24112817)
In python without explicit analysis using something like pylint you won’t find out until function call time.
Re:Where do argc and argv come from? by Karliss on Monday August 10, 2020 @03:08PM (#24112863)
No compiler in Python. In combination with features like varargs, kwargs, unpacking dictionary into args, argument forwarding Python allows you to turn this into bugs.
Re:Where do argc and argv come from? by senkora on Monday August 10, 2020 @04:59PM (#24113923)
Well, Python does get compiled to bytecode before it is run. And the compiler does tell you about some errors, like inconsistent indentation, even if that code is never executed.