From 6cf1cdf1981fcb48b5865b74b69f34603535600c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Janosch=20Mu=CC=88ller?= Date: Wed, 1 Feb 2023 18:12:16 +0100 Subject: [PATCH] Remove redundant #pack call --- lib/regexp_parser/scanner/property.rl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/regexp_parser/scanner/property.rl b/lib/regexp_parser/scanner/property.rl index 64edb63..822d035 100644 --- a/lib/regexp_parser/scanner/property.rl +++ b/lib/regexp_parser/scanner/property.rl @@ -17,7 +17,7 @@ text = copy(data, ts-1, te) type = (text[1] == 'P') ^ (text[3] == '^') ? :nonproperty : :property - name = data[ts+2..te-2].pack('c*').gsub(/[\^\s_\-]/, '').downcase + name = text[3..-2].gsub(/[\^\s_\-]/, '').downcase token = self.class.short_prop_map[name] || self.class.long_prop_map[name] validation_error(:property, name) unless token