(PUP-3635) Add scanf function

This adds a scanf function that is useful when converting from a string
to other data types.

This function is available when the future parser is in use.

Note that the documentation system cannot yet pick up the documentation from a 4x function and it is therefore documented in a function stub for 3x (that fails when called).