1
1
mirror of https://github.com/github/semantic.git synced 2024-12-18 20:31:55 +03:00
Commit Graph

21 Commits

Author SHA1 Message Date
Rob Rix
e1f38f64d0 Precompute the width of the matrix. 2015-11-12 15:26:50 -05:00
Rob Rix
dd812a2b2b Test that we aren’t at the endIndex instead of testing containment.
This should be O(1) for all index types.
2015-11-12 15:20:51 -05:00
Rob Rix
ee285d79dd Don’t transpose the coordinate system. 2015-11-05 16:12:53 -05:00
Rob Rix
217a2c5a50 Define Matrix over two ranges. 2015-11-05 15:51:15 -05:00
Rob Rix
fc76ce05eb Matrix can be constructed with a pair of ranges. 2015-11-05 15:45:30 -05:00
Rob Rix
38686fee20 constructRowMajor operates over a pair of ranges. 2015-11-05 15:45:19 -05:00
Rob Rix
5bf82fd366 🔥 Memo and Stream. 2015-10-13 00:51:43 -04:00
Rob Rix
2726a43c83 Lazily, not eagerly.
`Memo.init` selected the eager version, of course, since the lazy
version takes a closure.
2015-10-06 14:19:39 -04:00
Rob Rix
1658219d59 Document constructRowMajor. 2015-10-06 14:17:14 -04:00
Rob Rix
092087fc54 Extract row-major ordering into a private function. 2015-10-06 14:15:21 -04:00
Rob Rix
934390a0d5 Retrieve in row-major order. 2015-10-06 14:11:36 -04:00
Rob Rix
d12c95e296 Insert in row-major order. 2015-10-06 14:11:26 -04:00
Rob Rix
6c8ce1bcb2 Append, don’t subscript.
Subscripting only replaces, never appends.
2015-10-06 13:29:43 -04:00
Rob Rix
6cef3b9884 Matrix is public. 2015-10-06 13:00:07 -04:00
Rob Rix
bdabcc5c24 Matrix.values is private. 2015-10-06 13:00:01 -04:00
Rob Rix
511ef4d1a1 Document that out-of-bound indices are safe. 2015-10-06 12:20:58 -04:00
Rob Rix
25f29c328c Document Matrix a little. 2015-10-06 12:19:59 -04:00
Rob Rix
3fdda99653 Matrix is a functor. 2015-10-05 17:18:40 -04:00
Rob Rix
0e8b74e830 Matrix has a private fieldwise constructor. 2015-10-05 17:18:35 -04:00
Rob Rix
81b6c172cf Populate the matrix with a compute function. 2015-10-05 17:12:28 -04:00
Rob Rix
c935e4a3d9 Stub in a matrix of memoized values. 2015-10-05 17:11:56 -04:00