mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-26 19:29:16 +00:00
AK: Rename adopt() to adopt_ref()
This makes it more symmetrical with adopt_own() (which is used to create a NonnullOwnPtr from the result of a naked new.)
This commit is contained in:
@@ -84,7 +84,7 @@ bool Parser::expect(const StringView& expected)
|
||||
template<typename A, typename... Args>
|
||||
NonnullRefPtr<A> Parser::create(Args... args)
|
||||
{
|
||||
return adopt(*new A(AST::Position { m_rule_start_offsets.last(), m_offset, m_rule_start_lines.last(), line() }, args...));
|
||||
return adopt_ref(*new A(AST::Position { m_rule_start_offsets.last(), m_offset, m_rule_start_lines.last(), line() }, args...));
|
||||
}
|
||||
|
||||
[[nodiscard]] OwnPtr<Parser::ScopedOffset> Parser::push_start()
|
||||
|
||||
Reference in New Issue
Block a user