]> git.saurik.com Git - apple/icu.git/blobdiff - icuSources/io/ustream.cpp
ICU-64232.0.1.tar.gz
[apple/icu.git] / icuSources / io / ustream.cpp
index 25c54eb55532f91023bb920bc4d8d7f4cbcb7083..51676ea0f545e910241c06c1fa3f0a60a5839f29 100644 (file)
@@ -1,3 +1,5 @@
+// © 2016 and later: Unicode, Inc. and others.
+// License & terms of use: http://www.unicode.org/copyright.html
 /*
 **********************************************************************
 *   Copyright (C) 2001-2016, International Business Machines
@@ -27,8 +29,6 @@
 
 // console IO
 
-#if U_IOSTREAM_SOURCE >= 199711
-
 #define STD_NAMESPACE std::
 
 #define STD_OSTREAM STD_NAMESPACE ostream
@@ -123,7 +123,7 @@ operator>>(STD_ISTREAM& stream, UnicodeString& str)
             /* Was the character consumed? */
             if (us != uBuffer) {
                 /* Reminder: ibm-1390 & JISX0213 can output 2 Unicode code points */
-                int32_t uBuffSize = us-uBuffer;
+                int32_t uBuffSize = static_cast<int32_t>(us-uBuffer);
                 int32_t uBuffIdx = 0;
                 while (uBuffIdx < uBuffSize) {
                     U16_NEXT(uBuffer, uBuffIdx, uBuffSize, ch32);
@@ -168,4 +168,3 @@ STOP_READING:
 U_NAMESPACE_END
 
 #endif
-#endif