Skip to content

Commit aff047f

Browse files
authored
Rewriter compiler comment (#8033)
* add comment to clarify the purpose of the compiler file * remove old and no longer relevant comment
1 parent 89cd561 commit aff047f

1 file changed

Lines changed: 8 additions & 1 deletion

File tree

  • packages/datadog-instrumentations/src/helpers/rewriter

packages/datadog-instrumentations/src/helpers/rewriter/compiler.js

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,13 @@
11
'use strict'
22

3+
/**
4+
* This file is meant to be only thin wrappers over core
5+
* parsing/traversing/generating functionality with the goal to eventually move
6+
* them out of the project. No other code should be added to this file such as
7+
* helpers etc, and the API should be kept exactly as an external API would be
8+
* expected to be.
9+
*/
10+
311
const log = require('../../../../dd-trace/src/log')
412

513
// eslint-disable-next-line camelcase, no-undef
@@ -24,7 +32,6 @@ const compiler = {
2432
} catch (e) {
2533
log.error(e)
2634

27-
// Fallback for when OXC is not available.
2835
const meriyah = require('../../../../../vendor/dist/meriyah')
2936

3037
compiler.parse = (sourceText, { range, sourceType } = {}) => {

0 commit comments

Comments
 (0)