[Haskell-cafe] cabal probems with binary/containers packages

2009-10-27 Thread brian
during the building phase. The exception was: exit: ExitFailure 1 help Thanks, Brian ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

Re: [Haskell-cafe] cabal probems with binary/containers packages

2009-10-28 Thread brian
. Is there something broken in the 0.5.0.2 release that causes ghc to look for the old library ? Brian On Oct 28, 2009, at 4:00 AM, Duncan Coutts wrote: On Tue, 2009-10-27 at 21:37 -0700, brian wrote: It all started with this: Loading package binary-0.5.0.1 ... can't load .so/.DLL

Re: [Haskell-cafe] cabal probems with binary/containers packages

2009-10-28 Thread brian
Just found the following file: .ghc/powerpc-darwin-6.10.1/pkg-config and it is referring to 0.5.0.1. Is there anyway to regenerate the file, or is it broken because of a problem with the package ? Thanks, Brian On Oct 28, 2009, at 4:00 AM, Duncan Coutts wrote: On Tue, 2009-10-27 at 21

Re: [Haskell-cafe] cabal probems with binary/containers packages

2009-10-28 Thread brian
That was indeed the problem. I edited the pkg-config file by hand. I followed your advice anyway and unregistered and re-installed. Everythingworks now. Thanks for your help. Brian On Oct 28, 2009, at 11:58 AM, Duncan Coutts wrote: On Wed, 2009-10-28 at 07:07 -0700, brian wrote: Just

Re: [Haskell-cafe] What's the deal with Clean?

2009-11-03 Thread brian
;-) There's also ST. So why is there a uvector, when there's ST ?? etc, etc, etc... and then there's monads... other than that, having fun with haskell :-) Brian On Nov 3, 2009, at 3:42 PM, David Leimbach wrote: On Tue, Nov 3, 2009 at 2:16 PM, Tracy Wadleigh tracy.wadle...@gmail.com

Re: [Haskell-cafe] Arrays in Clean and Haskell

2009-11-03 Thread brian
On Nov 3, 2009, at 7:38 PM, Philippos Apolinarius wrote: Brian wrote: Really, arrays in Haskell are the most @#!$! confusing thing in the world. Hi, Brian. I am having a great difficulty with arrays in Haskell. In the university where I study, functional programming is taught in Clean

Re: [Haskell-cafe] What's the deal with Clean?

2009-11-03 Thread brian
Don, There is more than one indexU ? In Data.Array.Vector there is only 1 indexU that I can find. Brian On Nov 3, 2009, at 9:15 PM, Don Stewart wrote: Well, it depends on which indexU the OP means. The one linked in the docs is the O(1) UA type class version. -- Don gcross: Actually

Re: [Haskell-cafe] What's the deal with Clean?

2009-11-05 Thread brian
On Nov 5, 2009, at 8:26 AM, Jason Dagit wrote: I can't really think of how laziness and polymorphism are related. For me the big win with laziness is composability. Laziness allows us to express things in ways that are more natural. The prelude function 'take' is a perfect example.

Re: [Haskell-cafe] What's the deal with Clean?

2009-11-05 Thread brian
On Nov 5, 2009, at 8:26 AM, Jason Dagit wrote: Haskell knows when I have a list of Doubles, you know, because it's strongly typed. Then it proceeds to box them. Huh ? Imagine a computation which will yield a Double if evaluated, but has not yet been evaluated. How do you store that

[Haskell-cafe] converting IOException to Either in ErrorT

2009-05-03 Thread brian
I wrote this to make it a little nicer to catch IO exceptions and convert them to ErrorT failure: onExceptionThrowError :: (Error ce) = IO a - (String - ce) - ErrorT ce IO a onExceptionThrowError a ce = liftIO (try a) = either (\(e :: IOException) - throwError (ce

[Haskell-cafe] *system*-time timeout?

2009-05-04 Thread brian
System.Timeout.timeout is OK for wall clock time, but can I limit the amount of system time an IO action can take? ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

[Haskell-cafe] setResourceLimit

2009-05-05 Thread brian
I have a long-lived multithreaded server process that needs to execute programs and interact with them via Handles. The programs could misbehave, like loop or hang, so I need to limit the real and CPU time they can take. I guess System.Posix.Resource.setResourceLimit sets limits on the current

Re: [Haskell-cafe] setResourceLimit

2009-05-06 Thread brian
On Tuesday, 05.05.09 at 22:48, Brandon S. Allbery KF8NH wrote: On May 5, 2009, at 04:52 , br...@lorf.org wrote: I have a long-lived multithreaded server process that needs to execute programs and interact with them via Handles. The programs could misbehave, like loop or hang, so I need to

Re: [Haskell-cafe] setResourceLimit

2009-05-06 Thread brian
On Wednesday, 06.05.09 at 16:25, Brandon S. Allbery KF8NH wrote: No. What it means is that, if the child will continue to run in the same Haskell program after forkProcess-ing, any open Handles won't work right. You could fix this with handleToFd and fdToHandle, I suspect, but it's

[Haskell-cafe] hackage version scheme survey

2009-05-23 Thread brian
It's not good to specify open version ranges in cabal build-depends like foo = 1.1 because the foo maintainer will eventually release 2.0, containing API-breaking changes, and the build will fail. If you depend on foo 1.1, you can specify == 1.*, no problem. But if you depend on a package that

Re: [Haskell-cafe] hackage version scheme survey

2009-05-23 Thread brian
On Saturday, 23.05.09 at 17:26, Don Stewart wrote: http://haskell.org/haskellwiki/Package_versioning_policy ? That helps a lot. I should have found that. But putting the policy on a web page doesn't seem to be working; there are a lot of non-compliant packages. I guess I'm surprised thah 'cabal

Re: [Haskell-cafe] Cabal/primes

2009-06-03 Thread brian
Prelude :m + Data.Numbers.Primes Prelude Data.Numbers.Primes :browse isPrime :: Integer - Bool isProbablyPrime :: (System.Random.RandomGen g) = Integer - g - (Bool, g) primes :: [Integer] Prelude Data.Numbers.Primes isPrime 3525266 Loading package syb ... linking ... done. Loading package

[Haskell-cafe] slow code

2009-06-14 Thread brian
the show's with , and compiled with -O2 and not much improvement. I need to write _a lot_ of code in this style. A few words about how best to do this would be helpful. Laziness, infinite lists, uvector ?? Help... Thanks, Brian import Complex import System.IO genData :: Double - Int

Re: [Haskell-cafe] slow code

2009-06-15 Thread brian
time =0.14 secs (7 ticks @ 20 ms) total alloc = 65,562,824 bytes (excludes profiling overheads) So I guess it's the show's, but I can't seem to find more efficient float output. FFI to sprintf ? yuch. Brian foo.hs import Numeric import Complex import IO genData :: Double

Re: [Haskell-cafe] slow code

2009-06-16 Thread brian
. Is there an efficient way to output double - binary ? I typically write my data files as binary anyway, because it's faster for graph and the like to handle them anyway. Brian ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org

Re: [Haskell-cafe] hmatrix on os x

2009-09-10 Thread brian
fink installed. Brian On Sep 7, 2009, at 7:06 PM, Ben wrote: hello -- i've been having a heck of a time installing hmatrix on mac os x. i've seen the help pages including http://mit.edu/harold/Public/easyVisionNotes.html but they haven't helped me. my setup is haskell platform 2009.2.0.2

Re: [Haskell-cafe] hmatrix on os x

2009-09-11 Thread brian
to work. Let me know what happens. The linux pc gave me even more problems which I eventually traced to LD_LIBRARY_PATH needing to include the lib dirs. HTH. Brian On Sep 9, 2009, at 11:57 PM, Martijn van Steenbergen wrote: brian wrote: yep I had some trouble too, although interestingly less

[Haskell-cafe] self-referential data

2008-08-09 Thread brian
From https://secure.wikimedia.org/wikipedia/en/wiki/Bencoding , I think I should code data BValue = BString String | BIntegerInteger | BList [BValue] | BDictionary (M.Map BString BValue) but: Not in scope: type constructor or class `BString' The

Re: [Haskell-cafe] self-referential data

2008-08-09 Thread brian
On Sat, Aug 9, 2008 at 5:18 PM, Brent Yorgey [EMAIL PROTECTED] wrote: The problem is that BString is not a type, it is a data constructor. I know. You could use M.Map BValue BValue, but of course that's probably not what you want either. Right. That wouldn't be according to spec either.

Re: [Haskell-cafe] Recommended Haskell Books

2008-08-11 Thread brian
On Sun, Aug 10, 2008 at 1:29 PM, Warren Aldred [EMAIL PROTECTED] wrote: I'm new to Haskell and looking for recommendations on introductory Haskell books. Online or offline. Any suggestions? I like _Programming in Haskell_ (Hutton) _The Haskell School of Expression_ (Hudak) _Real World

[Haskell-cafe] parsec, hGetContents

2008-08-23 Thread brian
I'm writing an NNTP client API. When I connect with connectTo, I get a Handle 'h'. I immediately hGetContents h to get a string 'c' that I hope contains all the data the server will ever send. I put h and c in a data Connection and pass it to the functions that send or receive. I send a command

[Haskell-cafe] Parsec and network data

2008-08-26 Thread brian
Hi, I've been struggling with this problem for days and I'm dying. Please help. I want to use Parsec to parse NNTP data coming to me from a handle I get from connectTo. One unworkable approach I tried is to get a lazy String from the handle with hGetContents. The problem: suppose the first

Re: [Haskell-cafe] Parsec and network data

2008-08-26 Thread brian
On Tue, Aug 26, 2008 at 3:38 PM, John Van Enk [EMAIL PROTECTED] wrote: Are you doing this all in a single thread? Yes. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

Re: [Haskell-cafe] Parsec and network data

2008-08-26 Thread brian
On Tue, Aug 26, 2008 at 3:43 PM, John Van Enk [EMAIL PROTECTED] wrote: Perhaps you'll want to continue with the hGetLine setup in one thread (assuming the NNTP data is line delimited), then in another, parse the data, then in a third, respond. Sorry if my writing was unclear. I think hGetLine

[Haskell-cafe] Re: Parsec and network data

2008-08-27 Thread brian
I made a small example related to the problem: http://hpaste.org/9957 It's my attempt to run data from the network directly into Parsec without having to fear deadlock due to blocking. The idea is that we feed Parsec from a timeout-enabled Stream based on Handle. As long as Parsec is able to read

Re: [Haskell-cafe] Parsec and network data

2008-08-29 Thread brian
On Fri, Aug 29, 2008 at 11:15 AM, Donn Cave [EMAIL PROTECTED] wrote: Quoth brian [EMAIL PROTECTED]: | I want to use Parsec to parse NNTP data coming to me from a handle I | get from connectTo. I would implement the network service input data stream myself, with timeouts Could you explain

Re: [Haskell-cafe] Re: Hmm, what license to use?

2008-09-30 Thread brian
On Tue, Sep 30, 2008 at 8:54 PM, Stefan Monnier [EMAIL PROTECTED] wrote: That still leaves anyone free to use LGPL if they want to, but please don't assume that it allows commercial use by all potential users. It *does* allow commercial use. Your example just shows that some people may

Re: [Haskell-cafe] Haskell-cafe-cafe? Was: Re: Health effects

2008-10-03 Thread brian
On Fri, Oct 3, 2008 at 8:01 PM, Christopher Lane Hinson [EMAIL PROTECTED] wrote: What /is/ it with haskell-cafe lately? Do we need a haskell-blah mailing list? Thanks for saying it. +1. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org

Re: [Haskell-cafe] There is something wrong in derive-0.1.2 package.

2008-10-14 Thread brian
On Tue, Oct 14, 2008 at 3:31 AM, Magicloud [EMAIL PROTECTED] wrote: Finally, after I hacked some files, everything worksMan! Come ON. You're banned from the Internet. Please, never ever do what you just did again. Tell what you did! This whole thing is useless otherwise.

Re: [Haskell-cafe] Foreign.Marshal.Error.void

2008-10-14 Thread brian
On Tue, Oct 14, 2008 at 12:52 PM, Mauricio [EMAIL PROTECTED] wrote: Wouldn't it be nice if we had something like 'void' in Foreign.Marshal.Error in standard monad functions, so that we could use it instead of, for instance, mapM_ or sequence_? Dunno. I thought about using 'void' in the

Re: [Haskell-cafe] An irritating Parsec problem

2008-10-15 Thread brian
On Wed, Oct 15, 2008 at 2:22 PM, Andrew Coppin [EMAIL PROTECTED] wrote: So if + is not a valid token, but the user writes x = 1; y = 2; z = 3 + z; w = 4; then what my program receives back is x = 1; y = 2; z = 3 You said you expect one or more 'expression'. It looks as if your expression can

Re: [Haskell-cafe] Password hashing

2008-10-29 Thread brian
Please be careful not to invent or reinvent a password hashing scheme. I'd go with bcrypt. That'd be a worthy module. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

Re: [Haskell-cafe] Missing comment highlighting in vim syntax script

2008-12-13 Thread brian
On Sat, Dec 13, 2008 at 9:10 AM, Ori Avtalion o...@avtalion.name wrote: Comments on the same line as import declarations don't get highlighted: import A -- This comment isn't highlighted import B {- Neither is this -} import C {- and this -} I think the way vim tries to do syntax

Re: [Haskell-cafe] Parsec and type level numerals

2008-12-13 Thread brian
2008/12/13 Nathan Bloomfield nblo...@gmail.com: I want to be able to parse a string of digits to a type level numeral as described in the Number parameterized types paper. Hi, I'm at UA too (bsl04). Here's a quick try. Sorry if I'm not getting what you're doing. import Text.Parsec import

Re: [Haskell-cafe] Time for a new logo?

2008-12-14 Thread brian
On Sun, Dec 14, 2008 at 3:15 PM, Don Stewart d...@galois.com wrote: I noticed a new haskell logo idea on a tshirt today, http://image.spreadshirt.net/image-server/image/configuration/13215127/producttypecolor/2/type/png I'd buy one, but I'm not seeing it on spreadshirt.net.

Re: [Haskell-cafe] Removing/Uninstalling cabal packages ?

2008-12-21 Thread brian
On Sun, Dec 21, 2008 at 12:12 PM, Laurent Giroud m...@niaow.com wrote: I have been doing a few experiments with cabal packages lately and I wish to uninstall these to return to a cleaner package base. However, there doesn't seem to be a cabal uninstall command and reading the documentation at

[Haskell-cafe] OpenAL

2008-12-22 Thread brian
Does the example code at http://articles.bluishcoder.co.nz/Haskell/OpenAL work for anyone? I added some putStrLns to see the device and context, and get $ ./Main2 Device (ALCdevice 0x08a744c8) Context (ALCcontext 0x08aabda0) AL lib: alSource.c:2291: alcDestroyContext(): 1 Source(s) NOT deleted AL

[Haskell-cafe] example editrc

2008-12-23 Thread brian
This is making ghci with editline nicer for me. It says to use the vi key mapping, tab for completion, C-l to clear the screen, and jj to go into vi command mode. $ cat ~/.editrc bind -v bind \\t rl_complete bind ^L ed-clear-screen bind jj vi-command-mode

Re: [Haskell-cafe] Don't make 'show*' functions

2008-12-26 Thread brian
On Fri, Dec 26, 2008 at 1:55 PM, Jeff Heard jefferson.r.he...@gmail.com wrote: Off the top of my head, I would say that the traditional meaning of Show could be changed to Serial, where serial encompasses both Read and Show -- possibly we could find a more efficient read function, several have

Re: [Haskell-cafe] chroot a single thread

2008-12-27 Thread brian
On Sat, Dec 27, 2008 at 8:01 PM, Jeremy Shaw jer...@n-heptane.com wrote: The problem with that function is that chroot affects the root of the whole process. Yeah. Maybe you want privilege separation. Instead of starting a thread to do the stuff that requires extra authority, make it a separate

Re: [Haskell-cafe] databases in Haskell type-safety

2009-01-03 Thread brian
On Sat, Jan 3, 2009 at 4:25 AM, Austin Seipp mad@gmail.com wrote: NB: I have *just* (about 5 minutes ago) sent in a patch for takusen to get it to build on GHC 6.10.1 to Oleg. Hopefully an updated version will appear on hackage in the next few days. Yay! Thanks. I've been waiting.

[Haskell-cafe] template haskell

2009-01-07 Thread brian
Smart constructors sometimes need to generate errors like Foo.Bar.Baz.create: invalid value, etc. Can TH generate the module and function names? ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

[Haskell-cafe] cabal build on mac os 10.5.6 , can't find gmp

2009-04-05 Thread brian
a bad sign. I can get to the build step with the additional -L option but then ./ Setup fails again because it can't find gmp. Help ? Thanks, Brian ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo

[Haskell-cafe] error handling (esp. IO/exceptions)

2009-04-14 Thread brian
I'm finding it hard to write robust code that isn't really ugly. Suppose I want to write execute :: FilePath - [String] - IO (Either ExecuteError ExitCode) where 'ExecuteError' is a data type representing all the ways 'execute' could fail and that 'execute p args' is supposed to * ensure p

Re: [Haskell-cafe] error handling (esp. IO/exceptions)

2009-04-14 Thread brian
On Tuesday, 14.04.09 at 23:36, Miguel Mitrofanov wrote: What about ErrorT monad transformer? I don't see how it helps in my situation. ErrorT doesn't catch exceptions, for example. Suppose I did make something like ErrorT that catches exceptions and turn them into Lefts. Where would (=) get my

Re: [Haskell-cafe] error handling (esp. IO/exceptions)

2009-04-14 Thread brian
On Tuesday, 14.04.09 at 22:13, Lennart Augustsson wrote: So the right way to do this (like opening a file), is to try executing it and let the OS tell you if it failed. I know, but the various functions that create processes don't help me know whether the program actually ran or not. For

Re: [Haskell-cafe] Re: Language support for imperative code. Was: Re: monad subexpressions

2007-08-13 Thread Brian Hulley
Brian Hulley wrote: apfelmus wrote: Brian Hulley schrieb: main = do buffer - createBuffer edit1 - createEdit buffer edit2 - createEdit buffer splitter - createSplitter (wrapWidget edit1) (wrapWidget edit2) runMessageLoopWith splitter

Re: [Haskell-cafe] Re: Explaining monads

2007-08-13 Thread Brian Brunswick
On 13/08/07, David Roundy [EMAIL PROTECTED] wrote: Try executing: do { x - return 2; undefined; return (x*x); } in any monad you like, and you'll find that regardless of the *data* dependencies (the return value of this monadic action is unambiguous), the undefined is evaluated *before*

Re: [Haskell-cafe] Explaining monads

2007-08-14 Thread Brian Brunswick
On 14/08/07, Jeff Polakow [EMAIL PROTECTED] wrote: Of course, the type [Int] denotes a value which is a list of Ints; additionally [Int] can be viewed as a value representing the nondeterministic computation of a single Int. Generally, the type Monad m = m Int can be viewed as a value

Re: [Haskell-cafe] Re:Explaining monads

2007-08-14 Thread Brian Brunswick
On 15/08/07, Gregory Propf [EMAIL PROTECTED] wrote: - Original Message From: Jeff Polakow [EMAIL PROTECTED] One general intuition about monads is that they represent computations rather than simple (already computed) values: I still want to re-iterate that they represent /complex/

[Haskell-cafe] Syntax for lambda case proposal could be \of

2007-08-15 Thread Brian Hulley
edit the H' wiki, so if anyone agrees that the above syntax is better please could they add the above to the page. Thanks, Brian. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

Re: [Haskell-cafe] Syntax for lambda case proposal could be \of

2007-08-15 Thread Brian Hulley
as an incomplete character literal or a complete TH name. I suppose my main point is that it's useful for a syntax to have plenty of unfilled gaps that result in an error when written rather than filling all those gaps with different meanings... Brian

Re: [Haskell-cafe] Elevator pitch for Haskell.

2007-09-09 Thread Brian Hurt
things that enable the language to cross the chasm are the very things that make people like us want to start looking for a new language. Any links to these presentations? I'm interested. Thanks. Brian ___ Haskell-Cafe mailing list Haskell-Cafe

Re: [Haskell-cafe] Elevator pitch for Haskell.

2007-09-10 Thread Brian Hurt
On Mon, 10 Sep 2007, Devin Mullins wrote: Brian Hurt wrote: Any links to these presentations? I'm interested. Videos: http://rubyhoedown2007.confreaks.com/session04.html Actually, this video has an interesting bit, relevent to this discussion. He doesn't phrase it as an elevator pitch

[Haskell-cafe] Desugaring of infix operators is (always?) the wrong way round

2007-09-25 Thread Brian Hulley
: a - b === (-) b a Can anyone think of an example where the current desugaring of infix arguments gives the correct order when the function is used in a postfix application? (apart from commutative functions of course!) Thanks, Brian ___ Haskell-Cafe

Re: [Haskell-cafe] Desugaring of infix operators is (always?) the wrong way round

2007-09-25 Thread Brian Hulley
Brian Hulley wrote: I'm wondering if anyone can shed light on the reason why x # y gets desugared to (#) x y and not (#) y x Can anyone think of an example where the current desugaring of infix arguments gives the correct order when the function is used in a postfix application

Re: [Haskell-cafe] Desugaring of infix operators is (always?) the wrong way round

2007-09-25 Thread Brian Hulley
Jonathan Cast wrote: On Tue, 2007-09-25 at 19:18 +0100, Brian Hulley wrote: Brian Hulley wrote: I'm wondering if anyone can shed light on the reason why x # y gets desugared to (#) x y and not (#) y x Of course, this is all a consequence of the well-known failure

Re: [Haskell-cafe] Desugaring of infix operators is (always?) the wrong way round

2007-09-25 Thread Brian Hulley
Ryan Ingram wrote: My comments inlined below... On 9/25/07, Brian Hulley [EMAIL PROTECTED] wrote: let shiftLeftByThree = shiftL' 3 in map shiftLeftByThree [10, 78, 99, 102] let shiftLeftByThree = (`shiftL` 3) in ... Aha! but this is using section syntax which

Re: [Haskell-cafe] Desugaring of infix operators is (always?) the wrong way round

2007-09-25 Thread Brian Hulley
Dan Piponi wrote: On 9/25/07, Brian Hulley [EMAIL PROTECTED] wrote: ..I seem to dimly recall that there is a natural language somewhere that also uses it but I can't remember which one. Every permutation of [S,V,O] appears in 'nature': http://en.wikipedia.org/wiki/Word_order. Thanks

Re: [Haskell-cafe] Desugaring of infix operators is (always?) the wrong way round

2007-09-27 Thread Brian Hulley
Sam Hughes wrote: Brian Hulley wrote: ... For example, with the prefix definition of a function with multiple clauses, the function name at the start of each clause is already lined up since it must appear at the margin of the current layout block ... Or you could have everything

Re: [Haskell-cafe] Dynamic choice of reverse implementation

2007-09-28 Thread Brian Hulley
]. Hope this helps, Brian. but I couldn't get this to work. I've tried typeclass approach: class (Foldable f) = Reversor f where reverse' :: [a] - f a instance Reversor ([]) where reverse' = Data.List.reverse instance Reversor ViewR where reverse' = viewr . foldr (|) empty

Re: [Haskell-cafe] Dynamic choice of reverse implementation

2007-09-28 Thread Brian Hulley
Brian Hulley wrote: Krzysztof Kościuszkiewicz wrote: So the type of mapM_ used in the code is (Foldable t, Monad m) = (a - m b) - t a - m () I'd like to keep the generic Foldable t there when m is specialized to IO. I thought this would allow type of reversor to be specialized to (Foldable f

Re: [Haskell-cafe] Dynamic choice of reverse implementation

2007-09-28 Thread Brian Hulley
:: (Foldable f, Foldable g) :: f a - g a Of course with lazy evaluation + compiler optimizations the lists in [a] - something - [a] should be erased at compile time... ;-) Regards, Brian. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http

Re: [Haskell-cafe] On the verge of ... giving up!

2007-10-14 Thread Brian Hurt
something working. And as you have the time/inclination/need to, you can start playing with more advanced functional concepts, like purely applicative data structures, lazy evaluation, and even monads. Brian ___ Haskell-Cafe mailing list Haskell-Cafe

Re: [Haskell-cafe] Re: Waiting for thread to finish

2007-11-28 Thread Brian Sniffen
on a shared-memory machine. If the threads are distributed, then the channel to communicate back that one has finished may be very expensive. -Brian -- Brian T. Sniffen [EMAIL PROTECTED]or[EMAIL PROTECTED] http://www.evenmere.org/~bts

Re: [Haskell-cafe] Doing some things right

2007-12-28 Thread Brian Sniffen
not possible in Haskell without Templates. Macros were invented in Lisp because the syntax is so easy for machine manipulation---they don't have a tenth the complexity of Template Haskell for about the same power. -Brian -- Brian T. Sniffen [EMAIL PROTECTED]or[EMAIL PROTECTED] http

[Haskell-cafe] Newbie question: can laziness lead to space compression?

2007-12-29 Thread Brian Hurt
. Note that the benefit isn't *big*- we're talking about 40 words of memory when the main data structure is taking up 5K plus words of memory- so it's less than 1% different. But there is a (small) upside in memory usage at least occassionally, right? Brian

[Haskell-cafe] haskell package installation problem

2008-01-03 Thread Brian Park
, readline-1.0.1.0, rts-1.0, template-haskell-2.2.0.0, unix-2.3.0.0, xmonad-0.5, xmonad-contrib-0.5 = Thank you, - Brian ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

[Haskell-cafe] the trivial monad- thoughts and a question

2008-01-12 Thread Brian Hurt
question I have is: is there any hope of getting something like this into the standard library? Thanks, Brian ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

Re: [Haskell-cafe] GSOC idea: Haskell JVM bytecode library

2010-03-26 Thread Brian Alliet
be more than happy to give anybody who is interested in using it some pointers though. -Brian ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

[Haskell-cafe] US Patent for the idea of using Haskell to implement UAX #9

2010-04-16 Thread Brian Hulley
the huge task of reclaiming our world for real people who understand that true meaning in life comes from extending our feeling of self into the world beyond our own body: http://petition.stopsoftwarepatents.eu/ http://ffii.org Thanks a lot for reading this, Brian. [expecting to be crucified

Re: [Haskell-cafe] US Patent for the idea of using Haskell to implement UAX #9

2010-04-17 Thread Brian Hulley
Daniel Fischer wrote: Am Freitag 16 April 2010 20:50:25 schrieb Brian Hulley: revealed a link to a US Patent (7120900) for the idea of implementing the Unicode Bidirectional Algorithm (UAX #9 http://www.unicode.org/reports/tr9) in Haskell, making use, as far as I can tell, of nothing more than

Re: [Haskell-cafe] Re: US Patent for the idea ...

2010-04-17 Thread Brian Hulley
jerzy.karczmarc...@info.unicaen.fr wrote: Brian Hulley reports a search similar to : haskell unicode bidirectional Comment irrelevant to Haskell, sorry. Everybody does his/her various jobs. But I lost all respect due to people who work in the US Patent Office, when I saw the patent

Re: [Haskell-cafe] Re: US Patent for the idea ...

2010-04-17 Thread Brian Hulley
Murray Gross wrote: On Sat, 17 Apr 2010, Brian Hulley wrote: see the patent 6,368,227. The search site is here: http://patft.uspto.gov/netahtml/PTO/srchnum.htm Best regards. Jerzy Karczmarczuk ... It's really almost not fair to cite that particular patent, since, if I recall the story

Re: [Haskell-cafe] Editors for Haskell

2006-05-30 Thread Brian Hulley
the standard can be changed to enable the determinism and ease of parsing necessary for interactive editing with immediate feedback)? Regards, Brian. -- Logic empowers us and Love gives us purpose. Yet still phantoms restless for eras long past, congealed in the present in unthought forms, strive mightily

