Fix String.replace/4 typespec

Signed-off-by: Eric Meadows-Jönsson <eric.meadows.jonsson@gmail.com>