Talk:Ruby (programming language)

From Wikipedia, the free encyclopedia
Jump to: navigation, search
WikiProject Free Software / Software / Computing  (Rated B-class, High-importance)
WikiProject icon This article is within the scope of WikiProject Free Software, a collaborative effort to improve the coverage of free software on Wikipedia. If you would like to participate, please visit the project page, where you can join the discussion and see a list of open tasks.
B-Class article B  This article has been rated as B-Class on the project's quality scale.
 High  This article has been rated as High-importance on the project's importance scale.
Taskforce icon
This article is supported by WikiProject Software.
Taskforce icon
This article is supported by WikiProject Computing (marked as Mid-importance).
 

Stuff removed from Boolean data type article[edit]

The following section was removed from the article Boolean data type:
begin removed text



The Ruby programming language does not have a Boolean data type as part of the language. Like many other interpreted languages, all variables are dynamically typed. Instead, ruby defines the explicit values of false and nil, and everything else is considered true, including 0, [ ], and the empty string "". The values true, false, and nil can be assigned to variables, returned from functions or methods, and compared in Boolean expressions.

a = 0
if a
  puts "true"
else
  puts "false"
end

will print "true", which might come as a surprise to a new user of the language.

Since Ruby is a pure object-oriented programming language, even the "explicitly" defined values of true, false and nil are objects that each have their own class:

p false.class
p true.class
p nil.class

Would output "FalseClass", "TrueClass" and "NilClass" respectively.



end removed text
Is there a place for this text in the Ruby-related articles? Perhaps in the Wikibook? Thanks, and all the best, --Jorge Stolfi (talk) 00:05, 31 December 2009 (UTC)

Archiving[edit]

Does anyone object to me setting up automatic archiving for this page using MiszaBot? Unless otherwise agreed, I would set it to archive threads that have been inactive for 60 days.--Oneiros (talk) 14:51, 5 January 2010 (UTC)

Yes check.svg Done--Oneiros (talk) 20:46, 16 January 2010 (UTC)

Magic Global[edit]

Alternatively, the most recent exception is stored in the magic global $!.

Is $! really considered a magic global? It feels like an unnecessary adjective. Simply stating "the global $!" seems adequate.

Adamstegman (talk) 15:21, 22 February 2010 (UTC)

All variables that start with a $ are "global variables.2 I do not know who came up with the word "magic global", I think it is a misnomer. Nothing in the source of ruby refers to anything as a "magic global". However, not all global variables are the same in ruby. $1 $2 etc... are somewhat special and volatile, used for regexes. They may tend to "disappear" more rapidly than other variables, when you use a new =~ regex check. 193.83.131.214 (talk) 11:21, 6 February 2013 (UTC)

[edit]

The ruby site uses the same logo as on this page, which is the one everybody knows. However, one of the news pages on the official site appears to indicate that the official logo is the one that the Ruby Association hosts on their site at http://www.ruby-assn.org/en/logo.htm

Could somebody please check with Matz to see if that is really more official than his own logo (the one currently shown on the page)? —Preceding unsigned comment added by 66.254.237.152 (talk) 06:23, 23 April 2010 (UTC)

Initial purpose?[edit]

Did it have an initial purpose except "promoting fun and productivity" (which is pretty much "good and good")? Rursus dixit. (mbork3!) 08:50, 30 September 2010 (UTC)

Yes. Matz liked perl, but he felt he could do it better. So he wrote ruby, for his own use (more or less). 193.83.131.214 (talk) 11:19, 6 February 2013 (UTC)

Implementations of Ruby 1.9[edit]

The section start off with ...



The newest version of Ruby, the recently released version 1.9, has a single working implementation written in C that utilizes a Ruby-specific virtual machine.



... however, JRuby currently provides a 1.9.2 compliant VM as evidenced on the JRuby page. 122.170.48.143 (talk) 07:25, 10 June 2011 (UTC)

Strong typing[edit]

Hello, why was "Strong Typing" removed from the list of typing disciplines? --Cokaban (talk) 10:28, 26 November 2011 (UTC)

'Repositories and Libraries' not up to date[edit]

The data mentioned is outdated and the predominant role of RubyGems not adequately described. 95.208.117.113 (talk) 10:12, 21 October 2012 (UTC)

mruby[edit]

matz is working on mruby, a light variant of ruby, a bit similar to lua. Should the main article mention mruby eventually? The link to the github page is at: https://github.com/mruby/mruby I suppose one day mruby may be ready, and then the main article could have a small subsection about mruby. 193.83.131.214 (talk) 11:23, 6 February 2013 (UTC)

Is Ruby a "C family" programming language?[edit]

Please see Wikipedia:Categories_for_discussion/Log/2014_October_24#Category_talk:C_programming_language_family. Andy Dingley (talk) 12:20, 24 October 2014 (UTC)