Reference to enum that includes absolute path (like ::path::to::enum) will be parsed to DataType.EnumType(List(,path,to,enum)) (note the first empty string in EnumType.name)
In many cases in the generators such paths will produce uncompilable code, for example, in Java and C# the generated type name will begin with dot: .Absolute.Path.To.Type and .Absolute.Path.To.Enum:
Reference to enum that includes absolute path (like
::path::to::enum
) will be parsed toDataType.EnumType(List(,path,to,enum))
(note the first empty string inEnumType.name
)Creation of
EnumType
instance: https://github.com/kaitai-io/kaitai_struct_compiler/blob/542b24124a95f5308df625d667f8776dd023c696/shared/src/main/scala/io/kaitai/struct/datatype/DataType.scala#L486-L497The same will happen with the
CalcUserType.name
when type is defined in a parameter with absolute path:https://github.com/kaitai-io/kaitai_struct_compiler/blob/542b24124a95f5308df625d667f8776dd023c696/shared/src/main/scala/io/kaitai/struct/datatype/DataType.scala#L549
.Absolute.Path.To.Type
and.Absolute.Path.To.Enum
:I think, that sign of absolute path should be present in types explicitly instead of implicitly as empty first component of a name.