[PATCH] D39903: [libclang] Allow pretty printing declarations
Jonathan B Coe via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Jan 11 00:29:33 PST 2018
jbcoe added inline comments.
================
Comment at: include/clang-c/Index.h:4118
+ */
+CINDEX_LINKAGE unsigned clang_PrintingPolicy_getIndentation(CXPrintingPolicy);
+
----------------
Could one use an enum to get/set different properties of the policy?
```
clang_PrintingPolicy_get(CXPrintingPolicy Policy, unsigned Property);
clang_PrintingPolicy_set(CXPrintingPolicy Policy, unsigned Property, unsigned Value);
```
I've seen other C-API's (for Linear and Quadratic programming) follow a similar approach quite extensibly.
It would significantly reduce the size of the API.
Repository:
rC Clang
https://reviews.llvm.org/D39903
More information about the cfe-commits
mailing list