Skip to content

Commit 83266f1

Browse files
stevengjjrevels
authored andcommitted
fix tests and doc for JuliaLang/julia#7669 in 0.6: semicolons no longer give macros keywords (#38)
1 parent d1c2c85 commit 83266f1

File tree

2 files changed

+3
-9
lines changed

2 files changed

+3
-9
lines changed

doc/reference.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -203,12 +203,12 @@ Run a single evaluation of `x`. This can be useful if you think JIT overhead is
203203

204204
# Macros
205205

206-
##### `@benchmarkable(expr; kwargs...)`
206+
##### `@benchmarkable(expr, kwargs...)`
207207

208208
Define and return, but do not tune or run, a `Benchmark` that can be used to test the performance of `expr`. Relevant manual documentation can be found [here](manual.md#benchmarking-basics) (for valid `kwargs` values, see [here](manual.md#benchmark-parameters) specifically). If used in local scope, all
209209
external local variables must be interpolated.
210210

211-
##### `@benchmark(expr; kwargs...)`
211+
##### `@benchmark(expr, kwargs...)`
212212

213213
Define, tune, and run the `Benchmark` generated from `expr`. Relevant manual documentation can be found [here](manual.md#benchmarking-basics) (for valid `kwargs` values, see [here](manual.md#benchmark-parameters) specifically). If used in local scope, all external local variables must be interpolated.
214214

test/ExecutionTests.jl

+1-7
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ sizes = (5, 10, 20)
1919
for s in sizes
2020
A = rand(s, s)
2121
groups["sum"][s] = @benchmarkable sum($A) seconds=3
22-
groups["sin"][s] = @benchmarkable(sin($s); seconds=1, gctrial=false)
22+
groups["sin"][s] = @benchmarkable(sin($s), seconds=1, gctrial=false)
2323
end
2424

2525
groups["special"]["macro"] = @benchmarkable @test(1 == 1)
@@ -135,12 +135,6 @@ tune!(b)
135135
# test kwargs separated by `,`
136136
@benchmark(output=sin(x), setup=(x=1.0; output=0.0), teardown=(@test output == sin(x)))
137137

138-
# test kwargs separated by `;`
139-
@benchmark(output=sin(x); setup=(x=1.0; output=0.0), teardown=(@test output == sin(x)))
140-
141-
# test kwargs separated by `,` and `;`
142-
@benchmark(output=sin(x), setup=(x=1.0; output=0.0); teardown=(@test output == sin(x)))
143-
144138
########
145139
# misc #
146140
########

0 commit comments

Comments
 (0)