File: class10.bsh

package info (click to toggle)
bsh 2.0b4-20
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, forky, sid, trixie
  • size: 4,224 kB
  • sloc: java: 23,431; xml: 4,500; sh: 139; makefile: 24
file content (27 lines) | stat: -rw-r--r-- 430 bytes parent folder | download | duplicates (10)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
source("TestHarness.bsh");

class Foo10
{
	Bar10 myBar;

	// random instance stuff
	assert( this instanceof Foo10 );
	assert( Foo10.Bar10 instanceof bsh.ClassIdentifier );
	assert( Bar10 instanceof bsh.ClassIdentifier );

	static class Bar10 { }

	void go() {
		myBar = new Bar10();
		assert( myBar instanceof Bar10 );
	}
}


f=new Foo10();
f.go();
assert( f.myBar instanceof Foo10.Bar10 );

assert( myBar == void );

complete();