------------------------->  GNU Sather - sourcefile  <-------------------------
-- Copyright (C) 1995 by International Computer Science Institute            --
-- This file is part of the GNU Sather package. It is free software; you may --
-- redistribute  and/or modify it under the terms of the  GNU General Public --
-- License (GPL)  as  published  by the  Free  Software  Foundation;  either --
-- version 2 of the license, or (at your option) any later version.          --
-- This  program  is distributed  in the  hope that it will  be  useful, but --
-- WITHOUT ANY WARRANTY without even the implied warranty of MERCHANTABILITY --
-- or FITNESS FOR A PARTICULAR PURPOSE. See Doc/GPL for more details.        --
-- The license text is also available from:  Free Software Foundation, Inc., --
-- 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA                     --
-------------->  Please email comments to <bug-sather@gnu.org>  <--------------

-- test-cb.sa: Test c-to-sather callbacks
-- Author: Benedict A. Gomes <gomes@samosa.ICSI.Berkeley.EDU>

class TEST_CB is
   include TEST;
   
   main is
      class_name("External Callbacks");
      res ::= CALLBACK_TEST::sather_to_c_call(11);
      test("call",res,66);
      finish;
   end;
   
   
end; -- class TEST_CB
-------------------------------------------------------------------
external class CALLBACK_TEST is
   
   sather_to_c_call(num: INT): INT;
   -- Returns num+the value returned by c_to_sather_callback = num+55
   
   c_to_sather_callback: INT is return 55 end;
      
end;
-------------------------------------------------------------------
