From 428cafc3dca492cbf9c4c8f2c08d88f6374ffc17 Mon Sep 17 00:00:00 2001 From: harukitosa <13haruki28@gmail.com> Date: Sat, 15 Oct 2022 18:04:15 +0900 Subject: [PATCH 1/4] fix ecma262 url --- meetings/2017-07-21/README.md | 2 +- meetings/2017-09-28/README.md | 2 +- source/OUTLINE.md | 14 +++++++------- source/basic/async/OUTLINE.md | 8 ++++---- source/basic/class/OUTLINE.md | 8 ++++---- source/basic/class/README.md | 6 +++--- source/basic/ecmascript/README.md | 2 +- source/basic/function-scope/OUTLINE.md | 18 +++++++++--------- source/basic/function-scope/README.md | 14 +++++++------- source/basic/function-this/Notes.md | 2 +- source/basic/function-this/OUTLINE.md | 26 +++++++++++++------------- source/basic/string/README.md | 2 +- 12 files changed, 52 insertions(+), 52 deletions(-) diff --git a/meetings/2017-07-21/README.md b/meetings/2017-07-21/README.md index b0f369976c..da9003f38f 100644 --- a/meetings/2017-07-21/README.md +++ b/meetings/2017-07-21/README.md @@ -31,7 +31,7 @@ - @azu: 例外的なケースが多すぎる気がする - 仕様のNoteが6つもある -- +- - これはTableなどで対応をまとめて書いたほうが楽なのでは? | 種類 | シリアライズ結果 | diff --git a/meetings/2017-09-28/README.md b/meetings/2017-09-28/README.md index e660c99c72..3b12ef8d7e 100644 --- a/meetings/2017-09-28/README.md +++ b/meetings/2017-09-28/README.md @@ -149,7 +149,7 @@ - throw = 例外を発生させる構文 - Error = エラーを表現するために標準化されているオブジェクト - @azu: この章ではこういう定義ですという形でやらないとダメそう。 -- @azu: あとはdebugger; https://tc39.github.io/ecma262/#sec-debugger-statement か +- @azu: あとはdebugger; https://tc39.es/ecma262/#sec-debugger-statement か - これECMAScriptの仕様にあるんだな。 - Promiseと同じでイベントは飛ぶから後は実行環境で何かしてみたいな感じ - 省いても良さそう。 diff --git a/source/OUTLINE.md b/source/OUTLINE.md index 295e2376b6..a99307a548 100644 --- a/source/OUTLINE.md +++ b/source/OUTLINE.md @@ -532,7 +532,7 @@ console.log(array.slice(4, 1)); // => [] - 分類: グローバルスコープ - global - [x] 確認: 仕様ではどのような言及 - - https://tc39.github.io/ecma262/#sec-global-environment-records + - https://tc39.es/ecma262/#sec-global-environment-records - 分類: ブロックスコープ - 機能: スコープチェイン - 名前解決: スコープ間で同じ変数の定義とshadowing @@ -595,21 +595,21 @@ console.log(array.slice(4, 1)); // => [] - scopeによって定義されたenvironment - EnvironmentはRecordから構成される - inner env -> outer envによりスコープチェインという現象が起きる - - + - - Scope chain - - https://tc39.github.io/ecma262/#sec-newdeclarativeenvironment + - https://tc39.es/ecma262/#sec-newdeclarativeenvironment - スコープを作成するときにouter lexicale envへのリファレンスを - A global environment is a Lexical Environment - GlobalもLexicalの一種 - globalはouterがnull - Envの種類 - - + - - LexicalEnv - letやconst、classはこちらに登録する - - https://tc39.github.io/ecma262/#sec-let-and-const-declarations + - https://tc39.es/ecma262/#sec-let-and-const-declarations - VariableEnv - varはこちらに登録する - - https://tc39.github.io/ecma262/#sec-variable-statement + - https://tc39.es/ecma262/#sec-variable-statement - この2つのenvは同じことがあり、実行Contextに紐づく - module environment もあるよ - module envはglobal envとなることがある @@ -664,7 +664,7 @@ function getValue(variableName, currentScope) { ## Arrow Functionとthis - Arrow Functionでは`this`が`[[ThisMode]]`が`lexical`になる -- https://tc39.github.io/ecma262/#sec-functioninitialize +- https://tc39.es/ecma262/#sec-functioninitialize - lexicalではもっとも近いfunctionを参照するようになる = ## 削った章 diff --git a/source/basic/async/OUTLINE.md b/source/basic/async/OUTLINE.md index 65e5f033b2..a5b21594de 100644 --- a/source/basic/async/OUTLINE.md +++ b/source/basic/async/OUTLINE.md @@ -22,7 +22,7 @@ ## 仕様 - PendingJob -- https://tc39.github.io/ecma262/#sec-enqueuejob +- https://tc39.es/ecma262/#sec-enqueuejob - https://html.spec.whatwg.org/multipage/timers-and-user-prompts.html#dom-settimeout - ECMAScript と DOM - https://html.spec.whatwg.org/multipage/webappapis.html#integration-with-the-javascript-job-queue @@ -333,9 +333,9 @@ try{ - return or awaitについて - 仕様 - `async function`では`[[FunctionKind]]`が`async`の関数を作成する - - https://tc39.github.io/ecma262/#sec-createdynamicfunction + - https://tc39.es/ecma262/#sec-createdynamicfunction - 必ずPromiseを返す - - + - - Generatorで再現できるけど、Async FunctionはGeneratorとは関係ない仕様 - 未使用 - TODO: AgentとJob Queueと実行コンテキスト解説 @@ -381,7 +381,7 @@ Promise本から抽出した内容 - Promiseは統一したインタフェースがあることについて - [1.2. Promise Overview](http://azu.github.io/promises-book/#promises-overview) - コンストラクタ、インスタンスメソッド、静的メソッド - - Promiseの3つの状態 [`[[PromiseState]]`](https://tc39.github.io/ecma262/#table-59) + - Promiseの3つの状態 [`[[PromiseState]]`](https://tc39.es/ecma262/#table-59) - fulfilled => onFulfilled - rejected => onRejectedの対応 - Pending diff --git a/source/basic/class/OUTLINE.md b/source/basic/class/OUTLINE.md index 2054bd08bf..8e6f43708e 100644 --- a/source/basic/class/OUTLINE.md +++ b/source/basic/class/OUTLINE.md @@ -272,7 +272,7 @@ - 未使用 - `instanceof`演算子は`__proto__`と`prototype`の比較 - https://www.slideshare.net/zhiyelee/protoandprototype - - https://tc39.github.io/ecma262/#sec-ordinaryhasinstance + - https://tc39.es/ecma262/#sec-ordinaryhasinstance - new演算子は何をやっているのかについて - メソッドはnewできない件について - クラスとtypeofの結果 @@ -357,11 +357,11 @@ C(); // => TypeError これって意外にも `[[Call]]` で クラスのコンストラクタ関数は呼び出すと例外を投げるって書いてあるんだ。てっきり定義するときに例外を投げる関数を登録みたいな感じだと思ってた。 -- [Runtime Semantics: ClassDefinitionEvaluation](https://tc39.github.io/ecma262/#sec-runtime-semantics-classdefinitionevaluation "Runtime Semantics: ClassDefinitionEvaluation") +- [Runtime Semantics: ClassDefinitionEvaluation](https://tc39.es/ecma262/#sec-runtime-semantics-classdefinitionevaluation "Runtime Semantics: ClassDefinitionEvaluation") - `class`で定義した場合 -- [MakeClassConstructor ( F )](https://tc39.github.io/ecma262/#sec-makeclassconstructor "MakeClassConstructor ( F )") +- [MakeClassConstructor ( F )](https://tc39.es/ecma262/#sec-makeclassconstructor "MakeClassConstructor ( F )") - このコンストラクタ関数の`[[FunctionKind]]`が`classConstructor`になる -- [`[[Call]] ( thisArgument, argumentsList )`](https://tc39.github.io/ecma262/#sec-ecmascript-function-objects-call-thisargument-argumentslist) +- [`[[Call]] ( thisArgument, argumentsList )`](https://tc39.es/ecma262/#sec-ecmascript-function-objects-call-thisargument-argumentslist) - `[[FunctionKind]]`が`classConstructor`な関数は`TypeError`を投げる diff --git a/source/basic/class/README.md b/source/basic/class/README.md index 449acaf3d0..a3d0febf73 100644 --- a/source/basic/class/README.md +++ b/source/basic/class/README.md @@ -432,7 +432,7 @@ Arrayの`length`プロパティは、`length`プロパティへ値を代入し @@ -1577,9 +1577,9 @@ console.log(child instanceof Child); // => true diff --git a/source/basic/ecmascript/README.md b/source/basic/ecmascript/README.md index 1553796c06..d040e7afbe 100644 --- a/source/basic/ecmascript/README.md +++ b/source/basic/ecmascript/README.md @@ -40,7 +40,7 @@ ES5.1からES2015がでるまで4年もの歳月がかかっているのに対 ## Living StandardとなるECMAScript {#living-standard} 現在、ECMAScriptの仕様書のドラフトはGitHub上の[tc39/ecma262][]で管理されており、日々更新されています。 -そのため、本当の意味での最新のECMAScript仕様はとなります。 +そのため、本当の意味での最新のECMAScript仕様はとなります。 このように更新ごとにバージョン番号をつけずに、常に最新版を公開する仕様のことを**Living Standard**と呼びます。 ECMAScriptはLiving Standardですが、これに加えてECMAScript 2017のようにバージョン番号をつけたものも公開されています。 diff --git a/source/basic/function-scope/OUTLINE.md b/source/basic/function-scope/OUTLINE.md index 9db2ccae84..8600245bc2 100644 --- a/source/basic/function-scope/OUTLINE.md +++ b/source/basic/function-scope/OUTLINE.md @@ -33,7 +33,7 @@ - global - ビルトインオブジェクトが参照できるのもスコープチェイン仕組みによる - [x] 確認: 仕様ではどのような言及 - - https://tc39.github.io/ecma262/#sec-global-environment-records + - https://tc39.es/ecma262/#sec-global-environment-records - @名前解決 スコープ間で同じ変数の定義とshadowingの問題 - スコープチェインの仕組みを理解するとなぜ起きるのかが分かる - @コラム スコープは小さく、変数の影響範囲は小さく @@ -132,21 +132,21 @@ console.log(obj);// => {} - scopeによって定義されたenvironment - EnvironmentはRecordから構成される - inner env -> outer envによりスコープチェインという現象が起きる - - + - - Scope chain - - https://tc39.github.io/ecma262/#sec-newdeclarativeenvironment + - https://tc39.es/ecma262/#sec-newdeclarativeenvironment - スコープを作成するときにouter lexicale envへのリファレンスを - A global environment is a Lexical Environment - GlobalもLexicalの一種 - globalはouterがnull - Envの種類 - - + - - LexicalEnv - letやconst、classはこちらに登録する - - https://tc39.github.io/ecma262/#sec-let-and-const-declarations + - https://tc39.es/ecma262/#sec-let-and-const-declarations - VariableEnv - varはこちらに登録する - - https://tc39.github.io/ecma262/#sec-variable-statement + - https://tc39.es/ecma262/#sec-variable-statement - この2つのenvは同じことがあり、実行Contextに紐づく - module environment もあるよ - module envはglobal envとなることがある @@ -175,7 +175,7 @@ const fnScope = { outer: globalScope, // <= 現在の実装スコープ = globalScope envRec: new Map() // <= envRecはスコープ毎に作られる // Object.create(null) = arguments - // https://tc39.github.io/ecma262/#sec-createmappedargumentsobject + // https://tc39.es/ecma262/#sec-createmappedargumentsobject }; // function fnの中の変数処理 // `arg` 仮引数はfnScopeのenvRecに記録される @@ -203,7 +203,7 @@ function getValue(variableName, currentScope) { ## Arrow Functionとthis - Arrow Functionでは`this`が`[[ThisMode]]`が`lexical`になる -- https://tc39.github.io/ecma262/#sec-functioninitialize +- https://tc39.es/ecma262/#sec-functioninitialize - lexicalではもっとも近いfunctionを参照するようになる = @@ -401,7 +401,7 @@ function submit(data){ - https://twitter.com/azu_re/status/911872145252159488 - https://twitter.com/azu_re/status/911874213971034112 - varで宣言された変数はLetのLexicalEnviromentとは異なり、VariableEnvironmentに紐づく - - https://tc39.github.io/ecma262/#sec-execution-contexts`` + - https://tc39.es/ecma262/#sec-execution-contexts`` - @具体例 巻き上げられた処理の擬似コード - @事実 巻き上げはもっとも近くの関数スコープまたはグローバルスコープに変数が紐づく - つまりブロックスコープを無視します diff --git a/source/basic/function-scope/README.md b/source/basic/function-scope/README.md index 39faf84417..2ed4b74fb1 100644 --- a/source/basic/function-scope/README.md +++ b/source/basic/function-scope/README.md @@ -52,12 +52,12 @@ console.log(x); // => ReferenceError: x is not defined 関数の宣言 - Set F.[[FormalParameters]] to ParameterList. -- https://tc39.github.io/ecma262/#sec-functioninitialize +- https://tc39.es/ecma262/#sec-functioninitialize - function objectの[[Environment]]ではなく、[[FormalParameters]]に代入される - 仮引数は関数のスコープではなくfunction objectに紐づく 関数の初期化処理 -- https://tc39.github.io/ecma262/#sec-functiondeclarationinstantiation +- https://tc39.es/ecma262/#sec-functiondeclarationinstantiation - [[FormalParameters]]は初期化時に`varEnv`に対して代入される - つまり、仮引数はvarで宣言しているのと同じになる - スコープという意味では内側のみから参照でき、外からは参照できないという点で同じ @@ -121,11 +121,11 @@ console.log(x); // => ReferenceError: x is not defined @@ -293,10 +293,10 @@ fn();