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

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

[Dotgnu-pnet-commits] CVS: pnet/ildasm ildasm_method.c,1.16,1.17


From: Rhys Weatherley <address@hidden>
Subject: [Dotgnu-pnet-commits] CVS: pnet/ildasm ildasm_method.c,1.16,1.17
Date: Fri, 13 Jun 2003 00:23:06 -0400

Update of /cvsroot/dotgnu-pnet/pnet/ildasm
In directory subversions:/tmp/cvs-serv27045/ildasm

Modified Files:
        ildasm_method.c 
Log Message:


Dump custom attribute and constant values that are attached
to method parameters.



Index: ildasm_method.c
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/ildasm/ildasm_method.c,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -r1.16 -r1.17
*** ildasm_method.c     19 Feb 2003 02:42:43 -0000      1.16
--- ildasm_method.c     13 Jun 2003 04:23:03 -0000      1.17
***************
*** 850,853 ****
--- 850,876 ----
  }
  
+ /*
+  * Dump the custom attributes on the parameters.
+  */
+ static void DumpParameterAttributes(ILImage *image, FILE *outstream,
+                                                                       
ILMethod *method, int flags)
+ {
+       ILParameter *param = 0;
+       ILAttribute *attr;
+       while((param = ILMethodNextParam(method, param)) != 0)
+       {
+               attr = ILProgramItemNextAttribute(ILToProgramItem(param), 0);
+               if(attr || ILConstantGetFromOwner(ILToProgramItem(param)) != 0)
+               {
+                       fprintf(outstream, "\t\t.param [%ld]",
+                                       (long)(ILParameter_Num(param)));
+                       ILDumpConstant(outstream, ILToProgramItem(param), 0);
+                       putc('\n', outstream);
+                       ILDAsmDumpCustomAttrs(image, outstream, flags, 2,
+                                                                 
ILToProgramItem(param));
+               }
+       }
+ }
+ 
  void ILDAsmDumpMethod(ILImage *image, FILE *outstream,
                                          ILMethod *method, int flags,
***************
*** 886,889 ****
--- 909,913 ----
        fprintf(outstream, "\t\t// Start of method header: %lx\n",
                        (unsigned long)(addr - code.headerSize));
+       DumpParameterAttributes(image, outstream, method, flags);
        if(isEntryPoint)
        {





reply via email to

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