diff options
| author | Tristan Gingold <tgingold@free.fr> | 2023-01-14 18:50:22 +0100 | 
|---|---|---|
| committer | Tristan Gingold <tgingold@free.fr> | 2023-01-15 09:47:13 +0100 | 
| commit | 5b59dda84a7eb8a48e94a75b9b3ad008514089ce (patch) | |
| tree | 7d8bcf6addec0f6ebb6bb68b50650d03607128c8 /src/vhdl/vhdl-sem_expr.ads | |
| parent | 1fe5958609b57e7d134e0cc75713c530339a86dd (diff) | |
| download | ghdl-5b59dda84a7eb8a48e94a75b9b3ad008514089ce.tar.gz ghdl-5b59dda84a7eb8a48e94a75b9b3ad008514089ce.tar.bz2 ghdl-5b59dda84a7eb8a48e94a75b9b3ad008514089ce.zip | |
vhdl: add a warning to detect use before elaboration
Diffstat (limited to 'src/vhdl/vhdl-sem_expr.ads')
| -rw-r--r-- | src/vhdl/vhdl-sem_expr.ads | 7 | 
1 files changed, 7 insertions, 0 deletions
| diff --git a/src/vhdl/vhdl-sem_expr.ads b/src/vhdl/vhdl-sem_expr.ads index 1519d9252..b247d2d7e 100644 --- a/src/vhdl/vhdl-sem_expr.ads +++ b/src/vhdl/vhdl-sem_expr.ads @@ -24,8 +24,15 @@ package Vhdl.Sem_Expr is     --  Set type to nodes,     --  Resolve overloading +   --  If set, use of deferred constants is allowed. +   --  Set during analysis of default value of subprogram parameters.     Deferred_Constant_Allowed : Boolean := False; +   --  If set, use of unelaborated constructs is allowed. +   --  This is set while analyzing subprograms body (and default parameters +   --  values), as a subprogram may be called way after elaboration. +   Unelaborated_Use_Allowed : Boolean := False; +     --  Analyze an expression (other than a range) with a possible overloading.     --  Sem_expression_ov (and therefore sem_expression) must be called *once*     --  for each expression node with A_TYPE1 not null and at most *once* with | 
