Project

General

Profile

Feature #3703

add lint reports

Added by Greg Shah over 5 years ago. Updated over 5 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Target version:
-
Start date:
Due date:
% Done:

0%

billable:
No
vendor_id:
GCD
version:

History

#1 Updated by Greg Shah over 5 years ago

Add reports for "lint" to the standard reports for FWD Analytics.

The key thing here is having a pretty comprehensive list of items on which to report.

Examples:

  • Keyword abbreviations.
  • Field/Table/Database name abbreviations.
  • Unqualified field or table names.
  • Variables that are UNDO.
  • Shared variable usage.
  • Standalone expressions that have no side effects.
  • References to a default frame.
  • Queries without indexes.
  • Indexes that aren't referenced.
  • Fields that aren't referenced.
  • Tables that aren't referenced.
  • Platform-specific code.
  • Transactions that span multiple program files.
  • Locks that outlive transactions.
  • Runtime preprocessor arguments.
  • Dynamic code generation.
  • Other code that can't work in an r-code (compiled) application.
  • Parsing/preprocessing quirks.
  • Runtime quirks that can be predicted from static code analysis.
  • Coding standards.

This is not a complete list. I just jotted down some stuff that came to mind. We already have some of these built. Please post your own ideas to this task to save them.

We can review the Prolint tool (which is open source) and see if there are useful ideas (see their list of rules). Please note that the prolint approach will be missing the more advanced things that we can calculate since they are using a pretty weak AST (as compared to our more rich AST). When you add the deeper analysis of our annotations phase, there is so much that we can exploit which prolint cannot provide. But prolint may show some ideas for reports that are more basic. If they are useful we can create our own version. Their actual code is useless to us but the concepts could be useful.

Also available in: Atom PDF