stainless icon indicating copy to clipboard operation
stainless copied to clipboard

Stainless doesn't finish on polymorphic recursive data types

Open pgimalac opened this issue 3 years ago • 4 comments

Hello, As discussed, on the following code using polymorphic recursive data type stainless never finishes (nor prints errors or anything).

https://github.com/jacobprudhomme/finger-tree/tree/stainless-bug

Thanks.

pgimalac avatar Dec 15 '22 15:12 pgimalac

Not very useful to know but seems to be related to isInductive and isWellformed definitions. Will look into it!

mario-bucev avatar Dec 15 '22 16:12 mario-bucev

It is useful to know, @mario-bucev ; some things are more useful to users, some to developers. But those sets of people overlap. For now, we will need to check more carefully permitted inductive data types.

vkuncak avatar Dec 16 '22 09:12 vkuncak

We should reject cleanly and upfront unsupported data types.

vkuncak avatar Jan 11 '23 10:01 vkuncak

Here is a more precise link to where polymorphic recursion happens: https://github.com/jacobprudhomme/finger-tree/blob/stainless-bug/src/main/scala/fingertree/FingerTree.scala#L18

vkuncak avatar Mar 20 '23 21:03 vkuncak