Forum: Ruby rkelly 1.0.1 Released

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Aaron P. (Guest)
on 2009-06-09 02:11
(Received via mailing list)
I have no idea how this happened, but I'm sure that someone pulling out
a
Beretta was involved.  Anyway, here it is:

rkelly version 1.0.1 has been released!

* <http://rkelly.rubyforge.org/>

The RKelly library will parse JavaScript and return a parse tree.

Changes:

### 1.0.1

* Bugfixes

  * Fixed nondeterministic file order loading issue.

## Example

  ##
  # Iterate over and modify a JavaScript AST.  Then print the modified
  # AST as JavaScript.
  require 'rkelly'

  parser = RKelly::Parser.new
  ast    = parser.parse(
    "for(var i = 0; i < 10; i++) { var x = 5 + 5; }"
  )

  ast.each do |node|
    node.value  = 'hello' if node.value == 'i'
    node.name   = 'hello' if node.respond_to?(:name) && node.name == 'i'
  end
  puts ast.to_ecma # => awesome javascript

* <http://rkelly.rubyforge.org/>
Eleanor McHugh (Guest)
on 2009-06-09 19:18
(Received via mailing list)
On 8 Jun 2009, at 23:10, Aaron P. wrote:
> I have no idea how this happened, but I'm sure that someone pulling
> out a
> Beretta was involved.  Anyway, here it is:
>
> rkelly version 1.0.1 has been released!
>
> * <http://rkelly.rubyforge.org/>
>
> The RKelly library will parse JavaScript and return a parse tree.

You are a sick puppy - and I love you for it :)


Ellie

Eleanor McHugh
Games With Brains
http://slides.games-with-brains.net
----
raise ArgumentError unless @reality.responds_to? :reason
Aaron P. (Guest)
on 2009-06-09 19:45
(Received via mailing list)
On Wed, Jun 10, 2009 at 12:18:04AM +0900, Eleanor McHugh wrote:
>
> You are a sick puppy - and I love you for it :)

This is what happens when you sit next to Ryan all day. ;-)
Ryan D. (Guest)
on 2009-06-09 21:20
(Received via mailing list)
On Jun 9, 2009, at 08:44 , Aaron P. wrote:

>>> The RKelly library will parse JavaScript and return a parse tree.
>>
>> You are a sick puppy - and I love you for it :)
>
> This is what happens when you sit next to Ryan all day. ;-)

Pthththth

_I_ don't own a single pain of zubaz pants. I'm not even remotely the
cause of your sickness.
Tony A. (Guest)
on 2009-06-09 21:28
(Received via mailing list)
On Mon, Jun 8, 2009 at 4:10 PM, Aaron P.
<removed_email_address@domain.invalid>wrote:

> I have no idea how this happened, but I'm sure that someone pulling out a
> Beretta was involved.  Anyway, here it is:
>
> rkelly version 1.0.1 has been released!
>
> * <http://rkelly.rubyforge.org/>
>
> The RKelly library will parse JavaScript and return a parse tree.
>

Hey, this is an awesome library, but there's one thing I should point
out
about your description on Rubyforge:

This library will parse Javascript and turn it into Ruby. The ruby
generated
> should be functionally equivalent to the Javascript.
>

At the time I was looking for a JavaScript-to-JavaScript compiler to do
some
code futzing.  When I found RKelly, I was like "hey great, a Racc
grammar
for JavaScript!"  However I was too lazy to check the README and started
trying to pull the grammar/parser into my project first before
discovering
that it was a fully fledged JavaScript-to-JavaScript compiler.

You might want to note that it also outputs JavaScript on the Rubyforge
description.
Eleanor McHugh (Guest)
on 2009-06-09 21:36
(Received via mailing list)
On 9 Jun 2009, at 18:19, Ryan D. wrote:
>>>>
> _I_ don't own a single pain of zubaz pants. I'm not even remotely
> the cause of your sickness.

Hmmm... sitting next to the author of Wilson and RubyInline... all day
long? That's gotta have some kind of osmotic influence...


Ellie

Eleanor McHugh
Games With Brains
http://slides.games-with-brains.net
----
raise ArgumentError unless @reality.responds_to? :reason
Eric H. (Guest)
on 2009-06-09 22:55
(Received via mailing list)
On Jun 9, 2009, at 10:27, Tony A. wrote:
> At the time I was looking for a JavaScript-to-JavaScript compiler to
> Rubyforge
> description.

I think you missed the first line:

>> I have no idea how this happened, but I'm sure that someone pulling
>> out a
>> Beretta was involved.

Judging from this sentence, I bet Aaron wouldn't mind someone taking
over rkelly.
Tony A. (Guest)
on 2009-06-10 03:07
(Received via mailing list)
On Tue, Jun 9, 2009 at 12:54 PM, Eric H. <removed_email_address@domain.invalid>
wrote:

> I think you missed the first line:
>
>  I have no idea how this happened, but I'm sure that someone pulling out a
>>> Beretta was involved.
>>>
>>
> Judging from this sentence, I bet Aaron wouldn't mind someone taking over
> rkelly.
>

Heh, guess you're not an R Kelly fan...

I pull out my Beretta
He walks up to the closet
He comes up to the closet
Now he's at the closet
Now he's opening the closet
Ryan D. (Guest)
on 2009-06-10 03:27
(Received via mailing list)
On Jun 9, 2009, at 16:06 , Tony A. wrote:

>> Judging from this sentence, I bet Aaron wouldn't mind someone
>> taking over
>> rkelly.
>>
>
> Heh, guess you're not an R Kelly fan...

We sit next to and code with aaron every day... Fan or not, we bet
Aaron would'nt mind someone taking over the project.
Eleanor McHugh (Guest)
on 2009-06-10 04:05
(Received via mailing list)
On 10 Jun 2009, at 00:06, Tony A. wrote:
>> Judging from this sentence, I bet Aaron wouldn't mind someone
> Now he's opening the closet
And now that South Park episode finally makes sense...


Ellie

Eleanor McHugh
Games With Brains
http://slides.games-with-brains.net
----
raise ArgumentError unless @reality.responds_to? :reason
Tony A. (Guest)
on 2009-06-10 05:18
(Received via mailing list)
On Tue, Jun 9, 2009 at 5:26 PM, Ryan D. <removed_email_address@domain.invalid>
wrote:

> We sit next to and code with aaron every day... Fan or not, we bet Aaron
> would'nt mind someone taking over the project.
>

Well, through a roundabout manner I have come upon yet another of
tenderlove's projects, Johnson, which seems intended as an RKelly
replacement and is better suited for our needs anyway.

I forsee transitioning what I wrote with RKelly to Johnson shortly and
begin
writing tests which actually execute the JavaScripts we're compiling.
This topic is locked and can not be replied to.