This is the mail archive of the 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] [BZ 17588 13064] Update UTF-8 charmap and width to Unicode 7.0.0

Thanks Alexandre for review it truly helped to further improve scripts. Mike updated the scripts and replied in other mails. He also fixed pylint warning for scripts.

updated patch now available on bugzilla [1] with updated changelog. Please review and let us know if anything more remained.

Pravin Satpute


----- Original Message -----
From: "Alexandre Oliva" <>
To: "Pravin Satpute" <>, "Mike FABIAN" <>
Sent: Thursday, December 4, 2014 7:55:24 PM
Subject: Re: [PATCH] [BZ 17588 13064]  Update UTF-8 charmap and width to Unicode 7.0.0

On Dec  4, 2014, Alexandre Oliva <> wrote:

> On Nov 24, 2014, Pravin Satpute <> wrote:
>> 6.

> I've reviewed the gen scripts in the git repo above.

I see there have been changes since I started the review.

The only one that caught my attention was in

I think the single loop in read_input_file would be better split into
multiple loops, one for head, one to skip to tail, one for tail.

Also consider using line.startswith instead of regexps for the
end-of-head and beginning-of-tail markers, unless that risks matching
unintended lines.

Finally, consider returning a tuple instead of modifying the global

It could end up like this:

def read_input_file(filename):
  head = tail = ''
  with open(filename, mode='r') as file:
    for line in file:
      match = re.match(
      if match:
        line ='key') + '"{:s}"\n'.format(time.strftime('%Y-%m-%d'))
      head = head + line
      if (line.startswith('LC_CTYPE'))
    for line in file:
      if (line.startswith('translit_start'))
        tail = line
    for line in file:
      tail = tail + line
  return (head, tail)

  (i18n_file_head, i18n_file_tail) = read_input_file(args.input_file)

Alexandre Oliva, freedom fighter
You must be the change you wish to see in the world. -- Gandhi
Be Free! --   FSF Latin America board member
Free Software Evangelist|Red Hat Brasil GNU Toolchain Engineer

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