Merge pull request #342 from csabahruska/master

add unit test for constructor duplicate
This commit is contained in:
Niklas Larsson 2020-06-25 10:39:25 +02:00 committed by GitHub
commit 8d75d70fac
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 12 additions and 0 deletions

View File

@ -47,6 +47,7 @@ idrisTests
-- Error messages
"error001", "error002", "error003", "error004", "error005",
"error006", "error007", "error008", "error009", "error010",
"error011",
-- Modules and imports
"import001", "import002", "import003", "import004",
-- Interactive editing support

View File

@ -0,0 +1,5 @@
data A = B | B
data C : Type -> Type where
D : C Int
D : C String

View File

@ -0,0 +1,3 @@
1/1: Building ConstructorDuplicate (ConstructorDuplicate.idr)
ConstructorDuplicate.idr:1:14--3:1:Main.B is already defined
ConstructorDuplicate.idr:5:3--5:15:Main.D is already defined

3
tests/idris2/error011/run Executable file
View File

@ -0,0 +1,3 @@
$1 ConstructorDuplicate.idr --check
rm -rf build