This is the mail archive of the mailing list for the Archer project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[python][rfc] rename getter function and methods


Here are the patches which implement the renaming I mentioned earlier.
In some cases, I changed the code from a getter method to an object
attribute. In other cases, I just stripped the "get_" prefix. I also
renamed the functions in C to try to keep some consistency.

I only changed from method to attribute in cases where the value is
trivially obtained or computed from GDB's internal structure, and also
only if the value can't change from one read of the attribute to the
next (i.e., change behind the python script's back). So, for cases when
GDB has to do non-trivial computation (or even an access to inferior
memory), I kept it as a method. Also, if the value can change over time,
I kept it as a method.

I didn't commit anything since these patches will break existing scripts
(they adapt the scripts which are committed in the repository, though),
so posting as RFC first.
Thiago Jung Bauermann
IBM Linux Technology Center

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]