X-Git-Url: https://ocean-lang.org/code/?p=ocean-D;a=blobdiff_plain;f=00-TODO;h=c4978a79fa6b4b2a913fe20df4e38d7b72c4cb2f;hp=56d26e39cb03bff4a43ccfb498fccc08b1a5c3f3;hb=95060a31f56b05d2ac6dd87c9d102f76be1b8174;hpb=eceb0a08424f3129775dfccc6de1a5f7f5b98d0a diff --git a/00-TODO b/00-TODO index 56d26e3..c4978a7 100644 --- a/00-TODO +++ b/00-TODO @@ -6,8 +6,10 @@ - allow global names to be used before they are declared. Assume global if undeclared, and complain in final analysis. + If used in 'use' and 'case', then make it a label +- avoid definition loops in global constants - allow type names to be used before declared. Need to re-evaluate all - type sizes after parse. + type sizes after parse. avoid loops - resolve the HACK of allowing assign from struct when name starts space. - '?' prefix operator returns Boolean, index operator for strings. Can be used to test for end-of-string @@ -20,9 +22,12 @@ - int nat cyc {i,n,c}{8,16,32,64} - maybe not cyc - it needs size. - ops: # & | ~ &~ - no shift: use (N * #shift) or (N / #shift) - op= +- make '.' modifier interpolate a deref if needed - enum, with multi-valued names. enum foo { yes, no, many(10) } bar:foo=.yes; if bar == .no... if ?bar.many: print bar.many, "items" Maybe .true and .false for Boolean +- change use/case labels in ".name" which creates a local enum if no + type is evident. - set, with bool or int members. set foo { pinned, memalloc, priority(4) } bar:foo = .memalloc | .priority(2). if bar.pinned: bar.priority += 1 . array slices - references to arrays @@ -50,8 +55,12 @@ - const structures can inherit from another, and update select fields. - 'use' labels *must* appear in case statements. - 'then' can extend a case section into some other. - + ## Needs Design +- const arrays that are initialized incrementally throughout the code, + and post-processed at compile-time, e.g. to sort or derive LR tables. + Maybe even across modules. + Need a syntax - union types - how do I want to support these? inheritance with variance? - lambda - 'error' value for various types. NIL for pointer NaN for float, extra flag bit