chicken-janitors
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-janitors] #1368: Command line options for adding directorie


From: Chicken Trac
Subject: Re: [Chicken-janitors] #1368: Command line options for adding directories to include-path should prepend, not append
Date: Fri, 27 Oct 2017 18:55:48 -0000

#1368: Command line options for adding directories to include-path should 
prepend,
not append
-----------------------------------+--------------------
            Reporter:  felix       |      Owner:
                Type:  defect      |     Status:  new
            Priority:  major       |  Milestone:  5.0
           Component:  core tools  |    Version:  4.12.0
          Resolution:              |   Keywords:
Estimated difficulty:  easy        |
-----------------------------------+--------------------

Comment (by sjamaan):

 Replying to [comment:7 felix]:
 > Replying to [comment:6 sjamaan]:
 > > Or could this have something to do with the fact that the CSC_OPTIONS
 and CSI_OPTIONS environment variables are appended at the end, even after
 the initial value of {{{##sys#include-pathnames}}} (which is the result of
 {{{(list (chicken-home))}}})?
 >
 > But what would be the "right" behaviour? Currently the options from the
 env vars are prepended in csc.scm.

 I'd expect explicitly supplied options on the command line to supersede
 options given in the environment, so I suppose prepending the options is
 correct.  However, currently -I will be processed in order which means
 earlier options are searched first, so any {{{-I}}} in the
 {{{CSC_OPTIONS}}} will supersede any {{{-I}}} on the command line.

 I don't know if there's a "correct" solution for this problem.  Reversing
 the include-path seems weird too, because something like {{{csc -I /foo -I
 /bar}}} would then cause the compiler to search {{{/bar}}} before
 {{{/foo}}}, which is definitely not what one would expect.

 All in all, I think the current situation is probably fine as it is. So
 maybe this should just be closed "works for me" and wait until someone
 comes up with a clearer example of what's wrong with the current
 situation?

--
Ticket URL: <https://bugs.call-cc.org/ticket/1368#comment:8>
CHICKEN Scheme <https://www.call-cc.org/>
CHICKEN Scheme is a compiler for the Scheme programming language.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]