Ticket #1125 (closed defect: duplicate)

Opened 9 years ago

Last modified 9 years ago

drawWindowGetPointer raises "NonExhaustivePattern" or something...

Reported by: guest Owned by: somebody
Priority: normal Milestone:
Component: general (Gtk+, Glib) Version: 0.9.12
Keywords: drawWindowGetPointer, non exhaustive pattern Cc: dignor.sign@…


..when called inside a callback for onScroll... anyways in Events.hsc there is that little function "toModifier" which is used for everything else and that works. It have a nice comment:

-- Turn an int into a modifier.
-- * Use instead of (toFlags . fromIntegral) since the latter will fail
--   if flags are set for which no constructor exists

which is exactly what gets done in DrawWindow.hsc.pp, and then the error. I would gladly post a patch, but I'm not very skilled on making patches. The obvious fix however worked for me:

  • Export toModifier in the Events module
  • import it in DrawWindow
  • change (toEnum (fromIntegral m) ) by toModifier (... m). The three dots represents my ugly hack for converting a Word to a CInt.

Change History

Changed 9 years ago by axel

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

Duplicate of #1126.

Changed 9 years ago by Alvaro


Auntie Em:

Hate you. Hate Kansas. Taking the dog.


viagra compra online buy fioricet cialis generico acquisto on line farmacia svizzera how to buy tramadol

Note: See TracTickets for help on using tickets.