Skip to content

Mishandling of print function #172

Description

@shindavid

The following code...

import redbaron
rb = redbaron.RedBaron('func = print if True else print')
print(rb.dumps())

...produces the following output:

func = printif True else print

Note that the space between the print and the if has been removed.

This bug does not occur if the the word print is replaced with foo.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions