AREF command

I've read over some of the material on the forum on using the analog reference pin, which is all AVR calls. How about setting this up into a function or two in the core? It's already set up somewhere to use the 5V internal reference so a function could default to that, then I think there's a 2.5 something internal voltage reference and a user reference voltage - presumably this just disconnects the internal refs - the pin is always fairly high Z, I think I remember.

I'll be happy to write up the docs on a function - I was thinking about trying to codify what is there now, by puzzling through some of the AVR calls but then some other projects started calling me louder.

I'd also like to put in my preference for putting more things in core as opposed to libraries, if the code is simple, and memory allocation modest. Since the latest revisions only link function calls that are used anyway, a lot of potential functionality could be put into core, at the cost of nothing more than a few bytes of memory. Am I missing some fine points on this?