]> git.lyx.org Git - lyx.git/blobdiff - src/support/docstring.cpp
Use empty() to check empty and non-empty'ness not size()
[lyx.git] / src / support / docstring.cpp
index 30298b5f59a9a6e310847bcae490ee0c5e1597ee..c937ba3721a1157bd2acff7d0bc754b74b0e614e 100644 (file)
@@ -25,6 +25,7 @@
 
 using namespace std;
 
+using lyx::support::isHexChar;
 
 namespace lyx {
 
@@ -132,7 +133,7 @@ string const to_local8bit(docstring const & s)
        if (s.empty())
                return string();
        QByteArray const local = toqstr(s).toLocal8Bit();
-       if (local.size() == 0)
+       if (local.isEmpty())
                throw to_local8bit_failure();
        return string(local.begin(), local.end());
 }