[Lazarus] thread safe

Lukasz Sokol el.es.cr at gmail.com
Mon Jun 27 17:37:05 CEST 2011


On 27/06/2011 15:05, Hans-Peter Diettrich wrote:
> Lukasz Sokol schrieb:
> 
>> The computer/OS/system has no clue of anything you may call 'an
>> object'... when compiled, it is just 'code'.
> 
> Right.
> 
>> OOP is just a convenient abstraction, it's for people needed only
>> :)
> 
> OOP is for designers, not for hackers ;-)
> 
> When some thread-safe code must never bring a program (automaton,
> system...) into an inconsistent state, objects are fine to break down
> the entire program into self-contained sub-systems. This allows to
> dramatically reduce the degree of freedom of the entire ("flattened")
> problem. Whatever can be done entirely inside an object, deserves no
> further consideration of everything outside the object.

What I meant (and I think) it is, is that whatever thread-safe *is*, 
is completely orthogonal i.e. not dependent on your programming 
paradigm, it is completely about the resulting code.
Therefore, *result* code can either be thread safe, or it can not be, 
there is no shades of gray here, whatever complex paradigms you apply 
to your language :)

(somebody correct me if I'm not correct ;)
L.

> 
> DoDi





More information about the Lazarus mailing list