diff --git a/build.sh b/build.sh index aa5229c..bf1ef9c 100755 --- a/build.sh +++ b/build.sh @@ -28,3 +28,32 @@ dmd \ -O -release -noboundscheck -inline\ -ofdcd-server +#gdc client.d\ +# messages.d\ +# msgpack-d/src/msgpack.d\ +# -Imsgpack-d/src\ +# -O3 -frelease -fno-bounds-check\ +# -odcd-client +# +#gdc \ +# actypes.d\ +# astconverter.d\ +# autocomplete.d\ +# constants.d\ +# messages.d\ +# modulecache.d\ +# semantic.d\ +# server.d\ +# stupidlog.d\ +# dscanner/stdx/d/ast.d\ +# dscanner/stdx/d/parser.d\ +# dscanner/stdx/lexer.d\ +# dscanner/stdx/d/lexer.d\ +# dscanner/stdx/d/entities.d\ +# dscanner/formatter.d\ +# msgpack-d/src/msgpack.d\ +# -Imsgpack-d/src\ +# -Idscanner\ +# -O3 -frelease -fno-bounds-check\ +# -odcd-server + diff --git a/dscanner b/dscanner index d840eed..2c90f30 160000 --- a/dscanner +++ b/dscanner @@ -1 +1 @@ -Subproject commit d840eed12af4984a71933a1d2f09de6065e13a26 +Subproject commit 2c90f300fd51355fd583868c7efde3dece988af9 diff --git a/modulecache.d b/modulecache.d index c061e96..fded2da 100644 --- a/modulecache.d +++ b/modulecache.d @@ -61,18 +61,6 @@ struct ModuleCache cache = cache.init; } - static void estimateMemory() - { - size_t estimate = 0; - foreach (c; cache) - { - foreach (symbol; c.symbols) - estimate = symbol.estimateMemory(estimate); - } - double megabytes = estimate / (1024.0F * 1024.0F); - Log.trace("Memory use estimated at ", megabytes, " megabytes"); - } - /** * Adds the given path to the list of directories checked for imports */ diff --git a/server.d b/server.d index 65653ae..85d0833 100644 --- a/server.d +++ b/server.d @@ -27,6 +27,7 @@ import std.file; import std.array; import std.process; import std.datetime; +import std.conv; import msgpack; @@ -46,7 +47,6 @@ version(OSX) version = useXDG; int main(string[] args) { - Log.info("Starting up..."); StopWatch sw = StopWatch(AutoStart.yes); @@ -61,7 +61,7 @@ int main(string[] args) { getopt(args, "port|p", &port, "I", &importPaths, "help|h", &help); } - catch (Exception e) + catch (ConvException e) { stderr.writeln(e.msg); printHelp(args[0]); @@ -96,7 +96,7 @@ int main(string[] args) sw.stop(); Log.info("Startup completed in ", sw.peek().to!("msecs", float), " milliseconds"); - ModuleCache.estimateMemory(); +// ModuleCache.estimateMemory(); // No relative paths