Skip to content

Commit

Permalink
Merge pull request #53 from cda-tum/52-narrowing-cast-errors-wawindows
Browse files Browse the repository at this point in the history
Fix issue
  • Loading branch information
micheltakken authored Sep 18, 2024
2 parents 36ba93d + b56ddc3 commit 056acef
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions src/hybridDynamics/Scheme.hh
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ Scheme<T>::Scheme(const std::shared_ptr<arch::Module<T>> module_, std::unordered

template<typename T>
void Scheme<T>::setAlpha(T alpha_) {
for (auto a : alpha) {
a = alpha_;
for (auto& a : alpha) {
a = static_cast<T>(alpha_);
}
}

Expand All @@ -57,8 +57,8 @@ void Scheme<T>::setAlpha(std::unordered_map<int, T> alpha_) {

template<typename T>
void Scheme<T>::setBeta(T beta_) {
for (auto b : beta) {
b = beta_;
for (auto& b : beta) {
b = static_cast<T>(beta_);
}
}

Expand All @@ -74,8 +74,8 @@ void Scheme<T>::setBeta(std::unordered_map<int, T> beta_) {

template<typename T>
void Scheme<T>::setTheta(int theta_) {
for (auto t : theta) {
t = theta_;
for (auto& t : theta) {
t = static_cast<T>(theta_);
}
}

Expand Down Expand Up @@ -119,4 +119,4 @@ const std::unordered_map<int, int>& Scheme<T>::getTheta() const {
return theta;
}

} // namespace mmft
} // namespace mmft

0 comments on commit 056acef

Please sign in to comment.