Re: [Haskell-cafe] Editors for Haskell

2006-05-30 Thread Brian Hulley
Benjamin Franksen wrote: On Tuesday 30 May 2006 20:59, Brian Hulley wrote: It is quite a tall order to provide immediate typed feedback of an edit buffer that will in general be syntactically incomplete but this is my eventual aim. One issue in the area of immediate feedback is that Haskell's

Re: [Haskell-cafe] Editors for Haskell

2006-05-31 Thread Brian Hulley
Doaitse Swierstra wrote: On 2006 mei 30, at 17:33, Brian Hulley wrote: But the buffer will nearly always be incomplete as you're editing it. I was kind of hoping that the syntax of Haskell could be changed so that for any sequence of characters there would be a unique parse that had a minimum

[Haskell-cafe] Re: Editors for Haskell

2006-06-01 Thread Brian Hulley
Thomas Hallgren wrote: Brian Hulley wrote: Another thing which causes difficulty is the use of qualified operators, and the fact that the qualification syntax is in the context free grammar instead of being kept in the lexical syntax (where I think it belongs). You are in luck, because

Re: [Haskell-cafe] Re: Editors for Haskell

2006-06-02 Thread Brian Hulley
Simon Marlow wrote: Malcolm Wallace wrote: Brian Hulley [EMAIL PROTECTED] wrote: Thanks for pointing this out. Although there is still a problem with the fact that var, qvar, qcon etc is in the context free syntax instead of the lexical syntax so you could write: 2 `plus

Re: [Haskell-cafe] FunDeps conflict

2006-06-06 Thread Brian Hulley
. Is there anyway to get around this, knowing that (Bar a) won`t instantiate the isFoo class, or is the right answer simply to get rid of the FunDep ? If 'b' is not uniquely determined by 'a' in all instances of Class2 a b, then you'd need to get rid of the fundep. Regards, Brian. -- Logic empowers us

Re: [Haskell-cafe] FunDeps conflict

2006-06-06 Thread Brian Hulley
complexity. There is a proposal for Haskell' for closed classes but this is listed under the probably no section so it's unlikely this will be adopted. http://hackage.haskell.org/trac/haskell-prime/wiki/ClassSystem http://hackage.haskell.org/trac/haskell-prime/wiki/ClosedClasses Regards, Brian

Re: [Haskell-cafe] FunDeps conflict

2006-06-06 Thread Brian Hulley
Brian Hulley wrote: Joel Björnson wrote: Hi. I have a question regarding type classes and FunDeps. Consider the following code : class Class2 a b | a - b class IsFoo a data Bar a = Bar a instance IsFoo a = Class2 a a instance IsFoo a = Class2 (Bar a) a The last two instantiations

Re: [Haskell-cafe] newbie type signature question

2006-06-09 Thread Brian Hulley
style where one guideline was never to use contexts in data declarations. Regards, Brian. -- Logic empowers us and Love gives us purpose. Yet still phantoms restless for eras long past, congealed in the present in unthought forms, strive mightily unseen to destroy us. http://www.metamilk.com

Re: Re[2]: [Haskell-cafe] newbie type signature question

2006-06-12 Thread Brian Hulley
Bulat Ziganshin wrote: Hello Brian, Saturday, June 10, 2006, 3:05:25 AM, you wrote: It is possible that this feature was added to the language for the benefit of people who prefer not to use explicit type signatures but afaiu this goes against best practice where everything should always have

