Among many new things in the recent proposal about adding generic programming for Golang there is a new keyword any
So if my current program has declared a variable named any
it won't compile.
Among many new things in the recent proposal about adding generic programming for Golang there is a new keyword any
So if my current program has declared a variable named any
it won't compile.
Copyright © 2021 Jogjafile Inc.
Wrong.
any
will be a predaclared identifier not a keyword.No, of course not, it will just redeclare
any
in the current scope.The list of keywords in Go is pretty short, see https://golang.org/ref/spec#Keywords . Keywords are keywords and cannot be used for other things. A predeclared identifier (see https://golang.org/ref/spec#Predeclared_identifiers) is not a keyword and can be redeclared.