(define-foreign-enum-type (exceptiontype int) (exceptiontype->int int->exceptiontype) ((UndefinedException) UndefinedException) ((WarningException) WarningException) ((ResourceLimitWarning) ResourceLimitWarning) ;; ... ellided ((ConfigureFatalError) ConfigureFatalError) ((PolicyFatalError) PolicyFatalError)) (define magick-get-exception (foreign-lambda c-string MagickGetException (const magickwand) (c-pointer exceptiontype))) ;; compiler output: magickwand.c: In function ‘stub420’: magickwand.c:122:1: warning: passing argument 2 of ‘MagickGetException’ from incompatible pointer type [enabled by default] /usr/include/ImageMagick/wand/MagickWand.h:148:4: note: expected ‘enum ExceptionType *’ but argument is of type ‘int *’ /usr/bin/csc -feature compiling-extension -setup-mode -k -c -O3 -d1 -lMagickWand -C `pkg-config --cflags MagickWand` -L `pkg-config -- libs MagickWand` magickwand.scm -unit magickwand magickwand.c: In function ‘stub420’: magickwand.c:122:1: warning: passing argument 2 of ‘MagickGetException’ from incompatible pointer type [enabled by default] /usr/include/ImageMagick/wand/MagickWand.h:148:4: note: expected ‘enum ExceptionType *’ but argument is of type ‘int *’ /usr/bin/csc -feature compiling-extension -setup-mode -k -s -O3 -d0 magickwand.import.scm -C `pkg-config --cflags MagickWand` -L `pkg- config --libs MagickWand`