This Slashdot article



  • @Maciejasjmj said:

    @joe.edwards said:

    Edit: except for C++ because C++ is a shitty language

    In practice, many C implementations recognize, for example, #pragma once as a rough equivalent of #include guards — but GCC 1.17, upon finding a #pragma directive, would instead attempt to launch commonly distributed Unix games such as NetHack and Rogue, or start Emacs running a simulation of the Towers of Hanoi.[7]

    Fuck. And people ask me why I started to hate open source.

    Yeah, it's not like Microsoft ever added a feature for laughs!



  • @Ben L. said:

    Yeah, it's not like Microsoft ever added a feature for laughs!
    "Microsoft formally stopped including Easter eggs in its programs as part of its Trustworthy Computing Initiative in 2002"

    Yeah, so let's criticize them for something they stopped doing 12 years ago.

     



  • @Ben L. said:

    @Maciejasjmj said:
    @joe.edwards said:

    Edit: except for C++ because C++ is a shitty language

    In practice, many C implementations recognize, for example, #pragma once as a rough equivalent of #include guards — but GCC 1.17, upon finding a #pragma directive, would instead attempt to launch commonly distributed Unix games such as NetHack and Rogue, or start Emacs running a simulation of the Towers of Hanoi.[7]

    Fuck. And people ask me why I started to hate open source.

    Yeah, it's not like Microsoft ever added a feature for laughs!

    It's not like it's even an easter egg. An easter egg is a joke that's somewhat hidden and usually you won't encounter it during normal use of the program.

    Plus, there's the fact that people actually use #pragmas in their source. And GCC developers decided that instead of warning the user that the pragmas won't work, or breaking the build with an actual explanation, they're going to stick a fat middle finger up the asses of everyone who's compiling sources made for another compiler.

    Imagine if MS pulled shit like that in VS. Everybody and their mother would bash them senselessly for doing something that senseless. But GCC team apparently can get away with this, because oh, they're so wacky open-sourcey funny guys.


  • Discourse touched me in a no-no place

    @Maciejasjmj said:

    But GCC team apparently can get away with this, because oh, they're so wacky open-sourcey funny guys.
    No, it's because they're socialists. “cccp.c”? It's a dead cert! We need to make a time machine so we can get that file called “usa!usa!usa!.c” from the very beginning



  • @Maciejasjmj said:

    @Ben L. said:
    @Maciejasjmj said:
    @joe.edwards said:

    Edit: except for C++ because C++ is a shitty language

    In practice, many C implementations recognize, for example, #pragma once as a rough equivalent of #include guards — but GCC 1.17, upon finding a #pragma directive, would instead attempt to launch commonly distributed Unix games such as NetHack and Rogue, or start Emacs running a simulation of the Towers of Hanoi.[7]

    Fuck. And people ask me why I started to hate open source.

    Yeah, it's not like Microsoft ever added a feature for laughs!

    It's not like it's even an easter egg. An easter egg is a joke that's somewhat hidden and usually you won't encounter it during normal use of the program.

    Plus, there's the fact that people actually use #pragmas in their source. And GCC developers decided that instead of warning the user that the pragmas won't work, or breaking the build with an actual explanation, they're going to stick a fat middle finger up the asses of everyone who's compiling sources made for another compiler.

    Imagine if MS pulled shit like that in VS. Everybody and their mother would bash them senselessly for doing something that senseless. But GCC team apparently can get away with this, because oh, they're so wacky open-sourcey funny guys.

    @TFA said:

    Compiler easter eggs[edit]

    In some languages (including C), even the compiler is not bound to behave in a sensible manner once undefined behavior has been invoked. One instance of undefined behavior acting as an Easter egg is the behavior of early versions of the GCC C compiler when given a program containing the #pragma directive, which has implementation-defined behavior according to the C standard. In practice, many C implementations recognize, for example, #pragma once as a rough equivalent of #include guards — but GCC 1.17, upon finding a #pragma directive, would instead attempt to launch commonly distributed Unix games such as NetHack and Rogue, or start Emacs running a simulation of the Towers of Hanoi.[7]

    By the way, GCC 1.17 is from January 9, 1988. Visual Studio wasn't invented yet that decade.



  • By the way, GCC 1.17 is from January 9, 1988. Visual Studio wasn't invented yet that decade.

    Lucky for them. It doesn't make the decision any less moronic, though - only luckily irrelevant. And ignoring pragmas and using language extensions for stuff thatpragmas were specifically designed for is still stupid.



  • @Maciejasjmj said:

    By the way, GCC 1.17 is from January 9, 1988. Visual Studio wasn't invented yet that decade.

    Lucky for them. It doesn't make the decision any less moronic, though - only luckily irrelevant. And ignoring pragmas and using language extensions for stuff thatpragmas were specifically designed for is still stupid.

    Yes, they should have one the M$ or Apple route, just quietly not supporting it, stating that it's non compliant.



  • @DrakeSmith said:

    @Maciejasjmj said:
    By the way, GCC 1.17 is from January 9, 1988. Visual Studio wasn't invented yet that decade.

    Lucky for them. It doesn't make the decision any less moronic, though - only luckily irrelevant. And ignoring pragmas and using language extensions for stuff thatpragmas were specifically designed for is still stupid.

    Yes, they should have one the M$ or Apple route, just quietly not supporting it, stating that it's non compliant.

    The Microsoft route is more "Oh, you have a feature? Well here's a slightly different feature that is incompatible but has the same name."

    The Apple route is "Oh, you have a feature? Well here's the same feature, but it has a picture of a fruit so it's worth $1000 more."



  • @DrakeSmith said:

    @Maciejasjmj said:
    By the way, GCC 1.17 is from January 9, 1988. Visual Studio wasn't invented yet that decade.

    Lucky for them. It doesn't make the decision any less moronic, though - only luckily irrelevant. And ignoring pragmas and using language extensions for stuff thatpragmas were specifically designed for is still stupid.

    Yes, they should have one the M$ or Apple route, just quietly not supporting it, stating that it's non compliant.

    What? I don't know about Apple (I thought they used GCC), but AFAIK, Microsoft's compiler is the only one I know that actually supports pragmas (NVCC also has #pragma unroll, but its kernel syntax is still a IntelliSense-breaking language extension)

    Actually, language extensions are a clusterfuck (here's a standard, and aside from that your compiler can do whatever the fuck it wants if it puts underscores in the right places), pragmas are a clusterfuck (you shouldn't rely on undefined behaviour - here, have a feature that's undefined behaviour* by design), C++ is a clusterfuck (for actually having a half-baked standard that basically means your program is non-portable between compilers if you so much as use an int).

    *technically implementation-defined, but if your language standard has 3 varying degrees of nasal demons, you're doing something wrong anyway



  • @Ben L. said:

    @DrakeSmith said:
    @Maciejasjmj said:
    By the way, GCC 1.17 is from January 9, 1988. Visual Studio wasn't invented yet that decade.

    Lucky for them. It doesn't make the decision any less moronic, though - only luckily irrelevant. And ignoring pragmas and using language extensions for stuff thatpragmas were specifically designed for is still stupid.

    Yes, they should have one the M$ or Apple route, just quietly not supporting it, stating that it's non compliant.

    The Microsoft route is more "Oh, you have a feature? Well here's a slightly different feature that is incompatible but has the same name."

    The Apple route is "Oh, you have a feature? Well here's the same feature, but it has a picture of a fruit so it's worth $1000 more."

    Ha! Couldn't have set it better myself.

    gcc provided a little inside joke using undefined behavior, while Apple's inside joke is the price, made possible by sheeple behavior.


Log in to reply