Re: [PATCH] PR123012 Namelist input of variable accessed by use association with renaming fails
Jerry D <[email protected]>
| Newsgroups | gmane.comp.gcc.patches,gmane.comp.gcc.fortran |
|---|---|
| Message-ID | <[email protected]> |
On 1/7/26 7:10 PM, Steve Kargl wrote: > On Wed, Jan 07, 2026 at 03:52:33PM -0800, Jerry D wrote: >> /* Build the namelist object name. */ >> - if (sym && !sym->attr.use_only && sym->attr.use_rename >> - && sym->ns->use_stmts->rename) >> + if (sym && sym->attr.use_rename && sym->ns->use_stmts->rename >> + && sym->ns->use_stmts->rename->local_name >> + && sym->ns->use_stmts->rename->local_name[0] >> + && strcmp(sym->ns->use_stmts->rename->use_name, var_name) == 0) >> string = gfc_build_cstring_const (sym->ns->use_stmts->rename->local_name); > > This breaks on FreeBSD. sym->ns->use_stmts->rename->local_name > is not a pointer. local_name is a component of a gfc_use_rename > struct with a fixed size. The strlen() I had in the code was > correct. > OK Steve, my apologies, I did not understand. These little nuances between systems are getting us in several ways. I will adjust it back to what you had and push it. Regards, Jerry