Thanks Richard, now I have my answers.
Richard Eisenberg wrote:
- The type system of Haskell is based on theoretical work that resolutely
assumes that types of non-* kind are uninhabited. While it is possible to
stretch imagination to allow types like 'Zero to be inhabited, the
designers of
Mostly just a refresh of the current development version
binary installers, so people can use it with the latest
Haskell Platform (which uses GHC 7.6.3).
Unfortunately an official 0.14 release may still be a
be a way off.
I have been doing some work on getting Code Mirror working,
but there are
It is not obvious that semantics is preserved for optimisations which
remove non-constants like
bar a b = a + b - a - b -- the RHS is should be optimized away to 0
Calling bar undefined undefined throws an error, but the optimised bar
would return 0.
On Sat, Jun 1, 2013 at 8:10 PM, Patrick
Right, these optimizations are done on the unboxed level, where bottom is
not a concern. GHC would transform
bar a b = a + b - a - b
to
bar (I# a) (I# b) = I# (a +# b -# a -# b)
whose RHS could be optimized away to I# 0#. bar is still strict in its two
arguments, so calling bar undefined
Hi Edward,
Thanks for this comprehensive answer (and also thanks to participants in the
follow-up dissuasion).
How is the public good determined? (sounds rather Benthamite). I would have
been disappointed if charts using diagrams had not been selected yet I don't
recall being canvassed.
On Sat, Jun 1, 2013 at 7:55 PM, nadine.and.he...@pobox.com wrote:
Yesterday I decided to take a look at the most recent Euler problem,
number 249, and give it a shot. I have a couple of computers at home,
a Dell laptop and a desktop. I compiled this message with ghc -O2
--make ex429.lhs and
Hi all,
I try to play with the Typeable typeclass, and I have some difficulties to
make it work in this simple case where I use type-level naturals:
-
{-# LANGUAGE GADTs #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE PolyKinds #-}
{-#
Public good is a nebulous concept, but it is something that each of the
folks who sign up as mentors judges independently when they are rating the
projects and talking about them.
Most of the folks who are offering to mentor have been involved in the
community for quite some time and have a
Gregory Collins greg at gregorycollins.net writes:
On Sat, Jun 1, 2013 at 7:55 PM, nadine.and.henry at pobox.com wrote:
Yesterday I decided to take a look at the most recent Euler problem,
number 249, and give it a shot. I have a couple of computers at home,
a Dell laptop and a desktop.
On Jun 2, 2013, at 12:52 , Henry Laxen nadine.and.he...@pobox.com wrote:
Yes, that was it. The dell was a 32 bit system, and the desktop a 64. I
changed everything from Int to Integer, and now both agree. Thanks for the
pointer.
Isn't that just terrible? I hate the fact that Haskell was
On Sun, Jun 2, 2013 at 11:02 PM, Tommy Thorn tt1...@yahoo.com wrote:
On Jun 2, 2013, at 12:52 , Henry Laxen nadine.and.he...@pobox.com wrote:
Yes, that was it. The dell was a 32 bit system, and the desktop a 64. I
changed everything from Int to Integer, and now both agree. Thanks for
On Sunday, June 2, 2013 at 5:02 PM, Tommy Thorn wrote:
On Jun 2, 2013, at 12:52 , Henry Laxen nadine.and.he...@pobox.com
(mailto:nadine.and.he...@pobox.com) wrote:
Yes, that was it. The dell was a 32 bit system, and the desktop a 64. I
changed everything from Int to Integer, and now both
On Jun 2, 2013, at 14:13 , Kata lightqu...@amateurtopologist.com wrote:
In addition to Haskell already having an arbitrary-width integer type called
Integer
But I wasn't asking for arbitrary-width. I was asking for explicit failures
(overflow) rather
than C-like silent corruption.
,
There was a quite long discussion here:
http://conal.net/blog/posts/notions-of-purity-in-haskell
On 2 June 2013 22:02, Tommy Thorn tt1...@yahoo.com wrote:
...
I wish this fatal flaw would be reconsidered for the next major revision.
___
Haskell-Cafe
Try adding
deriving instance Typeable 'Zero
deriving instance Typeable a = Typeable ('Succ a)
to your module.
(I haven't tested it — you might need to tweak it a bit.)
Roman
* TP paratribulati...@free.fr [2013-06-02 18:08:02+0200]
Hi all,
I try to play with the Typeable typeclass, and
There is a package that implements an Int that throws an exception on
overflow:
http://hackage.haskell.org/package/safeint
Since Int's existence is pretty much all about trading for performance, I
wouldn't recommend holding your breath on the above becoming the default.
If you want things
Hi,
I want to implement a function in C++ via Haskell FFI, which should have
the (final) type of String - String.
Say, is it possible to re-implement the following function in C++ with the
exact same signature?
import Data.Char
toUppers:: String - String
toUppers s = map toUpper senter code here
===
APLAS 2013
11th Asian Symposium on Programming Languages and Systems
9-11 December 2013
Melbourne, Australia (colocated with CPP 2013)
CALL FOR PAPERS
On Sun, Jun 2, 2013 at 7:22 PM, Ting Lei tin...@gmail.com wrote:
In particular, I wanted to avoid having an IO in the return type because
introducing the impurity
(by that I mean the IO monad) for this simple task is logically
unnecessary. All examples involing
Anything that comes into or
On 2 Jun 2013, at 16:48, Brandon Allbery allber...@gmail.com wrote:
On Sun, Jun 2, 2013 at 7:22 PM, Ting Lei tin...@gmail.com wrote:
In particular, I wanted to avoid having an IO in the return type because
introducing the impurity
(by that I mean the IO monad) for this simple task is
On Sun, Jun 2, 2013 at 8:01 PM, Thomas Davie tom.da...@gmail.com wrote:
On 2 Jun 2013, at 16:48, Brandon Allbery allber...@gmail.com wrote:
(String is a linked list of Char, which is also not a C char; it is a
constructor and a machine word large enough to hold a Unicode codepoint.
And
Thanks for your answers so far.
It seems that the laziness of String or [char] is the problem.
My question boils then down to this. There are plenty of Haskell FFI
examples where simple things like sin/cos in math.h can be imported into
Haskell as pure functions. Is there a way to extend that to
The C++/C function (e.g. toUppers) is computation-only and as pure as cos
and tan. The fact that marshaling string incurs an IO monad in current
examples is kind of unintuitive and like a bug in design. I don't mind
making redundant copies under the hood from one type to another..
If you can
23 matches
Mail list logo