mikepb / go-serial

Go binding to libserialport for serial port functionality.
53 stars 28 forks source link

Unused parameter warnings #3

Closed tehsphinx closed 6 years ago

tehsphinx commented 8 years ago

As soon as I use this package somewhere in my code I always get these warnings. If not problematic so it is at least very annoying.

Already the go get command shows:

Apples-MacBook-Pro:src $ go get github.com/mikepb/go-serial/ # github.com/mikepb/go-serial .../github.com/mikepb/go-serial/_obj/_cgo_main.c:2:61: warning: unused parameter 'a' [-Wunused-parameter] .../github.com/mikepb/go-serial/_obj/_cgo_main.c:2:23: warning: unused parameter 'fn' [-Wunused-parameter] .../github.com/mikepb/go-serial/_obj/_cgo_main.c:2:68: warning: unused parameter 'c' [-Wunused-parameter] .../github.com/mikepb/go-serial/_obj/_cgo_main.c:2:85: warning: unused parameter 'ctxt' [-Wunused-parameter] .../github.com/mikepb/go-serial/_obj/_cgo_main.c:4:41: warning: unused parameter 'ctxt' [-Wunused-parameter] .../github.com/mikepb/go-serial/_obj/_cgo_main.c:6:26: warning: unused parameter 'a' [-Wunused-parameter] .../github.com/mikepb/go-serial/_obj/_cgo_main.c:6:33: warning: unused parameter 'c' [-Wunused-parameter] .../github.com/mikepb/go-serial/_obj/_cgo_main.c:7:23: warning: unused parameter 'a' [-Wunused-parameter] .../github.com/mikepb/go-serial/_obj/_cgo_main.c:7:30: warning: unused parameter 'c' [-Wunused-parameter]

Am I doing something wrong?

I tested it with go 1.6 and go 1.7.1: same issue.

mikepb commented 8 years ago

Sorry, I haven’t programmed in Go for a while. Please feel free to fork and update the library.

On Sep 19, 2016, at 8:22 AM, tehsphinx notifications@github.com wrote:

As soon as I use this package somewhere in my code I always get these warnings. If not problematic so it is at least very annoying.

Already the go get command shows:

`Apples-MacBook-Pro:src $ go get github.com/mikepb/go-serial/

github.com/mikepb/go-serial

.../github.com/mikepb/go-serial/_obj/_cgo_main.c:2:61: warning: unused parameter 'a' [-Wunused-parameter] .../github.com/mikepb/go-serial/_obj/_cgo_main.c:2:23: warning: unused parameter 'fn' [-Wunused-parameter] .../github.com/mikepb/go-serial/_obj/_cgo_main.c:2:68: warning: unused parameter 'c' [-Wunused-parameter] .../github.com/mikepb/go-serial/_obj/_cgo_main.c:2:85: warning: unused parameter 'ctxt' [-Wunused-parameter] .../github.com/mikepb/go-serial/_obj/_cgo_main.c:4:41: warning: unused parameter 'ctxt' [-Wunused-parameter] .../github.com/mikepb/go-serial/_obj/_cgo_main.c:6:26: warning: unused parameter 'a' [-Wunused-parameter] .../github.com/mikepb/go-serial/_obj/_cgo_main.c:6:33: warning: unused parameter 'c' [-Wunused-parameter] .../github.com/mikepb/go-serial/_obj/_cgo_main.c:7:23: warning: unused parameter 'a' [-Wunused-parameter] .../github.com/mikepb/go-serial/_obj/_cgo_main.c:7:30: warning: unused parameter 'c' [-Wunused-parameter] `

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/mikepb/go-serial/issues/3, or mute the thread https://github.com/notifications/unsubscribe-auth/AAm4b1UJSYr1aFesIe1t7QnC67KWfM5Vks5qrqi3gaJpZM4KAneM.

tehsphinx commented 6 years ago

I will close this. Have moved on to another serial package since.