Singleton: Difference between revisions

Content added Content deleted
Line 1,153: Line 1,153:
=={{header|Oforth}}==
=={{header|Oforth}}==


Oforth does not have global variables, class attributes or some kind of shared memory that can be updated between tasks.
Oforth does not have global variables, class attributes or some kind of shared mutable memory that can be updated by different tasks.


In Oforth, singleton is an anti-pattern because it needs synchronisation in order to be safe between tasks.
In Oforth, singleton is an anti-pattern because it needs synchronisation in order to be safe between tasks.