Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Esm tests #1

Closed
wants to merge 12 commits into from
Closed

Esm tests #1

wants to merge 12 commits into from

Conversation

aduh95
Copy link

@aduh95 aduh95 commented Feb 15, 2021

This rewrites the test in ESM so the test can pass. We probably want to add a CJS test as well to make sure this still works for users that still want to use the old syntax.

This includes highlightjs#3009, needed because ESM dooesn't let you remove an entry from the cache.

Changes

Checklist

  • Added markup tests, or they don't apply here because...
  • Updated the changelog at CHANGES.md
  • Added myself to AUTHORS.txt, under Contributors

Ayesh and others added 5 commits February 14, 2021 12:35
* [PHP] Add WeakMap class to internal list

PHP 8.0 adds a new [`WeakMap` built-in class](https://php.watch/versions/8.0/weakmap). Adding it to `KEYWORDS.keyword` list.

* [PHP] Add `UnhandledMatchError` exception type

PHP 8.0 match expression throws an [`UnhandledMatchError` exception](https://php.watch/versions/8.0/match-expression#UnhandledMatchError). It's a new built-in exception type, and adding it the keywords list.

* [PHP] Add new `mixed` type in PHP 8.0

PHP 8.0 adds a new [`mixed` type](https://php.watch/versions/8.0/mixed-type) as a new reserved keyword and a type.

* [PHP] Add `Stringable` interface

PHP 8.0 adds a new built-in interface called [`Stringable`](https://php.watch/versions/8.0/stringable). Adding it to the keywords list.

* [PHP] Add `trait` to list of class-like naming patterns

Traits follow [class-like syntax](https://www.php.net/manual/en/language.oop5.traits.php), and was missing from the class-like naming pattern matches.

* [PHP] Update tests with a `match` expression

* [PHP] Number pattern improvements

Expands the number detection to support to all numerals supported up to PHP 8.1.
 - Decimal numbers
 - Floats
 - Binary numbers (`0b1100` and `0B1100`).
 - Hex number support (`0xAFAF` and `0XAFAF`).
 - Octal number support (`0777`)
 - [New `0o` and `0O` prefix support for Octals](https://php.watch/versions/8.1/explicit-octal-notation) (`0o777` and `0O777`) (Already accepted and merged to upcoming PHP 8.1)
 - Scientific notation (`7E-10` and `1.2e3`)
 - [Underscore number separator](https://php.watch/versions/7.4/underscore_numeric_separator) (Already implemented in PHP 7.4)

* [PHP] Misc updates to CHANGES, AUTHORS, and SUPPORTED_LANGUAGES files
@aduh95 aduh95 closed this Feb 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants