473,670 Members | 2,499 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Different Language causing bugs


Did you know that in Turkish strupper("i") <> "I" ?!
They have dotted i and un-dotted I, both in upper case and in lower
case...

We found it only after a complain from a Turkish client.
Where can I find more language differences, before I get more clients
complaining?

Thanks

Atara

*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 20 '05 #1
7 1142
* Atara <At***@DD.com > scripsit:
Did you know that in Turkish strupper("i") <> "I" ?!
They have dotted i and un-dotted I, both in upper case and in lower
case...


What's 'strupper'?

--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/>
Nov 20 '05 #2

I guess this is the C form for
myStr.ToUpper

and in VB:

dim str1 as string = "i"
dim str2 as string = "I"
str1.ToUpper <> str2 ' Only in Turky !

Atara

*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 20 '05 #3
* Atara <At***@DD.com > scripsit:
I guess this is the C form for
myStr.ToUpper

and in VB:

dim str1 as string = "i"
dim str2 as string = "I"
str1.ToUpper <> str2 ' Only in Turky !


OK, it would be the same for 'UCase', I assume. Can you post the
character code of the characters you are comparing? You can determine
the character code using 'AscW'.

--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/>
Nov 20 '05 #4


Ascw(i) = 105
Ascw(I) = 73
but they are not a pair in Turkish.
We already removed the turkish from our testing machine, so I cannot
tell you what is the unicode of the Capital-Dotted-I and the
Lower-unDotted-i

My question is: Does anyone knows about other bugs that are specific to
a language?

Atara


*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 20 '05 #5
Atara,
Have you tried asking this "down the hall" in the
microsoft.publi c.dotnet.intern ationalization newsgroup?

Remember that .NET uses Unicode, that Windows XP & Windows 2000 both support
Unicode, you should not need Turkish installed on your machine per se.

You should be able to use Character Map (Start - Programs - Accessories -
System Tools) to find the characters. From your description are you
referring to "U+0130: Latin Capital Letter I with Dot Above" ChrW(130) and
"U+0131: Latin Small Letter Dotless I" ChrW(131)? I don't know Turkish so I
don't know if it falls within the Latin characters or its "by itself" like
Greek, Cyrillic, Hebrew, Arabic or other...

I'm not seeing a problem comparing the above characters in VS.NET 2003.

For a plethora of information on Unicode in .NET see:
http://www.yoda.arachsys.com/csharp/unicode.html

Hope this helps
Jay
"Atara" <At***@DD.com > wrote in message
news:ui******** ******@TK2MSFTN GP11.phx.gbl...


Ascw(i) = 105
Ascw(I) = 73
but they are not a pair in Turkish.
We already removed the turkish from our testing machine, so I cannot
tell you what is the unicode of the Capital-Dotted-I and the
Lower-unDotted-i

My question is: Does anyone knows about other bugs that are specific to
a language?

Atara


*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!

Nov 20 '05 #6

Thank you all.

Our program failed in Turkey because we used code that relied on the
'fault' assumption that "i".ToUpper = "I"

* The only way we could specify the problem was by installing Turkish
OS.
* I fixed the bug by creating the upperCase string using -
Dim deltaAscii As Integer = 97-65 ' Asc("a")=97, Asc("A")=65
For Each strChar In myStr
intAsc = AscW(strChar)
If (intAsc >= AscW("a")) And (intAsc <= AscW("z")) Then
strUpper = strUpper & Chr(intAsc - deltaAscii)

I am looking for a site that will include information about
specification of languages that might cause other bugs.

Are you aware of such a site?

Thanks
Atara.
*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 20 '05 #7
Atara,
I am looking for a site that will include information about
specification of languages that might cause other bugs. Are they bugs? Did you contact MS directly to verify they are bugs?

I would contact Microsoft directly if I suspected an alleged bug in the
framework that did not allow me to compare "i" to "I"!
Are you aware of such a site? In addition to the links below try asking this "down the hall" in the
microsoft.publi c.dotnet.intern ationalization newsgroup I suspect will offer
you a plethora of more sites!
Note: I would strongly discourage your code to "workaround " this problem as
you may actually be introducing new problems for other cultures!

I would make sure that I was using the "correct" compare method. In addition
to the "=" operator, there is String.Compare & String.CompareO ridinal with
overloads. I would make sure I had a good understanding (or at least good
enough) of cultures & how strings worked in the various cultures.

For example:

Imports System.Globaliz ation

' This is effectively what "string1.ToUppe r() = string2.ToUpper ()" does:
If String.Compare( string1, string2, True, CultureInfo.Cur rentCulture) =
0 Then

' This is effectively what you loop is trying to do:
If String.Compare( string1, string2, True, CultureInfo.Inv ariantCulture)
= 0 Then
For details on compare strings see:

http://msdn.microsoft.com/library/de...ficculture.asp

http://msdn.microsoft.com/library/de...operations.asp

Interesting enough this page talks about your "bug"!

http://msdn.microsoft.com/library/de...rtingrules.asp

http://msdn.microsoft.com/library/de...operations.asp

Plus any sub topics of the above...

Hope this helps
Jay

"Atara" <At***@DD.com > wrote in message
news:uz******** ******@TK2MSFTN GP10.phx.gbl...
Thank you all.

Our program failed in Turkey because we used code that relied on the
'fault' assumption that "i".ToUpper = "I"

* The only way we could specify the problem was by installing Turkish
OS.
* I fixed the bug by creating the upperCase string using -
Dim deltaAscii As Integer = 97-65 ' Asc("a")=97, Asc("A")=65
For Each strChar In myStr
intAsc = AscW(strChar)
If (intAsc >= AscW("a")) And (intAsc <= AscW("z")) Then
strUpper = strUpper & Chr(intAsc - deltaAscii)

I am looking for a site that will include information about
specification of languages that might cause other bugs.

Are you aware of such a site?

Thanks
Atara.
*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!

Nov 20 '05 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
2106
by: Dave Benjamin | last post by:
Hey good people, I've been doing a lot of simultaneous Jython and CPython programming lately, and just wanted to say, with no intended ill will toward any of the individuals who have been generous enough to make the two languages possible, that, well, they're kinda different. I guess it was inevitable, but with Jython stuck at Python 2.1, it's not really the same language as CPython is today. You still have to type "from __future__...
1
1756
by: RM | last post by:
I am using DataSet's .ReadXml() method to parse an XML file that has an inline schema and Im getting "different" results on various machines using the same myDataSet.ReadXml("myExample.xml"). Out of 5 test machines, my results are as follows. 1 Windows 2000 Server and 2 Windows XP Professional PC's that parses the XML, builds 2 tables with appropriate format columns (string, int, etc) and populates the tables with rows of data as...
6
3178
by: Cro | last post by:
Dear Access Developers, The 'Allow Additions' property of my form is causing unexpected results. I am developing a form that has its 'Default View' property set to 'Continuous Forms' and am displaying records that match an SQL statement entered in the 'Record Source' property of the form. The form behaves correctly and displays the records as expected. The
134
7971
by: evolnet.regular | last post by:
I've been utilising C for lots of small and a few medium-sized personal projects over the course of the past decade, and I've realised lately just how little progress it's made since then. I've increasingly been using scripting languages (especially Python and Bourne shell) which offer the same speed and yet are far more simple and safe to use. I can no longer understand why anyone would willingly use C to program anything but the lowest...
39
2067
by: Darren Oakey | last post by:
Hi all, I just thought I'd throw down what I think are the three biggest language inadequacies of C#, hopefully so that people will jump on the bandwagon and lobby MS to fix them! So - in order: *** 1 - lack of const *** I know this has been mentioned before, so I won't get into it, but really, WHAT WERE THEY THINKING??? Personally, I'd actually like to go a little further and invert the const logic - so all parameter declarations...
2
1232
by: Erich Brunthaller | last post by:
I run the SQL-server on VM-Ware with mixed mode auth. When I host the ASP service on IIS in VM-Ware access is possible from everywhere. But hosting the service on the IIS outside VM-Ware can not access the SQL-Server. The error is "SQL server does not exist, or access denied". The problem can not be any firewall because EnterpriseManager sees the Server and is dissabled. One possibility for solving this might be Impersonation I guess....
61
4724
by: phil-news-nospam | last post by:
Why does SVG need a different tag than other images? IMHO, SVG should be implemented as an image type just like any other image type, allowing it to work with <img> tags, and ... here is the important part ... also work with backgrounds in other tags. I fail to see any wisdom in making SVG different than say PNG (of course the implementation of the rendering code would obvious be different). --
669
25865
by: Xah Lee | last post by:
in March, i posted a essay “What is Expressiveness in a Computer Language”, archived at: http://xahlee.org/perl-python/what_is_expresiveness.html I was informed then that there is a academic paper written on this subject. On the Expressive Power of Programming Languages, by Matthias Felleisen, 1990. http://www.ccs.neu.edu/home/cobbe/pl-seminar-jr/notes/2003-sep-26/expressive-slides.pdf
87
3712
by: pereges | last post by:
I have a C program which I created on Windows machine. I have compiled and executed the program on windows machine and it gives me the consistent output every time i run it. for eg. input a = 2, b =3 lets say a sum operation is to be performed, then: output: 5
0
8468
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, well explore What is ONU, What Is Router, ONU & Routers main usage, and What is the difference between ONU and Router. Lets take a closer look ! Part I. Meaning of...
0
8386
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8901
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8814
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8591
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8660
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7415
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development projectplanning, coding, testing, and deploymentwithout human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
4209
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
2799
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.