using uCalcSoftware;

var uc = new uCalc();

// Here we define < and > as a bracket pair.
// Such pairs can be part of a pattern match
// and a match can be found within a bracket pair
// but a match will not cross boundaries with one
// part of the match out and another part inside

var t = uc.NewTransformer();
var txt = "a < b c > c, < a > b c, < a b c >";

t.Tokens.Add("<", TokenType.Generic, ">");
t.FromTo("a {etc} c", "((a {etc} c))");

Console.WriteLine(txt);
Console.WriteLine(t.Transform(txt));