Fixes a bug where the source name would be unknown because it got declared too late.