Uniswap / v3-core

🦄 🦄 🦄 Core smart contracts of Uniswap v3
https://uniswap.org
Other
4.38k stars 2.68k forks source link

Update BitMath.sol #666

Closed Bansuri-Gupta closed 10 months ago

Bansuri-Gupta commented 1 year ago

Detailed Description of Changes:

The code has been formatted to follow a consistent style, with appropriate indentation and line breaks to enhance readability. Comments have been provided for each function, explaining its purpose and properties. The mostSignificantBit and leastSignificantBit functions are now more readable and easier to understand due to improved code organization. Error Messages in require Statements:

The require statements in both functions now include specific error messages to provide more informative feedback when the input value (x) is not greater than 0. The error messages make it clear that the value must be greater than 0 for the functions to produce valid results. Executive Summary of Changes:

The optimized version of the BitMath library focuses on improving code readability and providing more informative error messages while preserving the efficient bit manipulation capabilities. The key changes include code formatting and organization, adding descriptive comments, and enhancing the error messages in require statements.

Advantages of the Changes:

stale[bot] commented 10 months ago

Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.