Uploaded image for project: 'Thrift'
  1. Thrift
  2. THRIFT-5627

More consistent syntax for cpp_type

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 0.18.0
    • Compiler (General)
    • None

    Description

      As a side effect on my current work I recognized an interesting parser warning.

      Essentially it boils down to the list<> case in these definitions taken from https://thrift.apache.org/docs/idl which (now) would cause ambiguities.

      [28] MapType         ::=  'map' CppType? '<' FieldType ',' FieldType '>'
      [29] SetType         ::=  'set' CppType? '<' FieldType '>'
      [30] ListType        ::=  'list' '<' FieldType '>' CppType?
      

      I wonder why we need it this way at all. Wouldn't it be better if list<> set<> and map<> would expect the same syntax?

      Attachments

        Issue Links

          Activity

            People

              jensg Jens Geyer
              jensg Jens Geyer
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 20m
                  20m