Re: Q. about XML support

2003-02-20 Thread Joe English
Shae Matijs Erisson wrote: > Do you have a version of HXML + (any) namespace support online or otherwise > available for playing with? I'd like to try it. Not yet, but stay tuned. --Joe English [EMAIL PROTECTED] ___ Haskell mailing

Re: Q. about XML support

2003-02-20 Thread Joe English
Graham Klyne wrote: > Joe English wrote: > >What are you looking for in an XML toolkit? > > Hi, thanks for responding. My desiderata: > > 1. Works with HUGS and GHC (I'm currently developing with HUGS, but > anticipate using GHC for "production" code). H

Re: Q. about XML support (WAS: Re: Interesting Read)

2003-02-19 Thread Joe English
implementing XMLNS is not hard, but implementing it in a sane way requires some ingenuity.) --Joe English [EMAIL PROTECTED] ___ Haskell mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/haskell

Re: Enum on Float/Double

2002-10-24 Thread Joe English
e Just Plain Wrong -- they're subject to horribly bad roundoff errors -- and I'm not even close to being a numerical analyst. --Joe English [EMAIL PROTECTED] ___ Haskell mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/haskell

Re: UTF-8 library

2002-08-10 Thread Joe English
s not true on all platforms. The slogan is "All the world is not a VAX." Java attempts platform independence by declaring that all the world *is*, in fact, a VAX [*]. [*] More precisely, a 32-bit platform with IEEE 754 floating point. --Joe English [EMAIL PROTECTED] __

Re: UTF-8 library

2002-08-08 Thread Joe English
d it's very convenient. --Joe English [EMAIL PROTECTED] ___ Haskell mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/haskell

[ADMINISTRIVIA]: Change list submission policy please?

2002-06-27 Thread Joe English
The haskell mailing list is getting an increasing amount of spam, viruses, and virus warnings. Would it be possible to change the list policy to only allow submissions from subscribed members? Please? --Joe English [EMAIL PROTECTED

Re: Functional design patterns (was: How to get functional software engineering experience?)

2002-05-15 Thread Joe English
tterns and OO patterns. OO patterns tend to be informal, intuitive guidelines; and though some FP patterns are like this (e.g., "combinator library", "embedded domain-specific language"), the majority can be described rigorously. This gives t

ANNOUNCE: HXML 0.2, XML parser for Haskell

2002-03-06 Thread Joe English
YPE declarations) + Several data structures and public functions have been renamed + Space fault in comment parsing fixed Please contact Joe English <[EMAIL PROTECTED]> with any questions, comments, or bug reports. --Joe English [EMAIL

Re: heap and walking through a very long list

2001-11-24 Thread Joe English
Simon Peyton-Jones wrote: > There should really be a strict accumArray, just as there > should be a strict foldl. Yes, please! Is there a way to write a strict version of accumArray in Haskell 98, or does this need to be done by the implementation? --Joe English [EMAIL PRO

Space faults in HaXml

2001-11-04 Thread Joe English
kElem and cat finally fixes the problem. I'm still not sure *why* this does the trick -- hopefully somebody smarter can explain that -- but the modified program runs in bounded space, no matter how large the input file is. (It even works in Hugs, which I found surprising, since

ANNOUNCE: HXML 0.1, an(other) XML parser for Haskell

2001-11-02 Thread Joe English
version is 0.1, and is slightly post-alpha quality. Tested with GHC 5.02, NHC98 1.10, and various recent versions of Hugs. Please contact Joe English <[EMAIL PROTECTED]> with any questions, comments, or bug reports. --Joe English [E

HaXml article on IBM developerWorks

2001-10-25 Thread Joe English
ese "datafied" | XML documents. Many of the HaXml techniques are far more elegant, compact, | and powerful than the ones found in familiar techniques like DOM, SAX, or | XSLT. Code samples demonstrate the techniques. http://www-106.ibm.com/developerworks/xml/library/x-matters14.

Re: Monads

2001-05-17 Thread Joe English
ng about them goes, I don't think I really "got" monads until reading Wadler's aptly-titled "Comprehending Monads", which approaches them from this perspective. --Joe English [EMAIL PROTECTED] ___ Haskell mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/haskell

Re: newbie

2001-03-10 Thread Joe English
;Comprehending Monads" gives a very good presentation using the fmap/return/join formulation (called map/unit/join in that paper). "The Essense of Functional Programming" is another very good presentation using the return/>>= formulation (there called "unitM/bindM"). See http://cm.bell-labs.com/cm/cs/who/wadler/topics/monads.html > --Joe English [EMAIL PROTECTED] ___ Haskell mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/haskell

Re: Extending the do-notation

2001-01-07 Thread Joe English
ine | f # m = m >>= (return . f) and add an appropriate fixity declaration for '#'. --Joe English [EMAIL PROTECTED] ___ Haskell mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/haskell

Re: Finding primes using a primes map with Haskell and Hugs98

2000-12-16 Thread Joe English
ve to do with the way hugs98 implements and Int to Bool array? Most likely yes. Hugs is optimized for interactive use and quick compilation, not for space usage. Try it with GHC or HBC and see how it does. --Joe English [EMAIL PROTECTED] ___ Haskell mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/haskell

Re: mapM/concatMapM

2000-10-18 Thread Joe English
t ([1..102400] :: [Integer])' has type 'IO [()]', perhaps the result of the IO operation -- a list of 100K empty tuples -- is the culprit, even though the result is never used. Does 'mapM_ print ... ' (:: IO ()) perform any better? --Joe English [EMAIL PROTECTED]

Re: SAX, XML, Haskell

2000-09-25 Thread Joe English
a combination of the HaXML combinators and Ketil Malde's parser would give the best of both worlds. --Joe English [EMAIL PROTECTED]

Re: simple binary IO proposition.

2000-09-02 Thread Joe English
Marcin 'Qrczak' Kowalczyk wrote: > Joe English pisze: > > According to the ISO C standard, the meaning of wchar_t > > is implementation-defined. > > I know. How to convert between the default multibyte locale and > Unicode on such systems? As far as I ca

Re: simple binary IO proposition.

2000-09-01 Thread Joe English
erpreted as such. It appears to depend on the current locale. --Joe English [EMAIL PROTECTED]

Re: Test case Re: Is there a space leak here?

2000-02-28 Thread Joe English
-- also runs without a space problem under STG Hugs. --Joe English [EMAIL PROTECTED]

Re: Test case [space leak?]

2000-02-28 Thread Joe English
and sum', where: length' :: [a] -> Integer sum':: [Integer] -> Integer length' = foldl_strict (\n _ -> n + 1) 0 sum'= foldl_strict (+) 0 foldl_strict:: (a -> b -> a) -> a -> [b] -> a foldl_strict f a [] = a foldl_strict f a (x:xs) = (foldl_strict f $! f a x) xs fixed these as well. Thanks! --Joe English [EMAIL PROTECTED]

Re: Test case Re: Is there a space leak here?

2000-02-28 Thread Joe English
t case, plus ~10K words to spare. After fixing the *other* space leak that Malcolm Wallace noted, (too much laziness in 'length' and 'sum') all the tests ran without a problem. That was using breadth=12 and depth=6, which makes Hugs98 run out of room even with the default heap size. Problem solved! Thanks! --Joe English [EMAIL PROTECTED]

Test case Re: Is there a space leak here?

2000-02-26 Thread Joe English
In my real program though there's much more data stored at each node and it fails on modestly-sized inputs. Thanks in advance for any advice... --Joe English [EMAIL PROTECTED] -- module SpaceLeak where data Tree a = Tree a [Tree a] deriving (Show, Eq) -- -- a few of the usual polyt

Re: Is there a space leak here?

2000-02-26 Thread Joe English
cumulation (validation, namespace processing, many simple translations to other document types, etc.), all of which should run in space bounded by the depth of the tree. --Joe English [EMAIL PROTECTED]

Help! Is there a space leak here?

2000-02-22 Thread Joe English
;unfoldr' which -- again according to my unreliable intuition -- should behave nicely space-wise). Thanks for any advice, --Joe English [EMAIL PROTECTED]

Re: Haskell 98: partition; and take,drop,splitAt

2000-01-24 Thread Joe English
'filter/filter' version, so the former may be preferable if the two are in fact semantically equivalent. --Joe English [EMAIL PROTECTED]

Re: Reverse composition

1999-10-08 Thread Joe English
arrows), but those don't look as nice typeset IMHO. I also like: apfst :: (a -> c) -> (a,b) -> (c,b) apsnd :: (b -> c) -> (a,b) -> (a,c) apl :: (a -> c) -> Either a b -> Either c b apr :: (b -> c) -> Either a b -> Either a c These are called "first", "second", "left", and "right" in the Arrow library. --Joe English [EMAIL PROTECTED]

Re: To all those who don't like ad-hoc overloading

1999-10-04 Thread Joe English
p = (==)) l1 l2 > ... > where > union l1 l2 > means > union (==) l1 l2 I don't quite see what algorithm you're using to decide how many arguments are passed to the function. What would you get if you typed: foo = foldr union [] for example? --Joe English [EMAIL PROTECTED]

Re: Cryptarithm solver - comparing oranges and oranges

1999-09-20 Thread Joe English
he built-in functions enough to follow > it. (Monads are Haskell's way of making imperative and mutative programming > harder to do so that programmers are less likely to do it, right? :)) Actually, quite the opposite... you should see how difficult it was to do I/O in Haskell *befor

Re: Guidance on strictness

1999-06-07 Thread Joe English
luated until it's requested, so the space behaviour of "array" is particularly bad. The second rule of thumb, then, is "avoid Haskell Arrays unless you really, really need constant-time random access." In this particular problem, 'scprod' consumes elements in sequential order, so it may be better to use lists instead of arrays. (In fact "scprod a a where a = produce n 1.0" has a closed-form, O(1) solution, but I assume that's not the problem you're really trying to solve :-) Hope this helps, --Joe English [EMAIL PROTECTED]

Re: Modifying the monomorphism restriction

1999-02-24 Thread Joe English
I wrote: > Operationally I expect that in "let x = f y in ... x ... x", > 'f y' is only evaluated once, no matter what type it is. Which, of course, is not how Haskell actually works, if x :: (SomeClass a) => SomeType a. DOH! Please disregard my earlier remarks

Re: Modifying the monomorphism restriction

1999-02-24 Thread Joe English
Alex Ferguson <[EMAIL PROTECTED]> wrote: > Joe English: > > How about leaving the 'a = b' binding form as it is, > > (monomorphism restriction and all) and using 'a = ~ b' > > to indicate call-by-name. [...] > I like that much less [...] becaus

Re: Modifying the monomorphism restriction

1999-02-24 Thread Joe English
till signal an error if the programmer accidentally bumps into the MR. If this happens you only need to twiddle the code to fix it. For people reading the code, a ~ on the RHS of a binding is a signal that something out-of-the-ordinary is going on operationally, the same as when it appears on the LHS. --Joe English [EMAIL PROTECTED]

Haskell-2

1999-02-17 Thread Joe English
s. IIRC, the main reason comprehensions et al. were de-overloaded is because ambiguities led to error messages that bewildered novices. If it were possible to declare default Monad ([]) this problem could be alleviated. That's my $.02... --Joe English [EMAIL PROTECTED] P.S., than