3 ms·
The papers I read would keep a running tally of the types of the variables and if they were all the same could optimize and/or specialize the called functions.
by UncleEntity 4y ago
The papers I read would keep a running tally of the types of the variables and if they were all the same could optimize and/or specialize the called functions. If not they would just fall back to checking the types before performing whatever operations.
Basically the theory behind the Futamura projections.
I’m sure you could write some code which could keep an abstract interpreter or however type checking is implemented busy forever especially with a dynamic language with eval but, you know, you get what you pay for.
Or I’m completely wrong since I just read about this stuff for fun…