dotty.tools.dotc.core.classfile.ByteCodecs$
Attributes
- Graph
- Supertypes
- Self type
Members list
Concise view
Value members
Destructively decodes array xs and returns the length of the decoded array.
Destructively decodes array xs and returns the length of the decoded array.
Sometimes returns (length + 1) of the decoded array. Example:
scala> val enc = reflect.generic.ByteCodecs.encode(Array(1,2,3))
enc: Array[Byte] = Array(2, 5, 13, 1)
scala> reflect.generic.ByteCodecs.decode(enc)
res43: Int = 4
scala> enc
res44: Array[Byte] = Array(1, 2, 3, 0)
However, this does not always happen.
Attributes