diff options
author | Ömer Sinan Ağacan <omeragacan@gmail.com> | 2020-02-28 09:52:04 +0300 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2020-02-29 05:12:06 -0500 |
commit | 04d30137771a6cf8a18fda1ced25f78d0b2eb204 (patch) | |
tree | a69c36e0827b1374d3cb66bafd518a2c54df0876 /testsuite | |
parent | 34c7d23074f47c720b5722ca14d78a34213eabb6 (diff) | |
download | haskell-04d30137771a6cf8a18fda1ced25f78d0b2eb204.tar.gz |
Simplify IfaceIdInfo type
IfaceIdInfo type is confusing: there's practically no difference between
`NoInfo` and `HasInfo []`. The comments say NoInfo is used when
-fomit-interface-pragmas is enabled, but we don't need to distinguish
`NoInfo` from `HasInfo []` in when reading the interface so the
distinction is not important.
This patch simplifies the type by removing NoInfo. When we have no info
we use an empty list.
With this change we no longer read the info list lazily when reading an
IfaceInfoItem, but when reading an IfaceId the ifIdInfo field is
read lazily, so I doubt this is going to be a problem.
Diffstat (limited to 'testsuite')
-rw-r--r-- | testsuite/tests/codeGen/should_compile/Makefile | 4 | ||||
-rw-r--r-- | testsuite/tests/simplCore/should_compile/T4201.stdout | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/testsuite/tests/codeGen/should_compile/Makefile b/testsuite/tests/codeGen/should_compile/Makefile index 203111f55e..45d1b605a0 100644 --- a/testsuite/tests/codeGen/should_compile/Makefile +++ b/testsuite/tests/codeGen/should_compile/Makefile @@ -64,10 +64,10 @@ T17648: # NoCafRefs) to the interface files. '$(TEST_HC)' $(TEST_HC_OPTS) -dno-typeable-binds -O T17648.hs -v0 '$(TEST_HC)' --show-iface T17648.hi | tr -d '\n' | \ - grep -F 'f :: T GHC.Types.Int -> () {- HasNoCafRefs, Arity' >/dev/null + grep -F 'f :: T GHC.Types.Int -> () [HasNoCafRefs, Arity' >/dev/null # Second compilation with -fcatch-bottoms, f should be CAFFY '$(TEST_HC)' $(TEST_HC_OPTS) -dno-typeable-binds -O \ -fcatch-bottoms T17648.hs -v0 -fforce-recomp '$(TEST_HC)' --show-iface T17648.hi | tr -d '\n' | \ - grep -F 'f :: T GHC.Types.Int -> () {- Arity: 1, Strictness' >/dev/null + grep -F 'f :: T GHC.Types.Int -> () [Arity: 1, Strictness' >/dev/null diff --git a/testsuite/tests/simplCore/should_compile/T4201.stdout b/testsuite/tests/simplCore/should_compile/T4201.stdout index 0ee2f5c7e9..e12c9f1584 100644 --- a/testsuite/tests/simplCore/should_compile/T4201.stdout +++ b/testsuite/tests/simplCore/should_compile/T4201.stdout @@ -1,3 +1,3 @@ - {- HasNoCafRefs, Arity: 1, Strictness: <S,1*H>, CPR: m1, - Unfolding: InlineRule (0, True, True) - bof `cast` (Sym (N:Foo[0]) ->_R <T>_R) -} + [HasNoCafRefs, Arity: 1, Strictness: <S,1*H>, CPR: m1, + Unfolding: InlineRule (0, True, True) + bof `cast` (Sym (N:Foo[0]) ->_R <T>_R)] |