Commit 9953ace9 authored by julien.delange's avatar julien.delange

backends previous jerome changes



git-svn-id: https://tecsw.estec.esa.int/svn/taste/trunk/po-hi-ada@673 129961e7-ef38-4bb5-a8f7-c9a525a55882
parent 1ea62818
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
-- -- -- --
-- B o d y -- -- B o d y --
-- -- -- --
-- Copyright (C) 2009, GET-Telecom Paris. -- -- Copyright (C) 2009-2010, GET-Telecom Paris. --
-- -- -- --
-- PolyORB HI is free software; you can redistribute it and/or modify it -- -- PolyORB HI is free software; you can redistribute it and/or modify it --
-- under terms of the GNU General Public License as published by the Free -- -- under terms of the GNU General Public License as published by the Free --
...@@ -59,8 +59,8 @@ package body PolyORB_HI.Utils is ...@@ -59,8 +59,8 @@ package body PolyORB_HI.Utils is
-- Swap_Bytes -- -- Swap_Bytes --
---------------- ----------------
function Swap_Bytes (B : Interfaces.Unsigned_16) function Swap_Bytes (B : Interfaces.Integer_16)
return Interfaces.Unsigned_16 return Interfaces.Integer_16
is is
use System; use System;
begin begin
...@@ -86,7 +86,7 @@ package body PolyORB_HI.Utils is ...@@ -86,7 +86,7 @@ package body PolyORB_HI.Utils is
function Internal_Code (P : Port_Type) return Unsigned_16 is function Internal_Code (P : Port_Type) return Unsigned_16 is
function To_Internal_Code is new Ada.Unchecked_Conversion function To_Internal_Code is new Ada.Unchecked_Conversion
(Port_Type, Unsigned_16); (Port_Type, Integer_16);
begin begin
return Swap_Bytes (To_Internal_Code (P)); return Swap_Bytes (To_Internal_Code (P));
end Internal_Code; end Internal_Code;
...@@ -95,9 +95,9 @@ package body PolyORB_HI.Utils is ...@@ -95,9 +95,9 @@ package body PolyORB_HI.Utils is
-- Corresponding_Port -- -- Corresponding_Port --
------------------------ ------------------------
function Corresponding_Port (I : Unsigned_16) return Port_Type is function Corresponding_Port (I : Integer_16) return Port_Type is
function To_Corresponding_Port is new Ada.Unchecked_Conversion function To_Corresponding_Port is new Ada.Unchecked_Conversion
(Unsigned_16, Port_Type); (Integer_16, Port_Type);
begin begin
return To_Corresponding_Port (Swap_Bytes (I)); return To_Corresponding_Port (Swap_Bytes (I));
end Corresponding_Port; end Corresponding_Port;
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
-- -- -- --
-- S p e c -- -- S p e c --
-- -- -- --
-- Copyright (C) 2007-2009, GET-Telecom Paris. -- -- Copyright (C) 2007-2010, GET-Telecom Paris. --
-- -- -- --
-- PolyORB HI is free software; you can redistribute it and/or modify it -- -- PolyORB HI is free software; you can redistribute it and/or modify it --
-- under terms of the GNU General Public License as published by the Free -- -- under terms of the GNU General Public License as published by the Free --
...@@ -70,10 +70,10 @@ package PolyORB_HI.Utils is ...@@ -70,10 +70,10 @@ package PolyORB_HI.Utils is
(Integer_8, Node_Type); (Integer_8, Node_Type);
function Internal_Code (P : Port_Type) return Unsigned_16; function Internal_Code (P : Port_Type) return Unsigned_16;
function Corresponding_Port (I : Unsigned_16) return Port_Type; function Corresponding_Port (I : Integer_16) return Port_Type;
function Swap_Bytes (B : Interfaces.Unsigned_16) function Swap_Bytes (B : Interfaces.Integer_16)
return Interfaces.Unsigned_16; return Interfaces.Integer_16;
-- Swap bytes iff the host is little endian. This function is -- Swap bytes iff the host is little endian. This function is
-- notionnally equivalent to htons(). -- notionnally equivalent to htons().
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment