From 1fa0be9782eea7e780e3f0500f50a679d8cad2a0 Mon Sep 17 00:00:00 2001 From: Raphael R Date: Thu, 18 Feb 2016 11:51:59 +0100 Subject: [PATCH 1/4] Fixes Markdown table in targets.md --- doc/targets.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/targets.md b/doc/targets.md index 00058a4af..e9478aed8 100644 --- a/doc/targets.md +++ b/doc/targets.md @@ -18,7 +18,7 @@ The [ANTLR v4 book](http://pragprog.com/book/tpantlr2/the-definitive-antlr-4-ref New features generally appear in the Java target and then migrate to the other targets, but these other targets don't always get updated in the same overall tool release. This section tries to identify features added to Java that have not been added to the other targets. |Feature|Java|C♯|JavaScript|Python2|Python3|Swift|C++| -|-|-|-|-|-|-|-|-| +|---|---|---|---|---|---|---|---| |Ambiguous tree construction|4.5.1|-|-|-|-|-|-| From eb5af71a301fb6a388296cb2a00ceec82cf0429b Mon Sep 17 00:00:00 2001 From: David Tymon Date: Tue, 15 Mar 2016 13:38:55 +1100 Subject: [PATCH 2/4] JS: ATNConfig can incorrectly change "alt" of 0 to null When an ATNConfig instance is created with an alt of 0, it is possible for it to be incorrectly changed to null due to its "falsey" nature. --- runtime/JavaScript/src/antlr4/atn/ATNConfig.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/runtime/JavaScript/src/antlr4/atn/ATNConfig.js b/runtime/JavaScript/src/antlr4/atn/ATNConfig.js index 0b13737ed..988729dc7 100644 --- a/runtime/JavaScript/src/antlr4/atn/ATNConfig.js +++ b/runtime/JavaScript/src/antlr4/atn/ATNConfig.js @@ -50,7 +50,7 @@ function checkParams(params, isCfg) { } else { var props = {}; props.state = params.state || null; - props.alt = params.alt || null; + props.alt = (params.alt === undefined) ? null : params.alt; props.context = params.context || null; props.semanticContext = params.semanticContext || null; if(isCfg) { From 93b1fa53b450f9f55f6ef8191cc566a1037e69a5 Mon Sep 17 00:00:00 2001 From: Justin Szaday Date: Fri, 25 Mar 2016 22:16:54 -0500 Subject: [PATCH 3/4] Fixing Issue #1148, Python Target Generates Invalid Code With Rule Named 'Return' --- tool/src/org/antlr/v4/codegen/target/Python2Target.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tool/src/org/antlr/v4/codegen/target/Python2Target.java b/tool/src/org/antlr/v4/codegen/target/Python2Target.java index efa5d2ce9..51ee8689c 100644 --- a/tool/src/org/antlr/v4/codegen/target/Python2Target.java +++ b/tool/src/org/antlr/v4/codegen/target/Python2Target.java @@ -61,7 +61,7 @@ public class Python2Target extends Target { "memoryview", "object", "oct", "open", "ord", "pow", "print", "property", - "range", "raw_input", "reduce", "reload", "repr", "reversed", "round", + "range", "raw_input", "reduce", "reload", "repr", "return", "reversed", "round", "set", "setattr", "slice", "sorted", "staticmethod", "str", "sum", "super", "tuple", "type", "unichr", "unicode", From 7b9a7b5ec5be0dc314fef372bff0322322b67e1b Mon Sep 17 00:00:00 2001 From: Raphael R Date: Tue, 29 Mar 2016 10:47:18 +0200 Subject: [PATCH 4/4] Update contributors.txt --- contributors.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/contributors.txt b/contributors.txt index 07a894eda..7293713a0 100644 --- a/contributors.txt +++ b/contributors.txt @@ -88,5 +88,6 @@ YYYY/MM/DD, github id, Full name, email 2015/12/17, sebadur, Sebastian Badur, sebadur@users.noreply.github.com 2015/12/23, pboyer, Peter Boyer, peter.b.boyer@gmail.com 2015/12/24, dtymon, David Tymon, david.tymon@gmail.com +2016/02/18, reitzig, Raphael Reitzig, reitzig[at]cs.uni-kl.de 2016/03/27, beardlybread, Bradley Steinbacher, bradley.j.steinbacher@gmail.com 2016/03/28, gagern, Martin von Gagern, gagern@ma.tum.de