in Compiler Design edited by
14,062 views
28 votes
28 votes

Which data structure in a compiler is used for managing information about variables and their attributes?

  1. Abstract syntax tree
  2. Symbol table
  3. Semantic stack
  4. Parse table
in Compiler Design edited by
14.1k views

5 Answers

0 votes
0 votes

The data structure in a compiler used for managing information about variables and their attributes is the Symbol Table.

The Symbol Table is a crucial data structure in compilers that keeps track of identifiers (such as variables, functions, etc.) and their associated information, including their types, memory locations, scope, and other attributes. It plays a vital role in semantic analysis, type checking, and code generation phases of the compiler.

Answer:

Related questions