tableau icon indicating copy to clipboard operation
tableau copied to clipboard

enum: check enum value alias uniqueness when define enum type in sheet or proto file

Open wenchy opened this issue 1 year ago • 0 comments

1. Problem in sheet

A sheet named ItemType (also the enum type name) in workbook:

Name Alias
ITEM_TYPE_DIAMOND Diamond
ITEM_TYPE_EQUIP Diamond
ITEM_TYPE_BOX Box

Note the enum value alias Diamond is duplicate.

2. Problem in proto file

enum ItemType {
  ITEM_TYPE_INVALID = 0;
  ITEM_TYPE_DIAMOND = 1 [(tableau.evalue).name = "Diamond"];
  ITEM_TYPE_EQUIP = 2 [(tableau.evalue).name = "Diamond"];
  ITEM_TYPE_BOX = 3 [(tableau.evalue).name = "Box"];
}

wenchy avatar May 14 '24 14:05 wenchy