Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: Ms2ger/ecma262
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: master
Choose a base ref
...
head repository: tc39/ecma262
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: main
Choose a head ref
Able to merge. These branches can be automatically merged.
Loading
Showing with 47,246 additions and 31,620 deletions.
  1. +42 −0 .github/ISSUE_TEMPLATE/1-bug-report.md
  2. +11 −0 .github/ISSUE_TEMPLATE/config.yml
  3. +9 −0 .github/PULL_REQUEST_TEMPLATE.md
  4. +19 −0 .github/workflows/build.yml
  5. +26 −0 .github/workflows/deploy.yml
  6. +19 −0 .github/workflows/enforce-format.yml
  7. +41 −0 .github/workflows/esmeta-typecheck.yml
  8. +28 −0 .github/workflows/ipr.yml
  9. +25 −0 .github/workflows/preview-build.yml
  10. +61 −0 .github/workflows/preview.yml
  11. +32 −0 .github/workflows/publish-biblio.yml
  12. +12 −0 .github/workflows/require-allow-edits.yml
  13. +24 −0 .github/workflows/spellcheck.yml
  14. +3 −2 .gitignore
  15. +0 −13 .travis.yml
  16. +1 −1 CODE_OF_CONDUCT.md
  17. +33 −14 CONTRIBUTING.md
  18. +2 −2 FAQ.md
  19. +5 −0 LICENSE.md
  20. +20 −0 PUBLISHING.md
  21. +10 −7 README.md
  22. +9 −0 biblio/README.md
  23. +19 −0 biblio/package.json
  24. +17 −0 esmeta-ignore.json
  25. +0 −468 figure-2.uxf
  26. +1 −120 img/ecma-logo.svg
  27. BIN img/figure-1.png
  28. +1 −1 img/figure-1.svg
  29. BIN img/figure-2.png
  30. +301 −0 img/figure-2.svg
  31. +1 −0 img/module-graph-cycle-async.svg
  32. +1 −63 img/module-graph-cycle.svg
  33. +1 −48 img/module-graph-missing.svg
  34. +1 −56 img/module-graph-simple.svg
  35. +4,846 −0 package-lock.json
  36. +21 −11 package.json
  37. +14 −24 scripts/auto-deploy.sh
  38. +50 −0 scripts/check-commit.js
  39. +282 −0 scripts/check-form.js
  40. BIN scripts/github_deploy_key.enc
  41. +42 −0 scripts/insert_snapshot_warning.js
  42. +22 −0 scripts/publish-biblio.sh
  43. +100 −0 scripts/publish-preview.js
  44. +66 −0 scripts/snapshot_warning.css
  45. +25 −0 scripts/snapshot_warning.html
  46. +72 −0 scripts/spellcheck.mjs
  47. +40,618 −28,446 spec.html
  48. +1 −1 stage0.md
  49. +31 −0 table-binary-unicode-properties-of-strings.html
  50. +265 −326 table-binary-unicode-properties.html
  51. +15 −21 table-nonbinary-unicode-properties.html
  52. +0 −357 table-unicode-general-category-values.html
  53. +0 −1,282 table-unicode-script-values.html
  54. +1 −1 withdrawn-proposals.md
  55. +0 −55 workingdocs/ES6-super-construct=proposal.md
  56. +0 −301 workingdocs/callconstructor.md
42 changes: 42 additions & 0 deletions .github/ISSUE_TEMPLATE/1-bug-report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
---
name: "\U0001F41B Bug report"
about: Report a bug with the specification.

---

<!--
Thank you for reporting a possible bug in ECMA-262.
If this is a bug with a specific implementation of ECMA-262, such as
a JavaScript engine or a browser, please report it on their bug tracker
instead.
eshost is a tool to run the same code on many JS engines
to compare the output.
To set up eshost:
1. $ npm i -g eshost-cli jsvu
2. $ jsvu
3. $ eshost --configure-jsvu
Running eshost:
Use `-x` to evaluate multiple statements:
$ eshost -s -x "const a = 1 + 1; print(a);"
Or `-e` to evaluate a single expression:
$ eshost -s -e "1 + 1"
Paste the output of eshost into the box below.
-->

**Description:** Adding 1 and 1 is two, but it should be...

**eshost Output:**

```
$ eshost -s -e "1 + 1"
#### Chakra, JavaScriptCore, SpiderMonkey, V8, XS
2
```
11 changes: 11 additions & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
blank_issues_enabled: true
contact_links:
-
about: "Feature requests for future versions of ECMAScript should not be made in this repository. See CONTRIBUTING.md for more details."
name: "\U0001F680 Feature request"
url: "https://github.com/tc39/ecma262/blob/HEAD/CONTRIBUTING.md#new-feature-proposals"
-
about: "You can also ask questions and suggest ideas on the TC39 Discourse."
name: "\U0001F4AC Discourse"
url: "https://es.discourse.group/"
9 changes: 9 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<!--
If you are changing the signature or behavior of an existing construct, please check if this affects downstream dependencies (searching for the construct's name is sufficient) and if needed file an issue:
* [Web IDL](https://webidl.spec.whatwg.org/) — [file an issue](https://github.com/whatwg/webidl/issues/new)
* [HTML Standard](https://html.spec.whatwg.org/) — [file an issue](https://github.com/whatwg/html/issues/new)
* [ECMAScript Intl API](https://tc39.es/ecma402/) - [file an issue](https://github.com/tc39/ecma402/issues/new)
Note: please ensure that the "Allow edits and access to secrets by maintainers" checkbox remains checked.
-->
19 changes: 19 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: 'ecma-262'

on: [pull_request, push]

jobs:
build:
name: 'build & lint ecmarkup'
runs-on: ubuntu-22.04

steps:
- uses: actions/checkout@v4
- uses: ljharb/actions/node/install@dfd9796898850cf07630d1bd4053a7c9a379e90f
name: 'nvm install lts/* && npm ci --no-audit'
env:
NPM_CONFIG_AUDIT: false
with:
node-version: lts/*
use-npm-ci: true
- run: npm run build-head
26 changes: 26 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: 'ecma-262 deploy'

on:
push:
branches:
- main

jobs:
deploy:
name: 'deploy github pages'
runs-on: ubuntu-22.04
if: ${{ github.repository == 'tc39/ecma262' }}

steps:
- uses: actions/checkout@v4
- uses: ljharb/actions/node/install@dfd9796898850cf07630d1bd4053a7c9a379e90f
name: 'nvm install lts/* && npm ci --no-audit'
env:
NPM_CONFIG_AUDIT: false
with:
node-version: lts/*
use-npm-ci: true
- run: npm run build-only
- run: ./scripts/auto-deploy.sh
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
19 changes: 19 additions & 0 deletions .github/workflows/enforce-format.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: 'enforce format'

on: [pull_request]

jobs:
build:
name: 'enforce format'
runs-on: ubuntu-22.04

steps:
- uses: actions/checkout@v4
- uses: ljharb/actions/node/install@dfd9796898850cf07630d1bd4053a7c9a379e90f
name: 'nvm install lts/* && npm ci --no-audit'
env:
NPM_CONFIG_AUDIT: false
with:
node-version: lts/*
use-npm-ci: true
- run: 'if ! npx emu-format --check spec.html; then echo "You need to run \`npm run format\`"; exit 1; fi'
41 changes: 41 additions & 0 deletions .github/workflows/esmeta-typecheck.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: 'esmeta typecheck'

on: [pull_request]

jobs:
esmeta-typecheck:
name: 'esmeta typecheck'
runs-on: ubuntu-22.04

env:
ESMETA_HOME: vendor/esmeta

steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup JDK
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 17
- name: Setup SBT
uses: sbt/setup-sbt@v1
- name: download esmeta
run: |
mkdir -p "${ESMETA_HOME}"
cd "${ESMETA_HOME}"
git init
git remote add origin https://github.com/es-meta/esmeta.git
git fetch --depth 1 origin 4bc6a2ffd015a150596fde1c9dcbcb3614e7cbbb ;# v0.5.1
git checkout FETCH_HEAD
- name: build esmeta
run: |
cd "${ESMETA_HOME}"
sbt assembly
- name: link
run: |
rmdir "${ESMETA_HOME}"/ecma262 \
&& ln -s "$(pwd)" "${ESMETA_HOME}"/ecma262
- name: typecheck
run: '"${ESMETA_HOME}"/bin/esmeta tycheck -status -tycheck:log -tycheck:ignore=esmeta-ignore.json'

28 changes: 28 additions & 0 deletions .github/workflows/ipr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: 'ecma-262'

on:
pull_request_target:
branches:
- '*'
push:
branches:
- main

jobs:
build:
name: 'check IPR form'
runs-on: ubuntu-22.04

steps:
- uses: actions/checkout@v4
- uses: ljharb/actions/node/install@dfd9796898850cf07630d1bd4053a7c9a379e90f
name: 'nvm install lts/* && npm ci --no-audit'
env:
NPM_CONFIG_AUDIT: false
with:
node-version: lts/*
use-npm-ci: true
- run: npm run ipr-check ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || 'HEAD' }}
env:
GH_TOKEN: ${{ secrets.GH_IPR_TOKEN }}
GOOGLE_API_KEY: ${{ secrets.GOOGLE_API_KEY }}
25 changes: 25 additions & 0 deletions .github/workflows/preview-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Build Preview

on: [pull_request]

jobs:
build:
name: 'build PR preview'
runs-on: ubuntu-22.04

steps:
- uses: actions/checkout@v4
- uses: ljharb/actions/node/install@dfd9796898850cf07630d1bd4053a7c9a379e90f
name: 'nvm install lts/* && npm ci --no-audit'
env:
NPM_CONFIG_AUDIT: false
with:
node-version: lts/*
use-npm-ci: true
- run: npm run build-only
- run: node scripts/insert_snapshot_warning
- run: echo ${{ github.event.number }} > out/pr.txt
- uses: actions/upload-artifact@v4
with:
name: out
path: out/
61 changes: 61 additions & 0 deletions .github/workflows/preview.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: Upload Preview

on:
workflow_run:
workflows: ["Build Preview"]
types:
- completed

jobs:
upload:
name: 'upload PR preview'
runs-on: ubuntu-22.04
if: >
${{
github.event.workflow_run.event == 'pull_request' &&
github.event.workflow_run.conclusion == 'success' &&
github.repository == 'tc39/ecma262'
}}
steps:
- uses: actions/checkout@v4
- uses: ljharb/actions/node/install@dfd9796898850cf07630d1bd4053a7c9a379e90f
name: 'nvm install lts/* && npm ci --no-audit'
env:
NPM_CONFIG_AUDIT: false
with:
node-version: lts/*
use-npm-ci: true
- name: 'Download artifact'
uses: actions/github-script@v7
with:
script: |
const { owner, repo } = context.repo;
const artifacts = await github.rest.listWorkflowRunArtifacts({
owner,
repo,
run_id: ${{ github.event.workflow_run.id }},
});
const { id: artifact_id } = artifacts.data.artifacts.find((artifact) => artifact.name == 'out');
const download = await github.rest.downloadArtifact({
owner,
repo,
artifact_id,
archive_format: 'zip',
});
const fs = require('fs');
fs.writeFileSync('${{ github.workspace }}/out.zip', Buffer.from(download.data));
- run: unzip -o out.zip -d out
- name: 'debug info'
uses: actions/github-script@v7
with:
script: |
console.log(${{ toJson(github.event) }});
- run: head -n1 out/pr.txt | grep -e '^[1-9][0-9]*$'
name: 'validate PR number from archive'
- run: echo "PULL_REQUEST=$(head -n1 out/pr.txt)" >> $GITHUB_ENV
- run: rm out/pr.txt && echo $PULL_REQUEST
- run: node scripts/publish-preview
env:
CI_PREVIEW_TOKEN: ${{ secrets.CI_PREVIEW_TOKEN }}
GITHUB_HEAD_SHA: ${{ github.event.workflow_run.head_commit.id }}
32 changes: 32 additions & 0 deletions .github/workflows/publish-biblio.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: 'ecma-262-biblio'

on:
push:
branches:
- main

jobs:
publish:
name: 'publish ecma262-biblio'
runs-on: ubuntu-22.04
if: ${{ github.repository == 'tc39/ecma262' }}

steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Setup node
uses: actions/setup-node@v4
with:
node-version: 'lts/*'
registry-url: 'https://registry.npmjs.org'

- name: Install dependencies
run: npm ci --no-audit

- name: Publish biblio
run: scripts/publish-biblio.sh
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN_FOR_TC39_USER }}
12 changes: 12 additions & 0 deletions .github/workflows/require-allow-edits.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
name: Require “Allow Edits”

on: [pull_request]

jobs:
_:
name: "Require “Allow Edits”"

runs-on: ubuntu-22.04

steps:
- uses: ljharb/require-allow-edits@main
24 changes: 24 additions & 0 deletions .github/workflows/spellcheck.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: 'ecma-262'

on: [pull_request]

jobs:
spellcheck:
name: 'check for newly-introduced spelling errors'
runs-on: ubuntu-22.04

steps:
- run: sudo apt-get install aspell
- uses: actions/checkout@v4
with:
# Number of commits to fetch. 0 indicates all history for all branches and tags.
# Default: 1
fetch-depth: 0
- uses: ljharb/actions/node/install@dfd9796898850cf07630d1bd4053a7c9a379e90f
name: 'nvm install lts/* && npm ci --no-audit'
env:
NPM_CONFIG_AUDIT: false
with:
node-version: lts/*
use-npm-ci: true
- run: node scripts/spellcheck.mjs origin/"${GITHUB_BASE_REF}"
5 changes: 3 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
node_modules/
out/
vendor/esmeta
test*.js
aspell.txt

# Only apps should have lockfiles
# lockfiles we don't use are ignored
npm-shrinkwrap.json
package-lock.json
yarn.lock
13 changes: 0 additions & 13 deletions .travis.yml

This file was deleted.

2 changes: 1 addition & 1 deletion CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
This repository is a TC39 project and subscribes to its [code of conduct](https://tc39.github.io/code-of-conduct/). It is available at [https://tc39.github.io/code-of-conduct/](https://tc39.github.io/code-of-conduct/).
This repository is a TC39 project and subscribes to its [code of conduct](https://tc39.es/code-of-conduct/). It is available at [https://tc39.es/code-of-conduct/](https://tc39.es/code-of-conduct/).

To ask a question or report an issue, please email [tc39-conduct-reports@googlegroups.com](mailto:tc39-conduct-reports@googlegroups.com).
Loading