-
Notifications
You must be signed in to change notification settings - Fork 130
/
defined-3.bas
145 lines (120 loc) · 2.47 KB
/
defined-3.bas
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
#print "T1 -- fields only"
type T1
value as integer
end type
#if defined( T1.value )
#print "T1.value defined"
#else
#print "T1.value not defined - NOK"
#endif
#if defined( T1.constructor )
#print "T1.constructor defined - NOK"
#else
#print "T1.constructor not defined"
#endif
#if defined( T1.destructor )
#print "T1.constructor defined - NOK"
#else
#print "T1.constructor not defined"
#endif
#if defined( T1.let )
#print "T1.let defined - NOK"
#else
#print "T1.let not defined"
#endif
#if defined( T1.cast )
#print "T1.cast defined - NOK"
#else
#print "T1.cast not defined"
#endif
#print "T2 -- fields and procedures"
type T2
value as integer
static svalue as integer
declare sub proc()
declare static sub sproc()
end type
sub T2.proc()
#if defined( value )
#print "value defined"
#else
#print "value not defined - NOK"
#endif
#if defined( proc )
#print "proc defined"
#else
#print "proc not defined - NOK"
#endif
#if defined( svalue )
#print "svalue defined"
#else
#print "svalue not defined - NOK"
#endif
#if defined( sproc )
#print "sproc defined"
#else
#print "sproc not defined - NOK"
#endif
#if defined( T2.value )
#print "T2.value defined"
#else
#print "T2.value not defined - NOK"
#endif
#if defined( T2.proc )
#print "T2.proc defined"
#else
#print "T2.proc not defined - NOK"
#endif
#if defined( T2.svalue )
#print "T2.svalue defined"
#else
#print "T2.svalue not defined - NOK"
#endif
#if defined( T2.sproc )
#print "T2.sproc defined"
#else
#print "T2.sproc not defined - NOK"
#endif
#if defined( T2.constructor )
#print "T2.constructor defined - NOK"
#else
#print "T2.constructor not defined"
#endif
#if defined( T2.destructor )
#print "T2.constructor defined - NOK"
#else
#print "T2.constructor not defined"
#endif
#if defined( T2.let )
#print "T2.let defined - NOK"
#else
#print "T2.let not defined"
#endif
#if defined( T2.cast )
#print "T2.cast defined - NOK"
#else
#print "T2.cast not defined"
#endif
#if ENABLE_CHECK_BUGS
#if defined( this.svalue )
#print "this.svalue defined"
#else
#print "this.svalue not defined - NOK"
#endif
#if defined( this.sproc )
#print "this.sproc defined"
#else
#print "this.sproc not defined - NOK"
#endif
#if defined( this.svalue )
#print "this.svalue defined"
#else
#print "this.svalue not defined - NOK"
#endif
#if defined( this.sproc )
#print "this.sproc defined"
#else
#print "this.sproc not defined - NOK"
#endif
#endif
end sub