StackSource holds function/location info for a stack entry.
| 46 | |
| 47 | // StackSource holds function/location info for a stack entry. |
| 48 | type StackSource struct { |
| 49 | FullName string |
| 50 | FileName string |
| 51 | UniqueName string // Disambiguates functions with same names |
| 52 | Inlined bool // If true this source was inlined into its caller |
| 53 | |
| 54 | // Alternative names to display (with decreasing lengths) to make text fit. |
| 55 | // Guaranteed to be non-empty. |
| 56 | Display []string |
| 57 | |
| 58 | // Places holds the list of stack slots where this source occurs. |
| 59 | // In particular, if [a,b] is an element in Places, |
| 60 | // StackSet.Stacks[a].Sources[b] points to this source. |
| 61 | // |
| 62 | // No stack will be referenced twice in the Places slice for a given |
| 63 | // StackSource. In case of recursion, Places will contain the outer-most |
| 64 | // entry in the recursive stack. E.g., if stack S has source X at positions |
| 65 | // 4,6,9,10, the Places entry for X will contain [S,4]. |
| 66 | Places []StackSlot |
| 67 | |
| 68 | // Combined count of stacks where this source is the leaf. |
| 69 | Self int64 |
| 70 | |
| 71 | // Color number to use for this source. |
| 72 | // Colors with high numbers than supported may be treated as zero. |
| 73 | Color int |
| 74 | } |
| 75 | |
| 76 | // StackSlot identifies a particular StackSlot. |
| 77 | type StackSlot struct { |
nothing calls this directly
no outgoing calls
no test coverage detected