Fix -Asserts warning.

Fix -Asserts warning.

git-svn-id: ffe668792ed300d6c2daa1f6eba2e0aa28d7ec6c@89149 91177308-0d34-0410-b5e6-96231b3b80d8

--- tools/clang-cc/clang-cc.cpp
+++ tools/clang-cc/clang-cc.cpp
@@ -225,7 +225,7 @@
   //
   // FIXME: We should move .ast inputs to taking a separate path, they are
   // really quite different.
-  bool IsAST;
+  bool IsAST = false;
   Clang.setTarget(
     ConstructCompilerInvocation(Clang.getInvocation(), Clang.getDiagnostics(),
                                 argv[0], IsAST));


clang-cc: Simplify this code, now that predefines handling is uniform in the
PCH/-E and PCH/not--E cases.

git-svn-id: ffe668792ed300d6c2daa1f6eba2e0aa28d7ec6c@86808 91177308-0d34-0410-b5e6-96231b3b80d8

--- tools/clang-cc/clang-cc.cpp
+++ tools/clang-cc/clang-cc.cpp
@@ -1114,39 +1114,27 @@
     // We want to add these paths to the predefines buffer in order, make a
     // temporary vector to sort by their occurrence.
     llvm::SmallVector<std::pair<unsigned, std::string*>, 8> OrderedPaths;
+    std::string OriginalFile; // For use by -implicit-include-pch.

     if (!ImplicitIncludePTH.empty())
       OrderedPaths.push_back(std::make_pair(ImplicitIncludePTH.getPosition(),
                                             &ImplicitIncludePTH));
-    if (!ImplicitIncludePCH.empty())
+    if (!ImplicitIncludePCH.empty()) {
+      OriginalFile = PCHReader::getOriginalSourceFile(ImplicitIncludePCH);
+      // FIXME: Don't fail like this.
+      if (OriginalFile.empty())
+        exit(1);
       OrderedPaths.push_back(std::make_pair(ImplicitIncludePCH.getPosition(),
-                                            &ImplicitIncludePCH));
+                                            &OriginalFile));
+    }
     for (unsigned i = 0, e = ImplicitIncludes.size(); i != e; ++i)
       OrderedPaths.push_back(std::make_pair(ImplicitIncludes.getPosition(i),
                                             &ImplicitIncludes[i]));
     llvm::array_pod_sort(OrderedPaths.begin(), OrderedPaths.end());

     // Now that they are ordered by position, add to the predefines buffer.
-    for (unsigned i = 0, e = OrderedPaths.size(); i != e; ++i) {
-      std::string *Ptr = OrderedPaths[i].second;
-      if (!ImplicitIncludes.empty() &&
-          Ptr >= &ImplicitIncludes[0] &&
-          Ptr <= &ImplicitIncludes[ImplicitIncludes.size()-1]) {
-        InitOpts.addInclude(*Ptr);
-      } else if (Ptr == &ImplicitIncludePTH) {
-        InitOpts.addInclude(*Ptr);
-      } else {
-        // We end up here when we're producing preprocessed output and
-        // we loaded a PCH file. In this case, just include the header
-        // file that was used to build the precompiled header.
-        assert(Ptr == &ImplicitIncludePCH);
-        std::string OriginalFile = PCHReader::getOriginalSourceFile(*Ptr);
-        // FIXME: Don't fail like this.
-        if (OriginalFile.empty())
-          exit(1);
-        InitOpts.addInclude(OriginalFile);
-      }
-    }
+    for (unsigned i = 0, e = OrderedPaths.size(); i != e; ++i)
+      InitOpts.addInclude(*OrderedPaths[i].second);
   }
 }


Correction (Raphael)

Correction (Raphael)

--- PWG1/VZERO/readQAPbPb.C
+++ PWG1/VZERO/readQAPbPb.C
@@ -342,8 +342,8 @@
 		hMultA->SetBinContent(nEntries,hV0A->GetMean());
 		hMultC->SetBinContent(nEntries,hV0C->GetMean());

-		hAdcA->SetBinContent(nEntries,hAdcWithTimeA->GetMean());
-		hAdcC->SetBinContent(nEntries,hAdcWithTimeC->GetMean());
+		//		hAdcA->SetBinContent(nEntries,hAdcWithTimeA->GetMean());
+		//		hAdcC->SetBinContent(nEntries,hAdcWithTimeC->GetMean());

 //-------------
 	TCanvas * cOut = new TCanvas("cOut",Form("Run %d",runNumber));


BUG: I had switched a "max" and a "min", causing k-d tree calculation to be wrong.  This also caused the dashboard error on the D3 4-node test.

--- Parallel/vtkPKdTree.cxx
+++ Parallel/vtkPKdTree.cxx
@@ -76,7 +76,7 @@

 // Timing data ---------------------------------------------

-vtkCxxRevisionMacro(vtkPKdTree, "1.6");
+vtkCxxRevisionMacro(vtkPKdTree, "1.7");
 vtkStandardNewMacro(vtkPKdTree);

 const int vtkPKdTree::NoRegionAssignment = 0;   // default
@@ -1490,8 +1490,8 @@

     for (d=0; d<3; d++)
       {
-      min[d] = (float)regionMin[d];
-      max[d] = (float)regionMax[d];
+      min[d] = (float)regionMax[d];
+      max[d] = (float)regionMin[d];
       }
     }
 }


Actualizar_stats() actualizada

Actualizar_stats() actualizada

Ahora actualizar_stats soporta la información de múltiples usuarios.

--- Pasa_la_calculadora.cpp
+++ Pasa_la_calculadora.cpp
@@ -71,8 +71,10 @@
 //FUNCIONES DE ARCHIVO
 bool acerca();

-bool actualizar_stats(tJugador ganador);
-void stats();
+bool actualizar_stats(tJugador ganador, string usuario);
+void stats(string usuario);
+
+void fcopy(string origen, string destino);

 //FUNCIONES DE SISTEMA
 void pausa();
@@ -92,7 +94,7 @@
 		if(opcion == 1)
 		{
 			ganador = pasaCalculadora(cheats);
-			actualizar_stats(ganador);
+			actualizar_stats(ganador, nombre);
 			despedirse(ganador, nombre);

 		}
@@ -186,46 +188,93 @@
 }

 //Actualiza las estadisticas
-bool actualizar_stats(tJugador ganador)
+bool actualizar_stats(tJugador ganador, string usuario)
 {
 	bool ok;
 	int ganadas, perdidas, abandonadas;
+	string linea;
 	ifstream stats;
 	ofstream actualizar;

 	stats.open("stats.txt");
+
+	//Restauracion con el backup, si es necesaria
+	if (!stats.is_open())
+	{
+		cout << "Error! stats.txt no existe. Buscando backup..."<<endl;
+		stats.close();
+		stats.open("backup.txt");
+		if (stats.is_open())
+		{
+			cout << "backup encontrado. Restaurando stats"<<endl;
+			fcopy("backup.txt", "stats.txt");
+		}
+		else
+		{
+			cout << "No pudo encontrarse el backup. Un nuevo archivo sera creado."<<endl;
+		}
+		stats.close();
+		stats.open("stats.txt");
+	}
+	actualizar.open("backup.txt");
+
 	if(stats.is_open())
 	{
+		//Copia de stats a backup, hasta la info del usuario
+		do
+		{
+			getline(stats, linea);
+			actualizar << linea;
+		}
+		while(linea != usuario);
+
+		//Actualizacion de datos
 		stats >> ganadas;
 		stats >> perdidas;
 		stats >> abandonadas;
+
+		if     (ganador == Jugador)   ganadas += 1;
+		else if(ganador == Automata) perdidas += 1;
+		else if(ganador == Nadie) abandonadas += 1;
+
+		actualizar << ganadas     << endl;
+		actualizar << perdidas    << endl;
+		actualizar << abandonadas << endl;
+		actualizar << endl;

+		//Copia el resto del archivo
+		getline(stats, linea);
+		while (!stats.eof())
+		{
+			getline(stats, linea);
+			actualizar << linea;
+		}
+
 		ok = true;
 	}
 	else
 	{
-		ganadas = 0;
-		perdidas = 0;
-		abandonadas = 0;
+		ganadas =   (ganador == Jugador) ?1 :0;
+		perdidas = (ganador == Automata) ?1 :0;
+		abandonadas = (ganador == Nadie) ?1 :0;
+
+		actualizar << usuario     << endl;
+		actualizar << ganadas     << endl;
+		actualizar << perdidas    << endl;
+		actualizar << abandonadas << endl;
+		actualizar << endl;

 		cout << "El archivo 'stats.txt' no se encontro, se ha creado un nuevo archivo" << endl;

 		ok = false;
 	}

-	if(ganador == Jugador) ganadas += 1;
-	else if(ganador == Automata) perdidas += 1;
-	else if(ganador == Nadie) abandonadas += 1;
+	//Ahora copiamos la informacion actualizada en el archivo original
+	fcopy("backup.txt", "stats.txt");

 	stats.close();
-
-	actualizar.open("stats.txt");
-
-	actualizar << ganadas << endl;
-	actualizar << perdidas << endl;
-	actualizar << abandonadas << endl;
-
 	actualizar.close();
+
 	return ok;
 }


No era un fallo

No era un fallo

EL argumento que acepta iniciar_sesion2 es el otro usuario, para evitar
que coincidan.

--- Pasa_la_calculadora.cpp
+++ Pasa_la_calculadora.cpp
@@ -981,12 +981,12 @@
 	if (sesion == 1)
 	{
 		cout << "Hasta la proxima, " << usuario1 << endl;
-		usuario1 = iniciar_sesion2(usuario1);
+		usuario1 = iniciar_sesion2(usuario2);
 	}
 	else if (sesion == 2)
 	{
 		cout << "Hasta la proxima, " << usuario2 << endl;
-		usuario2 = iniciar_sesion2(usuario2);
+		usuario2 = iniciar_sesion2(usuario1);
 	}
 	else if (sesion == 3)
 	{


catch exceptions better

catch exceptions better

--- src/zippylogd.cpp
+++ src/zippylogd.cpp
@@ -57,17 +57,8 @@
 #error "not implemented on this platform"
 #endif
     }
-    catch (string s) {
-        cout << "Exception:" << endl;
-        cout << s;
-        return 1;
-    }
-    catch (char * s) {
-        cout << "Exception: " << s << endl;
-        return 1;
-    }
-    catch (...) {
-        cout << "received an exception" << endl;
+    catch (::std::exception e) {
+        cout << "Exception: " << e.what() << endl;
         return 1;
     }


Spaces replaced with underscores in attribute names too...

Signed-off-by: Ephphatha <c8d2f131b08ba393ae40d299f9d9ee0f39994494@thelettereph.com>

--- QCSVToXML/qcsvtoxml.cpp
+++ QCSVToXML/qcsvtoxml.cpp
@@ -180,7 +180,7 @@
 		if (this->ui.checkBoxAttributeAsElement->isChecked()) {
 			writer.writeTextElement(this->fieldLineEdits[i]->text().replace(' ', '_'), this->csvContents[dataRow][i]);
 		} else {
-			writer.writeAttribute(this->ui.lineEditNamespaceUri->text().replace(' ', '_'), this->fieldLineEdits[i]->text(), this->csvContents[dataRow][i]);
+			writer.writeAttribute(this->ui.lineEditNamespaceUri->text().replace(' ', '_'), this->fieldLineEdits[i]->text().replace(' ', '_'), this->csvContents[dataRow][i]);
 		}
 	}


Fix commenting style

Fix commenting style

--- libcaf_core/caf/detail/parser/read_uri.hpp
+++ libcaf_core/caf/detail/parser/read_uri.hpp
@@ -98,7 +98,7 @@
   });
   // FSM declaration.
   start();
-  // query may be empty
+  // Query may be empty.
   term_state(init) {
     read_next_char(read_key, key)
   }


add a copy method to the AST

add a copy method to the AST


X11 Media Key Support

X11 Media Key Support

--- QHotkey/qhotkey_x11.cpp
+++ QHotkey/qhotkey_x11.cpp
@@ -21,6 +21,7 @@
 	// QHotkeyPrivate interface
 	quint32 nativeKeycode(Qt::Key keycode, bool &ok) Q_DECL_OVERRIDE;
 	quint32 nativeModifiers(Qt::KeyboardModifiers modifiers, bool &ok) Q_DECL_OVERRIDE;
+	QString getX11String(Qt::Key keycode);
 	bool registerShortcut(QHotkey::NativeShortcut shortcut) Q_DECL_OVERRIDE;
 	bool unregisterShortcut(QHotkey::NativeShortcut shortcut) Q_DECL_OVERRIDE;

@@ -63,9 +64,33 @@
 	return false;
 }

+QString QHotkeyPrivateX11::getX11String(Qt::Key keycode)
+{
+	switch(keycode){
+
+		case Qt::Key_MediaLast :
+		case Qt::Key_MediaPrevious :
+			return "XF86AudioPrev";
+		case Qt::Key_MediaNext :
+			return "XF86AudioNext";
+		case Qt::Key_MediaPause :
+		case Qt::Key_MediaPlay :
+		case Qt::Key_MediaTogglePlayPause :
+			return "XF86AudioPlay";
+		case Qt::Key_MediaRecord :
+			return "XF86AudioRecord";
+		case Qt::Key_MediaStop :
+			return "XF86AudioStop";
+		default :
+			return QKeySequence(keycode).toString(QKeySequence::NativeText);
+	}
+}
+
 quint32 QHotkeyPrivateX11::nativeKeycode(Qt::Key keycode, bool &ok)
 {
-	KeySym keysym = XStringToKeysym(QKeySequence(keycode).toString(QKeySequence::NativeText).toLatin1().constData());
+	QString keyString = getX11String(keycode);
+
+	KeySym keysym = XStringToKeysym(keyString.toLatin1().constData());
 	if (keysym == NoSymbol) {
 		//not found -> just use the key
 		if(keycode <= 0xFFFF)


fix SIGSEGV on wayland

fix SIGSEGV on wayland

--- QHotkey/qhotkey_x11.cpp
+++ QHotkey/qhotkey_x11.cpp
@@ -154,7 +154,7 @@
 bool QHotkeyPrivateX11::registerShortcut(QHotkey::NativeShortcut shortcut)
 {
 	Display *display = QX11Info::display();
-	if(!display)
+	if(!display || !QX11Info::isPlatformX11())
 		return false;

 	HotkeyErrorHandler errorHandler;


NvE Typo corrected in yesterday's mods of AliTimstamp.


comienzo read/write

comienzo read/write


more correct alignas #1853

more correct alignas #1853

--- libraries/fc/include/fc/static_variant.hpp
+++ libraries/fc/include/fc/static_variant.hpp
@@ -195,7 +195,7 @@
     static_assert(impl::type_info<Types...>::no_reference_types, "Reference types are not permitted in static_variant.");
     static_assert(impl::type_info<Types...>::no_duplicates, "static_variant type arguments contain duplicate types.");

-    alignas(__int128) char storage[impl::type_info<Types...>::size];
+    alignas(Types...) char storage[impl::type_info<Types...>::size];
     int _tag;

     template<typename X>


Use our own type for 64 bit int.

Use our own type for 64 bit int.

git-svn-id: 04e88ac4940b0408b73cd6f458a224a262abaaff@293 ec705bc8-faf6-4f9b-9aff-b4916e9bedc3

--- RawSpeed/RawDecoder.cpp
+++ RawSpeed/RawDecoder.cpp
@@ -76,7 +76,7 @@
     ByteStream in(mFile->getData(slice.offset), slice.count);
     iPoint2D size(width, slice.h);
     iPoint2D pos(0, offY);
-    bitPerPixel = (int)((__int64)(slice.count * 8) / (slice.h * width));
+    bitPerPixel = (int)((uint64)(slice.count * 8) / (slice.h * width));
     try {
         readUncompressedRaw(in, size, pos, width*bitPerPixel / 8, bitPerPixel, true);
     } catch (RawDecoderException e) {


new renderwindows now start with a quad in the 2d transferfunction

git-svn-id: 83c4c97093aeea62ac982fbfd516bf9db27f5c99@490 c36c8488-0289-0348-9b64-b301f74bd9a7

--- Renderer/GLRenderer.cpp
+++ Renderer/GLRenderer.cpp
@@ -89,10 +89,26 @@

   if (SysTools::FileExists(strPotential2DTransName))
     m_pMasterController->MemMan()->Get2DTransFromFile(strPotential2DTransName, this, &m_p2DTrans, &m_p2DTransTex);
-  else
+  else {
     m_pMasterController->MemMan()->GetEmpty2DTrans(m_pDataset->Get2DHistogram()->GetFilledSize(), this, &m_p2DTrans, &m_p2DTransTex);

-
+    TFPolygon newSwatch;
+    newSwatch.pPoints.push_back(FLOATVECTOR2(0.1f,0.1f));
+    newSwatch.pPoints.push_back(FLOATVECTOR2(0.1f,0.9f));
+    newSwatch.pPoints.push_back(FLOATVECTOR2(0.9f,0.9f));
+    newSwatch.pPoints.push_back(FLOATVECTOR2(0.9f,0.1f));
+
+    newSwatch.pGradientCoords[0] = FLOATVECTOR2(0.1f,0.5f);
+    newSwatch.pGradientCoords[1] = FLOATVECTOR2(0.9f,0.5f);
+
+    GradientStop g1(0,FLOATVECTOR4(0,0,0,0)),g2(0.5f,FLOATVECTOR4(1,1,1,1)),g3(1,FLOATVECTOR4(0,0,0,0));
+    newSwatch.pGradientStops.push_back(g1);
+    newSwatch.pGradientStops.push_back(g2);
+    newSwatch.pGradientStops.push_back(g3);
+
+    m_p2DTrans->m_Swatches.push_back(newSwatch);
+    m_pMasterController->MemMan()->Changed2DTrans(NULL, m_p2DTrans);
+  }

   if (!LoadAndVerifyShader("Shaders/Transfer-VS.glsl", "Shaders/Transfer-FS.glsl",  &(m_pProgramTrans))        ||
       !LoadAndVerifyShader("Shaders/Transfer-VS.glsl", "Shaders/1D-slice-FS.glsl",  &(m_pProgram1DTransSlice)) ||


added missing init of local var (not that I know of any trouble it caused but proper init never hurts)

git-svn-id: 83c4c97093aeea62ac982fbfd516bf9db27f5c99@1835 c36c8488-0289-0348-9b64-b301f74bd9a7

--- Renderer/RenderMesh.cpp
+++ Renderer/RenderMesh.cpp
@@ -68,6 +68,7 @@
        other.GetTexCoordIndices(),other.GetColorIndices(),
        false, false, other.Name(),other.GetMeshType()),
    m_bActive(true),
+   m_splitIndex(0),
    m_fTransTreshhold(fTransTreshhold),
    m_bSortOver(false),
    m_viewPoint(FLOATVECTOR3(0,0,0)),
@@ -92,6 +93,7 @@
        vIndices,nIndices,tIndices,cIndices,
        false, bScaleToUnitCube,desc,meshType),
    m_bActive(true),
+   m_splitIndex(0),
    m_fTransTreshhold(fTransTreshhold),
    m_bSortOver(false),
    m_viewPoint(FLOATVECTOR3(0,0,0)),


[R]: use a diff name convention to identify graphs in SAFS.

--- Rpkg/src/rinterface.cpp
+++ Rpkg/src/rinterface.cpp
@@ -102,14 +102,12 @@

 bool standalone = true;

-static bool exist_cindex(const std::string &graph_name)
-{
-	if (standalone)
-		return false;
-
-	std::string cindex_name = graph_name + "-cindex-v" + itoa(CURR_VERSION);
-	safs_file cindex_file(get_sys_RAID_conf(), cindex_name);
-	return cindex_file.exist();
+static std::pair<std::string, std::string> get_graph_files(
+		const std::string &graph_name)
+{
+	std::string graph_file = graph_name + ".adj";
+	std::string index_file = graph_name + ".index";
+	return std::pair<std::string, std::string>(graph_file, index_file);
 }

 /*
@@ -129,15 +127,8 @@
 		return FG_graph::ptr();
 	}
 	else {
-		std::string graph_name = graph["name"];
-		std::string version = itoa(CURR_VERSION);
-		std::string graph_file = graph_name + "-v" + version;
-		std::string index_file;
-		if (exist_cindex(graph_name))
-			index_file = graph_name + "-cindex-v" + version;
-		else
-			index_file = graph_name + "-index-v" + version;
-		return FG_graph::create(graph_file, index_file, configs);
+		auto graph_files = get_graph_files(graph["name"]);
+		return FG_graph::create(graph_files.first, graph_files.second, configs);
 	}
 }

@@ -259,20 +250,16 @@
 	if (standalone)
 		return false;

-	std::string version = itoa(CURR_VERSION);
-	std::string graph_file_name = graph_name + "-v" + version;
-	safs_file graph_file(get_sys_RAID_conf(), graph_file_name);
+	auto graph_files = get_graph_files(graph_name);
+	safs_file graph_file(get_sys_RAID_conf(), graph_files.first);
 	if (!graph_file.exist()) {
 		fprintf(stderr, "The graph file of %s doesn't exist\n",
 				graph_name.c_str());
 		return false;
 	}

-	std::string graph_index_name = graph_name + "-index-v" + version;
-	std::string graph_cindex_name = graph_name + "-cindex-v" + version;
-	safs_file graph_index_file(get_sys_RAID_conf(), graph_index_name);
-	safs_file graph_cindex_file(get_sys_RAID_conf(), graph_cindex_name);
-	if (!graph_index_file.exist() && !graph_cindex_file.exist()) {
+	safs_file graph_index_file(get_sys_RAID_conf(), graph_files.second);
+	if (!graph_index_file.exist()) {
 		fprintf(stderr, "The index file of %s doesn't exist\n",
 				graph_name.c_str());
 		return false;
@@ -355,12 +342,9 @@

 static std::string extract_graph_name(const std::string &file_name)
 {
-	std::string version = itoa(CURR_VERSION);
-	size_t pos = file_name.rfind("-cindex-v" + version);
+	size_t pos = file_name.rfind(".adj");
 	if (pos == std::string::npos)
-		pos = file_name.rfind("-index-v" + version);
-	if (pos == std::string::npos)
-		pos = file_name.rfind("-v" + version);
+		pos = file_name.rfind(".index");
 	if (pos == std::string::npos)
 		return "";
 	else
@@ -660,17 +644,9 @@
 	auto it = graphs.find(graph_name);
 	// If the graph exist, but it's not in the graph table. It's in SAFS.
 	if (it == graphs.end()) {
-		std::string version = itoa(CURR_VERSION);
-		std::string graph_file = graph_name + "-v" + version;
-		std::string index_file;
-
-		std::string cindex_name = graph_name + "-cindex-v" + itoa(CURR_VERSION);
-		safs_file cindex_file(get_sys_RAID_conf(), cindex_name);
-		if (cindex_file.exist())
-			index_file = graph_name + "-cindex-v" + version;
-		else
-			index_file = graph_name + "-index-v" + version;
-		FG_graph::ptr fg = FG_graph::create(graph_file, index_file, configs);
+		auto graph_files = get_graph_files(graph_name);
+		FG_graph::ptr fg = FG_graph::create(graph_files.first,
+				graph_files.second, configs);
 		graph_ref *ref = register_in_mem_graph(fg, graph_name);
 		if (ref)
 			return create_FGR_obj(ref);


[R]: fix a bug in fetching a subgraph.

[R]: fix a bug in fetching a subgraph.

--- Rpkg/src/rinterface.cpp
+++ Rpkg/src/rinterface.cpp
@@ -874,6 +874,10 @@
 RcppExport SEXP R_FG_fetch_subgraph_el(SEXP graph, SEXP pvertices)
 {
 	Rcpp::IntegerVector vertices(pvertices);
+	if (vertices.length() == 0) {
+		fprintf(stderr, "There aren't vertices to fetch\n");
+		return R_NilValue;
+	}
 	std::vector<vertex_id_t> vids(vertices.begin(), vertices.end());
 	FG_graph::ptr fg = R_FG_get_graph(graph);
 	vertex_id_t max_vid = fg->get_graph_header().get_num_vertices() - 1;
@@ -934,6 +938,10 @@
 	bool compress = LOGICAL(pcompress)[0];
 	std::string graph_name = CHAR(STRING_ELT(pname, 0));
 	Rcpp::IntegerVector vertices(pvertices);
+	if (vertices.length() == 0) {
+		fprintf(stderr, "There aren't vertices to fetch\n");
+		return R_NilValue;
+	}
 	std::vector<vertex_id_t> vids(vertices.begin(), vertices.end());
 	FG_graph::ptr fg = R_FG_get_graph(graph);
 	vertex_id_t max_vid = fg->get_graph_header().get_num_vertices() - 1;


[Specific-PSXPC_N] Correct ROOMLET2.

[Specific-PSXPC_N] Correct ROOMLET2.


[Specific-PSXPC_N] Correct CreateNewVertex

--- SPEC_PSXPC_N/ROOMLETB.C
+++ SPEC_PSXPC_N/ROOMLETB.C
@@ -171,7 +171,7 @@
 	at += s2;
 	at >>= 1;

-	((unsigned char*)a1)[30] = a1;
+	((unsigned char*)t2)[30] = a1;

 	a1 = ((unsigned int*)t7)[4];
 	s2 = ((unsigned int*)t8)[4];
@@ -231,17 +231,6 @@
 	Add2DPrim(&sp[9], &sp[4], &sp[2]);
 	Add2DPrim(&sp[9], (int*)sp[3], &sp[14]);
 	Add2DPrim(&sp[9], (int*)sp[14], &sp[4]);
-#if 0
-	t3 = &sp[9];
-	t4 = &sp[4];
-	t5 = &sp[2]
-
-	addi    $t4, $sp, arg_38
-	jal     Add2DPrim
-	addi    $t5, $sp, arg_10
-
-#endif
-	UNIMPLEMENTED();
 }

 int* SubPolyGTLoop(int nVertices /*gp*/, int* t00, int s1, int* t1, int* t7, int* t8)


Protection for run counter initialization for long 32 bit machines

--- STEER/AliMillePede2.cxx
+++ STEER/AliMillePede2.cxx
@@ -1119,7 +1119,7 @@
 Bool_t AliMillePede2::IsRecordAcceptable() const
 {
   // validate record according run lists set by the user
-  static Long_t prevRunID = 0xffffffffff;
+  static Long_t prevRunID = kMaxInt;
   static Bool_t prevAns   = kTRUE;
   Long_t runID = fRecord->GetRunID();
   if (runID!=prevRunID) {


Added grid test.

Added grid test.

--- test_app.cpp
+++ test_app.cpp
@@ -1,6 +1,9 @@
+
+#include <sstream>

 #include <layout/form_layout.h>
 #include <layout/box_layout.h>
+#include <layout/grid_layout.h>
 #include <gui/application.h>
 #include <gui/cocoa_style.h>

@@ -42,6 +45,31 @@
 	builder.make_button( layout->new_area(), "Me Too" );
 }

+void build_grid_window( const std::shared_ptr<gui::window> &win )
+{
+	using layout::grid_layout;
+
+	gui::builder builder( win );
+	auto layout = builder.new_layout<grid_layout>();
+	layout->set_pad( 12.0, 12.0, 12.0, 12.0 );
+	layout->set_spacing( 12.0, 12.0 );
+
+	for ( size_t i = 0; i < 5; ++i )
+		layout->new_column( 1.0 );
+
+	int count = 0;
+	for ( size_t i = 0; i < 5; ++i )
+	{
+		auto cols = layout->new_row();
+		for ( auto a: cols )
+		{
+			std::stringstream tmp;
+			tmp << ++count;
+			builder.make_label( a, tmp.str() );
+		}
+	}
+}
+
 ////////////////////////////////////////

 int safemain( int argc, char **argv )
@@ -57,6 +85,10 @@
 	auto win2 = app->new_window();
 	build_box_window( win2 );
 	win2->show();
+
+	auto win3 = app->new_window();
+	build_grid_window( win3 );
+	win3->show();

 	int code = app->run();
 	app->pop();


Fix segfault when adding value of vr LO to empty item.

When adding a value of vr LO, SH, etc (any vr that uses specific
character set) to an empty item, a segfault (null deref) would occur.
This patch adds the needed null check.

--- Source/vtkDICOMItem.cxx
+++ Source/vtkDICOMItem.cxx
@@ -345,7 +345,7 @@
     vtkDICOMVR vr = item->FindDictVR(tag);
     assert(vr != vtkDICOMVR::UN);
     // note that there is similar code in vtkDICOMMetaData
-    if (vr.HasSpecificCharacterSet())
+    if (vr.HasSpecificCharacterSet() && item->L != 0)
       {
       vtkDICOMCharacterSet cs = item->L->CharacterSet;
       const vtkDICOMValue& vcs =


cbc: throw error if store op couldn't be scheduled

Change-Id: I7fc2c6be1049e59d50020aa311686ec6ef7b86bc
Reviewed-on: http://review.couchbase.org/53610
Reviewed-by: Subhashni Balakrishnan <7129c8e37b832c7bd362ff375532d24b98ef5162@gmail.com>
Tested-by: buildbot <80754af91bfb6d1073585b046fe0a474ce868509@couchbase.com>

--- tools/cbc.cc
+++ tools/cbc.cc
@@ -486,6 +486,9 @@
         err = lcb_storedur3(instance, NULL, &cmd);
     } else {
         err = lcb_store3(instance, NULL, reinterpret_cast<lcb_CMDSTORE*>(&cmd));
+    }
+    if (err != LCB_SUCCESS) {
+        throw err;
     }
 }


strtoull doesn't exist on win32

strtoull doesn't exist on win32

Change-Id: I747f2f14883bef777f70c0710c20b461bd123144
Reviewed-on: http://review.couchbase.org/16789
Reviewed-by: Sergey Avseyev <87f6d5e4fd3644c3c20800cde7fd3ad1569370b3@gmail.com>
Tested-by: Trond Norbye <60edd2ef23891a753f231b0c6f161dc634079a93@gmail.com>

--- tools/cbc.cc
+++ tools/cbc.cc
@@ -440,8 +440,10 @@
     }

     for (list<string>::iterator iter = keys.begin(); iter != keys.end(); ++iter) {
+        libcouchbase_cas_t cas;
         string key = *iter;
-        libcouchbase_cas_t cas = strtoull((++iter)->c_str(), NULL, 16);
+        stringstream ss(key);
+        ss >> hex >> cas;
         libcouchbase_error_t err = libcouchbase_unlock(instance, NULL,
                                                        (const void *)key.c_str(),
                                                        (libcouchbase_size_t)key.length(), cas);


Only purel incoming requests have to be deleted by Sender

--- tpn/core.cpp
+++ tpn/core.cpp
@@ -1511,8 +1511,8 @@
 					if(!finished) continue;
 				}

+				if(!request->mId) delete request;
 				mRequestsToRespond.erase(i);
-				delete request;
 			}
 		}


tpunit++: increment release version

tpunit++: increment release version

--- tpunit++.hpp
+++ tpunit++.hpp
@@ -37,10 +37,10 @@
  * TPUNITPP_VERSION_MINOR is an integer of the minor version.
  * TPUNITPP_VERSION_PATCH is an integer of the patch version.
  */
-#define TPUNITPP_VERSION 1000001
+#define TPUNITPP_VERSION 1000002
 #define TPUNITPP_VERSION_MAJOR 1
 #define TPUNITPP_VERSION_MINOR 0
-#define TPUNITPP_VERSION_PATCH 1
+#define TPUNITPP_VERSION_PATCH 2

 /**
  * ABORT(); generates a failure, immediately returning from the


opencl: cosmetic and code consistency changes to the OpenCL controller impl

--- sixtracklib/opencl/internal/base_context.cpp
+++ sixtracklib/opencl/internal/base_context.cpp
@@ -31,15 +31,21 @@
 namespace st = SIXTRL_CXX_NAMESPACE;
 namespace SIXTRL_CXX_NAMESPACE
 {
-    using  _this_t = st::ClContextBase;
-
-    constexpr _this_t::kernel_arg_type_t _this_t::ARG_TYPE_NONE;
-    constexpr _this_t::kernel_arg_type_t _this_t::ARG_TYPE_VALUE;
-    constexpr _this_t::kernel_arg_type_t _this_t::ARG_TYPE_RAW_PTR;
-    constexpr _this_t::kernel_arg_type_t _this_t::ARG_TYPE_CL_ARGUMENT;
-    constexpr _this_t::kernel_arg_type_t _this_t::ARG_TYPE_CL_BUFFER;
-    constexpr _this_t::kernel_arg_type_t _this_t::ARG_TYPE_INVALID;
-    constexpr _this_t::size_type _this_t::MIN_NUM_REMAP_BUFFER_ARGS;
+    namespace
+    {
+        using  this_t = st::ClContextBase;
+        using  st_size_t = this_t::size_type;
+        using  st_kernel_id_t = this_t::kernel_id_t;
+        using  st_kernel_arg_type_t = this_t::kernel_arg_type_t;
+    }
+
+    constexpr st_kernel_arg_type_t this_t::ARG_TYPE_NONE;
+    constexpr st_kernel_arg_type_t this_t::ARG_TYPE_VALUE;
+    constexpr st_kernel_arg_type_t this_t::ARG_TYPE_RAW_PTR;
+    constexpr st_kernel_arg_type_t this_t::ARG_TYPE_CL_ARGUMENT;
+    constexpr st_kernel_arg_type_t this_t::ARG_TYPE_CL_BUFFER;
+    constexpr st_kernel_arg_type_t this_t::ARG_TYPE_INVALID;
+    constexpr st_size_t this_t::MIN_NUM_REMAP_BUFFER_ARGS;

     ClContextBase::ClContextBase(
         const char *const SIXTRL_RESTRICT config_str ) :
@@ -69,10 +75,10 @@
             this->doParseConfigStringBaseImpl( this->configStr() );
         }

-        _this_t::status_t status = this->doInitDefaultFeatureFlagsBaseImpl();
+        this_t::status_t status = this->doInitDefaultFeatureFlagsBaseImpl();
         SIXTRL_ASSERT( status == st::ARCH_STATUS_SUCCESS );

-        status = _this_t::GetAvailableNodes( this->m_available_nodes_id,
+        status = this_t::GetAvailableNodes( this->m_available_nodes_id,
             &this->m_available_nodes_info, &this->m_available_devices );

         SIXTRL_ASSERT( status == st::ARCH_STATUS_SUCCESS );
@@ -82,7 +88,7 @@
     }

     ClContextBase::ClContextBase(
-        _this_t::size_type const node_index,
+        this_t::size_type const node_index,
         const char *const SIXTRL_RESTRICT config_str ) :
         m_feature_flags(),
         m_cl_programs(),
@@ -111,10 +117,10 @@
             this->doParseConfigStringBaseImpl( this->configStr() );
         }

-        _this_t::status_t status = this->doInitDefaultFeatureFlagsBaseImpl();
+        this_t::status_t status = this->doInitDefaultFeatureFlagsBaseImpl();
         SIXTRL_ASSERT( status == st::ARCH_STATUS_SUCCESS );

-        status = _this_t::GetAvailableNodes( this->m_available_nodes_id,
+        status = this_t::GetAvailableNodes( this->m_available_nodes_id,
             &this->m_available_nodes_info, &this->m_available_devices );

         SIXTRL_ASSERT( status == st::ARCH_STATUS_SUCCESS );
@@ -133,7 +139,7 @@
     }

     ClContextBase::ClContextBase(
-        _this_t::node_id_t const node_id,
+        this_t::node_id_t const node_id,
         const char *const SIXTRL_RESTRICT config_str ) :
         m_feature_flags(),
         m_cl_programs(),
@@ -162,10 +168,10 @@
             this->doParseConfigStringBaseImpl( this->configStr() );
         }

-        _this_t::status_t status = this->doInitDefaultFeatureFlagsBaseImpl();
+        this_t::status_t status = this->doInitDefaultFeatureFlagsBaseImpl();
         SIXTRL_ASSERT( status == st::ARCH_STATUS_SUCCESS );

-        status = _this_t::GetAvailableNodes( this->m_available_nodes_id,
+        status = this_t::GetAvailableNodes( this->m_available_nodes_id,
             &this->m_available_nodes_info, &this->m_available_devices );

         SIXTRL_ASSERT( status == st::ARCH_STATUS_SUCCESS );
@@ -217,10 +223,10 @@
             this->doParseConfigStringBaseImpl( this->configStr() );
         }

-        _this_t::status_t status = this->doInitDefaultFeatureFlagsBaseImpl();
+        this_t::status_t status = this->doInitDefaultFeatureFlagsBaseImpl();
         SIXTRL_ASSERT( status == st::ARCH_STATUS_SUCCESS );

-        status = _this_t::GetAvailableNodes( this->m_available_nodes_id,
+        status = this_t::GetAvailableNodes( this->m_available_nodes_id,
             &this->m_available_nodes_info, &this->m_available_devices );

         SIXTRL_ASSERT( status == st::ARCH_STATUS_SUCCESS );
@@ -228,7 +234,7 @@

         this->doInitDefaultProgramsBaseImpl();

-        _this_t::size_type const node_index =
+        this_t::size_type const node_index =
             this->findAvailableNodesIndex( node_id_str );

         if( ( node_index < this->numAvailableNodes() ) &&
@@ -242,8 +248,8 @@
     }

     ClContextBase::ClContextBase(
-        _this_t::platform_id_t const platform_idx,
-        _this_t::device_id_t const device_idx,
+        this_t::platform_id_t const platform_idx,
+        this_t::device_id_t const device_idx,
         const char *const SIXTRL_RESTRICT config_str ) :
         m_feature_flags(),
         m_cl_programs(),
@@ -272,10 +278,10 @@
             this->doParseConfigStringBaseImpl( this->configStr() );
         }

-        _this_t::status_t status = this->doInitDefaultFeatureFlagsBaseImpl();
+        this_t::status_t status = this->doInitDefaultFeatureFlagsBaseImpl();
         SIXTRL_ASSERT( status == st::ARCH_STATUS_SUCCESS );

-        status = _this_t::GetAvailableNodes( this->m_available_nodes_id,
+        status = this_t::GetAvailableNodes( this->m_available_nodes_id,
             &this->m_available_nodes_info, &this->m_available_devices );

         SIXTRL_ASSERT( status == st::ARCH_STATUS_SUCCESS );
@@ -283,7 +289,7 @@

         this->doInitDefaultProgramsBaseImpl();

-        _this_t::size_type const node_index =
+        this_t::size_type const node_index =
             this->findAvailableNodesIndex( platform_idx, device_idx );

         if( ( node_index < this->numAvailableNodes() ) &&
@@ -319,7 +325,7 @@
         return this->m_cl_success_flag;
     }

-    _this_t::size_type ClContextBase::numAvailableNodes() const SIXTRL_NOEXCEPT
+    this_t::size_type ClContextBase::numAvailableNodes() const SIXTRL_NOEXCEPT
     {
         SIXTRL_ASSERT( this->m_available_nodes_id.size() ==
                        this->m_available_nodes_info.size() );
@@ -327,16 +333,16 @@
         return this->m_available_nodes_id.size();
     }

-    _this_t::node_info_t const*
+    this_t::node_info_t const*
     ClContextBase::availableNodesInfoBegin() const SIXTRL_NOEXCEPT
     {
         return this->m_available_nodes_info.data();
     }

-    _this_t::node_info_t const*
+    this_t::node_info_t const*
     ClContextBase::availableNodesInfoEnd()   const SIXTRL_NOEXCEPT
     {
-        _this_t::node_info_t const* ptr_end =
+        this_t::node_info_t const* ptr_end =
             this->availableNodesInfoBegin();

         if( ptr_end != nullptr )
@@ -347,17 +353,17 @@
         return ptr_end;
     }

-    _this_t::node_info_t const*
+    this_t::node_info_t const*
     ClContextBase::defaultNodeInfo() const SIXTRL_NOEXCEPT
     {
         return this->availableNodesInfoBegin();
     }

-    _this_t::node_id_t ClContextBase::defaultNodeId() const SIXTRL_NOEXCEPT
+    this_t::node_id_t ClContextBase::defaultNodeId() const SIXTRL_NOEXCEPT
     {
         NS(ComputeNodeId) default_node_id;

-        _this_t::node_info_t const* default_node_info = this->defaultNodeInfo();
+        this_t::node_info_t const* default_node_info = this->defaultNodeInfo();
         NS(ComputeNodeId_preset)( &default_node_id );

         if( default_node_info != nullptr )
@@ -369,13 +375,13 @@
     }

     bool ClContextBase::isNodeIndexAvailable(
-         _this_t::size_type const node_index ) const SIXTRL_NOEXCEPT
+         this_t::size_type const node_index ) const SIXTRL_NOEXCEPT
     {
         return ( node_index < this->numAvailableNodes() );
     }

     bool ClContextBase::isNodeIdAvailable(
-        _this_t::node_id_t const node_id ) const SIXTRL_NOEXCEPT
+        this_t::node_id_t const node_id ) const SIXTRL_NOEXCEPT
     {
         platform_id_t const platform_index =
             NS(ComputeNodeId_get_platform_id)( &node_id );
@@ -388,8 +394,8 @@
     }

     bool ClContextBase::isNodeIdAvailable(
-        _this_t::platform_id_t const platform_index,
-        _this_t::device_id_t  const device_index ) const SIXTRL_NOEXCEPT
+        this_t::platform_id_t const platform_index,
+        this_t::device_id_t  const device_index ) const SIXTRL_NOEXCEPT
     {
         return ( this->numAvailableNodes() > this->findAvailableNodesIndex(
             platform_index, device_index ) );
@@ -412,14 +418,14 @@
     }

     bool ClContextBase::isDefaultNode(
-        _this_t::node_id_t const node_id ) const SIXTRL_NOEXCEPT
+        this_t::node_id_t const node_id ) const SIXTRL_NOEXCEPT
     {
         node_id_t const default_node_id = this->defaultNodeId();
         return ( NS(ComputeNodeId_are_equal)( &node_id, &default_node_id ) );
     }

     bool ClContextBase::isDefaultNode(
-        _this_t::size_type const node_index ) const SIXTRL_NOEXCEPT
+        this_t::size_type const node_index ) const SIXTRL_NOEXCEPT
     {
         node_id_t const default_node_id = this->defaultNodeId();

@@ -428,8 +434,8 @@
     }

     bool ClContextBase::isDefaultNode(
-        _this_t::platform_id_t const platform_index,
-        _this_t::device_id_t const device_index ) const SIXTRL_NOEXCEPT
+        this_t::platform_id_t const platform_index,
+        this_t::device_id_t const device_index ) const SIXTRL_NOEXCEPT
     {
         node_id_t const default_node_id = this->defaultNodeId();

@@ -438,16 +444,16 @@
                                        &default_node_id ) );
     }

-    _this_t::node_id_t const* ClContextBase::ptrAvailableNodesId(
-        _this_t::size_type const index ) const SIXTRL_NOEXCEPT
+    this_t::node_id_t const* ClContextBase::ptrAvailableNodesId(
+        this_t::size_type const index ) const SIXTRL_NOEXCEPT
     {
         return ( index < this->numAvailableNodes() )
                ? &this->m_available_nodes_id[ index ] : nullptr;
     }

-    _this_t::node_id_t const* ClContextBase::ptrAvailableNodesId(
-        _this_t::platform_id_t const platform_index,
-        _this_t::device_id_t   const device_index ) const SIXTRL_NOEXCEPT
+    this_t::node_id_t const* ClContextBase::ptrAvailableNodesId(
+        this_t::platform_id_t const platform_index,
+        this_t::device_id_t   const device_index ) const SIXTRL_NOEXCEPT
     {
         size_type const index =
             this->findAvailableNodesIndex( platform_index, device_index );
@@ -456,7 +462,7 @@
                ? &this->m_available_nodes_id[ index ] : nullptr;
     }

-    _this_t::node_id_t const* ClContextBase::ptrAvailableNodesId(
+    this_t::node_id_t const* ClContextBase::ptrAvailableNodesId(
         char const* SIXTRL_RESTRICT node_id_str ) const SIXTRL_NOEXCEPT
     {
         size_type const index = this->findAvailableNodesIndex( node_id_str );
@@ -465,14 +471,14 @@
                ? &this->m_available_nodes_id[ index ] : nullptr;
     }

-    _this_t::node_info_t const* ClContextBase::ptrAvailableNodesInfo(
+    this_t::node_info_t const* ClContextBase::ptrAvailableNodesInfo(
         size_type const index ) const SIXTRL_NOEXCEPT
     {
         return ( index < this->numAvailableNodes() )
                ? &this->m_available_nodes_info[ index ] : nullptr;
     }

-    _this_t::node_info_t const* ClContextBase::ptrAvailableNodesInfo(
+    this_t::node_info_t const* ClContextBase::ptrAvailableNodesInfo(
         char const* SIXTRL_RESTRICT node_id_str ) const SIXTRL_NOEXCEPT
     {
         size_type const index = this->findAvailableNodesIndex( node_id_str );
@@ -481,8 +487,8 @@
                ? &this->m_available_nodes_info[ index ] : nullptr;
     }

-    _this_t::node_info_t const* ClContextBase::ptrAvailableNodesInfo(
-        _this_t::node_id_t const node_id ) const SIXTRL_NOEXCEPT
+    this_t::node_info_t const* ClContextBase::ptrAvailableNodesInfo(
+        this_t::node_id_t const node_id ) const SIXTRL_NOEXCEPT
     {
         size_type const index = this->findAvailableNodesIndex(
                                     NS(ComputeNodeId_get_platform_id)( &node_id ),
@@ -493,11 +499,11 @@
     }

     bool ClContextBase::isAvailableNodeAMDPlatform(
-        _this_t::size_type const index ) const SIXTRL_NOEXCEPT
+        this_t::size_type const index ) const SIXTRL_NOEXCEPT
     {
         bool is_amd_platform = false;

-        _this_t::node_info_t const* node_info =
+        this_t::node_info_t const* node_info =
             this->ptrAvailableNodesInfo( index );

         if( node_info != nullptr )
@@ -547,23 +553,23 @@
             static_cast< ClContextBase const& >( *this ).selectedNodeDevice() );
     }

-    _this_t::node_id_t const*
+    this_t::node_id_t const*
     ClContextBase::ptrSelectedNodeId() const SIXTRL_NOEXCEPT
     {
         return this->ptrAvailableNodesId( static_cast< size_type >(
             this->m_selected_node_index ) );
     }

-    _this_t::node_info_t const*
+    this_t::node_info_t const*
     ClContextBase::ptrSelectedNodeInfo() const SIXTRL_NOEXCEPT
     {
         return this->ptrAvailableNodesInfo( static_cast< size_type >(
             this->m_selected_node_index ) );
     }

-    _this_t::size_type ClContextBase::selectedNodeIndex() const SIXTRL_NOEXCEPT
-    {
-        using size_t = _this_t::size_type;
+    this_t::size_type ClContextBase::selectedNodeIndex() const SIXTRL_NOEXCEPT
+    {
+        using size_t = this_t::size_type;

         return ( this->hasSelectedNode() )
             ? static_cast< size_t >( this->m_selected_node_index )
@@ -584,7 +590,7 @@
     }

     bool ClContextBase::selectedNodeIdStr( char* SIXTRL_RESTRICT node_id_str,
-        _this_t::size_type const max_str_length ) const SIXTRL_NOEXCEPT
+        this_t::size_type const max_str_length ) const SIXTRL_NOEXCEPT
     {
         return ( 0 == NS(ComputeNodeId_to_string)(
             this->ptrSelectedNodeId(), node_id_str, max_str_length ) );
@@ -633,8 +639,8 @@
     }

     bool ClContextBase::selectNode(
-         _this_t::platform_id_t const platform_idx,
-         _this_t::device_id_t   const device_idx )
+         this_t::platform_id_t const platform_idx,
+         this_t::device_id_t   const device_idx )
     {
         bool success = false;

@@ -664,10 +670,10 @@
         return this->doSelectNodeBaseImpl( node_index );
     }

-    _this_t::status_t ClContextBase::doSetStatusFlags(
-        _this_t::status_flag_t const value )
-    {
-        _this_t::status_t status = st::ARCH_STATUS_GENERAL_FAILURE;
+    this_t::status_t ClContextBase::doSetStatusFlags(
+        this_t::status_flag_t const value )
+    {
+        this_t::status_t status = st::ARCH_STATUS_GENERAL_FAILURE;
         cl::CommandQueue* queue = this->openClQueue();

         if( ( queue != nullptr ) &&
@@ -677,7 +683,7 @@

             cl_int const ret = queue->enqueueWriteBuffer(
                 this->internalStatusFlagsBuffer(), CL_TRUE, 0,
-                    sizeof( _this_t::status_flag_t ),
+                    sizeof( this_t::status_flag_t ),
                         this->doGetPtrLocalStatusFlags() );

             if( ret == CL_SUCCESS )
@@ -689,10 +695,10 @@
         return status;
     }

-    _this_t::status_t ClContextBase::doFetchStatusFlags(
-        _this_t::status_flag_t* SIXTRL_RESTRICT ptr_status_flags )
-    {
-        _this_t::status_t status = st::ARCH_STATUS_GENERAL_FAILURE;
+    this_t::status_t ClContextBase::doFetchStatusFlags(
+        this_t::status_flag_t* SIXTRL_RESTRICT ptr_status_flags )
+    {
+        this_t::status_t status = st::ARCH_STATUS_GENERAL_FAILURE;
         cl::CommandQueue* queue = this->openClQueue();

         if( ( queue != nullptr ) &&
@@ -703,7 +709,7 @@

             cl_int const ret = queue->enqueueReadBuffer(
                 this->internalStatusFlagsBuffer(), CL_TRUE, 0,
-                    sizeof( _this_t::status_flag_t ),
+                    sizeof( this_t::status_flag_t ),
                         this->doGetPtrLocalStatusFlags() );

             if( ret == CL_SUCCESS )
@@ -712,26 +718,32 @@
                     *this->doGetPtrLocalStatusFlags() );
             }

+            if( ( ptr_status_flags != SIXTRL_NULLPTR ) &&
+                ( status == st::ARCH_STATUS_SUCCESS ) )
+            {
+                *ptr_status_flags = *this->doGetPtrLocalStatusFlags();
+            }
+
             queue->finish();
         }

         return status;
     }

-    _this_t::status_t ClContextBase::doAssignStatusFlagsArg(
+    this_t::status_t ClContextBase::doAssignStatusFlagsArg(
         cl::Buffer& SIXTRL_RESTRICT_REF status_flags_arg )
     {
         return this->doAssignStatusFlagsArgBaseImpl( status_flags_arg );
     }

-    _this_t::status_t ClContextBase::doAssignStatusFlagsArgBaseImpl(
+    this_t::status_t ClContextBase::doAssignStatusFlagsArgBaseImpl(
             cl::Buffer& SIXTRL_RESTRICT_REF status_flags_arg )
     {
-        using kernel_id_t = _this_t::kernel_id_t;
-        using size_t = _this_t::size_type;
-
-        _this_t::status_t status = st::ARCH_STATUS_SUCCESS;
+        using kernel_id_t = this_t::kernel_id_t;
+        using size_t = this_t::size_type;
+
+        this_t::status_t status = st::ARCH_STATUS_SUCCESS;

         if( this->has_remapping_kernel() )
         {
@@ -743,10 +755,10 @@
             {
                 size_t const num_args = this->kernelNumArgs( kernel_id );

-                if( num_args >= _this_t::MIN_NUM_REMAP_BUFFER_ARGS )
+                if( num_args >= this_t::MIN_NUM_REMAP_BUFFER_ARGS )
                 {
                     if( ( this->debugMode() ) &&
-                        ( num_args > _this_t::MIN_NUM_REMAP_BUFFER_ARGS ) )
+                        ( num_args > this_t::MIN_NUM_REMAP_BUFFER_ARGS ) )
                     {
                         SIXTRL_ASSERT( num_args > size_t{ 1 } );

@@ -758,7 +770,7 @@
                         status = st::ARCH_STATUS_GENERAL_FAILURE;
                     }
                 }
-                else if( num_args < _this_t::MIN_NUM_REMAP_BUFFER_ARGS )
+                else if( num_args < this_t::MIN_NUM_REMAP_BUFFER_ARGS )
                 {
                     status = st::ARCH_STATUS_GENERAL_FAILURE;
                 }
@@ -768,17 +780,17 @@
         return status;
     }

-    _this_t::status_t ClContextBase::doAssignSlotSizeArg(
-        _this_t::size_type const slot_size )
+    this_t::status_t ClContextBase::doAssignSlotSizeArg(
+        this_t::size_type const slot_size )
     {
          return this->doAssignSlotSizeArgBaseImpl( slot_size );
     }

-    _this_t::status_t ClContextBase::doAssignSlotSizeArgBaseImpl(
-        _this_t::size_type const slot_size )
-    {
-        using size_t = _this_t::size_type;
-        _this_t::status_t status = st::ARCH_STATUS_GENERAL_FAILURE;
+    this_t::status_t ClContextBase::doAssignSlotSizeArgBaseImpl(
+        this_t::size_type const slot_size )
+    {
+        using size_t = this_t::size_type;
+        this_t::status_t status = st::ARCH_STATUS_GENERAL_FAILURE;

         if( slot_size > size_t{ 0 } )
         {
@@ -786,16 +798,16 @@

             if( this->has_remapping_kernel() )
             {
-                _this_t::kernel_id_t const kernel_id =
+                this_t::kernel_id_t const kernel_id =
                     this->remapping_kernel_id();

                 if( ( kernel_id != st::ARCH_ILLEGAL_KERNEL_ID ) &&
-                    ( kernel_id >= _this_t::kernel_id_t{ 0 } ) &&
+                    ( kernel_id >= this_t::kernel_id_t{ 0 } ) &&
                     ( kernel_id <  static_cast< size_t >(
                             this->numAvailableKernels() ) ) )
                 {
                     if( this->kernelNumArgs( kernel_id ) >=
-                        _this_t::MIN_NUM_REMAP_BUFFER_ARGS )
+                        this_t::MIN_NUM_REMAP_BUFFER_ARGS )
                     {
                         uint64_t const slot_size_arg =
                             static_cast< uint64_t >( slot_size );
@@ -818,7 +830,7 @@
         const char *const SIXTRL_RESTRICT config_str )
     {
         if( ( config_str != nullptr ) &&
-            ( std::strlen( config_str ) > _this_t::size_type{ 0 } ) )
+            ( std::strlen( config_str ) > this_t::size_type{ 0 } ) )
         {
             this->m_config_str = std::string{ config_str };
         }
@@ -922,9 +934,9 @@
         return this->m_config_str.c_str();
     }

-    _this_t::status_t ClContextBase::reinit_default_programs()
-    {
-        _this_t::status_t status = st::ARCH_STATUS_GENERAL_FAILURE;
+    this_t::status_t ClContextBase::reinit_default_programs()
+    {
+        this_t::status_t status = st::ARCH_STATUS_GENERAL_FAILURE;

         if( !this->hasSelectedNode() )
         {
@@ -965,23 +977,23 @@
         return this->m_default_compile_options.c_str();
     }

-    _this_t::program_id_t ClContextBase::addProgramCode(
+    this_t::program_id_t ClContextBase::addProgramCode(
         std::string const& source_code )
     {
         return this->addProgramCode(
             source_code.c_str(), this->defaultCompileOptions() );
     }

-    _this_t::program_id_t ClContextBase::addProgramCode( char const* source_code )
+    this_t::program_id_t ClContextBase::addProgramCode( char const* source_code )
     {
         return this->addProgramCode(
             source_code, this->defaultCompileOptions() );
     }

-    _this_t::program_id_t ClContextBase::addProgramCode(
+    this_t::program_id_t ClContextBase::addProgramCode(
         std::string const& source_code, std::string const& compile_options )
     {
-        _this_t::program_id_t program_id = st::ARCH_ILLEGAL_PROGRAM_ID;
+        this_t::program_id_t program_id = st::ARCH_ILLEGAL_PROGRAM_ID;

         if( !source_code.empty() )
         {
@@ -1012,7 +1024,7 @@
         return program_id;
     }

-    _this_t::program_id_t
+    this_t::program_id_t
     ClContextBase::addProgramCode(
         char const* source_code, char const* compile_options )
     {
@@ -1026,14 +1038,14 @@
         return this->addProgramCode( str_source_code, str_compile_options );
     }

-    _this_t::program_id_t
+    this_t::program_id_t
     ClContextBase::addProgramFile( std::string const& path_to_program )
     {
         return this->addProgramFile(
                    path_to_program, this->m_default_compile_options );
     }

-    _this_t::program_id_t
+    this_t::program_id_t
     ClContextBase::addProgramFile( char const* path_to_program )
     {
         return ( path_to_program != nullptr )
@@ -1041,7 +1053,7 @@
                : st::ARCH_ILLEGAL_PROGRAM_ID;
     }

-    _this_t::program_id_t
+    this_t::program_id_t
     ClContextBase::addProgramFile(
         std::string const& path_to_program, std::string const& compile_options )
     {
@@ -1071,7 +1083,7 @@
         return st::ARCH_ILLEGAL_PROGRAM_ID;
     }

-    _this_t::program_id_t
+    this_t::program_id_t
     ClContextBase::addProgramFile(
         char const* path_to_program, char const* compile_options )
     {
@@ -1085,7 +1097,7 @@
     }

     bool ClContextBase::compileProgram(
-        _this_t::program_id_t const program_id )
+        this_t::program_id_t const program_id )
     {
         bool success = false;

@@ -1105,7 +1117,7 @@
     }

     char const* ClContextBase::programSourceCode(
-        _this_t::program_id_t const program_id ) const SIXTRL_NOEXCEPT
+        this_t::program_id_t const program_id ) const SIXTRL_NOEXCEPT
     {
         return ( ( program_id >= program_id_t{ 0 } ) &&
                  ( this->m_program_data.size() >
@@ -1115,7 +1127,7 @@
     }

     bool ClContextBase::programHasFilePath(
-         _this_t::program_id_t const program_id ) const SIXTRL_NOEXCEPT
+         this_t::program_id_t const program_id ) const SIXTRL_NOEXCEPT
     {
         return ( ( program_id >= program_id_t{ 0 } ) &&
                  ( this->m_program_data.size() >
@@ -1124,7 +1136,7 @@
     }

     char const* ClContextBase::programPathToFile(
-        _this_t::program_id_t const program_id ) const SIXTRL_NOEXCEPT
+        this_t::program_id_t const program_id ) const SIXTRL_NOEXCEPT
     {
         return ( ( program_id >= program_id_t{ 0 } ) &&
                  ( this->m_program_data.size() >
@@ -1134,7 +1146,7 @@
     }

     char const* ClContextBase::programCompileOptions(
-        _this_t::program_id_t const program_id ) const SIXTRL_NOEXCEPT
+        this_t::program_id_t const program_id ) const SIXTRL_NOEXCEPT
     {
         return ( ( program_id >= program_id_t{ 0 } ) &&
                  ( this->m_program_data.size() >
@@ -1144,7 +1156,7 @@
     }

     char const* ClContextBase::programCompileReport(
-        _this_t::program_id_t const program_id ) const SIXTRL_NOEXCEPT
+        this_t::program_id_t const program_id ) const SIXTRL_NOEXCEPT
     {
         return ( ( program_id >= program_id_t{ 0 } ) &&
                  ( this->m_program_data.size() >
@@ -1154,7 +1166,7 @@
     }

     bool ClContextBase::isProgramCompiled(
-        _this_t::program_id_t const program_id ) const SIXTRL_NOEXCEPT
+        this_t::program_id_t const program_id ) const SIXTRL_NOEXCEPT
     {
         return ( ( program_id >= program_id_t{ 0 } ) &&
                  ( this->m_program_data.size() >
@@ -1162,20 +1174,20 @@
             ? this->m_program_data[ program_id ].m_compiled : false;
     }

-    _this_t::size_type
+    this_t::size_type
     ClContextBase::numAvailablePrograms() const SIXTRL_NOEXCEPT
     {
         return this->m_program_data.size();
     }

-    _this_t::kernel_id_t ClContextBase::enableKernel(
+    this_t::kernel_id_t ClContextBase::enableKernel(
         std::string const& kernel_name,
-        _this_t::program_id_t const program_id )
+        this_t::program_id_t const program_id )
     {
         return this->enableKernel( kernel_name.c_str(), program_id );
     }

-    _this_t::kernel_id_t
+    this_t::kernel_id_t
     ClContextBase::enableKernel(
         char const* kernel_name, program_id_t const program_id )
     {
@@ -1287,7 +1299,7 @@
         return kernel_id;
     }

-    _this_t::kernel_id_t ClContextBase::findKernelByName(
+    this_t::kernel_id_t ClContextBase::findKernelByName(
         char const* SIXTRL_RESTRICT kernel_name ) const SIXTRL_NOEXCEPT
     {
         kernel_id_t kernel_id = st::ARCH_ILLEGAL_KERNEL_ID;
@@ -1334,7 +1346,7 @@
                    this->numAvailablePrograms() ) );
     }

-    _this_t::program_id_t
+    this_t::program_id_t
     ClContextBase::remapping_program_id() const SIXTRL_NOEXCEPT
     {
         return ( this->has_remapping_program() )
@@ -1350,7 +1362,7 @@
     }

     char const* ClContextBase::kernelFunctionName(
-        _this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
+        this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
     {
         SIXTRL_ASSERT( this->m_cl_kernels.size() ==
                        this->m_kernel_data.size() );
@@ -1363,8 +1375,8 @@
             : nullptr;
     }

-    _this_t::size_type ClContextBase::kernelLocalMemSize(
-        _this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
+    this_t::size_type ClContextBase::kernelLocalMemSize(
+        this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
     {
         SIXTRL_ASSERT( this->m_cl_kernels.size() ==
                        this->m_kernel_data.size() );
@@ -1377,8 +1389,8 @@
             : size_type{ 0 };
     }

-    _this_t::size_type ClContextBase::kernelNumArgs(
-        _this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
+    this_t::size_type ClContextBase::kernelNumArgs(
+        this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
     {
         SIXTRL_ASSERT( this->m_cl_kernels.size() ==
                        this->m_kernel_data.size() );
@@ -1391,8 +1403,8 @@
             : size_type{ 0 };
     }

-    _this_t::size_type ClContextBase::kernelWorkGroupSize(
-        _this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
+    this_t::size_type ClContextBase::kernelWorkGroupSize(
+        this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
     {
         SIXTRL_ASSERT( this->m_cl_kernels.size() ==
                        this->m_kernel_data.size() );
@@ -1411,8 +1423,8 @@
         return work_group_size;
     }

-    _this_t::size_type ClContextBase::kernelMaxWorkGroupSize(
-        _this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
+    this_t::size_type ClContextBase::kernelMaxWorkGroupSize(
+        this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
     {
         SIXTRL_ASSERT( this->m_cl_kernels.size() ==
                        this->m_kernel_data.size() );
@@ -1426,8 +1438,8 @@
     }

     bool ClContextBase::setKernelWorkGroupSize(
-        _this_t::kernel_id_t const kernel_id,
-        _this_t::size_type work_group_size ) SIXTRL_NOEXCEPT
+        this_t::kernel_id_t const kernel_id,
+        this_t::size_type work_group_size ) SIXTRL_NOEXCEPT
     {
         bool success = false;

@@ -1448,8 +1460,8 @@
         return success;
     }

-    _this_t::size_type ClContextBase::kernelPreferredWorkGroupSizeMultiple(
-        _this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
+    this_t::size_type ClContextBase::kernelPreferredWorkGroupSizeMultiple(
+        this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
     {
         SIXTRL_ASSERT( this->m_cl_kernels.size() ==
                        this->m_kernel_data.size() );
@@ -1462,8 +1474,8 @@
             : size_type{ 0 };
     }

-    _this_t::program_id_t ClContextBase::programIdByKernelId(
-        _this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
+    this_t::program_id_t ClContextBase::programIdByKernelId(
+        this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
     {
         SIXTRL_ASSERT( this->m_cl_kernels.size() ==
                        this->m_kernel_data.size() );
@@ -1476,8 +1488,8 @@
             : st::ARCH_ILLEGAL_PROGRAM_ID;
     }

-    _this_t::size_type ClContextBase::kernelExecCounter(
-        _this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
+    this_t::size_type ClContextBase::kernelExecCounter(
+        this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
     {
         return ( ( kernel_id >= kernel_id_t{ 0 } ) &&
                  ( static_cast< size_type >( kernel_id ) <
@@ -1487,8 +1499,8 @@
     }

     ClArgument* ClContextBase::ptrKernelArgument(
-        _this_t::kernel_id_t const kernel_id,
-        _this_t::size_type const arg_index ) SIXTRL_NOEXCEPT
+        this_t::kernel_id_t const kernel_id,
+        this_t::size_type const arg_index ) SIXTRL_NOEXCEPT
     {
         using _this_t = ClContextBase;
         using   ptr_t = ClArgument*;
@@ -1498,8 +1510,8 @@
     }

     ClArgument const* ClContextBase::ptrKernelArgument(
-        _this_t::kernel_id_t const kernel_id,
-        _this_t::size_type const arg_index ) const SIXTRL_NOEXCEPT
+        this_t::kernel_id_t const kernel_id,
+        this_t::size_type const arg_index ) const SIXTRL_NOEXCEPT
     {
         ClArgument const* ptr_arg = nullptr;

@@ -1518,9 +1530,9 @@
         return ptr_arg;
     }

-    _this_t::kernel_arg_type_t ClContextBase::kernelArgumentType(
-        _this_t::kernel_id_t const kernel_id,
-        _this_t::size_type const arg_index) const SIXTRL_NOEXCEPT
+    this_t::kernel_arg_type_t ClContextBase::kernelArgumentType(
+        this_t::kernel_id_t const kernel_id,
+        this_t::size_type const arg_index) const SIXTRL_NOEXCEPT
     {
         return ( ( static_cast< size_t >( kernel_id ) <
                    this->m_kernel_data.size() ) &&
@@ -1530,15 +1542,15 @@
     }

     void ClContextBase::assignKernelArgument(
-        _this_t::kernel_id_t const kernel_id,
-        _this_t::size_type const index,
+        this_t::kernel_id_t const kernel_id,
+        this_t::size_type const index,
         ClArgument& SIXTRL_RESTRICT_REF arg )
     {
         SIXTRL_ASSERT( arg.context() == this );
-        SIXTRL_ASSERT( arg.size() > _this_t::size_type{ 0 } );
+        SIXTRL_ASSERT( arg.size() > this_t::size_type{ 0 } );

         this->m_kernel_data.at( kernel_id ).setKernelArg(
-            _this_t::ARG_TYPE_CL_ARGUMENT, index, &arg );
+            this_t::ARG_TYPE_CL_ARGUMENT, index, &arg );

         cl::Kernel* kernel = this->openClKernel( kernel_id );
         if( kernel != nullptr ) kernel->setArg( index, arg.openClBuffer() );
@@ -1615,22 +1627,22 @@
     }

     void ClContextBase::resetSingleKernelArgument(
-        _this_t::kernel_id_t const kernel_id,
-        _this_t::size_type const arg_index ) SIXTRL_NOEXCEPT
-    {
-        using _this_t = ClContextBase;
+        this_t::kernel_id_t const kernel_id,
+        this_t::size_type const arg_index ) SIXTRL_NOEXCEPT
+    {
+        using this_t = st::ClContextBase;

         cl::Kernel* kernel = this->openClKernel( kernel_id );
         if( kernel != nullptr ) kernel->setArg(
                 arg_index, this->m_default_kernel_arg );

         this->m_kernel_data.at( kernel_id ).setKernelArg(
-            _this_t::ARG_TYPE_NONE, arg_index, nullptr );
-    }
-
-    _this_t::size_type ClContextBase::calculateKernelNumWorkItems(
-        _this_t::kernel_id_t const kernel_id,
-        _this_t::size_type const min_num_work_items ) const SIXTRL_NOEXCEPT
+            this_t::ARG_TYPE_NONE, arg_index, nullptr );
+    }
+
+    this_t::size_type ClContextBase::calculateKernelNumWorkItems(
+        this_t::kernel_id_t const kernel_id,
+        this_t::size_type const min_num_work_items ) const SIXTRL_NOEXCEPT
     {
         size_type num_threads = min_num_work_items;
         size_type work_group_size = this->kernelWorkGroupSize( kernel_id );
@@ -1656,16 +1668,16 @@
     }

     bool ClContextBase::runKernel(
-        _this_t::kernel_id_t const kernel_id,
-        _this_t::size_type min_num_work_items )
+        this_t::kernel_id_t const kernel_id,
+        this_t::size_type min_num_work_items )
     {
         return this->runKernel( kernel_id, min_num_work_items,
                          this->kernelWorkGroupSize( kernel_id ) );
     }

-    bool ClContextBase::runKernel( _this_t::kernel_id_t const kernel_id,
-        _this_t::size_type const min_num_work_items,
-        _this_t::size_type work_group_size )
+    bool ClContextBase::runKernel( this_t::kernel_id_t const kernel_id,
+        this_t::size_type const min_num_work_items,
+        this_t::size_type work_group_size )
     {
         bool success = false;

@@ -1732,7 +1744,7 @@
     }

     double ClContextBase::lastExecTime(
-        _this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
+        this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
     {
         return ( ( kernel_id >= kernel_id_t{ 0 } ) &&
                  ( static_cast< size_type >( kernel_id ) <
@@ -1741,7 +1753,7 @@
     }

     double ClContextBase::minExecTime(
-        _this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
+        this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
     {
         return ( ( kernel_id >= kernel_id_t{ 0 } ) &&
                  ( static_cast< size_type >( kernel_id ) <
@@ -1750,7 +1762,7 @@
     }

     double ClContextBase::maxExecTime(
-        _this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
+        this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
     {
         return ( ( kernel_id >= kernel_id_t{ 0 } ) &&
                  ( static_cast< size_type >( kernel_id ) <
@@ -1759,7 +1771,7 @@
     }

     double ClContextBase::avgExecTime(
-        _this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
+        this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
     {
         return ( ( kernel_id >= kernel_id_t{ 0 } ) &&
                  ( static_cast< size_type >( kernel_id ) <
@@ -1767,8 +1779,8 @@
             ? this->m_kernel_data[ kernel_id ].avgExecTime() : double{ 0 };
     }

-    _this_t::size_type ClContextBase::lastExecWorkGroupSize(
-        _this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
+    this_t::size_type ClContextBase::lastExecWorkGroupSize(
+        this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
     {
         return ( ( kernel_id >= kernel_id_t{ 0 } ) &&
                  ( static_cast< size_type >( kernel_id ) <
@@ -1777,8 +1789,8 @@
             : size_type{ 0 };
     }

-    _this_t::size_type ClContextBase::lastExecNumWorkItems(
-        _this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
+    this_t::size_type ClContextBase::lastExecNumWorkItems(
+        this_t::kernel_id_t const kernel_id ) const SIXTRL_NOEXCEPT
     {
         return ( ( kernel_id >= kernel_id_t{ 0 } ) &&
                  ( static_cast< size_type >( kernel_id ) <
@@ -1788,7 +1800,7 @@
     }

     void ClContextBase::resetKernelExecTiming(
-         _this_t::kernel_id_t const kernel_id ) SIXTRL_NOEXCEPT
+         this_t::kernel_id_t const kernel_id ) SIXTRL_NOEXCEPT
     {
         if( ( kernel_id >= kernel_id_t{ 0 } ) &&
             ( static_cast< size_type >( kernel_id ) <
@@ -1801,7 +1813,7 @@
     }

     void ClContextBase::addKernelExecTime( double const time,
-        _this_t::kernel_id_t const kernel_id ) SIXTRL_NOEXCEPT
+        this_t::kernel_id_t const kernel_id ) SIXTRL_NOEXCEPT
     {
         if( ( kernel_id >= kernel_id_t{ 0 } ) &&
             ( static_cast< size_type >( kernel_id ) <
@@ -1813,7 +1825,7 @@
         return;
     }

-    _this_t::kernel_id_t
+    this_t::kernel_id_t
     ClContextBase::remapping_kernel_id() const SIXTRL_NOEXCEPT
     {
         return ( this->has_remapping_kernel() )
@@ -1821,7 +1833,7 @@
     }

     bool ClContextBase::set_remapping_kernel_id(
-        _this_t::kernel_id_t const kernel_id ) SIXTRL_NOEXCEPT
+        this_t::kernel_id_t const kernel_id ) SIXTRL_NOEXCEPT
     {
         bool success = false;

@@ -1845,7 +1857,7 @@
         return success;
     }

-    _this_t::size_type
+    this_t::size_type
     ClContextBase::numAvailableKernels() const SIXTRL_NOEXCEPT
     {
         SIXTRL_ASSERT( this->m_cl_kernels.size() ==
@@ -1855,7 +1867,7 @@
     }

     cl::Program* ClContextBase::openClProgram(
-        _this_t::program_id_t const program_id ) SIXTRL_NOEXCEPT
+        this_t::program_id_t const program_id ) SIXTRL_NOEXCEPT
     {
         return ( ( program_id >= program_id_t{ 0 } ) &&
         ( this->m_cl_programs.size() >
@@ -1864,7 +1876,7 @@
     }

     cl::Kernel* ClContextBase::openClKernel(
-        _this_t::kernel_id_t const kernel_id ) SIXTRL_NOEXCEPT
+        this_t::kernel_id_t const kernel_id ) SIXTRL_NOEXCEPT
     {
         return ( ( kernel_id >= kernel_id_t{ 0 } ) &&
             ( this->m_cl_kernels.size() > static_cast< size_type >( kernel_id ) ) )
@@ -1910,9 +1922,9 @@
         return;
     }

-    _this_t::status_flag_t ClContextBase::status_flags()
-    {
-        _this_t::status_t const status = this->doFetchStatusFlags(
+    this_t::status_flag_t ClContextBase::status_flags()
+    {
+        this_t::status_t const status = this->doFetchStatusFlags(
             this->doGetPtrLocalStatusFlags() );

         return ( status == st::ARCH_STATUS_SUCCESS )
@@ -1920,15 +1932,15 @@
             : st::ARCH_DEBUGGING_GENERAL_FAILURE;
     }

-    _this_t::status_flag_t ClContextBase::set_status_flags(
-        _this_t::status_flag_t const status_flags )
+    this_t::status_flag_t ClContextBase::set_status_flags(
+        this_t::status_flag_t const status_flags )
     {
         return this->doSetStatusFlags( status_flags );
     }

-    _this_t::status_t ClContextBase::prepare_status_flags_for_use()
-    {
-        _this_t::status_t const status = this->doSetStatusFlags(
+    this_t::status_t ClContextBase::prepare_status_flags_for_use()
+    {
+        this_t::status_t const status = this->doSetStatusFlags(
             st::ARCH_DEBUGGING_REGISTER_EMPTY );

         SIXTRL_ASSERT( ( status != st::ARCH_STATUS_SUCCESS ) ||
@@ -1939,9 +1951,9 @@
         return status;
     }

-    _this_t::status_t ClContextBase::eval_status_flags_after_use()
-    {
-        _this_t::status_t status = this->doFetchStatusFlags(
+    this_t::status_t ClContextBase::eval_status_flags_after_use()
+    {
+        this_t::status_t status = this->doFetchStatusFlags(
             this->doGetPtrLocalStatusFlags() );

         if( status == st::ARCH_STATUS_SUCCESS )
@@ -1962,32 +1974,32 @@
         return status;
     }

-    _this_t::status_t ClContextBase::assign_slot_size_arg(
-        _this_t::size_type const slot_size )
+    this_t::status_t ClContextBase::assign_slot_size_arg(
+        this_t::size_type const slot_size )
     {
         return this->doAssignSlotSizeArg( slot_size );
     }

-    _this_t::status_t ClContextBase::assign_status_flags_arg(
-        _this_t::cl_buffer_t& SIXTRL_RESTRICT_REF success_flag_arg )
+    this_t::status_t ClContextBase::assign_status_flags_arg(
+        this_t::cl_buffer_t& SIXTRL_RESTRICT_REF success_flag_arg )
     {
         return this->doAssignStatusFlagsArg( success_flag_arg );
     }

     /* --------------------------------------------------------------------- */

