Silence warnings in 5.18

This is not using anything remotely dangerous in given/when, so the
warnings are unhelpful at best.