Skip to content

AFNI/NIfTI Server

Sections
Personal tools
You are here: Home » AFNI » Documentation

Doxygen Source Code Documentation


Main Page   Alphabetical List   Data Structures   File List   Data Fields   Globals   Search  

error.c File Reference

#include "defs.h"

Go to the source code of this file.


Functions

void warni (char *s, int t)
void warn1 (char *s, char *t)
void warn (char *s)
void errstr (char *s, char *t)
void erri (char *s, int t)
void errl (char *s, long t)
void err (char *s)
void yyerror (char *s)
void dclerr (char *s, Namep v)
void execerr (char *s, char *n)
void Fatal (char *t)
void fatalstr (char *t, char *s)
void fatali (char *t, int d)
void badthing (char *thing, char *r, int t)
void badop (char *r, int t)
void badtag (char *r, int t)
void badstg (char *r, int t)
void badtype (char *r, int t)
void many (char *s, char c, int n)
void err66 (char *s)
void errext (char *s)

Variables

char * err_proc = 0

Function Documentation

void badop char *    r,
int    t
 

Definition at line 258 of file f2cdir/error.c.

References badthing(), and r.

Referenced by cktype(), fold(), mkexpr(), putch1(), putcx1(), putop(), and putx().

00260 {
00261         badthing("opcode", r, t);
00262 }

void badstg char *    r,
int    t
 

Definition at line 286 of file f2cdir/error.c.

References badthing(), and r.

Referenced by eqvcommon(), memname(), and mkaddr().

00288 {
00289         badthing("storage class", r, t);
00290 }

void badtag char *    r,
int    t
 

Definition at line 271 of file f2cdir/error.c.

References badthing(), and r.

Referenced by asg_addr(), awalk(), cpexpr(), fixexpr(), fixtype(), frexpr(), ioseta(), opconv_fudge(), out_args(), putch1(), putchcmp(), putcheq(), putconst(), putcx1(), putcxcmp(), putcxeq(), putmnmx(), and putx().

00273 {
00274         badthing("tag", r, t);
00275 }

void badthing char *    thing,
char *    r,
int    t
 

Definition at line 243 of file f2cdir/error.c.

References Fatal(), and r.

Referenced by badop(), badstg(), badtag(), badtype(), and ioseta().

00245 {
00246         char buff[50];
00247         sprintf(buff, "Impossible %s %d in routine %s", thing, t, r);
00248         Fatal(buff);
00249 }

void badtype char *    r,
int    t
 

Definition at line 300 of file f2cdir/error.c.

References badthing(), and r.

Referenced by consnegop(), conspower(), conssgn(), intrcall(), ioset(), lengtype(), mkconv(), mktmpn(), putconst(), retval(), and setdata().

00302 {
00303         badthing("type", r, t);
00304 }

void dclerr char *    s,
Namep    v
 

Definition at line 157 of file f2cdir/error.c.

References err, errstr(), and Nameblock::fvarname.

Referenced by dim_check(), docommon(), doentry(), doequiv(), eqvcommon(), exdo(), impldcl(), incomm(), mkfunct(), mkstfunct(), namelist(), newentry(), setbound(), setext(), setintr(), settype(), stfcall(), vardcl(), and yyparse().

00159 {
00160         char buff[100];
00161 
00162         if(v)
00163         {
00164                 sprintf(buff, "Declaration error for %s: %s", v->fvarname, s);
00165                 err(buff);
00166         }
00167         else
00168                 errstr("Declaration error %s", s);
00169 }

void err char *    s
 

Definition at line 123 of file f2cdir/error.c.

References err_proc.

00125 {
00126         if (err_proc)
00127                 fprintf(diagfile,
00128                         "Error processing %s before line %ld",
00129                         err_proc, lineno);
00130         else
00131                 fprintf(diagfile, "Error on line %ld", lineno);
00132         if (infname && *infname)
00133                 fprintf(diagfile, " of %s", infname);
00134         fprintf(diagfile, ": %s\n", s);
00135         fflush(diagfile);
00136         ++nerr;
00137 }

void err66 char *    s
 

Definition at line 329 of file f2cdir/error.c.

References errstr().

Referenced by intrcall().

00331 {
00332         errstr("Fortran 77 feature used: %s", s);
00333         --nerr;
00334 }

void errext char *    s
 

Definition at line 342 of file f2cdir/error.c.

References errstr().

Referenced by getcds(), gettok(), intrfunct(), mkname(), and setbound().

00344 {
00345         errstr("f2c extension used: %s", s);
00346         --nerr;
00347 }

void erri char *    s,
int    t
 

Definition at line 94 of file f2cdir/error.c.

References err.

Referenced by compgoto_out(), crunch(), do_p1_addr(), do_p1_comp_goto(), do_p1_name_pointer(), exdo(), expr_out(), gettok(), mktmpn(), negate_const(), op_assign(), out_const(), output_binary(), output_unary(), p1_addr(), p1_const(), p1_expr(), p1_unary(), putcall(), suboffset(), subskept(), wr_array_init(), wr_equiv_init(), wr_one_init(), wr_struct(), and yyparse().

00096 {
00097         char buff[100];
00098         sprintf(buff, s, t);
00099         err(buff);
00100 }

void errl char *    s,
long    t
 

Definition at line 108 of file f2cdir/error.c.

References err.

Referenced by do_p1_charp(), do_p1_const(), do_p1_expr(), do_p1_head(), do_p1_ident(), do_p1_set_line(), and wr_equiv_init().

00110 {
00111         char buff[100];
00112         sprintf(buff, s, t);
00113         err(buff);
00114 }

void errstr char *    s,
char *    t
 

Definition at line 79 of file f2cdir/error.c.

References err.

Referenced by argsort(), bad_dimtype(), badchleng(), builtin(), comblock(), dclerr(), duparg(), endproc(), eqvcommon(), err66(), errext(), exdo(), exenddo(), exequals(), getcd(), getkwd(), hexcheck(), intraddr(), intrcall(), ioclause(), iocname(), iosetip(), make_param(), mkaddr(), mkext(), mkfunct(), mkplace(), mkprim(), set_externs(), settype(), sserr(), stfcall(), subcheck(), suboffset(), unclassifiable(), wr_one_init(), and yyparse().

00081 {
00082         char buff[100];
00083         sprintf(buff, s, t);
00084         err(buff);
00085 }

void execerr char *    s,
char *    n
 

Definition at line 178 of file f2cdir/error.c.

References err.

Referenced by execlab(), exelif(), exelse(), exendif(), exstop(), fmtstmt(), newproc(), putcmgo(), and yyparse().

00180 {
00181         char buf1[100], buf2[100];
00182 
00183         sprintf(buf1, "Execution error %s", s);
00184         sprintf(buf2, buf1, n);
00185         err(buf2);
00186 }

void Fatal char *    t
 

Definition at line 194 of file f2cdir/error.c.

Referenced by Alloc(), autovar(), badthing(), c_name(), cds(), ckalloc(), consbinop(), conssgn(), do_format(), dofork(), doinclude(), fatali(), fatalstr(), findconst(), fixexpr(), flovflo(), get_argtypes(), intrcall(), list_init_data(), main(), many(), memno2info(), mkfunct(), nextdata(), out_addr(), popctl(), putch1(), putpower(), r8fix(), rdname(), start_formatting(), and zdiv().

00196 {
00197         fprintf(diagfile, "Compiler error line %ld", lineno);
00198         if (infname)
00199                 fprintf(diagfile, " of %s", infname);
00200         fprintf(diagfile, ": %s\n", t);
00201         done(3);
00202 }

void fatali char *    t,
int    d
 

Definition at line 227 of file f2cdir/error.c.

References Fatal().

Referenced by endioctl(), intraddr(), intrcall(), list_init_data(), mkfunct(), nextdata(), opconv_fudge(), and yylex().

00229 {
00230         char buff[100];
00231         sprintf(buff, t, d);
00232         Fatal(buff);
00233 }

void fatalstr char *    t,
char *    s
 

Definition at line 212 of file f2cdir/error.c.

References Fatal().

Referenced by def_commons(), ind_printf(), intraddr(), main(), mkfunct(), and opf().

00214 {
00215         char buff[100];
00216         sprintf(buff, t, s);
00217         Fatal(buff);
00218 }

void many char *    s,
char    c,
int    n
 

Definition at line 313 of file f2cdir/error.c.

References c, and Fatal().

Referenced by contmax(), mkext1(), mklabel(), mkname(), pushctl(), putconst(), write_char_init(), and yyparse().

00315 {
00316         char buff[250];
00317 
00318         sprintf(buff,
00319             "Too many %s.\nTable limit now %d.\nTry rerunning with the -N%c%d option.\n",
00320             s, n, c, 2*n);
00321         Fatal(buff);
00322 }

void warn char *    s
 

Definition at line 59 of file f2cdir/error.c.

Referenced by atype_squawk(), changedtype(), exdo(), expr_out(), exreturn(), main(), mixed_type(), mkconv(), mkexpr(), mkfunct(), p1_expr(), setfmt(), warn1(), warni(), and yyparse().

00061 {
00062         if(nowarnflag)
00063                 return;
00064         if (infname && *infname)
00065                 fprintf(diagfile, "Warning on line %ld of %s: %s\n",
00066                         lineno, infname, s);
00067         else
00068                 fprintf(diagfile, "Warning on line %ld: %s\n", lineno, s);
00069         fflush(diagfile);
00070         ++nwarn;
00071 }

void warn1 char *    s,
char *    t
 

Definition at line 46 of file f2cdir/error.c.

References warn().

Referenced by backup(), do_init_data(), dobss(), docomleng(), execlab(), intrcall(), setdata(), setfmt(), wronginf(), and yyparse().

00048 {
00049         char buff[100];
00050         sprintf(buff, s, t);
00051         warn(buff);
00052 }

void warni char *    s,
int    t
 

Definition at line 32 of file f2cdir/error.c.

References warn().

Referenced by doequiv(), set_externs(), and setfmt().

00034 {
00035         char buf[100];
00036         sprintf(buf,s,t);
00037         warn(buf);
00038         }

void yyerror char *    s
 

Definition at line 144 of file f2cdir/error.c.

References err.

Referenced by yyparse().

00146 {
00147         err(s);
00148 }

Variable Documentation

char* err_proc = 0
 

Definition at line 116 of file f2cdir/error.c.

Referenced by enddcl(), and err().

 

Powered by Plone

This site conforms to the following standards: