Renamed callerViewer to _callViewer to align with other "view" structs

This commit is contained in:
Matthieu Vachon 2024-04-29 11:50:19 -04:00
parent 8d802608f5
commit 27ace57951

View file

@ -1983,11 +1983,11 @@ func (r *receiptView) String() string {
return fmt.Sprintf("[status=%s, gasUsed=%d, logs=%d]", status, r.GasUsed, len(r.Logs))
}
type callerViewer struct {
type _callerView struct {
skipFrame int
}
func (v callerViewer) String() string {
func (v _callerView) String() string {
_, file, line, found := runtime.Caller(v.skipFrame)
if !found {
return "<unknown>"
@ -2009,7 +2009,7 @@ func (v callerViewer) String() string {
// In this example, with `callerView(2)` which means skip 3 call frames, you would get
// you to ProcessCall frame and `callerView` would print that.
func callerView(skipFrame int) fmt.Stringer {
return callerViewer{skipFrame}
return _callerView{skipFrame}
}
func emptyBytesToNil(in []byte) []byte {