Skip to content
masterclass Buddy

Go · Function

close

close shuts down a bidirectional or send-only channel. Receivers can finish queued values, then receive the element type's zero value without blocking; the two-result form reports false.

Last updated

Syntax

func close(c chan<- Type)

In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.

Subscribe
  • panic
  • recover
  • make

Source: builtin package - builtin - Go Packages. Checked 2026-11-03.