i am new to Golang.
can you just share some piece of code just to check each field in struct
for empty or nil or zero value.
On Tue, Nov 22, 2016 at 4:19 PM, Dave Cheney wrote:
> If you want to write a general function you will need to use the reflect
> package, specifically reflect.Value.IsVal
Hi Dave,
I need to create a common utility which checks whether the struct is empty
or not else i can throw error.
for example:
type Employee struct{
EmpId string
EmpName string
Department []String
Projects map[string]string
}
i need to check whether the object co