Lines Matching refs:value

3     __str__, argument and return value conventions
22 ExampleMandA(int value) : value(value) { print_created(this, value); }
23 ExampleMandA(const ExampleMandA &e) : value(e.value) { print_copy_created(this); }
24 ExampleMandA(ExampleMandA &&e) : value(e.value) { print_move_created(this); }
28 return "ExampleMandA[value=" + std::to_string(value) + "]";
31 void operator=(const ExampleMandA &e) { print_copy_assigned(this); value = e.value; }
32 void operator=(ExampleMandA &&e) { print_move_assigned(this); value = e.value; }
34 void add1(ExampleMandA other) { value += other.value; } // passing by value
35 void add2(ExampleMandA &other) { value += other.value; } // passing by reference
36 void add3(const ExampleMandA &other) { value += other.value; } // passing by const reference
37 void add4(ExampleMandA *other) { value += other->value; } // passing by pointer
38 void add5(const ExampleMandA *other) { value += other->value; } // passing by const pointer
40 void add6(int other) { value += other; } // passing by value
41 void add7(int &other) { value += other; } // passing by reference
42 void add8(const int &other) { value += other; } // passing by const reference
43 void add9(int *other) { value += *other; } // passing by pointer
44 void add10(const int *other) { value += *other; } // passing by const pointer
46 ExampleMandA self1() { return *this; } // return by value
52 int internal1() { return value; } // return by value
53 int &internal2() { return value; } // return by reference
54 const int &internal3() { return value; } // return by const reference
55 int *internal4() { return &value; } // return by pointer
56 const int *internal5() { return &value; } // return by const pointer
72 int value = 0;
76 int value = 1;
79 int get() const { return value; }
80 void set(int v) { value = v; }
88 int value = 99;
118 value.arg = "loading ArgInspector1 argument " +
120 "Argument value = " + (std::string) str(src);
133 value.arg = "loading ArgInspector2 argument " +
135 "Argument value = " + (std::string) str(src);
277 .def_readwrite("value", &ExampleMandA::value);
286 .def_readonly("def_readonly", &TestProperties::value)
287 .def_readwrite("def_readwrite", &TestProperties::value)
289 [](TestProperties& s,int v) { s.value = v; } )
311 .def_readonly("def_readonly", &TestPropertiesOverride::value)
438 //.def_readwrite("fails", &UserType::value) // should trigger a static_assert if uncommented
439 //.def_readonly("fails", &UserType::value) // should trigger a static_assert if uncommented
447 static_assert(std::is_same<Adapted, void (RegisteredDerived::*)() const>::value, "");