Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Having to typedef at all is a sign of deep, unfixable badness.


I am unable to reply to my sibling poster, but I believe what you're saying is that having a hideous and unreadable syntax that forces the use of typedefs just so others can understand what you have written is a sign of deep, unfixable badness. And I agree.


I'm not sure how you arrived at that belief, unless perhaps you think everything should be (visibly to the programmer) type-free? Care to elaborate? I think it would be nice if C and C++ supported more type semantics than `typedef` and `class`, say something as powerful as Haskell's system...


It's the fundamental unfixable crappiness of C declaration syntax that makes 'typedef' necessary.


Example? What language doesn't need typedefs?

Java doesn't have typedefs, and most everyone agrees that's a language bug.


typedef as type aliasing: uncontroversial. typedef to paper over hideous syntax mistakes: disgusting.




Consider applying for YC's Fall 2026 batch! Applications are open till July 27.

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

Search: