Re: fetching unset GParamSpec property




On Sep 6, 2008, at 9:32 AM, Torsten Schoenfeld wrote:

Kevin Ryde wrote:
I just committed a patch that implements the latter approach.

Don't forget the constructors returning null for bad args too.

With the recent commit, these tests now actually pass. Unfortunately, they also print very noisy warning messages, so unless there's a way to suppress those, I don't think we should add the tests. Handling NULL GParamSpecs is tested
already at the end of t/e.t anyway.

You *can* suppress those messages, by using a log handler.

    Glib::Log->set_handler ('GLib-GObject', 'critical', sub {
            print "Hijacked failed assertion message: $_[2]\n";
    });

I'd be tempted to add an ok(1) in there, but you can build glib with assertions turned off.

--
Applause is an addiction, like heroin or checking your email.
  -- Sideshow Mel




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]