more fixes for gcc -fstrict-aliasing -Wall

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@7193 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
William S Fulton 2005-05-13 23:51:16 +00:00
commit 71646dcd81
4 changed files with 8 additions and 8 deletions

View file

@ -27,13 +27,13 @@ code is not functioning properly it will fail to compile.
%typemap(in) Animal ()
{
void *space_needed = malloc(HEIGHT_$1_lextype * WIDTH_$1_lextype);
$1 = 0;
$1 = space_needed;
}
%typemap(in) Animal[2] ()
{
void *space_needed = malloc(2 * HEIGHT_$1_lextype * WIDTH_$1_lextype);
$1 = 0;
$1 = space_needed;
}
%inline %{

View file

@ -72,7 +72,7 @@ struct Structure {
const std::string ConstMemberString;
static const std::string ConstStaticMemberString;
Structure() : ConstMemberString("const member string"), MemberString2("member string 2") {}
Structure() : MemberString2("member string 2"), ConstMemberString("const member string") {}
};
%}