Re: [go-nuts] What is the total max size of embed content?

2023-10-06 Thread Glen Newton
section SCOVERAGE_COUNTER (2097373648, over 2e+09 bytes)* (Which makes sense). https://pkg.go.dev/runtime/coverage https://github.com/golang/go/blob/master/src/cmd/link/internal/ld/data.go Glen On Monday, September 20, 2021 at 8:29:30 PM UTC-4 Glen Newton wrote: > Hello, > &g

[go-nuts] Re: are Go generics more like C++ or more like Java?

2022-03-17 Thread Glen Newton
>- exotic use-cases are not supported (for example having an integer *constant* as *generic parameter*, such as you see in C++ fixed size matrix templates, is not supported) Does a longer (but not necessarily exhaustive) list of the unsupported exotic use cases exist? This would be useful to

Re: [go-nuts] Float32 -> string --> Float32 round trip not possible for strconv.FormatFloat 'b' ?

2021-12-09 Thread Glen Newton
Thanks to both of you for this! Appreciated. :-) Glen On Thursday, December 9, 2021 at 11:20:11 PM UTC-5 kortschak wrote: > On Thu, 2021-12-09 at 17:22 -0800, Kurtis Rader wrote: > > Note that the documentation for ParseFloat states: "ParseFloat > > accepts decimal and hexadecimal

[go-nuts] Float32 -> string --> Float32 round trip not possible for strconv.FormatFloat 'b' ?

2021-12-09 Thread Glen Newton
Hello, I am using strconv.FormatFloat[1] and strconv.ParseFloat[2]to convert float32s back-and-forth in a library I am working on. In my tests I decided to test all formats for FormatFloat ('b', 'e', 'E', 'f', 'g', 'G', 'x', 'X'). However, it seems like the 'b' format is not supported by

Re: [go-nuts] What is the total max size of embed content?

2021-09-23 Thread Glen Newton
large text, data or bss segments. $ Previously reported: https://bugs.kde.org/show_bug.cgi?id=290061 Glen On Thursday, September 23, 2021 at 8:15:36 PM UTC-4 Glen Newton wrote: > I have a MWE here: https://github.com/gnewton/goembeddb > > TLDR: a MWE embedding a key-value store file of 2

Re: [go-nuts] What is the total max size of embed content?

2021-09-23 Thread Glen Newton
I have a MWE here: https://github.com/gnewton/goembeddb TLDR: a MWE embedding a key-value store file of 20 million k/v pairs (1.9GB) into a Go binary and using the db from the binary. The same Go program that writes the db then is recompiled, embedding the db in the newly compiled Go binary.

Re: [go-nuts] What is the total max size of embed content?

2021-09-21 Thread Glen Newton
ing an entire static web site from embedded files. The primary difference is the scale. Thanks, Glen On Tuesday, September 21, 2021 at 1:28:12 PM UTC-4 Ian Lance Taylor wrote: > On Tue, Sep 21, 2021 at 6:23 AM Glen Newton wrote: > > > > Looking at https://groups.google.com/g/go

Re: [go-nuts] What is the total max size of embed content?

2021-09-21 Thread Glen Newton
; looks better in errors than 2^31) The comment indicates that this is a limit in the linker; is this a limit in the elf format? If No, could the linker et al be modified to accept larger static data? Thanks, Glen On Monday, September 20, 2021 at 8:29:30 PM UTC-4 Glen Newton wrote: > He

Re: [go-nuts] What is the total max size of embed content?

2021-09-20 Thread Glen Newton
, 2021 at 5:11:45 PM UTC-4 Ian Lance Taylor wrote: > On Mon, Sep 20, 2021 at 2:04 PM Glen Newton wrote: > > > > I am testing this with an increasing number of 1GB files. At 3 files, > and I am getting this error: > > > > compile: writing output: write $WORK/b001/_pkg_

Re: [go-nuts] What is the total max size of embed content?

