
Show HN: C++11 port of Postgres - jarulraj
https://github.com/jarulraj/postgresql-cpp
======
andrew3726
Several questions: * Is this a one-man effort (for now at least?) or is this
'official' * Why refactor the increment operator? (s ++ to s = s + 1) * Is
clang supported (or libc++ for example?) * Do you have a roadmap for planned
refactoring?

Interesting project, I wonder about the effort which is required. Even slow
incremental involves breaking interfaces.

~~~
jarulraj
* It is a proof-of-concept implementation to show that porting Postgres over to C++ is feasible with minimal changes. It is not official.

* We need to refactor the increment operator because the variables are of enumeration type.

* We have not yet tested compilation with clang. But, I presume that minimal changes would be required to support compilation with clang. PRs are welcome!

* Not really. Our hope is that the PostgreSQL core team would consider gradually migrating over to C++. I think that this refactoring can be done without breaking external interfaces.

Thanks for the positive feedback.

~~~
andrew3726
> Our hope is that the PostgreSQL core team would consider gradually migrating
> over to C++.

How many are you? I see only commits from you. And did you speak with any of
the pgsql core team yet? Might be worth investigating, whether they even
consider it... I don't see the point, if they don't.

Good luck with they project, might look into it some time soon!

~~~
jarulraj
There is on-going conversation on the pg-hackers mailing list. Thanks for the
positive feedback.

------
fiatjaf
It's dissapointing it is not in Javascript.

~~~
jarulraj
Whoa, why would you do that ?

~~~
fiatjaf
Just kidding.

But it would work in the browser!

------
borplk
I'm ignorant, what's the benefit of it?

~~~
jarulraj
Certain features of the C++ language and its library should help simplify
coding, improve code reuse, and avoid bugs.

Here's a blog post that provides more context:
[https://petereisentraut.blogspot.com/2013/05/moving-
to-c.htm...](https://petereisentraut.blogspot.com/2013/05/moving-to-c.html)

~~~
anarazel
The problem is that the current set of portability targets
([https://www.postgresql.org/docs/devel/static/supported-
platf...](https://www.postgresql.org/docs/devel/static/supported-
platforms.html)) doesn't support a lot of common ground WRT c++ support.
Otherwise I (and some others involved in the project) would have started to
gently push in that direction.

~~~
jarulraj
I see, thanks for sharing this information.

