harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mohanraj Loganathan (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HARMONY-6582) [classlib][luni]String.indexOf behaves wrongly if the string contains any Supplementary Characters
Date Thu, 15 Jul 2010 05:10:51 GMT

    [ https://issues.apache.org/jira/browse/HARMONY-6582?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12888707#action_12888707
] 

Mohanraj Loganathan commented on HARMONY-6582:
----------------------------------------------

In the description above it should be 'String chars codepoint value above 0xFFFF' instead
'String chars codepoint value above 0x10FFFF'

> [classlib][luni]String.indexOf behaves wrongly if the string contains any Supplementary
Characters
> --------------------------------------------------------------------------------------------------
>
>                 Key: HARMONY-6582
>                 URL: https://issues.apache.org/jira/browse/HARMONY-6582
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>         Environment: Windows and Linux
>            Reporter: Mohanraj Loganathan
>         Attachments: StringIndexOf_001.diff
>
>
> If the String contains Supplementary characters in it then String.indexof function returns
wrong values in Harmony. 
> If the String chars codepoint value above 0x10FFFF , then String.indexOf return wrong
results.
> Consider the example below:
> if("a\ud800\udc00".indexOf(0x10000) != 1)
> 	System.out.println("we should not be here");
> if("ab\ud800\udc00".indexOf(0x10000, 1) != 2)
> 	System.out.println("we should not be here");
> Above test passes in RI and fails with harmony.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message