-
Notifications
You must be signed in to change notification settings - Fork 81
Closed
Labels
enhancementNew feature or requestNew feature or request
Description
static メソッドや static プロパティは、スコープ定義演算子で以下のようにアクセスする
<?php
class Test {
public static int $prop = 1;
public static function testMethod() : int { return 2; }
};
var_dump(Test::$prop); // 1
var_dump(Test::testMethod()); // 2
上記の呼び方を statically call
と呼んでいる箇所がかなりある。日本語版では「静的にコールする(呼び出す) 」と訳しているのだが、正直意味がわからない。静的にってどういうこと!? そのまま statically を置き換えただけである。
これについては、 (インスタンス化せずに)スコープ定義演算子を使ってアクセスする
という意味なので、適切なタイミングで置き換える。
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request