@@ -137,21 +137,6 @@ public function getUnresolvedInstancePropertyPrototype(string $propertyName, Cla
137
137
);
138
138
}
139
139
140
- public function hasStaticProperty (string $ propertyName ): TrinaryLogic
141
- {
142
- return TrinaryLogic::createNo ();
143
- }
144
-
145
- public function getStaticProperty (string $ propertyName , ClassMemberAccessAnswerer $ scope ): ExtendedPropertyReflection
146
- {
147
- throw new ShouldNotHappenException ();
148
- }
149
-
150
- public function getUnresolvedStaticPropertyPrototype (string $ propertyName , ClassMemberAccessAnswerer $ scope ): UnresolvedPropertyPrototypeReflection
151
- {
152
- throw new ShouldNotHappenException ();
153
- }
154
-
155
140
public function accepts (Type $ type , bool $ strictTypes ): AcceptsResult
156
141
{
157
142
if ($ type instanceof CompoundType) {
@@ -189,8 +174,8 @@ public function accepts(Type $type, bool $strictTypes): AcceptsResult
189
174
if (in_array ($ propertyName , $ this ->optionalProperties , true )) {
190
175
continue ;
191
176
}
192
- $ result = $ result -> and ( $ hasProperty );
193
- continue ;
177
+
178
+ return $ hasProperty ;
194
179
}
195
180
if ($ hasProperty ->maybe ()) {
196
181
if (!in_array ($ propertyName , $ this ->optionalProperties , true )) {
@@ -301,7 +286,17 @@ public function isSuperTypeOf(Type $type): IsSuperTypeOfResult
301
286
}
302
287
303
288
$ result = $ result ->and ($ hasProperty );
304
- $ otherProperty = $ type ->getInstanceProperty ($ propertyName , $ scope );
289
+ <<<<<<< HEAD
290
+ $ otherProperty = $ type ->getProperty ($ propertyName , $ scope );
291
+ =======
292
+
293
+ try {
294
+ $ otherProperty = $ type ->getInstanceProperty ($ propertyName , $ scope );
295
+ } catch (MissingPropertyFromReflectionException ) {
296
+ return $ result ;
297
+ }
298
+
299
+ >>>>>>> a507ab857 (Solve deprecations)
305
300
if (!$ otherProperty ->isPublic ()) {
306
301
return IsSuperTypeOfResult::createNo ();
307
302
}
0 commit comments