The code below should all consider using `mb_` functions.