From mboxrd@z Thu Jan 1 00:00:00 1970 From: Artur Biesiadowski To: tromey@cygnus.com, mauve Subject: Re: Character Test Date: Sat, 09 Jan 1999 06:06:00 -0000 Message-id: <36975F57.881E9D4F@pg.gda.pl> References: <36957A24.B7BB761F@urbanophile.com> <877luxy5xw.fsf@cygnus.com> X-SW-Source: 1999-01/msg00012.html Tom Tromey wrote: > I think this code is also moderately buggy. For instance, it says > that Character.digit(\u00b2,6) should be 2. However, that is not the > case. \u00b2 is not a digit per the table in the JCL book. > > The test gives me nearly 1000 errors for my implementation of > Character. However, I actually think my implementation is correct (or > if it is not, it has very few bugs). I'm afraid that we will have to go with these one by one. isDigit problem is cause because I just used N* for type to determine the digit, not using dumb sun rule (if name contains DIGIT). But I'm afraid that I'll have to change that - so report all places where test reports unneeded bugs. But at the same time remeber that JLS is not perfect - there are some parts that contradict each other - I'll cite them soon. > Is there a particular reason you didn't use the 2.1.5 version of the > database? That is the latest version (as of sometime last month; I > haven't looked in a few weeks). > > Some care is required here. JDK conformance actually depends on using > the correct version of the table. For JDK 1.0, I believe a very old > Unicode data table was used. I'll say NO. JDK isn't god's implementation. We are interested in conformance to JLS and to common sense, only then taking JDK in account. Test is designed to check if Character class is valid to JLS, not if it has same bugs as JDK1.0.3. There is no duobt that latest version of Unicode spec is best, so we should use latest possible. If this will cause some 'good' implementation to fail, then it is ok - this means that this implementation is out of date compared to latest unicode standards. And JDK versions has nothing to do with it. Only important part is functionality exposed by Character methods - here we should use different versions of test. But why something implementing 1.0 methods should not recognize euro sign ? Only because there was a historic version of sun's product that was releases before euro introduction ? Artur