style changes

This commit is contained in:
Katarzyna Miernikiewicz 2020-09-18 12:31:02 +00:00
parent bcdda46857
commit b806fa83a8
5 changed files with 18 additions and 19 deletions

View File

@ -56,4 +56,4 @@ target_include_directories(jsonnet_sapi INTERFACE
target_link_libraries(jsonnet_sapi PUBLIC jsonnet_helper)
add_subdirectory(tests)
add_subdirectory(tests)

View File

@ -64,4 +64,5 @@ target_link_libraries(jsonnet_base_transacted PRIVATE
jsonnet_helper
jsonnet_sapi
sapi::sapi
)
)

View File

@ -34,8 +34,8 @@ char* c_jsonnet_evaluate_snippet_multi(struct JsonnetVm* vm,
}
char* c_jsonnet_evaluate_snippet_stream(struct JsonnetVm* vm,
const char* filename,
const char* snippet, int* error) {
const char* filename,
const char* snippet, int* error) {
return jsonnet_evaluate_snippet_stream(vm, filename, snippet, error);
}
@ -58,7 +58,8 @@ bool c_write_output_file(const char* output, const char* output_file) {
return write_output_file(output, s_output_file);
}
bool c_write_multi_output_files(char* output, char* output_dir, bool show_output_file_names) {
bool c_write_multi_output_files(char* output, char* output_dir,
bool show_output_file_names) {
std::string s_output_dir(output_dir);
return write_multi_output_files(output, s_output_dir, show_output_file_names);
}
@ -72,6 +73,7 @@ char* c_jsonnet_realloc(struct JsonnetVm* vm, char* str, size_t sz) {
return jsonnet_realloc(vm, str, sz);
}
char* c_jsonnet_fmt_snippet(struct JsonnetVm* vm, const char* filename, const char* snippet, int* error) {
char* c_jsonnet_fmt_snippet(struct JsonnetVm* vm, const char* filename,
const char* snippet, int* error) {
return jsonnet_fmt_snippet(vm, filename, snippet, error);
}

View File

@ -46,21 +46,17 @@ extern "C" bool c_write_output_file(const char* output,
extern "C" char* c_jsonnet_realloc(struct JsonnetVm* vm, char* str, size_t sz);
extern "C" bool c_write_multi_output_files(//struct JsonnetVm* vm,
char* output,
char* output_dir, bool show_output_file_names);
extern "C" bool c_write_multi_output_files(
char* output, char* output_dir, bool show_output_file_names);
bool write_multi_output_files(//struct JsonnetVm* vm,
char* output,
const std::string& output_dir, bool show_output_file_names);
bool write_multi_output_files(
char* output, const std::string& output_dir, bool show_output_file_names);
extern "C" bool c_write_output_stream(//struct JsonnetVm* vm,
char* output,
char* output_file);
extern "C" bool c_write_output_stream(
char* output, char* output_file);
bool write_output_stream(//struct JsonnetVm* vm,
char* output,
const std::string& output_file);
bool write_output_stream(
char* output, const std::string& output_file);
extern "C" char* c_jsonnet_fmt_snippet(struct JsonnetVm* vm,
const char* filename,

View File

@ -105,4 +105,4 @@ TEST_F(JsonnetTest, Bad_evaluation) {
Read_input(input_file);
Evaluate_jsonnet_code(input_file, BASE, false);
}
}