The Gateway to Computer Science Excellence
+23 votes

Choose the correct alternatives (more than one may be correct ) and write the corresponding letters only

A “link editor” is a program that:

  1. matches the parameters of the macro-definition with locations of the parameters of the macro call
  2. matches external names of one program with their location in other programs
  3. matches the parameters of subroutine definition with the location of parameters of subroutine call.
  4. acts as a link between text editor and the user
  5. acts as a link between compiler and the user program
in Compiler Design by
edited by | 2.6k views

1 Answer

+30 votes
Best answer

Link editor or (linker ) performs 

  1. external symbol resolution 
  2. relocation.


Matches external names of one program with their location in other programs

edited by
Even I think answer is b

Which is the correct one
why not e ?
@bikram sir

Option e is more specific . Please see it.

@hem chandra joshi  User program  jorney:-

Source program -> preprocessor ->compiler-> Assembler->Linker-> Loader -> Exectution 

So,you see why e is false.Please let me know for any corrections.

what does c option means here?
who will perform option c

Macro resolution is done during compiling phase "Lexical analysis"

Yes,  this is given in dragon book some languages that not supported macro substitution lexical analyzer do that task which is done by pre-processor program ; like macro resolutions , white space and comments  elimination etc.
But this slight confusing Why not option c) here, if it not then what it is and moreover where it will be done?

Please explain anyone... it's confusing...


I guess locating parameters of a subroutine call is done in semantic analysis.

Questions like "Is the function global? Local to the module? Nested in another procedure? Attached to a class?" needs to be addressed. Symbol table would be used.

Correct me if I'm wrong. :)

Related questions

Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
52,375 questions
60,581 answers
95,400 users