aboutsummaryrefslogtreecommitdiffstats
path: root/packages/sol-cov/src/collect_coverage_entries.ts
diff options
context:
space:
mode:
Diffstat (limited to 'packages/sol-cov/src/collect_coverage_entries.ts')
-rw-r--r--packages/sol-cov/src/collect_coverage_entries.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/packages/sol-cov/src/collect_coverage_entries.ts b/packages/sol-cov/src/collect_coverage_entries.ts
index 703af3099..bdbcd613e 100644
--- a/packages/sol-cov/src/collect_coverage_entries.ts
+++ b/packages/sol-cov/src/collect_coverage_entries.ts
@@ -5,6 +5,8 @@ import * as parser from 'solidity-parser-antlr';
import { ASTVisitor, CoverageEntriesDescription } from './ast_visitor';
import { getLocationByOffset } from './source_maps';
+const IGNORE_RE = /\/\*\s*solcov\s+ignore\s+next\s*\*\/\s*/gm;
+
// Parsing source code for each transaction/code is slow and therefore we cache it
const coverageEntriesBySourceHash: { [sourceHash: string]: CoverageEntriesDescription } = {};
@@ -22,8 +24,6 @@ export const collectCoverageEntries = (contractSource: string) => {
return coverageEntriesDescription;
};
-const IGNORE_RE = /\/\*\s*solcov\s+ignore\s+next\s*\*\/\s*/gm;
-
// Gather the start index of all code blocks preceeded by "/* solcov ignore next */"
function gatherRangesToIgnore(contractSource: string): number[] {
const ignoreRangesStart = [];