473,756 Members | 3,111 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Yacc non terminal Symbol

SSG
I tried one lex, yacc program, but it says the error

yacc: e - line 349 of "comp_y.y", a token appears on the lhs of a
production

can anyone tell me about the error..

How to solve it...

By
SSG

Dec 7 '05 #1
4 3146
SSG wrote
(in article
<11************ **********@o13g 2000cwo.googleg roups.com>):
I tried one lex, yacc program, but it says the error

yacc: e - line 349 of "comp_y.y", a token appears on the lhs of a
production

can anyone tell me about the error..


Why don't you ask in an appropriate newsgroup?

comp.computers. tools.lex+yacc

Followups set...

--
Randy Howard (2reply remove FOOBAR)
"The power of accurate observation is called cynicism by those
who have not got it." - George Bernard Shaw

Dec 7 '05 #2
On 2005-12-07, SSG <ss****@gmail.c om> wrote:
I tried one lex, yacc program, but it says the error

yacc: e - line 349 of "comp_y.y", a token appears on the lhs of a
production

can anyone tell me about the error..

How to solve it...

By
SSG


It's really not on-topic for here, but there's really no way to tell
without line 349 and possibly context around it
Dec 7 '05 #3
SSG wrote:
I tried one lex, yacc program, but it says the error

yacc: e - line 349 of "comp_y.y", a token appears on the lhs of a
production

can anyone tell me about the error..

How to solve it...


$oracle -mw

- - 22. Jiji (63. Jiji)
--- Already Completed:
- - Receipt;
--- slightly beneficial to determine;
-X- initially auspicious, in the end disordered.
---

second yin:
The wife loses her hair;
do not follow,
in seven days you will get it.

- - 18. Ru (5. Xu)
--- Moistened.
- - There is a return;
--- radiant receipt;
--- determination is auspicious;
--- beneficial to ford the great river.

$
Dec 7 '05 #4

Jordan Abel schrieb:
On 2005-12-07, SSG <ss****@gmail.c om> wrote:
I tried one lex, yacc program, but it says the error

yacc: e - line 349 of "comp_y.y", a token appears on the lhs of a
production

can anyone tell me about the error..

How to solve it...

By
SSG


It's really not on-topic for here, but there's really no way to tell
without line 349 and possibly context around it


A qualified guess is that the symbol on the left hand side of line 349
was declared as token earlier. But, on the left hand side of a grammar
rule, only non terminal symbols make sense.

Dec 7 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

18
10754
by: Moonlit | last post by:
Hi, I am searching for the best lex and yacc combination (or something similar) that can be used in combination with C++ and that can contain C++ code. I have the regular flex/bison port working but then I, of course, can't use C++ constructs in the actions. I have tried spirit although I could make a simple command line parser (after too many hours), creating a parser tree with it was not possible in an easy way (the compiler choked...
4
6340
by: Profetas | last post by:
Hi. I was wondering how can I access the yacc functions? because when use a normal yacc function such as qstring { yylval.string = strdup(yytext+1); if(yylval.string !='"') warning("Undeterminated Character strig",(char *)0); else
4
4902
by: Rodrick Brown | last post by:
This might be off topic but can someone give me a quick run down on why tools like lexx/yacc/bison are usefull ? I know what there used for but not sure when they should be used and where ? Thanks. -- Rodrick R. Brown
3
11827
by: John Sasso | last post by:
In my Yacc .y file I defined: %union { int value; struct Symbol Sym; } The Symbol struct I defined in a header file I #included in the Prologue section of the .y file as:
6
15485
by: Volker Hetzer | last post by:
Hi! We are finding ourselves in a situation where we have to parse several more or less free format text files. In the past, on linux, we had flex and bison for generating very fast parsers for these files. Is there any equivalent in the visual studio world? Lots of Greetings! Volker --
13
5021
by: Berk Birand | last post by:
Hi, I am working on a school project where we use lex/yacc to write a compiler for a fictional (Java-like) language. I have handled all the details about the yacc and lex files, but I still have a question regarding the dynamic memory allocation for strings. When the lex file encounters a variable name, I want it to pass this to yacc through yylval, and then retrieve it to add to a syntax tree. For this purpose, I wrote the following...
2
7523
by: max.giacometti | last post by:
Hi everybody! I am using lex and yacc to write a vhdl to systemc converter. Lex simply reads the input file and yacc implements grammar and translation. I'd like to be able to make yacc able to command lex to stop reading the current file and starting reading another file, when the inclusion syntax is reached.
2
1744
by: Xose Lois Castro | last post by:
Hi, mates: I'm trying to write a grammar to read files with the following structure, for example: text ... more text
1
2031
by: Robert | last post by:
If the goal is to take a 1-dimensional package of text and produce a tree data structure that is easy to understand and manipulate, and then write C/C++ code that works with that tree - does lex/yacc suit that purpose - i.e. kind of like a tree-manufacturing C library? Or is it for producing a compiler/interpreter the internals of which a new C/ C++ program cannot so easily work with?
0
9152
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9716
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9571
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7116
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6410
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4996
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5180
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3185
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2542
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.