Skip to content

Commit

Permalink
[skip ci] Refactor Systrace.traceSection() to unblock CI (facebook#46994
Browse files Browse the repository at this point in the history
)

Summary:

This diff makes a small refactor on Systrace.traceSection() to unblock CI, which was broken by D64141515 

changelog: [internal] internal

Reviewed By: Abbondanzo

Differential Revision: D64276651
  • Loading branch information
mdvacca authored and facebook-github-bot committed Oct 12, 2024
1 parent 401991c commit 2fdf2e4
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,12 @@ public object Systrace {
@JvmStatic public fun traceInstant(tag: Long, title: String?, scope: EventScope?): Unit = Unit

@JvmStatic
public fun traceSection(tag: Long, sectionName: String, block: () -> T) {
beginSection(sectionName)
public fun traceSection(tag: Long, sectionName: String, block: () -> Unit) {
beginSection(tag, sectionName)
try {
return block()
block()
} finally {
endSection(sectionName)
endSection(tag)
}
}

Expand Down

0 comments on commit 2fdf2e4

Please sign in to comment.