A const method can't affect other threads, but other threads can

> affect a const method.
>
> Suppose a const function is reading a large data object. If the object
> wasn't locked, other threads could modify it while the first function
> is in the middle of reading it, potentially corrupting the result of
> the first function.
>

You're right. But I was asking about the specific senario the OP mentioned,
i.e with only readers operating on an object, no writers.

Thanks,
-mandeep


>
> Sze-Howe
>
_______________________________________________
Interest mailing list
[email protected]
http://lists.qt-project.org/mailman/listinfo/interest

Reply via email to