Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'mcs/class/I18N/Other/CP57002.cs')
-rw-r--r--mcs/class/I18N/Other/CP57002.cs51
1 files changed, 3 insertions, 48 deletions
diff --git a/mcs/class/I18N/Other/CP57002.cs b/mcs/class/I18N/Other/CP57002.cs
index 09779d5ae98..a4e8830685d 100644
--- a/mcs/class/I18N/Other/CP57002.cs
+++ b/mcs/class/I18N/Other/CP57002.cs
@@ -43,9 +43,9 @@ using I18N.Common;
public abstract class ISCIIEncoding : MonoEncoding
{
// Internal state.
- int shift;
- string encodingName;
- string webName;
+ protected int shift;
+ protected String encodingName;
+ protected String webName;
// Constructor.
protected ISCIIEncoding(int codePage, int shift,
@@ -87,51 +87,6 @@ public abstract class ISCIIEncoding : MonoEncoding
return s.Length;
}
- public unsafe override int GetByteCountImpl (char* chars, int count)
- {
-#if NET_2_0
- EncoderFallbackBuffer buffer = null;
- int index = 0;
- int charIndex = 0;
- int byteIndex = 0;
-
- int length = 0;
- char ch;
- char first = (char)shift;
- char last = (char)(shift + 0x7F);
- while(count-- > 0)
- {
- ch = chars[index++];
- if(ch < (char)0x0080)
- {
- // Regular ASCII subset.
- length++;
- }
- else if(ch >= first && ch <= last)
- {
- // ISCII range that we need to shift.
- length++;
- }
- else if(ch >= '\uFF01' && ch <= '\uFF5E')
- {
- // ASCII full-width characters.
- length++;
- }
- else
- {
- // FIXME: implement fallback support for GetByteCountImpl().
- length++;
- }
- count--;
- }
-
- // Return the final length of the output.
- return length;
-#else
- return count;
-#endif
- }
-
public unsafe override int GetBytesImpl (char* chars, int charCount, byte* bytes, int byteCount)
{
#if NET_2_0