Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

go知识点 - Ray_YC's Blog #16

Open
lyc10031 opened this issue Sep 10, 2019 · 0 comments
Open

go知识点 - Ray_YC's Blog #16

lyc10031 opened this issue Sep 10, 2019 · 0 comments

Comments

@lyc10031
Copy link
Owner

https://lyc10031.github.io/2019/09/10/go-%E7%9F%A5%E8%AF%86%E7%82%B9.html

defer defer 是后进先出。panic 需要等defer 结束后才会向上传递。 出现panic会先按照defer的后入先出的顺序执行,最后才会执行panic。 例子1: package mainimport

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant