projectfluent/python-fluent

Undocumented, maybe unused and maybe inconsistent parameter `use_isolating`

studyingegret opened this issue · 1 comments

(API Page) Present in constructors of FluentLocalization and FluentBundle, the use_isolating parameter is not explained. It does not seem to be used either: FluentLocalization delegates it to FluentBundle, and FluentBundle doesn't use it for anything (except that FluentBundle passes self to ResolverEnvironment, which may expose self.use_isolating, but I did not check further).

In addition, the default value of use_isolating in FluentLocalization constructor is False, while in FluentBundle's it is True.

It determines whether to wrap placeholders with FSI/PDI bidirectional isolation marks, here:

if not env.context.use_isolating:
return inner
return "\u2068" + inner + "\u2069"

The option is documented at the very bottom of the Internals of fluent.runtime document.