mirror of
https://sourceware.org/git/glibc.git
synced 2025-07-28 00:21:52 +03:00
posix: Remove internal_function attribute
This commit is contained in:
@ -20,14 +20,14 @@
|
||||
static void re_string_construct_common (const char *str, int len,
|
||||
re_string_t *pstr,
|
||||
RE_TRANSLATE_TYPE trans, int icase,
|
||||
const re_dfa_t *dfa) internal_function;
|
||||
const re_dfa_t *dfa);
|
||||
static re_dfastate_t *create_ci_newstate (const re_dfa_t *dfa,
|
||||
const re_node_set *nodes,
|
||||
unsigned int hash) internal_function;
|
||||
unsigned int hash);
|
||||
static re_dfastate_t *create_cd_newstate (const re_dfa_t *dfa,
|
||||
const re_node_set *nodes,
|
||||
unsigned int context,
|
||||
unsigned int hash) internal_function;
|
||||
unsigned int hash);
|
||||
|
||||
/* Functions for string operation. */
|
||||
|
||||
@ -35,7 +35,7 @@ static re_dfastate_t *create_cd_newstate (const re_dfa_t *dfa,
|
||||
re_string_reconstruct before using the object. */
|
||||
|
||||
static reg_errcode_t
|
||||
internal_function __attribute_warn_unused_result__
|
||||
__attribute_warn_unused_result__
|
||||
re_string_allocate (re_string_t *pstr, const char *str, int len, int init_len,
|
||||
RE_TRANSLATE_TYPE trans, int icase, const re_dfa_t *dfa)
|
||||
{
|
||||
@ -63,7 +63,7 @@ re_string_allocate (re_string_t *pstr, const char *str, int len, int init_len,
|
||||
/* This function allocate the buffers, and initialize them. */
|
||||
|
||||
static reg_errcode_t
|
||||
internal_function __attribute_warn_unused_result__
|
||||
__attribute_warn_unused_result__
|
||||
re_string_construct (re_string_t *pstr, const char *str, int len,
|
||||
RE_TRANSLATE_TYPE trans, int icase, const re_dfa_t *dfa)
|
||||
{
|
||||
@ -126,7 +126,7 @@ re_string_construct (re_string_t *pstr, const char *str, int len,
|
||||
/* Helper functions for re_string_allocate, and re_string_construct. */
|
||||
|
||||
static reg_errcode_t
|
||||
internal_function __attribute_warn_unused_result__
|
||||
__attribute_warn_unused_result__
|
||||
re_string_realloc_buffers (re_string_t *pstr, int new_buf_len)
|
||||
{
|
||||
#ifdef RE_ENABLE_I18N
|
||||
@ -166,7 +166,6 @@ re_string_realloc_buffers (re_string_t *pstr, int new_buf_len)
|
||||
|
||||
|
||||
static void
|
||||
internal_function
|
||||
re_string_construct_common (const char *str, int len, re_string_t *pstr,
|
||||
RE_TRANSLATE_TYPE trans, int icase,
|
||||
const re_dfa_t *dfa)
|
||||
@ -198,7 +197,6 @@ re_string_construct_common (const char *str, int len, re_string_t *pstr,
|
||||
built and starts from PSTR->VALID_LEN. */
|
||||
|
||||
static void
|
||||
internal_function
|
||||
build_wcs_buffer (re_string_t *pstr)
|
||||
{
|
||||
#ifdef _LIBC
|
||||
@ -267,7 +265,7 @@ build_wcs_buffer (re_string_t *pstr)
|
||||
but for REG_ICASE. */
|
||||
|
||||
static reg_errcode_t
|
||||
internal_function __attribute_warn_unused_result__
|
||||
__attribute_warn_unused_result__
|
||||
build_wcs_upper_buffer (re_string_t *pstr)
|
||||
{
|
||||
mbstate_t prev_st;
|
||||
@ -486,7 +484,6 @@ build_wcs_upper_buffer (re_string_t *pstr)
|
||||
Return the index. */
|
||||
|
||||
static int
|
||||
internal_function
|
||||
re_string_skip_chars (re_string_t *pstr, int new_raw_idx, wint_t *last_wc)
|
||||
{
|
||||
mbstate_t prev_st;
|
||||
@ -527,7 +524,6 @@ re_string_skip_chars (re_string_t *pstr, int new_raw_idx, wint_t *last_wc)
|
||||
This function is used in case of REG_ICASE. */
|
||||
|
||||
static void
|
||||
internal_function
|
||||
build_upper_buffer (re_string_t *pstr)
|
||||
{
|
||||
int char_idx, end_idx;
|
||||
@ -550,7 +546,6 @@ build_upper_buffer (re_string_t *pstr)
|
||||
/* Apply TRANS to the buffer in PSTR. */
|
||||
|
||||
static void
|
||||
internal_function
|
||||
re_string_translate_buffer (re_string_t *pstr)
|
||||
{
|
||||
int buf_idx, end_idx;
|
||||
@ -571,7 +566,7 @@ re_string_translate_buffer (re_string_t *pstr)
|
||||
convert to upper case in case of REG_ICASE, apply translation. */
|
||||
|
||||
static reg_errcode_t
|
||||
internal_function __attribute_warn_unused_result__
|
||||
__attribute_warn_unused_result__
|
||||
re_string_reconstruct (re_string_t *pstr, int idx, int eflags)
|
||||
{
|
||||
int offset = idx - pstr->raw_mbs_idx;
|
||||
@ -831,7 +826,7 @@ re_string_reconstruct (re_string_t *pstr, int idx, int eflags)
|
||||
}
|
||||
|
||||
static unsigned char
|
||||
internal_function __attribute ((pure))
|
||||
__attribute ((pure))
|
||||
re_string_peek_byte_case (const re_string_t *pstr, int idx)
|
||||
{
|
||||
int ch, off;
|
||||
@ -867,7 +862,6 @@ re_string_peek_byte_case (const re_string_t *pstr, int idx)
|
||||
}
|
||||
|
||||
static unsigned char
|
||||
internal_function
|
||||
re_string_fetch_byte_case (re_string_t *pstr)
|
||||
{
|
||||
if (BE (!pstr->mbs_allocated, 1))
|
||||
@ -904,7 +898,6 @@ re_string_fetch_byte_case (re_string_t *pstr)
|
||||
}
|
||||
|
||||
static void
|
||||
internal_function
|
||||
re_string_destruct (re_string_t *pstr)
|
||||
{
|
||||
#ifdef RE_ENABLE_I18N
|
||||
@ -918,7 +911,6 @@ re_string_destruct (re_string_t *pstr)
|
||||
/* Return the context at IDX in INPUT. */
|
||||
|
||||
static unsigned int
|
||||
internal_function
|
||||
re_string_context_at (const re_string_t *input, int idx, int eflags)
|
||||
{
|
||||
int c;
|
||||
@ -963,7 +955,7 @@ re_string_context_at (const re_string_t *input, int idx, int eflags)
|
||||
/* Functions for set operation. */
|
||||
|
||||
static reg_errcode_t
|
||||
internal_function __attribute_warn_unused_result__
|
||||
__attribute_warn_unused_result__
|
||||
re_node_set_alloc (re_node_set *set, int size)
|
||||
{
|
||||
set->alloc = size;
|
||||
@ -975,7 +967,7 @@ re_node_set_alloc (re_node_set *set, int size)
|
||||
}
|
||||
|
||||
static reg_errcode_t
|
||||
internal_function __attribute_warn_unused_result__
|
||||
__attribute_warn_unused_result__
|
||||
re_node_set_init_1 (re_node_set *set, int elem)
|
||||
{
|
||||
set->alloc = 1;
|
||||
@ -991,7 +983,7 @@ re_node_set_init_1 (re_node_set *set, int elem)
|
||||
}
|
||||
|
||||
static reg_errcode_t
|
||||
internal_function __attribute_warn_unused_result__
|
||||
__attribute_warn_unused_result__
|
||||
re_node_set_init_2 (re_node_set *set, int elem1, int elem2)
|
||||
{
|
||||
set->alloc = 2;
|
||||
@ -1021,7 +1013,7 @@ re_node_set_init_2 (re_node_set *set, int elem1, int elem2)
|
||||
}
|
||||
|
||||
static reg_errcode_t
|
||||
internal_function __attribute_warn_unused_result__
|
||||
__attribute_warn_unused_result__
|
||||
re_node_set_init_copy (re_node_set *dest, const re_node_set *src)
|
||||
{
|
||||
dest->nelem = src->nelem;
|
||||
@ -1046,7 +1038,7 @@ re_node_set_init_copy (re_node_set *dest, const re_node_set *src)
|
||||
Note: We assume dest->elems is NULL, when dest->alloc is 0. */
|
||||
|
||||
static reg_errcode_t
|
||||
internal_function __attribute_warn_unused_result__
|
||||
__attribute_warn_unused_result__
|
||||
re_node_set_add_intersect (re_node_set *dest, const re_node_set *src1,
|
||||
const re_node_set *src2)
|
||||
{
|
||||
@ -1137,7 +1129,7 @@ re_node_set_add_intersect (re_node_set *dest, const re_node_set *src1,
|
||||
DEST. Return value indicate the error code or REG_NOERROR if succeeded. */
|
||||
|
||||
static reg_errcode_t
|
||||
internal_function __attribute_warn_unused_result__
|
||||
__attribute_warn_unused_result__
|
||||
re_node_set_init_union (re_node_set *dest, const re_node_set *src1,
|
||||
const re_node_set *src2)
|
||||
{
|
||||
@ -1190,7 +1182,7 @@ re_node_set_init_union (re_node_set *dest, const re_node_set *src1,
|
||||
DEST. Return value indicate the error code or REG_NOERROR if succeeded. */
|
||||
|
||||
static reg_errcode_t
|
||||
internal_function __attribute_warn_unused_result__
|
||||
__attribute_warn_unused_result__
|
||||
re_node_set_merge (re_node_set *dest, const re_node_set *src)
|
||||
{
|
||||
int is, id, sbase, delta;
|
||||
@ -1273,7 +1265,7 @@ re_node_set_merge (re_node_set *dest, const re_node_set *src)
|
||||
return -1 if an error is occured, return 1 otherwise. */
|
||||
|
||||
static int
|
||||
internal_function __attribute_warn_unused_result__
|
||||
__attribute_warn_unused_result__
|
||||
re_node_set_insert (re_node_set *set, int elem)
|
||||
{
|
||||
int idx;
|
||||
@ -1330,7 +1322,7 @@ re_node_set_insert (re_node_set *set, int elem)
|
||||
Return -1 if an error is occured, return 1 otherwise. */
|
||||
|
||||
static int
|
||||
internal_function __attribute_warn_unused_result__
|
||||
__attribute_warn_unused_result__
|
||||
re_node_set_insert_last (re_node_set *set, int elem)
|
||||
{
|
||||
/* Realloc if we need. */
|
||||
@ -1353,7 +1345,7 @@ re_node_set_insert_last (re_node_set *set, int elem)
|
||||
return 1 if SET1 and SET2 are equivalent, return 0 otherwise. */
|
||||
|
||||
static int
|
||||
internal_function __attribute ((pure))
|
||||
__attribute ((pure))
|
||||
re_node_set_compare (const re_node_set *set1, const re_node_set *set2)
|
||||
{
|
||||
int i;
|
||||
@ -1368,7 +1360,7 @@ re_node_set_compare (const re_node_set *set1, const re_node_set *set2)
|
||||
/* Return (idx + 1) if SET contains the element ELEM, return 0 otherwise. */
|
||||
|
||||
static int
|
||||
internal_function __attribute ((pure))
|
||||
__attribute ((pure))
|
||||
re_node_set_contains (const re_node_set *set, int elem)
|
||||
{
|
||||
unsigned int idx, right, mid;
|
||||
@ -1390,7 +1382,6 @@ re_node_set_contains (const re_node_set *set, int elem)
|
||||
}
|
||||
|
||||
static void
|
||||
internal_function
|
||||
re_node_set_remove_at (re_node_set *set, int idx)
|
||||
{
|
||||
if (idx < 0 || idx >= set->nelem)
|
||||
@ -1405,7 +1396,6 @@ re_node_set_remove_at (re_node_set *set, int idx)
|
||||
Or return -1, if an error will be occured. */
|
||||
|
||||
static int
|
||||
internal_function
|
||||
re_dfa_add_node (re_dfa_t *dfa, re_token_t token)
|
||||
{
|
||||
int type = token.type;
|
||||
@ -1453,7 +1443,6 @@ re_dfa_add_node (re_dfa_t *dfa, re_token_t token)
|
||||
}
|
||||
|
||||
static inline unsigned int
|
||||
internal_function
|
||||
calc_state_hash (const re_node_set *nodes, unsigned int context)
|
||||
{
|
||||
unsigned int hash = nodes->nelem + context;
|
||||
@ -1473,7 +1462,7 @@ calc_state_hash (const re_node_set *nodes, unsigned int context)
|
||||
optimization. */
|
||||
|
||||
static re_dfastate_t *
|
||||
internal_function __attribute_warn_unused_result__
|
||||
__attribute_warn_unused_result__
|
||||
re_acquire_state (reg_errcode_t *err, const re_dfa_t *dfa,
|
||||
const re_node_set *nodes)
|
||||
{
|
||||
@ -1517,7 +1506,7 @@ re_acquire_state (reg_errcode_t *err, const re_dfa_t *dfa,
|
||||
optimization. */
|
||||
|
||||
static re_dfastate_t *
|
||||
internal_function __attribute_warn_unused_result__
|
||||
__attribute_warn_unused_result__
|
||||
re_acquire_state_context (reg_errcode_t *err, const re_dfa_t *dfa,
|
||||
const re_node_set *nodes, unsigned int context)
|
||||
{
|
||||
@ -1609,7 +1598,7 @@ free_state (re_dfastate_t *state)
|
||||
Return the new state if succeeded, otherwise return NULL. */
|
||||
|
||||
static re_dfastate_t *
|
||||
internal_function __attribute_warn_unused_result__
|
||||
__attribute_warn_unused_result__
|
||||
create_ci_newstate (const re_dfa_t *dfa, const re_node_set *nodes,
|
||||
unsigned int hash)
|
||||
{
|
||||
@ -1659,7 +1648,7 @@ create_ci_newstate (const re_dfa_t *dfa, const re_node_set *nodes,
|
||||
Return the new state if succeeded, otherwise return NULL. */
|
||||
|
||||
static re_dfastate_t *
|
||||
internal_function __attribute_warn_unused_result__
|
||||
__attribute_warn_unused_result__
|
||||
create_cd_newstate (const re_dfa_t *dfa, const re_node_set *nodes,
|
||||
unsigned int context, unsigned int hash)
|
||||
{
|
||||
|
Reference in New Issue
Block a user