The package! family of macros will throw an error if used in the wrong files. This same check would prevent macroexpand from expanding them, or prevent them from being evaluated inline.