Slightly expand the :help text.

Swift SVN r1624
This commit is contained in:
Eli Friedman
2012-04-25 07:11:42 +00:00
parent b4ec884307
commit d228618b8d

View File

@@ -322,7 +322,13 @@ void swift::REPL(ASTContext &Context) {
L.lex(Tok);
if (CurChunkLines == 1 && !BraceCount && Tok.is(tok::colon)) {
if (L.peekNextToken().getText() == "help") {
printf("%s", "I'm not helpful yet, but use :quit to exit\n");
printf("%s", "Available commands:\n"
" :quit - quit the interpreter (you can also use :exit"
" or Control+D or exit(0))\n"
" :dump_ir - dump the LLVM IR generated by the REPL\n"
" :dump_ast - dump the AST representation of"
" the REPL input\n"
"API documentation etc. will be here eventually.\n");
} else if (L.peekNextToken().getText() == "quit" ||
L.peekNextToken().getText() == "exit") {
return;