summaryrefslogtreecommitdiff
path: root/test/pending/res/bug837
diff options
context:
space:
mode:
Diffstat (limited to 'test/pending/res/bug837')
-rw-r--r--test/pending/res/bug837/DataFlowAnalysis.scala17
-rw-r--r--test/pending/res/bug837/DeadCode.scala6
2 files changed, 23 insertions, 0 deletions
diff --git a/test/pending/res/bug837/DataFlowAnalysis.scala b/test/pending/res/bug837/DataFlowAnalysis.scala
new file mode 100644
index 0000000000..0197f5fbbf
--- /dev/null
+++ b/test/pending/res/bug837/DataFlowAnalysis.scala
@@ -0,0 +1,17 @@
+package test;
+import scala.collection.mutable._;
+trait CompleteLattice {
+ trait Elem;
+}
+trait DataFlowAnalysis[L <: CompleteLattice] {
+ type P;
+ val lattice : L;
+ val out: Map[P, lattice.Elem] = new HashMap;
+}
+abstract class Liveness {
+ object livenessLattice extends CompleteLattice;
+ final class LivenessAnalysis extends DataFlowAnalysis[livenessLattice.type] {
+ type P = String;
+ val lattice = livenessLattice;
+ }
+} \ No newline at end of file
diff --git a/test/pending/res/bug837/DeadCode.scala b/test/pending/res/bug837/DeadCode.scala
new file mode 100644
index 0000000000..2978e24d42
--- /dev/null
+++ b/test/pending/res/bug837/DeadCode.scala
@@ -0,0 +1,6 @@
+package test;
+trait DeadcodeAnalysis {
+ object liveness extends Liveness;
+ val a = new liveness.LivenessAnalysis();
+ var live = a.out("hello");
+}