[Haskell-cafe] Everything but the lazyness - idea for force/delay lists

2006-06-12 Thread Brian Hulley
to do this but I've shared the idea here in the vague hope someone else might want to do it first :-) There certainly seems to be a gap in the market between the perfection of lazy Haskell's monads, typeclasses etc and strict ML's side effects and less expressive type system. Regards, Brian

Re: [Haskell-cafe] Everything but the lazyness - idea for force/delay lists

2006-06-15 Thread Brian Hulley
is that the typeclasses and existentials that Haskell supports are an advantage over OCaml or SML, but that the lazyness is a real nusiance but with some extra effort it's possible to mostly get rid of it. Regards, Brian. mt 2006/6/13, Brian Hulley [EMAIL PROTECTED]: Hi - I've been thinking about

Re: [Haskell-cafe] what do you think of haskell ? (yes, it's a bit general ...:)

2006-06-15 Thread Brian Hulley
things like monads and monad transformers, you can also look at the Haskell source (available from ghc wiki for example) to see that they are not so complicated as they appear if you only look at the Haddock documentation which only gives the type signatures. Regards, Brian. -- Logic empowers us

Re: [Haskell-cafe] do we have something like isDefined or isNullin Haskell?

2006-06-15 Thread Brian Hulley
? pupil: Nothing in a shop: Haskeller: I'll just buy some crisps OCamler: I'll buy some packet of crisps SMLer: I'll buy SOME packet of crisps Regards, Brian. -- Logic empowers us and Love gives us purpose. Yet still phantoms restless for eras long past, congealed in the present

Re: [Haskell-cafe] Re: Functional programming for processing of largeraster images

2006-06-21 Thread Brian Hulley
have side effects, which limit optimizations due to possible aliasing etc, it might be possible to compile such a language to code which is certainly no slower, and possibly *even faster* than OCaml!!! :-) Regards, Brian. -- Logic empowers us and Love gives us purpose. Yet still phantoms

