You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The type generic type, for instance type<bool>, appears to be accepted as a possible parameter type or return type for functions and predicates, but then triggers a NotSupported exception in the ColToSilver transform. For example, in PVL:
void x(type<void> y) { }
In Java:
/*@ resource x(type<int> y); */
The error message, "This kind of node (TType) is not supported by silver directly", blames the correct node in the program, so it would not be difficult for a user to find the problem, but the crash is probably unexpected.
viper.api.transform.ColToSilver$NotSupported: ======================================
18 }
19
[----------
20 void x1(int tid, type y) returns (Void res) {
----------]
21 ref exc;
22 Void return1;
--------------------------------------
This kind of node (TType) is not supported by silver directly. Is there a rewrite missing?
======================================
at viper.api.transform.ColToSilver.$qmark$qmark(ColToSilver.scala:57)
at viper.api.transform.ColToSilver.typ(ColToSilver.scala:347)
at viper.api.transform.ColToSilver.variable(ColToSilver.scala:321)
at viper.api.transform.ColToSilver.$anonfun$collect$8(ColToSilver.scala:248)
at scala.collection.immutable.List.map(List.scala:250)
at scala.collection.immutable.List.map(List.scala:79)
at viper.api.transform.ColToSilver.$anonfun$collect$6(ColToSilver.scala:248)
at viper.api.transform.ColToSilver.scoped(ColToSilver.scala:120)
at viper.api.transform.ColToSilver.collect(ColToSilver.scala:238)
at viper.api.transform.ColToSilver.$anonfun$transform$16(ColToSilver.scala:176)
at viper.api.transform.ColToSilver.$anonfun$transform$16$adapted(ColToSilver.scala:176)
at scala.collection.immutable.List.foreach(List.scala:333)
at viper.api.transform.ColToSilver.transform(ColToSilver.scala:176)
at viper.api.transform.ColToSilver$.transform(ColToSilver.scala:26)
at viper.api.backend.SilverBackend.$anonfun$transform$1(SilverBackend.scala:91)
at hre.progress.task.NameSequenceTask.scope(NameSequenceTask.scala:16)
at hre.progress.Progress$.stages(Progress.scala:47)
at viper.api.backend.SilverBackend.transform(SilverBackend.scala:90)
at viper.api.backend.SilverBackend.transform$(SilverBackend.scala:81)
at viper.api.backend.silicon.Silicon.transform(Silicon.scala:34)
at vct.main.stages.SilverBackend.transform(Backend.scala:196)
at vct.main.stages.Backend.$anonfun$run$3(Backend.scala:152)
at hre.progress.Progress$.$anonfun$map$2(Progress.scala:35)
at hre.progress.task.AbstractTask.frame(AbstractTask.scala:166)
at hre.progress.Progress$.$anonfun$map$1(Progress.scala:35)
at scala.collection.parallel.IterableSplitter$Mapped.next(RemainsIterator.scala:463)
at scala.collection.immutable.List.prependedAll(List.scala:153)
at scala.collection.immutable.List$.from(List.scala:684)
at scala.collection.immutable.List$.from(List.scala:681)
at scala.collection.SeqFactory$Delegate.from(Factory.scala:306)
at scala.collection.immutable.Seq$.from(Seq.scala:42)
at scala.collection.immutable.Seq$.from(Seq.scala:39)
at scala.collection.IterableFactory$ToFactory.fromSpecific(Factory.scala:274)
at scala.collection.IterableOnceOps.to(IterableOnce.scala:1310)
at scala.collection.IterableOnceOps.to$(IterableOnce.scala:1310)
at scala.collection.parallel.IterableSplitter$Mapped.to(RemainsIterator.scala:460)
at vct.main.stages.Backend.$anonfun$run$1(Backend.scala:153)
at hre.progress.task.NameSequenceTask.scope(NameSequenceTask.scala:16)
at hre.progress.Progress$.stages(Progress.scala:47)
at vct.main.stages.Backend.run(Backend.scala:145)
at vct.main.stages.Backend.run$(Backend.scala:137)
at vct.main.stages.SilverBackend.run(Backend.scala:184)
at vct.main.stages.SilverBackend.run(Backend.scala:184)
at hre.stages.Stages.$anonfun$run$3(Stages.scala:104)
at hre.stages.Stages.$anonfun$run$3$adapted(Stages.scala:101)
at scala.collection.IterableOnceOps.foreach(IterableOnce.scala:576)
at scala.collection.IterableOnceOps.foreach$(IterableOnce.scala:574)
at scala.collection.AbstractIterable.foreach(Iterable.scala:933)
at scala.collection.IterableOps$WithFilter.foreach(Iterable.scala:903)
at hre.stages.Stages.$anonfun$run$1(Stages.scala:101)
at hre.progress.task.NameSequenceTask.scope(NameSequenceTask.scala:16)
at hre.progress.Progress$.stages(Progress.scala:47)
at hre.stages.Stages.run(Stages.scala:98)
at hre.stages.Stages.run$(Stages.scala:95)
at hre.stages.StagesPair.run(Stages.scala:145)
at vct.main.modes.Verify$.verifyWithOptions(Verify.scala:64)
at vct.main.modes.Verify$.$anonfun$runOptions$3(Verify.scala:99)
at scala.runtime.java8.JFunction0$mcI$sp.apply(JFunction0$mcI$sp.scala:17)
at hre.util.Time$.logTime(Time.scala:23)
at vct.main.modes.Verify$.runOptions(Verify.scala:99)
at vct.main.Main$.runMode(Main.scala:107)
at vct.main.Main$.$anonfun$runOptions$3(Main.scala:100)
at scala.runtime.java8.JFunction0$mcI$sp.apply(JFunction0$mcI$sp.scala:17)
at hre.middleware.Middleware$.using(Middleware.scala:78)
at vct.main.Main$.$anonfun$runOptions$2(Main.scala:100)
at scala.runtime.java8.JFunction0$mcI$sp.apply(JFunction0$mcI$sp.scala:17)
at hre.io.Watch$.booleanWithWatch(Watch.scala:58)
at vct.main.Main$.$anonfun$runOptions$1(Main.scala:100)
at scala.runtime.java8.JFunction0$mcI$sp.apply(JFunction0$mcI$sp.scala:17)
at hre.middleware.Middleware$.using(Middleware.scala:78)
at vct.main.Main$.runOptions(Main.scala:95)
at vct.main.Main$.main(Main.scala:50)
at vct.main.Main.main(Main.scala)
[ERROR] !*!*!*!*!*!*!*!*!*!*!*!
[ERROR] ! VerCors has crashed !
[ERROR] !*!*!*!*!*!*!*!*!*!*!*!
wandernauta
changed the title
Accepting an argument of type type<...> triggers ColToSilver$NotSupported
Accepting or returning a value of type type<...> triggers ColToSilver$NotSupported
Feb 11, 2025
The
type
generic type, for instancetype<bool>
, appears to be accepted as a possible parameter type or return type for functions and predicates, but then triggers aNotSupported
exception in theColToSilver
transform. For example, in PVL:In Java:
/*@ resource x(type<int> y); */
The error message, "This kind of node (TType) is not supported by silver directly", blames the correct node in the program, so it would not be difficult for a user to find the problem, but the crash is probably unexpected.
Version: 2bd3bca (dev branch).
This issue was found by fuzzing.
The text was updated successfully, but these errors were encountered: