Skywind wrote:
> What about provide an option "nl" in ch_read to make it better ?
>
> :call ch_read(mych, {"timeout": 0, "nl":1})
>
> returns "abc\n" for a line "abc"
> returns "\n" for an empty line
> returns "" for not enough data
>
> This will not break the plugins, and will make ch_read better.
> It could be used in a timer for congestion control manually.
That changes what you get back, that is a bit strange.
How about adding a function that returns whether there is something to
read? Could call it ch_canread().
--
The real
trick is
this: to
keep the
lines as
short as
possible
and keep
the size
the same
yet free
from the
need for
hyphena-
Dammit!! (Matthew Winn)
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.