[MacRuby-devel] [MacRuby] #346: Can't run macirb on Snow Leopard

2009-09-23 Thread MacRuby
#346: Can't run macirb on Snow Leopard
+---
 Reporter:  comec...@…  |   Owner:  lsansone...@…
 Type:  defect  |  Status:  new  
 Priority:  critical|   Milestone:  MacRuby 0.4  
Component:  MacRuby |Keywords:   
+---
 I'm getting this error message running macirb (0.4) on OSX Snow Leopard:

 [bas...@bastos:~/]% macirb
 /Library/Frameworks/MacRuby.framework/Versions/0.4/usr/bin/macruby: [BUG]
 get_dyna_var_idx: -1
 MacRuby version 0.4 (ruby 1.9.1) [universal-darwin9.5, x86_64]

 -- stack frame 
  (0x30260): 0004
 0001 (0x30268): 
 0002 (0x30270): 0004
 0003 (0x30278):  <- lfp <- dfp
 -- control frame --
 c:0002 p:-1073823456 s:0004 b:0004 l:03 d:03 TOP
 c:0001 p: s:0002 b:0002 l:01 d:01 TOP
 ---
 -- backtrace of native function call (Use addr2line) --
 0x10010f301
 0x100029544
 0x100029628
 0x1000e3cee
 0x1000e867b
 0x1000ee668
 0x1000eae10
 0x1000e9685
 0x1000e6b66
 0x1000edcfb
 0x1000f1a25
 0x1000f1a84
 0x1000f1be5
 0x100126cbb
 0x1000bfadb
 0x1000f83df
 0x1000bf250
 0x10002fa65
 0x10f17
 0x10ea4
 0x2
 ---
 [1]45475 abort  macirb
 [bas...@bastos:~/]%

-- 
Ticket URL: 
MacRuby 

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] [MacRuby] #346: Can't run macirb on Snow Leopard

2009-09-23 Thread MacRuby
#346: Can't run macirb on Snow Leopard
+---
 Reporter:  comec...@…  |   Owner:  lsansone...@…
 Type:  defect  |  Status:  new  
 Priority:  critical|   Milestone:  MacRuby 0.4  
Component:  MacRuby |Keywords:   
+---

Comment(by comec...@…):

 It is working well on macruby_nightly-2009-09-22-2000

-- 
Ticket URL: 
MacRuby 

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] [MacRuby] #346: Can't run macirb on Snow Leopard

2009-09-23 Thread MacRuby
#346: Can't run macirb on Snow Leopard
+---
 Reporter:  comec...@…  |   Owner:  lsansone...@…
 Type:  defect  |  Status:  new  
 Priority:  critical|   Milestone:  MacRuby 0.4  
Component:  MacRuby |Keywords:   
+---

Comment(by eloy.de.en...@…):

 0.4 is not supported on Snow Leopard anyways. So use 0.5 trunk, or one of
 the nightly builds.

-- 
Ticket URL: 
MacRuby 

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] [MacRuby] #346: Can't run macirb on Snow Leopard

2009-09-23 Thread MacRuby
#346: Can't run macirb on Snow Leopard
+---
 Reporter:  comec...@…  |Owner:  lsansone...@…
 Type:  defect  |   Status:  closed   
 Priority:  critical|Milestone:  MacRuby 0.4  
Component:  MacRuby |   Resolution:  invalid  
 Keywords:  |  
+---
Changes (by eloy.de.en...@…):

  * status:  new => closed
  * resolution:  => invalid


-- 
Ticket URL: 
MacRuby 

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


[MacRuby-devel] [MacRuby] #347: module in module_function mode can't have methods with default args

2009-09-23 Thread MacRuby
#347: module in module_function mode can't have methods with default args
-+--
 Reporter:  mattaimone...@…  |   Owner:  lsansone...@… 
 Type:  defect   |  Status:  new   
 Priority:  blocker  |   Milestone:  MacRuby 0.5   
Component:  MacRuby  |Keywords:  module_function module
-+--
 {{{
 $ macruby -e "module Foo; module_function; def bar(baz=42); baz; end; end;
 p Foo.bar(2)"
 => -e:1:in `': wrong number of arguments (1 for 0) (ArgumentError)
 }}}


 {{{
 $ macruby -e "module Foo; def bar(baz=42); baz; end; end; include Foo; p
 bar(2)"
 => 2
 }}}

 {{{
 $ ruby19 -e "module Foo; module_function; def bar(baz=42); baz; end; end;
 p Foo.bar(2)"
 => 2
 }}}

-- 
Ticket URL: 
MacRuby 

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


[MacRuby-devel] require failing to find installed gem - from Cocoa app

2009-09-23 Thread Stevenson, Bob
I've installed a gem that I'm trying to use from the latest nightly; but
the embedded macruby runtime; does not find the gem.
Controller.rb:14:in `': no such file to load -- xml-object
(LoadError)
 
What do I need to do so that the embedded macruby can find my installed
gem?
I can perform the require successfully from macirb.  Then gem is
installed off my home directory at: ~/.gem
 
Thanks in advance.
 
___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] macruby nightly build 2009-09-10

2009-09-23 Thread Robert Rice

Hi Laurent:

Thanks for your offer to help. Sorry I was busy with another project  
but now I get back to MacRuby.


I have attached a file that causes the assertion error when loaded by  
the require command. Probably there is something else I need to change  
when porting from Ruby-Cocoa.


Thanks,
Bob Rice
#
#  JBH_F7575101_WindowController.rb
#  Cocoa-Ruby Driver Assistant
#
#  Created by Robert Rice on 9/4/09.
#  Copyright (c) 2009 Rice Audio. All rights reserved.
#

class JBH_F7575101_WindowController < NSWindowController
	
#	require 'TextUtilities'; include TextUtilities
	
	def init
		if super_init
			puts "JBH_F7575101_WindowController"
			initWithWindowNibName( 'JBH_F7575101' )
			end
		
		self
		end
	
	attr_writer :chartView, :remarksIndexView, :weatherView, :f11, :f12, :f13, :f21, :f22, :f23, :f31, :f32, :f33, :f41, :f42, :f43
	
	def Initialize( key, rptdate, historyEvent )
		@key = key
		@rptdate = rptdate
		@historyEvent = historyEvent
		
		@driverRec = historyEvent.driverRec
		@driver = historyEvent.driver
		
		@rules = historyEvent.rules
		@commentlist = historyEvent.commentlist
		puts "commentlist #[email protected]}"

		showWindow_( self )

		@headerFont = NSFont.fontWithName_size_( "Lucida Handwriting", 18 )

		[ @chartView, @remarksIndexView, @weatherView, @f11, @f12, @f13, @f21, @f22, @f23, @f31, @f32, @f33, @f41, @f42, @f43 ].each do | field |
# setNeedsDisplay will cause the field to notify it's closest ancestor clip view to refresh its buffer for the drawing area
			field.setNeedsDisplay_( true ) if field != nil 
			end

		ShowDates()
		ShowTractor()
		ShowMiles()
		ShowDrivers()
		ShowTrailers()
		ShowTotals()
		ShowRemarks()
		ShowAlphaCode()
		ShowReporting()
		ShowTrips()
		ShowHistory()
		end
	
	def Fallback; @date.Fallback; end
	def SpringForward; @date.SpringForward; end
	
	def SetWindow( mywindow ) # Ruby method called from JBH_PrintView
		Model.instance.SetWindow( @key, mywindow )
		mywindow.setTitle_( "Driver #...@driver} on #...@rptdate}" )
		end
	
	def windowWillClose( notification ) # We will get this message as window delegate		
		Model.instance.WindowWillClose( @key )
		self.autorelease
		end
	
	attr_reader :rptdate, :driverRec, :rules, :commentlist

	attr_writer :reportMo, :reportmO, :reportDy, :reportdY, :reportYr, :reportyR	
	attr_writer :reportMov, :reportmOv, :reportDyv, :reportdYv, :reportYrv, :reportyRv
	attr_writer :endMo, :endmO, :endDy, :enddY, :endYr, :endyR

	def ShowDates
		startdate = @rptdate
		
		if @rules.totals.at( 0 ) == 24.0
			tenhour = @rules.tenhour
			while tenhour >= 48.0 # Combine two days off duty
mydate = Time.local( startdate.slice( 0..3 ),  startdate.slice( 4..5 ), startdate.slice( 6..7 ) )
yesterday = ( mydate - 24*60*60 ).strftime( "%Y%m%d" )
break if yesterday.slice( 5..5 ) != startdate.slice( 5..5 ) # cannot span month
startdate = yesterday
tenhour -= 24.0
end
			end
		
	# Space each character to fit in a box on the form
		startdate = startdate.slice( 2..7 )
		MonoSpace( startdate, @headerFont, [ @reportYr, @reportyR, @reportMo, @reportmO, @reportDy, @reportdY ] )
		MonoSpace( startdate, @headerFont, [ @reportYrv, @reportyRv, @reportMov, @reportmOv, @reportDyv, @reportdYv ] )

		enddate = ( startdate == @rptdate ? "  " : @rptdate.slice( 2..7 ) )
		MonoSpace( enddate, @headerFont, [ @endYr, @endyR, @endMo, @endmO, @endDy, @enddY ] )
		end

	attr_writer :tractor, :tRactor, :trActor, :traCtor, :tracTor, :tractOr
	attr_writer :tractorv, :tRactorv, :trActorv, :traCtorv, :tracTorv, :tractOrv
	attr_writer :startHub, :endHub
	
	def ShowTractor	
		starthub = endhub = 0
		
		tractor = @historyEvent.tractor.to_s
		tractor = ( tractor.empty? ? "None  " : tractor.ljust( 6 ) )

		MonoSpace( tractor, @headerFont, [ @tractor, @tRactor, @trActor, @traCtor, @tracTor, @tractOr ] )
		MonoSpace( tractor, @headerFont, [ @tractorv, @tRactorv, @trActorv, @traCtorv, @tracTorv, @tractOrv ] )

		font = NSFont.fontWithName_size_( "Lucida Handwriting", 14 )
		
		@odometerEvents = [ VehicleEvent, StoppedEvent ]
		
		if @startHub != nil # Linked?
			startHub = @historyEvent.startHub
			@startHub.setStringValue_( startHub == 0.0 ? "" : startHub.to_s.rjust( 6, '0' ) )
			@startHub.setFont_( font )
			end
		
		if @endHub != nil
			@endHub.setStringValue_( @historyEvent.endHub.to_s )
			@endHub.setFont_( font )
			end
		end

	attr_writer :driverMiles, :dRiverMiles, :drIverMiles
	def ShowMiles
		dvrMiles = @historyEvent.dvrMiles
		drivermiles = ( dvrMiles == nil ? "   " : dvrMiles.round.to_s.rjust( 3, '0' ) )
		MonoSpace( drivermiles, @headerFont, [ @driverMiles, @dRiverMiles, @drIverMiles ] )
		end
	
	attr_writer :driverNumber, :dRiverNumber, :drIverNumber, :driVerNumber, :drivErNumber
	attr_writer :codriver, :cOdriver, :coDriver, :codRiver, :codrIver
	attr_writer :driverName, :timeZone

	def ShowDrivers
		@driver = "?" if @driver == nil
		MonoSpace( @driver, @headerFont, [ @driverNumber, @dRiverNumber, @drIverNumber, @driVerNumber

Re: [MacRuby-devel] macruby nightly build 2009-09-10

2009-09-23 Thread Laurent Sansonetti

Hi Robert,

The problem is line 68, the call to autorelease. If you remove it it  
should load again. The reason is that autorelease (like release and  
retain) are ignored selectors of the runtime. Clearly we should not  
crash this way, I will fix that.


Also, keep in mind that retain, release and autorelease should not be  
used in MacRuby. We run under GC mode which makes these calls no-ops.


Laurent

On Sep 23, 2009, at 12:18 PM, Robert Rice wrote:


Hi Laurent:

Thanks for your offer to help. Sorry I was busy with another project  
but now I get back to MacRuby.


I have attached a file that causes the assertion error when loaded  
by the require command. Probably there is something else I need to  
change when porting from Ruby-Cocoa.


Thanks,
Bob Rice


On Sep 12, 2009, at 3:08 PM, Laurent Sansonetti wrote:


Hi Robert,

Unless you found what was wrong, feel free to contact me off-list  
with a copy of your app and I will investigate the problem.


Laurent

On Sep 12, 2009, at 9:48 AM, Robert Rice wrote:


Hi Laurent:

It's a relatively large application that I ported from a RubyCocoa  
environment.
I need the threading support hook that was removed from Ruby in  
the Snow Leopard release.


I'll try to track it down better by porting and testing modules a  
little at a time.


Thanks,
Bob Rice

On Sep 11, 2009, at 12:53 PM, Laurent Sansonetti wrote:

Looks like we are hitting an assertion in the symbol generator...  
Could you send us what you are trying to execute here?


Laurent

Sent from my iPhone

On Sep 11, 2009, at 9:48 AM, Robert Rice   
wrote:



How would I track down the following error from the nightly build?

[Session started at 2009-09-11 12:43:22 -0400.]
GNU gdb 6.3.50-20050815 (Apple version gdb-1344) (Fri Jul  3  
01:19:56 UTC 2009)

Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License,  
and you are
welcome to change it and/or distribute copies of it under  
certain conditions.

Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty"  
for details.

This GDB was configured as "x86_64-apple-darwin".tty /dev/ttys000
Loading program into debugger…
Program loaded.
run
[Switching to process 326]
Running…
Assertion failed: (1==0), function rb_intern3, file parse.y,  
line 9596.

Program received signal:  “SIGABRT”.
sharedlibrary apply-load-rules all
warning: Could not find object file "/Users/mattetti/src/macruby- 
gitsvn/trunk/array.o" - no debug information available for  
"array.c".


warning: Could not find object file "/Users/mattetti/src/macruby- 
gitsvn/trunk/bignum.o" - no debug information available for  
"bignum.c".


...
Thanks,
Bob Rice

On Sep 10, 2009, at 2:24 PM, Matt Aimonetti wrote:

Latest trunk code available as an unofficial pkg ready to  
install: http://rubyurl.com/5K3W


Lots of bug fixes, improved macgem (not finished yet but you  
can install gems and load them using `gem 'gem_name'; require  
'whatever'`).

Things are looking pretty good on trunk :)

- Matt
___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel



___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] [MacRuby] #347: module in module_function mode can't have methods with default args

2009-09-23 Thread MacRuby
#347: module in module_function mode can't have methods with default args
-+--
 Reporter:  mattaimone...@…  |   Owner:  lsansone...@… 
 Type:  defect   |  Status:  new   
 Priority:  blocker  |   Milestone:  MacRuby 0.5   
Component:  MacRuby  |Keywords:  module_function module
-+--

Comment(by oc...@…):

 FYI, this bug looks a lot like ticket #326.  For example,  contrary to the
 reported example, the following explicit module_function declaration works
 (even though the rolling declaration style "module_function;" does not
 work).

 macruby -e "module Foo; def bar(baz=42); baz;  end; module_function :bar;
 end; p Foo.bar(2)" => 2

 FYI, so if you need (or want) a workaround, explicitly declare the
 "module_function :bar", and it should work (until rolling declarations are
 working as well).

-- 
Ticket URL: 
MacRuby 

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] macruby nightly build 2009-09-10

2009-09-23 Thread Robert Rice

Hi Laurent:

Thanks for your quick reply. I have attached another file that causes  
a similar crash without a call to autorelease.


Bob Rice
#
#  OutlineRowNode.rb
#  Cocoa-Ruby Driver Assistant
#
#  Created by Robert Rice on 9/4/09.
#  Copyright (c) 2009 Rice Audio. All rights reserved.
#

require 'ReadLogNew'

class OutlineRowNode

	include FileSystemFunctions

	Months = [ "January", "Feburary", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December" ]
	
	def init
#		super
		
		@initialized = false
		@path = ""
		@object = nil
		@level = 0
		@dirname = ""
		@filename = ""
		@columnValues = Array.new
		@columnColors = Array.new
		@children = NSMutableArray.alloc.init
		@parent = nil
	
		self
		end
	
	attr_accessor :path, :dirname, :filename
	attr_writer :columnValues, :columnColors, :level, :parent, :object
	attr_reader :children
	
	def count; @children.count; end
	def value; @dirname + @filename; end
	
	def Populate
		NSLog( "numberOfChildrenOfItem #...@path} #...@dirname}" )

#		if not @initialized			
			case @level
when 0; GetDirs() # Year
when 1; GetDirs() # Month
when 2; GetFiles() # Days
when 3; GetEvents()
end
			@initialized = true
#			end
		
		@children.count
		end
	
	def GetColumnObject( tableColumn )
		return nil if @object == nil
		
		column = tableColumn.identifier.to_i - 1
		column = 0 if column < 0
		@object.at( column )
		end
	
	def Expandable
#		NSLog( "isItemExpandable #...@path} #...@dirname}" )
		@level < 4
		end

	def ToolTip( tableColumn )
		column = tableColumn.identifier.to_i
		NSLog( "toolTipForCell_rect_tableColumn_item_mouseLocation #...@path}, #{column}" )
		obj = self.GetColumnObject( tableColumn )
		return "" if obj == nil
		
		obj.ToolTip( column )
		end
	
	def ColumnColor( tableColumn )
		column = tableColumn.identifier.to_i
		if @columnColors == false
			obj = self.GetColumnObject( tableColumn )
			return "" if obj == nil
			return obj.TableColor( column )
			end
		
		@columnColors.at( column )
		end
	
	def childAtIndex( index )
#		NSLog( "child_ofItem #{index}, #...@path} #...@dirname}" )
		@children.objectAtIndex( index )
		end
	
	def WillDisplayCell( cell, tableColumn )
		column = tableColumn.identifier.to_i
#		NSLog( "willDisplayCell_forTableColumn_item #...@path}, #{column}" )
		if cell.font != "Times"
			font = NSFont.fontWithName_size_( "Times", 14.0 )
			cell.setFont_( font )

			color = ColumnColor( tableColumn )
			color = NSColor.blackColor if color == nil
			cell.setTextColor_( color )
			end
		
		cell.setMenu_( nil ) # Clear previous menu

		return if column < 2 or @parent == nil
		
		obj = self.GetColumnObject( tableColumn )
		if obj != nil
			menu = obj.ContextMenu( @parent, column )
			cell.setMenu_( menu ) if menu != nil # Set menu for this cell
			end
		end
	
	def ColumnValue( tableColumn )
		column = tableColumn.identifier.to_i
#		NSLog( "objectValueForTableColumn_byItem #...@path} #...@dirname} column #{column}" )

		if @columnValues == false
			obj = self.GetColumnObject( tableColumn )
			return "" if obj == nil
			return obj.TableValue( column )
			end
		
		@columnValues.at( column )
		end
	
	def GetDirs
		path = ( @level == 0 ? @path : "#...@path}/#...@dirname}" )
		dirlist = GetDirectories( path )
		NSLog( dirlist.inspect )
		return if count() == dirlist.length
		
		@children.removeAllObjects
		dirlist.each do | dirname |
			grp = OutlineRowNode.alloc.init
			grp.path = path
			grp.dirname = dirname
			grp.columnValues = [ @level == 1 ? Months.at( dirname.to_i - 1 ) : dirname ]
			grp.columnColors = [ NSColor.darkGrayColor ]
			grp.parent = self
			grp.level = @level + 1
			@children.addObject( grp )
			end
		end
	
	def GetFiles
		path = "#...@path}/#...@dirname}"
		
		filelist = Array.new
		GetDataFiles( path ).each do | filename |
			filelist << filename if filename.length == 8
			end
		return if count() == filelist.length
		
		@children.removeAllObjects
		filelist.each do | filename |
			grp = OutlineRowNode.alloc.init
			grp.path = path
			grp.filename = filename
			grp.columnValues = [ filename ]
			grp.columnColors = [ ]
			grp.parent = self
			grp.level = @level + 1
			@children.addObject( grp )
			end
		end
	
	def ReloadTable
		NSLog( "ReloadTable #{value()}" )
		@initialized = false
		Model.instance.outlineView.reloadItem_reloadChildren_( self, true ) # Refresh the table
		end

	def GetEvents
		date = ModelDate.alloc.InitWithString( @filename, false )
		date.setToUTC
		
		driverList = Model.instance.DriverList # Not fully initialized first pass
		
		# Build table of events
		eventTable = Array.new
		tableRow = Array.new
		tableTime = "25:00:00"
		
		eventList = Model.instance.EventTable( date )
		eventList.each do | event |
			case event.class.to_s
			
when "StartOfDay"; displayColumn = -1 # not displayed

when "HistoryEvent"
displayColumn = -1 # not displayed
event.parentItem = self

when "StopEvent", "DriveEvent", "TripEvent", "VehicleEvent", "Dri

Re: [MacRuby-devel] macruby nightly build 2009-09-10

2009-09-23 Thread Conrad Taylor
Hi, is this the complete application?  If not, could you generate subset of
your application that can be ran which produces the error message?
-Conrad

On Wed, Sep 23, 2009 at 2:46 PM, Robert Rice  wrote:

> Hi Laurent:
>
> Thanks for your quick reply. I have attached another file that causes a
> similar crash without a call to autorelease.
>
> Bob Rice
>
>
>
>
> On Sep 23, 2009, at 3:24 PM, Laurent Sansonetti wrote:
>
>  Hi Robert,
>>
>> The problem is line 68, the call to autorelease. If you remove it it
>> should load again. The reason is that autorelease (like release and retain)
>> are ignored selectors of the runtime. Clearly we should not crash this way,
>> I will fix that.
>>
>> Also, keep in mind that retain, release and autorelease should not be used
>> in MacRuby. We run under GC mode which makes these calls no-ops.
>>
>> Laurent
>>
>> On Sep 23, 2009, at 12:18 PM, Robert Rice wrote:
>>
>>  Hi Laurent:
>>>
>>> Thanks for your offer to help. Sorry I was busy with another project but
>>> now I get back to MacRuby.
>>>
>>> I have attached a file that causes the assertion error when loaded by the
>>> require command. Probably there is something else I need to change when
>>> porting from Ruby-Cocoa.
>>>
>>> Thanks,
>>> Bob Rice
>>> 
>>>
>>> On Sep 12, 2009, at 3:08 PM, Laurent Sansonetti wrote:
>>>
>>>  Hi Robert,

 Unless you found what was wrong, feel free to contact me off-list with a
 copy of your app and I will investigate the problem.

 Laurent

 On Sep 12, 2009, at 9:48 AM, Robert Rice wrote:

  Hi Laurent:
>
> It's a relatively large application that I ported from a RubyCocoa
> environment.
> I need the threading support hook that was removed from Ruby in the
> Snow Leopard release.
>
> I'll try to track it down better by porting and testing modules a
> little at a time.
>
> Thanks,
> Bob Rice
>
> On Sep 11, 2009, at 12:53 PM, Laurent Sansonetti wrote:
>
>  Looks like we are hitting an assertion in the symbol generator...
>> Could you send us what you are trying to execute here?
>>
>> Laurent
>>
>> Sent from my iPhone
>>
>> On Sep 11, 2009, at 9:48 AM, Robert Rice 
>> wrote:
>>
>>  How would I track down the following error from the nightly build?
>>>
>>> [Session started at 2009-09-11 12:43:22 -0400.]
>>> GNU gdb 6.3.50-20050815 (Apple version gdb-1344) (Fri Jul  3 01:19:56
>>> UTC 2009)
>>> Copyright 2004 Free Software Foundation, Inc.
>>> GDB is free software, covered by the GNU General Public License, and
>>> you are
>>> welcome to change it and/or distribute copies of it under certain
>>> conditions.
>>> Type "show copying" to see the conditions.
>>> There is absolutely no warranty for GDB.  Type "show warranty" for
>>> details.
>>> This GDB was configured as "x86_64-apple-darwin".tty /dev/ttys000
>>> Loading program into debugger…
>>> Program loaded.
>>> run
>>> [Switching to process 326]
>>> Running…
>>> Assertion failed: (1==0), function rb_intern3, file parse.y, line
>>> 9596.
>>> Program received signal:  “SIGABRT”.
>>> sharedlibrary apply-load-rules all
>>> warning: Could not find object file
>>> "/Users/mattetti/src/macruby-gitsvn/trunk/array.o" - no debug 
>>> information
>>> available for "array.c".
>>>
>>> warning: Could not find object file
>>> "/Users/mattetti/src/macruby-gitsvn/trunk/bignum.o" - no debug 
>>> information
>>> available for "bignum.c".
>>>
>>> ...
>>> Thanks,
>>> Bob Rice
>>>
>>> On Sep 10, 2009, at 2:24 PM, Matt Aimonetti wrote:
>>>
>>>  Latest trunk code available as an unofficial pkg ready to install:
 http://rubyurl.com/5K3W

 Lots of bug fixes, improved macgem (not finished yet but you can
 install gems and load them using `gem 'gem_name'; require 'whatever'`).
 Things are looking pretty good on trunk :)

 - Matt
 ___
 MacRuby-devel mailing list
 [email protected]
 http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel

>>>
>>> ___
>>> MacRuby-devel mailing list
>>> [email protected]
>>> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
>>>
>> ___
>> MacRuby-devel mailing list
>> [email protected]
>> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
>>
>
> ___
> MacRuby-devel mailing list
> [email protected]
> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
>

 ___
>>>

Re: [MacRuby-devel] macruby nightly build 2009-09-10

2009-09-23 Thread Laurent Sansonetti

Hi Robert,

The problem here is dealloc. Same reason, dealloc is ignored by the  
runtime, and you should not use it in MacRuby, it will never be called.


I just fixed macruby to not crash in case autorelease or dealloc is  
used, but keep in mind that using these selectors won't do anything.


Laurent

On Sep 23, 2009, at 2:46 PM, Robert Rice wrote:


Hi Laurent:

Thanks for your quick reply. I have attached another file that  
causes a similar crash without a call to autorelease.


Bob Rice



On Sep 23, 2009, at 3:24 PM, Laurent Sansonetti wrote:


Hi Robert,

The problem is line 68, the call to autorelease. If you remove it  
it should load again. The reason is that autorelease (like release  
and retain) are ignored selectors of the runtime. Clearly we should  
not crash this way, I will fix that.


Also, keep in mind that retain, release and autorelease should not  
be used in MacRuby. We run under GC mode which makes these calls no- 
ops.


Laurent

On Sep 23, 2009, at 12:18 PM, Robert Rice wrote:


Hi Laurent:

Thanks for your offer to help. Sorry I was busy with another  
project but now I get back to MacRuby.


I have attached a file that causes the assertion error when loaded  
by the require command. Probably there is something else I need to  
change when porting from Ruby-Cocoa.


Thanks,
Bob Rice


On Sep 12, 2009, at 3:08 PM, Laurent Sansonetti wrote:


Hi Robert,

Unless you found what was wrong, feel free to contact me off-list  
with a copy of your app and I will investigate the problem.


Laurent

On Sep 12, 2009, at 9:48 AM, Robert Rice wrote:


Hi Laurent:

It's a relatively large application that I ported from a  
RubyCocoa environment.
I need the threading support hook that was removed from Ruby in  
the Snow Leopard release.


I'll try to track it down better by porting and testing modules  
a little at a time.


Thanks,
Bob Rice

On Sep 11, 2009, at 12:53 PM, Laurent Sansonetti wrote:

Looks like we are hitting an assertion in the symbol  
generator... Could you send us what you are trying to execute  
here?


Laurent

Sent from my iPhone

On Sep 11, 2009, at 9:48 AM, Robert Rice   
wrote:


How would I track down the following error from the nightly  
build?


[Session started at 2009-09-11 12:43:22 -0400.]
GNU gdb 6.3.50-20050815 (Apple version gdb-1344) (Fri Jul  3  
01:19:56 UTC 2009)

Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public  
License, and you are
welcome to change it and/or distribute copies of it under  
certain conditions.

Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty"  
for details.
This GDB was configured as "x86_64-apple-darwin".tty /dev/ 
ttys000

Loading program into debugger…
Program loaded.
run
[Switching to process 326]
Running…
Assertion failed: (1==0), function rb_intern3, file parse.y,  
line 9596.

Program received signal:  “SIGABRT”.
sharedlibrary apply-load-rules all
warning: Could not find object file "/Users/mattetti/src/ 
macruby-gitsvn/trunk/array.o" - no debug information available  
for "array.c".


warning: Could not find object file "/Users/mattetti/src/ 
macruby-gitsvn/trunk/bignum.o" - no debug information  
available for "bignum.c".


...
Thanks,
Bob Rice

On Sep 10, 2009, at 2:24 PM, Matt Aimonetti wrote:

Latest trunk code available as an unofficial pkg ready to  
install: http://rubyurl.com/5K3W


Lots of bug fixes, improved macgem (not finished yet but you  
can install gems and load them using `gem 'gem_name'; require  
'whatever'`).

Things are looking pretty good on trunk :)

