swapped funcContext and pkgContext