Skip to content

O

object, 42, 79

  • automatic, 205, 251

  • dynamically allocated, 458463

  • const object, 460

  • delete, 460

  • factory program, 461

  • initialization, 459

  • lifetime, 450

  • new, 458

  • lifetime, 204, 252

  • local static, 205, 252

  • order of destruction

  • class type object, 502

  • derived class object, 627

  • multiple inheritance, 805

  • virtual base classes, 815

order of initialization

  • class type object, 289

  • derived class object, 598, 623

  • multiple inheritance, 804

  • virtual base classes, 814

object code, 252

object file, 208, 252

object-oriented programming, 650

oct, manipulator, 754

octal, literal (0num), 38

octal escape sequence (\nnn), 39

off-the-beginning iterator, 351, 373

  • before_begin, 351

  • forward_list, 351

off-the-end

ofstream, 311, 316320, 324

old-style, cast, 164

open, file stream, 318

operand, 134, 169

  • conversion, 159

operator, 134, 169

operator alternative name, 46

operator delete

operator delete[]

  • class member, 822

  • compared to deallocate, 823

  • global function, 820

operator new

operator new[]

  • class member, 822

  • compared to allocate, 823

  • global function, 820

operator overloading, seeoverloaded operator

operators

c++
Sales_data
  • += (compound assignment), 564

  • + (addition), 560

  • == (equality), 561

  • != (inequality), 561

  • >> (input operator), 558

  • << (output operator), 557

  • Sales_item, 20

  • scope, 82

  • sizeof, 156

  • sizeof..., 700

c++
string
c++
vector
  • equality and relational, 102

  • subscript, 103105

options to main, 218

order of destruction

  • class type object, 502

  • derived class object, 627

  • multiple inheritance, 805

  • virtual base classes, 815

order of evaluation, 134, 169

  • && (logical AND), 138

  • || (logical OR), 138

  • , (comma operator), 138

  • ?: (conditional operator), 138

  • expression, 137

  • pitfalls, 149

order of initialization

  • class type object, 289

  • derived class object, 598

  • multiple base classes, 816

  • multiple inheritance, 804

  • virtual base classes, 814

ordered container

ordering, strict weak, 425, 448

OrQuery, 637

  • class definition, 644

  • eval function, 645

ostream, 5, 27, 311

  • see alsomanipulator

  • << (output operator), 7

  • precedence and associativity, 155

  • chained output, 7

  • condition state, 312

  • explicit conversion to bool, 583

  • file marker, 765

  • floating-point notation, 757

  • flushing output buffer, 314

  • format state, 753

  • no copy or assign, 311

  • not flushed if program crashes, 315

  • off_type, 766

  • output format, floating-point, 755

  • pos_type, 766

  • precision member, 756

  • random access, 765

  • random IO program, 766

  • seek and tell, 763768

  • tie member, 315

  • virtual base class, 810

  • write, 763

ostream_iterator, 403, 418

  • << (output operator), 405

  • algorithms, 404

  • initialization, 405

  • operations, 405

  • type requirements, 406

ostringstream, 311, 321, 321323

out (file mode), 319

out-of-range value, signed, 35

out_of_range, 197

  • at function, 348

out_of__stock, 783

outer scope, 48, 79

output, standard, 6

output iterator, 411, 418

overflow, 140

overflow_error, 197

overhead, function call, 238

overload resolution, seefunction matching

overloaded function, 230, 230235, 252

  • see alsofunction matching

  • as friend, 281

  • compared to redeclaration, 231

  • compared to template specialization, 708

  • const parameters, 232

  • constructor, 262

  • function template, 694699

  • linkage directive, 860

  • member function, 273

  • const, 276

  • move-enabled, 545

  • reference qualified, 547

  • virtual, 621

  • move-enabled, 545

  • namespace, 800

  • pointer to, 248

  • scope, 234

  • derived hides base, 619

  • using declaration, 800

  • in derived class, 621

  • using directive, 801

overloaded operator, 135, 169, 500, 550, 552, 590

  • ++ (increment), 566568

  • -- (decrement), 566568

  • * (dereference), 569

  • StrBlobPtr, 569

  • & (address-of), 554

  • -> (arrow operator), 569

  • StrBlobPtr, 569

  • [] (subscript), 564

  • StrVec, 565

  • () (call operator), 571

  • absInt, 571

  • PrintString, 571

  • = (assignment), 500, 563

  • StrVec initializer_list, 563

  • += (compound assignment), 555, 560

  • Sales_data, 564

  • + (addition), Sales_data, 560

  • == (equality), 561

  • Sales_data, 561

  • != (inequality), 562

  • Sales_data, 561

  • < (less-than), strict weak ordering, 562

  • >> (input operator), 558559

  • Sales_data, 558

  • << (output operator), 557558

  • Sales_data, 557

  • && (logical AND), 554

  • || (logical OR), 554

  • & (bitwise AND), Query, 644

  • | (bitwise OR), Query, 644

  • ~ (bitwise NOT), Query, 643

  • , (comma operator), 554

  • ambiguous, 588

  • arithmetic operators, 560

  • associativity, 553

  • binary operators, 552

  • candidate function, 587

  • consistency between relational and equality operators, 562

  • definition, 500, 552

  • design, 554556

  • equality operators, 561

  • explicit call to, 553

  • postfix operators, 568

  • function matching, 587589

  • member function, 500, 552

  • member vs. nonmember function, 552, 555

  • precedence, 553

  • relational operators, 562

  • requires class-type parameter, 552

  • short-circuit evaluation lost, 553

  • unary operators, 552

override, virtual function, 595, 650