microo8 / plgo

easily create postgresql extensions in golang; moved to gitlab.com/microo8/plgo
292 stars 23 forks source link

invalid operation #19

Closed Albus closed 5 years ago

Albus commented 5 years ago

command-line-arguments

/tmp/plgo197184652/pl.go: In function ‘jsonb_to_datum’: /tmp/plgo197184652/pl.go:148:17: warning: implicit declaration of function ‘DatumGetJsonb’; did you mean ‘DatumGetJsonbP’? [-Wimplicit-function-declaration] return (Datum) DatumGetJsonb(DirectFunctionCall1(jsonb_in, (Datum) (char ) val)); ^~~~~ DatumGetJsonbP /tmp/plgo197184652/pl.go: In function ‘datum_to_jsonb_cstring’: /tmp/plgo197184652/pl.go:226:17: warning: initialization of ‘Jsonb ’ {aka ‘struct ’} from ‘int’ makes pointer from integer without a cast [-Wint-conversion] Jsonb jsonb = DatumGetJsonb(val); ^~~~~

command-line-arguments

/tmp/plgo197184652/pl.go:347:171: cannot convert _Ciconst_true (type untyped number) to type _CtypeBool /tmp/plgo197184652/pl.go:347:171: invalid operation: (func literal)() == _Ciconst_true (mismatched types _Ctype__Bool and int) /tmp/plgo197184652/pl.go:400:51: cannot convert _Ciconst_true (type untyped number) to type _CtypeBool /tmp/plgo197184652/pl.go:400:51: invalid operation: _Cfunc_trigger_fired_before(td.tgEvent) == _Ciconst_true (mismatched types _CtypeBool and int) /tmp/plgo197184652/pl.go:405:50: cannot convert _Ciconst_true (type untyped number) to type _Ctype__Bool /tmp/plgo197184652/pl.go:405:50: invalid operation: _Cfunc_trigger_fired_after(td.tgEvent) == _Ciconst_true (mismatched types _CtypeBool and int) /tmp/plgo197184652/pl.go:410:52: cannot convert _Ciconst_true (type untyped number) to type _CtypeBool /tmp/plgo197184652/pl.go:410:52: invalid operation: _Cfunc_trigger_fired_instead(td.tgEvent) == _Ciconst_true (mismatched types _Ctype__Bool and int) /tmp/plgo197184652/pl.go:415:52: cannot convert _Ciconst_true (type untyped number) to type _CtypeBool /tmp/plgo197184652/pl.go:415:52: invalid operation: _Cfunc_trigger_fired_for_row(td.tgEvent) == _Ciconst_true (mismatched types _Ctype__Bool and int) /tmp/plgo197184652/pl.go:415:52: too many errors Cannot build package: exit status 2

microo8 commented 5 years ago

Solved. Try updating plgo (go get -u github.com/microo8/plgo/...)