/* Extended regular expression matching and search library.
Copyright (C) 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Isamu Hasegawa <isamu@yamato.ibm.com>.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License along
with this program; if not, write to the Free Software Foundation,
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */
static reg_errcode_t match_ctx_init (re_match_context_t *cache, int eflags,
Idx n) internal_function;
static void match_ctx_clean (re_match_context_t *mctx) internal_function;
static void match_ctx_free (re_match_context_t *cache) internal_function;
static reg_errcode_t match_ctx_add_entry (re_match_context_t *cache, Idx node,
Idx str_idx, Idx from, Idx to)
internal_function;
static Idx search_cur_bkref_entry (const re_match_context_t *mctx, Idx str_idx)
internal_function;
static reg_errcode_t match_ctx_add_subtop (re_match_context_t *mctx, Idx node,
Idx str_idx) internal_function;
static re_sub_match_last_t * match_ctx_add_sublast (re_sub_match_top_t *subtop,
Idx node, Idx str_idx)
internal_function;
static void sift_ctx_init (re_sift_context_t *sctx, re_dfastate_t **sifted_sts,
re_dfastate_t **limited_sts, Idx last_node,
Idx last_str_idx)
internal_function;
static reg_errcode_t re_search_internal (const regex_t *preg,
const char *string, Idx length,
Idx start, Idx last_start, Idx stop,
size_t nmatch, regmatch_t pmatch[],
int eflags) internal_function;
static regoff_t re_search_2_stub (struct re_pattern_buffer *bufp,
const char *string1, Idx length1,
const char *string2, Idx length2,
Idx start, regoff_t range,
struct re_registers *regs,
Idx stop, bool ret_len) internal_function;
static regoff_t re_search_stub (struct re_pattern_buffer *bufp,
const char *string, Idx length, Idx start,
regoff_t range, Idx stop,
struct re_registers *regs,
bool ret_len) internal_function;
static unsigned int re_copy_regs (struct re_registers *regs, regmatch_t *pmatch,
Idx nregs, int regs_allocated)
internal_function;
static reg_errcode_t prune_impossible_nodes (re_match_context_t *mctx)
internal_function;
static Idx check_matching (re_match_context_t *mctx, bool fl_longest_match,
Idx *p_match_first) internal_function;
static Idx check_halt_state_context (const re_match_context_t *mctx,
const re_dfastate_t *state, Idx idx)
internal_function;
static void update_regs (const re_dfa_t *dfa, regmatch_t *pmatch,
regmatch_t *prev_idx_match, Idx cur_node,
Idx cur_idx, Idx nmatch) internal_function;
static reg_errcode_t push_fail_stack (struct re_fail_stack_t *fs,
Idx str_idx, Idx dest_node, Idx nregs,
regmatch_t *regs,
re_node_set *eps_via_nodes)
internal_function;
static reg_errcode_t set_regs (const regex_t *preg,
const re_match_context_t *mctx,
size_t nmatch, regmatch_t *pmatch,
bool fl_backtrack) internal_function;
static reg_errcode_t free_fail_stack_return (struct re_fail_stack_t *fs)
internal_function;
#ifdef RE_ENABLE_I18N
static int sift_states_iter_mb (const re_match_context_t *mctx,
re_sift_context_t *sctx,
Idx node_idx, Idx str_idx, Idx max_str_idx)
internal_function;
#endif /* RE_ENABLE_I18N */
static reg_errcode_t sift_states_backward (const re_match_context_t *mctx,
re_sift_context_t *sctx)
internal_function;
static reg_errcode_t build_sifted_states (const re_match_context_t *mctx,
re_sift_context_t *sctx, Idx str_idx,
re_node_set *cur_dest)
internal_function;
static reg_errcode_t update_cur_sifted_state (const re_match_context_t *mctx,
re_sift_context_t *sctx,
Idx str_idx,
re_node_set *dest_nodes)
internal_function;
static reg_errcode_t add_epsilon_src_nodes (const re_dfa_t *dfa,
re_node_set *dest_nodes,
const re_node_set *candidates)
internal_function;
static bool check_dst_limits (const re_match_context_t *mctx,
const re_node_set *limits,
Idx dst_node, Idx dst_idx, Idx src_node,
Idx src_idx) internal_function;
static int check_dst_limits_calc_pos_1 (const re_match_context_t *mctx,
int boundaries, Idx subexp_idx,
Idx from_node, Idx bkref_idx)
internal_function;
static int check_dst_limits_calc_pos (const re_match_context_t *mctx,
Idx limit, Idx subexp_idx,
Idx node, Idx str_idx,
Idx bkref_idx) internal_function;
static reg_errcode_t check_subexp_limits (const re_dfa_t *dfa,
re_node_set *dest_nodes,
const re_node_set *candidates,
re_node_set *limits,
struct re_backref_cache_entry *bkref_ents,
Idx str_idx) internal_function;
static reg_errcode_t sift_states_bkref (const re_match_context_t *mctx,
re_sift_context_t *sctx,
Idx str_idx, const re_node_set *candidates)
internal_function;
static reg_errcode_t merge_state_array (const re_dfa_t *dfa,
re_dfastate_t **dst,
re_dfastate_t **src, Idx num)
internal_function;
static re_dfastate_t *find_recover_state (reg_errcode_t *err,
re_match_context_t *mctx) internal_function;
static re_dfastate_t *transit_state (reg_errcode_t *err,
re_match_context_t *mctx,
re_dfastate_t *state) internal_function;
static re_dfastate_t *merge_state_with_log (reg_errcode_t *err,
re_match_context_t *mctx,
re_dfastate_t *next_state)
internal_function;
static reg_errcode_t check_subexp_matching_top (re_match_context_t *mctx,
re_node_set *cur_nodes,
Idx str_idx) internal_function;
#if 0
static re_dfastate_t *transit_state_sb (reg_errcode_t *err,
re_match_context_t *mctx,
re_dfastate_t *pstate)
internal_function;
#endif
#ifdef RE_ENABLE_I18N
static reg_errcode_t transit_state_mb (re_match_context_t *mctx,
re_dfastate_t *pstate)
internal_function;
#endif /* RE_ENABLE_I18N */
static reg_errcode_t transit_state_bkref (re_match_context_t *mctx,
const re_node_set *nodes)
internal_function;
static reg_errcode_t get_subexp (re_match_context_t *mctx,
Idx bkref_node, Idx bkref_str_idx)
internal_function;
static reg_errcode_t get_subexp_sub (re_match_context_t *mctx,
const re_sub_match_top_t *sub_top,
re_sub_match_last_t *sub_last,
Idx bkref_node, Idx bkref_str)
internal_function;
static Idx find_subexp_node (const re_dfa_t *dfa, const re_node_set *nodes,
Idx subexp_idx, int type) internal_function;
static reg_errcode_t check_arrival (re_match_context_t *mctx,
state_array_t *path, Idx top_node,
Idx top_str, Idx last_node, Idx last_str,
int type) internal_function;
static reg_errcode_t check_arrival_add_next_nodes (re_match_context_t *mctx,
Idx str_idx,
re_node_set *cur_nodes,
re_node_set *next_nodes)
internal_function;
static reg_errcode_t check_arrival_expand_ecl (const re_dfa_t *dfa,
re_node_set *cur_nodes,
Idx ex_subexp, int type)
internal_function;
static reg_errcode_t check_arrival_expand_ecl_sub (const re_dfa_t *dfa,
re_node_set *dst_nodes,
Idx target, Idx ex_subexp,
int type) internal_function;
static reg_errcode_t expand_bkref_cache (re_match_context_t *mctx,
re_node_set *cur_n
程序员Chino的日记
- 粉丝: 3770
- 资源: 5万+
最新资源
- 滑膜控制与模糊规则融合的后轮主动稳定控制策略:协同稳定性与轨迹跟踪优化,基于滑膜控制的后轮主动(ARS)和DYC的协调稳定性控制,上层根据模糊控制规则和滑膜控制产生期望后轮转角ARS和附加横摆力矩Mz
- 四旋翼ADRC控制器仿真结果详解:C语言代码生成与单片机运行研究指南,四旋翼ADRC控制器仿真,已调好 已经生成C语言了,要放到单片机运行的伙伴可以拿去研究 ,四旋翼; ADRC控制器; 仿真;
- 基于二次规划(QP)的Piecesie Jerk路径规划与速度规划Matlab实现与详细文档和C++实现可视化界面,基于二次规划(QP)的路径规划和速度规划 matlab代码实现 + 详细文档 pic
- 单相单极性SPWM调制电压型逆变器的仿真研究:自定义载波与调制波参数及调制比功能探究,单相单极性SPWM调制的电压型逆变仿真 自己搭建的单极性SPWM发波模块,可以方便的设置载波和调制波频率,以及调
- 三相PWM整流器闭环仿真研究:电压电流双闭环控制下的SVPWM与升压拓扑模型分析,三相PWM整流器闭环仿真,电压电流双闭环控制,输出直流电压做外环 模型中包含主电路,坐标变,电压电流双环PI控制器,S
- 基于容积卡尔曼滤波与滑膜控制的永磁同步电机无传感器控制技术研究:状态估计与控制精度提升的实践研究,基于容积卡尔曼以及滑膜控制的的永磁同步电机无传感器控制,无传感器采用的是容积卡尔曼滤波对转速及转子位置
- DSP28335与FPGA SPI通信:C语言与Verilog代码的联合实现,DSP28335与FPGA进行SPI通信,DSP为C语言代码,FPGA为verilog代码 ,核心关键词:DSP28335
- 磁耦合谐振式无线电能传输电路系统板LCC-S拓扑补偿网络:STM32主控与ESP通讯的电能传输与显示方案,磁耦合谐振式 无线电能传输电路系统板 LCC-S拓扑补偿网络 发射端电路采用Stm32f103
- 自动驾驶纵向控制:Apollo双PID纵向位置跟踪技术解析与实现,自动驾驶纵向控制-复现Apollo双pid纵向位置跟踪 复现百度apollo纵向控制 纵向控制已经制作好油门刹车标定表,无需自己做标定
- 基于Multisim仿真的水箱水位检测控制系统设计与实现:实时监测、分级控制及越线警报系统,数电设计水箱水位检测控制系统multisim仿真+设计报告+ 水箱水位控制系统仿真功能: 1.在水箱内的不同
- 基于模型图的风储调频和储能调频技术真实应用与实践探索,风储调频,储能调频,保证真实,模型如图,保证正常使用 ,风储调频; 储能调频; 真实保证; 模型; 正常使用,"风储调频与储能保障系统:真实可靠
- Prius 2004永磁同步电机设计详解:从设计程序到建模仿真与温升分析,Prius2004永磁同步电机设计报告: 磁路法、maxwell有限元法、MotorCAD温仿真、应力分析 (内容比较完善
- "COMSOL模拟随机裂隙注浆:浆液粘度影响下的扩散研究",comsol模拟随机裂隙注浆,浆液在多孔介质和裂隙中扩散,考虑浆液粘度时变性 ,关键词:Comsol模拟;随机裂隙注浆;浆液扩散;多孔介质
- 铅酸电池失效仿真模拟:COMSOL多物理场分析软件的应用探索,铅酸电池失效仿真comsol ,核心关键词:铅酸电池失效仿真; comsol; 电池仿真; 失效模式; 铅酸电池性能 ,"基于Comsol
- Cruise与Simulink联合仿真:纯电动汽车动力经济性研究,含BMS策略、再生制动及电机驱动详解,纯电动汽车动力经济性仿真,Cruise和Simulink联合仿真,提供Cruise整车模型和si
- "改进蚁群算法与动态窗口算法融合全局与局部路径规划仿真:多场景对比实验报告",改进蚁群算法+动态窗口算法全局结合局部路径规划仿真 静态路径规划算法 采用改进蚁群算法,有单独对比代码 动态实时规划 采
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