walk
walk copied to clipboard
Windows 10 to go build err
PS E:\go\xlsl\gui> ls
目录: E:\go\xlsl\gui
Mode LastWriteTime Length Name
-a---- 2020/12/4 星期五 16:0 1069 rsrc.syso 6 -a---- 2020/12/4 星期五 16:0 889 test.manifest 0 -a---- 2020/12/4 星期五 15:5 627 walktest1.go 8
PS E:\go\xlsl\gui> go build # golang.org/x/sys/windows E:\go\src\golang.org\x\sys\windows\exec_windows.go:94:28: cannot use buf[:n] (type []uint16) as type *uint16 in argument to UTF16ToString E:\go\src\golang.org\x\sys\windows\security_windows.go:50:26: cannot use b[:n] (type []uint16) as type *uint16 in argument to UTF16ToString E:\go\src\golang.org\x\sys\windows\security_windows.go:221:29: cannot use db (type []uint16) as type uint16 in argument to UTF16ToString E:\go\src\golang.org\x\sys\windows\security_windows.go:241:56: cannot use ([256]uint16)(unsafe.Pointer(s))[:] (type []uint16) as type *uint16 in argument to UTF16ToString E:\go\src\golang.org\x\sys\windows\security_windows.go:278:24: cannot use b (type []uint16) as type *uint16 in argument to UTF16ToString E:\go\src\golang.org\x\sys\windows\security_windows.go:278:42: cannot use db (type []uint16) as type *uint16 in argument to UTF16ToString E:\go\src\golang.org\x\sys\windows\security_windows.go:460:24: cannot use b (type []uint16) as type *uint16 in argument to UTF16ToString E:\go\src\golang.org\x\sys\windows\syscall_windows.go:86:14: cannot range over s (type *uint16) E:\go\src\golang.org\x\sys\windows\syscall_windows.go:88:9: cannot slice s (type *uint16) E:\go\src\golang.org\x\sys\windows\syscall_windows.go:92:28: cannot use s (type *uint16) as type []uint16 in argument to utf16.Decode E:\go\src\golang.org\x\sys\windows\syscall_windows.go:92:28: too many errors PS E:\go\xlsl\gui> go build -ldflags="-H windowsgui" # golang.org/x/sys/windows E:\go\src\golang.org\x\sys\windows\exec_windows.go:94:28: cannot use buf[:n] (type []uint16) as type *uint16 in argument to UTF16ToString E:\go\src\golang.org\x\sys\windows\security_windows.go:50:26: cannot use b[:n] (type []uint16) as type *uint16 in argument to UTF16ToString E:\go\src\golang.org\x\sys\windows\security_windows.go:221:29: cannot use db (type []uint16) as type uint16 in argument to UTF16ToString E:\go\src\golang.org\x\sys\windows\security_windows.go:241:56: cannot use ([256]uint16)(unsafe.Pointer(s))[:] (type []uint16) as type *uint16 in argument to UTF16ToString E:\go\src\golang.org\x\sys\windows\security_windows.go:278:24: cannot use b (type []uint16) as type *uint16 in argument to UTF16ToString E:\go\src\golang.org\x\sys\windows\security_windows.go:278:42: cannot use db (type []uint16) as type *uint16 in argument to UTF16ToString E:\go\src\golang.org\x\sys\windows\security_windows.go:460:24: cannot use b (type []uint16) as type *uint16 in argument to UTF16ToString E:\go\src\golang.org\x\sys\windows\syscall_windows.go:86:14: cannot range over s (type *uint16) E:\go\src\golang.org\x\sys\windows\syscall_windows.go:88:9: cannot slice s (type *uint16) E:\go\src\golang.org\x\sys\windows\syscall_windows.go:92:28: cannot use s (type *uint16) as type []uint16 in argument to utf16.Decode E:\go\src\golang.org\x\sys\windows\syscall_windows.go:92:28: too many errors PS E:\go\xlsl\gui>
Could you maybe provide us the walktest1.go file content ?
You should update golang.org/x/sys