*
* @see ConstantDataSequential::getAsString()
*/
-const char *LLVMGetAsString(LLVMValueRef c, size_t* out);
+const char *LLVMGetAsString(LLVMValueRef c, size_t *Length);
/**
* Create an anonymous ConstantStruct with the specified values.
* @param Len Memory address which will hold length of returned string.
* @return String data in MDString.
*/
-const char *LLVMGetMDString(LLVMValueRef V, unsigned* Len);
+const char *LLVMGetMDString(LLVMValueRef V, unsigned *Length);
/**
* Obtain the number of operands from an MDNode value.
return LLVMMDNodeInContext(LLVMGetGlobalContext(), Vals, Count);
}
-const char *LLVMGetMDString(LLVMValueRef V, unsigned* Len) {
+const char *LLVMGetMDString(LLVMValueRef V, unsigned *Length) {
if (const auto *MD = dyn_cast<MetadataAsValue>(unwrap(V)))
if (const MDString *S = dyn_cast<MDString>(MD->getMetadata())) {
- *Len = S->getString().size();
+ *Length = S->getString().size();
return S->getString().data();
}
- *Len = 0;
+ *Length = 0;
return nullptr;
}
return unwrap<ConstantDataSequential>(C)->isString();
}
-const char *LLVMGetAsString(LLVMValueRef C, size_t* Length) {
- StringRef str = unwrap<ConstantDataSequential>(C)->getAsString();
- *Length = str.size();
- return str.data();
+const char *LLVMGetAsString(LLVMValueRef C, size_t *Length) {
+ StringRef Str = unwrap<ConstantDataSequential>(C)->getAsString();
+ *Length = Str.size();
+ return Str.data();
}
LLVMValueRef LLVMConstArray(LLVMTypeRef ElementTy,