The Daily WTF: Curious Perversions in Information Technology
Welcome to TDWTF Forums Sign in | Join | Help
in Search

All tags need to be closed

Last post 07-14-2008 4:54 PM by Renan "C#" Sousa. 26 replies.
Page 1 of 1 (27 items)
Sort Posts: Previous Next
  • 07-11-2008 12:27 PM

    • movzx
    • Not Ranked
    • Joined on 07-11-2008
    • Posts 40

    All tags need to be closed

    I was checking out some random tutorials, and found this little nugget. I think someone is a tad bit confused about how things work in C/C++.

     #include <shellapi.h></shellapi.h>

  • 07-11-2008 12:43 PM In reply to

    Re: All tags need to be closed

     I know nothing whatsoever about programming, and even my eyes are watering in sympathy here. I mean, who's the guy around here who says 'Nuke it from orbit!" about pretty much anything that sucks, and can I borrow his catchphrase?

    You can never have too much time, luck, shelf space or spare duct tape.
  • 07-11-2008 12:49 PM In reply to

    Re: All tags need to be closed

    Wow.

    Just... Wow.
    - Dan
  • 07-11-2008 1:15 PM In reply to

    Re: All tags need to be closed

    Please tell me someone accidentially put that file through some sort of XML cleanup program... 

  • 07-11-2008 1:31 PM In reply to

    • Zecc
    • Top 50 Contributor
    • Joined on 06-12-2007
    • Location, Location, Location
    • Posts 653

    Re: All tags need to be closed

    And this, gentlemen, is the true meaning of WTF.
    If mixed metaphors were illegal, I'd be having an indigestion.
    typeof NaN == 'number'
  • 07-11-2008 1:33 PM In reply to

    Re: All tags need to be closed

    What's next, if (i &gt; 0) ?

  • 07-11-2008 1:34 PM In reply to

    Re: All tags need to be closed

    Does that actually compile? 

  • 07-11-2008 1:56 PM In reply to

    Re: All tags need to be closed

     warning: extra tokens at end of #include directive

     

    Otherwise, it compiles and runs in g++. 

  • 07-11-2008 2:03 PM In reply to

    Re: All tags need to be closed

    movzx:

     #include <shellapi.h></shellapi.h>

    The very best wtf's truly don't really require a long explanation.

     O...M...G...

     

    If you must burn our flag, please wrap yourself in it first!
  • 07-11-2008 2:56 PM In reply to

    Re: All tags need to be closed

    Google led me to Tomy Chen's blog, which unfortunately confirms this wasn't a one-time mistake

    #include "stdafx.h"
    #include <shellapi.h></shellapi.h>
    #include <stdio.h></stdio.h>


  • 07-11-2008 3:29 PM In reply to

    Re: All tags need to be closed

    believe it or not, I think that somebody has a screwed up stylesheet generating the webpage and a validator added the ending tags.

  • 07-11-2008 3:34 PM In reply to

    Re: All tags need to be closed

    billhead:

    Google led me to Tomy Chen's blog, which unfortunately confirms this wasn't a one-time mistake

    #include "stdafx.h"
    #include <shellapi.h></shellapi.h>
    #include <stdio.h></stdio.h>


    So that's how Chinese C/C++ is different than the English one. (Just kidding)
    : IF` 0=GOTO` ORIG ;
    : THEN` HERE SWAP ! ;
    : ELSE` GOTO` ORIG SWAP THEN` ;


    gopher://zzo38computer.cjb.net/
  • 07-11-2008 3:38 PM In reply to

    Re: All tags need to be closed

     mmm... so I was reading through that paula thread, and the last page or so of comments appears to have been linkbotted.

    Is there a way to easily report that abuse?

     -MBirchmeier

  • 07-11-2008 4:15 PM In reply to

    Re: All tags need to be closed

    MBirchmeier:
    Is there a way to easily report that abuse?
    Check the link at the bottom right corner of these posts .. the that says "report abuse" Feel free to use it :D
  • 07-11-2008 4:35 PM In reply to

    Re: All tags need to be closed

    OzPeter:
    MBirchmeier:
    Is there a way to easily report that abuse?
    Check the link at the bottom right corner of these posts .. the that says "report abuse" Feel free to use it :D
     

    The one that doesn't exist in front page comments you mean?

  • 07-11-2008 6:57 PM In reply to

    Re: All tags need to be closed

    This HAS to be a misguided auto-formatter. The rest of the code there is too sane to have been written by someone who would write that atrocity.
  • 07-11-2008 9:48 PM In reply to

    • Spartan
    • Not Ranked
    • Joined on 04-11-2008
    • Lansing
    • Posts 2

    Re: All tags need to be closed

    Simply clbuttic!!

    There are 10 types of people. Those who read binary and those who don't.
  • 07-12-2008 3:47 AM In reply to

    Re: All tags need to be closed

     How the fuck do you screw up <stdio.h> and such O_O;

     

    Even copy and paste code should have that right.

     

    I'm not sure what the bigger WTF is; that horrible horrible include exists, or it compiles ....

    TDWTF Forum Moderator
  • 07-12-2008 8:09 AM In reply to

    • WWWWolf
    • Top 150 Contributor
    • Joined on 12-05-2005
    • Oulu, Finland
    • Posts 244

    Re: All tags need to be closed

    movzx:

     #include <shellapi.h></shellapi.h>

    Well, still much better than the tutorials that just seem to have "#include", until you happen to look at the page source code.

    mysql> help contents;

    Nothing found
    Please try to run 'help contents' for a list of all accessible topics

    Desktop Search Rain - Gothic Computing's EASY button

    (Go wild^H^H^H^H figure)
  • 07-12-2008 9:24 AM In reply to

    • TGV
    • Top 200 Contributor
    • Joined on 10-09-2005
    • Posts 165

    Re: All tags need to be closed

    Take a look here: http://www.shield.on.ca/Blog/?p=105 There you'll find the same thing, but it also has does strange things to the ampersand. However, I don't understand why, since the tags are clearly not part of the HTML/whatever code.

  • 07-12-2008 10:59 AM In reply to

    • rbowes
    • Top 75 Contributor
    • Joined on 02-08-2007
    • Winnipeg, MB
    • Posts 412

    Re: All tags need to be closed

    Ah, I get the joke. It's supposed to be this, right?

    #include <shellapi.h />

  • 07-12-2008 1:49 PM In reply to

    • ariel
    • Not Ranked
    • Joined on 10-04-2006
    • Posts 3

    Re: All tags need to be closed

     They are both using some html code colorizer that is obviously overzealously closing tags.

  • 07-13-2008 1:26 AM In reply to

    Re: All tags need to be closed

    rbowes:

    Ah, I get the joke. It's supposed to be this, right?

    #include <shellapi.h />

     

    The most correct application would be:

    <includes>
        <include name="shellapi.h" />
    </includes>

    ;)

  • 07-13-2008 3:49 AM In reply to

    Re: All tags need to be closed

    Soviut:
    The most correct application would be:

    <includes>
        <include name="shellapi.h" />
    </includes>

    I disagree. The usage of attributes for content is becoming deprecated. Attributes should be descriptive of the content within the tag.

    More Correct Example:
    <?xml version="1.0" encoding="UTF-8"?>
    <includes xmlns="http://forums.thedailywtf.com/xml/includes">
    <include type="header">shellapi.h</include>
    </includes>
  • 07-13-2008 8:00 AM In reply to

    Re: All tags need to be closed

    joe.edwards:
    More Correct Example:
    <?xml version="1.0" encoding="UTF-8"?>

    <includes xmlns="http://forums.thedailywtf.com/xml/includes">
    <include type="header">shellapi.h</include>
    </includes>

     

    Ah, ah, but this doesn't even has a schema... how are you supposed to validate it?

    Also, in case you wanted to extend the "type" attribute, how would you avoid name collisions?

    Obviously, the correct example is:

    <includes
         xmlns = "http://forums.thedailywtf.com/xml/includes"
         xmlns:cinc = "
    http://forums.thedailywtf.com/xml/C-include-types"
         xmlns:xsi
    = "http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation = "http://forums.thedailywtf.com/xml/includes http://forums.thedailywtf.com/xml/includes.xsd"
    >
      <include type="cinc:header">shellapi.h</include>
    </includes>

  • 07-14-2008 3:04 PM In reply to

    Re: All tags need to be closed

    PSWorx:

    joe.edwards:
    More Correct Example:
    <?xml version="1.0" encoding="UTF-8"?>

    <includes xmlns="http://forums.thedailywtf.com/xml/includes">
    <include type="header">shellapi.h</include>
    </includes>

     

    Ah, ah, but this doesn't even has a schema... how are you supposed to validate it?

    Also, in case you wanted to extend the "type" attribute, how would you avoid name collisions?

    Obviously, the correct example is:

    <includes
         xmlns = "http://forums.thedailywtf.com/xml/includes"
         xmlns:cinc = "
    http://forums.thedailywtf.com/xml/C-include-types"
         xmlns:xsi
    = "http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation = "http://forums.thedailywtf.com/xml/includes http://forums.thedailywtf.com/xml/includes.xsd"
    >
      <include type="cinc:header">shellapi.h</include>
    </includes>

    O...M...G...

    I think you just invented ... ACAX.

  • 07-14-2008 4:54 PM In reply to

    Re: All tags need to be closed

    Nice, all it needs now is a header saying whether it's UTF-8, UTF-32 or some other encoding.

    edit: missed it from a previous post XD

    snoofle

    That hideousness is what keeps you and I [sic] employed!
    cconroy
    Renan "C#" Sousa
    You engineer types and your exxageration on accuracy... Can't we just call that one fuckload of snow and be done with it?
    Depends. Is that an imperial fuckload or a metric one?
Page 1 of 1 (27 items)
Powered by Community Server (Non-Commercial Edition), by Telligent Systems