1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 05:47:35 +00:00

LibWeb: Port CSS::Parser::Rule to new Strings

`Rule::to_deprecated_string()` and
`DeclarationOrAtRule::to_deprecated_string()` are not used anywhere, so
we can just delete them.
This commit is contained in:
Sam Atkins 2023-02-15 11:28:44 +00:00 committed by Tim Flynn
parent bee32b6cd2
commit 41c4cc95e4
5 changed files with 10 additions and 49 deletions

View file

@ -1,6 +1,6 @@
/*
* Copyright (c) 2020-2021, the SerenityOS developers.
* Copyright (c) 2021-2022, Sam Atkins <atkinssj@serenityos.org>
* Copyright (c) 2021-2023, Sam Atkins <atkinssj@serenityos.org>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
@ -24,20 +24,4 @@ DeclarationOrAtRule::DeclarationOrAtRule(Declaration declaration)
DeclarationOrAtRule::~DeclarationOrAtRule() = default;
DeprecatedString DeclarationOrAtRule::to_deprecated_string() const
{
StringBuilder builder;
switch (m_type) {
default:
case DeclarationType::At:
builder.append(m_at->to_deprecated_string());
break;
case DeclarationType::Declaration:
builder.append(m_declaration->to_string().release_value_but_fixme_should_propagate_errors());
break;
}
return builder.to_deprecated_string();
}
}