MCPcopy Create free account
hub / github.com/babel/minify / extra_distance_bits

Function extra_distance_bits

scripts/pyflate.py:226–232  ·  view source on GitHub ↗
(n)

Source from the content-addressed store, hash-verified

224 return (3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258)[i-257]
225
226def extra_distance_bits(n):
227 if 0 <= n <= 1:
228 return 0
229 elif 2 <= n <= 29:
230 return (n >> 1) - 1
231 else:
232 raise "illegal distance code"
233
234def extra_length_bits(n):
235 if 257 <= n <= 260 or n == 285:

Callers 1

gzip_mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected