diff options
| author | Jack Koenig | 2022-01-10 10:39:52 -0800 |
|---|---|---|
| committer | Jack Koenig | 2022-01-10 15:53:55 -0800 |
| commit | 3131c0daad41dea78bede4517669e376c41a325a (patch) | |
| tree | 55baed78a6a01f80ff3952a08233ca553a19964f /src/main/scala/chisel3/util/BlackBoxUtils.scala | |
| parent | dd36f97a82746cec0b25b94651581fe799e24579 (diff) | |
Apply scalafmt
Command:
sbt scalafmtAll
Diffstat (limited to 'src/main/scala/chisel3/util/BlackBoxUtils.scala')
| -rw-r--r-- | src/main/scala/chisel3/util/BlackBoxUtils.scala | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/main/scala/chisel3/util/BlackBoxUtils.scala b/src/main/scala/chisel3/util/BlackBoxUtils.scala index 443d7f3e..7c4400f8 100644 --- a/src/main/scala/chisel3/util/BlackBoxUtils.scala +++ b/src/main/scala/chisel3/util/BlackBoxUtils.scala @@ -4,14 +4,20 @@ package chisel3.util import chisel3._ import chisel3.experimental.{ChiselAnnotation, RunFirrtlTransform} -import firrtl.transforms.{BlackBoxPathAnno, BlackBoxResourceAnno, BlackBoxInlineAnno, BlackBoxSourceHelper, - BlackBoxNotFoundException} +import firrtl.transforms.{ + BlackBoxInlineAnno, + BlackBoxNotFoundException, + BlackBoxPathAnno, + BlackBoxResourceAnno, + BlackBoxSourceHelper +} import firrtl.annotations.ModuleName import logger.LazyLogging private[util] object BlackBoxHelpers { implicit class BlackBoxInlineAnnoHelpers(anno: BlackBoxInlineAnno.type) extends LazyLogging { + /** Generate a BlackBoxInlineAnno from a Java Resource and a module name. */ def fromResource(resourceName: String, moduleName: ModuleName) = try { val blackBoxFile = os.resource / os.RelPath(resourceName.dropWhile(_ == '/')) |
