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
Remove explicit conversion to std::string when it's not required.
[simgrid.git]
/
src
/
s4u
/
s4u_Netzone.cpp
diff --git
a/src/s4u/s4u_Netzone.cpp
b/src/s4u/s4u_Netzone.cpp
index
388cdd4
..
180eacd
100644
(file)
--- a/
src/s4u/s4u_Netzone.cpp
+++ b/
src/s4u/s4u_Netzone.cpp
@@
-170,8
+170,8
@@
s4u::SplitDuplexLink* NetZone::create_split_duplex_link(const std::string& name,
try {
speed = xbt_parse_get_bandwidth("", 0, bandwidth, "");
} catch (const simgrid::ParseError&) {
try {
speed = xbt_parse_get_bandwidth("", 0, bandwidth, "");
} catch (const simgrid::ParseError&) {
- throw std::invalid_argument(
std::string("Impossible to create split-duplex link: ")
+ name +
-
std::string(". Invalid bandwidth: ")
+ bandwidth);
+ throw std::invalid_argument(
"Impossible to create split-duplex link: "
+ name +
+
". Invalid bandwidth: "
+ bandwidth);
}
return create_split_duplex_link(name, speed);
}
}
return create_split_duplex_link(name, speed);
}
@@
-191,8
+191,7
@@
s4u::Link* NetZone::create_link(const std::string& name, const std::vector<std::
double speed = xbt_parse_get_bandwidth("", 0, speed_str, "");
bw.push_back(speed);
} catch (const simgrid::ParseError&) {
double speed = xbt_parse_get_bandwidth("", 0, speed_str, "");
bw.push_back(speed);
} catch (const simgrid::ParseError&) {
- throw std::invalid_argument(std::string("Impossible to create link: ") + name +
- std::string(". Invalid bandwidth: ") + speed_str);
+ throw std::invalid_argument("Impossible to create link: " + name + ". Invalid bandwidth: " + speed_str);
}
}
return create_link(name, bw);
}
}
return create_link(name, bw);