diff --git includes/theme.inc includes/theme.inc
index 50a2f11..a058fee 100644
--- includes/theme.inc
+++ includes/theme.inc
@@ -469,6 +469,7 @@ function _theme_process_registry(&$cache, $name, $type, $theme, $path) {
           }
           if (function_exists($name . '_' . $phase . '_' . $hook)) {
             $cache[$hook][$phase_key][] = $name . '_' . $phase . '_' . $hook;
+            $cache[$hook]['theme path'] = $path;
           }
           // Ensure uniqueness.
           $cache[$hook][$phase_key] = array_unique($cache[$hook][$phase_key]);
