<commit_before>// Copyright 2011 The Snappy-Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

package snappy

import (
	"encoding/binary"
)

// We limit how far copy back-references can go, the same as the C++ code.
const maxOffset = 1 << 15

// equal4 returns whether b[i:i+4] equals b[j:j+4].
func equal4(b []byte, i, j int) bool {
	return b[i] == b[j] &&
		b[i+1] == b[j+1] &&
		b[i+2] == b[j+2] &&
		b[i+3] == b[j+3]
}

// emitLiteral writes a literal chunk and returns the number of bytes written.
func emitLiteral(dst, lit []byte) int {
	i, n := 0, uint(len(lit)-1)<commit_msg>snappy-go: Remove equal4<commit_after>// Copyright 2011 The Snappy-Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

package snappy

import (
	"encoding/binary"
)

// We limit how far copy back-references can go, the same as the C++ code.
const maxOffset = 1 << 15

// emitLiteral writes a literal chunk and returns the number of bytes written.
func emitLiteral(dst, lit []byte) int {
	i, n := 0, uint(len(lit)-1)
{'fraction_non_alphanumeric': 0.128839590443686, 'fraction_numerical': 0.024744027303754267, 'mean_word_length': 3.528957528957529, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3344733', 'n_tokens_mistral': 415, 'n_tokens_neox': 394, 'n_words': 165}