dotgnu-pnet-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Dotgnu-pnet-commits] CVS: pnet/codegen cg_coerce.c,1.14,1.15 cg_coerce.


From: Gopal.V <address@hidden>
Subject: [Dotgnu-pnet-commits] CVS: pnet/codegen cg_coerce.c,1.14,1.15 cg_coerce.h,1.15,1.16
Date: Fri, 15 Nov 2002 21:45:34 -0500

Update of /cvsroot/dotgnu-pnet/pnet/codegen
In directory subversions:/tmp/cvs-serv17358/codegen

Modified Files:
        cg_coerce.c cg_coerce.h 
Log Message:
indirect checks for ILCoerce* and ILCast* functions 


Index: cg_coerce.c
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/codegen/cg_coerce.c,v
retrieving revision 1.14
retrieving revision 1.15
diff -C2 -r1.14 -r1.15
*** cg_coerce.c 16 Nov 2002 01:02:30 -0000      1.14
--- cg_coerce.c 16 Nov 2002 02:45:32 -0000      1.15
***************
*** 573,578 ****
                        argType=ILTypeGetParam(signature,1);
  
!                       if(ILCanCoerce(info,returnType,toType,0) && 
!                               ILCanCoerce(info,fromType,argType,0))
                        {
                                if(itype1)(*itype1)=argType;
--- 573,578 ----
                        argType=ILTypeGetParam(signature,1);
  
!                       if(ILCanCoerceKind(info,returnType,toType,kinds,0) && 
!                               ILCanCoerceKind(info,fromType,argType,kinds,0))
                        {
                                if(itype1)(*itype1)=argType;
***************
*** 614,619 ****
                        argType=ILTypeGetParam(signature,1);
  
!                       if(ILCanCoerce(info,returnType,toType,0) && 
!                               ILCanCoerce(info,fromType,argType,0))
                        {
                                if(itype1)(*itype1)=argType;
--- 614,619 ----
                        argType=ILTypeGetParam(signature,1);
  
!                       if(ILCanCoerceKind(info,returnType,toType,kinds,0) && 
!                               ILCanCoerceKind(info,fromType,argType,kinds,0))
                        {
                                if(itype1)(*itype1)=argType;
***************
*** 801,805 ****
  
  int ILCanCoerceKind(ILGenInfo *info, ILType *fromType,
!                                       ILType *toType, int kinds)
  {
        ConvertRules rules;
--- 801,805 ----
  
  int ILCanCoerceKind(ILGenInfo *info, ILType *fromType,
!                                       ILType *toType, int kinds,int indirect)
  {
        ConvertRules rules;
***************
*** 809,813 ****
                return 1;
        }
!       else if(GetIndirectConvertRules(info,fromType,toType,0, 
                                                        
kinds,&rules,&rules2,NULL,NULL))
        {
--- 809,813 ----
                return 1;
        }
!       else if(indirect && GetIndirectConvertRules(info,fromType,toType,0, 
                                                        
kinds,&rules,&rules2,NULL,NULL))
        {
***************
*** 818,822 ****
  
  int ILCanCoerceNode(ILGenInfo *info, ILNode *node,
!                                   ILType *fromType, ILType *toType)
  {
        ConvertRules rules;
--- 818,822 ----
  
  int ILCanCoerceNode(ILGenInfo *info, ILNode *node,
!                                   ILType *fromType, ILType *toType, int 
indirect)
  {
        ConvertRules rules;
***************
*** 830,834 ****
                return 1;
        }
!       else if(GetIndirectConvertRules(info,fromType,toType,0, 
                                                        
IL_CONVERT_ALL,&rules,&rules2,NULL,NULL))
        {
--- 830,834 ----
                return 1;
        }
!       else if(indirect && GetIndirectConvertRules(info,fromType,toType,0, 
                                                        
IL_CONVERT_ALL,&rules,&rules2,NULL,NULL))
        {
***************
*** 842,846 ****
  
  int ILCanCoerceNodeKind(ILGenInfo *info, ILNode *node,
!                                       ILType *fromType, ILType *toType, int 
kinds)
  {
        ConvertRules rules;
--- 842,847 ----
  
  int ILCanCoerceNodeKind(ILGenInfo *info, ILNode *node,
!                                       ILType *fromType, ILType *toType, int 
kinds,
!                                               int indirect)
  {
        ConvertRules rules;
***************
*** 855,859 ****
                return 1;
        }
!       else if(GetIndirectConvertRules(info,fromType,toType,0, 
                                                        
kinds,&rules,&rules2,NULL,NULL))
        {
--- 856,860 ----
                return 1;
        }
!       else if(indirect && GetIndirectConvertRules(info,fromType,toType,0, 
                                                        
kinds,&rules,&rules2,NULL,NULL))
        {
***************
*** 867,871 ****
  
  int ILCoerce(ILGenInfo *info, ILNode *node, ILNode **parent,
!                        ILType *fromType, ILType *toType)
  {
        ConvertRules rules;
--- 868,872 ----
  
  int ILCoerce(ILGenInfo *info, ILNode *node, ILNode **parent,
!                        ILType *fromType, ILType *toType,int indirect)
  {
        ConvertRules rules;
***************
*** 884,892 ****
                return 1;
        }
!       else if(GetIndirectConvertRules(info,fromType,toType,0, 
                                                        
IL_CONVERT_ALL,&rules,&rules2,&t1,&t2))
        {
                ApplyRules(info, node, parent, &rules, t1);
!               ILCoerce(info,*parent,parent,t1,t2);
                ApplyRules(info, *parent, parent, &rules2, toType);
                return 1;
--- 885,893 ----
                return 1;
        }
!       else if(indirect && GetIndirectConvertRules(info,fromType,toType,0, 
                                                        
IL_CONVERT_ALL,&rules,&rules2,&t1,&t2))
        {
                ApplyRules(info, node, parent, &rules, t1);
!               ILCoerce(info,*parent,parent,t1,t2,0);
                ApplyRules(info, *parent, parent, &rules2, toType);
                return 1;
***************
*** 899,903 ****
  
  int ILCoerceKind(ILGenInfo *info, ILNode *node, ILNode **parent,
!                            ILType *fromType, ILType *toType, int kinds)
  {
        ConvertRules rules;
--- 900,904 ----
  
  int ILCoerceKind(ILGenInfo *info, ILNode *node, ILNode **parent,
!                            ILType *fromType, ILType *toType, int kinds,int 
indirect)
  {
        ConvertRules rules;
***************
*** 917,925 ****
                return 1;
        }
!       else if(GetIndirectConvertRules(info,fromType,toType,0, 
                                                                
kinds,&rules,&rules2,&t1,&t2))
        {
                ApplyRules(info, node, parent, &rules, t1);
!               ILCoerceKind(info,*parent,parent,t1,t2,kinds);
                ApplyRules(info, *parent, parent, &rules, toType);
                return 1;
--- 918,926 ----
                return 1;
        }
!       else if(indirect && GetIndirectConvertRules(info,fromType,toType,0, 
                                                                
kinds,&rules,&rules2,&t1,&t2))
        {
                ApplyRules(info, node, parent, &rules, t1);
!               ILCoerceKind(info,*parent,parent,t1,t2,kinds,0);
                ApplyRules(info, *parent, parent, &rules, toType);
                return 1;
***************
*** 931,935 ****
  }
  
! int ILCanCast(ILGenInfo *info, ILType *fromType, ILType *toType)
  {
        ConvertRules rules;
--- 932,936 ----
  }
  
! int ILCanCast(ILGenInfo *info, ILType *fromType, ILType *toType,int indirect)
  {
        ConvertRules rules;
***************
*** 939,943 ****
                return 1;
        }
!       else if(GetIndirectConvertRules(info,fromType,toType,0, 
                                                        
IL_CONVERT_ALL,&rules,&rules2,NULL,NULL))
        {
--- 940,944 ----
                return 1;
        }
!       else if(indirect && GetIndirectConvertRules(info,fromType,toType,0, 
                                                        
IL_CONVERT_ALL,&rules,&rules2,NULL,NULL))
        {
***************
*** 948,952 ****
  
  int ILCanCastKind(ILGenInfo *info, ILType *fromType,
!                                 ILType *toType, int kinds)
  {
        ConvertRules rules;
--- 949,953 ----
  
  int ILCanCastKind(ILGenInfo *info, ILType *fromType,
!                                 ILType *toType, int kinds,int indirect)
  {
        ConvertRules rules;
***************
*** 956,960 ****
                return 1;
        }
!       else if(GetIndirectConvertRules(info,fromType,toType,0, 
                                                                        
kinds,&rules,&rules2,NULL,NULL))
        {
--- 957,961 ----
                return 1;
        }
!       else if(indirect && GetIndirectConvertRules(info,fromType,toType,0, 
                                                                        
kinds,&rules,&rules2,NULL,NULL))
        {
***************
*** 965,969 ****
  
  int ILCast(ILGenInfo *info, ILNode *node, ILNode **parent,
!                  ILType *fromType, ILType *toType)
  {
        ConvertRules rules;
--- 966,970 ----
  
  int ILCast(ILGenInfo *info, ILNode *node, ILNode **parent,
!                  ILType *fromType, ILType *toType,int indirect)
  {
        ConvertRules rules;
***************
*** 979,983 ****
        {
                ApplyRules(info, node, parent, &rules, t1);
!               ILCast(info,*parent,parent,t1,t2);
                ApplyRules(info, *parent, parent, &rules2, toType);
                return 1;
--- 980,984 ----
        {
                ApplyRules(info, node, parent, &rules, t1);
!               ILCast(info,*parent,parent,t1,t2,indirect);
                ApplyRules(info, *parent, parent, &rules2, toType);
                return 1;
***************
*** 990,994 ****
  
  int ILCastKind(ILGenInfo *info, ILNode *node, ILNode **parent,
!                      ILType *fromType, ILType *toType, int kinds)
  {
        ConvertRules rules;
--- 991,996 ----
  
  int ILCastKind(ILGenInfo *info, ILNode *node, ILNode **parent,
!                      ILType *fromType, ILType *toType, int kinds,
!                          int indirect)
  {
        ConvertRules rules;
***************
*** 1000,1008 ****
                return 1;
        }
!       else if(GetIndirectConvertRules(info,fromType,toType,0, 
                                                                        
kinds,&rules,&rules2,&t1,&t2))
        {
                ApplyRules(info, node, parent, &rules, t1);
!               ILCastKind(info,*parent,parent,t1,t2,kinds);
                ApplyRules(info, *parent, parent, &rules, toType);
                return 1;
--- 1002,1010 ----
                return 1;
        }
!       else if(indirect && GetIndirectConvertRules(info,fromType,toType,0, 
                                                                        
kinds,&rules,&rules2,&t1,&t2))
        {
                ApplyRules(info, node, parent, &rules, t1);
!               ILCastKind(info,*parent,parent,t1,t2,kinds,0);
                ApplyRules(info, *parent, parent, &rules, toType);
                return 1;

Index: cg_coerce.h
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/codegen/cg_coerce.h,v
retrieving revision 1.15
retrieving revision 1.16
diff -C2 -r1.15 -r1.16
*** cg_coerce.h 16 Nov 2002 01:02:30 -0000      1.15
--- cg_coerce.h 16 Nov 2002 02:45:32 -0000      1.16
***************
*** 124,128 ****
   */
  int ILCanCoerceKind(ILGenInfo *info, ILType *fromType,
!                                       ILType *toType, int kinds);
  
  /*
--- 124,128 ----
   */
  int ILCanCoerceKind(ILGenInfo *info, ILType *fromType,
!                                       ILType *toType, int kinds,int indirect);
  
  /*
***************
*** 131,135 ****
   */
  int ILCanCoerceNode(ILGenInfo *info, ILNode *node,
!                                   ILType *fromType, ILType *toType);
  
  /*
--- 131,136 ----
   */
  int ILCanCoerceNode(ILGenInfo *info, ILNode *node,
!                                   ILType *fromType, ILType *toType,
!                                       int indirect);
  
  /*
***************
*** 139,143 ****
   */
  int ILCanCoerceNodeKind(ILGenInfo *info, ILNode *node,
!                                       ILType *fromType, ILType *toType, int 
kinds);
  
  /*
--- 140,145 ----
   */
  int ILCanCoerceNodeKind(ILGenInfo *info, ILNode *node,
!                                       ILType *fromType, ILType *toType, int 
kinds,
!                                               int indirect);
  
  /*
***************
*** 146,150 ****
   */
  int ILCoerce(ILGenInfo *info, ILNode *node, ILNode **parent,
!                        ILType *fromType, ILType *toType);
  
  /*
--- 148,152 ----
   */
  int ILCoerce(ILGenInfo *info, ILNode *node, ILNode **parent,
!                        ILType *fromType, ILType *toType, int indirect);
  
  /*
***************
*** 154,158 ****
   */
  int ILCoerceKind(ILGenInfo *info, ILNode *node, ILNode **parent,
!                            ILType *fromType, ILType *toType, int kinds);
  
  /*
--- 156,161 ----
   */
  int ILCoerceKind(ILGenInfo *info, ILNode *node, ILNode **parent,
!                            ILType *fromType, ILType *toType, int kinds,
!                                int indirect);
  
  /*
***************
*** 160,164 ****
   * from one type to another.
   */
! int ILCanCast(ILGenInfo *info, ILType *fromType, ILType *toType);
  
  /*
--- 163,168 ----
   * from one type to another.
   */
! int ILCanCast(ILGenInfo *info, ILType *fromType, ILType *toType, 
!                               int indirect);
  
  /*
***************
*** 168,172 ****
   */
  int ILCanCastKind(ILGenInfo *info, ILType *fromType,
!                                 ILType *toType, int kinds);
  
  /*
--- 172,176 ----
   */
  int ILCanCastKind(ILGenInfo *info, ILType *fromType,
!                                 ILType *toType, int kinds, int indirect);
  
  /*
***************
*** 175,179 ****
   */
  int ILCast(ILGenInfo *info, ILNode *node, ILNode **parent,
!                  ILType *fromType, ILType *toType);
  
  /*
--- 179,183 ----
   */
  int ILCast(ILGenInfo *info, ILNode *node, ILNode **parent,
!                  ILType *fromType, ILType *toType,int indirect);
  
  /*
***************
*** 183,187 ****
   */
  int ILCastKind(ILGenInfo *info, ILNode *node, ILNode **parent,
!                      ILType *fromType, ILType *toType, int kinds);
  
  /*
--- 187,192 ----
   */
  int ILCastKind(ILGenInfo *info, ILNode *node, ILNode **parent,
!                      ILType *fromType, ILType *toType, int kinds,
!                          int indirect);
  
  /*





reply via email to

[Prev in Thread] Current Thread [Next in Thread]