29 Sep 22:57
references to shared objects - too much typing...
Rajesh Walkay <rwalkay <at> speedpost.net>
2004-09-29 20:57:17 GMT
2004-09-29 20:57:17 GMT
Isn't T shared^ too much typing? If C2 makes heap my primary store why not defaulting references to refer to objects on shared store only? In such a case reference to any-store object would be a special case (being less safe and all that) and expect users to be explicit. For example, T^ myT1 = new T(); /// myT1: reference to shared T T any^ myT2 = myT; /// myT2: reference to any-store T myT1 @= myT2; /// error... cannot rebind from any-store I used "any" for the lack of better nameConstructors would then typically be written as: struct X { X(X const any^ rhs) /// rhs: reference to any-store const X {...} }; About references to local objects..., what's the use of explicitly specifying "local"? Won't shared and any-store qualifiers suffice? -Rajesh ------------------------------------------------------- This SF.net email is sponsored by: IT Product Guide on ITManagersJournal Use IT products in your business? Tell us what you think of them. Give us Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more http://productguide.itmanagersjournal.com/guidepromo.tmpl
Constructors would then typically be written as:
struct X {
X(X const any^ rhs) /// rhs: reference to any-store const X
{...}
};
About references to local objects..., what's the use of explicitly
specifying "local"? Won't shared and any-store qualifiers suffice?
-Rajesh
-------------------------------------------------------
This SF.net email is sponsored by: IT Product Guide on ITManagersJournal
Use IT products in your business? Tell us what you think of them. Give us
Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more
RSS Feed