mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-01-23 17:52:26 -05:00
f991e40d7f
This change allows IDL interfaces to be compiled using new AK String which have a attribute in the interface that may return null. Without this change we would run into a compile error from code such as the following example: ``` auto retval = impl->deprecated_attribute(HTML::AttributeNames::ref); if (!retval.has_value()) { return JS::js_null(); } return JS::PrimitiveString::create(vm, retval.release_value()); ``` As `deprecated_attribute` returns a `DeprecatedString` instead of an `Optional<String>`. Fix that by using the non-deprecated attribute implementation, and falling back to the empty string for where we cannot return null. Also add a test here to cover a regression I almost introduced here which was not previously covered by our test suite. Ideally, all of this should actually just be calling Element::get_attribute_value, but I'm not entirely sure at this stage what the behavioral change would be to test for here. Since this implementation preserves the previous behavior, stick with it, and add a FIXME for now. |
||
---|---|---|
.. | ||
Azure | ||
CMake | ||
gn | ||
HeaderCheck | ||
Lagom | ||
Screenshots | ||
ShellCompletions/zsh | ||
Websites | ||
analyze-qemu-coverage.sh | ||
bochsrc | ||
build-image-extlinux.sh | ||
build-image-grub.sh | ||
build-image-limine.sh | ||
build-image-qemu.sh | ||
build-manpages-website.sh | ||
build-native-partition.sh | ||
build-root-filesystem.sh | ||
check-ak-test-files.sh | ||
check-debug-flags.sh | ||
check-emoji.py | ||
check-markdown.sh | ||
check-newlines-at-eof.py | ||
check-png-sizes.sh | ||
check-style.py | ||
check-symbols.sh | ||
convert-markdown-links.lua | ||
debug-kernel.sh | ||
embed_as_string_view.py | ||
export-argsparser-manpages.sh | ||
extlinux.conf | ||
generate-embedded-resource-assembly.sh | ||
generate-libwasm-spec-test.py | ||
generate-libwasm-spec-test.sh | ||
grub-ebr.cfg | ||
grub-gpt.cfg | ||
grub-mbr.cfg | ||
install-ports-tree.sh | ||
label-pull-requests.js | ||
limine.cfg | ||
lint-ci.sh | ||
lint-clang-format.sh | ||
lint-commit.sh | ||
lint-executable-resources.sh | ||
lint-gml-format.sh | ||
lint-gn.sh | ||
lint-keymaps.py | ||
lint-ports.py | ||
lint-prettier.sh | ||
lint-python.sh | ||
lint-shell-scripts.sh | ||
new-project.sh | ||
refresh-serenity-qtcreator.sh | ||
run.sh | ||
serenity.sh | ||
serenity_gdb.py | ||
shell_include.sh | ||
toot-commits.js | ||
tweet-commits.js |