Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Not A Problem
-
2.3.0, 2.4.0-rc-1
-
None
-
None
Description
@groovy.transform.CompileStatic class Test { byte[] parseStructuredString(String s) { byte[] data = new byte[s.length() / 2]; for (int i = 0; i < s.length(); i += 2) { data[i / 2] = (byte) ((Character.digit(s.charAt(i), 16) << 4) + Character.digit(s.charAt(i+1), 16)); } return data } }
Error:(11, 13) Groovyc: [Static type checking] - Cannot find matching method [B#getAt(java.math.BigDecimal). Please check if the declared type is right and if the method exists.
Error:(11, 27) Groovyc: [Static type checking] - Cannot assign value of type byte to variable of type byte[]