Comments (1)
The ast doesn't preserve the comments nor the fine code structure so you can't preserve the exact code structure.
You could traverse the ast to create some code which worked the same though.
There isn't a way of doing this right now, but it wouldn't be too tricky to implement.
Why do you want to do this?
from gpython.
Related Issues (20)
- Slicing large list causes segfault of gpython HOT 1
- Incorrect elementtree operation cause double free of memory. HOT 1
- Decimal.from_float takes bad arguments crashing gpython HOT 1
- Double underlines("_") for nonlocal variable names crash gpython HOT 1
- Large hex_string of pickle.load() crashes gpython HOT 3
- Reassignment of 'getattr' leads to gpython crashing HOT 2
- Annotating types with decorators crashes gpython HOT 1
- '__import__' takes incorrect arguments crashing gpython HOT 1
- Comparing uncomparable types in 'is' crashes gpython HOT 1
- Transforming unsupported types into a set leads to crashing HOT 1
- Defining Nested set crashes gpython HOT 1
- transforming generators into list trigger crashing HOT 1
- Taking large arguments in functions crashes gpython HOT 1
- Compiling long operations crashes gpython HOT 3
- How to get `globals()` inside Go bounded method?
- Set attributes on python objects from Go code HOT 3
- Do you need type conversion of struct? HOT 6
- Can you guys put a pure python library as a built-in library, So the battery will be a built-in feature? HOT 1
- function not found with error AttributeError: "'module' has no attribute 'pre_save'" HOT 2
- Error when i try to get the `__doc__` from a type like `str`
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gpython.