Re: [go-nuts] Going crazy on golang maps

2017-09-24 Thread Chris Polderman
YES We have a winner! I really did not see that! Regards, Chris Op zaterdag 23 september 2017 18:32:25 UTC+2 schreef Jakob Borg: > > On 23 Sep 2017, at 15:27, Chris Polderman > wrote: > > > > func (hue *HueBridge) pollSensors(sensors *sensors.Sensors) { > >var

Re: [go-nuts] Going crazy on golang maps

2017-09-23 Thread Jakob Borg
On 23 Sep 2017, at 15:27, Chris Polderman wrote: > > func (hue *HueBridge) pollSensors(sensors *sensors.Sensors) { >var previousSensorInfo map[int]sensors.Sensor = > make(map[int]sensors.Sensor) In your function declaration, you're declaring a parameter "sensors"

Re: [go-nuts] Going crazy on golang maps

2017-09-23 Thread Jan Mercl
On Sat, Sep 23, 2017 at 4:37 PM Chris Polderman wrote: > The full code reads: The full code is not full code. It lacks eg. the import declarations. Please provide a link to the really full code at a specific commit for others to reproduce. -- -j -- You received

[go-nuts] Going crazy on golang maps

2017-09-23 Thread Chris Polderman
Hello! I am working on a home automation project in Go. One of the components is polling all the sensors in a HUE bridge (this is some LED lighting system with smart lamps and buttons). I am wanting to make a map, keyed on int to "Sensor" objects. These objects are located in a sensors