Skip to content

Commit 2d6e452

Browse files
committed
Start on READMEs for basis for #71
1 parent e9c01b5 commit 2d6e452

7 files changed

+43
-3
lines changed

basis/Holmakefile

+8-1
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,15 @@ OPTIONS = QUIT_ON_FAILURE
33
THYFILES = $(patsubst %Script.sml,%Theory.uo,$(wildcard *.sml))
44
TARGETS0 = $(patsubst %Theory.sml,,$(THYFILES))
55
TARGETS = $(patsubst %.sml,%.uo,$(TARGETS0))
6-
all: $(TARGETS) basis_ffi.o
6+
7+
README_SOURCES = basis.sml basis_ffi.c dependency-order
8+
9+
README.md: $(README_SOURCES) readmePrefix ../developers/readme_gen
10+
../developers/readme_gen $(README_SOURCES)
11+
12+
all: $(TARGETS) basis_ffi.o README.md
713
.PHONY: all
14+
815
ifndef CC
916
CC=gcc
1017
endif

basis/README.md

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
Contains the beginnings of a standard basis library for CakeML,
2+
similar to the standard basis library of SML.
3+
4+
[basis.sml](basis.sml):
5+
Convenience structure that re-exports all the libraries and theories of the
6+
CakeML basis library.
7+
8+
[basis_ffi.c](basis_ffi.c):
9+
Implements the foreign function interface (FFI) used in the CakeML basis
10+
library, as a thin wrapper around the relevant system calls.
11+
12+
[dependency-order](dependency-order):
13+
This file records the current, linear dependency order between the
14+
translation/CF theories making up the basis library verification.
15+
16+
[pure](pure):
17+
HOL definitions of the pure functions used in the CakeML basis.

basis/basis_ffi.c

+4
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
/*
2+
Implements the foreign function interface (FFI) used in the CakeML basis
3+
library, as a thin wrapper around the relevant system calls.
4+
*/
15
#include <stdio.h>
26
#include <string.h>
37
#include <stdlib.h>

basis/dependency-order

-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
(*
21
This file records the current, linear dependency order between the
32
translation/CF theories making up the basis library verification.
43

@@ -7,7 +6,6 @@ translator (which provides only translation_extends as a method for joining two
76
translations). Eventually, when we have an abstract mode translator, the
87
different modules can be made more independent and different combinations can
98
be selected than simple prefixes of the current ordering.
10-
*)
119

1210
std_prelude
1311
Runtime

basis/pure/Holmakefile

+6
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,8 @@
11
INCLUDES = ../../misc $(HOLDIR)/examples/formal-languages/regular
22
OPTIONS = QUIT_ON_FAILURE
3+
4+
README_SOURCES =
5+
6+
README.md: $(README_SOURCES) readmePrefix ../../developers/readme_gen
7+
../../developers/readme_gen $(README_SOURCES)
8+

basis/pure/README.md

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
HOL definitions of the pure functions used in the CakeML basis.
2+
3+
The CakeML code for the pure parts of the basis is produced
4+
from these by the translator.

basis/pure/readmePrefix

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
HOL definitions of the pure functions used in the CakeML basis.
2+
3+
The CakeML code for the pure parts of the basis is produced
4+
from these by the translator.

0 commit comments

Comments
 (0)