This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Locales: Use CLDR matching thousands separator


9.10.2018 10:38 Marko Myllynen <myllynen@redhat.com> wrote:
> [...]
> I wonder would it make sense to consider an addition to provide a
> function that would recognize non-breaking spaces, to allow applications
> to detect something like "123 456" as a single number, regardless of the
> exact variant of no-break space used in between.

I think that what we need is to split the "space" class into the
subclasses: "breaking space" and "non-breaking space", or maybe rather
define just "breaking space" and "non-breaking space":

    def is_breaking_space(conde_point):
    '''

    def is_non_breaking_space(code_point):
    '''

    def is_space(code_point):
        return is_breaking_space(code_point) ||
is_non_breaking_space(code_point)

so that application would be able to distinguish whether a space
is breaking or non-breaking or whether it is a space in general.

> I'm not sure on what level such an addition should ideally be done
> (standards, GNU/glibc, a higher-level library, perhaps something else),
> so I won't start championing such a change further.

Same here.

Regards,

Rafal


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]