最近发布的主题
- Go基础 Golang语法详解笔记 at
最近发布的文章
暂无
最近分享的资源
最近发布的项目
暂无
最近的评论
-
先把 `$GOPATH/bin`加到系统环境变量`PATH`中.
-
评论了主题 为什么go语言不能有注解啊难道Java里面有`struct tag` ?
-
评论了主题 弱弱问下 GO 密文输入有什么可以实现。。。
-
评论了主题 弱弱问下 GO 密文输入有什么可以实现。。。仅限Linux: ```go package main func main() { pwd = new(string) terminalEcho(false) // Hide input fmt.Scanln(pwd) terminalEcho(true) fmt.Println(pwd) } func terminalEcho(show bool) { // Enable or disable echoing terminal input. This is useful specifically for // when users enter passwords. // calling terminalEcho(true) turns on echoing (normal mode) // calling terminalEcho(false) hides terminal input. var termios = &syscall.Termios{} var fd = os.Stdout.Fd() if _, _, err := syscall.Syscall(syscall.SYS_IOCTL, fd, syscall.TCGETS, uintptr(unsafe.Pointer(termios))); err != 0 { return } if show { termios.Lflag |= syscall.ECHO } else { termios.Lflag &^= syscall.ECHO } if _, _, err := syscall.Syscall(syscall.SYS_IOCTL, fd, uintptr(syscall.TCSETS), uintptr(unsafe.Pointer(termios))); err != 0 { return } } ```
-
评论了主题 寻一个go语法例子大全文件Google Go语言 golang 语法详解笔记 http://yougg.github.io/static/gonote/gogrammar.html