cnotes9 - Copyright c Nancy Leveson, Sept. 1999 Programming...

Info iconThis preview shows pages 1–6. Sign up to view the full content.

View Full Document Right Arrow Icon
Copyright c Nancy Leveson, Sept. 1999 Programming Languages As difficult to discuss rationally as religion or politics. Prone to extreme statements devoid of data. Examples: "It is practically impossible to teach good programming to students that have had a prior exposure to BASIC; as potential programmers they are mentally mutilated beyond hope of regeneration." (Dijkstra) "The use of COBOL cripples the mind; its teaching should, therefore, be regarded as a criminal offence." (Dijkstra) Like anything else, decision making should be a rational process based on the priorities and features of the project.
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Copyright c Nancy Leveson, Sept. 1999 Some Decision Factors Features of application: Hard real time? Not just efficiency Predictability (need to guarantee deadlines will be met) High assurance? Portability? Maintainability? Others? Features of development environment: Availability of programmers, compilers, development tools? Schedule constraints? Others?
Background image of page 2
Copyright c Nancy Leveson, Sept. 1999 Relationship between PL and Correctness Decreasing emphasis as an explicit design goal and research topic. Masterability Not complex: programmers understand it in its entirety The most important decisions in language design concern what is to be left out." (Wirth) Powerful features OK only if easy to use correctly. Balance against need to keep language simple "Natural" Language should not surprise us in any of its effects. Should correspond to our experience with natural languages, mathematics, and other PLs
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Copyright c Nancy Leveson, Sept. 1999 Relationship between PL and Correctness (2) Error Proneness Language design should prevent errors. Should be difficult or impossible to write an incorrect program. If not possible, then allow their detection (as early as possible) Need for general principles and hypotheses so can predict error-prone features and improve language design. Some hypotheses and data about: Go to Global variables Pointers Selection by position (long parameter lists) Defaults and implicit type conversion Attempts to interpret intentions or fix errors Meaning of features should be precisely defined (not dependent on compiler.
Background image of page 4
Copyright c Nancy Leveson, Sept. 1999 Relationship between PL and Correctness (3) Understandability "The primary goal of a programming language is accurate communication among humans." Readability more important than writeability.
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 6
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 15

cnotes9 - Copyright c Nancy Leveson, Sept. 1999 Programming...

This preview shows document pages 1 - 6. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online