Peter Ludemann

Results 128 comments of Peter Ludemann
trafficstars

AFAICT black's `blib2to3` uses the same compiler technology that `lib2to3` uses, and therefore won't work in the future -- the PEG parsers can handle things that the `lib2to3` parsers can't....

It appears that [asttokens](https://github.com/gristlabs/asttokens) could be used with the new PEG parser. I'll try converting some of my code to use asttokens and see how it goes. Don't expect a...

It seems that there's now a PEG parser (implemented in Rust) that's aimed towards ASTs. Somebody might want to investigate whether it'll suffice for yapf. https://github.com/Instagram/LibCST/pull/566

"After 5 years, this is still an open issue..." -- yapf is Open Source, and no doubt a contribution would be accepted.

See also Issue #894, Issue #448, and possibly other issues. (A number of alternatives are discussed - see also https://github.com/psf/black/issues/2318) I think that there's an intermediate solution, using a thin...

Is the new parser intended to become a separate package, or only used by yapf? (Reason for asking: I could use a whitepace-aware parser replacement for lib2to3 for something I'm...

You could always use "Black" (see https://github.com/google/yapf/issues/794) to make those changes and then running yapf to get the formatting in the style you want. ;) Yapf has a policy of...

Yapf has a philosophy of not changing the source at all, except for whitespace. You could always format your code with `black`, then re-format it with yapf. ;) This would...

@fanninpm "How are these two statements in concord? Does the README need to be changed?" No. Yapf only changes whitespace. It doesn't change quotes; it doesn't reformat comments; it doesn't...