GoLang debugging operation method

藏色散人
Release: 2021-05-26 16:06:48
forward
3348 people have browsed it

The following tutorial column will introduce you to the goLang debugging operation method. I hope it will be helpful to friends in need! I went to a studygoLang today and found that the blog wanted to include an article. Not a bad start.

Then I found someone posted a debug thing. I honestly don't know where this stuff came from. Do not understand.

You can only find it yourself. I found his github address later.

go get github.com/mailgun/godebug
go install   github.com/mailgun/godebug
Copy after login

After the installation is completed. Run the godebug command to see if

package main

import (
	"fmt"
)

func main() {
	_ = "brakpoint"
	x := "debugger"
	debug_funtion(x)
	debug_value_save(x)
	fmt.Println(x)
}

func debug_funtion(x string) {
	fmt.Printf("x=,%s!\n", x)
}
func debug_value_save(x string) {
	x = "sssss"
	fmt.Printf("goodbye,%s!\n", x)
}
Copy after login

has written some code. But if you run it with godebug, you will have one more debugger, and I don’t understand how this thing works.
Try it out later. More to add.

The above is the detailed content of GoLang debugging operation method. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:csdn.net
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!