diff options
author | murgatroid99 <mlumish@google.com> | 2017-11-06 13:13:20 -0800 |
---|---|---|
committer | murgatroid99 <mlumish@google.com> | 2017-11-06 13:13:20 -0800 |
commit | 6fb23dbc3d1b3ce4b366c4300a6e78afa3bcd566 (patch) | |
tree | ef9273a36b371d6646056c0d9f25a72474aaae56 /templates | |
parent | d02751aed1265e0d14c1058bc3dd15b6179f5dc7 (diff) | |
parent | 0f2cfdcc0f57d21fe2823268263ef5bdc4b6704c (diff) |
Merge branch 'master' into remove_node
Diffstat (limited to 'templates')
4 files changed, 23 insertions, 9 deletions
diff --git a/templates/src/core/lib/surface/version.cc.template b/templates/src/core/lib/surface/version.cc.template index d2efa565e5..d9fa4479db 100644 --- a/templates/src/core/lib/surface/version.cc.template +++ b/templates/src/core/lib/surface/version.cc.template @@ -23,6 +23,6 @@ #include <grpc/grpc.h> - const char *grpc_version_string(void) { return "${settings.core_version}"; } + const char* grpc_version_string(void) { return "${settings.core_version}"; } - const char *grpc_g_stands_for(void) { return "${settings.g_stands_for}"; } + const char* grpc_g_stands_for(void) { return "${settings.g_stands_for}"; } diff --git a/templates/src/cpp/common/version_cc.cc.template b/templates/src/cpp/common/version_cc.cc.template index d2e19fe264..9882878727 100644 --- a/templates/src/cpp/common/version_cc.cc.template +++ b/templates/src/cpp/common/version_cc.cc.template @@ -25,4 +25,4 @@ namespace grpc { grpc::string Version() { return "${settings.cpp_version}"; } - } + } // namespace grpc diff --git a/templates/test/core/surface/public_headers_must_be_c89.c.template b/templates/test/core/surface/public_headers_must_be_c89.c.template index dcaa59bb30..e2d3b1810a 100644 --- a/templates/test/core/surface/public_headers_must_be_c89.c.template +++ b/templates/test/core/surface/public_headers_must_be_c89.c.template @@ -35,9 +35,23 @@ assert(hdr[0:len(pfx)] == pfx) hdrs.add(hdr[len(pfx):]) hdrs = sorted(list(hdrs)) + fns = list() + for api in c_apis: + if is_platform_header(api.header): + continue + fns.append(api.name) %>\ % for hdr in hdrs: #include <${hdr}> % endfor - int main(int argc, char **argv) { return 0; } + #include <stdio.h> + + int main(int argc, char **argv) { + if(argc == 12345678) { + % for fn in fns: + printf("%lx", (unsigned long) ${fn}); + % endfor + } + return 0; + } diff --git a/templates/tools/dockerfile/clang_format.include b/templates/tools/dockerfile/clang_format.include index 81bd2be797..79d0ff286f 100644 --- a/templates/tools/dockerfile/clang_format.include +++ b/templates/tools/dockerfile/clang_format.include @@ -1,5 +1,5 @@ -RUN apt-get update && apt-get -y install wget -RUN echo "deb http://llvm.org/apt/jessie/ llvm-toolchain-jessie-3.8 main" >> /etc/apt/sources.list -RUN echo "deb-src http://llvm.org/apt/jessie/ llvm-toolchain-jessie-3.8 main" >> /etc/apt/sources.list -RUN wget -O - http://llvm.org/apt/llvm-snapshot.gpg.key | apt-key add - -RUN apt-get update && apt-get -y install clang-format-3.8 +RUN apt-get update && apt-get -y install wget xz-utils +RUN wget http://releases.llvm.org/5.0.0/clang+llvm-5.0.0-linux-x86_64-ubuntu14.04.tar.xz +RUN tar xf clang+llvm-5.0.0-linux-x86_64-ubuntu14.04.tar.xz +RUN ln -s /clang+llvm-5.0.0-linux-x86_64-ubuntu14.04/bin/clang-format /usr/local/bin/clang-format +ENV CLANG_FORMAT=clang-format |