Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » Single quotation marks consumed incorrectly
Single quotation marks consumed incorrectly [message #1058806] Wed, 15 May 2013 07:55 Go to next message
Claudio Heeg is currently offline Claudio HeegFriend
Messages: 75
Registered: April 2013
Member
Hello, following problem:
I'm in the process of defining a grammar.
One concrete function should look as follows:
Func('123','456')

However, currently only
Func('123', '456')
(note the whitespace) and
Func("123","456")
seem to work.
Trying the function as it should be produces the error <mismatched input ','' expecting ','> at the comma.
However, I can't seem to find the error in my grammar that would cause this.

Func: 'Func''('something=String_Encap_IntParam','sthElse=String_Encap_IntParam')';

..

String_Encap_IntParam : STRING_ENCAP_INT;
terminal STRING_ENCAP_INT : '"' INT '"' | "'" INT "'"; 

I do not have any terminals or Datatypes defined that involve the sequence ",'" either, so I'm at a loss here, especially since a simple whitespace makes the function work.

Help is much appreciated.

[Updated on: Wed, 15 May 2013 07:57]

Report message to a moderator

Re: Single quotation marks consumed incorrectly [message #1058808 is a reply to message #1058806] Wed, 15 May 2013 08:05 Go to previous messageGo to next message
Christian Dietrich is currently offline Christian DietrichFriend
Messages: 14661
Registered: July 2009
Senior Member
Hi,

sorry i cannot reproduce this (Xtext 2.4.1). do you have any keywords contains ws or stuff like that.


Twitter : @chrdietrich
Blog : https://www.dietrich-it.de
Re: Single quotation marks consumed incorrectly [message #1058809 is a reply to message #1058808] Wed, 15 May 2013 08:12 Go to previous message
Claudio Heeg is currently offline Claudio HeegFriend
Messages: 75
Registered: April 2013
Member
Hello - yeah, it seems to work on a minimal example, just wrote one up quickly.
I guess there's some ambiguity hidden somewhere after all.

Thanks anyway!

Edit:
It also works now and I have no idea why. Always nice.

[Updated on: Wed, 15 May 2013 08:20]

Report message to a moderator

Previous Topic:Content assist formatted text with HTML mark-up
Next Topic:Remove gaps from the blanked name
Goto Forum:
  


Current Time: Thu Mar 28 13:38:06 GMT 2024

Powered by FUDForum. Page generated in 0.07270 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top