-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Usage of static fields #12
Labels
Comments
@eugene-nikolaev I'm not managing this repo, remove the webhook or contact me in Slack //cc @yegor256 |
Job #12 is now in scope, role is |
Thanks for your contribution, @eugene-nikolaev/z! If you would be a member of the project, you would now earn +15 reputation points, as explained in §29. You can join and apply to it, see §2. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@yegor256, I cannot figure out what are criteria for making a field static or not.
E.g.
After reading your books I often hesitate to make something static but sometimes pretty constant non-static fields looks weird.
Where is the line which should be drawn?
I think it is more like OK than not?:
Bit why this isn't really a ctor?
Well, I guess it should be fixed as long as the methods aren't being used in a static context or in
this(...)
:So, what is a legal use of static fields? Is it OK for really definitions which are unlikely will need to be overriden (say even in the unit-tests)?
The text was updated successfully, but these errors were encountered: