@@ -20,7 +20,7 @@ module Data.UUID(UUID
2020 ,toString
2121 ,toStringUpper
2222 ,toStringLower
23− ,generate
23+ ,generate
2424 ,generateRandom
2525 ,generateTime
2626 ,null
@@ -124,20 +124,20 @@ instance Storable UUID where
124124
125125 peek p = do
126126 tl <- peek $ castPtr p
127− tm <- peekByteOff (castPtr p) 4
128− th <- peekByteOff (castPtr p) 6
129− ch <- peekByteOff (castPtr p) 8
130− cl <- peekByteOff (castPtr p) 9
131− node <- peekByteOff (castPtr p) 10
127+ tm <- peekByteOff p 4
128+ th <- peekByteOff p 6
129+ ch <- peekByteOff p 8
130+ cl <- peekByteOff p 9
131+ node <- peekByteOff p 10
132132 return $ UUID tl tm th ch cl node
133133
134134 poke p (UUID tl tm th ch cl node) = do
135135 poke (castPtr p) tl
136− pokeByteOff (castPtr p) 4 tm
137− pokeByteOff (castPtr p) 6 th
138− pokeByteOff (castPtr p) 8 ch
139− pokeByteOff (castPtr p) 9 cl
140− pokeByteOff (castPtr p) 10 node
136+ pokeByteOff p 4 tm
137+ pokeByteOff p 6 th
138+ pokeByteOff p 8 ch
139+ pokeByteOff p 9 cl
140+ pokeByteOff p 10 node
141141
142142instance Storable Node where
143143 sizeOf _ = 6
@@ -145,20 +145,20 @@ instance Storable Node where
145145
146146 peek p = do
147147 w1 <- peek $ castPtr p
148− w2 <- peekByteOff (castPtr p) 1
149− w3 <- peekByteOff (castPtr p) 2
150− w4 <- peekByteOff (castPtr p) 3
151− w5 <- peekByteOff (castPtr p) 4
152− w6 <- peekByteOff (castPtr p) 5
148+ w2 <- peekByteOff p 1
149+ w3 <- peekByteOff p 2
150+ w4 <- peekByteOff p 3
151+ w5 <- peekByteOff p 4
152+ w6 <- peekByteOff p 5
153153 return $ Node w1 w2 w3 w4 w5 w6
154154
155155 poke p (Node w1 w2 w3 w4 w5 w6) = do
156156 poke (castPtr p) w1
157− pokeByteOff (castPtr p) 1 w2
158− pokeByteOff (castPtr p) 2 w3
159− pokeByteOff (castPtr p) 3 w4
160− pokeByteOff (castPtr p) 4 w5
161− pokeByteOff (castPtr p) 5 w6
157+ pokeByteOff p 1 w2
158+ pokeByteOff p 2 w3
159+ pokeByteOff p 3 w4
160+ pokeByteOff p 4 w5
161+ pokeByteOff p 5 w6
162162
163163-- My goal with this instance was to make it work just enough to do what
164164-- I want when used with the HStringTemplate library.