Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove illegal Ghost aspects #1015

Merged
merged 1 commit into from
May 9, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions rflx/generator/message.py
Original file line number Diff line number Diff line change
Expand Up @@ -1053,7 +1053,9 @@ def create_generic_read_procedure() -> UnitPart:
[Parameter(["Buffer"], const.TYPES_BYTES)],
),
TRUE,
aspects=[Ghost()],
# ISSUE: Componolit/Workarounds#48
# Ghost entities are not allowed as formal generic parameters.
# aspects=[Ghost()],
),
Pragma(
"Warnings",
Expand Down Expand Up @@ -1142,7 +1144,9 @@ def create_generic_write_procedure(message: Message) -> UnitPart:
],
),
TRUE,
aspects=[Ghost()],
# ISSUE: Componolit/Workarounds#48
# Ghost entities are not allowed as formal generic parameters.
# aspects=[Ghost()],
),
Pragma(
"Warnings",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -179,9 +179,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Buffer : RFLX_Types.Bytes) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand All @@ -197,9 +195,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Context_Buffer_Length : RFLX_Types.Length; Offset : RFLX_Types.Length) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -176,9 +176,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Buffer : RFLX_Types.Bytes) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand All @@ -194,9 +192,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Context_Buffer_Length : RFLX_Types.Length; Offset : RFLX_Types.Length) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -179,9 +179,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Buffer : RFLX_Types.Bytes) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand All @@ -197,9 +195,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Context_Buffer_Length : RFLX_Types.Length; Offset : RFLX_Types.Length) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -176,9 +176,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Buffer : RFLX_Types.Bytes) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand All @@ -194,9 +192,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Context_Buffer_Length : RFLX_Types.Length; Offset : RFLX_Types.Length) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -176,9 +176,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Buffer : RFLX_Types.Bytes) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand All @@ -194,9 +192,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Context_Buffer_Length : RFLX_Types.Length; Offset : RFLX_Types.Length) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -187,9 +187,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Buffer : RFLX_Types.Bytes) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand All @@ -205,9 +203,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Context_Buffer_Length : RFLX_Types.Length; Offset : RFLX_Types.Length) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -179,9 +179,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Buffer : RFLX_Types.Bytes) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand All @@ -197,9 +195,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Context_Buffer_Length : RFLX_Types.Length; Offset : RFLX_Types.Length) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -176,9 +176,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Buffer : RFLX_Types.Bytes) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand All @@ -194,9 +192,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Context_Buffer_Length : RFLX_Types.Length; Offset : RFLX_Types.Length) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -179,9 +179,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Buffer : RFLX_Types.Bytes) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand All @@ -197,9 +195,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Context_Buffer_Length : RFLX_Types.Length; Offset : RFLX_Types.Length) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -176,9 +176,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Buffer : RFLX_Types.Bytes) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand All @@ -194,9 +192,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Context_Buffer_Length : RFLX_Types.Length; Offset : RFLX_Types.Length) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -179,9 +179,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Buffer : RFLX_Types.Bytes) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand All @@ -197,9 +195,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Context_Buffer_Length : RFLX_Types.Length; Offset : RFLX_Types.Length) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -176,9 +176,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Buffer : RFLX_Types.Bytes) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand All @@ -194,9 +192,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Context_Buffer_Length : RFLX_Types.Length; Offset : RFLX_Types.Length) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -179,9 +179,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Buffer : RFLX_Types.Bytes) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand All @@ -197,9 +195,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Context_Buffer_Length : RFLX_Types.Length; Offset : RFLX_Types.Length) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -176,9 +176,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Buffer : RFLX_Types.Bytes) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand All @@ -194,9 +192,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Context_Buffer_Length : RFLX_Types.Length; Offset : RFLX_Types.Length) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -179,9 +179,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Buffer : RFLX_Types.Bytes) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand All @@ -197,9 +195,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Context_Buffer_Length : RFLX_Types.Length; Offset : RFLX_Types.Length) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -176,9 +176,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Buffer : RFLX_Types.Bytes) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand All @@ -194,9 +192,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Context_Buffer_Length : RFLX_Types.Length; Offset : RFLX_Types.Length) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -179,9 +179,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Buffer : RFLX_Types.Bytes) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand All @@ -197,9 +195,7 @@ is
pragma Warnings (Off, "formal parameter ""*"" is not referenced");

function Always_Valid (Context_Buffer_Length : RFLX_Types.Length; Offset : RFLX_Types.Length) return Boolean is
(True)
with
Ghost;
(True);

pragma Warnings (On, "formal parameter ""*"" is not referenced");

Expand Down
Loading