Skip to content

Commit f4e7ebe

Browse files
committed
clang-format for files moved to ansi-c/
This is a separate commit for clang-formatting the files moved to ansi-c/.
1 parent a0eff20 commit f4e7ebe

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+1041
-1097
lines changed

src/ansi-c/builtin_functions.cpp

+189-199
Large diffs are not rendered by default.

src/ansi-c/c_nondet_symbol_factory.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,10 @@ Author: Diffblue Ltd.
1212
#ifndef CPROVER_ANSI_C_C_NONDET_SYMBOL_FACTORY_H
1313
#define CPROVER_ANSI_C_C_NONDET_SYMBOL_FACTORY_H
1414

15-
#include <set>
16-
1715
#include "allocate_objects.h"
1816

17+
#include <set>
18+
1919
struct c_object_factory_parameterst;
2020

2121
class symbol_factoryt

src/ansi-c/destructor.cpp

+9-9
Original file line numberDiff line numberDiff line change
@@ -10,33 +10,33 @@ Author: Daniel Kroening, [email protected]
1010
/// Destructor Calls
1111

1212
#include "destructor.h"
13-
#include <goto-programs/goto_instruction_code.h>
1413

1514
#include <util/namespace.h>
1615
#include <util/pointer_expr.h>
1716

18-
code_function_callt get_destructor(
19-
const namespacet &ns,
20-
const typet &type)
17+
#include <goto-programs/goto_instruction_code.h>
18+
19+
code_function_callt get_destructor(const namespacet &ns, const typet &type)
2120
{
2221
if(type.id() == ID_struct_tag)
2322
{
2423
return get_destructor(ns, ns.follow_tag(to_struct_tag_type(type)));
2524
}
26-
else if(type.id()==ID_struct)
25+
else if(type.id() == ID_struct)
2726
{
28-
const exprt &methods=static_cast<const exprt&>(type.find(ID_methods));
27+
const exprt &methods = static_cast<const exprt &>(type.find(ID_methods));
2928

3029
for(const auto &op : methods.operands())
3130
{
3231
if(op.type().id() == ID_code)
3332
{
3433
const code_typet &code_type = to_code_type(op.type());
3534

36-
if(code_type.return_type().id()==ID_destructor &&
37-
code_type.parameters().size()==1)
35+
if(
36+
code_type.return_type().id() == ID_destructor &&
37+
code_type.parameters().size() == 1)
3838
{
39-
const typet &arg_type=code_type.parameters().front().type();
39+
const typet &arg_type = code_type.parameters().front().type();
4040

4141
if(
4242
arg_type.id() == ID_pointer &&

src/ansi-c/destructor.h

+2-3
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,7 @@ Author: Daniel Kroening, [email protected]
1515
class namespacet;
1616
class typet;
1717

18-
class code_function_callt get_destructor(
19-
const namespacet &ns,
20-
const typet &type);
18+
class code_function_callt
19+
get_destructor(const namespacet &ns, const typet &type);
2120

2221
#endif // CPROVER_GOTO_PROGRAMS_DESTRUCTOR_H

0 commit comments

Comments
 (0)