Skip to content
DevMeme
3363 of 7590
Languages Post #3695 · source on Telegram

C++ Readability vs. Standard Library Hieroglyphics

Description

A two-panel meme contrasting different types of C++ programmers. The top panel is labeled 'Regular C++ programmers' and shows a man with a concerned expression sitting at a computer. A speech bubble from him reads, 'My code needs to be readable or I won't understand it tomorrow...'. The bottom panel, labeled 'C++ Standard lib programmers', shows the same man in the same posture, but his head has been replaced with a grey alien's head. The computer screen in front of him, which was normal before, now displays a block of chaotic, unreadable text resembling Zalgo text or ancient symbols. This meme humorously exaggerates the perceived complexity and inscrutability of C++ Standard Library (STL) code. It plays on the idea that while most developers prioritize writing clear, maintainable code, those who work on the standard library delve into such deep, complex template metaprogramming that their code becomes 'alien' and unreadable to the average programmer

Comments

15
Anonymous ★ Top Pick Some C++ programmers write readable code to solve problems. STL programmers write unreadable code just to see if the compiler's SFINAE implementation starts crying
  1. Anonymous ★ Top Pick

    Some C++ programmers write readable code to solve problems. STL programmers write unreadable code just to see if the compiler's SFINAE implementation starts crying

  2. Anonymous

    Why bother writing docs when the compiler will gladly emit a 500-line template instantiation traceback that doubles as your architecture diagram?

  3. Anonymous

    The STL maintainer who wrote std::enable_if_t<std::is_invocable_v<...>> just got promoted for reducing compile times by 3% while simultaneously making debugging impossible for the next decade of engineers

  4. Anonymous

    The C++ Standard Library: where `std::enable_if_t<std::is_same_v<decltype(std::declval<T>()), U>>` is considered 'self-documenting code' and your future self will need a Rosetta Stone to decipher what you meant by that perfectly cromulent SFINAE expression you wrote at 2 AM

  5. Anonymous

    Std::lib developers don’t write comments; they let two-phase lookup and SFINAE annotate the code as a 900-line compiler error

  6. Anonymous

    STL: where 'readable tomorrow' requires resurrecting the metaprogramming monk who wrote it

  7. Anonymous

    Zero-cost abstractions: the CPU pays nothing; your reviewers, compilers, and 3 a.m. on-call pay the invoice

  8. @nuntikov 4y

    __std_crp_ttl_ra2

    1. @karim_mahyari 4y

      Kind of where nightmares come into existence

  9. @NikoNotANeko 4y

    Когда lorem ipsum folor sit amet

  10. @twisted_by_design 4y

    До сих пор не понимаю зачем у них локальные даже имена переменных с начинаются с __

    1. @p4vook 4y

      Стдлиба должна пережить дефайн

      1. @twisted_by_design 4y

        Да, действительно, чет я тупенький и не додумался, спасибо. Забыл про возможность #define true false и подобного, и чтобы это не ломало стдлиб

    2. @sylfn 4y

      Please use English as a main language in this chat -- add a translation

  11. @twisted_by_design 4y

    No doubt c/cpp will allow you to that :). Theoretically, you can completely write your own preprocessor language dialect with unique constructions & other things, and that's the reason a lot of people like it (incl. me). However, I think we were discussing cases when you don't want absolutely accidentally break things up, not when you're really wishing to shot yourself in the leg

Use J and K for navigation