Skip to content

Commit

Permalink
Unescape includes() method
Browse files Browse the repository at this point in the history
"includes" was added to the WebIDL grammar to avoid needing escaping:

https://heycam.github.io/webidl/#prod-OperationName

Fixes #294
  • Loading branch information
inexorabletash authored Sep 24, 2019
1 parent 2bc2e3c commit d3943e1
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions index.bs
Original file line number Diff line number Diff line change
Expand Up @@ -4214,14 +4214,10 @@ interface IDBKeyRange {
optional boolean lowerOpen = false,
optional boolean upperOpen = false);

boolean _includes(any key);
boolean includes(any key);
};
</xmp>

<aside class=note>
Note: When mapping the `_includes` identifier from [[WEBIDL]] to ECMAScript, the leading U+005F LOW LINE ("_") character is removed. A leading "_" is used to escape the identifier from looking like a reserved word (in this case, the `includes` keyword).
</aside>

<dl class="domintro note">
: |range| . {{IDBKeyRange/lower}}
:: Returns the range's [=lower bound=], or `undefined` if none.
Expand Down Expand Up @@ -4361,7 +4357,7 @@ The <dfn method for=IDBKeyRange>bound(|lower|, |upper|, |lowerOpen|,

<div class=algorithm>

The <dfn method for=IDBKeyRange lt="_includes(key)|includes(key)">includes(|key|)</dfn> method, when
The <dfn method for=IDBKeyRange>includes(|key|)</dfn> method, when
invoked, must run these steps:

1. Let |k| be the result of running [=convert a
Expand Down Expand Up @@ -6894,6 +6890,7 @@ For the revision history of the second edition, see [that document's Revision Hi
* Added {{IDBTransaction/commit()}} method. ([Issue #234](https://github.com/w3c/IndexedDB/issues/234))
* Added {{IDBCursor/request}} attribute. ([Issue #255](https://github.com/w3c/IndexedDB/issues/255))
* Removed handling for nonstandard `lastModifiedDate` property of {{File}} objects. ([Issue #215](https://github.com/w3c/IndexedDB/issues/215))
* Remove escaping {{IDBKeyRange/includes()}} method. ([Issue #294](https://github.com/w3c/IndexedDB/issues/294))

<!-- ============================================================ -->
# Acknowledgements # {#acknowledgements}
Expand Down

0 comments on commit d3943e1

Please sign in to comment.