Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ Core » Error in "NTL - moveable" documentation?
Re: Error in "NTL - moveable" documentation? [message #4297 is a reply to message #4295] Mon, 31 July 2006 23:28 Go to previous message
mirek is currently offline  mirek
Messages: 14265
Registered: November 2005
Ultimate Member
Werner wrote on Mon, 31 July 2006 15:19

luzr wrote on Sun, 30 July 2006 11:11

Thanks!

Fixed: capacity = max(1, 2 * capacity);

Mirek


You're welcome!

May I suggest to check that "Expand" in the second - improved - "SimpleVector" class is also corrected?

There is another error - just a simple typo - in the "Moveable"-documentation:

The last member function of the class "SimpleString" is obviously the destructor, but the tilde (~) in front of "SimpleString" is missing.

By the way, the "Moveable" documentation leads to the following question:

As a "NTL_MOVEABLE"-macro example you provide:

NTL_MOVEABLE(std::string);


This provokes to use STL's "string" instead of UPP's "String". What is there against it? (After all its the standard!) Rolling Eyes

Werner




Actually, this provokes that I should finally make the pass through NTL documentation.

NTL_MOVEABLE(std::string);

is unfortunately just a guessing - there is nothing in C++ standard about std::string being moveable and, worse, non-moveable implementation makes sense.

There are other troubles with std::string - e.g. copy may depend on the length. That is quite a problem as we are used to store whole files in String...

Mirek
 
Read Message
Read Message
Read Message
Read Message
Previous Topic: More String Functions [FEATURE REQUEST]
Next Topic: running programs from upp program
Goto Forum:
  


Current Time: Fri Jul 04 15:17:15 CEST 2025

Total time taken to generate the page: 0.03639 seconds