But it fails to account for the fact that an XML name for ERecord has already been created, and so inside struct EDocGeteRecordDetailsResponse this happened:
type EDocGeteRecordDetailsResponse struct {
XMLName xml.Name xml:"http://tempuri.org/ eDocGeteRecordDetailsResponse"
EDocGeteRecordDetailsResult *ERecord /*xml:"eDocGeteRecordDetailsResult,omitempty" json:"eDocGeteRecordDetailsResult,omitempty"*/ <- this xml name should not have been generated
ErrorMsg string `xml:"errorMsg,omitempty" json:"errorMsg,omitempty"`
}
If a WSDL element refers to another WSDL element, this problem will arise.
So this:
refers to this:
And it seems that gowsdl does not handle this edge case, as the generated Go code will be wrong. It creates a struct from ERecord as expected:
But it fails to account for the fact that an XML name for ERecord has already been created, and so inside struct EDocGeteRecordDetailsResponse this happened:
And so a conflict occurs.