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.

Change cross-reference syntax

See original GitHub issue

The cross-reference syntax of Xtext is [Type|TOKEN], where Type is the AST type of the reference and TOKEN is a terminal rule or datatype rule that shall be parsed here. This syntax is misleading because in the context of TypeScript | means an alternative.

Proposals: [Type: TOKEN], [TOKEN: Type]

Of course omitting the token shall still be possible: [Type] (the token defaults to ID)

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:1
  • Comments:19 (18 by maintainers)

github_iconTop GitHub Comments

1reaction
spoenemanncommented, Sep 3, 2021

I understand why that decision was made: it’s like the mathematical notation for sets {a | a > 0}. The same reasoning is behind the lambda syntax of Xtend. The point is that it’s inconsistent with all major programming languages that we use. We should keep the good parts of the Xtext syntax, but change the bad parts. Easing migration is a separate topic, we could even offer a CLI to convert .xtext to .langium.

0reactions
spoenemanncommented, Jan 13, 2022

We had an internal chat about this and decided to keep the current syntax. Feel free to drop new thoughts here anyway.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Formatting Cross-references - Suzanne S. Barnhill
Change the case of a cross-reference ... The first letter of each word. For example, { FILLIN "Type your name:" \* Caps }...
Read more >
Create a cross-reference - Microsoft Support
In the document, type the text that begins the cross-reference. · On the Insert tab, click Cross-reference. · In the Reference type box,...
Read more >
how cross-reference fields work - Microsoft Word Add Ins
In the Ribbon, select References tab > Captions group: Cross-references. Note that you will also find the command in Insert tab > Links...
Read more >
How To Update Cross-References in Word in 4 Steps - Indeed
To update all your cross-references, right-click on the original reference you highlighted. In the drop-down menu, between the "Paste" and "Edit ...
Read more >
Editing Cross-Reference Style Formats
How to Edit a Cross-Reference Style Format at the Point of Insertion · Open the document or topic. · In the XML Editor,...
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