Source/Packages

Compiler.Planning.Resources

packages/compiler/planning/src/Compiler/Planning/Resources.alpha

636 lines34 declarations25.9 KiBSHA-256 773ccd6b9504

def · lines 441–460

resourceGraphEntries

Full file
441def resourceGraphEntries =
442  (lambda unrestricted graph : (family ResourceGraph) .
443    (naturalAdd
444      (stdListLength (family ResourceDomain) (resourceGraphDomains graph))
445      (naturalAdd
446        (stdListLength (family ResourceLink) (resourceGraphLinks graph))
447        (stdListFold
448          (family ResourceEndpoint)
449          Nat
450          (lambda unrestricted endpoint : (family ResourceEndpoint) .
451            (lambda unrestricted total : Nat .
452              (naturalAdd
453                total
454                (naturalAdd
455                  1
456                  (naturalAdd
457                    (stdListLength Bytes (resourceEndpointCapabilities endpoint))
458                    (stdListLength Nat (resourceEndpointDomains endpoint)))))))
459          0
460          (resourceGraphEndpoints graph)))))

The compiler supplied declaration spans and resolved links from this source snapshot. This page does not assert that this file belongs to a checked closure.