Re: [MacRuby-devel] MacRuby classes delete/overwrite Objective-C classes?

2011-02-11 Thread Caio Chassot
On 2011-02-12, at 01:59 , Robert Payne wrote: > > The behavior I'm expecting is to see "Hello world" in the console but it > seems as if the entire Objective-C method was deleted. I don't have a method > in the Ruby class called helloWorld. There's likely something wrong somewhere else in your

Re: [MacRuby-devel] MacRuby classes delete/overwrite Objective-C classes?

2011-02-11 Thread Robert Payne
Hey Guys, I'm a bit unclear on this situation then.. If you create an Objective-C class "MyController" with methods and then a Ruby class "MyController" the class should combine all the methods between both correct? For instance: Objective-C Class: #import "MyController.h" @implementation M

Re: [MacRuby-devel] MacRuby classes delete/overwrite Objective-C classes?

2011-02-11 Thread Matt Aimonetti
Mark, your answer was great, I just wanted to make sure people reading the thread in the future get a simple answer. You did a great job explaining why the answer was no and I'm sure it will be valuable to many. - Matt On Fri, Feb 11, 2011 at 5:35 PM, Mark Rada wrote: > One day I'll get this qu

Re: [MacRuby-devel] MacRuby classes delete/overwrite Objective-C classes?

2011-02-11 Thread Mark Rada
One day I'll get this question answering thing done correctly. Sent from my iDevice On 2011-02-11, at 20:05, Matt Aimonetti wrote: > Do MacRuby classes completely overwrite Objective-C classes if you load one > in with the same class name? > > Just to be clear, the answer is no ;) > > - Mat

Re: [MacRuby-devel] MacRuby classes delete/overwrite Objective-C classes?

2011-02-11 Thread Matt Aimonetti
Do MacRuby classes completely overwrite Objective-C classes if you load one in with the same class name? Just to be clear, the answer is no ;) - Matt Sent from my iPhone On Feb 11, 2011, at 17:00, Mark Rada wrote: > Hi Robert, > > Classes in ruby are open, which means that if you define it

Re: [MacRuby-devel] MacRuby classes delete/overwrite Objective-C classes?

2011-02-11 Thread Mark Rada
Hi Robert, Classes in ruby are open, which means that if you define it in multiple places, you get one class with things from all the definitions definitions. However, if you define the same methods, then which ever method you define last is the one that will exist. There are also techniques fo

Re: [MacRuby-devel] Core Data / MacRuby article

2011-02-11 Thread Joshua Ballanco
Great article! Regarding the sqlite store, I think it would be best to keep the default to XML for the template...just to be consistent with Xcode's Obj-C templates. However, it might be nice to add something to the macruby_deploy script to switch this over to SQLite? On Fri, Feb 11, 2011 at 1:47

[MacRuby-devel] MacRuby classes delete/overwrite Objective-C classes?

2011-02-11 Thread Robert Payne
Hey All, Do MacRuby classes completely overwrite Objective-C classes if you load one in with the same class name? I'm just testing the best way to communicate to a MacRuby class from an Objective-C class and wanted to make sure. Robert Payne Interactive Developer ___

Re: [MacRuby-devel] Issue with running unit tests when requiring rubygems

2011-02-11 Thread Gabriel Ayuso
I did a little more testing and I found out that the problem is apparently by how Mocha changes Test::Unit::TestUnit. The only way I was able to make it work was the following: require 'rubygems' gem 'mocha' require 'mocha' require 'test/unit' class QuickTest < Test::Unit::TestCase

Re: [MacRuby-devel] book idea - "making it look like Ruby"

2011-02-11 Thread Jordan K. Hubbard
On Feb 11, 2011, at 2:08 PM, Rich Morin wrote: > The question of documentation is also somewhat iffy. > There is already a difference in appearance between > the ObjC and MacRuby calling syntaxes. Would merely > allowing (ie, not requiring) the use of snake_case > make this much problem much wor

Re: [MacRuby-devel] book idea - "making it look like Ruby"

2011-02-11 Thread Rich Morin
At 6:09 PM -0200 2/11/11, Caio Chassot wrote: > On 2011-02-11, at 15:25 , Matt Aimonetti wrote: >> >> Magically converting a snake_case method call to a >> CamelCase method dispatch is bad for peformance >> and documentation. It's not clear to me that there would be a significant performance impac

Re: [MacRuby-devel] book idea - "making it look like Ruby"

2011-02-11 Thread Caio Chassot
On 2011-02-11, at 15:25 , Matt Aimonetti wrote: > > Magically converting a snake_case method call to a CamelCase method dispatch > is bad for peformance and documentation. I'm not suggesting that this be done as part of MacRuby, but should one want to go ahead on their on… Wouldn't it be possib

Re: [MacRuby-devel] book idea - "making it look like Ruby"

2011-02-11 Thread Matt Aimonetti
Magically converting a snake_case method call to a CamelCase method dispatch is bad for peformance and documentation. I believe that Laurent addressed that topic a few times already but I might be wrong. There is currently no plan to support that approach in MacRuby. - Matt On Fri, Feb 4, 2011 at

Re: [MacRuby-devel] Issue with running unit tests when requiring rubygems

2011-02-11 Thread Joshua Ballanco
Considering that the updated minitest library also contains the new benchmarking facilities (though I don't think that part was officially adopted by MRI), it might be worth considering pulling from upstream. On Fri, Feb 11, 2011 at 9:37 AM, Eloy Duran wrote: > This *might* be because the minite

Re: [MacRuby-devel] Issue with running unit tests when requiring rubygems

2011-02-11 Thread Eloy Duran
This *might* be because the minitest version in our stdlib is outdated. You can try to install the minitest gem and require that instead and see if that fixes it. On Fri, Feb 11, 2011 at 3:24 PM, Gabriel Ayuso wrote: > I wanted to try using mocha to write unit tests with mocks. After requiring >

[MacRuby-devel] Issue with running unit tests when requiring rubygems

2011-02-11 Thread Gabriel Ayuso
I wanted to try using mocha to write unit tests with mocks. After requiring "rubygems" a NoMethodError exception was thrown when attempting to run the tests. The method which wasn't found was 'run'. If I remove the call to require "rubygems" my test fails because I can't use mocha but the NoMethod