|
|
|
|
|
by humanrebar
3117 days ago
|
|
> ...Google writes the code in nice C++ classes, that get exposed as low level C APIs... I'm not on the android team, but in general it's easier to maintain reverse-compatibility with C ABIs than with C++ ABIs. And the plethora of libraries and the modest size of the standard library are part of the problem. Let's say you're writing a C++ library that understands git and lets users develop more complex applications with your libgitxx as a building block. Whose filesystem primitives (file, directory, path, user, etc.) do you use? There's really not a satisfactory answer to that question. Point being, C ABIs don't have this problem as much. They tend to just pass around ints and char. Maybe there are some structs to pass around, but they tend to be made up of ints, char, etc. |
|
As such, backward compatibility (binary-wise) is not needed.
Android, Chrome, etc. are another matter - former has an SDK, and I guess you may need that there, but I don't have much experience with it.