Commit 5433e401 by Martin Liska Committed by Martin Liska

Fix small coding style issues (PR fortran/87394).

2018-09-25  Martin Liska  <mliska@suse.cz>

	PR fortran/87394
	* dbgcnt.c (dbg_cnt_process_single_pair): Return false
	instead of NULL.
	* dumpfile.c (dump_enable_all): Remove extra parenthesis.
	* gcov-tool.c: Declare the function with ATTRIBUTE_NORETURN.
	* godump.c (go_format_type): Remove extra parenthesis.
2018-09-25  Martin Liska  <mliska@suse.cz>

	PR fortran/87394
	* decl.c (add_hidden_procptr_result): Simplify condition
	as we are in branch witch 'case1 || case2'.

From-SVN: r264562
parent 72744f65
2018-09-25 Martin Liska <mliska@suse.cz> 2018-09-25 Martin Liska <mliska@suse.cz>
PR fortran/87394
* dbgcnt.c (dbg_cnt_process_single_pair): Return false
instead of NULL.
* dumpfile.c (dump_enable_all): Remove extra parenthesis.
* gcov-tool.c: Declare the function with ATTRIBUTE_NORETURN.
* godump.c (go_format_type): Remove extra parenthesis.
2018-09-25 Martin Liska <mliska@suse.cz>
* alias.c (set_dest_equal_p): Remove unused function. * alias.c (set_dest_equal_p): Remove unused function.
* config/i386/i386.c (def_builtin_pure2): Likewise. * config/i386/i386.c (def_builtin_pure2): Likewise.
* diagnostic-show-locus.c (class layout): Remove * diagnostic-show-locus.c (class layout): Remove
......
...@@ -138,7 +138,7 @@ dbg_cnt_process_single_pair (const char *arg) ...@@ -138,7 +138,7 @@ dbg_cnt_process_single_pair (const char *arg)
int high, low; int high, low;
if (value1 == NULL) if (value1 == NULL)
return NULL; return false;
if (value2 == NULL) if (value2 == NULL)
{ {
......
...@@ -1511,7 +1511,7 @@ dump_enable_all (dump_kind dkind, dump_flags_t flags, const char *filename) ...@@ -1511,7 +1511,7 @@ dump_enable_all (dump_kind dkind, dump_flags_t flags, const char *filename)
for (i = TDI_none + 1; i < (size_t) TDI_end; i++) for (i = TDI_none + 1; i < (size_t) TDI_end; i++)
{ {
if ((dump_files[i].dkind == dkind)) if (dump_files[i].dkind == dkind)
{ {
const char *old_filename = dump_files[i].pfilename; const char *old_filename = dump_files[i].pfilename;
dump_files[i].pstate = -1; dump_files[i].pstate = -1;
...@@ -1532,7 +1532,7 @@ dump_enable_all (dump_kind dkind, dump_flags_t flags, const char *filename) ...@@ -1532,7 +1532,7 @@ dump_enable_all (dump_kind dkind, dump_flags_t flags, const char *filename)
for (i = 0; i < m_extra_dump_files_in_use; i++) for (i = 0; i < m_extra_dump_files_in_use; i++)
{ {
if ((m_extra_dump_files[i].dkind == dkind)) if (m_extra_dump_files[i].dkind == dkind)
{ {
const char *old_filename = m_extra_dump_files[i].pfilename; const char *old_filename = m_extra_dump_files[i].pfilename;
m_extra_dump_files[i].pstate = -1; m_extra_dump_files[i].pstate = -1;
......
2018-09-25 Martin Liska <mliska@suse.cz> 2018-09-25 Martin Liska <mliska@suse.cz>
PR fortran/87394
* decl.c (add_hidden_procptr_result): Simplify condition
as we are in branch witch 'case1 || case2'.
2018-09-25 Martin Liska <mliska@suse.cz>
* trans.c (remove_suffix): Remove * trans.c (remove_suffix): Remove
unused function. unused function.
......
...@@ -6463,7 +6463,7 @@ add_hidden_procptr_result (gfc_symbol *sym) ...@@ -6463,7 +6463,7 @@ add_hidden_procptr_result (gfc_symbol *sym)
gfc_symtree *stree; gfc_symtree *stree;
if (case1) if (case1)
gfc_get_sym_tree ("ppr@", gfc_current_ns, &stree, false); gfc_get_sym_tree ("ppr@", gfc_current_ns, &stree, false);
else if (case2) else
{ {
gfc_symtree *st2; gfc_symtree *st2;
gfc_get_sym_tree ("ppr@", gfc_current_ns->parent, &stree, false); gfc_get_sym_tree ("ppr@", gfc_current_ns->parent, &stree, false);
......
...@@ -438,7 +438,7 @@ static const struct option overlap_options[] = ...@@ -438,7 +438,7 @@ static const struct option overlap_options[] =
/* Print overlap usage and exit. */ /* Print overlap usage and exit. */
static void static void ATTRIBUTE_NORETURN
overlap_usage (void) overlap_usage (void)
{ {
fnotice (stderr, "Overlap subcomand usage:"); fnotice (stderr, "Overlap subcomand usage:");
......
...@@ -961,7 +961,7 @@ go_format_type (struct godump_container *container, tree type, ...@@ -961,7 +961,7 @@ go_format_type (struct godump_container *container, tree type,
unions. */ unions. */
if (!is_anon_substructure) if (!is_anon_substructure)
{ {
if ((DECL_NAME (field) == NULL)) if (DECL_NAME (field) == NULL)
*p_art_i = go_append_artificial_name (ob, *p_art_i); *p_art_i = go_append_artificial_name (ob, *p_art_i);
else else
go_append_decl_name go_append_decl_name
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment