Revision c021b2859740f76e6da61670d7cf9011989bfc36 authored by TypeScript Bot on 23 November 2019, 00:26:51 UTC, committed by Nathan Shively-Sanders on 23 November 2019, 00:26:51 UTC
Component commits:
5810765259 Emit defineProperty calls before param prop assignments
Note that I restricted this to --useDefineForClassFields is true.
Nothing changes when it's off. I think this is the correct fix for a
patch release.

However, in principal there's nothing wrong with moving parameter
property initialisation after property declaration initialisation. It
would be Extremely Bad and Wrong to rely on this working:

```ts
class C {
  p = this.q // what is q?
  constructor(public q: number) { }
}
```

But today it does, and probably somebody relies on it without knowing.

ec7959091a Put parameter property initialiser into defineProperty's value

be863550b7 Merge branch 'master' into fix-defineProperty-parameter-property-emit

8ff59b98b8 Combine ES5/ESNext into one test
1 parent d5bcb6f
History
File Mode Size
.github
.vscode
bin
doc
lib
loc
scripts
src
tests
.dockerignore -rw-r--r-- 1013 bytes
.editorconfig -rw-r--r-- 188 bytes
.eslintignore -rw-r--r-- 59 bytes
.eslintrc.json -rw-r--r-- 3.9 KB
.gitattributes -rw-r--r-- 42 bytes
.gitignore -rw-r--r-- 2.8 KB
.gitmodules -rw-r--r-- 0 bytes
.mailmap -rw-r--r-- 18.7 KB
.npmignore -rw-r--r-- 411 bytes
.npmrc -rw-r--r-- 18 bytes
.travis.yml -rw-r--r-- 296 bytes
.yarnrc -rw-r--r-- 27 bytes
AUTHORS.md -rw-r--r-- 6.0 KB
CODE_OF_CONDUCT.md -rw-r--r-- 333 bytes
CONTRIBUTING.md -rw-r--r-- 10.9 KB
CopyrightNotice.txt -rw-r--r-- 819 bytes
Dockerfile -rw-r--r-- 257 bytes
Gulpfile.js -rw-r--r-- 31.8 KB
LICENSE.txt -rw-r--r-- 9.0 KB
README.md -rw-r--r-- 5.5 KB
ThirdPartyNoticeText.txt -rw-r--r-- 36.9 KB
package.json -rw-r--r-- 4.3 KB

README.md

back to top