Inner function that handles the core timing logic. Args: name (str): The name/identifier for this timing measurement. timing_raw (Dict[str, float]): Dictionary to store timing information.
(name: str, timing_raw: dict[str, float])
| 138 | |
| 139 | |
| 140 | def _timer(name: str, timing_raw: dict[str, float]): |
| 141 | """Inner function that handles the core timing logic. |
| 142 | |
| 143 | Args: |
| 144 | name (str): The name/identifier for this timing measurement. |
| 145 | timing_raw (Dict[str, float]): Dictionary to store timing information. |
| 146 | """ |
| 147 | with Timer(name=name, logger=None) as timer: |
| 148 | yield |
| 149 | if name not in timing_raw: |
| 150 | timing_raw[name] = 0 |
| 151 | timing_raw[name] += timer.last |
| 152 | |
| 153 | |
| 154 | @contextmanager |
no outgoing calls
no test coverage detected