Quantcast
Channel: Cadence Custom IC Skill Forum
Viewing all articles
Browse latest Browse all 5186

Replace a pattern with groups using pcre or regex

$
0
0

If I have a a string say:

myString="((pPar(\"area\"))*(pPar(\"mi\")))" 

I want to convert it to myStringAfter = area*mi 

If I use recReplace or pcre functions, I an getting myStringAfter=(area)*(mi)

But, I can not evaluate as (mi) or (area) are considered as functions in Skill for my purpose.

Is there any way I can use pPar(\"[a-z A-Z 0-9]+\") or any smart regular expressions and group the "area" and "mi" and replace them without open and close brackets?

I tried in possible combinations, and I am not successful so far.

Regards,

Venu


Viewing all articles
Browse latest Browse all 5186

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>