Email or username:

Password:

Forgot your password?
Top-level
DrYak

@mhoye That's indeed a perfect example of PDP-11 concepts leaking into modern coding errors: As I've discussed elsewhere in the thread the main problem is C itself, it's too leaky as an abstraction of assembler, and its type system makes this code perfectly valid (but doesn't do what one think it does).

If one isn't a C guru, it's difficult to track down.

A linter to spot the pattern would have helped.

The "multichar warning" could be a bit more expanded to cover that user error in details.

1 comment
spmatich :blobcoffee:

@dryak @mhoye C is not the problem. Neither is gcc. None of these tools can be unhelpful. Only people can be unhelpful. If you missed the fact that some people created and maintained a free C compiler, you might be tempted to conclude they were being unhelpful, by not anticipating how people new to the language (hello world is for newbies right?) might find its output cryptic. So you are learning a new language and you use Google, which might have a few hits for stack overflow. Again you are learning new tools, which some people have provided free for you.
When C was created the tools were documented on paper. In books. Search was literally an index at the back of the book.
Call me old, but I'm thinking expecting compiler error messages to be appropriate for elementary / beginning users would require (waste) a lot of devs time.
Part of the skill you can be proud of as a dev is understanding not just how to use the tool, but how the tool works. That kind of understanding does not come from search engines.

@dryak @mhoye C is not the problem. Neither is gcc. None of these tools can be unhelpful. Only people can be unhelpful. If you missed the fact that some people created and maintained a free C compiler, you might be tempted to conclude they were being unhelpful, by not anticipating how people new to the language (hello world is for newbies right?) might find its output cryptic. So you are learning a new language and you use Google, which might have a few hits for stack overflow. Again you are learning...

Go Up