This commit is contained in:
bluepython508 committed 2026-10-22 12:27:19 +01:00
1 parent 3530afb854
commit 6903fcff27
2146 files changed
+112256 -190703

No files matched your search

+7 -7
View File
@@ -52,9 +52,9 @@ func (h *defaultHandler) introspectPath(path ObjectPath) string {
if p != "/" {
p += "/"
}
if strings.HasPrefix(string(obj), p) {
node_name := strings.Split(string(obj[len(p):]), "/")[0]
subpath[node_name] = struct{}{}
if after, ok := strings.CutPrefix(string(obj), p); ok {
name, _, _ := strings.Cut(after, "/")
subpath[name] = struct{}{}
}
}
for s := range subpath {
@@ -117,7 +117,7 @@ type exportedMethod struct {
reflect.Value
}
func (m exportedMethod) Call(args ...interface{}) ([]interface{}, error) {
func (m exportedMethod) Call(args ...any) ([]any, error) {
t := m.Type()
params := make([]reflect.Value, len(args))
@@ -143,7 +143,7 @@ func (m exportedMethod) Call(args ...interface{}) ([]interface{}, error) {
ret = ret[:t.NumOut()-1]
}
}
out := make([]interface{}, len(ret))
out := make([]any, len(ret))
for i, val := range ret {
out[i] = val.Interface()
}
@@ -158,7 +158,7 @@ func (m exportedMethod) NumArguments() int {
return m.Value.Type().NumIn()
}
func (m exportedMethod) ArgumentValue(i int) interface{} {
func (m exportedMethod) ArgumentValue(i int) any {
return reflect.Zero(m.Type().In(i)).Interface()
}
@@ -166,7 +166,7 @@ func (m exportedMethod) NumReturns() int {
return m.Value.Type().NumOut()
}
func (m exportedMethod) ReturnValue(i int) interface{} {
func (m exportedMethod) ReturnValue(i int) any {
return reflect.Zero(m.Type().Out(i)).Interface()
}