From 04125feb5e55df140f3b42218a0d59280e5f5496 Mon Sep 17 00:00:00 2001 From: Wojciech Mazur Date: Wed, 23 Oct 2024 09:18:38 +0200 Subject: [PATCH] Don't warn for deprecated Thread.getId() calls --- compiler/src/dotty/tools/dotc/profile/ChromeTrace.scala | 1 + 1 file changed, 1 insertion(+) diff --git a/compiler/src/dotty/tools/dotc/profile/ChromeTrace.scala b/compiler/src/dotty/tools/dotc/profile/ChromeTrace.scala index c33039f46398..4950f439640f 100644 --- a/compiler/src/dotty/tools/dotc/profile/ChromeTrace.scala +++ b/compiler/src/dotty/tools/dotc/profile/ChromeTrace.scala @@ -45,6 +45,7 @@ final class ChromeTrace(f: Path) extends Closeable { private val traceWriter = FileUtils.newAsyncBufferedWriter(f) private val context = mutable.Stack[JsonContext](TopContext) private val tidCache = new ThreadLocal[String]() { + @annotation.nowarn("cat=deprecation") override def initialValue(): String = "%05d".format(Thread.currentThread().getId()) } objStart()