Skip to content

Commit 8adb25a

Browse files
author
Joel Allred
committed
Further documentation corrections
1 parent 6de9d25 commit 8adb25a

File tree

1 file changed

+35
-40
lines changed

1 file changed

+35
-40
lines changed

src/util/std_expr.h

Lines changed: 35 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ Author: Daniel Kroening, [email protected]
1818
#include "expr_cast.h"
1919

2020

21-
/// transition system, consisting of state invariant, initial state predicate,
21+
/// Transition system, consisting of state invariant, initial state predicate,
2222
/// and transition predicate.
2323
class transt:public exprt
2424
{
@@ -80,20 +80,17 @@ class symbol_exprt:public exprt
8080
{
8181
}
8282

83-
/// Constructor
8483
/// \param identifier: Name of symbol
8584
explicit symbol_exprt(const irep_idt &identifier):exprt(ID_symbol)
8685
{
8786
set_identifier(identifier);
8887
}
8988

90-
/// Constructor
9189
/// \param type: Type of symbol
9290
explicit symbol_exprt(const typet &type):exprt(ID_symbol, type)
9391
{
9492
}
9593

96-
/// Constructor
9794
/// \param identifier: Name of symbol
9895
/// \param type: Type of symbol
9996
symbol_exprt(
@@ -114,7 +111,7 @@ class symbol_exprt:public exprt
114111
}
115112
};
116113

117-
/// Expression to hold a symbol (variable) with extra ccessors to
114+
/// Expression to hold a symbol (variable) with extra accessors to
118115
/// ID_c_static_lifetime and ID_C_thread_local
119116
class decorated_symbol_exprt:public symbol_exprt
120117
{
@@ -123,21 +120,18 @@ class decorated_symbol_exprt:public symbol_exprt
123120
{
124121
}
125122

126-
/// Constructor
127123
/// \param identifier: Name of symbol
128124
explicit decorated_symbol_exprt(const irep_idt &identifier):
129125
symbol_exprt(identifier)
130126
{
131127
}
132128

133-
/// Constructor
134129
/// \param type: Type of symbol
135130
explicit decorated_symbol_exprt(const typet &type):
136131
symbol_exprt(type)
137132
{
138133
}
139134

140-
/// Constructor
141135
/// \param identifier: Name of symbol
142136
/// \param : type Type of symbol
143137
decorated_symbol_exprt(
@@ -213,7 +207,6 @@ inline void validate_expr(const symbol_exprt &value)
213207
class nondet_symbol_exprt:public exprt
214208
{
215209
public:
216-
/// \brief Constructor
217210
/// \param identifier: Name of symbol
218211
/// \param : type Type of symbol
219212
nondet_symbol_exprt(
@@ -345,7 +338,7 @@ template<> inline bool can_cast_expr<unary_exprt>(const exprt &base)
345338
}
346339

347340

348-
/// \brief absolute value
341+
/// \brief Absolute value
349342
class abs_exprt:public unary_exprt
350343
{
351344
public:
@@ -547,7 +540,7 @@ class predicate_exprt:public exprt
547540
};
548541

549542
/// \brief A generic base class for expressions that are predicates,
550-
/// i.e., boolean-typed, and that take exactly one argument.
543+
/// i.e., Boolean-typed, and that take exactly one argument.
551544
class unary_predicate_exprt:public unary_exprt
552545
{
553546
public:
@@ -571,7 +564,7 @@ class unary_predicate_exprt:public unary_exprt
571564
using exprt::op2; // hide
572565
};
573566

574-
/// \brief sign of an expression
567+
/// \brief Sign of an expression
575568
/// Predicate is true if \a _op is negative, false otherwise.
576569
class sign_exprt:public unary_predicate_exprt
577570
{
@@ -661,7 +654,7 @@ template<> inline bool can_cast_expr<binary_exprt>(const exprt &base)
661654

662655

663656
/// \brief A generic base class for expressions that are predicates,
664-
/// i.e., boolean-typed, and that take exactly two arguments.
657+
/// i.e., Boolean-typed, and that take exactly two arguments.
665658
class binary_predicate_exprt:public binary_exprt
666659
{
667660
public:
@@ -755,6 +748,7 @@ template<> inline bool can_cast_expr<binary_relation_exprt>(const exprt &base)
755748

756749

757750
/// \brief A generic base class for multi-ary expressions
751+
/// Associativity is not specified.
758752
class multi_ary_exprt:public exprt
759753
{
760754
public:
@@ -812,6 +806,7 @@ inline multi_ary_exprt &to_multi_ary_expr(exprt &expr)
812806

813807

814808
/// \brief The plus expression
809+
/// Associativity is not specified.
815810
class plus_exprt:public multi_ary_exprt
816811
{
817812
public:
@@ -871,7 +866,7 @@ inline void validate_expr(const plus_exprt &value)
871866
}
872867

873868

874-
/// \brief binary minus
869+
/// \brief Binary minus
875870
class minus_exprt:public binary_exprt
876871
{
877872
public:
@@ -923,7 +918,8 @@ inline void validate_expr(const minus_exprt &value)
923918
}
924919

925920

926-
/// \brief binary multiplication
921+
/// \brief Binary multiplication
922+
/// Associativity is not specified.
927923
class mult_exprt:public multi_ary_exprt
928924
{
929925
public:
@@ -975,7 +971,7 @@ inline void validate_expr(const mult_exprt &value)
975971
}
976972

977973

978-
/// \brief division (integer and real)
974+
/// \brief Division
979975
class div_exprt:public binary_exprt
980976
{
981977
public:
@@ -1027,7 +1023,7 @@ inline void validate_expr(const div_exprt &value)
10271023
}
10281024

10291025

1030-
/// \brief modulo
1026+
/// \brief Modulo
10311027
class mod_exprt:public binary_exprt
10321028
{
10331029
public:
@@ -1075,7 +1071,7 @@ inline void validate_expr(const mod_exprt &value)
10751071
}
10761072

10771073

1078-
/// \brief remainder of division
1074+
/// \brief Remainder of division
10791075
class rem_exprt:public binary_exprt
10801076
{
10811077
public:
@@ -1123,8 +1119,7 @@ inline void validate_expr(const rem_exprt &value)
11231119
}
11241120

11251121

1126-
/// \brief exponentiation
1127-
////
1122+
/// \brief Exponentiation
11281123
class power_exprt:public binary_exprt
11291124
{
11301125
public:
@@ -1172,7 +1167,7 @@ inline void validate_expr(const power_exprt &value)
11721167
}
11731168

11741169

1175-
/// \brief falling factorial power
1170+
/// \brief Falling factorial power
11761171
class factorial_power_exprt:public binary_exprt
11771172
{
11781173
public:
@@ -1225,7 +1220,7 @@ inline void validate_expr(const factorial_power_exprt &value)
12251220
}
12261221

12271222

1228-
/// \brief equality
1223+
/// \brief Equality
12291224
class equal_exprt:public binary_relation_exprt
12301225
{
12311226
public:
@@ -1271,7 +1266,7 @@ inline void validate_expr(const equal_exprt &value)
12711266
}
12721267

12731268

1274-
/// \brief inequality
1269+
/// \brief Disequality
12751270
class notequal_exprt:public binary_relation_exprt
12761271
{
12771272
public:
@@ -1321,7 +1316,7 @@ inline void validate_expr(const notequal_exprt &value)
13211316
}
13221317

13231318

1324-
/// \brief array index operator
1319+
/// \brief Array index operator
13251320
class index_exprt:public binary_exprt
13261321
{
13271322
public:
@@ -1525,7 +1520,7 @@ inline void validate_expr(const array_list_exprt &value)
15251520
PRECONDITION(value.operands().size() % 2 == 0);
15261521
}
15271522

1528-
/// \brief vector constructor from list of elements
1523+
/// \brief Vector constructor from list of elements
15291524
class vector_exprt:public exprt
15301525
{
15311526
public:
@@ -1565,7 +1560,7 @@ template<> inline bool can_cast_expr<vector_exprt>(const exprt &base)
15651560
}
15661561

15671562

1568-
/// \brief union constructor from single element
1563+
/// \brief Union constructor from single element
15691564
class union_exprt:public unary_exprt
15701565
{
15711566
public:
@@ -1644,7 +1639,7 @@ inline void validate_expr(const union_exprt &value)
16441639
}
16451640

16461641

1647-
/// \brief struct constructor from list of elements
1642+
/// \brief Struct constructor from list of elements
16481643
class struct_exprt:public exprt
16491644
{
16501645
public:
@@ -1687,7 +1682,7 @@ template<> inline bool can_cast_expr<struct_exprt>(const exprt &base)
16871682
}
16881683

16891684

1690-
/// \brief complex constructor from a pair of numbers
1685+
/// \brief Complex constructor from a pair of numbers
16911686
class complex_exprt:public binary_exprt
16921687
{
16931688
public:
@@ -1765,7 +1760,7 @@ inline void validate_expr(const complex_exprt &value)
17651760

17661761
class namespacet;
17671762

1768-
/// \brief split an expression into a base object and a (byte) offset
1763+
/// \brief Split an expression into a base object and a (byte) offset
17691764
class object_descriptor_exprt:public binary_exprt
17701765
{
17711766
public:
@@ -1838,7 +1833,7 @@ inline void validate_expr(const object_descriptor_exprt &value)
18381833
}
18391834

18401835

1841-
/// \brief TO_BE_DOCUMENTED
1836+
/// Representation of heap-allocated objects
18421837
class dynamic_object_exprt:public binary_exprt
18431838
{
18441839
public:
@@ -1908,7 +1903,7 @@ inline void validate_expr(const dynamic_object_exprt &value)
19081903
}
19091904

19101905

1911-
/// \brief semantic type conversion
1906+
/// \brief Semantic type conversion
19121907
class typecast_exprt:public unary_exprt
19131908
{
19141909
public:
@@ -1967,7 +1962,7 @@ inline void validate_expr(const typecast_exprt &value)
19671962
}
19681963

19691964

1970-
/// \brief semantic type conversion from/to floating-point formats
1965+
/// \brief Semantic type conversion from/to floating-point formats
19711966
class floatbv_typecast_exprt:public binary_exprt
19721967
{
19731968
public:
@@ -2076,8 +2071,8 @@ class and_exprt:public multi_ary_exprt
20762071
};
20772072

20782073
/// 1) generates a conjunction for two or more operands
2079-
/// 2) for one operand, returns the operand
2080-
/// 3) returns true otherwise
2074+
/// 2) for one operand, returns the operand
2075+
/// 3) returns true otherwise
20812076

20822077
exprt conjunction(const exprt::operandst &);
20832078

@@ -2199,8 +2194,8 @@ class or_exprt:public multi_ary_exprt
21992194
};
22002195

22012196
/// 1) generates a disjunction for two or more operands
2202-
/// 2) for one operand, returns the operand
2203-
/// 3) returns false otherwise
2197+
/// 2) for one operand, returns the operand
2198+
/// 3) returns false otherwise
22042199

22052200
exprt disjunction(const exprt::operandst &);
22062201

@@ -3142,8 +3137,8 @@ inline void validate_expr(const if_exprt &value)
31423137

31433138

31443139
/// \brief Operator to update elements in structs and arrays
3145-
/// \remark This expression will eventually be replaced by separate
3146-
/// array and struct update operators.
3140+
/// \remark This expression will eventually be replaced by separate
3141+
/// array and struct update operators.
31473142
class with_exprt:public exprt
31483143
{
31493144
public:
@@ -3438,7 +3433,7 @@ inline void validate_expr(const update_exprt &value)
34383433

34393434

34403435
#if 0
3441-
/// \brief update of one element of an array
3436+
/// \brief Update of one element of an array
34423437
class array_update_exprt:public exprt
34433438
{
34443439
public:
@@ -4126,7 +4121,7 @@ class null_pointer_exprt:public constant_exprt
41264121
}
41274122
};
41284123

4129-
/// \brief application of (mathematical) function
4124+
/// \brief Application of (mathematical) function
41304125
class function_application_exprt:public binary_exprt
41314126
{
41324127
public:

0 commit comments

Comments
 (0)