Re: [go-nuts] Deleting the /r/golang subreddit

2016-11-30 Thread 'Axel Wagner' via golang-nuts
There is also HN currently in existence, as much as I despise the interface. But I would like to warn against building a go-specific (or only adopted by go) solution to this; the cross-pollination with other communities is a specific advantage of reddit that isn't just a technical restriction that

[go-nuts] Deleting the /r/golang subreddit

2016-11-30 Thread austin
I don't weigh in often because the Go team has been very good about vetting their options before executing them. I want to highlight that because that is what I feel Brad is doing here. I do not think they are going nuclear and pulling the trigger. I appreciate that we are consider the ethics in

Re: [go-nuts] Re: locks and "happens before" withing a goroutine

2016-11-30 Thread Ian Lance Taylor
On Wed, Nov 30, 2016 at 5:44 PM, Daniel Fanjul wrote: > I cannot tell if there is any memory barrier in the code of > sync.RWMutex.Lock(), I don't understand it completely. I just think there is > not. > https://golang.org/src/sync/mutex.go?s=1143:1165#L34 The sync/atomic routines provides memory

[go-nuts] go test -bench -benchmem, allocs/op mystery

2016-11-30 Thread Dave Cheney
The build flag -gcflags=-m will cause the compiler to report which allocations escape to the heap. Give that a try and see what it tells you. -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emai

[go-nuts] logrus and aws lambda now working

2016-11-30 Thread JM
im running go in aws lambda via node and a js wrapper. Everything works but when i try to log to cloudwatch it blows up and returns my log statements in the output of my lambda functions. Is anyone using golang in lambda and able to log to cloudwatch? How are you doing it? I just now realiz

[go-nuts] Go 1.8 Beta 1 is released

2016-11-30 Thread Chris Broadfoot
Hello gophers, We have just released go1.8beta1, a beta version of Go 1.8. It is cut from the master branch at the revision tagged go1.8beta1. There are no known problems or regressions. Please try running production workloads and your unit tests with the new version. It is important that we fi

Re: [go-nuts] Processing Images with baked data

2016-11-30 Thread Nigel Tao
On Wed, Nov 30, 2016 at 4:46 AM, wrote: > I know there is an image package that exist in Golang that implements encode > and decode functionality, but how can I get other data from an image?. For > example I am trying to get iTXt chunks from PNG images, is there any way I > can do this? Not in t

[go-nuts] Need canonical Dockerfile examples for web-based golang project

2016-11-30 Thread Arun S. Kumar
Hello Gophers, I am looking for links to some open-source go projects that uses Dockerfile in an idiomatic way for building and deploying go based web apps to cloud services like aws etc. Thanks in advance. Thanks, Arun -- You received this message because you are subscribed to the Google Group

Re: [go-nuts] Re: locks and "happens before" withing a goroutine

2016-11-30 Thread Dave Cheney
Inside a single goroutine the code proceeds in statement order. If it didn't chaos would ensue, it would be as if statements in a function were executed in random order. However, from the view of another goroutine, without synchronising operations like channel sends and receives, or agreeing in

Re: [go-nuts] Re: locks and "happens before" withing a goroutine

2016-11-30 Thread Caleb Spare
I think the bit you're missing is this: > Within a single goroutine, the happens-before order is the order expressed by > the program. That is, there is an implicit happens-before between each successive statement *within a single goroutine*. So in the example: - the first l.Lock() happens-bef

[go-nuts] Re: locks and "happens before" withing a goroutine

2016-11-30 Thread Daniel Fanjul
I cannot tell if there is any memory barrier in the code of sync.RWMutex.Lock(), I don't understand it completely. I just think there is not. https://golang.org/src/sync/mutex.go?s=1143:1165#L34 -- You received this message because you are subscribed to the Google Groups "golang-nuts" group.

[go-nuts] Re: locks and "happens before" withing a goroutine

2016-11-30 Thread Daniel Fanjul
I think the current implementations of the methods of sync.RWMutex happen to be actual memory barriers and this is why everything works just fine. But I don't think the spec or the memory model or the doc of sync mentions this. If this is not desc

[go-nuts] locks and "happens before" withing a goroutine

2016-11-30 Thread Daniel Fanjul
Hi gophers, The code "a = 1; b = 2;" within a goroutine does not ensure any "happens before" relation between these assignments for an external observer. My doubt is with the code "a = 1; x.Lock(); b = 2;" where x is a sync.RWMutex. Does the spec (or the memory model or anything else) ensure t

