Skip to content

Make prompt more useful on Windows - #132

Open
anchpop wants to merge 1 commit into
granule-project:mainfrom
anchpop:master
Open

Make prompt more useful on Windows#132
anchpop wants to merge 1 commit into
granule-project:mainfrom
anchpop:master

Conversation

@anchpop

@anchpop anchpop commented Sep 4, 2019

Copy link
Copy Markdown

No description provided.

@dorchard

dorchard commented Sep 4, 2019

Copy link
Copy Markdown
Member

Thanks very much. Could you perhaps provide a little bit more explanation about this? i.e., what is happening and the moment and what would make it more useful? I will try to get things going on a Windows machine at some point, but I don't have full access to one usually.

@anchpop

anchpop commented Sep 5, 2019

Copy link
Copy Markdown
Author

Oh, sorry. I made the pr during class and forgot to leave a description. The issue is that (when reading from stdin) the advice given says to "confirm input with enter+ctrl-d", but when running on windows the correct advice is actually to use enter+ctrl-z. I was considering checking what os the user was running on to give the correct advice but I thought giving the compiler input from stdin was probably a rare enough occurrence that it wasn't worth complicating the module for such a small change.

@dorchard
dorchard changed the base branch from master to dev-minor November 1, 2019 13:18
@dorchard

dorchard commented Nov 1, 2019

Copy link
Copy Markdown
Member

Sorry I didn't realise this wasn't merged, but actually the compiler has moved to a new project:
https://github.com/granule-project/granule-compiler-llvm/commits/master
Is there any chance you could make the change there.
That said, this problem also affects the interpreter in file interpreter/src/Language/Granule/Interpreter.hs which has a similar message which should be updated I think. So I think we should update that as well.

Now, all in all, I am starting to wonder how much we need this feature of reading from stdin. What do you think @buggymcbugfix ?

@buggymcbugfix

buggymcbugfix commented Nov 3, 2019

Copy link
Copy Markdown
Member

We can take input from stdin because this allows us to pipe input from other programs, e.g.

echo "data Foo = Bar" | gr

I think I did this to allow for preprocessors, etc. but I don't think we're actively using this feature at the moment. Still nice to have imo.

@dorchard
dorchard requested a review from buggymcbugfix March 10, 2023 08:41
@buggymcbugfix
buggymcbugfix changed the base branch from dev-minor to main May 3, 2024 08:06
@dorchard

Copy link
Copy Markdown
Member

We provide this behaviour via --interactive so we decided to remove the default stdin input.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants