security manager conflict commented

Dependencies:   BLE_API mbed-dev-bin nRF51822

Fork of microbit-dal by Lancaster University

Revision:
52:3db7b4d64316
Parent:
51:9198e7bb83dc
Child:
69:b62f231e51ce
--- a/source/types/ManagedString.cpp	Wed Jul 13 12:18:30 2016 +0100
+++ b/source/types/ManagedString.cpp	Wed Jul 13 12:18:31 2016 +0100
@@ -437,9 +437,10 @@
 }
 
 /**
-  * Concatenates this string with the one provided.
+  * Concatenates two strings.
   *
-  * @param s The ManagedString to concatenate.
+  * @param lhs The first ManagedString to concatenate.
+  * @param rhs The second ManagedString to concatenate.
   *
   * @return a new ManagedString representing the joined strings.
   *
@@ -451,16 +452,17 @@
   * display.scroll(s + p) // scrolls "abcdefgh"
   * @endcode
   */
-ManagedString ManagedString::operator+ (const ManagedString& s)
+ManagedString operator+ (const ManagedString& lhs, const ManagedString& rhs)
 {
-    // If the other string is empty, nothing to do!
-    if(s.length() == 0)
-        return *this;
+
+    // If the either string is empty, nothing to do!
+    if (rhs.length() == 0)
+        return lhs;
 
-    if (length() == 0)
-        return s;
+    if (lhs.length() == 0)
+        return rhs;
 
-    return ManagedString(*this, s);
+    return ManagedString(lhs, rhs);
 }