From dc94a3fac921acb31f8759b49f573880d4065b27 Mon Sep 17 00:00:00 2001 From: Thad House Date: Mon, 7 Nov 2016 19:35:48 -0800 Subject: [PATCH] Adds a size parameter to JStringRef (#152) Want to use that for some allwpilib JNI cleanups and potential bug fixes --- wpiutil/include/support/jni_util.h | 1 + 1 file changed, 1 insertion(+) diff --git a/wpiutil/include/support/jni_util.h b/wpiutil/include/support/jni_util.h index 32860a5..2564c13 100644 --- a/wpiutil/include/support/jni_util.h +++ b/wpiutil/include/support/jni_util.h @@ -90,6 +90,7 @@ class JStringRef { operator llvm::StringRef() const { return m_str; } llvm::StringRef str() const { return m_str; } const char* c_str() const { return m_str.data(); } + size_t size() const { return m_str.size(); } private: llvm::SmallString<128> m_str;