Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

enhancement #5

Merged
merged 2 commits into from
Feb 16, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ Just give `ic()` a variable or expression and you're done. Easy.

### Plain Ice Cream (without Arguments)

Do you ever add print statments to determine which parts of your program are
Do you ever add print statements to determine which parts of your program are
executed, and in which order they're executed? For example, if you've ever added
prints statements to debug something like

Expand Down
4 changes: 2 additions & 2 deletions icecream/icecream.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,13 +116,13 @@ def getCallSourceLines(funcName, callFrame):

def splitExpressionsOntoSeparateLines(source):
"""
Split every expression onto its own line so any preceeding and/or trailing
Split every expression onto its own line so any preceding and/or trailing
expressions, like 'foo(1); ' and '; foo(2)' of

foo(1); ic(1); foo(2)

are properly separated from ic(1) for dis.findlinestarts(). Otherwise, any
preceeding and/or trailing expressions break ic(1)'s bytecode offset
preceding and/or trailing expressions break ic(1)'s bytecode offset
calculation with dis.findlinestarts().
"""
indices = [expr.col_offset for expr in ast.parse(source).body]
Expand Down