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












SourceForge.net Logo
Home » U++ Library support » U++ Core » LoadFile("/sys/devices/virtual/thermal/ ...") does not work
Re: LoadFile("/sys/devices/virtual/thermal/ ...") does not work [message #58416 is a reply to message #58413] Wed, 18 May 2022 11:04 Go to previous messageGo to previous message
mirek is currently offline  mirek
Messages: 13975
Registered: November 2005
Ultimate Member
Tom1 wrote on Wed, 18 May 2022 10:47
mirek wrote on Wed, 18 May 2022 11:29
Empty file issue fixed (with len >= 0).

Not sure what do you mean with IsVoid problem, piece of code maybe?

OK, I found the reason causing part of my testing issues:
	if(String::GetVoid().IsVoid()) Cout() << "String::GetVoid().IsVoid() works!\n";
	else Cout() << "String::GetVoid().IsVoid() fails!\n";
	if(IsVoid(String::GetVoid())) Cout() << "IsVoid(String::GetVoid()) works!\n";
	else Cout() << "IsVoid(String::GetVoid()) fails!\n";



Best regards,

Tom

EDIT: Improved test code.


Uhm, that is actually API problem:

IsVoid(const Value&) function is about Value - it tells you that Value was not assigned anything. In above example you assign it a String, so it must return false.

I agree this is a bit confusing, but I am not sure there is a solution to that.

Mirek
 
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
Read Message
Read Message
Read Message
Read Message
Previous Topic: BiArray::Create{Head,Tail} with variadic args
Next Topic: Serialize long as uint64 on some platforms
Goto Forum:
  


Current Time: Sun Apr 28 07:13:00 CEST 2024

Total time taken to generate the page: 0.04942 seconds