Red Gate forums :: View topic - missing using directive
Return to www.red-gate.com RSS Feed Available

Search  | Usergroups |  Profile |  Messages |  Log in  Register 
Go to product documentation
.NET Reflector 7 EAP
.NET Reflector 7 EAP forum

missing using directive

Search in .NET Reflector 7 EAP forum
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.
Jump to:  
Author Message
alehandro



Joined: 16 Nov 2010
Posts: 35

PostPosted: Tue Jan 25, 2011 4:37 pm    Post subject: missing using directive Reply with quote

HI
for some reason Reflector does not include the required "using" for the HwndSourceHook type

example:

public bool m000141()
{
this.f000258 = new c00007c();
if (!this.f000258.m000022(new HwndSourceHook(this.m000058)))
{
return false;
}
.....

and here is the list of generated using:

using System;
using System.Collections.Generic;
using System.Runtime.InteropServices;
using System.Threading;
using System.Windows.Threading;


the missed one is
using System.Windows.Interop;


2) similar issue for ThreadStart type
missed using is System.Threading
Thanks
Back to top
View user's profile Send private message
Clive Tong



Joined: 04 Dec 2008
Posts: 283

PostPosted: Wed Jan 26, 2011 10:14 am    Post subject: Reply with quote

Hi.

Do you have an example I can look at?

When I use the export functionality on the following example:
Code:

            bool handled = false;
            System.Windows.Interop.HwndSourceHook foo = null;
            foo.Invoke(new IntPtr(10), 10, new IntPtr(10), new IntPtr(20), ref handled);

            ThreadStart start = null;
            start.Invoke();


I do get the following using statements

Code:

    using System;
    using System.Threading;
    using System.Windows.Interop;


Thanks.
Back to top
View user's profile Send private message
alehandro



Joined: 16 Nov 2010
Posts: 35

PostPosted: Thu Jan 27, 2011 1:56 pm    Post subject: Reply with quote

Hi,
here is the sample assembly
http://www.multiupload.com/ASYE2OUYYG
try to Export the sources, then compile (it is .NET 4.0 assembly)
you'll find a couple of missed using directives
Back to top
View user's profile Send private message
Clive Tong



Joined: 04 Dec 2008
Posts: 283

PostPosted: Thu Jan 27, 2011 5:27 pm    Post subject: Reply with quote

Thank You for the example. I've logged it as RP-954.
Back to top
View user's profile Send private message
Display posts from previous:   
This topic is locked: you cannot edit posts or make replies. All times are GMT + 1 Hour
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group