Skip to content

Commit

Permalink
Surround with try..except is now try..except Exception.
Browse files Browse the repository at this point in the history
  • Loading branch information
fabioz committed Sep 14, 2024
1 parent 1979ce8 commit 3995fa6
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ private ICompletionProposalHandle createProposal(PySelection ps, IImageCache ima
}

/**
* Template completions available for surround with... They %s will be replaced later for the actual code/indentation.
* Template completions available for surround with... The %s will be replaced later for the actual code/indentation.
*
* Could be refactored so that we don't have to put the actual indent here (creating a subclass of PyDocumentTemplateContext)
* Also, if that refactoring was done, we could give an interface for the user to configure those templates better.
Expand All @@ -146,7 +146,7 @@ private ICompletionProposalHandle createProposal(PySelection ps, IImageCache ima
* for item in collection could have 'good' choices for the collection variable based on the local variables.
*/
public static final String[] SURROUND_WITH_COMPLETIONS = new String[] {
"%stry:%s%s%s%sexcept${cursor}:%s%s%sraise", "try..except",
"%stry:%s%s%s%sexcept ${Exception}${cursor}:%s%s%sraise", "try..except Exception",
"%stry:%s%s%s%sexcept ${Exception} as e:%s%s%s${raise}${cursor}", "try..except Exception as e",
"%stry:%s%s%s%sfinally:%s%s%s${pass}", "try..finally", "%sif ${True}:%s%s%s%selse:%s%s%s${pass}",
"if..else",
Expand Down

0 comments on commit 3995fa6

Please sign in to comment.