debugging

Stopping delphi program in an infinite loop

拜拜、爱过 提交于 2020-01-01 11:29:33
问题 When an indefinite loop occurs in Delphi, the debugger will not even give me a stack trace when I hit the stop button. If I have a suspicion of where the program is stalling, I can put a breakpoint and it will stop if that is the correct indefinite loop. Here is a sample program to deliberately cause an indefinite loop: procedure TForm1.btnDebugInfiniteLoopClick(Sender: TObject); var I: Integer; begin I:=0; while I<100 do begin I:=1+1; if I>64 then I:=I div 2; end; end; When stopped, I get

Error:Execution failed for task ':app:transformClassesAndResourcesWithProguardForDebug'

99封情书 提交于 2020-01-01 11:14:28
问题 I must use certain librairy in my project. When I want bebu my application I receive an indication which says to me that my code exceeds 65k method. Thus I decided to use Proguard. But I receive this error. my code of buile.gradle apply plugin: 'com.android.application' apply plugin: 'realm-android' android { compileSdkVersion 24 buildToolsVersion "24.0.0" defaultConfig { applicationId "transplusafrica.delydress" minSdkVersion 19 targetSdkVersion 24 versionCode 1 versionName "1.0" }

Error:Execution failed for task ':app:transformClassesAndResourcesWithProguardForDebug'

混江龙づ霸主 提交于 2020-01-01 11:12:47
问题 I must use certain librairy in my project. When I want bebu my application I receive an indication which says to me that my code exceeds 65k method. Thus I decided to use Proguard. But I receive this error. my code of buile.gradle apply plugin: 'com.android.application' apply plugin: 'realm-android' android { compileSdkVersion 24 buildToolsVersion "24.0.0" defaultConfig { applicationId "transplusafrica.delydress" minSdkVersion 19 targetSdkVersion 24 versionCode 1 versionName "1.0" }

Error:Execution failed for task ':app:transformClassesAndResourcesWithProguardForDebug'

梦想与她 提交于 2020-01-01 11:12:31
问题 I must use certain librairy in my project. When I want bebu my application I receive an indication which says to me that my code exceeds 65k method. Thus I decided to use Proguard. But I receive this error. my code of buile.gradle apply plugin: 'com.android.application' apply plugin: 'realm-android' android { compileSdkVersion 24 buildToolsVersion "24.0.0" defaultConfig { applicationId "transplusafrica.delydress" minSdkVersion 19 targetSdkVersion 24 versionCode 1 versionName "1.0" }

Cannot resolve symbol `FileUtils` in Codepath `Todo App` tutorial (Android)

可紊 提交于 2020-01-01 10:59:07
问题 I'm trying to follow a Todo app tutorial from Codepath (https://guides.codepath.com). Source: https://guides.codepath.com/android/Basic-Todo-App-Tutorial As far as I can tell I've followed the tutorial, but am getting the below issue. Cannot resolve symbol `FileUtils` MainActivity.Java package com.codepath.simpletodo; import android.support.v7.app.AppCompatActivity; import android.os.Bundle; import android.view.Menu; import android.view.View; import android.widget.AdapterView; import android

Microsoft's CodeView format specs

此生再无相见时 提交于 2020-01-01 10:58:51
问题 I've been looking for a Microsoft document from the 1990's called CodeView Symbolic Debug Information Specification . It's referenced by Microsoft in their PE/COFF spec. Information about this document is sparse, and every lead I come across ends in a 404. Unfortunately I don't have any old MSDN CD's, which seemed to end the search for a few people. Does anyone have a copy, or know where I could find any related specs? 回答1: The one Matt Pietrek linked to, but which is not available at the

std::vector<std::string> crash

孤街醉人 提交于 2020-01-01 10:48:45
问题 This question is continuation of my question. Here is problematic code. a.h: #include <string> #include <vector> std::vector<std::string> foo(); a.cpp #include "a.h" std::vector<std::string> foo() { std::vector<std::string> v; return v; } and finally main.cpp: #include "a.h" #include <iostream> int main() { std::vector<std::string> s = foo(); return 0; } Compilation as following (main.cpp is compiled with STL debugging flag): g++ -c a.cpp g++ -D_GLIBCXX_DEBUG main.cpp a.o When running a.out,

Debugging karma-jasmine tests with node-inspector

本小妞迷上赌 提交于 2020-01-01 10:47:10
问题 Almost the same question as Debugging jasmine-node tests with node-inspector BUT does anyone know how to use node-inspector with karma? 回答1: Install the node-inspector globally from NPM: npm install -g node-inspector Then start the node-inspector and background the process (use fg to bring it back to the foreground and kill %1 to stop it): node-inspector & And then start your test runner like in debug mode this node --inspect ./node_modules/karma/bin/karma start Then connect to the inspector

What are common values for uninitialized memory for debugging?

坚强是说给别人听的谎言 提交于 2020-01-01 10:17:07
问题 A long time ago I learned about filling unused / uninitialized memory with 0xDEADBEEF so that in a debugger or a crash report if I ever see that value I know I'm looking at uninitialized memory. I saw from a crash report iOS uses 0xBBADBEEF . What other creative values have people used? Do any particular values have any kind of specific benefit? The most obvious benefit of values that turn into words is that, at least of most people, if the words are in their language they stick out easily

In Xcode how do I add a breakpoint inside a block?

喜欢而已 提交于 2020-01-01 10:13:32
问题 I have a method which returns a block. I want to add a breakpoint inside the block. In Xcode adding a breakpoint on a line that's inside the block causes execution to pause when the method is returned and not when the block is executed. How do I add a breakpoint inside a block? 回答1: I had the same difficulty, until I tried using Xcode 4's LLDB debugger (go to Product>Edit Scheme to turn it on). Perhaps you'll have better luck with it. 回答2: From the documentation You can set breakpoints and