[fortran-exp, patch] get_expr code cleanup, part II

Bud Davis bdavis9659@sbcglobal.net
Mon Jan 4 19:59:00 GMT 2010



--- On Mon, 1/4/10, Daniel Franke <franke.daniel@gmail.com> wrote:

> From: Daniel Franke <franke.daniel@gmail.com>
> Subject: Re: [fortran-exp, patch] get_expr code cleanup, part II
> To: "Bud Davis" <bdavis9659@sbcglobal.net>
> Cc: fortran@gcc.gnu.org, gcc-patches@gcc.gnu.org
> Date: Monday, January 4, 2010, 1:55 PM
> On Monday 04 January 2010 20:51:42
> Bud Davis wrote:
> >     
> tmp_sym->value->ts.is_c_interop = 1;
> >     
> tmp_sym->value->ts.is_iso_c = 1;
> >     
> tmp_sym->value->value.character.length = 1;
> > -   
> tmp_sym->value->value.character.string =
> gfc_get_wide_string (2);
> >     
> tmp_sym->value->value.character.string[0]
> >        = (gfc_char_t)
> c_interop_kinds_table[s].value;
> > -   
> tmp_sym->value->value.character.string[1] = '\0';
> >      tmp_sym->ts.u.cl =
> gfc_new_charlen (gfc_current_ns, NULL);
> > 
> > 
> > did you really mean to delete these 2 lines ?
> 
> Yes.
> 
> +       tmp_sym->value =
> gfc_get_character_expr (gfc_default_character_kind,
> +               
>                
>                
> &gfc_current_locus, NULL, 1);
> 
> which is just above the quoted part builds a 1+1 character
> string, blanks it 
> and appends a '\0'. At least, that was what I meant to
> happen here?!
> 
> Cheers
> 
>     Daniel
> 

very good.  false positive:)

--bud



More information about the Fortran mailing list