Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit b1ead4a

Browse files
committed
Order Error::Severity enum from most to least severe
- Also reorder Error::Type to match initial values for some consistency
1 parent c5b81b6 commit b1ead4a

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

liblangutil/Exceptions.h

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,8 @@ class Error: virtual public util::Exception
170170
public:
171171
enum class Type
172172
{
173+
Info,
174+
Warning,
173175
CodeGenerationError,
174176
DeclarationError,
175177
DocstringParsingError,
@@ -185,15 +187,14 @@ class Error: virtual public util::Exception
185187
UnimplementedFeatureError,
186188
YulException,
187189
SMTLogicException,
188-
Warning,
189-
Info
190190
};
191191

192192
enum class Severity
193193
{
194-
Error,
194+
// NOTE: We rely on these being ordered from least to most severe.
195+
Info,
195196
Warning,
196-
Info
197+
Error,
197198
};
198199

199200
Error(

0 commit comments

Comments
 (0)