basic macro functions implemented