Skip to content

Latest commit

 

History

History
154 lines (154 loc) · 5.77 KB

TODO.md

File metadata and controls

154 lines (154 loc) · 5.77 KB
  • inspiration: AWK, Haskell, J/APL/k, C (include)... (some architectural decisions mime GHC)

Release

  • Anchored streams
  • Bug: fold1
    • fold-of-scan-of-mapMaybe...
    • two expressions with fold1 (and also gather-folds)
    • fold: catmaybes, mapMaybes

Documentation

  • Document escaped characters
  • tuples
  • Document %i, %s in manpages

Unicode

  • reintercalate builtin
  • ∅ for monoidal identity
  • defeq ≔
  • arrows (types)
  • APL iota should be allowed instead of 'ix'
  • lambda
  • ♯ in front of type variables
  • 〈〈⟨⟩
  • unicode/apl for floor+ceiling

Features

  • set variables on the command-line?
    • fd has {}, {/}, etc. so one could use it to pass in filenames while invoking...
  • named columns (e.g. ``Ndxfor output ofreadelf -Ws`)
  • scan1
  • "mod"
  • $> operator like awk's END, allow stream to print and then present summary
  • Ord for tuples, vectors
  • occurs check
  • drop builtin/syntax?
  • $( anchor: evaluate multiple streams at once
  • $1: etc. parseable columns
  • :? parsemaybe
  • 0 literal could be a float
  • fail : a builtin (unicode bottom?)
  • Error when type is ambiguous (e.g. 3: - 2: or w/e)
  • mapMaybe, catMaybes? for Witherable...
    • vectors/lists should be a member!
  • iota for vectors etc.
  • SCANS
    • backend
  • ignore case?
  • environment variables
  • x need only be a keyword inside anonymous functions (dfns?)... otherwise it can be a variable!
    • that introduced a bug w/ nested dfns (euh)
  • .1 etc. to extract tuples (arrays?)
  • alex-style regex combinations, $digit+ and @string_in or w/e
  • parse dates
  • [½] map, filter, scan, prior for vectors &c.?
  • lint for duplicate names at top-level
  • list comprehensions or w/e
  • \$` as "all fields, as list" or something
  • dedupBy builtin
  • Infix operators
    • $> (ice cream cone?)
    • ~? (maybe match)
    • (<|>) (alternative)
  • fold without seed
    • seq 10 | ja "[x+','+y]|'' \$0"
    • foldMaybe
  • helios distribution? https://github.com/oxidecomputer/helios
  • csv format: FPAT = "([^,]*)|(\"[^\"]+\")"
  • substitute multiple to process
    vectorzmstreamzm0zi1zi0zi1zmb52aad89fd7b09efa5330a0a5ffa6e096514cefa8231d7a1e742d7f529db8237_DataziStreamziMonadic_zzipWith6_slow
    
    https://gitlab.haskell.org/ghc/ghc/-/wikis/commentary/compiler/symbol-names#variable-characters
  • https://www.thegeekstuff.com/2010/01/8-powerful-awk-built-in-variables-fs-ofs-rs-ors-nr-nf-filename-fnr/
    • OFS
    • ORS

Instances

  • Ord instance for option? (and lists)

Syntax

  • $$ synonym for newline?
  • .[ ... ] dfn where you specify that it's binary?
  • ? for if... then?
  • lineLength := (#")
  • {\<pat>}. $0 ... filter on stream expressions
    • or #: maybe?
  • 0$ or something... stream of lines line, split by field separator into a list

Examples

Bugs

vanessa@Vanessas-Air jacinda % seq 100001 | cabal run ja -- run test/examples/evenOdd.jac
(50000 . 50001)
vanessa@Vanessas-Air jacinda % seq 1000001 | cabal run ja -- run test/examples/evenOdd.jac
(500002 . 500000)
  • Scoping pass so that ix outside of {|...} would be caught
  • ix (line number) on filtered streams?

Performance

Examples

sed