final_initialization_in_ctor.java: New file
2001-09-27 Alexandre Petit-Bianco <apbianco@redhat.com> * libjava.compile/final_initialization_in_ctor.java: New file ( http://gcc.gnu.org/ml/gcc-patches/2001-09/msg01160.html ) From-SVN: r45843
This commit is contained in:
parent
387beb8240
commit
5952078834
@ -1,3 +1,7 @@
|
||||
2001-09-27 Alexandre Petit-Bianco <apbianco@redhat.com>
|
||||
|
||||
* libjava.compile/final_initialization_in_ctor.java: New file
|
||||
|
||||
2001-08-28 Alexandre Petit-Bianco <apbianco@redhat.com>
|
||||
|
||||
* libjava.compile/final_assignment_check.java: New file.
|
||||
|
@ -0,0 +1,21 @@
|
||||
// This test case was insipred by
|
||||
// http://gcc.gnu.org/ml/java/2001-09/msg00181.html
|
||||
|
||||
class M {
|
||||
int size () { return 3; }
|
||||
}
|
||||
|
||||
class final_initialization_in_ctor {
|
||||
|
||||
final float loadFactor;
|
||||
|
||||
public final_initialization_in_ctor(M m)
|
||||
{
|
||||
this(Math.max(m.size() * 2, 30), (float)40.0);
|
||||
}
|
||||
|
||||
public final_initialization_in_ctor(int initialCapacity, float loadFactor)
|
||||
{
|
||||
this.loadFactor = loadFactor;
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user