On Sat, Oct 16, 2010 at 8:45 AM, Brandon S Allbery KF8NH
wrote:
> I thought Windows already had a system message for something like that. Or
> at least it used to, although I can see why it would have been removed or at
> least deprecated.
You're probably thinking of CreateMemoryResourceNotifica
[I wrote initially, ...]
> As I have migrated more of my application into Haskell, I find that
> I/O in one thread effectively blocks other threads.
Resolved - the SSL_read external I/O function needs to be "safe".
My apologies for botching the mailing list threading, but I deleted
the mail wher
On 16/10/2010, at 10:35 PM, Andrew Coppin wrote:
>
> Also, it's news to me that Java finds heavy use anywhere yet. (Then again, if
> they run Java server-side, how would you tell?)
Java seems to be used heavily for developing mobile phone applications
(other than iPhone, of course). My young d
Hi Mathew
Matthew Brecknell wrote:
> Ben Franksen wrote:
>> Suppose we have a function
>>
>> f :: IORef a -> IO b
>>
>> I want to prove that
>>
>> f r == do
>> s1 <- readIORef r
>> r' <- newIORef s1
>> x <- f r'
>> s3 <- readIORef r'
>> writeIORef r s3
>> return x
>
On Sun, Oct 17, 2010 at 4:05 PM, Bryan O'Sullivan wrote:
> On Sun, Oct 17, 2010 at 1:51 PM, Antoine Latter wrote:
>>
>> What would the definition of a function of the form:
>>
>> > find :: (Text -> Bool) -> Text -> Maybe Text
>>
>> look like?
>
> Can you be more specific? I assume you mean that t
Quoth Gregory Collins ,
> Dumb question: are you compiling "-threaded"?
Yes.
Donn
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe
On Sun, Oct 17, 2010 at 1:51 PM, Antoine Latter wrote:
>
> What would the definition of a function of the form:
>
> > find :: (Text -> Bool) -> Text -> Maybe Text
>
> look like?
>
Can you be more specific? I assume you mean that the only sensible return
values are Nothing or the entire Text for
On Sun, Oct 17, 2010 at 3:11 PM, aditya siram wrote:
> An honest list of cons mentioned up-front is a great idea and would attract
> me to a language. It shows me that the community is grounded, active ,
> pragmatic and helpful.
Yes. It's called "damaging admission", and generally works very well
On Sun, Oct 17, 2010 at 3:25 PM, Bryan O'Sullivan wrote:
> On Mon, Oct 11, 2010 at 1:12 PM, Malcolm Wallace
> wrote:
>>
>> find find find (Text -> Bool) -> Text -> Maybe Text
>>
>> Proposal: rename Text.findBy to Text.find.
>
> I agree with the change of type, not so much w
On Sat, Oct 16, 2010 at 3:02 AM, Stephen Tetley
wrote:
>
> If a "functional language" doesn't mean anything significant then
> Haskell probably isn't the language you should be choosing.
People who don't know what 'functional language' means can still get
all the benefits of functional programmin
An honest list of cons mentioned up-front is a great idea and would attract
me to a language. It shows me that the community is grounded, active ,
pragmatic and helpful.
-deech
On Sun, Oct 17, 2010 at 1:45 PM, wrote:
> How about a bullet list of Haskell's features (maybe pros & cons) might be
> Note that in my experience working on SML/NJ's optimizer (using
> wrapper+inlining), such an approach to code transformation doesn't care
> about types at all, and indeed most/all of what tacc-hs09.pdf presents
> is mostly unrelated to whether the language is typed: e.g. the
> uncurrying of the z
> Not sure how this fits into what I thought you were saying. Are you
> trying to use Haskell to build an AST, use GHC to optimize it, and
> then spit it out and compile it with, say, a OCaml program that you
> have already written?
Yes, that would be the basic idea:
1. Compile the Haskell metapr
Donn Cave writes:
> As I have migrated more of my application into Haskell, I find that
> I/O in one thread effectively blocks other threads. That's rather
> the opposite of what I need - I don't care so much if Haskell threads
> manage to compute in parallel, but the application should continue
On Sun, Oct 17, 2010 at 12:12 PM, Patai Gergely
wrote:
>> And it is not enough to provide just a driver function, that is called in
>> 'main', say
>> run :: IOArrow a b -> a -> IO b
>> ?
> No, because I need to compile the stream processing program itself by a
> different tool.
Not sure how th
Quoth Jeremy Shaw ,
...
> I wonder what it would take to make it so that the message body could
> be multipart mime...
Well, here's what it takes for me -
- function to determine file type of attachment (e.g., image/jpeg)
- data encoding (base64, maybe quoted-printable, others)
- randomly generat
On Sun, Oct 17, 2010 at 1:04 PM, Arie Peterson wrote:
> On Thu, 14 Oct 2010 12:01:59 +0200, Michael Snoyman
> wrote:
>> [...] which I believe is a flawed
>> design in the MonadCatchIO-transformers package. Here are my thoughts
>> on this and what I think needs to be done to fix it.
>>
>> [...]
>>
How about a bullet list of Haskell's features (maybe pros & cons)
might be better; followed by a list of a few other languages and their
trade-offs.
As Jon Bentley has said, "design" is usually trade-offs but when you
can come up with something that is a mutual benefit; so much the
better
On Sun, Oct 17, 2010 at 1:32 PM, Stefan Monnier
wrote:
> AFAIK laziness is a property of the major implementations of Haskell,
> but not really of the language itself. All I see in the Haskell report
> points at it being "applicative", "call by name", but nowhere does the
> report seem to mandat
Ketil Malde schrieb:
> Don Stewart writes:
>
>>> Good start, if only the "advanced" were replaced with something more
>>> characteristic, like "lazy", or "statically typed". Which, BTW, both do not
>
>> "lazy" and "statically typed" don't mean much to other people. They are
>> buzz words that me
> Good start, if only the "advanced" were replaced with something more
> characteristic, like "lazy", or "statically typed". Which, BTW, both do not
> appear in the whole blurb, even though they are *the* characteristics of
> Haskell, lazyness being even something that sets it apart from most other
> That said, I've been told that UHC's core language uses the ideas from
> Strict Core, and they have/had a student at Utretch (Tom Lokhorst) who
> was working on implementing optimisations like arity raising and deep
> unboxing for the language.
Many/most implementations of ML-ish languages use a
As I have migrated more of my application into Haskell, I find that
I/O in one thread effectively blocks other threads. That's rather
the opposite of what I need - I don't care so much if Haskell threads
manage to compute in parallel, but the application should continue
to function, in other threa
> And it is not enough to provide just a driver function, that is called in
> 'main', say
>run :: IOArrow a b -> a -> IO b
> ?
No, because I need to compile the stream processing program itself by a
different tool. I just want to trick GHC into doing much of the
weightlifting. No IO monad is i
On Thu, 14 Oct 2010 12:01:59 +0200, Michael Snoyman
wrote:
> [...] which I believe is a flawed
> design in the MonadCatchIO-transformers package. Here are my thoughts
> on this and what I think needs to be done to fix it.
>
> [...]
>
> Try running the code with each version of go uncommented. In
On Sun, 17 Oct 2010, Patai Gergely wrote:
I'm trying to reuse as much of the sweat and tear put into GHC as
possible to derive a compiler for a language highly similar to Haskell
in many aspects. The difference is that instead of constructing an
expression of type IO (), the programmer has to p
Hello all,
I'm trying to reuse as much of the sweat and tear put into GHC as
possible to derive a compiler for a language highly similar to Haskell
in many aspects. The difference is that instead of constructing an
expression of type IO (), the programmer has to provide a stream
processor on the t
On Sun, Oct 17, 2010 at 10:14 AM, Michael Snoyman wrote:
> I'm sure people would love to see built-in support for serving over
> SMTP, but I think that's more appropriate for a different package.
> Proper SMTP support will also include SSL/TLS support, which will
> require even more dependencies.
Forwarding to list.
-- Forwarded message --
From: Antoine Latter
Date: Sun, Oct 17, 2010 at 10:48 AM
Subject: Re: [Haskell-cafe] Heterogenous network stream
To: Charles-Pierre Astolfi
On Sun, Oct 17, 2010 at 7:31 AM, Charles-Pierre Astolfi wrote:
> Hi cafe,
>
> I'd like to im
On 16/10/2010, at 12:36, Max Bolingbroke wrote:
> On 16 October 2010 12:16, Roman Leshchinskiy wrote:
>> eta :: Stream a -> Stream a
>> eta s = Stream s next
>> where
>> next (Stream s next') = case next' s of
>> Just (x,s') -> Just (x,Stream s' next')
>>
On Oct 17, 2010, at 5:37 AM, Michael Snoyman wrote:
> in the case of JSON, I believe this is always specified as UTF-8.
RFC 4627 section 3 says that JSON must be encoded in Unicode, but all encodings
are acceptable. The encoding is inferred by the firsthand four octets. So you
need to be prepar
OK, I've put together a new repository on github[1]. I've modified the
original code from Yesod to now include support for
multipart/alternative, and to only create a multipart when there
really are multiple parts. I've done some simple tests, and it seems
to work just fine. Now a question for ever
I'm a bit partial to Swift Mailer [1]. It's useful to support multiple
transport backends, especially in situations where sendmail is not
portable.
Cheers,
Edward
[1] http://swiftmailer.org/
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http:/
Something along the lines of these examples would be helpful I think:
http://phpmailer.worxware.com/index.php?pg=examples
Phpmailer is probably the most widely used email library, so if it
could be shown that there was a Haskell equivalent (or better), I
think that might start attracting the atte
On 17/Oct/10 3:37 PM, Michael Snoyman wrote:
On Sun, Oct 17, 2010 at 2:26 PM, Ionut G. Stan wrote:
Thanks Michael, now it works indeed. But I don't understand, is there any
inherent problem with Haskell's built-in String? Should one choose
ByteString when dealing with Unicode stuff? Or, is ther
On Sun, Oct 17, 2010 at 2:26 PM, Ionut G. Stan wrote:
> On 17/Oct/10 8:02 AM, Michael Snoyman wrote:
>>
>> In the gist you sent, the problem is that you are reading the HTTP
>> response as a String. The HTTP library doesn't deal well with
>> non-Latin characters when doing String requests; you sho
Hi cafe,
I'd like to implement a toy-protocol and I'm looking for the sanest
way (for me) to do so.
Here's what it looks like:
The server receives, in that order:
- Ascii string (4 bytes)
- 16 bits int (2 bytes)
- 8 bits int (1 byte)
- UTF8 string (128 bytes)
I tried to use hGetBuf, but I don't
Hi Ben,
Ben Franksen wrote:
> Suppose we have a function
>
> f :: IORef a -> IO b
>
> I want to prove that
>
> f r == do
> s1 <- readIORef r
> r' <- newIORef s1
> x <- f r'
> s3 <- readIORef r'
> writeIORef r s3
> return x
I'm not sure where in your question the qua
On 17/Oct/10 8:02 AM, Michael Snoyman wrote:
In the gist you sent, the problem is that you are reading the HTTP
response as a String. The HTTP library doesn't deal well with
non-Latin characters when doing String requests; you should be using
ByteString and then converting. It's a little tedious
Ben Millwood wrote:
> On Sun, Oct 17, 2010 at 11:15 AM, Malcolm Wallace
> wrote:
>>
>> The problem with the code you originally posted was that it looked like
>> this:
>>
>> f r = do r' <- something
>> f r'
>> something else -- this is dead code
>>
>> That is, the computation is non-terminating, b
Derek Elkins wrote:
> On Sun, Oct 17, 2010 at 6:49 AM, Miguel Mitrofanov
> wrote:
>>
>> On 17 Oct 2010, at 05:21, Ben Franksen wrote:
>>
>>> I want to prove that
>>>
>>> f r == do
>>> s1 <- readIORef r
>>> r' <- newIORef s1
>>> x <- f r'
>>> s3 <- readIORef r'
>>> writeIORef r s3
>>> return x
>>
>
Hi Dmitry,
Dmitry V'yal writes:
> Hello list,
>
> I'm trying to make a clickable link in gtk2hs program. Clicking it should
> open an url in the default
> browser. Can I hope to find some portable solution in gtk2hs (it should work
> in linux and windows)
> or should I start searching platform
On Sun, Oct 17, 2010 at 11:15 AM, Malcolm Wallace
wrote:
>
> The problem with the code you originally posted was that it looked like
> this:
>
> f r = do r' <- something
> f r'
> something else -- this is dead code
>
> That is, the computation is non-terminating, because f sim
Hi Erik and wren
Thanks for both messages.
On 17 October 2010 10:12, Erik Hesselink wrote:
[Snip]
>
> I think you can just use the original instance for Monoid for this. It
> declares
>
> instance Monoid b => Monoid a -> b
>
> since 'b' can itself be a function (and r1 -> r2 -> a is parenthesiz
On Sun, Oct 17, 2010 at 6:49 AM, Miguel Mitrofanov
wrote:
>
> On 17 Oct 2010, at 05:21, Ben Franksen wrote:
>
>> I want to prove that
>>
>> f r == do
>> s1 <- readIORef r
>> r' <- newIORef s1
>> x <- f r'
>> s3 <- readIORef r'
>> writeIORef r s3
>> return x
>
> That is not true.
On 17 Oct 2010, at 05:21, Ben Franksen wrote:
> I want to prove that
>
> f r == do
>s1 <- readIORef r
>r' <- newIORef s1
>x <- f r'
>s3 <- readIORef r'
>writeIORef r s3
>return x
That is not true. Consider the following function:
g r1 r2 = writeIORef r1 0 >> writeIORef
At any rate, if you intend to prove this for any arbitrary f, I
can't
tell you how to prove it formally because it's not true.
How do you know that? Can you give an example where it fails?
The problem with the code you originally posted was that it looked
like this:
f r = do r' <- some
Hello list,
I'm trying to make a clickable link in gtk2hs program. Clicking it
should open an url in the default browser. Can I hope to find some
portable solution in gtk2hs (it should work in linux and windows) or
should I start searching platform specific ones, like /usr/bin/xdg-open
or som
On 17 October 2010 04:45, Duane Johnson wrote:
> I bumped into a segmentation fault in the regex library today and thought
> I'd warn others in case similar behavior is observed:
>
>> Prelude> :m Text.Regex
>> Prelude Text.Regex> map read (splitRegex (mkRegex "\\|") "0|1|2|4") ::
>> [Int]
>> Loadi
Yes you're right Kevin. I'll put up a new release sometime in the
next week with some more examples
and possible some simpler methods if only so HaskellNet can be more
easily evaluated.
As I recall Happstack also uses an smtp library. I forget which one.
-Rob
On Sun, Oct 17, 2010 at 9:29 AM, K
On Sat, Oct 16, 2010 at 21:39, Stephen Tetley wrote:
> Hello list
>
> The Monad and Applicative instances for functions are "equivalent" to
> the respective Reader vesions (I use "equivalent" along the lines of -
> operationally the same but without the type distinction / newtype).
> There is also
On 13 Oct 2010, at 16:55, Ozgur Akgun wrote:
Cafe,
Just a quick question. Either I am hallucinating or there was a way
of saying ghci to always show types. It was working as if you typed
":t it" after every line of input.
Sorry, I searched but couldn't find the option via google. Hope
Hi Robert,
I did look at HaskellNet a few months ago.
It looked big and undocumented so I guess I got scared away.
What I'd be interested in is something with the simplicity of the PHP
mail command (or perhaps the phpmailer package).
I dislike PHP as a programming language but it does basic web
Last summer I put cabalized HaskellNet (written by Jun Mukai for a
GSOC) (http://hackage.haskell.org/package/HaskellNet)
and uploaded it to hackage. I put myself down as a maintainer but I
haven't done much maintaining.
HaskellNet also does multipart mime and base64 stuff as well as imap
and pop
Hi Michael,
Last time I checked Hackage for email libraries I could find some
basic SMTP systems but nothing very recent or robust.
Practically every web app needs to send email, so I think that a
robust and well maintained email package would be very useful.
I know you have many other projects
55 matches
Mail list logo