question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Add support to label rules of mixed types

See original GitHub issue

Currently it’s allowed to label rules of mixed types, however it compiles to an invalid code.

example: value=integer | value=string;

The generated parser will contain a value property which type is StringContext (because it was declared later). IMHO, the most appropriate behaviour is to declare the property as ParserRuleContext (all rules) or ParseTree (rules and tokens).

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:7 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
sharwellcommented, Dec 4, 2016

For whoever fixes it, make sure there is a unit test showing the following works fine:

example
  : value=integer # integerExample
  | value=string # stringExample
  ;
0reactions
KvanTTTcommented, Dec 7, 2016

We also can not use a += operator for rules with different types (table updated):

rule5
    : t5 += a+ b t5 += c+
    ;
Read more comments on GitHub >

github_iconTop Results From Across the Web

Labeling Controls | Web Accessibility Initiative (WAI) - W3C
This section of the tutorial describes how to provide labels that are properly associated with form controls. Later sections explain how to provide...
Read more >
Organize your rules with labels | Cloud automation Cloud
Labels are key words or tags that you can add to rules to categorize, identify, and bookmark your automation rules. For example, you...
Read more >
Learn about sensitivity labels - Microsoft Purview (compliance)
Require users to apply a label for the different types of items and the containers that support sensitivity labels.
Read more >
Essential labeling concepts—Help | ArcGIS for Desktop
Labeling is useful to add descriptive text to your map for many features. ... of the text to help differentiate labels for different...
Read more >
FSIS Compliance Guideline for Label Approval (July 2020)
label approval regulations to expand the circumstances in which certain types of labels are generically approved. The Labeling and Program Delivery Staff ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found