-
Notifications
You must be signed in to change notification settings - Fork 1.9k
C++: Remove decimal floating point types #21110
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
base: main
Are you sure you want to change the base?
Conversation
b17ca3c to
5923301
Compare
5923301 to
a161572
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This pull request removes support for decimal floating point types (_Decimal32, _Decimal64, _Decimal128) from the C++ CodeQL library. These were gcc-specific types with incomplete support that are rarely used in C/C++ codebases.
Changes:
- Removed decimal type definitions from database schema and type system
- Added database upgrade/downgrade scripts to handle the schema change
- Updated test expected files to reflect the removal
- Removed test cases specifically testing decimal types
Reviewed changes
Copilot reviewed 19 out of 20 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| cpp/ql/lib/semmlecode.cpp.dbscheme | Commented out decimal type definitions (kinds 40-42) in builtin types |
| cpp/ql/lib/semmle/code/cpp/Type.qll | Removed Decimal32Type, Decimal64Type, and Decimal128Type classes and their mappings |
| cpp/ql/lib/upgrades/.../builtintypes.ql | Upgrade script to convert decimal types to error types |
| cpp/ql/lib/upgrades/.../upgrade.properties | Upgrade metadata marking compatibility as partial |
| cpp/ql/lib/upgrades/.../semmlecode.cpp.dbscheme | New schema with decimal types removed |
| cpp/ql/lib/upgrades/.../old.dbscheme | Old schema with decimal types included |
| cpp/downgrades/.../upgrade.properties | Downgrade metadata marking compatibility as full |
| cpp/downgrades/.../semmlecode.cpp.dbscheme | Downgrade schema restoring decimal types |
| cpp/ql/lib/change-notes/2026-01-02-decimal-removal.md | Change note documenting the removal |
| cpp/ql/test/library-tests/builtins/types/types.c | Removed test code for decimal types |
| cpp/ql/test/library-tests/builtins/types/types.ql | Removed entire test query file |
| cpp/ql/test/library-tests/builtins/types/types.expected | Cleared expected results |
| cpp/ql/test/library-tests/literals/literals/literals.c | Removed decimal literal suffix test cases |
| Multiple test .expected files | Updated to remove decimal type entries |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
See internal PR for details.