Add support of global and local macros