I have a quick question on string pattern matching and string replacement.
Basically I wanted to replace the name inside the ** pattern and match it with @path string.
if(match(("*%s*",name),s@path)
But It cant identify the **s and compares only with raw string “name”, can anyone please let me know how to do this.
below is my full code
s[]@groupNames = {"trunk","leaves","branch"}; foreach (string name; @groupNames) { if(match(("*%s*",name),s@path)==1){ setprimgroup(0,name,@primnum,1,"set"); } }
Thanks in advance.