title: define golang type as a slice of other type in protobuf's .proto file
body: <p>I want to define a Go type in <code>.proto</code> file. The type is a slice of other type which is defined in <code>.proto</code> file.</p>
  
  <p>I have types as below.</p>
  
  <pre><code>type SomeType struct {
      // few fields
  }
  
  type SomeTypes []SomeType
  </code></pre>
  
  <p>I have <code>SomeType</code> is defined in .proto file as below.</p>
  
  <pre><code>message SomeType {
      //
  }
  </code></pre>
  
  <p>Now I want to define type <code>SomeTypes</code> in .proto file. But I have not found any way to do that. The simplest solution for me is to change type <code>SomeTypes</code> as below:</p>
  
  <pre><code>type SomeTypes struct {
      Content []SomeType
  }
  </code></pre>
  
  <p>Then I can define that in .proto file as</p>
  
  <pre><code>message SomeTypes {
        repeated SomeType Content = 1 [(gogoproto.nullable) = false];
  }
  </code></pre>
  
  <p>But I want to know if there is any solution which does not involve changing the struct <code>SomeTypes</code></p>
  
  <p>I am using <code>proto2</code>.</p>