From 7f22a2b353e14f26d5c8a80b31b2cc6c80f2abee Mon Sep 17 00:00:00 2001 From: limepoutine <144896890+limepoutine@users.noreply.github.com> Date: Mon, 24 Feb 2025 15:56:23 +0800 Subject: [PATCH] Remove unused null check in Bytes.getString --- std/haxe/io/Bytes.hx | 2 -- 1 file changed, 2 deletions(-) diff --git a/std/haxe/io/Bytes.hx b/std/haxe/io/Bytes.hx index fdfdf4290fe..ae197b33166 100644 --- a/std/haxe/io/Bytes.hx +++ b/std/haxe/io/Bytes.hx @@ -404,8 +404,6 @@ class Bytes { interpreted with the given `encoding` (UTF-8 by default). **/ public function getString(pos:Int, len:Int, ?encoding:Encoding):String { - if (encoding == null) - encoding == UTF8; #if !neko if (pos < 0 || len < 0 || pos + len > length) throw Error.OutsideBounds;