Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
D
D7050E
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Hugo Wangler
D7050E
Commits
cb7225fb
Commit
cb7225fb
authored
5 years ago
by
Hugo Wangler
Browse files
Options
Downloads
Patches
Plain Diff
Update HOME_EXAM_Type_check_part2.md
parent
682b680a
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
HOME_EXAM_Type_check_part2.md
+6
-6
6 additions, 6 deletions
HOME_EXAM_Type_check_part2.md
with
6 additions
and
6 deletions
HOME_EXAM_Type_check_part2.md
+
6
−
6
View file @
cb7225fb
...
...
@@ -76,40 +76,40 @@ math```
or
math
```
```
math
\frac{\Gamma \ \vdash \ e1 \ : \ i32 \quad \Gamma \ \vdash \ e2 \ : \ i32}{\Gamma \ \vdash (e1 \ != \ e2) \ : \ bool}
```
### Assignment
Given the type $
`\tau`
$, variable $
`x`
$ and value $
`n`
$
math
```
```
math
\frac{\Gamma \ \vdash \ x \ : \ \tau \quad \Gamma \ \vdash \ n \ : \ \tau}{\lang x := n, \sigma \rang \ \Darr \ \Gamma \ \vdash x \ : \ \tau}
```
### **let** assignment
math
```
```
math
\frac{\Gamma \ \vdash \ n \ : \ \tau}{\lang \text{let} \ x \ : \ \tau \ := \ n, \sigma \rang \ \Darr \ \Gamma \ \vdash x \ : \ \tau}
```
### **while** statement
The condition, $
`b`
$, of the while statement
math
```
```
math
\frac{}{\Gamma \ \vdash b \ : \ bool}
```
### **if/elseif** statement
The conditions, $
`b_i`
$, of the if- and elseif-statements
math
```
```
math
\frac{}{\Gamma \ \vdash b_i \ : \ bool}
```
### Functions
Given the function $
`p`
$ with the type of its return type
math
```
```
math
\frac{\Gamma \ \vdash p \ : \ \tau \quad \lang p, \sigma \rang \ \Darr \ n}{\Gamma \ \vdash n \ : \ \tau}
```
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment