Programming :: YACC Conflicts - First Error (Shift / Reduce)
Jun 17, 2011
I'm programming an SQL grammar using YACC and during compilation I got this error:
conflits:
1 shift/reduce, 2 reduce/reduce
the first error : shift/reduce
Code:
scalar_exp:
scalar_exp PLUS scalar_exp
| scalar_exp NEG scalar_exp
|scalar_exp MULT scalar_exp
|scalar_exp DIV scalar_exp
| atom
|column_ref
|function_ref .....
I am getting shift/reduce and reduce/reduce conflict in my yacc grammar code. yacc generates (i.e yacc -d -v parser.y) its grammar and state information in the parser.output file.
How can i interpret the below information and understand which grammar state is conflicting with other grammar state? Please help me to understand.
State 159 conflicts: 1 shift/reduce State 1863 conflicts: 1 shift/reduce State 1865 conflicts: 1 shift/reduce State 1960 conflicts: 1 shift/reduce
I was going through this Lex/YACC tutorial: [URL]... and I was working along with it. The Lex examples worked fine, but the YACC one quit white compiling
I have a rack of four 1TB drives all partitioned identically with three primary partitions. On each drive
- the first partition is only 64MB; - the second is a large 900GB partition and - the last holds all the remaining space
mdadm has been used to set up /dev/md0 - RAID1, comprised of /dev/sda1 and /dev/sdb1 /dev/md1 - RAID5, comprised of /dev/sda2, /dev/sdb2, /dev/sdc2, /dev/sdd2 /dev/md2 - RAID5, comprised of /dev/sda3, /dev/sdb3, /dev/sdc3, /dev/sdd3
OK, so it was a silly mistake to make - but I am now need to increase the size of /dev/md0. My thinking is to reduce the size of md1 so that I can grow md0.
On md1 I have two logical volumes. I've successfully reduced the size of the volume so that I can reduce the size of md1. Now I'm at the nervous stage; I can find little written on the topic of shrinking RAID5 arrays - and even if I do this I'm unsure if I can move partitions around to regain the space I so desire.
I had the following error while trying to install pcalc in Debian. I have bison and flex installed, and looking at the files it looks like there might be a problem with yacc being removed from the Debian library. I m trying to learn about memory registration and interaction with the CPU. This program could really help if I could get it to install Here's my log:
I had the following error while trying to install pcalc in Debian. I have bison and flex installed, and looking at the files it looks like there might be a problem with yacc being removed from the Debian library. I'm a newbie but am trying to learn about memory registration and interaction with the CPU. if I could get it to install Here's my log:
I issued "yum update" and the process ended with a transaction check error(see below). Running rpm_check_debug Running Transaction Test Finished Transaction Test
Transaction Check Error: file /usr/share/backgrounds/images/default-5_4.jpg from install of oracle-logos-4.9.17-6.noarch conflicts with file from package desktop-backgrounds-basic-2.0-41.el5.centos.noarch file /usr/share/backgrounds/images/default-dual-wide.jpg from install of oracle-logos-4.9.17-6.noarch conflicts with file from package desktop-backgrounds-basic-2.0-4 [code]...
I installed Oracle Database on this server few months ago. I see in /etc/yum.repos.d directory a public-yum-el5.repo file with entries pointing to Oracle which must have come from that installation. Now how do I proceed from here?
Fedora15 32bit. I write a test program, it creates new thread continually, the thread does nothing but sleep. I find virtual memory increases up almost 10Mb when a new thread is created. and when there's more than 200 threads, the virtual memory used by the program is 3Gb, and now cann't create new thread. but on windows, it costs little memory. What can I do to config the operation system to take less memory on threads?
I think I had this problem before but I don't remember what was done to correct it. I just tried to do an update and got this error message.
Code: Test Transaction Errors: file /usr/lib/gstreamer-0.10/libgstfbdevsink.so from install of gstreamer-plugins-bad-free-extras-0.10.18-1.fc12.i686 conflicts with file from package gstreamer-plugins-bad-0.10.17-2.fc12.i686 file /usr/lib/gstreamer-0.10/libgstoss4audio.so from install of gstreamer-plugins-bad-free-extras-0.10.18-1.fc12.i686 conflicts with file from package gstreamer-plugins-bad-0.10.17-2.fc12.i686 file /usr/lib/gstreamer-0.10/libgstsdl.so from install of gstreamer-plugins-bad-free-extras-0.10.18-1.fc12.i686 conflicts with file from package gstreamer-plugins-bad-0.10.17-2.fc12.i686 file /usr/lib/gstreamer-0.10/libgstshapewipe.so from install of gstreamer-plugins-good-0.10.21-1.fc12.i686 conflicts with file from package gstreamer-plugins-bad-0.10.17-2.fc12.i686 file /usr/bin/gst-camera from install of gstreamer-plugins-bad-free-0.10.18-1.fc12.i686 conflicts with file from package gstreamer-plugins-bad-0.10.17-2.fc12.i686 file /usr/bin/gst-camera-perf from install of gstreamer-plugins-bad-f...
so i have f12 installed on my hd with lvm using the whole extent of the HD , i want to reduce it so i can dual boot it with a windows system, i managed to reduce the logical volume to free some space, but i cant seem to reduce the physical volume, is this possible and how ?
It seems to me that I've got a dual package somewhere.
Quote:
Transaction Check Error: file /usr/lib/libakonadi-kabc.so.4 from install of kdepimlibs-4.2.0-1.fc10.i386 conflicts with file from package kdepim-libs-6:4.1.4-1.fc10.i386 file /usr/share/config/plasmoids.knsrc from install of kdelibs-6:4.2.0-10.fc10.i386 conflicts with file from package kdebase-workspace-4.1.4-1.fc10.i386 file /usr/share/kde4/servicetypes/plasma-animator.desktop from install of kdelibs-6:4.2.0-10.fc10.i386 conflicts with file from package kdebase-workspace-4.1.4-1.fc10.i386
I have MySQL 5.1.34 and PHP 5.1.6 installed on my system, how do I install php-mysql? Each time I try, it says
mysql-5.0.45-7.el5.i386 from base has depsolving problems -- > mysql conflicts with mysql-server-community error: mysql conflicts with mysql-server-community
I'm installing a NVIDIA driver and encountered some error message. Please see below the sequence (I've set runlevel to init 3);
linux:~/SuSe # rpm -ivh NVIDIA_GLX-1.0-4191.suse81:i586.rpm Preparing... ############################ [100%])file /usr/X11R6/lib/modules/drivers/nvidia-drv.o from install of NVIDIA_GLX-1.0-4191 conflicts with file from package XFree86-server-4.3.0.1-21
I have installed php 5.3.6-4 on centOS 5.6. When i try to install some modules of php then it gives an error
php53-common-5.3.3-1.el5_6.1.i386 from updates has depsolving problems --> php53-common conflicts with php-common Error: php53-common conflicts with php-common
[code]....
I have reinstall it twice but each time i get same error.
reducing the size of LVM. I did it by using the commands, lvreduce,fsck,resize2fs.After reducing the lvm size, my system is not booting...it is saying file system corrupted error.
I'm writing a parser using lex and yacc for an IEEE standard language ( STIL ). Here's the lex file ( some of ).
[Code]....
stil_language is the start symbol. The bus variable is initialised at 0 ( There's a check in the main ). The problem is that the parser does not recognises the NUM token ! It just re writes any expression that corresponds to the "number" regular expression. Here's a prompt example :
I am porting a code which ran on HP unix to CentOS. It was a working code and compiled with gcc3.1.x and a c++ file and now I tried to compile with gcc3-3.4.6 and gcc4-4.2.4 also. But still I get this conflicts in declaration error as pasted below.
I'm using Debian Testing (I know it doesn't happen in Stable)
Words isn't required here. I'll show examples:
# aptitude dist-upgrade Code: Select allThe following NEW packages will be installed: Â appstream{a} coinor-libcoinutils3v5{ab} coinor-libosi1v5{ab} cpp-5{a} Â g++-5{a} gcc-5{a} gcj-5-jre{a} gcj-5-jre-headless{a} gcj-5-jre-lib{a} Â geoip-database-extra{a} gnuplot5-data{a} gnuplot5-qt{a} icoutils{a} Â kded5{a} kinit{a} kio{a} libapt-inst1.7{a} libapt-pkg4.16{a} libasan2{a}
[Code] ....
Why apt-get can while aptitude can't?
I've searched on web, and all I can tell is that aptitude is "safer" than apt-get because it taking account the packages on hold.
But I don't have any package on hold! (I've tested dpkg --get-selections | grep hold)
When I moved from Fedora 13 from Fedora 11, I thought the annoying application crashes that I had been having were gone for good. Random crashes - firefox, Thunderbird, Abrt, metacity and what have you with SIGSEGV errors. I'm beginning to believe that these are not down to Fedora or even the RAM (Have run Memtest, several times). I'm not sure if what I am seeing are signs of IRQ conflicts of some sort. Can someone, please have a look and give me some guidance on what to do? Should I reinstall with acpi=off ? noapic? Also, don't have a clue why the system complains of ECC being disabled? The RAM is non-ECC. I have posted some sections of the logs here with links to the full logs instead of making this a massive post.
Code: EDAC MC: Ver: 2.1.0 Aug 27 2010 EDAC amd64_edac: Ver: 3.3.0 Aug 27 2010 EDAC amd64: This node reports that Memory ECC is currently disabled, set F3x44[22] (0000:00:18.3). EDAC amd64: ECC disabled in the BIOS or no ECC capability, module will not load. Either enable ECC checking or force module loading by setting 'ecc_enable_override'. (Note that use of the override may cause unknown side effects.) amd64_edac: probe of 0000:00:18.2 failed with error -22 Complete system spec, BIOS details etc.
Full dmesg log on a fresh install. No issues experienced with system installation.
I recently locked Thunderbird 3.1.8 and Firefox 4.0 using zypper addlock, but now every time I go into Online Update I get "There are some conflicts on the transaction that must be solved manually." with these "options" which I have to tell it "Do not install..." (2x) seen at SUSE Paste.Is Online update trying to update my locked apps or a DEP of the locked app or something else? I can't touch those 2 apps, but how can I "fix" this behavior?
OpenSUSE 11.4, 64 bits, with Index of /repositories/KDE:/Release:/46/openSUSE_11.4 and Index of /repositories/KDE:/Extra/KDE_Release_46_openSUSE_11.4 repositories enabled. Since some days, if I go to YaST2 †’ Package †’ "Update packages if a new version is available" (I'm translating from Spanish) I get a warning that plasma-addons-4.6.5-9.3.x86_64 needs akonadi-runtime < 1.5.40, but that that requirement cannot be match because there are eliminated providers: akonadi-runtime-1.5.3-91.1.x86_64 and non instalable providers: akonadi-runtime-1.5.0-3.3.1.x86_64[openSUSE-11.4-11.4-0] As "solution" it offers me to not install akonadi-runtime-1.6.0.93.1.x86_64 and libakonadiprotocolinternals1-1.6.0.93.1.x86_64 (which I selected) or to uninstall plasma-addons and kadressbook, which I do not think it is a good idea...
I keep getting u1conflicts in my Moneydance backup. For example, I am usually doing something in Moneydance daily. However, when I went to open it up yesterday, it didn't save anything from the previous 3 days. The last 3 days worth were u1.conflict. Moreover, this is the only computer that we do the Moneydance transactions on. My other question is about the speed it is taking to upload all my pictures. Granted, I do have A lot of pictures (3000+), but it is taking forever to upload them. When U1 is running, it takes all of the bandwidth. My husband already posted something about limiting the bandwidth problems. What I am wondering though is if there is a way to get all my pictures backed up faster? I have been trying to back them up for about a week now. In 6 hours, it only backed up 115 files of over 3000, and that is using up all of our bandwidth.
I am having conflicts in my software sources some maybe out of date but I am not sure how to tell which ones are. Is there a program that solves these problems. I have Ubuntu 10.4