From f643af992b58ecc9e3f6526de069b97d857f8e51 Mon Sep 17 00:00:00 2001 From: bdemsky Date: Mon, 23 Mar 2009 19:33:47 +0000 Subject: [PATCH] even simpler --- .../smalltest/smaller.java | 44 +++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 Robust/src/Tests/OwnershipAnalysisTest/smalltest/smaller.java diff --git a/Robust/src/Tests/OwnershipAnalysisTest/smalltest/smaller.java b/Robust/src/Tests/OwnershipAnalysisTest/smalltest/smaller.java new file mode 100644 index 00000000..bd1b7fa1 --- /dev/null +++ b/Robust/src/Tests/OwnershipAnalysisTest/smalltest/smaller.java @@ -0,0 +1,44 @@ +class small { + tiny t1; + + public small(tiny t) { + t1=t; + } + + public static void main(String x[]) { + tiny t=new tiny(); + small s=new small(t); + foo[] farray=s.process(); + } + + public foo[] process() { + foo []farray=new foo[30]; + while(true) { + foo f=createfoo(); + farray[0]=f; + } + return farray; + } + + public foo createfoo() { + foo f=disjoint test new foo(); + f.t1=t1; + return f; + } + + +} + +public class tiny { + int x; + public tiny() { + + } +} + +public class foo { + tiny t1; + public foo() { + + } +} \ No newline at end of file -- 2.34.1