The Example in the README does not make sense to me, but I might be missing something. Specifically, the foo.baz == true example expression. Nowhere else in the example does baz appear, and foo appears twice. First, in the struct tags. Second, in the map. I think that the Z field may have been mislabeled in the example, because foo.baz == true evaluating to true would make sense if Z was labeled as baz.
The correction would be as follows:
type Example struct {
// ...
Z bool `bexpr:"foo"`
// ...
}
Goes to
type Example struct {
// ...
Z bool `bexpr:"baz"`
// ...
}
If I'm not missing anything and this is actually correct, I can open a quick PR to fix this.
The Example in the README does not make sense to me, but I might be missing something. Specifically, the
foo.baz == trueexample expression. Nowhere else in the example doesbazappear, andfooappears twice. First, in the struct tags. Second, in the map. I think that theZfield may have been mislabeled in the example, becausefoo.baz == trueevaluating to true would make sense ifZwas labeled asbaz.The correction would be as follows:
Goes to
If I'm not missing anything and this is actually correct, I can open a quick PR to fix this.