I would like to be able to predict what will happen in the resulting binary when I call Write in Ada to serialize the record. Do you know where I can watch this?
I have outdated Ada software that creates a binary file by writing a record, and I need to debug a C ++ program that needs to write a compatible binary file. So, I would like to understand what Ada rules follow when it serializes a record, so that I can make sure that the C ++ code will create a functionally equivalent record.
, . . , Ada . , , . , .
"Write" .
, , , ( ). GNAT ( GCC Ada) .
, "Write ". XML.
, , pragma PACK pragma PRESERVE_LAYOUT . , . :
: 8, 16 32 -
Float: 32- IEEE
Long_Float: 64- IEEE
: 8, 16 32 ; 16 32
: Integer, 0
Booleans: , 8 , LSB : 0 = false, 1 = true
: , 8 , 0 127
: 32 , 32- 0 NULL
: , . , .
Ada95 ( 13.13.2):
"For elementary types, the representation in terms of stream elements is determined by the implementation. For composite types, the Write or Read attribute for each component is invoked in canonical order. The canonical order of components is the last size, the fastest for an array, and the positional aggregate order for writing."
Source: https://habr.com/ru/post/1697056/More articles:Subscription options in SQL Server Reporting Services 2005 - sql-serverIs there any other way to integrate PDF viewing in a Flex application? - flexhttps://translate.googleusercontent.com/translate_c?depth=1&pto=aue&rurl=translate.google.com&sl=ru&sp=nmt4&tl=en&u=https://fooobar.com/questions/1697053/mysqldump-mysql-yields-too-many-open-files-error-why&usg=ALkJrhhd9BShzURqKBIx5-qqW__2P3NpXwC ++ class design from database schema - c ++https://translate.googleusercontent.com/translate_c?depth=1&pto=aue&rurl=translate.google.com&sl=ru&sp=nmt4&tl=en&u=https://fooobar.com/questions/1697055/is-there-a-macro-to-conditionally-copy-rows-to-another-worksheet&usg=ALkJrhhqEytJRjZMzY0XfCmZhTWdfgehPgFlex time analysis - dateHow to transfer a virtual machine from VMWare to VirtualBox? - virtualboxRich Edit Control in raw Win32 - windowsОграничение результатов System.Data.Linq.Table - linq-to-sqlWhat is the best way to find out the RESTful server code? - restAll Articles