-    _this_t::size_type ClContextBase::num_feature_flags() const SIXTRL_NOEXCEPT
+    this_t::size_type ClContextBase::num_feature_flags() const SIXTRL_NOEXCEPT
     {
         return this->m_feature_flags.size();
     }

-    _this_t::feature_flags_iter_t
+    this_t::feature_flags_iter_t
     ClContextBase::feature_flags_begin() const SIXTRL_NOEXCEPT
     {
         return this->m_feature_flags.begin();
     }

-    _this_t::feature_flags_iter_t
+    this_t::feature_flags_iter_t
     ClContextBase::feature_flags_end() const SIXTRL_NOEXCEPT
     {
         return this->m_feature_flags.end();
@@ -2199,7 +2211,7 @@
         std::vector< ClContextBase::node_id_t >& allowed_node_ids,
         char const* SIXTRL_RESTRICT env_variable_name )
     {
-        _this_t::status_t status = st::ARCH_STATUS_SUCCESS;
+        this_t::status_t status = st::ARCH_STATUS_SUCCESS;

         allowed_node_ids.clear();
         char const* env_var_begin = nullptr;
@@ -2224,7 +2236,7 @@

             auto expr_end = (std::cregex_iterator());

-            _this_t::node_id_t tnode_id;
+            this_t::node_id_t tnode_id;

             for( ; expr_it != expr_end ; ++expr_it )
             {
@@ -2241,8 +2253,8 @@
             if( !allowed_node_ids.empty() )
             {
                 auto cmp_node_ids =
-                []( _this_t::node_id_t const& SIXTRL_RESTRICT_REF lhs,
-                    _this_t::node_id_t const& SIXTRL_RESTRICT_REF rhs )
+                []( this_t::node_id_t const& SIXTRL_RESTRICT_REF lhs,
+                    this_t::node_id_t const& SIXTRL_RESTRICT_REF rhs )
                 {
                     return (
                         ( ::NS(ComputeNodeId_get_platform_id)( &lhs ) <
@@ -2258,8 +2270,8 @@

                 allowed_node_ids.erase(
                     std::unique( allowed_node_ids.begin(), allowed_node_ids.end(),
-                    []( _this_t::node_id_t const& SIXTRL_RESTRICT_REF lhs,
-                        _this_t::node_id_t const& SIXTRL_RESTRICT_REF rhs )
+                    []( this_t::node_id_t const& SIXTRL_RESTRICT_REF lhs,
+                        this_t::node_id_t const& SIXTRL_RESTRICT_REF rhs )
                     {
                         return ::NS(ComputeNodeId_are_equal)( &lhs, &rhs );
                     } ), allowed_node_ids.end() );
@@ -2272,13 +2284,13 @@
         return status;
     }

-    _this_t::status_t ClContextBase::GetAllAvailableNodes(
+    this_t::status_t ClContextBase::GetAllAvailableNodes(
             std::vector< cl::Platform>& available_platforms,
             std::vector< cl::Device >&  available_devices,
-            std::vector< _this_t::node_id_t >* ptr_available_nodes_id,
-            std::vector< _this_t::node_info_t >* ptr_available_nodes_info )
-    {
-        _this_t::status_t status = st::ARCH_STATUS_SUCCESS;
+            std::vector< this_t::node_id_t >* ptr_available_nodes_id,
+            std::vector< this_t::node_info_t >* ptr_available_nodes_info )
+    {
+        this_t::status_t status = st::ARCH_STATUS_SUCCESS;

         if( ptr_available_nodes_id != nullptr )
         {
@@ -2302,8 +2314,8 @@
         temp_devices.clear();
         temp_devices.reserve( 100 );

-        _this_t::platform_id_t platform_idx = _this_t::platform_id_t{ 0 };
-        _this_t::device_id_t device_idx = _this_t::device_id_t{ 0 };
+        this_t::platform_id_t platform_idx = this_t::platform_id_t{ 0 };
+        this_t::device_id_t device_idx = this_t::device_id_t{ 0 };

         cl::Platform::get( &available_platforms );
         std::string const arch_str( "opencl" );
@@ -2341,7 +2353,7 @@

             for( auto const& device : temp_devices )
             {
-                _this_t::node_id_t temp_node_id;
+                this_t::node_id_t temp_node_id;

                 ::NS(ComputeNodeId_preset)( &temp_node_id );

@@ -2371,9 +2383,9 @@
                     ret |= device.getInfo( CL_DEVICE_EXTENSIONS, &description );

                     ptr_available_nodes_info->push_back(
-                        _this_t::node_info_t{} );
-
-                    _this_t::node_info_t* ptr_node_info =
+                        this_t::node_info_t{} );
+
+                    this_t::node_info_t* ptr_node_info =
                         &ptr_available_nodes_info->back();

                     ::NS(ComputeNodeInfo_preset)( ptr_node_info );
@@ -2414,14 +2426,14 @@
         return status;
     }

-    _this_t::status_t ClContextBase::GetAvailableNodes(
+    this_t::status_t ClContextBase::GetAvailableNodes(
             std::vector< ClContextBase::node_id_t>& available_nodes_id,
             std::vector< ClContextBase::node_info_t >* ptr_available_nodes_info,
             std::vector< cl::Device >* ptr_available_devices,
             char const* SIXTRL_RESTRICT env_variable_name,
             char const* SIXTRL_RESTRICT filter_str )
     {
-        using node_id_t = _this_t::node_id_t;
+        using node_id_t = this_t::node_id_t;

         ( void )filter_str;

@@ -2448,9 +2460,9 @@
         std::vector< cl::Device > all_available_devices;
         std::vector< cl::Platform > all_available_platforms;
         std::vector< node_id_t > all_available_nodes_id;
-        std::vector< _this_t::node_info_t > all_available_nodes_info;
-
-        _this_t::status_t status = _this_t::GetAllAvailableNodes(
+        std::vector< this_t::node_info_t > all_available_nodes_info;
+
+        this_t::status_t status = this_t::GetAllAvailableNodes(
             all_available_platforms, all_available_devices,
                 &all_available_nodes_id, &all_available_nodes_info );

@@ -2466,7 +2478,7 @@
         SIXTRL_ASSERT( all_available_devices.size() ==
                        all_available_nodes_info.size() );

-        std::vector< _this_t::node_id_t > allowed_node_ids;
+        std::vector< this_t::node_id_t > allowed_node_ids;

         bool first_available_node = false;
         bool ext_list_of_nodes    = false;
@@ -2486,16 +2498,16 @@

         if( ext_list_of_nodes )
         {
-            status = _this_t::GetAllowedNodesFromEnvVariable(
+            status = this_t::GetAllowedNodesFromEnvVariable(
                 allowed_node_ids, env_variable_name );
         }

         if( status != st::ARCH_STATUS_SUCCESS ) return status;

-        _this_t::size_type const max_expected_num_nodes = ( ext_list_of_nodes )
+        this_t::size_type const max_expected_num_nodes = ( ext_list_of_nodes )
             ? allowed_node_ids.size() : all_available_devices.size();

-        if( max_expected_num_nodes > _this_t::size_type{ 0 } )
+        if( max_expected_num_nodes > this_t::size_type{ 0 } )
         {
             available_nodes_id.reserve( max_expected_num_nodes );

@@ -2524,13 +2536,13 @@
                 SIXTRL_ASSERT( std::is_sorted( allowed_node_ids.begin(),
                        allowed_node_ids.end(), cmp_node_ids ) );

-                _this_t::size_type const num_available_nodes =
+                this_t::size_type const num_available_nodes =
                     all_available_devices.size();

-                for( _this_t::size_type ii = _this_t::size_type{ 0 } ;
+                for( this_t::size_type ii = this_t::size_type{ 0 } ;
                         ii < num_available_nodes ; ++ii )
                 {
-                    _this_t::node_id_t const& node_id =
+                    this_t::node_id_t const& node_id =
                         all_available_nodes_id[ ii ];

                     if( std::binary_search( allowed_node_ids.begin(),
@@ -2616,21 +2628,21 @@
         return status;
     }

-    _this_t::kernel_data_list_t const&
+    this_t::kernel_data_list_t const&
     ClContextBase::kernelData() const SIXTRL_NOEXCEPT
     {
         return this->m_kernel_data;
     }

-    _this_t::program_data_list_t const&
+    this_t::program_data_list_t const&
     ClContextBase::programData() const SIXTRL_NOEXCEPT
     {
         return this->m_program_data;
     }

     void ClContextBase::setLastWorkGroupSize(
-         _this_t::size_type const work_group_size,
-         _this_t::kernel_id_t const kernel_id ) SIXTRL_NOEXCEPT
+         this_t::size_type const work_group_size,
+         this_t::kernel_id_t const kernel_id ) SIXTRL_NOEXCEPT
     {
         if( ( kernel_id >= kernel_id_t{ 0 } ) &&
             ( static_cast< size_type >( kernel_id ) <
@@ -2644,8 +2656,8 @@
     }

     void ClContextBase::setLastNumWorkItems(
-        _this_t::size_type const num_work_items,
-        _this_t::kernel_id_t const kernel_id ) SIXTRL_NOEXCEPT
+        this_t::size_type const num_work_items,
+        this_t::kernel_id_t const kernel_id ) SIXTRL_NOEXCEPT
     {
         if( ( kernel_id >= kernel_id_t{ 0 } ) &&
             ( static_cast< size_type >( kernel_id ) <
@@ -2658,9 +2670,9 @@
         return;
     }

-    _this_t::size_type ClContextBase::findAvailableNodesIndex(
-        _this_t::platform_id_t const platform_index,
-        _this_t::device_id_t const device_index ) const SIXTRL_NOEXCEPT
+    this_t::size_type ClContextBase::findAvailableNodesIndex(
+        this_t::platform_id_t const platform_index,
+        this_t::device_id_t const device_index ) const SIXTRL_NOEXCEPT
     {
         size_type index = this->numAvailableNodes();

@@ -2688,7 +2700,7 @@
         return index;
     }

-    _this_t::size_type ClContextBase::findAvailableNodesIndex(
+    this_t::size_type ClContextBase::findAvailableNodesIndex(
         char const* node_id_str ) const SIXTRL_NOEXCEPT
     {
         if( ( node_id_str != nullptr ) && ( std::strlen( node_id_str ) >= 3u ) )
@@ -2710,13 +2722,13 @@
         return this->numAvailableNodes();
     }

-    _this_t::status_flag_t*
+    this_t::status_flag_t*
     ClContextBase::doGetPtrLocalStatusFlags() SIXTRL_NOEXCEPT
     {
         return &this->m_local_status_flags;
     }

-    _this_t::status_flag_t const*
+    this_t::status_flag_t const*
     ClContextBase::doGetPtrLocalStatusFlags() const SIXTRL_NOEXCEPT
     {
         return &this->m_local_status_flags;
@@ -2763,20 +2775,20 @@
         return;
     }

-    _this_t::status_t ClContextBase::doInitDefaultFeatureFlags()
+    this_t::status_t ClContextBase::doInitDefaultFeatureFlags()
     {
         return this->doInitDefaultFeatureFlagsBaseImpl();
     }

-    _this_t::status_t ClContextBase::doInitDefaultFeatureFlagsBaseImpl()
-    {
-        _this_t::status_t status = st::ARCH_STATUS_GENERAL_FAILURE;
+    this_t::status_t ClContextBase::doInitDefaultFeatureFlagsBaseImpl()
+    {
+        this_t::status_t status = st::ARCH_STATUS_GENERAL_FAILURE;

         this->set_feature_flag( "_GPUCODE", "1" );
         this->set_feature_flag( "SIXTRL_BUFFER_ARGPTR_DEC", "__private" );
         this->set_feature_flag( "SIXTRL_BUFFER_DATAPTR_DEC", "__global" );

-        if( this->num_feature_flags() >= _this_t::size_type{ 2 } )
+        if( this->num_feature_flags() >= this_t::size_type{ 2 } )
         {
             status = st::ARCH_STATUS_SUCCESS;
         }
@@ -3026,18 +3038,19 @@
     char* SIXTRL_RESTRICT out_node_info_str,
     ::NS(arch_size_t) const out_node_info_str_capacity )
 {
-    using _this_t = st::ClContextBase;
-    _this_t::status_t status = st::ARCH_STATUS_GENERAL_FAILURE;
+    st::ClContextBase::status_t status = st::ARCH_STATUS_GENERAL_FAILURE;

     if( ( out_node_info_str != nullptr ) &&
-        ( out_node_info_str_capacity > _this_t::size_type{ 0 } ) )
+        ( out_node_info_str_capacity > st::ClContextBase::size_type{ 0 } ) )
     {
         std::memset( out_node_info_str, ( int )'\0',
                      out_node_info_str_capacity );

-        std::string const temp_str( _this_t::PRINT_ALL_NODES_TO_STRING() );
+        std::string const temp_str(
+            st::ClContextBase::PRINT_ALL_NODES_TO_STRING() );
+
         std::strncpy( out_node_info_str, temp_str.c_str(),
-                      out_node_info_str_capacity - _this_t::size_type{ 1 } );
+            out_node_info_str_capacity - st::ClContextBase::size_type{ 1 } );

         status = st::ARCH_STATUS_SUCCESS;
     }
@@ -3107,20 +3120,20 @@
     char const* SIXTRL_RESTRICT filter_str,
     char const* SIXTRL_RESTRICT env_variable_name )
 {
-    using _this_t = st::ClContextBase;
-    _this_t::status_t status = st::ARCH_STATUS_GENERAL_FAILURE;
+    using this_t = st::ClContextBase;
+    this_t::status_t status = st::ARCH_STATUS_GENERAL_FAILURE;

     if( ( out_node_info_str != nullptr ) &&
-        ( out_node_info_str_capacity > _this_t::size_type{ 0 } ) )
+        ( out_node_info_str_capacity > this_t::size_type{ 0 } ) )
     {
         std::memset( out_node_info_str, ( int )'\0',
                      out_node_info_str_capacity );

-        std::string const temp_str( _this_t::PRINT_AVAILABLE_NODES_TO_STRING(
+        std::string const temp_str( this_t::PRINT_AVAILABLE_NODES_TO_STRING(
             filter_str, env_variable_name ) );

         std::strncpy( out_node_info_str, temp_str.c_str(),
-                      out_node_info_str_capacity - _this_t::size_type{ 1 } );
+                      out_node_info_str_capacity - this_t::size_type{ 1 } );

         status = st::ARCH_STATUS_SUCCESS;
     }


Remove device get_default().

Remove device get_default().


Move a function out of an anonymous namespace.

We only call this function in debug mode right now, so the compiler
complains (in release mode) that we have an unused function.

--- source/sundials/copy.cc
+++ source/sundials/copy.cc
@@ -22,40 +22,37 @@
 {
   namespace internal
   {
-    namespace
+    /**
+     * SUNDIALS provides different macros for getting the local length of a
+     * vector for serial and parallel vectors (as well as various parallel
+     * vectors that are not yet supported by deal.II). This function provides
+     * a generic interface to both and does a (checked) conversion from long
+     * int (the type SUNDIALS uses for lengths) to std::size_t.
+     */
+    inline
+    std::size_t
+    N_Vector_length(const N_Vector &vec)
     {
-      /**
-       * SUNDIALS provides different macros for getting the local length of a
-       * vector for serial and parallel vectors (as well as various parallel
-       * vectors that are not yet supported by deal.II). This function provides
-       * a generic interface to both and does a (checked) conversion from long
-       * int (the type SUNDIALS uses for lengths) to std::size_t.
-       */
-      inline
-      std::size_t
-      N_Vector_length(const N_Vector &vec)
-      {
-        const N_Vector_ID id = N_VGetVectorID(vec);
-        long int length = -1;
-        switch (id)
-          {
-          case SUNDIALS_NVEC_SERIAL:
-          {
-            length = NV_LENGTH_S(vec);
-            break;
-          }
-          case SUNDIALS_NVEC_PARALLEL:
-          {
-            length = NV_LOCLENGTH_P(vec);
-            break;
-          }
-          default:
-            Assert(false, ExcNotImplemented());
-          }
+      const N_Vector_ID id = N_VGetVectorID(vec);
+      long int length = -1;
+      switch (id)
+        {
+        case SUNDIALS_NVEC_SERIAL:
+        {
+          length = NV_LENGTH_S(vec);
+          break;
+        }
+        case SUNDIALS_NVEC_PARALLEL:
+        {
+          length = NV_LOCLENGTH_P(vec);
+          break;
+        }
+        default:
+          Assert(false, ExcNotImplemented());
+        }

-        Assert(length >= 0, ExcInternalError());
-        return static_cast<std::size_t>(length);
-      }
+      Assert(length >= 0, ExcInternalError());
+      return static_cast<std::size_t>(length);
     }

 #ifdef DEAL_II_WITH_MPI


Separate Best AI stats from game results


Handle Challenge improvements

Handle Challenge improvements

* Skip challenges if there is not a queued payload
* Remove queued payload after use

--- RF24Node.cpp
+++ RF24Node.cpp
@@ -119,6 +119,12 @@
     pkt_challenge_t payload;
     this->network.read(header, &payload, sizeof(payload));

+    if (this->queued_payloads.find(header.from_node) == this->queued_payloads.end() ||
+        this->queued_payloads[header.from_node].find(payload.type) == this->queued_payloads[header.from_node].end()) {
+        if (this->debug) printf("No queued payload for for node 0%o of payload type %d.\n", header.from_node, payload.type);
+        return;
+    }
+
     switch (payload.type) {
         case PKT_SWITCH:
             this->handle_send_switch(header.from_node, this->queued_payloads[header.from_node][payload.type], payload.challenge);
@@ -128,6 +134,7 @@
             break;
     }

+    this->queued_payloads[header.from_node].erase(payload.type);
 }

 /*


rank1_xword comments include bool and 8-bit

--- Rank1Ops.hpp
+++ Rank1Ops.hpp
@@ -197,7 +197,7 @@
 }

 ////////////////////////////////////////////////////////////////////////////////
-// convert between bitwise word types
+// bitwise conversion between unsigned integers and bool
 //

 template <typename FR>
@@ -209,14 +209,14 @@
     std::vector<snarklib::R1Term<FR>> v(returnSize, FR::zero());

     if (1 == x.size()) {
-        // convert bool to word
+        // convert bool to 8-bit, 32-bit, or 64-bit
         for (std::size_t i = 0; i < returnSize; ++i)
             v[i] = x[0];

     } else {
-        // convert between 32-bit and 64-bit words
+        // if destination type is bool, returnSize is 1 so takes 0th bit
+        // otherwise, bitwise slices between unsigned integer types
         const auto N = std::min(returnSize, x.size());
-
         for (std::size_t i = 0; i < N; ++i)
             v[i] = x[i];
     }


Implement connection methods.

Implement connection methods.

--- ReQL-CPP.cpp
+++ ReQL-CPP.cpp
@@ -21,3 +21,87 @@
 #include "ReQL-CPP.hpp"

 #include "ReQL.hpp"
+
+#include <cstdlib>
+
+using namespace ReQL;
+
+Connection::Connection() {
+  conn = (struct _ReQL_Conn_s *)new _ReQL_Conn_t();
+  conn = (struct _ReQL_Conn_s *)_reql_new_connection((_ReQL_Conn_t *)conn);
+
+  if (!conn) {
+    return;
+  }
+
+  char *buf;
+
+  if (_reql_connect((_ReQL_Conn_t *)conn, &buf)) {
+  }
+
+  free(buf);
+}
+
+Connection::Connection(std::string host) {
+  conn = (struct _ReQL_Conn_s *)new _ReQL_Conn_t();
+  conn = (struct _ReQL_Conn_s *)_reql_new_connection((_ReQL_Conn_t *)conn);
+
+  if (!conn) {
+    return;
+  }
+
+  char *buf;
+
+  if (_reql_connect((_ReQL_Conn_t *)conn, &buf)) {
+  }
+
+  free(buf);
+}
+
+Connection::Connection(std::string host, std::string port) {
+  conn = (struct _ReQL_Conn_s *)new _ReQL_Conn_t();
+  conn = (struct _ReQL_Conn_s *)_reql_new_connection((_ReQL_Conn_t *)conn);
+
+  if (!conn) {
+    return;
+  }
+
+  char *buf;
+
+  if (_reql_connect((_ReQL_Conn_t *)conn, &buf)) {
+  }
+
+  free(buf);
+}
+
+Connection::Connection(std::string host, std::string port, std::string key) {
+  conn = (struct _ReQL_Conn_s *)new _ReQL_Conn_t();
+  conn = (struct _ReQL_Conn_s *)_reql_new_connection((_ReQL_Conn_t *)conn);
+
+  if (!conn) {
+    return;
+  }
+
+  char *buf;
+
+  if (_reql_connect((_ReQL_Conn_t *)conn, &buf)) {
+  }
+
+  free(buf);
+}
+
+Connection connect() {
+  return Connection();
+}
+
+Connection connect(std::string host) {
+  return Connection(host);
+}
+
+Connection connect(std::string host, std::string port) {
+  return Connection(host, port);
+}
+
+Connection connect(std::string host, std::string port, std::string key) {
+  return Connection(host, port, key);
+}


neste record materialization...

neste record materialization...

--- RecordSet.cc
+++ RecordSet.cc
@@ -120,7 +120,7 @@

   if (!snap.datafile.isEmpty()) {
     cstable::CSTableReader reader(snap.datafile.get());
-    cstable::RecordMaterializer record_reader(schema_, &reader);
+    cstable::RecordMaterializer record_reader(schema_.get(), &reader);

     auto msgid_col_ref = reader.getColumnReader("__msgid");
     auto msgid_col = dynamic_cast<cstable::UInt64ColumnReader*>(msgid_col_ref.get());


trim \r at line end because ini can have Windows endings and prog is on Linux

--- StrTools.cpp
+++ StrTools.cpp
@@ -5,7 +5,7 @@
 //http://stackoverflow.com/questions/1798112/removing-leading-and-trailing-spaces-from-a-string
 string StrTools::trim(const string& str)
 {
-	const string whitespace = " \t";
+	const string whitespace = " \t\r";
 	const auto strBegin = str.find_first_not_of(whitespace);
 	if (strBegin == string::npos)
 		return ""; // no content
@@ -28,7 +28,7 @@

 string StrTools::trimRight(const string& str)
 {
-	const auto strEnd = str.find_last_not_of(" \t");
+	const auto strEnd = str.find_last_not_of(" \t\r");
 	if (strEnd == string::npos)
 		return ""; // no content
 	return str.substr(0, strEnd + 1);


Changes due change of the CalibDB interface (Marian)

--- TPC/recTPC.C
+++ TPC/recTPC.C
@@ -16,7 +16,7 @@
   AliCDBManager * man = AliCDBManager::Instance();
   man->SetDefaultStorage("local://$ALICE_ROOT");
   man->SetRun(0);
-  man->SetSpecificStorage("TPC","local:///afs/cern.ch/user/m/mivanov/public/Calib");
+  man->SetSpecificStorage("TPC/*/*","local:///afs/cern.ch/user/m/mivanov/public/Calib");
   //
   // Set reconstruction parameters
   //
@@ -31,7 +31,8 @@
   //
   //
   AliReconstruction rec;
-  rec.SetSpecificStorage("TPC","local:///afs/cern.ch/user/m/mivanov/public/Calib");
+  rec.SetDefaultStorage("local://$ALICE_ROOT");
+  rec.SetSpecificStorage("TPC/*/*","local:///afs/cern.ch/user/m/mivanov/public/Calib");
   rec.SetLoadAlignData("");
   rec.SetWriteESDfriend(kTRUE);
   rec.SetInput(filename);
@@ -57,7 +58,7 @@
   AliCDBManager * man = AliCDBManager::Instance();
   man->SetDefaultStorage("local://$ALICE_ROOT");
   man->SetRun(0);
-  man->SetSpecificStorage("TPC","local:///afs/cern.ch/user/m/mivanov/public/Calib");
+  man->SetSpecificStorage("TPC/*/*","local:///afs/cern.ch/user/m/mivanov/public/Calib");
   //
   // Set reconstruction parameters
   //
@@ -74,7 +75,7 @@
   //
   //
   AliReconstruction rec;
-  //rec.SetSpecificStorage("TPC","local:///afs/cern.ch/user/m/mivanov/public/Calib");
+  rec.SetSpecificStorage("TPC/*/*","local:///afs/cern.ch/user/m/mivanov/public/Calib");
   rec.SetLoadAlignData("");
   rec.SetWriteESDfriend(kTRUE);
   rec.SetInput(filename);


A little clarity running arrayprimitives test driver in verbose mode

--- groups/bsl/bslalg/bslalg_arrayprimitives.t.cpp
+++ groups/bsl/bslalg/bslalg_arrayprimitives.t.cpp
@@ -4401,10 +4401,10 @@
         if (verbose) printf("\t...with char.\n");                             \
         func<char>(true, true);                                               \
                                                                               \
-        if (verbose) printf("\t...with char.\n");                             \
+        if (verbose) printf("\t...with signed char.\n");                      \
         func<signed char>(true, true);                                        \
                                                                               \
-        if (verbose) printf("\t...with char.\n");                             \
+        if (verbose) printf("\t...with unsigned char.\n");                    \
         func<unsigned char>(true, true);                                      \
                                                                               \
         if (verbose) printf("\t...with short.\n");                            \
@@ -4452,9 +4452,6 @@
         if (verbose) printf("\t...with 'const int *'.\n");                    \
         func<const int *>(true, true);                                        \
                                                                               \
-        if (verbose) printf("\t...with 'FuncPtrType'.\n");                    \
-        func<FuncPtrType>(true, true);                                        \
-                                                                              \
         if (verbose) printf("\t...with 'FnPtrConvertibleType'.\n");           \
         func<FnPtrConvertibleType>(false, false);                             \
                                                                               \
@@ -4463,6 +4460,12 @@
                                                                               \
         if (verbose) printf("\tException test.\n");                           \
         func<T>(false, false, true);                                          \
+                                                                              \
+        if (verbose) printf("\t...with BitwiseMoveableTestType.\n");          \
+        func<BMT>(true, false, true);                                         \
+                                                                              \
+        if (verbose) printf("\t...with BitwiseCopyableTestType.\n");          \
+        func<BCT>(true, true, true);                                          \
     } while (false)

 //=============================================================================
@@ -4855,7 +4858,12 @@
         if (verbose) printf("\nTESTING 'copyConstruct'"
                             "\n=======================\n");

+        if (verbose) printf(
+                 "\nTesting 'copyConstruct(T *dstB, T *srcB, T *srcE, *a)'\n");
         GAUNTLET(testCopyConstruct);
+
+        if (verbose) printf(
+               "\nTesting 'copyConstruct(T *dstB, FWD_ITER, FWD_ITER, *a)'\n");
         GAUNTLET(testCopyConstructWithIterators);
       } break;
       case 2: {


ENH: Naming arrays.

ENH: Naming arrays.

--- graphics/vtkGlyph3D.cxx
+++ graphics/vtkGlyph3D.cxx
@@ -255,28 +255,33 @@
     {
     newScalars = (vtkScalars *) inScalars->MakeObject ();
     newScalars->Allocate(numPts*numSourcePts);
-    newScalarsData = newScalars->GetData ();
-    inScalarsData = inScalars->GetData ();
+    newScalarsData = newScalars->GetData();
+    inScalarsData = inScalars->GetData();
+    newScalarsData->SetName(inScalarsData->GetName());
     }
   else if ( (this->ColorMode == VTK_COLOR_BY_SCALE) && inScalars)
     {
     newScalars = vtkScalars::New();
     newScalars->Allocate(numPts*numSourcePts);
+    newScalars->GetData()->SetName("GlyphScale");
     }
   else if ( (this->ColorMode == VTK_COLOR_BY_VECTOR) && haveVectors)
     {
     newScalars = vtkScalars::New();
     newScalars->Allocate(numPts*numSourcePts);
+    newScalars->GetData()->SetName("VectorMagnitude");
     }
   if ( haveVectors )
     {
     newVectors = vtkVectors::New();
     newVectors->Allocate(numPts*numSourcePts);
+    newVectors->GetData()->SetName("GlyphVector");
     }
   if ( haveNormals )
     {
     newNormals = vtkNormals::New();
     newNormals->Allocate(numPts*numSourcePts);
+    newNormals->GetData()->SetName("Normals");
     }

   // Setting up for calls to PolyData::InsertNextCell()