2 % (c) The GRASP/AQUA Project, Glasgow University, 1992-1998
4 \section[RnMonad]{The monad used by the renamer}
10 module RdrName, -- Re-exports
11 module Name, -- from these two
24 #include "HsVersions.h"
26 #if defined(__GLASGOW_HASKELL__) && __GLASGOW_HASKELL__ >= 405
27 import IOExts ( fixIO )
28 #elif defined(__GLASGOW_HASKELL__) && __GLASGOW_HASKELL__ >= 302
29 import PrelIOBase ( fixIO ) -- Should be in GlaExts
31 import IOBase ( fixIO )
33 import IOExts ( IORef, newIORef, readIORef, writeIORef, unsafePerformIO )
37 import RnHsSyn ( RenamedFixitySig, RenamedDeprecation )
38 import BasicTypes ( Version, defaultFixity )
39 import SrcLoc ( noSrcLoc )
40 import ErrUtils ( addShortErrLocLine, addShortWarnLocLine,
41 pprBagOfErrors, ErrMsg, WarnMsg, Message
43 import RdrName ( RdrName, dummyRdrVarName, rdrNameOcc,
44 RdrNameEnv, emptyRdrEnv, extendRdrEnv,
45 lookupRdrEnv, addListToRdrEnv, rdrEnvToList, rdrEnvElts
47 import Name ( Name, OccName, NamedThing(..), getSrcLoc,
48 isLocallyDefinedName, nameModule, nameOccName,
49 decode, mkLocalName, mkUnboundName,
50 NameEnv, lookupNameEnv, emptyNameEnv, unitNameEnv, extendNameEnv,
51 addToNameEnv_C, plusNameEnv_C, nameEnvElts,
52 elemNameEnv, addToNameEnv, addListToNameEnv
54 import Module ( Module, ModuleName, ModuleHiMap, SearchPath, WhereFrom,
55 mkModuleHiMaps, moduleName, mkSearchPath
58 import CmdLineOpts ( opt_D_dump_rn_trace, opt_HiMap )
59 import PrelInfo ( builtinNames )
60 import TysWiredIn ( boolTyCon )
61 import SrcLoc ( SrcLoc, mkGeneratedSrcLoc )
62 import Unique ( Unique, getUnique, unboundKey )
63 import FiniteMap ( FiniteMap, emptyFM, bagToFM, lookupFM, addToFM, addListToFM,
64 addListToFM_C, addToFM_C, eltsFM, fmToList
66 import Bag ( Bag, mapBag, emptyBag, isEmptyBag, snocBag )
67 import Maybes ( mapMaybe )
73 infixr 9 `thenRn`, `thenRn_`
77 %************************************************************************
79 \subsection{Somewhat magical interface to other monads}
81 %************************************************************************
84 ioToRnM :: IO r -> RnM d (Either IOError r)
85 ioToRnM io rn_down g_down = (io >>= \ ok -> return (Right ok))
87 (\ err -> return (Left err))
89 traceRn :: SDoc -> RnM d ()
90 traceRn msg | opt_D_dump_rn_trace = putDocRn msg
91 | otherwise = returnRn ()
93 putDocRn :: SDoc -> RnM d ()
94 putDocRn msg = ioToRnM (printErrs msg) `thenRn_`
99 %************************************************************************
101 \subsection{Data types}
103 %************************************************************************
105 %===================================================
106 \subsubsection{ MONAD TYPES}
107 %===================================================
110 type RnM d r = RnDown -> d -> IO r
111 type RnMS r = RnM SDown r -- Renaming source
112 type RnMG r = RnM () r -- Getting global names etc
115 data RnDown = RnDown {
116 rn_mod :: ModuleName,
118 rn_ns :: IORef RnNameSupply,
119 rn_errs :: IORef (Bag WarnMsg, Bag ErrMsg),
120 rn_ifaces :: IORef Ifaces,
121 rn_hi_maps :: (SearchPath, -- For error messages
122 ModuleHiMap, -- for .hi files
123 ModuleHiMap) -- for .hi-boot files
126 -- For renaming source code
130 rn_genv :: GlobalRdrEnv,
131 -- Global envt; the fixity component gets extended
132 -- with local fixity decls
134 rn_lenv :: LocalRdrEnv, -- Local name envt
135 -- Does *not* include global name envt; may shadow it
136 -- Includes both ordinary variables and type variables;
137 -- they are kept distinct because tyvar have a different
138 -- occurrence contructor (Name.TvOcc)
139 -- We still need the unsullied global name env so that
140 -- we can look up record field names
142 rn_fixenv :: FixityEnv -- Local fixities
143 -- The global fixities are held in the
144 -- rn_ifaces field. Why? See the comments
145 -- with RnIfaces.lookupFixity
148 data RnMode = SourceMode -- Renaming source code
149 | InterfaceMode -- Renaming interface declarations.
152 %===================================================
153 \subsubsection{ ENVIRONMENTS}
154 %===================================================
157 --------------------------------
158 type GlobalRdrEnv = RdrNameEnv [Name] -- The list is because there may be name clashes
159 -- These only get reported on lookup,
160 -- not on construction
161 type LocalRdrEnv = RdrNameEnv Name
163 --------------------------------
164 type FixityEnv = NameEnv RenamedFixitySig
165 -- We keep the whole fixity sig so that we
166 -- can report line-number info when there is a duplicate
167 -- fixity declaration
169 lookupFixity :: FixityEnv -> Name -> Fixity
170 lookupFixity env name
171 = case lookupNameEnv env name of
172 Just (FixitySig _ fix _) -> fix
173 Nothing -> defaultFixity
175 --------------------------------
176 type DeprecationEnv = NameEnv DeprecTxt
180 --------------------------------
184 , FiniteMap String Int
185 -- This is used as a name supply for dictionary functions
186 -- From the inst decl we derive a string, usually by glomming together
187 -- the class and tycon name -- but it doesn't matter exactly how;
188 -- this map then gives a unique int for each inst decl with that
189 -- string. (In Haskell 98 there can only be one,
190 -- but not so in more extended versions; also class CC type T
191 -- and class C type TT might both give the string CCT
193 -- We could just use one Int for all the instance decls, but this
194 -- way the uniques change less when you add an instance decl,
195 -- hence less recompilation
197 , FiniteMap (ModuleName, OccName) Name
198 -- Ensures that one (module,occname) pair gets one unique
199 , FiniteMap OccName Name
200 -- Ensures that one implicit parameter name gets one unique
204 --------------------------------
205 type Avails = [AvailInfo]
207 type ExportAvails = (FiniteMap ModuleName Avails,
208 -- Used to figure out "module M" export specifiers
209 -- Includes avails only from *unqualified* imports
210 -- (see 1.4 Report Section 5.1.1)
212 AvailEnv) -- Used to figure out all other export specifiers.
215 data GenAvailInfo name = Avail name -- An ordinary identifier
216 | AvailTC name -- The name of the type or class
217 [name] -- The available pieces of type/class.
218 -- NB: If the type or class is itself
219 -- to be in scope, it must be in this list.
220 -- Thus, typically: AvailTC Eq [Eq, ==, /=]
222 -- Equality used when deciding if the interface has changed
224 type AvailEnv = NameEnv AvailInfo -- Maps a Name to the AvailInfo that contains it
225 type AvailInfo = GenAvailInfo Name
226 type RdrAvailInfo = GenAvailInfo OccName
229 %===================================================
230 \subsubsection{ INTERFACE FILE STUFF}
231 %===================================================
234 type ExportItem = (ModuleName, [RdrAvailInfo])
236 type ImportVersion name = (ModuleName, WhetherHasOrphans, IsBootInterface, WhatsImported name)
238 type ModVersionInfo = (Version, -- Version of the whole module
239 Version, -- Version number for all fixity decls together
240 Version) -- ...ditto all rules together
242 type WhetherHasOrphans = Bool
244 -- * an instance decl in a module other than the defn module for
245 -- one of the tycons or classes in the instance head
246 -- * a transformation rule in a module other than the one defining
247 -- the function in the head of the rule.
249 type IsBootInterface = Bool
251 data WhatsImported name = NothingAtAll -- The module is below us in the
252 -- hierarchy, but we import nothing
254 | Everything Version -- The module version
256 | Specifically Version -- Module version
257 Version -- Fixity version
258 Version -- Rules version
259 [(name,Version)] -- List guaranteed non-empty
261 -- 'Specifically' doesn't let you say "I imported f but none of the fixities in
262 -- the module. If you use anything in the module you get its fixity and rule version
263 -- So if the fixities or rules change, you'll recompile, even if you don't use either.
264 -- This is easy to implement, and it's safer: you might not have used the rules last
265 -- time round, but if someone has added a new rule you might need it this time
267 -- 'Everything' means there was a "module M" in
268 -- this module's export list, so we just have to go by M's version,
269 -- not the list of (name,version) pairs
273 pi_mod :: Module, -- Complete with package info
274 pi_vers :: Version, -- Module version number
275 pi_orphan :: WhetherHasOrphans, -- Whether this module has orphans
276 pi_usages :: [ImportVersion OccName], -- Usages
277 pi_exports :: [ExportItem], -- Exports
278 pi_insts :: [RdrNameInstDecl], -- Local instance declarations
279 pi_decls :: [(Version, RdrNameHsDecl)], -- Local definitions
280 pi_fixity :: (Version, [RdrNameFixitySig]), -- Local fixity declarations, with their version
281 pi_rules :: (Version, [RdrNameRuleDecl]), -- Rules, with their version
282 pi_deprecs :: [RdrNameDeprecation] -- Deprecations
286 type RdrNamePragma = () -- Fudge for now
289 data Ifaces = Ifaces {
290 iImpModInfo :: ImportedModuleInfo,
291 -- Modules this one depends on: that is, the union
292 -- of the modules its *direct* imports depend on.
293 -- NB: The direct imports have .hi files that enumerate *all* the
294 -- dependencies (direct or not) of the imported module.
296 iDecls :: DeclsMap, -- A single, global map of Names to decls
298 iDeferred :: NameSet, -- data (not newtype) TyCons that have been slurped,
299 -- but none of their constructors have.
300 -- If this is still the case right at the end
301 -- we can get away with importing them abstractly
304 -- A single, global map of Names to fixities
305 -- See comments with RnIfaces.lookupFixity
308 -- All the names (whether "big" or "small", whether wired-in or not,
309 -- whether locally defined or not) that have been slurped in so far.
311 iVSlurp :: [(Name,Version)],
312 -- All the (a) non-wired-in (b) "big" (c) non-locally-defined
313 -- names that have been slurped in so far, with their versions.
314 -- This is used to generate the "usage" information for this module.
315 -- Subset of the previous field.
317 iInsts :: IfaceInsts,
318 -- The as-yet un-slurped instance decls; this bag is depleted when we
319 -- slurp an instance decl so that we don't slurp the same one twice.
320 -- Each is 'gated' by the names that must be available before
321 -- this instance decl is needed.
323 iRules :: IfaceRules,
324 -- Similar to instance decls, only for rules
326 iDeprecs :: DeprecationEnv
329 type IfaceInsts = Bag GatedDecl
330 type IfaceRules = Bag GatedDecl
332 type GatedDecl = (NameSet, (Module, RdrNameHsDecl))
334 type ImportedModuleInfo
335 = FiniteMap ModuleName (WhetherHasOrphans, IsBootInterface,
336 Maybe (Module, Version, Version, Version, WhereFrom, Avails))
337 -- The three Versions are module version, fixity version, rules version
339 -- Suppose the domain element is module 'A'
341 -- The first Bool is True if A contains
342 -- 'orphan' rules or instance decls
344 -- The second Bool is true if the interface file actually
345 -- read was an .hi-boot file
347 -- Nothing => A's interface not yet read, but this module has
348 -- imported a module, B, that itself depends on A
350 -- Just xx => A's interface has been read. The Module in
351 -- the Just has the correct Dll flag
353 -- This set is used to decide whether to look for
354 -- A.hi or A.hi-boot when importing A.f.
355 -- Basically, we look for A.hi if A is in the map, and A.hi-boot
358 type DeclsMap = NameEnv (Version, AvailInfo, Bool, (Module, RdrNameHsDecl))
359 -- A DeclsMap contains a binding for each Name in the declaration
360 -- including the constructors of a type decl etc.
361 -- The Bool is True just for the 'main' Name.
365 %************************************************************************
367 \subsection{Main monad code}
369 %************************************************************************
372 initRn :: ModuleName -> UniqSupply -> SearchPath -> SrcLoc
374 -> IO (r, Bag ErrMsg, Bag WarnMsg)
376 initRn mod us dirs loc do_rn = do
377 himaps <- mkModuleHiMaps dirs
378 names_var <- newIORef (us, emptyFM, builtins, emptyFM)
379 errs_var <- newIORef (emptyBag,emptyBag)
380 iface_var <- newIORef emptyIfaces
382 rn_down = RnDown { rn_loc = loc, rn_ns = names_var,
385 rn_ifaces = iface_var,
389 res <- do_rn rn_down ()
391 -- grab errors and return
392 (warns, errs) <- readIORef errs_var
394 return (res, errs, warns)
397 initRnMS :: GlobalRdrEnv -> FixityEnv -> RnMode -> RnMS r -> RnM d r
398 initRnMS rn_env fixity_env mode thing_inside rn_down g_down
400 s_down = SDown { rn_genv = rn_env, rn_lenv = emptyRdrEnv,
401 rn_fixenv = fixity_env, rn_mode = mode }
403 thing_inside rn_down s_down
405 initIfaceRnMS :: Module -> RnMS r -> RnM d r
406 initIfaceRnMS mod thing_inside
407 = initRnMS emptyRdrEnv emptyNameEnv InterfaceMode $
408 setModuleRn (moduleName mod) thing_inside
410 emptyIfaces :: Ifaces
411 emptyIfaces = Ifaces { iImpModInfo = emptyFM,
412 iDecls = emptyNameEnv,
413 iDeferred = emptyNameSet,
414 iFixes = emptyNameEnv,
415 iSlurp = unitNameSet (mkUnboundName dummyRdrVarName),
416 -- Pretend that the dummy unbound name has already been
417 -- slurped. This is what's returned for an out-of-scope name,
418 -- and we don't want thereby to try to suck it in!
422 iDeprecs = emptyNameEnv
425 builtins :: FiniteMap (ModuleName,OccName) Name
428 mapBag (\ name -> ((moduleName (nameModule name), nameOccName name), name))
432 @renameSourceCode@ is used to rename stuff ``out-of-line'';
433 that is, not as part of the main renamer.
434 Sole examples: derived definitions,
435 which are only generated in the type checker.
437 The @RnNameSupply@ includes a @UniqueSupply@, so if you call it more than
438 once you must either split it, or install a fresh unique supply.
441 renameSourceCode :: ModuleName
446 renameSourceCode mod_name name_supply m
448 -- It's not really unsafe! When renaming source code we
449 -- only do any I/O if we need to read in a fixity declaration;
450 -- and that doesn't happen in pragmas etc
452 mkModuleHiMaps (mkSearchPath opt_HiMap) >>= \ himaps ->
453 newIORef name_supply >>= \ names_var ->
454 newIORef (emptyBag,emptyBag) >>= \ errs_var ->
456 rn_down = RnDown { rn_loc = mkGeneratedSrcLoc, rn_ns = names_var,
457 rn_errs = errs_var, rn_hi_maps = himaps,
459 rn_ifaces = panic "rnameSourceCode: rn_ifaces" -- Not required
461 s_down = SDown { rn_mode = InterfaceMode,
462 -- So that we can refer to PrelBase.True etc
463 rn_genv = emptyRdrEnv, rn_lenv = emptyRdrEnv,
464 rn_fixenv = emptyNameEnv }
466 m rn_down s_down >>= \ result ->
468 readIORef errs_var >>= \ (warns,errs) ->
470 (if not (isEmptyBag errs) then
471 pprTrace "Urk! renameSourceCode found errors" (display errs)
473 else if not (isEmptyBag warns) then
474 pprTrace "Note: renameSourceCode found warnings" (display warns)
482 display errs = pprBagOfErrors errs
484 {-# INLINE thenRn #-}
485 {-# INLINE thenRn_ #-}
486 {-# INLINE returnRn #-}
489 returnRn :: a -> RnM d a
490 thenRn :: RnM d a -> (a -> RnM d b) -> RnM d b
491 thenRn_ :: RnM d a -> RnM d b -> RnM d b
492 andRn :: (a -> a -> a) -> RnM d a -> RnM d a -> RnM d a
493 mapRn :: (a -> RnM d b) -> [a] -> RnM d [b]
494 mapRn_ :: (a -> RnM d b) -> [a] -> RnM d ()
495 mapMaybeRn :: (a -> RnM d (Maybe b)) -> [a] -> RnM d [b]
496 flatMapRn :: (a -> RnM d [b]) -> [a] -> RnM d [b]
497 sequenceRn :: [RnM d a] -> RnM d [a]
498 foldlRn :: (b -> a -> RnM d b) -> b -> [a] -> RnM d b
499 mapAndUnzipRn :: (a -> RnM d (b,c)) -> [a] -> RnM d ([b],[c])
500 fixRn :: (a -> RnM d a) -> RnM d a
502 returnRn v gdown ldown = return v
503 thenRn m k gdown ldown = m gdown ldown >>= \ r -> k r gdown ldown
504 thenRn_ m k gdown ldown = m gdown ldown >> k gdown ldown
505 fixRn m gdown ldown = fixIO (\r -> m r gdown ldown)
506 andRn combiner m1 m2 gdown ldown
507 = m1 gdown ldown >>= \ res1 ->
508 m2 gdown ldown >>= \ res2 ->
509 return (combiner res1 res2)
511 sequenceRn [] = returnRn []
512 sequenceRn (m:ms) = m `thenRn` \ r ->
513 sequenceRn ms `thenRn` \ rs ->
516 mapRn f [] = returnRn []
518 = f x `thenRn` \ r ->
519 mapRn f xs `thenRn` \ rs ->
522 mapRn_ f [] = returnRn ()
527 foldlRn k z [] = returnRn z
528 foldlRn k z (x:xs) = k z x `thenRn` \ z' ->
531 mapAndUnzipRn f [] = returnRn ([],[])
532 mapAndUnzipRn f (x:xs)
533 = f x `thenRn` \ (r1, r2) ->
534 mapAndUnzipRn f xs `thenRn` \ (rs1, rs2) ->
535 returnRn (r1:rs1, r2:rs2)
537 mapAndUnzip3Rn f [] = returnRn ([],[],[])
538 mapAndUnzip3Rn f (x:xs)
539 = f x `thenRn` \ (r1, r2, r3) ->
540 mapAndUnzip3Rn f xs `thenRn` \ (rs1, rs2, rs3) ->
541 returnRn (r1:rs1, r2:rs2, r3:rs3)
543 mapMaybeRn f [] = returnRn []
544 mapMaybeRn f (x:xs) = f x `thenRn` \ maybe_r ->
545 mapMaybeRn f xs `thenRn` \ rs ->
547 Nothing -> returnRn rs
548 Just r -> returnRn (r:rs)
550 flatMapRn f [] = returnRn []
551 flatMapRn f (x:xs) = f x `thenRn` \ r ->
552 flatMapRn f xs `thenRn` \ rs ->
558 %************************************************************************
560 \subsection{Boring plumbing for common part}
562 %************************************************************************
566 \subsubsection{ Errors and warnings}
567 %=====================
570 failWithRn :: a -> Message -> RnM d a
571 failWithRn res msg (RnDown {rn_errs = errs_var, rn_loc = loc}) l_down
572 = readIORef errs_var >>= \ (warns,errs) ->
573 writeIORef errs_var (warns, errs `snocBag` err) >>
576 err = addShortErrLocLine loc msg
578 warnWithRn :: a -> Message -> RnM d a
579 warnWithRn res msg (RnDown {rn_errs = errs_var, rn_loc = loc}) l_down
580 = readIORef errs_var >>= \ (warns,errs) ->
581 writeIORef errs_var (warns `snocBag` warn, errs) >>
584 warn = addShortWarnLocLine loc msg
586 addErrRn :: Message -> RnM d ()
587 addErrRn err = failWithRn () err
589 checkRn :: Bool -> Message -> RnM d () -- Check that a condition is true
590 checkRn False err = addErrRn err
591 checkRn True err = returnRn ()
593 warnCheckRn :: Bool -> Message -> RnM d () -- Check that a condition is true
594 warnCheckRn False err = addWarnRn err
595 warnCheckRn True err = returnRn ()
597 addWarnRn :: Message -> RnM d ()
598 addWarnRn warn = warnWithRn () warn
600 checkErrsRn :: RnM d Bool -- True <=> no errors so far
601 checkErrsRn (RnDown {rn_errs = errs_var}) l_down
602 = readIORef errs_var >>= \ (warns,errs) ->
603 return (isEmptyBag errs)
608 \subsubsection{ Source location}
609 %=====================
612 pushSrcLocRn :: SrcLoc -> RnM d a -> RnM d a
613 pushSrcLocRn loc' m down l_down
614 = m (down {rn_loc = loc'}) l_down
616 getSrcLocRn :: RnM d SrcLoc
617 getSrcLocRn down l_down
618 = return (rn_loc down)
622 \subsubsection{ Name supply}
623 %=====================
626 getNameSupplyRn :: RnM d RnNameSupply
627 getNameSupplyRn rn_down l_down
628 = readIORef (rn_ns rn_down)
630 setNameSupplyRn :: RnNameSupply -> RnM d ()
631 setNameSupplyRn names' (RnDown {rn_ns = names_var}) l_down
632 = writeIORef names_var names'
634 -- See comments with RnNameSupply above.
635 newInstUniq :: String -> RnM d Int
636 newInstUniq key (RnDown {rn_ns = names_var}) l_down
637 = readIORef names_var >>= \ (us, mapInst, cache, ipcache) ->
639 uniq = case lookupFM mapInst key of
642 mapInst' = addToFM mapInst key uniq
644 writeIORef names_var (us, mapInst', cache, ipcache) >>
647 getUniqRn :: RnM d Unique
648 getUniqRn (RnDown {rn_ns = names_var}) l_down
649 = readIORef names_var >>= \ (us, mapInst, cache, ipcache) ->
651 (us1,us') = splitUniqSupply us
653 writeIORef names_var (us', mapInst, cache, ipcache) >>
654 return (uniqFromSupply us1)
658 \subsubsection{ Module}
659 %=====================
662 getModuleRn :: RnM d ModuleName
663 getModuleRn (RnDown {rn_mod = mod_name}) l_down
666 setModuleRn :: ModuleName -> RnM d a -> RnM d a
667 setModuleRn new_mod enclosed_thing rn_down l_down
668 = enclosed_thing (rn_down {rn_mod = new_mod}) l_down
672 %************************************************************************
674 \subsection{Plumbing for rename-source part}
676 %************************************************************************
679 \subsubsection{ RnEnv}
680 %=====================
683 getNameEnvs :: RnMS (GlobalRdrEnv, LocalRdrEnv)
684 getNameEnvs rn_down (SDown {rn_genv = global_env, rn_lenv = local_env})
685 = return (global_env, local_env)
687 getLocalNameEnv :: RnMS LocalRdrEnv
688 getLocalNameEnv rn_down (SDown {rn_lenv = local_env})
691 setLocalNameEnv :: LocalRdrEnv -> RnMS a -> RnMS a
692 setLocalNameEnv local_env' m rn_down l_down
693 = m rn_down (l_down {rn_lenv = local_env'})
695 getFixityEnv :: RnMS FixityEnv
696 getFixityEnv rn_down (SDown {rn_fixenv = fixity_env})
699 extendFixityEnv :: [(Name, RenamedFixitySig)] -> RnMS a -> RnMS a
700 extendFixityEnv fixes enclosed_scope
701 rn_down l_down@(SDown {rn_fixenv = fixity_env})
703 new_fixity_env = extendNameEnv fixity_env fixes
705 enclosed_scope rn_down (l_down {rn_fixenv = new_fixity_env})
709 \subsubsection{ Mode}
710 %=====================
713 getModeRn :: RnMS RnMode
714 getModeRn rn_down (SDown {rn_mode = mode})
717 setModeRn :: RnMode -> RnMS a -> RnMS a
718 setModeRn new_mode thing_inside rn_down l_down
719 = thing_inside rn_down (l_down {rn_mode = new_mode})
723 %************************************************************************
725 \subsection{Plumbing for rename-globals part}
727 %************************************************************************
730 getIfacesRn :: RnM d Ifaces
731 getIfacesRn (RnDown {rn_ifaces = iface_var}) _
732 = readIORef iface_var
734 setIfacesRn :: Ifaces -> RnM d ()
735 setIfacesRn ifaces (RnDown {rn_ifaces = iface_var}) _
736 = writeIORef iface_var ifaces
738 getHiMaps :: RnM d (SearchPath, ModuleHiMap, ModuleHiMap)
739 getHiMaps (RnDown {rn_hi_maps = himaps}) _