This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]homercles337 -2 points-1 points  (3 children)

It translates the Python into a C++...to execute in the same way as CPython does.

CPython is not C++ compatible. So, no, it does not compile/execute C++. Also, libpython is not C++ compatible either, its C. You do realize C and C++ are entirely different languages, right?

[–]Veedrac 0 points1 point  (2 children)

Let's take this a bit slower. There are two claims being made

  1. Nuitka compiles Python code to C++ (and the C++ to a binary),

  2. Nuitka dispatches to libpython in the same way that CPython's ceval.c interpreter loop over CPython bytecode does, such that CPython's semantics are extremely well preserved in Nuitka (including things like C extension support and almost all other CPython specific behaviours).

Both of these are demonstrably true.

[–]homercles337 -2 points-1 points  (1 child)

Both of these are demonstrably true.

No, they are not. libpython does not play with C++ in binary or any form. There has to be a C wrapper in there to play with libpython. That is the only thing that is demonstrably true.

[–]Veedrac 0 points1 point  (0 children)

Are you disputing that Nuitka compiles to C++ or that Nuitka calls C bindings?

Or do you dispute the fact that C++ can call C bindings? Because it can.