MCPcopy Index your code
hub / github.com/maruel/panicparse / less

Method less

stack/stack.go:736–756  ·  view source on GitHub ↗

less compares two Signature, where the ones that are less are more important, so they come up front. A Signature with more private functions is 'less' so it is at the top. Inversely, a Signature with only public functions is 'more' so it is at the bottom.

(r *Signature)

Source from the content-addressed store, hash-verified

734// 'less' so it is at the top. Inversely, a Signature with only public
735// functions is 'more' so it is at the bottom.
736func (s *Signature) less(r *Signature) bool {
737 if s.Stack.less(&r.Stack) {
738 return true
739 }
740 if r.Stack.less(&s.Stack) {
741 return false
742 }
743 if s.Locked && !r.Locked {
744 return true
745 }
746 if r.Locked && !s.Locked {
747 return false
748 }
749 if s.State < r.State {
750 return true
751 }
752 if s.State > r.State {
753 return false
754 }
755 return false
756}
757
758// SleepString returns a string "N-M minutes" if the goroutine(s) slept for a
759// long time.

Callers

nothing calls this directly

Calls 1

lessMethod · 0.45

Tested by

no test coverage detected