[Mono-bugs] [Bug 584306] New: Can't change the value of a string field
bugzilla_noreply at novell.com
bugzilla_noreply at novell.com
Mon Mar 1 10:24:59 EST 2010
http://bugzilla.novell.com/show_bug.cgi?id=584306
http://bugzilla.novell.com/show_bug.cgi?id=584306#c0
Summary: Can't change the value of a string field
Classification: Mono
Product: Mono: Debugger
Version: 2.6.x
Platform: Other
OS/Version: Other
Status: NEW
Severity: Normal
Priority: P5 - None
Component: backend
AssignedTo: martin at novell.com
ReportedBy: lluis at novell.com
QAContact: mono-bugs at lists.ximian.com
Found By: ---
Blocker: ---
Setting the value of a field using TargetClass.SetField doesn't seem to work.
Test case:
using System;
namespace SimpleTest
{
class MainClass
{
string someField = "hi";
public static void Main (string[] args)
{
string someLocal = "one";
MainClass c = new MainClass ();
Console.WriteLine (c.someField);
}
}
}
Debug session:
Mono Debugger
(mdb) r
Starting program: SimpleTest.exe
Thread @1 stopped at #0: 0x4146b279 in SimpleTest.MainClass.Main(string[])+0x19
at /home/lluis/Projects/borra420/SimpleTest/Main.cs:11.
11 string someLocal = "one";
(mdb) n
Thread @1 stopped at #0: 0x4146b287 in SimpleTest.MainClass.Main(string[])+0x27
at /home/lluis/Projects/borra420/SimpleTest/Main.cs:12.
12 MainClass c = new MainClass ();
(mdb) n
Thread @1 stopped at #0: 0x4146b2a7 in SimpleTest.MainClass.Main(string[])+0x47
at /home/lluis/Projects/borra420/SimpleTest/Main.cs:13.
13 Console.WriteLine (c.someField);
(mdb) p someLocal
(string) "one"
(mdb) p someLocal="two"
(string) "two"
(mdb) p someLocal
(string) "two"
(mdb) p c.someField
(string) "hi"
(mdb) p c.someField="bye"
(string) "bye"
(mdb) p c.someField
(string) "hi"
(mdb)
This debug session shows that changing the value of a local variable works, but
doing the same with a field doesn't work.
--
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
More information about the mono-bugs
mailing list