Skip to content

Accept CJS module.exports = {} baseline diffs#3855

Merged
RyanCavanaugh merged 2 commits into
mainfrom
copilot/investigate-cjs-export-emit
May 15, 2026
Merged

Accept CJS module.exports = {} baseline diffs#3855
RyanCavanaugh merged 2 commits into
mainfrom
copilot/investigate-cjs-export-emit

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented May 15, 2026

Per @weswigham's review, these diffs are non-concerning — the namespace merge is no longer needed since typedefs can now be exported at the top level alongside export=, and the _exports_default local name change is nonfunctional.

  • Moved 15 baseline diffs from submoduleTriaged to submoduleAccepted
  • Grouped alphabetically alongside existing CJS-related accepted groups
  • Removed the corresponding block from submoduleTriaged.txt

…th inlined object type)

Move 15 diff files from submoduleTriaged to submoduleAccepted for issue #3543.
These diffs reflect intentional changes where CJS module.exports = {} patterns
now emit export = _default with an inlined object type instead of individual
named exports.

Co-authored-by: RyanCavanaugh <6685088+RyanCavanaugh@users.noreply.github.com>
Copilot AI changed the title [WIP] Investigate CJS module.exports emission changes Accept CJS module.exports = {} baseline diffs May 15, 2026
Copilot AI requested a review from RyanCavanaugh May 15, 2026 17:28
@RyanCavanaugh RyanCavanaugh requested a review from weswigham May 15, 2026 17:51
@RyanCavanaugh RyanCavanaugh marked this pull request as ready for review May 15, 2026 17:54
Copilot AI review requested due to automatic review settings May 15, 2026 17:54
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the submodule baseline bookkeeping to treat a set of CommonJS module.exports = {} JS declaration emit diffs as “accepted” rather than “triaged”, reflecting that these output differences are now considered non-concerning for the port.

Changes:

  • Removed the CJS module.exports = {} diff group (15 entries) from testdata/submoduleTriaged.txt.
  • Added the same diff group to testdata/submoduleAccepted.txt, placed alongside other CJS-related accepted groups.
  • Added the corresponding 15 .diff baseline files under testdata/baselines/reference/submoduleAccepted/.
Show a summary per file
File Description
testdata/submoduleTriaged.txt Removes the CJS module.exports = {} diff group from the triaged list.
testdata/submoduleAccepted.txt Adds the CJS module.exports = {} diff group to the accepted list (15 entries) with issue link.
testdata/baselines/reference/submoduleAccepted/compiler/jsDeclarationEmitExportAssignedArray.js.diff Adds accepted baseline diff for CJS export-assigned array declaration emit.
testdata/baselines/reference/submoduleAccepted/compiler/jsDeclarationEmitExportAssignedFunctionWithExtraTypedefsMembers.js.diff Adds accepted baseline diff for CJS export-assigned function + typedef members emit.
testdata/baselines/reference/submoduleAccepted/conformance/jsDeclarationsCommonjsRelativePath.js.diff Adds accepted baseline diff for CJS relative-path declaration emit.
testdata/baselines/reference/submoduleAccepted/conformance/jsDeclarationsDocCommentsOnConsts(target=es2015).js.diff Adds accepted baseline diff for doc-comment emission under CJS export assignment pattern.
testdata/baselines/reference/submoduleAccepted/conformance/jsDeclarationsExportAssignmentExpressionPlusSecondary(target=es2015).js.diff Adds accepted baseline diff for CJS export assignment expression + secondary exports.
testdata/baselines/reference/submoduleAccepted/conformance/jsDeclarationsExportAssignmentWithKeywordName(target=es2015).js.diff Adds accepted baseline diff for keyword-named property under CJS export assignment.
testdata/baselines/reference/submoduleAccepted/conformance/jsDeclarationsExportedClassAliases.js.diff Adds accepted baseline diff for exported class alias shapes under CJS export assignment.
testdata/baselines/reference/submoduleAccepted/conformance/jsDeclarationsImportAliasExposedWithinNamespaceCjs.js.diff Adds accepted baseline diff for import-alias exposure patterns within CJS namespace-like exports.
testdata/baselines/reference/submoduleAccepted/conformance/jsDeclarationsReexportedCjsAlias(target=es2015).js.diff Adds accepted baseline diff for CJS alias re-export patterns.
testdata/baselines/reference/submoduleAccepted/conformance/jsDeclarationsReferenceToClassInstanceCrossFile.js.diff Adds accepted baseline diff for cross-file class instance references under CJS export assignment.
testdata/baselines/reference/submoduleAccepted/conformance/jsDeclarationsTypeAliases.js.diff Adds accepted baseline diff for type alias emission changes under CJS export assignment.
testdata/baselines/reference/submoduleAccepted/conformance/jsDeclarationsTypeReferences(target=es2015).js.diff Adds accepted baseline diff for type reference emission changes under CJS export assignment.
testdata/baselines/reference/submoduleAccepted/conformance/jsDeclarationsTypeReferences2(target=es2015).js.diff Adds accepted baseline diff for additional type reference emission changes under CJS export assignment.
testdata/baselines/reference/submoduleAccepted/conformance/jsDeclarationsTypedefAndImportTypes.js.diff Adds accepted baseline diff for typedef + import type emission changes under CJS export assignment.
testdata/baselines/reference/submoduleAccepted/conformance/jsDeclarationsTypedefPropertyAndExportAssignment.js.diff Adds accepted baseline diff for typedef-property + export assignment emission changes under CJS export assignment.

Copilot's findings

  • Files reviewed: 2/17 changed files
  • Comments generated: 0

@RyanCavanaugh RyanCavanaugh added this pull request to the merge queue May 15, 2026
Merged via the queue into main with commit 401d27a May 15, 2026
25 checks passed
@RyanCavanaugh RyanCavanaugh deleted the copilot/investigate-cjs-export-emit branch May 15, 2026 19:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Baselines: CJS module.exports = {} now emits export = _default with inlined object type instead of named exports

5 participants