better defining/undefining of shims