Created
July 15, 2014 00:41
-
-
Save kjseefried/32815c65dc88b106deed to your computer and use it in GitHub Desktop.
Example to convert an ada vector to a c vector
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type Index is range 1 .. 3; | |
type Ada_Vector is array (Index) of Float; | |
type C_Vector is array (Index) of C_Float; | |
function To_C (Item : in Ada_Vector) return C_Vector is | |
begin | |
return Result : C_Vector do | |
for I in Index loop | |
Result (I) := C_Float (Item (I)); | |
end loop; | |
end return; | |
end To_C; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment