日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當(dāng)前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

Ada 编程语言

發(fā)布時間:2023/12/15 编程问答 38 豆豆
生活随笔 收集整理的這篇文章主要介紹了 Ada 编程语言 小編覺得挺不錯的,現(xiàn)在分享給大家,幫大家做個參考.


以下內(nèi)容摘自wiki,http://zh.wikipedia.org/wiki/Ada


Ada,是一種程序設(shè)計語言。源于美國軍方的一個計劃,旨在整合美軍系統(tǒng)中運(yùn)行著上百種不同的程序設(shè)計語言編寫的程序,命名是為了紀(jì)念愛達(dá)·勒芙蕾絲而使用Ada。

目錄

[隱藏]
  • 1 重要特征
  • 2 歷史
  • 3 Ada語言的"世界,你好!" 示例程序
  • 4 關(guān)于阿利亞納五號的失敗
  • 5 參見
  • 6 參考書目
    • 6.1 國際標(biāo)準(zhǔn)
    • 6.2 書目
  • 7 Ada的百科
    • 7.1 總體信息
    • 7.2 輔助工具書
    • 7.3 工程
  • 8 注釋
  • 9 外部連接

[編輯] 重要特征

Ada語言最早是針對嵌入式和實(shí)時系統(tǒng)設(shè)計的,并且在今天依然在這方面使用廣泛。Ada95版,是由INTERMETRICS公司的塔克。塔夫特于92到95年間設(shè)計的,當(dāng)時主要是希望改進(jìn)對于 系統(tǒng),數(shù)字,財務(wù)軟件編程的支持。

Ada語言的重要特征就是其鍵入式風(fēng)格,模塊化設(shè)計,編譯檢查,平行處理,異常處理及泛型編程。Ada在95年加入了對面向?qū)ο笤O(shè)計的支持,包括動態(tài)分配等。

Ada的編譯檢查主要是針對沒有分配的內(nèi)存讀寫的保護(hù),堆棧溢出錯誤,單個錯誤空閑,隊列讀寫錯誤以及其他可以避免的小問題。這些檢查可以在為增加 效率的情況下被取消,但是在編譯的時候他們卻能帶來很高的效率。同樣它也包括對程序的嚴(yán)正的設(shè)置。因為這些原因,它被廣泛應(yīng)用于一些非常重要的系統(tǒng)中,例 如航空電子學(xué),武器及航天飛行器的操作系統(tǒng)中。

同樣它支持很多的編譯時間檢查,這些檢查被用來避免一些錯誤的發(fā)生。這種錯誤往往是在其他語言中在運(yùn)行以前都不能被察覺到的,需要在源碼中加入特殊的檢查設(shè)置才能被發(fā)現(xiàn)。

Ada的動態(tài)內(nèi)存管理非常安全和高規(guī)格,它類似于JAVA語言卻不同于C語言的。 這種特殊功能并不需要特殊的運(yùn)行設(shè)置。盡管這種語言的語意結(jié)構(gòu)允許對于不能讀寫的目標(biāo)進(jìn)行自動的碎片搜集,但是大多數(shù)運(yùn)行都不支持它。Ada卻支持有限形 式基于區(qū)域的存儲管理。無效的讀寫常在運(yùn)行時候被檢查出來(除非這種檢測被人為關(guān)閉)并且有時候在編譯時候就被發(fā)現(xiàn)。

Ada語言的定義同國際標(biāo)準(zhǔn)化組織(ISO)的標(biāo)準(zhǔn)有很大不同,因為他是一個自由內(nèi)容形式的。這種做法的后果是被廣大程序員只能從它的標(biāo)準(zhǔn)化文檔 (普遍認(rèn)為是Ada的參考使用手冊(ARM))尋找細(xì)節(jié)性的技術(shù)問題,但是普遍情況是一本標(biāo)準(zhǔn)教科書卻可以在其他不同語言上使用。

[編輯] 歷史

在70年代,美國國防部 因為它所屬項目的編程語言數(shù)量而倍受關(guān)注。這些語言中的很多都是完全獨(dú)立于硬件的,并且其中沒有一個是支持安全模塊編程的。1975年 高次階語言工作組 (HOLWG) 終于成立了。它的主要目標(biāo)就是尋找或者創(chuàng)造一些適合國防部需要的語言來減少這種現(xiàn)存的編程語言數(shù)量。它帶來的結(jié)果就是Ada語言。因此,這些編程語言數(shù)量從1983 的450下降到了1996的37種。

維基文庫中相關(guān)的原始文獻(xiàn): en:Steelman language requirements http://zh.wikisource.org/wiki/en:Steelman language requirements

工作組開發(fā)出了語言要求文檔—文檔。許多現(xiàn)存的語言都被仔細(xì)地檢查,但是1977年 這個團(tuán)隊卻聲稱沒有任何現(xiàn)存語言符合他們的條件。

[編輯] Ada語言的"世界,你好!" 示例程序

一個Ada語言編寫的"你好世界"Hello world program程序:

with Ada.Text_IO;

procedure Hello is
begin
Ada.Text_IO.Put_Line("Hello, world!");
end Hello;

在Ada.Text_IO.Put_Line處有一些快捷圖標(biāo),不需要很多的文字輸入,但是對于這里的理解來講并沒有多大意義。細(xì)節(jié)性的問題請參考Ada Programming/Basic。

[編輯] 關(guān)于阿利亞納五號的失敗

一個普遍的關(guān)于歐洲航天局阿利亞納五號火 箭失敗的說法是因為 Ada 語言在編譯過程的檢查失敗導(dǎo)致的。 將大的浮點(diǎn)數(shù)轉(zhuǎn)換成整數(shù)是一種常見的程序錯誤來源。1996年6月4日,對于Ariane 5火箭的初次航行來說,這樣一個錯誤產(chǎn)生了災(zāi)難性的后果。發(fā)射后僅僅37秒,火箭偏離它的飛行路徑,解體并爆炸了。火箭上載有價值5億美元的通信衛(wèi)星。6 億美元付之一炬。后來的調(diào)查顯示,控制慣性導(dǎo)航系統(tǒng)的計算機(jī)向控制引擎噴嘴的計算機(jī)發(fā)送了一個無效數(shù)據(jù)。失事調(diào)查報告指出,火箭爆炸是因為:

During execution of a data conversion from 64-bit floating point to 16-bit signed integer value, the floating point number which was converted had a value greater than what could be represented by a 16-bit signed integer. This resulted in an Operand Error.

它沒有發(fā)送飛行控制信息,而是送出了一個診斷位模式,表明在將一個64位浮點(diǎn)數(shù)轉(zhuǎn)換成16位有符號整數(shù)時,產(chǎn)生了溢出。 溢出值測量的是火箭的水平速率,這比早先的Ariane 4火箭所能達(dá)到的高出了5倍。在設(shè)計阿利亞納4火箭的軟件時,他們小心地分析了數(shù)字值,并且確定水平速率絕不會超出一個16位的數(shù)。不幸的是,他們在阿利 亞納5火箭的系統(tǒng)中簡單地重新使用了這一部分,而沒有檢查它所基于的假設(shè)。Ada代碼如下:

begin
sensor_get(vertical_veloc_sensor);
sensor_get(horizontal_veloc_sensor);
vertical_veloc_bias := integer(vertical_veloc_sensor);
horizontal_veloc_bias := integer(horizontal_veloc_sensor);
...
exception
when numeric_error => calculate_vertical_veloc();
when others => use_irs1();
end;

參考:阿利亞納五號

[編輯] 參見

[編輯] 參考書目

[編輯] 國際標(biāo)準(zhǔn)

  • ISO/IEC 8652:Information technology — Programming languages — Ada
  • ISO/IEC 15291:Information technology — Programming languages — Ada Semantic Interface Specification(ASIS)
  • ISO/IEC 18009:Information technology — Programming languages — Ada: Conformity assessment of a language processor(ACATS)
  • IEEE Standard 1003.5b-1996,the POSIX Ada binding
  • Ada Language Mapping Specification,the CORBA IDL to Ada mapping

[編輯] 書目

您可以在維基教科書中查找此百科條目的相關(guān)電子教程: Ada Programming
  • Jan Skansholm:Ada 95 From the Beginning, Addison-Wesley, ISBN 0-201-40376-5
  • John Barnes:Programming in Ada plus Language Reference Manual, Addison-Wesley, ISBN 0-201-56539-0
  • John Barnes:Programming in Ada 95, Addison-Wesley, ISBN 0-201-34293-6
  • John Barnes:High Integrity Ada: The SPARK Approach, Addison-Wesley, ISBN 0201175177
  • John Barnes:High Integrity Software: The SPARK Approach to Safety and Security, Addison-Wesley, ISBN 0-321-13616-0
  • Dean W. Gonzalez:Ada Programmer's Handbook, Benjamin-Cummings Publishing Company, ISBN 0805325298
  • M. Ben-Ari:Ada for Software Engineers, John Wiley & Sons, ISBN 0-471-97912-0
  • Norman Cohen:Ada as a Second Language, McGraw-Hill Science/Engineering/Math, ISBN 0-0-7011607-5
  • Alan Burns,Andy Wellings:Real-Time Systems and Programming Languages. Ada 95, Real-Time Java and Real-Time POSIX., Addison-Wesley, ISBN 0-201-72988-1
  • Alan Burns,Andy Wellings:Concurrency in Ada, Cambridge University Press, ISBN 0-521-62911-X
  • Colin Atkinson:Object-Oriented Reuse, Concurrency and Distribution: An Ada-Based Approach, Addison-Wesley, ISBN 0201565277
  • Grady Booch,Doug Bryan:Software Engineering with Ada, Addison-Wesley, ISBN 0805306080
  • Daniel Stubbs,Neil W. Webre:Data Structures with Abstract Data Types and Ada, Brooks Cole, ISBN 0-534-14448-9
  • Pascal Ledru:Distributed Programming in Ada with Protected Objects, Dissertation.com, ISBN 1-58112-034-6
  • Fintan Culwin:Ada, a Developmental Approach, Prentice Hall, ISBN 0132646803
  • John English,Fintan Culwin:Ada 95 the Craft of Object Oriented Programming, Prentice Hall, ISBN 0-1-3230350-7
  • David A. Wheeler:Ada 95, Springer-Verlag, ISBN 0-387-94801-5
  • David R. Musser,Alexander Stepanov:The Ada Generic Library: Linear List Processing Packages, Springer-Verlag, ISBN 0387971335
  • Michael B. Feldman:Software Construction and Data Structures with Ada 95, Addison-Wesley, ISBN 0201887959
  • Simon Johnston:Ada95 for C and C++ Programmers, Addison-Wesley, ISBN 0201403633
  • Michael B. Feldman,Elliot B. Koffman:Ada 95, Addison-Wesley, ISBN 0-201-36123-X
  • Nell Dale,Chip Weems,John McCormick:Programming and Problem Solving with Ada 95, Jones & Bartlett Publishers, ISBN 0763702935
  • Nell Dale,Susan Lilly,John McCormick:Ada Plus Data Structures: An Object-Based Approach, Jones & Bartlett Publishers, ISBN 0669416762
  • Bruce C. Krell:Developing With Ada: Life-Cycle Methods, Bantam Dell Pub Group, ISBN 0553091026
  • Judy Bishop:Distributed Ada: Developments and Experiences, Cambridge University Press, ISBN 0-521-39251-9
  • Bo Sanden:Software Systems Construction With Examples in Ada, Prentice Hall, ISBN 013030834X
  • Bruce Hillam:Introduction to Abstract Data Types Using Ada, Prentice Hall, ISBN 0130459496
  • David Rudd:Introduction to Software Design and Development With Ada, Brooks Cole, ISBN 0314028293
  • Ian C. Pyle:Developing Safety Systems: A Guide Using Ada, Prentice Hall, ISBN 0132042983
  • Louis Baker:Artificial Intelligence With Ada, McGraw-Hill, ISBN 0070033501
  • Alan Burns,Andy Wellings:HRT-HOOD: A Structured Design Method for Hard Real-Time Ada Systems, North-Holland, ISBN 0444821643
  • Walter Savitch, Charles Peterson:Ada: An Introduction to the Art and Science of Programming, Benjamin-Cummings Publishing Company, ISBN 0805370706
  • Mark Allen Weiss:Data Structures and Algorithm Analysis in Ada, Benjamin-Cummings Publishing Company, ISBN 0805390553

[編輯] Ada的百科

[編輯] 總體信息

  • Ada@Krischik

[編輯] 輔助工具書

  • Ada Programming
  • Programación en Ada
  • Programmation Ada

[編輯] 工程

  • AdaCL
  • wikibook-ada
  • ASIS
  • GLADE
  • Florist

[編輯] 注釋


[編輯] 外部連接

  • Ada World
  • AdaPower
  • ACM SIGAda
  • Ada-Europe Organization
  • Ada Information Clearinghouse
  • ISO Home of Ada Standards
  • Ada 95 Books Available Online
  • Ada Rapporteur Group (evolution of standard)
  • Ada Answers - Building better software with Ada
  • Ada Academic Initiative
  • "Libre" Ada Software
  • GNU Ada Homepage
  • GNAVI Ada Visual RAD
  • Citations from CiteSeer
  • GNAT
  • AdaGIDE, the Ada GNAT Integrated Development Environment for Windows
  • Forum
  • Ada Tutorial
  • Projects Using Ada
  • A#: Ada on .NET
  • Conference announcements for the international Ada community


補(bǔ)充說明:Ada語言很適合嵌入式應(yīng)用,高安全性,應(yīng)該值得關(guān)注!
請參照這個站點(diǎn):www.Ada-tech.com,這個套件包括Ada語言的編譯器及相應(yīng)的開發(fā)文檔和各種工具。
中文Ada語言資源網(wǎng):http://go8.163.com/wkh/
一個教程的中文站:http://all.163.com/it/school/apl/

總結(jié)

以上是生活随笔為你收集整理的Ada 编程语言的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網(wǎng)站內(nèi)容還不錯,歡迎將生活随笔推薦給好友。