GHC does not eforce that Main exports main
The Haskell 98 report says "A Haskell program is a
collection of
modules, one of which, by convention, must be called
Main and must
export the value main." However, the program below
builds and executes
fine.
module Main() -- should be "module Main" or "module
Main(main)"
where
main = putStrLn "Hello, World"
$ runghc Main.hs
Hello, World
Originally reported by Brian Smith
[brianlsmith@gmail.com]
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
- Show closed items
No child items are currently assigned. Use child items to break down this issue into smaller parts.
Relates to
Activity
-
Newest first Oldest first
-
Show all activity Show comments only Show history only
- Simon Peyton Jones changed weight to 0
changed weight to 0
- Simon Peyton Jones added Tbug Trac import labels
added Tbug Trac import labels
- Simon Marlow changed the description
changed the description
- Developer
Trac metadata
Trac field Value Version None → 6.4.1 - Ben Gamari mentioned in commit 5a54c38e
mentioned in commit 5a54c38e
Trac metadata
Trac field Value Test case - → mod174 - Ben Gamari mentioned in commit 49ca979d
mentioned in commit 49ca979d
- Simon Marlow unassigned @trac-nobody
unassigned @trac-nobody
- Developer
Trac metadata
Trac field Value Operating system → Unknown Architecture → Unknown - Developer
Trac metadata
Trac field Value Architecture Unknown → Unknown/Multiple - Developer
Trac metadata
Trac field Value Operating system Unknown → Unknown/Multiple Verified it's still a problem in 6.10.4.
Trac metadata
Trac field Value Version 6.4.1 → 6.10.4 TypeOfFailure - → OtherFailure - Simon Marlow mentioned in commit 46c673a7
mentioned in commit 46c673a7
- Simon Marlow assigned to @simonmar
assigned to @simonmar
- Simon Marlow mentioned in commit 80294406
mentioned in commit 80294406
- Simon Marlow changed milestone to %6.12.2
changed milestone to %6.12.2
- Simon Marlow assigned to @trac-igloo and unassigned @simonmar
assigned to @trac-igloo and unassigned @simonmar
- Developer
Fixed
Mon Nov 30 11:23:27 GMT 2009 Simon Marlow <marlowsd@gmail.com> * Check whether the main function is actually exported (#414)
Trac metadata
Trac field Value Type Bug → MergeReq - Simon Marlow added backport label and removed Tbug label
Mon Nov 30 04:04:04 PST 2009 Simon Marlow <marlowsd@gmail.com> * add a test for #414
- Ian Lynagh <igloo@earth.li> closed
closed
Both merged
Trac metadata
Trac field Value Resolution ResolvedNoReason → ResolvedFixed - Thomas Miedema mentioned in issue #7765 (closed)
mentioned in issue #7765 (closed)
Trac metadata
Trac field Value Test case mod174 → module/T414 - Thomas Miedema mentioned in commit 0fa20726
mentioned in commit 0fa20726
- Andrey Mokhov mentioned in commit f479c5d5
mentioned in commit f479c5d5
- Andrey Mokhov mentioned in commit f846945c
mentioned in commit f846945c
- Andrey Mokhov mentioned in commit e25bb01f
mentioned in commit e25bb01f
- Andrey Mokhov mentioned in commit f6a491d1
mentioned in commit f6a491d1
- trac-import added Tbug label
added Tbug label
- Ben Gamari added Plow label
added Plow label
- Roland Senn mentioned in merge request !2889 (closed)
mentioned in merge request !2889 (closed)
Please register or sign in to reply