Description: Remove dead stream insertion operators that break GCC 15 build
 Basis, ObserverHelper and TargetQuantumElectrons each defined a friend
 operator<< that referenced member variables which do not exist in the class
 (quantumNumbers_, electrons_, SpermutationInverse_, transform_, wavefunction_,
 totalElectrons, twiceJ, ...). These operators are never called anywhere in the
 code base and were evidently copied from DmrgSerializer. GCC 15 instantiates
 the friend template bodies and errors out on the non-existent members
 (-Wtemplate-body), causing an FTBFS. Remove the three dead operators.
Author: tangxiaofeng <tangxiaofeng@kylinos.cn>
Forwarded: not-needed
Last-Update: 2026-09-01

--- dmrgpp-6.06.orig/src/Engine/Basis.h
+++ dmrgpp-6.06/src/Engine/Basis.h
@@ -635,25 +635,6 @@ public:
 				UnonConst(row, col) = Uconst(row, perm[col]);
 	}
 
-	//! The operator<< is a friend
-	friend std::ostream& operator<<(std::ostream& os,
-	    const Basis<SparseMatrixType>& x)
-	{
-		os << "dmrgTransformed=" << x.dmrgTransformed_ << "\n";
-		os << "name=" << x.name_ << "\n";
-		os << "quantumNumbers\n";
-		os << x.quantumNumbers_;
-		os << "electrons\n";
-		os << x.electrons_;
-		os << "partition\n";
-		os << x.offsets_;
-		os << "permutation\n";
-		os << x.permutationVector_;
-		os << "block\n";
-		os << x.block_;
-		return os;
-	}
-
 	friend std::istream& operator>>(std::istream& is,
 	    Basis<SparseMatrixType>&)
 	{
--- dmrgpp-6.06.orig/src/Engine/ObserverHelper.h
+++ dmrgpp-6.06/src/Engine/ObserverHelper.h
@@ -311,23 +311,6 @@ public:
 		return withLegacyBugs_;
 	}
 
-	friend std::ostream& operator<<(std::ostream& os, ObserverHelper& p)
-	{
-		for (SizeType i = 0; i < p.SpermutationInverse_.size(); i++) {
-			os << "i=" << i << "\n";
-			os << "\tS.size=" << p.SpermutationInverse_[i].size();
-			os << " " << p.Spermutation_[i].size() << "\n";
-			os << "\tSE.size=" << p.SEpermutationInverse_[i].size();
-			os << " " << p.SEpermutation_[i].size() << "\n";
-			os << "\tElectrons.size=" << p.electrons_[i].size() << "\n";
-			os << "\tTransform=" << p.transform_[i].n_row() << "x";
-			os << p.transform_[i].n_col() << "\n";
-			os << "\tWF.size=" << p.wavefunction_[i].size() << "\n";
-		}
-
-		return os;
-	}
-
 private:
 
 	SizeType siteInternal(const LeftRightSuperType& lrs,
--- dmrgpp-6.06.orig/src/Engine/TargetQuantumElectrons.h
+++ dmrgpp-6.06/src/Engine/TargetQuantumElectrons.h
@@ -185,20 +185,8 @@ public:
 	}
 
 	//! Function that prints model parameters to stream os
-	friend std::ostream& operator<<(std::ostream& os,
-	    const TargetQuantumElectrons& p)
-	{
-		if (p.vqn_.size() == 0)
-			return os;
-		const QnType& qn = p.vqn_[0];
-		os << "TargetElectronsTotal=" << p.totalElectrons << "\n";
-		os << "TargetOther=" << p.other << "\n";
-		if (p.isSu2)
-			os << "TargetSpinTimesTwo=" << p.twiceJ << "\n";
-		if (p.vqn_.size() > 1)
-			os << "FIXME TODO: More than one qn found\n";
-		return os;
-	}
+	// (operator<< removed: it referenced non-existent members and
+	//  was never called; caused FTBFS with GCC 15 template-body check)
 
 private:
 
