add debug for swift