[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Dotgnu-pnet-commits] CVS: pnet/engine lib_reflect.c,1.42,1.43
From: |
Rhys Weatherley <address@hidden> |
Subject: |
[Dotgnu-pnet-commits] CVS: pnet/engine lib_reflect.c,1.42,1.43 |
Date: |
Wed, 06 Aug 2003 00:40:33 -0400 |
Update of /cvsroot/dotgnu-pnet/pnet/engine
In directory subversions:/tmp/cvs-serv11141/engine
Modified Files:
lib_reflect.c
Log Message:
Implement the internalcall for MethodInfo.GetBaseDefinition (bug #4577).
Index: lib_reflect.c
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/engine/lib_reflect.c,v
retrieving revision 1.42
retrieving revision 1.43
diff -C2 -r1.42 -r1.43
*** lib_reflect.c 26 Jul 2003 06:23:13 -0000 1.42
--- lib_reflect.c 6 Aug 2003 04:40:30 -0000 1.43
***************
*** 2234,2239 ****
ILObject *_this)
{
! /* TODO */
! return 0;
}
--- 2234,2277 ----
ILObject *_this)
{
! ILMethod *method;
!
! /* Extract the method item from the "this" object */
! method = ILProgramItemToMethod(_ILClrFromObject(thread, _this));
! if(!method)
! {
! /* Something is wrong with the object */
! ILExecThreadThrowSystem(thread,
"System.MissingMethodException", 0);
! return 0;
! }
!
! /* If the method is part of an interface, return it as-is */
! if(ILClass_IsInterface(ILMethod_Owner(method)))
! {
! return _this;
! }
!
! /* If the method is "new", static, or a constructor, return it as-is */
! if(ILMethod_IsNewSlot(method))
! {
! return _this;
! }
! if(ILMethod_IsStatic(method))
! {
! return _this;
! }
! if(ILMethod_IsConstructor(method))
! {
! return _this;
! }
!
! /* Find the base method */
! method = (ILMethod *)ILMemberGetBase((ILMember *)method);
! if(method)
! {
! return _ILClrToObject(thread, method,
"System.Reflection.ClrMethod");
! }
!
! /* We were unable to find a base definition, so return the method
itself */
! return _this;
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Dotgnu-pnet-commits] CVS: pnet/engine lib_reflect.c,1.42,1.43,
Rhys Weatherley <address@hidden> <=
- Prev by Date:
[Dotgnu-pnet-commits] CVS: pnet ChangeLog,1.2634,1.2635
- Next by Date:
[Dotgnu-pnet-commits] CVS: pnetlib/tests/runtime/System TestDecimal.cs, 1.2, 1.3 TestDouble.cs, 1.5, 1.6 TestString.cs, 1.9, 1.10
- Previous by thread:
[Dotgnu-pnet-commits] CVS: pnet ChangeLog,1.2634,1.2635
- Next by thread:
[Dotgnu-pnet-commits] CVS: pnetlib/tests/runtime/System TestDecimal.cs, 1.2, 1.3 TestDouble.cs, 1.5, 1.6 TestString.cs, 1.9, 1.10
- Index(es):