[Git][ghc/ghc][wip/marge_bot_batch_merge_job] 3 commits: haddock: Add a .readthedocs.yml file for online documentation
Marge Bot (@marge-bot)
gitlab at gitlab.haskell.org
Sun May 19 22:18:57 UTC 2024
Marge Bot pushed to branch wip/marge_bot_batch_merge_job at Glasgow Haskell Compiler / GHC
Commits:
64459a3e by Hécate Moonlight at 2024-05-19T08:42:27-04:00
haddock: Add a .readthedocs.yml file for online documentation
- - - - -
7d3d9bbf by Serge S. Gulin at 2024-05-19T18:47:05+00:00
Unicode: General Category size test (related #24789)
Added trivial size performance test which involves unicode general category usage via `read`.
The `read` itself uses general category to detect spaces.
The purpose for this test is to measure outcome of applying improvements at General Category representation in code discussed at #24789.
- - - - -
bd710564 by Alan Zimmerman at 2024-05-19T18:18:52-04:00
EPA: Remove redundant code
Remove unused
epAnnAnns function
various cases for showAstData that no longer exist
- - - - -
5 changed files:
- compiler/GHC/Hs/Dump.hs
- compiler/GHC/Parser/Annotation.hs
- testsuite/tests/perf/size/all.T
- + testsuite/tests/perf/size/size_hello_unicode.hs
- + utils/haddock/.readthedocs.yaml
Changes:
=====================================
compiler/GHC/Hs/Dump.hs
=====================================
@@ -59,16 +59,10 @@ showAstData bs ba a0 = blankLine $$ showAstData' a0
`ext1Q` list
`extQ` list_addEpAnn
`extQ` string `extQ` fastString `extQ` srcSpan `extQ` realSrcSpan
- `extQ` annotation
`extQ` annotationModule
- `extQ` annotationAddEpAnn
`extQ` annotationGrhsAnn
- `extQ` annotationEpAnnHsCase
`extQ` annotationAnnList
`extQ` annotationEpAnnImportDecl
- `extQ` annotationAnnParen
- `extQ` annotationTrailingAnn
- `extQ` annotationEpaLocation
`extQ` annotationNoEpAnns
`extQ` addEpAnn
`extQ` annParen
@@ -235,36 +229,18 @@ showAstData bs ba a0 = blankLine $$ showAstData' a0
-- -------------------------
- annotation :: EpAnn [AddEpAnn] -> SDoc
- annotation = annotation' (text "EpAnn [AddEpAnn]")
-
annotationModule :: EpAnn AnnsModule -> SDoc
annotationModule = annotation' (text "EpAnn AnnsModule")
- annotationAddEpAnn :: EpAnn AddEpAnn -> SDoc
- annotationAddEpAnn = annotation' (text "EpAnn AddEpAnn")
-
annotationGrhsAnn :: EpAnn GrhsAnn -> SDoc
annotationGrhsAnn = annotation' (text "EpAnn GrhsAnn")
- annotationEpAnnHsCase :: EpAnn EpAnnHsCase -> SDoc
- annotationEpAnnHsCase = annotation' (text "EpAnn EpAnnHsCase")
-
annotationAnnList :: EpAnn AnnList -> SDoc
annotationAnnList = annotation' (text "EpAnn AnnList")
annotationEpAnnImportDecl :: EpAnn EpAnnImportDecl -> SDoc
annotationEpAnnImportDecl = annotation' (text "EpAnn EpAnnImportDecl")
- annotationAnnParen :: EpAnn AnnParen -> SDoc
- annotationAnnParen = annotation' (text "EpAnn AnnParen")
-
- annotationTrailingAnn :: EpAnn TrailingAnn -> SDoc
- annotationTrailingAnn = annotation' (text "EpAnn TrailingAnn")
-
- annotationEpaLocation :: EpAnn EpaLocation -> SDoc
- annotationEpaLocation = annotation' (text "EpAnn EpaLocation")
-
annotationNoEpAnns :: EpAnn NoEpAnns -> SDoc
annotationNoEpAnns = annotation' (text "EpAnn NoEpAnns")
=====================================
compiler/GHC/Parser/Annotation.hs
=====================================
@@ -70,7 +70,6 @@ module GHC.Parser.Annotation (
-- ** Querying annotations
getLocAnn,
- epAnnAnns,
annParen2AddEpAnn,
epAnnComments,
@@ -1139,9 +1138,6 @@ widenLocatedAn (EpAnn (EpaSpan l) a cs) as = EpAnn (spanAsAnchor l') a cs
l' = widenSpan l as
widenLocatedAn (EpAnn anc a cs) _as = EpAnn anc a cs
-epAnnAnns :: EpAnn [AddEpAnn] -> [AddEpAnn]
-epAnnAnns (EpAnn _ anns _) = anns
-
annParen2AddEpAnn :: AnnParen -> [AddEpAnn]
annParen2AddEpAnn (AnnParen pt o c)
= [AddEpAnn ai o, AddEpAnn ac c]
=====================================
testsuite/tests/perf/size/all.T
=====================================
@@ -3,6 +3,8 @@ test('size_hello_obj', [collect_size(5, 'size_hello_obj.o')], compile, [''])
test('size_hello_artifact', [collect_size(5, 'size_hello_artifact' + exe_extension())],
compile_artifact, [''])
+test('size_hello_unicode', [collect_size(5, 'size_hello_unicode' + exe_extension())], compile_artifact, [''])
+
size_acceptance_threshold = 100
test('array_dir' ,[collect_size_ghc_pkg(size_acceptance_threshold , 'array')] , static_stats , [] )
=====================================
testsuite/tests/perf/size/size_hello_unicode.hs
=====================================
@@ -0,0 +1,5 @@
+-- same as size_hello_artifact but we test the size of the resulting executable with unicode general category involved.
+module Main where
+
+-- read uses unicode general category to detect spaces
+main = print (read @Int "1337")
=====================================
utils/haddock/.readthedocs.yaml
=====================================
@@ -0,0 +1,14 @@
+# Documentation lives at https://haskell-haddock.readthedocs.io/latest/
+version: 2
+
+sphinx:
+ configuration: doc/conf.py
+
+build:
+ os: "ubuntu-22.04"
+ tools:
+ python: "3.8"
+
+python:
+ install:
+ - requirements: doc/requirements.txt
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/c076c449745947b7a066c16e11599af44abd72d7...bd7105642c2b8ef401a3f4bb0a8e540c4cf2053c
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/c076c449745947b7a066c16e11599af44abd72d7...bd7105642c2b8ef401a3f4bb0a8e540c4cf2053c
You're receiving this email because of your account on gitlab.haskell.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20240519/f37c6bb7/attachment-0001.html>
More information about the ghc-commits
mailing list