- Matt
___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel



___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel



___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/

Re: [MacRuby-devel] macruby nightly build 2009-09-10

2009-09-23 Thread Conrad Taylor
Laurent, I understand that one should use the GC for MacRuby but why do we
have such a restriction?  Just curious about the history here.
Thanks in advance,

-Conrad

On Wed, Sep 23, 2009 at 3:49 PM, Laurent Sansonetti
wrote:

> Hi Robert,
>
> The problem here is dealloc. Same reason, dealloc is ignored by the
> runtime, and you should not use it in MacRuby, it will never be called.
>
> I just fixed macruby to not crash in case autorelease or dealloc is used,
> but keep in mind that using these selectors won't do anything.
>
> Laurent
>
>
> On Sep 23, 2009, at 2:46 PM, Robert Rice wrote:
>
>  Hi Laurent:
>>
>> Thanks for your quick reply. I have attached another file that causes a
>> similar crash without a call to autorelease.
>>
>> Bob Rice
>> 
>>
>>
>> On Sep 23, 2009, at 3:24 PM, Laurent Sansonetti wrote:
>>
>>  Hi Robert,
>>>
>>> The problem is line 68, the call to autorelease. If you remove it it
>>> should load again. The reason is that autorelease (like release and retain)
>>> are ignored selectors of the runtime. Clearly we should not crash this way,
>>> I will fix that.
>>>
>>> Also, keep in mind that retain, release and autorelease should not be
>>> used in MacRuby. We run under GC mode which makes these calls no-ops.
>>>
>>> Laurent
>>>
>>> On Sep 23, 2009, at 12:18 PM, Robert Rice wrote:
>>>
>>>  Hi Laurent:

 Thanks for your offer to help. Sorry I was busy with another project but
 now I get back to MacRuby.

 I have attached a file that causes the assertion error when loaded by
 the require command. Probably there is something else I need to change when
 porting from Ruby-Cocoa.

 Thanks,
 Bob Rice
 

 On Sep 12, 2009, at 3:08 PM, Laurent Sansonetti wrote:

  Hi Robert,
