Re: [go-nuts] Re: cgo and Python as a shared library

2022-11-26 Thread Howard Waterfall
SOLVED! It took a while to sort out the various locations. Environment Variables: export LIBRARY_PATH=/usr/local/Frameworks/Python.framework/Versions/3.9/lib export PKG_CONFIG_PATH=/usr/local/Frameworks/Python.framework/Versions/3.9/lib/pkgconfig Code: ... package main /* #cgo

Re: [go-nuts] SetMapIndex() equivalent for slice/array

2021-06-05 Thread Howard Waterfall
Updated sample <https://play.golang.org/p/o9e6Q3EvemH> On Sat, Jun 5, 2021 at 6:27 AM Howard Waterfall wrote: > Dammit!. How'd I miss that?! Thanks Dan. I updated the sample accordingly. > > On Fri, Jun 4, 2021, 9:10 PM Dan Kortschak wrote: > >> On Fri, 2021-06-04 at 2

Re: [go-nuts] SetMapIndex() equivalent for slice/array

2021-06-05 Thread Howard Waterfall
Dammit!. How'd I miss that?! Thanks Dan. I updated the sample accordingly. On Fri, Jun 4, 2021, 9:10 PM Dan Kortschak wrote: > On Fri, 2021-06-04 at 20:29 -0700, Deiter wrote: > > The reflect package provides the SetMapIndex method for updating > > elements in a map that are represented by a

Re: [go-nuts] SetMapIndex() equivalent for slice/array

2021-06-04 Thread Howard Waterfall
I'm trying to decouple algorithm from type. if an algorithm works on a collection, it ought to work on either a map or slice. It appeared that result.Value facilitated the decoupling entirely, until I ran into the limitation with array/slice. It seems odd that I have to use the unsafe the package

Re: [go-nuts] Methods and pointer type receivers

2021-02-28 Thread Howard Waterfall
the way. I appreciate your insights. On Sun, Feb 28, 2021 at 5:23 AM Ian Lance Taylor wrote: > On Sat, Feb 27, 2021 at 9:12 PM Howard Waterfall > wrote: > > > > Thanks Ian! Some comments inline. > > Please write to the mailing list, not just to me. Thanks. > > >

Re: [go-nuts] Re: Resolving type ambiguity w/ functions that return an interface

2021-02-28 Thread Howard Waterfall
Thanks Brian, Axel & Ian for your very thorough treatment of my post. When I first read about golang interfaces, I was impressed with how elegant and powerful they are, so it's very disappointing that my first opportunity at leveraging them was such a fail! Your explanations did a remarkable job