This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: C++ patch: Add support for calling Java interfaces


>>>>> "Bryce" == Bryce McKinlay <bryce@albatross.co.nz> writes:

> +  tree lookup_fn = builtin_function ("_Jv_LookupInterfaceMethodIdx",
> +				     build_function_type (ptr_type_node, t),
> +				     0, NOT_BUILT_IN, NULL_PTR);

You should only call builtin_function once; after that, just look it up.

> +  /* Determine the itable index of FN. */
> +  i = 1;
> +  for (method = TYPE_METHODS (iface); method; method = TREE_CHAIN (method))
> +    {
> +      if (DECL_ARTIFICIAL (method) || !DECL_VIRTUAL_P (method))
> +        continue;

Why check DECL_ARTIFICIAL?

Jason


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]