Commit graph

725 commits

Author SHA1 Message Date
Gaming4JC
f08c44f010 Bug 1390082 - Implement AsyncGeneratorQueue with simpler array operations.
Tag #1287

Note: Without ReadableStream implementation
2019-12-18 09:17:09 +08:00
Gaming4JC
586cd0b71b Bug 1379525 - Part 2: Properly handle rejection in async-from-sync iteration.
Tag #1287
2019-12-18 09:17:08 +08:00
Gaming4JC
9e8369d01f Bug 1379525 - Part 1: Await on the value before yielding or returning inside async generator.
Tag #1287
2019-12-18 09:17:06 +08:00
Gaming4JC
ba1cf5608c Bug 1364608 - Stash rval in AsyncIteratorClose.
Tag #1287
2019-12-18 09:17:05 +08:00
Gaming4JC
3206741afa Bug 1355399 - Switch property retrieval in Async-from-Sync Iterator prototype methods.
Tag #1287
2019-12-18 09:17:04 +08:00
Gaming4JC
9cecb72f37 Bug 1331092 - Part 11: Await on the innerResult.value when innerResult.done is true in yield*.
Tag #1287
2019-12-18 09:17:02 +08:00
Gaming4JC
9379133c2d Bug 1331092 - Part 9: Implement for-await-of.
Tag #1287
2019-12-18 09:17:01 +08:00
Gaming4JC
06b3cb6ccd Bug 1331092 - Part 8: Support JSOP_TOASYNCITER in JIT.
Tag #1287
2019-12-18 09:17:00 +08:00
Gaming4JC
142e8bf444 Bug 1331092 - Part 7: Implement Async Generator yield*.
Tag #1287
2019-12-18 09:16:59 +08:00
Gaming4JC
67b8cd621a Bug 1331092 - Part 6: Support JSOP_TOASYNCGEN in JIT.
Tag #1287
2019-12-18 09:16:57 +08:00
Gaming4JC
b5bcbfe58c Bug 1331092 - Part 2: Implement Async Generator except yield*.
Tag #1287
2019-12-18 09:16:56 +08:00
Gaming4JC
10b93afff4 Bug 1331092 - Part 2: Implement Async Generator except yield*.
Tag #1287
2019-12-18 09:16:52 +08:00
Gaming4JC
c8d569d1b8 Bug 1331092 - Part 1: Add Symbol.asyncIterator.
Tag #1287
2019-12-18 09:16:06 +08:00
Gaming4JC
e9ad9eab15 Bug 1331092 - Part 0: Define NOMINMAX to avoid compile error from min/max macro on windows.
Tag #1287
2019-12-18 09:16:05 +08:00
Gaming4JC
22cd310e82 Bug 1317389: Change property attributes for generator and async functions to match ES2015/2017.
Tag #1287
2019-12-18 09:16:03 +08:00
Gaming4JC
086d14cb8b Bug 1344753 - Update for-of stack depth in ControlFlowGenerator::processWhileOrForInLoop.
Tag #1287
2019-12-18 09:16:02 +08:00
Gaming4JC
c9f1fa2cda Bug 1316098 - Optimize out result object allocation for await/return in async function.
Tag #1287
2019-12-18 09:16:01 +08:00
Gaming4JC
c1bdfa62fc Bug 1343481 - Part 7: Add BytecodeEmitter::emitDotGenerator and make yield/await nodes unary.
Tag #1287
2019-12-18 09:15:59 +08:00
Gaming4JC
2bbebc6ebc Bug 1343481 - Part 6: Add native functions wrapper for GetInternalError and GetTypeError.
Tag #1287
2019-12-18 09:15:58 +08:00
Gaming4JC
04ec8aaf1c Bug 1343481 - Part 5: Rename AsyncFunction-related names in Promise.cpp to explicitly say Async Function.
Tag #1287
2019-12-18 09:15:56 +08:00
Gaming4JC
bc80cb0d51 Bug 1343481 - Part 4: Add Add GeneratorObject.{isAfterYield,isAfterAwait}.
Tag #1287
2019-12-18 09:15:55 +08:00
Gaming4JC
a6872d9ea3 Bug 1343481 - Part 3: Add JSOP_AWAIT and rename {yieldIndex,yieldOffset} to {yieldAndAwaitIndex,yieldAndAwaitOffset}.
Tag #1287
2019-12-18 09:15:54 +08:00
Gaming4JC
45337018ef Bug 1343481 - Part 2: Stop using StarGegerator for async function.
Tag #1287
2019-12-18 09:15:52 +08:00
Gaming4JC
7eb5d46c11 Bug 1343481 - Part 1: Remove {JSFunction,JSScript,LazyScript}.isGenerator() method.
Tag #1287
2019-12-18 09:15:51 +08:00
Gaming4JC
4ce0bb5e0a Bug 1336705 - Part 2: Add self-hosting intrinsics for resolving/rejecting Promises and adding reactions.
Tag #1287
2019-12-18 09:15:50 +08:00
Gaming4JC
f15e675b86 Bug 336705 - Part 1: Support creating and resolving Promises without resolve/reject functions.
Useful for internally-created Promises that'll only ever be resolved/rejected internally.

