mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Add missing rb_enc_iscntrl
This commit is contained in:
parent
9a11d50dc7
commit
a201cfd0cd
Notes:
git
2022-08-12 15:56:51 +09:00
1 changed files with 15 additions and 0 deletions
|
|
@ -126,6 +126,20 @@ rb_enc_isupper(OnigCodePoint c, rb_encoding *enc)
|
||||||
return ONIGENC_IS_CODE_UPPER(enc, c);
|
return ONIGENC_IS_CODE_UPPER(enc, c);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Identical to rb_iscntrl(), except it additionally takes an encoding.
|
||||||
|
*
|
||||||
|
* @param[in] c A code point.
|
||||||
|
* @param[in] enc An encoding.
|
||||||
|
* @retval true `enc` classifies `c` as "CNTRL".
|
||||||
|
* @retval false Otherwise.
|
||||||
|
*/
|
||||||
|
static inline bool
|
||||||
|
rb_enc_iscntrl(OnigCodePoint c, rb_encoding *enc)
|
||||||
|
{
|
||||||
|
return ONIGENC_IS_CODE_CNTRL(enc, c);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Identical to rb_ispunct(), except it additionally takes an encoding.
|
* Identical to rb_ispunct(), except it additionally takes an encoding.
|
||||||
*
|
*
|
||||||
|
|
@ -235,6 +249,7 @@ RBIMPL_SYMBOL_EXPORT_END()
|
||||||
#define rb_enc_isdigit rb_enc_isdigit
|
#define rb_enc_isdigit rb_enc_isdigit
|
||||||
#define rb_enc_islower rb_enc_islower
|
#define rb_enc_islower rb_enc_islower
|
||||||
#define rb_enc_isprint rb_enc_isprint
|
#define rb_enc_isprint rb_enc_isprint
|
||||||
|
#define rb_enc_iscntrl rb_enc_iscntrl
|
||||||
#define rb_enc_ispunct rb_enc_ispunct
|
#define rb_enc_ispunct rb_enc_ispunct
|
||||||
#define rb_enc_isspace rb_enc_isspace
|
#define rb_enc_isspace rb_enc_isspace
|
||||||
#define rb_enc_isupper rb_enc_isupper
|
#define rb_enc_isupper rb_enc_isupper
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue