CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 15 of 31

Threaded View

  1. #16
    Join Date
    Apr 1999
    Posts
    27,449

    Re: try/catch don't work under release version???

    Quote Originally Posted by amcelroy View Post
    Sorry to revive a dead thread, but I had this same problem. Try Catch works under debug but not release for x64 compiler using VS2010. The issues seems to be that Try Catch aren't implemented if the compiler is set to optimize the code.
    And the same thing applies to your situation as in the other -- let's see your code that you claim should throw an exception, as what you think is being executed may never be executed.

    Optimizing code means that code is removed and moved around. So the code you think should be throwing an exception may not have even been called, used, or it could have been removed from the final executable.

    Do you really think that a major compiler only has exception handling when the code is unoptimized? If that were the case, then there would be thousands of programmers reporting this issue.

    Regards,

    Paul McKenzie
    Last edited by Paul McKenzie; February 28th, 2013 at 02:51 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured