Skip to content
Snippets Groups Projects
Commit cfb72f26 authored by Ian Bell's avatar Ian Bell
Browse files

Turn lambdas to functions

parent a35c93c5
No related branches found
No related tags found
No related merge requests found
...@@ -69,13 +69,13 @@ namespace teqp { ...@@ -69,13 +69,13 @@ namespace teqp {
} }
} }
auto toeig = [](const std::vector<double>& v) -> Eigen::ArrayXd { return Eigen::Map<const Eigen::ArrayXd>(&(v[0]), v.size()); }; inline auto toeig (const std::vector<double>& v) -> Eigen::ArrayXd { return Eigen::Map<const Eigen::ArrayXd>(&(v[0]), v.size()); }
auto all_same_length = [](const nlohmann::json& j, const std::vector<std::string>& ks) { inline auto all_same_length(const nlohmann::json& j, const std::vector<std::string>& ks) {
std::set<decltype(j[0].size())> lengths; std::set<decltype(j[0].size())> lengths;
for (auto k : ks) { lengths.insert(j[k].size()); } for (auto k : ks) { lengths.insert(j[k].size()); }
return lengths.size() == 1; return lengths.size() == 1;
}; }
class Timer { class Timer {
private: private:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment