robert-strandh / SICL

A fresh implementation of Common Lisp
Other
1.07k stars 79 forks source link

Fix local function inlining (hopefully) #59

Closed Bike closed 7 years ago

Bike commented 7 years ago

In the event that a local function marked for inlining refers to ASTs not in the function body, such as a block or go tag, those ASTs should be referred to directly instead of being cloned. This patch should accomplish that.

Example compile failure before this patch: (block nil (flet ((foo () (return nil))) (declare (inline foo)) (foo)))

This fixes some things, but I'm not totally confident that it fully fixes the problem and doesn't add issues elsewhere, because the issue arose in Clasp loading PPCRE (drmeister/clasp#319). This patch lets PPCRE load, but it still doesn't work, and I don't know if that problem is related.