Posted 16 years ago by Jason Tobiasz
Avatar
I'm having great difficulty modifying our current production. I'm rather new to this stuff and having a hard time putting the pieces together. If you could direct me to some resource other than the help file, I'd greatly appreciate it.

Here is my current issue:

At the end of the production, I want to put out an error messgage:

<Production><![CDATA[
<% //some data init %>
'Define<+ startOffset = this.Token.StartOffset; +>'
(
"procedure<@ out statement @>"
)
| (
"macro<@ out statement @>"
)
| <? true ?><% this.ReportSyntaxError("'Procedure' or 'Macro' expected."); return false; %>

...

Well, I cannot figure out how to stuff that error message into the else after the grammar is generated. By doing it the way I have above, it automatically generates an else if (true) and then an else with a false in it. That creates a compiler warning saying 'Unreachable code'...I'm trying to get rid of it.

[Modified at 04/06/2009 02:12 PM]

Comments (1)

Posted 16 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
The "Simple" language in the sample project is a good place to look too since it shows implementation of a simple language, with full IntelliPrompt support etc.

We'll mark down a TODO item list to try and eliminate the additional else for the scenario with <? true ?>. Thanks for the post.


Actipro Software Support

The latest build of this product (v25.1.0) was released 20 days ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.