@@ -329,7 +329,11 @@ function stringifyLogValue(value) {
|
||||
function printCallLog(name, args, result) {
|
||||
console.log(`调用 ${name} 功能`);
|
||||
console.log(`入参 ${args.map(stringifyLogValue).join(" ")}`);
|
||||
console.log(`结果 ${stringifyLogValue(result)}`);
|
||||
if (result === undefined) {
|
||||
console.log("执行结束");
|
||||
} else {
|
||||
console.log(`执行结果 ${stringifyLogValue(result)}`);
|
||||
}
|
||||
}
|
||||
|
||||
function withCallLog(name, fn) {
|
||||
|
||||
Reference in New Issue
Block a user