Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Basic support for writing extensions in C++ #7

Open
1 task
mkindahl opened this issue Nov 16, 2022 · 0 comments
Open
1 task

Basic support for writing extensions in C++ #7

mkindahl opened this issue Nov 16, 2022 · 0 comments
Labels

Comments

@mkindahl
Copy link
Owner

What

Extensions for PostgreSQL are traditionally written in C, but in some cases you might want to write the extension in C++ but still interface with standard PostgreSQL code. Normally, you can just include the PostgreSQL file wrapped in extern "C", but it can be useful to have some additional tools to make it easy to do some of the work.

The use of setjmp/longjmp for error reporting makes it more complicated to use the full power of C++, but in many cases this is not necessarily a problem. For example, RAII model can be used for cases where functions cannot error out.

How

Some ideas for simplifications that might be useful.

  • C++ iterators for PostgreSQL List type
@mkindahl mkindahl added the Epic label Nov 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant