-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
An Implementation in Python with a Compiler #653
Open
jcguu95
wants to merge
60
commits into
kanaka:master
Choose a base branch
from
jcguu95:python-compile
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Commits on Mar 11, 2024
-
Configuration menu - View commit details
-
Copy full SHA for da0c3b4 - Browse repository at this point
Copy the full SHA da0c3b4View commit details -
Configuration menu - View commit details
-
Copy full SHA for cd73f72 - Browse repository at this point
Copy the full SHA cd73f72View commit details -
Configuration menu - View commit details
-
Copy full SHA for f7636c5 - Browse repository at this point
Copy the full SHA f7636c5View commit details -
Configuration menu - View commit details
-
Copy full SHA for 4b537f7 - Browse repository at this point
Copy the full SHA 4b537f7View commit details -
Configuration menu - View commit details
-
Copy full SHA for 402065f - Browse repository at this point
Copy the full SHA 402065fView commit details -
Configuration menu - View commit details
-
Copy full SHA for 3de4bbf - Browse repository at this point
Copy the full SHA 3de4bbfView commit details -
Configuration menu - View commit details
-
Copy full SHA for 6da0cf5 - Browse repository at this point
Copy the full SHA 6da0cf5View commit details -
Configuration menu - View commit details
-
Copy full SHA for ad88939 - Browse repository at this point
Copy the full SHA ad88939View commit details -
Configuration menu - View commit details
-
Copy full SHA for abc1538 - Browse repository at this point
Copy the full SHA abc1538View commit details -
Configuration menu - View commit details
-
Copy full SHA for cef411e - Browse repository at this point
Copy the full SHA cef411eView commit details -
Configuration menu - View commit details
-
Copy full SHA for e512847 - Browse repository at this point
Copy the full SHA e512847View commit details -
This took me a while.. and I need to redo the other operators. So far only def! and +-*/ works.
Configuration menu - View commit details
-
Copy full SHA for 8d62557 - Browse repository at this point
Copy the full SHA 8d62557View commit details -
Configuration menu - View commit details
-
Copy full SHA for 3db8a6b - Browse repository at this point
Copy the full SHA 3db8a6bView commit details -
Configuration menu - View commit details
-
Copy full SHA for 479d9d9 - Browse repository at this point
Copy the full SHA 479d9d9View commit details -
Scatter debugger in the compiled codes as well.
Make it verbose and more easily debuggable.
Configuration menu - View commit details
-
Copy full SHA for 57cfc0b - Browse repository at this point
Copy the full SHA 57cfc0bView commit details -
Configuration menu - View commit details
-
Copy full SHA for ed23b00 - Browse repository at this point
Copy the full SHA ed23b00View commit details -
Configuration menu - View commit details
-
Copy full SHA for 32ccb66 - Browse repository at this point
Copy the full SHA 32ccb66View commit details -
1. Remove old commented code. 2. Give repls new prompts. 3. Refactor COMPILE in to smaller functions.
Configuration menu - View commit details
-
Copy full SHA for bc11d01 - Browse repository at this point
Copy the full SHA bc11d01View commit details -
Configuration menu - View commit details
-
Copy full SHA for 4df900d - Browse repository at this point
Copy the full SHA 4df900dView commit details -
Configuration menu - View commit details
-
Copy full SHA for 70f7b4d - Browse repository at this point
Copy the full SHA 70f7b4dView commit details -
Configuration menu - View commit details
-
Copy full SHA for aa05747 - Browse repository at this point
Copy the full SHA aa05747View commit details -
Configuration menu - View commit details
-
Copy full SHA for bce3712 - Browse repository at this point
Copy the full SHA bce3712View commit details
Commits on Mar 12, 2024
-
Configuration menu - View commit details
-
Copy full SHA for 980fe72 - Browse repository at this point
Copy the full SHA 980fe72View commit details -
Configuration menu - View commit details
-
Copy full SHA for a4668dc - Browse repository at this point
Copy the full SHA a4668dcView commit details -
I'm concerned.. is this step cheating?
I feel the compiler should do more work, other than just delegating.
Configuration menu - View commit details
-
Copy full SHA for 61ae0bb - Browse repository at this point
Copy the full SHA 61ae0bbView commit details -
Configuration menu - View commit details
-
Copy full SHA for 6b6d20e - Browse repository at this point
Copy the full SHA 6b6d20eView commit details -
1. COMPILE now takes ast of function type. 2. Support eval and debugger toggle.
Configuration menu - View commit details
-
Copy full SHA for 1858659 - Browse repository at this point
Copy the full SHA 1858659View commit details -
Configuration menu - View commit details
-
Copy full SHA for 58a6879 - Browse repository at this point
Copy the full SHA 58a6879View commit details -
Configuration menu - View commit details
-
Copy full SHA for c384cf1 - Browse repository at this point
Copy the full SHA c384cf1View commit details -
Configuration menu - View commit details
-
Copy full SHA for f627b37 - Browse repository at this point
Copy the full SHA f627b37View commit details -
Configuration menu - View commit details
-
Copy full SHA for 58f3a6b - Browse repository at this point
Copy the full SHA 58f3a6bView commit details -
Configuration menu - View commit details
-
Copy full SHA for a46552f - Browse repository at this point
Copy the full SHA a46552fView commit details -
Configuration menu - View commit details
-
Copy full SHA for 404376f - Browse repository at this point
Copy the full SHA 404376fView commit details -
Implement fn* the right way without cheating.
(by cheating I mean deferring compilation)
Configuration menu - View commit details
-
Copy full SHA for f404182 - Browse repository at this point
Copy the full SHA f404182View commit details -
Configuration menu - View commit details
-
Copy full SHA for 07278d4 - Browse repository at this point
Copy the full SHA 07278d4View commit details
Commits on Mar 13, 2024
-
Made some changes that I don't fully understand. It's not working yet. I think I know what to do in the following ocmmits.
Configuration menu - View commit details
-
Copy full SHA for 66c2dfd - Browse repository at this point
Copy the full SHA 66c2dfdView commit details
Commits on Mar 14, 2024
-
It's still a mess and unusable now. But I know what to do now. When an AST (A) gets compiled, the end result is a code (C) to be executed. Execution of C should return a *closure* (not a function, which I've been doing, which is wrong), that holds a slot telling the function where to look for literals (e.g. scalars, functions, objects.. etc). So far I've been trying to save those literals in a global constant _consts. It was why my code failed so far because some compiled ASTs may be alive even after the next compilation. As a consequence, as they are reading from the global _consts, they read the wrong data.
Configuration menu - View commit details
-
Copy full SHA for 9aec4f8 - Browse repository at this point
Copy the full SHA 9aec4f8View commit details -
DONE defmacro! All tests passed :)
The closure way is the right way to go. Woo hoo :)
Configuration menu - View commit details
-
Copy full SHA for 39f897f - Browse repository at this point
Copy the full SHA 39f897fView commit details -
Configuration menu - View commit details
-
Copy full SHA for 0b484ec - Browse repository at this point
Copy the full SHA 0b484ecView commit details -
Configuration menu - View commit details
-
Copy full SHA for 0e38138 - Browse repository at this point
Copy the full SHA 0e38138View commit details -
Configuration menu - View commit details
-
Copy full SHA for 500bcfc - Browse repository at this point
Copy the full SHA 500bcfcView commit details -
Configuration menu - View commit details
-
Copy full SHA for 39acea6 - Browse repository at this point
Copy the full SHA 39acea6View commit details -
Configuration menu - View commit details
-
Copy full SHA for a2b062c - Browse repository at this point
Copy the full SHA a2b062cView commit details -
Configuration menu - View commit details
-
Copy full SHA for 864d13a - Browse repository at this point
Copy the full SHA 864d13aView commit details -
Configuration menu - View commit details
-
Copy full SHA for 4444bbb - Browse repository at this point
Copy the full SHA 4444bbbView commit details
Commits on Mar 15, 2024
-
Configuration menu - View commit details
-
Copy full SHA for 55f3a2a - Browse repository at this point
Copy the full SHA 55f3a2aView commit details -
Configuration menu - View commit details
-
Copy full SHA for 0c89eb1 - Browse repository at this point
Copy the full SHA 0c89eb1View commit details -
Configuration menu - View commit details
-
Copy full SHA for f99c682 - Browse repository at this point
Copy the full SHA f99c682View commit details -
Configuration menu - View commit details
-
Copy full SHA for 2745b97 - Browse repository at this point
Copy the full SHA 2745b97View commit details -
Configuration menu - View commit details
-
Copy full SHA for 882c32d - Browse repository at this point
Copy the full SHA 882c32dView commit details -
Configuration menu - View commit details
-
Copy full SHA for 4f6e497 - Browse repository at this point
Copy the full SHA 4f6e497View commit details -
Configuration menu - View commit details
-
Copy full SHA for 7222e7c - Browse repository at this point
Copy the full SHA 7222e7cView commit details -
Configuration menu - View commit details
-
Copy full SHA for f6de0e3 - Browse repository at this point
Copy the full SHA f6de0e3View commit details -
Configuration menu - View commit details
-
Copy full SHA for 2153aa8 - Browse repository at this point
Copy the full SHA 2153aa8View commit details
Commits on Mar 20, 2024
-
Configuration menu - View commit details
-
Copy full SHA for b86e213 - Browse repository at this point
Copy the full SHA b86e213View commit details -
Configuration menu - View commit details
-
Copy full SHA for c07b337 - Browse repository at this point
Copy the full SHA c07b337View commit details -
Configuration menu - View commit details
-
Copy full SHA for b801b2d - Browse repository at this point
Copy the full SHA b801b2dView commit details -
Configuration menu - View commit details
-
Copy full SHA for 87272da - Browse repository at this point
Copy the full SHA 87272daView commit details -
Configuration menu - View commit details
-
Copy full SHA for 02fe154 - Browse repository at this point
Copy the full SHA 02fe154View commit details -
Configuration menu - View commit details
-
Copy full SHA for ad5928d - Browse repository at this point
Copy the full SHA ad5928dView commit details
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.