I have a problem, and I'm not even sure I'm close to solving it. I have a grammar, that defines two types of symbols, in seperate symbol tables AList BList A...
13471
Bryan Ewbank
ewbankb
Oct 1, 2004 2:58 pm
If I understand what you want to do, you can use tokens instead of some external command; look for information on the tokens section, and the testLiterals ...
13472
Bryan Ewbank
ewbankb
Oct 1, 2004 3:02 pm
I think the problem here is that the tree is not constructed (because of the "!" following priVal). Therefore, INT is not recognized as "special" in the...
13473
Colm McHugh
colmmagoo
Oct 1, 2004 9:15 pm
Hi antlr-interest, [Language=C++ only, didn't try with Java] This is in the realm of triviality, but I noticed today that antlr produces what looks like to me...
13474
PAQ2000
Oct 2, 2004 1:16 pm
Hi, I'm writing a scanner for a pseudo assembly language program. Inside, they have a command LOAD and LOADI. This is how my code looks: LOAD: "load"; LOADI:...
13475
Monty Zukowski
montyzukowski
Oct 2, 2004 4:35 pm
Look at the lexer documentation about "literals". Monty...
13476
Richard Clark
rdsclark
Oct 2, 2004 6:04 pm
I'm trying to get the antlr/eclipse bridge working and I've hit a glitch. I had to create an adaptor that uses an Eclipse document as an input source, and I'm...
13477
Terence Parr
parrt2000
Oct 2, 2004 6:16 pm
... Hi Richard, Looking forward a great deal to your presentation on this next week at the workshop! Woohoo! ... Really? Hmm...Oh, EOF is a member of "not...
13478
Richard Clark
rdsclark
Oct 3, 2004 7:04 am
... Work has been eating me alive, but I'll have some stuff to show. A fair bit of the discussion could be on the "impedance matching" needed to bridge antlr...
13479
tim_doege
Oct 3, 2004 3:19 pm
I've seen serveal people suggesting to re-inject characters back into the stream (to solve different types of problems). However, I'm unable to find a...
13480
Bryan Ewbank
ewbankb
Oct 4, 2004 1:48 pm
... Easiest to use literals - define a general rule for IDENTIFIER, then use keyword lookup to intercept and change token values. Search for "testLiterals" and...
13481
Akhilesh Mritunjai
virtualaspirin
Oct 4, 2004 9:31 pm
Hi Have you set the lookahead to at least 5 for this case ? If not, put "k=5;" in the options section of lexer. - Akhilesh ... ...
13482
lgcraymer
Oct 4, 2004 9:36 pm
This would be true if ANTLR recognized literals individually, but ANTLR does not do that. What actually happens is that ANTLR constructs the token, then...
13483
PAQ2000
Oct 5, 2004 5:37 am
Thank you for the help you guys. I did read about the literals and the lookahead values and I actually tried a combination of both your ideas. I set k=10 and...
13484
codeteacher
Oct 5, 2004 11:04 pm
Hi all, I've got the following rule: positiveNumeric returns [String value] : ( i:NUM_INT {value = i.getText();} ... But ANTLR gave me this warning: ...
13485
codeteacher
Oct 5, 2004 11:04 pm
Hi all, Is it possible that in each rule we can throw custom exceptions other than modifying the generated code directly? What I mean is: MyRule {action}...
13486
kozchris
Oct 5, 2004 11:23 pm
You are fine. I don't think you can suppress this message (at least I haven't found a way). The warning is useful for checking why you haven't used the value ...
13487
mazypath
Oct 5, 2004 11:36 pm
Right. I mentioned this earlier in the thread. I also want to specify an AST for my tokens. I should be able to do this in the tokens block as so: tokens { ...
13488
Ric Klaren
izniegoed
Oct 6, 2004 12:13 am
Hi, Just had a quick peek at the codegenerator, I did not directly see a way this could happen. So could you please post a minimal grammar that exposes the...
13489
mazypath
Oct 6, 2004 8:42 pm
Thanks for your help. Your reply started me thinking. I've been using the eclipse plugin for ANTLR. It turns out that the plugin is the source of the...
13490
mazypath
Oct 6, 2004 8:57 pm
On futher investigation, it turns out that the bug in the plugin was fixed two weekes ago (4 days before I ran into a problem) in release 3.0.3 of the plugin. ...
13491
PAQ2000
Oct 6, 2004 8:58 pm
Hi Everyone, I'm still new to ANTLR, and I'm at a definite disadvantage because I don't know java, and it seems as though all the help/examples online are...
13492
ManimuthuLakshmi Pitc...
antlr_lakshmi
Oct 6, 2004 10:52 pm
Hi, How can i shift the position of node2 to node3? For example: Tree ... Thanks. Best Regards, Lakshmi ... Do you Yahoo!? vote.yahoo.com - Register online to...
13493
Thierry Miceli
sophocle33
Oct 6, 2004 10:54 pm
... Wrong, there is a 'string39; type that is part of the STL (standard template library) that should come with your C++ compiler. ... This way: std::string...
13494
PAQ2000
Oct 7, 2004 1:40 am
haha, thanks Thierry! I guess I'm rusty at the C++. Admittedly, I always avoid it whenever possible. I guess I shoulda just did what pilots do: "check six!" ...
13495
Bryan Ewbank
ewbankb
Oct 7, 2004 6:12 am
To get nodes in the tree "out of order", you have to build that part of the tree yourself... Assuming you have the production tree: node1 node2 node3; Replace...
13496
Bryan Ewbank
ewbankb
Oct 7, 2004 2:21 pm
Hi Folks, I've been building flattened trees for things like argument lists, but am now encountering a question of how to process these nodes in a general way,...
13497
send2jafer1
Oct 7, 2004 2:32 pm
i am having a lot of parameters defined in the lexer , whose input accepts values . but one among the parameters should accept a string which may contain "...
13498
Chris Miner
chris_miner
Oct 7, 2004 2:33 pm
I want to my generated parser as part of a C++ application on a smartphone. Compiling the antlr library for the target platform fails do to the use of cerr,...
13499
Monty Zukowski
montyzukowski
Oct 7, 2004 2:37 pm
... The tree rule would be identical to what you had before, substituting ARGLIST for COMMA. Your tree used to be #(COMMA arg1 arg2 ...) now it is #(ARGLIST...