Opened 11 years ago

Closed 11 years ago

Last modified 9 years ago

#883 closed bug (worksforme)

cannot use (!) as an infix operator

Reported by: aotani@… Owned by:
Priority: normal Milestone: 6.6
Component: Compiler Version: 6.5
Keywords: Cc:
Operating System: Unknown/Multiple Architecture: Unknown/Multiple
Type of failure: None/Unknown Test Case:
Blocked By: Blocking:
Related Tickets: Differential Rev(s):
Wiki Page:


When I tried to compile following code with ghc-6.5.20060830,

{-# INLINE (!) #-}
-- | Returns the element of an immutable array at the specified index.
(!) :: (IArray a e, Ix i) => a i e -> i -> e
arr ! i = case bounds arr of (l,u) -> unsafeAt arr (index (l,u) i)

I got error messages below

Data/ArrayBZ/Internals/IArray.hs:109:11: Not in scope: `!'
Data/ArrayBZ/Internals/IArray.hs:111:0: Not in scope: `!'
Data/ArrayBZ/Internals/IArray.hs:201:49: Not in scope: `!'

The above code is a part of ArrayRef library written by Bulat Ziganshin.

Change History (4)

comment:1 Changed 11 years ago by aotani@…

Resolution: worksforme
Status: newclosed

This problem is not occured when compiling with ghc-6.5.20060831. Sorry for my annoying report.

comment:2 Changed 11 years ago by simonpj

Actually, there was a missing case in -fbang-patterns, which I have now fixed. So it was a useful report.


comment:3 Changed 9 years ago by simonmar

Architecture: UnknownUnknown/Multiple

comment:4 Changed 9 years ago by simonmar

Operating System: UnknownUnknown/Multiple
Note: See TracTickets for help on using tickets.