lmfit/lmfit-py — pull request #122 by tritemio (2014-09-09 06:01:04+00:00)
Title: FIX: Flatten components when adding two composite models.

This patch flattens the components when summing composite models.

When adding 2 composite models, if the prefixes are the same (for example empty), `__add__()` makes sure there is no parameter name conflict and all the parameters and hints are preserved in the composition.

There are some corner cases when adding two composite models **with different prefixes**. In this case one prefix is lost, and a parameter defined via an hint **may** change name. This case may be addressed in the future if turn out to be a real-world problem.