enhanced moo_inttostr() with 2 new flags - MOO_INTTOSTR_LOWERCASE and MOO_INTTOSTR_NONEWOBJ

redefined bigint and fpdec check macros
added the strfmt primitive to String
This commit is contained in:
hyunghwan.chung
2018-12-21 16:25:25 +00:00
parent d3227d1452
commit 71a617b95b
9 changed files with 957 additions and 129 deletions

View File

@ -435,6 +435,7 @@ typedef enum moo_gcfin_t moo_gcfin_t;
#define MOO_OBJ_IS_HALFWORD_POINTER(oop) (MOO_OOP_IS_POINTER(oop) && (MOO_OBJ_GET_FLAGS_TYPE(oop) == MOO_OBJ_TYPE_HALFWORD))
#define MOO_OBJ_IS_WORD_POINTER(oop) (MOO_OOP_IS_POINTER(oop) && (MOO_OBJ_GET_FLAGS_TYPE(oop) == MOO_OBJ_TYPE_WORD))
/* [NOTE] this macro doesn't check the range of the actual value.
* make sure that the value of each bit fields given falls within the
* possible range of the defined bits */
@ -1632,6 +1633,16 @@ struct moo_t
} inttostr;
/* == END BIGINT CONVERSION == */
struct
{
struct
{
moo_ooch_t* ptr;
moo_oow_t capa;
moo_oow_t len;
} xbuf; /* buffer to support sprintf */
} sprintf;
moo_sbuf_t sbuf[64];
struct