summaryrefslogtreecommitdiff
path: root/lldb/bindings/interface/SBCommandReturnObjectExtensions.i
blob: ab9b376467b2b200d4ba03bac7625c707928fb4b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
STRING_EXTENSION_OUTSIDE(SBCommandReturnObject)

%extend lldb::SBCommandReturnObject {
    // transfer_ownership does nothing, and is here for compatibility with
    // old scripts.  Ownership is tracked by reference count in the ordinary way.

    void SetImmediateOutputFile(lldb::FileSP BORROWED, bool transfer_ownership) {
        self->SetImmediateOutputFile(BORROWED);
    }
    void SetImmediateErrorFile(lldb::FileSP BORROWED, bool transfer_ownership) {
        self->SetImmediateErrorFile(BORROWED);
    }

    // wrapping the variadic Printf() with a plain Print()
    // because it is hard to support varargs in SWIG bridgings
    void Print (const char* str)
    {
        self->Printf("%s", str);
    }
}