Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1908)

Unified Diff: source/common/usc_impl.c

Issue 2440913002: Update ICU to 58.1
Patch Set: Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « source/common/usc_impl.h ('k') | source/common/uscript.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: source/common/usc_impl.c
diff --git a/source/common/usc_impl.c b/source/common/usc_impl.c
index e30c7f5ad274ad61b2f8853e36206846530c668a..1fff0c4482d7f34e8afa4950b6c086a935596e03 100644
--- a/source/common/usc_impl.c
+++ b/source/common/usc_impl.c
@@ -1,6 +1,8 @@
+// Copyright (C) 2016 and later: Unicode, Inc. and others.
+// License & terms of use: http://www.unicode.org/copyright.html
/*
**********************************************************************
-* Copyright (C) 1999-2014, International Business Machines
+* Copyright (C) 1999-2016, International Business Machines
* Corporation and others. All Rights Reserved.
**********************************************************************
*
@@ -17,8 +19,6 @@
#include "usc_impl.h"
#include "cmemory.h"
-#define ARRAY_SIZE(array) (sizeof array / sizeof array[0])
-
#define PAREN_STACK_DEPTH 32
#define MOD(sp) ((sp) % PAREN_STACK_DEPTH)
@@ -156,7 +156,7 @@ highBit(int32_t value)
static int32_t
getPairIndex(UChar32 ch)
{
- int32_t pairedCharCount = ARRAY_SIZE(pairedChars);
+ int32_t pairedCharCount = UPRV_LENGTHOF(pairedChars);
int32_t pairedCharPower = 1 << highBit(pairedCharCount);
int32_t pairedCharExtra = pairedCharCount - pairedCharPower;
« no previous file with comments | « source/common/usc_impl.h ('k') | source/common/uscript.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698