-
Notifications
You must be signed in to change notification settings - Fork 920
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
[ads] size_t code health #27711
[ads] size_t code health #27711
Conversation
[puLL-Merge] - brave/brave-core@27711 DescriptionThis PR changes integer types across the Brave Ads codebase to use more appropriate and safer types, specifically:
The motivation appears to be to improve type safety and prevent potential integer overflow issues by using more appropriate types for different use cases. ChangesChangesBy filename:
sequenceDiagram
participant Code
participant Type System
participant Compiler
Code->>Type System: Change int to size_t for counts
Type System->>Compiler: Enforce unsigned bounds
Compiler->>Code: Prevent integer overflow
Code->>Type System: Change int to int32_t for DB
Type System->>Compiler: Enforce explicit sizing
Compiler->>Code: Ensure consistent DB types
Possible Issues
The main goal appears to be using more appropriate types for different use cases, which should improve type safety and prevent potential overflow issues. |
f681cdd
to
94d1c84
Compare
Chromium major version is behind target branch (133.0.6943.98 vs 134.0.6998.15). Please rebase. |
94d1c84
to
4b04d10
Compare
Released in v1.77.53 |
Resolves brave/brave-browser#44064
Submitter Checklist:
QA/Yes
orQA/No
;release-notes/include
orrelease-notes/exclude
;OS/...
) to the associated issuenpm run test -- brave_browser_tests
,npm run test -- brave_unit_tests
wikinpm run presubmit
wiki,npm run gn_check
,npm run tslint
git rebase master
(if needed)Reviewer Checklist:
gn
After-merge Checklist:
changes has landed on
Test Plan: