issues
search
peak
/
s5cmd
Parallel S3 and local filesystem execution tool.
MIT License
2.7k
stars
239
forks
source link
chore: prefer chan struct{} over chan bool for signalling
#733
Closed
sonmezonur
closed
4 months ago
sonmezonur
commented
4 months ago
Prefer using
chan struct{}
since:
We are not interested in value being passed to channel, it is just used for signaling
It occupies zero memory (bool:64bit)
We used
chan struct{}
and
chan bool
interchangeably. To maintain a standard in the codebase, let's only use chan struct.
Prefer using
chan struct{}
since:chan struct{}
andchan bool
interchangeably. To maintain a standard in the codebase, let's only use chan struct.