aboutsummaryrefslogtreecommitdiffstats
path: root/src/grt/grt-wave_opt.adb
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2018-09-16 08:07:36 +0200
committerTristan Gingold <tgingold@free.fr>2018-09-16 08:18:50 +0200
commit9ed21dea7e8c7c5a07d1438ec89ecc98ac7f399d (patch)
tree4528ee0f3bf6fffdaf3f210fc1a9c6fb7ae82bbc /src/grt/grt-wave_opt.adb
parent7303c1068a75001365f77f2569382cc093fa9ac2 (diff)
downloadghdl-9ed21dea7e8c7c5a07d1438ec89ecc98ac7f399d.tar.gz
ghdl-9ed21dea7e8c7c5a07d1438ec89ecc98ac7f399d.tar.bz2
ghdl-9ed21dea7e8c7c5a07d1438ec89ecc98ac7f399d.zip
grt: adjust grt-wave_opt error API.
Diffstat (limited to 'src/grt/grt-wave_opt.adb')
-rw-r--r--src/grt/grt-wave_opt.adb37
1 files changed, 11 insertions, 26 deletions
diff --git a/src/grt/grt-wave_opt.adb b/src/grt/grt-wave_opt.adb
index f976c42bd..5bc1524b3 100644
--- a/src/grt/grt-wave_opt.adb
+++ b/src/grt/grt-wave_opt.adb
@@ -29,48 +29,33 @@ with Grt.Errors; use Grt.Errors;
package body Grt.Wave_Opt is
- procedure Print_Context
- (Lineno, Column : Positive; Severity : Severity_Type) is
+ procedure Diag_C_Context (Lineno, Column : Positive) is
begin
- case Severity is
- when Error =>
- Error_S;
- when Warning =>
- Warning_S;
- end case;
Diag_C (File_Path.all);
Diag_C (':');
Diag_C (Lineno);
Diag_C (':');
Diag_C (Column);
Diag_C (": ");
- end Print_Context;
+ end Diag_C_Context;
- procedure Print_Context (Element : Elem_Acc; Severity : Severity_Type) is
+ procedure Diag_C_Context (Element : Elem_Acc) is
begin
- Print_Context
- (Element.Lineno, Element.Column, Severity);
- end Print_Context;
+ Diag_C_Context (Element.Lineno, Element.Column);
+ end Diag_C_Context;
procedure Error_Context (Msg : String;
- Lineno, Column : Positive;
- Severity : Severity_Type := Error) is
+ Lineno, Column : Positive) is
begin
- Print_Context (Lineno, Column, Severity);
+ Error_S;
+ Diag_C_Context (Lineno, Column);
Diag_C (Msg);
- case Severity is
- when Error =>
- Error_E;
- when Warning =>
- Warning_E;
- end case;
+ Error_E;
end Error_Context;
- procedure Error_Context
- (Msg : String; Element : Elem_Acc; Severity : Severity_Type := Error) is
+ procedure Error_Context (Msg : String; Element : Elem_Acc) is
begin
- Error_Context
- (Msg, Element.Lineno, Element.Column, Severity);
+ Error_Context (Msg, Element.Lineno, Element.Column);
end Error_Context;
end Grt.Wave_Opt;