mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
parser: deprecate short struct init (#10842)
This commit is contained in:
@@ -32,7 +32,7 @@ fn main() {
|
||||
nrec := os.args[2].int()
|
||||
buflen := os.args[3].int()
|
||||
nobj := os.args[4].int()
|
||||
stopwatch := time.new_stopwatch({})
|
||||
stopwatch := time.new_stopwatch()
|
||||
ch := chan int{cap: buflen}
|
||||
resch := chan i64{}
|
||||
mut no := nobj
|
||||
|
||||
@@ -36,7 +36,7 @@ mut:
|
||||
|
||||
fn do_rec(ch chan int, id int, mut ctx Context) {
|
||||
eprintln('start of do_rec id: $id')
|
||||
mut timer_sw_x := time.new_stopwatch({})
|
||||
mut timer_sw_x := time.new_stopwatch()
|
||||
mut tmp := int(0)
|
||||
mut i := int(0)
|
||||
// NB: a single receiver thread can get slightly more
|
||||
@@ -69,7 +69,7 @@ fn do_rec(ch chan int, id int, mut ctx Context) {
|
||||
|
||||
fn do_send(ch chan int, id int, mut ctx Context) {
|
||||
eprintln('start of do_send id: $id')
|
||||
mut timer_sw_x := time.new_stopwatch({})
|
||||
mut timer_sw_x := time.new_stopwatch()
|
||||
n_iters := ctx.n_iters
|
||||
base := n_iters * id // sender events can not overlap
|
||||
for i := 0; i < n_iters; i++ {
|
||||
|
||||
Reference in New Issue
Block a user