Re: [go-nuts] Certain float64 values lose precision on assignment

2016-11-30 Thread russ . vanderwaal
Thank you. On Wednesday, November 30, 2016 at 5:05:05 PM UTC-8, Jan Mercl wrote: > > On Thu, Dec 1, 2016 at 1:53 AM Raz Varren > wrote: > > > I've stumbled across an issue with some float64 numbers, where they get > rounded up as soon as they are assigned to a variable. > > A float64 variable ha

Re: [go-nuts] Certain float64 values lose precision on assignment

2016-11-30 Thread Jan Mercl
On Thu, Dec 1, 2016 at 1:53 AM Raz Varren wrote: > I've stumbled across an issue with some float64 numbers, where they get rounded up as soon as they are assigned to a variable. A float64 variable has only a limited, finite precision, so rounding an ideal value when materializing it to actual CP

Re: [go-nuts] Re: Understanding go routine heap

2016-11-30 Thread Ian Lance Taylor
On Wed, Nov 30, 2016 at 2:35 PM, Daniel Fanjul wrote: > Err... I think you understood the opposite. > > A no answer would mean this is that issue. A yes answer means the mutex is > still not enough. I said yes. I understood that, but the only implication I could draw is that mutexes are useless.

[go-nuts] Certain float64 values lose precision on assignment

2016-11-30 Thread Raz Varren
I've stumbled across an issue with some float64 numbers, where they get rounded up as soon as they are assigned to a variable. package main import ( "fmt" "strconv" ) func main() { fmt.Println(.0 == 1.0) //false f1 := .0 f2 := 1

[go-nuts] Re: Large 2D slice performance question

2016-11-30 Thread Mandolyte
Thanks for the discussion! Package with tester is at: https://github.com/mandolyte/TableRecursion While I can't share the data, I could take a sample set of paths for a root node, reverse engineer the pairs, and obfuscate... I've done this sort of thing before but it is a bit of work. So I'll tr

Re: [go-nuts] Re: Understanding go routine heap

2016-11-30 Thread Daniel Fanjul
Err... I think you understood the opposite. A no answer would mean this is that issue. A yes answer means the mutex is still not enough. I said yes. On Wednesday, November 30, 2016 at 11:23:49 PM UTC+1, Ian Lance Taylor wrote: > > On Wed, Nov 30, 2016 at 2:01 PM, Daniel Fanjul > > wrote: >

[go-nuts] Re: Large 2D slice performance question

2016-11-30 Thread Mandolyte
The finite set idea might work, but the set is well over 300K. The strings (part numbers) are not regular. I could make a single pass over the "parent" column and record in a map[string]int the index of the first occurrence. Then I would avoid sort.Search() having to find it each time. Or use s

Re: [go-nuts] Re: "Why does Go not have covariant result types?"

2016-11-30 Thread Ian Lance Taylor
On Wed, Nov 30, 2016 at 2:11 PM, wrote: > That works for me! Thanks for your answer. Difficult for humans to reason > about + difficult to implement seems like a decent reason to leave it out > :). > In general, do you think covariant types are more trouble than they're > worth? > I don't think I

Re: [go-nuts] Re: Understanding go routine heap

2016-11-30 Thread Ian Lance Taylor
On Wed, Nov 30, 2016 at 2:01 PM, Daniel Fanjul wrote: > I was going to answer no, but after a careful review of the go memory model > section regarding locks, I am replying: yes, I would. > > Because the memory model only specifies "happens before" restrictions > between calls to Lock() and Unlock

Re: [go-nuts] Re: Large 2D slice performance question

2016-11-30 Thread Mandolyte
I'll try to get it out on Github tonight. It will have a little test program so you can see what it generates. Will post again when it's there. On Wednesday, November 30, 2016 at 11:28:16 AM UTC-5, Michael Jones wrote: > > Yes…the more that you can share the better our help will be. If you have

[go-nuts] Re: "Why does Go not have covariant result types?"

2016-11-30 Thread groenendaal92
That works for me! Thanks for your answer. Difficult for humans to reason about + difficult to implement seems like a decent reason to leave it out :). In general, do you think covariant types are more trouble than they're worth? I don't think I've ever encountered them before (or if I did, I did

Re: [go-nuts] Re: Understanding go routine heap

