diff --git a/releases/8.0/tr.php b/releases/8.0/tr.php index 06138abec2..c9afa4254b 100644 --- a/releases/8.0/tr.php +++ b/releases/8.0/tr.php @@ -3,13 +3,13 @@ include_once __DIR__ . '/common.php'; releases\php80\language_redirect('tr'); - releases\php80\common_header( 'PHP 8.0, PHP dili için önemli bir güncellemedir. Optimizasyonlar ve yeni özellikler: Adlandırılmış ' . 'Değişkenler, Union Types, Attributes, Kurucularda Özellik Tanımı, Match İfadesi, Nullsafe Operatorü, ' . 'JIT(Anında Derleme) yanında tip sistemi, hata işleme ve tutarlılıkta iyileştirmeler içerir.'); ?> +
@@ -77,13 +77,12 @@
PHP 7
@@ -92,11 +91,10 @@ public function get($id) { /* ... */ }
PHP 8
@@ -117,20 +115,20 @@ public function get($id) { /* ... */ }
x = $x; - $this->y = $y; - $this->z = $z; - } -}' + public function __construct( + float $x = 0.0, + float $y = 0.0, + float $z = 0.0, + ) { + $this->x = $x; + $this->y = $y; + $this->z = $z; + } + }' );?>
@@ -140,12 +138,12 @@ public function __construct(
@@ -166,18 +164,18 @@ public function __construct(
number = $number; - } -} + /** + * @param float|int $number + */ + public function __construct($number) { + $this->number = $number; + } + } -new Number(\'NaN\'); // Ok' + new Number(\'NaN\'); // Ok' );?>
@@ -187,12 +185,12 @@ public function __construct($number) {
@@ -214,15 +212,15 @@ public function __construct(
Oh no!' + case \'8.0\': + $result = "Oh no!"; + break; + case 8.0: + $result = "This is what I expected"; + break; + } + echo $result; + //> Oh no!' );?>
@@ -232,10 +230,10 @@ public function __construct(
"Oh no!", - 8.0 => "This is what I expected", -}; -//> This is what I expected' + \'8.0\' => "Oh no!", + 8.0 => "This is what I expected", + }; + //> This is what I expected' );?>
@@ -262,17 +260,17 @@ public function __construct( user; + if ($session !== null) { + $user = $session->user; - if ($user !== null) { - $address = $user->getAddress(); - - if ($address !== null) { - $country = $address->country; - } - } -}' + if ($user !== null) { + $address = $user->getAddress(); + + if ($address !== null) { + $country = $address->country; + } + } + }' );?> @@ -334,8 +332,7 @@ public function __construct(
@@ -345,8 +342,7 @@ public function __construct(
@@ -422,7 +418,7 @@ public function __construct(

Diğer PHP sözdizimi düzenlemeleri ve iyileştirmeleri

- - - -