diff options
| author | pepeiborra@gmail.com <unknown> | 2010-12-03 20:23:46 +0000 |
|---|---|---|
| committer | pepeiborra@gmail.com <unknown> | 2010-12-03 20:23:46 +0000 |
| commit | 3f82c82ad95fa95cf0ce3a787c934bcccd2c23c4 (patch) | |
| tree | f004855a0660cc40ddb037e70671c7d74a961aa4 /compiler | |
| parent | b633499b3a9508fce26b622f2d0cd836290e9503 (diff) | |
| download | haskell-3f82c82ad95fa95cf0ce3a787c934bcccd2c23c4.tar.gz | |
Fix the behaviour of :history for ticks surrounding top level functions
Diffstat (limited to 'compiler')
| -rw-r--r-- | compiler/deSugar/Coverage.lhs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/compiler/deSugar/Coverage.lhs b/compiler/deSugar/Coverage.lhs index 2d8afbd7ad..72c9e664f3 100644 --- a/compiler/deSugar/Coverage.lhs +++ b/compiler/deSugar/Coverage.lhs @@ -691,7 +691,10 @@ allocATickBox :: BoxLabel -> SrcSpan -> FreeVars -> TM (Maybe (Int,[Id])) allocATickBox boxLabel pos fvs | isGoodSrcSpan' pos = sameFileName pos (return Nothing) $ TM $ \ env st -> - let me = (pos, declPath env, map (nameOccName.idName) ids, boxLabel) + let mydecl_path + | null (declPath env), TopLevelBox x <- boxLabel = x + | otherwise = declPath env + me = (pos, mydecl_path, map (nameOccName.idName) ids, boxLabel) c = tickBoxCount st mes = mixEntries st ids = occEnvElts fvs |
