mirror of
https://github.com/ProgramSnail/lang_modes_check.git
synced 2025-12-06 00:58:42 +00:00
update readme
This commit is contained in:
parent
1f8071c89b
commit
7055b353a9
1 changed files with 25 additions and 0 deletions
25
README.md
Normal file
25
README.md
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
# Check of modes correctness
|
||||
|
||||
## Info
|
||||
|
||||
https://blog.janestreet.com/oxidizing-ocaml-locality/
|
||||
https://blog.janestreet.com/oxidizing-ocaml-ownership/
|
||||
|
||||
- **locality:** *global* (default) or *local* (value should not be passed out of context, can be allocated on stach)
|
||||
|
||||
- **uniqueness:** *shared* (default), *unique* (used only once, consumed), *exclusive* (used only once in the same time)
|
||||
|
||||
- **linearity:** *many* (default), *once* (result value can be used by caller only once), *separated* (result value can be used by caller only once in the same time)
|
||||
|
||||
## Done
|
||||
|
||||
- *unique* check +
|
||||
- *exclusive* check
|
||||
- *local* check
|
||||
- *once* check
|
||||
- *separated* check
|
||||
- type check (optional)
|
||||
|
||||
## Examples
|
||||
|
||||
- *unique:* let f (unique x) = x * x in f;; -> error
|
||||
Loading…
Add table
Add a link
Reference in a new issue