RE: newtype of newtype

2004-03-17 Thread Simon Peyton-Jones
Now fixed properly in the head (and 6.2)

| -Original Message-
| From: [EMAIL PROTECTED]
[mailto:glasgow-haskell-bugs-
| [EMAIL PROTECTED] On Behalf Of Ross Paterson
| Sent: 15 March 2004 17:27
| To: [EMAIL PROTECTED]
| Subject: newtype of newtype
| 
| The following little module:
| 
|   module Bug where
| 
|   newtype Foo = Foo [Foo]
|   newtype Bar = Bar Foo
| 
|   unBar :: Bar - Foo
|   unBar (Bar x) = x
| 
| fails core-lint in both 6.2 and the HEAD:
| 
| *** Core Lint Errors: in result of Desugar ***
| Bug.hs:7:
| [RHS of x :: Bug.Foo]
| The type of this binder doesn't match the type of its RHS: x
| Binder's type: Bug.Foo
| Rhs type: Bug.Bar
| *** Offending Program ***
| Rec {
| unBar :: Bug.Bar - Bug.Foo
| unBar = \ ds_dch :: Bug.Bar -
|   let {
| x :: Bug.Foo
| x = ds_dch
|   } in  x
| Bug.unBar :: Bug.Bar - Bug.Foo
| Bug.unBar = unBar
| end Rec }
| 
| *** End of Offense ***
| ___
| Glasgow-haskell-bugs mailing list
| [EMAIL PROTECTED]
| http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs
___
Glasgow-haskell-bugs mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs


Stack space overflow after optimization

2004-03-17 Thread Christian Maeder
Hi,

my program throws

Stack space overflow: current size 1048576 bytes.
Use `+RTS -Ksize' to increase it.
only when translated with -O. Is it possible that the next release of 
ghc uses a higher stack size at least when the -O flag is set? (Only 
to reduce the likelyhood that our users need to supply RTS flags.)

Maybe it is even possible to add a ghc flag that allows to set the 
default Ksize of the generated programs.

Someone told me to link in an additional header file, but maybe you can 
supply a more convienent solution.

Christian

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


RE: Release Candidate for 6.2.1 available

2004-03-17 Thread Simon Marlow
Thanks to Sigbjorn, our long-suffering Windows installer guru, there is
a new Windows installer release candidate for 6.2.1 is here:

http://www.haskell.org/ghc/dist/stable/dist/ghc-6-2-1.msi

Please test.  We'd especially like to hear from Win98/WinME users.  Also
try installing under a directory path with spaces in if you can.

Cheers,
Simon

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED] On Behalf 
 Of Sigbjorn Finne
 Sent: 12 March 2004 02:32
 To: GHC users
 Subject: Re: Release Candidate for 6.2.1 available
 
 An installer for Windows users can now also be found in
 that directory.
 
 --sigbjorn
 
 - Original Message - 
 From: Simon Marlow [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Thursday, March 11, 2004 04:43
 Subject: RE: Release Candidate for 6.2.1 available
 
 
  
  ghc-6.2.20040304 and later are release candidates for 6.2.1
   
   Get them from here:
   
 http://www.haskell.org/ghc/dist/stable/dist/
  
  This is your last chance to test...  I'm going to freeze 
 the release on
  Monday (15 March).
  
  Cheers,
  Simon
 
 ___
 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


Re: Stack space overflow after optimization

2004-03-17 Thread Ketil Malde
Christian Maeder [EMAIL PROTECTED] writes:

 Stack space overflow: current size 1048576 bytes.
 Use `+RTS -Ksize' to increase it.
 
 only when translated with -O. Is it possible that the next release
 of ghc uses a higher stack size at least when the -O flag is set? 
 (Only to reduce the likelyhood that our users need to supply RTS
 flags.)

Also, profiling seems to increase stack usage.  Perhaps the 1M limit
is overly conservative?

 Maybe it is even possible to add a ghc flag that allows to set the
 default Ksize of the generated programs.

 Someone told me to link in an additional header file, but maybe you
 can supply a more convienent solution.

It's fairly simple; you just need to define the approprate constant in
a C file, compile and link it with your program proper.

-kzm
-- 
If I haven't seen further, it is by standing in the footprints of giants
___
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users


[Haskell] Announce: Takusen - an Oracle DBMS library

2004-03-17 Thread Bayley, Alistair
In keeping with recent announcements regarding database libraries,
Oleg Kiselyov and I present a library to interface to the Oracle DBMS.
This library is a low-level interface for issuing SQL commands,
similar to HSQL. It uses the Oracle Call Interface, a low-level C library
provided with most Oracle installations.

The library is currently hosted by the Haskell-libs project at SourceForge:
  http://sf.net/projects/haskell-libs

Here's a link to the CVS folders:
  http://cvs.sf.net/viewcvs.py/haskell-libs/libs/takusen/


The library is designed around a left-fold enumerator,
previously illustrated here:
  http://pobox.com/~oleg/ftp/Haskell/misc.html#fold-stream
The enumerator is the preferred interface. We also support cursors,
for those rare occasions where you may want to interleave results
from more than one query.

What distinguishes this library from HSQL/ODBC?
 - the groovy left-fold iterator
 - it works with Oracle :-)
 - it only works with Oracle :-(
 - it doesn't use any other libraries or pre-processors e.g. ODBC, hsc2hs

Other features to note:
 - The library is designed to support any DBMS, although we've
   only provided one initial implementation, for Oracle.
   The Oracle-specific code is quite separate from the general code.
   There is also a stub so you can try it without Oracle.
 - The query function is naturally polyvariadic.
   It can accept any number of arguments of the supported types.
   Type information is used to allocate data buffers and determine
   the correct conversion functions. Buffer allocation is transparent to the
user.
   See examples in Database.Test.SimpleEnumeratorTest:
 
http://cvs.sf.net/viewcvs.py/haskell-libs/libs/takusen/src/Database/Test/Sim
pleEnumeratorTest.lhs?view=markup

Deficiencies (we plan to rectify these soon, more-or-less in this order):
 - iteratee function should be monadic so you can do IO in it.
 - memory leaks exist (in the low-level OCI FFI code).
 - no performance tests (how well does it handle large result sets?).
 - no Haddock docs.
 - can't use OS-authenticated logon i.e. must provide username/password.
 - no bind variables.
 - support for multiple connections is limited.
 - limited set of Haskell/DBMS datatypes (String, Int, Double, CalendarTime)
 - doesn't support LOBs, user-defined DBMS types, and other exotic types.
 - CalendarTime support is incomplete, as Oracle doesn't store the
   Timezone with dates (this has been rectified in Oracle 9 with a
   new datatype: TIMESTAMP). We assume UTC.
 - doesn't support calling procedures, functions, or packages.
 - support for other DBMS's.

* Why didn't we implement HSQL for Oracle?
We started work on this long before we had any idea that HSQL
was being overhauled. And it took a long time.

* Do we have any plans to implement HSQL for Oracle?
Maybe... not right now. I don't think there are any major technical
impediments to writing it; I just lack time and motivation.


Stability:
Experimental. Still under active development.

Portability:
The library was developed on a Windows NT platform against Oracle 8.
As far as I know, there are no Oracle 8 specific features,
so it ought to work against an Oracle 7 DBMS without modification.
It was compiled with GHC 6.01, and uses MPTC, fundeps, overlapping
instances,
and deriving Typeable.


Alistair and Oleg.

-
*
Confidentiality Note: The information contained in this 
message, and any attachments, may contain confidential 
and/or privileged material. It is intended solely for the 
person(s) or entity to which it is addressed. Any review, 
retransmission, dissemination, or taking of any action in 
reliance upon this information by persons or entities other 
than the intended recipient(s) is prohibited. If you received
this in error, please contact the sender and delete the 
material from any computer.
*

___
Haskell mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell


Re: [Haskell] New version of the HTTP module

2004-03-17 Thread Bjorn Bringert
Graham Klyne wrote:
I'm trying to check this out with some software that uses a previous 
version (HXml toolbox), and I get the following error from Hugs:
[[
Reading file ..\http\Browser.hs:
Type checking
ERROR ..\http\Browser.hs:865 - Type error in application
*** Expression : ioAction $ openTCP hst
*** Term   : ioAction
*** Type   : IO a - BrowserAction a
*** Does not match : (Int - IO Connection) - BrowserAction a
]]

It appears that the signature for openTCP has changed...

Previous version (HTTP.hs):
[[
openTCP :: String - IO Connection
openTCP uri =
]]
-- http://homepages.paradise.net.nz/warrickg/haskell/http/HTTP.hs
Latest version (HTTP.hs):
[[
openTCP :: String - Int - IO Connection
openTCP uri port =
]]
-- http://www.dtek.chalmers.se/~d00bring/haskell-xml-rpc/HTTP.hs
But this is referenced by the copy of Browser indicated from your web page:
[[
 ; c - ioAction $ openTCP hst
]]
http://homepages.paradise.net.nz/warrickg/haskell/http/Browser.hs
I'm guessing that you also have a modified version of Browser.hs?

#g
--
At 00:16 16/03/04 +0100, Bjorn Bringert wrote:

The Haskell HTTP client implementation available from [1] seems to be 
without a maintainer (if anyone knows how to reach Warrick Gray, who 
wrote it, let me know).

I include a modified version of this module in the XML-RPC library 
[2]. Changes from the original module include:

* made it Hugs compatible
* disabled 100-continue transfers as they caused POST requests to
  HTTP/1.0 servers to stall
* called it Network.HTTP instead of HTTP
* added support for URIs with a port number
* added a simple toggle for HTTP traffic logging
The modified HTTP module is available from:

http://www.dtek.chalmers.se/~d00bring/haskell-xml-rpc/http.html

In line with Graham Klyne's suggestion [3] that a consistent version 
of this module be brought into some community space, it will 
probably move to the haskell-libs project at SourceForge in the not 
too distant future.

Yours truly,

Bjorn Bringert

[1] http://homepages.paradise.net.nz/warrickg/haskell/http/

[2] http://www.dtek.chalmers.se/~d00bring/haskell-xml-rpc/

[3] http://www.haskell.org/pipermail/libraries/2004-February/001693.html
Actually I don't have a modified version of Browser, since I have never
used that module :). Of course I should have realized that I would break
other software by adding a port argument to openTCP, but at the time I 
did that I had no idea that others would use it.

I have reverted the type of the exported openTCP to String - IO
Connection, it now always uses port 80 like the old version did. Instead 
there is an internal function openTCPPort that takes a port number. I 
will try to have a look at the Browser module to see what needs to be 
done to make it support arbitrary port numbers and if it needs any other 
updates.

An updated version of HTTP.hs is available at 
http://www.dtek.chalmers.se/~d00bring/haskell-xml-rpc/HTTP.hs

Thanks for pointing that out.

/Bjorn

___
Haskell mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell


Re: [Haskell] documentation of Language.Haskell.Syntax

2004-03-17 Thread Ross Paterson
On Wed, Mar 17, 2004 at 11:12:23AM -, José Vilaça wrote:
 I'm searching for more detailed information about
 Language.Haskell.Syntax than the one provided by the Haddock
 documentation of the  Hierarchical Libraries.

Unfortunately, that's all there is.  The docs are sparse, but the types
do correspond fairly closely to the grammar in the Haskell 98 Report.
Do ask about anything that's unclear (maybe libraries or haskell-cafe
would be a more appropriate mailing list).  In extremis, there's always
the source of Language.Haskell.Parser.
___
Haskell mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell


[Haskell] RE: Win32 process spawning, POpen and Hugs, revisited

2004-03-17 Thread Simon Marlow
 
On a related note, I recently implemented a System.Process library on
Unix.  Source code attached.  The Windows implementation should be
relatively straightforward.  Porting it to Hugs will require
System.Posix.forkProcess, but I don't see any great difficulties there.

One warning: if you want to use it in a concurrent environment with GHC,
you need to use GHC's threaded RTS (i.e. use the -threaded option in the
forthcoming GHC 6.2.1), otherwise waitForProcess will block all threads.

POpen-type abstractions can easily be layered on top of the
functionality here - indeed the library should probably contain some
higher-level versions which correspond to common usage.

I think this is a good platform-independent abstraction for process
management.  What do others think?

Cheers,
Simon


Process.hs
Description: Process.hs
___
Haskell mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell


[Haskell] COM port IO on a Windows machine?

2004-03-17 Thread Peter Pudney
I have a microcontroller connected to the COM2 port on a Windows machine, and
want my Haskell program to interact with it. My Haskell program is working
nicely on my Mac, with interaction using stdin and stdout, but I am not
familiar with Windows and a quick Google search did not give me any information
on how to get Haskell IO happening through a Windows serial port.

* How should I open the COM2 port? IO Mode? Buffering?

* How do I write and read?


I presume I can set the port parameters fusing something like:

   ...; e - system MODE COM2 19200,*,N,1,P; ...


