Hi,

    I am new to swig, am using swig for the calling C++ function in Perl.

 

In C++ I have a function that can throw the Exception eg int s() throw(MyException).

 

I have Test.i eg

 

%module Test

 %{

 /* Put header files here or function declarations like below */

 extern int s() throw(MyException);

 

 %}

 

 extern int s() throw(MyException);

 

when I am running the following command :-

 

swig -perl5 Test.i

 

Following error message is coming

 

Test.i:9: Error: Syntax error in input(1).

 

When I have the following entry in the Test.i

 

%module Test

 %{

 /* Put header files here or function declarations like below */

 extern int s() throw(MyException);

 

 %}

 

 extern int s() ;

 

Now running the following command :-

 

swig -perl5 Test.i

 

It generate all the files,without any error.

 

Why is it so,Please guide me!

 

Any help is highly appreciated.

 

Thanks

Ashish

 

 

 

 

DISCLAIMER:
-----------------------------------------------------------------------------------------------------------------------

The contents of this e-mail and any attachment(s) are confidential and intended for the named recipient(s) only. 
It shall not attach any liability on the originator or HCL or its affiliates. Any views or opinions presented in 
this email are solely those of the author and may not necessarily reflect the opinions of HCL or its affiliates. 
Any form of reproduction, dissemination, copying, disclosure, modification, distribution and / or publication of 
this message without the prior written consent of the author of this e-mail is strictly prohibited. If you have 
received this email in error please delete it and notify the sender immediately. Before opening any mail and 
attachments please check them for viruses and defect.

-----------------------------------------------------------------------------------------------------------------------