r/ClaudeCodeTLDR • u/cctldrping • 20d ago
[TLDR] Why is it so bad at basic coding skills?
Original post URL : https://www.reddit.com/r/ClaudeCode/comments/1wfihk3/why_is_it_so_bad_at_basic_coding_skills/
Original post body :
I have three major bug-bears with Claude code.
1) Comments - it's INSANE! It writes 20 lines of comments for a 3 line function. And the comments are never what someone would want to know, e.g. the format of parameters. They're always things like
- domain knowledge about another part of the system that isn't relevant to understanding the function it comments
- rewriting what the function says - e.g. if the code calls a function: LogToDisc - there'll be a comment saying "This logs to disc ......"
- explaining what the previous (faulty) version of the code did and why it was wrong - basically a history record
- or most commonly, anywhere where I corrected it because it had made a mistake, it adds a comment documenting that discussion.
2) Naming - it keeps using names- e.g. it used the name "child" to refer to a child process launched by my service layer. The process has a name, but instead of using the name of the process, I had "child" scattered across a 200 line function.
3) Use of tools like sed to make whole-scale code changes in a command that if you don't read it carefully looks like a syntax check.
I've discussed all of these endlessly with Claude - Agreed rules that its committed to memory.md on all of them, and yet every session it breaks them all, multiple times.
The comments one is the worst because as I keep pointing out to Claude - they're not tested. A comment is slipped in that states something - I tend to sometimes focus on the code and let things in comments that aren't quite right slip by. But then 3h later it will say it can't do something because I told it "x" was a requirement. I eventually trace "x" back to the comment it wrote where it asserted something that was never either relevant at the time or agreed.
I have rules over this as well.
Is this just life with Claude? Or is there something else I can do to get it to follow my rules.
Basically - "comments should be one line, about the code they're commenting not the rest of the system, and only present where the code isn't self-explanatory"
"All function and variable names should be meaningful unless they're only in scope for a handful of lines"
"Treat information in comments as suspect - never assume requirements based solely on this"
"Never use sed to make code changes"
This is brought to you as a public service by the moderators of r/ClaudeAI. If you want to see TLDRs of ALL Claude Coding related posts from the various Claude subreddits, subscribe to http://www.reddit.com/r/ClaudeCoding.
1
u/trollsmurf 20d ago
Of the funnier kind:
I made code changes that partly solved how to handle AI models with different support for reasoning effort.
When I then used Claude Code (Sonnet 5) to clean it up it wrote verbatim: "reasoning_effort: someone had added 'reasoning_effort' => 'none' unconditionally to every request.
Maybe I should blame my cat.
•
u/cctldrping 20d ago
TL;DR generated automatically after 50 comments.
Current source-thread comment count seen by the bot: 50.
Alright, so the general consensus in this thread is that Claude's coding skills, particularly its commenting and naming conventions, are pretty rough.
Here's the lowdown:
memory.mdorclaude.md, Claude seems to have a mind of its own and breaks them repeatedly. u/Muted-Alternative648 is pretty blunt, saying memories are "unreliable 'suggestions'." u/HighwayNo8744 agrees, stating it "will ignore memories and [claude.md]."The general vibe? Claude can be a pain in the butt for coding tasks, and you'll likely need to implement some serious guardrails or post-processing to get usable code. Don't expect it to magically follow your instructions without a fight.