From 6852c803c422bbaaf471b0767fd909d4f8b9886c Mon Sep 17 00:00:00 2001 From: Brandon Dyck Date: Mon, 9 Sep 2024 15:19:00 -0600 Subject: [PATCH] Removed pointless hasPrefix in favor of point-free --- parser_test.go | 4 ---- 1 file changed, 4 deletions(-) diff --git a/parser_test.go b/parser_test.go index 4232059..441194f 100644 --- a/parser_test.go +++ b/parser_test.go @@ -26,10 +26,6 @@ func not[T any](pred func(T) bool) func(T) bool { return func(x T) bool { return !pred(x) } } -func hasPrefix(prefix []byte) func([]byte) bool { - return func(b []byte) bool { return bytes.HasPrefix(b, prefix) } -} - func TestSlice(t *testing.T) { assertParseFails := func(t rapid.TB, input []byte, p gigaparsec.Parser[byte, []byte]) (parseErr gigaparsec.ParseError) { t.Helper()