X-Git-Url: https://ocean-lang.org/code/?p=ocean-D;a=blobdiff_plain;f=00-TODO;h=25b8eb127dca08f3154a57a45e83ad956ad388aa;hp=ac474b28506bfa2ff427392fd1a5c566284d59d6;hb=62fa958bc69d7b1701376c391a80382d7a7d00d7;hpb=fb71b26483853b4e8198c3b5ca1c3f2ec554a800 diff --git a/00-TODO b/00-TODO index ac474b2..25b8eb1 100644 --- a/00-TODO +++ b/00-TODO @@ -1,17 +1,30 @@ This is a living document - delete things when done. Avoid discussion. Current version (Cataract Creek) +- functions to return type with 'use' +- functions to return structure with name assignment - bare 'use'? +- '?' prefix operator returns Boolean +- reference to struct (@foo), with @new, @free, @nil +- more number types, no units yet + +Later +- string manipulation +- file i/o +- enum +- basic methods - structs - const fields ... what does that mean? Assign once as initialization? Can be used for array size? What else? - anonymous field - array or struct (or pointer to these) multiple anon struct are allowed if they don't conflict - - [] can apply to anon array field - - anon struct field gets fields interpolated + no - transparent fields! They still have a name, but you can + look through it. + - [] can apply to transparent array field + - transparent struct field gets fields interpolated - - anon fields have no name before the :, so + - How to give attributes? just say the word? struct foobar: - :content + x:content transparent size:number - manifest values for arrays and structs [a,b,c] @@ -19,6 +32,13 @@ Current version (Cataract Creek) That last doesn't parse easily, unless we require tags... not a good idea. [ .[1] = a, .[2] = b ] ?? Maybe. or () to group, [] for index. To (.foo=a) ( [1] = b ) + + I think that last works. () might almost be optional + .foo=a + is an expression means a structure with a .foo field assined to 'a' + [3] = 2 + is an array for at least 4 elements with 4th set to 2. + - yet more operators << >> # bit-ops & | ~ &~ @@ -44,14 +64,20 @@ Much later - per-field attributes constant, stable, add-only, read-only, mutable, owned, borrowed, dependant, pure - records -- enum +- enum / set - classes - constructors and destructors - or "after" ?? + destructors, which can be declared inline - vtables, fat pointers, list of approaches - operators as interface methods + + - * / etc make an arith interface add sub mult div - interfaces, inheritance - modules, imports and exports + public(version) on types, fields etc - closures, threads, co-routines, generators +- generics/templates. These should be just a compile-time + decision. Same code can be called with suitable methods passed, or + recompiled in the new context and then optimised. - introspection / reflection ? e.g. support serialization find function given a string holding the name