Skip to content

Commit

Permalink
Make the scope for @thrift.AllowReservedIdentifierName more robust.
Browse files Browse the repository at this point in the history
Summary: `thrift.AllowReservedIdentifierName` applies to all definitions and the program as well. Rather than list the individual definition, use the available `scope.Definition`. This makes the usage robust and simplifies the code in the process.

Reviewed By: praihan, vitaut

Differential Revision: D59494687

fbshipit-source-id: cff2e0130c18042c8b5fac93707449ad33b1061b
  • Loading branch information
Satish Kumar authored and facebook-github-bot committed Jul 9, 2024
1 parent a173ad0 commit 7cacdee
Showing 1 changed file with 1 addition and 11 deletions.
12 changes: 1 addition & 11 deletions thrift/annotation/thrift.thrift
Original file line number Diff line number Diff line change
Expand Up @@ -257,16 +257,6 @@ struct DeprecatedUnvalidatedAnnotations {
* the usage with `@thrift.AllowReservedIdentifierName`,
* and may result in undefined behavior.
*/
@scope.Const
@scope.Enum
@scope.EnumValue
@scope.Exception
@scope.Field
@scope.Function
@scope.Interaction
@scope.Program
@scope.Service
@scope.Struct
@scope.Typedef
@scope.Union
@scope.Definition
struct AllowReservedIdentifierName {}

0 comments on commit 7cacdee

Please sign in to comment.