Skip to content
This repository has been archived by the owner on Dec 1, 2021. It is now read-only.

Make stackTracer interface public #71

Closed
hnakamur opened this issue Jul 16, 2016 · 2 comments
Closed

Make stackTracer interface public #71

hnakamur opened this issue Jul 16, 2016 · 2 comments

Comments

@hnakamur
Copy link

I read https://godoc.org/github.com/pkg/errors#hdr-Retrieving_the_stack_trace_of_an_error_or_wrapper
and learn you need to the stackTracer interface yourself.

I understand the intension is exposing APIs as little as possible to enhance the future API compatibility.
However, if everyone must defines the stackTracer interface to retrieve stack traces, it is actually an implicit interface. I think it is not good.

So how about make the stackTracer interface public and adding StackTracer interface?

@davecheney
Copy link
Member

I understand this request but I'm sorry I do not plan to add this interface to this package. I strongly believe that interfaces should be defined by their caller, not the package which implements them.

Thank you for your understanding.

@hnakamur
Copy link
Author

OK, I understand.
Thanks for your explanation.

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

No branches or pull requests

2 participants