This patch rethinks the way indexed property storage works:
Instead of having a cut-off point at 200 elements where we always move
to generic property storage, we now allow arrays to stay in simple mode
as long as we don't create a gap/hole larger than 200 elements.
We also simplify generic storage to only have a hash map (for now)
instead of juggling both a vector and a hash map. This is mostly fine
since the vast majority of arrays get to stay simple now.
This is a huge speedup on anything that uses basic JS arrays with more
than 200 elements in them. :^)
Otherwise we continuously lose the first sparse element (at index
SPARSE_ARRAY_THRESHOLD) without noticing, as we overwrite all indices
with the value at index+1.
Fixes#5884.
Previously, libc.a contained undefined symbols from ssp and libsystem,
which caused static compilation to fail.
We now generate libc.a with a custom CMake rule that combines all
object files from libc, ssp and libsystem to form libc.a
Closes#5758.
Since we already have a type enum for these, let's use it to make
is<T> bypass dynamic_cast for CSS rules.
These were often near the top of random browser profiles.
Columns can now be best-fit resized by double-clicking their
grabbable edges. When a default width is set and all data is empty,
double-clicking will restore the column to its original state.
Under some circumstances we need to ignore unsupported preprocessor
keywords instead of crashing the processing, for example during live
parsing in HackStudio.
This commit makes sure that we fail if an encoded lz77 back reference
references bytes that are outside our sliding window, instead of just
silently failing, which triggers an assertion down the line.
Instead of counting the number of call frames on the VM stack, we now
always fake the "arguments" object when the current call frame has
a callee value.
This fixes an issue with DOM event handlers in LibWeb not being able
to access "arguments" since they were called without an outer frame.
With a little help (read: copy & paste) from ImageWidget, QuickShow will
now cycle through the frames of animated images - enjoy the cat GIFs!
Future improvement: cache decoded images like LibWeb's ImageResource to
waste less CPU - the same applies to LibGUI though, maybe we can put
something shared in LibGfx.
Closes#5837.
The image decoder already tells us whether the image is animated and it
can provide more than one frame, let's not put this behind an artificial
"file path must end with lowercase .gif" barrier.
Since we were not checking for error flags set by read_bits we would
just always read 0 as the bits' value, which in some edge cases could
lead to an infinite loop.
We now read the header into a temporary header byte array that is used
as the header once its filled up by the input stream, instead of just
ending the stream if we are out of bytes mid header.
At the cost of using more read() syscalls, process the DSR response
character-by-character.
This avoids blocking forever waiting for an 'R' that will never come :P
Checking for the existence of a call frame is not enough to check if
we're in a function call, as the global execution context is a regular
call frame as well.
Found by OSS-Fuzz, where simply accessing "arguments" in the global
scope would crash due to call_frame().callee being an empty value
(https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=32115).
It's a little awkward that we do this in two places, but IPWV and OOPWV
currently implement resizing a little differently from each other so we
need to cover both paths.
This was a kludge to paint ComboBox editors before the advent of
accessory windows, isn't being used anymore, and was inadvertently
letting two ComboBoxes paint as if both had focus.