Skip to main content

Compyler Compyler version

Compiler for Spring 2019 Compilers Course, implemented in python. Compiles a custom language into a subset of the 6502 opcodes.

Setup

To run the Compyler it must be installed. It can be installed either from pypi or from the source code of the directory.

From PyPi

Simply use pip to install the latest release of the compyler. To do so run pip install Compyler.

From Source

Either in a Python Virtual Environment or just on your machine in the root of the directory run make install this will install the compyler from the source code in the repo using the setup.py file. If you would like to uninstall simply run make uninstall

Compiling

Once setup has been completed an Alan++ source code file can be compiled. To do so run compyler /path/to/file

Arguements

path - The path of an Alan++ source file to be compiled.

Flags

--verbose or -v - when passed all actions of compiler will be logged to stdout.

--prettytree or -p - Outputs CST and AST in a fancier form.

Example

compyler -v -p ./examples/AssignVals.txt

Releases

0.1.0 - Project1

0.2.0 - Project2

0.3.2 - Project3

0.4.0 - Project4

Developing

To develop the compyler it would be a nuisance to install each time a change is made, to avoid this use a python virtual environment. To create a Virtual environment or venv use the following command python3 -m venv/path/to/new/virtual/environment The path should be pointed at this repository. To enter a venv that already exists navigate to the bin dir inside of env and run source activate. In the case of this repo the command would look like this, source ./env/bin/activate.

Once in a venv to run the compyler without installing use the following format: python3 compyler /path/to/source/file while in the root of the directory.

Publishing to PyPi

To publish the latest release of the build to pypi run the following recipe: make release. This will test, build and publish the release to pypi.

Metadata

Release files for Compyler 0.4.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for Compyler 0.4.4
File Size Uploaded
Compyler-0.4.4.tar.gz 18.9 kB Details

Release files / Compyler-0.4.4.tar.gz

Download URL Compyler-0.4.4.tar.gz
Size 18.9 kB
Tags Source
SHA-256 checksum
How to use checksums
0003a9098139a6606864886c54ad3b3717ae6de2566ab358ae6a01b8217331a8
BLAKE2b-256 checksum
How to use checksums
a29d67d65543c45a1ab23a6eeedadead505214da2658cb0a960dd4307b7191a1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.12.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.0 CPython/3.7.0

Release history Release notifications | RSS feed

This release

0.4.4 This release

1 release file

0.4.3

1 release file

0.4.2

1 release file

0.4.1

1 release file

0.4.0

1 release file

0.3.2

1 release file

0.3.1

1 release file

0.3.0

1 release file

0.2.0

1 release file

0.1.0

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page