internal int codePage;
internal int windows_code_page;
bool is_readonly = true;
-
- internal static readonly byte[] empty = new byte[0];
// Constructor.
protected Encoding ()
throw new ArgumentNullException ("s");
if (s.Length == 0)
- return empty;
+ return EmptyArray<byte>.Value;
int byteCount = GetByteCount (s);
if (byteCount == 0)
- return empty;
+ return EmptyArray<byte>.Value;
unsafe {
fixed (char* cptr = s) {
byte [] bytes = new byte [byteCount];
// Get the identifying preamble for this encoding.
public virtual byte[] GetPreamble ()
{
- return empty;
+ return EmptyArray<byte>.Value;
}
// Decode a buffer of bytes into a string.