Files
sex/tests/modules/cycle/a.sex
alex-eg ca4ac949d8 count a unit among its own imports
Two modules importing each other with pub hand the unit its own
interface back, and its types were defined twice.
2026-10-19 21:56:28 +03:00

9 lines
302 B
Scheme

;;; Each imports the other with pub, so either one compiled pastes the
;;; other's interface, which imports it back. b holds an ra by value, so
;;; ra is defined before b is imported, as C needs it in one unit
(pub record ra ((x int)))
(pub import b)
(pub fn make-ra ((x int)) ra (return #(ra : x)))