diff --git a/src/kernel.hcl b/src/kernel.hcl new file mode 100644 index 0000000..037c331 --- /dev/null +++ b/src/kernel.hcl @@ -0,0 +1,30 @@ +class Object { +} + +class Collection: Object { +} + +class IndexedCollection: Collection { +} + +class FixedSizedCollection: Collection { +} + +class Array: FixedSizedCollection { +} + +class String: Array { +} + +fun Collection:length() { + return (arr.length self) +} + +fun Collection:slice(index count) { + return (arr.slice self index count) +} + + + + +printf "string length %d\n" ("aaaa":length)