The Closure Compiler parsers `goog.require` and `goog.provide` with simple regular expressions. They are not executed as JavaScript expressions (except when running in RAW mode). Therefore, it's hard to be clever with `goog.provide`.