Ticket #5545 (closed bug: fixed)

Opened 20 months ago

Last modified 19 months ago

($!) not in scope

Reported by: daniel.is.fischer Owned by: simonmar
Priority: high Milestone: 7.4.1
Component: GHCi Version: 7.2.1
Keywords: Cc:
Operating System: Unknown/Multiple Architecture: Unknown/Multiple
Type of failure: None/Unknown Difficulty:
Test Case: Blocked By:
Blocking: Related Tickets:

Description

When no module is interpreted, ghci doesn't know ($!) anymore:

$ ghci -ignore-dot-ghci
GHCi, version 7.2.1: http://www.haskell.org/ghc/  :? for help
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
Loading package ffi-1.0 ... linking ... done.
Prelude> const 3 $! 5

<interactive>:0:9:
    Not in scope: `$!'
    Perhaps you meant one of these:
      `$' (imported from Prelude), `!!' (imported from Prelude)

The same happens when only compiled modules are loaded, but it's there when there's an interpreted module loaded. The same behaviour is exhibited by HEAD.

Change History

Changed 20 months ago by daniel.is.fischer

Hmm, it's available as Prelude.$!.

Changed 20 months ago by simonpj

  • owner set to simonpj

Deeply strange. I'll look into it.

Changed 19 months ago by simonmar

  • owner changed from simonpj to simonmar
  • priority changed from normal to high
  • milestone set to 7.4.1

I have a fix for this, validating now.

Changed 19 months ago by marlowsd@…

commit 6a342059c19c85a929884453806b1727b526df68

Author: Simon Marlow <marlowsd@gmail.com>
Date:   Tue Oct 18 11:31:53 2011 +0100

    fix value of this_mod passed to tcRnImports (#5545)

 compiler/main/HscMain.lhs        |    7 +++----
 compiler/main/InteractiveEval.hs |    7 +------
 2 files changed, 4 insertions(+), 10 deletions(-)

Changed 19 months ago by simonmar

  • status changed from new to closed
  • resolution set to fixed

Changed 19 months ago by simonpj@…

commit bcd8fdb0301adb78654a5e2794301b38a8fa2a41

Author: Simon Peyton Jones <simonpj@microsoft.com>
Date:   Fri Oct 21 16:41:13 2011 +0100

    A little more refactoring, triggered by the fix to Trac #5545

 compiler/main/HscMain.lhs         |    5 +----
 compiler/main/InteractiveEval.hs  |    8 ++++----
 compiler/typecheck/TcRnDriver.lhs |   11 ++++++++++-
 3 files changed, 15 insertions(+), 9 deletions(-)
Note: See TracTickets for help on using tickets.