Skip to content
This repository was archived by the owner on Dec 14, 2018. It is now read-only.
This repository was archived by the owner on Dec 14, 2018. It is now read-only.

Is GetOrCreate thread-safe? #359

Closed
Closed
@withinoneyear

Description

@withinoneyear

I wonder if GetOrCreate extension method thread-safe?

From the source code it seems to perform 2 steps separately - check if key exists and then add if not. No lock is being used, so is it thread-safe?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions