]> git.saurik.com Git - apple/icu.git/blobdiff - icuSources/test/perf/ubrkperf/ubrkperf.cpp
ICU-64232.0.1.tar.gz
[apple/icu.git] / icuSources / test / perf / ubrkperf / ubrkperf.cpp
index 9a090ee5facc1731734ae4e72638da0055d29d54..361a14baadf1f805edf5b9a344c1fcec52849aac 100644 (file)
@@ -1,9 +1,14 @@
-/********************************************************************
+/***********************************************************************
+ * © 2016 and later: Unicode, Inc. and others.
+ * License & terms of use: http://www.unicode.org/copyright.html#License
+ *
+ ***********************************************************************
+ ***********************************************************************
  * COPYRIGHT:
- * Copyright (C) 2001-2008 International Business Machines Corporation
+ * Copyright (C) 2001-2016 International Business Machines Corporation
  * and others. All Rights Reserved.
  *
- ********************************************************************/
+ ***********************************************************************/
 /********************************************************************************
 *
 * File ubrkperf.cpp
 *********************************************************************************
 */
 
+#include "cmemory.h"
 #include "ubrkperf.h"
 #include "uoptions.h"
 #include <stdio.h>
 
 
 #if 0
-#ifdef U_DARWIN
+#if U_PLATFORM_IS_DARWIN_BASED
 #include <ApplicationServices/ApplicationServices.h>
 enum{
   kUCTextBreakAllMask = (kUCTextBreakClusterMask | kUCTextBreakWordMask | kUCTextBreakLineMask)
@@ -83,7 +89,7 @@ void doForwardTest() {
 
     elapsedTime = timeGetTime()-startTime;
   } else if(opt_mac) {
-#ifdef U_DARWIN
+#if U_PLATFORM_IS_DARWIN_BASED
     createMACBrkIt();
     UniChar* filePtr = text;
     OSStatus status = noErr;
@@ -192,7 +198,7 @@ m_file_(NULL),
 m_fileLen_(0)
 {
 
-    _remainingArgc = u_parseArgs(_remainingArgc, (char**)argv, (int32_t)(sizeof(options)/sizeof(options[0])), options);
+    _remainingArgc = u_parseArgs(_remainingArgc, (char**)argv, UPRV_LENGTHOF(options), options);
 
 
     if(options[0].doesOccur) {