in Compiler Design edited by
4,241 views
26 votes

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 edited by
4.2k views

1 Answer

36 votes
 
Best answer

Link editor or (linker ) performs 

  1. external symbol resolution 
  2. relocation.

ANS: B 

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

edited by

10 Comments

Even I think answer is b

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

Option e is more specific . Please see it.
1

@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.

14
what does c option means here?
1
who will perform option c
0

Macro resolution is done during compiling phase "Lexical analysis"

9
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.
0
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...
2

@Aks9639

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. :)

0
Answer:

Related questions