Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / CLR / November 2003

Tip: Looking for answers? Try searching our database.

Disassembly shows comment generating code

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Steve W TSI - 18 Nov 2003 13:56 GMT
I have a program that is acting weird.  
Stepping through with the debugger is skipping lines.
In the disassembler, it appears a comment is generating code....should this even be possible?
Using C++ .Net

Thanks
Steve W

       tag->Id       =  TIFFTAG_MODEL;
00000681  mov         ecx,edi
00000683  mov         edx,110h
00000688  call        dword ptr ds:[0C494514h]
       tag->DataType = Codecs::Tag::DataTypeConstants::Ascii;
0000068e  mov         ecx,edi
00000690  mov         edx,2
00000695  call        dword ptr ds:[0C4944D8h]
0000069b  mov         edx,dword ptr [ebp-20h]
0000069e  mov         ecx,edi
000006a0  call        dword ptr ds:[0C4944ECh]
//                 Debug::WriteLine("Pre ClearTag");
000006a6  nop              
000006a7  pop         ebx  
000006a8  pop         esi  
000006a9  pop         edi  
000006aa  mov         esp,ebp
000006ac  pop         ebp  
000006ad  ret         4
Gabriele G. Ponti - 18 Nov 2003 15:21 GMT
Steve,

What you are referring to as a comment line generating code looks like some
clean-up code before returning from a function generated by the compiler.
Also, code generated in Debug mode is often different than code generate in
Release mode.

Regards,

   Gabriele
Steve W TSI - 18 Nov 2003 16:11 GMT
Gabriele

I found the problem.

The .Net compiler wants CR and LF (0x0d and 0x0a) in the source cod
I had some lines with just CR's (0x0ds) probably pasted in from sample code (web or help file)

The compiler becomes incredibly confused....I couldn't comment out a line using //

I believe the compiler should handle this, or the IDE editor should show the lines as NOT breaking since the compiler doesn't see the breaks

Steve

PS:  Am I "chicken little saying the sky is falling", or should Microsoft be notified

Stev

   
    ----- Gabriele G. Ponti wrote: ----
   
    Steve
   
    What you are referring to as a comment line generating code looks like som
    clean-up code before returning from a function generated by the compiler
    Also, code generated in Debug mode is often different than code generate i
    Release mode
   
    Regards
   
        Gabriel

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.