Add a couple of extra casts to avoid having to add #include