Explorer

definy.snapshot-check-entries

description
The committed list of core.type-checker. All the parts are in the replaced module (#replaced). The type of a compiler builtin is the builtin expression. The expression key is the content hash
type
Fn(parts: List<@definy.snapshot-check-part>, resolutions: List<@definy.resolution-cache-entry>) -> List<@definy.type-check-entry>
expression
fn(parts$0, resolutions$1) =>
  let resolution_index$9500 = @definy.resolution-index(resolutions: $1);
  @core.list-fold(
    T: @definy.snapshot-check-part,
    A: List<@definy.type-check-entry>,
    reducer: fn(acc$2, item$3) =>
      match $3.content {
        #none(_) =>
          $2,
        #some(content$4) =>
          match @definy.resolution-for(resolutions: $9500, content_hash: $3.content_hash) {
            #some(hit$5) =>
              @core.list-append(
                list: $2,
                item: {
                  part_id: $3.id,
                  module_id: "#replaced",
                  part_type: $5.entry.part_type,
                  type_declaration: $5.entry.type_declaration,
                  expression_key: $5.entry.expression_key,
                  has_expression: $5.entry.has_expression,
                  references: $5.entry.references
                }
              ),
            #none(_) =>
              @core.list-append(
                list: $2,
                item: @definy.content-type-check-entry(part_id: $3.id, module_id: "#replaced", content_hash: $3.content_hash, content: $4)
              )
          }
      },
    init: [],
    xs: $0
  )
visibility
public
definy.snapshot-check-entries (project definy, branch main, snapshot l0VFjJZP174d8CbZWFoujAGTYjgsQu4uTq5uWCZaXgo)
id: _ncJgmgE7tkq4gUoMnhRCP6p_fe6Iw1BA3Bj5LS0EOM
content hash: jouLHLxecnrjrYbml5soiUfCxBK0tb0SbNL72KhyJBg