This is because of how the REPL decides whether to output the result of
a function or not.

When something outputs stuff on stdout (like say does), it'll notice
that and suppress the return value printing.

note, however, outputs on stderr, which the REPL doesn't inspect for output.

I think this behaviour is all right, because you may get warnings or
things like that but still want the return value of your code, whereas
if you do some output in your code, you'll probably be getting what you
want from the output and not need the return value of the whole
statement on top of that.

I'd close this as "not a bug".

Reply via email to