Почему я не могу иметь это в golang?Структуры с полями типа интерфейса
type EventDefinition struct {
Name string
EventProperties interface{}
}
Где EventProperties может быть одним из возможных типов структур, каждая структура с разными полями. Идея заключается в том, чтобы иметь EventDefinition с EventProperties
type Party struct {
Location string
Hour string
}
или
type Wedding struct {
Bride string
Groom string
Hour string
}
или
type Graduation struct {
Location string
Graduate string
}