From 3f9512b68752421200b4fc34645a25a494c01c9f Mon Sep 17 00:00:00 2001 From: Tristan Gingold Date: Wed, 22 Mar 2023 04:33:34 +0100 Subject: vhdl: add Set/Get_Immediate_Body_Flag (for package instantiation) --- pyGHDL/libghdl/vhdl/nodes_meta.py | 619 +++++++++++++++++++------------------- 1 file changed, 313 insertions(+), 306 deletions(-) (limited to 'pyGHDL/libghdl/vhdl/nodes_meta.py') diff --git a/pyGHDL/libghdl/vhdl/nodes_meta.py b/pyGHDL/libghdl/vhdl/nodes_meta.py index fcacf57c5..42154df63 100644 --- a/pyGHDL/libghdl/vhdl/nodes_meta.py +++ b/pyGHDL/libghdl/vhdl/nodes_meta.py @@ -198,312 +198,313 @@ class fields(IntEnum): Package_Body = 78 Instance_Package_Body = 79 Need_Body = 80 - Macro_Expanded_Flag = 81 - Need_Instance_Bodies = 82 - Hierarchical_Name = 83 - Vunit_Item_Chain = 84 - Bound_Vunit_Chain = 85 - Verification_Block_Configuration = 86 - Block_Configuration = 87 - Concurrent_Statement_Chain = 88 - Chain = 89 - Port_Chain = 90 - Generic_Chain = 91 - Type = 92 - Subtype_Indication = 93 - Discrete_Range = 94 - Type_Definition = 95 - Subtype_Definition = 96 - Incomplete_Type_Declaration = 97 - Interface_Type_Subprograms = 98 - Interface_Type_Definition = 99 - Nature_Definition = 100 - Nature = 101 - Subnature_Indication = 102 - Reference_Terminal_Flag = 103 - Mode = 104 - Guarded_Signal_Flag = 105 - Signal_Kind = 106 - Base_Name = 107 - Interface_Declaration_Chain = 108 - Default_Subprogram = 109 - Associated_Subprogram = 110 - Subprogram_Specification = 111 - Sequential_Statement_Chain = 112 - Simultaneous_Statement_Chain = 113 - Subprogram_Body = 114 - Overload_Number = 115 - Subprogram_Depth = 116 - Subprogram_Hash = 117 - Impure_Depth = 118 - Return_Type = 119 - Implicit_Definition = 120 - Uninstantiated_Subprogram_Name = 121 - Default_Value = 122 - Deferred_Declaration = 123 - Deferred_Declaration_Flag = 124 - Shared_Flag = 125 - Design_Unit = 126 - Block_Statement = 127 - Signal_Driver = 128 - Declaration_Chain = 129 - File_Logical_Name = 130 - File_Open_Kind = 131 - Element_Position = 132 - Use_Clause_Chain = 133 - Context_Reference_Chain = 134 - Inherit_Spec_Chain = 135 - Selected_Name = 136 - Type_Declarator = 137 - Complete_Type_Definition = 138 - Incomplete_Type_Ref_Chain = 139 - Associated_Type = 140 - Enumeration_Literal_List = 141 - Entity_Class_Entry_Chain = 142 - Group_Constituent_List = 143 - Unit_Chain = 144 - Primary_Unit = 145 - Identifier = 146 - Label = 147 - Return_Identifier = 148 - Visible_Flag = 149 - Range_Constraint = 150 - Direction = 151 - Left_Limit = 152 - Right_Limit = 153 - Left_Limit_Expr = 154 - Right_Limit_Expr = 155 - Parent_Type = 156 - Simple_Nature = 157 - Base_Nature = 158 - Resolution_Indication = 159 - Record_Element_Resolution_Chain = 160 - Tolerance = 161 - Plus_Terminal_Name = 162 - Minus_Terminal_Name = 163 - Plus_Terminal = 164 - Minus_Terminal = 165 - Magnitude_Expression = 166 - Phase_Expression = 167 - Power_Expression = 168 - Simultaneous_Left = 169 - Simultaneous_Right = 170 - Text_File_Flag = 171 - Only_Characters_Flag = 172 - Is_Character_Type = 173 - Nature_Staticness = 174 - Type_Staticness = 175 - Constraint_State = 176 - Index_Subtype_List = 177 - Index_Subtype_Definition_List = 178 - Element_Subtype_Indication = 179 - Element_Subtype = 180 - Element_Subnature_Indication = 181 - Element_Subnature = 182 - Index_Constraint_List = 183 - Array_Element_Constraint = 184 - Has_Array_Constraint_Flag = 185 - Has_Element_Constraint_Flag = 186 - Elements_Declaration_List = 187 - Owned_Elements_Chain = 188 - Designated_Type = 189 - Designated_Subtype_Indication = 190 - Index_List = 191 - Reference = 192 - Nature_Declarator = 193 - Across_Type_Mark = 194 - Through_Type_Mark = 195 - Across_Type_Definition = 196 - Through_Type_Definition = 197 - Across_Type = 198 - Through_Type = 199 - Target = 200 - Waveform_Chain = 201 - Guard = 202 - Delay_Mechanism = 203 - Reject_Time_Expression = 204 - Force_Mode = 205 - Has_Force_Mode = 206 - Sensitivity_List = 207 - Process_Origin = 208 - Package_Origin = 209 - Condition_Clause = 210 - Break_Element = 211 - Selector_Quantity = 212 - Break_Quantity = 213 - Timeout_Clause = 214 - Postponed_Flag = 215 - Callees_List = 216 - Passive_Flag = 217 - Resolution_Function_Flag = 218 - Wait_State = 219 - All_Sensitized_State = 220 - Seen_Flag = 221 - Pure_Flag = 222 - Foreign_Flag = 223 - Resolved_Flag = 224 - Signal_Type_Flag = 225 - Has_Signal_Flag = 226 - Purity_State = 227 - Elab_Flag = 228 - Vendor_Library_Flag = 229 - Configuration_Mark_Flag = 230 - Configuration_Done_Flag = 231 - Index_Constraint_Flag = 232 - Hide_Implicit_Flag = 233 - Assertion_Condition = 234 - Report_Expression = 235 - Severity_Expression = 236 - Instantiated_Unit = 237 - Instantiated_Header = 238 - Generic_Map_Aspect_Chain = 239 - Port_Map_Aspect_Chain = 240 - Configuration_Name = 241 - Component_Configuration = 242 - Configuration_Specification = 243 - Default_Binding_Indication = 244 - Default_Configuration_Declaration = 245 - Expression = 246 - Conditional_Expression_Chain = 247 - Allocator_Designated_Type = 248 - Selected_Waveform_Chain = 249 - Conditional_Waveform_Chain = 250 - Guard_Expression = 251 - Guard_Decl = 252 - Guard_Sensitivity_List = 253 - Attribute_Implicit_Chain = 254 - Block_Block_Configuration = 255 - Package_Header = 256 - Block_Header = 257 - Uninstantiated_Package_Name = 258 - Uninstantiated_Package_Decl = 259 - Associated_Package = 260 - Instance_Source_File = 261 - Generate_Block_Configuration = 262 - Generate_Statement_Body = 263 - Alternative_Label = 264 - Generate_Else_Clause = 265 - Condition = 266 - Else_Clause = 267 - Parameter_Specification = 268 - Parent = 269 - Loop_Label = 270 - Exit_Flag = 271 - Next_Flag = 272 - Component_Name = 273 - Instantiation_List = 274 - Entity_Aspect = 275 - Default_Entity_Aspect = 276 - Binding_Indication = 277 - Named_Entity = 278 - Referenced_Name = 279 - Expr_Staticness = 280 - Scalar_Size = 281 - Error_Origin = 282 - Operand = 283 - Left = 284 - Right = 285 - Unit_Name = 286 - Name = 287 - Group_Template_Name = 288 - Name_Staticness = 289 - Prefix = 290 - Signature_Prefix = 291 - External_Pathname = 292 - Pathname_Suffix = 293 - Pathname_Expression = 294 - In_Formal_Flag = 295 - Inertial_Flag = 296 - Slice_Subtype = 297 - Suffix = 298 - Index_Subtype = 299 - Parameter = 300 - Parameter_2 = 301 - Parameter_3 = 302 - Parameter_4 = 303 - Attr_Chain = 304 - Attribute_Implicit_Declaration = 305 - Actual_Type = 306 - Actual_Type_Definition = 307 - Association_Chain = 308 - Individual_Association_Chain = 309 - Subprogram_Association_Chain = 310 - Aggregate_Info = 311 - Sub_Aggregate_Info = 312 - Aggr_Dynamic_Flag = 313 - Aggr_Min_Length = 314 - Aggr_Low_Limit = 315 - Aggr_High_Limit = 316 - Aggr_Others_Flag = 317 - Aggr_Named_Flag = 318 - Aggregate_Expand_Flag = 319 - Determined_Aggregate_Flag = 320 - Association_Choices_Chain = 321 - Case_Statement_Alternative_Chain = 322 - Matching_Flag = 323 - Choice_Staticness = 324 - Procedure_Call = 325 - Implementation = 326 - Parameter_Association_Chain = 327 - Method_Object = 328 - Subtype_Type_Mark = 329 - Subnature_Nature_Mark = 330 - Type_Conversion_Subtype = 331 - Type_Mark = 332 - File_Type_Mark = 333 - Return_Type_Mark = 334 - Has_Disconnect_Flag = 335 - Has_Active_Flag = 336 - Is_Within_Flag = 337 - Type_Marks_List = 338 - Implicit_Alias_Flag = 339 - Alias_Signature = 340 - Attribute_Signature = 341 - Overload_List = 342 - Simple_Name_Identifier = 343 - Simple_Name_Subtype = 344 - Protected_Type_Body = 345 - Protected_Type_Declaration = 346 - Use_Flag = 347 - Elaborated_Flag = 348 - End_Has_Reserved_Id = 349 - End_Has_Identifier = 350 - End_Has_Postponed = 351 - Has_Label = 352 - Has_Begin = 353 - Has_End = 354 - Has_Is = 355 - Has_Pure = 356 - Has_Body = 357 - Has_Parameter = 358 - Has_Component = 359 - Has_Identifier_List = 360 - Has_Mode = 361 - Has_Class = 362 - Has_Delay_Mechanism = 363 - Suspend_Flag = 364 - Stop_Flag = 365 - Is_Ref = 366 - Is_Forward_Ref = 367 - Psl_Property = 368 - Psl_Sequence = 369 - Psl_Declaration = 370 - Psl_Expression = 371 - Psl_Boolean = 372 - PSL_Clock = 373 - PSL_NFA = 374 - PSL_Nbr_States = 375 - PSL_Clock_Sensitivity = 376 - PSL_EOS_Flag = 377 - PSL_Abort_Flag = 378 - Count_Expression = 379 - Clock_Expression = 380 - Default_Clock = 381 - Foreign_Node = 382 - Suspend_State_Index = 383 - Suspend_State_Chain = 384 - Suspend_State_Last = 385 - Suspend_State_Decl = 386 + Immediate_Body_Flag = 81 + Macro_Expanded_Flag = 82 + Need_Instance_Bodies = 83 + Hierarchical_Name = 84 + Vunit_Item_Chain = 85 + Bound_Vunit_Chain = 86 + Verification_Block_Configuration = 87 + Block_Configuration = 88 + Concurrent_Statement_Chain = 89 + Chain = 90 + Port_Chain = 91 + Generic_Chain = 92 + Type = 93 + Subtype_Indication = 94 + Discrete_Range = 95 + Type_Definition = 96 + Subtype_Definition = 97 + Incomplete_Type_Declaration = 98 + Interface_Type_Subprograms = 99 + Interface_Type_Definition = 100 + Nature_Definition = 101 + Nature = 102 + Subnature_Indication = 103 + Reference_Terminal_Flag = 104 + Mode = 105 + Guarded_Signal_Flag = 106 + Signal_Kind = 107 + Base_Name = 108 + Interface_Declaration_Chain = 109 + Default_Subprogram = 110 + Associated_Subprogram = 111 + Subprogram_Specification = 112 + Sequential_Statement_Chain = 113 + Simultaneous_Statement_Chain = 114 + Subprogram_Body = 115 + Overload_Number = 116 + Subprogram_Depth = 117 + Subprogram_Hash = 118 + Impure_Depth = 119 + Return_Type = 120 + Implicit_Definition = 121 + Uninstantiated_Subprogram_Name = 122 + Default_Value = 123 + Deferred_Declaration = 124 + Deferred_Declaration_Flag = 125 + Shared_Flag = 126 + Design_Unit = 127 + Block_Statement = 128 + Signal_Driver = 129 + Declaration_Chain = 130 + File_Logical_Name = 131 + File_Open_Kind = 132 + Element_Position = 133 + Use_Clause_Chain = 134 + Context_Reference_Chain = 135 + Inherit_Spec_Chain = 136 + Selected_Name = 137 + Type_Declarator = 138 + Complete_Type_Definition = 139 + Incomplete_Type_Ref_Chain = 140 + Associated_Type = 141 + Enumeration_Literal_List = 142 + Entity_Class_Entry_Chain = 143 + Group_Constituent_List = 144 + Unit_Chain = 145 + Primary_Unit = 146 + Identifier = 147 + Label = 148 + Return_Identifier = 149 + Visible_Flag = 150 + Range_Constraint = 151 + Direction = 152 + Left_Limit = 153 + Right_Limit = 154 + Left_Limit_Expr = 155 + Right_Limit_Expr = 156 + Parent_Type = 157 + Simple_Nature = 158 + Base_Nature = 159 + Resolution_Indication = 160 + Record_Element_Resolution_Chain = 161 + Tolerance = 162 + Plus_Terminal_Name = 163 + Minus_Terminal_Name = 164 + Plus_Terminal = 165 + Minus_Terminal = 166 + Magnitude_Expression = 167 + Phase_Expression = 168 + Power_Expression = 169 + Simultaneous_Left = 170 + Simultaneous_Right = 171 + Text_File_Flag = 172 + Only_Characters_Flag = 173 + Is_Character_Type = 174 + Nature_Staticness = 175 + Type_Staticness = 176 + Constraint_State = 177 + Index_Subtype_List = 178 + Index_Subtype_Definition_List = 179 + Element_Subtype_Indication = 180 + Element_Subtype = 181 + Element_Subnature_Indication = 182 + Element_Subnature = 183 + Index_Constraint_List = 184 + Array_Element_Constraint = 185 + Has_Array_Constraint_Flag = 186 + Has_Element_Constraint_Flag = 187 + Elements_Declaration_List = 188 + Owned_Elements_Chain = 189 + Designated_Type = 190 + Designated_Subtype_Indication = 191 + Index_List = 192 + Reference = 193 + Nature_Declarator = 194 + Across_Type_Mark = 195 + Through_Type_Mark = 196 + Across_Type_Definition = 197 + Through_Type_Definition = 198 + Across_Type = 199 + Through_Type = 200 + Target = 201 + Waveform_Chain = 202 + Guard = 203 + Delay_Mechanism = 204 + Reject_Time_Expression = 205 + Force_Mode = 206 + Has_Force_Mode = 207 + Sensitivity_List = 208 + Process_Origin = 209 + Package_Origin = 210 + Condition_Clause = 211 + Break_Element = 212 + Selector_Quantity = 213 + Break_Quantity = 214 + Timeout_Clause = 215 + Postponed_Flag = 216 + Callees_List = 217 + Passive_Flag = 218 + Resolution_Function_Flag = 219 + Wait_State = 220 + All_Sensitized_State = 221 + Seen_Flag = 222 + Pure_Flag = 223 + Foreign_Flag = 224 + Resolved_Flag = 225 + Signal_Type_Flag = 226 + Has_Signal_Flag = 227 + Purity_State = 228 + Elab_Flag = 229 + Vendor_Library_Flag = 230 + Configuration_Mark_Flag = 231 + Configuration_Done_Flag = 232 + Index_Constraint_Flag = 233 + Hide_Implicit_Flag = 234 + Assertion_Condition = 235 + Report_Expression = 236 + Severity_Expression = 237 + Instantiated_Unit = 238 + Instantiated_Header = 239 + Generic_Map_Aspect_Chain = 240 + Port_Map_Aspect_Chain = 241 + Configuration_Name = 242 + Component_Configuration = 243 + Configuration_Specification = 244 + Default_Binding_Indication = 245 + Default_Configuration_Declaration = 246 + Expression = 247 + Conditional_Expression_Chain = 248 + Allocator_Designated_Type = 249 + Selected_Waveform_Chain = 250 + Conditional_Waveform_Chain = 251 + Guard_Expression = 252 + Guard_Decl = 253 + Guard_Sensitivity_List = 254 + Attribute_Implicit_Chain = 255 + Block_Block_Configuration = 256 + Package_Header = 257 + Block_Header = 258 + Uninstantiated_Package_Name = 259 + Uninstantiated_Package_Decl = 260 + Associated_Package = 261 + Instance_Source_File = 262 + Generate_Block_Configuration = 263 + Generate_Statement_Body = 264 + Alternative_Label = 265 + Generate_Else_Clause = 266 + Condition = 267 + Else_Clause = 268 + Parameter_Specification = 269 + Parent = 270 + Loop_Label = 271 + Exit_Flag = 272 + Next_Flag = 273 + Component_Name = 274 + Instantiation_List = 275 + Entity_Aspect = 276 + Default_Entity_Aspect = 277 + Binding_Indication = 278 + Named_Entity = 279 + Referenced_Name = 280 + Expr_Staticness = 281 + Scalar_Size = 282 + Error_Origin = 283 + Operand = 284 + Left = 285 + Right = 286 + Unit_Name = 287 + Name = 288 + Group_Template_Name = 289 + Name_Staticness = 290 + Prefix = 291 + Signature_Prefix = 292 + External_Pathname = 293 + Pathname_Suffix = 294 + Pathname_Expression = 295 + In_Formal_Flag = 296 + Inertial_Flag = 297 + Slice_Subtype = 298 + Suffix = 299 + Index_Subtype = 300 + Parameter = 301 + Parameter_2 = 302 + Parameter_3 = 303 + Parameter_4 = 304 + Attr_Chain = 305 + Attribute_Implicit_Declaration = 306 + Actual_Type = 307 + Actual_Type_Definition = 308 + Association_Chain = 309 + Individual_Association_Chain = 310 + Subprogram_Association_Chain = 311 + Aggregate_Info = 312 + Sub_Aggregate_Info = 313 + Aggr_Dynamic_Flag = 314 + Aggr_Min_Length = 315 + Aggr_Low_Limit = 316 + Aggr_High_Limit = 317 + Aggr_Others_Flag = 318 + Aggr_Named_Flag = 319 + Aggregate_Expand_Flag = 320 + Determined_Aggregate_Flag = 321 + Association_Choices_Chain = 322 + Case_Statement_Alternative_Chain = 323 + Matching_Flag = 324 + Choice_Staticness = 325 + Procedure_Call = 326 + Implementation = 327 + Parameter_Association_Chain = 328 + Method_Object = 329 + Subtype_Type_Mark = 330 + Subnature_Nature_Mark = 331 + Type_Conversion_Subtype = 332 + Type_Mark = 333 + File_Type_Mark = 334 + Return_Type_Mark = 335 + Has_Disconnect_Flag = 336 + Has_Active_Flag = 337 + Is_Within_Flag = 338 + Type_Marks_List = 339 + Implicit_Alias_Flag = 340 + Alias_Signature = 341 + Attribute_Signature = 342 + Overload_List = 343 + Simple_Name_Identifier = 344 + Simple_Name_Subtype = 345 + Protected_Type_Body = 346 + Protected_Type_Declaration = 347 + Use_Flag = 348 + Elaborated_Flag = 349 + End_Has_Reserved_Id = 350 + End_Has_Identifier = 351 + End_Has_Postponed = 352 + Has_Label = 353 + Has_Begin = 354 + Has_End = 355 + Has_Is = 356 + Has_Pure = 357 + Has_Body = 358 + Has_Parameter = 359 + Has_Component = 360 + Has_Identifier_List = 361 + Has_Mode = 362 + Has_Class = 363 + Has_Delay_Mechanism = 364 + Suspend_Flag = 365 + Stop_Flag = 366 + Is_Ref = 367 + Is_Forward_Ref = 368 + Psl_Property = 369 + Psl_Sequence = 370 + Psl_Declaration = 371 + Psl_Expression = 372 + Psl_Boolean = 373 + PSL_Clock = 374 + PSL_NFA = 375 + PSL_Nbr_States = 376 + PSL_Clock_Sensitivity = 377 + PSL_EOS_Flag = 378 + PSL_Abort_Flag = 379 + Count_Expression = 380 + Clock_Expression = 381 + Default_Clock = 382 + Foreign_Node = 383 + Suspend_State_Index = 384 + Suspend_State_Chain = 385 + Suspend_State_Last = 386 + Suspend_State_Decl = 387 def Get_Boolean(node, field): @@ -1124,6 +1125,12 @@ def Has_Need_Body(kind: IirKind) -> bool: """""" +@export +@BindToLibGHDL("vhdl__nodes_meta__has_immediate_body_flag") +def Has_Immediate_Body_Flag(kind: IirKind) -> bool: + """""" + + @export @BindToLibGHDL("vhdl__nodes_meta__has_macro_expanded_flag") def Has_Macro_Expanded_Flag(kind: IirKind) -> bool: -- cgit v1.2.3