[PR #154] [CLOSED] A static analysis tools framework for TheIDE #190

Closed
opened 2026-05-05 03:42:38 -06:00 by gitea-mirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/ultimatepp/ultimatepp/pull/154
Author: @ismail-yilmaz
Created: 4/29/2023
Status: Closed

Base: masterHead: ide_linter


📄 Description

Summary:

The aim of this pull request is to Implement in theIDE a framework for linters.

Characteristics:

  • Designed to work with command-line-driven (cld) external static analysis tools.
    Does not require any external library as its build dependency.

  • Designed to be modular.
    Allows TheIDE to use any existing cld linter by registering a uniform module.

  • Designed to be optional.
    The package is hidden behind the LINTER flag.

  • Designed to be easily maintainable.
    The package has a very narrow footprint in TheIDe's codebase.
    The only entries in the main source tree are as follows (hidden behind the LINTER flag):

    1. Header inclusion line in ide.h.
    2. Package entry line in the ide.upp.
    3. Menu entry in the idebar.cpp.
  • Designed to support most common operation types.
    Allows registered linters to analyze the whole project, a single package or a file.

  • Designed to support both GUI and keyboard commands.
    Common operations can also be invoked using the menu or the configurable keyboard shortcuts.
    Linter package exposes a menu which;

    1. Allows common operation types (analyze file, package, project).
    2. Contains a submenu of the list of registered (and valid) linter modules.
    3. A menu entry for configuring the active (selected) linter module.
  • Comes with the basic API doc (in Topic++ form) for the Linter module interface.

  • Comes with CppCheck module as the default option.
    The rationale behind adding CppCheck as the default module are:

    1. It's widely available and has has both free and commercial versions that use the same command-line.
    2. It is cross platform and very easy to incorporate into TheIDE.
    3. It is easily extendible using its library and add-ons infrastructure. (An U++ rules library can be easily created.)
    4. It can utilize the Clang backend for its AST generation (option).

Modules

The target is to implement modules at least for both CppCheck and clang-tidy.

cppcheck

Done:

  • Ability to select severity message types.
  • Core configuration settings (language, standard, platform, etc.)
  • Library file(s) support (extensions).
  • Add-ons support (extensions).
  • The ability to pass additional command line options.
  • The ability to show verbose messages.
  • The ability to show inconclusive results.
  • The ability to filter out non C/C++ files and directories (*.tpp, *.log, etc).
  • Allows per-project configuration file.

To-Do:

  • Add configurable build dir path (to speed-up analysis).
  • Add CLANG backend switch to CppCheck module.

clang-tidy

TODO.

Please review.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/ultimatepp/ultimatepp/pull/154 **Author:** [@ismail-yilmaz](https://github.com/ismail-yilmaz) **Created:** 4/29/2023 **Status:** ❌ Closed **Base:** `master` ← **Head:** `ide_linter` --- ### 📄 Description # Summary: The aim of this pull request is to Implement in theIDE a framework for linters. ## Characteristics: - Designed to work with command-line-driven (cld) external static analysis tools. Does not require any external library as its build dependency. - Designed to be modular. Allows TheIDE to use any existing cld linter by registering a uniform module. - Designed to be optional. The package is hidden behind the LINTER flag. - Designed to be easily maintainable. The package has a very narrow footprint in TheIDe's codebase. The only entries in the main source tree are as follows (hidden behind the LINTER flag): 1) Header inclusion line in `ide.h`. 2) Package entry line in the `ide.upp`. 3) Menu entry in the `idebar.cpp`. - Designed to support most common operation types. Allows registered linters to analyze the whole project, a single package or a file. - Designed to support both GUI and keyboard commands. Common operations can also be invoked using the menu or the configurable keyboard shortcuts. Linter package exposes a menu which; 1) Allows common operation types (analyze file, package, project). 2) Contains a submenu of the list of registered (and valid) linter modules. 3) A menu entry for configuring the active (selected) linter module. - Comes with the basic API doc (in Topic++ form) for the Linter module interface. - Comes with CppCheck module as the default option. The rationale behind adding CppCheck as the default module are: 1) It's widely available and has has both free and commercial versions that use the same command-line. 2) It is cross platform and very easy to incorporate into TheIDE. 3) It is easily extendible using its library and add-ons infrastructure. (An U++ rules library can be easily created.) 4) It can utilize the Clang backend for its AST generation (option). # Modules The target is to implement modules at least for both CppCheck and clang-tidy. ## cppcheck Done: + Ability to select severity message types. + Core configuration settings (language, standard, platform, etc.) + Library file(s) support (extensions). + Add-ons support (extensions). + The ability to pass additional command line options. + The ability to show verbose messages. + The ability to show inconclusive results. + The ability to filter out non C/C++ files and directories (*.tpp, *.log, etc). + Allows per-project configuration file. To-Do: - Add configurable build dir path (to speed-up analysis). - Add CLANG backend switch to CppCheck module. ## clang-tidy TODO. Please review. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
gitea-mirror 2026-05-05 03:42:38 -06:00
Sign in to join this conversation.
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/ultimatepp#190
No description provided.