(The application is a little interesting---we have three large large bins in a
Waste Education Centre. Kids present items such as cans, paper, garden waste
and rubbish to the bins, and characters in the bin respond. The items are
tagged with Dallas 1-wire ID buttons. A microcontroller in each bin sends a
(BinID,ItemID) pair to the PC. The Haskell program then illuminates characters
in the bins and plays an appropriate dialogue. The lights and speakers are
turned on and off by the microcontroller under the control of the Haskell
program. The dialogue is stored in WAV files, which are played by a Visual
Basic Script called from a Haskell system function.)


Peter








___
Haskell mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell


Re: [Haskell] HaXml and XML Schema

2004-03-17 Thread Frank Atanassow
On Mar 10, 2004, at 8:56 AM, [EMAIL PROTECTED] wrote:
Example (readers familiar with the problem may
skip this):
salutationDear Mr.nameRobert Smith/name./salutation
This structure is represented by the XML Schema

xsd:element name=salutation
xsd:complexType mixed=true
xsd:sequence
xsd:element name=name type=xsd:string/
/xsd:sequence
/xsd:complexType
/xsd:element
How would you represent this in Haskell?
A first idea may be to store the enclosing strings:
data Salutation = Salutation String Name String

This approach is not scaling well. E.g., there may be multiple
names in the text...
No, according to the content model, there must be exactly one 
occurrence of name in the content of salutation: not zero, and not 
more than one. To allow zero or more you need to add minOccurs and/or 
maxOccurs attributes. This is one of the ways that mixed content in XML 
Schema differs from that in DTD's, and is treated in the references 
Johan posted.

So, on the contrary, your first declaration:

  data Salutation = Salutation String Name String

is a better translation of this schema (fragment), than your second 
attempt:

  data Salutation' = Salutation' [Either Char Name]

Regards,
Frank
___
Haskell mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell


[Haskell] ghc question

2004-03-17 Thread Jurriaan Hage
Hello,

Given the fact that Haskell 98 demands that class constraints in an 
explicit type are
in a normal form (either a variable, or a type variable applied to a 
list of types), it struck me
that in the following (not very useful) program ghci yields a type 
which is not of that form.

class X a where
  () :: a - a - Bool
class Y a where
  () :: a - a - Bool
  _  _ = True
instance Y a = X [a] where
  x  y = not(head x   head y)
--f :: Y a = a - a - Bool
f g h = [g]  [h]
Now, in ghci
:t f yields f :: forall t. (X [t]) = t - t - Bool
Hugs does reduce the type of f to the explicit type in comments.

My question is: is there any special reason for this behaviour?

Jur
--
http://www.cs.uu.nl/people/jur/progrock.html -- [EMAIL PROTECTED]
If e-mail does not work try [EMAIL PROTECTED]
___
Haskell mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell


RE: [Haskell] ghc question

2004-03-17 Thread Simon Peyton-Jones
GHC does context reduction as late as possible, so that when overlapping
instances are involved the commitment is made where maximum information
is available.

Simon

| -Original Message-
| From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
On Behalf Of Jurriaan Hage
| Sent: 17 March 2004 15:35
| To: [EMAIL PROTECTED]
| Subject: [Haskell] ghc question
| 
| Hello,
| 
| Given the fact that Haskell 98 demands that class constraints in an
| explicit type are
| in a normal form (either a variable, or a type variable applied to a
| list of types), it struck me
| that in the following (not very useful) program ghci yields a type
| which is not of that form.
| 
| class X a where
|() :: a - a - Bool
| 
| class Y a where
|() :: a - a - Bool
|_  _ = True
| 
| instance Y a = X [a] where
|x  y = not(head x   head y)
| 
| --f :: Y a = a - a - Bool
| f g h = [g]  [h]
| 
| Now, in ghci
| :t f yields f :: forall t. (X [t]) = t - t - Bool
| 
| Hugs does reduce the type of f to the explicit type in comments.
| 
| My question is: is there any special reason for this behaviour?
| 
| Jur
| --
| http://www.cs.uu.nl/people/jur/progrock.html -- [EMAIL PROTECTED]
| If e-mail does not work try [EMAIL PROTECTED]
| 
| ___
| Haskell mailing list
| [EMAIL PROTECTED]
| http://www.haskell.org/mailman/listinfo/haskell
___
Haskell mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell


[Haskell] Re: DData revision /equivalence vs equality

2004-03-17 Thread Iavor S. Diatchki
hi ,
this is an interesting discussion and i agree that in general instances
of Eq should be equality, but what do people mean by real equality?
probably the most reasonable interpretation is some sort of
observational equivalance, i.e. if two things are equal we should always
be able to replace the one with the other.  for a datatype that is not 
abstract
this basically forces the equality to be structural equality, which has 
prolems:
   * if a datatype contains functions, structural equivalance is tricky
   * every now and than i think the most common test i want to do is an 
equivalance,
 and not equality (e.g. consider the implementation of join-lists)
so for datatypes that are not abstract it seems more reasonable to 
expect that
Eq will provide an equivalance relation rather than a real equality.

for abstract datatypes one can do better as the programmer could control 
what
observations are available to programmers. unfortunately, in Haskell it 
is a pain to work with those,
as we cannot use pattern matching anymore and programs become clunky.

so until we can think of better support for working with abstract 
datatypes, it seems
reasonbale to me to adopt daan's original design and have different 
datatstructures
for Bag and MultiSet (if these are commonly assumed to be the same, 
myabe they should have
some other names).

-iavor

Wolfgang Jeltsch wrote:

Am Mittwoch, 17. März 2004 13:30 schrieb Ketil Malde:
 

[...]
   

 

Furthermore, having only an equivalence implies that there is a
stronger equality below that cannot be also an instance of Eq.
 

I've already said that I think Eq's (==) should be structural
equality, which I thought meant that there shouldn't be any
deeper equality.
   

I think, the name structural equality is misleading because it seems to 
imply that equivalent values have to have the same (internal) structure.  If 
values a and b have different internal representations but are 
indistinguishable for the library user, than a == b should hold.

But I totally agree with you that == should mean equality and not anything 
different.  And this is also what The Haskell Report says in § 6.3.1: The Eq 
class provides equality (==) and inequality (/=) methods.  So a lot of the 
MultiSet/Bag and the bias discussion can be avoided.  DData can and should 
assume that the Eq methods mean exactly what they are supposed to mean: 
equality and inequality.

 

[...]
   

 

-kzm
   

Wolfgang

___
Libraries mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/libraries
 

___
Haskell mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell


Re: [Haskell] COM port IO on a Windows machine?

2004-03-17 Thread Axel Simon
On Wed, Mar 17, 2004 at 05:46:25PM +1030, Peter Pudney wrote:
 I have a microcontroller connected to the COM2 port on a Windows machine, and
 want my Haskell program to interact with it. My Haskell program is working
 nicely on my Mac, with interaction using stdin and stdout, but I am not
 familiar with Windows and a quick Google search did not give me any information
 on how to get Haskell IO happening through a Windows serial port.
 
 * How should I open the COM2 port? IO Mode? Buffering?
 
 * How do I write and read?
 
 
 I presume I can set the port parameters fusing something like:
 
...; e - system MODE COM2 19200,*,N,1,P; ...

You can also set these default parameters somewhere in the Control Panel. In 
case the openFile function is implemented under Windows by calling 
CreateFile in the Windows API, then you can just call openFile with the
name COM2:19200,8,N,1,P or simliar and use standard read and write 
functions on files.

Maybe this helps,
Axel.
___
Haskell mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell


Re: [Haskell-cafe] 2-CNF Sat algorithm/haskell code

2004-03-17 Thread Keith Wansbrough
 Dear Haskellers,
 
 Today I searched over more than an hour on the web to
 find an implementation of an algorithm that was first
 written in the 1970's that solves 2-Conjuntive Normal
 Form logical sentences in polynomial time. 

I don't recall the exact algorithm, but here are some observations:

- a 2CNF clause (x \/ y) is a pair of implications
  ( -x = y /\ -y = x).

- if there are n variables, the graph used has 2n nodes, one for each
  literal (for a variable x, there is a node x and a node -x).

- add edges for each implication arising from a clause.

- observe that for each path x = y = z = w there is an antipath
  -w = -z = -y = -x.

- observe that as long as there is no cycle containing a literal and
  its negation, the problem is solvable.

- observe that (if the problem is solvable) you can remove a terminal
  edge by asserting the terminal literal (dually, you can remove an
  initial edge by asserting the negation of the initial literal).

- so I guess you can keep going until there's nothing left; if you
  have a cycle left, then arbitrarily set or clear all its literals;
  if you can't, the problem is insoluble.

I haven't proved this, but it made sense to me when I thought about it
a couple of weeks ago.

--KW 8-)


___
Haskell-Cafe mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] infix naming

2004-03-17 Thread David Roundy
[moving to haskell-cafe due to an extreme shift in topic]

On Wed, Mar 17, 2004 at 08:55:22AM +0100, Ketil Malde wrote:
  So it is agreed: we use is :-)
 
 Hmm...
 
 s1 `isSubsetOf` s2   vs   s1 `isSubset` s2
 isSubsetOf s1 s2  isSubset s1 s2
 
 I'm not sure I have any clear preference.  ..Of reads slightly clearer
 in infix notation, but is arguably a bit more confusing in prefix. 

This seems to be a common problem:  a name that makes sense (i.e. it is
obvious what it does) in prefix notation very often is completely wrong in
infix notation, particularly when partially applied.

e `isElementOf` list makes perfect sense, while isElementOf e list
seems a bit wrong, and isElementOf e (of type [a] - Bool) reads
completely wrong.  I guess `isElementOf` list (which is of type a -
Bool) does make sense.

I guess perhaps names just have be chosen to either make sense in infix
notation, or in prefix notation, but not both?  Is this a general
principle, and if so, that seems bad, since the choice of infix vs prefix
notation seems like it shouldn't have to be made at the API level.

Does anyone know why it was originally decided to make infix notation work
as it does? To me it seems like it would make sense for (`f` x) to be the
same as (f x) rather than the opposite.  e.g. (`is_less_than` 2) and
(is_less_than 2) sound the same way when I pronounce them, and it's not
entirely pleasant that the second one is in fact the same as (= 2).  On
the other hand, if you don't think of it as (is_less_than a) b, one might
naturally think that (is_less_than a b) should be (a  b).
-- 
David Roundy
http://www.abridgegame.org
___
Haskell-Cafe mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell-cafe


RE: [Haskell-cafe] Building Haddock on Windows

2004-03-17 Thread Simon Marlow
 
 Has anyone recently built Haddock on Windows? I'm invoking 
 configure and
 make from Cygwin bash. Configure takes a couple of hours, and 
 then make produces a load of errors (see below).

I'm ashamed to say that Haddock, like Alex and Happy don't really
support native Windows too well.

You can use them in a Cygwin (and possibly MSYS) environment, by doing
the usual ./configure  make install, which will install the tool by
default in /usr/local/bin.

Cheers,
Simon
___
Haskell-Cafe mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell-cafe


RE: [Haskell-cafe] Building Haddock on Windows

2004-03-17 Thread Bayley, Alistair
Got it built after realising that my PATH didn't include ghc (thanks Andy
Moran). I renamed haddock.bin to haddock.exe and copied to into ghc's bin
for convenience (ghc's bin is already in my path). Now I just have to figure
out how to invoke it...

Where can I find instructions for use? I see haddock.sgml in
haddock-0.6/haddock/doc but reading sgml hurts. Is there an html version of
this somewhere?

I have a few questions:
 - can you invoke it on a folder and have it generate docs for all of the
source files in it (and sub-folders)?
 - does it work on .lhs source containing bird-track style code? It would
appear not, as I get a parse error. 
 - why doesn't it know what Int, String, Float, IO, Monad, Show, etc are?
What invocation option do I need to ensure it links to
Prelude/hierarchical-library stuff? (I think it's --read-interface; must I
generate interface files for the Prelude and libraries though?)


Thanks,
Alistair.


 -Original Message-
 From: Simon Marlow [mailto:[EMAIL PROTECTED]
 Sent: 17 March 2004 13:22
 To: Bayley, Alistair; [EMAIL PROTECTED]
 Subject: RE: [Haskell-cafe] Building Haddock on Windows
 
 
  
  Has anyone recently built Haddock on Windows? I'm invoking 
  configure and
  make from Cygwin bash. Configure takes a couple of hours, and 
  then make produces a load of errors (see below).
 
 I'm ashamed to say that Haddock, like Alex and Happy don't really
 support native Windows too well.
 
 You can use them in a Cygwin (and possibly MSYS) environment, by doing
 the usual ./configure  make install, which will install the tool by
 default in /usr/local/bin.
 
 Cheers,
   Simon

-
*
Confidentiality Note: The information contained in this 
message, and any attachments, may contain confidential 
and/or privileged material. It is intended solely for the 
person(s) or entity to which it is addressed. Any review, 
retransmission, dissemination, or taking of any action in 
reliance upon this information by persons or entities other 
than the intended recipient(s) is prohibited. If you received
this in error, please contact the sender and delete the 
material from any computer.
*

___
Haskell-Cafe mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Building Haddock on Windows

2004-03-17 Thread Arjan van IJzendoorn
Hello Alistair,

 Where can I find instructions for use? I see haddock.sgml in
 haddock-0.6/haddock/doc but reading sgml hurts. Is there an html version
of
 this somewhere?

Haddock is very well documented at http://www.haskell.org/haddock/

Greetings, Arjan

___
Haskell-Cafe mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell-cafe


RE: [Haskell-cafe] Building Haddock on Windows

2004-03-17 Thread Bayley, Alistair
http://www.haskell.org/haddock/docs/haddock.html

Ahh, sorry, somehow I missed that. Yes, that is the html generated from the
sqml.


 -Original Message-
 From: Arjan van IJzendoorn [mailto:[EMAIL PROTECTED]
 Sent: 17 March 2004 14:00
 To: Bayley, Alistair
 Cc: [EMAIL PROTECTED]
 Subject: Re: [Haskell-cafe] Building Haddock on Windows
 
 
 Hello Alistair,
 
  Where can I find instructions for use? I see haddock.sgml in
  haddock-0.6/haddock/doc but reading sgml hurts. Is there an 
 html version
 of
  this somewhere?
 
 Haddock is very well documented at http://www.haskell.org/haddock/
 
 Greetings, Arjan

-
*
Confidentiality Note: The information contained in this 
message, and any attachments, may contain confidential 
and/or privileged material. It is intended solely for the 
person(s) or entity to which it is addressed. Any review, 
retransmission, dissemination, or taking of any action in 
reliance upon this information by persons or entities other 
than the intended recipient(s) is prohibited. If you received
this in error, please contact the sender and delete the 
material from any computer.
*

___
Haskell-Cafe mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell-cafe