Pavel Sanda wrote:
Abdelrazak Younes wrote:
Please leave this const and make schedule_check_ mutable.

can you explain why (sincere question)?

Because, by definition, checking for emptyness is not something that should
change the contents of a class. The scheduled checking is an implementation
detail and the user of that class is not interested in the details.

i dont know which definition states that empty should be const

That's common sense IMO.

  and remember
reading somewhere that making conditions in your program which are based on
mutable variable shows there is something wrong.
in general yes. For scheduling something or implementing a cache, this is a very common practice.

  not only we are chaning
internal data structures, but also we change the behaviour wrt interaction with
clipboard.
As I said this is an implementation detail that pollutes the clipboard virtual interface (clipboard.h). If you don't like "mutable", move that code to a private implementation in GuiClipboard.cpp

Abdel.

Reply via email to