Improve types pkg (#668)

This commit is contained in:
Anton Medvedev
2024-06-05 01:14:25 +02:00
committed by GitHub
parent c953d0dde1
commit d0aa2e9136
7 changed files with 150 additions and 59 deletions
+2 -1
View File
@@ -6,6 +6,7 @@ import (
"strings"
"github.com/expr-lang/expr/checker/nature"
"github.com/expr-lang/expr/conf"
"github.com/expr-lang/expr/internal/deref"
)
@@ -84,7 +85,7 @@ func CreateDoc(i any) *Context {
PkgPath: deref.Type(reflect.TypeOf(i)).PkgPath(),
}
for name, t := range nature.Of(i).All() {
for name, t := range conf.Env(i).All() {
if _, ok := c.Variables[Identifier(name)]; ok {
continue
}