/[MITgcm]/mitgcm.org/devel/buildweb/code-browser/F90Mapper/F90sym.y
ViewVC logotype

Annotation of /mitgcm.org/devel/buildweb/code-browser/F90Mapper/F90sym.y

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (hide annotations) (download)
Fri Sep 20 19:47:31 2002 UTC (22 years, 9 months ago) by adcroft
Branch point for: Import, MAIN
Initial revision

1 adcroft 1.1 /* F90 program symbol/call tree lister */
2     %{
3     int Lno; char *currentFile;
4     %}
5    
6     %union {
7     int LineNo;
8     char *symbolName;
9     }
10    
11     %token <LineNo> OTHER
12     %token <symbolName> NAME
13     %token <LineNo> SUBROUTINE
14     %token <LineNo> EXTERNAL
15     %token <LineNo> CALL
16     %token <LineNo> NAMELIST
17     %token <LineNo> FSLASH
18     %token <LineNo> CPP_IFDEF
19     %token <LineNo> CPP_IFNDEF
20     %token <LineNo> CPP_DEFINE
21     %token <LineNo> CPP_UNDEF
22     %token <LineNo> CPP_ELIF
23     %token <LineNo> CPP_IF
24     %type <LineNo> call
25    
26     %%
27    
28     input: /* empty */
29     | input NAME {noteVariable($2,Lno,currentFile);}
30     | input SUBROUTINE NAME {noteProcDef($3,Lno,currentFile); }
31     | input call NAME {noteProcCall($3,Lno,currentFile);}
32     | input EXTERNAL NAME {noteExtDef($3,Lno,currentFile); }
33     | input NAMELIST FSLASH
34     NAME FSLASH {noteInNameList($4,Lno,currentFile); }
35     | input CPP_IFDEF {noteInIfdef(); }
36     | input CPP_IFNDEF {noteInIfdef(); }
37     | input CPP_DEFINE {noteInIfdef(); }
38     | input CPP_UNDEF {noteInIfdef(); }
39     | input CPP_ELIF {noteInIfdef(); }
40     | input CPP_IF {noteInIfdef(); }
41     | input FSLASH
42     | input OTHER
43     | input error { yyerrok; }
44     ;
45     call: CALL { $$ = $1; }
46     ;
47     %%

  ViewVC Help
Powered by ViewVC 1.1.22