Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在使用 regsub 将 (T|Z) 替换为空格
set date(1,2) "2012-09-14T00:00:00Z" regsub -all {(T|Z)} $date(1,2) " " date(1,2) puts $date(1,2)
但是当我使用
regsub -all {(T|Z)} $date(1,2) "\s" date(1,2)
它正在用 \s 替换 T|Z 。
如何将单个空格字符映射到“\s”以使代码清晰可见
替换"\s"为" "
"\s"
" "
\s