lysdexic

joined 1 year ago
MODERATOR OF
[–] lysdexic 8 points 1 month ago* (last edited 1 month ago)

Well, auto looks just like var in that regard.

It really isn't. Neither in C# nor in Java. They are just syntactic sugar to avoid redundant type specifications. I mean things like Foo foo = new Foo();. Who gets confused with that?

Why do you think IDEs are able to tell which type a variable is?

Even C# takes a step further and allows developer to omit the constructor with their target-typed new expressions. No one is whining about dynamic types just because the language let's you instantiate an object with Foo foo = new();.

[–] lysdexic 1 points 1 month ago (1 children)

I think I could have states my opinion better. I think LLMs total value remains to be seen. They allow totally incompetent developers to occasionally pass as below average developers.

This is a baseless assertion from your end, and a purely personal one.

My anecdotal evidence is that the best software engineers I know use these tools extensively to get rid of churn and drudge work, and they apply it anywhere and everywhere they can.

[–] lysdexic 1 points 1 month ago

the first thing I saw is 150 lines of C# reimplementing functions available in the .NET standard lib.

Once again: https://en.wikipedia.org/wiki/Dunning%E2%80%93Kruger_effect

[–] lysdexic 2 points 1 month ago (3 children)

They existed before LLMs were spitting code like today, and this will undoubtedly lower the bar for bad developers to enter.

If LLMs allow bad programmers to deliver work with good enough quality to pass themselves off as good programmers, this means LLMs are fantastic value for money.

Also worth noting: programmers do learn by analysing the output of LLMs, just as the programmers of old learned by reading someone else's code.

[–] lysdexic 2 points 1 month ago

Claude is laughable hypersensitive and self-censoring to certain words independently of contexts (...)

That's not a problem, nor Claude's main problem.

Claude's main problem is that it is frequently down, unreliable, and extremely buggy. Overall I think it might be better than ChatGPT and Copilot, but it's simply so unstable it becomes unusable.

[–] lysdexic 0 points 1 month ago* (last edited 1 month ago) (1 children)

I agree. Those who make bold claims like "AI is making programmers worse" neither has any first-hand experience with AI tools nor has any contact with how programmers are using them in their day-to-day business.

Let's think about this for a second: one feature of GitHub Copilot is the /explain command, which is used to put together a synthetic description of what a codebase does. Please someone tell me how a programmer gets worse at their job by having a tool that helps him understand any codebase anywhere.

[–] lysdexic 10 points 1 month ago

C++ continues to be the dumping ground of paradigms and language features. This proposal just aims to add even more to an overloaded language.

I think you could not be more wrong even if you tried, and you clearly did not even read the proposal you're commenting on.

This proposal aims to basically create an entirely different programming language aimed at being easy to integrate in extsting codebases. The language just so happens to share some syntax with C++, but you definitely can't compile it with a C++ compiler because it introduces a series of backwards incompatible changes.

It's also absurd how you complain about introducing new features. Can you point out any language that is not absolutely dead that is not introducing new features with each release?

C++ programmers mocked languages for being dynamically typed then they introduced auto (...)

I'm sorry, you are clearly confused. The auto keyword is not "dynamically typed". It is called "auto" because it does automatic type deduction. It is syntactic sugar to avoid having to explicitly specify the type name in places the compiler knows it already. Do you understand what this means?

Your comment sounds like trolling, frankly.

[–] lysdexic -2 points 1 month ago

I feel like this will have zero protection against

Zero protections against what? Against the programmer telling the program to do something it shouldn't? Not programming language does that. If you resort to this sort of convoluted reasoning, the same hypothetical programmer can also swallow all exceptions.

The main problem you're creating for yourself is that you've been given an open-ended problem but instead prefer to not look for solutions.

[–] lysdexic 1 points 1 month ago (1 children)

Have you ever worked at large old corporation?

I'm not sure you understand that it's way more than "large old corporations" that use it. Everyone uses it, from large multinationals to small one-taxi shops, and even guys like you and me in personal projects. This has been going on for years. I really don't know what led you to talk about large old corporations, seriously.

[–] lysdexic -2 points 1 month ago (5 children)

I mean, yeah, if your language does not support error values, do not use them.

Nonsense. If adopting info of the many libraries already available is not for you, it's trivial to roll your own result type.

Even if that was somehow unexplainably not an option, even the laziest of developers can write a function to return a std::tuple or a std::pair and use structured binding.

[–] lysdexic 3 points 1 month ago

That’s only true in crappy languages that have no concept of async workflows, monads, effects systems, etc.

You don't even need to sit on your ass and wait for these data types to be added to standard libraries. There are countless libraries that support those, and even if that is somehow not an option it's trivial to roll your own.

55
Code Smells Catalog (luzkan.github.io)
submitted 1 month ago by lysdexic to c/programming
11
submitted 1 month ago by lysdexic to c/git
13
submitted 1 month ago by lysdexic to c/cpp
5
Kuth’s Merge Sort in C (www.yodaiken.com)
submitted 1 month ago by lysdexic to c/data_structures
11
submitted 1 month ago by lysdexic to c/ddd
17
submitted 1 month ago by lysdexic to c/webdev
view more: ‹ prev next ›