G'day all.
Quoting Peter Simons <[EMAIL PROTECTED]>:
> >> Is there any reason why you would have a function in one
> >> of your modules and _not_ export it?
>
> > Because that function is nobody else's business.
>
> I'm sorry, but that's not really a convincing technical
> argument, that's ess
Iavor Diatchki writes:
>> Do you have an concrete example which illustrates this
>> point?
> [...] consider a file A.hs that defines some data type T
> and exports a function "f" that is defined in terms of a
> private function "g". Now if we place "g" in a file
> called "Private.hs" then A
Galois Connections does most of its development in Haskell, and this
job may involve some Haskell development, so I felt it was on topic
for this list.
Senior Test Engineer
Galois Connections, Inc., located near Portland, Oregon, designs and
develops high confidence software for critical appli
Hi,
Florian Weimer wrote:
I'm toying a bit with Haskell and wondering what's the best way to
implement bit fiddling. Most of my applications involve serializing
and deserializing small blobs (IP packets, for instance), and after
browsing the GHC library documentation, I'm not sure which appraoch I
* robert dockins:
> If you want C compatibility, you need
>
> http://www.haskell.org/ghc/docs/latest/html/libraries/base/Data.Array.Storable.html
>
> which is similar. You then use the "withStorableArray" to call out to
> your C functions.
Looks exactly like what I need. I'll give it a try and
On 2005 May 17 Tuesday 11:44, Donn Cave wrote:
> > You can get efficiency, the desired data, and deal with infinite strings.
> >reversed_inits = scanl (flip (:)) ""
> >find (isPrefixOf (reverse "needle")) (reversed_inits "haystack")
With "get efficiency", I was comparing this program which
If you want C compatibility, you need
http://www.haskell.org/ghc/docs/latest/html/libraries/base/Data.Array.Storable.html
which is similar. You then use the "withStorableArray" to call out to
your C functions.
Florian Weimer wrote:
* robert dockins:
Probably you have seen this already, but I th
* robert dockins:
> Probably you have seen this already, but I thought I'd mention it on the
> off-chance you missed it:
>
> http://www.haskell.org/ghc/docs/latest/html/libraries/base/Data.Bits.html
> http://www.haskell.org/ghc/docs/latest/html/libraries/base/Data.Word.html
>
> Probably you'll wa
Probably you have seen this already, but I thought I'd mention it on the
off-chance you missed it:
http://www.haskell.org/ghc/docs/latest/html/libraries/base/Data.Bits.html
http://www.haskell.org/ghc/docs/latest/html/libraries/base/Data.Word.html
Probably you'll want to think about an IOUArray of
I'm toying a bit with Haskell and wondering what's the best way to
implement bit fiddling. Most of my applications involve serializing
and deserializing small blobs (IP packets, for instance), and after
browsing the GHC library documentation, I'm not sure which appraoch I
should use. That's why I
Hello,
On 17 May 2005 12:09:35 +0200, Peter Simons <[EMAIL PROTECTED]> wrote:
> Iavor Diatchki writes:
>
> > [...] in practice this is likely to often lead to
> > recursive modules [...]
>
> Why is that? My intuition would say that the exact opposite
> is true: a more fine-grained set of modul
> You can get efficiency, the desired data, and deal with infinite strings by
> using a function that is like 'inits' but which returns the initial strings
> in reversed order.
>
>reversed_inits = scanl (flip (:)) ""
>find (isPrefixOf (reverse "needle")) (reversed_inits "haystack")
If I
> From: Atwood, John Wesley [mailto:[EMAIL PROTECTED]
>
> Under my Linux install, with ghc6.4, it doesn't throw an
> exception, but
> also doesn't return a correct result;
> it returns Just []. Under WindowsXP, ghc6.4, I get the exception you
> get; under hugs, it can't find subRegex, but
> mat
> Date: Wed, 11 May 2005 17:22:25 -0400 (Eastern Standard Time)
> From: "S. Alexander Jacobson" <[EMAIL PROTECTED]>
> Subject: [Haskell-cafe] subRegex bug?
>
> Am I misunderstanding the regex docs?
>
> *MyMod> subRegex (mkRegex "\\." ) "foo.bar" "blah"
> "foo*** Exception: Text.Regex.Posix.regcom
On 2005 May 16 Monday 08:00, Gracjan Polak wrote:
> Ketil Malde wrote:
> > While the result isn't exactly the same, I suspect
> > using isPrefixOf and tails would be more efficient.
>
> I need the data before and including my needle.
When the haystack gets large, the beautiful
find (isSuffixO
> > How would I introduce number classes that are extended with plus and
> > minus infinity? I'd like to have polymorphism over these new classes,
> > something like a signature
> >
> > f :: (Real a, Extended a b) => b -> b
> >
> > which clearly is not part of the current syntax, but I hope you get
Thanks for your opinions everybody!
Ketil Malde writes:
> I guess you could sometimes have name clashes as well?
I was afraid about those for the longest time too, but in
practice name clashes curiously enough hardly ever occur --
in my experience. The problem only arises when you actually
_us
> From: Bulat Ziganshin [mailto:[EMAIL PROTECTED]
>
> if you really need KMP, you can find it at
> http://haskell.org/hawiki/RunTimeCompilation
>
> > find (isSuffixOf "needle") (inits "haystack")
>
> find (isPrefixOf "needle") (tails "haystack")
>
> if you need an index - add it with zip:
>
Hello Gracjan,
Monday, May 16, 2005, 4:00:33 PM, you wrote:
GP> > Unless you have very repetitive data and/or tiny alphabet, it is
GP> > actually quite efficient, as the expected length of prefixes that need
GP> > to be checked before a mismatch can be determined is small.
GP> >
GP> > At leas
19 matches
Mail list logo