Split-package: contradicting documentation?

On Private-Package PACKAGE-SPEC ( ‘,’ PACKAGE-SPEC )* | bnd there are two sentences which mention a default behavior. But they seem contradictive.

Without any extra instructions, bnd will merge multiple packages where the last one wins if the packages contain duplicate resources, but it will give a warning to notify the unwanted case of split packages.

I get the impression that last one wins is the default.

and a bit later it reads:

merge-first Merge split packages but do not add resources that come later in the classpath. That is, the first resource wins. This is the default, although the default will generate a warning

Here it seems first resource wins is the default.

Which one is correct?
Is merge-first or merge-last the actual default if split-package declaration is ommited?

Just don’t rely on the default :slight_smile:

Split packages is a very bad practice, relying on its default handling (and getting then fixing up the error) is a malpractice … At least the merge instruction documents the intended behavior.

2 Likes