two-values.scm added by gahr on Wed May 29 09:19:07 2024

(import (scheme) (chicken foreign))

(define two-values
  (foreign-primitive ()
    "
    C_word v1 = 12;
    C_word v2 = 13;
    C_word av[4] = { C_SCHEME_UNDEFINED, C_k, v1, v2 };
    C_values(4, av);
    "))

(let-values (((v1 v2) (two-values)))
  (print "v1: " v1 ", v2: "  v2))