MCPcopy Create free account
hub / github.com/despiteallobjections/amigo / Less

Method Less

types/initorder.go:306–314  ·  view source on GitHub ↗
(i, j int)

Source from the content-addressed store, hash-verified

304}
305
306func (a nodeQueue) Less(i, j int) bool {
307 x, y := a[i], a[j]
308 // nodes are prioritized by number of incoming dependencies (1st key)
309 // and source order (2nd key)
310 if x.ndeps != y.ndeps {
311 return x.ndeps < y.ndeps
312 }
313 return x.obj.order() < y.obj.order()
314}
315
316func (a *nodeQueue) Push(x interface{}) {
317 panic("unreachable")

Callers

nothing calls this directly

Calls 1

orderMethod · 0.65

Tested by

no test coverage detected