1
1
mirror of https://github.com/github/semantic.git synced 2024-11-27 12:57:49 +03:00
Commit Graph

23 Commits

Author SHA1 Message Date
Patrick Thomson
d56377aea9 Prevent slowdowns when pretty-printing in ghci.
Right now, when opening a shell with `script/ghci`, you can encounter
a tremendous slowdown by turning on pretty-printing (with `pretty`)
then printing any value (`[0..3]` should work).

This stems from the fact that our `.ghci` specifies the `prettyShow`
function, defined in Semantic.Util, as its `-interactive-print`
function. While this is a good choice of a pretty-printer, the fact
that it is in Util, a file which imports many modules and uses fancy
types, is not good: pretty-printing cannot begin until Util is
recompiled and linked in. This explains why benchmarking this slowdown
revealed nothing but `dlsym` calls: we thought it was due to linking
in the tree-sitter libraries, but it was actually waiting for Util to
compile and link in.

The fix is simple: define `prettyShow` in another module. This should
provide significant speedups to our developer workflow.
2018-10-04 14:38:36 -04:00
Ayman Nadeem
e030824d52 fix conflicts with new haskell additions 2018-05-31 15:32:10 -07:00
Rob Rix
39e4f6cc0a Use prettyShow from .ghci. 2018-05-23 09:48:14 -04:00
Ayman Nadeem
b1c05d6755 Merge remote-tracking branch 'origin/master' into java-assignment 2018-05-01 10:57:21 -07:00
Timothy Clem
373004bdf6 Fix docs 2018-04-22 07:48:04 -07:00
Ayman Nadeem
a0d880f1fa add java and php to assignment macro in .ghci 2018-03-16 16:58:23 -07:00
Rob Rix
dbb1a33fca Rename Parser to Parsing.Parser. 2017-11-27 13:24:45 -05:00
Rob Rix
a5925ce9ed This doesn’t work. 2017-10-13 14:23:11 -04:00
Rob Rix
8b89c73979 Rename the reload binding to :r. 2017-10-13 12:47:46 -04:00
Rob Rix
1cc005bc4a Pretty-printing is on by default. 2017-10-13 12:47:28 -04:00
Rob Rix
bcf273b019 Define pretty with unlines & without importing. 2017-10-13 12:47:21 -04:00
Rob Rix
b77d847a19 🔥 source because it’s dangerous now. 2017-10-13 12:46:16 -04:00
Rob Rix
5e0a1c9101 Update .ghci 2017-10-13 12:42:08 -04:00
Rob Rix
b22f4f9fc3 No : in the prompt. 2017-10-13 11:41:52 -04:00
Rob Rix
b1a7056948 Make the assignment binding reloadable. 2017-10-13 11:24:13 -04:00
Rob Rix
e511bd2572 Document stuff in .ghci. 2017-10-13 11:23:55 -04:00
Rob Rix
55fec0a156 Add the assignment macro to the .ghci file. 2017-10-13 10:55:15 -04:00
Rob Rix
8d156bfa8b Set a cyan lambda prompt. 2017-10-13 10:21:39 -04:00
Rob Rix
e17f8e58a4 Warnings aren’t fatal in the repl. 2017-10-13 10:21:29 -04:00
Rob Rix
0d71bf7fa6 Break on errors in interactive code. 2017-10-13 10:21:08 -04:00
Rob Rix
7f6017b037 Define a reload-with-pretty macro. 2017-10-13 10:20:48 -04:00
Rob Rix
dcf5f5b40a Define pretty/no-pretty macros. 2017-10-13 10:20:36 -04:00
Rob Rix
b55f5a20d2 Add a .ghci file with a source macro. 2017-10-13 10:20:24 -04:00