MCPcopy Create free account
hub / github.com/HaxeFoundation/hxcpp / __ToDouble

Method __ToDouble

src/String.cpp:2498–2507  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2496 String __ToString() const HXCPP_OVERRIDE { return mValue; }
2497 String toString() HXCPP_OVERRIDE { return mValue; }
2498 double __ToDouble() const HXCPP_OVERRIDE
2499 {
2500 if (!mValue.raw_ptr()) return 0;
2501
2502 #ifdef HX_ANDROID
2503 return strtod(mValue.utf8_str(),0);
2504 #else
2505 return atof(mValue.utf8_str());
2506 #endif
2507 }
2508 int __length() const HXCPP_OVERRIDE { return mValue.length; }
2509
2510 void __Mark(hx::MarkContext *__inCtx) HXCPP_OVERRIDE

Callers

nothing calls this directly

Calls 2

atofFunction · 0.85
utf8_strMethod · 0.80

Tested by

no test coverage detected