https://github.com/pickledchair/pl0dash
PL/0' compiler
https://github.com/pickledchair/pl0dash
Last synced: 10 months ago
JSON representation
PL/0' compiler
- Host: GitHub
- URL: https://github.com/pickledchair/pl0dash
- Owner: PickledChair
- Created: 2020-09-05T10:00:09.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2020-09-05T10:04:08.000Z (almost 6 years ago)
- Last Synced: 2025-03-12T06:16:44.745Z (over 1 year ago)
- Language: Rust
- Size: 14.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# PL/0' コンパイラ(in Rust)
勉強のために、中田育男先生の著書「[コンパイラ 作りながら学ぶ](https://www.ohmsha.co.jp/book/9784274221163/)」の巻末のソースコード(C言語による)を比較的素直にRustで書き直したものです。
(オリジナルのコードは[中田先生のホームページ](http://www.k.hosei.ac.jp/~nakata/oCompiler/oCompiler.html)でも公開されています。)
## 実行方法
```
$ cargo run /path/to/pl0dash_source
```
あるいは
```
$ cargo run
...
enter source file name
/path/to/pl0dash_source
```
## 命令語のリストを印字
```
$ cargo run /path/to/pl0dash_source -p
```