in-progress compiler for Windows/Linux/macOS
C Other
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
examples
mk
phase1
phase2
phase3
phase4
phase5
src
.gitignore
COPYING
FEATURES
README
cleanup.pl

README

        Kit v0.00.2C.x

Current status:  "This is a test!  Ignore!!!"

1. BUILD INSTRUCTIONS

(From a Visual Studio command line:)

   mk\build_windows.bat

or  (on 32-bit Linux, or 64-bit with gcc-multilib)

   ./mk/build_linux.sh

or  (on OS X, with XCode tools (i.e. clang) installed)

   ./mk/build_osx.sh


2. RUN INSTRUCTIONS

   # Run tests.
   s6
   # Run tests more verbosely.
   s6 --build
   # Run tests verbosely, without the codegen phase.
   s6 --no-build

   # Build modulename.ki and its imports for Windows, => modulename.obj
   s6 <modulename>

   # Build modulename.ki and its imports, => modulename.o
   s6 --linux <modulename>
   s6 --osx <modulename>

3. FOR FREEBSD USERS

   FreeBSD works out of the box with "--linux" -- you'll probably
   need to tweak the mk/linux scripts to use clang.

4. PREREQUISITES

  -. An x86 CPU.
  -. One of:
    a. Windows (MSVC 2013 or 2015)
    b. Linux (gcc with 32-bit support, i.e. gcc-multilib)
    c. OS X (with clang, i.e. XCode's command line tools, or maybe some GCC)
    c. FreeBSD (using the "--linux" option, it makes an ELF .o file)

5. DIRECTORY STRUCTURE

The current directory structure is:

   phase1 - s1, implemented in C.  Compiles s2.
   phase2 - s2, implemented in proto-Kit.  Compiles s2 and s3.
   phase3 - s3, implemented in proto-Kit.  Compiles s3 and s4.
   phase4 - s4, implemented in proto-Kit.  Compiles s4 and s5.
   phase5 - s5, implemented in proto-Kit.  Compiles s5 and s6.
   src - s6, implemented in proto-Kit.  Compiles s6.
   examples - examples to run, disorganized junk

  ABOUT THE VERSIONS

- s1's language is merely "C, with templates, constructors and
destructors, elementary encapsulation, tagged enum types, no
implicit conversions."

- s2's is very similar to s1's, but with some worthwhile
enhancements that s1 does not support.

- s3 uses s2's quick-return expressions.

- s4 uses s3's generalized indexing expressions.

- s5 uses s4's foreach loops. It defines the same language as s4.

- s6 should be compilable via s4 and s5.  s1 will someday be
  capable of compiling s6 directly (once quick-return, generalized
  indexing, and foreach loops get added).

At some point, the highest-numbered version will use features that
s1 will never support.  See FEATURES for more information.

  ABOUT THE IMPLEMENTATIONS

s1 can target x86 and, on Linux, amd64.  Use --linux64 to target
amd64.

s2, s3, s4, and s5 can only target x86.