/*
**********************************************************************
-* Copyright (C) 2002-2009, International Business Machines
+* Copyright (C) 2002-2011, International Business Machines
* Corporation and others. All Rights Reserved.
**********************************************************************
* file name: ucnv_u32.c
#if !UCONFIG_NO_CONVERSION
#include "unicode/ucnv.h"
+#include "unicode/utf.h"
#include "ucnv_bld.h"
#include "ucnv_cnv.h"
#include "cmemory.h"
while (mySource < sourceLimit && myTarget < targetLimit) {
ch = *(mySource++);
- if (UTF_IS_SURROGATE(ch)) {
+ if (U_IS_SURROGATE(ch)) {
if (U_IS_LEAD(ch)) {
lowsurogate:
if (mySource < sourceLimit) {
while (mySource < sourceLimit && myTarget < targetLimit) {
ch = *(mySource++);
- if (UTF_IS_SURROGATE(ch)) {
+ if (U_IS_SURROGATE(ch)) {
if (U_IS_LEAD(ch)) {
lowsurogate:
if (mySource < sourceLimit) {
{
ch = *(mySource++);
- if (UTF_IS_SURROGATE(ch)) {
- if (U_IS_LEAD(ch))
+ if (U16_IS_SURROGATE(ch)) {
+ if (U16_IS_LEAD(ch))
{
lowsurogate:
if (mySource < sourceLimit)
{
ch2 = *mySource;
- if (U_IS_TRAIL(ch2)) {
+ if (U16_IS_TRAIL(ch2)) {
ch = ((ch - SURROGATE_HIGH_START) << HALF_SHIFT) + ch2 + SURROGATE_LOW_BASE;
mySource++;
}
{
ch = *(mySource++);
- if (UTF_IS_SURROGATE(ch)) {
- if (U_IS_LEAD(ch))
+ if (U16_IS_SURROGATE(ch)) {
+ if (U16_IS_LEAD(ch))
{
lowsurogate:
if (mySource < sourceLimit)
{
ch2 = *mySource;
- if (U_IS_TRAIL(ch2))
+ if (U16_IS_TRAIL(ch2))
{
ch = ((ch - SURROGATE_HIGH_START) << HALF_SHIFT) + ch2 + SURROGATE_LOW_BASE;
mySource++;