C++ – Talking About Methods vs Member Functions

cobject-orientedterminology

I understand that according to the C++ spec there is no such thing as a "method", and some (many? most?) C++ programmers consider "method" to be a Java-ism. On the other hand, even on a C++ forum people seem to talk about methods without twitching. I am looking for known conventions or common practices regarding this terminology.

I am documenting an API that has both C++ and Java versions. The developers actually kept the class and method/member-function names the same between the two, presumably for expedience in porting and testing. Because of this, some of what needs to be documented about these APIs sits "above" the choice of language; I need to be able to talk in general about Foos and Bars, with their baz() and mumble()…methods?

If I talk about methods Java programmers will consider it natural and, it appears, C++ programmers will probably understand but some will consider it to be incorrect. My question is: how heinous is this in practice? How are C++ member functions conventionally talked about in "general OOP" contexts, as opposed to C++-specific ones? Is there a better way to talk about member functions in a way that's not incorrect for either language? ("Member functions" is a little verbose.)

This isn't an opinion survey; I'm trying to determine if there are actual conventions or common practices to address this problem.

I am aware of this question, but it's about OOP in general and doesn't ask about specific languages.

Best Answer

Why don't you include an explanation (very much like you did in your question) in the introductory part of the documentation, e.g. a Conventions section? Then you could explain that the term "method", as used in your documentation, is meant in the generic sense of method (Java), member function (C++), ... since the documentation applies to all implementations.