Correctly handle strings ending in backslash in debug mode