Skip to content

Command-line options should override !% headers #279

@erkyrath

Description

@erkyrath

Currently the compiler parses command-line options in order (including ICL files mentioned on the command line); then it opens the source file and parses !% headers; then it reopens the source file and compiles it.

This means that !% headers override command-line options. This is not intuitive. Normal procedure is that options ("easy to change") override options baked in a file ("hard to change").

Changing this will be a moderate pain though. Either we have to hold command-line options until a later stage of compilation, or keep track of the priority level of each set option.

On the up side, maybe we can systematize the big swaths of boilerplate option code in memory.c.

(Proposed as an alternative to #275 .)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions