Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dead code cleanup #242

Open
micrococo opened this issue Apr 22, 2020 · 5 comments
Open

Dead code cleanup #242

micrococo opened this issue Apr 22, 2020 · 5 comments

Comments

@micrococo
Copy link
Contributor

qps has a lot of dead code:

  • Code in conditional blocks with conditions that are always false.
  • Unused variables, functions and classes.
  • Commented code and functions with all of its code commented.

Are pull request removing that code accepted or is it kept for something? And what about MOSIX (that is a proprietary operating system) specific code?

@tsujan
Copy link
Member

tsujan commented Apr 22, 2020

We're aware of that and have removed some redundant codes.

So far, our focus was on making Qps really work fine and that's done. Now, it's time for serious code cleanup, which will take a lot of time -- and is boring ;) It should be done with care; we don't want to damage the functionality. In some places, the whole code structure may need to be changed.

@micrococo
Copy link
Contributor Author

Yes, removal should be made with care and in several stages. I'm not profient in C++ but recently removed all the unreachable code without any noticeable issues. That made me think that it could be removed safely, but again I'm not profient in C++. I made my own task manager some time ago as an exercise to learn a bit of C++ and Qt. It works but it is dead simple compared to qps.

captura_20200422_215647

I've tried to understand the code of qps but I am not able to do so. To the eye of a noob like me, it looks like a rewrite from scratch could take less time than fixing the current code. :)

@tsujan
Copy link
Member

tsujan commented Apr 22, 2020

it looks like a rewrite from scratch could take less time than fixing the current code. :)

I don't know about other devs but, when I was fixing Qps, I had similar thoughts ;)

Anyway, if you make cleanup PRs -- which would be VERY appreciated -- please make them so that they can be reviewed as easily as possible.

@micrococo
Copy link
Contributor Author

Understood. Thanks.

@shlyakpavel
Copy link
Member

I made my own task manager some time ago as an exercise to learn a bit of C++ and Qt. It works but it is dead simple compared to qps.

Why not just to upload it on GitHub? Maybe there will be some people involved in development.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants