ImageVerifierCode 换一换
格式:PDF , 页数:42 ,大小:651.32KB ,
资源ID:545476      下载积分:10000 积分
快捷下载
登录下载
邮箱/手机:
温馨提示:
如需开发票,请勿充值!快捷下载时,用户名和密码都是您填写的邮箱或者手机号,方便查询和重复下载(系统自动生成)。
如填写123,账号就是123,密码也是123。
特别说明:
请自助下载,系统不会自动发送文件的哦; 如果您已付费,想二次下载,请登录后访问:我的下载记录
支付方式: 支付宝扫码支付 微信扫码支付   
注意:如需开发票,请勿充值!
验证码:   换一换

加入VIP,免费下载
 

温馨提示:由于个人手机设置不同,如果发现不能下载,请复制以下地址【http://www.mydoc123.com/d-545476.html】到电脑端继续下载(重复下载不扣费)。

已注册用户请登录:
账号:
密码:
验证码:   换一换
  忘记密码?
三方登录: 微信登录  

下载须知

1: 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。
2: 试题试卷类文档,如果标题没有明确说明有答案则都视为没有答案,请知晓。
3: 文件的所有权益归上传用户所有。
4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
5. 本站仅提供交流平台,并不能对任何下载内容负责。
6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

版权提示 | 免责声明

本文(BS 5905-1980 Specification for computer programming language CORAL 66《计算机程序设计语言CORAL66规范》.pdf)为本站会员(lawfemale396)主动上传,麦多课文库仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。 若此文所含内容侵犯了您的版权或隐私,请立即通知麦多课文库(发送邮件至master@mydoc123.com或直接QQ联系客服),我们立即给予删除!

BS 5905-1980 Specification for computer programming language CORAL 66《计算机程序设计语言CORAL66规范》.pdf

1、BRITISH STANDARD BS 5905:1980 Incorporating Amendment No. 1 Specification for Computer programming language CORAL 66 UDC 681.3.06CORAL 66BS5905:1980 This British Standard, having been prepared under the directionof the Data ProcessingStandards Committee,was published underthe authority ofthe Executi

2、ve Board and comes into effect on 31October1980 BSI 04-2000 The following BSI references relate to the work on this standard: Committee reference IST/5 Draft for comment 78/63605 DC ISBN 0 580 11442 2 Cooperating organizations The Data Processing Standards Committee, under whose direction this Briti

3、shStandard was prepared, consists of representatives from the following Government departments and scientific and industrial organizations: British Computer Society Ltd.* British Paper and Board Industry Federation (PIF) British Printing Industries Federation Business Equipment Trade Association* Ce

4、ntral Computer Agency (Civil Service Department)* Committee of London Clearing Bankers on behalf of the Committee of Scottish Clearing Bankers, Co-operative Bank, Central Trustee Savings Bank and Yorkshire Bank Department of Industry (Computers Systems and Electronics) Department of Industry (Nation

5、al Physical Laboratory)* Electricity Supply Industry in England and Wales* Government Communications Headquarters HM Customs and Excise Institute of Cost and Management Accountants Institute of Purchasing and Supply Institution of Electrical Engineers Institution of Mechanical Engineers Inter-univer

6、sity Committee on Computing London Transport Executive Ministry of Defence* National Computer Users Forum National Computing Centre Ltd.* National Research Development Corporation Post Office* Society of British Aerospace Companies Limited The organizations marked with an asterisk in the above list,

7、 together with the following, were directly represented on the committee entrusted with the preparation of this British Standard: Association for Literary and Linguistic Computing Association of Computer Units in Colleges of Higher Education (ACUCHE) British Gas Corporation Computing Services Associ

8、ation Control and Automation Manufacturers Association (BEAMA) Edinburgh Regional Computing Centre Engineering Equipment Users Association Hatfield Polytechnic University of London Amendments issued since publication Amd. No. Date of issue Comments 5079 October 1986 Indicated by a sideline in the ma

9、rginBS5905:1980 BSI 04-2000 i Contents Page Cooperating organizations Inside front cover Foreword ii 1 Scope 1 2 References 1 3 Definitions 1 4 Syntactic metalanguage 1 5 Compliance 2 5.1 Implementations 2 5.2 Programs 8 6 Requirements 8 6.1 The CORAL 66 program 8 6.2 Scoping 9 6.3 References to dat

10、a 10 6.4 Place references: switches 15 6.5 Expressions 15 6.6 Statements 19 6.7 Procedures 23 6.8 Communicators 26 6.9 Names and constants 27 6.10 Processing text in a program 29 6.11 List of language symbols and character set 30 6.12 Permissible options 31 Appendix A Unspecified features 33 Appendi

11、x B Implementation 33 Table 1 Alphabetical list of syntax rules 2 Table 2 Parameters of procedures 24 Table 3 Language words 30 Table 4 Other symbols 31 Publications referred to Inside back coverBS5905:1980 ii BSI 04-2000 Foreword This British Standard has been prepared under the direction of the Da

12、ta Processing Standards Committee and is based on the “Official definition of CORAL 66”, first published in1970 by Her Majestys Stationery Office, and reproduces material taken from that publication. This standard follows some ten years after the “Official definition” and the BSI committee believes

13、that the standard should not contain requirements incompatible with the very large number of existing implementations. For this reason, although a number of proposals for extensions of the language have been considered, their adoption has, in general, been reserved until a future revision of the sta

14、ndard. Two exceptions have, however, been made in this first edition: a) the number denotation HEX has been included (see6.9.2); b) the language words CORAL and SEGMENT have been included to give a formal syntax to a multisegment program (see6.1.3). Future revisions may make fuller provision for byt

15、e-addressable machines with a byte-oriented, but otherwise conformable, language definition. The current requirements assume a word-addressable virtual machine, but some provision for such byte-addressable machines is made inAppendix B. This standard aims to achieve an overall economy, in terms of h

16、uman effort, in the development of computer-based systems for real-time applications and to protect the interests of the user by encouraging the use of computers that comply with this standard. CORAL 66 provides a means of increasing the implementation efficiency of computer applications in environm

17、ents where the input/output communication requirements may not have been standardized and that are time-critical. CORAL66 is a kernel high-level computer language intended to replace a high proportion of assembly code in each specific application. Items not explicitly specified in this standard shou

18、ld be clearly understood as being unspecified. These unspecified items result from an original design objective that CORAL66 should favour all computer architectures as equally as possible and should allow implementors to exploit hardware features as efficiently as possible. The objective is to prom

19、ote the use of a common form of expression whenever it is expedient to do so. The language specification thus explicitly includes both the insertion of machine code statements and anonymous referencing, so as to ensure that special machine features and peripherals can be handled efficiently at the c

20、ost of reduced program portability. Furthermore, implementors are thus able to adopt the hardware conventions of the target machine with regard to numeric representation and computation. The parameterized macro facility enables the source text to retain a high level of readability. CORAL66 therefore

21、 aims to minimize, rather than to eliminate, the consequent machine dependency of programs and to maximize the portability of programming and software maintenance staff. It is virtually impossible to design a standard language such that programs will run with equally high efficiency in all types of

22、computer and in any applications. Much of the design of CORAL66 reflects this difficulty. For example, the language permits the use of non-standard “code statements” for any parts of a program where it may be important to exploit particular hardware facilities. A special feature is scaled fixed-poin

23、t arithmetic for use in small fixed-point machines; the floating-point facilities of the language can be omitted when hardware limitations make the use of floating-point arithmetic uneconomical. Other features can also be omitted without reducing the power of the language to an unacceptably low leve

24、l. Major features that may be omitted are listed in6.12.BS5905:1980 BSI 04-2000 iii A clear distinction needs to be made between general-purpose languages and more limited languages designed to incorporate the inbuilt assumptions of specialized applications or to make direct computer access practica

25、l for the non-specialist user. CORAL66 belongs to the first category. Languages in this class are suitable for writing compilers and interpreters as well as for direct application. Special-purpose languages can therefore be implemented by means of software written in CORAL66, backed up as required w

26、ith suites of specialized macros or procedures. It is largely for this reason that the facilities for using procedures have been kept as general as possible. The main differences between CORAL66 procedures and those of ALGOL60 lie in the replacement of the ALGOL60 dynamic “name parameter” by the mor

27、e efficient “location” or reference parameter used in FORTRAN, and the requirement to declare recursive procedures explicitly as such, again in the interest of object-code efficiency. The theory and structure of programming for real-time computer applications has not yet advanced to a point where a

28、particular choice of language facilities is inevitable. Furthermore, the design of real-time languages is handicapped by the lack of agreed standard software interfaces for applications programmers or compiler writers. This does not imply that real-time programs cannot yet be written in high-level l

29、anguage. The use of CORAL66 in real-time applications implies the presence of a supervisory system for the control of communications, which may have been designed independently of the compiler. The programmers control over external events, and the computers reaction to them, is expressed by the use

30、of procedures or macros that communicate with the outside world indirectly through the agency of the supervisory software. No requirements are specified in this standard regarding the names or action of such calls on the supervisor. Editorial note. It is normal convention in British Standards to use

31、 italic type for algebraic quantities. Since the status of such quantities contained in this standard may or may not directly represent true variable quantities, this convention has not been adopted in this standard. A British Standard does not purport to include all the necessary provisions of a co

32、ntract. Users of British Standards are responsible for their correct application. Compliance with a British Standard does not of itself confer immunity from legal obligations. Summary of pages This document comprises a front cover, an inside front cover, pages i to iv, pages1to 34, an inside back co

33、ver and a back cover. This standard has been updated (see copyright date) and may have had amendments incorporated. This will be indicated in the amendment table on the inside front cover.iv blankBS5905:1980 BSI 04-2000 1 1 Scope This British Standard specifies the semantics and syntax of the comput

34、er programming language CORAL66 by specifying requirements for a compiler and for a conforming program. NOTE 1Any feature that is not explicitly specified in this standard has been intentionally left unspecified. Appendix A lists some unspecified features. Appendix B gives additional information reg

35、arding implementation. NOTE 2The examples given among the specification requirements are not intended to add to or detract from the requirements, but are included purely to aid understanding. 2 References The titles of the publications referred to in this standard are listed on the inside back cover

36、. 3 Definitions For the purposes of this British Standard, the following definitions, together with those for other terms given in BS3527, apply. 3.1 layout characters the six “layout characters” and the space character specified in BS4730 3.2 printing characters the graphic characters specified in

37、BS4730 NOTETo draw attention to the language concepts, some terms are printed in italics on their first mention in this standard. 4 Syntactic metalanguage 1) The widespread use of syntax-driven methods of compilation lends increasing importance to syntax methods of language description. This standar

38、d specifies the syntax of CORAL66, and therefore starts with broad structure, working downwards to finer detail. For reasons of legibility, the customary Backus notation has been abandoned in favour of a system relying on typographical layout. Each syntax rule has on its left-hand side a class name,

39、 such as “Statement”. Such names appear in lower case without spaces, and with an initial capital letter. On the right-hand side of a rule are the various alternative expansions for the class name. These alternatives are either each printed on a new line or separated by “or”, as appropriate. Where a

40、 single alternative spreads over more than one line of print, the additional lines are inset in relation to the starting position of the alternative. Each alternative expansion consists of a sequence of items separated by spaces. The items themselves are either further class names or terminal symbol

41、s, such as BEGIN. The class name “Void” is used for an empty class. For example, a typical pair of rules might be Examples of specimens complying with these rules are ALPHA+ and BETA. The equals sign is used to separate the left-hand side from the right, except after its first appearance in a rule.

42、Certain constructs are defined informally in this standard; these are underlined. The syntax rules are listed inTable 1. 1) A British Standard syntactic metalanguage is at an early stage of preparation. Specimen = ALPHA Sign BETA Sign Sign = + p VoidBS5905:1980 2 BSI 04-2000 5 Compliance 5.1 Impleme

43、ntations 5.1.1 Any implementation of CORAL66 that can accept all of the features of the language specified in clause6 and with the meanings defined in clause6 complies with the requirements of this standard. 5.1.2 Except as specifically allowed by6.12, an implementation that omits any of the feature

44、s of the language specified in clause6 or that includes such a feature, but with a meaning altered in any way from that specified in clause6, does not comply with the requirements of this standard. Table 1 Alphabetical list of syntax rules Syntax rule Reference Absolutecommunicator = defined in a pa

45、rticular implementation to conform to the style of the commoncommunicator 6.8.5 Actual = Expression 6.6.4 Wordreference Destination Name Actuallist = Actual 6.6.4 Actual, Actuallist Addoperator = + 6.5.2 p Alternative = Statement 6.6.10 Answerspec = Numbertype 6.7.2 Void Answerstatement = ANSWER Exp

46、ression 6.6.5 Arraydec = Numbertype ARRAY Arraylist Presetlist 6.3.3 Arrayitem = Idlist Sizelist 6.3.3 Arraylist = Arrayitem 6.3.3 Arrayitem, Arraylist Assignmentstatement = Variable D Expression 6.6.2 Base = Id 6.3.8 Id Signedinteger Bitposition = Integer 6.3.4.3.1 Block = BEGIN Declist; Statementl

47、ist END 6.2.1 Booleanword = Booleanword2 6.5.4 Booleanword4 DIFFER Booleanword5 Booleanword2 = Booleanword3 6.5.4 Booleanword5 UNION Booleanword6 Booleanword3 = Booleanword6 MASK Typedprimary 6.5.4 Booleanword4 = Booleanword 6.5.4 Typedprimary Booleanword5 = Booleanword2 6.5.4 Typedprimary Booleanwo

48、rd6 = Booleanword3 6.5.4 Typedprimary Bracketedcomment = (any sequence of characters in which round brackets are matched) 6.10.3 Codesequence = defined in a particular implementation 6.6.6 Codestatement = CODE BEGIN Codesequence END 6.6.6BS5905:1980 BSI 04-2000 3 Table 1 Alphabetical list of syntax

49、rules Syntax rule Reference Commentsentence = COMMENT any sequence of characters not including a semicolon; 6.10.3 Commoncommunicator = COMMON (Commonitemlist) 6.8.2 Commonitem = Datadec 6.8.2 Overlaydec Placespec Procedurespec Void Commonitemlist = Commonitem 6.8.2 Commonitem; Commonitemlist Comparator = or s 6.5.6.2 Comparison = Simpleexpression Comparator Simpleexpression 6.5.6.2 Compoundstatement = BEGIN Statementlist END 6.6.7 Condition = Condition OR Subcondition 6.5.6.2 Subcondition Conditionalexpression = IF Condition 6.5.6.1 THEN Expression ELSE Exp

copyright@ 2008-2019 麦多课文库(www.mydoc123.com)网站版权所有
备案/许可证编号:苏ICP备17064731号-1