improved macros