tc.
Thanks again!
-- Peter
On Thu, Nov 18, 2010 at 3:44 PM, Henk-Jan van Tuyl wrote:
> On Thu, 18 Nov 2010 21:20:10 +0100, Peter Schmitz
> wrote:
>
> Thank you very much for the help. Good tips for improving my code design.
>> I'm new to sequence, mapM, and mapM_; I've see
erT Monad Transformer.
>
> If you want to stop processing the rest of the list on error, either
> write a recursive function yourself or use foldM or use ErrorT Monad
> Transformer.
>
> On Nov 18, 3:03 am, Peter Schmitz wrote:
> > I am able to use System.Cmd (system) to inv
Thank you very much for the help.
-- Peter
On Thu, Nov 18, 2010 at 4:48 AM, Scott Turner <1hask...@pkturner.org> wrote:
> On 2010-11-17 21:03, Peter Schmitz wrote:
> > I am wondering how to generalize this to do likewise for a
> > series of commands, where the varying arg
I am able to use System.Cmd (system) to invoke a shell command
and interpret the results.
Please see the code below that works okay for one such command.
(I invoke a program, passing two args.)
I am wondering how to generalize this to do likewise for a
series of commands, where the varying args (
Dean,
Thanks very much, that indeed worked.
-- Peter
On Wed, Nov 3, 2010 at 9:16 PM, Dean Herington
wrote:
> At 8:45 PM -0700 11/3/10, Peter Schmitz wrote:
>>
>> I have a program (test.hs):
>>
>>> module Main (main) where
>>> import System.Exit
I have a program (test.hs):
> module Main (main) where
> import System.Exit
> main :: IO ExitCode
> main = do
>return (ExitFailure 1)
In another program, I invoke it via 'system':
>exitCode <- system ".\\test.exe"
>case (exitCode) of
> ExitFailure failCnt -> do
> putS
I am seeking suggestions for a regression test utility or framework
to use while developing in Haskell (in a MS Windows environment).
I am developing a Haskell application that parses an input text file,
and outputs some information about what was parsed.
The application is currently in a GUI, bu
Antoine and Christian:
Many thanks for your help on this thread.
(I am still digesting it; much appreciated; will post when I get it working.)
-- Peter
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-
I am a new Parsec user, and having some trouble with a relatively
simple parser.
The grammar I want to parse contains tags (not html) marked by
angle brackets (e.g., ""), with arbitrary text (no angle
brackets allowed) optionally in between tags.
Tags may not nest, but the input must begin and en
Stephen,
Thanks much for the pointer to the examples in the sources; found them.
(Its nice to learn from the coding style used by the authors.)
-- Peter
On Sat, Sep 25, 2010 at 12:34 AM, Stephen Tetley
wrote:
> On 25 September 2010 05:30, Evan Laforge wrote:
>
>> I thought the parsec source incl
On Fri, Sep 24, 2010 at 9:28 PM, Evan Laforge wrote:
>>> simpleComment = do{ string ""))
>>> }
>>>
>>> Note the overlapping parsers anyChar and string "", ...
>
> Yes, I think the doc just made a mistake there. In fact, it looks
> like the same mistake is in the current doc at
>
I am new to parsec and having difficulty understanding the
explanation of manyTill in
http://legacy.cs.uu.nl/daan/download/parsec/parsec.html.
(I really appreciate having this doc by the way; great reference.)
I.e.:
> manyTill :: GenParser tok st a -> GenParser tok st end -> GenParser tok st [a]
Ivan,
Duncan,
Thank you both very much for your kind help and comments.
I'm really impressed with the quality of help at Haskell Cafe,
and Cabal really has worked great for me; I'll just avoid "upgrade"
in the future.
Anyone:
So, to get a clean start with my library situation I will delete my
".
This gets a little hilarious (but better to laugh than cry).
Well, I decided to try Parsec version 3 (i.e., 3.1.0) after all, and
edited my cabal config to include:
preference: parsec >= 3
I did not include "base >= 4"; hope that is not a problem.
I did "cabal upgrade parsec", which went great.
reason not to, but it's good to know how
Cabal works.
I am finding developing in Haskell + Gtk2Hs + Glade + Parsec a lot of
fun. Parser combinators are so cool.
-- Peter
On Wed, Sep 15, 2010 at 8:15 PM, Jason Dagit wrote:
> On Wed, Sep 15, 2010 at 7:47 PM, Peter Schmitz wrote:
>>
Thomas,
Ivan,
Thanks much for the info.
-- Peter
On Wed, Sep 15, 2010 at 8:00 PM, Ivan Lazar Miljenovic
wrote:
> On 16 September 2010 12:47, Peter Schmitz wrote:
>> Not that I'm having any problem with parsec 2.1.0.1, but I guess I
>> would like to install the latest (3.1.0
Not that I'm having any problem with parsec 2.1.0.1, but I guess I
would like to install the latest (3.1.0), unless there is a reason
not to.
I can't seem to get Cabal to do so; thanks in advance for any help.
I don't understand part of the output from "cabal install --dry-run
--reinstall -v pars
Daniel,
Thanks much; the more I learn Haskell and Parsec, the more I like them.
-- Peter
On Wed, Sep 15, 2010 at 4:02 PM, Daniel Fischer
wrote:
> On Wednesday 15 September 2010 23:01:34, Peter Schmitz wrote:
>> > textLine :: Parser String
>> > textLine = do
>>
Antoine,
Thank you very much for your reply. Adding type sigs did help me think
about it. I got it to work.
I replaced:
> eol = char '\n'
> textLines = endBy eol
with:
> textLine :: Parser String
> textLine = do
>x <- many (noneOf "\n")
>char '\n'
>return x
>
> textLines :: Parser [
Simple Parsec example, question
I am learning Parsec and have been studying some great reference and
tutorial sites I have found (much thanks to the authors), including:
http://legacy.cs.uu.nl/daan/download/parsec/parsec.html#UserGuide
http://legacy.cs.uu.nl/daan/download/parsec/parsec.html#Refer
Thanks so very much Axel and Ivan.
You were both absolutely correct and I can compile Glade apps now fine.
Great help!
The tricky part (for me) would have been looking at the error from
cabal install glade:
"setup.exe: The pkg-config package libglade-2.0 version >=2.0.0
is required but it co
(I am posting this to Cafe and Gtk2Hs Users; if you subscribe to both,
please reply to Cafe; but I will see your replies either place; thanks
much.)
I am trying to compile the Gtk2Hs demo program GladeTest.hs (located
in the ...\demo\glade dir), under MS Windows XP.
The error I get is:
H:\proc\t
In [Haskell-beginners], please see:
http://www.haskell.org/pipermail/beginners/2010-August/004949.html
Please reply to [Haskell-beginners]; thanks much.
-- Peter
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listin
On Thu, Jul 29, 2010 at 8:47 PM, Ivan Miljenovic
wrote:
> On 30 July 2010 13:32, Peter Schmitz wrote:
> > I have a question about finding the Gtk2Hs demos (the demos written in
> > Haskell).
>
> They're not there:
> http://osdir.com/ml/haskell-cafe@haskell.org/
I have a question about finding the Gtk2Hs demos (the demos written in
Haskell).
To summarize what I have done so far:
I'm a new Cabal user; need to use Cabal in a Windows XP environment, where
it and the Haskell Platform are located on a network drive (H:) instead of
C:. (Need to be able to do d
>
> Rogan is right. You just need to edit the cabal config file to point
> to locations on your other drive.
>
> I would suggest not relocating the config file itself. If you really
> must do so then you can use the --config-file flag or the environment
> variable CABAL_CONFIG.
>
> Duncan
>
I will
Rogan:
Again, thanks very much for your reply.
My situation is that I need to be able to use Cabal (and the Haskell
Platform, Gtk2Hs, etc.) at any of several PCs in a (Windows XP) LAN, each of
which has access to the network drive H:.
So, I am using:
H:\proc\tools\Haskell Platform
H:\proc\tools\
n H:
(and ignore C:) ?
Thanks (very much) in advance.
-- Peter Schmitz
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe
y what to do next -- the exact
commands to use for my non-C: / network drive installation. (I have not used
Cabal before.)
I would prefer to do this without admin privs, if possible.
** If anyone could help me out here with a step-by-step, I would appreciate
it.
Hopefully the procedure for glade
Problem summary
Trying to build a stand-alone executable GLUT app with ghc, Windows XP
Problem description
I compile and link (without errors) a simple GLUT application under Windows
XP.
When I run it, XP pops an error window saying the app cannot start due to a
missing "glut32.dll".
I want to
module Main(main) where
import System.IO
main = do
b1 <- hGetBuffering stdin
print b1
b2 <- hGetBuffering stdout
print b2
-- not sure if these help, or are needed
hSetBuffering stdin NoBuffering
hSetBuffering stdout NoBuffering
b1 <- hGetBuffering stdin
print b1
b2
31 matches
Mail list logo