diff options
| author | toon <toon@138bc75d-0d04-0410-961f-82ee72b054a4> | 2003-01-03 22:02:29 +0000 |
|---|---|---|
| committer | toon <toon@138bc75d-0d04-0410-961f-82ee72b054a4> | 2003-01-03 22:02:29 +0000 |
| commit | 11056c49f9473cc8475f4d9c0a446528cfd2a8e7 (patch) | |
| tree | 07139f9fbcebfc9c33ff24e1d951d249292c28fe /gcc/f/ste.c | |
| parent | bdb2219e7e699db95907d0558c04676024db9560 (diff) | |
| download | ppe42-gcc-11056c49f9473cc8475f4d9c0a446528cfd2a8e7.tar.gz ppe42-gcc-11056c49f9473cc8475f4d9c0a446528cfd2a8e7.zip | |
2003-01-03 Bud Davis <bdavis11@directvinternet.com>
* stc.c (ffestc_R810): Allow any kind integer in
case statements.
* ste.c (ffeste_R810): Give error message when
case selector exceeds its valid values.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@60852 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/f/ste.c')
| -rw-r--r-- | gcc/f/ste.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/gcc/f/ste.c b/gcc/f/ste.c index d7d84954eef..a620acd1f15 100644 --- a/gcc/f/ste.c +++ b/gcc/f/ste.c @@ -1,5 +1,5 @@ /* ste.c -- Implementation File (module.c template V1.0) - Copyright (C) 1995, 1996, 2000, 2002 Free Software Foundation, Inc. + Copyright (C) 1995, 1996, 2000, 2002, 2003 Free Software Foundation, Inc. Contributed by James Craig Burley. This file is part of GNU Fortran. @@ -2725,7 +2725,15 @@ ffeste_R810 (ffestw block, unsigned long casenum) } else pushok = pushcase (texprlow, convert, tlabel, &duplicate); - assert (pushok == 0); + assert((pushok !=2) || (pushok !=0)); + if (pushok==2) + { + ffebad_start_msg ("SELECT (at %0) has duplicate cases -- check integer overflow of CASE(s)", + FFEBAD_severityFATAL); + ffebad_here (0, ffestw_line (block), ffestw_col (block)); + ffebad_finish (); + ffestw_set_select_texpr (block, error_mark_node); + } c = c->next_stmt; /* Unlink prev. */ c->previous_stmt->previous_stmt->next_stmt = c; |

