This is an archive of the discontinued LLVM Phabricator instance.

[LLVM-C] Use Length-Providing Value Name Getters and Setters
ClosedPublic

Authored by CodaFi on May 15 2018, 9:32 AM.

Details

Summary
  • Provide LLVMGetValueName2 and LLVMSetValueName2 that return and take the length of the provided C string respectively
  • Deprecate LLVMGetValueName and LLVMSetValueName

Diff Detail

Repository
rL LLVM

Event Timeline

CodaFi created this revision.May 15 2018, 9:32 AM
whitequark requested changes to this revision.May 17 2018, 12:41 AM

First, the naming here is absurdly confusing. Second, it's also inconsistent with all other functions, e.g. LLVMGetSourceFileName/LLVMSetSourceFileName.

Use LLVMGetValueName2 and LLVMSetValueName2, since this is what we do when updating function signatures in the C API.

This revision now requires changes to proceed.May 17 2018, 12:41 AM

First, the naming here is absurdly confusing. Second, it's also inconsistent with all other functions, e.g. LLVMGetSourceFileName/LLVMSetSourceFileName.

Use LLVMGetValueName2 and LLVMSetValueName2, since this is what we do when updating function signatures in the C API.

No problem. I'll update the names.

CodaFi updated this revision to Diff 147636.May 18 2018, 6:56 PM
CodaFi edited the summary of this revision. (Show Details)May 18 2018, 7:25 PM
whitequark accepted this revision.May 19 2018, 3:35 AM

Thanks!

This revision is now accepted and ready to land.May 19 2018, 3:35 AM
This revision was automatically updated to reflect the committed changes.