Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How should output be done ideally? #836

Open
actuday6418 opened this issue Sep 28, 2024 · 1 comment
Open

How should output be done ideally? #836

actuday6418 opened this issue Sep 28, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@actuday6418
Copy link

I see in the examples that the println! macro is used directly for output, but using this or even print! flushes stdout before printing the next prompt, and this doesn't look pleasant.

a

In the GIF, you can see the cursor move to the next line after printing from println! and then go down again after printing the next prompt.
(Open GIF in a new tab if it isn't clear)

I think we should have an API for printing command outputs so there's no flush before the next prompt is printed. Maybe we could also have an output "prompt", which popular REPLs like ipython doo.
2024-09-28-171502_screenshot

@actuday6418 actuday6418 added the enhancement New feature or request label Sep 28, 2024
@actuday6418
Copy link
Author

actuday6418 commented Sep 29, 2024

We'll need APIs for both buffered and unbuffered output.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant