Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Lines ending with \ are incomplete (kudos to fowl)
  • Loading branch information
ConradIrwin committed Apr 18, 2012
1 parent 4d2ed09 commit 02a9c35
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/pry/code.rb
Expand Up @@ -48,8 +48,8 @@ def complete_expression?(str)
end end
end end


# Assert that a line which ends with a , is incomplete. # Assert that a line which ends with a , or \ is incomplete.
str !~ /[,]\z/ str !~ /[,\\]\s*\z/
rescue SyntaxError => e rescue SyntaxError => e
if incomplete_user_input_exception?(e) if incomplete_user_input_exception?(e)
false false
Expand Down

0 comments on commit 02a9c35

Please sign in to comment.