Skip to main content

Benx Shen's Library tagged tips   View Popular

20 Oct 09

Caller and Callee « ActiveState Code

  • Recipe 576925: Caller and Callee











    A recipe to find out which function is the caller of the current function.












    Python


    1
    2
    3
    4
    5
    6
    7
    import inspect

    def callee():
    return inspect.getouterframes(inspect.currentframe())[1][1:4]

    def caller():
    return inspect.getouterframes(inspect.currentframe())[2][1:4]
02 Jul 08

Eclipse 3.4 Hidden Treasures | Eclipse Zone

  • Format Only Edited Lines


    The "Save Actions" is one of my favorite features in Eclipse 3.3 (read my original post about it). In Eclipse 3.4 there are several improvements including some new formatting features. One of the complaints against the Save Actions feature was that it will change the entire file, thus, making it very hard to compare to previous revisions when using a source control. It can become very annoying if some team members use it and some don't.

    For that purpose there's a new feature which allows changing just the edited lines, keeping the rest of the file intact. I highly recommend using the Save Actions feature. It is inactive by default, so go ahead and activate it.

    Enabling Format Edited Lines Only

  • Enabling Format Edited Lines Only
1 - 20 of 31 Next ›
Showing 20 items per page

Highlighter, Sticky notes, Tagging, Groups and Network: integrated suite dramatically boosting research productivity. Learn more »

Join Diigo