A compiler hook on string initialization, eh?
I have a distantly related story--this isn't important, just another random Python use case for the file. (The i"xyzzy" proposal wouldn't help this case.)
In scons, your SConscripts (makefiles, essentially) are Python source code. You typically have SConscripts throughout your source tree. Any SConscript could have something like this:
sort_exe = Program('sort', ['main.c', 'timsort.c'])
The problem is dealing with relative filenames. The only sane way to resolve "main.c" to an abspath is relative to the source file that physically contains that string literal token. But that's impossible to determine at run time.
scons uses some cleverness to guess the directory. It's always right, except when it's wrong. Maddening.
So, what does this have to do with string initialization hooks? If scons could "decorate" string constants as part of SConscript compilation/execution, this problem could actually be solved.
 Well, this is my opinion, but it's the right one.