# $/kEND parse error nightmare

**URL:** <https://rubytalk.org/t/kend-parse-error-nightmare/26311>\
**Category:** ruby-talk\
**Created:** [31 March 2006 22:45 UTC](https://rubytalk.org/t/kend-parse-error-nightmare/26311 "2006-03-31T22:45:04Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kurt\_V\_Hindenburg](https://avatars.discourse-cdn.com/v4/letter/k/9de0a6/32.png) [@Kurt\_V\_Hindenburg](https://rubytalk.org/u/Kurt_V_Hindenburg)\
**Post date:** [31 March 2006 22:45 UTC](https://rubytalk.org/t/kend-parse-error-nightmare/26311/1 "2006-03-31T22:45:04Z")

</div>

Hello,  
&nbsp;&nbsp;In all the time I've used Ruby, I've never come across such an aggravating,  
uninformative error message... argh!

parse error, unexpected $, expecting kEND

wtf?

&nbsp;&nbsp;Regards,  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Kurt

% ruby --version  
ruby 1.8.4 (2005-12-24) [sparc-linux]

---

<div class="post-metadata">

**Author:** ![Logan\_Capaldo](https://avatars.discourse-cdn.com/v4/letter/l/7ea924/32.png) [@Logan\_Capaldo](https://rubytalk.org/u/Logan_Capaldo)\
**Post date:** [31 March 2006 23:28 UTC](https://rubytalk.org/t/kend-parse-error-nightmare/26311/2 "2006-03-31T23:28:40Z")

</div>

This means, unexpected end of line, (or possibly end of file) I was expecting to see the keyword "end"

> **···**
>
> On Mar 31, 2006, at 5:45 PM, Kurt V. Hindenburg wrote:
> 
> > parse error, unexpected $, expecting kEND

---

<div class="post-metadata">

**Author:** ![gabriele\_renzi8](https://avatars.discourse-cdn.com/v4/letter/g/35a633/32.png) [@gabriele\_renzi8](https://rubytalk.org/u/gabriele_renzi8)\
**Post date:** [1 April 2006 08:58 UTC](https://rubytalk.org/t/kend-parse-error-nightmare/26311/3 "2006-04-01T08:58:43Z")

</div>

Kurt V. Hindenburg ha scritto:

> Hello,  
> &nbsp;&nbsp;In all the time I've used Ruby, I've never come across such an aggravating, uninformative error message... argh!
> 
> parse error, unexpected $, expecting kEND
> 
> wtf?

notice that before bison 2.0 you did not had neither this messages 🙂

I reported the strange messages around ruby-talk:179793 and matz said he did not know of a way to get better error messages.

In ruby-talk:182173 I reported that there is a siple solution, at least for some things, but I don't know if someone in ruby-core/dev ever read or considered that, I guess providing a patch to parse.y would be helpful 🙂

---

<div class="post-metadata">

**Author:** ![Robin\_Stocker1](https://avatars.discourse-cdn.com/v4/letter/r/ce7236/32.png) [@Robin\_Stocker1](https://rubytalk.org/u/Robin_Stocker1)\
**Post date:** [2 April 2006 01:06 UTC](https://rubytalk.org/t/kend-parse-error-nightmare/26311/4 "2006-04-02T01:06:25Z")

</div>

gabriele renzi wrote:

> In ruby-talk:182173 I reported that there is a siple solution, at least for some things, but I don't know if someone in ruby-core/dev ever read or considered that, I guess providing a patch to parse.y would be helpful 🙂

Hi,

With the help of your mail about how to add descriptive names to tokens I wrote a patch and sent it to ruby-core 🙂  
[http://ruby-talk.org/cgi-bin/scat.rb/ruby/ruby-core/7653](http://ruby-talk.org/cgi-bin/scat.rb/ruby/ruby-core/7653)

Regards,  
&nbsp;&nbsp;&nbsp;Robin Stocker

---

<div class="post-metadata">

**Author:** ![gabriele\_renzi8](https://avatars.discourse-cdn.com/v4/letter/g/35a633/32.png) [@gabriele\_renzi8](https://rubytalk.org/u/gabriele_renzi8)\
**Post date:** [2 April 2006 11:18 UTC](https://rubytalk.org/t/kend-parse-error-nightmare/26311/5 "2006-04-02T11:18:44Z")

</div>

Robin Stocker ha scritto:

> Hi,
> 
> With the help of your mail about how to add descriptive names to tokens I wrote a patch and sent it to ruby-core 🙂  
> [http://ruby-talk.org/cgi-bin/scat.rb/ruby/ruby-core/7653](http://ruby-talk.org/cgi-bin/scat.rb/ruby/ruby-core/7653)

well, great, I was hoping for something like this 🙂
