标签:inter str func golang mys fun main interface var
type MyInterface interface{ Print() } func TestFunc(x MyInterface) {} type MyStruct struct {} func (me MyStruct) Print() {} func main() { var me MyStruct TestFunc(me) }
标签:inter str func golang mys fun main interface var
原文地址:https://www.cnblogs.com/xiaoxiaof/p/12059508.html