>
> Unless you found what was wrong, feel free to contact me off-list with
> a copy of your app and I will investigate the problem.
>
> Laurent
>
> On Sep 12, 2009, at 9:48 AM, Robert Rice wrote:
>
>  Hi Laurent:
>>
>> It's a relatively large application that I ported from a RubyCocoa
>> environment.
>> I need the threading support hook that was removed from Ruby in the
>> Snow Leopard release.
>>
>> I'll try to track it down better by porting and testing modules a
>> little at a time.
>>
>> Thanks,
>> Bob Rice
>>
>> On Sep 11, 2009, at 12:53 PM, Laurent Sansonetti wrote:
>>
>>  Looks like we are hitting an assertion in the symbol generator...
>>> Could you send us what you are trying to execute here?
>>>
>>> Laurent
>>>
>>> Sent from my iPhone
>>>
>>> On Sep 11, 2009, at 9:48 AM, Robert Rice 
>>> wrote:
>>>
>>>  How would I track down the following error from the nightly build?

 [Session started at 2009-09-11 12:43:22 -0400.]
 GNU gdb 6.3.50-20050815 (Apple version gdb-1344) (Fri Jul  3
 01:19:56 UTC 2009)
 Copyright 2004 Free Software Foundation, Inc.
 GDB is free software, covered by the GNU General Public License, and
 you are
 welcome to change it and/or distribute copies of it under certain
 conditions.
 Type "show copying" to see the conditions.
 There is absolutely no warranty for GDB.  Type "show warranty" for
 details.
 This GDB was configured as "x86_64-apple-darwin".tty /dev/ttys000
 Loading program into debugger…
 Program loaded.
 run
 [Switching to process 326]
 Running…
 Assertion failed: (1==0), function rb_intern3, file parse.y, line
 9596.
 Program received signal:  “SIGABRT”.
 sharedlibrary apply-load-rules all
 warning: Could not find object file
 "/Users/mattetti/src/macruby-gitsvn/trunk/array.o" - no debug 
 information
 available for "array.c".

 warning: Could not find object file
 "/Users/mattetti/src/macruby-gitsvn/trunk/bignum.o" - no debug 
 information
 available for "bignum.c".

 ...
 Thanks,
 Bob Rice

 On Sep 10, 2009, at 2:24 PM, Matt Aimonetti wrote:

  Latest trunk code available as an unofficial pkg ready to install:
> http://rubyurl.com/5K3W
>
> Lots of bug fixes, improved macgem (not finished yet but you can
> install gems and load them using `gem 'gem_name'; require 
> 'whatever'`).
> Things are looking pretty good on trunk :)
>
> - Matt
> ___
> MacRuby-devel mailing list
> [email protected]
> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
>

 ___
 MacRuby-devel mailing list
 [email protected]
 http://lists.maco

Re: [MacRuby-devel] macruby nightly build 2009-09-10

2009-09-23 Thread Laurent Sansonetti

Hi Conrad,

The thing is, MacRuby is built on top of the ObjC GC, so there is  
currently no way you can not use it :)


In the future we might introduce a mode where MacRuby doesn't use this  
GC, but it's all tentative.


Laurent

On Sep 23, 2009, at 3:58 PM, Conrad Taylor wrote:

Laurent, I understand that one should use the GC for MacRuby but why  
do we have such a restriction?  Just curious about the history here.


Thanks in advance,

-Conrad

On Wed, Sep 23, 2009 at 3:49 PM, Laurent Sansonetti > wrote:

Hi Robert,

The problem here is dealloc. Same reason, dealloc is ignored by the  
runtime, and you should not use it in MacRuby, it will never be  
called.


I just fixed macruby to not crash in case autorelease or dealloc is  
used, but keep in mind that using these selectors won't do anything.


Laurent


On Sep 23, 2009, at 2:46 PM, Robert Rice wrote:

Hi Laurent:

Thanks for your quick reply. I have attached another file that  
causes a similar crash without a call to autorelease.


Bob Rice




On Sep 23, 2009, at 3:24 PM, Laurent Sansonetti wrote:

Hi Robert,

The problem is line 68, the call to autorelease. If you remove it it  
should load again. The reason is that autorelease (like release and  
retain) are ignored selectors of the runtime. Clearly we should not  
crash this way, I will fix that.


Also, keep in mind that retain, release and autorelease should not  
be used in MacRuby. We run under GC mode which makes these calls no- 
ops.


Laurent

On Sep 23, 2009, at 12:18 PM, Robert Rice wrote:

Hi Laurent:

Thanks for your offer to help. Sorry I was busy with another project  
but now I get back to MacRuby.


I have attached a file that causes the assertion error when loaded  
by the require command. Probably there is something else I need to  
change when porting from Ruby-Cocoa.


Thanks,
Bob Rice


On Sep 12, 2009, at 3:08 PM, Laurent Sansonetti wrote:

Hi Robert,

Unless you found what was wrong, feel free to contact me off-list  
with a copy of your app and I will investigate the problem.


Laurent

On Sep 12, 2009, at 9:48 AM, Robert Rice wrote:

Hi Laurent:

It's a relatively large application that I ported from a RubyCocoa  
environment.
I need the threading support hook that was removed from Ruby in the  
Snow Leopard release.


I'll try to track it down better by porting and testing modules a  
little at a time.


Thanks,
Bob Rice

On Sep 11, 2009, at 12:53 PM, Laurent Sansonetti wrote:

Looks like we are hitting an assertion in the symbol generator...  
Could you send us what you are trying to execute here?


Laurent

Sent from my iPhone

On Sep 11, 2009, at 9:48 AM, Robert Rice  wrote:

How would I track down the following error from the nightly build?

[Session started at 2009-09-11 12:43:22 -0400.]
GNU gdb 6.3.50-20050815 (Apple version gdb-1344) (Fri Jul  3  
01:19:56 UTC 2009)

Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and  
you are
welcome to change it and/or distribute copies of it under certain  
conditions.

Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for  
details.

This GDB was configured as "x86_64-apple-darwin".tty /dev/ttys000
Loading program into debugger…
Program loaded.
run
[Switching to process 326]
Running…
Assertion failed: (1==0), function rb_intern3, file parse.y, line  
9596.

Program received signal:  “SIGABRT”.
sharedlibrary apply-load-rules all
warning: Could not find object file "/Users/mattetti/src/macruby- 
gitsvn/trunk/array.o" - no debug information available for "array.c".


warning: Could not find object file "/Users/mattetti/src/macruby- 
gitsvn/trunk/bignum.o" - no debug information available for  
"bignum.c".


...
Thanks,
Bob Rice

On Sep 10, 2009, at 2:24 PM, Matt Aimonetti wrote:

Latest trunk code available as an unofficial pkg ready to install: 
http://rubyurl.com/5K3W

Lots of bug fixes, improved macgem (not finished yet but you can  
install gems and load them using `gem 'gem_name'; require  
'whatever'`).

Things are looking pretty good on trunk :)

- Matt
___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-

Re: [MacRuby-devel] require failing to find installed gem - from Cocoa app

2009-09-23 Thread Laurent Sansonetti

Hi Bob,

Did you embed MacRuby within your app? This could potentially explain  
why it cannot find the gem.


Laurent

On Sep 23, 2009, at 12:05 PM, Stevenson, Bob wrote:

I've installed a gem that I'm trying to use from the latest nightly;  
but the embedded macruby runtime; does not find the gem.
Controller.rb:14:in `': no such file to load -- xml-object  
(LoadError)


What do I need to do so that the embedded macruby can find my  
installed gem?
I can perform the require successfully from macirb.  Then gem is  
installed off my home directory at: ~/.gem


Thanks in advance.

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] macruby nightly build 2009-09-10

2009-09-23 Thread Jordan Breeding
So in that case Ruby would be garbage collected, but ObjC code it uses  
will be ref counted?


Sent from my iPhone

On Sep 23, 2009, at 18:00, Laurent Sansonetti   
wrote:



Hi Conrad,

The thing is, MacRuby is built on top of the ObjC GC, so there is  
currently no way you can not use it :)


In the future we might introduce a mode where MacRuby doesn't use  
this GC, but it's all tentative.


Laurent

On Sep 23, 2009, at 3:58 PM, Conrad Taylor wrote:

Laurent, I understand that one should use the GC for MacRuby but  
why do we have such a restriction?  Just curious about the history  
here.


Thanks in advance,

-Conrad

On Wed, Sep 23, 2009 at 3:49 PM, Laurent Sansonetti > wrote:

Hi Robert,

The problem here is dealloc. Same reason, dealloc is ignored by the  
runtime, and you should not use it in MacRuby, it will never be  
called.


I just fixed macruby to not crash in case autorelease or dealloc is  
used, but keep in mind that using these selectors won't do anything.


Laurent


On Sep 23, 2009, at 2:46 PM, Robert Rice wrote:

Hi Laurent:

Thanks for your quick reply. I have attached another file that  
causes a similar crash without a call to autorelease.


Bob Rice




On Sep 23, 2009, at 3:24 PM, Laurent Sansonetti wrote:

Hi Robert,

The problem is line 68, the call to autorelease. If you remove it  
it should load again. The reason is that autorelease (like release  
and retain) are ignored selectors of the runtime. Clearly we should  
not crash this way, I will fix that.


Also, keep in mind that retain, release and autorelease should not  
be used in MacRuby. We run under GC mode which makes these calls no- 
ops.


Laurent

On Sep 23, 2009, at 12:18 PM, Robert Rice wrote:

Hi Laurent:

Thanks for your offer to help. Sorry I was busy with another  
project but now I get back to MacRuby.


I have attached a file that causes the assertion error when loaded  
by the require command. Probably there is something else I need to  
change when porting from Ruby-Cocoa.


Thanks,
Bob Rice


On Sep 12, 2009, at 3:08 PM, Laurent Sansonetti wrote:

Hi Robert,

Unless you found what was wrong, feel free to contact me off-list  
with a copy of your app and I will investigate the problem.


Laurent

On Sep 12, 2009, at 9:48 AM, Robert Rice wrote:

Hi Laurent:

It's a relatively large application that I ported from a RubyCocoa  
environment.
I need the threading support hook that was removed from Ruby in the  
Snow Leopard release.


I'll try to track it down better by porting and testing modules a  
little at a time.


Thanks,
Bob Rice

On Sep 11, 2009, at 12:53 PM, Laurent Sansonetti wrote:

Looks like we are hitting an assertion in the symbol generator...  
Could you send us what you are trying to execute here?


Laurent

Sent from my iPhone

On Sep 11, 2009, at 9:48 AM, Robert Rice   
wrote:


How would I track down the following error from the nightly build?

[Session started at 2009-09-11 12:43:22 -0400.]
GNU gdb 6.3.50-20050815 (Apple version gdb-1344) (Fri Jul  3  
01:19:56 UTC 2009)

Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License,  
and you are
welcome to change it and/or distribute copies of it under certain  
conditions.

Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for  
details.

This GDB was configured as "x86_64-apple-darwin".tty /dev/ttys000
Loading program into debugger…
Program loaded.
run
[Switching to process 326]
Running…
Assertion failed: (1==0), function rb_intern3, file parse.y, line  
9596.

Program received signal:  “SIGABRT”.
sharedlibrary apply-load-rules all
warning: Could not find object file "/Users/mattetti/src/macruby- 
gitsvn/trunk/array.o" - no debug information available for "array.c".


warning: Could not find object file "/Users/mattetti/src/macruby- 
gitsvn/trunk/bignum.o" - no debug information available for  
"bignum.c".


...
Thanks,
Bob Rice

On Sep 10, 2009, at 2:24 PM, Matt Aimonetti wrote:

Latest trunk code available as an unofficial pkg ready to install: 
http://rubyurl.com/5K3W

Lots of bug fixes, improved macgem (not finished yet but you can  
install gems and load them using `gem 'gem_name'; require  
'whatever'`).

Things are looking pretty good on trunk :)

- Matt
___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/ma

Re: [MacRuby-devel] macruby nightly build 2009-09-10

2009-09-23 Thread Conrad Taylor
Hi, Objective-C could use GC and non-GC for memory management on the
desktop.
-Conrad

On Wed, Sep 23, 2009 at 4:51 PM, Jordan Breeding wrote:

> So in that case Ruby would be garbage collected, but ObjC code it uses will
> be ref counted?
>
> Sent from my iPhone
>
>
> On Sep 23, 2009, at 18:00, Laurent Sansonetti 
> wrote:
>
>  Hi Conrad,
>>
>> The thing is, MacRuby is built on top of the ObjC GC, so there is
>> currently no way you can not use it :)
>>
>> In the future we might introduce a mode where MacRuby doesn't use this GC,
>> but it's all tentative.
>>
>> Laurent
>>
>> On Sep 23, 2009, at 3:58 PM, Conrad Taylor wrote:
>>
>>  Laurent, I understand that one should use the GC for MacRuby but why do
>>> we have such a restriction?  Just curious about the history here.
>>>
>>> Thanks in advance,
>>>
>>> -Conrad
>>>
>>> On Wed, Sep 23, 2009 at 3:49 PM, Laurent Sansonetti <
>>> [email protected]> wrote:
>>> Hi Robert,
>>>
>>> The problem here is dealloc. Same reason, dealloc is ignored by the
>>> runtime, and you should not use it in MacRuby, it will never be called.
>>>
>>> I just fixed macruby to not crash in case autorelease or dealloc is used,
>>> but keep in mind that using these selectors won't do anything.
>>>
>>> Laurent
>>>
>>>
>>> On Sep 23, 2009, at 2:46 PM, Robert Rice wrote:
>>>
>>> Hi Laurent:
>>>
>>> Thanks for your quick reply. I have attached another file that causes a
>>> similar crash without a call to autorelease.
>>>
>>> Bob Rice
>>> 
>>>
>>>
>>>
>>> On Sep 23, 2009, at 3:24 PM, Laurent Sansonetti wrote:
>>>
>>> Hi Robert,
>>>
>>> The problem is line 68, the call to autorelease. If you remove it it
>>> should load again. The reason is that autorelease (like release and retain)
>>> are ignored selectors of the runtime. Clearly we should not crash this way,
>>> I will fix that.
>>>
>>> Also, keep in mind that retain, release and autorelease should not be
>>> used in MacRuby. We run under GC mode which makes these calls no-ops.
>>>
>>> Laurent
>>>
>>> On Sep 23, 2009, at 12:18 PM, Robert Rice wrote:
>>>
>>> Hi Laurent:
>>>
>>> Thanks for your offer to help. Sorry I was busy with another project but
>>> now I get back to MacRuby.
>>>
>>> I have attached a file that causes the assertion error when loaded by the
>>> require command. Probably there is something else I need to change when
>>> porting from Ruby-Cocoa.
>>>
>>> Thanks,
>>> Bob Rice
>>> 
>>>
>>> On Sep 12, 2009, at 3:08 PM, Laurent Sansonetti wrote:
>>>
>>> Hi Robert,
>>>
>>> Unless you found what was wrong, feel free to contact me off-list with a
>>> copy of your app and I will investigate the problem.
>>>
>>> Laurent
>>>
>>> On Sep 12, 2009, at 9:48 AM, Robert Rice wrote:
>>>
>>> Hi Laurent:
>>>
>>> It's a relatively large application that I ported from a RubyCocoa
>>> environment.
>>> I need the threading support hook that was removed from Ruby in the Snow
>>> Leopard release.
>>>
>>> I'll try to track it down better by porting and testing modules a little
>>> at a time.
>>>
>>> Thanks,
>>> Bob Rice
>>>
>>> On Sep 11, 2009, at 12:53 PM, Laurent Sansonetti wrote:
>>>
>>> Looks like we are hitting an assertion in the symbol generator... Could
>>> you send us what you are trying to execute here?
>>>
>>> Laurent
>>>
>>> Sent from my iPhone
>>>
>>> On Sep 11, 2009, at 9:48 AM, Robert Rice  wrote:
>>>
>>> How would I track down the following error from the nightly build?
>>>
>>> [Session started at 2009-09-11 12:43:22 -0400.]
>>> GNU gdb 6.3.50-20050815 (Apple version gdb-1344) (Fri Jul  3 01:19:56 UTC
>>> 2009)
>>> Copyright 2004 Free Software Foundation, Inc.
>>> GDB is free software, covered by the GNU General Public License, and you
>>> are
>>> welcome to change it and/or distribute copies of it under certain
>>> conditions.
>>> Type "show copying" to see the conditions.
>>> There is absolutely no warranty for GDB.  Type "show warranty" for
>>> details.
>>> This GDB was configured as "x86_64-apple-darwin".tty /dev/ttys000
>>> Loading program into debugger…
>>> Program loaded.
>>> run
>>> [Switching to process 326]
>>> Running…
>>> Assertion failed: (1==0), function rb_intern3, file parse.y, line 9596.
>>> Program received signal:  “SIGABRT”.
>>> sharedlibrary apply-load-rules all
>>> warning: Could not find object file
>>> "/Users/mattetti/src/macruby-gitsvn/trunk/array.o" - no debug information
>>> available for "array.c".
>>>
>>> warning: Could not find object file
>>> "/Users/mattetti/src/macruby-gitsvn/trunk/bignum.o" - no debug information
>>> available for "bignum.c".
>>>
>>> ...
>>> Thanks,
>>> Bob Rice
>>>
>>> On Sep 10, 2009, at 2:24 PM, Matt Aimonetti wrote:
>>>
>>> Latest trunk code available as an unofficial pkg ready to install:
>>> http://rubyurl.com/5K3W
>>>
>>> Lots of bug fixes, improved macgem (not finished yet but you can install
>>> gems and load them using `gem 'gem_name'; require 'whatever'`).
>>> Things are looking pretty good on trunk :)
>>>
>>> - Matt
>>> _

Re: [MacRuby-devel] macruby nightly build 2009-09-10

2009-09-23 Thread Jordan Breeding
But would the new MacRuby interpreter be smart enough to switch  
between them and prefer GC Objc-C code, or would it be locked to one  
or the other?


Sent from my iPhone

On Sep 23, 2009, at 18:56, Conrad Taylor  wrote:

Hi, Objective-C could use GC and non-GC for memory management on the  
desktop.


-Conrad

On Wed, Sep 23, 2009 at 4:51 PM, Jordan Breeding > wrote:
So in that case Ruby would be garbage collected, but ObjC code it  
uses will be ref counted?


Sent from my iPhone


On Sep 23, 2009, at 18:00, Laurent Sansonetti  
 wrote:


Hi Conrad,

The thing is, MacRuby is built on top of the ObjC GC, so there is  
currently no way you can not use it :)


In the future we might introduce a mode where MacRuby doesn't use  
this GC, but it's all tentative.


Laurent

On Sep 23, 2009, at 3:58 PM, Conrad Taylor wrote:

Laurent, I understand that one should use the GC for MacRuby but why  
do we have such a restriction?  Just curious about the history here.


Thanks in advance,

-Conrad

On Wed, Sep 23, 2009 at 3:49 PM, Laurent Sansonetti > wrote:

Hi Robert,

The problem here is dealloc. Same reason, dealloc is ignored by the  
runtime, and you should not use it in MacRuby, it will never be  
called.


I just fixed macruby to not crash in case autorelease or dealloc is  
used, but keep in mind that using these selectors won't do anything.


Laurent


On Sep 23, 2009, at 2:46 PM, Robert Rice wrote:

Hi Laurent:

Thanks for your quick reply. I have attached another file that  
causes a similar crash without a call to autorelease.


Bob Rice




On Sep 23, 2009, at 3:24 PM, Laurent Sansonetti wrote:

Hi Robert,

The problem is line 68, the call to autorelease. If you remove it it  
should load again. The reason is that autorelease (like release and  
retain) are ignored selectors of the runtime. Clearly we should not  
crash this way, I will fix that.


Also, keep in mind that retain, release and autorelease should not  
be used in MacRuby. We run under GC mode which makes these calls no- 
ops.


Laurent

On Sep 23, 2009, at 12:18 PM, Robert Rice wrote:

Hi Laurent:

Thanks for your offer to help. Sorry I was busy with another project  
but now I get back to MacRuby.


I have attached a file that causes the assertion error when loaded  
by the require command. Probably there is something else I need to  
change when porting from Ruby-Cocoa.


Thanks,
Bob Rice


On Sep 12, 2009, at 3:08 PM, Laurent Sansonetti wrote:

Hi Robert,

Unless you found what was wrong, feel free to contact me off-list  
with a copy of your app and I will investigate the problem.


Laurent

On Sep 12, 2009, at 9:48 AM, Robert Rice wrote:

Hi Laurent:

It's a relatively large application that I ported from a RubyCocoa  
environment.
I need the threading support hook that was removed from Ruby in the  
Snow Leopard release.


I'll try to track it down better by porting and testing modules a  
little at a time.


Thanks,
Bob Rice

On Sep 11, 2009, at 12:53 PM, Laurent Sansonetti wrote:

Looks like we are hitting an assertion in the symbol generator...  
Could you send us what you are trying to execute here?


Laurent

Sent from my iPhone

On Sep 11, 2009, at 9:48 AM, Robert Rice  wrote:

How would I track down the following error from the nightly build?

[Session started at 2009-09-11 12:43:22 -0400.]
GNU gdb 6.3.50-20050815 (Apple version gdb-1344) (Fri Jul  3  
01:19:56 UTC 2009)

Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and  
you are
welcome to change it and/or distribute copies of it under certain  
conditions.

Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for  
details.

This GDB was configured as "x86_64-apple-darwin".tty /dev/ttys000
Loading program into debugger…
Program loaded.
run
[Switching to process 326]
Running…
Assertion failed: (1==0), function rb_intern3, file parse.y, line  
9596.

Program received signal:  “SIGABRT”.
sharedlibrary apply-load-rules all
warning: Could not find object file "/Users/mattetti/src/macruby- 
gitsvn/trunk/array.o" - no debug information available for "array.c".


warning: Could not find object file "/Users/mattetti/src/macruby- 
gitsvn/trunk/bignum.o" - no debug information available for  
"bignum.c".


...
Thanks,
Bob Rice

On Sep 10, 2009, at 2:24 PM, Matt Aimonetti wrote:

Latest trunk code available as an unofficial pkg ready to install: 
http://rubyurl.com/5K3W

Lots of bug fixes, improved macgem (not finished yet but you can  
install gems and load them using `gem 'gem_name'; require  
'whatever'`).

Things are looking pretty good on trunk :)

- Matt
___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/ma

Re: [MacRuby-devel] macruby nightly build 2009-09-10

2009-09-23 Thread Conrad Taylor
In regards to a MacRuby application, you would need to use GC for
Objective-C.

-Conrad

On Wed, Sep 23, 2009 at 5:00 PM, Jordan Breeding wrote:

> But would the new MacRuby interpreter be smart enough to switch between
> them and prefer GC Objc-C code, or would it be locked to one or the other?
>
> Sent from my iPhone
>
> On Sep 23, 2009, at 18:56, Conrad Taylor  wrote:
>
> Hi, Objective-C could use GC and non-GC for memory management on the
> desktop.
> -Conrad
>
> On Wed, Sep 23, 2009 at 4:51 PM, Jordan Breeding <
> [email protected]> wrote:
>
>> So in that case Ruby would be garbage collected, but ObjC code it uses
>> will be ref counted?
>>
>> Sent from my iPhone
>>
>>
>> On Sep 23, 2009, at 18:00, Laurent Sansonetti < 
>> [email protected]> wrote:
>>
>>  Hi Conrad,
>>>
>>> The thing is, MacRuby is built on top of the ObjC GC, so there is
>>> currently no way you can not use it :)
>>>
>>> In the future we might introduce a mode where MacRuby doesn't use this
>>> GC, but it's all tentative.
>>>
>>> Laurent
>>>
>>> On Sep 23, 2009, at 3:58 PM, Conrad Taylor wrote:
>>>
>>>  Laurent, I understand that one should use the GC for MacRuby but why do
 we have such a restriction?  Just curious about the history here.

 Thanks in advance,

 -Conrad

 On Wed, Sep 23, 2009 at 3:49 PM, Laurent Sansonetti 
 <
 [email protected]> wrote:
 Hi Robert,

 The problem here is dealloc. Same reason, dealloc is ignored by the
 runtime, and you should not use it in MacRuby, it will never be called.

 I just fixed macruby to not crash in case autorelease or dealloc is
 used, but keep in mind that using these selectors won't do anything.

 Laurent


 On Sep 23, 2009, at 2:46 PM, Robert Rice wrote:

 Hi Laurent:

 Thanks for your quick reply. I have attached another file that causes a
 similar crash without a call to autorelease.

 Bob Rice
 



 On Sep 23, 2009, at 3:24 PM, Laurent Sansonetti wrote:

 Hi Robert,

 The problem is line 68, the call to autorelease. If you remove it it
 should load again. The reason is that autorelease (like release and retain)
 are ignored selectors of the runtime. Clearly we should not crash this way,
 I will fix that.

 Also, keep in mind that retain, release and autorelease should not be
 used in MacRuby. We run under GC mode which makes these calls no-ops.

 Laurent

 On Sep 23, 2009, at 12:18 PM, Robert Rice wrote:

 Hi Laurent:

 Thanks for your offer to help. Sorry I was busy with another project but
 now I get back to MacRuby.

 I have attached a file that causes the assertion error when loaded by
 the require command. Probably there is something else I need to change when
 porting from Ruby-Cocoa.

 Thanks,
 Bob Rice
 

 On Sep 12, 2009, at 3:08 PM, Laurent Sansonetti wrote:

 Hi Robert,

 Unless you found what was wrong, feel free to contact me off-list with a
 copy of your app and I will investigate the problem.

 Laurent

 On Sep 12, 2009, at 9:48 AM, Robert Rice wrote:

 Hi Laurent:

 It's a relatively large application that I ported from a RubyCocoa
 environment.
 I need the threading support hook that was removed from Ruby in the Snow
 Leopard release.

 I'll try to track it down better by porting and testing modules a little
 at a time.

 Thanks,
 Bob Rice

 On Sep 11, 2009, at 12:53 PM, Laurent Sansonetti wrote:

 Looks like we are hitting an assertion in the symbol generator... Could
 you send us what you are trying to execute here?

 Laurent

 Sent from my iPhone

 On Sep 11, 2009, at 9:48 AM, Robert Rice < 
 [email protected]> wrote:

 How would I track down the following error from the nightly build?

 [Session started at 2009-09-11 12:43:22 -0400.]
 GNU gdb 6.3.50-20050815 (Apple version gdb-1344) (Fri Jul  3 01:19:56
 UTC 2009)
 Copyright 2004 Free Software Foundation, Inc.
 GDB is free software, covered by the GNU General Public License, and you
 are
 welcome to change it and/or distribute copies of it under certain
 conditions.
 Type "show copying" to see the conditions.
 There is absolutely no warranty for GDB.  Type "show warranty" for
 details.
 This GDB was configured as "x86_64-apple-darwin".tty /dev/ttys000
 Loading program into debugger…
 Program loaded.
 run
 [Switching to process 326]
 Running…
 Assertion failed: (1==0), function rb_intern3, file parse.y, line 9596.
 Program received signal:  “SIGABRT”.
 sharedlibrary apply-load-rules all
 warning: Could not find object file
 "/Users/mattetti/src/macruby-gitsvn/trunk/array.o" - no debug information
 available for "array.

Re: [MacRuby-devel] macruby nightly build 2009-09-10

2009-09-23 Thread Robert Rice

Hi Laurent:

Thanks again. This gets me past the compile crashes but now the  
execution doesn't get very far before I get “EXC_BAD_INSTRUCTION” with  
no backtrace. Any suggestions?


Program loaded.
run
[Switching to process 1521]
Running…
rb_main
requiring AppDelegate.rb
requiring DataBaseNew.rb
requiring DrawChart.rb
requiring DrawRemarksIndex.rb
requiring DrawUtilities.rb
requiring DrawWeather.rb
requiring Driver.rb
requiring DriverSummary.rb
requiring EventsTabView.rb
requiring GPSwindowController.rb
requiring History.rb
requiring JBH_F7575101_Views.rb
requiring JBH_F7575101_WindowController.rb
requiring JBH_TS_Views.rb
requiring JBH_TS_WindowController.rb
requiring Location.rb
requiring Log.rb
requiring Logger.rb
requiring LoggerWindowController.rb
requiring Model.rb
requiring OutlineRowNode.rb
requiring OutlineView.rb
requiring OutlineViewData.rb
requiring Position.rb
requiring Remarks.rb
requiring ReportsWindowController.rb
requiring Rules.rb
requiring SearchLocation.rb
requiring StartOfDay.rb
requiring Stop.rb
requiring TextUtilities.rb
requiring Trailers.rb
requiring Trip.rb
requiring Vehicle.rb
requiring WeatherIcons.rb
Program received signal:  “EXC_BAD_INSTRUCTION”.
sharedlibrary apply-load-rules all
warning: Could not find object file "/Sites/kain/icoretech.org/macruby/ 
repo/array.o" - no debug information available for "array.c".


warning: Could not find object file "/Sites/kain/icoretech.org/macruby/ 
repo/bignum.o" - no debug information available for "bignum.c".


Bob Rice

On Sep 23, 2009, at 6:49 PM, Laurent Sansonetti wrote:


Hi Robert,

The problem here is dealloc. Same reason, dealloc is ignored by the  
runtime, and you should not use it in MacRuby, it will never be  
called.


I just fixed macruby to not crash in case autorelease or dealloc is  
used, but keep in mind that using these selectors won't do anything.


Laurent

On Sep 23, 2009, at 2:46 PM, Robert Rice wrote:
___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] macruby nightly build 2009-09-10

2009-09-23 Thread Laurent Sansonetti

Hi Robert,

This one will be hard to debug without your code. At least, from gdb,  
could you do a "bt" and copy/paste the output?


Laurent

On Sep 23, 2009, at 5:17 PM, Robert Rice wrote:


Hi Laurent:

Thanks again. This gets me past the compile crashes but now the  
execution doesn't get very far before I get “EXC_BAD_INSTRUCTION”  
with no backtrace. Any suggestions?


Program loaded.
run
[Switching to process 1521]
Running…
rb_main
requiring AppDelegate.rb
requiring DataBaseNew.rb
requiring DrawChart.rb
requiring DrawRemarksIndex.rb
requiring DrawUtilities.rb
requiring DrawWeather.rb
requiring Driver.rb
requiring DriverSummary.rb
requiring EventsTabView.rb
requiring GPSwindowController.rb
requiring History.rb
requiring JBH_F7575101_Views.rb
requiring JBH_F7575101_WindowController.rb
requiring JBH_TS_Views.rb
requiring JBH_TS_WindowController.rb
requiring Location.rb
requiring Log.rb
requiring Logger.rb
requiring LoggerWindowController.rb
requiring Model.rb
requiring OutlineRowNode.rb
requiring OutlineView.rb
requiring OutlineViewData.rb
requiring Position.rb
requiring Remarks.rb
requiring ReportsWindowController.rb
requiring Rules.rb
requiring SearchLocation.rb
requiring StartOfDay.rb
requiring Stop.rb
requiring TextUtilities.rb
requiring Trailers.rb
requiring Trip.rb
requiring Vehicle.rb
requiring WeatherIcons.rb
Program received signal:  “EXC_BAD_INSTRUCTION”.
sharedlibrary apply-load-rules all
warning: Could not find object file "/Sites/kain/icoretech.org/ 
macruby/repo/array.o" - no debug information available for "array.c".


warning: Could not find object file "/Sites/kain/icoretech.org/ 
macruby/repo/bignum.o" - no debug information available for  
"bignum.c".


Bob Rice

On Sep 23, 2009, at 6:49 PM, Laurent Sansonetti wrote:


Hi Robert,

The problem here is dealloc. Same reason, dealloc is ignored by the  
runtime, and you should not use it in MacRuby, it will never be  
called.


I just fixed macruby to not crash in case autorelease or dealloc is  
used, but keep in mind that using these selectors won't do anything.


Laurent

On Sep 23, 2009, at 2:46 PM, Robert Rice wrote:

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] macruby nightly build 2009-09-10

2009-09-23 Thread Robert Rice

Hi again:

Does this help?

(gdb) bt
#0  0x7fff827521b2 in +[NSThread callStackSymbols] ()
#1  0x00010213700c in ?? ()
#2  0x000102132034 in ?? ()
#3  0x7fff81ab7408 in -[NSIBObjectData instantiateObject:] ()
#4  0x7fff81ab67f2 in -[NSIBObjectData  
nibInstantiateWithOwner:topLevelObjects:] ()

#5  0x7fff81ab4e7d in loadNib ()
#6  0x7fff81ab438a in +[NSBundle(NSNibLoading)  
_loadNibFile:nameTable:withZone:ownerBundle:] ()
#7  0x7fff81ab41c2 in +[NSBundle(NSNibLoading)  
loadNibNamed:owner:] ()

#8  0x7fff81ab1743 in NSApplicationMain ()
#9  0x000102136f70 in ?? ()
#10 0x0001020802a0 in ?? ()
#11 0x00010003fb09 in ruby_run_node ()
#12 0x000100172c49 in macruby_main ()
#13 0x00010e3e in main (argc=1, argv=0x7fff5fbff538) at /Users/ 
robertrice/Desktop/Test Systems/MacRuby 0.5 Driver Assistant/main.m:13

(gdb)

Thanks,
Bob Rice

On Sep 23, 2009, at 8:23 PM, Laurent Sansonetti wrote:


Hi Robert,

This one will be hard to debug without your code. At least, from  
gdb, could you do a "bt" and copy/paste the output?


Laurent

On Sep 23, 2009, at 5:17 PM, Robert Rice wrote:


___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] macruby nightly build 2009-09-10

2009-09-23 Thread Laurent Sansonetti
Very hard to tell, sorry. Contact me offline with a copy of your app  
and I can investigate (if you don't want to share your source code  
here).


Laurent

On Sep 23, 2009, at 5:57 PM, Robert Rice wrote:


Hi again:

Does this help?

(gdb) bt
#0  0x7fff827521b2 in +[NSThread callStackSymbols] ()
#1  0x00010213700c in ?? ()
#2  0x000102132034 in ?? ()
#3  0x7fff81ab7408 in -[NSIBObjectData instantiateObject:] ()
#4  0x7fff81ab67f2 in -[NSIBObjectData  
nibInstantiateWithOwner:topLevelObjects:] ()

#5  0x7fff81ab4e7d in loadNib ()
#6  0x7fff81ab438a in +[NSBundle(NSNibLoading)  
_loadNibFile:nameTable:withZone:ownerBundle:] ()
#7  0x7fff81ab41c2 in +[NSBundle(NSNibLoading)  
loadNibNamed:owner:] ()

#8  0x7fff81ab1743 in NSApplicationMain ()
#9  0x000102136f70 in ?? ()
#10 0x0001020802a0 in ?? ()
#11 0x00010003fb09 in ruby_run_node ()
#12 0x000100172c49 in macruby_main ()
#13 0x00010e3e in main (argc=1, argv=0x7fff5fbff538) at / 
Users/robertrice/Desktop/Test Systems/MacRuby 0.5 Driver Assistant/ 
main.m:13

(gdb)

Thanks,
Bob Rice

On Sep 23, 2009, at 8:23 PM, Laurent Sansonetti wrote:


Hi Robert,

This one will be hard to debug without your code. At least, from  
gdb, could you do a "bt" and copy/paste the output?


Laurent

On Sep 23, 2009, at 5:17 PM, Robert Rice wrote:


___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] macruby nightly build 2009-09-10

2009-09-23 Thread Jordan Breeding

Sorry, I don't know if I missed something or not.

Currently MacRuby has a GC (as does Ruby) and it is based on Obj-C's  
GC. This means that code pulled in to MacRuby MUST be GC currently.


In my opinion this isn't horrible or extremely difficult as you can  
compile frameworks as -fobjc-gc instead of fobjc-gc-only and make sure  
that you have all of the proper ref-counting in place.


It seems to me that the original problem here was someone sending ref- 
counting messages straight from Ruby code. Where I get confused is  
that then Laurent said "in the future we might introduce a mode where  
MacRuby doesn't use this GC".


I assume that the plan isn't to ditch GC all together in MacRuby since  
Ruby has a GC, so I am assuming that the goal of this possible future  
mode is to have Ruby code be garbage collected but not require Obj-C  
code to be GC anymore.


I am guessing because this is the first I remember seeing about this  
and am curious as to how it would work in practice. At least to me the  
current system of making GC a requirement for Frameworks in use in  
MacRuby seems to work well.


I guess I am just curious as to what exactly this mode would be like  
from the perspective of Ruby and from the perspective of Obj-C/Cocoa  
if it is introduced.


Laurent, is it possible to get more info publicly, or is this all  
still in really early stages, or private within Apple at this point?


Jordan

On Sep 23, 2009, at 19:05, Conrad Taylor wrote:

In regards to a MacRuby application, you would need to use GC for  
Objective-C.


-Conrad

On Wed, Sep 23, 2009 at 5:00 PM, Jordan Breeding > wrote:
But would the new MacRuby interpreter be smart enough to switch  
between them and prefer GC Objc-C code, or would it be locked to one  
or the other?


Sent from my iPhone

On Sep 23, 2009, at 18:56, Conrad Taylor  wrote:

Hi, Objective-C could use GC and non-GC for memory management on  
the desktop.


-Conrad

On Wed, Sep 23, 2009 at 4:51 PM, Jordan Breeding > wrote:
So in that case Ruby would be garbage collected, but ObjC code it  
uses will be ref counted?


Sent from my iPhone


On Sep 23, 2009, at 18:00, Laurent Sansonetti  
 wrote:


Hi Conrad,

The thing is, MacRuby is built on top of the ObjC GC, so there is  
currently no way you can not use it :)


In the future we might introduce a mode where MacRuby doesn't use  
this GC, but it's all tentative.


Laurent

On Sep 23, 2009, at 3:58 PM, Conrad Taylor wrote:

Laurent, I understand that one should use the GC for MacRuby but  
why do we have such a restriction?  Just curious about the history  
here.


Thanks in advance,

-Conrad

On Wed, Sep 23, 2009 at 3:49 PM, Laurent Sansonetti > wrote:

Hi Robert,

The problem here is dealloc. Same reason, dealloc is ignored by the  
runtime, and you should not use it in MacRuby, it will never be  
called.


I just fixed macruby to not crash in case autorelease or dealloc is  
used, but keep in mind that using these selectors won't do anything.


Laurent


On Sep 23, 2009, at 2:46 PM, Robert Rice wrote:

Hi Laurent:

Thanks for your quick reply. I have attached another file that  
causes a similar crash without a call to autorelease.


Bob Rice




On Sep 23, 2009, at 3:24 PM, Laurent Sansonetti wrote:

Hi Robert,

The problem is line 68, the call to autorelease. If you remove it  
it should load again. The reason is that autorelease (like release  
and retain) are ignored selectors of the runtime. Clearly we should  
not crash this way, I will fix that.


Also, keep in mind that retain, release and autorelease should not  
be used in MacRuby. We run under GC mode which makes these calls no- 
ops.


Laurent

On Sep 23, 2009, at 12:18 PM, Robert Rice wrote:

Hi Laurent:

Thanks for your offer to help. Sorry I was busy with another  
project but now I get back to MacRuby.


I have attached a file that causes the assertion error when loaded  
by the require command. Probably there is something else I need to  
change when porting from Ruby-Cocoa.


Thanks,
Bob Rice


On Sep 12, 2009, at 3:08 PM, Laurent Sansonetti wrote:

Hi Robert,

Unless you found what was wrong, feel free to contact me off-list  
with a copy of your app and I will investigate the problem.


Laurent

On Sep 12, 2009, at 9:48 AM, Robert Rice wrote:

Hi Laurent:

It's a relatively large application that I ported from a RubyCocoa  
environment.
I need the threading support hook that was removed from Ruby in the  
Snow Leopard release.


I'll try to track it down better by porting and testing modules a  
little at a time.


Thanks,
Bob Rice

On Sep 11, 2009, at 12:53 PM, Laurent Sansonetti wrote:

Looks like we are hitting an assertion in the symbol generator...  
Could you send us what you are trying to execute here?


Laurent

Sent from my iPhone

On Sep 11, 2009, at 9:48 AM, Robert Rice   
wrote:


How would I track down the following error from the nightly build?

[Session started at 2009-09-11 12:43:22 -0400.]
GNU gdb 6.3.50-20050815 (Appl