Moved to new error-checking macro and fixed conversion warnings
Fixed test warnings on x86