Hi everyone,
Is there any way to debug DLL files once it is loaded?
--
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.
To
is go-plugin supported by Windows?...We want to create go dll and tey to
access through go code
On Thursday, September 29, 2022 at 5:12:34 PM UTC+5:30 Brian Candler wrote:
> My first reaction is, do you *really* want to call a Go DLL from a Go main
> program? It seems to me like you will have t
import (
"encoding/json"
"fmt"
"io"
)
func PrintPrettyJSON(data any, writer io.Writer) error {
b, err := json.MarshalIndent(data, "", "")
if err != nil {
return err
}
content := string(b)
_, err = fmt.Fprintf(writer, "%s\n", content)
return err
}
On
On Thu, Sep 29, 2022 at 11:44 AM Rafael Ávila de Espíndola
wrote:
>
> Ian Lance Taylor writes:
>
> > On Thu, Sep 29, 2022 at 10:29 AM Rafael Ávila de Espíndola
> > wrote:
> >>
> >> Currently errors.Is(syscall.ENOENT, fs.ErrNotExist) return true, but
> >> errors.Is(syscall.EINVAL, fs.ErrInvalid)
Hello gophers,
We plan to issue Go 1.19.2 and Go 1.18.7 on Tuesday, October 4.
These minor releases include PRIVATE security fixes to the standard library.
Following our security policy, this is the pre-announcement of those releases.
Thanks,
The Go team
--
You received this message because y
Ian Lance Taylor writes:
> On Thu, Sep 29, 2022 at 10:29 AM Rafael Ávila de Espíndola
> wrote:
>>
>> Currently errors.Is(syscall.ENOENT, fs.ErrNotExist) return true, but
>> errors.Is(syscall.EINVAL, fs.ErrInvalid) returns false. As far as I can
>> tell that is because of
>>
>> func (e Errno) Is(
On Thu, Sep 29, 2022 at 10:29 AM Rafael Ávila de Espíndola
wrote:
>
> Currently errors.Is(syscall.ENOENT, fs.ErrNotExist) return true, but
> errors.Is(syscall.EINVAL, fs.ErrInvalid) returns false. As far as I can
> tell that is because of
>
> func (e Errno) Is(target error) bool {
> switch
On Thu, Sep 29, 2022 at 10:47 AM Mahesh Sharma wrote:
> Hi,
> I'm collecting some JSON from an end point. I can print this to screen:
> fmt.Printf("%s\n", bodyText).
>
> I'm struggling to figure how to write the bodyText to a file.
>
> Any help appreciated.
>
See https://gobyexample.com/writ
Hi All,
How I could detect programmatically that import in a go code
belongs to a go distribution ?
thank you very much for the answer.
--
You received this message because you are subscribed to the Google Groups
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails fro
Hi,
I'm collecting some JSON from an end point. I can print this to screen:
fmt.Printf("%s\n", bodyText).
I'm struggling to figure how to write the bodyText to a file.
Any help appreciated.
--
You received this message because you are subscribed to the Google Groups
"golang-nuts" grou
When we use go list -m dependencyName@Version to get the specific
information of the version of the dependency package, does the Version and
the tag of the dependency in github.com correspond, which tags will be
recognized by the go language, and allow us to pass the go list command Get
specifi
Currently errors.Is(syscall.ENOENT, fs.ErrNotExist) return true, but
errors.Is(syscall.EINVAL, fs.ErrInvalid) returns false. As far as I can
tell that is because of
func (e Errno) Is(target error) bool {
switch target {
case oserror.ErrPermission:
return e == EACCES
My first reaction is, do you *really* want to call a Go DLL from a Go main
program? It seems to me like you will have two active copies of the Go
runtime with their own garbage collectors etc.
Go "plugins" might be closer to what you need:
https://medium.com/learning-the-go-programming-language/
Oh, hang on, please ignore my last message. It's that was because the
*caller* was defined that way - it's NOT a Go thing. Oops, my bad.
Peter
On Thursday, 29 September 2022 at 10:33:23 UTC+1 Peter Galbavy wrote:
> On Linux at least - I have not tried building or using a Windows DLL, you
> hav
On Linux at least - I have not tried building or using a Windows DLL, you
have to accept C-style args and process them in the exported function
signature:
e.g.
//export SendMail
func SendMail(n C.int, args **C.char) C.int {
conf := parseArgs(n, args)
...
Here my parseArgs() func loops over
Hi Everyone,
I'm trying to create go DLL for the below program using "go build
-buildmode=c-shared -o calc.so calc.go"
*package mainimport "C"func main() {}//export SayHellofunc SayHello(name
string) {fmt.Printf("Go says: Hello, %s!\n", name)}//export Addfunc
Add(num0, num1 int) int
16 matches
Mail list logo