Skip to content

Commit 4b2fcc4

Browse files
authored
Merge pull request #56 from minaminao/fix-shadowing-warning
Fix shadowing warning
2 parents 46983c6 + e36d104 commit 4b2fcc4

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/strings.sol

+4-4
Original file line numberDiff line numberDiff line change
@@ -42,9 +42,9 @@ library strings {
4242
uint _ptr;
4343
}
4444

45-
function memcpy(uint dest, uint src, uint len) private pure {
45+
function memcpy(uint dest, uint src, uint length) private pure {
4646
// Copy word-length chunks while possible
47-
for(; len >= 32; len -= 32) {
47+
for(; length >= 32; length -= 32) {
4848
assembly {
4949
mstore(dest, mload(src))
5050
}
@@ -54,8 +54,8 @@ library strings {
5454

5555
// Copy remaining bytes
5656
uint mask = type(uint).max;
57-
if (len > 0) {
58-
mask = 256 ** (32 - len) - 1;
57+
if (length > 0) {
58+
mask = 256 ** (32 - length) - 1;
5959
}
6060
assembly {
6161
let srcpart := and(mload(src), not(mask))

0 commit comments

Comments
 (0)