compilation_unit {
  package_statement {
    package_name: "ExplorerTest"
  }
  is_api: true
  declarations {
    interface {
      name: "A"
      members {
        function {
          name: "F"
          param_pattern {
          }
          return_term {
            kind: Expression
            type {
              int_type_literal {
              }
            }
          }
        }
      }
      self {
        name: "Self"
        type {
          type_type_literal {
          }
        }
      }
    }
  }
  declarations {
    interface {
      name: "B"
      members {
        function {
          name: "F"
          param_pattern {
          }
          return_term {
            kind: Expression
            type {
              int_type_literal {
              }
            }
          }
        }
      }
      members {
        function {
          name: "G"
          param_pattern {
          }
          return_term {
            kind: Expression
            type {
              int_type_literal {
              }
            }
          }
        }
      }
      self {
        name: "Self"
        type {
          type_type_literal {
          }
        }
      }
    }
  }
  declarations {
    interface {
      name: "C"
      members {
        function {
          name: "H"
          param_pattern {
          }
          return_term {
            kind: Expression
            type {
              identifier {
                name: "T"
              }
            }
          }
        }
      }
      self {
        name: "Self"
        type {
          type_type_literal {
          }
        }
      }
    }
  }
  declarations {
    impl {
      kind: ExternalImpl
      impl_type {
        int_type_literal {
        }
      }
      interface {
        identifier {
          name: "A"
        }
      }
      members {
        function {
          name: "F"
          param_pattern {
          }
          return_term {
            kind: Expression
            type {
              int_type_literal {
              }
            }
          }
          body {
            statements {
              return_expression_statement {
                expression {
                  int_literal {
                    value: 1
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  declarations {
    impl {
      kind: ExternalImpl
      impl_type {
        int_type_literal {
        }
      }
      interface {
        where {
          base {
            operator {
              op: BitwiseAnd
              arguments {
                identifier {
                  name: "B"
                }
              }
              arguments {
                call {
                  function {
                    identifier {
                      name: "C"
                    }
                  }
                  argument {
                    tuple_literal {
                      fields {
                        int_type_literal {
                        }
                      }
                    }
                  }
                }
              }
            }
          }
          clauses {
            is {
              type {
                designator {
                  name: "Self"
                }
              }
              constraint {
                identifier {
                  name: "A"
                }
              }
            }
          }
        }
      }
      members {
        function {
          name: "F"
          param_pattern {
          }
          return_term {
            kind: Expression
            type {
              int_type_literal {
              }
            }
          }
          body {
            statements {
              return_expression_statement {
                expression {
                  int_literal {
                    value: 2
                  }
                }
              }
            }
          }
        }
      }
      members {
        function {
          name: "G"
          param_pattern {
          }
          return_term {
            kind: Expression
            type {
              int_type_literal {
              }
            }
          }
          body {
            statements {
              return_expression_statement {
                expression {
                  int_literal {
                    value: 3
                  }
                }
              }
            }
          }
        }
      }
      members {
        function {
          name: "H"
          param_pattern {
          }
          return_term {
            kind: Expression
            type {
              int_type_literal {
              }
            }
          }
          body {
            statements {
              return_expression_statement {
                expression {
                  int_literal {
                    value: 4
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  declarations {
    function {
      name: "Main"
      param_pattern {
      }
      return_term {
        kind: Expression
        type {
          int_type_literal {
          }
        }
      }
      body {
        statements {
          variable_definition {
            pattern {
              binding_pattern {
                name: "n"
                type {
                  expression_pattern {
                    expression {
                      int_type_literal {
                      }
                    }
                  }
                }
              }
            }
            init {
              int_literal {
                value: 0
              }
            }
            is_returned: false
          }
        }
        statements {
          return_expression_statement {
            expression {
              operator {
                op: Add
                arguments {
                  operator {
                    op: Add
                    arguments {
                      operator {
                        op: Add
                        arguments {
                          operator {
                            op: Mul
                            arguments {
                              call {
                                function {
                                  compound_member_access {
                                    object {
                                      identifier {
                                        name: "n"
                                      }
                                    }
                                    path {
                                      simple_member_access {
                                        field: "F"
                                        object {
                                          identifier {
                                            name: "A"
                                          }
                                        }
                                      }
                                    }
                                  }
                                }
                                argument {
                                  tuple_literal {
                                  }
                                }
                              }
                            }
                            arguments {
                              int_literal {
                                value: 1000
                              }
                            }
                          }
                        }
                        arguments {
                          operator {
                            op: Mul
                            arguments {
                              call {
                                function {
                                  compound_member_access {
                                    object {
                                      identifier {
                                        name: "n"
                                      }
                                    }
                                    path {
                                      simple_member_access {
                                        field: "F"
                                        object {
                                          identifier {
                                            name: "B"
                                          }
                                        }
                                      }
                                    }
                                  }
                                }
                                argument {
                                  tuple_literal {
                                  }
                                }
                              }
                            }
                            arguments {
                              int_literal {
                                value: 100
                              }
                            }
                          }
                        }
                      }
                    }
                    arguments {
                      operator {
                        op: Mul
                        arguments {
                          call {
                            function {
                              compound_member_access {
                                object {
                                  identifier {
                                    name: "n"
                                  }
                                }
                                path {
                                  simple_member_access {
                                    field: "G"
                                    object {
                                      identifier {
                                        name: "B"
                                      }
                                    }
                                  }
                                }
                              }
                            }
                            argument {
                              tuple_literal {
                              }
                            }
                          }
                        }
                        arguments {
                          int_literal {
                            value: 10
                          }
                        }
                      }
                    }
                  }
                }
                arguments {
                  call {
                    function {
                      compound_member_access {
                        object {
                          identifier {
                            name: "n"
                          }
                        }
                        path {
                          simple_member_access {
                            field: "H"
                            object {
                              call {
                                function {
                                  identifier {
                                    name: "C"
                                  }
                                }
                                argument {
                                  tuple_literal {
                                    fields {
                                      int_type_literal {
                                      }
                                    }
                                  }
                                }
                              }
                            }
                          }
                        }
                      }
                    }
                    argument {
                      tuple_literal {
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}
