From: Chris Lattner
/// identifierexpr -/// ::= identifer -/// ::= identifer '(' expression* ')' +/// ::= identifier +/// ::= identifier '(' expression* ')' static ExprAST *ParseIdentifierExpr() { std::string IdName = IdentifierStr; - getNextToken(); // eat identifer. + getNextToken(); // eat identifier. if (CurTok != '(') // Simple variable ref. return new VariableExprAST(IdName); @@ -954,12 +954,12 @@ FunctionAST *ErrorF(const char *Str) { Error(Str); return 0; } static ExprAST *ParseExpression(); /// identifierexpr -/// ::= identifer -/// ::= identifer '(' expression* ')' +/// ::= identifier +/// ::= identifier '(' expression* ')' static ExprAST *ParseIdentifierExpr() { std::string IdName = IdentifierStr; - getNextToken(); // eat identifer. + getNextToken(); // eat identifier. if (CurTok != '(') // Simple variable ref. return new VariableExprAST(IdName); diff --git a/docs/tutorial/LangImpl3.html b/docs/tutorial/LangImpl3.html index 42093270c6a..e16d1be5cc1 100644 --- a/docs/tutorial/LangImpl3.html +++ b/docs/tutorial/LangImpl3.html @@ -818,12 +818,12 @@ FunctionAST *ErrorF(const char *Str) { Error(Str); return 0; } static ExprAST *ParseExpression(); /// identifierexpr -/// ::= identifer -/// ::= identifer '(' expression* ')' +/// ::= identifier +/// ::= identifier '(' expression* ')' static ExprAST *ParseIdentifierExpr() { std::string IdName = IdentifierStr; - getNextToken(); // eat identifer. + getNextToken(); // eat identifier. if (CurTok != '(') // Simple variable ref. return new VariableExprAST(IdName); diff --git a/docs/tutorial/LangImpl4.html b/docs/tutorial/LangImpl4.html index 8c25a047c7e..6fb2c8824d8 100644 --- a/docs/tutorial/LangImpl4.html +++ b/docs/tutorial/LangImpl4.html @@ -686,12 +686,12 @@ FunctionAST *ErrorF(const char *Str) { Error(Str); return 0; } static ExprAST *ParseExpression(); /// identifierexpr -/// ::= identifer -/// ::= identifer '(' expression* ')' +/// ::= identifier +/// ::= identifier '(' expression* ')' static ExprAST *ParseIdentifierExpr() { std::string IdName = IdentifierStr; - getNextToken(); // eat identifer. + getNextToken(); // eat identifier. if (CurTok != '(') // Simple variable ref. return new VariableExprAST(IdName); diff --git a/docs/tutorial/LangImpl5.html b/docs/tutorial/LangImpl5.html index a1146ed263b..09477faba6e 100644 --- a/docs/tutorial/LangImpl5.html +++ b/docs/tutorial/LangImpl5.html @@ -574,7 +574,7 @@ the AST node:-/// forexpr ::= 'for' identifer '=' expr ',' expr (',' expr)? 'in' expression +/// forexpr ::= 'for' identifier '=' expr ',' expr (',' expr)? 'in' expression static ExprAST *ParseForExpr() { getNextToken(); // eat the for. @@ -582,7 +582,7 @@ static ExprAST *ParseForExpr() { return Error("expected identifier after for"); std::string IdName = IdentifierStr; - getNextToken(); // eat identifer. + getNextToken(); // eat identifier. if (CurTok != '=') return Error("expected '=' after for"); @@ -1085,12 +1085,12 @@ FunctionAST *ErrorF(const char *Str) { Error(Str); return 0; } static ExprAST *ParseExpression(); /// identifierexpr -/// ::= identifer -/// ::= identifer '(' expression* ')' +/// ::= identifier +/// ::= identifier '(' expression* ')' static ExprAST *ParseIdentifierExpr() { std::string IdName = IdentifierStr; - getNextToken(); // eat identifer. + getNextToken(); // eat identifier. if (CurTok != '(') // Simple variable ref. return new VariableExprAST(IdName); @@ -1163,7 +1163,7 @@ static ExprAST *ParseIfExpr() { return new IfExprAST(Cond, Then, Else); } -/// forexpr ::= 'for' identifer '=' expr ',' expr (',' expr)? 'in' expression +/// forexpr ::= 'for' identifier '=' expr ',' expr (',' expr)? 'in' expression static ExprAST *ParseForExpr() { getNextToken(); // eat the for. @@ -1171,7 +1171,7 @@ static ExprAST *ParseForExpr() { return Error("expected identifier after for"); std::string IdName = IdentifierStr; - getNextToken(); // eat identifer. + getNextToken(); // eat identifier. if (CurTok != '=') return Error("expected '=' after for"); diff --git a/docs/tutorial/LangImpl6.html b/docs/tutorial/LangImpl6.html index 90f02abb173..5a184c2c181 100644 --- a/docs/tutorial/LangImpl6.html +++ b/docs/tutorial/LangImpl6.html @@ -1048,12 +1048,12 @@ FunctionAST *ErrorF(const char *Str) { Error(Str); return 0; } static ExprAST *ParseExpression(); /// identifierexpr -/// ::= identifer -/// ::= identifer '(' expression* ')' +/// ::= identifier +/// ::= identifier '(' expression* ')' static ExprAST *ParseIdentifierExpr() { std::string IdName = IdentifierStr; - getNextToken(); // eat identifer. + getNextToken(); // eat identifier. if (CurTok != '(') // Simple variable ref. return new VariableExprAST(IdName); @@ -1126,7 +1126,7 @@ static ExprAST *ParseIfExpr() { return new IfExprAST(Cond, Then, Else); } -/// forexpr ::= 'for' identifer '=' expr ',' expr (',' expr)? 'in' expression +/// forexpr ::= 'for' identifier '=' expr ',' expr (',' expr)? 'in' expression static ExprAST *ParseForExpr() { getNextToken(); // eat the for. @@ -1134,7 +1134,7 @@ static ExprAST *ParseForExpr() { return Error("expected identifier after for"); std::string IdName = IdentifierStr; - getNextToken(); // eat identifer. + getNextToken(); // eat identifier. if (CurTok != '=') return Error("expected '=' after for"); diff --git a/docs/tutorial/LangImpl7.html b/docs/tutorial/LangImpl7.html index b002f7a4519..07dd5c620f8 100644 --- a/docs/tutorial/LangImpl7.html +++ b/docs/tutorial/LangImpl7.html @@ -809,8 +809,8 @@ static ExprAST *ParsePrimary() {-/// varexpr ::= 'var' identifer ('=' expression)? -// (',' identifer ('=' expression)?)* 'in' expression +/// varexpr ::= 'var' identifier ('=' expression)? +// (',' identifier ('=' expression)?)* 'in' expression static ExprAST *ParseVarExpr() { getNextToken(); // eat the var. @@ -829,7 +829,7 @@ local VarNames vector.while (1) { std::string Name = IdentifierStr; - getNextToken(); // eat identifer. + getNextToken(); // eat identifier. // Read the optional initializer. ExprAST *Init = 0; @@ -1244,12 +1244,12 @@ FunctionAST *ErrorF(const char *Str) { Error(Str); return 0; } static ExprAST *ParseExpression(); /// identifierexpr -/// ::= identifer -/// ::= identifer '(' expression* ')' +/// ::= identifier +/// ::= identifier '(' expression* ')' static ExprAST *ParseIdentifierExpr() { std::string IdName = IdentifierStr; - getNextToken(); // eat identifer. + getNextToken(); // eat identifier. if (CurTok != '(') // Simple variable ref. return new VariableExprAST(IdName); @@ -1322,7 +1322,7 @@ static ExprAST *ParseIfExpr() { return new IfExprAST(Cond, Then, Else); } -/// forexpr ::= 'for' identifer '=' expr ',' expr (',' expr)? 'in' expression +/// forexpr ::= 'for' identifier '=' expr ',' expr (',' expr)? 'in' expression static ExprAST *ParseForExpr() { getNextToken(); // eat the for. @@ -1330,7 +1330,7 @@ static ExprAST *ParseForExpr() { return Error("expected identifier after for"); std::string IdName = IdentifierStr; - getNextToken(); // eat identifer. + getNextToken(); // eat identifier. if (CurTok != '=') return Error("expected '=' after for"); @@ -1364,8 +1364,8 @@ static ExprAST *ParseForExpr() { return new ForExprAST(IdName, Start, End, Step, Body); } -/// varexpr ::= 'var' identifer ('=' expression)? -// (',' identifer ('=' expression)?)* 'in' expression +/// varexpr ::= 'var' identifier ('=' expression)? +// (',' identifier ('=' expression)?)* 'in' expression static ExprAST *ParseVarExpr() { getNextToken(); // eat the var. @@ -1377,7 +1377,7 @@ static ExprAST *ParseVarExpr() { while (1) { std::string Name = IdentifierStr; - getNextToken(); // eat identifer. + getNextToken(); // eat identifier. // Read the optional initializer. ExprAST *Init = 0;