[FFmpeg-devel] [RFC] extern "C" usage

Olivier Galibert galibert
Mon May 14 20:08:24 CEST 2007

On Mon, May 14, 2007 at 11:40:50AM -0400, Rich Felker wrote:
> Huh? Why is C++ special? Should the header files auto-detect if you're
> using Pascal and give you pascal bindings? Or Java? Or ...???

C++ is special because C headers and C-compiled libraries are usually
perfectly compatible with C++ unless you go out of your way to make it
hard.  And if you add the 6 lines per public header for the extern "C"
you can even make it easy.  Minimal effort for maximal gain.

That doesn't prevent people from writing bindings which integrate the
library better into what some consider to be "real" C++, whatever that
means, but that's a different problem.


More information about the ffmpeg-devel mailing list