Added
- Hack: preliminary support for hack-lang
thanks to David Frankel, Nicholas Lin, and more people at Slack! - OCaml: support for partial if, match, and try patterns
(e.g.,if $X = $Y
) - OCaml: you can match uppercase identifiers (constructors, module names) by
using a metavariable with an uppercase letter followed by an underscore,
followed by uppercase letters or digits (e.g.$X_
,$F_OO
).
Instead,$FOO
will match everything else (lowercase identifiers,
full expressions, types, patterns, etc.). - OCaml: match cases patterns are now matched in any order, and ellipsis are
handled correctly - Improved error messages sent to the playground
Changed
- Run version check and print upgrade message after scan instead of before
- OCaml: skip ocamllex and ocamlyacc files. Process only .ml and .mli files.
- Memoize range computation for expressions and speed up taint mode
- Report semgrep-core's message upon a parse error
- Deprecated the following experimental features:
- pattern-where-python
- taint-mode
- equivalences
- step-by-step evaluation output
- Deduplicate findings that fire on the same line ranges and have the same message.
Fixed
- Go: Match import module paths correctly (#3484)
- OCaml: use latest ocamllsp 1.7.0 for the -lsp option
- OCaml: include parenthesis tokens in the AST for tuples and constructor
calls for better range matching and autofix - OCaml: fixed many matching bugs with ellipsis
- core: Do not crash when is not possible to compute range info
- eliminate 6x slowdown when using the '--max-memory' option