This could also do with some tests for the other extrapolation modes - as shown by the problems in the "nan" code path.