|
|
@ -152,6 +152,8 @@ var reTests = []struct {
|
|
|
|
{"^((3[7-9])|([4-9][0-9])|([1-9][0-9][0-9])|(1000))$", "400", []Group{{0, 3}}},
|
|
|
|
{"^((3[7-9])|([4-9][0-9])|([1-9][0-9][0-9])|(1000))$", "400", []Group{{0, 3}}},
|
|
|
|
{"^((3[7-9])|([4-9][0-9])|([1-9][0-9][0-9])|(1000))$", "4000", []Group{}},
|
|
|
|
{"^((3[7-9])|([4-9][0-9])|([1-9][0-9][0-9])|(1000))$", "4000", []Group{}},
|
|
|
|
{"a{1,3}", "aaaaa", []Group{{0, 3}, {3, 5}}},
|
|
|
|
{"a{1,3}", "aaaaa", []Group{{0, 3}, {3, 5}}},
|
|
|
|
|
|
|
|
{`\\[ab\\]`, "a", []Group{}},
|
|
|
|
|
|
|
|
{`\\[ab\\]`, `\a`, []Group{{0, 2}}},
|
|
|
|
|
|
|
|
|
|
|
|
// Lookaround tests
|
|
|
|
// Lookaround tests
|
|
|
|
{"(?<=bo)y", "boy", []Group{{2, 3}}},
|
|
|
|
{"(?<=bo)y", "boy", []Group{{2, 3}}},
|
|
|
|