File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -57,6 +57,7 @@ struct Name {
5757 */
5858@scope.Typedef
5959@scope.Field
60+ @scope.FunctionParameter
6061struct Type {
6162 1: string name ;
6263
Original file line number Diff line number Diff line change @@ -28,13 +28,15 @@ namespace py thrift.annotation.go
2828// Annotation for overriding Go names (e.g. to avoid codegen name conflicts).
2929@scope.Field
3030@scope.Function
31+ @scope.FunctionParameter
3132@scope.Typedef
3233struct Name {
3334 1: string name ;
3435}
3536
3637// Annotation for overriding Go struct field tags (e.g. json, yaml, serf tags).
3738@scope.Field
39+ @scope.FunctionParameter
3840struct Tag {
3941 1: string tag ;
4042}
Original file line number Diff line number Diff line change @@ -33,6 +33,7 @@ struct Mutable {}
3333
3434// When this annotation is applied, thrift compiler will annotate corresponding java entity the given java annotation.
3535@scope.Field
36+ @scope.FunctionParameter
3637@scope.Struct
3738@scope.Union
3839@scope.Exception
Original file line number Diff line number Diff line change @@ -27,7 +27,12 @@ namespace py thrift.annotation.python
2727// start
2828
2929// / Hides in thrift-py3 only, not in thrift-python
30- @scope.Definition
30+ // / Allowed for all @scope.Definition, except for @scope.FunctionParameter as that would hide part of
31+ // / the RPC function parameters.
32+ @scope.RootDefinition
33+ @scope.Field
34+ @scope.Function
35+ @scope.Transitive
3136struct Py3Hidden {}
3237
3338// / Hides in thrift-py-deprecated only
Original file line number Diff line number Diff line change @@ -262,6 +262,7 @@ struct NewType {}
262262 * | `&'a T<K, V>` | `IntoIterator<Item = (&'a K, &'a V)>`
263263 */
264264@scope.Field
265+ @scope.FunctionParameter
265266@scope.Typedef
266267struct Type {
267268 1: string name ;
Original file line number Diff line number Diff line change @@ -86,7 +86,7 @@ struct Union {}
8686/** The `exception` definition scope. */
8787struct Exception {}
8888
89- /** Field declartaions , for example in `struct` or `function` declartions . */
89+ /** Field declarations , for example in `struct` declaration . */
9090struct Field {}
9191
9292/** The `typedef` definition scope. */
@@ -102,6 +102,9 @@ struct Interaction {}
102102struct Function {}
103103/* added by compiler: (hack.name = "TFunction", js.name = "TFunction") */
104104
105+ /** The `function parameter` definition scope. */
106+ struct FunctionParameter {}
107+
105108/** The Enum value definition scope. */
106109struct EnumValue {}
107110
@@ -141,6 +144,7 @@ struct RootDefinition {}
141144@RootDefinition
142145@Field
143146@Function
147+ @FunctionParameter
144148@EnumValue
145149@Transitive
146150struct Definition {}
You can’t perform that action at this time.
0 commit comments