bson package unable to Decode Enum values

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Fixed
    • Priority: Major - P3
    • 0.0.14
    • Affects Version/s: 0.0.6
    • Component/s: BSON
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      I am trying to use new go driver but I found with regarding BSON decoding. I can reproduce the issue with the file in the attachment. The problem is with the defined types. Following EnumType has no problem with encoding but can't decode the original value.
       
      type EnumType int32
      const EnumType_A EnumType = 1
      type Dummy struct

      { Tt EnumType `bson:"tt"` }

              Assignee:
              Kristofer Brandow (Inactive)
              Reporter:
              Sercan Degirmenci
              Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: