github.com/MangoDowner/go-gm@v0.0.0-20180818020936-8baa2bd4408c/misc/cgo/test/issue5740.go (about) 1 // Copyright 2013 The Go Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style 3 // license that can be found in the LICENSE file. 4 5 package cgotest 6 7 // int test5740a(void), test5740b(void); 8 import "C" 9 import "testing" 10 11 func test5740(t *testing.T) { 12 if v := C.test5740a() + C.test5740b(); v != 5 { 13 t.Errorf("expected 5, got %v", v) 14 } 15 }