diff options
author | sagitario <sagitario@fc51e93f-b9fe-4711-8d8d-3ae870c5f7d8> | 2012-02-12 16:05:27 (GMT) |
---|---|---|
committer | sagitario <sagitario@fc51e93f-b9fe-4711-8d8d-3ae870c5f7d8> | 2012-02-12 16:05:27 (GMT) |
commit | 96e6e9fa7388b010f55cf8d122ef03a2a8ab87e4 (patch) | |
tree | 43bfb85629d0fa32de2d88d04997642a0828c128 /src/symutil.cpp | |
parent | 805aac230223f45acc7db218eb64589a4adb390e (diff) | |
download | cv2pdb-96e6e9fa7388b010f55cf8d122ef03a2a8ab87e4.zip cv2pdb-96e6e9fa7388b010f55cf8d122ef03a2a8ab87e4.tar.gz cv2pdb-96e6e9fa7388b010f55cf8d122ef03a2a8ab87e4.tar.bz2 |
* disabled named enumerator for D basic types to avoid debugger troubles displaying arrays
* added command line switch -e to enable using named enumerator for D basic types
* added DWARF support
* added x64 support
Diffstat (limited to 'src/symutil.cpp')
-rw-r--r-- | src/symutil.cpp | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/src/symutil.cpp b/src/symutil.cpp index 61a4fa0..91e086e 100644 --- a/src/symutil.cpp +++ b/src/symutil.cpp @@ -15,6 +15,7 @@ extern "C" { char dotReplacementChar = '@';
bool demangleSymbols = true;
+bool useTypedefEnum = false;
int dsym2c(const BYTE* p, int len, char* cname, int maxclen)
{
@@ -143,6 +144,28 @@ char* p2c(const p_string& p, int idx) return p2c(&p.namelen, idx);
}
+int c2p(const char* c, BYTE* p)
+{
+ BYTE* q = p;
+ int len = strlen(c);
+ if(len > 255)
+ {
+ *p++ = 0xff;
+ *p++ = 0;
+ *p++ = len & 0xff;
+ *p++ = len >> 8;
+ }
+ else
+ *p++ = len;
+ memcpy(p, c, len);
+ return p + len - q;
+}
+
+int c2p(const char* c, p_string& p)
+{
+ return c2p(c, &p.namelen);
+}
+
int p2ccpy(char* p, const BYTE* s)
{
int len = pstrlen(s);
|