Matthew Zimmerman | 28 May 03:33 2015
Picon

Re: leveldb - golang - levigo

** Back on list **

That's because you're using levigo which is a cgo based wrapper for the C-based leveldb.  You may have fetched github.com/syndtr/goleveldb/leveldb using go get, but you're still referencing levigo in your import paths.  syndtr's implementation doesn't reference any C header files since it's a pure Go implementation.

On Wed, May 27, 2015 at 9:29 PM Prajakta Dandawate <prajakta.dandawate-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
Now I am getting following error. Please help me.

 go build ./...
# github.com/jmhodges/levigo/examples
src/github.com/jmhodges/levigo/examples/comparator_example.go:6:23: error: leveldb/c.h: No such file or directory
# github.com/jmhodges/levigo
src/github.com/jmhodges/levigo/batch.go:4:24: error: leveldb/c.h: No such file or directory

Thanks

On Wed, May 27, 2015 at 8:57 PM, Matthew Zimmerman <mzimmerman-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
And I've usedgithub.com/syndtr/goleveldb/leveldb which is working great for me.  code.google.com/p/leveldb-go is not being maintained anymore.

On Wed, May 27, 2015 at 8:42 PM Michael Jones <mtj-mrStQ/BkNDnqlBn2x/YWAg@public.gmane.org> wrote:

I use levigo by J. M. Hodges:

https://www.google.com/url?sa=t&source=web&rct=j&ei=z2NmVYS9OIKroQTb2YLQDg&url=https://github.com/jmhodges/levigo&ved=0CB4QFjAA&usg=AFQjCNEoSxZ0uk5YB-x2hKMpH9oGRmfDzw

Wotks perfectly for me.

On May 27, 2015 3:41 PM, "Prajakta Dandawate" <prajakta.dandawate-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
Hello

I am very new to golang and have a basic question

Please let me know if there exists latest working leveldb package can be used by golang?
Is there any example?

Which leveldb should be used?
or

Regards
PD

--
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+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.

--
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+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.

--
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+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.
Jeremy S | 28 May 02:30 2015
Picon

AST (abstract syntax tree) parser for another language

Hi everyone,

I know that Go has a built-in ast package for parsing Go source files, but I was wondering if there is a way to parse the AST for other languages.
Specifically, I would like to use Go to parse the AST for Java source files.

Any help would be appreciated.

Thanks!

--
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+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.
bep | 28 May 02:48 2015
Picon

Optional library features

I'm not expecting a solution/answer to this -- but this may get someone to think.

Let's use https://github.com/spf13/viper as an example.

This is a useful little library for configuration management.

The core, and estimated 90% of the usage, is an in-memory map. But it also supports etcd for more advanced use.

But Go's static linking doesn't really handle this opt-ins very elegant. In this case etcd will be compiled in even if I do not use it.

I come from a decade++ in the Java world, and in that world the concept of feature switches based on "what's on the classpath" is very common.

In the case of Viper, the library itself could be split into a lean and mean version. But couldn't this somehow be solved at build time? GB?

bep

--
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+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.
Prajakta Dandawate | 27 May 23:59 2015
Picon

leveldb - golang - levigo

Hello

I am very new to golang and have a basic question

Please let me know if there exists latest working leveldb package can be used by golang?
Is there any example?

Which leveldb should be used?
or

Regards
PD

--
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+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.
Fatih Arslan | 27 May 23:49 2015

How to license vim-go (part of it was from misc/vim)

Hi,

As some of you know, vim-go includes the original misc/vim. Over the
course (~1 year) a lot of changes and improvements has been made. I
add a lot new features, improved the current ones. Not only me, 75
contributors has contributed to it already.

My problem is, I was asked about the license of vim-go
(https://github.com/fatih/vim-go/issues/443)

And to be honest I never thought about it. All my open source projects
are distributed with MIT license, so I truly want everyone to use it.
However I'm not a lawyer and have limited knowledge about licenses and
co.

The initial misc/vim files includes these lines:

" Copyright 2011 The Go Authors. All rights reserved.
" Use of this source code is governed by a BSD-style
" license that can be found in the LICENSE file.

It's still there in some of the files (with a lot of changes of course):

https://github.com/fatih/vim-go/blob/master/autoload/go/fmt.vim

Now, is it ok to license the vim-go project under 3-clause BSD (as
stated in the in the issue page):
http://opensource.org/licenses/BSD-3-Clause
Is there anything I should be aware of? I think this is fairly simple
process, but as said before I'm not an expert here and have limited
knowledge, so I'm asking to no get into any trouble in the future.

Regards

--

-- 
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+unsubscribe@...
For more options, visit https://groups.google.com/d/optout.

Brendan Tracey | 27 May 17:05 2015
Picon

Write barriers in GC

In the garbage collector coming up for 1.5, pointer writes are memory writes when the GC is off, but they are blocked by a write barrier when GC is on (see for example http://talks.golang.org/2015/state-of-go-may.slide#6). Could someone explain briefly how this is possible? The mutator code does not know when GC will start or end. I would have imagined that the compiled code would either need to have a memory write or need to go through a write barrier, but evidently it can switch somehow. I see how it's possible if there are two versions of everything (with and without write barriers), but I doubt this is the actual approach. I'm missing the mental model for how this can work.

--
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+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.
EduRam | 27 May 10:00 2015
Picon

Can go std lib support .ini files ?

Hi!

We are starting to evaluate Go lang, by porting some small +20yr old windows C programs.
The 1st task was "let's start to read .ini configuration files".
We were expecting on Windows to do that, but we could not found it on std lib.
That "raise a few eyebrows"! 
But we continue by using one random lib from github.

Even so, is it possible Go Standard Library, to support reading ".ini" files ?

Thanks,

Eduardo

PS: Sorry if this issue was already bring up on discussions.
I did not found it!

--
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+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.
Uriel Fanelli | 27 May 08:13 2015
Picon

Re: Re: Golang for Mission Critical Projects


>
> Nevertheless, I am reminded of Donald Knuth's famous words, "Beware of 
> bugs in the above code; I have only proved it correct, not tried it". 
> Indeed, a formal specification may not actually capture every 
> requirement, due to oversight or lack of formal clarity such as "not 
> able to start fires, flooding or damage third parties".

Maybe, but I was not talking of rewriting every line of code in lambda 
notation and use Hoare logics .
Still, if you want to do it, there are many automatic proof assistant 
now, which can speed the job.

In any case, after a semiformal verification, the quality of software is 
much, much, much higher.

And yes, undert the point of view of insurances, this matters.

But, again, at the end, living means to face reality, so let's see what 
will happen....

--

-- 
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+unsubscribe@...
For more options, visit https://groups.google.com/d/optout.

Uriel Fanelli | 27 May 08:07 2015
Picon

Re: Re: Golang for Mission Critical Projects



On 05/27/2015 04:41 AM, Benjamin Measures wrote:
On Tuesday, 26 May 2015 15:13:03 UTC+1, Uriel Fanelli wrote:
If you think how you do formal verifications  , you are going to do something like that:

You keep using that term- I do not think it means what you think it means.


Indeed, I should have used "semiformal".

--
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+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.

webuser1200 | 27 May 02:23 2015
Picon

PostForm and []byte

I'm looking at the following two examples from the docs:

resp, err := http.Post("http://example.com/upload", "image/jpeg", &buf)
...
resp, err := http.PostForm("http://example.com/form",
url.Values{"key": {"Value"}, "id": {"123"}})

Is there any way to pass a []byte data instead of string in url.Values in the PostForm example above. Or I have to do something along the lines in :

http://stackoverflow.com/questions/20205796/golang-post-data-using-the-content-type-multipart-form-data

If it is the latter (using a multi part form), is there an easier way to add form parameters instead of having to do the following for each form field:

    // Add the other fields
    if fw, err = w.CreateFormField("key"); err != nil {
        return
    }
    if _, err = fw.Write([]byte("KEY")); err != nil {
        return
    }

--
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+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.
rojer9 | 27 May 02:03 2015
Picon

controlling buffering of glog

glog's flush interval is currently fixed at 30 seconds which makes tailing them less useful by introducing a delay.
would be nice to have (an equivalent of) glog-cpp's --logbufsecs flag
alternatively, logbuflevel would be sufficient for the simplest case of turning buffering off completely.

P.S.: unaware of the export-only status of the github repository, i created a PR that implements --logbufsecs - https://github.com/golang/glog/pull/12

--
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+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.

Gmane