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












SourceForge.net Logo
Home » Extra libraries, Code snippets, applications etc. » C++ language problems and code snippets » Make THISFN simpler and more powerful (by taking advantage of some new c++ feature)
Re: Make THISFN simpler and more powerful [message #59154 is a reply to message #59153] Thu, 10 November 2022 06:29 Go to previous messageGo to previous message
Oblivion is currently offline  Oblivion
Messages: 1214
Registered: August 2007
Senior Contributor
Maybe a combination of is_constructibles can help here:

using namespace Upp;

struct A {
	A(A&&) = delete;
	A&& operator=(A&&) = delete;
};

CONSOLE_APP_MAIN
{
	StdLogSetup(LOG_COUT);
	
	bool a = std::is_constructible_v<Rect, Rect&&>;
	bool b = std::is_constructible_v<String, String&&>;
	bool c = std::is_constructible_v<A, A&&>;
	RLOG(a);
	RLOG(b);
	RLOG(c);
}



Best regards,
Oblivion


[Updated on: Thu, 10 November 2022 06:30]

Report message to a moderator

 
Read Message icon10.gif
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Math - GaussJordan function
Next Topic: Clang cannot find DLLs
Goto Forum:
  


Current Time: Thu Jul 03 03:30:43 CEST 2025

Total time taken to generate the page: 0.03202 seconds