2016-11-30 Thread Daniel Fanjul
I was going to answer no, but after a careful review of the go memory model section regarding locks, I am replying: yes, I would. Because the memory model only specifies "happens before" restrictions between calls to Lock() and Unlock() and that is not this case. "For any sync.Mutex or sync.RWMu

Re: [go-nuts] Re: Understanding go routine heap

2016-11-30 Thread Ian Lance Taylor
On Wed, Nov 30, 2016 at 1:31 PM, Daniel Fanjul wrote: > Case A: because there is a write and then a method call that does not touch > that variable. The go memory model apply only to reads and writes of the > same variables. So any possible reordering in this scenario fulfills "the > reordering do

Re: [go-nuts] "Why does Go not have covariant result types?"

2016-11-30 Thread Ian Lance Taylor
On Wed, Nov 30, 2016 at 1:12 PM, wrote: > > I had a question and when I looked through the FAQ I saw it: > https://golang.org/doc/faq#covariant_types. But could anyone give more > information specifically as to why Go does not have "covariant types"? What > is > the motivation behind that choice?

Re: [go-nuts] Re: Understanding go routine heap

2016-11-30 Thread Daniel Fanjul
Case A: because there is a write and then a method call that does not touch that variable. The go memory model apply only to reads and writes of the same variables. So any possible reordering in this scenario fulfills "the reordering does not change the behavior within that goroutine as defined

[go-nuts] "Why does Go not have covariant result types?"

2016-11-30 Thread groenendaal92
I had a question and when I looked through the FAQ I saw it: https://golang.org/doc/faq#covariant_types. But could anyone give more information specifically as to why Go does not have "covariant types"? What is the motivation behind that choice? If Go did support it, what kind of problems could c

[go-nuts] Re: Interface help

2016-11-30 Thread sc28
Thanks On Wednesday, November 30, 2016 at 2:05:59 PM UTC-5, parais...@gmail.com wrote: > > Just create a slice of GoNoGoer > > var evals []GoNoGoer > > now you DO NOT need a type assertion like that > > if ok := eval.(GoNoGoer); ok // REMOVE that line > > > Le mercredi 30 novembre 2016 17:59:0

[go-nuts] Re: Why do plugins require a main package?

2016-11-30 Thread Craig Peterson
It appears this is not a hard requirement. In my tests I can successfully load a compiled plugin with no exported functions or variables. On Wednesday, November 30, 2016 at 12:37:23 PM UTC-7, Lars Tørnes Hansen wrote: > > I would pay attention to > > > > > > > *with exported functions and varia

Re: [go-nuts] Re: Understanding go routine heap

2016-11-30 Thread Ian Lance Taylor
On Wed, Nov 30, 2016 at 12:36 PM, Daniel Fanjul wrote: > Yes, I saw your assert and I trust it but I don't see how that answers my > question. > > There are 4 things that we expect to happen in order: > 1) assignment to result, > 2) call to wg.Done(), > 3) call to wg.Wait(), > 4) read of result. >

Re: [go-nuts] Why do plugins require a main package?

2016-11-30 Thread Craig Peterson
> > > We could arrange for the go tool (probably not the compiler itself) to > optionally auto-generate a main package. Want to write a patch? > > Yes. Yes I do. Not sure exactly where to start, but I will start digging. I will file an issue to track I suppose. -- You received this message

Re: [go-nuts] Why do plugins require a main package?

2016-11-30 Thread Ian Lance Taylor
On Wed, Nov 30, 2016 at 9:47 AM, Craig Peterson wrote: > > This feels like unnecessary boilerplate to me. Can anyone explain what are > the technical reasons for requiring a main package? Could the compiler not > generate a main package shim like this if you try to build a library package > with -

Re: [go-nuts] Re: Understanding go routine heap

2016-11-30 Thread Daniel Fanjul
Yes, I saw your assert and I trust it but I don't see how that answers my question. There are 4 things that we expect to happen in order: 1) assignment to *result,* 2) call to *wg.Done()*, 3) call to *wg.Wait()*, 4) read of *result*. So there is no race condition if we can prove: A) that (1) hap

Re: [go-nuts] Re: Understanding go routine heap

2016-11-30 Thread Ian Lance Taylor
On Wed, Nov 30, 2016 at 10:04 AM, Daniel Fanjul wrote: > > I still don't understand this issue completely. > > Sure, the call to wg.Done() will "happen before" wg.Wait() finishes, but the > assignment "result = &foo{1}" might still happen concurrently. > > I think the problem is the semantics of t

[go-nuts] Re: Why do plugins require a main package?

2016-11-30 Thread Lars Tørnes Hansen
I would pay attention to *with exported functions and variables.Fxfunc SomeFunc() {}* *https://golang.org/ref/spec#Exported_identifiers* Den onsdag den 30. november 2016 kl. 20.13.10 UTC+1 skrev Craig Peterson: > > From the 1.8 plugin docs : > > A plug

[go-nuts] Re: net.Conn.Read() performance

2016-11-30 Thread antondoe
Any thoughts, anyone? -- 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 options, visit https://groups.google.com/

[go-nuts] Why do plugins require a main package?

2016-11-30 Thread Craig Peterson
>From the 1.8 plugin docs : A plugin is a Go main package with exported functions and variables This creates a bit of a headache for me. My current setup is that a plugin is a simple library package like so: package someLibrary import "gihub.com/someapp/pl

[go-nuts] Re: [golang-dev] How to improve the performance of io.Copy during copying data from one TCP connection to another TCP connection

2016-11-30 Thread subrata das
Hi, I took the CPU profiling for 180 Second --- Started the traffic to proxy for infinite time, start the profiler using --- go tool pprof -seconds=180 http://localhost:6060/debug/pprof/profile using web command -- I checked the those io.Copy is taking 60.50 second, out of 180 second. io.Copy()

[go-nuts] Re: Interface help

2016-11-30 Thread paraiso . marc
Just create a slice of GoNoGoer var evals []GoNoGoer now you DO NOT need a type assertion like that if ok := eval.(GoNoGoer); ok // REMOVE that line Le mercredi 30 novembre 2016 17:59:07 UTC+1, sc28 a écrit : > > I'm trying to better understand how to properly use interfaces and created >

Re: [go-nuts] Re: Understanding go routine heap

2016-11-30 Thread Daniel Fanjul
That quote of the spec does not apply here, because there are no multiple reads and writes. There is one write to 'result' and one method call that will not read or write that 'result'. On Wednesday, November 30, 2016 at 7:34:12 PM UTC+1, Jan Mercl wrote: > > On Wed, Nov 30, 2016 at 7:04 PM Dan

Re: [go-nuts] synchronise read from two channels

2016-11-30 Thread Michael Jones
It seems that you are fighting the helpful infrastructure, but I can’t be sure from what you’ve said. You can (presumably) just do this: For u := range streamOfUrls { For w := range availableWorkers {   w.url = u   activeWorkers <- w } } …but that is strange to me. Why not jus

Re: [go-nuts] Re: Understanding go routine heap

2016-11-30 Thread Jan Mercl
On Wed, Nov 30, 2016 at 7:04 PM Daniel Fanjul < daniel.fanjul.alcu...@gmail.com> wrote: > Sure, the call to wg.Done() will "happen before" wg.Wait() finishes, but the assignment "result = &foo{1}" might still happen concurrently. > > I think the problem is the semantics of the defer and the discus

Re: [go-nuts] Re: Understanding go routine heap

2016-11-30 Thread Daniel Fanjul
Hi, I still don't understand this issue completely. Sure, the call to *wg.Done()* will "happen before" *wg.Wait()* finishes, but the assignment *"result = &foo{1}"* might still happen concurrently. I think the problem is the semantics of the *defer* and the discussion is reduced completely to

[go-nuts] synchronise read from two channels

2016-11-30 Thread omarshariffdontlikeit
Hi, I'm having a bit of a slow day... I'm trying to synchronise two reads from two channels and can't get my fuzzy head round the problem. I have a channel containing urls (which will be feed periodically by a named pipe by another program) and I have a cannel which consists of a pool of availa

[go-nuts] Interface help

2016-11-30 Thread sc28
I'm trying to better understand how to properly use interfaces and created this scenario: Let's say I have an 'evaluator' program, that over time will want to add more and more evaluations of a Go-NoGo nature (Nasa?) Here's want I was trying: // My Go-NoGo interface - method should return true

Re: [go-nuts] runtime.GC - documentation

2016-11-30 Thread 'Austin Clements' via golang-nuts
On Tue, Nov 29, 2016 at 6:57 PM, Rick Hudson wrote: > That is correct. ... but not guaranteed. :) -- 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+

Re: [go-nuts] Re: Large 2D slice performance question

2016-11-30 Thread Michael Jones
Yes…the more that you can share the better our help will be. If you have a small, even synthetic example of before and after we can do our best. From: adonovan via golang-nuts Reply-To: Date: Wednesday, November 30, 2016 at 6:31 AM To: golang-nuts Subject: [go-nuts] Re: Large 2D slice perfo

[go-nuts] Re: Supervisor Golang app

2016-11-30 Thread gnikosn
Thank's you very much Τη Τρίτη, 29 Νοεμβρίου 2016 - 8:03:09 μ.μ. UTC+2, ο χρήστης gni...@gmail.com έγραψε: > > Hi my environment variables are : > > GOPATH="/root/work" > > > GOROOT="/usr/local/go" > > and my supervisor of my app are : > > [program:appname] > > command=/work/bin/appname > > aut

Re: [go-nuts] BuckHashSys growth

2016-11-30 Thread Ian Lance Taylor
On Tue, Nov 29, 2016 at 10:27 PM, Levi Corcoran wrote: > Thanks much. Memory allocation does indeed appear 'spread out' as a result > of some recursive function calls of varying depth that get called during > serialization, and a variety of code paths that can trigger the > serialization, at leas

[go-nuts] Re: [golang-dev] How to improve the performance of io.Copy during copying data from one TCP connection to another TCP connection

2016-11-30 Thread Russ Cox
+golang-nuts, bcc golang-dev How did you get the pprof profile? How long did your test run for? pprof has 12 seconds of CPU profile samples (the Total: line). If your test ran for a lot more than 12 seconds (typically a profile is fetched for 30 seconds), then the problem is not the CPU usage. If

Re: [go-nuts] Are Go locks/mutex not the same as ordinary locks/mutexes?

2016-11-30 Thread adonovan via golang-nuts
On Tuesday, 29 November 2016 13:10:49 UTC-5, Ian Lance Taylor wrote: > > On Tue, Nov 29, 2016 at 9:51 AM, Roger Alsing > wrote: > > Coming from C++/C# background where locks/mutexes are considered evil > due to > > blocking threads. > > Due to how the Go goroutine scheduler works, are the Go c

[go-nuts] Re: Large 2D slice performance question

2016-11-30 Thread adonovan via golang-nuts
> > On Wednesday, 30 November 2016 03:37:55 UTC+2, Mandolyte wrote: >> >> I have a fairly large 2D slice of strings, about 115M rows. These are >> (parent, child) pairs that, processed recursively, form a tree. I am >> "materializing" all possible trees as well as determining for each root >> n

Re: [go-nuts] CFG for a Go program

2016-11-30 Thread adonovan via golang-nuts
On Wednesday, 30 November 2016 05:13:15 UTC-5, akshans...@gmail.com wrote: > > Thanks a lot for your valuable suggestions. I think the one using SSA form > will be helpful for my project. > Lest there be any confusion: there are two unrelated SSA forms for Go code, the one used internally by th

[go-nuts] go test -bench -benchmem, allocs/op mystery

2016-11-30 Thread Erwin Driessens
When I 'go test -bench . -benchmem', I sometimes see small numbers reported in allocs/op that I can't spot in the code for the function that was benchmarked. For example, the following function: func Mul_c(m1, m2, m3 *Matrix) { // validate r1, c1 := m1.Dim() r2, c2 := m2.Dim() r3, c3 := m3.Dim(

[go-nuts] Error - Redefinition of 'GoString' as different kind of symbol

2016-11-30 Thread Tamás Gulácsi
Simple: don't use GString, but pass the *char,int (pointer and length) to a Go helper which treat it as a []byte. -- 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

[go-nuts] ANN: A HTTP backed File System (FUSE)

2016-11-30 Thread prologic
Hey all, First time poster here so go easy on me :) Just sharing httpfs: https://github.com/prologic/httpfs (Naming is hard!) This is basically a HTTP backed FileSystem using FUSE via the wonderful bazil.org/fuse library. Why? Scratching my own itch to present remote storage on my home NAS as a

Re: [go-nuts] Golang asm to real asm table/doc/tool

2016-11-30 Thread jsonp via golang-nuts
Sorry, where is oplook, buildop and asmout? On Wednesday, November 30, 2016 at 7:43:25 AM UTC+11, Aram Hăvărneanu wrote: > > On Tue, Nov 29, 2016 at 8:59 PM, matt > > wrote: > > Where in the source code does it map say MOVBU.P to ldrb post increment? > > It's complicated, there's no trivial eas

