Inline three small functions of less generality than expected.