Opened 8 years ago

Last modified 14 months ago

#1354 new task

Clean up the expander a bit

Reported by: sjamaan Owned by: sjamaan
Priority: minor Milestone: 6.0.0
Component: expander Version: 5.0.0
Keywords: expander Cc:
Estimated difficulty: hard

Description

Currently the expander is full of hooks and hacks, mostly for maintaining the line number database and various syntactic environments. It would be nice if we can clean things up a bit. A few ideas:

  • ##sys#syntax-context and ##sys#syntax-error/context are weird and can maybe be cleaned up if we can make ##sys#check-syntax work better with line number info.
  • ##sys#syntax-error-culprit seems to be unnecessary, because while expanding ##sys#check-syntax should have access to the input form already?
  • ##sys#line-number-database is defined in expander, but only really used in core.scm (except for getting the line number)
  • The new expansion-result-hook is yet another hook, and can perhaps be combined with the previous two.
  • The special-cased hack in ##sys#canonicalize-body that prevents expansion of import and hands back control to the compiler after expansion of ##core#module) (in a currently pending patch) needs to die. No clue yet how to do this...

Change History (4)

comment:1 Changed 6 years ago by sjamaan

Milestone: 5.15.2

Getting ready for 5.1, moving tickets which won't make it in to 5.2.

comment:2 Changed 5 years ago by felix winkelmann

Milestone: 5.25.3

comment:3 Changed 4 years ago by sjamaan

Milestone: 5.35.4

comment:4 Changed 14 months ago by felix winkelmann

Milestone: 5.46.0.0
Note: See TracTickets for help on using tickets.