在Turbo c ++中跟踪(F7)和跳过(F8)有什么区别?

时间:2017-09-21 12:32:02

标签: c++

enter image description here

在turbo c ++中跟踪和转换的主要区别是什么

1 个答案:

答案 0 :(得分:0)

我们假设您有以下计划:

"prop1"|"prop2"|"prop3"

如果选择Step Over,调试器将运行type SomeProperties = ['prop1', 'prop2', 'prop3']; type MyInterface = { [key in SomeProperties[number]]: string; } const myInterface: MyInterface = { prop1: 'this', prop2: 'works', prop3: 'now' } ,因为main函数中没有下一行,它将结束。所以你不会在这一行void main(String[] args){ myFunc(); //breakpoint here } void myFunc() { funcTwo(); } void funcTwo() { int x = 2; } 看到这个突破。按F8后,您甚至不会看到变量x,因为它只是运行而不是调试。调试器会粘贴到您正在调试的myFunc的上下文中,而不是更深入。

通过选择Trace Into,调试器将尝试运行int x = 2;,它会在运行该行时看到其他代码行。它会更深入,直到找到需要运行的指令行。这允许您在完整申请的同时调试mainmyFunc以及变量myFunc