> - Give an example that showcases all rules of your EBNF. The program should "do" something as used in the next exercise.
> - For your implementation, show that your compiler successfully accepts the input program.
**Accepted code**
```Rust
fn main() {
let mut a = 3;
let b = &mut a;
*b = 1;
while a <= 3 {
*b = add(*b, 1);
}
let c = a / 3;
}
fn add(a:i32, b:i32) -> i32 {
a+b
}
```
> - Give a set of examples that are syntactically illegal, and rejected by your compiler.
**Rejected Code**
```Rust
```
> - Compare your solution to the requirements (as stated in the README.md). What are your contributions to the implementation.
I have fullfilled all of the of the requirements for a minimal subset of Rust such as:
* Functions
* Statements
* Expressions
* Primitive types and literals
* Returns
* References and Dereferences
## Your semantics
## Your semantics
...
@@ -46,14 +267,6 @@
...
@@ -46,14 +267,6 @@
- Compare your solution to the requirements (as stated in the README.md). What are your contributions to the implementation.
- Compare your solution to the requirements (as stated in the README.md). What are your contributions to the implementation.
## Your LLVM/Crane-Lift backend (optional)
- Let your backend produce LLVM-IR/Crane Lift IR for an example program (covering the translations implemented).
- Describe the translation process, and connect back to the generated IR.
- Compare your solution to the requirements (as stated in the README.md). What are your contributions to the implementation.
## Overall course goals and learning outcomes.
## Overall course goals and learning outcomes.
Comment on the alignment of the concrete course goals (taken from the course description) to the theory presented, work You have done and knowledge You have gained. (I have put some comments in [...]).
Comment on the alignment of the concrete course goals (taken from the course description) to the theory presented, work You have done and knowledge You have gained. (I have put some comments in [...]).