diff --git a/oss-internship-2020/jsonnet/examples/jsonnet_base_example.cc b/oss-internship-2020/jsonnet/examples/jsonnet_base_example.cc index 9c67a96..9682f47 100644 --- a/oss-internship-2020/jsonnet/examples/jsonnet_base_example.cc +++ b/oss-internship-2020/jsonnet/examples/jsonnet_base_example.cc @@ -15,9 +15,9 @@ #include #include -#include "jsonnet_base_sandbox.h" +#include "jsonnet_base_sandbox.h" // NOLINT(build/include) -absl::Status JsonnetMain(std::string in_file, std::string out_file){ +absl::Status JsonnetMain(std::string in_file, std::string out_file) { // Initialize sandbox. JsonnetBaseSandbox sandbox(in_file, out_file); SAPI_RETURN_IF_ERROR(sandbox.Init()) @@ -25,23 +25,24 @@ absl::Status JsonnetMain(std::string in_file, std::string out_file){ JsonnetApi api(&sandbox); // Initialize library's main structure. - SAPI_ASSIGN_OR_RETURN(JsonnetVm* jsonnet_vm, api.c_jsonnet_make()); + SAPI_ASSIGN_OR_RETURN(JsonnetVm * jsonnet_vm, api.c_jsonnet_make()); sapi::v::RemotePtr vm_pointer(jsonnet_vm); // Read input file. std::string in_file_in_sandboxee(std::string("/input/") + basename(&in_file[0])); sapi::v::ConstCStr in_file_var(in_file_in_sandboxee.c_str()); - SAPI_ASSIGN_OR_RETURN(char* input, api.c_read_input(false, in_file_var.PtrBefore())); + SAPI_ASSIGN_OR_RETURN(char* input, + api.c_read_input(false, in_file_var.PtrBefore())); // Process jsonnet data. sapi::v::RemotePtr input_pointer(input); sapi::v::Int error; SAPI_ASSIGN_OR_RETURN(char* output, api.c_jsonnet_evaluate_snippet( - &vm_pointer, in_file_var.PtrBefore(), &input_pointer, error.PtrAfter())); + &vm_pointer, in_file_var.PtrBefore(), + &input_pointer, error.PtrAfter())); CHECK(!error.GetValue()) - << "Jsonnet code evaluation failed: " - << error.GetValue() << "\n" + << "Jsonnet code evaluation failed: " << error.GetValue() << "\n" << "Make sure all files used by your jsonnet file are in the same " "directory as your file."; @@ -51,16 +52,18 @@ absl::Status JsonnetMain(std::string in_file, std::string out_file){ sapi::v::ConstCStr out_file_var(out_file_in_sandboxee.c_str()); sapi::v::RemotePtr output_pointer(output); - SAPI_ASSIGN_OR_RETURN(bool success, api.c_write_output_file(&output_pointer, out_file_var.PtrBefore())); + SAPI_ASSIGN_OR_RETURN( + bool success, + api.c_write_output_file(&output_pointer, out_file_var.PtrBefore())); CHECK(success) << "Writing to output file failed: " << success; // Clean up. - SAPI_ASSIGN_OR_RETURN(char* result, api.c_jsonnet_realloc(&vm_pointer, &output_pointer, 0)); + SAPI_ASSIGN_OR_RETURN(char* result, + api.c_jsonnet_realloc(&vm_pointer, &output_pointer, 0)); SAPI_RETURN_IF_ERROR(api.c_jsonnet_destroy(&vm_pointer)); SAPI_RETURN_IF_ERROR(api.c_free_input(&input_pointer)); return absl::OkStatus(); - } int main(int argc, char* argv[]) { @@ -81,7 +84,7 @@ int main(int argc, char* argv[]) { if (!status.ok()) { LOG(ERROR) << "Failed: " << status.ToString(); return EXIT_FAILURE; - } + } return EXIT_SUCCESS; } diff --git a/oss-internship-2020/jsonnet/examples/jsonnet_base_transaction.cc b/oss-internship-2020/jsonnet/examples/jsonnet_base_transaction.cc index b873636..3602ca2 100644 --- a/oss-internship-2020/jsonnet/examples/jsonnet_base_transaction.cc +++ b/oss-internship-2020/jsonnet/examples/jsonnet_base_transaction.cc @@ -12,7 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include "jsonnet_base_transaction.h" +#include "jsonnet_base_transaction.h" // NOLINT(build/include) absl::Status JsonnetTransaction::Main() { JsonnetApi api(sandbox()); diff --git a/oss-internship-2020/jsonnet/examples/jsonnet_formatter_example.cc b/oss-internship-2020/jsonnet/examples/jsonnet_formatter_example.cc index 6fc18ff..6e32dda 100644 --- a/oss-internship-2020/jsonnet/examples/jsonnet_formatter_example.cc +++ b/oss-internship-2020/jsonnet/examples/jsonnet_formatter_example.cc @@ -28,7 +28,7 @@ class JsonnetSapiSandbox : public JsonnetSandbox { // We need only the input file here, not the whole input directory std::unique_ptr ModifyPolicy( - sandbox2::PolicyBuilder *) override { + sandbox2::PolicyBuilder*) override { return sandbox2::PolicyBuilder() .AllowStaticStartup() .AllowOpen() @@ -51,70 +51,73 @@ class JsonnetSapiSandbox : public JsonnetSandbox { std::string out_file_; }; -int main(int argc, char *argv[]) { +absl::Status JsonnetMain(std::string in_file, std::string out_file) { + // Initialize sandbox. + JsonnetSapiSandbox sandbox(in_file, out_file); + SAPI_RETURN_IF_ERROR(sandbox.Init()) + + JsonnetApi api(&sandbox); + + // Initialize library's main structure. + SAPI_ASSIGN_OR_RETURN(JsonnetVm * jsonnet_vm, api.c_jsonnet_make()); + sapi::v::RemotePtr vm_pointer(jsonnet_vm); + + // Read input file. + std::string in_file_in_sandboxee(std::string("/input/") + + basename(&in_file[0])); + sapi::v::ConstCStr in_file_var(in_file_in_sandboxee.c_str()); + SAPI_ASSIGN_OR_RETURN(char* input, + api.c_read_input(false, in_file_var.PtrBefore())); + + // Process jsonnet data. + sapi::v::RemotePtr input_pointer(input); + sapi::v::Int error; + SAPI_ASSIGN_OR_RETURN(char* output, api.c_jsonnet_fmt_snippet( + &vm_pointer, in_file_var.PtrBefore(), + &input_pointer, error.PtrAfter())); + + CHECK(!error.GetValue()) << "Jsonnet code evaluation failed: " + << error.GetValue() << "\n"; + + // Write data to file. + std::string out_file_in_sandboxee(std::string("/output/") + + basename(&out_file[0])); + sapi::v::ConstCStr out_file_var(out_file_in_sandboxee.c_str()); + sapi::v::RemotePtr output_pointer(output); + + SAPI_ASSIGN_OR_RETURN( + bool success, + api.c_write_output_file(&output_pointer, out_file_var.PtrBefore())); + CHECK(success) << "Writing to output file failed: " << success; + + // Clean up. + SAPI_ASSIGN_OR_RETURN(char* result, + api.c_jsonnet_realloc(&vm_pointer, &output_pointer, 0)); + SAPI_RETURN_IF_ERROR(api.c_jsonnet_destroy(&vm_pointer)); + SAPI_RETURN_IF_ERROR(api.c_free_input(&input_pointer)); + + return absl::OkStatus(); +} + +int main(int argc, char* argv[]) { google::InitGoogleLogging(argv[0]); gflags::ParseCommandLineFlags(&argc, &argv, true); if (!(argc == 3)) { std::cerr << "Usage:\n" << basename(argv[0]) << " absolute/path/to/INPUT.jsonnet" - << " absolute/path/to/OUTPUT.jsonnet\n"; + << " absolute/path/to/OUTPUT\n"; return EXIT_FAILURE; } std::string in_file(argv[1]); std::string out_file(argv[2]); - // Initialize sandbox. - JsonnetSapiSandbox sandbox(in_file, out_file); - absl::Status status = sandbox.Init(); - CHECK(status.ok()) << "Sandbox initialization failed " << status; - - JsonnetApi api(&sandbox); - - // Initialize library's main structure. - sapi::StatusOr jsonnet_vm = api.c_jsonnet_make(); - sapi::v::RemotePtr vm_pointer(jsonnet_vm.value()); - CHECK(jsonnet_vm.ok()) << "JsonnetVm initialization failed: " - << jsonnet_vm.status(); - - // Read input file. - sapi::v::ConstCStr in_file_var(in_file.c_str()); - sapi::StatusOr input = - api.c_read_input(false, in_file_var.PtrBefore()); - CHECK(input.ok()) << "Reading input file failed " << input.status(); - - // Process jsonnet data. - sapi::v::RemotePtr input_pointer(input.value()); - sapi::v::Int error; - sapi::StatusOr output = api.c_jsonnet_fmt_snippet( - &vm_pointer, in_file_var.PtrBefore(), &input_pointer, error.PtrAfter()); - CHECK(output.ok() && !error.GetValue()) - << "Jsonnet code evaluation failed: " << output.status() << " " - << error.GetValue(); - - // Write data to file. - std::string out_file_in_sandboxee(std::string("/output/") + - basename(&out_file[0])); - sapi::v::ConstCStr out_file_var(out_file_in_sandboxee.c_str()); - sapi::v::RemotePtr output_pointer(output.value()); - sapi::StatusOr success; - - success = api.c_write_output_file(&output_pointer, out_file_var.PtrBefore()); - CHECK(success.ok() && success.value()) - << "Writing to output file failed " << success.status() << " " - << success.value(); - - // Clean up. - sapi::StatusOr result = - api.c_jsonnet_realloc(&vm_pointer, &output_pointer, 0); - CHECK(result.ok()) << "JsonnetVm realloc failed: " << result.status(); - - status = api.c_jsonnet_destroy(&vm_pointer); - CHECK(status.ok()) << "JsonnetVm destroy failed: " << status; - - status = api.c_free_input(&input_pointer); - CHECK(status.ok()) << "Input freeing failed: " << status; + absl::Status status = JsonnetMain(in_file, out_file); + if (!status.ok()) { + LOG(ERROR) << "Failed: " << status.ToString(); + return EXIT_FAILURE; + } return EXIT_SUCCESS; } diff --git a/oss-internship-2020/jsonnet/examples/jsonnet_multiple_files_example.cc b/oss-internship-2020/jsonnet/examples/jsonnet_multiple_files_example.cc index a4bcb54..0b5b17b 100644 --- a/oss-internship-2020/jsonnet/examples/jsonnet_multiple_files_example.cc +++ b/oss-internship-2020/jsonnet/examples/jsonnet_multiple_files_example.cc @@ -30,7 +30,7 @@ class JsonnetSapiSandbox : public JsonnetSandbox { // We need a slightly different policy than the default one std::unique_ptr ModifyPolicy( - sandbox2::PolicyBuilder *) override { + sandbox2::PolicyBuilder*) override { return sandbox2::PolicyBuilder() .AllowStaticStartup() .AllowOpen() @@ -55,73 +55,74 @@ class JsonnetSapiSandbox : public JsonnetSandbox { std::string out_directory_; }; -int main(int argc, char *argv[]) { +absl::Status JsonnetMain(std::string in_file, std::string out_file) { + // Initialize sandbox. + JsonnetSapiSandbox sandbox(in_file, out_file); + SAPI_RETURN_IF_ERROR(sandbox.Init()) + + JsonnetApi api(&sandbox); + + // Initialize library's main structure. + SAPI_ASSIGN_OR_RETURN(JsonnetVm * jsonnet_vm, api.c_jsonnet_make()); + sapi::v::RemotePtr vm_pointer(jsonnet_vm); + + // Read input file. + std::string in_file_in_sandboxee(std::string("/input/") + + basename(&in_file[0])); + sapi::v::ConstCStr in_file_var(in_file_in_sandboxee.c_str()); + SAPI_ASSIGN_OR_RETURN(char* input, + api.c_read_input(false, in_file_var.PtrBefore())); + + // Process jsonnet data. + sapi::v::RemotePtr input_pointer(input); + sapi::v::Int error; + SAPI_ASSIGN_OR_RETURN(char* output, api.c_jsonnet_evaluate_snippet_multi( + &vm_pointer, in_file_var.PtrBefore(), + &input_pointer, error.PtrAfter())); + CHECK(!error.GetValue()) + << "Jsonnet code evaluation failed: " << error.GetValue() << "\n" + << "Make sure all files used by your jsonnet file are in the same " + "directory as your file."; + + // Write data to file. + std::string out_file_in_sandboxee(std::string("/output/") + + basename(&out_file[0])); + sapi::v::ConstCStr out_file_var(out_file_in_sandboxee.c_str()); + sapi::v::RemotePtr output_pointer(output); + + SAPI_ASSIGN_OR_RETURN( + bool success, + api.c_write_output_file(&output_pointer, out_file_var.PtrBefore())); + CHECK(success) << "Writing to output file failed: " << success; + + // Clean up. + SAPI_ASSIGN_OR_RETURN(char* result, + api.c_jsonnet_realloc(&vm_pointer, &output_pointer, 0)); + SAPI_RETURN_IF_ERROR(api.c_jsonnet_destroy(&vm_pointer)); + SAPI_RETURN_IF_ERROR(api.c_free_input(&input_pointer)); + + return absl::OkStatus(); +} + +int main(int argc, char* argv[]) { google::InitGoogleLogging(argv[0]); gflags::ParseCommandLineFlags(&argc, &argv, true); if (!(argc == 3)) { std::cerr << "Usage:\n" << basename(argv[0]) << " absolute/path/to/INPUT.jsonnet" - << " absolute/path/to/OUTPUT_DIRECTORY\n"; + << " absolute/path/to/OUTPUT\n"; return EXIT_FAILURE; } std::string in_file(argv[1]); - std::string out_directory(argv[2]); + std::string out_file(argv[2]); - // Initialize sandbox. - JsonnetSapiSandbox sandbox(in_file, out_directory); - absl::Status status = sandbox.Init(); - CHECK(status.ok()) << "Sandbox initialization failed " << status; - - JsonnetApi api(&sandbox); - - // Initialize library's main structure. - sapi::StatusOr jsonnet_vm = api.c_jsonnet_make(); - sapi::v::RemotePtr vm_pointer(jsonnet_vm.value()); - CHECK(jsonnet_vm.ok()) << "JsonnetVm initialization failed: " - << jsonnet_vm.status(); - - // Read input file. - std::string in_file_in_sandboxee(std::string("/input/") + - basename(&in_file[0])); - sapi::v::ConstCStr in_file_var(in_file_in_sandboxee.c_str()); - sapi::StatusOr input = - api.c_read_input(false, in_file_var.PtrBefore()); - CHECK(input.ok()) << "Reading input file failed " << input.status(); - - // Process jsonnet data. - sapi::v::RemotePtr input_pointer(input.value()); - sapi::v::Int error; - sapi::StatusOr output = api.c_jsonnet_evaluate_snippet_multi( - &vm_pointer, in_file_var.PtrBefore(), &input_pointer, error.PtrAfter()); - CHECK(output.ok() && !error.GetValue()) - << "Jsonnet code evaluation failed: " << output.status() << " " - << error.GetValue() << "\n" - << "Make sure all files used by your jsonnet file are in the same " - "directory as your file."; - - // Write data to file. - std::string out_file_in_sandboxee(std::string("/output/")); - sapi::v::ConstCStr out_file_var(out_file_in_sandboxee.c_str()); - sapi::v::RemotePtr output_pointer(output.value()); - sapi::StatusOr success = api.c_write_multi_output_files( - &output_pointer, out_file_var.PtrBefore(), true); - - CHECK(success.ok() && success.value()) - << "Writing to output file failed " << success.status() << " " - << success.value(); - - // Clean up. - sapi::StatusOr result = - api.c_jsonnet_realloc(&vm_pointer, &output_pointer, 0); - CHECK(result.ok()) << "JsonnetVm realloc failed: " << result.status(); - - status = api.c_jsonnet_destroy(&vm_pointer); - CHECK(status.ok()) << "JsonnetVm destroy failed: " << status; - - status = api.c_free_input(&input_pointer); - CHECK(status.ok()) << "Input freeing failed: " << status; + absl::Status status = JsonnetMain(in_file, out_file); + if (!status.ok()) { + LOG(ERROR) << "Failed: " << status.ToString(); + return EXIT_FAILURE; + } return EXIT_SUCCESS; } diff --git a/oss-internship-2020/jsonnet/examples/jsonnet_yaml_stream_example.cc b/oss-internship-2020/jsonnet/examples/jsonnet_yaml_stream_example.cc index 216e033..7747065 100644 --- a/oss-internship-2020/jsonnet/examples/jsonnet_yaml_stream_example.cc +++ b/oss-internship-2020/jsonnet/examples/jsonnet_yaml_stream_example.cc @@ -15,9 +15,58 @@ #include #include -#include "jsonnet_base_sandbox.h" +#include "jsonnet_base_sandbox.h" // NOLINT(build/include) -int main(int argc, char *argv[]) { +absl::Status JsonnetMain(std::string in_file, std::string out_file) { + // Initialize sandbox. + JsonnetBaseSandbox sandbox(in_file, out_file); + SAPI_RETURN_IF_ERROR(sandbox.Init()) + + JsonnetApi api(&sandbox); + + // Initialize library's main structure. + SAPI_ASSIGN_OR_RETURN(JsonnetVm * jsonnet_vm, api.c_jsonnet_make()); + sapi::v::RemotePtr vm_pointer(jsonnet_vm); + + // Read input file. + std::string in_file_in_sandboxee(std::string("/input/") + + basename(&in_file[0])); + sapi::v::ConstCStr in_file_var(in_file_in_sandboxee.c_str()); + SAPI_ASSIGN_OR_RETURN(char* input, + api.c_read_input(false, in_file_var.PtrBefore())); + + // Process jsonnet data. + sapi::v::RemotePtr input_pointer(input); + sapi::v::Int error; + SAPI_ASSIGN_OR_RETURN(char* output, api.c_jsonnet_evaluate_snippet_stream( + &vm_pointer, in_file_var.PtrBefore(), + &input_pointer, error.PtrAfter())); + CHECK(!error.GetValue()) + << "Jsonnet code evaluation failed: " << error.GetValue() << "\n" + << "Make sure all files used by your jsonnet file are in the same " + "directory as your file."; + + // Write data to file. + std::string out_file_in_sandboxee(std::string("/output/") + + basename(&out_file[0])); + sapi::v::ConstCStr out_file_var(out_file_in_sandboxee.c_str()); + sapi::v::RemotePtr output_pointer(output); + + SAPI_ASSIGN_OR_RETURN( + bool success, + api.c_write_output_file(&output_pointer, out_file_var.PtrBefore())); + CHECK(success) << "Writing to output file failed: " << success; + + // Clean up. + SAPI_ASSIGN_OR_RETURN(char* result, + api.c_jsonnet_realloc(&vm_pointer, &output_pointer, 0)); + SAPI_RETURN_IF_ERROR(api.c_jsonnet_destroy(&vm_pointer)); + SAPI_RETURN_IF_ERROR(api.c_free_input(&input_pointer)); + + return absl::OkStatus(); +} + +int main(int argc, char* argv[]) { google::InitGoogleLogging(argv[0]); gflags::ParseCommandLineFlags(&argc, &argv, true); @@ -31,61 +80,11 @@ int main(int argc, char *argv[]) { std::string in_file(argv[1]); std::string out_file(argv[2]); - // Initialize sandbox. - JsonnetBaseSandbox sandbox(in_file, out_file); - absl::Status status = sandbox.Init(); - CHECK(status.ok()) << "Sandbox initialization failed " << status; - - JsonnetApi api(&sandbox); - - // Initialize library's main structure. - sapi::StatusOr jsonnet_vm = api.c_jsonnet_make(); - sapi::v::RemotePtr vm_pointer(jsonnet_vm.value()); - CHECK(jsonnet_vm.ok()) << "JsonnetVm initialization failed: " - << jsonnet_vm.status(); - - // Read input file. - std::string in_file_in_sandboxee(std::string("/input/") + - basename(&in_file[0])); - sapi::v::ConstCStr in_file_var(in_file_in_sandboxee.c_str()); - sapi::StatusOr input = - api.c_read_input(false, in_file_var.PtrBefore()); - CHECK(input.ok()) << "Reading input file failed " << input.status(); - - // Process jsonnet data. - sapi::v::RemotePtr input_pointer(input.value()); - sapi::v::Int error; - sapi::StatusOr output = api.c_jsonnet_evaluate_snippet_stream( - &vm_pointer, in_file_var.PtrBefore(), &input_pointer, error.PtrAfter()); - CHECK(output.ok() && !error.GetValue()) - << "Jsonnet code evaluation failed: " << output.status() << " " - << error.GetValue() << "\n" - << "Make sure all files used by your jsonnet file are in the same " - "directory as your file."; - - // Write data to file. - std::string out_file_in_sandboxee(std::string("/output/") + - basename(&out_file[0])); - sapi::v::ConstCStr out_file_var(out_file_in_sandboxee.c_str()); - sapi::v::RemotePtr output_pointer(output.value()); - sapi::StatusOr success; - - success = - api.c_write_output_stream(&output_pointer, out_file_var.PtrBefore()); - CHECK(success.ok() && success.value()) - << "Writing to output file failed " << success.status() << " " - << success.value(); - - // Clean up. - sapi::StatusOr result = - api.c_jsonnet_realloc(&vm_pointer, &output_pointer, 0); - CHECK(result.ok()) << "JsonnetVm realloc failed: " << result.status(); - - status = api.c_jsonnet_destroy(&vm_pointer); - CHECK(status.ok()) << "JsonnetVm destroy failed: " << status; - - status = api.c_free_input(&input_pointer); - CHECK(status.ok()) << "Input freeing failed: " << status; + absl::Status status = JsonnetMain(in_file, out_file); + if (!status.ok()) { + LOG(ERROR) << "Failed: " << status.ToString(); + return EXIT_FAILURE; + } return EXIT_SUCCESS; } diff --git a/oss-internship-2020/jsonnet/headers/jsonnet_base_transaction.h b/oss-internship-2020/jsonnet/headers/jsonnet_base_transaction.h index 9dfedc5..d47f30d 100644 --- a/oss-internship-2020/jsonnet/headers/jsonnet_base_transaction.h +++ b/oss-internship-2020/jsonnet/headers/jsonnet_base_transaction.h @@ -12,7 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include "jsonnet_base_sandbox.h" +#include "jsonnet_base_sandbox.h" // NOLINT(build/include) class JsonnetTransaction : public sapi::Transaction { public: diff --git a/oss-internship-2020/jsonnet/headers/jsonnet_tests.h b/oss-internship-2020/jsonnet/headers/jsonnet_tests.h index f09bc02..ea89c9f 100644 --- a/oss-internship-2020/jsonnet/headers/jsonnet_tests.h +++ b/oss-internship-2020/jsonnet/headers/jsonnet_tests.h @@ -21,7 +21,7 @@ #include #include "gtest/gtest.h" -#include "jsonnet_base_sandbox.h" +#include "jsonnet_base_sandbox.h" // NOLINT(build/include) #include "jsonnet_sapi.sapi.h" #include "sandboxed_api/util/flag.h" #include "sandboxed_api/util/status_matchers.h" diff --git a/oss-internship-2020/jsonnet/jsonnet.patch b/oss-internship-2020/jsonnet/jsonnet.patch index 288337d..57f1812 100644 --- a/oss-internship-2020/jsonnet/jsonnet.patch +++ b/oss-internship-2020/jsonnet/jsonnet.patch @@ -1,5 +1,5 @@ --- jsonnet.cpp 2020-09-09 12:15:33.687539042 +0000 -+++ write_helper.cpp 2020-09-17 15:35:02.684743876 +0000 ++++ write_helper.cpp 2020-09-25 15:38:37.317147682 +0000 @@ -14,559 +14,125 @@ limitations under the License. */ @@ -20,7 +20,7 @@ #include -#include "utils.h" -+#include "jsonnet_helper.h" ++#include "jsonnet_helper.h" // NOLINT(build/include) -extern "C" { -#include diff --git a/oss-internship-2020/jsonnet/jsonnet_helper.cc b/oss-internship-2020/jsonnet/jsonnet_helper.cc index 1832580..15e8cf9 100644 --- a/oss-internship-2020/jsonnet/jsonnet_helper.cc +++ b/oss-internship-2020/jsonnet/jsonnet_helper.cc @@ -12,7 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include "jsonnet_helper.h" +#include "jsonnet_helper.h" // NOLINT(build/include) #include diff --git a/oss-internship-2020/jsonnet/jsonnet_helper.h b/oss-internship-2020/jsonnet/jsonnet_helper.h index f74a897..84c6804 100644 --- a/oss-internship-2020/jsonnet/jsonnet_helper.h +++ b/oss-internship-2020/jsonnet/jsonnet_helper.h @@ -12,11 +12,11 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include "jsonnet/cmd/utils.h" +#include "jsonnet/cmd/utils.h" // NOLINT(build/include) extern "C" { -#include -#include +#include // NOLINT(build/include) +#include // NOLINT(build/include) } extern "C" struct JsonnetVm* c_jsonnet_make(void);