Skip to content

Instantly share code, notes, and snippets.

@eccstartup
Created September 3, 2013 02:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save eccstartup/6419021 to your computer and use it in GitHub Desktop.
Save eccstartup/6419021 to your computer and use it in GitHub Desktop.
--code
```
main = do
putStrLn "Type something:"
l <- getLine
putStrLn $ "You typed:" ++ l
main
```
------
--compile-log
```
ajhc hello.hs
ajhc 0.8.0.8 (a1265f031e6b75f9346ec23ca7caec0b5ced82bc)
Finding Dependencies...
Using Ho Cache: '/Users/eccstartup/.ajhc/cache'
Main [hello.hs]
Typechecking...
[1 of 1] Main (.............................................)
Compiling...
[1 of 1] Main <.............************.........................>
Collected Compilation...
-- TypeAnalyzeMethods
-- BoxifyProgram
-- Boxy WorkWrap
-- LambdaLift
Converting to Grin...
Updatable CAFS: 0
Constant CAFS: 0
Recursive CAFS: 0
-- Speculative Execution Optimization
-- Node Usage Analysis
-- Grin Devolution
Writing "/var/folders/3r/5c02fv4j15l0khx6qllnx4dc0000gn/T/jhc_5838/main_code.c"
Running: gcc /var/folders/3r/5c02fv4j15l0khx6qllnx4dc0000gn/T/jhc_5838/rts/profile.c /var/folders/3r/5c02fv4j15l0khx6qllnx4dc0000gn/T/jhc_5838/rts/rts_support.c /var/folders/3r/5c02fv4j15l0khx6qllnx4dc0000gn/T/jhc_5838/rts/gc_none.c /var/folders/3r/5c02fv4j15l0khx6qllnx4dc0000gn/T/jhc_5838/rts/jhc_rts.c /var/folders/3r/5c02fv4j15l0khx6qllnx4dc0000gn/T/jhc_5838/lib/lib_cbits.c /var/folders/3r/5c02fv4j15l0khx6qllnx4dc0000gn/T/jhc_5838/rts/gc_jgc.c /var/folders/3r/5c02fv4j15l0khx6qllnx4dc0000gn/T/jhc_5838/rts/stableptr.c /var/folders/3r/5c02fv4j15l0khx6qllnx4dc0000gn/T/jhc_5838/rts/conc.c -I/var/folders/3r/5c02fv4j15l0khx6qllnx4dc0000gn/T/jhc_5838/cbits -I/var/folders/3r/5c02fv4j15l0khx6qllnx4dc0000gn/T/jhc_5838 /var/folders/3r/5c02fv4j15l0khx6qllnx4dc0000gn/T/jhc_5838/main_code.c -o hs.out '-std=gnu99' -D_GNU_SOURCE '-falign-functions=4' -ffast-math -Wextra -Wall -Wno-unused-parameter -fno-strict-aliasing -DNDEBUG -O3 '-D_JHC_GC=_JHC_GC_JGC' '-D_JHC_CONC=_JHC_CONC_NONE'
/var/folders/3r/5c02fv4j15l0khx6qllnx4dc0000gn/T/jhc_5838/rts/gc_jgc.c: In function ‘gc_mark_deeper’:
/var/folders/3r/5c02fv4j15l0khx6qllnx4dc0000gn/T/jhc_5838/rts/gc_jgc.c:110: warning: value computed is not used
/var/folders/3r/5c02fv4j15l0khx6qllnx4dc0000gn/T/jhc_5838/main_code.c: In function ‘fPrelude_IO_getChar’:
/var/folders/3r/5c02fv4j15l0khx6qllnx4dc0000gn/T/jhc_5838/main_code.c:181: warning: comparison between signed and unsigned
/var/folders/3r/5c02fv4j15l0khx6qllnx4dc0000gn/T/jhc_5838/main_code.c:188: warning: statement with no effect
```
-------
--runtime
```
./hs.out
Type something:
1
Segmentation fault: 11
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment