Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Glasgow Haskell Compiler
GHC
Commits
897c7a62
Commit
897c7a62
authored
Jan 19, 2008
by
Ian Lynagh
Browse files
Add a test for :main and :run
parent
1351580c
Changes
3
Hide whitespace changes
Inline
Side-by-side
testsuite/tests/ghc-regress/ghci/scripts/all.T
View file @
897c7a62
...
...
@@ -39,6 +39,7 @@ test('ghci026', normal, ghci_script, ['ghci026.script'])
test
('
ghci027
',
normal
,
ghci_script
,
['
ghci027.script
'])
test
('
ghci028
',
normal
,
ghci_script
,
['
ghci028.script
'])
test
('
ghci029
',
normal
,
ghci_script
,
['
ghci029.script
'])
test
('
1914
',
if_compiler_ge
('
ghc
',
'
6.9
',
expect_broken
(
2034
)),
ghci_script
,
['
1914.script
'])
...
...
testsuite/tests/ghc-regress/ghci/scripts/ghci029.script
0 → 100644
View file @
897c7a62
-- :main and :run
let main = System.Environment.getArgs >>= print
:main foo bar
:main foo "bar baz"
:main ["foo", "bar baz"]
let foo = putStrLn "foo" >> System.Environment.getArgs >>= print
let bar = putStrLn "bar" >> System.Environment.getArgs >>= print
:set -main-is foo
:main foo "bar baz"
:run bar ["foo", "bar baz"]
testsuite/tests/ghc-regress/ghci/scripts/ghci029.stdout
0 → 100644
View file @
897c7a62
["foo","bar"]
["foo","bar baz"]
["foo","bar baz"]
foo
["foo","bar baz"]
bar
["foo","bar baz"]
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment