[AMD Official Use Only] Thanks Kevin, Requesting to review the updated patch with suggested changes. TYPE_DYN_PROP is added by me as part of assumed rank feature(e1ac856e3aee2f95e567e5fbca17e41b72957cdb) only for this case. Since we are no longer using it removed the macro. Regards, Rupesh P > -----Original Message----- > From: Kevin Buettner > Sent: Wednesday, April 13, 2022 11:58 PM > To: Potharla, Rupesh via Gdb-patches > Cc: Potharla, Rupesh ; George, Jini Susan > ; Parasuraman, Hariharan > ; Sharma, Alok Kumar > > Subject: Re: GDB/Fortran: Support for Assumed Rank Zero. > > [CAUTION: External Email] > > Hi Rupesh, > > Thanks for working on this problem. I found a couple of nits; see below. > > On Wed, 13 Apr 2022 09:55:01 +0000 > "Potharla, Rupesh via Gdb-patches" wrote: > > > diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c index > > 49ecb199b07..c2d142ac3cc 100644 > > --- a/gdb/gdbtypes.c > > +++ b/gdb/gdbtypes.c > > @@ -2398,10 +2398,12 @@ resolve_dynamic_array_or_string (struct type > > *type, > > > > if (rank == 0) > > { > > - /* The dynamic property list juggling below was from the original > > - patch. I don't understand what this is all about, so I've > > - commented it out for now and added the following error. */ > > - error (_("failed to resolve dynamic array rank")); > > + /* Rank is zero, if a variable is passed as an argument to a > > + function. GDB considers the variable as an array so discard > > + the array type and return the target type which is of variable. */ > > + TYPE_DYN_PROP(TYPE_TARGET_TYPE(type)) = > TYPE_DYN_PROP(type); > > + type = TYPE_TARGET_TYPE(type); > > + return type; > > } > > else if (type->code () == TYPE_CODE_STRING && rank != 1) > > { > > > > GDB's coding standard requires that things like TYPE_TARGET_TYPE(type) be > written with a space before the left paren, i.e. TYPE_TARGET_TYPE (type). > > See: > https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Fsour > ceware.org%2Fgdb%2Fwiki%2FInternals%2520GDB-C-Coding- > Standards&data=04%7C01%7Crupesh.potharla%40amd.com%7C4f7745 > 3bd29d4333881d08da1d7b55bf%7C3dd8961fe4884e608e11a82d994e183d% > 7C0%7C0%7C637854712954812288%7CUnknown%7CTWFpbGZsb3d8eyJWIjo > iMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C30 > 00&sdata=pqbYaZKCkhvCLBDXdq9obe8NJUpFlOWK3nhPCtAWMlY%3D& > amp;reserved=0 > > Also, regarding TYPE_DYN_PROP, it appears to me that this macro is no > longer being used. I've noticed that other code in gdbtypes.c is referencing > the dyn_prop_list field directly. > > Kevin