expr icon indicating copy to clipboard operation
expr copied to clipboard

Extra type hints for maps content?

Open dmzkrsk opened this issue 1 year ago • 0 comments

For my domain I need to use raw map[string]interface{} sometimes. But maps have finite number of keys and each key always has specific type

Is there a way to say compiler, that x.A is int, and x.B is an error, since map has no B key?

dmzkrsk avatar May 03 '24 11:05 dmzkrsk