func panic_if_version_older_auto(major, minor, micro int) { if C._check_version(C.int(major), C.int(minor), C.int(micro)) != 0 { return } formatStr := "%s is not provided on your Glib, version %d.%d is required\n" if pc, _, _, ok := runtime.Caller(1); ok { log.Panicf(formatStr, runtime.FuncForPC(pc).Name(), major, minor) } else { log.Panicf("Glib version %d.%d is required (unknown caller, see stack)\n", major, minor) } }
func deprecated_since(major int, minor int, micro int, function string) { if C._check_version(C.int(major), C.int(minor), C.int(micro)) != 0 { log.Printf("\nWarning: %s is deprecated since glib %d.%d\n", function, major, minor) } }
func panic_if_version_older(major int, minor int, micro int, function string) { if C._check_version(C.int(major), C.int(minor), C.int(micro)) == 0 { log.Panicf("%s is not provided on your Glib, version %d.%d is required\n", function, major, minor) } }