title: InvalidClose layout: article

InvalidClose occurs when close(...) is called with an argument that is
not of channel type, or that is a receive-only channel.

Example:
 func f() {
 	var x int
 	close(x)
 }