4 ms·
One might want to add that it does work when you use a variable however. https://play.golang.org/p/6UfNFWm_-JR https://play.golang.org/p/6UfNFWm_-JR
by 7steps2much 5y ago
One might want to add that it does work when you use a variable however. https://play.golang.org/p/6UfNFWm_-JR https://play.golang.org/p/6UfNFWm_-JR
- jakelazaroff 5y agoThe issue isn't that they're constants, but that GP called them "true" and "false" and assigned the opposite values you'd expect. You can break it in exactly the same way with variables: https://play.golang.org/p/EVU84l0A57I https://play.golang.org/p/EVU84l0A57I Kinda crazy to me that Go doesn't reserve the words "true" and "false", but ¯\_(ツ)_/¯
- deleted 5y ago[deleted]