mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-20 11:04:34 +02:00
8263677: Improve Character.isLowerCase/isUpperCase lookups
Reviewed-by: erikj, ihse, naoto, rriggs
This commit is contained in:
parent
b63b5d4c4b
commit
e152cc0312
8 changed files with 144 additions and 266 deletions
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2002, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2002, 2021, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
|
@ -87,13 +87,12 @@ class CharacterDataLatin1 extends CharacterData {
|
|||
|
||||
@IntrinsicCandidate
|
||||
boolean isLowerCase(int ch) {
|
||||
return (getProperties(ch) & $$maskType) == Character.LOWERCASE_LETTER
|
||||
|| (getPropertiesEx(ch) & $$maskOtherLowercase) != 0; // 0xaa, 0xba
|
||||
return (getPropertiesEx(ch) & $$maskOtherLowercase) != 0;
|
||||
}
|
||||
|
||||
@IntrinsicCandidate
|
||||
boolean isUpperCase(int ch) {
|
||||
return (getProperties(ch) & $$maskType) == Character.UPPERCASE_LETTER;
|
||||
return (getPropertiesEx(ch) & $$maskOtherUppercase) != 0;
|
||||
}
|
||||
|
||||
boolean isOtherAlphabetic(int ch) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue