mitsuhiko/babel — pull request #117 by etanol (2014-11-05 16:27:20+00:00)
Title: Add support for parent locale exceptions

The method to generate the name for the parent locale has some exceptions. Notably the latin america regions (``es_MX``, ``es_CO``, ``es_AR``, etc...) which should inherit from ``es_419`` instead of ``es``. Fortunately, these exceptions are described in the element of the supplemental data document.

This pull request tries to implement the proper locale inheritance for such cases.

There is an ugly hack because one of the commits introduces a circular dependency between ``babel.core`` and ``babel.locale``.