Hacker News new | past | comments | ask | show | jobs | submit login

For fun, I asked ChatGPT to write code documentation for a small sample class (C# xml docs in this case). It did an incredibly good job at this. I don't really think this type of documentation will be necessary in the future as it can easily be inferred by AI. I think that extends to code comments as well. Perhaps it is too early for such guidance but I suspect over time the pendulum will swing to not documenting / commenting any code which can be inferred from the code itself (even if the code would require considerable concentration to understand).

Of course, it is impossible to infer from the code why something was done so this will always be needed.




Large codebases are always a puzzle. Maybe I should be more plain - large existing codebases usually suck.

I suspect they drag down engineers, and cause them to refactor, or burn out.

But what if something like chatgpt could explain the code to you. If you could ask questions

"does anyone call this function?"

"who calls it, and what do they do with the results?"

"can you call it a million times, fuzz the inputs and see if it crashes?"

"can you replace the bubble sort with qsort?"




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

Search: