1
1
mirror of https://github.com/github/semantic.git synced 2024-12-29 18:06:14 +03:00
Commit Graph

18030 Commits

Author SHA1 Message Date
joshvera
2958d2578e Return currentFrame in Maybe
and throw CurrentFrameError and CurrentScopeError in terms that require a current scope and frame

Co-Authored-By: Rick Winfrey <rick.winfrey@gmail.com>
2018-11-06 13:43:14 -05:00
joshvera
e561bf1da7 Add declaration to LookupPathError
Co-Authored-By: Rick Winfrey <rick.winfrey@gmail.com>
2018-11-06 13:05:10 -05:00
joshvera
fdad4295a0 Don't define a prelude of TypeScript atm
Co-Authored-By: Rick Winfrey <rick.winfrey@gmail.com>
2018-11-06 13:04:49 -05:00
Timothy Clem
343289f1c5 Merge remote-tracking branch 'origin/master' into docstrings-round2 2018-11-06 09:17:49 -08:00
joshvera
e6cf810822 Merge remote-tracking branch 'origin/master' into heap-frames 2018-11-06 11:26:11 -05:00
Timothy Clem
a297d15f47 Fix for comments in expressions with python assignment changes 2018-11-06 08:01:33 -08:00
joshvera
1818a74060 Return ValueRef everywhere 2018-11-05 19:43:14 -05:00
joshvera
11a64f043e return value refs 2018-11-05 17:25:51 -05:00
joshvera
7ed1521ad6 use raiseHandler for runState calls 2018-11-05 17:08:37 -05:00
joshvera
0d9fc6a24a Remove Span constraints 2018-11-05 17:08:26 -05:00
joshvera
f6ffb8904f move type signatures from effects to sig 2018-11-05 17:07:59 -05:00
Patrick Thomson
bdc5db555b rename and prune 2018-11-05 16:56:49 -05:00
joshvera
2a90f1d13f fix type param 2018-11-05 16:11:51 -05:00
joshvera
5186b394e8 run scope graph and heap effects in evaluate 2018-11-05 16:11:45 -05:00
joshvera
28dff57ddb return ScopeGraph from doRequire 2018-11-05 16:11:28 -05:00
joshvera
1020f6dc61 use withLexicalScopeAndFrame in Statements 2018-11-05 16:11:16 -05:00
joshvera
f2754368cb If evaluatable instance returns a ValueRef 2018-11-05 16:11:04 -05:00
joshvera
63aa9da7f6 return undefined from Class instance 2018-11-05 16:10:42 -05:00
joshvera
fc426a9793 fix type constraints 2018-11-05 16:10:31 -05:00
joshvera
c9501897a1 Construct frame from Closure scope in Abstract.Call 2018-11-05 16:10:21 -05:00
joshvera
faffb3098e add heap semantics to BuiltIn 2018-11-05 16:10:04 -05:00
joshvera
14347215cb Set the declaration's scope in runFunction 2018-11-05 16:09:39 -05:00
Timothy Clem
bdb7ee0430 More tests 2018-11-05 13:09:37 -08:00
joshvera
95204199fb rename address to frameAddress 2018-11-05 16:09:14 -05:00
joshvera
674d835ad9 import AllocatorC 2018-11-05 16:09:02 -05:00
joshvera
652461a65f asArray returns values 2018-11-05 16:08:56 -05:00
joshvera
cb0c4ac8f2 address returns a slot 2018-11-05 16:08:50 -05:00
joshvera
9a1fc0f063 Return () from declare 2018-11-05 16:08:34 -05:00
joshvera
cd78a2aaa7 expose runAllocator 2018-11-05 16:08:20 -05:00
joshvera
fc6c21c85e Rename address to frameAddress 2018-11-05 16:08:06 -05:00
joshvera
2beb576dd7 assign to the correct slot in define 2018-11-05 16:07:44 -05:00
joshvera
b3b7d2e5ff fix constraints 2018-11-05 16:07:23 -05:00
joshvera
1f43f15c1d Remove deref from python package 2018-11-05 16:06:18 -05:00
joshvera
3c0e7ce322 remove configurationContext 2018-11-05 16:05:39 -05:00
joshvera
2eeaf7585c parameterize eavesdrop with value 2018-11-05 16:05:11 -05:00
joshvera
e4e6451b1e Remove configurationContext and fix type params 2018-11-05 16:04:52 -05:00
Timothy Clem
67724b2812 Take annotation from first item in list for snippets 2018-11-05 12:33:14 -08:00
Timothy Clem
7169685d06 Always use a wrapping list for python functions and classes 2018-11-05 12:32:46 -08:00
Timothy Clem
11c145589c Give class a custom Declarations1 instance 2018-11-05 09:27:41 -08:00
joshvera
37da68d706 Show builtIn name 2018-11-05 12:22:22 -05:00
joshvera
28ee7a136d currentScope returns in Maybe 2018-11-05 12:22:09 -05:00
joshvera
0d0ef95582 type parameters 2018-11-05 12:22:01 -05:00
Patrick Thomson
15f5319252 fix stray indent 2018-11-05 12:17:05 -05:00
Patrick Thomson
76f0ef7f38 Merge remote-tracking branch 'origin/master' into revisit-matching 2018-11-05 11:07:49 -05:00
Patrick Thomson
688219e380 Arrow instance, why not 2018-11-05 11:06:59 -05:00
Timothy Clem
fa60a394b4 Fully commit to new method of generating symbols 2018-11-05 08:03:09 -08:00
Timothy Clem
0cacdd84d0 Helps the warnings 2018-11-05 07:57:14 -08:00
Rob Rix
3cb4fc5711 Use pure instead of return & 🔥 the annotation. 2018-11-05 09:53:17 -05:00
Rob Rix
2ee79706e3 Whitelist attemptUnsafeArithmetic in the hlint config. 2018-11-05 09:51:56 -05:00
Rob Rix
68d87314ce Move the reduce duplication annotation into the hlint config. 2018-11-05 09:51:56 -05:00
Rob Rix
4f92337221 Move the ignore use . annotation into the hlint config. 2018-11-05 09:51:56 -05:00
Rob Rix
1e5920e318 Move the ignore eta reduce thing into the hlint config. 2018-11-05 09:51:04 -05:00
Rob Rix
fe9f0b0aeb 🔥 a redundant hlint annotation. 2018-11-05 09:49:34 -05:00
Patrick Thomson
292a268b00 better name for infix operator 2018-11-04 14:46:19 -05:00
Patrick Thomson
a84b25ad6e remove Data.Algebra import 2018-11-04 14:39:38 -05:00
Patrick Thomson
8e4f9ea119 better docs 2018-11-02 19:43:12 -04:00
Patrick Thomson
7ea52dbfe3 Give Control.Matching API better ergonomics.
Given that @tclem and I have found the matcher API frustrating, I've
taken a stab at improving its ergonomics, and I've found some success
in separating composition of matchers from predicate-based narrowing
thereof.

The biggest change here is the elimination of the old `match`
combinator, which proved to be clumsy in that it complected narrowing
and composition. Top-down matching combinators are now written with
the `need` combinator and the `>>>` combinator, which is more readable
and more versatile. Here's a matcher that accepts functions with
Python docstrings:

```haskell
docstringMatcher :: ( Decl.Function :< fs
                    , [] :< fs
                    , Lit.TextElement :< fs
                    , term ~ Term (Sum fs) ann
                    ) => Matcher term term
docstringMatcher = target <*
               (need Decl.functionBody
                >>> narrow @[]
                >>> mhead
                >>> narrow @Lit.TextElement
                >>> ensure Lit.isTripleQuoted))
```

Pretty readable, right? Each step of the tree regular expression -
choosing function bodies, ensuring said bodies are lists, examining
the first element, and choosing only TextElements containing
triple-quoted strings - is made implicit. The old way would have
looked something like this:

```haskell
docstringMatcher = target <* match Decl.functionBody
                           $ narrow
                           $ matchM listToMaybe
                           $ target <* ensure Lit.isTripleQuoted
```
which is a good deal more disorganized and less flexible
in the quite-common case of applying functions during a
matching pass. Separating the act of composition from
function application is a big win here.

Further comments are inline.
2018-11-02 19:25:29 -04:00
Timothy Clem
8d12b5c242 Fix declarations to make tests pass 2018-11-02 13:55:55 -07:00
Timothy Clem
5b9b0daee3 Helper for testing ruby tags 2018-11-02 13:55:46 -07:00
Timothy Clem
bf90ef8e45 Did this 2018-11-02 13:54:55 -07:00
joshvera
2f3fc46e00 Remove subterm uses 2018-11-02 16:18:49 -04:00
joshvera
29383adf7a currentScope returns in Maybe 2018-11-02 16:18:35 -04:00
joshvera
42b350cc6e Remove evalQualifiedImport 2018-11-02 16:18:24 -04:00
joshvera
bb39ebde84 use withLexicalScopeAndFrame 2018-11-02 16:18:16 -04:00
joshvera
6470a3a976 Remove ScopeEnv constraint 2018-11-02 16:17:58 -04:00
joshvera
39deb34db6 ignore define values 2018-11-02 16:17:50 -04:00
joshvera
5647df2a16 remove instance sigs 2018-11-02 16:17:43 -04:00
joshvera
cb8a1222c0 forLoop in terms of withLexicalScopeAndFrame 2018-11-02 16:17:32 -04:00
joshvera
595b3d8747 Add withLexicalScopeAndFrame 2018-11-02 16:17:10 -04:00
joshvera
02bcc64102 Fix Env constraints 2018-11-02 16:17:01 -04:00
Timothy Clem
223298b86a Merge remote-tracking branch 'origin/master' into docstrings-round2 2018-11-02 12:54:21 -07:00
Timothy Clem
018dc73af9 Python assignment: conditionally include annotation on functions 2018-11-02 12:39:38 -07:00
joshvera
f50329ced4 fix up Abstract, Type, and Value 2018-11-02 15:33:45 -04:00
Timothy Clem
a87c526977 No errors, just keep trying 2018-11-02 12:30:43 -07:00
joshvera
d93f2adcd5 fix up primitive, value, and heap 2018-11-02 15:03:10 -04:00
Patrick Thomson
b4a469c706 Merge branch 'master' into add-tsparse-quiet-flag 2018-11-02 13:07:58 -04:00
Patrick Thomson
0a117222c1 Merge branch 'master' into add-explicit-assignment-timeout 2018-11-02 11:10:09 -04:00
Patrick Thomson
b9a742e6db address @rewinfrey's suggestion 2018-11-02 11:03:57 -04:00
Patrick Thomson
a62840c58d Be commensurate with parse --quiet 2018-11-02 11:00:09 -04:00
Patrick Thomson
bd51a186e7 Merge remote-tracking branch 'origin/master' into add-tsparse-quiet-flag 2018-11-02 09:16:28 -04:00
joshvera
e2f9773f7f type signatures 2018-11-01 23:09:03 -04:00
joshvera
4e2126611b Remove allocator from Heap 2018-11-01 23:08:57 -04:00
joshvera
e30239123d port State ScopeGraph to fused effects 2018-11-01 23:08:45 -04:00
joshvera
f85a2d0f1a Evaluator sig 2018-11-01 23:08:28 -04:00
joshvera
daf17e426d derive any class 2018-11-01 22:45:51 -04:00
joshvera
2c4c53904b No effectful constraint 2018-11-01 22:33:43 -04:00
joshvera
82c50ed96d remove pureeffect 2018-11-01 22:32:46 -04:00
joshvera
5234688d9c circular imports 2018-11-01 22:32:30 -04:00
joshvera
c2643d3463 Don't make the heap a monoidal map 2018-11-01 22:32:14 -04:00
joshvera
86253d11c7 NFData instance 2018-11-01 22:31:55 -04:00
joshvera
4870936047 add value param to LoadError 2018-11-01 22:28:45 -04:00
joshvera
069a50a634 add NFData to Position 2018-11-01 22:28:38 -04:00
joshvera
ef9a54cabe add value back to Modules 2018-11-01 22:28:21 -04:00
joshvera
a1bdbccb53 parameterize LoopControl by value 2018-11-01 22:28:10 -04:00
Josh Vera
9f22607fc0 Merge branch 'master' into diff-via-fused-effects 2018-11-01 22:21:46 -04:00
Timothy Clem
55787183b9 Use evalState 2018-11-01 17:40:58 -07:00
Timothy Clem
12a4fc5073 Turn this on for classes and Modules 2018-11-01 17:40:49 -07:00
Timothy Clem
d26cd0bf1a No need for State in this fold 2018-11-01 17:16:34 -07:00
Timothy Clem
63e13ee20c Merge remote-tracking branch 'origin/master' into docstrings-round2 2018-11-01 16:04:15 -07:00
Timothy Clem
02c9074b7e Format, hide lang 2018-11-01 16:03:12 -07:00
Timothy Clem
92f9f8373e Render to same output format, respecting field choice 2018-11-01 15:48:47 -07:00
Timothy Clem
806c5c417b Include a place for span 2018-11-01 15:48:35 -07:00
Rick Winfrey
9e753a1757 Remove conflict markers 2018-11-01 15:39:09 -07:00
Rick Winfrey
4750d51bf6 Merge branch 'master' into heap-frames
Co-Authored-By: Josh Vera <vera@github.com>
2018-11-01 15:29:45 -07:00
Timothy Clem
1f6a7b9e48 Move HasTextElement 2018-11-01 14:49:35 -07:00
Timothy Clem
59bdb77fc4 Import cleanup 2018-11-01 14:39:15 -07:00
Timothy Clem
460ea0cf67 Rough, but WORKING symbols output with doc strings 2018-11-01 14:31:19 -07:00
Timothy Clem
f860d4aa66 Add in util for Go defs 2018-11-01 13:20:50 -07:00
Patrick Thomson
514dacf756 Merge branch 'master' into add-data-coerce-to-prologue 2018-11-01 12:51:21 -04:00
Timothy Clem
24a9b2b6ea s/Tag/Symbol 2018-11-01 07:56:28 -07:00
Timothy Clem
77f5b0a1d6 Introduce new renderToSymbols 2018-11-01 07:55:34 -07:00
Rob Rix
98805db943 Merge branch 'master' into diff-via-fused-effects 2018-10-31 18:39:24 -04:00
Timothy Clem
7aaeca419f Don't need this 2018-10-31 15:02:14 -07:00
Timothy Clem
c1d3f60073 Make use of language 2018-10-31 15:01:39 -07:00
Patrick Thomson
b9cf8f73c6 Environment and App. 2018-10-31 15:47:30 -04:00
joshvera
ef67897838 Make it compile 2018-10-31 15:37:13 -04:00
Timothy Clem
e18c65ce47 tag doesn't need to be a method 2018-10-31 12:27:01 -07:00
Timothy Clem
0111afde81 Fix up ConstructorNameStrategy for TermF 2018-10-31 12:26:38 -07:00
joshvera
e83b2b75b6 Revert "Fix up constraints"
This reverts commit 922d244a6100c1740c253d8f56ad55b67cdf58b0.
2018-10-31 14:28:15 -04:00
Rick Winfrey
0c6afc5995 Fix up constraints 2018-10-31 11:16:51 -07:00
Timothy Clem
2ccb468800 Taggable instance for Context 2018-10-31 11:08:14 -07:00
Timothy Clem
d4d19ea21f Some renaming, split out into two modules 2018-10-31 10:58:00 -07:00
Patrick Thomson
d473b9e1af add Data/Abstract/Name/Spec 2018-10-31 13:19:43 -04:00
joshvera
8b57ade7e6 Add runState call 2018-10-31 12:59:21 -04:00
Patrick Thomson
b0e6190dbf add Data/Range/Spec 2018-10-31 12:46:52 -04:00
Patrick Thomson
cd05aaa7a5 add Data/Graph/Spec 2018-10-31 12:30:56 -04:00
Timothy Clem
427e933b36 Minor cleanup 2018-10-31 08:41:41 -07:00
Timothy Clem
945ab01275 Introduce Taggable 2018-10-31 08:34:58 -07:00
Timothy Clem
100ffff873 Only annotate Python functions if there is a type 2018-10-31 08:34:58 -07:00
Timothy Clem
335989f22d Small helper to test new tags 2018-10-31 08:34:58 -07:00
Timothy Clem
55670cd524 Strings in mini python 2018-10-31 08:29:00 -07:00
Timothy Clem
feef6e3ed6 Generic1 instance for TermF 2018-10-31 08:28:37 -07:00
Timothy Clem
3e26d933b3 MonadFail for Matcher 2018-10-31 08:28:22 -07:00
Patrick Thomson
fd94b225c9 Merge branch 'master' into add-tsparse-quiet-flag 2018-10-31 11:09:20 -04:00
Patrick Thomson
f0d9ba3f8a one last import 2018-10-31 09:36:04 -04:00
Patrick Thomson
27a9ae546a Merge branch 'master' into add-data-coerce-to-prologue 2018-10-31 09:09:37 -04:00
Rob Rix
c95822894e Merge branch 'master' into diff-via-fused-effects 2018-10-30 23:03:50 -04:00
joshvera
09ab5d74a0 Fix some Graph module errors 2018-10-30 19:47:22 -04:00
joshvera
3fd78a2938 fix constraints in outer modules 2018-10-30 18:19:16 -04:00
joshvera
8c41511c87 lowerBound for Heap 2018-10-30 18:19:06 -04:00
Patrick Thomson
015abadea2 Merge branch 'master' into break-dependency-of-config-on-SHA 2018-10-30 18:10:58 -04:00
Rick Winfrey
ad2bb368dd Comment out resumingEnvironmentError 2018-10-30 14:03:00 -07:00
Rick Winfrey
e3be56166a Add fix me comments to evaluatable instances 2018-10-30 13:50:43 -07:00
Rick Winfrey
b1521a30fa Replace usage of insertEdge in favor of new combinators 2018-10-30 13:23:36 -07:00
Rick Winfrey
e7d94f9555 Add insert edge combinators 2018-10-30 13:22:49 -07:00
Patrick Thomson
cb54dd7aed Merge remote-tracking branch 'origin/master' into repl-effect 2018-10-30 15:58:00 -04:00
Patrick Thomson
c73696fcc0 Merge branch 'master' into add-explicit-assignment-timeout 2018-10-30 15:53:29 -04:00
Patrick Thomson
5cac709075 Merge remote-tracking branch 'origin/master' into add-tsparse-quiet-flag 2018-10-30 15:53:02 -04:00
Rob Rix
74f183921a Merge branch 'master' into break-dependency-of-config-on-SHA 2018-10-30 15:40:48 -04:00
Rob Rix
994464105c Merge branch 'master' into diff-via-fused-effects 2018-10-30 15:40:42 -04:00
Patrick Thomson
c4698ff96c Merge branch 'master' into add-data-coerce-to-prologue 2018-10-30 15:40:14 -04:00
Patrick Thomson
a16822e7c3 oops, wrong file 2018-10-30 15:39:04 -04:00
Patrick Thomson
2d91f7e263 stray pragma 2018-10-30 15:24:47 -04:00
Patrick Thomson
3caa753808 Add Data.Coerce to the Prologue.
This is ubiquitous enough that we should just export it.
2018-10-30 15:12:45 -04:00
Patrick Thomson
aa34a5b2c9 cleanup 2018-10-30 15:05:25 -04:00
Patrick Thomson
3cb8608703 Merge remote-tracking branch 'origin/master' into add-purely-to-matching 2018-10-30 15:00:37 -04:00
Rob Rix
8389097a81 Log a SHA of “development” when it’s absent from the Config. 2018-10-30 14:59:14 -04:00
Rob Rix
1ff9c7ac36 Move the SHA to Config. 2018-10-30 14:58:29 -04:00
Patrick Thomson
da1704af56 Extract the REPL effect into its own module.
I need this for the refactoring OKR.
2018-10-30 14:55:23 -04:00
Rob Rix
e44ab265ab 📝 optionsSHA. 2018-10-30 14:16:52 -04:00
joshvera
44b7e7640e Remove more constraints 2018-10-30 13:53:03 -04:00
Rob Rix
c71d9ba199 Include the SHA from the Options. 2018-10-30 13:48:22 -04:00
Rob Rix
4faf8dcc52 Add a SHA to Options. 2018-10-30 13:47:12 -04:00
Rob Rix
2d507b0912 Move the request_id field onto its own line. 2018-10-30 13:46:13 -04:00
Patrick Thomson
6b476d0eb7 Add 'purely' combinator to Matching and rename it.
@tclem and I found ourselves wanting an arrow-like combinator that
promotes a given function to a Matcher. While I think an Arrow
instance is going a little overboard, there's no harm in adding a
'purely' function, the naming of which is commensurate with the
rewriting DSL.

This also renames the module, since there's not anything really
abstract about matching (indeed, it is quite concrete).
2018-10-30 11:04:11 -04:00
Rick Winfrey
9d375d72a1 Comment out remaining problematic code 2018-10-29 16:41:40 -07:00
Rick Winfrey
8c26fbfb61 Fix up parts of Evaluatable Class; not sure about the klass declaration 2018-10-29 16:33:09 -07:00
Rick Winfrey
d76fcb73a7 Sketch out Evalutable TypeAlias 2018-10-29 16:01:59 -07:00
joshvera
25dae2319a Fix up a couple more eval instances
and comment out even more
2018-10-29 18:08:56 -04:00
Rob Rix
d477db7813 Terminate on the first result. 2018-10-29 11:58:33 -04:00
Rob Rix
1eacd39c0c Reformat the Carrier signature a little more. 2018-10-29 11:19:31 -04:00
Rob Rix
148eb81d51 Diffing.Algorithm no longer exports Empty. 2018-10-29 11:01:52 -04:00
Rob Rix
65b7707f46 Define diffing as an effect. 2018-10-29 11:01:41 -04:00
Rob Rix
5bf4479597 🔥 a stray LambdaCase. 2018-10-29 10:26:56 -04:00
Rob Rix
f8001765e0 Fix a dodgy import. 2018-10-29 09:59:29 -04:00
Rob Rix
636eec364e Update to fused-effects, replace \/ with handleSum and bundle Interpose. 2018-10-29 09:52:48 -04:00
Rob Rix
1b507fc5c0 Inline runValueEffects into evaluate. 2018-10-26 13:38:20 -04:00
Rob Rix
2734b380fc Move graphingModuleInfo above eavesdrop. 2018-10-26 13:12:51 -04:00
Rob Rix
2fd8bcad92 🔥 some unused language extensions. 2018-10-26 13:11:20 -04:00
Rob Rix
66d5a1dfe8 Run nondeterminism locally in flow-sensitive analysis. 2018-10-26 13:03:14 -04:00
Rob Rix
f0925ad0cf 📝 evaluate. 2018-10-26 13:00:37 -04:00
Rob Rix
55df272a2a 📝 evalTerm. 2018-10-26 12:58:30 -04:00
Rob Rix
33f20e0cf5 📝 runValueEffects. 2018-10-26 12:56:13 -04:00
Rob Rix
141ed75d40 Don’t export ModuleC/ValueC. 2018-10-26 12:54:35 -04:00
Rob Rix
77675e1b80 Rename analyzeTerm to perTerm. 2018-10-26 12:52:30 -04:00
Rob Rix
b5ae015260 Inline the definition of evalModule into evaluate. 2018-10-26 12:51:59 -04:00
Rob Rix
485cbfdcfe Inline the definition of runInModule into evalModule. 2018-10-26 12:47:23 -04:00
Rob Rix
cb19a79fad Run python packaging. 2018-10-26 12:40:26 -04:00
Rob Rix
4aae4db57d Implement python packaging directly in the carrier. 2018-10-26 12:37:26 -04:00
Rob Rix
197ef61386 Rename the carrier to PythonPackagingC. 2018-10-26 12:30:49 -04:00
Rob Rix
37d4fea7b2 Simplify the carrier for runPythonPackaging. 2018-10-26 12:30:06 -04:00
Rob Rix
24660fca31 Rename runInTerm to runValueEffects. 2018-10-26 12:24:37 -04:00
Rob Rix
6cf82efb50 Factor runInTerm out of evalModule. 2018-10-26 11:39:47 -04:00
Rob Rix
cc09615b7b Inline the definition of evaluateModules into evaluate. 2018-10-26 10:27:05 -04:00
Rob Rix
bfb3b8a352 Rename the type parameters relating to the outer context. 2018-10-26 10:18:25 -04:00
Rob Rix
2b9d751aad Factor the prelude definition into runInTerm. 2018-10-26 10:17:19 -04:00
Rob Rix
915c7f5c61 🔥 the Eavesdrop effect. 2018-10-25 23:13:47 -04:00
Rob Rix
2a600ee28a Give a type signature for evalModule. 2018-10-25 23:10:37 -04:00
Rob Rix
3979ea4e86 🔥 disjunction. 2018-10-25 22:56:08 -04:00
Rob Rix
d4c6edb156 🔥 Disjunction. 2018-10-25 22:54:00 -04:00
Rob Rix
bc08525229 Don’t specialize disjunction. 2018-10-25 22:50:16 -04:00
Rob Rix
5c6801a272 Parameterize evaluate by a function running all the effects. 2018-10-25 22:23:47 -04:00
Rob Rix
52ed317fe6 Treat the prelude as a sort of a module. 2018-10-25 21:52:37 -04:00
Rob Rix
ce407d1c9e Move a bunch of the evaluation machinery to Semantic.Analysis. 2018-10-25 21:40:37 -04:00
Rob Rix
1414df368d Define a high-level Semantic.Analysis module. 2018-10-25 21:31:38 -04:00
Rob Rix
830fde2104 Simplify evaluate to take the term evaluator. 2018-10-25 21:22:22 -04:00
Rob Rix
428d92788b Sort a couple of constraints down. 2018-10-25 21:13:28 -04:00
Rob Rix
b738dcc12b Run effects in module analysis. 2018-10-25 21:03:51 -04:00
Rob Rix
64df59c4bf Extract evalTerm. 2018-10-25 20:55:07 -04:00
Rick Winfrey
9fc1a17ac6 Merge branch 'master' into add-explicit-assignment-timeout 2018-10-25 14:34:22 -07:00
Rob Rix
097af57735 Factor the interposes into a runInTerm helper. 2018-10-25 17:34:04 -04:00
Rob Rix
4cad9bc45e Re-export Control.Abstract.ScopeGraph from Control.Abstract. 2018-10-25 16:42:53 -04:00
Rob Rix
8a3d7ba927 Don’t be clever. 2018-10-25 13:48:47 -04:00
Rob Rix
c625efd9c5 Extract the fold over modules to the top level. 2018-10-25 13:47:07 -04:00
Rob Rix
df10f93bcd Extract runInModule to the top level. 2018-10-25 13:44:28 -04:00
Rob Rix
70a3a58034 Merge branch 'higher-order-effects' into decompose-evaluate 2018-10-25 13:32:43 -04:00
Rob Rix
b5aae138c5 🔥 a commented-out line. 2018-10-25 13:29:10 -04:00
Rob Rix
996a2ab79c 🔥 HasPostlude. 2018-10-25 11:49:50 -04:00
Rob Rix
91e747db8d 🔥 the HasPostlude constraints on SomeAnalysisParser. 2018-10-25 11:49:45 -04:00
Rob Rix
1e83574cf0 🔥 the use of postludes. 2018-10-25 11:47:21 -04:00
Rob Rix
4531c9afc7 🔥 Prologue’s re-export of MonadError. 2018-10-25 10:21:14 -04:00
Patrick Thomson
74005e5746 Make flag info and unit formatting like parse --quiet. 2018-10-25 09:40:38 -04:00
Rob Rix
775bc6ef80 Bump higher-order-effects for interposition. 2018-10-25 09:27:40 -04:00
Rob Rix
05c4f76663 🔥 redundant parens. 2018-10-24 15:41:14 -04:00
Rob Rix
49d7068f46 Define hmap with a LambdaCase. 2018-10-24 15:39:52 -04:00
Rob Rix
fc935058a5 Define handle with a LambdaCase. 2018-10-24 15:39:25 -04:00
Rob Rix
f2473d2807 handleCoercible. 2018-10-24 15:35:46 -04:00
Rob Rix
95d200426d 🔥 redundant parens. 2018-10-24 15:35:03 -04:00
Rob Rix
66466448ec Simplify the reinterpretation in ScopeEnvC. 2018-10-24 15:26:20 -04:00
Rob Rix
2d71e0b6fc Parameterize ScopeEnvC by the address type. 2018-10-24 15:23:59 -04:00
Rob Rix
cc97e57b01 Align the ScopeEnvC cases. 2018-10-24 15:21:07 -04:00
Rob Rix
b353f88ec5 Define the ScopeEnvC algebra with LambdaCase. 2018-10-24 15:20:09 -04:00
Rob Rix
277b7ad906 handleCoercible. 2018-10-24 15:16:50 -04:00
Rob Rix
676b5b5105 🔥 some redundant parens. 2018-10-24 15:16:30 -04:00
Rob Rix
d559aa1162 Use uncurry. 2018-10-24 15:09:34 -04:00
Rob Rix
8c4853eb9b Use LambdaCase for the Modules handler. 2018-10-24 15:08:58 -04:00
Rob Rix
254e20e831 Ignore a hint that doesn’t work. 2018-10-24 15:07:23 -04:00
Rob Rix
131cae4d7b Merge branch 'master' into higher-order-effects 2018-10-24 14:04:13 -04:00
Patrick Thomson
ab221477a4 extra import 2018-10-24 13:43:45 -04:00
Patrick Thomson
6f87624e35 Merge remote-tracking branch 'origin/master' into add-tsparse-quiet-flag 2018-10-24 13:37:16 -04:00
Patrick Thomson
ac33c7ac3a Add timing info and make output commensurate with parse --quiet. 2018-10-24 13:36:19 -04:00
Rob Rix
2216fcc44a Effect, not carrier.
Co-Authored-By: Patrick Thomson <patrick.william.thomson@gmail.com>
2018-10-24 12:40:17 -04:00
Rob Rix
41d206b9fa Eavesdrop in evaluate.
Co-Authored-By: Patrick Thomson <patrick.william.thomson@gmail.com>
2018-10-24 12:39:53 -04:00
Rob Rix
8edc379c31 Use Eavesdrop from the library.
Co-Authored-By: Patrick Thomson <patrick.william.thomson@gmail.com>
2018-10-24 12:39:45 -04:00
Patrick Thomson
e5b7965fcd Add a --quiet flag to the ts-parse command.
When parsing huge source files, I found myself wanting to time how
long the `ts-parse` command takes; however, the time spent printing
large ASTs means that such timings are inaccurate. The `tree-sitter`
CLI provides a `--quiet` flag for this purpose; I've copied it here.
2018-10-24 11:01:38 -04:00
Rob Rix
15a8917c84 Simplify the FunctionC carrier instances. 2018-10-24 11:00:54 -04:00
Rob Rix
25b2c3c4e9 Encapsulate the state effects inside EnvC. 2018-10-24 10:21:29 -04:00
Rob Rix
bff13c7272 Parameterize EnvC by the address type. 2018-10-24 10:14:04 -04:00
Rob Rix
9c390c57ee Prune empty branches. 2018-10-23 17:00:53 -04:00
Rob Rix
b858c1db2a Specialize the Traversable instance for B. 2018-10-23 16:51:04 -04:00