在线咨询
eetop公众号 创芯大讲堂 创芯人才网
切换到宽版

EETOP 创芯网论坛 (原名:电子顶级开发网)

手机号码,快捷登录

手机号码,快捷登录

找回密码

  登录   注册  

快捷导航
搜帖子
查看: 3446|回复: 2

[求助] tcl中如何跨行匹配

[复制链接]
发表于 2014-1-16 17:00:11 | 显示全部楼层 |阅读模式

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有账号?注册

x
tcl中如何跨行匹配, 求正则表达,谢谢!
发表于 2014-1-16 21:39:56 | 显示全部楼层
试试看这个:

regexp
-line

Enables newline-sensitive matching. By default, newline is a completely ordinary character with no special meaning. With this flag, “[^” bracket expressions and “.” never match newline, “^” matches an empty string after any newline in addition to its normal function, and “$” matches an empty string before any newline in addition to its normal function. This flag is equivalent to specifying both -linestop and -lineanchor, or the (?n) embedded option (see the re_syntax manual page).
 楼主| 发表于 2014-1-20 18:15:40 | 显示全部楼层
回复 2# sjtusonic


    Hi, 版主:

    regexp -line应该只对单行进行操作,属于行敏感,
    我如果在多行匹配,应该用 -inline, 我已经尝试过并且解决了, 谢谢!
您需要登录后才可以回帖 登录 | 注册

本版积分规则

关闭

站长推荐 上一条 /1 下一条

小黑屋| 关于我们| 联系我们| 在线咨询| 隐私声明| EETOP 创芯网
( 京ICP备:10050787号 京公网安备:11010502037710 )

GMT+8, 2024-3-29 18:22 , Processed in 0.017950 second(s), 8 queries , Gzip On, Redis On.

eetop公众号 创芯大讲堂 创芯人才网
快速回复 返回顶部 返回列表