-
-
Notifications
You must be signed in to change notification settings - Fork 35.4k
buffer: removed unused variable conf from buffer-base64-decode & buffer-base64-encode #10175
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 1 commit
7243066
4eb18d6
df392f0
08cdc9c
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
- Loading branch information
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -3,15 +3,15 @@ var common = require('../common.js'); | |
|
|
||
| const bench = common.createBenchmark(main, { | ||
| N: [64 * 1024 * 1024], | ||
| n: [32] | ||
| len: [32] | ||
| }); | ||
|
|
||
| function main(conf) { | ||
| var n = conf.n; | ||
| var N = conf.N; | ||
| var b = Buffer.allocUnsafe(N); | ||
| var s = ''; | ||
| var i; | ||
| const n = +conf.len; | ||
| const N = +conf.N; | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This should be |
||
| const b = Buffer.allocUnsafe(N); | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This should be |
||
| let s = ''; | ||
| let i; | ||
| for (i = 0; i < 256; ++i) s += String.fromCharCode(i); | ||
| for (i = 0; i < N; i += 256) b.write(s, i, 256, 'ascii'); | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
| bench.start(); | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I meant this parameter should be called
len.nshould stay the same.