document sv_gets() internals