2021-09-20 Thread Glen Newton
AM Glen Newton wrote: > > > > The maximum size for any single embedded file as []byte is 4GB. What is > the total maximum size for all embedded files included this way in a Go > binary? > > Also, are there any platform dependencies? > > The total maximum size for a

[go-nuts] What is the total max size of embed content?

2021-09-20 Thread Glen Newton
Hello, The maximum size for any single embedded file as []byte is 4GB. What is the total maximum size for all embedded files included this way in a Go binary? Also, are there any platform dependencies? Thanks, Glen -- You received this message because you are subscribed to the Google Groups

[go-nuts] Supporting contained zip archives inside of tar and zip archives

2021-03-17 Thread Glen Newton
zip archives contain files and directories. Often, some of the files contained in zip archives are also archives, zip and tar(.gz|bz2). Sometimes, these contained archives also contain such archives (and so on...). Reading a zip file requires an io.ReaderAt in the func zip.NewReader(r

[go-nuts] New methods on imported structs: how do I do this with complex external structs

2020-10-13 Thread Glen Newton
Hello, Context: looked at: https://stackoverflow.com/questions/28800672/how-to-add-new-methods-to-an-existing-type-in-go as well as the discussion on this issue: ""cannot define new methods on non-local type ___" is not always an error #31631" https://github.com/golang/go/issues/31631

Re: [go-nuts] Get name of struct implementing interface using interface method, reflection

2020-05-08 Thread Glen Newton
Thanks! Oh no, when I try that here: https://play.golang.org/p/RV-S4MJWYUi Did not work: similar results: instead of: BaseFoo BaseFoo BaseFoo BaseFoo now I get: main.BaseFoo main.BaseFoo main.BaseFoo main.BaseFoo Other suggestions? :-) Thanks, Glen -- You received this message because you

[go-nuts] OPI: IBM Job: Go Compiler Developer on IBM's Z Enterprise

2020-03-17 Thread Glen Newton
Interesting. I just stumbled on it (I have no affiliations). https://careers.ibm.com/ShowJob/Id/850903/Go%20Compiler%20Developer *"The IBM Compiler development team is looking to hire Open Source software developers with a passion for Golang to join our mission in developing a

Re: [go-nuts] Re: Temporarily allow unused variables

2019-01-09 Thread Glen Newton
I use the "if false{..." extensively as described above. -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. For more

[go-nuts] Re: Go Performance

2018-10-30 Thread Glen Newton
I would also be interested in the memory comparison. Glen On Tuesday, October 30, 2018 at 1:03:13 PM UTC, T L wrote: > > OP really should compare the memory consumptions of the Java version and > Go version. > > On Monday, October 29, 2018 at 4:53:52 PM UTC-4, robert engels wrote: >> >> Hello

[go-nuts] Re: Why isn't os.File an interface?

2018-04-09 Thread Glen Newton
Thanks! Apologies for not doing a quick search for this. Thanks, Glen On Monday, April 9, 2018 at 2:40:19 PM UTC-4, Glen Newton wrote: > > Hello, > > I was wondering why os.File is a struct and not an interface. It does not > expose anything except methods. > > I was w

[go-nuts] Why isn't os.File an interface?

2018-04-09 Thread Glen Newton
Hello, I was wondering why os.File is a struct and not an interface. It does not expose anything except methods. I was wanting to make a mock os.File for testing and other purposes, but it not being an interface makes this not easy. Unless I am missing something here. Thanks, Glen -- You

[go-nuts] Re: golang with single-page HTML.

2018-01-24 Thread Glen Newton
Try https://github.com/icza/gowut https://gowut-demo.herokuapp.com/show Glen On Wednesday, January 24, 2018 at 4:24:51 PM UTC-5, matthe...@gmail.com wrote: > > One way is the server still serves all of those endpoints, but instead of > returning a full HTML page they each just return data.

Re: [go-nuts] Re: Web Framework for Beginners

2018-01-24 Thread Glen Newton
I am not going to be popular expressing this, but I really really really like gowut: https://github.com/icza/gowut Just write (drop-dead simple) Go code for SPA, AJAX handled transparently, no fiddling with Javascript. See: Gowut - Showcase of Features

[go-nuts] Re: [ANN] Go Jupyter kernel and an interactive REPL

2018-01-16 Thread Glen Newton
Wow! This is great and positions Go better in the 'data science' world! Thanks, Glen On Tuesday, January 16, 2018 at 8:53:39 AM UTC-5, Yu Watanabe wrote: > > Hi Gophers, > > I developed a new Go's Jupyter Notebook kernel and > REPL environment. > I would like to announce

Re: [go-nuts] Calling the Go compiler inside of tests

2017-12-15 Thread Glen Newton
YES! This looks like it is exactly what I needed! Thanks! Glen On Friday, December 15, 2017 at 3:55:51 PM UTC-5, Ian Cottrell wrote: > > You could just use the go/types package to typecheck the result instead of > compiling it, depending on exactly what you want to check that may be > enough.

[go-nuts] Calling the Go compiler inside of tests

2017-12-15 Thread Glen Newton
Hello, Apologies if this has already been discussed. I have a go tool (chidley - https://github.com/gnewton/chidley) that converts xml to Go struct code by examining a sample file (perhaps very large) of the XML (It can also generate Java JAXB code...). Production examples of generated

[go-nuts] Just launched a new Go Community Site

2017-07-02 Thread Glen Newton
Suggest displaying timestamp of entries. Very annoying (read 'very un-useful') to look through such a list without a published date/time... -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails

[go-nuts] Re: production PDF to text service

2017-06-18 Thread Glen Newton
Could you list the 2 packages? Glen On Sunday, June 18, 2017 at 6:27:40 PM UTC-4, svj...@gmail.com wrote: > > Can someone with experience with the problem suggest a best package for > building a production PDF to text conversion service in Go? I am working > with Go and Google App Engine. A

Re: [go-nuts] Re: chidley: XML to Go structs

2017-06-15 Thread Glen Newton
Without your XML file I cannot figure out the issue. If you are OK with sharing your XML file, please post it with the issue at: https://github.com/gnewton/chidley/issues Thanks, Glen On Wednesday, June 14, 2017 at 2:54:28 PM UTC-4, shrinkhala singhania wrote: > > Hi, > > I tried running my

[go-nuts] Re: filago: Monitor a Linux process' opening and closing of files, including Unix pipes and sockets

2017-06-05 Thread Glen Newton
The functionality filago provides can be implemented with truss or strace. filago offers a simpler (to many) way of getting to this information, and can provide it in json as well. Thanks, Glen On Monday, June 5, 2017 at 3:25:20 PM UTC-4, Simon Ritchie wrote: > > Does this have some

[go-nuts] Re: filago: Monitor a Linux process' opening and closing of files, including Unix pipes and sockets

2017-06-05 Thread Glen Newton
Sorry about that: link to github: https://github.com/gnewton/filago Thanks, Glen On Friday, June 2, 2017 at 11:56:34 PM UTC-4, Glen Newton wrote: > > Monitor open files (via /proc/pid) of a process. Lists time when it first > sees the file open (which may be later than when the file

[go-nuts] filago: Monitor a Linux process' opening and closing of files, including Unix pipes and sockets

2017-06-02 Thread Glen Newton
Monitor open files (via /proc/pid) of a process. Lists time when it first sees the file open (which may be later than when the file actually opened, especially at startup of filago), and when it is no longer open. Stop running when target process ends. This includes anon_inode and tcp and

[go-nuts] Proposal: Tags on Interface types

2017-05-06 Thread Glen Newton
I would like to propose allowing annotations (tags) on Interface types. Only a subset of an Interfaces methods could be tagged. This subset is defined as methods that have a single return type and take no parameters (as a best practice, these methods should not change any state and be thread

[go-nuts] Re: How do I convert a byte into BigEndian or LittleEndian?

2017-02-27 Thread Glen Newton
Thanks! :-) On Monday, February 27, 2017 at 4:45:19 PM UTC-5, Glen Newton wrote: > > > > Given a byte b, how do I convert it to a byte of particular endianness? > It is not clear to me looking at "encoding/binary" > > (I am assuming that golang byte endiann

[go-nuts] Re: How do I convert a byte into BigEndian or LittleEndian?

2017-02-27 Thread Glen Newton
, ppc64le) if read by a Go program on them? Sorry for my confusion. :-) Thanks, Glen On Monday, February 27, 2017 at 4:45:19 PM UTC-5, Glen Newton wrote: > > > > Given a byte b, how do I convert it to a byte of particular endianness? > It is not clear to me looking at "encodi

[go-nuts] Re: How do I convert a byte into BigEndian or LittleEndian?

2017-02-27 Thread Glen Newton
Ack! Sorry. I was referring to *bit endianness* https://en.wikipedia.org/wiki/Bit_numbering On Monday, February 27, 2017 at 4:45:19 PM UTC-5, Glen Newton wrote: > > > > Given a byte b, how do I convert it to a byte of particular endianness? > It is not clear to me looking at &

[go-nuts] How do I convert a byte into BigEndian or LittleEndian?

2017-02-27 Thread Glen Newton
Given a byte b, how do I convert it to a byte of particular endianness? It is not clear to me looking at "encoding/binary" (I am assuming that golang byte endianness varies across architectures. If this is wrong please educate me). :-) Thanks, Glen -- You received this message because you

