Live data from Hacker News

Orthodox C++ (2016)

bkaradzic.github.io

1–10 of 238 posts

Re: Orthodox C++ (2016)

#2
You can take

   for (auto const & ess : esses) {
         ...
   }
from my cold dead hands.

Also, you can fight me if you want to take

      dynamic_cast (base_ptr)
and force me to implement my own typing system every time I need to upcast.

Basically, stick with C and leave C++ programmers alone. I haven't seen a less useful article about C++ in a long time, and as an HN reader, that's really saying something.

Re: Orthodox C++ (2016)

#4
Submitted a fair few times previously. HN's search turned up these submissions with some additional discussion:

https://news.ycombinator.com/item?id=40445536 (2 years ago, 63 points, 66 comments)

https://news.ycombinator.com/item?id=25554018 (5 years ago, 70 points, 102 comments)

https://news.ycombinator.com/item?id=13751244 (9 years ago, 29 points, 14 comments)

Looks like the page was moved from a GitHub gist to a github.io page in October of last year.

Re: Orthodox C++ (2016)

#7
I've developed a style that I legitimately call Heterodox C++ (mainly due to the popularity of Orthodox C++), it is effectively a purely functional & metaprogramming heavy style of C++. Quite the opposite of this, not everyones cup of tea, and it won't fit into every codebase but it is incredibly powerful. The template metaprogramming C++ offers is the most powerful of any imperative language, and (subjective opinion) is second only to Lisp, but few people make use of it. With some of C++26 features you can almost even replicate most of Rusts safety features in pure C++ (via function tagging + reflection)

Re: Orthodox C++ (2016)

#8

You can take for (auto const & ess : esses) { ... } from my cold dead hands. Also, you can fight me if you want to take dynamic_cast (base_ptr) and force me to implement my own typing system every time I need to upcast. Basically, stick with C and leave C++ programmers alone. I haven't seen a less useful article about C++ in a long time, and as an HN reader, that's really saying something.

One thing I've noticed about a lot of these "strict C" developers is that quite often they actually refuse to learn C++. One of the most common complaints of C developers regarding C++ is "it does things behind the scenes/performs magic", often with regards to operator overloading. When they refuse to actually look at the implementation (y'know you can check if an operator has been overloaded) AND they refuse to acknowledge that a huge chunk of "pure C" does HEAPS of magic behind the scenes (that the developer has no idea about) unless they've actually studied the spec in detail. Malloc and memory allocation methods are at least 10k+ lines of code for instance.

Re: Orthodox C++ (2016)

#10
post #7

I've developed a style that I legitimately call Heterodox C++ (mainly due to the popularity of Orthodox C++), it is effectively a purely functional & metaprogramming heavy style of C++. Quite the opposite of this, not everyones cup of tea, and it won't fit into every codebase but it is incredibly powerful. The template metaprogramming C++ offers is the most powerful of any imperative language, and (subjective opinion…

have you written about this anywhere, or hosting any examples?
Post reply on HN