functional: fix std::move usage in Factory::constant

This commit is contained in:
Emil J. Tywoniak 2024-10-10 16:04:01 +02:00
parent 785bd44da7
commit bc5d9d1bd3
1 changed files with 2 additions and 1 deletions

View File

@ -537,7 +537,8 @@ namespace Functional {
return add(Fn::memory_write, mem.sort(), {mem, addr, data});
}
Node constant(RTLIL::Const value) {
return add(IR::NodeData(Fn::constant, std::move(value)), Sort(value.size()), {});
int s = value.size();
return add(IR::NodeData(Fn::constant, std::move(value)), Sort(s), {});
}
Node create_pending(int width) {
return add(Fn::buf, Sort(width), {});