mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-07-11 22:03:01 -06:00
*ide: Fixed array expressions in debugger.
git-svn-id: svn://ultimatepp.org/upp/trunk@2393 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
f0de0de418
commit
4426d557d9
4 changed files with 23 additions and 4 deletions
|
|
@ -1232,7 +1232,6 @@ bool FileSel::Execute(int _mode) {
|
|||
}
|
||||
}
|
||||
#else
|
||||
const char *fs = "Software\\Microsoft\\Windows\\CurrentVersion\\Explorer\\Shell Folders";
|
||||
dir.Add(GetDesktopFolder());
|
||||
Array<FileSystemInfo::FileInfo> root = filesystem->Find(Null);
|
||||
for(i = 0; i < root.GetCount(); i++) {
|
||||
|
|
|
|||
|
|
@ -2,6 +2,18 @@
|
|||
|
||||
#ifdef COMPILER_MSC
|
||||
|
||||
#define LLOG(x) // DLOG(x)
|
||||
|
||||
#ifdef _DEBUG
|
||||
String Pdb::Val::ToString() const
|
||||
{
|
||||
String r;
|
||||
r << "Pdb::Val type: " << type << ", ref: " << ref << ", array: " << array
|
||||
<< ", rvalue: " << rvalue;
|
||||
return r;
|
||||
}
|
||||
#endif
|
||||
|
||||
void Pdb::ThrowError(const char *s)
|
||||
{
|
||||
throw CParser::Error(s);
|
||||
|
|
@ -135,7 +147,10 @@ double Pdb::GetFlt(Pdb::Val v)
|
|||
|
||||
Pdb::Val Pdb::Compute(Pdb::Val v1, Pdb::Val v2, int oper)
|
||||
{
|
||||
if(v1.ref) {
|
||||
LLOG("Compute " << char(oper));
|
||||
LLOG("v1: " << v1);
|
||||
LLOG("v2: " << v2);
|
||||
if(v1.ref || v1.array) {
|
||||
int q = (int)GetInt(v2) * (v1.ref > 1 ? 4 : SizeOfType(v1.type));
|
||||
v1 = GetRVal(v1);
|
||||
switch(oper) {
|
||||
|
|
@ -145,7 +160,7 @@ Pdb::Val Pdb::Compute(Pdb::Val v1, Pdb::Val v2, int oper)
|
|||
}
|
||||
return v1;
|
||||
}
|
||||
if(v2.ref) {
|
||||
if(v2.ref || v2.array) {
|
||||
int q = (int)GetInt(v1) * (v2.ref ? 4 : SizeOfType(v2.type));
|
||||
v2 = GetRVal(v2);
|
||||
if(oper == '+')
|
||||
|
|
@ -347,6 +362,7 @@ String ReadType(CParser& p)
|
|||
Pdb::Val Pdb::Post(CParser& p)
|
||||
{
|
||||
Val v = Term(p);
|
||||
LLOG("Post: " << v);
|
||||
for(;;) {
|
||||
if(p.Char(':'))
|
||||
v = Field(v.ref ? DeRef(v) : v, ReadType(p));
|
||||
|
|
@ -413,6 +429,7 @@ Pdb::Val Pdb::Additive(CParser& p)
|
|||
|
||||
Pdb::Val Pdb::Exp0(CParser& p)
|
||||
{
|
||||
LLOG("Evaluating Expression: " << p.GetPtr());
|
||||
return Additive(p);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -77,6 +77,10 @@ struct Pdb : Debugger, ParentCtrl {
|
|||
int64 ival;
|
||||
double fval;
|
||||
};
|
||||
|
||||
#ifdef _DEBUG
|
||||
String ToString() const;
|
||||
#endif
|
||||
|
||||
Val() { rvalue = false; ref = 0; array = false; bitcnt = 0; address = 0; }
|
||||
};
|
||||
|
|
|
|||
|
|
@ -345,7 +345,6 @@ const Pdb::Type& Pdb::GetType(int ti)
|
|||
}
|
||||
else
|
||||
if(tag == SymTagBaseClass) {
|
||||
DUMP(kind);
|
||||
Val& v = t.base.Add();
|
||||
TypeVal(v, GetSymInfo(t.modbase, ch, TI_GET_TYPEID), t.modbase);
|
||||
v.address = GetSymInfo(t.modbase, ch, TI_GET_OFFSET);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue