Skip to content

Conversation

@chandanch
Copy link
Contributor

No description provided.

class Singleton {
// A variable which stores the singleton object. Intially,
// the variable acts like a placeholder
private static __singleton: Singleton = null;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you change the name of the instance to singleton?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sure

@torokmark torokmark merged commit fb03481 into torokmark:master Dec 5, 2017
@fredrik-macrobond
Copy link

You could make the constructor private.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants