JOEY BOYD <joey.b...@adtran.com> wrote: > Hi all, > > Currently, it's not allowed to do the following as you cannot wrap > case statements in a grouping. > > grouping common-cases { > case b { > leaf b { > } > } > > case c { > leaf c { > } > } > } > > container alpha { > choice my-first-choice { > case a { > leaf a { > } > } > > uses common-cases; > } > } > > container beta { > choice my-second-choice { > case d { > leaf d { > } > } > uses common-cases; > } > } > > > > I was wondering why this restriction is in place. I know you have to > be careful with name collisions but that's true of just a grouping of > leafs. Am I missing something?
This could maybe have been considered. Such a grouping would of course only be allowed to be used in a choice, and it would be limited to define *only* case nodes. As such it is a bit different than other groupings. Note that you can achieve a similar effect by doing: grouping choice-with-common-cases { choice the-choice { case b { leaf b { } } case c { leaf c { } } } } container alpha { uses choice-with-common-cases { augment "the-choice" { case a { leaf a { } } } } } container beta { uses choice-with-common-cases { augment "the-choice" { case d { leaf d { } } } } } /martin _______________________________________________ netmod mailing list netmod@ietf.org https://www.ietf.org/mailman/listinfo/netmod