mirror of
https://github.com/wesnoth/wesnoth
synced 2025-04-24 20:27:40 +00:00
Config: attempt to reenable append_children optimization
This commit is contained in:
parent
a52c5e133a
commit
4d086b6db4
@ -172,8 +172,6 @@ void config::append_children(const config& cfg)
|
||||
|
||||
void config::append_children(config&& cfg)
|
||||
{
|
||||
#if 0
|
||||
//For some unknown reason this doesn't compile.
|
||||
if(children_.empty()) {
|
||||
//optimisation
|
||||
children_ = std::move(cfg.children_);
|
||||
@ -181,7 +179,6 @@ void config::append_children(config&& cfg)
|
||||
cfg.clear_all_children();
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
for(const any_child value : cfg.all_children_range()) {
|
||||
add_child(value.key, std::move(value.cfg));
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user