Skip to content

Commit 08c0afe

Browse files
chriselrodcarstenbauer
authored andcommitted
update counter show method for PrettyTables 2
1 parent a830cb3 commit 08c0afe

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,5 @@ Printf = "de0858da-6303-5e67-8744-51eddeeeb8d7"
99

1010
[compat]
1111
Formatting = "0.4"
12-
PrettyTables = "0.9, 1, 2"
12+
PrettyTables = "2"
1313
julia = "1"

src/LinuxPerf.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -367,7 +367,7 @@ function Base.show(io::IO, c::Counters)
367367
c.running == 0 ? ["did not run" "0 %"] :
368368
[format(Int64(c.value), commas=true) @sprintf("%.1f %%", 100*(c.running/c.enabled))]
369369
end
370-
return pretty_table(io, stats, ["Events", "Active Time"], row_names=events, alignment=:l, crop=:none, body_hlines=collect(axes(stats, 1)))
370+
return pretty_table(io, stats, header=["Events", "Active Time"], row_labels=events, alignment=:l, crop=:none, body_hlines=collect(axes(stats, 1)))
371371
end
372372

373373
enable!(b::PerfBench) = foreach(enable!, b.groups)

0 commit comments

Comments
 (0)