Author: spouliot
Date: 2008-01-11 20:18:52 -0500 (Fri, 11 Jan 2008)
New Revision: 92710

Modified:
   trunk/cecil/gendarme/rules/Gendarme.Rules.Interoperability/ChangeLog
   
trunk/cecil/gendarme/rules/Gendarme.Rules.Interoperability/GetLastErrorMustBeCalledRightAfterPInvokeRule.cs
Log:
2008-01-11  Sebastien Pouliot  <[EMAIL PROTECTED]> 

        * GetLastErrorMustBeCalledRightAfterPInvokeRule.cs: Use new 
        Location ctors.



Modified: trunk/cecil/gendarme/rules/Gendarme.Rules.Interoperability/ChangeLog
===================================================================
--- trunk/cecil/gendarme/rules/Gendarme.Rules.Interoperability/ChangeLog        
2008-01-12 01:12:10 UTC (rev 92709)
+++ trunk/cecil/gendarme/rules/Gendarme.Rules.Interoperability/ChangeLog        
2008-01-12 01:18:52 UTC (rev 92710)
@@ -1,3 +1,8 @@
+2008-01-11  Sebastien Pouliot  <[EMAIL PROTECTED]> 
+
+       * GetLastErrorMustBeCalledRightAfterPInvokeRule.cs: Use new 
+       Location ctors.
+
 2008-01-02  Sebastien Pouliot  <[EMAIL PROTECTED]>
 
        * GetLastErrorMustBeCalledRightAfterPInvokeRule.cs: Change two 

Modified: 
trunk/cecil/gendarme/rules/Gendarme.Rules.Interoperability/GetLastErrorMustBeCalledRightAfterPInvokeRule.cs
===================================================================
--- 
trunk/cecil/gendarme/rules/Gendarme.Rules.Interoperability/GetLastErrorMustBeCalledRightAfterPInvokeRule.cs
 2008-01-12 01:12:10 UTC (rev 92709)
+++ 
trunk/cecil/gendarme/rules/Gendarme.Rules.Interoperability/GetLastErrorMustBeCalledRightAfterPInvokeRule.cs
 2008-01-12 01:18:52 UTC (rev 92710)
@@ -77,7 +77,6 @@
                                return runner.RuleSuccess;
 
                        MessageCollection results = null;
-                       string fullname = method.DeclaringType.FullName;
 
                        foreach (Instruction ins in method.Body.Instructions) {
 
@@ -112,7 +111,7 @@
                                                break;
 
                                        EnsureExists (ref results);
-                                       Location loc = new Location (fullname, 
method.Name, ins.Offset);
+                                       Location loc = new Location (method, 
ins.Offset);
                                        Message msg = new Message 
("GetLastError() should be called immediately after this the PInvoke call.", 
loc, MessageType.Error);
                                        results.Add (msg);
                                        break;

_______________________________________________
Mono-patches maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches

Reply via email to