added die macro, calls exit after output