Hacker News new | past | comments | ask | show | jobs | submit | catlifeonmars's comments login

Conversely, reading through my own code from ancient history (>3 months ago) is both humbling and terrifying :D

This happens to me all the time, but mostly with work code.

I'm under pressure, I have to deliver, things get rewritten many times, edge cases are found and fixed in production after they slipped through multiple qas but need to be fixed instantly or we lose money.

It happens.

But personal code? I am almost always proud of my work. It shows in general I was not under pressure and enjoying building it.

Even my code from the first year of programming, it shows it was made to make a point in writing a nice solution.

I may cringe at times, but still proud.

Context does matter, and code quality is more often than not a byproduct of our emotional state rather than skills.


Like a shiny coat of paint that blinds me, I scrape my code and write new in place, maybe this time with comments so I don't forget.

I feel very similarly about the split between my professional and personal code.

Theres always something that needs to be rushed out the door at work and honestly nobody pays me for pretty code.

But my own projects? The code is a large part of why I do it .


It's often "What was I thinking" or "What was I on" as Kernighan's Law bites you again.

What was surprising to me here is that two threads share the same stack. Is this a rust thing or is this common in programming languages?

This is about “stack”, the general purpose data structure, not “stack”, the place in memory you put local variables.

One reason to stick to a restricted naming scheme for tables is that table names cannot be parametrized. This means you need to implement escaping manually in tools/scripts where table names are not hardcoded. Snake casing creates word boundaries that do not rely on casing and thus do not need to be quoted, there for your manual escaping/sanitization is greatly simplified (lowercase ascii characters, numbers and underscore). I’ve found this reduces the number of footguns by one in databases maintained by a team with varying degrees of familiarity with RDBMS.

FWIW I think we need both? Agree that the latter is severely lacking in the US.

And maybe in some distant future post-scarcity society we would not have a need for a savings scheme.


This is also very relevant for cryptography use cases, where branching is a potential side channel for leaking secret information.

Why would you use ChatGPT to draw diagrams? It’s a generative language model. Just because you can doesn’t mean it’s the best tool for the job.

Why not include some suggested tools in your comment? "you are an idiot for using ChatGPT" (paraphrased) isn't very helpful.

What’s a giggle test?

One of the fun things with SEI Capability Maturity Model is that you reach level 1 just by having your process written down at all, no matter how stupid it sounds.

But the giggle test is just something I borrowed from business, which is, “can I say this with a straight face?” Which eliminates a lot more censorious than you would think. Writing something down is one thing, making eye contact with someone while repeating it is a bit harder.


What’s a censorious as a noun? Hadn’t heard it used that way before.

censorious appears to mean 'severely critical of others'. I expect they meant 'censoriously', with the full intent being that the embarrassment felt by the critical reactions of others when reading the instructions out loud will cause you to eliminate or fix obviously broken, complex or tedious processes that you had, until then, just quietly been putting up with.

I suspect they meant “scenario”.

Yeah that’s an autocomplete bug I didn’t catch until edits timed out. Thats “scenarios”.

hah ok thanks

I like it because it’s really easy to extend the editor with custom language support/tooling if you know JavaScript/Typescript. Providing custom completions, diagnostics, etcetera. I can also provide custom Go to definitions for cross-language support.

I think that’s part of the authors point. The article starts out by explaining a human phenomenon and then extending it to LLMs

Humans only failed to spot it when prompted in a way that was misdirective, though.

True. What I think is missing (and probably the more interesting question) is an analysis on _why_ LLMs failed to spot it. I imagine it has something to do with the model architecture.

Ah because there is no way to express E1 | E2 as a type parameter?

Yeah. Ironically the JLS includes a complete specification of what the type E1|E2 is, because if you write a catch block that catches both then that's the type of what you catch, there's just no syntax for it.

Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: