mirror of
https://github.com/GaloisInc/cryptol.git
synced 2024-12-28 18:32:07 +03:00
Don't panic if we fail to resolve a top-level instnatiation
Fixes #1470
This commit is contained in:
parent
c2cda89aa2
commit
18e3563c2c
@ -148,8 +148,7 @@ resolveImports ext def su =
|
||||
|
||||
case tryInstanceMaybe s (ImpTop m) (f,as) of
|
||||
Just (r,newS) -> add m r newS
|
||||
Nothing -> panic "resolveImports"
|
||||
[ "Failed to finish a top-level instantiation" ]
|
||||
Nothing -> (Map.singleton (ImpTop m) forceResolveInst, su)
|
||||
|
||||
where
|
||||
toNest m = Map.fromList [ (ImpNested k, v) | (k,v) <- Map.toList m ]
|
||||
|
1
tests/modsys/functors/T034.cry
Normal file
1
tests/modsys/functors/T034.cry
Normal file
@ -0,0 +1 @@
|
||||
module T034 = submodule X { submodule Y }
|
1
tests/modsys/functors/T034.icry
Normal file
1
tests/modsys/functors/T034.icry
Normal file
@ -0,0 +1 @@
|
||||
:load T034.cry
|
7
tests/modsys/functors/T034.icry.stdout
Normal file
7
tests/modsys/functors/T034.icry.stdout
Normal file
@ -0,0 +1,7 @@
|
||||
Loading module Cryptol
|
||||
Loading module T034
|
||||
|
||||
[error] at T034.cry:1:25--1:26
|
||||
Module not in scope: X
|
||||
[error] at T034.cry:1:39--1:40
|
||||
Module not in scope: Y
|
Loading…
Reference in New Issue
Block a user