ICU-9008 some more U_SIGNED_RIGHT_SHIFT_IS_ARITHMETIC fixes; include putilimp.h where that macro is tested

X-SVN-Rev: 31188
This commit is contained in:
Markus Scherer 2012-01-10 07:15:25 +00:00
parent 4c61713090
commit 6390003c87
3 changed files with 11 additions and 4 deletions

View file

@ -1,7 +1,7 @@
/*
*******************************************************************************
*
* Copyright (C) 2009-2011, International Business Machines
* Copyright (C) 2009-2012, International Business Machines
* Corporation and others. All Rights Reserved.
*
*******************************************************************************
@ -25,6 +25,7 @@
#include "cmemory.h"
#include "mutex.h"
#include "normalizer2impl.h"
#include "putilimp.h"
#include "uassert.h"
#include "uset_imp.h"
#include "utrie2.h"

View file

@ -1,7 +1,7 @@
/*
*******************************************************************************
*
* Copyright (C) 2004-2011, International Business Machines
* Copyright (C) 2004-2012, International Business Machines
* Corporation and others. All Rights Reserved.
*
*******************************************************************************
@ -21,6 +21,7 @@
#include "unicode/utypes.h"
#include "unicode/uset.h"
#include "putilimp.h"
#include "uset_imp.h"
#include "udataswp.h"
@ -295,7 +296,11 @@ enum {
#define UCASE_MAX_DELTA 0x1ff
#define UCASE_MIN_DELTA (-UCASE_MAX_DELTA-1)
#define UCASE_GET_DELTA(props) ((int16_t)(props)>>UCASE_DELTA_SHIFT)
#if U_SIGNED_RIGHT_SHIFT_IS_ARITHMETIC
# define UCASE_GET_DELTA(props) ((int16_t)(props)>>UCASE_DELTA_SHIFT)
#else
# define UCASE_GET_DELTA(props) (int16_t)(((props)&0x8000) ? (((props)>>UCASE_DELTA_SHIFT)|0xfc00) : ((uint16_t)(props)>>UCASE_DELTA_SHIFT))
#endif
/* case-ignorable uses one of the delta bits, see gencase/store.c */
#define UCASE_CASE_IGNORABLE 0x40

View file

@ -1,7 +1,7 @@
/*
******************************************************************************
* *
* Copyright (C) 1999-2011, International Business Machines *
* Copyright (C) 1999-2012, International Business Machines *
* Corporation and others. All Rights Reserved. *
* *
******************************************************************************
@ -21,6 +21,7 @@
#include "unicode/utypes.h"
#include "unicode/udata.h"
#include "unicode/ures.h"
#include "putilimp.h"
#include "udataswp.h"
/**