Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6854319
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T01:37:06+00:00 2026-05-27T01:37:06+00:00

Why is it that when I do range in Haskell, this works: [LT ..

  • 0

Why is it that when I do range in Haskell, this works:

[LT .. GT]

but this doesn’t:

[LT..GT]

and what does this cryptic error mean:

<interactive>:1:2:
    Failed to load interface for `LT':
      Use -v to see a list of the files searched for.

<interactive>:1:2:
    A section must be enclosed in parentheses thus: (`LT..` GT)

However, When I use Ints, the second form (without spaces) works:

[1..3]
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T01:37:07+00:00Added an answer on May 27, 2026 at 1:37 am

    It’s because LT.. is interpreted as the . operator in the LT module.


    <interactive>:1:2:
        Failed to load interface for `LT':
          Use -v to see a list of the files searched for.
    

    It means GHC cannot find a module named LT. The same message appears if you use a qualified name with a non-existing library:

    Prelude> SDJKASD.sdfhj
    
    <interactive>:1:1:
        Failed to load interface for `SDJKASD':
          Use -v to see a list of the files searched for.
    

    <interactive>:1:2:
        A section must be enclosed in parentheses thus: (`LT..` GT)
    

    In Haskell, a section is an infix operator with a partial application, e.g. (* 3), which is equivalent to \x -> x * 3.

    In your case, LT.. is interpreted as an infix . operator, and the GT is part of the section formed with this operator.

    A section must be enclosed in parenthesis, and since the misinterpretation does not, the parser will complain like this.

    Another example of the error:

    Prelude> [* 3]
    
    <interactive>:1:2:
        A section must be enclosed in parentheses thus: (* 3)
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

With the jQuery datepicker, how does one change the year range that is displayed?
I've got some library code that works on a range of .NET runtimes (regular,
The documentation basically says that range must behave exactly as this implementation (for positive
You are given 2^32-2 unique numbers that range from 1 to 2^32-1. It's impossible
I have a Range variable that contains an address - $2:$2,$4:$205,$214:$214 - (3 groups
I want to enforce CHECK constraint on a date range such that all dates
I have a little one-liner in my Rails app that returns a range of
I am trying to make a web app in Dashcode that uses a range
I have a range of data that I have approximated using a polynomial of
I have a column of data that contains a percentage range as a string

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.