Skip to content

Level constants screaming CAPS #438

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

Open
alextekartik opened this issue Sep 27, 2018 · 5 comments
Open

Level constants screaming CAPS #438

alextekartik opened this issue Sep 27, 2018 · 5 comments

Comments

@alextekartik
Copy link

Level constants still have screaming CAPS such as:

static const Level FINEST = const Level('FINEST', 300);

Is there any plan to change that (or is this package to be deprecated) or would you accept any pull request on this. If yes would change be for the previous example:

static const Level finest = const Level('FINEST', 300);

or

static const Level finest = const Level('finest', 300);
@natebosch
Copy link
Member

See some discussion at dart-archive/logging#46

I'm somewhat inclined to do this - there will be a fair amount of churn but it's not going to be difficult to do and we'll be churning lots of code anyway.

@kevmoo @jakemac53 - assuming we'll be having a breaking version bump for null safety - would you still be opposed to this?

@kevmoo
Copy link
Member

kevmoo commented Mar 12, 2020 via email

@allentv
Copy link

allentv commented May 10, 2020

Is there an industry wide preference to move away from ALL CAPS to lowercase? If so, then I would say the cost of switching would be justified. When I started programming 15 years ago, constants were always in ALL CAPS. Haven't heard any discussions on this case recently though. So I am curious to understand why the inclination towards the change in case?

@natebosch
Copy link
Member

Is there an industry wide preference to move away from ALL CAPS to lowercase?

There is at least a Dart preference. https://dart.dev/guides/language/effective-dart/style#prefer-using-lowercamelcase-for-constant-names

@mleonhard
Copy link

Do not make this change. See the detailed explanation in dart-lang/sdk#58508 .

@mosuem mosuem transferred this issue from dart-archive/logging Oct 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants