mirror of
https://github.com/xmonad/xmonad.git
synced 2025-08-04 14:11:55 -07:00
Use -funbox-strict-fields, rather than UNPACK pragmas. cleaner code.
This commit is contained in:
24
XMonad.hs
24
XMonad.hs
@@ -33,18 +33,20 @@ import qualified Data.Map as M
|
|||||||
-- | XState, the window manager state.
|
-- | XState, the window manager state.
|
||||||
-- Just the display, width, height and a window list
|
-- Just the display, width, height and a window list
|
||||||
data XState = XState
|
data XState = XState
|
||||||
{ display :: Display
|
{ display :: Display
|
||||||
, screen :: {-# UNPACK #-} !ScreenNumber
|
, screen :: !ScreenNumber
|
||||||
, xineScreens :: {-# UNPACK #-} ![Rectangle]
|
|
||||||
|
, xineScreens :: ![Rectangle]
|
||||||
-- a mapping of workspaces to xinerama screen numbers
|
-- a mapping of workspaces to xinerama screen numbers
|
||||||
, wsOnScreen :: {-# UNPACK #-} !(M.Map Int Int)
|
|
||||||
, theRoot :: {-# UNPACK #-} !Window
|
, wsOnScreen :: !(M.Map Int Int)
|
||||||
, wmdelete :: {-# UNPACK #-} !Atom
|
, theRoot :: !Window
|
||||||
, wmprotocols :: {-# UNPACK #-} !Atom
|
, wmdelete :: !Atom
|
||||||
, dimensions :: {-# UNPACK #-} !(Int,Int)
|
, wmprotocols :: !Atom
|
||||||
, workspace :: {-# UNPACK #-} !WorkSpace -- ^ workspace list
|
, dimensions :: !(Int,Int)
|
||||||
, defaultLayoutDesc :: {-# UNPACK #-} !LayoutDesc
|
, workspace :: !WorkSpace -- ^ workspace list
|
||||||
, layoutDescs :: {-# UNPACK #-} !(M.Map Int LayoutDesc)
|
, defaultLayoutDesc :: !LayoutDesc
|
||||||
|
, layoutDescs :: !(M.Map Int LayoutDesc)
|
||||||
-- ^ mapping of workspaces to descriptions of their layouts
|
-- ^ mapping of workspaces to descriptions of their layouts
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -11,6 +11,6 @@ build-depends: base>=1.0, X11>=1.1, X11-extras==0.0, mtl==1.0, unix>=1.0
|
|||||||
|
|
||||||
executable: xmonad
|
executable: xmonad
|
||||||
main-is: Main.hs
|
main-is: Main.hs
|
||||||
ghc-options: -O2 -Wall -optl-Wl,-s
|
ghc-options: -funbox-strict-fields -O2 -Wall -optl-Wl,-s
|
||||||
-- ghc-options: -O2 -Wall -optl-Wl,-s -prof -auto-all
|
-- ghc-options: -O2 -Wall -optl-Wl,-s -prof -auto-all
|
||||||
extensions: GeneralizedNewtypeDeriving
|
extensions: GeneralizedNewtypeDeriving
|
||||||
|
Reference in New Issue
Block a user