Thank you so much Ivan!!!
main :: IO ( )
main =
let
a = 8
b = 3
c = 15
in print(b / a * c)
This code works!!! :)
Julita
On Fri, Nov 4, 2011 at 12:53 AM, Ivan Lazar Miljenovic <
ivan.miljeno...@gmail.com> wrote:
> On 4 November 2011 16:21, yrazes wrote:
> > H
On 4 November 2011 16:21, yrazes wrote:
> Hi
> This is a very simple basic case, but I have a little trouble with this... I
> hope somebody can help me
First of all, it would help if you said what your actual trouble is.
> main :: IO()
> main = return :: f
The "return :: f" bit here doesn't mak
> I have interfaced Erlang and Haskell... And delivered it as a product. I
> just came up with a dead-simple text based communication syntax from Erlang
> to Haskell that was very easily testable. It allowed for complete isolation
Interesting. I can't imagine there are too many people who have
2011/11/4 José Pedro Magalhães :
> Hi,
>
> 2011/11/3 Bas van Dijk
>>
>> 2011/11/3 José Pedro Magalhães :
>> > "-ddump-deriv" will print (most of) it.
>>
>> But it doesn't print the most useful piece of information: the
>> definition of Rep.
>
> Yes... I am aware of this.
>
>>
>> It would be great
Hi,
2011/11/3 Bas van Dijk
> 2011/11/3 José Pedro Magalhães :
> > "-ddump-deriv" will print (most of) it.
>
> But it doesn't print the most useful piece of information: the
> definition of Rep.
>
Yes... I am aware of this.
>
> It would be great if this could be added.
>
I'll do it.
Cheers,
2011/11/3 José Pedro Magalhães :
> "-ddump-deriv" will print (most of) it.
But it doesn't print the most useful piece of information: the
definition of Rep.
It would be great if this could be added.
Currently when I have a type that I want to know the Rep of, say:
data Foo = Bar Int
|
On 3 November 2011 23:11, Giovanni Tirloni wrote:
> Does anyone know what's the procedure to create a new mailing list at
> haskell.org for a forming user group?
community.haskell.org provides MailMan mailing lists:
Cheers,
Bas
___
Haskell-Cafe maili
Hi,
Does anyone know what's the procedure to create a new mailing list at
haskell.org for a forming user group?
Thank you,
--
Giovanni
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe
Chalmers University in Gothenburg, Sweden has a master's programme
that includes a compiler construction course. For the lectures from
last term, see:
http://www.cse.chalmers.se/edu/course/TDA282/lectures.html
When I took it in 2006 it was a very practical course -- your task was
to implement a b
Hi Timo,
> Now I look for Universities, which offer compiler construction, since
> I need that course, preferably in the UK, Ireland, Australia or New
> Zealand.
> Ideally it would be in Haskell of course.
>
I currently work in a research group that is well known for their compiler
construction
On 3 November 2011 17:38, Twan van Laarhoven wrote:
> Perhaps relying on Attoparsec backtracking for picking out the right
> alternative from the sum is the problem. You could try it with Maybe:
Good idea. I implemented and committed it and the
BigSum/fromJSON/generic benchmark goes from 13.6 us
On Thu, Nov 3, 2011 at 10:22 AM, David Barbour wrote:
> It is correct in context. Mighttpd does not use the -Nx argument to create
> multiple OS threads, instead uses a `prefork` model that creates separate
> processes to balance user invocations. Using multiple processes instead of
> multiple Ha
On Thu, Nov 3, 2011 at 8:35 AM, Andreas Voellmy
wrote:
> I just read Kazu Yamamoto's article on a high performance web server in
> the latest Monad.Reader, and I came across a statement that doesn't sound
> correct to me. He says:
>
> "When a user thread issues a system call, a context switch occu
Hi,
I study computer science in Kiel, Germany and I want to study abroad.
Now I look for Universities, which offer compiler construction, since
I need that course, preferably in the UK, Ireland, Australia or New
Zealand.
Ideally it would be in Haskell of course.
Greetings
Timo
__
On 03/11/11 11:16, Bas van Dijk wrote:
...
instance (Constructor c, GFromJSON a, ConsFromJSON a) => GFromSum (C1 c a) where
gParseSum (key, value)
| key == pack (conName (undefined :: t c a p)) =
gParseJSON value
| otherwise = notFound $ unpack key
{-# INL
"-ddump-deriv" will print (most of) it.
Cheers,
Pedro
On Thu, Nov 3, 2011 at 16:26, Magicloud Magiclouds <
magicloud.magiclo...@gmail.com> wrote:
> Hi,
> I am learning the new generic feature of ghc. I'd have to say, it is
> harder than template to enter.
> When I started to learn template, g
On Thu, Nov 3, 2011 at 8:35 AM, Andreas Voellmy
wrote:
> I just read Kazu Yamamoto's article on a high performance web server in
> the latest Monad.Reader, and I came across a statement that doesn't sound
> correct to me. He says:
>
> "When a user thread issues a system call, a context switch occu
Hi,
I am learning the new generic feature of ghc. I'd have to say, it is
harder than template to enter.
When I started to learn template, ghc -ddump-slices really helped.
So I wonder if I could get the representation generated when deriving
Generic. I think that would be a great help.
--
竹密岂妨流
I just read Kazu Yamamoto's article on a high performance web server in the
latest Monad.Reader, and I came across a statement that doesn't sound
correct to me. He says:
"When a user thread issues a system call, a context switch occurs. This
means that all Haskell user threads stop, and instead th
Hi Everyone,
I'm happy to announce version 0.3.4.0 of the cereal serialization
library. This release includes a patch from Adam Foltzer to provide
support for IEEE754 encoded Float/Double values. This functionality is
exposed through Serialize instances for both types, and specialized
get/p
2011/11/3 Claus Reinke :
> Not that it matters much if you're going with other tools, but your SYB code
> has a long linear chain of type rep comparisons, at every
> level of the recursive traversals. That is partially inherent in the SYB
> design (reducing everything to cast), but could probably b
* syb: toJSON and fromJSON from the Data.Aeson.Generic module. Uses
the Data type class.
..
As can be seen, in most cases the GHC Generics implementation is much
faster than SYB and just as fast as TH. I'm impressed by how well GHC
optimizes the code!
Not that it matters much if you're going wit
On 3 November 2011 14:56, Ryan Newton wrote:
>> Aside: The problem with collections is that we don't have the programming
>> language means to do this well yet (although soon!). The issue is that we
>> want to declare a type class where the context of the methods depends on the
>> instance e.g.
>>
For those who find this interesting. Here's the code of the BigSum benchmark
with a manual Generic instance with inlined 'from' and 'to':
https://gist.github.com/1336426
José, I was thinking about the following idea. Say GHC generates the
following instance for BigSum:
instance Generic BigSum whe
> I think the best option at the moment is to break out type classes in their>
> own packages. That's what I did with hashable.
Indeed! I greatly believe in this mantra now. Really, my point was
only this banal one -- packages with only interfaces in them have no
dependencies and are much less l
2011/11/3 José Pedro Magalhães :
> - Compile with -O2 and -fno-spec-constr-count (this last one is particularly
> important)
I already compiled with -O2. Adding -fno-spec-constr-count does not
change the results.
> - Add {-# INLINE [1] #-} pragmas to the to/from methods of your Generic
> instance
Hi Bas,
First of all, thanks for these numbers. I have previously compared the
performance of GP libs [1] and your results confirm what I would expect,
except for that last one, BigSum/fromJSON/generic.
It's good that you're using INLINE pragmas on the generic function already.
What I would also
You are absolutely right, they do not seem to play along very well.
Here's what I tried:
$ cabal install --disable-library-vanilla --enable-shared ranges
Resolving dependencies...
Configuring ranges-0.2.4...
Preprocessing library ranges-0.2.4...
Building ranges-0.2.4...
[1 of 1] Compiling Data.Ran
Hello,
I recently added default generic implementations of toJSON and
parseJSON to the aeson package. Now I'm optimizing them. Here are some
benchmark results that compare:
* th: toJSON and fromJSON generated by template-haskell. Can be
compared to hand-written code. Should be the fastest of all.
Hi,
The actual thanks for tracking this down go to Vincent Hanquez for finding
that we're doing a lot of gmp calls (and for making me aware of ltrace),
and to Felipe Lessa for finding that this is caused by poor code generated
for cFloatConv :)
Your changes look identical to those that I made in
Thanks, you spotted another mistake on that page, I corrected it.
Make sure to have a look at the functions in
http://hackage.haskell.org/package/generic-deriving too; I'm sure those
compile :-)
Pedro
2011/11/3 Magicloud Magiclouds
> 2011/11/1 José Pedro Magalhães :
> > Oh, right, I see that
2011/11/1 José Pedro Magalhães :
> Oh, right, I see that some things on that page need updating; I'll do so.
>
> Thanks,
> Pedro
>
> On Tue, Nov 1, 2011 at 09:33, Magicloud Magiclouds
> wrote:
>>
>> On Tue, Nov 1, 2011 at 1:59 PM, Andres Löh
>> wrote:
>> > Hi.
>> >
>> >> I do not know why, my gh
32 matches
Mail list logo