260 ❘
CHAPTER 12 Debugging ironPython APPlicAtions
➤➤
u or up: Moves the frame pointer up one level in the stack trace to an old frame.
➤
➤
unalias: Removes the specified alias (see the alias command for additional details).
➤
➤
unt or until: Continues execution until such time as the line number is greater than the cur-
rent line number or the current frame returns. This command works much like a combina-
tion of the step over and step out commands in most other debuggers (see next, return, and
step for other stepping commands).
➤
➤
whatis: Displays the type of the argument that you supply.
dEbUggINg WITH THE ClR dEbUggER The CLR debugger,
CLRDbg.EXE
, is part of the .NET Framework SDK. You find it in the
GuiDebug
folder of your .NET Framework installation or in the
\Program Files\Microsoft.NET\SDK\v2.0\
GuiDebug\
folder. However, if you installed Visual Studio without installing the SDK, you might
not see a
GuiDebug
folder. In this case, you can download and install the .NET Framework SDK
separately. You can obtain the .NET Framework SDK for various platforms at these locations.
➤➤
.NET Framework 2.0: http://msdn.microsoft.com/en-us/netframework/aa731542.aspx
➤
➤
.NET Framework 3.0: http://msdn.microsoft.com/en-us/netframework/bb264589.aspx
➤
➤
.NET Framework 3.5: http://msdn.microsoft.com/en-us/netframework/cc378097.aspx
➤
➤
.NET Framework 3.5 SP1: http://msdn.microsoft.com/en-us/netframework/
aa569263.aspx
This section relies on the
CLRDbg.EXE
version found in the .NET Framework 2.0 SDK. However, the
instructions work fine for every other version of the CLR debugger as well. The newer versions of
the debugger may include a few additional features that you won’t likely use or need when working
with IronPython. The following steps describe how to start the debugger.
1. Start the CLR debugger. If you installed
the .NET Framework SDK separately,
choose Start
➤➤➪➤➤
Programs
➤➤➪➤➤
Microsoft .NET
Framework SDK v2.0
➤➤➪➤➤
Tools
➤➤➪➤➤
Microsoft
CLR Debugger. It’s also possible to start
the CLR debugger from the command line
by typing CLRDbg and pressing Enter as
long as the debugger’s location appears in
the path. You see the Microsoft CLR
Debugger window.
2. Choose Debug
➤➤➪➤➤
Program to Debug. You
see the Program to Debug dialog box shown
in Figure 12-10. This dialog box is where you enter the IronPython executable and script
information, along with any command line switches you want to use.
FIgURE 12-10: Provide the information needed
to debug your application.
548592c12.indd 260
2/24/10 12:48:49 PM
www.finebook.ir