473,795 Members | 2,630 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Re: Notation of "A Proposal to Add an Rvalue Reference to the C++ Language"

In article <9f60e411-a5b1-4571-9d3d-005432378cd4@
56g2000hsm.goog legroups.com>, ai*******@gmail .com says...
Hi,
I have been reading the improvement that will be made to C++0x, and
one of this is "A Proposal to Add an Rvalue Reference to the C++
Language" , which will add a double &, for example:

int someFunction(in t && a){ ...

the reason is to allow to change temporaries passed to functions. Due
to:
That's not the real reason for rvalue references. There are two primary
reasons for rvalue references: providing move semantics, and providing
forwarding semantics.

The ability to modify the original object with impunity is the
_mechanism_ behind the move semantics. Looking at this as 'mutable',
however is looking at how you do one thing with rvalue references,
rather than looking at what the rvalue reference itself really is.

This would also completely ignore the other major use of rvalue
references, which is forwarding. In this case, the ability to modify the
original item is entirely beside the point -- it's mostly about avoiding
providing lots of overloads of forwarding functions.

--
Later,
Jerry.

The universe is a figment of its own imagination.
Jun 27 '08 #1
0 1101

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

49
2876
by: Ville Vainio | last post by:
I don't know if you have seen this before, but here goes: http://text.userlinux.com/white_paper.html There is a jab at Python, though, mentioning that Ruby is more "refined". -- Ville Vainio http://www.students.tut.fi/~vainio24
10
5091
by: msnews.microsoft.com | last post by:
Hi, How do I add a reference in VC++.NET? In VB.NET and VC#.NET, there's an option in "Project" menu called "Add Reference". This will add a .NET DLL reference to the current project. After I add a reference, I can start using the class in the DLL as follows: Imports <TheNamespace>
0
2559
by: Joeyej | last post by:
Hi - I'm trying to move/use a web form (containing some javascript field checks) previously hosted on a Windows 2000 server. However, the FORM METHOD="post..." command in the form (shown below) now renders "Page not Found" when launched on the new Windows 2003 server (ws-server1). The form is designed to use the write.asp program to write to an Acccess database and is successful on any Windows 2000 server. This is frustrating because...
0
1115
by: Michal | last post by:
Hi, I'm already learn cshar language. I have a little problem with serialport and error message "object reference not set to an instance of an object". Serial communication works well, but when i closing application i get mentioned above error message. It happens on method "components.Dispose();". Only when serialport is closed (yes, closed!). When I open it before "components.Dispose();", everything is alright. P.S. I writing on this...
1
1956
by: Mike | last post by:
Hi, I'm auctioning the book "The C++ Programming Language" 3rd Ed. by Bjarne Stroustrup on ebay, details as follows or see eBay item number 250030480853. Softback. Condition : Good. Pub. Addison Wesley 1997. 3rd Edition. 910 pages. "The C++ Programming Language" by Bjarne Stroustrup is the classic C++
8
2333
by: kaili | last post by:
i'm chinese i heard that "The C Programming Language " by Brian W. Kernighan, Dennis Ritchie is the best book for new learners. but it is unavailable here. i mearn there is nobody selled it. i wonder any body can help me???
84
8599
by: aarklon | last post by:
Hi all, I found an interesting article here:- http://en.wikipedia.org/wiki/Criticism_of_the_C_programming_language well what do you guys think of this article....??? Is it constructive criticism that needs to be appreciated always...???
0
1074
by: Victor Bazarov | last post by:
aitorf666@gmail.com wrote: My bet is that it's not going to happen. Too late. Many compilers have already implemented the && syntax. Besides, would you allow the keyword 'mutable' to be used in the context of declaring a pointer to something? What if you want to declare a mutable data member that is itself an r-value reference? "mutable mutable"? V --
0
1256
by: r.battistoni | last post by:
Hy to everyone I have created a simple SAX parser for a very simple XML file. When I run the code that follows I get this error: "Invalid hexadecimal character reference" The strange thing is If I change the "chunk size" for the data I send to the parser, the error row changes. This behaviour is very strange!
0
9519
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10438
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10164
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10001
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9042
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7540
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5437
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5563
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
2920
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.