diff options
author | Kevin Enderby <enderby@apple.com> | 2009-07-20 20:25:37 +0000 |
---|---|---|
committer | Kevin Enderby <enderby@apple.com> | 2009-07-20 20:25:37 +0000 |
commit | 5026ae4514caf5bb88d6c09fbf56a9db2753ed43 (patch) | |
tree | a610cc7a46320195b936b5584f68a38ede2c2190 /tools/llvm-mc/AsmParser.cpp | |
parent | dbd692a66e6a5f60ec3ff120ed27ae3a918c375f (diff) | |
download | llvm-5026ae4514caf5bb88d6c09fbf56a9db2753ed43.tar.gz llvm-5026ae4514caf5bb88d6c09fbf56a9db2753ed43.tar.bz2 llvm-5026ae4514caf5bb88d6c09fbf56a9db2753ed43.tar.xz |
Removed the DumpSymbolsandMacros and LoadSymbolsandMacros MCStreamer API as
the parsing of the .dump and .load should be done in the assembly parser and
not have any need for an MCStreamer API. Changed the code for now so these
just produce an error saying these specific directives are not yet implemented
since they are likely no longer used and may never need to be implemented.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@76462 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/llvm-mc/AsmParser.cpp')
-rw-r--r-- | tools/llvm-mc/AsmParser.cpp | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/tools/llvm-mc/AsmParser.cpp b/tools/llvm-mc/AsmParser.cpp index 066879ff48..1b9ca052a3 100644 --- a/tools/llvm-mc/AsmParser.cpp +++ b/tools/llvm-mc/AsmParser.cpp @@ -539,9 +539,9 @@ bool AsmParser::ParseStatement() { if (!strcmp(IDVal, ".include")) return ParseDirectiveInclude(); if (!strcmp(IDVal, ".dump")) - return ParseDirectiveDarwinDumpOrLoad(/*IsDump=*/true); + return ParseDirectiveDarwinDumpOrLoad(IDLoc, /*IsDump=*/true); if (!strcmp(IDVal, ".load")) - return ParseDirectiveDarwinDumpOrLoad(/*IsLoad=*/false); + return ParseDirectiveDarwinDumpOrLoad(IDLoc, /*IsLoad=*/false); Warning(IDLoc, "ignoring directive for now"); EatToEndOfStatement(); @@ -1197,11 +1197,11 @@ bool AsmParser::ParseDirectiveInclude() { /// ParseDirectiveDarwinDumpOrLoad /// ::= ( .dump | .load ) "filename" -bool AsmParser::ParseDirectiveDarwinDumpOrLoad(bool IsDump) { +bool AsmParser::ParseDirectiveDarwinDumpOrLoad(SMLoc IDLoc, bool IsDump) { if (Lexer.isNot(asmtok::String)) return TokError("expected string in '.dump' or '.load' directive"); - const char *Str = Lexer.getCurStrVal(); + Lexer.getCurStrVal(); Lexer.Lex(); @@ -1210,10 +1210,12 @@ bool AsmParser::ParseDirectiveDarwinDumpOrLoad(bool IsDump) { Lexer.Lex(); + // FIXME: If/when .dump and .load are implemented they will be done in the + // the assembly parser and not have any need for an MCStreamer API. if (IsDump) - Out.DumpSymbolsandMacros(Str); + Warning(IDLoc, "ignoring directive .dump for now"); else - Out.LoadSymbolsandMacros(Str); + Warning(IDLoc, "ignoring directive .load for now"); return false; } |