made moo_rbt_getxtn() inline
This commit is contained in:
parent
5672b62e27
commit
55a57dbf9e
@ -324,9 +324,11 @@ MOO_EXPORT void moo_rbt_fini (
|
||||
moo_rbt_t* rbt /**< red-black tree */
|
||||
);
|
||||
|
||||
MOO_EXPORT void* moo_rbt_getxtn (
|
||||
moo_rbt_t* rbt
|
||||
);
|
||||
#if defined(MOO_HAVE_INLINE)
|
||||
static MOO_INLINE void* moo_rbt_getxtn (moo_rbt_t* rbt) { return (void*)(rbt + 1); }
|
||||
#else
|
||||
#define moo_rbt_getxtn(awk) ((void*)((moo_rbt_t*)(rbt) + 1))
|
||||
#endif
|
||||
|
||||
/**
|
||||
* The moo_rbt_getstyle() function gets manipulation callback function set.
|
||||
|
@ -243,11 +243,6 @@ void moo_rbt_fini (moo_rbt_t* rbt)
|
||||
moo_rbt_clear (rbt);
|
||||
}
|
||||
|
||||
void* moo_rbt_getxtn (moo_rbt_t* rbt)
|
||||
{
|
||||
return (void*)(rbt + 1);
|
||||
}
|
||||
|
||||
const moo_rbt_style_t* moo_rbt_getstyle (const moo_rbt_t* rbt)
|
||||
{
|
||||
return rbt->style;
|
||||
|
@ -692,7 +692,7 @@ MOO_INLINE int moo_conv_bcstr_to_ucstr_with_cmgr (
|
||||
for (bp = bcs; *bp != '\0'; bp++) /* nothing */ ;
|
||||
|
||||
mlen = bp - bcs; wlen = *ucslen;
|
||||
n = moo_conv_bchars_to_uchars_with_cmgr (bcs, &mlen, ucs, &wlen, cmgr, all);
|
||||
n = moo_conv_bchars_to_uchars_with_cmgr(bcs, &mlen, ucs, &wlen, cmgr, all);
|
||||
if (ucs)
|
||||
{
|
||||
/* null-terminate the target buffer if it has room for it. */
|
||||
@ -726,7 +726,7 @@ MOO_INLINE int moo_conv_uchars_to_bchars_with_cmgr (
|
||||
break;
|
||||
}
|
||||
|
||||
n = cmgr->uctobc (*p, bcs, rem);
|
||||
n = cmgr->uctobc(*p, bcs, rem);
|
||||
if (n == 0)
|
||||
{
|
||||
ret = -1;
|
||||
@ -751,7 +751,7 @@ MOO_INLINE int moo_conv_uchars_to_bchars_with_cmgr (
|
||||
{
|
||||
moo_oow_t n;
|
||||
|
||||
n = cmgr->uctobc (*p, bcsbuf, MOO_COUNTOF(bcsbuf));
|
||||
n = cmgr->uctobc(*p, bcsbuf, MOO_COUNTOF(bcsbuf));
|
||||
if (n == 0)
|
||||
{
|
||||
ret = -1;
|
||||
|
Loading…
Reference in New Issue
Block a user