Map
Index
Random
Help
th

Quote: a 'const' member function can read but not write its object

topics > all references > references sa-sz > QuoteRef: stroB_1991 , p. 148



Topic:
immutable files and data
Topic:
object modification

Quotation Skeleton

A member function can be declared to be … [by appending 'const' to its argument list.] … [p. 149] The reason one is allowed to "cast … we could call physical constness, is simply "stored … to its users." … Caching values, maintaining statistics, and updating use counts …   Google-1   Google-2

Copyright clearance needed for quotation.

Additional Titles

Quote: a member function can "cast away const" if the object is modified but it appears constant to its users; e.g., caching values, maintaining statistics, updating use counts

Related Topics up

Topic: immutable files and data (57 items)
Topic: object modification (10 items)

Copyright © 2002-2008 by C. Bradford Barber. All rights reserved.
Thesa is a trademark of C. Bradford Barber.