HF RL Explorer

Task: Verify Thread Safety of C Static Constructor Singleton Pattern

Task: Verify Thread Safety of C Static Constructor Singleton Pattern: a task in Terminal-Lego-15k (Harbor dataset). In C , the static constructor (also known as a type initializer) has specific thread-safety guarantees provided by the CLR. Your task is to implement and verify that a Singleton…

The task

In C#, the static constructor (also known as a type initializer) has specific thread-safety guarantees provided by the CLR. Your task is to implement and verify that a Singleton pattern using a static constructor is indeed thread-safe by creating a multi-threaded test that attempts to break the singleton guarantee.

Part of PrimeIntellect/Terminal-Lego-15k.