A
lgorithmique
N
umérique
D
istribuée
Public GIT Repository
projects
/
simgrid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Improve coverage :p
[simgrid.git]
/
src
/
kernel
/
activity
/
ExecImpl.cpp
diff --git
a/src/kernel/activity/ExecImpl.cpp
b/src/kernel/activity/ExecImpl.cpp
index
d80b853
..
e3d9d32
100644
(file)
--- a/
src/kernel/activity/ExecImpl.cpp
+++ b/
src/kernel/activity/ExecImpl.cpp
@@
-88,9
+88,7
@@
namespace activity {
ExecImpl& ExecImpl::set_host(s4u::Host* host)
{
ExecImpl& ExecImpl::set_host(s4u::Host* host)
{
- if (not hosts_.empty())
- hosts_.clear();
- hosts_.push_back(host);
+ hosts_.assign(1, host);
return *this;
}
return *this;
}
@@
-111,9
+109,7
@@
ExecImpl& ExecImpl::set_timeout(double timeout)
ExecImpl& ExecImpl::set_flops_amount(double flops_amount)
{
ExecImpl& ExecImpl::set_flops_amount(double flops_amount)
{
- if (not flops_amounts_.empty())
- flops_amounts_.clear();
- flops_amounts_.push_back(flops_amount);
+ flops_amounts_.assign(1, flops_amount);
return *this;
}
return *this;
}