Closed leonardocarreras closed 6 months ago
A remaining question would be if we explicitly declare the override
in the case of the SynchronGenerator
files
Kudos, SonarCloud Quality Gate passed!
0 Bugs
0 Vulnerabilities
0 Security Hotspots
0 Code Smells
0.0% Coverage
25.0% Duplication
The version of Java (11.0.14.1) you have used to run this analysis is deprecated and we will stop accepting it soon. Please update to at least Java 17. Read more here
But in general: we should prefer passing
const std::string &
in favour ofString
as it would copy the string and is a lot slower due to additional copies.
Should we make that as a new issue? In a quick search, we get this way of doing it by copying in 75 files, versus the only the 4 files modified here...
I guess it is still an option to discard this part of the changes and maybe think of the deprecation notice that was here and a better way of doing it by modifying the base class https://github.com/sogno-platform/dpsim/blob/e0ae9d97db67b9554f019fc45dafa76f59a4da9e/dpsim-models/include/dpsim-models/SimPowerComp.h#L58-L61
Should we make that as a new issue? In a quick search, we get this way of doing it by copying in 75 files, versus the only the 4 files modified here...
I can confirm this. All these are actually detected by cppcheck. However, we dont show these performance warnings in the CI log due to:
@leonardocarreras sorry, for not merging sooner. Could you please rebase and I will merge it. The changes look good to me too.
@m-mirz now is WIP, the rebase becomes a bit more interesting than expected
Thanks for the suggestions, will adopt them... Just to keep track, there is now also an alternate solution in #293 (that also do some extra things)
sorry. I didn't look if someone else was already working on it. I hope it doesn't create too much work if we merge my PR first.
If your PR is ready to merge I can rebase after that
Issues
9 New issues
0 Accepted issues
Measures
0 Security Hotspots
0.0% Coverage on New Code
29.4% Duplication on New Code
Moved to #294
This PR changes the signature of the
log
function in theDiakopticsSolver
files to match the current ones used in the other solvers, where we have now two arguments.On the other side, the overrides on the
SynchronGenerator
files of the functionclone
had a different signature compared to all the rest of the classes (and did not override the Base class virtual function.This PR fixes issue #256