comparison tests/test-rename-dir-merge.t @ 25937:4f1144c3c72b

demandimport: support lazy loading for absolute_import Before, we didn't support lazy loading if absolute_import was in effect and a fromlist was used. This meant that "from . import X" wasn't lazy and performance could suffer as a result. With this patch, we now support lazy loading for this scenario. As part of developing this, I discovered issues when module names are defined. Since the enforced import style only allows "from X import Y" or "from .X import Y" in very few scenarios when absolute_import is enabled - scenarios where Y is not a module and thus there is nothing to lazy load - I decided to drop support for this case instead of chasing down the errors. I don't think much harm will come from this. But I'd like to take another look once all modules are using absolute_import and I can see the full extent of what is using names in absolute_import mode.
author Gregory Szorc <gregory.szorc@gmail.com>
date Sat, 08 Aug 2015 16:13:27 -0700
parents bd625cd4e5e7
children ef1eb6df7071
comparison
equal deleted inserted replaced
25936:f90bb2002bcf 25937:4f1144c3c72b