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] |
Other format: | [Raw text] |
hi, I have updated the patch according your comments. please find code diff and change log with this mail. Should I also put it in the patch queue again? > I also have a few remarks WRT the code which would also apply to a revised > version: > - there are a number of cases where you're not following the coding standards > (trailing whitespace, spaces around '->', maybe others) --changes made for this comments > - I think the function prototypes you added can safely be put into parse.h, > otherwise don't hesistate to put them in gfortran.h --prototypes added to these two files. > - the logic here would be much easier if you moved the check for COMP_ENUM > before the other if >> if (d == DECL_NONE || d == DECL_COLON) >> ! { >> ! if (gfc_current_state () == COMP_ENUM) >> ! { >> ! t = gfc_add_flavor (¤t_attr, FL_PARAMETER, NULL, NULL); >> ! if (t == FAILURE) >> ! { >> ! m = MATCH_ERROR; >> ! goto cleanup; >> ! } >> ! current_attr.enumerator = 1; >> ! } >> ! break; >> ! } >> ! else if (gfc_current_state () == COMP_ENUM) >> ! { >> ! gfc_error ("Enumerator cannot have attributes %C"); >> ! return MATCH_ERROR; >> ! } > the same goes for the change to variable_decl. --changed accordingly > I'm wondering if using gfc_match_data_decl makes much sense given the very > restricted syntax that is allowed inside enumeration declarations. --since enumerators have implemted as integer constants, so most of the functionality of gfc_data_decl has been used. writing a different function didnt seem appropriate to me, since this would have lead to a large amount of repeated code. Regards, Gaurav Gautam
Attachment:
changelog_code_20051016
Description: changelog_code_20051016
Attachment:
code_diff_20051016
Description: code_diff_20051016
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |