/* s4u::Engine Simulation Engine and global functions. */
-/* Copyright (c) 2006-2022. The SimGrid Team. All rights reserved. */
+/* Copyright (c) 2006-2023. The SimGrid Team. All rights reserved. */
/* This program is free software; you can redistribute it and/or modify it
* under the terms of the license (GNU LGPL) which comes with this package. */
{
auto* host = host_by_name_or_null(name);
if (not host)
- throw std::invalid_argument(std::string("Host not found: '") + name + std::string("'"));
+ throw std::invalid_argument("Host not found: '" + name + "'");
return host;
}
{
auto* link = link_by_name_or_null(name);
if (not link)
- throw std::invalid_argument(std::string("Link not found: ") + name);
+ throw std::invalid_argument("Link not found: " + name);
return link;
}
{
auto* link_impl = pimpl->netzone_root_ ? pimpl->netzone_root_->get_split_duplex_link_by_name_or_null(name) : nullptr;
if (not link_impl)
- throw std::invalid_argument(std::string("Link not found: ") + name);
+ throw std::invalid_argument("Link not found: " + name);
return link_impl->get_iface();
}
{
auto netp = netpoint_by_name_or_null(name);
if (netp == nullptr) {
- throw std::invalid_argument(std::string("Netpoint not found: %s") + name);
+ throw std::invalid_argument("Netpoint not found: " + name);
}
return netp;
}
void simgrid_set_maestro(void (*code)(void*), void* data)
{
-#ifdef _WIN32
- XBT_WARN("simgrid_set_maestro is believed to not work on windows. Please help us investigating this issue if "
- "you need that feature");
-#endif
maestro_code = std::bind(code, data);
}