diff options
author | Yusuke Endoh <mame@ruby-lang.org> | 2022-03-24 16:59:11 +0900 |
---|---|---|
committer | Yusuke Endoh <mame@ruby-lang.org> | 2022-03-30 16:50:46 +0900 |
commit | ffc3b37f969a779f93b8f8a5b3591b4ef7de1538 (patch) | |
tree | 25b2d942e8eb2c4a73043773edfcfd6c0d709155 /include | |
parent | 23530d68cb04aed9c2f59a050523b0193ee2d0c1 (diff) | |
download | ruby-ffc3b37f969a779f93b8f8a5b3591b4ef7de1538.tar.gz |
re.c: Add Regexp.timeout= and Regexp.timeout
[Feature #17837]
Diffstat (limited to 'include')
-rw-r--r-- | include/ruby/onigmo.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/ruby/onigmo.h b/include/ruby/onigmo.h index 6187b37dc3..a7ef59c7c8 100644 --- a/include/ruby/onigmo.h +++ b/include/ruby/onigmo.h @@ -793,6 +793,13 @@ typedef struct re_pattern_buffer { OnigDistance dmin; /* min-distance of exact or map */ OnigDistance dmax; /* max-distance of exact or map */ + /* rb_hrtime_t from hrtime.h */ +#ifdef MY_RUBY_BUILD_MAY_TIME_TRAVEL + int128_t timelimit; +#else + uint64_t timelimit; +#endif + /* regex_t link chain */ struct re_pattern_buffer* chain; /* escape compile-conflict */ } OnigRegexType; |