Asger F
ef7bde472b
TS: Fix javadoc
2019-04-10 15:33:39 +01:00
Asger F
4b4e7eb5ff
TS: update trap test output
2019-04-10 13:17:15 +01:00
Asger F
c1c7ebfc48
TS: Support const type assertions
2019-04-10 12:54:42 +01:00
Asger F
d5ae69d40a
TS: Support readonly type expressions
2019-04-10 12:26:46 +01:00
Asger F
11f460c6a3
JS: Generalize KeyofTypeExpr to UnaryTypeExpr
2019-04-10 12:21:28 +01:00
Asger F
65d863f8fb
TS: update to TypeScript 3.4
2019-04-10 11:18:23 +01:00
Asger F
50c2921625
TS: Use contextual typing for literals
2019-04-05 18:43:51 +01:00
Max Schaefer
8c460ae385
Merge remote-tracking branch 'upstream/master' into rc/1.20-merge-master
...
Conflict in `javascript/extractor/src/com/semmle/js/extractor/Main.java` resolved
in favour of `master`.
2019-03-21 14:46:29 +00:00
Max Schaefer
1835028b93
JavaScript: Show character code when reporting unexpected character.
2019-03-21 10:44:49 +00:00
Asger F
5768d85c7b
TS: fix trap test output
2019-03-20 12:46:52 +00:00
Asger F
8201e7ea27
TS: update trap test output
2019-03-20 10:23:28 +00:00
Asger F
aaa8bfb874
TS: allow namespace imports as types
2019-03-20 10:09:18 +00:00
Max Schaefer
03a2204c30
JavaScript: Improve support for dynamic imports.
...
`yield import(...)` previously caused a syntax error, now it is parsed
correctly.
`parseYield` is the only place where the value of `startsExpr` matters,
so this change should not affect anything else.
2019-03-13 14:40:12 +00:00
semmle-qlci
669f035444
Merge pull request #1084 from asger-semmle/typescript3.3
...
Approved by esben-semmle
2019-03-12 16:34:48 +00:00
semmle-qlci
13c6f55a2e
Merge pull request #1085 from asger-semmle/extract-symbol
...
Approved by xiemaisi
2019-03-12 14:07:17 +00:00
Asger F
f2ec35c334
TS: remove unused import
2019-03-12 11:35:59 +00:00
Asger F
824a50d14e
TS: fix extraction of symbols with unusual names
2019-03-12 11:24:16 +00:00
Asger F
0f5e6b2193
TS: update TypeScript compiler version
2019-03-12 09:52:38 +00:00
Asger F
957db8374c
JS: Bump extractor version string
2019-03-11 16:53:52 +00:00
Asger F
146909ba13
TS: fix missing this type in method declarations
2019-03-11 16:53:25 +00:00
Asger F
d7f0099426
TS: bump extractor version
2019-03-11 11:26:46 +00:00
Asger F
dc6c33dd12
TS: Fix infinite type expansion issue
2019-03-11 11:26:46 +00:00
Max Schaefer
832dff54e8
JavaScript: Remove a @link in Javadoc.
...
Javadoc claims not to be able to resolve this link, while Eclipse manages to do so without any problems, failing an internal PR check.
It's only in a test, though, so I just removed it.
2019-03-05 17:02:44 +00:00
Max Schaefer
b1033b079f
JavaScript: Make configuration of parallel extraction consistent with parallel evaluation.
...
Just like parallel evaluation, the number of extractor threads is now determined by the `LGTM_THREADS` environment variable, and defaults to one.
2019-03-05 10:06:32 +00:00
Max Schaefer
c4fa29dd0f
JavaScript: Autoformat extractor sources using google-java-format.
...
No special settings; command:
find javascript/extractor/src -name "*.java" | xargs java -jar /path/to/google-java-format-1.7-all-deps.jar --replace
2019-02-28 14:30:06 +00:00
Asger F
5478e0da62
Merge pull request #998 from xiemaisi/js/autobuild-file-types
...
JavaScript: Make file types customisable in AutoBuild.
2019-02-28 15:26:35 +01:00
Max Schaefer
9d77619afc
JavaScript: Make file types customisable in AutoBuild.
...
Every once in a while we encounter projects using some custom file extension for files that we could in principle extract, but since the extractor doesn't know about the extension the files are skipped.
To handle this, the legacy extractor has a `--file-type` option that one can use to specify a file type to use for all files in that particular extraction. So far, `AutoBuild` has nothing of the sort.
This PR proposes to introduce an environment variable `LGTM_INDEX_FILETYPES` to allow a similar customisation. In the fullness of time, this variable would be set through `lgtm.yml` in the usual way, but for now it is undocumented and for internal use only.
Specifically, `LGTM_INDEX_FILETYPES` is a newline-separated list of ".extension:filetype" pairs, specifying that files with the given `.extension` should be extracted as type `filetype`, where
`filetype` is one of `js`, `html`, `json`, `typescript` or `yaml`.
For example, `.jsm:js` causes all `.jsm` files to be extracted as JavaScript.
This can also be used to override default file types: for example, by specifying `.js:typescript` all JavaScript files will be extracted as TypeScript.
2019-02-27 12:02:01 +00:00
Max Schaefer
2ed37903d8
JavaScript: Include list of relevant environment variables in Javadoc for AutoBuild.
2019-02-27 11:54:59 +00:00
Max Schaefer
6ecdb0edd5
JavaScript: Allow first expression in array literal to be an in expression.
2019-02-27 08:58:28 +00:00
Max Schaefer
d4dbe3bfb6
JavaScript: Back out parsing of qualified XML identifiers.
...
Their syntax conflicts with the proposed function-bind operator, which is more important to support.
2019-02-24 21:30:59 +00:00
Max Schaefer
7491b5ea53
JavaScript: Add a comment.
2019-02-24 21:02:12 +00:00
Max Schaefer
f726125b71
JavaScript: Restrict E4X processing instruction disambiguation to the <?xml ...?> case.
2019-02-24 20:56:43 +00:00
Max Schaefer
cc216ad250
JavaScript: Buffer recoverable syntax errors during speculative parsing.
...
Analogous to how we buffer tokens, we need to delay reporting these errors until we have committed to a parse.
2019-02-24 20:45:41 +00:00
Max Schaefer
c7e428eb27
JavaScript: Handle E4X/Flow lexical ambiguity.
2019-02-24 20:45:41 +00:00
Max Schaefer
d6deefed86
JavaScript: Accept CDATA in E4X content.
2019-02-24 20:45:41 +00:00
Max Schaefer
81b86d9a0f
JavaScript: Skip XML processing instructions in E4X content.
2019-02-24 20:45:41 +00:00
Max Schaefer
5a89024507
JavaScript: Be more lenient about keywords used as identifiers.
2019-02-24 20:45:41 +00:00
Max Schaefer
dbbb961b48
JavaScript: Accept let expressions with an object literal as their body.
2019-02-24 20:45:41 +00:00
Max Schaefer
63ed569724
JavaScript: Recover from missing initializers in const/destructuring declarations.
2019-02-24 20:45:41 +00:00
Max Schaefer
fbf2774bb3
JavaScript: Accept expression-bodied function declarations in experimental mode.
2019-02-24 20:45:41 +00:00
Max Schaefer
a42bec7f44
JavaScript: Accept comments in E4X XML literals (but not in JSX HTML literals).
2019-02-24 20:45:41 +00:00
Max Schaefer
b2366c7a68
JavaScript: Refactor parsing of JSX element content.
2019-02-24 20:45:41 +00:00
Max Schaefer
88be67a4fc
JavaScript: Add support for for-each-in comprehensions.
2019-02-24 20:45:41 +00:00
Max Schaefer
d3ae2954ff
JavaScript: Add support for parsing postfix generator comprehensions.
2019-02-24 20:45:41 +00:00
Max Schaefer
bb93cef20a
JavaScript: Refactor parsing of parenthesised expressions.
2019-02-24 20:45:41 +00:00
Max Schaefer
92c8501e67
JavaScript: Refactor parsing of generator/array comprehensions.
2019-02-24 20:45:41 +00:00
Max Schaefer
f3ea810c21
JavaScript: Add parser support for E4X.
2019-02-24 20:45:41 +00:00
Max Schaefer
1ad4867f2a
JavaScript: Make parsing of decorators more restrictive.
...
As per [the proposal](https://tc39.github.io/proposal-decorators/#sec-new-syntax ), decorators can only contain identifiers or parenthesised expressions, optionally followed by property accesses and arguments.
2019-02-24 20:45:41 +00:00
Asger F
7a813cfb84
TS: disable type expansion by default
2019-02-12 12:21:11 +00:00
Asger F
9dae08bbcf
JS: fix javadoc
2019-02-07 13:53:29 +00:00