compilation_unit {
  package_statement {
    package_name: "ExplorerTest"
  }
  is_api: true
  declarations {
    choice {
      name {
        name: "Opt"
      }
      alternatives {
        name: "None"
        signature {
        }
      }
      alternatives {
        name: "Some"
        signature {
          fields {
            int_type_literal {
            }
          }
        }
      }
    }
  }
  declarations {
    function {
      name {
        name: "A"
      }
      param_pattern {
        fields {
          binding_pattern {
            name: "a"
            type {
              expression_pattern {
                expression {
                  identifier {
                    name: "Opt"
                  }
                }
              }
            }
          }
        }
        fields {
          binding_pattern {
            name: "b"
            type {
              expression_pattern {
                expression {
                  identifier {
                    name: "Opt"
                  }
                }
              }
            }
          }
        }
      }
      return_term {
        kind: Expression
        type {
          int_type_literal {
          }
        }
      }
      body {
        statements {
          match {
            expression {
              tuple_literal {
                fields {
                  identifier {
                    name: "a"
                  }
                }
                fields {
                  identifier {
                    name: "b"
                  }
                }
              }
            }
            clauses {
              pattern {
                tuple_pattern {
                  fields {
                    alternative_pattern {
                      choice_type {
                        identifier {
                          name: "Opt"
                        }
                      }
                      alternative_name: "Some"
                      arguments {
                        fields {
                          binding_pattern {
                            name: "n"
                            type {
                              expression_pattern {
                                expression {
                                  int_type_literal {
                                  }
                                }
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                  fields {
                    binding_pattern {
                      name: "_"
                      type {
                        auto_pattern {
                        }
                      }
                    }
                  }
                }
              }
              statement {
                block {
                  statements {
                    return_expression_statement {
                      expression {
                        identifier {
                          name: "n"
                        }
                      }
                    }
                  }
                }
              }
            }
            clauses {
              pattern {
                tuple_pattern {
                  fields {
                    binding_pattern {
                      name: "_"
                      type {
                        auto_pattern {
                        }
                      }
                    }
                  }
                  fields {
                    alternative_pattern {
                      choice_type {
                        identifier {
                          name: "Opt"
                        }
                      }
                      alternative_name: "Some"
                      arguments {
                        fields {
                          binding_pattern {
                            name: "n"
                            type {
                              expression_pattern {
                                expression {
                                  int_type_literal {
                                  }
                                }
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
              statement {
                block {
                  statements {
                    return_expression_statement {
                      expression {
                        identifier {
                          name: "n"
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  declarations {
    function {
      name {
        name: "Main"
      }
      param_pattern {
      }
      return_term {
        kind: Expression
        type {
          int_type_literal {
          }
        }
      }
      body {
        statements {
          return_expression_statement {
            expression {
              call {
                function {
                  identifier {
                    name: "A"
                  }
                }
                argument {
                  tuple_literal {
                    fields {
                      call {
                        function {
                          simple_member_access {
                            field: "None"
                            object {
                              identifier {
                                name: "Opt"
                              }
                            }
                          }
                        }
                        argument {
                          tuple_literal {
                          }
                        }
                      }
                    }
                    fields {
                      call {
                        function {
                          simple_member_access {
                            field: "Some"
                            object {
                              identifier {
                                name: "Opt"
                              }
                            }
                          }
                        }
                        argument {
                          tuple_literal {
                            fields {
                              int_literal {
                                value: 1
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}