Re: [go-nuts] goroutine/channel errors?

2016-11-30 Thread Mandolyte
Perfect! thanks for the quick reply. On Wednesday, November 30, 2016 at 7:32:09 AM UTC-5, Jan Mercl wrote: > > On Wed, Nov 30, 2016 at 1:21 PM Mandolyte > > wrote: > > > tr.sema <- struct{}{} > > > What is this telling me? > > The particular channel send operation was blocked for 595 minutes be

[go-nuts] Error - Redefinition of 'GoString' as different kind of symbol

2016-11-30 Thread laszlo . hordos
Hi, I'm trying to write a CGo shared library and I get a error always because I found these two definition in https://github.com/golang/go/blob/master/src/cmd/cgo/out.go *typedef struct { const char *p; GoInt n; } GoString;* * _GoString_ GoString(char *p);* I just wrote a simple sample co

Re: [go-nuts] goroutine/channel errors?

2016-11-30 Thread Jan Mercl
On Wed, Nov 30, 2016 at 1:21 PM Mandolyte wrote: > tr.sema <- struct{}{} > What is this telling me? The particular channel send operation was blocked for 595 minutes before the stack trace was produced. It shows nothing is receiving from that channel which might indicate a bug in the program or

[go-nuts] goroutine/channel errors?

2016-11-30 Thread Mandolyte
This morning a job that I had started last night was spitting out messages like this: goroutine 23866180 [chan send, 595 minutes] followed a stack trace, the first line number of which was pointing to this line of code: tr.sema <- struct{}{} What is this telling me? -- You received th

[go-nuts] Re: Hide struct fields from frontend code (JSON REST API)

2016-11-30 Thread Tahir Hashmi
It would be easier to do: type User struct { Name string `json:"name"` } type PrivateUser struct { User Password string `json:"password"` } See https://play.golang.org/p/2VlGgRlrP1 On Wednesday, November 30, 2016 at 2:42:19 PM UTC+5:30, Mirco Zeiss wrote: > > Maybe I'll just wait for go 1.8 whe

Re: [go-nuts] CFG for a Go program

2016-11-30 Thread akshanshchahal
Thanks a lot for your valuable suggestions. I think the one using SSA form will be helpful for my project. On Monday, November 28, 2016 at 7:38:13 AM UTC+5:30, adon...@google.com wrote: > > If you're building tools for source code analysis, you may find the > golang.org/x/go/ssa representation

Re: [go-nuts] CFG for a Go program

2016-11-30 Thread akshanshchahal
Thanks Keith for your suggestion ! On Sunday, November 27, 2016 at 7:24:45 AM UTC+5:30, Keith Randall wrote: > > You can get the CFG (control flow graph) for a function by setting the > environment variable GOSSAFUNC to the function in question when building. > It will generate a file named ssa.h

[go-nuts] Re: CFG for a Go program

2016-11-30 Thread akshanshchahal
Sorry, didn't mention it properly. I want Control Flow Graph (CFG) for any given Go Program. On Saturday, November 26, 2016 at 11:57:15 AM UTC+5:30, akshans...@gmail.com wrote: > > Hi, > > I need the CFG for a Golang Program. > Any suggestions about which way can I access the CFG. > > Thank you

[go-nuts] Re: Go is two times slower than python code?

2016-11-30 Thread Thomas Modeneis
+6 years later, It seems that this issue still a problem. There is a open ticket on github for it: https://github.com/golang/go/issues/16791 I've been facing this issue for a while, and on my experience the best workaround is to serialize the CSV to the disk after reading it. Cheers. On Tuesda

[go-nuts] Re: Hide struct fields from frontend code (JSON REST API)

2016-11-30 Thread Mirco Zeiss
Maybe I'll just wait for go 1.8 where the following is possible, because tags aren't part of types anymore. type PublicUser struct{ Password string `json:"-"` Name string `json:"name"` } type PrivateUser struct{ Password string `json:"password"` Name string `json:"name"` } func main() {

[go-nuts] Re: Large 2D slice performance question

2016-11-30 Thread Egon
On Wednesday, 30 November 2016 03:37:55 UTC+2, Mandolyte wrote: > > I have a fairly large 2D slice of strings, about 115M rows. These are > (parent, child) pairs that, processed recursively, form a tree. I am > "materializing" all possible trees as well as determining for each root > node all ch