We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5e96761 commit 46e3ecdCopy full SHA for 46e3ecd
src/Type/Generic/TemplateObjectWithoutClassType.php
@@ -155,8 +155,12 @@ public function isSubTypeOf(Type $type): TrinaryLogic
155
return TrinaryLogic::createYes();
156
}
157
158
- return $type->getBound()->isSuperTypeOf($this->getBound())
159
- ->and(TrinaryLogic::createMaybe());
+ if ($type->getBound()->isSuperTypeOf($this->getBound())->no() &&
+ $this->getBound()->isSuperTypeOf($type->getBound())->no()) {
160
+ return TrinaryLogic::createNo();
161
+ }
162
+
163
+ return TrinaryLogic::createMaybe();
164
165
166
public function inferTemplateTypes(Type $receivedType): TemplateTypeMap
0 commit comments