{ return $this->e1; } /** @return T0 */ public function failMismatch() { return 42; } /** @return T0 */ public function failVoid() { } /** @return T0 */ public function failAnotherGeneric() { return $this->e1; } /** @return T0 */ public static function failStatic() { return 42; } } function f(string $p0, int $p1) { } $tuple_a = new Tuple2(42, 'string'); f($tuple_a->e0, $tuple_a->e1); f($tuple_a->getE0(), $tuple_a->getE1()); f($tuple_a->e1, $tuple_a->e0); f($tuple_a->getE1(), $tuple_a->getE0());
/** * @param T0 $_0 * The 0th element * * @param T1 $_1 * The 1st element * * @param T2 $_2 * The 2nd element */ public function __construct($_0, $_1, $_2) { parent::__construct($_0, $_1); $this->_2 = $_2; }