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 » VectorMap inside VectorMap
VectorMap inside VectorMap [message #19924] Mon, 02 February 2009 23:08 Go to previous message
White_Owl is currently offline  White_Owl
Messages: 27
Registered: January 2009
Location: New York
Promising Member
What is wrong with this code?
#include <Core/Core.h>

using namespace Upp;

class mycontainer: Moveable<mycontainer> {
public:
	VectorMap<String, String> data;
};

VectorMap<String, mycontainer> vm;

CONSOLE_APP_MAIN
{
	mycontainer ca = vm.GetAdd("First");
	ca.data.FindPut("first-first", "aa");
	ca.data.FindPut("first-second", "bb");
	
	mycontainer cb = vm.GetAdd("First");
	cb.data.FindPut("first-first", "cc"); // run-time error
	cb.data.FindPut("first-second", "dd");
}
Why do I get a run-time error in debug mode?
---------------------------
Fatal error
---------------------------
Assertion failed in C:/upp/uppsrc/Core/Vcont.h, line 18
Broken pick semantics

---------------------------
OK   
---------------------------

 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Quick bi-array
Next Topic: Core package build flags
Goto Forum:
  


Current Time: Thu May 16 19:41:57 CEST 2024

Total time taken to generate the page: 0.02369 seconds