Re: [Haskell-cafe] Functional progr., images, laziness and all the rest

2006-06-21 Thread Brian Hulley
also has unboxed types so perhaps something like data HSList = Empty | Cons Double# HSList but see the restrictions on their use at http://www.haskell.org/ghc/docs/latest/html/users_guide/primitives.html ) Regards, Brian. -- Logic empowers us and Love gives us purpose. Yet still phantoms

Re: [Haskell-cafe] Functional progr., images, laziness and all therest

2006-06-22 Thread Brian Hulley
Jerzy Karczmarczuk wrote: Brian Hulley wrote: [EMAIL PROTECTED] wrote: you may transform a recurrential equation yielding Y out of X: Y[n+1] = a*X[n+1] + b*Y[n] usually (imperatively) implemented as a loop, into a stream definition: ... Can you explain how this transformation

Re: [Haskell-cafe] Functional progr., images, laziness and all therest

2006-06-22 Thread Brian Hulley
minh thu wrote: 2006/6/22, Brian Hulley [EMAIL PROTECTED]: Jerzy Karczmarczuk wrote: Brian Hulley wrote: [snip] y IS NOT a longer list than yq, since co-recursive equations without limiting cases, apply only to *infinite* streams. Obviously, the consumer of such a stream will generate

Re: [Haskell-cafe] Functional progr., images, laziness and all therest

2006-06-22 Thread Brian Hulley
Jon Fairbairn wrote: On 2006-06-22 at 15:16BST Brian Hulley wrote: minh thu wrote: y and yq are infinite... But how does this change the fact that y still has 1 more element than yq? yq is after all, not a circular list. infinity+1 = infinity Surely this is just a mathematical convention

Re: [Haskell-cafe] Functional progr., images, laziness and all therest

2006-06-22 Thread Brian Hulley
with that of y) Best regards, Brian. -- Logic empowers us and Love gives us purpose. Yet still phantoms restless for eras long past, congealed in the present in unthought forms, strive mightily unseen to destroy us. http://www.metamilk.com

Re: [Haskell-cafe] Functional progr., images, laziness and alltherest

2006-06-22 Thread Brian Hulley
Stepan Golosunov wrote: On Thu, Jun 22, 2006 at 03:32:25PM +0100, Brian Hulley wrote: Bill Wood wrote: On Thu, 2006-06-22 at 15:16 +0100, Brian Hulley wrote: . . . But how does this change the fact that y still has 1 more element than yq? yq is after all, not a circular list. I don't see why

  1   2   3   4   5   6   7   >