Tag #1287
2019-12-18 09:15:49 +08:00
Gaming4JC
70cbae88ea Bug 1317376 - Part 2: Detect Promise self-resolution when resolving through the Promise resolving fast path.
Tag #1287
2019-12-18 09:15:47 +08:00
Gaming4JC
300f97150c Bug 1317376 - Part 1: Remove unreachable code and remnants from the self-hosted implementation.
Tag #1287
2019-12-18 09:15:46 +08:00
wolfbeast
37e3ac713b Issue #1302 followup - Add spec-compliance checks/errors
- Check for undefined/null regex flags (because...)
- Make it throw a typeerror instead of syntax error on non-global
- Generalize JS error messages for these checks.
2019-12-02 15:45:58 +08:00
wolfbeast
c16e82c9b1 Issue #1302 - Add self-hosted implementation for string regex .matchAll
This resolves #1302.
2019-11-28 10:32:42 +08:00
Gaming4JC
211c1e4e7b Issue #1284 - Update js/src/builtin/TestingFunctions.cpp for /s (dotAll) regular expression changes
This fixes debug builds
2019-11-22 10:52:04 +08:00
wolfbeast
8148cf0001 Issue #1284 - Implement /s (dotAll) for regular expressions, v2.
Resolves #1284.
2019-11-22 10:52:02 +08:00
Gaming4JC
59a1758d89 Issue #1279 - Update js/src/builtin/TestingFunctions.cpp for regex lookbehind changes
This fixes debug builds
2019-11-15 14:24:14 +08:00
wolfbeast
63b7dedc94 Issue #1279 - Implement regular expression lookbehind
Based on Tom Schuster's work, with extra minters for unicode.
2019-11-15 14:23:10 +08:00
André Bargull
ff54e6899f Issue #1283 - Implement Promise.prototype.finally()
This resolves #1283.
2019-11-15 14:23:09 +08:00
janekptacijarabaci
67f5e5d20c Bug 1341298 - Relax expected module state when resolving modules and circular module dependencies are present 2019-11-11 21:57:58 +08:00
janekptacijarabaci
39a2b217b7 Bug 1341411 - Support circular module dependencies through export* per ES2017 2019-11-11 21:57:55 +08:00
janekptacijarabaci
832b047eea Bug 1339986 - Handle export* when checking for duplicate export 2019-11-11 21:57:52 +08:00
janekptacijarabaci
eaf8fcd215 Bug 1341256 - Fix module namespace object get handler 2019-11-11 21:57:50 +08:00
janekptacijarabaci
b79662ba48 Bug 1340268 - [[HasProperty]] on module namespace object should work even when binding is uninitialized 2019-11-11 21:57:48 +08:00
janekptacijarabaci
e82ffc59bb Bug 1326453 - Part 5: Remove no longer used ListIterator implementation 2019-11-11 21:57:42 +08:00
janekptacijarabaci
184438aa10 Bug 1326453 - Part 4: Return @@toStringTag in [[OwnPropertyKeys]] trap for module namespace objects 2019-11-11 21:55:13 +08:00
janekptacijarabaci
50765b944e Bug 1326453 - Part 3: Don't throw a TypeError when SetPrototypeOf for module namespace objects is called with null 2019-11-11 21:55:10 +08:00
janekptacijarabaci
307c8cb570 Bug 1326453 - Part 2: Change @@toStringTag for module namespace objects to non-configurable 2019-11-11 21:55:08 +08:00
janekptacijarabaci
99f20bdc22 Bug 1326453 - Part 1: Remove @@iterator method from module namespace objects per ES2017 2019-11-11 21:55:05 +08:00
janekptacijarabaci
db68ce927e Bug 1320993 - Fix exporting default class expression 2019-11-11 21:48:39 +08:00
athenian200
45bf760ac5 MoonchildProductions#1251 - Part 27: Fix ifdef style.
This should do it for all the commits to files I changed, but while I'm in here I could probably go ahead and turn ALL the singular if defined statements into ifdef statements by using grep/find on the tree. On the other hand, perhaps we should do that as a separate issue so that this doesn't become a case of scope creep.
2019-11-04 11:54:07 +08:00
athenian200
e27eeb28c6 MoonchildProductions#1251 - Part 25: Fix link paths.
This fix is a bit ugly and may need to be changed later if we switch a new GCC version, but the fact is that we use an architecture-specific path for GCC libraries on Solaris, so knowing the right prefix for GCC would only help so much, because it would still need to decide between ${gccdir}/lib and ${gccdir}/lib/amd64. The MOZ_FIX_LINK_PATHS variable puts the search paths into the right order without the need for me to use elfedit on the binaries afterwards.
2019-11-04 11:54:04 +08:00
athenian200
0239eb8ac9 MoonchildProductions#1251 - Part 23: Allow AMD64 build to work.
https://developer.mozilla.org/en-US/docs/Mozilla/Developer_guide/Build_Instructions/Compiling_32-bit_Firefox_on_a_Linux_64-bit_OS

Setting this up turned out to be easier than I thought it would be. All I had to do was apply these instructions in reverse and add the following to my .mozconfig file:

CC="gcc -m64"
CXX="g++ -m64"
AS="gas --64"
ac_add_options --target=x86_64-pc-solaris2.11
export PKG_CONFIG_PATH=/usr/lib/amd64/pkgconfig
ac_add_options --libdir=/usr/lib/amd64
ac_add_options --x-libraries=/usr/lib/amd64

Most of these changes were fairly trivial, just requiring me to make a few of the changes I made earlier conditional on a 32-bit build. The biggest challenge was figuring out why the JavaScript engine triggered a segfault everytime it tried to allocate memory. But this patch fixes it:

https://github.com/OpenIndiana/oi-userland/blob/oi/hipster/components/web/firefox/patches/patch-js_src_gc_Memory.cpp.patch

Turns out that Solaris on AMD64 handles memory management in a fairly unusual way with a segmented memory model, but it's not that different from what we see on other 64-bit processors. In fact, I saw a SPARC crash for a similar reason, and noticed that it looked just like mine except the numbers in the first segment were reversed. Having played around with hex editors before, I had a feeling I might be dealing with a little-endian version of a big-endian problem, but I didn't expect that knowledge to actually yield an easy solution.

https://bugzilla.mozilla.org/show_bug.cgi?id=577056

https://www.oracle.com/technetwork/server-storage/solaris10/solaris-memory-135224.html

As far as I can tell, this was the last barrier to an AMD64 Solaris build of Pale Moon.
2019-11-04 11:54:02 +08:00
athenian200
cbf60a2058 Fix a bunch of dumb typos and omissions. 2019-11-04 11:53:57 +08:00