Trailing-Edge
-
PDP-10 Archives
-
AP-D480B-SB_1978
-
f72bnf.syn
There are 12 other files named f72bnf.syn in the archive. Click here to see a list.
100-310-044-03
DATE: DEC 18,1972
THE SYNTAX OF DECsystem-10 FORTRAN 72 IN EXTENDED BNF
JUNE 12,1972
AUTHORS: F. INFANTE , J. BELL , D. B. TOLMAN
VERSION 2
EDIT 1
THE INFORMATION IN THIS MEMORANDUM IS
SUBJECT TO CHANGE WITHOUT NOTICE AND
SHOULD NOT BE CONSTRUED AS A COMMITMENT
BY DIGITAL EQUIPEMENT CORPORATION .
;THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY ONLY BE USED
; OR COPIED IN ACCORDANCE WITH THE TERMS OF SUCH LICENSE.
;COPYRIGHT (C) 1974,1977 BY DIGITAL EQUIPMENT CORPORATION
; 100-310-044-03
PAGE 02
.
;THE COMPONENTS OF THE MODIFIED BNF SYNTAX USED IN THE PRODUCTIONS ON THE FOLLOWING PAGES .
BNFDEFINITION = METASYMBOL "=" BNFCOMPONENT [ COMMENT ] "." .
BNFCOMPONENT = ( TERMINAL l
METASYMBOL l
ONE l
ALL l
OPTION l
LIST l
REPEAT l
ACTION ) .
TERMINAL = """ *ALPHANUMERIC """ ;TERMINAL CHARACTER STRING .
METASYMBOL = [ *LETTER "-" ] *LETTER ;AN ELEMENT
OF THE SYNTAX DEFINED BY THE SYNTAX OR BY A LEXICAL
PROCESS .
ONE = "(" BNFCOMPONENT *[ "l" BNFCOMPONENT ] ")"
;ONLY ONE OF THE BNFCOMPONENTS IS REQUIRED .
ALL = BNFCOMPONENT *[ BNFCOMPONENT ] ;ALL OF THE
BNFCOMPONENTS ARE REQUIRED .
OPTION = "[" BNFCOMPONENT "]" ;USE OF THE BNFCOMPONENT IS
OPTIONAL .
LIST = "+" BNFCOMPONENT ;BNFCOMPONENTS SEPERATED BY
COMMAS .
REPEAT = "*" BNFCOMPONENT ;BNFCOMPONENTS NOT SEPERATED BY
COMMAS .
ACTION = "%" ACTIONNAME "%" ;ACTION TO BE PERFORMED WHEN ENCOUNTERED .
COMMENT = ";" *ASCIICHARACTER .
;*****************************************************************************************************************
; 100-310-044-03
PAGE 03
.
;FORTRAN-10 SYNTAX IN MODIFIED BNF .
EXPRESSION = %EXPRESS% .
VARIABLESPEC = IDENTIFIER %NOLABELS% [ LPAREN +%EXPRESS% RPAREN ] .
DATA = +( +DATAITEM VALUELIST ) LINEND .
;FORMAT = %FORMATSYN% .
; INTEGERSPEC = DECLARESPEC LINEND .
; REALSPEC = DECLARESPEC LINEND .
; LOGICALSPEC = DECLARESPEC LINEND .
; DOUBLEPRECISION = DECLARESPEC LINEND .
; COMPLEXSPEC = DECLARESPEC LINEND .
DECLARESPEC = ( FUNCTIONSPEC l TYPELIST ) LINEND .
FUNCTIONSPEC = %FUNCTIONSCAN% SUBPROGRAMID .
PARAMSPEC = +( IDENTIFIER EQUAL ( [ PLUS l MINUS ] CONSTLEX l LITSTRING ) ) LINEND .
; 100-310-044-03
PAGE 04
.
; PROGRAM = [ IDENTIFIER ] LINEND .
; BLOCKDATA = [ IDENTIFIER ] LINEND .
DIMENSION = +ONEARRAY LINEND .
SUBROUTINE = SUBPROGRAMID LINEND .
COMMON = *COMMONGROUP LINEND .
EQUIVALENCE = +( LPAREN VARIABLESPEC COMMA +VARIABLESPEC RPAREN ) LINEND .
EXTERNSPEC = +( [ ANDSGN l ASTERISK ] IDENTIFIER ) LINEND .
; INCLUDESPEC = LPAREN [ UNITSPEC COMMA ] ( LITSTRING l VARIABLESPEC ) RPAREN LINEND .
IMPLICIT = +( %TYPEID% LPAREN +%IMPLICITSPEC% RPAREN ) LINEND .
; PROTECT = +ONEARRAY LINEND .
; GLOBALSPEC = +ONEARRAY LINEND .
NAMELIST = *( SLASH IDENTIFIER SLASH +IDENTIFIER ) LINEND .
; IMPLICITSPEC = %LETTER% [ DASH %LETTER% ] .
;TYPEID = ( "SUBSCRIPTINTEGER" l "DOUBLEPRECISION" l
; ( "INTEGER" l "REAL" l "LOGICAL" l "COMPLEX" l "BIT" ) [ TIMES CONSTANT ] ) %SETTYPE% .
DATAITEM = ( VARIABLESPEC l LPAREN +DATAITEM [ LOOPPART ] RPAREN ) .
LOOPPART = EQUAL %EXPRESS% COMMA %EXPRESS% [ COMMA %EXPRESS% ] .
SUBPROGRAMID = IDENTIFIER %PNAMSET% [ LPAREN +( IDENTIFIER l ASTERISK l DOLLAR l ANDSGN ) RPAREN ] .
ONEARRAY = IDENTIFIER %ASTERTYPE% [
LPAREN +( [ PLUS l MINUS ] ( CONSTLEX l IDENTIFIER )
[ ( SLASH l COLON ) [ PLUS l MINUS ] ( CONSTLEX l IDENTIFIER ) ]
)
RPAREN ] .
TYPELIST = +( +ONEARRAY [ VALUELIST ] ) .
VALUELIST = SLASH +( [ PLUS l MINUS ]
( CONSTLEX [ TIMES ( [ PLUS l MINUS ] ( CONSTLEX l CMPLEXCON )
l LITSTRING
)
]
l CMPLEXCON
)
l LITSTRING
) SLASH .
CMPLEXCON = LPAREN [ PLUS l MINUS ] CONSTLEX COMMA [ PLUS l MINUS ] CONSTLEX RPAREN .
; 100-310-044-03
PAGE 05
.
COMMONGROUP = [ SLASH [ IDENTIFIER ] SLASH ] +ONEARRAY .
ASSIGN = %LABELS% LABELEX %TOQUOTE% VARIABLESPEC LINEND .
GOTO = %LABELS% ( LABELEX l GOTOSPEC ) LINEND .
CALL = IDENTIFIER [ LPAREN %EXPRLIST% RPAREN ] LINEND .
; RETURNSPEC = [ %EXPRESS% ] LINEND .
;CONTINUE = LINEND .
; STOP = [ LITSTRING l CONSTLEX ] LINEND .
; PAUSE = [ LITSTRING l CONSTLEX ] LINEND .
;END = LINEND .
RWSPEC = %LABELS% ( IOSPEC l FORMATID ) [ [ COMMA ] +DATAITEM ] LINEND .
IOSPEC1 = %LABELS% FORMATID [ COMMA +DATAITEM ] LINEND .
; ACCEPT = %LABELS% FORMATID [ COMMA +DATAITEM ] LINEND .
; PUNCH = %LABELS% FORMATID [ COMMA +DATAITEM ] LINEND .
; WRITESPEC = %LABELS% ( IOSPEC l FORMATID ) [ [ COMMA ] +DATAITEM ] LINEND .
; PRINT = %LABELS% FORMATID [ COMMA +DATAITEM ] LINEND .
; TYPESPEC = %LABELS% FORMATID [ COMMA +DATAITEM ] LINEND .
; ENCODE = ENCODECODESPEC LINEND .
; DECODE = ENCODECODESPEC LINEND .
; REREAD = %LABELS% FORMATID [ COMMA +DATAITEM ] LINEND .
; 100-310-044-03
PAGE 06
.
; BACKSPEC = UTILSPEC .
; REWIND = UTILSPEC .
; UNLOAD = UTILSPEC .
; ENDFILESPEC = UTILSPEC .
; SKIPSPEC = UTILSPEC .
; OPEN = LPAREN +( IDENTIFIER EQUAL ( VARIABLESPEC l CONSTANT l LITSTRING ) ) RPAREN LINEND .
; CLOSESPEC = LPAREN ( CONSTANT l VARIABLESPEC )
; *[ COMMA IDENTIFIER EQUAL ( VARIABLESPEC l LITSTRING ) ] RPAREN LINEND .
FIND = LPAREN ( CONSTLEX l IDENTIFIER ) %RECORDMARK% %EXPRESS% RPAREN LINEND .
IOSPEC = LPAREN UNITSPEC [ COMMA
+( %LABELS% ( LABELEX l IDENTIFIER [ EQUAL %NOLABELS% CONSTLEX ] l ASTERISK ) )
] RPAREN .
GOTOSPEC = ( VARIABLESPEC [ [ COMMA ] LPAREN +( %LABELS% LABELEX ) RPAREN ] l
LPAREN +( %LABELS% LABELEX ) RPAREN [ COMMA ] %EXPRESS% ) .
ENCODECODESPEC = LPAREN %EXPRESS% COMMA %LABELS% FORMATID COMMA VARIABLESPEC RPAREN [ +DATAITEM ] LINEND .
FORMATID = ( LABELEX l IDENTIFIER l ASTERISK ) .
; ACTUALARG = ( %EXPRESS% l DOLLAR CONSTLEX ) .
UNITSPEC = %NOLABELS% ( CONSTLEX l IDENTIFIER ) [ %RECORDMARK% EXPRESSION ] .
; REPEATEXPR = +( [ LPAREN ] ( CONSTLEX l VARIABLESPEC ) [ RPAREN ] [ LPAREN ( CONSTLEX l VARIABLESPEC ) RPAREN ] ) .
UTILSPEC = [ LPAREN ] +( CONSTLEX l VARIABLESPEC ) [ RPAREN ] LINEND .
; 100-310-044-03
PAGE 07
.
STATEFUNCSPEC = LPAREN +%SUBLOCAL% RPAREN EQUAL %EXPRESS% LINEND .
ARRAYASSIGNSPEC = LPAREN +%EXPRESS% RPAREN EQUAL %EXPRESS% LINEND .
LOGICALIFSPEC = LPAREN %EXPRESS% RPAREN .
ARITHIFSPEC = LPAREN %EXPRESS% RPAREN %LABELS% LABELEX COMMA %LABELS% LABELEX [ COMMA %LABELS% LABELEX ] LINEND .
ASSIGNSPEC = IDENTIFIER EQUAL %EXPRESS% LINEND .
DOSPEC = %LABELS% LABELEX IDENTIFIER EQUAL %EXPRESS% COMMA %EXPRESS% [ COMMA %EXPRESS% ] LINEND .