1/*
2 * Licensed to the Apache Software Foundation (ASF) under one
3 * or more contributor license agreements. See the NOTICE file
4 * distributed with this work for additional information
5 * regarding copyright ownership. The ASF licenses this file
6 * to you under the Apache License, Version 2.0 (the
7 * "License"); you may not use this file except in compliance
8 * with the License. You may obtain a copy of the License at
9 *
10 *   http://www.apache.org/licenses/LICENSE-2.0
11 *
12 * Unless required by applicable law or agreed to in writing,
13 * software distributed under the License is distributed on an
14 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15 * KIND, either express or implied. See the License for the
16 * specific language governing permissions and limitations
17 * under the License.
18 */
19
20// This is to make sure you don't mess something up when you change typedef code.
21// Generate it with the old and new thrift and make sure they are the same.
22/*
23rm -rf gen-* orig-*
24mkdir old new
25thrift --gen cpp --gen java --gen php --gen phpi --gen py --gen rb --gen xsd --gen perl --gen ocaml --gen erl --gen hs --strict ManyTypedefs.thrift
26mv gen-* old
27../compiler/cpp/thrift --gen cpp --gen java --gen php --gen phpi --gen py --gen rb --gen xsd --gen perl --gen ocaml --gen erl --gen hs --strict ManyTypedefs.thrift
28mv gen-* new
29diff -ur old new
30rm -rf old new
31# There should be no output.
32*/
33
34typedef i32 int32
35typedef list<map<int32, string>> biglist
36
37struct struct1 {
38  1: int32 myint;
39  2: biglist mylist;
40}
41
42exception exception1 {
43  1: biglist alist;
44  2: struct1 mystruct;
45}
46
47service AService {
48  struct1 method1(1: int32 myint) throws (1: exception1 exn);
49  biglist method2();
50}
51