Re: go test -race much slower in 1.8 (was Re: [go-nuts] Go 1.8 is released)

2017-02-21 Thread Will Newton
.8.1 > > https://github.com/golang/go/issues/19133: Milestone Go1.8.1 Thanks, yes I had misread the github ticket. > Peter > > On Tuesday, February 21, 2017 at 5:41:25 AM UTC-5, Will Newton wrote: >> >> On Mon, Feb 20, 2017 at 8:23 PM, Ian Lance Taylor <ia...@golang.o

Re: go test -race much slower in 1.8 (was Re: [go-nuts] Go 1.8 is released)

2017-02-21 Thread Will Newton
On Mon, Feb 20, 2017 at 8:23 PM, Ian Lance Taylor <i...@golang.org> wrote: > On Mon, Feb 20, 2017 at 12:06 PM, Will Newton <will.new...@gmail.com> wrote: >> On Thu, Feb 16, 2017 at 9:01 PM, Chris Broadfoot <c...@golang.org> wrote: >>> Hello gophers, >>>

Re: [go-nuts] Go 1.8 is released

2017-02-20 Thread Will Newton
On Thu, Feb 16, 2017 at 9:01 PM, Chris Broadfoot wrote: > Hello gophers, > > We just released Go 1.8. > > You can read the announcement blog post here: > https://blog.golang.org/go1.8 > > You can download binary and source distributions from our download page: >

[go-nuts] Could Go http serve somehow use Apache modules? Interested in modsecurity in particular...

2017-01-06 Thread Glen Newton
Hello, I was wondering if Apache modules could somehow be exposed and used by Go http. My motivation is that ModSecurity is pretty attractive: https://modsecurity.org/ I know the default config for Go web is to put it behind Apache or nginx, but recent discussions

Re: [go-nuts] Debug memory leaks in cgo calls

2016-12-16 Thread Will Newton
On Thu, Dec 15, 2016 at 12:57 AM, Pablo Rozas Larraondo wrote: > I've seen this question asked before in the mail list but with no clear > answers. I'm just asking it again in case someone has come up with a new way > of doing this: > > Does anyone know about a good

Re: [go-nuts] Mobile + camera

2016-09-23 Thread Glen Newton
ough for accessing the camera from Go. In practice, the new features are > very recent and you might encounter problems along the way. Feel free to > report any issues you encounter and CC them to me :) > > - elias > > On Friday, September 23, 2016 at 5:16:08 PM UTC+2, Gl

Re: [go-nuts] Mobile + camera

2016-09-23 Thread Glen Newton
Are there any updates on this topic, i.e. can I use Go to talk to the Android camera? Thanks, Glen -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to