Re:We need visual programming. No, not like that
by DixieDev on Monday July 15, 2024 @05:43AM
(#40966430)
I would like to see improvements in the speed of feedback - particularly from language servers - but the value of those 'basic' guarantees is more than worth the current cost. Unexpected side effects are responsible for almost every trip I've taken with a debugger in any large Java or C++ project I've ever worked on.
Re:We need visual programming. No, not like that
by arethuza on Monday July 15, 2024 @05:46AM
(#40966448)
I can remember about 20 years ago a colleague getting quite frustrated that a bug he had been looking at for quite a long time came down to someone doing something bizarre in an overloaded assignment operator in C++.
Re:We need visual programming. No, not like that
by guappa on Monday July 15, 2024 @06:44AM
(#40966678)
I've seen methods with names like "get_value()" have extensive side effects.
No type system can fix bad programming.
Re:We need visual programming. No, not like that
by arethuza on Monday July 15, 2024 @06:55AM
(#40966724)
Of course I think we have all seen horrors like that - what I remember was his completely exasperated response not the technical details of the bug.
Re:We need visual programming. No, not like that
by pastage on Monday July 15, 2024 @07:31AM
(#40966884)
Complexity is mostly exponentiellt worse in the unknowns and you can not graph what you already know.
The point in the article is that when we read code we need another visualization to change or mental model. I can scan code and find most bugs fast, but when you are stuck a complexity by row/column sure would be handy to find overloaded assignments.
Re:We need visual programming. No, not like that
by k__ on Monday July 15, 2024 @05:46AM
(#40966449)
Fair.
However, most people are using stuff like JS and Python. For them even the non-dependent type systems are an improvement.
Re:We need visual programming. No, not like that
by dahauns on Monday July 15, 2024 @09:00AM
(#40967485)
I agree that one should refrain from ever using "guarantee correctness" in context of type systems outside of Coq & co. But "extremely basic properties" is IMO similarly exaggerating in the other direction.
Take the "basic" property "cannot be null" for example - Considering the issues and costs the lack of that one incurred over the decades, I'd call that one damn interesting.
And Rust? C'mon, its affine type system is its biggest raison d'etre.
Re:We need visual programming. No, not like that
by RHSeeger on Monday July 15, 2024 @10:42AM
(#40968296)
You're missing the most basic utility they provide... that of making sure other code is calling the function with the right types of arguments. That's a lot of coverage over a language without a compile type checked type system.
Re:We need visual programming. No, not like that
by tsimionescu on Monday July 15, 2024 @12:24PM
(#40969241)
That's not a utility in itself, it depends on what the types represent to know if this is a useful property or not. For example, a Cfunction which is declared as "void foo(int a)" does ensure that it's called with an int, but if it's body then does "100/a", calling it as foo(0) is allowed by the compiler but will fail at runtime. It's true that that the equivalent Python function (def foo(a)) can fail at runtime when called as foo(0), but also foo("ABC"), but it's a matter of degrees, not kind.
For any more interesting properties (say "this function returns a sorted version of the input list", or "this function finds the smallest element in the set", or "this transaction is atomic"), you need something like dependent types, and that comes with a hell of a lot more work.