Skip to main content

All Questions

1 vote
2 answers
110 views

understand haskell logic behind odd's and even's index lists

I had a question in haskell that asks a function to divide a list in two different lists so the even indexs filled a list and the odd ones another. Example: func :: [Int] -> ([Int], [Int]) Then, ...
Gabriel Monteiro Silva's user avatar
1 vote
0 answers
170 views

What is wrong with my "token type" in Happy?

I am writing a simple arithmetic expression parser in the Haskell platform's Happy. The Happy tutorial (labeled "Documentation") from the Haskell site implements a similar grammar to what I ...
nau5ea's user avatar
  • 13
1 vote
1 answer
487 views

Failed to build Distribution.Simple package using stack in Haskell

the stack command stack new my-project creates a auto-generated file Setup.hs with contents: import Distribution.Simple main = defaultMain but my vs code intellisense just tells me Could not load ...
Mark Peter's user avatar
5 votes
0 answers
2k views

cabal version 3.2: unrecognised command: sandbox (try --help)

Following this tutorial http://wiki.haskell.org/How_to_write_a_Haskell_program#Recommended_tools but not able to run cabal sandbox init. I have the latest version of cabal installed on my Mac and ...
user3226932's user avatar
  • 2,272
3 votes
2 answers
596 views

Can standalone Haskell Executable run across Machine having the same OS?

NOTE: I am using Stack. When we do (say on a CentOS machine) stack install --ghc-options='-optl-static -optl-pthread' --force-dirty --local-bin-path path-to-executable(my-project-exe) Can the newly ...
Ishan Sharma's user avatar
1 vote
1 answer
237 views

When I tried to compile a Haskell file , error:parse error on input '#'

I was learning how to use this SDK from https://github.com/spaceships/garbled-circuits When I finished downloading the dependencies and tried to compile one example, the error was like parse error on ...
Rookie's user avatar
  • 11
2 votes
2 answers
3k views

How to get the current UTC time in Haskell?

i want to use system time in my code for having the record of time when the data is captured from the user interface.how to get system time using Haskell.
Logical Thinker's user avatar
-1 votes
1 answer
202 views

Haskell. Implement a function that takes a string as input and expands its compressed representation

Implement a function (myData2Fun) that takes a string as input and expands its compressed representation according to the rules for encoding series lengths. The essence of compression is that ...
Yaroslav's user avatar
1 vote
1 answer
2k views

Haskell error - 'parse error on input `->'

I am trying to declare a function in Haskell GHCi as fact :: Int -> Int But I am getting this error - error: parse error on input `->' I do not understand why this is happening. Can anyone ...
orbitze's user avatar
  • 11
4 votes
1 answer
796 views

Undefined symbols for architecture x86_64: "_utimensat", referenced from: _cazW_info in libHSdirectory-1.3.3.0.a(Posix.o)

I'm trying to install haskell-ide-engine. Below are the commands git clone https://github.com/haskell/haskell-ide-engine --recursive cd haskell-ide-engine ./install.hs build-all The last command ./...
user51's user avatar
  • 10.3k
0 votes
1 answer
304 views

Basic question on executing multiple commands in Haskell

I have the following on my code: where launch :: MonadIO m => m (Maybe Text) launch = do line <- launchLine return $ lineToText <$> line launchLine :: ...
user1858059's user avatar
1 vote
1 answer
260 views

How does haskell-platform use Stack?

The page: https://www.haskell.org/platform/ claims that haskell-platform comes with the Stack tool. However, on my Debian system after installing the haskell-platform package, I do not have the ...
Cameron Ball's user avatar
  • 4,128
4 votes
1 answer
1k views

Stack always downloads ghc even though it is in path

I want to use Haskell on my computer currently running Windows 10 build 1803, and I am using a broadband connection of 25 Mbps. As of 2018, the Haskell compiler version known as ghc is 8.4.3. First ...
suraj Mandal's user avatar
2 votes
1 answer
1k views

Installing and running a haskell package offline

I'm trying to run duckling (https://github.com/facebook/duckling) on a Windows server. Unfortunately, the server only has intranet access and no internet access. How do I set up Haskell to be able ...
atotalnoob's user avatar
25 votes
2 answers
12k views

How to install Haskell (Platform or Stack) in 2018 on Linux?

I am trying to learn Haskell from the book Learn You a Haskell by Miran Lipovača. Both the book and haskell.org recommends installing the Haskell Platform but there is no download for Manjaro Linux (...
Klorax's user avatar
  • 579

15 30 50 per page