]> git.madduck.net Git - etc/vim.git/commit

madduck's git repository

Every one of the projects in this repository is available at the canonical URL git://git.madduck.net/madduck/pub/<projectpath> — see each project's metadata for the exact URL.

All patches and comments are welcome. Please squash your changes to logical commits before using git-format-patch and git-send-email to patches@git.madduck.net. If you'd read over the Git project's submission guidelines and adhered to them, I'd be especially grateful.

SSH access, as well as push access can be individually arranged.

If you use my repositories frequently, consider adding the following snippet to ~/.gitconfig and using the third clone URL listed for each project:

[url "git://git.madduck.net/madduck/"]
  insteadOf = madduck:

normalize numeric literals (#454)
authorJelle Zijlstra <jelle.zijlstra@gmail.com>
Fri, 17 Aug 2018 14:03:58 +0000 (07:03 -0700)
committerŁukasz Langa <lukasz@langa.pl>
Fri, 17 Aug 2018 14:03:58 +0000 (15:03 +0100)
commitcc48bc56caa79b0d605e80302c32be0457cfde39
tree3b1c973abd6294f6b4e3919cef7a227ecbb49e56
parente94a41f92a568706700522aaad48ebd137fe1d8b
normalize numeric literals (#454)

Fixes #452

I ended up making a couple of other normalizations to numeric literals
too (lowercase everything, don't allow leading or trailing . in floats,
remove redundant + sign in exponent). I don't care too much about those,
so I'm happy to change the behavior there.

For reference, here is Python's grammar for numeric literals:
https://docs.python.org/3/reference/lexical_analysis.html#numeric-literals
black.py
tests/data/numeric_literals.py [new file with mode: 0644]
tests/data/numeric_literals_py2.py [new file with mode: 0644]
tests/test_black.py