module = new ModuleContainer (ctx);
module.Evaluator = this;
- source_file = new CompilationSourceFile (module);
+ source_file = new CompilationSourceFile (module, null);
module.AddTypeContainer (source_file);
startup_files = ctx.SourceFiles.Count;
Location.Initialize (ctx.SourceFiles);
+ var parser_session = new ParserSession ();
for (int i = 0; i < startup_files; ++i) {
var sf = ctx.SourceFiles [i];
- d.Parse (sf, module);
+ d.Parse (sf, module, parser_session, ctx.Report);
}
}
//
InputKind ToplevelOrStatement (SeekableStreamReader seekable)
{
- Tokenizer tokenizer = new Tokenizer (seekable, source_file);
+ Tokenizer tokenizer = new Tokenizer (seekable, source_file, new ParserSession ());
int t = tokenizer.token ();
switch (t){
seekable.Position = 0;
source_file.DeclarationFound = false;
- CSharpParser parser = new CSharpParser (seekable, source_file);
+ CSharpParser parser = new CSharpParser (seekable, source_file, new ParserSession ());
if (kind == InputKind.StatementOrExpression){
parser.Lexer.putback_char = Tokenizer.EvalStatementParserCharacter;
static public string help {
get {
return "Static methods:\n" +
+#if !NET_2_1
" Describe (object); - Describes the object's type\n" +
+#endif
" LoadPackage (package); - Loads the given Package (like -pkg:FILE)\n" +
" LoadAssembly (assembly); - Loads the given assembly (like -r:ASSEMBLY)\n" +
" ShowVars (); - Shows defined local variables.\n" +
{
}
- public override void EmitSymbolInfo ()
- {
- }
-
protected override FieldExpr GetFieldExpression (EmitContext ec)
{
return new FieldExpr (field, field.Location);