Re: [請益] 刪除特殊字串, 保留其它內容(soved)

作者: nash7555 (Caspar)   2020-04-19 11:41:37
: 顯示如下:
: (7006): actual bit length 16 differs from formal bit length 13 for port
: "cfgbp_link2csr"
: (120): truncated value with size 64 to match size of target (32)
: (144): truncated value with size 64 to match size of target (32)
: (241): truncated value with size 5 to match size of target (4)
: 但是砍掉就還不知道怎麼做...
: 期望是:
: : actual bit length 16 differs from formal bit length 13 for port
: "cfgbp_link2csr"
: : truncated value with size 64 to match size of target (32)
: : truncated value with size 64 to match size of target (32)
: : truncated value with size 5 to match size of target (4)
研究出來用以下code可以搞定, 謝謝~
$string_2 =~ tr/^\([0-9]+\)//d;
就可以印出上述的要求了

Links booklink

Contact Us: admin [ a t ] ucptt.com