Skip to content
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

RULE-8-4: Improve detection of compatible types #780

Open
lcartey opened this issue Oct 24, 2024 · 0 comments
Open

RULE-8-4: Improve detection of compatible types #780

lcartey opened this issue Oct 24, 2024 · 0 comments
Labels
Difficulty-Medium A false positive or false negative report which is expected to take 1-5 days effort to address false positive/false negative An issue related to observed false positives or false negatives. Impact-Low Standard-CERT-C

Comments

@lcartey
Copy link
Collaborator

lcartey commented Oct 24, 2024

Affected rules

  • DCL40-C
  • RULE-8-3
  • RULE-8-4

Description

There are some cases of compatible types which are not currently detected by these queries:

  • Enumerations - these are compatible with a specified integer type.
  • Array types - are compatible if the element types are compatible (and the sizes match, where appropriate)
  • Pointer types - are compatible in the pointer target types are compatible.
  • Function types - if the return/argument types are compatible (with some exceptions for functions that don't declare arguments).

Example

@lcartey lcartey added Difficulty-Medium A false positive or false negative report which is expected to take 1-5 days effort to address false positive/false negative An issue related to observed false positives or false negatives. Impact-Low labels Oct 24, 2024
@lcartey lcartey moved this from Reported to Triaged in Coding Standards Public Development Board Oct 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Difficulty-Medium A false positive or false negative report which is expected to take 1-5 days effort to address false positive/false negative An issue related to observed false positives or false negatives. Impact-Low Standard-CERT-C
Projects
Development

No branches or pull requests

2 participants