mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-09-25 12:50:12 +01:00
Rename main to Main for Carbon style consistency (#939)
Main() is more consistency with Carbon's naming guidelines. C# offers some precedent: https://docs.microsoft.com/en-us/dotnet/csharp/fundamentals/program-structure/main-command-line
This commit is contained in:
@@ -62,9 +62,9 @@ void ExecProgram(Nonnull<Arena*> arena, AST ast, bool trace) {
|
||||
llvm::outs() << "********** starting execution **********\n";
|
||||
}
|
||||
|
||||
SourceLocation source_loc("<main()>", 0);
|
||||
SourceLocation source_loc("<Main()>", 0);
|
||||
Nonnull<Expression*> call_main = arena->New<CallExpression>(
|
||||
source_loc, arena->New<IdentifierExpression>(source_loc, "main"),
|
||||
source_loc, arena->New<IdentifierExpression>(source_loc, "Main"),
|
||||
arena->New<TupleLiteral>(source_loc));
|
||||
int result =
|
||||
Interpreter(arena, trace).InterpProgram(ast.declarations, call_main);
|
||||
|
||||
Reference in New Issue
Block a user