Skip to content

Commit da804c1

Browse files
authored
fix: add missing console logs (#577)
I copy pasted the console2 functions to console and replaced `int256` with `int`.
1 parent 8948d45 commit da804c1

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/console.sol

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,10 @@ library console {
186186
_sendLogPayload(abi.encodeWithSignature("log(uint)", p0));
187187
}
188188

189+
function log(int p0) internal pure {
190+
_sendLogPayload(abi.encodeWithSignature("log(int)", p0));
191+
}
192+
189193
function log(string memory p0) internal pure {
190194
_sendLogPayload(abi.encodeWithSignature("log(string)", p0));
191195
}
@@ -218,6 +222,10 @@ library console {
218222
_sendLogPayload(abi.encodeWithSignature("log(string,uint)", p0, p1));
219223
}
220224

225+
function log(string memory p0, int p1) internal pure {
226+
_sendLogPayload(abi.encodeWithSignature("log(string,int)", p0, p1));
227+
}
228+
221229
function log(string memory p0, string memory p1) internal pure {
222230
_sendLogPayload(abi.encodeWithSignature("log(string,string)", p0, p1));
223231
}

0 commit comments

Comments
 (0)