Kittekat - 2010-02-13

I try to return an errorpointer as shown in
this is my test code.:
require 'osx/cocoa'
class Contr < OSX::NSObject
  include OSX
  ib_action :trigger

  def generateError(errorPtr)
    error = NSError.alloc.initWithDomain_code_userInfo(
                  4711, nil)
  end # generate_error
  def trigger(sender)
    errorPtr =
    a = NSAlert.alertWithError(errorPtr)
  end # trigger
end # Contr

Anyway, I get a runtime error when using "errorPtr.assign(error)":
2010-02-13 19:59:49.816 ErrorTest Contr#trigger: TypeError: can't convert OSX::NSError into Integer

Looks like i have to somehow tell the instance, what object I want to assign, perhaps when generating it.

But I did not find any documentation about It requires one parameter. I tried do find an indication in the objective-C code of this class, but I was not successful.

Please give me a hint.
Best regards