TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Show HN: Error return traces for Go, inspired by Zig

133 点作者 abhinavg超过 1 年前

7 条评论

Kharacternyk超过 1 年前
The logo is awesome. Has an artist been hired to create it?
评论 #38460986 未加载
da39a3ee超过 1 年前
I read the README but I'm not understanding yet why the return path might be what you want. The stack trace at error creation sounds more useful.
评论 #38479814 未加载
Vanclief超过 1 年前
While from a first instance, this package seems a bit overkill, I think the idea is interesting and is something that can be improved for Go.<p>I also felt that Go errors where too bare-bones, so I developed a small package (<a href="https:&#x2F;&#x2F;github.com&#x2F;Vanclief&#x2F;ez">https:&#x2F;&#x2F;github.com&#x2F;Vanclief&#x2F;ez</a>) based on an awesome post that I saw here once. I use this package in all Golang code I touch.
stirante超过 1 年前
We actually did something similar in Go here: <a href="https:&#x2F;&#x2F;github.com&#x2F;Bedrock-OSS&#x2F;go-burrito">https:&#x2F;&#x2F;github.com&#x2F;Bedrock-OSS&#x2F;go-burrito</a><p>I guess the difference we try to make is that we really wanted to make errors that are understandable by users. Each time the error is returned we try to wrap it with an information where and why.
pixelpoet超过 1 年前
(Aside about Zig, sorry. Although this applies to Go as well, I think?) Urgh I am <i>so</i> keen to switch to Zig but their attitude towards having vector operators just completely kills the viability for me as a graphics programmer.<p>I&#x27;ve asked in their Discord, Andrew Kelley himself passed on commenting (I know his stance, every C++ dev wants their fav feature), but the reality remains that it&#x27;s just infeasible to do with a DSL so it&#x27;s just the wrong language for writing graphics code.
评论 #38463530 未加载
评论 #38462580 未加载
评论 #38462482 未加载
评论 #38465861 未加载
评论 #38463794 未加载
评论 #38466928 未加载
评论 #38488830 未加载
评论 #38467442 未加载
评论 #38462406 未加载
Eun超过 1 年前
Can you explain why we should this over <a href="https:&#x2F;&#x2F;github.com&#x2F;pkg&#x2F;errors">https:&#x2F;&#x2F;github.com&#x2F;pkg&#x2F;errors</a>?
评论 #38461774 未加载
评论 #38461793 未加载
评论 #38461712 未加载
评论 #38462069 未加载
zgk7iqea超过 1 年前
go is step by step reinventing exceptions
评论 #38466790 未加载
评论 #38466638 未加载
评论 #38467357 未加载