aboutsummaryrefslogtreecommitdiff
path: root/cores/arduino/WString.h
diff options
context:
space:
mode:
authorIván Pérez <ivanperez2@gmail.com>2016-09-12 08:56:02 +0200
committerIván Pérez <ivanperez2@gmail.com>2016-09-12 08:56:02 +0200
commitb74a02cb217be5857afde7eb05ccdec686fe83f9 (patch)
tree23a88c9974d4d7a1d231e1c2e0ed5376a6bcf991 /cores/arduino/WString.h
parent0f959829ba264a8dabf726048fcee177bd58e1dc (diff)
WString: add `toDouble`
`toFloat` internally converts into double and then truncates into a float, so why not add a method to return the double?
Diffstat (limited to 'cores/arduino/WString.h')
-rw-r--r--cores/arduino/WString.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/cores/arduino/WString.h b/cores/arduino/WString.h
index de5632c..08b8147 100644
--- a/cores/arduino/WString.h
+++ b/cores/arduino/WString.h
@@ -190,6 +190,7 @@ public:
// parsing/conversion
long toInt(void) const;
float toFloat(void) const;
+ double toDouble(void) const;
protected:
char *buffer; // the actual char array