memberpointers
本頁內容尚未翻譯。
cpp.MemberPointers.accessor
Section titled “cpp.MemberPointers.accessor”def MemberPointers.accessor (v : String) : StringThe member function a class is given for a pointer to its data member v.
cpp.MemberPointers.membersOf
Section titled “cpp.MemberPointers.membersOf”def MemberPointers.membersOf (items : List Item) (o : String) : List MemberThe members of the class named o among the items, if it is one.
cpp.MemberPointers.fieldType
Section titled “cpp.MemberPointers.fieldType”def MemberPointers.fieldType (items : List Item) (o : String) (v : String) : Option TypeSyntaxThe type of a data member v of the class o, if o has one.
cpp.MemberPointers.plainMethod
Section titled “cpp.MemberPointers.plainMethod”def MemberPointers.plainMethod (items : List Item) (o : String) (f : String) : BoolWhether the class o has exactly one member function named f, and it is not virtual.
cpp.MemberPointers.type
Section titled “cpp.MemberPointers.type”def MemberPointers.type (t : TypeSyntax) : TypeSyntaxA pointer-to-member type as a pointer to a function taking the object’s address first.
cpp.MemberPointers.object
Section titled “cpp.MemberPointers.object”def MemberPointers.object (n : NodeId) (o : Expr) (arrow : Bool) : ExprThe object’s address a pointer to member is applied to: &o for o.*p, q itself for q->*p.
cpp.MemberPointers.called
Section titled “cpp.MemberPointers.called”def MemberPointers.called (items : List Item) (e : Expr) : Expr&S::m as the function it points to (a data member’s accessor); a call through o.*p as a call of p.
cpp.MemberPointers.read
Section titled “cpp.MemberPointers.read”def MemberPointers.read (e : Expr) : Expro.*f that is not called: the data member, through its accessor.
cpp.MemberPointers.taken
Section titled “cpp.MemberPointers.taken”def MemberPointers.taken (items : List Item) : List (String * String)The data members whose address the items take (&S::v), each with its class.
cpp.MemberPointers.distinct
Section titled “cpp.MemberPointers.distinct”def MemberPointers.distinct (ps : List (String * String)) : List (String * String)The pairs without repeats, in order.
cpp.MemberPointers.withAccessors
Section titled “cpp.MemberPointers.withAccessors”def MemberPointers.withAccessors (items : List Item) (taken : List (String * String)) (it : Item) : ItemA class given the accessors of its data members whose address is taken.
cpp.MemberPointers.prepare
Section titled “cpp.MemberPointers.prepare”def MemberPointers.prepare (p : Program) : ProgramA program with its pointers to members lowered (see the module’s description).
cpp.MemberPointers.expression
Section titled “cpp.MemberPointers.expression”def MemberPointers.expression (e : Expr) : Option (CheckResult Cpp.constructs (Lifted Cpp.constructs))What is left of a pointer to member after MemberPointers.prepare: one it does not lower, not known.