unsafePerformIO

2002-09-20 Thread David Sabel

In read your paper ""Tackling the Awkward Squad: monadic input / output,
concurrency, exceptions, and foreign-language calls in Haskell",  and have
a question about unsafePerformIO.

In your operational semantic of the IO-Monad you tell nothing about, how
'unsafe' IO actions are performed, is there another paper / documentation
about
this available, or can you - or someone else - give me a review about that?

David
JWGU Frankfurt


___
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users



Re: unsafePerformIO

2002-09-20 Thread Hal Daume III

I'm not sure of a reference, the basic idea is this:

  IO a is represented by the pair (RealWorld, a) (unboxed, really
  but whatever)
  When an IO action is run (via main), a RealWorld state is provided
  by the compiler and passes it around.
  When you do unsafePerformIO, the compiler conjures up some
  value of type RealWorld to use.  It is unsafe because it
  doesn't guarentee the relative order of IO actions.

Of course, someone correct me if I'm mistaken.

 - Hal

--
Hal Daume III

 "Computer science is no more about computers| [EMAIL PROTECTED]
  than astronomy is about telescopes." -Dijkstra | www.isi.edu/~hdaume

On Fri, 20 Sep 2002, David Sabel wrote:

> In read your paper ""Tackling the Awkward Squad: monadic input / output,
> concurrency, exceptions, and foreign-language calls in Haskell",  and have
> a question about unsafePerformIO.
> 
> In your operational semantic of the IO-Monad you tell nothing about, how
> 'unsafe' IO actions are performed, is there another paper / documentation
> about
> this available, or can you - or someone else - give me a review about that?
> 
> David
> JWGU Frankfurt
> 
> 
> ___
> Glasgow-haskell-users mailing list
> [EMAIL PROTECTED]
> http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
> 

___
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users



Interface file for ShowFunctions not found

2002-09-20 Thread Jose Romildo Malaquias

Hello.

I am trying to using the ShowFunctions module but
ghc 5.04.1 is not being able to find its interface
file.

A Haskell program to test (t.hs):

--
module Main where

import ShowFunctions

main = print length
--

$ ghc -c t.hs

t.hs:3:
failed to load interface for `ShowFunctions':
Could not find interface file for `ShowFunctions'

$ find /usr/lib/ghc-5.04.1/ -name "ShowFunctions*"
/usr/lib/ghc-5.04.1/imports/lang/ShowFunctions.hi

What am I missing?

Romildo
-- 
Prof. José Romildo Malaquias
Departamento de Computação - Universidade Federal de Ouro Preto
http://www.decom.ufop.br/prof/romildo/  [EMAIL PROTECTED]
http://uber.com.br/romildo/ [EMAIL PROTECTED]
___
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users



Re: Interface file for ShowFunctions not found

2002-09-20 Thread Hal Daume III

Hi

> I am trying to using the ShowFunctions module but
> ghc 5.04.1 is not being able to find its interface
> file.
> $ ghc -c t.hs

Try '-package lang'

___
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users