mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
11 lines
298 B
TypeScript
11 lines
298 B
TypeScript
//// [tests/cases/conformance/types/spread/spreadNonPrimitive.ts] ////
|
|
|
|
//// [spreadNonPrimitive.ts]
|
|
declare let o: object;
|
|
const x: { a: number, b: number } = { a: 1, ...o, b: 2 };
|
|
|
|
|
|
//// [spreadNonPrimitive.js]
|
|
"use strict";
|
|
const x = Object.assign(Object.assign({ a: 1 }, o), { b: 2 });
|