Skip to content

Commit

Permalink
feat: remove uint2str
Browse files Browse the repository at this point in the history
Unused and doesn't work great according to the audit
  • Loading branch information
cpb8010 committed Dec 17, 2024
1 parent 0b7f4b3 commit 10d171d
Showing 1 changed file with 0 additions and 17 deletions.
17 changes: 0 additions & 17 deletions src/libraries/JsmnSolLib.sol
Original file line number Diff line number Diff line change
Expand Up @@ -334,23 +334,6 @@ library JsmnSolLib {
return mint;
}
function uint2str(uint i) internal pure returns (string memory) {
if (i == 0) return "0";
uint j = i;
uint len;
while (j != 0) {
len++;
j /= 10;
}
bytes memory bstr = new bytes(len);
uint k = len - 1;
while (i != 0) {
bstr[k--] = bytes1(uint8(48 + (i % 10)));
i /= 10;
}
return string(bstr);
}
function parseBool(string memory _a) internal pure returns (bool) {
if (strCompare(_a, "true") == 0) {
return true;
Expand Down

0 comments on commit 10d171d

Please sign in to comment.