Source File
prefix.go
Belonging Package
github.com/andybalholm/brotli
package brotli
/* Copyright 2013 Google Inc. All Rights Reserved.
Distributed under MIT license.
See file LICENSE for detail or copy at https://opensource.org/licenses/MIT
*/
/* Functions for encoding of integers into prefix codes the amount of extra
bits, and the actual values of the extra bits. */
/* Here distance_code is an intermediate code, i.e. one of the special codes or
the actual distance increased by BROTLI_NUM_DISTANCE_SHORT_CODES - 1. */
func prefixEncodeCopyDistance( uint, uint, uint, *uint16, *uint32) {
if < numDistanceShortCodes+ {
* = uint16()
* = 0
return
} else {
var uint = (uint(1) << ( + 2)) + ( - numDistanceShortCodes - )
var uint = uint(log2FloorNonZero() - 1)
var uint = (1 << ) - 1
var uint = &
var uint = ( >> ) & 1
var uint = (2 + ) <<
var uint = -
* = uint16(<<10 | (numDistanceShortCodes + + ((2*(-1) + ) << ) + ))
* = uint32(( - ) >> )
}
}
![]() |
The pages are generated with Golds v0.6.7. (GOOS=linux GOARCH=amd64) Golds is a Go 101 project developed by Tapir Liu. PR and bug reports are welcome and can be submitted to the issue list. Please follow @Go100and1 (reachable from the left QR code) to get the latest news of Golds. |