1. A method for selecting a set of candidate code expressions from a section of program code, comprising: receiving a user selection of an expression at a position in the section of program code, said user selection identifies an expression to be copied; identifying, using a processor, a set of candidate code expressions for copying, said set comprising one or more further occurrences of said user-selected expression in an enclosing scope at said position in said section of program code; copying said set of candidate code expressions; presenting said copied set of candidate code expressions to the user; receiving user input identifying candidate code expressions within said presented set; and pasting identified candidate code expressions within said presented set to at least one target location; wherein each occurrence of said expression is automatically renamed upon the occurrence being pasted to a target location to provide a unique name for the pasted occurrence for the scope at the target location.
1. A method for selecting a set of candidate code expressions from a section of program code, comprising: receiving a user selection of an expression at a position in the section of program code, said user selection identifies an expression to be copied; identifying, using a processor, a set of candidate code expressions for copying, said set comprising one or more further occurrences of said user-selected expression in an enclosing scope at said position in said section of program code; copying said set of candidate code expressions; presenting said copied set of candidate code expressions to the user; receiving user input identifying candidate code expressions within said presented set; and pasting identified candidate code expressions within said presented set to at least one target location; wherein each occurrence of said expression is automatically renamed upon the occurrence being pasted to a target location to provide a unique name for the pasted occurrence for the scope at the target location. 3. The method according to claim 1 , wherein each expression in said set of candidate code expression is a program statement comprising said user-selected expression.