diff options
| author | Sébastien d'Herbais de Thun <sebastien.d.herbais@gmail.com> | 2023-04-23 14:33:56 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-04-23 14:33:56 +0200 |
| commit | 561ff979d574f496415c0499345d41da2e1f6e1e (patch) | |
| tree | 037479ac000bd87a1cb2149e5389b28f08d24051 /library/src/math/mod.rs | |
| parent | 2fbb14f712708188649181525813b3ac5a02e0fb (diff) | |
Add instrumentation (Part 1) (#761)
Diffstat (limited to 'library/src/math/mod.rs')
| -rw-r--r-- | library/src/math/mod.rs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/library/src/math/mod.rs b/library/src/math/mod.rs index 48fe52d2..63bfdbbe 100644 --- a/library/src/math/mod.rs +++ b/library/src/math/mod.rs @@ -173,6 +173,7 @@ impl Synthesize for EquationElem { } impl Show for EquationElem { + #[tracing::instrument(name = "EquationElem::show", skip_all)] fn show(&self, _: &mut Vt, styles: StyleChain) -> SourceResult<Content> { let mut realized = self.clone().pack().guarded(Guard::Base(Self::func())); if self.block(styles) { @@ -193,6 +194,7 @@ impl Finalize for EquationElem { } impl Layout for EquationElem { + #[tracing::instrument(name = "EquationElem::layout", skip_all)] fn layout( &self, vt: &mut Vt, @@ -340,12 +342,14 @@ pub trait LayoutMath { } impl LayoutMath for EquationElem { + #[tracing::instrument(skip(ctx))] fn layout_math(&self, ctx: &mut MathContext) -> SourceResult<()> { self.body().layout_math(ctx) } } impl LayoutMath for Content { + #[tracing::instrument(skip(ctx))] fn layout_math(&self, ctx: &mut MathContext) -> SourceResult<()> { // Directly layout the body of nested equations instead of handling it // like a normal equation so that things like this work: |
