[Libreoffice] [PUSHED] Re: occured occurred

Caolán McNamara caolanm at redhat.com
Mon Dec 6 02:45:27 PST 2010


On Mon, 2010-12-06 at 10:06 +0000, Wols Lists wrote:
> On 06/12/10 09:53, Takeshi Abe wrote:
> >> I'm not adverse to changing that API, but its something we should plan
> >> > for and bundle a whole set of changes together for.
> > One possible way to gracefully diverge the APIs is providing new API/ABI
> > with old obsolete ones in the meanwhile, that allow users to spell both
> > variants as they like.

The catch there, and it happened before with the spelling/grammar API
and voikko, is that adding a new method e.g. a correctly spelled one,
means that e.g. an old implementation in C++ is now incomplete and if
someone calls the new correctly spelled name, then there isn't a virtual
method in the old implementation with that name which will cause it to
crash. In theory its not the internal implementation which are the most
problematic, the possibility exists of external implementation. Which is
why we have various horrific things like "XFilePicker2"  which adds
methods that didn't exist in XFilePicker.

> Rename the functions, and provide a #define in the .h? (Or doesn't that
> work well with C++?)

The additional catch with this is that changes in offapi affect all
language bindings, e.g. java, pyuno, basic as well as C++. So sticking
in a #define doesn't handle the general case.

C.



More information about the LibreOffice mailing list