[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
#1806: Finding missing dependencies
From: |
Chicken Trac |
Subject: |
#1806: Finding missing dependencies |
Date: |
Wed, 29 Jun 2022 06:57:14 -0000 |
#1806: Finding missing dependencies
---------------------------------------+-------------------------
Reporter: Idiomdrottning | Type: enhancement
Status: new | Priority: minor
Milestone: someday | Component: compiler
Version: 5.3.0 | Keywords:
Estimated difficulty: |
---------------------------------------+-------------------------
So I forgot to add a dependency (brev-separate) and csc didn't find it,
which is fair enough, it's on me.
But Teiresias pointed out that if I had jammed it into a module, csc
would've found it:
{{{
Part of the magic of csc flagging errors for you lies in modules. The
following would also have caught the missing dep when compiled by csc:
;; © 2022 Idiomdrottning, BSD 1-Clause License
(module main ()
(import fmt fmt-c tree)
(fmt #t
(c-expr
(tree-map
(fn
(case x ((fun) '%fun) ((var) '%var)
((pointer) '%pointer) ((array) '%array)
((cast) '%cast) (else x)))
(read))))
)
So probably best to (module) everything as a matter of course.
}}}
(As in, he only added the (module main () …) wrapper and that made csc
able to find the missing deps.)
Sure. Only problem with that is that I don't wanna. Can't CSC apply the
same magic even when there's no explicit module? Implicit is better than
explicit.
--
Ticket URL: <https://bugs.call-cc.org/ticket/1806>
CHICKEN Scheme <https://www.call-cc.org/>
CHICKEN Scheme is a compiler for the Scheme programming language.
- #1806: Finding missing dependencies,
Chicken Trac <=