* DecoderFallback.cs, EncoderFallback.cs, Encoding.cs :
the same "\uFFFD" fix for encoder fallback.
Reduced extra instantiation of those fallbacks.
* EncoderReplacementFallbackTest.cs,
EncoderReplacementFallbackBufferTest.cs : encoder test for
"\uFFFD" replacement.
svn path=/trunk/mcs/; revision=91947
* Encoding.cs : added UTF8UnmarkedUnsafe, for old empty replacement
UTF8.
* BinaryReader.cs, BinaryWriter.cs : use unsafe encoding that has ""
for replacement fallback. Binary serialization regression is fixed.
svn path=/trunk/mcs/; revision=88276
* DecoderReplacementFallbackBuffer.cs : Reset() should also reset the
input buffer. When fallback is not assigned, just return '\0'.
* UnicodeEncoding.cs : handle throwOnInvalid .ctor argument.
Default replacement fallback buffer is now "\uFFFD".
* UTF8Encoding.cs : couple of replacement buffer size fixes.
Default replacement fallback buffer is now "\uFFFD".
* UTF32Encoding.cs : Default replacement is "\uFFFD" too here.
See http://support.microsoft.com/kb/940521/ for this change.
* UnicodeEncodingTest.cs,
UTF8EncodingTest.cs,
DecoderReplacementFallbackBufferTest.cs,
DecoderReplacementFallbackTest.cs : default replacement buffer fix.
Added test for Reset() for replacement buffer.
svn path=/trunk/mcs/; revision=88150
* StringBuilder: hide non 2.1 AppendFormat on 2.1 so that
the compile picks up the adequate method when AppendFormat
is used in 2.1 platform code.
svn path=/trunk/mcs/; revision=84160
* Encoding.cs : the change broke the build, so reverted part of it.
* EncodingTest.cs :
reverted part of the related patch, thus added NotWorking.
svn path=/trunk/mcs/; revision=72087
* Encoding.cs: In GetEncoding (int) do not allow codepage value below zero
and above 0xffff. Modified NotSupportedException to ArgumentException in
GetEncoding (string).
* corlib_test.dll.sources: Added EncodingTest.cs.
svn path=/trunk/mcs/; revision=72052
* Encoding.cs :
Consider DecoderFallback and EncoderFallback in 2.0 Equals()
and GetHashCode().
* UTF32Encoding.cs, UTF7Encoding.cs :
Fixed GetHashCode() and Equals() as well.
Added several missing overrides in 2.0.
svn path=/trunk/mcs/; revision=64299
Marked 2.0-only members as ComVisible (false).
* Decoder.cs: Marked class ComVisible (true) on 2.0 profile. Marked
2.0-only members as ComVisible (false).
* Encoder.cs: Marked class ComVisible (true) on 2.0 profile. Marked
2.0-only members as ComVisible (false).
* Encoding.cs: Marked class ComVisible (true) on 2.0 profile. Marked
2.0-only members as ComVisible (false).
* NormalizationForm.cs: Marked ComVisible (true).
* StringBuilder.cs: Marked class ComVisible (true) on 2.0 profile.
Marked 2.0-only methods as ComVisible (false).
* UnicodeEncoding.cs: GetString (byte[], int, int) is only available
in 2.0 profile. Marked 2.0-only methods ComVisible (false). Added
missing ctor in 2.0 profile, and marked in MonoTODO.
* UTF7Encoding.cs: Marked class ComVisible (true) on 2.0 profile.
* UTF8Encoding.cs: Marked 2.0-only methods as ComVisible (false).
svn path=/trunk/mcs/; revision=61250
* Encoder.cs, Decoder.cs : implemented Convert(). Also added argument
check in some methods.
* EncoderTest.cs, DecoderTest.cs : new tests, for Convert().
* corlib_test.dll.sources: added EncoderTest.cs and DecoderTest.cs.
svn path=/trunk/mcs/; revision=58819
* ASCIIEncoding.cs : added overriden methods in NET_2_0 (maybe
there are optimizations, but for now we need something just works).
svn path=/trunk/mcs/; revision=58818
* UTF8Encoding.cs : In zero-charbuffer case, byte buffer count should
be checked. Also it should not ignore leftOver characters even if
byte buffer length is 0.
* UTF8EncodingTest.cs : added test for insufficient bytes for
flush=true and leftOver!='\0' case.
svn path=/trunk/mcs/; revision=56533
* UTF8Encoding.cs :
actually leftover bits needs more careful handleding. So it's
better to be rather close to the original GetBytes().
Also changed leftOver handling so that it will be able to support
fallback.
svn path=/trunk/mcs/; revision=56516
* UTF8Encoding.cs :
GetBytes(string, ...) could reuse InternalGetBytes() using fixed
pointers. However, InternalGetBytes() was slower than
GetBytes(string, ...), so first replaced existing InternalGetBytes()
with GetBytes() internals, and GetBytes(string, ...) switched to
InternalGetBytes(). Now GetBytes() implementation code is reduced
to one method.
svn path=/trunk/mcs/; revision=56509
* UTF8Encoding.cs : fast path optimization was pretty insufficient.
Now it handles the entire bytes, not just half of them.
svn path=/trunk/mcs/; revision=56449