aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/module.c
diff options
context:
space:
mode:
authorJanne Blomqvist <jb@gcc.gnu.org>2013-04-11 00:36:58 +0300
committerJanne Blomqvist <jb@gcc.gnu.org>2013-04-11 00:36:58 +0300
commit524af0d6c72031c249aa737945fde6ac3d726ba2 (patch)
tree3848fcd998968ff83378e8ad827c05578ce1d1fb /gcc/fortran/module.c
parent0ea8a6f9c72e6e8bf22a0f6da9295aed27e1ca1e (diff)
downloadgcc-524af0d6c72031c249aa737945fde6ac3d726ba2.zip
gcc-524af0d6c72031c249aa737945fde6ac3d726ba2.tar.gz
gcc-524af0d6c72031c249aa737945fde6ac3d726ba2.tar.bz2
Replace enum gfc_try with bool type.
2013-04-11 Janne Blomqvist <jb@gcc.gnu.org> * gfortran.h: Remove enum gfc_try, replace gfc_try with bool type. * arith.c: Replace gfc_try with bool type. * array.c: Likewise. * check.c: Likewise. * class.c: Likewise. * cpp.c: Likewise. * cpp.h: Likewise. * data.c: Likewise. * data.h: Likewise. * decl.c: Likewise. * error.c: Likewise. * expr.c: Likewise. * f95-lang.c: Likewise. * interface.c: Likewise. * intrinsic.c: Likewise. * intrinsic.h: Likewise. * io.c: Likewise. * match.c: Likewise. * match.h: Likewise. * module.c: Likewise. * openmp.c: Likewise. * parse.c: Likewise. * parse.h: Likewise. * primary.c: Likewise. * resolve.c: Likewise. * scanner.c: Likewise. * simplify.c: Likewise. * symbol.c: Likewise. * trans-intrinsic.c: Likewise. * trans-openmp.c: Likewise. * trans-stmt.c: Likewise. * trans-types.c: Likewise. From-SVN: r197682
Diffstat (limited to 'gcc/fortran/module.c')
-rw-r--r--gcc/fortran/module.c26
1 files changed, 11 insertions, 15 deletions
diff --git a/gcc/fortran/module.c b/gcc/fortran/module.c
index 814a40d..046ba48 100644
--- a/gcc/fortran/module.c
+++ b/gcc/fortran/module.c
@@ -555,8 +555,8 @@ gfc_match_use (void)
{
if ((m = gfc_match (" %n ::", module_nature)) == MATCH_YES)
{
- if (gfc_notify_std (GFC_STD_F2003, "module "
- "nature in USE statement at %C") == FAILURE)
+ if (!gfc_notify_std (GFC_STD_F2003, "module "
+ "nature in USE statement at %C"))
goto cleanup;
if (strcmp (module_nature, "intrinsic") == 0)
@@ -590,8 +590,7 @@ gfc_match_use (void)
{
m = gfc_match (" ::");
if (m == MATCH_YES &&
- gfc_notify_std (GFC_STD_F2003,
- "\"USE :: module\" at %C") == FAILURE)
+ !gfc_notify_std(GFC_STD_F2003, "\"USE :: module\" at %C"))
goto cleanup;
if (m != MATCH_YES)
@@ -658,9 +657,8 @@ gfc_match_use (void)
m = gfc_match (" =>");
if (type == INTERFACE_USER_OP && m == MATCH_YES
- && (gfc_notify_std (GFC_STD_F2003, "Renaming "
- "operators in USE statements at %C")
- == FAILURE))
+ && (!gfc_notify_std(GFC_STD_F2003, "Renaming "
+ "operators in USE statements at %C")))
goto cleanup;
if (type == INTERFACE_USER_OP)
@@ -4089,7 +4087,7 @@ load_generic_interfaces (void)
if (st && !sym->attr.generic
&& !st->ambiguous
&& sym->module
- && strcmp(module, sym->module))
+ && strcmp (module, sym->module))
{
ambiguous_set = true;
st->ambiguous = 1;
@@ -6096,10 +6094,9 @@ use_iso_fortran_env_module (void)
found = true;
u->found = 1;
- if (gfc_notify_std (symbol[i].standard, "The symbol '%s', "
- "referenced at %L, is not in the selected "
- "standard", symbol[i].name,
- &u->where) == FAILURE)
+ if (!gfc_notify_std (symbol[i].standard, "The symbol '%s', "
+ "referenced at %L, is not in the selected "
+ "standard", symbol[i].name, &u->where))
continue;
if ((gfc_option.flag_default_integer || gfc_option.flag_default_real)
@@ -6265,7 +6262,7 @@ gfc_use_module (gfc_use_list *module)
{
if (strcmp (module_name, "iso_fortran_env") == 0
&& gfc_notify_std (GFC_STD_F2003, "ISO_FORTRAN_ENV "
- "intrinsic module at %C") != FAILURE)
+ "intrinsic module at %C"))
{
use_iso_fortran_env_module ();
free_rename (module->rename);
@@ -6276,8 +6273,7 @@ gfc_use_module (gfc_use_list *module)
}
if (strcmp (module_name, "iso_c_binding") == 0
- && gfc_notify_std (GFC_STD_F2003,
- "ISO_C_BINDING module at %C") != FAILURE)
+ && gfc_notify_std (GFC_STD_F2003, "ISO_C_BINDING module at %C"))
{
import_iso_c_binding_module();
free_rename (module->rename);