Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
User name:
Password:
Save Password
Forgot your password?

 All Forums
 Visual Assist
 Feature Requests
 Naming Conventions
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

FriendlyRabbit
Junior Member

Germany
20 Posts

Posted - Nov 01 2023 :  03:32:20 AM  Show Profile  Reply with Quote
Are there any plans do support checking and enforcing naming conventions? Some code inspections go in that direction, but there is no exhausting solution.

I am asking for something similar to this, where you can configure naming conventions for certain types of symbols.
https://www.jetbrains.com/help/resharper/Coding_Assistance__Naming_Style.html

feline
Whole Tomato Software

United Kingdom
18988 Posts

Posted - Nov 01 2023 :  10:13:56 AM  Show Profile  Reply with Quote
No particular current plans, partly because this is something so very individual, so would require a lot of options to work well.

Having said that, clang-tidy does have this check:

https://clang.llvm.org/extra/clang-tidy/checks/readability/identifier-naming.html

which you can enable if you tell VA to show you Unevaluated Checkers in code inspection. But without the ability to set all of the options for this check, you are going to need to rely on the defaults matching what you want to do.

I have put in a feature request to support this checker, and also allowing you to set all of the options. Given the number, it could be that is better done via a text file of some sort, rather than a GUI.

case=153852

zen is the art of being at one with the two'ness
Go to Top of Page

FriendlyRabbit
Junior Member

Germany
20 Posts

Posted - Nov 02 2023 :  02:53:03 AM  Show Profile  Reply with Quote
Thank you for mentioning this check, I have not yet noticed it. This is exactly the feature I am looking for. However, the default configuration seems to do nothing at all.

I noticed that it is possible to configure the clang-tidy checks with some JSON text "CheckOptions", see below. I wonder if you can provide a simple text entry field for each unevaluated code inspection. This would allow me to configure them using the same syntax as in the command line (see below) and to customize them to my liking without requiring you to support them one by one. What do you think about it?

clang-tidy.exe -config="{Checks: '-*,readability-identifier-naming', CheckOptions: [ {key: readability-identifier-naming.ClassCase, value: CamelCase} ]}" test.cpp -- -std=c++11
https://stackoverflow.com/questions/51711435/clang-tidy-ignores-readability-identifier-naming-on-windows


Offtopic: The clock in the forum seems to be off. I am editing this file on 9:29 UTC time but is says 5:29. Which timezone is that?

Edited by - FriendlyRabbit on Nov 02 2023 05:30:02 AM
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
18988 Posts

Posted - Nov 07 2023 :  08:33:04 AM  Show Profile  Reply with Quote
The text field per code inspection actually makes a lot more sense, I have put a note on the case about this. It seems a reasonable approach, and will work well when we have several different checks that all have complex options, which is bound to happen with time.

As for the forum timezone, the settings says it is using zero hours of adjustment from the server timezone. So, nice and clear there -4 from UTC seems to be Atlantic Standard Time, based on this page:

https://www.timeanddate.com/time/zones/

zen is the art of being at one with the two'ness
Go to Top of Page

FriendlyRabbit
Junior Member

Germany
20 Posts

Posted - Nov 07 2023 :  08:35:57 AM  Show Profile  Reply with Quote
Looking forward to that solution. Being able to access the whole configuration of these checkers gives me full control while saving you from the work of creating a GUI for every single one. Can't wait for this feature :-)
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
18988 Posts

Posted - Nov 08 2023 :  05:35:05 AM  Show Profile  Reply with Quote
I can definitely see this being popular, I am just not looking forward to trying to understand how all the settings are going to interact for this one

zen is the art of being at one with the two'ness
Go to Top of Page

mariahcarey
New Member

USA
2 Posts

Posted - Apr 01 2024 :  03:18:51 AM  Show Profile  Reply with Quote
quote:
Originally posted by feline

No particular current plans, partly because this is something so very individual, so would require a lot of options to work well.

Having said that, clang-tidy does have this check:

https://clang.llvm.org/extra/clang-tidy/checks/readability/identifier-naming.html https://mapsdrivingdirections.io

which you can enable if you tell VA to show you Unevaluated Checkers in code inspection. But without the ability to set all of the options for this check, you are going to need to rely on the defaults matching what you want to do.

I have put in a feature request to support this checker, and also allowing you to set all of the options. Given the number, it could be that is better done via a text file of some sort, rather than a GUI.

case=153852


Thank you! While it may not offer as extensive customization options as ReSharper's naming style, it can still be a valuable tool for enforcing naming conventions in your codebase.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
18988 Posts

Posted - Apr 02 2024 :  10:33:46 AM  Show Profile  Reply with Quote
Thank you for the vote of interest. This is definitely something we are looking into, so hopefully we will have something fairly soon.

zen is the art of being at one with the two'ness
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000