Comment

Comment by jrockway

I modified the program so that the main function looks like:

  say = NULL;
  say("OH NOES");
When compiled with all warnings on, there are none. When run, it immediately segfaults. (The same would happen with any assignment from void*, like 'say = malloc(42)'. Nice.)

Edit: I knew this would get downmodded :) Why does any post implying that type safety is good get downmodded?

parent jrockway 17 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton