fix #5683
This commit is contained in:
parent
8de19a7f4c
commit
d578815963
3 changed files with 25 additions and 6 deletions
15
tests/generics/t5683.nim
Normal file
15
tests/generics/t5683.nim
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
discard """
|
||||
output: "perm: 22 det: 22"
|
||||
"""
|
||||
|
||||
type Matrix[M,N: static[int]] = array[M, array[N, float]]
|
||||
|
||||
proc det[M,N](a: Matrix[M,N]): int = N*10 + M
|
||||
proc perm[M,N](a: Matrix[M,N]): int = M*10 + N
|
||||
|
||||
const
|
||||
a = [ [1.0, 2.0]
|
||||
, [3.0, 4.0]
|
||||
]
|
||||
|
||||
echo "perm: ", a.perm, " det: ", a.det
|
||||
Loading…
Add table
Add a link
Reference in a new issue