MCPcopy Index your code
hub / github.com/python/cpython / fillhints

Method fillhints

Tools/unicode/genmap_tchinese.py:196–205  ·  view source on GitHub ↗
(self, hintfrom, hintto)

Source from the content-addressed store, hash-verified

194 self.filler = self.filler_class()
195
196 def fillhints(self, hintfrom, hintto):
197 name = f'{self.prefix}_phint_{hintfrom}'
198 self.fp.write(f'static const unsigned char {name}[] = {{\n')
199 for msbcode in range(hintfrom, hintto+1, 8):
200 v = 0
201 for c in range(msbcode, msbcode+8):
202 v |= self.isbmpmap.get(c, 0) << (c - msbcode)
203 self.filler.write('%d,' % v)
204 self.filler.printout(self.fp)
205 self.fp.write('};\n\n')
206
207
208def main_hkscs():

Callers 1

main_hkscsFunction · 0.80

Calls 3

printoutMethod · 0.80
writeMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected