The Artima Developer Community
Sponsored Link

Ruby Buzz Forum
Why you should switch to 1.9: Three Ruby 1.8 bugs

0 replies.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a flat view of this topic  Flat View
Previous Topic   Next Topic
Threaded View: This topic has 0 replies on 1 page
Jan Lelis

Posts: 136
Nickname: rbjl
Registered: Aug, 2009

Jan Lelis is an IT student from Dresden/Germany
Why you should switch to 1.9: Three Ruby 1.8 bugs Posted: Dec 3, 2011 10:16 PM
Reply to this message Reply

This post originated from an RSS feed registered with Ruby Buzz by Jan Lelis.
Original Post: Why you should switch to 1.9: Three Ruby 1.8 bugs
Feed Title: rbJ*_*L.net
Feed URL: http://feeds.feedburner.com/rbJL
Feed Description: Hi, I am a fan of Ruby and like to explore it and the world around ;). So I started this blog, where I am publishing code snippets, tutorials for beginners as well as general thoughts about Ruby, the web or programming in general.
Latest Ruby Buzz Posts
Latest Ruby Buzz Posts by Jan Lelis
Latest Posts From rbJ*_*L.net

Ruby 1.8 dies in June 2012. This post shows some small examples, why this is good ;)

Version used for testing: ruby-1.8.7-p352. Everything works well in 1.9.

Bug: Inconsistent Float representation

>> a=1215449.9999999993
=> 1215450.0 
>> puts "a as Float:   #{a}\na as Integer: #{a.to_i}"
a as Float:   1215450.0
a as Integer: 1215449

Bug: Encoding issues

>> a = "text with ─ unicode"
=> "text with ─ unicode"
>> a.tr "─", '-'
=> "text with --- unicode"

Bug: RUBY_ENGINE is not defined

Not really a bug, but still pretty annoying. You always have to check if the constants exists before using it.

CC-BY (DE)

Read: Why you should switch to 1.9: Three Ruby 1.8 bugs


Topic: Why you should switch to 1.9: Three Ruby 1.8 bugs Previous Topic   Next Topic Topic: PaperTrail + Sinatra strangeness

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use