David Megginson writes:
>
>Norman Vine writes:
> >
> > Judging by the number of times this is called
> >  i.e  54 times per LOOP iteration
> > this 'might' be a 'good' candidate for inlining
>
>It's a bad one for inlining, actually, because that forces globals.hxx
>to have a dependency on viewmgr.hxx, so all of FlightGear has to
>rebuild whenever Jim touches the viewer code.

So ???

 --- globals.hxx
#ifdef SLOW_DEVELOPER_CONVENIENCE_CODE
    FGViewer *get_current_view() const;
#else
   FGViewer *get_current_view() const { return
viewmgr->get_current_view(); }
#endif

-- globals.cxx
#iifdef SLOW_DEVELOPER_CONVENIENCE_CODE
FGViewer *
FGGlobals::get_current_view () const
{
  return viewmgr->get_current_view();
}
#endif


_______________________________________________
Flightgear-devel mailing list
[EMAIL PROTECTED]
http://mail.flightgear.org/mailman/listinfo/flightgear-devel

Reply via email to