From e20bee14dda37241ac0115c20d33a6e66296d35d Mon Sep 17 00:00:00 2001 From: Matt Ward Date: Sat, 21 Apr 2012 14:20:55 +0100 Subject: [PATCH 01/36] When creating a service reference use and update the app.config file that is open in the text editor. --- .../Project/ICSharpCode.SharpDevelop.csproj | 2 + .../ServiceReference/ActiveTextEditors.cs | 45 +++++ .../ServiceReference/IActiveTextEditors.cs | 14 ++ .../ServiceReference/IFileSystem.cs | 4 + .../IServiceReferenceProxyGenerator.cs | 2 + .../ServiceReferenceFileGenerator.cs | 5 + .../ServiceReferenceFileSystem.cs | 23 +++ .../ServiceReferenceGenerator.cs | 54 +++++- .../ServiceReferenceProxyGenerator.cs | 10 + .../ServiceReference/SvcUtilRunner.cs | 15 +- .../ServiceReferenceGeneratorTests.cs | 175 +++++++++++++++++- 11 files changed, 343 insertions(+), 6 deletions(-) create mode 100644 src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ActiveTextEditors.cs create mode 100644 src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/IActiveTextEditors.cs diff --git a/src/Main/Base/Project/ICSharpCode.SharpDevelop.csproj b/src/Main/Base/Project/ICSharpCode.SharpDevelop.csproj index 7c06c5241f..036b53695b 100644 --- a/src/Main/Base/Project/ICSharpCode.SharpDevelop.csproj +++ b/src/Main/Base/Project/ICSharpCode.SharpDevelop.csproj @@ -261,6 +261,7 @@ + AddServiceReferenceDialog.xaml Code @@ -272,6 +273,7 @@ + diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ActiveTextEditors.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ActiveTextEditors.cs new file mode 100644 index 0000000000..d11256eb8b --- /dev/null +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ActiveTextEditors.cs @@ -0,0 +1,45 @@ +// Copyright (c) AlphaSierraPapa for the SharpDevelop Team (for details please see \doc\copyright.txt) +// This code is distributed under the GNU LGPL (for details please see \doc\license.txt) + +using System; +using ICSharpCode.SharpDevelop.Editor; + +namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference +{ + public class ActiveTextEditors : IActiveTextEditors + { + public string GetTextForOpenFile(string fileName) + { + ITextEditor textEditor = GetTextEditor(fileName); + if (textEditor != null) { + return textEditor.Document.Text; + } + return null; + } + + ITextEditor GetTextEditor(string fileName) + { + IViewContent viewContent = FileService.GetOpenFile(fileName); + var textEditorProvider = viewContent as ITextEditorProvider; + if (textEditorProvider != null) { + return textEditorProvider.TextEditor; + } + return null; + } + + public void UpdateTextForOpenFile(string fileName, string text) + { + ITextEditor textEditor = GetTextEditor(fileName); + if (textEditor != null) { + using (IDisposable undoGroup = textEditor.Document.OpenUndoGroup()) { + textEditor.Document.Text = text; + } + } + } + + public bool IsFileOpen(string fileName) + { + return FileService.IsOpen(fileName); + } + } +} diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/IActiveTextEditors.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/IActiveTextEditors.cs new file mode 100644 index 0000000000..606856c24d --- /dev/null +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/IActiveTextEditors.cs @@ -0,0 +1,14 @@ +// Copyright (c) AlphaSierraPapa for the SharpDevelop Team (for details please see \doc\copyright.txt) +// This code is distributed under the GNU LGPL (for details please see \doc\license.txt) + +using System; + +namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference +{ + public interface IActiveTextEditors + { + string GetTextForOpenFile(string fileName); + void UpdateTextForOpenFile(string fileName, string text); + bool IsFileOpen(string fileName); + } +} diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/IFileSystem.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/IFileSystem.cs index 1614e97327..03dbaa0f5e 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/IFileSystem.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/IFileSystem.cs @@ -8,5 +8,9 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference public interface IFileSystem { void CreateDirectoryIfMissing(string path); + string CreateTempFile(string text); + string ReadAllFileText(string fileName); + void DeleteFile(string fileName); + void WriteAllText(string fileName, string text); } } diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/IServiceReferenceProxyGenerator.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/IServiceReferenceProxyGenerator.cs index e5eab2f37b..3dbe51caf7 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/IServiceReferenceProxyGenerator.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/IServiceReferenceProxyGenerator.cs @@ -10,5 +10,7 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference { ServiceReferenceGeneratorOptions Options { get; set; } void GenerateProxyFile(); + + event EventHandler Complete; } } diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceFileGenerator.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceFileGenerator.cs index ba54756fca..a970b0eaf2 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceFileGenerator.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceFileGenerator.cs @@ -40,5 +40,10 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference { mapGenerator.GenerateServiceReferenceMapFile(mapFile); } + + public event EventHandler Complete { + add { proxyGenerator.Complete += value; } + remove { proxyGenerator.Complete += value; } + } } } diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceFileSystem.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceFileSystem.cs index 1455e129c1..523931707d 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceFileSystem.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceFileSystem.cs @@ -14,5 +14,28 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference Directory.CreateDirectory(path); } } + + public string CreateTempFile(string text) + { + string folder = Path.GetTempPath(); + string fileName = Path.Combine(folder, "app.config"); + File.WriteAllText(fileName, text); + return fileName; + } + + public string ReadAllFileText(string fileName) + { + return File.ReadAllText(fileName); + } + + public void DeleteFile(string fileName) + { + File.Delete(fileName); + } + + public void WriteAllText(string fileName, string text) + { + File.WriteAllText(fileName, text); + } } } diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceGenerator.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceGenerator.cs index 2ac5a1942e..5d1d706b71 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceGenerator.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceGenerator.cs @@ -16,6 +16,8 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference IProjectWithServiceReferences project; IServiceReferenceFileGenerator fileGenerator; IFileSystem fileSystem; + IActiveTextEditors activeTextEditors; + string tempAppConfigFileName; public ServiceReferenceGenerator(IProject project) : this(new ProjectWithServiceReferences(project)) @@ -26,18 +28,21 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference : this( project, new ServiceReferenceFileGenerator(), - new ServiceReferenceFileSystem()) + new ServiceReferenceFileSystem(), + new ActiveTextEditors()) { } public ServiceReferenceGenerator( IProjectWithServiceReferences project, IServiceReferenceFileGenerator fileGenerator, - IFileSystem fileSystem) + IFileSystem fileSystem, + IActiveTextEditors activeTextEditors) { this.project = project; this.fileGenerator = fileGenerator; this.fileSystem = fileSystem; + this.activeTextEditors = activeTextEditors; } public ServiceReferenceGeneratorOptions Options { @@ -68,18 +73,38 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference ServiceReferenceFileName referenceFileName = project.GetServiceReferenceFileName(fileGenerator.Options.ServiceName); CreateFolderForFileIfFolderMissing(referenceFileName.Path); + CreateTempAppConfigFileIfOpenInTextEditor(); + Options.OutputFileName = referenceFileName.Path; - Options.AppConfigFileName = project.GetAppConfigFileName(); + Options.AppConfigFileName = GetAppConfigFileName(); Options.NoAppConfig = false; Options.MergeAppConfig = project.HasAppConfigFile(); Options.MapProjectLanguage(project.Language); Options.GenerateNamespace(project.RootNamespace); Options.AddProjectReferencesIfUsingTypesFromProjectReferences(project.GetReferences()); + + fileGenerator.Complete += ProxyFileGenerationComplete; fileGenerator.GenerateProxyFile(); return referenceFileName; } + string GetAppConfigFileName() + { + if (tempAppConfigFileName != null) { + return tempAppConfigFileName; + } + return project.GetAppConfigFileName(); + } + + void CreateTempAppConfigFileIfOpenInTextEditor() + { + string appConfigText = activeTextEditors.GetTextForOpenFile(project.GetAppConfigFileName()); + if (appConfigText != null) { + tempAppConfigFileName = fileSystem.CreateTempFile(appConfigText); + } + } + ServiceReferenceMapFileName CreateServiceReferenceMapFile() { ServiceReferenceMapFileName mapFileName = project.GetServiceReferenceMapFileName(fileGenerator.Options.ServiceName); @@ -94,6 +119,29 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference fileSystem.CreateDirectoryIfMissing(folder); } + void ProxyFileGenerationComplete(object sender, EventArgs e) + { + if (tempAppConfigFileName != null) { + UpdateAppConfigInTextEditor(); + DeleteTempAppConfigFile(); + } + } + + void DeleteTempAppConfigFile() + { + fileSystem.DeleteFile(tempAppConfigFileName); + } + + void UpdateAppConfigInTextEditor() + { + string text = fileSystem.ReadAllFileText(tempAppConfigFileName); + if (activeTextEditors.IsFileOpen(project.GetAppConfigFileName())) { + activeTextEditors.UpdateTextForOpenFile(project.GetAppConfigFileName(), text); + } else { + fileSystem.WriteAllText(project.GetAppConfigFileName(), text); + } + } + public IEnumerable GetCheckableAssemblyReferences() { return GetUnsortedCheckableAssemblyReferences() diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceProxyGenerator.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceProxyGenerator.cs index c56892b146..ccaae41cac 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceProxyGenerator.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceProxyGenerator.cs @@ -20,7 +20,17 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference public void GenerateProxyFile() { var runner = new SvcUtilRunner(options); + runner.ProcessExited += OnComplete; runner.Run(); } + + public event EventHandler Complete; + + void OnComplete(object sender, EventArgs e) + { + if (Complete != null) { + Complete(this, e); + } + } } } diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/SvcUtilRunner.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/SvcUtilRunner.cs index 072af8617e..c33cbf0632 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/SvcUtilRunner.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/SvcUtilRunner.cs @@ -13,6 +13,8 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference this.Options = options; } + public event EventHandler ProcessExited; + public ServiceReferenceGeneratorOptions Options { get; private set; } public void Run() @@ -48,7 +50,7 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference runner.LogStandardOutputAndError = false; runner.OutputLineReceived += LineReceived; runner.ErrorLineReceived += LineReceived; - runner.ProcessExited += ProcessExited; + runner.ProcessExited += SvcUtilProcessExited; return runner; } @@ -57,9 +59,18 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference SvcUtilMessageView.AppendLine(e.Line); } - void ProcessExited(object sender, EventArgs e) + void SvcUtilProcessExited(object sender, EventArgs e) { SvcUtilMessageView.AppendLine("SvcUtil finished."); + + WorkbenchSingleton.SafeThreadAsyncCall(() => OnProcessExited()); + } + + void OnProcessExited() + { + if (ProcessExited != null) { + ProcessExited(this, new EventArgs()); + } } } } diff --git a/src/Main/Base/Test/ServiceReferences/ServiceReferenceGeneratorTests.cs b/src/Main/Base/Test/ServiceReferences/ServiceReferenceGeneratorTests.cs index e3fc6565c0..52840a4106 100644 --- a/src/Main/Base/Test/ServiceReferences/ServiceReferenceGeneratorTests.cs +++ b/src/Main/Base/Test/ServiceReferences/ServiceReferenceGeneratorTests.cs @@ -23,6 +23,7 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences IFileSystem fakeFileSystem; ServiceReferenceGeneratorOptions options; List projectReferences; + IActiveTextEditors fakeActiveTextEditors; void CreateGenerator() { @@ -35,8 +36,9 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences fakeReferenceMapGenerator = MockRepository.GenerateStub(); fileGenerator = new ServiceReferenceFileGenerator(fakeProxyGenerator, fakeReferenceMapGenerator); fakeFileSystem = MockRepository.GenerateStub(); + fakeActiveTextEditors = MockRepository.GenerateStub(); - generator = new ServiceReferenceGenerator(fakeProject, fileGenerator, fakeFileSystem); + generator = new ServiceReferenceGenerator(fakeProject, fileGenerator, fakeFileSystem, fakeActiveTextEditors); } void SetProjectRootNamespace(string rootNamespace) @@ -133,6 +135,45 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences return projectItem; } + void AppConfigIsOpenInTextEditor(string fileName, string appConfigText) + { + fakeActiveTextEditors + .Stub(editors => editors.GetTextForOpenFile(fileName)) + .Return(appConfigText); + + fakeActiveTextEditors + .Stub(editors => editors.IsFileOpen(fileName)) + .Return(true); + } + + void AppConfigIsClosedInTextEditor(string fileName) + { + fakeActiveTextEditors.BackToRecord(BackToRecordOptions.All); + fakeActiveTextEditors.Replay(); + fakeActiveTextEditors + .Stub(editors => editors.IsFileOpen(fileName)) + .Return(false); + } + + void SetTempFileNameCreated(string tempFileName) + { + fakeFileSystem.Stub(fs => fs.CreateTempFile(Arg.Is.Anything)) + .Return(tempFileName); + } + + void SvcUtilRunCompleted() + { + fakeProxyGenerator.Raise(g => g.Complete += null, fakeProxyGenerator, new EventArgs()); + } + + void SetTempFileText(string fileName, string text) + { + SetTempFileNameCreated(fileName); + fakeFileSystem + .Stub(fs => fs.ReadAllFileText(fileName)) + .Return(text); + } + [Test] public void AddServiceReference_GeneratesServiceReference_ProxyFileIsGenerated() { @@ -450,5 +491,137 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences CollectionAssert.AreEqual(expectedAssemblies, generator.Options.Assemblies); } + + [Test] + public void AddServiceReference_AppConfigIsOpenInTextEditor_TempFileCreatedWithAppConfigText() + { + CreateGenerator(); + AddProxyFileNameForServiceName("MyService"); + AddMapFileNameForServiceName("MyService"); + generator.Options.ServiceName = "MyService"; + string appConfigFileName = @"d:\projects\MyProject\app.config"; + SetProjectAppConfigFileName(appConfigFileName); + ProjectHasAppConfigFile(); + AppConfigIsOpenInTextEditor(appConfigFileName, "appconfig text"); + + generator.AddServiceReference(); + + fakeFileSystem.AssertWasCalled(fs => fs.CreateTempFile("appconfig text")); + } + + [Test] + public void AddServiceReference_AppConfigIsNotOpenInTextEditor_TempFileNotCreated() + { + CreateGenerator(); + AddProxyFileNameForServiceName("MyService"); + AddMapFileNameForServiceName("MyService"); + generator.Options.ServiceName = "MyService"; + string appConfigFileName = @"d:\projects\MyProject\app.config"; + SetProjectAppConfigFileName(appConfigFileName); + ProjectHasAppConfigFile(); + + generator.AddServiceReference(); + + fakeFileSystem.AssertWasNotCalled(fs => fs.CreateTempFile(Arg.Is.Anything)); + } + + [Test] + public void AddServiceReference_AppConfigIsOpenInTextEditor_TempFileAppConfigPassedUsedWhenGeneratingProxy() + { + CreateGenerator(); + AddProxyFileNameForServiceName("MyService"); + AddMapFileNameForServiceName("MyService"); + generator.Options.ServiceName = "MyService"; + string appConfigFileName = @"d:\projects\MyProject\app.config"; + SetProjectAppConfigFileName(appConfigFileName); + ProjectHasAppConfigFile(); + AppConfigIsOpenInTextEditor(appConfigFileName, "appconfig text"); + SetTempFileNameCreated(@"d:\temp\test.tmp"); + + generator.AddServiceReference(); + + Assert.AreEqual(@"d:\temp\test.tmp", fakeProxyGenerator.Options.AppConfigFileName); + } + + [Test] + public void AddServiceReference_AppConfigIsOpenInTextEditorAndSvcUtilHasFinished_TempFileAppConfigContentReplacesTextInTextEditor() + { + CreateGenerator(); + AddProxyFileNameForServiceName("MyService"); + AddMapFileNameForServiceName("MyService"); + generator.Options.ServiceName = "MyService"; + string appConfigFileName = @"d:\projects\MyProject\app.config"; + SetProjectAppConfigFileName(appConfigFileName); + ProjectHasAppConfigFile(); + AppConfigIsOpenInTextEditor(appConfigFileName, "appconfig text"); + SetTempFileText(@"d:\temp\test.tmp", "New appconfig text"); + + generator.AddServiceReference(); + + SvcUtilRunCompleted(); + + fakeActiveTextEditors.AssertWasCalled(editors => editors.UpdateTextForOpenFile(appConfigFileName, "New appconfig text")); + } + + [Test] + public void AddServiceReference_AppConfigIsNotOpenInTextEditor_TextInTextEditorNotUpdated() + { + CreateGenerator(); + AddProxyFileNameForServiceName("MyService"); + AddMapFileNameForServiceName("MyService"); + generator.Options.ServiceName = "MyService"; + string appConfigFileName = @"d:\projects\MyProject\app.config"; + SetProjectAppConfigFileName(appConfigFileName); + ProjectHasAppConfigFile(); + + generator.AddServiceReference(); + + SvcUtilRunCompleted(); + + fakeActiveTextEditors.AssertWasNotCalled(editors => editors.UpdateTextForOpenFile(Arg.Is.Anything, Arg.Is.Anything)); + } + + [Test] + public void AddServiceReference_AppConfigIsOpenInTextEditorAndSvcUtilHasFinished_TempFileIsDeleted() + { + CreateGenerator(); + AddProxyFileNameForServiceName("MyService"); + AddMapFileNameForServiceName("MyService"); + generator.Options.ServiceName = "MyService"; + string appConfigFileName = @"d:\projects\MyProject\app.config"; + SetProjectAppConfigFileName(appConfigFileName); + ProjectHasAppConfigFile(); + AppConfigIsOpenInTextEditor(appConfigFileName, "appconfig text"); + SetTempFileNameCreated(@"d:\temp\test.tmp"); + + generator.AddServiceReference(); + + SvcUtilRunCompleted(); + + fakeFileSystem.AssertWasCalled(fs => fs.DeleteFile(@"d:\temp\test.tmp")); + } + + [Test] + public void AddServiceReference_AppConfigIsOriginallyOpenInTextEditorButIsClosedWhenSvcUtilHasFinished_TempFileAppConfigContentReplacesAppConfigOnFileSystem() + { + CreateGenerator(); + AddProxyFileNameForServiceName("MyService"); + AddMapFileNameForServiceName("MyService"); + generator.Options.ServiceName = "MyService"; + string appConfigFileName = @"d:\projects\MyProject\app.config"; + SetProjectAppConfigFileName(appConfigFileName); + ProjectHasAppConfigFile(); + AppConfigIsOpenInTextEditor(appConfigFileName, "appconfig text"); + SetTempFileText(@"d:\temp\test.tmp", "New appconfig text"); + + generator.AddServiceReference(); + + AppConfigIsClosedInTextEditor(appConfigFileName); + + SvcUtilRunCompleted(); + + fakeFileSystem.AssertWasCalled(fs => fs.WriteAllText(appConfigFileName, "New appconfig text")); + fakeActiveTextEditors.AssertWasNotCalled(editors => editors.UpdateTextForOpenFile(Arg.Is.Anything, Arg.Is.Anything)); + } } } From b653ce30d627dc981feffef1514b81202a02c16e Mon Sep 17 00:00:00 2001 From: Matt Ward Date: Sat, 21 Apr 2012 15:49:38 +0100 Subject: [PATCH 02/36] When generating a service reference only update the project after svcutil has finishing executing and successfully generates the reference. --- .../Project/ICSharpCode.SharpDevelop.csproj | 1 + .../AddServiceReferenceViewModel.cs | 9 +- .../GeneratorCompleteEventArgs.cs | 21 ++++ .../IServiceReferenceProxyGenerator.cs | 2 +- .../ServiceReferenceFileGenerator.cs | 2 +- .../ServiceReferenceGenerator.cs | 49 +++++--- .../ServiceReferenceProxyGenerator.cs | 5 +- .../ServiceReference/SvcUtilRunner.cs | 7 +- .../ServiceReferenceGeneratorTests.cs | 115 +++++++++++++++++- 9 files changed, 184 insertions(+), 27 deletions(-) create mode 100644 src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/GeneratorCompleteEventArgs.cs diff --git a/src/Main/Base/Project/ICSharpCode.SharpDevelop.csproj b/src/Main/Base/Project/ICSharpCode.SharpDevelop.csproj index 036b53695b..f6c7ed0237 100644 --- a/src/Main/Base/Project/ICSharpCode.SharpDevelop.csproj +++ b/src/Main/Base/Project/ICSharpCode.SharpDevelop.csproj @@ -273,6 +273,7 @@ + diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/AddServiceReferenceViewModel.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/AddServiceReferenceViewModel.cs index e49ec09e1a..365a58dca0 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/AddServiceReferenceViewModel.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/AddServiceReferenceViewModel.cs @@ -48,6 +48,7 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference { this.project = project; this.serviceGenerator = new ServiceReferenceGenerator(project); + this.serviceGenerator.Complete += ServiceReferenceGenerated; this.assemblyReferences = serviceGenerator.GetCheckableAssemblyReferences().ToList(); HeadLine = header; @@ -112,6 +113,13 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference discoveryUri = uri; serviceReferenceDiscoveryClient.Discover(uri); } + + void ServiceReferenceGenerated(object sender, GeneratorCompleteEventArgs e) + { + if (e.IsSuccess) { + new RefreshProjectBrowser().Run(); + } + } void ServiceReferenceDiscoveryComplete(object sender, ServiceReferenceDiscoveryEventArgs e) { @@ -295,7 +303,6 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference serviceGenerator.Options.ServiceName = defaultNameSpace; serviceGenerator.Options.Url = uri.ToString(); serviceGenerator.AddServiceReference(); - new RefreshProjectBrowser().Run(); } catch (Exception ex) { ICSharpCode.Core.LoggingService.Error("Failed to add service reference.", ex); } diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/GeneratorCompleteEventArgs.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/GeneratorCompleteEventArgs.cs new file mode 100644 index 0000000000..3599b1aece --- /dev/null +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/GeneratorCompleteEventArgs.cs @@ -0,0 +1,21 @@ +// Copyright (c) AlphaSierraPapa for the SharpDevelop Team (for details please see \doc\copyright.txt) +// This code is distributed under the GNU LGPL (for details please see \doc\license.txt) + +using System; + +namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference +{ + public class GeneratorCompleteEventArgs : EventArgs + { + public GeneratorCompleteEventArgs(int exitCode) + { + this.ExitCode = exitCode; + } + + public bool IsSuccess { + get { return ExitCode == 0; } + } + + public int ExitCode { get; set; } + } +} diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/IServiceReferenceProxyGenerator.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/IServiceReferenceProxyGenerator.cs index 3dbe51caf7..2f9e4d93bb 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/IServiceReferenceProxyGenerator.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/IServiceReferenceProxyGenerator.cs @@ -11,6 +11,6 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference ServiceReferenceGeneratorOptions Options { get; set; } void GenerateProxyFile(); - event EventHandler Complete; + event EventHandler Complete; } } diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceFileGenerator.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceFileGenerator.cs index a970b0eaf2..2ab625aaa1 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceFileGenerator.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceFileGenerator.cs @@ -41,7 +41,7 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference mapGenerator.GenerateServiceReferenceMapFile(mapFile); } - public event EventHandler Complete { + public event EventHandler Complete { add { proxyGenerator.Complete += value; } remove { proxyGenerator.Complete += value; } } diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceGenerator.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceGenerator.cs index 5d1d706b71..b57d7675d5 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceGenerator.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceGenerator.cs @@ -18,6 +18,7 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference IFileSystem fileSystem; IActiveTextEditors activeTextEditors; string tempAppConfigFileName; + ServiceReferenceFileName referenceFileName; public ServiceReferenceGenerator(IProject project) : this(new ProjectWithServiceReferences(project)) @@ -50,25 +51,21 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference set { fileGenerator.Options = value; } } - public void AddServiceReference() + public event EventHandler Complete; + + void OnComplete(GeneratorCompleteEventArgs e) { - GenerateServiceReferenceProxy(); - project.AddAssemblyReference("System.ServiceModel"); - project.Save(); + if (Complete != null) { + Complete(this, e); + } } - void GenerateServiceReferenceProxy() + public void AddServiceReference() { - ServiceReferenceFileName referenceFileName = GenerateProxyFile(); - ServiceReferenceMapFileName mapFileName = CreateServiceReferenceMapFile(); - project.AddServiceReferenceProxyFile(referenceFileName); - project.AddServiceReferenceMapFile(mapFileName); - if (!project.HasAppConfigFile()) { - project.AddAppConfigFile(); - } + referenceFileName = StartProxyFileGeneration(); } - ServiceReferenceFileName GenerateProxyFile() + ServiceReferenceFileName StartProxyFileGeneration() { ServiceReferenceFileName referenceFileName = project.GetServiceReferenceFileName(fileGenerator.Options.ServiceName); CreateFolderForFileIfFolderMissing(referenceFileName.Path); @@ -119,12 +116,34 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference fileSystem.CreateDirectoryIfMissing(folder); } - void ProxyFileGenerationComplete(object sender, EventArgs e) + void ProxyFileGenerationComplete(object sender, GeneratorCompleteEventArgs e) { + if (e.IsSuccess) { + UpdateProjectWithGeneratedServiceReference(); + } + if (tempAppConfigFileName != null) { - UpdateAppConfigInTextEditor(); + if (e.IsSuccess) { + UpdateAppConfigInTextEditor(); + } DeleteTempAppConfigFile(); } + OnComplete(e); + } + + void UpdateProjectWithGeneratedServiceReference() + { + ServiceReferenceMapFileName mapFileName = CreateServiceReferenceMapFile(); + project.AddServiceReferenceProxyFile(referenceFileName); + project.AddServiceReferenceMapFile(mapFileName); + + project.AddAssemblyReference("System.ServiceModel"); + + if (!project.HasAppConfigFile()) { + project.AddAppConfigFile(); + } + + project.Save(); } void DeleteTempAppConfigFile() diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceProxyGenerator.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceProxyGenerator.cs index ccaae41cac..56bf98f6a8 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceProxyGenerator.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceProxyGenerator.cs @@ -24,12 +24,13 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference runner.Run(); } - public event EventHandler Complete; + public event EventHandler Complete; void OnComplete(object sender, EventArgs e) { if (Complete != null) { - Complete(this, e); + var runner = (SvcUtilRunner)sender; + Complete(this, new GeneratorCompleteEventArgs(runner.ExitCode)); } } } diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/SvcUtilRunner.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/SvcUtilRunner.cs index c33cbf0632..db6cd00acc 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/SvcUtilRunner.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/SvcUtilRunner.cs @@ -7,7 +7,7 @@ using ICSharpCode.SharpDevelop.Util; namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference { public class SvcUtilRunner - { + { public SvcUtilRunner(ServiceReferenceGeneratorOptions options) { this.Options = options; @@ -17,6 +17,8 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference public ServiceReferenceGeneratorOptions Options { get; private set; } + public int ExitCode { get; private set; } + public void Run() { SvcUtilMessageView.ClearText(); @@ -63,6 +65,9 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference { SvcUtilMessageView.AppendLine("SvcUtil finished."); + var runner = (ProcessRunner)sender; + ExitCode = runner.ExitCode; + WorkbenchSingleton.SafeThreadAsyncCall(() => OnProcessExited()); } diff --git a/src/Main/Base/Test/ServiceReferences/ServiceReferenceGeneratorTests.cs b/src/Main/Base/Test/ServiceReferences/ServiceReferenceGeneratorTests.cs index 52840a4106..3053005db9 100644 --- a/src/Main/Base/Test/ServiceReferences/ServiceReferenceGeneratorTests.cs +++ b/src/Main/Base/Test/ServiceReferences/ServiceReferenceGeneratorTests.cs @@ -161,9 +161,20 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences .Return(tempFileName); } - void SvcUtilRunCompleted() + void SvcUtilRunCompletedSuccessfully() { - fakeProxyGenerator.Raise(g => g.Complete += null, fakeProxyGenerator, new EventArgs()); + SvcUtilRunCompleted(exitCode: 0); + } + + void SvcUtilRunCompletedWithErrors() + { + SvcUtilRunCompleted(exitCode: 1); + } + + void SvcUtilRunCompleted(int exitCode) + { + var eventArgs = new GeneratorCompleteEventArgs(exitCode); + fakeProxyGenerator.Raise(g => g.Complete += null, fakeProxyGenerator, eventArgs); } void SetTempFileText(string fileName, string text) @@ -184,6 +195,8 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.AddServiceReference(); + SvcUtilRunCompletedSuccessfully(); + fakeProxyGenerator.AssertWasCalled(p => p.GenerateProxyFile()); } @@ -196,6 +209,9 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.Options.ServiceName = "MyServiceRef"; generator.AddServiceReference(); + + SvcUtilRunCompletedSuccessfully(); + string expectedProxyFileName = @"d:\projects\MyProject\Service References\MyServiceRef\Reference.cs"; Assert.AreEqual(expectedProxyFileName, fakeProxyGenerator.Options.OutputFileName); @@ -211,6 +227,7 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.AddServiceReference(); + SvcUtilRunCompletedSuccessfully(); string expectedDirectory = @"d:\projects\MyProject\Service References\MyService1"; fakeFileSystem.AssertWasCalled(f => f.CreateDirectoryIfMissing(expectedDirectory)); @@ -227,6 +244,8 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.AddServiceReference(); + SvcUtilRunCompletedSuccessfully(); + fakeProject.AssertWasCalled(p => p.AddServiceReferenceProxyFile(expectedProxyFileName)); } @@ -240,6 +259,8 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.AddServiceReference(); + SvcUtilRunCompletedSuccessfully(); + fakeProject.AssertWasCalled(p => p.Save()); } @@ -253,6 +274,8 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.AddServiceReference(); + SvcUtilRunCompletedSuccessfully(); + var expectedMapFile = new ServiceReferenceMapFile() { FileName = @"d:\projects\MyProject\Service References\MyServiceRef\Reference.svcmap" }; @@ -271,6 +294,8 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.AddServiceReference(); + SvcUtilRunCompletedSuccessfully(); + fakeProject.AssertWasCalled(p => p.AddServiceReferenceMapFile(expectedMapFileName)); } @@ -284,6 +309,8 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.AddServiceReference(); + SvcUtilRunCompletedSuccessfully(); + fakeProject.AssertWasCalled(p => p.AddAssemblyReference("System.ServiceModel")); } @@ -301,6 +328,8 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences mi => fakeProject.AssertWasCalled(p => p.AddAssemblyReference("System.ServiceModel")))); generator.AddServiceReference(); + + SvcUtilRunCompletedSuccessfully(); } [Test] @@ -314,6 +343,8 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.AddServiceReference(); + SvcUtilRunCompletedSuccessfully(); + Assert.AreEqual("Test.MyServiceRef", fakeProxyGenerator.Options.Namespace); } @@ -328,6 +359,8 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.AddServiceReference(); + SvcUtilRunCompletedSuccessfully(); + Assert.AreEqual("MyServiceRef", fakeProxyGenerator.Options.Namespace); } @@ -342,6 +375,8 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.AddServiceReference(); + SvcUtilRunCompletedSuccessfully(); + Assert.AreEqual("CS", fakeProxyGenerator.Options.Language); } @@ -356,6 +391,8 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.AddServiceReference(); + SvcUtilRunCompletedSuccessfully(); + Assert.AreEqual("VB", fakeProxyGenerator.Options.Language); } @@ -373,6 +410,8 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.AddServiceReference(); + SvcUtilRunCompletedSuccessfully(); + Assert.AreEqual(expectedAppConfigFileName, fakeProxyGenerator.Options.AppConfigFileName); Assert.IsFalse(fakeProxyGenerator.Options.NoAppConfig); Assert.IsFalse(fakeProxyGenerator.Options.MergeAppConfig); @@ -393,6 +432,8 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.AddServiceReference(); + SvcUtilRunCompletedSuccessfully(); + Assert.AreEqual(expectedAppConfigFileName, fakeProxyGenerator.Options.AppConfigFileName); Assert.IsFalse(fakeProxyGenerator.Options.NoAppConfig); Assert.IsTrue(fakeProxyGenerator.Options.MergeAppConfig); @@ -413,6 +454,8 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.AddServiceReference(); + SvcUtilRunCompletedSuccessfully(); + string[] expectedReferences = new string[] { "System.Windows.Forms", @"d:\projects\MyProject\lib\MyLib.dll" @@ -435,6 +478,8 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.AddServiceReference(); + SvcUtilRunCompletedSuccessfully(); + Assert.AreEqual(0, fakeProxyGenerator.Options.Assemblies.Count); } @@ -558,7 +603,7 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.AddServiceReference(); - SvcUtilRunCompleted(); + SvcUtilRunCompletedSuccessfully(); fakeActiveTextEditors.AssertWasCalled(editors => editors.UpdateTextForOpenFile(appConfigFileName, "New appconfig text")); } @@ -576,7 +621,7 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.AddServiceReference(); - SvcUtilRunCompleted(); + SvcUtilRunCompletedSuccessfully(); fakeActiveTextEditors.AssertWasNotCalled(editors => editors.UpdateTextForOpenFile(Arg.Is.Anything, Arg.Is.Anything)); } @@ -596,7 +641,7 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences generator.AddServiceReference(); - SvcUtilRunCompleted(); + SvcUtilRunCompletedSuccessfully(); fakeFileSystem.AssertWasCalled(fs => fs.DeleteFile(@"d:\temp\test.tmp")); } @@ -618,10 +663,68 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences AppConfigIsClosedInTextEditor(appConfigFileName); - SvcUtilRunCompleted(); + SvcUtilRunCompletedSuccessfully(); fakeFileSystem.AssertWasCalled(fs => fs.WriteAllText(appConfigFileName, "New appconfig text")); fakeActiveTextEditors.AssertWasNotCalled(editors => editors.UpdateTextForOpenFile(Arg.Is.Anything, Arg.Is.Anything)); } + + [Test] + public void AddServiceReference_AppConfigIsOriginallyOpenInTextEditorButSvcUtilFails_TempFileAppConfigContentIsNotUpdatedInTextEditor() + { + CreateGenerator(); + AddProxyFileNameForServiceName("MyService"); + AddMapFileNameForServiceName("MyService"); + generator.Options.ServiceName = "MyService"; + string appConfigFileName = @"d:\projects\MyProject\app.config"; + SetProjectAppConfigFileName(appConfigFileName); + ProjectHasAppConfigFile(); + AppConfigIsOpenInTextEditor(appConfigFileName, "appconfig text"); + SetTempFileText(@"d:\temp\test.tmp", "New appconfig text"); + + generator.AddServiceReference(); + + SvcUtilRunCompletedWithErrors(); + + fakeActiveTextEditors.AssertWasNotCalled(editors => editors.UpdateTextForOpenFile(Arg.Is.Anything, Arg.Is.Anything)); + fakeFileSystem.AssertWasCalled(fs => fs.DeleteFile(@"d:\temp\test.tmp")); + } + + [Test] + public void AddServiceReference_SvcUtilFails_ProjectNotUpdatedWithServiceReference() + { + CreateGenerator(); + AddProxyFileNameForServiceName(@"d:\MyProject\Service References", "MyServiceRef"); + AddMapFileNameForServiceName("MyServiceRef"); + generator.Options.ServiceName = "MyServiceRef"; + + generator.AddServiceReference(); + + SvcUtilRunCompletedWithErrors(); + + fakeProject.AssertWasNotCalled(p => p.AddAssemblyReference(Arg.Is.Anything)); + fakeProject.AssertWasNotCalled(p => p.Save()); + fakeProject.AssertWasNotCalled(p => p.AddServiceReferenceMapFile(Arg.Is.Anything)); + fakeProject.AssertWasNotCalled(p => p.AddServiceReferenceProxyFile(Arg.Is.Anything)); + fakeReferenceMapGenerator.AssertWasNotCalled(g => g.GenerateServiceReferenceMapFile(Arg.Is.Anything)); + } + + [Test] + public void AddServiceReference_ProjectHasNoAppConfigButSvcUtilFails_AppConfigNotAddedToProject() + { + CreateGenerator(); + AddProxyFileNameForServiceName("MyService"); + AddMapFileNameForServiceName("MyService"); + generator.Options.ServiceName = "MyService"; + UseVisualBasicProject(); + SetProjectAppConfigFileName(@"d:\projects\MyProject\app.config"); + ProjectDoesNotHaveAppConfigFile(); + + generator.AddServiceReference(); + + SvcUtilRunCompletedWithErrors(); + + fakeProject.AssertWasNotCalled(p => p.AddAppConfigFile()); + } } } From 5369b65f1cebb76c3646a9b637b0699333412772 Mon Sep 17 00:00:00 2001 From: Matt Ward Date: Sat, 21 Apr 2012 16:21:29 +0100 Subject: [PATCH 03/36] Fix view in browser for html files. --- .../AspNet.Mvc/Project/AspNet.Mvc.csproj | 1 - .../AspNet.Mvc/Project/Src/ViewInBrowser.cs | 77 ------------------- .../Project/ICSharpCode.SharpDevelop.addin | 2 +- .../Project/ICSharpCode.SharpDevelop.csproj | 1 + .../Project/Src/Commands/ViewInBrowser.cs | 32 ++++++++ 5 files changed, 34 insertions(+), 79 deletions(-) delete mode 100644 src/AddIns/BackendBindings/AspNet.Mvc/Project/Src/ViewInBrowser.cs create mode 100644 src/Main/Base/Project/Src/Commands/ViewInBrowser.cs diff --git a/src/AddIns/BackendBindings/AspNet.Mvc/Project/AspNet.Mvc.csproj b/src/AddIns/BackendBindings/AspNet.Mvc/Project/AspNet.Mvc.csproj index 5fdddc6f26..34524f74cd 100644 --- a/src/AddIns/BackendBindings/AspNet.Mvc/Project/AspNet.Mvc.csproj +++ b/src/AddIns/BackendBindings/AspNet.Mvc/Project/AspNet.Mvc.csproj @@ -231,7 +231,6 @@ - diff --git a/src/AddIns/BackendBindings/AspNet.Mvc/Project/Src/ViewInBrowser.cs b/src/AddIns/BackendBindings/AspNet.Mvc/Project/Src/ViewInBrowser.cs deleted file mode 100644 index 4a89a3e636..0000000000 --- a/src/AddIns/BackendBindings/AspNet.Mvc/Project/Src/ViewInBrowser.cs +++ /dev/null @@ -1,77 +0,0 @@ -//// Copyright (c) AlphaSierraPapa for the SharpDevelop Team (for details please see \doc\copyright.txt) -//// This code is distributed under the GNU LGPL (for details please see \doc\license.txt) -// -//using System; -//using System.IO; -//using System.Linq; -// -//using ICSharpCode.Core; -//using ICSharpCode.SharpDevelop.Gui.OptionPanels; -//using ICSharpCode.SharpDevelop.Project; -//using ICSharpCode.SharpDevelop.Project.Commands; -// -//namespace ICSharpCode.AspNet.Mvc -//{ -// public class ViewInBrowser : AbstractMenuCommand -// { -// public override void Run() -// { -// var node = ProjectBrowserPad.Instance.SelectedNode as FileNode; -// if (node == null) { -// return; -// } -// -// var project = ProjectService.CurrentProject as CompilableProject; -// if (project == null) { -// return; -// } -// -// if (!project.IsWebProject) { -// MessageService.ShowError("${res:ProjectComponent.ContextMenu.NotAWebProject}"); -// return; -// } -// -// if (!WebProjectService.IsIISOrIISExpressInstalled) { -// MessageService.ShowError("${res:ICSharpCode.WebProjectOptionsPanel.IISNotFound}"); -// return; -// } -// -// string fileName = node.FileName; -// -//// // set project options -//// project.StartAction = StartAction.StartURL; -//// string directoryName = Path.GetDirectoryName(project.FileName) + "\\"; -//// project.StartUrl = fileName.Replace(directoryName, "/").Replace("\\", "/"); -// -// // set web server options -// string projectName = project.Name; -// WebProjectOptions existingOptions = WebProjectsOptions.Instance.GetWebProjectOptions(projectName); -// -// var options = new WebProjectOptions { -// Data = new WebProjectDebugData { -// WebServer = WebProjectService.IsIISExpressInstalled ? WebServer.IISExpress : WebServer.IIS, -// Port = (existingOptions != null && existingOptions.Data != null) ? existingOptions.Data.Port : "8080", //TODO: port collision detection -// ProjectUrl = string.Format("{0}/{1}", WebBehavior.LocalHost, project.Name) -// }, -// ProjectName = projectName -// }; -// -// if (options.Data.WebServer == WebServer.IISExpress) { -// options.Data.ProjectUrl = string.Format( -// @"{0}:{1}/{2}", WebBehavior.LocalHost, options.Data.Port, projectName); -// } -// -// WebProjectsOptions.Instance.SetWebProjectOptions(projectName, options); -// -// // create virtual directory -// string error = WebProjectService.CreateVirtualDirectory( -// options.Data.WebServer, -// projectName, -// Path.GetDirectoryName(ProjectService.CurrentProject.FileName)); -// LoggingService.Info(error ?? string.Empty); -// -// // RunProject -// new RunProject().Run(); -// } -// } -//} diff --git a/src/Main/Base/Project/ICSharpCode.SharpDevelop.addin b/src/Main/Base/Project/ICSharpCode.SharpDevelop.addin index 294b954cc3..959cbe3181 100755 --- a/src/Main/Base/Project/ICSharpCode.SharpDevelop.addin +++ b/src/Main/Base/Project/ICSharpCode.SharpDevelop.addin @@ -490,7 +490,7 @@ - + ListViewPad.xaml + diff --git a/src/Main/Base/Project/Src/Commands/ViewInBrowser.cs b/src/Main/Base/Project/Src/Commands/ViewInBrowser.cs new file mode 100644 index 0000000000..2396a7417d --- /dev/null +++ b/src/Main/Base/Project/Src/Commands/ViewInBrowser.cs @@ -0,0 +1,32 @@ +// Copyright (c) AlphaSierraPapa for the SharpDevelop Team (for details please see \doc\copyright.txt) +// This code is distributed under the GNU LGPL (for details please see \doc\license.txt) + +using System; +using System.Diagnostics; +using System.IO; +using System.Linq; + +using ICSharpCode.Core; +using ICSharpCode.SharpDevelop.Gui.OptionPanels; +using ICSharpCode.SharpDevelop.Project; +using ICSharpCode.SharpDevelop.Project.Commands; + +namespace ICSharpCode.SharpDevelop.Project.Commands +{ + public class ViewInBrowser : AbstractMenuCommand + { + public override void Run() + { + var node = ProjectBrowserPad.Instance.SelectedNode as FileNode; + if (node == null) { + return; + } + + try { + Process.Start(node.FileName); + } catch (Exception ex) { + MessageService.ShowMessage(ex.Message); + } + } + } +} From 869c2340ea3faf16f0a697af53fbe6516dd3cc97 Mon Sep 17 00:00:00 2001 From: Matt Ward Date: Sat, 21 Apr 2012 16:46:01 +0100 Subject: [PATCH 04/36] Fix error when installing latest jQuery NuGet package. --- .../Misc/PackageManagement/Project/Src/EnvDTE/DTE.cs | 4 ++++ .../Misc/PackageManagement/Test/Src/EnvDTE/DTETests.cs | 10 ++++++++++ 2 files changed, 14 insertions(+) diff --git a/src/AddIns/Misc/PackageManagement/Project/Src/EnvDTE/DTE.cs b/src/AddIns/Misc/PackageManagement/Project/Src/EnvDTE/DTE.cs index b190eb47e9..e2205ee818 100644 --- a/src/AddIns/Misc/PackageManagement/Project/Src/EnvDTE/DTE.cs +++ b/src/AddIns/Misc/PackageManagement/Project/Src/EnvDTE/DTE.cs @@ -29,6 +29,10 @@ namespace ICSharpCode.PackageManagement.EnvDTE ItemOperations = new ItemOperations(fileService); } + public string Version { + get { return "10.0"; } + } + public Solution Solution { get { if (IsSolutionOpen) { diff --git a/src/AddIns/Misc/PackageManagement/Test/Src/EnvDTE/DTETests.cs b/src/AddIns/Misc/PackageManagement/Test/Src/EnvDTE/DTETests.cs index b93e25ef91..bf21b84213 100644 --- a/src/AddIns/Misc/PackageManagement/Test/Src/EnvDTE/DTETests.cs +++ b/src/AddIns/Misc/PackageManagement/Test/Src/EnvDTE/DTETests.cs @@ -137,5 +137,15 @@ namespace PackageManagement.Tests.EnvDTE Assert.AreEqual("ProjectA", name); } + + [Test] + public void Version_CheckVersion_Returns10() + { + CreateDTE(); + + string version = dte.Version; + + Assert.AreEqual("10.0", version); + } } } From 1aaf6ddc6f6c6d8cdf3d667ab79dac9e30feb2b9 Mon Sep 17 00:00:00 2001 From: Matt Ward Date: Sat, 21 Apr 2012 17:04:54 +0100 Subject: [PATCH 05/36] Update to latest jQuery and Modernizr NuGet packages. --- data/templates/packages/Modernizr.1.7.nupkg | Bin 20540 -> 0 bytes data/templates/packages/Modernizr.2.5.3.nupkg | Bin 0 -> 18322 bytes data/templates/packages/jQuery.1.6.1.nupkg | Bin 228647 -> 0 bytes data/templates/packages/jQuery.1.7.2.nupkg | Bin 0 -> 180771 bytes .../project/CSharp/MvcRazorProject.xpt | 8 ++++---- .../templates/project/CSharp/MvcWebProject.xpt | 8 ++++---- data/templates/project/VB/MvcRazorProject.xpt | 8 ++++---- data/templates/project/VB/MvcWebProject.xpt | 8 ++++---- 8 files changed, 16 insertions(+), 16 deletions(-) delete mode 100644 data/templates/packages/Modernizr.1.7.nupkg create mode 100644 data/templates/packages/Modernizr.2.5.3.nupkg delete mode 100644 data/templates/packages/jQuery.1.6.1.nupkg create mode 100644 data/templates/packages/jQuery.1.7.2.nupkg diff --git a/data/templates/packages/Modernizr.1.7.nupkg b/data/templates/packages/Modernizr.1.7.nupkg deleted file mode 100644 index df768357232f1bd7076928c11d3f10412c80e145..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 20540 zcmd42Wl)<@)Gi8zBE`L>P+SWHcXy}I;>9(%2M^E|C{WzBI7JJ=iiJ|#-66O`fS|!H z-}jv}_nvd++Mhc&ne3T&^6oWzzj>aOwby#q2Q@VGS1AAS;`lx;$v5Jzbb^Y4@*f`@ z6e<)m4;v>>0M~zvv<0tGSbviK=dJ(q0B?ngOZhrG(fZhUcmiErBulY&K90ru5LCi z&)?X(dN^BnJzsj*0o*LC94+i@0KDAXf`I4M{O>mC|3{m&pZwfx{uhhRKr0VdPgh$n zE-P2(|7PrYUC-utxB=Wk0A~vqpskIk7d`DK3lBRRF9~{phO4!WhYQf(gUiL+)6K?; zo>s+Lf?mhMhFeg?Mo`2`*p{1L$eNFy7V!UM0spVI1aP+Tvaq)BvH)1Qdf0Hfc|6bd z@B-R+{vVe2-yevljfW4=%Et5mbPm8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!}l%E;#Cab#An8zuKt{o;2Wr_~+f^*hJ0V9_8GyYry7IVT0yTeE56k zzTD&+E=jUaYRtZ|q5c{CBH=*<_wi3;2G&9jf{oY*y&>4n6aI?q+y395rdR9_%t-gS z;l}QdyXv8-^}U_$G;?ctBy-X+xPhzR(eK=pFmtJ@nr&zN&llV!s*U4S_*OxvuV!zf8H3$DqtOKx{B3E`}%8dWmH|&xz3p)@On_Z zMDx9_fkgXt{1)8S2cIW+N6l3%h(Zd1+iAVXuN#)mEHqK0(MTH6GO8N zn;hs3`)rEsq2qR4G2S0&LN(rN4ejG%6uvF=qio+G zr}&J$F=fJp%`?bv^0OR!GmE#?mn|z#^`F%v{(af|*|$!6I5xPiYTarZq^X{yKCJI5 z37PV-WZcn^rX4KL>YU@dy3QGLzOB5^=g`h?Jb9vFWstBjSH5r8RR3o`R@W1;vt#v* z{R8u~-CgaPa|Zptbq{+V73)QckM5Of4W_fLJKI<38xP+R{L(30sw=6VCaXF_AF6n$X&2Pec}_1mC{ru`&1HUZ!7O^__6*`p;G-%|H~P<#>hqR z=z&pWx5n1=+m?=jHHU8=&D?!TzwYYg&)ahxi<7 zLxtB4m3bBW<_7+y?wi!6ys zMZ=(>kqYJ~7Rgi@W-+T!C>RQFvtfuG@?x%zSRQRA6wxuUj6}p-bjZF%vAvi`V0Vby8r9eh1aa1NiQIY}TpaC8so<{u@ZzMDac@#sdl*x1sKVA3kS0E;Ef)C+J zV17V!w6`Y+jfq&k(1Xea^dKWK=u(7WP#+UhY6wWi#3;bg6cnfIaUrioO2Cg0eFX>{ zLZhDN2WZI`%31$@Y%pDAMevm4LNF+GMHM7T4*eR!<<(Q|a9`+((EFPgDYoC!9Rm<@c_ L!-*aFA$9jZ!W4XX diff --git a/data/templates/packages/Modernizr.2.5.3.nupkg b/data/templates/packages/Modernizr.2.5.3.nupkg new file mode 100644 index 0000000000000000000000000000000000000000..98ade6d191766655f1351423e5b3fd60b5e638ca GIT binary patch literal 18322 zcmb@u1yCIA_a=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$Boo5yk)_}zC3iDP4g zbtc6K_VP0iJo^JI+dfe+?O8`VY)bmWtr}126(Rz{{hqjDwF?zyd7r%#4@cjL(9{0?Y^E zw&UB!ql8>9Mk|X#2jj21F;gOc7<62 z`Kd)kgzg7d`(tbXoCe||Xkji)Z4HAt3bM01x;oplL7lDGEzH@$_FxAv1m?od$;Qb} z{YPII*xAA5ZwY>#`J<z) zP`La$?ZO6E69g`$CDhpg1cSeYi}o+o!a4E&uWF?h5wb8BGbFu2-8Y}H-C&Yl1p7XSzV0lNe2Y#=LciSS-xe%#f7|=F7xoB*tXw`oK)65dZ+nK4 zP`H91FcU3LN3e?#+r5wc!)@>X+>d_o`^_c(uT2(i9QQH-VfQk@?NkbE339cE0i-?P z&A+*?GuYmR8t}XD_hZ3RL>=K4V-BBxD1_Y&V(}l20sP%5*x;1E`nXuzIJ&UFua_FY z{vX?X0e`s`(9H$Dg0R{C zmo!T6US%>eK0r81L_(na3rmY1|IG4lm;o1bliQ*Y5C$zCAkh4U*(wU+Kg!4EU<3IZ zhU*bDVuEn3#KCoi^B0E5iHN_4tbYnv|5IPXNy1Y%aD6?HLP7xig*-I*U*!L-CAge6x91} R=g&{{Tdu)NcR) diff --git a/data/templates/packages/jQuery.1.7.2.nupkg b/data/templates/packages/jQuery.1.7.2.nupkg new file mode 100644 index 0000000000000000000000000000000000000000..033bae95d0d8ee5aec4ab44c25092cff73e3ebf0 GIT binary patch literal 180771 zcmb5V1CS@d*Dct#ZB5(#YumPM+qP}n=Cr46+qP|Y&zt`jZ)5k{jeYT6MpQ;rRNhnf z<~@~JQTLRBG$%knr>ID4E(Ay8IjA zY+>o(O!Uvh&Y73Q!o|gbi-Ez}*uvD-(3#%e!PM^G6*GG$TSJ$Br%vV!4u;0ohUTUW z07gbOhJW7t-xwtS9g|4K)4}xrgJ^4M>}2n3Z{|X8Y;XHN!T$O64~~hEfsviT*3iz< z%+%S1gh<8E$=uY1mxRGe(bd$+litqN*}>G9gh@Q*KOKp;R+|HT(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tZNxI-l@Q3+dq)>#~_Zb$F_pZ~1EXB^5}; zO%rH%Tj(87!a^ZQZ& zCAY1YeO3&Giwt*Qbz}4I!;mne%{}W%m3LnF$iM~8@5`Uo=Ze_RV7(kPWnoJ)FPHKGqBgUccp(v{Li1iVvO~H4#fH(jG>LSAxPKdKLCjx zO!Xazfo4{=mS)DF?kAQ|mX#qkvN3f0?Q3EOd;LH9(Awk^F~I3}i7ANB64Z&GK*VMs zAN=!ABVr+QeHY^25;FGshQF-`5`&yXY_D%?W<=}^Fd#Mp;Vo@!f78+v|I13y^O~7h z1B{3rY={j(}+r5@K@vM|M1#hJ@wmjW=0_D-w$E`PsjaH z>o29e{|ra|KjdzB8UE+vZ?Gk(Wk*ng@B^&rRFwWe{#nFp0dRG;u{Q$#$@^yk?;q*& zuL$P}m@D>d^nrk^dqs^?#m6fAIYyCH{Yh zEGRgB+eGK^+a^$)eg+upJ6bvri@Jb{|B=4-081b#@js3K-4-9IzAY$X3_<;GW6j`X zZS-%6LHEz3pa&uUr~@=Lvjx(Eo|lxE;XgKE?Fh6582*<=Yz!R$4*xr}`F}I-zal~E zUjMg^{$n8gFX;c`mwy{||MU#QA3X^QBX9^huzwBbC!~IC$DknkeIfiWDr9=U`-kDT zuYvyn{!7}70=u)n1_ZhTP4tld24n<%GyEeB>Hp#Te}}U5&_OT{fq@;6LxFw#85AZP>uNl5)W<0g@V|QL z-}Scso$v4S^S|<0*Z&XS-)8IoAoy3%{Cy7aR|4r~i2wI9f`4!R?}Oi8o1bih_)kNj ZyfidOfDa55_V2)MK+%cw1M~~*{{!9nU4Z}q literal 0 HcmV?d00001 diff --git a/data/templates/project/CSharp/MvcRazorProject.xpt b/data/templates/project/CSharp/MvcRazorProject.xpt index 37e610e87b..d517855fe8 100644 --- a/data/templates/project/CSharp/MvcRazorProject.xpt +++ b/data/templates/project/CSharp/MvcRazorProject.xpt @@ -273,8 +273,8 @@ Aliquam suscipit tellus vel nunc elementum fringilla.

@ViewBag.Title - - + +
@@ -300,8 +300,8 @@ Aliquam suscipit tellus vel nunc elementum fringilla.

- - + + ]]> diff --git a/data/templates/project/CSharp/MvcWebProject.xpt b/data/templates/project/CSharp/MvcWebProject.xpt index bd14354e5e..93d614f7d1 100644 --- a/data/templates/project/CSharp/MvcWebProject.xpt +++ b/data/templates/project/CSharp/MvcWebProject.xpt @@ -280,8 +280,8 @@ namespace ${StandardNamespace} <asp:ContentPlaceHolder id="Title" runat="server"/> " rel="stylesheet" type="text/css"> - - + +
@@ -307,8 +307,8 @@ namespace ${StandardNamespace} - - + + ]]> diff --git a/data/templates/project/VB/MvcRazorProject.xpt b/data/templates/project/VB/MvcRazorProject.xpt index bd94faf848..87ba3a7275 100644 --- a/data/templates/project/VB/MvcRazorProject.xpt +++ b/data/templates/project/VB/MvcRazorProject.xpt @@ -265,8 +265,8 @@ Aliquam suscipit tellus vel nunc elementum fringilla.

@ViewData("Title") - - + +
@@ -292,8 +292,8 @@ Aliquam suscipit tellus vel nunc elementum fringilla.

- - + + ]]> diff --git a/data/templates/project/VB/MvcWebProject.xpt b/data/templates/project/VB/MvcWebProject.xpt index f472bafb05..5be3b65b5a 100644 --- a/data/templates/project/VB/MvcWebProject.xpt +++ b/data/templates/project/VB/MvcWebProject.xpt @@ -272,8 +272,8 @@ End Class <asp:ContentPlaceHolder id="Title" runat="server"/> " rel="stylesheet" type="text/css"> - - + +
@@ -299,8 +299,8 @@ End Class - - + + ]]> From 07599ad6409fade27de238d3ae70dc4735837867 Mon Sep 17 00:00:00 2001 From: Matt Ward Date: Sat, 21 Apr 2012 17:47:11 +0100 Subject: [PATCH 06/36] Update setup with new NuGet packages used in project templates. --- src/Setup/Files.wxs | 8 ++++---- src/Setup/Setup.wxs | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/Setup/Files.wxs b/src/Setup/Files.wxs index 6ce8eb43e5..c70aaa1083 100644 --- a/src/Setup/Files.wxs +++ b/src/Setup/Files.wxs @@ -939,11 +939,11 @@ - - + + - - + + diff --git a/src/Setup/Setup.wxs b/src/Setup/Setup.wxs index 1647d9c115..d6e81ae987 100644 --- a/src/Setup/Setup.wxs +++ b/src/Setup/Setup.wxs @@ -541,8 +541,8 @@ - - + + From c28103cce9f6e69c75e14ae80701c6351263d17e Mon Sep 17 00:00:00 2001 From: Siegfried Pammer Date: Sun, 22 Apr 2012 09:38:46 +0200 Subject: [PATCH 07/36] mark 4.2 RC release + update translations --- data/resources/StringResources.fr.resx | 15 +++++++++++++++ data/resources/StringResources.nl.resx | 6 ++++++ src/Main/GlobalAssemblyInfo.template | 2 +- 3 files changed, 22 insertions(+), 1 deletion(-) diff --git a/data/resources/StringResources.fr.resx b/data/resources/StringResources.fr.resx index e8e68aa95f..2ea1fca7a5 100644 --- a/data/resources/StringResources.fr.resx +++ b/data/resources/StringResources.fr.resx @@ -4973,6 +4973,9 @@ Soit ils n'existent pas, soit le document Wix n'est pas pour WiX 3.0 et l'espace Copier la valeur dans le presse-papier + + Nom + Membres non publics @@ -4994,6 +4997,12 @@ Soit ils n'existent pas, soit le document Wix n'est pas pour WiX 3.0 et l'espace Membres statiques + + Type + + + Valeur + Mémoire @@ -5369,6 +5378,9 @@ Soit ils n'existent pas, soit le document Wix n'est pas pour WiX 3.0 et l'espace Ouvrir le répertoire dans l'explorateur + + Ouvrir une invite de commande ici + Réduire tous les noeuds @@ -5504,6 +5516,9 @@ Soit ils n'existent pas, soit le document Wix n'est pas pour WiX 3.0 et l'espace Lance&r projet + + Exécuter ce projet sans débogueur + Définir comme projet de dém&arrage diff --git a/data/resources/StringResources.nl.resx b/data/resources/StringResources.nl.resx index 7cd2bbc355..5660fe197f 100644 --- a/data/resources/StringResources.nl.resx +++ b/data/resources/StringResources.nl.resx @@ -5380,6 +5380,9 @@ Microsoft.Tools.WindowsInstallerXml.Extenties.NetFxCompiler, WixNetFxExtentie Open de document bevattende map in de Explorer + + Open hier de commando prompt + Alle knooppunten invouwen @@ -5515,6 +5518,9 @@ Microsoft.Tools.WindowsInstallerXml.Extenties.NetFxCompiler, WixNetFxExtentie P&roject starten + + Project uitvoeren zonder foutopsporing + Als startproject instellen. diff --git a/src/Main/GlobalAssemblyInfo.template b/src/Main/GlobalAssemblyInfo.template index a7d5b2d18c..2e3a814d57 100644 --- a/src/Main/GlobalAssemblyInfo.template +++ b/src/Main/GlobalAssemblyInfo.template @@ -30,7 +30,7 @@ internal static class RevisionClass public const string Minor = "2"; public const string Build = "0"; public const string Revision = "$INSERTREVISION$"; - public const string VersionName = "Beta 2"; + public const string VersionName = "RC"; public const string FullVersion = Major + "." + Minor + "." + Build + ".$INSERTREVISION$$INSERTBRANCHPOSTFIX$$INSERTVERSIONNAMEPOSTFIX$"; } From 17032166d9f32dc12833e6f167b71fb8ed3844b8 Mon Sep 17 00:00:00 2001 From: Matt Ward Date: Sun, 22 Apr 2012 11:18:48 +0100 Subject: [PATCH 08/36] Add reference to System.Runtime.Serialization when generating service references. --- .../ServiceReference/ServiceReferenceGenerator.cs | 1 + .../ServiceReferenceGeneratorTests.cs | 15 +++++++++++++++ 2 files changed, 16 insertions(+) diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceGenerator.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceGenerator.cs index b57d7675d5..f37ba11f16 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceGenerator.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/ServiceReference/ServiceReferenceGenerator.cs @@ -137,6 +137,7 @@ namespace ICSharpCode.SharpDevelop.Gui.Dialogs.ReferenceDialog.ServiceReference project.AddServiceReferenceProxyFile(referenceFileName); project.AddServiceReferenceMapFile(mapFileName); + project.AddAssemblyReference("System.Runtime.Serialization"); project.AddAssemblyReference("System.ServiceModel"); if (!project.HasAppConfigFile()) { diff --git a/src/Main/Base/Test/ServiceReferences/ServiceReferenceGeneratorTests.cs b/src/Main/Base/Test/ServiceReferences/ServiceReferenceGeneratorTests.cs index 3053005db9..83a4809d11 100644 --- a/src/Main/Base/Test/ServiceReferences/ServiceReferenceGeneratorTests.cs +++ b/src/Main/Base/Test/ServiceReferences/ServiceReferenceGeneratorTests.cs @@ -314,6 +314,21 @@ namespace ICSharpCode.SharpDevelop.Tests.ServiceReferences fakeProject.AssertWasCalled(p => p.AddAssemblyReference("System.ServiceModel")); } + [Test] + public void AddServiceReference_ProjectDoesNotHaveSystemRuntimeSerializationReference_SystemRuntimeSerializationReferenceAddedToProject() + { + CreateGenerator(); + AddProxyFileNameForServiceName("MyService"); + AddMapFileNameForServiceName("MyService"); + generator.Options.ServiceName = "MyService"; + + generator.AddServiceReference(); + + SvcUtilRunCompletedSuccessfully(); + + fakeProject.AssertWasCalled(p => p.AddAssemblyReference("System.Runtime.Serialization")); + } + [Test] public void AddServiceReference_ProjectDoesNotHaveSystemServiceModelReference_ProjectIsSavedAfterReferenceIsAdded() { From b65f0de5f017525003afc6895836fbb095401be0 Mon Sep 17 00:00:00 2001 From: Daniel Grunwald Date: Fri, 20 Apr 2012 22:06:48 +0200 Subject: [PATCH 09/36] Make CreateMemento/SetMemento virtual for compatibility with SD 4.1. --- src/Main/Base/Project/Src/Project/AbstractProject.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Main/Base/Project/Src/Project/AbstractProject.cs b/src/Main/Base/Project/Src/Project/AbstractProject.cs index ea41f11ac2..d6c2f96410 100644 --- a/src/Main/Base/Project/Src/Project/AbstractProject.cs +++ b/src/Main/Base/Project/Src/Project/AbstractProject.cs @@ -69,12 +69,12 @@ namespace ICSharpCode.SharpDevelop.Project /// Saves project preferences (currently opened files, bookmarks etc.) to the /// a property container. /// - public Properties CreateMemento() + public virtual Properties CreateMemento() { return GetOrCreateBehavior().CreateMemento(); } - public void SetMemento(Properties memento) + public virtual void SetMemento(Properties memento) { GetOrCreateBehavior().SetMemento(memento); } From 78ca36ef338c51a05d79f9d7c5d92472ddf90398 Mon Sep 17 00:00:00 2001 From: Daniel Grunwald Date: Sun, 22 Apr 2012 16:14:20 +0200 Subject: [PATCH 10/36] Update ILSpy to 2.0.0 release Update NewNRefactory to 5.0.0.6 Update Mono.Cecil to 0.9.5-79-gec8248d --- .../ICSharpCode.Decompiler/Ast/AstBuilder.cs | 65 +- .../Ast/AstMethodBodyBuilder.cs | 7 +- .../Ast/CommentStatement.cs | 9 + .../Ast/TextOutputFormatter.cs | 16 +- .../ConvertConstructorCallIntoInitializer.cs | 2 +- .../Ast/Transforms/IntroduceUnsafeModifier.cs | 4 +- .../ReplaceMethodCallsWithOperators.cs | 2 +- .../ICSharpCode.Decompiler/CecilExtensions.cs | 2 + .../DecompilerSettings.cs | 23 + .../Disassembler/ReflectionDisassembler.cs | 11 +- .../FlowAnalysis/ControlFlowNode.cs | 11 +- .../ILAst/LoopsAndConditions.cs | 36 +- .../ILAst/TypeAnalysis.cs | 25 + .../Properties/AssemblyInfo.cs | 4 +- .../Tests/ControlFlow.cs | 81 + .../ICSharpCode.Decompiler/Tests/Generics.cs | 55 + .../Tests/Helpers/RemoveCompilerAttribute.cs | 2 +- .../Tests/ICSharpCode.Decompiler.Tests.csproj | 12 +- .../Tests/IL/ILTests.cs | 51 + .../Tests/IL/SequenceOfNestedIfs.Output.cs | 53 + .../Tests/IL/SequenceOfNestedIfs.dll | Bin 0 -> 2560 bytes .../Tests/IL/SequenceOfNestedIfs.il | 140 + .../Tests/{StackTests => IL}/StackTests.exe | Bin .../Tests/{StackTests => IL}/StackTests.il | 0 .../Tests/PropertiesAndEvents.cs | 3 +- .../Tests/TestRunner.cs | 22 +- .../Tests/TypeAnalysisTests.cs | 10 + src/Libraries/Mono.Cecil/.gitignore | 10 + .../Mono.Cecil/Mono.Cecil.PE/Image.cs | 1 + .../Mono.Cecil/Mono.Cecil.PE/ImageReader.cs | 1 + .../Mono.Cecil/Mono.Cecil.PE/ImageWriter.cs | 91 +- .../Mono.Cecil/Mono.Cecil/AssemblyFlags.cs | 1 + .../Mono.Cecil/AssemblyNameReference.cs | 5 + .../Mono.Cecil/Mono.Cecil/AssemblyWriter.cs | 10 +- src/Libraries/Mono.Cecil/Mono.Cecil/Import.cs | 2 +- .../Mono.Cecil/Mono.Cecil/TypeAttributes.cs | 1 + .../Mono.Cecil/Mono.Cecil/TypeDefinition.cs | 5 + .../Analysis/ControlFlow.cs | 27 +- .../Analysis/DefiniteAssignmentAnalysis.cs | 73 +- .../Analysis/ReachabilityAnalysis.cs | 91 + .../Ast/AstNode.cs | 386 +- .../Ast/AstNodeCollection.cs | 33 +- .../Ast/AstType.cs | 105 +- .../Ast/CSharpModifierToken.cs | 20 +- .../Ast/CSharpTokenNode.cs | 56 +- .../Ast/CSharpUtil.cs | 4 +- .../Ast/CompilationUnit.cs | 84 +- .../Ast/ComposedType.cs | 51 +- .../Ast/DepthFirstAstVisitor.cs | 1215 + .../Ast/DocumentationReference.cs | 149 + .../Ast/ErrorNode.cs | 11 +- .../Expressions/AnonymousMethodExpression.cs | 29 +- .../AnonymousTypeCreateExpression.cs | 16 +- .../Ast/Expressions/ArrayCreateExpression.cs | 17 +- .../Expressions/ArrayInitializerExpression.cs | 23 +- .../Ast/Expressions/AsExpression.cs | 16 +- .../Ast/Expressions/AssignmentExpression.cs | 51 +- .../Expressions/BaseReferenceExpression.cs | 12 +- .../Expressions/BinaryOperatorExpression.cs | 77 +- .../Ast/Expressions/CastExpression.cs | 12 +- .../Ast/Expressions/CheckedExpression.cs | 16 +- .../Ast/Expressions/ConditionalExpression.cs | 16 +- .../Ast/Expressions/DefaultValueExpression.cs | 16 +- .../Ast/Expressions/DirectionExpression.cs | 17 +- .../Ast/Expressions/EmptyExpression.cs | 15 +- .../Ast/Expressions/ErrorExpression.cs | 14 +- .../Ast/Expressions/Expression.cs | 38 +- .../Ast/Expressions/IdentifierExpression.cs | 14 +- .../Ast/Expressions/IndexerExpression.cs | 12 +- .../Ast/Expressions/InvocationExpression.cs | 12 +- .../Ast/Expressions/IsExpression.cs | 16 +- .../Ast/Expressions/LambdaExpression.cs | 23 +- .../Expressions/MemberReferenceExpression.cs | 14 +- .../Expressions/NamedArgumentExpression.cs | 14 +- .../Ast/Expressions/NamedExpression.cs | 14 +- .../Expressions/NullReferenceExpression.cs | 12 +- .../Ast/Expressions/ObjectCreateExpression.cs | 15 +- .../Expressions/ParenthesizedExpression.cs | 35 +- .../Expressions/PointerReferenceExpression.cs | 20 +- .../Ast/Expressions/PrimitiveExpression.cs | 35 +- .../Ast/Expressions/QueryExpression.cs | 183 +- .../Ast/Expressions/SizeOfExpression.cs | 16 +- .../Ast/Expressions/StackAllocExpression.cs | 16 +- .../Expressions/ThisReferenceExpression.cs | 14 +- .../Ast/Expressions/TypeOfExpression.cs | 16 +- .../Expressions/TypeReferenceExpression.cs | 12 +- .../Expressions/UnaryOperatorExpression.cs | 44 +- .../Ast/Expressions/UncheckedExpression.cs | 16 +- .../Ast/Expressions/UndocumentedExpression.cs | 32 +- .../Ast/GeneralScope/Attribute.cs | 17 +- .../Ast/GeneralScope/AttributeSection.cs | 31 +- .../Ast/GeneralScope/Comment.cs | 43 +- .../Ast/GeneralScope/Constraint.cs | 23 +- .../Ast/GeneralScope/DelegateDeclaration.cs | 50 +- .../GeneralScope/ExternAliasDeclaration.cs | 20 +- .../Ast/GeneralScope/NamespaceDeclaration.cs | 18 +- .../Ast/GeneralScope/NewLineNode.cs | 132 + .../Ast/GeneralScope/PreProcessorDirective.cs | 17 +- .../Ast/GeneralScope/TextNode.cs | 94 + .../Ast/GeneralScope/TypeDeclaration.cs | 70 +- .../GeneralScope/TypeParameterDeclaration.cs | 46 +- .../Ast/GeneralScope/UsingAliasDeclaration.cs | 21 +- .../Ast/GeneralScope/UsingDeclaration.cs | 15 +- .../Ast/GeneralScope/WhitespaceNode.cs | 91 + .../Ast/IAstVisitor.cs | 266 + .../Ast/Identifier.cs | 78 +- .../Ast/IdentifierExpressionBackreference.cs | 2 +- .../Ast/MemberType.cs | 48 +- .../Ast/ObservableAstVisitor.cs | 43 +- .../Ast/PrimitiveType.cs | 94 +- .../Ast/Roles.cs | 96 + .../Ast/SimpleType.cs | 46 +- .../Ast/Statements/BlockStatement.cs | 35 +- .../Ast/Statements/BreakStatement.cs | 18 +- .../Ast/Statements/CheckedStatement.cs | 16 +- .../Ast/Statements/ContinueStatement.cs | 18 +- .../Ast/Statements/DoWhileStatement.cs | 16 +- .../Ast/Statements/EmptyStatement.cs | 15 +- .../Ast/Statements/ExpressionStatement.cs | 12 +- .../Ast/Statements/FixedStatement.cs | 16 +- .../Ast/Statements/ForStatement.cs | 15 +- .../Ast/Statements/ForeachStatement.cs | 21 +- .../Ast/Statements/GotoStatement.cs | 52 +- .../Ast/Statements/IfElseStatement.cs | 17 +- .../Ast/Statements/LabelStatement.cs | 19 +- .../Ast/Statements/LockStatement.cs | 16 +- .../Ast/Statements/ReturnStatement.cs | 16 +- .../Ast/Statements/Statement.cs | 23 +- .../Ast/Statements/SwitchStatement.cs | 60 +- .../Ast/Statements/ThrowStatement.cs | 16 +- .../Ast/Statements/TryCatchStatement.cs | 46 +- .../Ast/Statements/UncheckedStatement.cs | 16 +- .../Ast/Statements/UnsafeStatement.cs | 16 +- .../Ast/Statements/UsingStatement.cs | 15 +- .../VariableDeclarationStatement.cs | 20 +- .../Ast/Statements/WhileStatement.cs | 14 +- .../Ast/Statements/YieldBreakStatement.cs | 16 +- .../Ast/Statements/YieldReturnStatement.cs | 16 +- .../Ast/TokenRole.cs | 33 + .../Ast/TypeMembers/Accessor.cs | 32 +- .../Ast/TypeMembers/ConstructorDeclaration.cs | 55 +- .../Ast/TypeMembers/DestructorDeclaration.cs | 32 +- ...AttributedNode.cs => EntityDeclaration.cs} | 41 +- .../Ast/TypeMembers/EnumMemberDeclaration.cs | 36 +- .../Ast/TypeMembers/EventDeclaration.cs | 59 +- .../Ast/TypeMembers/FieldDeclaration.cs | 26 +- .../Ast/TypeMembers/FixedFieldDeclaration.cs | 27 +- .../TypeMembers/FixedVariableInitializer.cs | 14 +- .../Ast/TypeMembers/IndexerDeclaration.cs | 36 +- .../Ast/TypeMembers/MemberDeclaration.cs | 74 - .../Ast/TypeMembers/MethodDeclaration.cs | 35 +- .../Ast/TypeMembers/OperatorDeclaration.cs | 145 +- .../Ast/TypeMembers/ParameterDeclaration.cs | 37 +- .../Ast/TypeMembers/PropertyDeclaration.cs | 34 +- .../Ast/TypeMembers/VariableInitializer.cs | 58 +- .../CSharpProjectContent.cs | 21 +- .../Completion/CSharpCompletionEngine.cs | 2929 +- .../Completion/CSharpCompletionEngineBase.cs | 826 +- .../CSharpParameterCompletionEngine.cs | 554 +- .../Completion/ICompletionDataFactory.cs | 1 + .../IMemberProvider.cs} | 24 +- .../IParameterCompletionDataFactory.cs | 13 +- .../Formatter/AstFormattingVisitor.cs | 2025 +- .../Formatter/CSharpFormattingOptions.cs | 162 +- .../Formatter/FormattingOptionsFactory.cs | 339 + .../Formatter/GeneratedCodeSettings.cs | 216 + .../Formatter/Indent.cs | 77 +- .../Formatter/TextEditorOptions.cs | 106 + .../ICSharpCode.NRefactory.CSharp.csproj | 149 +- .../OutputVisitor/CSharpAmbience.cs | 253 +- .../OutputVisitor/CSharpOutputVisitor.cs | 2799 +- .../OutputVisitor/CodeDomConvertVisitor.cs | 259 +- .../OutputVisitor/InsertParenthesesVisitor.cs | 50 +- .../TextWriterOutputFormatter.cs | 22 +- .../Parser/CSharpParser.cs | 2158 +- .../Parser/mcs/AssemblyInfo.cs | 43 - .../Parser/mcs/ChangeLog | 34100 ---------------- .../Parser/mcs/Makefile | 126 - .../Parser/mcs/MonoSymbolFile.cs | 164 +- .../Parser/mcs/MonoSymbolTable.cs | 59 +- .../Parser/mcs/MonoSymbolWriter.cs | 161 - .../Parser/mcs/NOTES | 38 - .../Parser/mcs/OPTIMIZE | 26 - .../Parser/mcs/OTODO | 239 - .../Parser/mcs/PLAN | 66 - .../Parser/mcs/README | 72 - .../Parser/mcs/SourceMethodBuilder.cs | 193 + .../Parser/mcs/TODO | 223 - .../Parser/mcs/anonymous.cs | 531 +- .../Parser/mcs/argument.cs | 12 +- .../Parser/mcs/assembly.cs | 74 +- .../Parser/mcs/assign.cs | 23 +- .../Parser/mcs/async.cs | 517 +- .../Parser/mcs/attribute.cs | 104 +- .../Parser/mcs/cfold.cs | 8 +- .../Parser/mcs/class.cs | 2185 +- .../Parser/mcs/codegen.cs | 105 +- .../Parser/mcs/compiler.doc | 116 - .../Parser/mcs/complete.cs | 22 +- .../Parser/mcs/const.cs | 8 +- .../Parser/mcs/constant.cs | 39 +- .../Parser/mcs/context.cs | 15 +- .../Parser/mcs/convert.cs | 68 +- .../Parser/mcs/cs-parser.cs | 10440 ++--- .../Parser/mcs/cs-parser.jay | 616 +- .../Parser/mcs/cs-tokenizer.cs | 366 +- .../Parser/mcs/decl.cs | 155 +- .../Parser/mcs/delegate.cs | 32 +- .../Parser/mcs/dmcs.csproj | 154 - .../Parser/mcs/dmcs.exe.config | 6 - .../Parser/mcs/dmcs.exe.sources | 55 - .../Parser/mcs/dmcs.sln | 20 - .../Parser/mcs/doc-bootstrap.cs | 59 - .../Parser/mcs/doc.cs | 131 +- .../Parser/mcs/driver.cs | 138 +- .../Parser/mcs/dynamic.cs | 93 +- .../Parser/mcs/ecore.cs | 289 +- .../Parser/mcs/enum.cs | 33 +- .../Parser/mcs/eval.cs | 116 +- .../Parser/mcs/expression.cs | 237 +- .../Parser/mcs/field.cs | 23 +- .../Parser/mcs/flowanalysis.cs | 27 +- .../Parser/mcs/generic.cs | 38 +- .../Parser/mcs/gmcs.csproj | 111 - .../Parser/mcs/gmcs.exe.config | 14 - .../Parser/mcs/gmcs.exe.sources | 56 - .../Parser/mcs/gmcs.sln | 20 - .../Parser/mcs/gmcs.userprefs | 23 - .../Parser/mcs/gmcs2.csproj | 29 - .../Parser/mcs/hosting.cs | 0 .../Parser/mcs/import.cs | 16 +- .../Parser/mcs/iterators.cs | 232 +- .../Parser/mcs/lambda.cs | 6 +- .../Parser/mcs/lambda.todo | 24 - .../Parser/mcs/linq.cs | 22 +- .../Parser/mcs/literal.cs | 8 +- .../Parser/mcs/location.cs | 419 +- .../Parser/mcs/membercache.cs | 75 +- .../Parser/mcs/method.cs | 295 +- .../Parser/mcs/{roottypes.cs => module.cs} | 237 +- .../Parser/mcs/namespace.cs | 620 +- .../Parser/mcs/nullable.cs | 6 +- .../Parser/mcs/parameter.cs | 128 +- .../Parser/mcs/pending.cs | 20 +- .../Parser/mcs/property.cs | 78 +- .../Parser/mcs/reflection.cs | 3 + .../Parser/mcs/repl.txt | 168 - .../Parser/mcs/report.cs | 282 +- .../mcs/{rootcontext.cs => settings.cs} | 210 +- .../Parser/mcs/smcs.exe.sources | 53 - .../Parser/mcs/smcs.exe.sources-xml | 384 - .../Parser/mcs/statement.cs | 829 +- .../Parser/mcs/support.cs | 2 +- .../Parser/mcs/symbolwriter.cs | 17 +- .../Parser/mcs/typemanager.cs | 164 +- .../Parser/mcs/typespec.cs | 24 +- .../Parser/mcs/visit.cs | 69 +- .../Parser/mcs/y.output | 31920 --------------- .../Properties/AssemblyInfo.cs | 20 +- .../Refactoring/BaseRefactoringContext.cs | 172 + .../Refactoring/CodeAction.cs | 73 + .../AddAnotherAccessorAction.cs} | 62 +- .../CheckIfParameterIsNullAction.cs} | 65 +- .../ConvertDecToHexAction.cs} | 34 +- .../CodeActions/ConvertForeachToForAction.cs | 101 + .../ConvertHexToDecAction.cs} | 33 +- .../CodeActions/CreateBackingStoreAction.cs | 76 + .../CreateClassDeclarationAction.cs | 234 + .../CreateConstructorDeclarationAction.cs | 59 + .../CodeActions/CreateDelegateAction.cs | 71 + .../CodeActions/CreateEventInvocatorAction.cs | 112 + .../CodeActions/CreateFieldAction.cs | 242 + .../CodeActions/CreateIndexerAction.cs | 102 + .../CodeActions/CreateLocalVariableAction.cs | 73 + .../CreateMethodDeclarationAction.cs | 356 + .../CodeActions/CreatePropertyAction.cs | 119 + .../CodeActions/DeclareLocalVariableAction.cs | 166 + .../ExtractMethod/ExtractMethodAction.cs | 186 + .../ExtractMethod/StaticVisitor.cs | 85 + .../ExtractMethod/VariableLookupVisitor.cs | 97 + .../FlipOperatorArgumentsAction.cs} | 28 +- .../GenerateGetterAction.cs} | 41 +- .../CodeActions/GeneratePropertyAction.cs | 98 + .../GenerateSwitchLabelsAction.cs} | 76 +- .../CodeActions/InlineLocalVariableAction.cs | 66 + .../InsertAnonymousMethodSignatureAction.cs} | 60 +- .../CodeActions/IntroduceConstantAction.cs | 89 + .../IntroduceFormatItemAction.cs} | 79 +- .../InvertIfAction.cs} | 37 +- .../RemoveBackingStoreAction.cs} | 45 +- .../RemoveBracesAction.cs} | 39 +- .../CodeActions/RemoveRegionAction.cs | 112 + .../ReplaceEmptyStringAction.cs} | 23 +- .../CodeActions/SpecializedCodeAction.cs | 38 + .../SplitDeclarationAndAssignmentAction.cs} | 59 +- .../SplitStringAction.cs} | 48 +- .../UseExplicitTypeAction.cs} | 38 +- .../UseVarKeywordAction.cs} | 28 +- .../Refactoring/CodeIssue.cs | 115 + .../ConditionalToNullCoalescingIssue.cs | 87 + .../ExplicitConversionInForEachIssue.cs | 71 + .../CodeIssues/GatherVisitorBase.cs | 96 + .../InconsistentNamingIssue/AffectedEntity.cs | 78 + .../InconsistentNamingIssue/DefaultRules.cs | 152 + .../InconsistentNamingIssue.cs | 306 + .../NamingConventionService.cs | 99 + .../InconsistentNamingIssue/NamingRule.cs | 392 + .../InconsistentNamingIssue/NamingStyle.cs} | 41 +- .../InconsistentNamingIssue/WordParser.cs | 68 + .../Refactoring/CodeIssues/IssueCategories.cs | 43 + .../NotImplementedExceptionIssue.cs | 66 + .../CodeIssues/RedundantInternalIssue.cs | 74 + .../RedundantNamespaceUsageIssue.cs | 101 + .../CodeIssues/RedundantPrivateIssue.cs | 135 + .../CodeIssues/RedundantThisIssue.cs | 109 + .../CodeIssues/RedundantUsingIssue.cs | 152 + .../CodeIssues/StringIsNullOrEmptyIssue.cs | 110 + .../CodeIssues/UseVarKeywordIssue.cs | 105 + .../ContextAction/ConvertForeachToFor.cs | 95 - .../ContextAction/CreateBackingStore.cs | 73 - .../ContextAction/CreateEventInvocator.cs | 109 - .../Refactoring/ContextAction/CreateField.cs | 77 - .../ContextAction/CreateLocalVariable.cs | 129 - .../ContextAction/CreateProperty.cs | 66 - .../ContextActionAttribute.cs} | 18 +- .../Refactoring/DocumentScript.cs | 166 + .../Refactoring/FormatTextAction.cs | 39 - .../Refactoring/IActionFactory.cs | 75 - ...ontextAction.cs => ICodeActionProvider.cs} | 9 +- .../{Action.cs => ICodeIssueProvider.cs} | 31 +- .../Refactoring/IssueAttribute.cs | 51 + .../Refactoring/IssueMarker.cs | 52 + .../Refactoring/NodeOutputAction.cs | 113 - .../Refactoring/PatternHelper.cs | 40 + .../Refactoring/RefactoringAstHelper.cs | 49 + .../Refactoring/RefactoringContext.cs | 132 +- .../Refactoring/Script.cs | 365 +- .../Refactoring/Severity.cs | 61 + .../Refactoring/TextReplaceAction.cs | 134 - .../Refactoring/TypeSystemAstBuilder.cs | 70 +- .../Resolver/CSharpAstResolver.cs | 146 +- .../{Conversions.cs => CSharpConversions.cs} | 107 +- .../Resolver/CSharpInvocationResolveResult.cs | 6 +- .../Resolver/CSharpOperators.cs | 132 +- .../Resolver/CSharpResolver.cs | 458 +- .../Resolver/FindReferencedEntities.cs | 48 +- .../Resolver/FindReferences.cs | 426 +- .../Resolver/LambdaResolveResult.cs | 2 +- .../Resolver/MemberLookup.cs | 6 + .../Resolver/MethodGroupResolveResult.cs | 36 +- .../Resolver/OverloadResolution.cs | 173 +- .../Resolver/ResolveAtLocation.cs | 76 +- .../Resolver/ResolveVisitor.cs | 1785 +- .../Resolver/TypeInference.cs | 23 +- .../{Resolver => }/SimpleNameLookupMode.cs | 2 +- .../TypeSystem/CSharpAssembly.cs | 150 +- .../TypeSystem/CSharpAttribute.cs | 14 +- .../TypeSystem/CSharpDocumentationComment.cs | 44 + .../TypeSystem/CSharpParsedFile.cs | 61 +- .../TypeSystem/ConstantValues.cs | 6 +- ...odTypeParameterWithInheritedConstraints.cs | 4 +- .../TypeSystem/ResolvedUsingScope.cs | 9 +- .../TypeSystem/TypeOrNamespaceReference.cs | 6 +- .../TypeSystem/TypeSystemConvertVisitor.cs | 415 +- .../Completion/CompletionCategory.cs | 6 +- .../Completion/IParameterDataProvider.cs | 46 +- .../Documentation/DocumentationComment.cs | 95 + .../GetPotentiallyNestedClassTypeReference.cs | 66 + .../Documentation/IDStringProvider.cs | 274 +- .../IDocumentationProvider.cs} | 42 +- .../Documentation/IdStringMemberReference.cs | 68 + .../Documentation/XmlDocumentationProvider.cs | 27 +- .../Editor/IDocument.cs | 5 + .../Editor/IDocumentLine.cs | 5 + .../ICSharpCode.NRefactory/Editor/ISegment.cs | 17 +- .../Editor/ITextAnchor.cs | 4 +- .../Editor/ITextSource.cs | 29 +- .../Editor/ReadOnlyDocument.cs | 39 +- .../Editor/StringBuilderDocument.cs | 425 + .../Editor/StringTextSource.cs | 31 +- .../Editor/TextChangeEventArgs.cs | 25 + .../Editor/TextSourceVersionProvider.cs | 130 + .../ICSharpCode.NRefactory/IAnnotatable.cs | 19 +- .../ICSharpCode.NRefactory.csproj | 46 +- .../Properties/AssemblyInfo.cs | 19 +- .../Properties/GlobalAssemblyInfo.cs | 26 + .../ICSharpCode.NRefactory/Role.cs | 39 +- .../Semantics/ArrayAccessResolveResult.cs | 12 +- .../Semantics/ArrayCreateResolveResult.cs | 6 +- .../Semantics/ByReferenceResolveResult.cs | 3 +- .../Semantics/ConstantResolveResult.cs | 3 +- .../Semantics/Conversion.cs | 39 +- .../Semantics/ConversionResolveResult.cs | 2 + .../Semantics/ForEachResolveResult.cs | 90 + .../InitializedObjectResolveResult.cs} | 16 +- .../Semantics/InvocationResolveResult.cs | 19 +- .../Semantics/LocalResolveResult.cs | 3 +- .../Semantics/MemberResolveResult.cs | 33 +- .../Semantics/NamespaceResolveResult.cs | 3 +- .../Semantics/ResolveResult.cs | 2 + .../Semantics/ThisResolveResult.cs | 12 +- .../Semantics/TypeIsResolveResult.cs} | 32 +- .../Semantics/UnknownMemberResolveResult.cs | 5 +- .../TypeSystem/AnonymousType.cs | 40 +- .../TypeSystem/ArrayType.cs | 7 +- .../TypeSystem/ByReferenceType.cs | 18 +- .../TypeSystem/CecilLoader.cs | 132 +- .../TypeSystem/ComHelper.cs | 63 + .../TypeSystem/ExtensionMethods.cs | 115 +- .../TypeSystem/IAmbience.cs | 15 +- .../TypeSystem/IAssembly.cs | 5 - .../TypeSystem/ICompilation.cs | 9 +- .../TypeSystem/IEntity.cs | 3 +- .../TypeSystem/IMember.cs | 3 +- .../TypeSystem/IMethod.cs | 10 + .../TypeSystem/IParsedFile.cs | 2 +- .../TypeSystem/IType.cs | 3 +- .../TypeSystem/ITypeDefinition.cs | 2 +- .../TypeSystem/ITypeParameter.cs | 6 + .../Implementation/AbstractResolvedEntity.cs | 3 +- .../Implementation/AbstractResolvedMember.cs | 52 +- .../AbstractResolvedTypeParameter.cs | 22 +- .../AbstractUnresolvedEntity.cs | 4 +- .../AbstractUnresolvedMember.cs | 2 +- .../DefaultAssemblyReference.cs | 9 +- .../Implementation/DefaultMemberReference.cs | 12 +- .../Implementation/DefaultParameter.cs | 18 +- .../Implementation/DefaultResolvedAccessor.cs | 81 - .../Implementation/DefaultResolvedMethod.cs | 26 +- .../Implementation/DefaultResolvedProperty.cs | 11 +- .../DefaultResolvedTypeDefinition.cs | 429 +- .../Implementation/DefaultSolutionSnapshot.cs | 2 +- .../DefaultUnresolvedAccessor.cs | 157 - .../DefaultUnresolvedAssembly.cs | 75 +- .../DefaultUnresolvedAttribute.cs | 3 +- .../Implementation/DefaultUnresolvedMethod.cs | 16 + .../DefaultUnresolvedParameter.cs | 9 +- .../DefaultUnresolvedTypeDefinition.cs | 11 +- .../DefaultUnresolvedTypeParameter.cs | 10 +- .../Implementation/DummyTypeParameter.cs | 10 +- ...tInterfaceImplementationMemberReference.cs | 55 + .../FullNameAndTypeParameterCount.cs | 27 +- .../Implementation/GetClassTypeReference.cs | 51 +- .../Implementation/GetMembersHelper.cs | 10 +- .../Implementation/KnownTypeCache.cs | 14 +- .../Implementation/MergedNamespace.cs | 13 +- .../Implementation/SimpleCompilation.cs | 25 +- .../Implementation/SimpleConstantValue.cs | 2 + .../SimpleTypeResolveContext.cs | 23 +- .../Implementation/SpecializedEvent.cs | 23 +- .../Implementation/SpecializedField.cs | 15 +- .../Implementation/SpecializedMember.cs | 203 +- .../Implementation/SpecializedMethod.cs | 99 +- .../Implementation/SpecializedProperty.cs | 21 +- .../SpecializingMemberReference.cs | 52 + .../Implementation/TypeParameterReference.cs | 10 +- .../TypeParameterSubstitution.cs | 94 + .../TypeSystem/InheritanceHelper.cs | 18 +- .../TypeSystem/KnownTypeReference.cs | 23 +- .../TypeSystem/ParameterizedType.cs | 27 +- .../TypeSystem/PointerType.cs | 18 +- .../TypeSystem/ReflectionHelper.cs | 49 +- .../Utils/BitVector16.cs | 3 +- .../Utils/BusyManager.cs | 5 +- .../Utils/CacheManager.cs | 32 +- .../Utils/CallbackOnDispose.cs | 51 + .../ICSharpCode.NRefactory/Utils/EmptyList.cs | 13 +- .../Utils/FastSerializer.cs | 11 +- .../Utils/GraphVizGraph.cs | 8 +- .../Utils/KeyComparer.cs | 60 + .../ICSharpCode.NRefactory/Utils/LazyInit.cs | 12 +- .../Utils/ProjectedList.cs | 120 +- .../Utils/ReferenceComparer.cs | 6 +- 473 files changed, 36265 insertions(+), 88772 deletions(-) create mode 100644 src/Libraries/ICSharpCode.Decompiler/Tests/ControlFlow.cs create mode 100644 src/Libraries/ICSharpCode.Decompiler/Tests/IL/ILTests.cs create mode 100644 src/Libraries/ICSharpCode.Decompiler/Tests/IL/SequenceOfNestedIfs.Output.cs create mode 100644 src/Libraries/ICSharpCode.Decompiler/Tests/IL/SequenceOfNestedIfs.dll create mode 100644 src/Libraries/ICSharpCode.Decompiler/Tests/IL/SequenceOfNestedIfs.il rename src/Libraries/ICSharpCode.Decompiler/Tests/{StackTests => IL}/StackTests.exe (100%) rename src/Libraries/ICSharpCode.Decompiler/Tests/{StackTests => IL}/StackTests.il (100%) create mode 100644 src/Libraries/Mono.Cecil/.gitignore create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Analysis/ReachabilityAnalysis.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/DocumentationReference.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/NewLineNode.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/TextNode.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/WhitespaceNode.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Roles.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TokenRole.cs rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/{AttributedNode.cs => EntityDeclaration.cs} (74%) delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/MemberDeclaration.cs rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/{Refactoring/CreateLinkAction.cs => Completion/IMemberProvider.cs} (72%) create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/FormattingOptionsFactory.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/GeneratedCodeSettings.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/TextEditorOptions.cs delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/AssemblyInfo.cs delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/ChangeLog delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/Makefile delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/NOTES delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/OPTIMIZE delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/OTODO delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/PLAN delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/README create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/SourceMethodBuilder.cs delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/TODO delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/compiler.doc delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dmcs.csproj delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dmcs.exe.config delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dmcs.exe.sources delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dmcs.sln delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/doc-bootstrap.cs delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.csproj delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.exe.config delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.exe.sources delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.sln delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.userprefs delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs2.csproj delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/hosting.cs delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/lambda.todo rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/{roottypes.cs => module.cs} (67%) delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/repl.txt rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/{rootcontext.cs => settings.cs} (88%) delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/smcs.exe.sources delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/smcs.exe.sources-xml delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/y.output create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/BaseRefactoringContext.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeAction.cs rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{ContextAction/AddAnotherAccessor.cs => CodeActions/AddAnotherAccessorAction.cs} (62%) rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{ContextAction/CheckIfParameterIsNull.cs => CodeActions/CheckIfParameterIsNullAction.cs} (55%) rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{ContextAction/ConvertDecToHex.cs => CodeActions/ConvertDecToHexAction.cs} (64%) create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/ConvertForeachToForAction.cs rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{ContextAction/ConvertHexToDec.cs => CodeActions/ConvertHexToDecAction.cs} (61%) create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/CreateBackingStoreAction.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/CreateClassDeclarationAction.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/CreateConstructorDeclarationAction.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/CreateDelegateAction.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/CreateEventInvocatorAction.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/CreateFieldAction.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/CreateIndexerAction.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/CreateLocalVariableAction.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/CreateMethodDeclarationAction.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/CreatePropertyAction.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/DeclareLocalVariableAction.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/ExtractMethod/ExtractMethodAction.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/ExtractMethod/StaticVisitor.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/ExtractMethod/VariableLookupVisitor.cs rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{ContextAction/FlipOperatorArguments.cs => CodeActions/FlipOperatorArgumentsAction.cs} (73%) rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{ContextAction/GenerateGetter.cs => CodeActions/GenerateGetterAction.cs} (75%) create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/GeneratePropertyAction.cs rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{ContextAction/GenerateSwitchLabels.cs => CodeActions/GenerateSwitchLabelsAction.cs} (54%) create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/InlineLocalVariableAction.cs rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{ContextAction/InsertAnonymousMethodSignature.cs => CodeActions/InsertAnonymousMethodSignatureAction.cs} (63%) create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/IntroduceConstantAction.cs rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{ContextAction/IntroduceFormatItem.cs => CodeActions/IntroduceFormatItemAction.cs} (51%) rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{ContextAction/InvertIf.cs => CodeActions/InvertIfAction.cs} (60%) rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{ContextAction/RemoveBackingStore.cs => CodeActions/RemoveBackingStoreAction.cs} (81%) rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{ContextAction/RemoveBraces.cs => CodeActions/RemoveBracesAction.cs} (59%) create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/RemoveRegionAction.cs rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{ContextAction/ReplaceEmptyString.cs => CodeActions/ReplaceEmptyStringAction.cs} (72%) create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeActions/SpecializedCodeAction.cs rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{ContextAction/SplitDeclarationAndAssignment.cs => CodeActions/SplitDeclarationAndAssignmentAction.cs} (53%) rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{ContextAction/SplitString.cs => CodeActions/SplitStringAction.cs} (55%) rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{ContextAction/UseExplicitType.cs => CodeActions/UseExplicitTypeAction.cs} (76%) rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{ContextAction/UseVarKeyword.cs => CodeActions/UseVarKeywordAction.cs} (75%) create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssue.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssues/ConditionalToNullCoalescingIssue.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssues/ExplicitConversionInForEachIssue.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssues/GatherVisitorBase.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssues/InconsistentNamingIssue/AffectedEntity.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssues/InconsistentNamingIssue/DefaultRules.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssues/InconsistentNamingIssue/InconsistentNamingIssue.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssues/InconsistentNamingIssue/NamingConventionService.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssues/InconsistentNamingIssue/NamingRule.cs rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{NodeSelectionAction.cs => CodeIssues/InconsistentNamingIssue/NamingStyle.cs} (71%) create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssues/InconsistentNamingIssue/WordParser.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssues/IssueCategories.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssues/NotImplementedExceptionIssue.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssues/RedundantInternalIssue.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssues/RedundantNamespaceUsageIssue.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssues/RedundantPrivateIssue.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssues/RedundantThisIssue.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssues/RedundantUsingIssue.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssues/StringIsNullOrEmptyIssue.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeIssues/UseVarKeywordIssue.cs delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/ContextAction/ConvertForeachToFor.cs delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/ContextAction/CreateBackingStore.cs delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/ContextAction/CreateEventInvocator.cs delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/ContextAction/CreateField.cs delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/ContextAction/CreateLocalVariable.cs delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/ContextAction/CreateProperty.cs rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/{Ast/IRelocatable.cs => Refactoring/ContextActionAttribute.cs} (73%) create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/DocumentScript.cs delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/FormatTextAction.cs delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/IActionFactory.cs rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{IContextAction.cs => ICodeActionProvider.cs} (88%) rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/{Action.cs => ICodeIssueProvider.cs} (70%) create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/IssueAttribute.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/IssueMarker.cs delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/NodeOutputAction.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/PatternHelper.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/RefactoringAstHelper.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/Severity.cs delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/TextReplaceAction.cs rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Resolver/{Conversions.cs => CSharpConversions.cs} (91%) rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/{Resolver => }/SimpleNameLookupMode.cs (97%) create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/TypeSystem/CSharpDocumentationComment.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory/Documentation/DocumentationComment.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory/Documentation/GetPotentiallyNestedClassTypeReference.cs rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory/{TypeSystem/IAccessor.cs => Documentation/IDocumentationProvider.cs} (53%) create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory/Documentation/IdStringMemberReference.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory/Editor/StringBuilderDocument.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory/Editor/TextSourceVersionProvider.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory/Properties/GlobalAssemblyInfo.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory/Semantics/ForEachResolveResult.cs rename src/Libraries/NewNRefactory/ICSharpCode.NRefactory/{TypeSystem/IDocumentationProvider.cs => Semantics/InitializedObjectResolveResult.cs} (76%) rename src/Libraries/NewNRefactory/{ICSharpCode.NRefactory.CSharp/Resolver/ConversionResolveResult.cs => ICSharpCode.NRefactory/Semantics/TypeIsResolveResult.cs} (70%) create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory/TypeSystem/ComHelper.cs delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory/TypeSystem/Implementation/DefaultResolvedAccessor.cs delete mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory/TypeSystem/Implementation/DefaultUnresolvedAccessor.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory/TypeSystem/Implementation/ExplicitInterfaceImplementationMemberReference.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory/TypeSystem/Implementation/SpecializingMemberReference.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory/Utils/CallbackOnDispose.cs create mode 100644 src/Libraries/NewNRefactory/ICSharpCode.NRefactory/Utils/KeyComparer.cs diff --git a/src/Libraries/ICSharpCode.Decompiler/Ast/AstBuilder.cs b/src/Libraries/ICSharpCode.Decompiler/Ast/AstBuilder.cs index bf647b379d..fc288d80fd 100644 --- a/src/Libraries/ICSharpCode.Decompiler/Ast/AstBuilder.cs +++ b/src/Libraries/ICSharpCode.Decompiler/Ast/AstBuilder.cs @@ -157,15 +157,10 @@ namespace ICSharpCode.Decompiler.Ast if (!transformationsHaveRun) RunTransformations(); - astCompileUnit.AcceptVisitor(new InsertParenthesesVisitor { InsertParenthesesForReadability = true }, null); + astCompileUnit.AcceptVisitor(new InsertParenthesesVisitor { InsertParenthesesForReadability = true }); var outputFormatter = new TextOutputFormatter(output); - var formattingPolicy = new CSharpFormattingOptions(); - // disable whitespace in front of parentheses: - formattingPolicy.SpaceBeforeMethodCallParentheses = false; - formattingPolicy.SpaceBeforeMethodDeclarationParentheses = false; - formattingPolicy.SpaceBeforeConstructorDeclarationParentheses = false; - formattingPolicy.SpaceBeforeDelegateDeclarationParentheses = false; - astCompileUnit.AcceptVisitor(new CSharpOutputVisitor(outputFormatter, formattingPolicy), null); + var formattingPolicy = context.Settings.CSharpFormattingOptions; + astCompileUnit.AcceptVisitor(new CSharpOutputVisitor(outputFormatter, formattingPolicy)); } public void AddAssembly(AssemblyDefinition assemblyDefinition, bool onlyAssemblyLevel = false) @@ -185,7 +180,7 @@ namespace ICSharpCode.Decompiler.Ast } } } - }, AttributedNode.AttributeRole); + }, EntityDeclaration.AttributeRole); } ConvertCustomAttributes(astCompileUnit, assemblyDefinition, "assembly"); @@ -225,7 +220,7 @@ namespace ICSharpCode.Decompiler.Ast Arguments = { forwardedType } } } - }, AttributedNode.AttributeRole); + }, EntityDeclaration.AttributeRole); } } } @@ -283,7 +278,7 @@ namespace ICSharpCode.Decompiler.Ast /// /// /// TypeDeclaration or DelegateDeclaration. - public AttributedNode CreateType(TypeDefinition typeDef) + public EntityDeclaration CreateType(TypeDefinition typeDef) { // create type TypeDefinition oldCurrentType = context.CurrentType; @@ -313,7 +308,7 @@ namespace ICSharpCode.Decompiler.Ast astType.TypeParameters.AddRange(MakeTypeParameters(genericParameters)); astType.Constraints.AddRange(MakeConstraints(genericParameters)); - AttributedNode result = astType; + EntityDeclaration result = astType; if (typeDef.IsEnum) { long expectedEnumMemberValue = 0; bool forcePrintingInitializers = IsFlagsEnum(typeDef); @@ -321,7 +316,7 @@ namespace ICSharpCode.Decompiler.Ast if (!field.IsStatic) { // the value__ field if (field.FieldType != typeDef.Module.TypeSystem.Int32) { - astType.AddChild(ConvertType(field.FieldType), TypeDeclaration.BaseTypeRole); + astType.AddChild(ConvertType(field.FieldType), Roles.BaseType); } } else { EnumMemberDeclaration enumMember = new EnumMemberDeclaration(); @@ -332,7 +327,7 @@ namespace ICSharpCode.Decompiler.Ast enumMember.AddChild(new PrimitiveExpression(field.Constant), EnumMemberDeclaration.InitializerRole); } expectedEnumMemberValue = memberValue + 1; - astType.AddChild(enumMember, TypeDeclaration.MemberRole); + astType.AddChild(enumMember, Roles.TypeMemberRole); } } } else if (typeDef.BaseType != null && typeDef.BaseType.FullName == "System.MulticastDelegate") { @@ -354,10 +349,10 @@ namespace ICSharpCode.Decompiler.Ast } else { // Base type if (typeDef.BaseType != null && !typeDef.IsValueType && typeDef.BaseType.FullName != "System.Object") { - astType.AddChild(ConvertType(typeDef.BaseType), TypeDeclaration.BaseTypeRole); + astType.AddChild(ConvertType(typeDef.BaseType), Roles.BaseType); } foreach (var i in typeDef.Interfaces) - astType.AddChild(ConvertType(i), TypeDeclaration.BaseTypeRole); + astType.AddChild(ConvertType(i), Roles.BaseType); AddTypeMembers(astType, typeDef); @@ -726,18 +721,18 @@ namespace ICSharpCode.Decompiler.Ast continue; var nestedType = CreateType(nestedTypeDef); SetNewModifier(nestedType); - astType.AddChild(nestedType, TypeDeclaration.MemberRole); + astType.AddChild(nestedType, Roles.TypeMemberRole); } // Add fields foreach(FieldDefinition fieldDef in typeDef.Fields) { if (MemberIsHidden(fieldDef, context.Settings)) continue; - astType.AddChild(CreateField(fieldDef), TypeDeclaration.MemberRole); + astType.AddChild(CreateField(fieldDef), Roles.TypeMemberRole); } // Add events foreach(EventDefinition eventDef in typeDef.Events) { - astType.AddChild(CreateEvent(eventDef), TypeDeclaration.MemberRole); + astType.AddChild(CreateEvent(eventDef), Roles.TypeMemberRole); } // Add properties @@ -756,7 +751,7 @@ namespace ICSharpCode.Decompiler.Ast } } - AttributedNode CreateMethod(MethodDefinition methodDef) + EntityDeclaration CreateMethod(MethodDefinition methodDef) { MethodDeclaration astMethod = new MethodDeclaration(); astMethod.AddAnnotation(methodDef); @@ -860,7 +855,7 @@ namespace ICSharpCode.Decompiler.Ast astMethod.Body = CreateMethodBody(methodDef, astMethod.Parameters); ConvertAttributes(astMethod, methodDef); if (methodDef.IsStatic && methodDef.DeclaringType.IsBeforeFieldInit && !astMethod.Body.IsNull) { - astMethod.Body.InsertChildAfter(null, new Comment(" Note: this type is marked as 'beforefieldinit'."), AstNode.Roles.Comment); + astMethod.Body.InsertChildAfter(null, new Comment(" Note: this type is marked as 'beforefieldinit'."), Roles.Comment); } return astMethod; } @@ -878,7 +873,7 @@ namespace ICSharpCode.Decompiler.Ast return m & ~Modifiers.Private; } - MemberDeclaration CreateProperty(PropertyDefinition propDef) + EntityDeclaration CreateProperty(PropertyDefinition propDef) { PropertyDeclaration astProp = new PropertyDeclaration(); astProp.AddAnnotation(propDef); @@ -937,7 +932,7 @@ namespace ICSharpCode.Decompiler.Ast } ConvertCustomAttributes(astProp, propDef); - MemberDeclaration member = astProp; + EntityDeclaration member = astProp; if(propDef.IsIndexer()) member = ConvertPropertyToIndexer(astProp, propDef); if(!accessor.HasOverrides && !accessor.DeclaringType.IsInterface) @@ -960,7 +955,7 @@ namespace ICSharpCode.Decompiler.Ast return astIndexer; } - AttributedNode CreateEvent(EventDefinition eventDef) + EntityDeclaration CreateEvent(EventDefinition eventDef) { if (eventDef.AddMethod != null && eventDef.AddMethod.IsAbstract) { // An abstract event cannot be custom @@ -1018,7 +1013,7 @@ namespace ICSharpCode.Decompiler.Ast FieldDeclaration astField = new FieldDeclaration(); astField.AddAnnotation(fieldDef); VariableInitializer initializer = new VariableInitializer(CleanName(fieldDef.Name)); - astField.AddChild(initializer, FieldDeclaration.Roles.Variable); + astField.AddChild(initializer, Roles.Variable); astField.ReturnType = ConvertType(fieldDef.FieldType, fieldDef); astField.Modifiers = ConvertModifiers(fieldDef); if (fieldDef.HasConstant) { @@ -1098,7 +1093,7 @@ namespace ICSharpCode.Decompiler.Ast } #region ConvertAttributes - void ConvertAttributes(AttributedNode attributedNode, TypeDefinition typeDefinition) + void ConvertAttributes(EntityDeclaration attributedNode, TypeDefinition typeDefinition) { ConvertCustomAttributes(attributedNode, typeDefinition); ConvertSecurityAttributes(attributedNode, typeDefinition); @@ -1154,7 +1149,7 @@ namespace ICSharpCode.Decompiler.Ast #endregion } - void ConvertAttributes(AttributedNode attributedNode, MethodDefinition methodDefinition) + void ConvertAttributes(EntityDeclaration attributedNode, MethodDefinition methodDefinition) { ConvertCustomAttributes(attributedNode, methodDefinition); ConvertSecurityAttributes(attributedNode, methodDefinition); @@ -1254,7 +1249,7 @@ namespace ICSharpCode.Decompiler.Ast ConvertAttributes(attributedNode, methodDefinition.MethodReturnType, methodDefinition.Module); } - void ConvertAttributes(AttributedNode attributedNode, MethodReturnType methodReturnType, ModuleDefinition module) + void ConvertAttributes(EntityDeclaration attributedNode, MethodReturnType methodReturnType, ModuleDefinition module) { ConvertCustomAttributes(attributedNode, methodReturnType, "return"); if (methodReturnType.HasMarshalInfo) { @@ -1263,7 +1258,7 @@ namespace ICSharpCode.Decompiler.Ast } } - internal static void ConvertAttributes(AttributedNode attributedNode, FieldDefinition fieldDefinition, string attributeTarget = null) + internal static void ConvertAttributes(EntityDeclaration attributedNode, FieldDefinition fieldDefinition, string attributeTarget = null) { ConvertCustomAttributes(attributedNode, fieldDefinition); @@ -1402,14 +1397,14 @@ namespace ICSharpCode.Decompiler.Ast var section = new AttributeSection(); section.AttributeTarget = attributeTarget; section.Attributes.Add(attribute); - attributedNode.AddChild(section, AttributedNode.AttributeRole); + attributedNode.AddChild(section, EntityDeclaration.AttributeRole); } } else if (attributes.Count > 0) { // use single section for all attributes var section = new AttributeSection(); section.AttributeTarget = attributeTarget; section.Attributes.AddRange(attributes); - attributedNode.AddChild(section, AttributedNode.AttributeRole); + attributedNode.AddChild(section, EntityDeclaration.AttributeRole); } } } @@ -1462,14 +1457,14 @@ namespace ICSharpCode.Decompiler.Ast var section = new AttributeSection(); section.AttributeTarget = attributeTarget; section.Attributes.Add(attribute); - attributedNode.AddChild(section, AttributedNode.AttributeRole); + attributedNode.AddChild(section, EntityDeclaration.AttributeRole); } } else if (attributes.Count > 0) { // use single section for all attributes var section = new AttributeSection(); section.AttributeTarget = attributeTarget; section.Attributes.AddRange(attributes); - attributedNode.AddChild(section, AttributedNode.AttributeRole); + attributedNode.AddChild(section, EntityDeclaration.AttributeRole); } } @@ -1594,7 +1589,7 @@ namespace ICSharpCode.Decompiler.Ast /// Sets new modifier if the member hides some other member from a base type. /// /// The node of the member which new modifier state should be determined. - static void SetNewModifier(AttributedNode member) + static void SetNewModifier(EntityDeclaration member) { try { bool addNewModifier = false; @@ -1614,7 +1609,7 @@ namespace ICSharpCode.Decompiler.Ast } } - private static bool HidesBaseMember(AttributedNode member) + private static bool HidesBaseMember(EntityDeclaration member) { var memberDefinition = member.Annotation(); bool addNewModifier = false; diff --git a/src/Libraries/ICSharpCode.Decompiler/Ast/AstMethodBodyBuilder.cs b/src/Libraries/ICSharpCode.Decompiler/Ast/AstMethodBodyBuilder.cs index 7b051c50df..5de5b0ba5a 100644 --- a/src/Libraries/ICSharpCode.Decompiler/Ast/AstMethodBodyBuilder.cs +++ b/src/Libraries/ICSharpCode.Decompiler/Ast/AstMethodBodyBuilder.cs @@ -543,12 +543,15 @@ namespace ICSharpCode.Decompiler.Ast } return arg1; } - case ILCode.Castclass: - return arg1.CastTo(operandAsTypeRef); case ILCode.Unbox_Any: // unboxing does not require a cast if the argument was an isinst instruction if (arg1 is AsExpression && byteCode.Arguments[0].Code == ILCode.Isinst && TypeAnalysis.IsSameType(operand as TypeReference, byteCode.Arguments[0].Operand as TypeReference)) return arg1; + else + goto case ILCode.Castclass; + case ILCode.Castclass: + if ((byteCode.Arguments[0].InferredType != null && byteCode.Arguments[0].InferredType.IsGenericParameter) || ((Cecil.TypeReference)operand).IsGenericParameter) + return arg1.CastTo(new PrimitiveType("object")).CastTo(operandAsTypeRef); else return arg1.CastTo(operandAsTypeRef); case ILCode.Isinst: diff --git a/src/Libraries/ICSharpCode.Decompiler/Ast/CommentStatement.cs b/src/Libraries/ICSharpCode.Decompiler/Ast/CommentStatement.cs index 0940c6c5c7..6837b2418f 100644 --- a/src/Libraries/ICSharpCode.Decompiler/Ast/CommentStatement.cs +++ b/src/Libraries/ICSharpCode.Decompiler/Ast/CommentStatement.cs @@ -38,6 +38,15 @@ namespace ICSharpCode.Decompiler.Ast this.comment = comment; } + public override void AcceptVisitor(IAstVisitor visitor) + { + } + + public override T AcceptVisitor(IAstVisitor visitor) + { + return default(T); + } + public override S AcceptVisitor(IAstVisitor visitor, T data) { return default(S); diff --git a/src/Libraries/ICSharpCode.Decompiler/Ast/TextOutputFormatter.cs b/src/Libraries/ICSharpCode.Decompiler/Ast/TextOutputFormatter.cs index 26bd784e2f..85fef513ee 100644 --- a/src/Libraries/ICSharpCode.Decompiler/Ast/TextOutputFormatter.cs +++ b/src/Libraries/ICSharpCode.Decompiler/Ast/TextOutputFormatter.cs @@ -82,7 +82,7 @@ namespace ICSharpCode.Decompiler.Ast { AstNode node = nodeStack.Peek(); MemberReference memberRef = node.Annotation(); - if (memberRef == null && node.Role == AstNode.Roles.TargetExpression && (node.Parent is InvocationExpression || node.Parent is ObjectCreateExpression)) { + if (memberRef == null && node.Role == Roles.TargetExpression && (node.Parent is InvocationExpression || node.Parent is ObjectCreateExpression)) { memberRef = node.Parent.Annotation(); } return memberRef; @@ -168,7 +168,7 @@ namespace ICSharpCode.Decompiler.Ast // Attach member reference to token only if there's no identifier in the current node. MemberReference memberRef = GetCurrentMemberReference(); var node = nodeStack.Peek(); - if (memberRef != null && node.GetChildByRole(AstNode.Roles.Identifier).IsNull) + if (memberRef != null && node.GetChildByRole(Roles.Identifier).IsNull) output.WriteReference(token, memberRef); else output.Write(token); @@ -282,7 +282,7 @@ namespace ICSharpCode.Decompiler.Ast nodeStack.Push(node); startLocations.Push(output.Location); - if (node is AttributedNode && node.GetChildByRole(AstNode.Roles.Identifier).IsNull) + if (node is EntityDeclaration && node.Annotation() != null && node.GetChildByRole(Roles.Identifier).IsNull) output.WriteDefinition("", node.Annotation(), false); MemberMapping mapping = node.Annotation(); @@ -330,15 +330,7 @@ namespace ICSharpCode.Decompiler.Ast private static bool IsDefinition(AstNode node) { - return - node is FieldDeclaration || - node is ConstructorDeclaration || - node is DestructorDeclaration || - node is EventDeclaration || - node is DelegateDeclaration || - node is OperatorDeclaration|| - node is MemberDeclaration || - node is TypeDeclaration; + return node is EntityDeclaration; } } } diff --git a/src/Libraries/ICSharpCode.Decompiler/Ast/Transforms/ConvertConstructorCallIntoInitializer.cs b/src/Libraries/ICSharpCode.Decompiler/Ast/Transforms/ConvertConstructorCallIntoInitializer.cs index 4976a759bb..36811c1852 100644 --- a/src/Libraries/ICSharpCode.Decompiler/Ast/Transforms/ConvertConstructorCallIntoInitializer.cs +++ b/src/Libraries/ICSharpCode.Decompiler/Ast/Transforms/ConvertConstructorCallIntoInitializer.cs @@ -123,7 +123,7 @@ namespace ICSharpCode.Decompiler.Ast.Transforms if (allSame) { foreach (var ctor in instanceCtorsNotChainingWithThis) ctor.Body.First().Remove(); - fieldOrEventDecl.GetChildrenByRole(AstNode.Roles.Variable).Single().Initializer = initializer.Detach(); + fieldOrEventDecl.GetChildrenByRole(Roles.Variable).Single().Initializer = initializer.Detach(); } } while (allSame); } diff --git a/src/Libraries/ICSharpCode.Decompiler/Ast/Transforms/IntroduceUnsafeModifier.cs b/src/Libraries/ICSharpCode.Decompiler/Ast/Transforms/IntroduceUnsafeModifier.cs index dc7e7f1a5a..43548e38d4 100644 --- a/src/Libraries/ICSharpCode.Decompiler/Ast/Transforms/IntroduceUnsafeModifier.cs +++ b/src/Libraries/ICSharpCode.Decompiler/Ast/Transforms/IntroduceUnsafeModifier.cs @@ -38,8 +38,8 @@ namespace ICSharpCode.Decompiler.Ast.Transforms for (AstNode child = node.FirstChild; child != null; child = child.NextSibling) { result |= child.AcceptVisitor(this, data); } - if (result && node is AttributedNode && !(node is Accessor)) { - ((AttributedNode)node).Modifiers |= Modifiers.Unsafe; + if (result && node is EntityDeclaration && !(node is Accessor)) { + ((EntityDeclaration)node).Modifiers |= Modifiers.Unsafe; return false; } return result; diff --git a/src/Libraries/ICSharpCode.Decompiler/Ast/Transforms/ReplaceMethodCallsWithOperators.cs b/src/Libraries/ICSharpCode.Decompiler/Ast/Transforms/ReplaceMethodCallsWithOperators.cs index 4561da8176..6a3f8f9743 100644 --- a/src/Libraries/ICSharpCode.Decompiler/Ast/Transforms/ReplaceMethodCallsWithOperators.cs +++ b/src/Libraries/ICSharpCode.Decompiler/Ast/Transforms/ReplaceMethodCallsWithOperators.cs @@ -140,7 +140,7 @@ namespace ICSharpCode.Decompiler.Ast.Transforms invocationExpression.ReplaceWith(arguments[0]); return; } - if (methodRef.Name == "op_True" && arguments.Length == 1 && invocationExpression.Role == AstNode.Roles.Condition) { + if (methodRef.Name == "op_True" && arguments.Length == 1 && invocationExpression.Role == Roles.Condition) { invocationExpression.ReplaceWith(arguments[0]); return; } diff --git a/src/Libraries/ICSharpCode.Decompiler/CecilExtensions.cs b/src/Libraries/ICSharpCode.Decompiler/CecilExtensions.cs index 82b67a07f4..cc047e09cd 100644 --- a/src/Libraries/ICSharpCode.Decompiler/CecilExtensions.cs +++ b/src/Libraries/ICSharpCode.Decompiler/CecilExtensions.cs @@ -133,6 +133,8 @@ namespace ICSharpCode.Decompiler /// public static int GetEndOffset(this Instruction inst) { + if (inst == null) + throw new ArgumentNullException("inst"); return inst.Offset + inst.GetSize(); } diff --git a/src/Libraries/ICSharpCode.Decompiler/DecompilerSettings.cs b/src/Libraries/ICSharpCode.Decompiler/DecompilerSettings.cs index 05a598520e..435124491c 100644 --- a/src/Libraries/ICSharpCode.Decompiler/DecompilerSettings.cs +++ b/src/Libraries/ICSharpCode.Decompiler/DecompilerSettings.cs @@ -18,6 +18,7 @@ using System; using System.ComponentModel; +using ICSharpCode.NRefactory.CSharp; namespace ICSharpCode.Decompiler { @@ -271,6 +272,26 @@ namespace ICSharpCode.Decompiler } #endregion + CSharpFormattingOptions csharpFormattingOptions; + + public CSharpFormattingOptions CSharpFormattingOptions { + get { + if (csharpFormattingOptions == null) { + csharpFormattingOptions = FormattingOptionsFactory.CreateAllman(); + csharpFormattingOptions.IndentSwitchBody = false; + } + return csharpFormattingOptions; + } + set { + if (value == null) + throw new ArgumentNullException(); + if (csharpFormattingOptions != value) { + csharpFormattingOptions = value; + OnPropertyChanged("CSharpFormattingOptions"); + } + } + } + public event PropertyChangedEventHandler PropertyChanged; protected virtual void OnPropertyChanged(string propertyName) @@ -283,6 +304,8 @@ namespace ICSharpCode.Decompiler public DecompilerSettings Clone() { DecompilerSettings settings = (DecompilerSettings)MemberwiseClone(); + if (csharpFormattingOptions != null) + settings.csharpFormattingOptions = csharpFormattingOptions.Clone(); settings.PropertyChanged = null; return settings; } diff --git a/src/Libraries/ICSharpCode.Decompiler/Disassembler/ReflectionDisassembler.cs b/src/Libraries/ICSharpCode.Decompiler/Disassembler/ReflectionDisassembler.cs index 413234e77f..675d9e28a0 100644 --- a/src/Libraries/ICSharpCode.Decompiler/Disassembler/ReflectionDisassembler.cs +++ b/src/Libraries/ICSharpCode.Decompiler/Disassembler/ReflectionDisassembler.cs @@ -809,6 +809,7 @@ namespace ICSharpCode.Decompiler.Disassembler { TypeAttributes.SpecialName, "specialname" }, { TypeAttributes.Import, "import" }, { TypeAttributes.Serializable, "serializable" }, + { TypeAttributes.WindowsRuntime, "windowsruntime" }, { TypeAttributes.BeforeFieldInit, "beforefieldinit" }, { TypeAttributes.HasSecurity, null }, }; @@ -1075,7 +1076,10 @@ namespace ICSharpCode.Decompiler.Disassembler public void WriteAssemblyHeader(AssemblyDefinition asm) { - output.Write(".assembly " + DisassemblerHelpers.Escape(asm.Name.Name)); + output.Write(".assembly "); + if (asm.Name.IsWindowsRuntime) + output.Write("windowsruntime "); + output.Write(DisassemblerHelpers.Escape(asm.Name.Name)); OpenBlock(false); WriteAttributes(asm.CustomAttributes); WriteSecurityDeclarations(asm); @@ -1103,7 +1107,10 @@ namespace ICSharpCode.Decompiler.Disassembler output.WriteLine(".module extern {0}", DisassemblerHelpers.Escape(mref.Name)); } foreach (var aref in module.AssemblyReferences) { - output.Write(".assembly extern {0}", DisassemblerHelpers.Escape(aref.Name)); + output.Write(".assembly extern "); + if (aref.IsWindowsRuntime) + output.Write("windowsruntime "); + output.Write(DisassemblerHelpers.Escape(aref.Name)); OpenBlock(false); if (aref.PublicKeyToken != null) { output.Write(".publickeytoken = "); diff --git a/src/Libraries/ICSharpCode.Decompiler/FlowAnalysis/ControlFlowNode.cs b/src/Libraries/ICSharpCode.Decompiler/FlowAnalysis/ControlFlowNode.cs index 606b43286b..cab507bc95 100644 --- a/src/Libraries/ICSharpCode.Decompiler/FlowAnalysis/ControlFlowNode.cs +++ b/src/Libraries/ICSharpCode.Decompiler/FlowAnalysis/ControlFlowNode.cs @@ -253,8 +253,11 @@ namespace ICSharpCode.Decompiler.FlowAnalysis StringWriter writer = new StringWriter(); switch (NodeType) { case ControlFlowNodeType.Normal: - int endOffset = End.GetEndOffset(); - writer.Write("Block #{0}: IL_{1:x4} to IL_{2:x4}", BlockIndex, Start.Offset, endOffset); + writer.Write("Block #{0}", BlockIndex); + if (Start != null) + writer.Write(": IL_{0:x4}", Start.Offset); + if (End != null) + writer.Write(" to IL_{0:x4}", End.GetEndOffset()); break; case ControlFlowNodeType.CatchHandler: case ControlFlowNodeType.FinallyOrFaultHandler: @@ -277,6 +280,10 @@ namespace ICSharpCode.Decompiler.FlowAnalysis writer.WriteLine(); Disassembler.DisassemblerHelpers.WriteTo(inst, new PlainTextOutput(writer)); } + if (UserData != null) { + writer.WriteLine(); + writer.Write(UserData.ToString()); + } return writer.ToString(); } diff --git a/src/Libraries/ICSharpCode.Decompiler/ILAst/LoopsAndConditions.cs b/src/Libraries/ICSharpCode.Decompiler/ILAst/LoopsAndConditions.cs index e5409a2e58..32095b03eb 100644 --- a/src/Libraries/ICSharpCode.Decompiler/ILAst/LoopsAndConditions.cs +++ b/src/Libraries/ICSharpCode.Decompiler/ILAst/LoopsAndConditions.cs @@ -101,7 +101,7 @@ namespace ICSharpCode.Decompiler.ILAst // Find all branches foreach(ILLabel target in node.GetSelfAndChildrenRecursive(e => e.IsBranch()).SelectMany(e => e.GetBranchTargets())) { ControlFlowNode destination; - // Labels which are out of out scope will not be int the collection + // Labels which are out of out scope will not be in the collection // Insert self edge only if we are sure we are a loop if (labelToCfNode.TryGetValue(target, out destination) && (destination != source || target == node.Body.FirstOrDefault())) { ControlFlowEdge edge = new ControlFlowEdge(source, destination, JumpType.Normal); @@ -228,15 +228,10 @@ namespace ICSharpCode.Decompiler.ILAst // Do not modify entry data scope = new HashSet(scope); - HashSet agenda = new HashSet(); - agenda.Add(entryNode); - while(agenda.Any()) { - ControlFlowNode node = agenda.First(); - // Attempt for a good order - while(agenda.Contains(node.ImmediateDominator)) { - node = node.ImmediateDominator; - } - agenda.Remove(node); + Stack agenda = new Stack(); + agenda.Push(entryNode); + while(agenda.Count > 0) { + ControlFlowNode node = agenda.Pop(); // Find a block that represents a simple condition if (scope.Contains(node)) { @@ -364,18 +359,12 @@ namespace ICSharpCode.Decompiler.ILAst labelToCfNode.TryGetValue(falseLabel, out falseTarget); // Pull in the conditional code - HashSet frontiers = new HashSet(); - if (trueTarget != null) - frontiers.UnionWith(trueTarget.DominanceFrontier.Except(new [] { trueTarget })); - if (falseTarget != null) - frontiers.UnionWith(falseTarget.DominanceFrontier.Except(new [] { falseTarget })); - - if (trueTarget != null && !frontiers.Contains(trueTarget)) { + if (trueTarget != null && HasSingleEdgeEnteringBlock(trueTarget)) { HashSet content = FindDominatedNodes(scope, trueTarget); scope.ExceptWith(content); ilCond.TrueBlock.Body.AddRange(FindConditions(content, trueTarget)); } - if (falseTarget != null && !frontiers.Contains(falseTarget)) { + if (falseTarget != null && HasSingleEdgeEnteringBlock(falseTarget)) { HashSet content = FindDominatedNodes(scope, falseTarget); scope.ExceptWith(content); ilCond.FalseBlock.Body.AddRange(FindConditions(content, falseTarget)); @@ -390,9 +379,9 @@ namespace ICSharpCode.Decompiler.ILAst } } - // Using the dominator tree should ensure we find the the widest loop first - foreach(var child in node.DominatorTreeChildren) { - agenda.Add(child); + // depth-first traversal of dominator tree + for (int i = node.DominatorTreeChildren.Count - 1; i >= 0; i--) { + agenda.Push(node.DominatorTreeChildren[i]); } } @@ -404,6 +393,11 @@ namespace ICSharpCode.Decompiler.ILAst return result; } + static bool HasSingleEdgeEnteringBlock(ControlFlowNode node) + { + return node.Incoming.Count(edge => !node.Dominates(edge.Source)) == 1; + } + static HashSet FindDominatedNodes(HashSet scope, ControlFlowNode head) { HashSet agenda = new HashSet(); diff --git a/src/Libraries/ICSharpCode.Decompiler/ILAst/TypeAnalysis.cs b/src/Libraries/ICSharpCode.Decompiler/ILAst/TypeAnalysis.cs index b2af46d975..6e8444a1ca 100644 --- a/src/Libraries/ICSharpCode.Decompiler/ILAst/TypeAnalysis.cs +++ b/src/Libraries/ICSharpCode.Decompiler/ILAst/TypeAnalysis.cs @@ -985,12 +985,24 @@ namespace ICSharpCode.Decompiler.ILAst InferTypeForExpression(right, typeSystem.IntPtr); return leftPreferred; } + if (IsEnum(leftPreferred)) { + //E+U=E + left.InferredType = left.ExpectedType = leftPreferred; + InferTypeForExpression(right, GetEnumUnderlyingType(leftPreferred)); + return leftPreferred; + } TypeReference rightPreferred = DoInferTypeForExpression(right, expectedType); if (rightPreferred is PointerType) { InferTypeForExpression(left, typeSystem.IntPtr); right.InferredType = right.ExpectedType = rightPreferred; return rightPreferred; } + if (IsEnum(rightPreferred)) { + //U+E=E + right.InferredType = right.ExpectedType = rightPreferred; + InferTypeForExpression(left, GetEnumUnderlyingType(rightPreferred)); + return rightPreferred; + } return InferBinaryArguments(left, right, expectedType, leftPreferred: leftPreferred, rightPreferred: rightPreferred); } @@ -1004,6 +1016,19 @@ namespace ICSharpCode.Decompiler.ILAst InferTypeForExpression(right, typeSystem.IntPtr); return leftPreferred; } + if (IsEnum(leftPreferred)) { + if (expectedType != null && IsEnum(expectedType)) { + // E-U=E + left.InferredType = left.ExpectedType = leftPreferred; + InferTypeForExpression(right, GetEnumUnderlyingType(leftPreferred)); + return leftPreferred; + } else { + // E-E=U + left.InferredType = left.ExpectedType = leftPreferred; + InferTypeForExpression(right, leftPreferred); + return GetEnumUnderlyingType(leftPreferred); + } + } return InferBinaryArguments(left, right, expectedType, leftPreferred: leftPreferred); } diff --git a/src/Libraries/ICSharpCode.Decompiler/Properties/AssemblyInfo.cs b/src/Libraries/ICSharpCode.Decompiler/Properties/AssemblyInfo.cs index 0deae79817..9260b6ba55 100644 --- a/src/Libraries/ICSharpCode.Decompiler/Properties/AssemblyInfo.cs +++ b/src/Libraries/ICSharpCode.Decompiler/Properties/AssemblyInfo.cs @@ -19,8 +19,8 @@ using System.Runtime.InteropServices; // If you need to expose a type to COM, use [ComVisible(true)] on that type. [assembly: ComVisible(false)] -[assembly: AssemblyVersion("2.0.0.1489")] -[assembly: AssemblyInformationalVersion("2.0.0.1489-774e3cd8")] +[assembly: AssemblyVersion("2.0.0.1595")] +[assembly: AssemblyInformationalVersion("2.0.0.1595-5773d3d2")] [assembly: NeutralResourcesLanguage("en-US")] [assembly: System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2243:AttributeStringLiteralsShouldParseCorrectly", diff --git a/src/Libraries/ICSharpCode.Decompiler/Tests/ControlFlow.cs b/src/Libraries/ICSharpCode.Decompiler/Tests/ControlFlow.cs new file mode 100644 index 0000000000..76038f1254 --- /dev/null +++ b/src/Libraries/ICSharpCode.Decompiler/Tests/ControlFlow.cs @@ -0,0 +1,81 @@ +// Copyright (c) AlphaSierraPapa for the SharpDevelop Team +// +// Permission is hereby granted, free of charge, to any person obtaining a copy of this +// software and associated documentation files (the "Software"), to deal in the Software +// without restriction, including without limitation the rights to use, copy, modify, merge, +// publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons +// to whom the Software is furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in all copies or +// substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, +// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR +// PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE +// FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +// DEALINGS IN THE SOFTWARE. + +using System; +using System.Collections.Generic; + +public static class ControlFlow +{ + public static void EmptyIf(string input, List value, Dictionary _headers) + { + if (value.Contains("test")) + { + } + _headers.Add(2, "result"); + } + + public static void NormalIf(string input, List value, Dictionary _headers) + { + if (value.Contains("test")) + { + _headers.Add(1, "result"); + } + else + { + _headers.Add(1, "else"); + } + _headers.Add(2, "end"); + } + + public static void NormalIf2(string input, List value, Dictionary _headers) + { + if (value.Contains("test")) + { + _headers.Add(1, "result"); + } + _headers.Add(2, "end"); + } + + public static void NormalIf3(string input, List value, Dictionary _headers) + { + if (value.Contains("test")) + { + _headers.Add(1, "result"); + } + else + { + _headers.Add(1, "else"); + } + } + + public static void Test(string input, List value, Dictionary _headers) + { + foreach (string current in value) + { + _headers.Add(0, current); + } + if (value.Contains("test")) + { + _headers.Add(1, "result"); + } + else + { + _headers.Add(1, "else"); + } + } +} diff --git a/src/Libraries/ICSharpCode.Decompiler/Tests/Generics.cs b/src/Libraries/ICSharpCode.Decompiler/Tests/Generics.cs index 5adb934c68..9776d42f34 100644 --- a/src/Libraries/ICSharpCode.Decompiler/Tests/Generics.cs +++ b/src/Libraries/ICSharpCode.Decompiler/Tests/Generics.cs @@ -107,4 +107,59 @@ public static class Generics // Tests references to inner classes in generic classes return d.Keys.GetEnumerator(); } + + public static bool IsString(T input) + { + return input is string; + } + + public static string AsString(T input) + { + return input as string; + } + + public static string CastToString(T input) + { + return (string)((object)input); + } + + public static T CastFromString(string input) + { + return (T)((object)input); + } + + public static bool IsInt(T input) + { + return input is int; + } + + public static int CastToInt(T input) + { + return (int)((object)input); + } + + public static T CastFromInt(int input) + { + return (T)((object)input); + } + + public static bool IsNullableInt(T input) + { + return input is int?; + } + + public static int? AsNullableInt(T input) + { + return input as int?; + } + + public static int? CastToNullableInt(T input) + { + return (int?)((object)input); + } + + public static T CastFromNullableInt(int? input) + { + return (T)((object)input); + } } diff --git a/src/Libraries/ICSharpCode.Decompiler/Tests/Helpers/RemoveCompilerAttribute.cs b/src/Libraries/ICSharpCode.Decompiler/Tests/Helpers/RemoveCompilerAttribute.cs index 2519165578..cb65620242 100644 --- a/src/Libraries/ICSharpCode.Decompiler/Tests/Helpers/RemoveCompilerAttribute.cs +++ b/src/Libraries/ICSharpCode.Decompiler/Tests/Helpers/RemoveCompilerAttribute.cs @@ -15,7 +15,7 @@ namespace ICSharpCode.Decompiler.Tests.Helpers var section = (AttributeSection)attribute.Parent; SimpleType type = attribute.Type as SimpleType; if (section.AttributeTarget == "assembly" && - (type.Identifier == "CompilationRelaxations" || type.Identifier == "RuntimeCompatibility" || type.Identifier == "SecurityPermission" || type.Identifier == "AssemblyVersion")) + (type.Identifier == "CompilationRelaxations" || type.Identifier == "RuntimeCompatibility" || type.Identifier == "SecurityPermission" || type.Identifier == "AssemblyVersion" || type.Identifier == "Debuggable")) { attribute.Remove(); if (section.Attributes.Count == 0) diff --git a/src/Libraries/ICSharpCode.Decompiler/Tests/ICSharpCode.Decompiler.Tests.csproj b/src/Libraries/ICSharpCode.Decompiler/Tests/ICSharpCode.Decompiler.Tests.csproj index c42f043393..52a4f950da 100644 --- a/src/Libraries/ICSharpCode.Decompiler/Tests/ICSharpCode.Decompiler.Tests.csproj +++ b/src/Libraries/ICSharpCode.Decompiler/Tests/ICSharpCode.Decompiler.Tests.csproj @@ -64,7 +64,10 @@ + + + @@ -77,6 +80,10 @@ + + + + @@ -117,10 +124,11 @@ ICSharpCode.Decompiler - + + + - \ No newline at end of file diff --git a/src/Libraries/ICSharpCode.Decompiler/Tests/IL/ILTests.cs b/src/Libraries/ICSharpCode.Decompiler/Tests/IL/ILTests.cs new file mode 100644 index 0000000000..3cfed30f22 --- /dev/null +++ b/src/Libraries/ICSharpCode.Decompiler/Tests/IL/ILTests.cs @@ -0,0 +1,51 @@ +// Copyright (c) AlphaSierraPapa for the SharpDevelop Team +// +// Permission is hereby granted, free of charge, to any person obtaining a copy of this +// software and associated documentation files (the "Software"), to deal in the Software +// without restriction, including without limitation the rights to use, copy, modify, merge, +// publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons +// to whom the Software is furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in all copies or +// substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, +// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR +// PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE +// FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +// DEALINGS IN THE SOFTWARE. + +using System; +using System.IO; +using ICSharpCode.Decompiler.Ast; +using ICSharpCode.Decompiler.Tests.Helpers; +using Mono.Cecil; +using NUnit.Framework; + +namespace ICSharpCode.Decompiler.Tests +{ + [TestFixture] + public class ILTests + { + const string path = "../../Tests/IL"; + + [Test] + public void SequenceOfNestedIfs() + { + Run("SequenceOfNestedIfs.dll", "SequenceOfNestedIfs.Output.cs"); + } + + void Run(string compiledFile, string expectedOutputFile) + { + string expectedOutput = File.ReadAllText(Path.Combine(path, expectedOutputFile)); + var assembly = AssemblyDefinition.ReadAssembly(Path.Combine(path, compiledFile)); + AstBuilder decompiler = new AstBuilder(new DecompilerContext(assembly.MainModule)); + decompiler.AddAssembly(assembly); + new Helpers.RemoveCompilerAttribute().Run(decompiler.CompilationUnit); + StringWriter output = new StringWriter(); + decompiler.GenerateCode(new PlainTextOutput(output)); + CodeAssert.AreEqual(expectedOutput, output.ToString()); + } + } +} diff --git a/src/Libraries/ICSharpCode.Decompiler/Tests/IL/SequenceOfNestedIfs.Output.cs b/src/Libraries/ICSharpCode.Decompiler/Tests/IL/SequenceOfNestedIfs.Output.cs new file mode 100644 index 0000000000..754d7dafdc --- /dev/null +++ b/src/Libraries/ICSharpCode.Decompiler/Tests/IL/SequenceOfNestedIfs.Output.cs @@ -0,0 +1,53 @@ +using System; +[Serializable] +public class Material +{ + public static implicit operator bool(Material m) + { + return m == null; + } +} +[Serializable] +public class SequenceOfNestedIfs +{ + public bool _clear; + public Material _material; + public override bool CheckShader() + { + return false; + } + public override void CreateMaterials() + { + if (!this._clear) + { + if (!this.CheckShader()) + { + return; + } + this._material = new Material(); + } + if (!this._material) + { + if (!this.CheckShader()) + { + return; + } + this._material = new Material(); + } + if (!this._material) + { + if (!this.CheckShader()) + { + return; + } + this._material = new Material(); + } + if (!this._material) + { + if (this.CheckShader()) + { + this._material = new Material(); + } + } + } +} diff --git a/src/Libraries/ICSharpCode.Decompiler/Tests/IL/SequenceOfNestedIfs.dll b/src/Libraries/ICSharpCode.Decompiler/Tests/IL/SequenceOfNestedIfs.dll new file mode 100644 index 0000000000000000000000000000000000000000..f517d4546d31c69b00e806950d055a6af4afebda GIT binary patch literal 2560 zcmeHI%}Z2K6#u<9I*giPVP*w+WfEc*4?~NJh{;jX@{2~ZLb5k+uKMbIOn2T`CPnl` zL4>Q?v}qH8v??f~MXPrG4=(xxS_fI@ym?b&LRi~6ynD|1opbKF=iCq8@YyBA0MyX< z_6>MLk|`bX-?JO!ZfbwqgjaPRJKktRA3Mh9?4l?re^!~UuuRYM1Cf(Ll{{g4qHi=S zTt6?3#>V>HQR=aNU`W%keCyt5WwjOP9SvFo5GRXXwl?tuK_g9rnIJ(vuA8YMah^al zCx-MLpgH`0$_Vl#qIXH)$HHaPTAl_rt+i|n2_R7wnIJq+g^fU72?)1v;pD6Cl~70m zIBzKF_*PUyn#|l=bz*{K?j`Y8^qKl+;@Wi7LUaI6Xbmm2{yE#F@1fcCsaCyZRZCS+ zeQSzR#kv~tJW8oA(h4<)b`sQm+JpF^T2c=@U|b|u{2HaH(HEI>#`wBWbK{}=Hy%p2 zuDXC!Z}xbv7VQS#gZUn#%joXv-g}S$?UzHmjp|Ka2X2#mPdJ$klB$>#hO>PD17<}pMMr-*j$R55^mb_E66vu{=bsm&4 zl5wO^PgiOJBcZ+Qqvi&FA+CbsD^!a@MFkEI`}vY1k085H z45VwEEO~+LN+aXD1>2D-E7iPh$s!^L+s(kv*^V7791Z9+a-~4RumWF2IWU^LAgusd zd8s5lOODQrNXnfboGHRBTE24Z9EQz6D%*767p4c@f@52D02kAiBTa>Ax8lysN$X;E z&df`NjFM!o%na`UVj}G2#L~XbGvYx1@>jLE<7M|Vwrh#kSEo*G?^(HD3r*jW(Bpb6 zz9m5(eHWk5xZXOc%)*H8^ { { "CompilerVersion", "v4.0" } }); CompilerParameters options = new CompilerParameters(); - options.CompilerOptions = "/unsafe /o" + (optimize ? "+" : "-"); + options.CompilerOptions = "/unsafe /o" + (optimize ? "+" : "-") + (useDebug ? " /debug": ""); options.ReferencedAssemblies.Add("System.Core.dll"); CompilerResults results = provider.CompileAssemblyFromSource(options, code); try { diff --git a/src/Libraries/ICSharpCode.Decompiler/Tests/TypeAnalysisTests.cs b/src/Libraries/ICSharpCode.Decompiler/Tests/TypeAnalysisTests.cs index 3c0ffc4b97..760bb862d3 100644 --- a/src/Libraries/ICSharpCode.Decompiler/Tests/TypeAnalysisTests.cs +++ b/src/Libraries/ICSharpCode.Decompiler/Tests/TypeAnalysisTests.cs @@ -140,4 +140,14 @@ public class TypeAnalysisTests { return new byte[length]; } + + public StringComparison EnumDiffNumber(StringComparison data) + { + return data - 1; + } + + public int EnumDiff(StringComparison a, StringComparison b) + { + return Math.Abs(a - b); + } } diff --git a/src/Libraries/Mono.Cecil/.gitignore b/src/Libraries/Mono.Cecil/.gitignore new file mode 100644 index 0000000000..8dcb32b7f6 --- /dev/null +++ b/src/Libraries/Mono.Cecil/.gitignore @@ -0,0 +1,10 @@ +bin +obj +*.suo +*.user +*.pidb +*.userprefs +*.xml +*.nupkg +**/test-results/* +*Resharper* diff --git a/src/Libraries/Mono.Cecil/Mono.Cecil.PE/Image.cs b/src/Libraries/Mono.Cecil/Mono.Cecil.PE/Image.cs index 9a04494f01..e5d8075251 100644 --- a/src/Libraries/Mono.Cecil/Mono.Cecil.PE/Image.cs +++ b/src/Libraries/Mono.Cecil/Mono.Cecil.PE/Image.cs @@ -52,6 +52,7 @@ namespace Mono.Cecil.PE { public DataDirectory Debug; public DataDirectory Resources; + public DataDirectory StrongName; public StringHeap StringHeap; public BlobHeap BlobHeap; diff --git a/src/Libraries/Mono.Cecil/Mono.Cecil.PE/ImageReader.cs b/src/Libraries/Mono.Cecil/Mono.Cecil.PE/ImageReader.cs index 9baeca5eef..b320169192 100644 --- a/src/Libraries/Mono.Cecil/Mono.Cecil.PE/ImageReader.cs +++ b/src/Libraries/Mono.Cecil/Mono.Cecil.PE/ImageReader.cs @@ -322,6 +322,7 @@ namespace Mono.Cecil.PE { // Resources 8 image.Resources = ReadDataDirectory (); // StrongNameSignature 8 + image.StrongName = ReadDataDirectory (); // CodeManagerTable 8 // VTableFixups 8 // ExportAddressTableJumps 8 diff --git a/src/Libraries/Mono.Cecil/Mono.Cecil.PE/ImageWriter.cs b/src/Libraries/Mono.Cecil/Mono.Cecil.PE/ImageWriter.cs index af6aa7a359..bea308c919 100644 --- a/src/Libraries/Mono.Cecil/Mono.Cecil.PE/ImageWriter.cs +++ b/src/Libraries/Mono.Cecil/Mono.Cecil.PE/ImageWriter.cs @@ -75,7 +75,7 @@ namespace Mono.Cecil.PE { this.GetDebugHeader (); this.GetWin32Resources (); this.text_map = BuildTextMap (); - this.sections = 2; // text + reloc + this.sections = (ushort) (pe64 ? 1 : 2); // text + reloc this.time_stamp = (uint) DateTime.UtcNow.Subtract (new DateTime (1970, 1, 1)).TotalSeconds; } @@ -133,7 +133,8 @@ namespace Mono.Cecil.PE { previous = rsrc; } - reloc = CreateSection (".reloc", 12u, previous); + if (!pe64) + reloc = CreateSection (".reloc", 12u, previous); } Section CreateSection (string name, uint size, Section previous) @@ -217,20 +218,29 @@ namespace Mono.Cecil.PE { throw new NotSupportedException (); } + Section LastSection () + { + if (reloc != null) + return reloc; + + if (rsrc != null) + return rsrc; + + return text; + } + void WriteOptionalHeaders () { WriteUInt16 ((ushort) (!pe64 ? 0x10b : 0x20b)); // Magic WriteByte (8); // LMajor WriteByte (0); // LMinor WriteUInt32 (text.SizeOfRawData); // CodeSize - WriteUInt32 (reloc.SizeOfRawData + WriteUInt32 (reloc != null ? reloc.SizeOfRawData : 0 + (rsrc != null ? rsrc.SizeOfRawData : 0)); // InitializedDataSize WriteUInt32 (0); // UninitializedDataSize - var entry_point_rva = text_map.GetRVA (TextSegment.StartupStub); - if (module.Architecture == TargetArchitecture.IA64) - entry_point_rva += 0x20; - WriteUInt32 (entry_point_rva); // EntryPointRVA + var startub_stub = text_map.GetRange (TextSegment.StartupStub); + WriteUInt32 (startub_stub.Length > 0 ? startub_stub.Start : 0); // EntryPointRVA WriteUInt32 (text_rva); // BaseOfCode if (!pe64) { @@ -251,7 +261,8 @@ namespace Mono.Cecil.PE { WriteUInt16 (0); // SubSysMinor WriteUInt32 (0); // Reserved - WriteUInt32 (reloc.VirtualAddress + Align (reloc.VirtualSize, section_alignment)); // ImageSize + var last_section = LastSection(); + WriteUInt32 (last_section.VirtualAddress + Align (last_section.VirtualSize, section_alignment)); // ImageSize WriteUInt32 (text.PointerToRawData); // HeaderSize WriteUInt32 (0); // Checksum @@ -288,8 +299,8 @@ namespace Mono.Cecil.PE { WriteZeroDataDirectory (); // ExceptionTable WriteZeroDataDirectory (); // CertificateTable - WriteUInt32 (reloc.VirtualAddress); // BaseRelocationTable - WriteUInt32 (reloc.VirtualSize); + WriteUInt32 (reloc != null ? reloc.VirtualAddress : 0); // BaseRelocationTable + WriteUInt32 (reloc != null ? reloc.VirtualSize : 0); if (text_map.GetLength (TextSegment.DebugDirectory) > 0) { WriteUInt32 (text_map.GetRVA (TextSegment.DebugDirectory)); @@ -335,7 +346,8 @@ namespace Mono.Cecil.PE { if (rsrc != null) WriteSection (rsrc, 0x40000040); - WriteSection (reloc, 0x42000040); + if (reloc != null) + WriteSection (reloc, 0x42000040); } void WriteSection (Section section, uint characteristics) @@ -386,8 +398,10 @@ namespace Mono.Cecil.PE { // ImportAddressTable - WriteRVA (text_map.GetRVA (TextSegment.ImportHintNameTable)); - WriteRVA (0); + if (!pe64) { + WriteRVA (text_map.GetRVA (TextSegment.ImportHintNameTable)); + WriteRVA (0); + } // CLIHeader @@ -439,6 +453,9 @@ namespace Mono.Cecil.PE { WriteDebugDirectory (); } + if (pe64) + return; + // ImportDirectory MoveToRVA (TextSegment.ImportDirectory); WriteImportDirectory (); @@ -605,19 +622,8 @@ namespace Mono.Cecil.PE { WriteUInt16 (0x25ff); WriteUInt32 ((uint) image_base + text_map.GetRVA (TextSegment.ImportAddressTable)); return; - case TargetArchitecture.AMD64: - WriteUInt16 (0xa148); - WriteUInt32 ((uint) image_base + text_map.GetRVA (TextSegment.ImportAddressTable)); - WriteUInt16 (0xe0ff); - return; - case TargetArchitecture.IA64: - WriteBytes (new byte [] { - 0x0b, 0x48, 0x00, 0x02, 0x18, 0x10, 0xa0, 0x40, 0x24, 0x30, 0x28, 0x00, 0x00, 0x00, 0x04, 0x00, - 0x10, 0x08, 0x00, 0x12, 0x18, 0x10, 0x60, 0x50, 0x04, 0x80, 0x03, 0x00, 0x60, 0x00, 0x80, 0x00 - }); - WriteUInt32 ((uint) image_base + text_map.GetRVA (TextSegment.StartupStub)); - WriteUInt32 ((uint) image_base + text_rva); - return; + default: + throw new NotSupportedException (); } } @@ -642,13 +648,8 @@ namespace Mono.Cecil.PE { case TargetArchitecture.I386: WriteUInt32 (0x3000 + reloc_rva - page_rva); break; - case TargetArchitecture.AMD64: - WriteUInt32 (0xa000 + reloc_rva - page_rva); - break; - case TargetArchitecture.IA64: - WriteUInt16 ((ushort) (0xa000 + reloc_rva - page_rva)); - WriteUInt16 ((ushort) (0xa000 + reloc_rva - page_rva + 8)); - break; + default: + throw new NotSupportedException(); } WriteBytes (new byte [file_alignment - reloc.VirtualSize]); @@ -663,7 +664,8 @@ namespace Mono.Cecil.PE { WriteText (); if (rsrc != null) WriteRsrc (); - WriteReloc (); + if (reloc != null) + WriteReloc (); } TextMap BuildTextMap () @@ -694,8 +696,16 @@ namespace Mono.Cecil.PE { map.AddMap (TextSegment.DebugDirectory, debug_dir_len, 4); + if (pe64) { + var start = map.GetNextRVA (TextSegment.DebugDirectory); + map.AddMap (TextSegment.ImportDirectory, new Range (start, 0)); + map.AddMap (TextSegment.ImportHintNameTable, new Range (start, 0)); + map.AddMap (TextSegment.StartupStub, new Range (start, 0)); + return map; + } + RVA import_dir_rva = map.GetNextRVA (TextSegment.DebugDirectory); - RVA import_hnt_rva = import_dir_rva + (!pe64 ? 48u : 52u); + RVA import_hnt_rva = import_dir_rva + 48u; import_hnt_rva = (import_hnt_rva + 15u) & ~15u; uint import_dir_len = (import_hnt_rva - import_dir_rva) + 27u; @@ -716,12 +726,8 @@ namespace Mono.Cecil.PE { switch (module.Architecture) { case TargetArchitecture.I386: return 6; - case TargetArchitecture.AMD64: - return 12; - case TargetArchitecture.IA64: - return 48; default: - throw new InvalidOperationException (); + throw new NotSupportedException (); } } @@ -744,11 +750,8 @@ namespace Mono.Cecil.PE { int GetStrongNameLength () { - if ((module.Attributes & ModuleAttributes.StrongNameSigned) == 0) - return 0; - if (module.Assembly == null) - throw new InvalidOperationException (); + return 0; var public_key = module.Assembly.Name.PublicKey; diff --git a/src/Libraries/Mono.Cecil/Mono.Cecil/AssemblyFlags.cs b/src/Libraries/Mono.Cecil/Mono.Cecil/AssemblyFlags.cs index e466e78441..72a0eb06c2 100644 --- a/src/Libraries/Mono.Cecil/Mono.Cecil/AssemblyFlags.cs +++ b/src/Libraries/Mono.Cecil/Mono.Cecil/AssemblyFlags.cs @@ -35,6 +35,7 @@ namespace Mono.Cecil { PublicKey = 0x0001, SideBySideCompatible = 0x0000, Retargetable = 0x0100, + WindowsRuntime = 0x0200, DisableJITCompileOptimizer = 0x4000, EnableJITCompileTracking = 0x8000, } diff --git a/src/Libraries/Mono.Cecil/Mono.Cecil/AssemblyNameReference.cs b/src/Libraries/Mono.Cecil/Mono.Cecil/AssemblyNameReference.cs index 31b7a30b3a..3da978057b 100644 --- a/src/Libraries/Mono.Cecil/Mono.Cecil/AssemblyNameReference.cs +++ b/src/Libraries/Mono.Cecil/Mono.Cecil/AssemblyNameReference.cs @@ -92,6 +92,11 @@ namespace Mono.Cecil { set { attributes = attributes.SetAttributes ((uint) AssemblyAttributes.Retargetable, value); } } + public bool IsWindowsRuntime { + get { return attributes.GetAttributes ((uint) AssemblyAttributes.WindowsRuntime); } + set { attributes = attributes.SetAttributes ((uint) AssemblyAttributes.WindowsRuntime, value); } + } + public byte [] PublicKey { get { return public_key; } set { diff --git a/src/Libraries/Mono.Cecil/Mono.Cecil/AssemblyWriter.cs b/src/Libraries/Mono.Cecil/Mono.Cecil/AssemblyWriter.cs index 22c77ab7ac..bffa439c60 100644 --- a/src/Libraries/Mono.Cecil/Mono.Cecil/AssemblyWriter.cs +++ b/src/Libraries/Mono.Cecil/Mono.Cecil/AssemblyWriter.cs @@ -97,13 +97,11 @@ namespace Mono.Cecil { var symbol_writer = GetSymbolWriter (module, fq_name, symbol_writer_provider); #if !SILVERLIGHT && !CF - if (parameters.StrongNameKeyPair != null && name != null) + if (parameters.StrongNameKeyPair != null && name != null) { name.PublicKey = parameters.StrongNameKeyPair.PublicKey; -#endif - - if (name != null && name.HasPublicKey) module.Attributes |= ModuleAttributes.StrongNameSigned; - + } +#endif var metadata = new MetadataBuilder (module, fq_name, symbol_writer_provider, symbol_writer); @@ -786,7 +784,7 @@ namespace Mono.Cecil { TextMap CreateTextMap () { var map = new TextMap (); - map.AddMap (TextSegment.ImportAddressTable, module.Architecture == TargetArchitecture.I386 ? 8 : 16); + map.AddMap (TextSegment.ImportAddressTable, module.Architecture == TargetArchitecture.I386 ? 8 : 0); map.AddMap (TextSegment.CLIHeader, 0x48, 8); return map; } diff --git a/src/Libraries/Mono.Cecil/Mono.Cecil/Import.cs b/src/Libraries/Mono.Cecil/Mono.Cecil/Import.cs index 4f3ff25c4e..38d0120412 100644 --- a/src/Libraries/Mono.Cecil/Mono.Cecil/Import.cs +++ b/src/Libraries/Mono.Cecil/Mono.Cecil/Import.cs @@ -92,7 +92,7 @@ namespace Mono.Cecil { if (IsNestedType (type)) reference.DeclaringType = ImportType (type.DeclaringType, context, import_kind); else - reference.Namespace = type.Namespace; + reference.Namespace = type.Namespace ?? string.Empty; if (type.IsGenericType) ImportGenericParameters (reference, type.GetGenericArguments ()); diff --git a/src/Libraries/Mono.Cecil/Mono.Cecil/TypeAttributes.cs b/src/Libraries/Mono.Cecil/Mono.Cecil/TypeAttributes.cs index bc4e18f336..86fbc4dba5 100644 --- a/src/Libraries/Mono.Cecil/Mono.Cecil/TypeAttributes.cs +++ b/src/Libraries/Mono.Cecil/Mono.Cecil/TypeAttributes.cs @@ -62,6 +62,7 @@ namespace Mono.Cecil { // Implementation attributes Import = 0x00001000, // Class/Interface is imported Serializable = 0x00002000, // Class is serializable + WindowsRuntime = 0x00004000, // Windows Runtime type // String formatting attributes StringFormatMask = 0x00030000, // Use this mask to retrieve string information for native interop diff --git a/src/Libraries/Mono.Cecil/Mono.Cecil/TypeDefinition.cs b/src/Libraries/Mono.Cecil/Mono.Cecil/TypeDefinition.cs index a43e7e53ea..58c52af179 100644 --- a/src/Libraries/Mono.Cecil/Mono.Cecil/TypeDefinition.cs +++ b/src/Libraries/Mono.Cecil/Mono.Cecil/TypeDefinition.cs @@ -389,6 +389,11 @@ namespace Mono.Cecil { set { attributes = attributes.SetAttributes ((uint) TypeAttributes.Serializable, value); } } + public bool IsWindowsRuntime { + get { return attributes.GetAttributes ((uint) TypeAttributes.WindowsRuntime); } + set { attributes = attributes.SetAttributes ((uint) TypeAttributes.WindowsRuntime, value); } + } + public bool IsAnsiClass { get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.StringFormatMask, (uint) TypeAttributes.AnsiClass); } set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.StringFormatMask, (uint) TypeAttributes.AnsiClass, value); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Analysis/ControlFlow.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Analysis/ControlFlow.cs index 508c5e945f..2812375b11 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Analysis/ControlFlow.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Analysis/ControlFlow.cs @@ -1,4 +1,4 @@ -// Copyright (c) AlphaSierraPapa for the SharpDevelop Team +// Copyright (c) AlphaSierraPapa for the SharpDevelop Team // // Permission is hereby granted, free of charge, to any person obtaining a copy of this // software and associated documentation files (the "Software"), to deal in the Software @@ -21,9 +21,10 @@ using System.Collections.Generic; using System.Diagnostics; using System.Linq; using System.Threading; - using ICSharpCode.NRefactory.CSharp.Resolver; +using ICSharpCode.NRefactory.CSharp.TypeSystem; using ICSharpCode.NRefactory.Semantics; +using ICSharpCode.NRefactory.TypeSystem; using ICSharpCode.NRefactory.TypeSystem.Implementation; namespace ICSharpCode.NRefactory.CSharp.Analysis @@ -112,7 +113,7 @@ namespace ICSharpCode.NRefactory.CSharp.Analysis /// Gets the try-finally statements that this control flow edge is leaving. /// public IEnumerable TryFinallyStatements { - get { return jumpOutOfTryFinally ?? EmptyList.Instance; } + get { return jumpOutOfTryFinally ?? Enumerable.Empty(); } } } @@ -156,7 +157,8 @@ namespace ICSharpCode.NRefactory.CSharp.Analysis } Statement rootStatement; - CSharpAstResolver resolver; + CSharpTypeResolveContext typeResolveContext; + Func resolver; List nodes; Dictionary labels; List gotoStatements; @@ -164,6 +166,8 @@ namespace ICSharpCode.NRefactory.CSharp.Analysis public IList BuildControlFlowGraph(Statement statement, CancellationToken cancellationToken = default(CancellationToken)) { + if (statement == null) + throw new ArgumentNullException("statement"); CSharpResolver r = new CSharpResolver(MinimalCorlib.Instance.CreateCompilation()); return BuildControlFlowGraph(statement, new CSharpAstResolver(r, statement), cancellationToken); } @@ -174,7 +178,11 @@ namespace ICSharpCode.NRefactory.CSharp.Analysis throw new ArgumentNullException("statement"); if (resolver == null) throw new ArgumentNullException("resolver"); - + return BuildControlFlowGraph(statement, resolver.Resolve, resolver.TypeResolveContext, cancellationToken); + } + + internal IList BuildControlFlowGraph(Statement statement, Func resolver, CSharpTypeResolveContext typeResolveContext, CancellationToken cancellationToken) + { NodeCreationVisitor nodeCreationVisitor = new NodeCreationVisitor(); nodeCreationVisitor.builder = this; try { @@ -183,6 +191,7 @@ namespace ICSharpCode.NRefactory.CSharp.Analysis this.gotoStatements = new List(); this.rootStatement = statement; this.resolver = resolver; + this.typeResolveContext = typeResolveContext; this.cancellationToken = cancellationToken; ControlFlowNode entryPoint = CreateStartNode(statement); @@ -205,6 +214,7 @@ namespace ICSharpCode.NRefactory.CSharp.Analysis this.gotoStatements = null; this.rootStatement = null; this.resolver = null; + this.typeResolveContext = null; this.cancellationToken = CancellationToken.None; } } @@ -288,7 +298,7 @@ namespace ICSharpCode.NRefactory.CSharp.Analysis if (!(expr is PrimitiveExpression || expr is NullReferenceExpression)) return null; } - return resolver.Resolve(expr, cancellationToken); + return resolver(expr, cancellationToken); } /// @@ -308,7 +318,7 @@ namespace ICSharpCode.NRefactory.CSharp.Analysis { if (c1 == null || c2 == null || !c1.IsCompileTimeConstant || !c2.IsCompileTimeConstant) return false; - CSharpResolver r = new CSharpResolver(resolver.TypeResolveContext); + CSharpResolver r = new CSharpResolver(typeResolveContext); ResolveResult c = r.ResolveBinaryOperator(BinaryOperatorType.Equality, c1, c2); return c.IsCompileTimeConstant && (c.ConstantValue as bool?) == true; } @@ -410,7 +420,8 @@ namespace ICSharpCode.NRefactory.CSharp.Analysis falseEnd = ifElseStatement.FalseStatement.AcceptVisitor(this, falseBegin); } ControlFlowNode end = builder.CreateEndNode(ifElseStatement); - Connect(trueEnd, end); + if (trueEnd != null) + Connect(trueEnd, end); if (falseEnd != null) { Connect(falseEnd, end); } else if (cond != true) { diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Analysis/DefiniteAssignmentAnalysis.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Analysis/DefiniteAssignmentAnalysis.cs index 8d0832bed8..fdcc4d717c 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Analysis/DefiniteAssignmentAnalysis.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Analysis/DefiniteAssignmentAnalysis.cs @@ -304,54 +304,53 @@ namespace ICSharpCode.NRefactory.CSharp.Analysis return DefiniteAssignmentStatus.PotentiallyAssigned; } - void ChangeNodeStatus(DefiniteAssignmentNode node, DefiniteAssignmentStatus inputStatus) + void ChangeNodeStatus (DefiniteAssignmentNode node, DefiniteAssignmentStatus inputStatus) { if (node.NodeStatus == inputStatus) return; node.NodeStatus = inputStatus; DefiniteAssignmentStatus outputStatus; switch (node.Type) { - case ControlFlowNodeType.StartNode: - case ControlFlowNodeType.BetweenStatements: - if (node.NextStatement is IfElseStatement) { - // Handle if-else as a condition node + case ControlFlowNodeType.StartNode: + case ControlFlowNodeType.BetweenStatements: + if (node.NextStatement is IfElseStatement) { + // Handle if-else as a condition node goto case ControlFlowNodeType.LoopCondition; - } - if (inputStatus == DefiniteAssignmentStatus.DefinitelyAssigned) { - // There isn't any way to un-assign variables, so we don't have to check the expression - // if the status already is definitely assigned. - outputStatus = DefiniteAssignmentStatus.DefinitelyAssigned; - } else { - outputStatus = CleanSpecialValues(node.NextStatement.AcceptVisitor(visitor, inputStatus)); - } - break; - case ControlFlowNodeType.EndNode: - outputStatus = inputStatus; - if (node.PreviousStatement.Role == TryCatchStatement.FinallyBlockRole - && (outputStatus == DefiniteAssignmentStatus.DefinitelyAssigned || outputStatus == DefiniteAssignmentStatus.PotentiallyAssigned)) - { - TryCatchStatement tryFinally = (TryCatchStatement)node.PreviousStatement.Parent; - // Changing the status on a finally block potentially changes the status of all edges leaving that finally block: - foreach (ControlFlowEdge edge in allNodes.SelectMany(n => n.Outgoing)) { - if (edge.IsLeavingTryFinally && edge.TryFinallyStatements.Contains(tryFinally)) { - DefiniteAssignmentStatus s = edgeStatus[edge]; - if (s == DefiniteAssignmentStatus.PotentiallyAssigned) { - ChangeEdgeStatus(edge, outputStatus); - } + } + if (inputStatus == DefiniteAssignmentStatus.DefinitelyAssigned) { + // There isn't any way to un-assign variables, so we don't have to check the expression + // if the status already is definitely assigned. + outputStatus = DefiniteAssignmentStatus.DefinitelyAssigned; + } else { + outputStatus = CleanSpecialValues (node.NextStatement.AcceptVisitor (visitor, inputStatus)); + } + break; + case ControlFlowNodeType.EndNode: + outputStatus = inputStatus; + if (node.PreviousStatement.Role == TryCatchStatement.FinallyBlockRole + && (outputStatus == DefiniteAssignmentStatus.DefinitelyAssigned || outputStatus == DefiniteAssignmentStatus.PotentiallyAssigned)) { + TryCatchStatement tryFinally = (TryCatchStatement)node.PreviousStatement.Parent; + // Changing the status on a finally block potentially changes the status of all edges leaving that finally block: + foreach (ControlFlowEdge edge in allNodes.SelectMany(n => n.Outgoing)) { + if (edge.IsLeavingTryFinally && edge.TryFinallyStatements.Contains (tryFinally)) { + DefiniteAssignmentStatus s = edgeStatus [edge]; + if (s == DefiniteAssignmentStatus.PotentiallyAssigned) { + ChangeEdgeStatus (edge, outputStatus); } } } + } + break; + case ControlFlowNodeType.LoopCondition: + ForeachStatement foreachStmt = node.NextStatement as ForeachStatement; + if (foreachStmt != null) { + outputStatus = CleanSpecialValues (foreachStmt.InExpression.AcceptVisitor (visitor, inputStatus)); + if (foreachStmt.VariableName == this.variableName) + outputStatus = DefiniteAssignmentStatus.DefinitelyAssigned; break; - case ControlFlowNodeType.LoopCondition: - ForeachStatement foreachStmt = node.NextStatement as ForeachStatement; - if (foreachStmt != null) { - outputStatus = CleanSpecialValues(foreachStmt.InExpression.AcceptVisitor(visitor, inputStatus)); - if (foreachStmt.VariableName == this.variableName) - outputStatus = DefiniteAssignmentStatus.DefinitelyAssigned; - break; - } else { - Debug.Assert(node.NextStatement is IfElseStatement || node.NextStatement is WhileStatement || node.NextStatement is ForStatement || node.NextStatement is DoWhileStatement); - Expression condition = node.NextStatement.GetChildByRole(AstNode.Roles.Condition); + } else { + Debug.Assert (node.NextStatement is IfElseStatement || node.NextStatement is WhileStatement || node.NextStatement is ForStatement || node.NextStatement is DoWhileStatement); + Expression condition = node.NextStatement.GetChildByRole (Roles.Condition); if (condition.IsNull) outputStatus = inputStatus; else diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Analysis/ReachabilityAnalysis.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Analysis/ReachabilityAnalysis.cs new file mode 100644 index 0000000000..ebb8d419d3 --- /dev/null +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Analysis/ReachabilityAnalysis.cs @@ -0,0 +1,91 @@ +// Copyright (c) AlphaSierraPapa for the SharpDevelop Team +// +// Permission is hereby granted, free of charge, to any person obtaining a copy of this +// software and associated documentation files (the "Software"), to deal in the Software +// without restriction, including without limitation the rights to use, copy, modify, merge, +// publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons +// to whom the Software is furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in all copies or +// substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, +// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR +// PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE +// FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +// DEALINGS IN THE SOFTWARE. + +using System; +using System.Collections.Generic; +using System.Threading; +using ICSharpCode.NRefactory.CSharp.Resolver; +using ICSharpCode.NRefactory.CSharp.TypeSystem; +using ICSharpCode.NRefactory.Semantics; + +namespace ICSharpCode.NRefactory.CSharp.Analysis +{ + /// + /// Statement reachability analysis. + /// + public sealed class ReachabilityAnalysis + { + HashSet reachableStatements = new HashSet(); + HashSet reachableEndPoints = new HashSet(); + HashSet visitedNodes = new HashSet(); + Stack stack = new Stack(); + + private ReachabilityAnalysis() {} + + public static ReachabilityAnalysis Create(Statement statement, CSharpAstResolver resolver = null, CancellationToken cancellationToken = default(CancellationToken)) + { + var cfgBuilder = new ControlFlowGraphBuilder(); + var cfg = cfgBuilder.BuildControlFlowGraph(statement, resolver, cancellationToken); + return Create(cfg, cancellationToken); + } + + internal static ReachabilityAnalysis Create(Statement statement, Func resolver, CSharpTypeResolveContext typeResolveContext, CancellationToken cancellationToken) + { + var cfgBuilder = new ControlFlowGraphBuilder(); + var cfg = cfgBuilder.BuildControlFlowGraph(statement, resolver, typeResolveContext, cancellationToken); + return Create(cfg, cancellationToken); + } + + public static ReachabilityAnalysis Create(IList controlFlowGraph, CancellationToken cancellationToken = default(CancellationToken)) + { + if (controlFlowGraph == null) + throw new ArgumentNullException("controlFlowGraph"); + ReachabilityAnalysis ra = new ReachabilityAnalysis(); + ra.stack.Push(controlFlowGraph[0]); + while (ra.stack.Count > 0) { + cancellationToken.ThrowIfCancellationRequested(); + ra.MarkReachable(ra.stack.Pop()); + } + ra.stack = null; + ra.visitedNodes = null; + return ra; + } + + void MarkReachable(ControlFlowNode node) + { + if (node.PreviousStatement != null) + reachableEndPoints.Add(node.PreviousStatement); + if (node.NextStatement != null) + reachableStatements.Add(node.NextStatement); + foreach (var edge in node.Outgoing) { + if (visitedNodes.Add(edge.To)) + stack.Push(edge.To); + } + } + + public bool IsReachable(Statement statement) + { + return reachableStatements.Contains(statement); + } + + public bool IsEndpointReachable(Statement statement) + { + return reachableEndPoints.Contains(statement); + } + } +} diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/AstNode.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/AstNode.cs index b7ea446ef4..bc4d27de03 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/AstNode.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/AstNode.cs @@ -1,4 +1,4 @@ -// +// // AstNode.cs // // Author: @@ -33,8 +33,11 @@ using System.Threading; namespace ICSharpCode.NRefactory.CSharp { - public abstract class AstNode : AbstractAnnotatable, PatternMatching.INode + public abstract class AstNode : AbstractAnnotatable, ICSharpCode.NRefactory.TypeSystem.IFreezable, PatternMatching.INode { + // the Root role must be available when creating the null nodes, so we can't put it in the Roles class + internal static readonly Role RootRole = new Role ("Root"); + #region Null public static readonly AstNode Null = new NullAstNode (); @@ -52,7 +55,16 @@ namespace ICSharpCode.NRefactory.CSharp } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return default (T); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return default (S); } @@ -83,7 +95,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return NodeType.Pattern; } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitPatternPlaceholder (this, child); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitPatternPlaceholder (this, child); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitPatternPlaceholder (this, child, data); } @@ -105,7 +127,42 @@ namespace ICSharpCode.NRefactory.CSharp AstNode nextSibling; AstNode firstChild; AstNode lastChild; - Role role = RootRole; + + // Flags, from least significant to most significant bits: + // - Role.RoleIndexBits: role index + // - 1 bit: IsFrozen + protected uint flags = RootRole.Index; + // Derived classes may also use a few bits, + // for example Identifier uses 1 bit for IsVerbatim + + const uint roleIndexMask = (1u << Role.RoleIndexBits) - 1; + const uint frozenBit = 1u << Role.RoleIndexBits; + protected const int AstNodeFlagsUsedBits = Role.RoleIndexBits + 1; + + protected AstNode() + { + if (IsNull) + Freeze(); + } + + public bool IsFrozen { + get { return (flags & frozenBit) != 0; } + } + + public void Freeze() + { + if (!IsFrozen) { + for (AstNode child = firstChild; child != null; child = child.nextSibling) + child.Freeze(); + flags |= frozenBit; + } + } + + protected void ThrowIfFrozen() + { + if (IsFrozen) + throw new InvalidOperationException("Cannot mutate frozen " + GetType().Name); + } public abstract NodeType NodeType { get; @@ -135,12 +192,39 @@ namespace ICSharpCode.NRefactory.CSharp } } + /// + /// Gets the region from StartLocation to EndLocation for this node. + /// The file name of the region is set based on the parent CompilationUnit's file name. + /// If this node is not connected to a whole compilation, the file name will be null. + /// + public ICSharpCode.NRefactory.TypeSystem.DomRegion GetRegion() + { + var cu = (this.Ancestors.LastOrDefault() ?? this) as CompilationUnit; + string fileName = (cu != null ? cu.FileName : null); + return new ICSharpCode.NRefactory.TypeSystem.DomRegion(fileName, this.StartLocation, this.EndLocation); + } + public AstNode Parent { get { return parent; } } public Role Role { - get { return role; } + get { + return Role.GetByIndex(flags & roleIndexMask); + } + set { + if (value == null) + throw new ArgumentNullException("value"); + if (!value.IsValid(this)) + throw new ArgumentException("This node is not valid in the new role."); + ThrowIfFrozen(); + SetRole(value); + } + } + + void SetRole(Role role) + { + flags = (flags & ~roleIndexMask) | role.Index; } public AstNode NextSibling { @@ -159,6 +243,12 @@ namespace ICSharpCode.NRefactory.CSharp get { return lastChild; } } + public bool HasChildren { + get { + return firstChild != null; + } + } + public IEnumerable Children { get { AstNode next; @@ -183,6 +273,17 @@ namespace ICSharpCode.NRefactory.CSharp } } + /// + /// Gets the ancestors of this node (including this node itself) + /// + public IEnumerable AncestorsAndSelf { + get { + for (AstNode cur = this; cur != null; cur = cur.parent) { + yield return cur; + } + } + } + /// /// Gets all descendants of this node (excluding this node itself). /// @@ -205,17 +306,23 @@ namespace ICSharpCode.NRefactory.CSharp /// Gets the first child with the specified role. /// Returns the role's null object if the child is not found. /// - public T GetChildByRole (Role role) where T : AstNode + public T GetChildByRole(Role role) where T : AstNode { if (role == null) throw new ArgumentNullException ("role"); + uint roleIndex = role.Index; for (var cur = firstChild; cur != null; cur = cur.nextSibling) { - if (cur.role == role) + if ((cur.flags & roleIndexMask) == roleIndex) return (T)cur; } return role.NullObject; } + public T GetParent() where T : AstNode + { + return Ancestors.OfType().FirstOrDefault(); + } + public AstNodeCollection GetChildrenByRole (Role role) where T : AstNode { return new AstNodeCollection (this, role); @@ -236,10 +343,11 @@ namespace ICSharpCode.NRefactory.CSharp throw new ArgumentNullException ("role"); if (child == null || child.IsNull) return; - if (this.IsNull) - throw new InvalidOperationException ("Cannot add children to null nodes"); + ThrowIfFrozen(); if (child.parent != null) throw new ArgumentException ("Node is already used in another tree.", "child"); + if (child.IsFrozen) + throw new ArgumentException ("Cannot add a frozen node.", "child"); AddChildUnsafe (child, role); } @@ -249,7 +357,7 @@ namespace ICSharpCode.NRefactory.CSharp void AddChildUnsafe (AstNode child, Role role) { child.parent = this; - child.role = role; + child.SetRole(role); if (firstChild == null) { lastChild = firstChild = child; } else { @@ -258,6 +366,13 @@ namespace ICSharpCode.NRefactory.CSharp lastChild = child; } } + + public void InsertChildsBefore(AstNode nextSibling, Role role, params T[] child) where T : AstNode + { + foreach (var cur in child) { + InsertChildBefore(nextSibling, cur, role); + } + } public void InsertChildBefore (AstNode nextSibling, T child, Role role) where T : AstNode { @@ -270,8 +385,11 @@ namespace ICSharpCode.NRefactory.CSharp if (child == null || child.IsNull) return; + ThrowIfFrozen(); if (child.parent != null) throw new ArgumentException ("Node is already used in another tree.", "child"); + if (child.IsFrozen) + throw new ArgumentException ("Cannot add a frozen node.", "child"); if (nextSibling.parent != this) throw new ArgumentException ("NextSibling is not a child of this node.", "nextSibling"); // No need to test for "Cannot add children to null nodes", @@ -282,7 +400,7 @@ namespace ICSharpCode.NRefactory.CSharp void InsertChildBeforeUnsafe (AstNode nextSibling, AstNode child, Role role) { child.parent = this; - child.role = role; + child.SetRole(role); child.nextSibling = nextSibling; child.prevSibling = nextSibling.prevSibling; @@ -307,6 +425,7 @@ namespace ICSharpCode.NRefactory.CSharp public void Remove () { if (parent != null) { + ThrowIfFrozen(); if (prevSibling != null) { Debug.Assert (prevSibling.nextSibling == this); prevSibling.nextSibling = nextSibling; @@ -322,7 +441,6 @@ namespace ICSharpCode.NRefactory.CSharp parent.lastChild = prevSibling; } parent = null; - role = Roles.Root; prevSibling = null; nextSibling = null; } @@ -342,10 +460,11 @@ namespace ICSharpCode.NRefactory.CSharp if (parent == null) { throw new InvalidOperationException (this.IsNull ? "Cannot replace the null nodes" : "Cannot replace the root node"); } + ThrowIfFrozen(); // Because this method doesn't statically check the new node's type with the role, // we perform a runtime test: - if (!role.IsValid (newNode)) { - throw new ArgumentException (string.Format ("The new node '{0}' is not valid in the role {1}", newNode.GetType ().Name, role.ToString ()), "newNode"); + if (!this.Role.IsValid (newNode)) { + throw new ArgumentException (string.Format ("The new node '{0}' is not valid in the role {1}", newNode.GetType ().Name, this.Role.ToString ()), "newNode"); } if (newNode.parent != null) { // newNode is used within this tree? @@ -357,9 +476,11 @@ namespace ICSharpCode.NRefactory.CSharp throw new ArgumentException ("Node is already used in another tree.", "newNode"); } } + if (newNode.IsFrozen) + throw new ArgumentException ("Cannot add a frozen node.", "newNode"); newNode.parent = parent; - newNode.role = role; + newNode.SetRole(this.Role); newNode.prevSibling = prevSibling; newNode.nextSibling = nextSibling; if (parent != null) { @@ -380,7 +501,6 @@ namespace ICSharpCode.NRefactory.CSharp parent = null; prevSibling = null; nextSibling = null; - role = Roles.Root; } } @@ -393,7 +513,7 @@ namespace ICSharpCode.NRefactory.CSharp } AstNode oldParent = parent; AstNode oldSuccessor = nextSibling; - Role oldRole = role; + Role oldRole = this.Role; Remove (); AstNode replacement = replaceFunction (this); if (oldSuccessor != null && oldSuccessor.parent != oldParent) @@ -422,26 +542,28 @@ namespace ICSharpCode.NRefactory.CSharp AstNode copy = (AstNode)MemberwiseClone (); // First, reset the shallow pointer copies copy.parent = null; - copy.role = Roles.Root; copy.firstChild = null; copy.lastChild = null; copy.prevSibling = null; copy.nextSibling = null; + copy.flags &= ~frozenBit; // unfreeze the copy // Then perform a deep copy: for (AstNode cur = firstChild; cur != null; cur = cur.nextSibling) { - copy.AddChildUnsafe (cur.Clone (), cur.role); + copy.AddChildUnsafe (cur.Clone (), cur.Role); } // Finally, clone the annotation, if necessary - ICloneable copiedAnnotations = copy.annotations as ICloneable; // read from copy (for thread-safety) - if (copiedAnnotations != null) - copy.annotations = copiedAnnotations.Clone(); + copy.CloneAnnotations(); return copy; } - public abstract S AcceptVisitor (IAstVisitor visitor, T data = default(T)); + public abstract void AcceptVisitor (IAstVisitor visitor); + + public abstract T AcceptVisitor (IAstVisitor visitor); + + public abstract S AcceptVisitor (IAstVisitor visitor, T data); #region Pattern Matching protected static bool MatchString (string pattern, string text) @@ -491,7 +613,6 @@ namespace ICSharpCode.NRefactory.CSharp return Parent.GetPrevNode (); return null; } - // filters all non c# nodes (comments, white spaces or pre processor directives) public AstNode GetCSharpNodeBefore (AstNode node) { @@ -504,11 +625,22 @@ namespace ICSharpCode.NRefactory.CSharp return null; } + #region GetNodeAt + /// + /// Gets the node specified by T at the location line, column. This is useful for getting a specific node from the tree. For example searching + /// the current method declaration. + /// (End exclusive) + /// public AstNode GetNodeAt (int line, int column, Predicate pred = null) { return GetNodeAt (new TextLocation (line, column), pred); } + /// + /// Gets the node specified by pred at location. This is useful for getting a specific node from the tree. For example searching + /// the current method declaration. + /// (End exclusive) + /// public AstNode GetNodeAt (TextLocation location, Predicate pred = null) { AstNode result = null; @@ -531,14 +663,20 @@ namespace ICSharpCode.NRefactory.CSharp return result; } + /// + /// Gets the node specified by T at the location line, column. This is useful for getting a specific node from the tree. For example searching + /// the current method declaration. + /// (End exclusive) + /// public T GetNodeAt (int line, int column) where T : AstNode { return GetNodeAt (new TextLocation (line, column)); } /// - /// Gets the node specified by T at location. This is useful for getting a specific node from the tree. For example searching + /// Gets the node specified by T at location. This is useful for getting a specific node from the tree. For example searching /// the current method declaration. + /// (End exclusive) /// public T GetNodeAt (TextLocation location) where T : AstNode { @@ -561,6 +699,97 @@ namespace ICSharpCode.NRefactory.CSharp } return result; } + + #endregion + + #region GetAdjacentNodeAt + /// + /// Gets the node specified by pred at the location line, column. This is useful for getting a specific node from the tree. For example searching + /// the current method declaration. + /// (End inclusive) + /// + public AstNode GetAdjacentNodeAt(int line, int column, Predicate pred = null) + { + return GetAdjacentNodeAt (new TextLocation (line, column), pred); + } + + /// + /// Gets the node specified by pred at location. This is useful for getting a specific node from the tree. For example searching + /// the current method declaration. + /// (End inclusive) + /// + public AstNode GetAdjacentNodeAt (TextLocation location, Predicate pred = null) + { + AstNode result = null; + AstNode node = this; + while (node.FirstChild != null) { + var child = node.FirstChild; + while (child != null) { + if (child.StartLocation <= location && location <= child.EndLocation) { + if (pred == null || pred (child)) + result = child; + node = child; + break; + } + child = child.NextSibling; + } + // found no better child node - therefore the parent is the right one. + if (child == null) + break; + } + return result; + } + + /// + /// Gets the node specified by T at the location line, column. This is useful for getting a specific node from the tree. For example searching + /// the current method declaration. + /// (End inclusive) + /// + public T GetAdjacentNodeAt(int line, int column) where T : AstNode + { + return GetAdjacentNodeAt (new TextLocation (line, column)); + } + + /// + /// Gets the node specified by T at location. This is useful for getting a specific node from the tree. For example searching + /// the current method declaration. + /// (End inclusive) + /// + public T GetAdjacentNodeAt (TextLocation location) where T : AstNode + { + T result = null; + AstNode node = this; + while (node.FirstChild != null) { + var child = node.FirstChild; + while (child != null) { + if (child.StartLocation <= location && location < child.EndLocation) { + if (child is T) + result = (T)child; + node = child; + break; + } + child = child.NextSibling; + } + // found no better child node - therefore the parent is the right one. + if (child == null) + break; + } + return result; + } + #endregion + + + /// + /// Gets the node that fully contains the range from startLocation to endLocation. + /// + public AstNode GetNodeContaining(TextLocation startLocation, TextLocation endLocation) + { + for (AstNode child = firstChild; child != null; child = child.nextSibling) { + if (child.StartLocation <= startLocation && endLocation <= child.EndLocation) + return child.GetNodeContaining(startLocation, endLocation); + } + return this; + } public IEnumerable GetNodesBetween (int startLine, int startColumn, int endLine, int endColumn) { @@ -579,7 +808,7 @@ namespace ICSharpCode.NRefactory.CSharp yield return node; } else { if (node.EndLocation <= start) { - next = node.NextSibling; + next = node.NextSibling; } else { next = node.FirstChild; } @@ -591,16 +820,65 @@ namespace ICSharpCode.NRefactory.CSharp } } + /// + /// Gets the node as formatted C# output. + /// + /// + /// Formatting options. + /// + public virtual string GetText (CSharpFormattingOptions formattingOptions = null) + { + if (IsNull) + return ""; + var w = new StringWriter (); + AcceptVisitor (new CSharpOutputVisitor (w, formattingOptions ?? FormattingOptionsFactory.CreateMono ())); + return w.ToString (); + } + + /// + /// Returns true, if the given coordinates (line, column) are in the node. + /// + /// + /// True, if the given coordinates are between StartLocation and EndLocation (exclusive); otherwise, false. + /// public bool Contains (int line, int column) { return Contains (new TextLocation (line, column)); } - + + /// + /// Returns true, if the given coordinates are in the node. + /// + /// + /// True, if location is between StartLocation and EndLocation (exclusive); otherwise, false. + /// public bool Contains (TextLocation location) { return this.StartLocation <= location && location < this.EndLocation; } + /// + /// Returns true, if the given coordinates (line, column) are in the node. + /// + /// + /// True, if the given coordinates are between StartLocation and EndLocation (inclusive); otherwise, false. + /// + public bool IsInside (int line, int column) + { + return IsInside (new TextLocation (line, column)); + } + + /// + /// Returns true, if the given coordinates are in the node. + /// + /// + /// True, if location is between StartLocation and EndLocation (inclusive); otherwise, false. + /// + public bool IsInside (TextLocation location) + { + return this.StartLocation <= location && location <= this.EndLocation; + } + public override void AddAnnotation (object annotation) { if (this.IsNull) @@ -612,60 +890,12 @@ namespace ICSharpCode.NRefactory.CSharp { if (IsNull) return "Null"; - StringWriter w = new StringWriter(); - AcceptVisitor(new CSharpOutputVisitor(w, new CSharpFormattingOptions()), null); - string text = w.ToString().TrimEnd().Replace("\t", "").Replace(w.NewLine, " "); + string text = GetText(); + text = text.TrimEnd().Replace("\t", "").Replace(Environment.NewLine, " "); if (text.Length > 100) return text.Substring(0, 97) + "..."; else return text; } - - // the Root role must be available when creating the null nodes, so we can't put it in the Roles class - static readonly Role RootRole = new Role ("Root"); - - public static class Roles - { - /// - /// Root of an abstract syntax tree. - /// - public static readonly Role Root = RootRole; - - // some pre defined constants for common roles - public static readonly Role Identifier = new Role ("Identifier", CSharp.Identifier.Null); - public static readonly Role Body = new Role ("Body", CSharp.BlockStatement.Null); - public static readonly Role Parameter = new Role ("Parameter"); - public static readonly Role Argument = new Role ("Argument", CSharp.Expression.Null); - public static readonly Role Type = new Role ("Type", CSharp.AstType.Null); - public static readonly Role Expression = new Role ("Expression", CSharp.Expression.Null); - public static readonly Role TargetExpression = new Role ("Target", CSharp.Expression.Null); - public readonly static Role Condition = new Role ("Condition", CSharp.Expression.Null); - public static readonly Role TypeParameter = new Role ("TypeParameter"); - public static readonly Role TypeArgument = new Role ("TypeArgument", CSharp.AstType.Null); - public readonly static Role Constraint = new Role ("Constraint"); - public static readonly Role Variable = new Role ("Variable"); - public static readonly Role EmbeddedStatement = new Role ("EmbeddedStatement", CSharp.Statement.Null); - public static readonly Role Keyword = new Role ("Keyword", CSharpTokenNode.Null); - public static readonly Role InKeyword = new Role ("InKeyword", CSharpTokenNode.Null); - - // some pre defined constants for most used punctuation - public static readonly Role LPar = new Role ("LPar", CSharpTokenNode.Null); - public static readonly Role RPar = new Role ("RPar", CSharpTokenNode.Null); - public static readonly Role LBracket = new Role ("LBracket", CSharpTokenNode.Null); - public static readonly Role RBracket = new Role ("RBracket", CSharpTokenNode.Null); - public static readonly Role LBrace = new Role ("LBrace", CSharpTokenNode.Null); - public static readonly Role RBrace = new Role ("RBrace", CSharpTokenNode.Null); - public static readonly Role LChevron = new Role ("LChevron", CSharpTokenNode.Null); - public static readonly Role RChevron = new Role ("RChevron", CSharpTokenNode.Null); - public static readonly Role Comma = new Role ("Comma", CSharpTokenNode.Null); - public static readonly Role Dot = new Role ("Dot", CSharpTokenNode.Null); - public static readonly Role Semicolon = new Role ("Semicolon", CSharpTokenNode.Null); - public static readonly Role Assign = new Role ("Assign", CSharpTokenNode.Null); - public static readonly Role Colon = new Role ("Colon", CSharpTokenNode.Null); - public static readonly Role Comment = new Role ("Comment"); - public static readonly Role PreProcessorDirective = new Role ("PreProcessorDirective"); - public static readonly Role Error = new Role ("Error"); - - } } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/AstNodeCollection.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/AstNodeCollection.cs index 1f1236e9cb..4e28849be4 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/AstNodeCollection.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/AstNodeCollection.cs @@ -85,12 +85,16 @@ namespace ICSharpCode.NRefactory.CSharp if (nodes != null) nodes = nodes.ToList(); Clear(); - foreach (T node in nodes) - Add(node); + if (nodes != null) { + foreach (T node in nodes) + Add(node); + } } public void MoveTo(ICollection targetCollection) { + if (targetCollection == null) + throw new ArgumentNullException("targetCollection"); foreach (T node in this) { node.Remove(); targetCollection.Add(node); @@ -124,6 +128,31 @@ namespace ICSharpCode.NRefactory.CSharp item.Remove(); } + /// + /// Returns the first element for which the predicate returns true, + /// or the null node (AstNode with IsNull=true) if no such object is found. + /// + public T FirstOrNullObject(Func predicate = null) + { + foreach (T item in this) + if (predicate == null || predicate(item)) + return item; + return role.NullObject; + } + + /// + /// Returns the last element for which the predicate returns true, + /// or the null node (AstNode with IsNull=true) if no such object is found. + /// + public T LastOrNullObject(Func predicate = null) + { + T result = role.NullObject; + foreach (T item in this) + if (predicate == null || predicate(item)) + result = item; + return result; + } + bool ICollection.IsReadOnly { get { return false; } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/AstType.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/AstType.cs index 12925b60ba..71d8357091 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/AstType.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/AstType.cs @@ -18,6 +18,7 @@ using System; using System.Collections.Generic; +using ICSharpCode.NRefactory.CSharp.Resolver; using ICSharpCode.NRefactory.TypeSystem; namespace ICSharpCode.NRefactory.CSharp @@ -38,7 +39,16 @@ namespace ICSharpCode.NRefactory.CSharp } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return default (T); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return default (S); } @@ -47,6 +57,11 @@ namespace ICSharpCode.NRefactory.CSharp { return other == null || other.IsNull; } + + public override ITypeReference ToTypeReference(SimpleNameLookupMode lookupMode) + { + return SpecialType.UnknownType; + } } #endregion @@ -69,9 +84,24 @@ namespace ICSharpCode.NRefactory.CSharp get { return NodeType.Pattern; } } - public override S AcceptVisitor(IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) { - return visitor.VisitPatternPlaceholder(this, child, data); + visitor.VisitPatternPlaceholder (this, child); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitPatternPlaceholder (this, child); + } + + public override S AcceptVisitor(IAstVisitor visitor, T data) + { + return visitor.VisitPatternPlaceholder (this, child, data); + } + + public override ITypeReference ToTypeReference(SimpleNameLookupMode lookupMode) + { + throw new NotSupportedException(); } protected internal override bool DoMatch(AstNode other, PatternMatching.Match match) @@ -95,6 +125,18 @@ namespace ICSharpCode.NRefactory.CSharp return (AstType)base.Clone(); } + /// + /// Create an ITypeReference for this AstType. + /// + /// + /// The resulting type reference will read the context information from the + /// : + /// For resolving type parameters, the CurrentTypeDefinition/CurrentMember is used. + /// For resolving simple names, the current namespace and usings from the CurrentUsingScope + /// (on CSharpTypeResolveContext only) is used. + /// + public abstract ITypeReference ToTypeReference(SimpleNameLookupMode lookupMode = SimpleNameLookupMode.Type); + /// /// Creates a pointer type from this type by nesting it in a . /// If this type already is a pointer type, this method just increases the PointerRank of the existing pointer type. @@ -130,6 +172,26 @@ namespace ICSharpCode.NRefactory.CSharp return new TypeReferenceExpression { Type = this }.Member(memberName); } + /// + /// Builds an expression that can be used to access a static member on this type. + /// + public MemberType MemberType(string memberName, params AstType[] typeArguments) + { + var memberType = new MemberType(this, memberName); + memberType.TypeArguments.AddRange(typeArguments); + return memberType; + } + + /// + /// Builds an expression that can be used to access a static member on this type. + /// + public MemberType MemberType(string memberName, IEnumerable typeArguments) + { + var memberType = new MemberType(this, memberName); + memberType.TypeArguments.AddRange(typeArguments); + return memberType; + } + /// /// Builds an invocation expression using this type as target. /// @@ -153,42 +215,5 @@ namespace ICSharpCode.NRefactory.CSharp { return new TypeReferenceExpression { Type = this }.Invoke(methodName, typeArguments, arguments); } - - public static AstType Create(Type type) - { - switch (Type.GetTypeCode(type)) { - case TypeCode.Object: - return new PrimitiveType("object"); - case TypeCode.Boolean: - return new PrimitiveType("bool"); - case TypeCode.Char: - return new PrimitiveType("char"); - case TypeCode.SByte: - return new PrimitiveType("sbyte"); - case TypeCode.Byte: - return new PrimitiveType("byte"); - case TypeCode.Int16: - return new PrimitiveType("short"); - case TypeCode.UInt16: - return new PrimitiveType("ushort"); - case TypeCode.Int32: - return new PrimitiveType("int"); - case TypeCode.UInt32: - return new PrimitiveType("uint"); - case TypeCode.Int64: - return new PrimitiveType("long"); - case TypeCode.UInt64: - return new PrimitiveType("ulong"); - case TypeCode.Single: - return new PrimitiveType("float"); - case TypeCode.Double: - return new PrimitiveType("double"); - case TypeCode.Decimal: - return new PrimitiveType("decimal"); - case TypeCode.String: - return new PrimitiveType("string"); - } - return new SimpleType(type.FullName); // TODO: implement this correctly - } } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/CSharpModifierToken.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/CSharpModifierToken.cs index e9cc00ebe9..ac59c72460 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/CSharpModifierToken.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/CSharpModifierToken.cs @@ -29,19 +29,29 @@ using System.Linq; namespace ICSharpCode.NRefactory.CSharp { - public class CSharpModifierToken : CSharpTokenNode { Modifiers modifier; public Modifiers Modifier { get { return modifier; } - set { - this.tokenLength = GetModifierName(value).Length; - this.modifier = value; + set { + ThrowIfFrozen(); + this.modifier = value; } } + protected override int TokenLength { + get { + return GetModifierName (modifier).Length; + } + } + + public override string GetText (CSharpFormattingOptions formattingOptions = null) + { + return GetModifierName (Modifier); + } + protected internal override bool DoMatch(AstNode other, PatternMatching.Match match) { CSharpModifierToken o = other as CSharpModifierToken; @@ -65,7 +75,7 @@ namespace ICSharpCode.NRefactory.CSharp get { return allModifiers; } } - public CSharpModifierToken (TextLocation location, Modifiers modifier) : base (location, 0) + public CSharpModifierToken (TextLocation location, Modifiers modifier) : base (location) { this.Modifier = modifier; } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/CSharpTokenNode.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/CSharpTokenNode.cs index 00bf53dfd2..04910ae181 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/CSharpTokenNode.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/CSharpTokenNode.cs @@ -27,7 +27,13 @@ using System; namespace ICSharpCode.NRefactory.CSharp { - public class CSharpTokenNode : AstNode, IRelocatable + /// + /// Represents a token in C#. Note that the type of the token is defined through the TokenRole. + /// + /// + /// In all non null c# token nodes the Role of a CSharpToken must be a TokenRole. + /// + public class CSharpTokenNode : AstNode { public static new readonly CSharpTokenNode Null = new NullCSharpTokenNode (); class NullCSharpTokenNode : CSharpTokenNode @@ -38,11 +44,20 @@ namespace ICSharpCode.NRefactory.CSharp } } - public NullCSharpTokenNode () : base (TextLocation.Empty, 0) + public NullCSharpTokenNode () : base (TextLocation.Empty) { } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return default (T); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return default (S); } @@ -53,7 +68,6 @@ namespace ICSharpCode.NRefactory.CSharp } } - public override NodeType NodeType { get { return NodeType.Token; @@ -67,27 +81,43 @@ namespace ICSharpCode.NRefactory.CSharp } } - protected int tokenLength; + protected virtual int TokenLength { + get { + if (!(Role is TokenRole)) + return 0; + return ((TokenRole)Role).Length; + } + } + public override TextLocation EndLocation { get { - return new TextLocation (StartLocation.Line, StartLocation.Column + tokenLength); + return new TextLocation (StartLocation.Line, StartLocation.Column + TokenLength); } } - public CSharpTokenNode (TextLocation location, int tokenLength) + public CSharpTokenNode (TextLocation location) { this.startLocation = location; - this.tokenLength = tokenLength; } - #region IRelocationable implementation - void IRelocatable.SetStartLocation (TextLocation startLocation) + public override string GetText (CSharpFormattingOptions formattingOptions = null) + { + if (!(Role is TokenRole)) + return null; + return ((TokenRole)Role).Token; + } + + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitCSharpTokenNode (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) { - this.startLocation = startLocation; + return visitor.VisitCSharpTokenNode (this); } - #endregion - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitCSharpTokenNode (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/CSharpUtil.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/CSharpUtil.cs index 46f528d46b..e13bf334c3 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/CSharpUtil.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/CSharpUtil.cs @@ -74,7 +74,6 @@ namespace ICSharpCode.NRefactory.CSharp return new UnaryOperatorExpression (UnaryOperatorType.Not, new ParenthesizedExpression (condition)); } } - if (condition is ConditionalExpression) { var cEx = condition as ConditionalExpression; cEx.Condition = InvertCondition (cEx.Condition); @@ -83,8 +82,7 @@ namespace ICSharpCode.NRefactory.CSharp if (condition is PrimitiveExpression) { var pex = condition as PrimitiveExpression; if (pex.Value is bool) { - pex.Value = !((bool)pex.Value); - return pex; + return new PrimitiveExpression (!((bool)pex.Value)); } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/CompilationUnit.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/CompilationUnit.cs index 3f3f0d08e7..04dec11e75 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/CompilationUnit.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/CompilationUnit.cs @@ -28,6 +28,10 @@ using System.Collections.Generic; using ICSharpCode.NRefactory.CSharp.Resolver; using ICSharpCode.NRefactory.CSharp.TypeSystem; using ICSharpCode.NRefactory.TypeSystem; +using System.Threading; +using Mono.CSharp; +using System.IO; +using ICSharpCode.NRefactory.Editor; namespace ICSharpCode.NRefactory.CSharp { @@ -41,10 +45,22 @@ namespace ICSharpCode.NRefactory.CSharp } } + string fileName; + /// /// Gets/Sets the file name of this compilation unit. /// - public string FileName { get; set; } + public string FileName { + get { return fileName; } + set { + ThrowIfFrozen(); + fileName = value; + } + } + + public AstNodeCollection Members { + get { return GetChildrenByRole(MemberRole); } + } List errors = new List (); @@ -68,17 +84,18 @@ namespace ICSharpCode.NRefactory.CSharp { } - public IEnumerable GetTypes (bool includeInnerTypes = false) + public IEnumerable GetTypes(bool includeInnerTypes = false) { Stack nodeStack = new Stack (); - nodeStack.Push (this); + nodeStack.Push(this); while (nodeStack.Count > 0) { - var curNode = nodeStack.Pop (); - if (curNode is TypeDeclaration) + var curNode = nodeStack.Pop(); + if (curNode is TypeDeclaration) { yield return (TypeDeclaration)curNode; + } foreach (var child in curNode.Children) { if (!(child is Statement || child is Expression) && - (child.Role != TypeDeclaration.MemberRole || (child is TypeDeclaration && includeInnerTypes))) + (child.Role != Roles.TypeMemberRole || (child is TypeDeclaration && includeInnerTypes))) nodeStack.Push (child); } } @@ -90,7 +107,17 @@ namespace ICSharpCode.NRefactory.CSharp return o != null && GetChildrenByRole(MemberRole).DoMatch(o.GetChildrenByRole(MemberRole), match); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitCompilationUnit (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitCompilationUnit (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitCompilationUnit (this, data); } @@ -98,14 +125,45 @@ namespace ICSharpCode.NRefactory.CSharp /// /// Converts this compilation unit into a parsed file that can be stored in the type system. /// - public CSharpParsedFile ToTypeSystem() + public CSharpParsedFile ToTypeSystem () { - if (string.IsNullOrEmpty(this.FileName)) - throw new InvalidOperationException("Cannot use ToTypeSystem() on a compilation unit without file name."); - var v = new TypeSystemConvertVisitor(this.FileName); - v.VisitCompilationUnit(this, null); + if (string.IsNullOrEmpty (this.FileName)) + throw new InvalidOperationException ("Cannot use ToTypeSystem() on a compilation unit without file name."); + var v = new TypeSystemConvertVisitor (this.FileName); + v.VisitCompilationUnit (this); return v.ParsedFile; } + + public static CompilationUnit Parse (string text, string fileName = "", CompilerSettings settings = null, CancellationToken cancellationToken = default (CancellationToken)) + { + var parser = new CSharpParser (); + if (settings != null) + parser.CompilerSettings = settings; + return parser.Parse (text, fileName); + } + + public static CompilationUnit Parse (TextReader reader, string fileName = "", CompilerSettings settings = null, CancellationToken cancellationToken = default (CancellationToken)) + { + var parser = new CSharpParser (); + if (settings != null) + parser.CompilerSettings = settings; + return parser.Parse (reader, fileName, 0); + } + + public static CompilationUnit Parse (Stream stream, string fileName = "", CompilerSettings settings = null, CancellationToken cancellationToken = default (CancellationToken)) + { + var parser = new CSharpParser (); + if (settings != null) + parser.CompilerSettings = settings; + return parser.Parse (stream, fileName, 0); + } + + public static CompilationUnit Parse (ITextSource textSource, string fileName = "", CompilerSettings settings = null, CancellationToken cancellationToken = default (CancellationToken)) + { + var parser = new CSharpParser (); + if (settings != null) + parser.CompilerSettings = settings; + return parser.Parse (textSource, fileName, 0); + } } } - diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/ComposedType.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/ComposedType.cs index d70a478207..845f189d76 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/ComposedType.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/ComposedType.cs @@ -27,13 +27,14 @@ using System; using System.Collections.Generic; using System.Linq; using System.Text; +using ICSharpCode.NRefactory.TypeSystem; namespace ICSharpCode.NRefactory.CSharp { public class ComposedType : AstType { - public static readonly Role NullableRole = new Role("Nullable", CSharpTokenNode.Null); - public static readonly Role PointerRole = new Role("Pointer", CSharpTokenNode.Null); + public static readonly TokenRole NullableRole = new TokenRole("?"); + public static readonly TokenRole PointerRole = new TokenRole("*"); public static readonly Role ArraySpecifierRole = new Role("ArraySpecifier"); public AstType BaseType { @@ -46,7 +47,7 @@ namespace ICSharpCode.NRefactory.CSharp return !GetChildByRole(NullableRole).IsNull; } set { - SetChildByRole(NullableRole, value ? new CSharpTokenNode(TextLocation.Empty, 1) : null); + SetChildByRole(NullableRole, value ? new CSharpTokenNode(TextLocation.Empty) : null); } } @@ -63,7 +64,7 @@ namespace ICSharpCode.NRefactory.CSharp d--; } while (d < value) { - InsertChildBefore(GetChildByRole(PointerRole), new CSharpTokenNode(TextLocation.Empty, 1), PointerRole); + InsertChildBefore(GetChildByRole(PointerRole), new CSharpTokenNode(TextLocation.Empty), PointerRole); d++; } } @@ -73,7 +74,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildrenByRole (ArraySpecifierRole); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitComposedType (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitComposedType (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitComposedType (this, data); } @@ -114,6 +125,22 @@ namespace ICSharpCode.NRefactory.CSharp InsertChildBefore(this.ArraySpecifiers.FirstOrDefault(), new ArraySpecifier(dimensions), ArraySpecifierRole); return this; } + + public override ITypeReference ToTypeReference(SimpleNameLookupMode lookupMode = SimpleNameLookupMode.Type) + { + ITypeReference t = this.BaseType.ToTypeReference(lookupMode); + if (this.HasNullableSpecifier) { + t = NullableType.Create(t); + } + int pointerRank = this.PointerRank; + for (int i = 0; i < pointerRank; i++) { + t = new PointerTypeReference(t); + } + foreach (var a in this.ArraySpecifiers.Reverse()) { + t = new ArrayTypeReference(t, a.Dimensions); + } + return t; + } } /// @@ -149,7 +176,7 @@ namespace ICSharpCode.NRefactory.CSharp d--; } while (d < value) { - InsertChildBefore(GetChildByRole(Roles.Comma), new CSharpTokenNode(TextLocation.Empty, 1), Roles.Comma); + InsertChildBefore(GetChildByRole(Roles.Comma), new CSharpTokenNode(TextLocation.Empty), Roles.Comma); d++; } } @@ -159,7 +186,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.RBracket); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitArraySpecifier (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitArraySpecifier (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitArraySpecifier(this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/DepthFirstAstVisitor.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/DepthFirstAstVisitor.cs index ac04c51115..68bce6c35b 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/DepthFirstAstVisitor.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/DepthFirstAstVisitor.cs @@ -28,6 +28,1201 @@ using System; namespace ICSharpCode.NRefactory.CSharp { + /// + /// AST visitor with a default implementation that visits all node depth-first. + /// + public abstract class DepthFirstAstVisitor : IAstVisitor + { + protected virtual void VisitChildren (AstNode node) + { + AstNode next; + for (var child = node.FirstChild; child != null; child = next) { + // Store next to allow the loop to continue + // if the visitor removes/replaces child. + next = child.NextSibling; + child.AcceptVisitor (this); + } + } + + public virtual void VisitCompilationUnit (CompilationUnit unit) + { + VisitChildren (unit); + } + + public virtual void VisitComment(Comment comment) + { + VisitChildren(comment); + } + + public virtual void VisitNewLine(NewLineNode newLineNode) + { + VisitChildren(newLineNode); + } + + public virtual void VisitWhitespace(WhitespaceNode whitespaceNode) + { + VisitChildren(whitespaceNode); + } + + public virtual void VisitText(TextNode textNode) + { + VisitChildren(textNode); + } + + public virtual void VisitDocumentationReference (DocumentationReference documentationReference) + { + VisitChildren (documentationReference); + } + + public virtual void VisitPreProcessorDirective (PreProcessorDirective preProcessorDirective) + { + VisitChildren (preProcessorDirective); + } + + public virtual void VisitIdentifier (Identifier identifier) + { + VisitChildren (identifier); + } + + public virtual void VisitCSharpTokenNode (CSharpTokenNode token) + { + VisitChildren (token); + } + + public virtual void VisitPrimitiveType (PrimitiveType primitiveType) + { + VisitChildren (primitiveType); + } + + public virtual void VisitComposedType (ComposedType composedType) + { + VisitChildren (composedType); + } + + public virtual void VisitSimpleType(SimpleType simpleType) + { + VisitChildren (simpleType); + } + + public virtual void VisitMemberType(MemberType memberType) + { + VisitChildren (memberType); + } + + public virtual void VisitAttribute (Attribute attribute) + { + VisitChildren (attribute); + } + + public virtual void VisitAttributeSection (AttributeSection attributeSection) + { + VisitChildren (attributeSection); + } + + public virtual void VisitDelegateDeclaration (DelegateDeclaration delegateDeclaration) + { + VisitChildren (delegateDeclaration); + } + + public virtual void VisitNamespaceDeclaration (NamespaceDeclaration namespaceDeclaration) + { + VisitChildren (namespaceDeclaration); + } + + public virtual void VisitTypeDeclaration (TypeDeclaration typeDeclaration) + { + VisitChildren (typeDeclaration); + } + + public virtual void VisitTypeParameterDeclaration (TypeParameterDeclaration typeParameterDeclaration) + { + VisitChildren (typeParameterDeclaration); + } + + public virtual void VisitEnumMemberDeclaration (EnumMemberDeclaration enumMemberDeclaration) + { + VisitChildren (enumMemberDeclaration); + } + + public virtual void VisitUsingDeclaration (UsingDeclaration usingDeclaration) + { + VisitChildren (usingDeclaration); + } + + public virtual void VisitUsingAliasDeclaration (UsingAliasDeclaration usingDeclaration) + { + VisitChildren (usingDeclaration); + } + + public virtual void VisitExternAliasDeclaration(ExternAliasDeclaration externAliasDeclaration) + { + VisitChildren (externAliasDeclaration); + } + + public virtual void VisitConstructorDeclaration (ConstructorDeclaration constructorDeclaration) + { + VisitChildren (constructorDeclaration); + } + + public virtual void VisitConstructorInitializer (ConstructorInitializer constructorInitializer) + { + VisitChildren (constructorInitializer); + } + + public virtual void VisitDestructorDeclaration (DestructorDeclaration destructorDeclaration) + { + VisitChildren (destructorDeclaration); + } + + public virtual void VisitEventDeclaration (EventDeclaration eventDeclaration) + { + VisitChildren (eventDeclaration); + } + + public virtual void VisitCustomEventDeclaration (CustomEventDeclaration eventDeclaration) + { + VisitChildren (eventDeclaration); + } + + public virtual void VisitFieldDeclaration (FieldDeclaration fieldDeclaration) + { + VisitChildren (fieldDeclaration); + } + + public virtual void VisitFixedFieldDeclaration (FixedFieldDeclaration fixedFieldDeclaration) + { + VisitChildren (fixedFieldDeclaration); + } + + public virtual void VisitFixedVariableInitializer (FixedVariableInitializer fixedVariableInitializer) + { + VisitChildren (fixedVariableInitializer); + } + + public virtual void VisitIndexerDeclaration (IndexerDeclaration indexerDeclaration) + { + VisitChildren (indexerDeclaration); + } + + public virtual void VisitMethodDeclaration (MethodDeclaration methodDeclaration) + { + VisitChildren (methodDeclaration); + } + + public virtual void VisitOperatorDeclaration (OperatorDeclaration operatorDeclaration) + { + VisitChildren (operatorDeclaration); + } + + public virtual void VisitPropertyDeclaration (PropertyDeclaration propertyDeclaration) + { + VisitChildren (propertyDeclaration); + } + + public virtual void VisitAccessor (Accessor accessor) + { + VisitChildren (accessor); + } + + public virtual void VisitVariableInitializer (VariableInitializer variableInitializer) + { + VisitChildren (variableInitializer); + } + + public virtual void VisitParameterDeclaration (ParameterDeclaration parameterDeclaration) + { + VisitChildren (parameterDeclaration); + } + + public virtual void VisitConstraint (Constraint constraint) + { + VisitChildren (constraint); + } + + public virtual void VisitBlockStatement (BlockStatement blockStatement) + { + VisitChildren (blockStatement); + } + + public virtual void VisitExpressionStatement (ExpressionStatement expressionStatement) + { + VisitChildren (expressionStatement); + } + + public virtual void VisitBreakStatement (BreakStatement breakStatement) + { + VisitChildren (breakStatement); + } + + public virtual void VisitCheckedStatement (CheckedStatement checkedStatement) + { + VisitChildren (checkedStatement); + } + + public virtual void VisitContinueStatement (ContinueStatement continueStatement) + { + VisitChildren (continueStatement); + } + + public virtual void VisitDoWhileStatement (DoWhileStatement doWhileStatement) + { + VisitChildren (doWhileStatement); + } + + public virtual void VisitEmptyStatement (EmptyStatement emptyStatement) + { + VisitChildren (emptyStatement); + } + + public virtual void VisitFixedStatement (FixedStatement fixedStatement) + { + VisitChildren (fixedStatement); + } + + public virtual void VisitForeachStatement (ForeachStatement foreachStatement) + { + VisitChildren (foreachStatement); + } + + public virtual void VisitForStatement (ForStatement forStatement) + { + VisitChildren (forStatement); + } + + public virtual void VisitGotoCaseStatement (GotoCaseStatement gotoCaseStatement) + { + VisitChildren (gotoCaseStatement); + } + + public virtual void VisitGotoDefaultStatement (GotoDefaultStatement gotoDefaultStatement) + { + VisitChildren (gotoDefaultStatement); + } + + public virtual void VisitGotoStatement (GotoStatement gotoStatement) + { + VisitChildren (gotoStatement); + } + + public virtual void VisitIfElseStatement (IfElseStatement ifElseStatement) + { + VisitChildren (ifElseStatement); + } + + public virtual void VisitLabelStatement (LabelStatement labelStatement) + { + VisitChildren (labelStatement); + } + + public virtual void VisitLockStatement (LockStatement lockStatement) + { + VisitChildren (lockStatement); + } + + public virtual void VisitReturnStatement (ReturnStatement returnStatement) + { + VisitChildren (returnStatement); + } + + public virtual void VisitSwitchStatement (SwitchStatement switchStatement) + { + VisitChildren (switchStatement); + } + + public virtual void VisitSwitchSection (SwitchSection switchSection) + { + VisitChildren (switchSection); + } + + public virtual void VisitCaseLabel (CaseLabel caseLabel) + { + VisitChildren (caseLabel); + } + + public virtual void VisitThrowStatement (ThrowStatement throwStatement) + { + VisitChildren (throwStatement); + } + + public virtual void VisitTryCatchStatement (TryCatchStatement tryCatchStatement) + { + VisitChildren (tryCatchStatement); + } + + public virtual void VisitCatchClause (CatchClause catchClause) + { + VisitChildren (catchClause); + } + + public virtual void VisitUncheckedStatement (UncheckedStatement uncheckedStatement) + { + VisitChildren (uncheckedStatement); + } + + public virtual void VisitUnsafeStatement (UnsafeStatement unsafeStatement) + { + VisitChildren (unsafeStatement); + } + + public virtual void VisitUsingStatement (UsingStatement usingStatement) + { + VisitChildren (usingStatement); + } + + public virtual void VisitVariableDeclarationStatement (VariableDeclarationStatement variableDeclarationStatement) + { + VisitChildren (variableDeclarationStatement); + } + + public virtual void VisitWhileStatement (WhileStatement whileStatement) + { + VisitChildren (whileStatement); + } + + public virtual void VisitYieldBreakStatement (YieldBreakStatement yieldBreakStatement) + { + VisitChildren (yieldBreakStatement); + } + + public virtual void VisitYieldReturnStatement (YieldReturnStatement yieldReturnStatement) + { + VisitChildren (yieldReturnStatement); + } + + public virtual void VisitAnonymousMethodExpression (AnonymousMethodExpression anonymousMethodExpression) + { + VisitChildren (anonymousMethodExpression); + } + + public virtual void VisitLambdaExpression (LambdaExpression lambdaExpression) + { + VisitChildren (lambdaExpression); + } + + public virtual void VisitAssignmentExpression (AssignmentExpression assignmentExpression) + { + VisitChildren (assignmentExpression); + } + + public virtual void VisitBaseReferenceExpression (BaseReferenceExpression baseReferenceExpression) + { + VisitChildren (baseReferenceExpression); + } + + public virtual void VisitBinaryOperatorExpression (BinaryOperatorExpression binaryOperatorExpression) + { + VisitChildren (binaryOperatorExpression); + } + + public virtual void VisitCastExpression (CastExpression castExpression) + { + VisitChildren (castExpression); + } + + public virtual void VisitCheckedExpression (CheckedExpression checkedExpression) + { + VisitChildren (checkedExpression); + } + + public virtual void VisitConditionalExpression (ConditionalExpression conditionalExpression) + { + VisitChildren (conditionalExpression); + } + + public virtual void VisitIdentifierExpression (IdentifierExpression identifierExpression) + { + VisitChildren (identifierExpression); + } + + public virtual void VisitIndexerExpression (IndexerExpression indexerExpression) + { + VisitChildren (indexerExpression); + } + + public virtual void VisitInvocationExpression (InvocationExpression invocationExpression) + { + VisitChildren (invocationExpression); + } + + public virtual void VisitDirectionExpression (DirectionExpression directionExpression) + { + VisitChildren (directionExpression); + } + + public virtual void VisitMemberReferenceExpression (MemberReferenceExpression memberReferenceExpression) + { + VisitChildren (memberReferenceExpression); + } + + public virtual void VisitNullReferenceExpression (NullReferenceExpression nullReferenceExpression) + { + VisitChildren (nullReferenceExpression); + } + + public virtual void VisitObjectCreateExpression (ObjectCreateExpression objectCreateExpression) + { + VisitChildren (objectCreateExpression); + } + + public virtual void VisitAnonymousTypeCreateExpression(AnonymousTypeCreateExpression anonymousTypeCreateExpression) + { + VisitChildren (anonymousTypeCreateExpression); + } + + public virtual void VisitArrayCreateExpression (ArrayCreateExpression arrayCreateExpression) + { + VisitChildren (arrayCreateExpression); + } + + public virtual void VisitParenthesizedExpression (ParenthesizedExpression parenthesizedExpression) + { + VisitChildren (parenthesizedExpression); + } + + public virtual void VisitPointerReferenceExpression (PointerReferenceExpression pointerReferenceExpression) + { + VisitChildren (pointerReferenceExpression); + } + + public virtual void VisitPrimitiveExpression(PrimitiveExpression primitiveExpression) + { + VisitChildren (primitiveExpression); + } + + public virtual void VisitSizeOfExpression (SizeOfExpression sizeOfExpression) + { + VisitChildren (sizeOfExpression); + } + + public virtual void VisitStackAllocExpression (StackAllocExpression stackAllocExpression) + { + VisitChildren (stackAllocExpression); + } + + public virtual void VisitThisReferenceExpression(ThisReferenceExpression thisReferenceExpression) + { + VisitChildren (thisReferenceExpression); + } + + public virtual void VisitTypeOfExpression (TypeOfExpression typeOfExpression) + { + VisitChildren (typeOfExpression); + } + + public virtual void VisitTypeReferenceExpression(TypeReferenceExpression typeReferenceExpression) + { + VisitChildren (typeReferenceExpression); + } + + public virtual void VisitUnaryOperatorExpression (UnaryOperatorExpression unaryOperatorExpression) + { + VisitChildren (unaryOperatorExpression); + } + + public virtual void VisitUncheckedExpression (UncheckedExpression uncheckedExpression) + { + VisitChildren (uncheckedExpression); + } + + public virtual void VisitQueryExpression(QueryExpression queryExpression) + { + VisitChildren (queryExpression); + } + + public virtual void VisitQueryContinuationClause(QueryContinuationClause queryContinuationClause) + { + VisitChildren (queryContinuationClause); + } + + public virtual void VisitQueryFromClause(QueryFromClause queryFromClause) + { + VisitChildren (queryFromClause); + } + + public virtual void VisitQueryLetClause(QueryLetClause queryLetClause) + { + VisitChildren (queryLetClause); + } + + public virtual void VisitQueryWhereClause(QueryWhereClause queryWhereClause) + { + VisitChildren (queryWhereClause); + } + + public virtual void VisitQueryJoinClause(QueryJoinClause queryJoinClause) + { + VisitChildren (queryJoinClause); + } + + public virtual void VisitQueryOrderClause(QueryOrderClause queryOrderClause) + { + VisitChildren (queryOrderClause); + } + + public virtual void VisitQueryOrdering(QueryOrdering queryOrdering) + { + VisitChildren (queryOrdering); + } + + public virtual void VisitQuerySelectClause(QuerySelectClause querySelectClause) + { + VisitChildren (querySelectClause); + } + + public virtual void VisitQueryGroupClause(QueryGroupClause queryGroupClause) + { + VisitChildren (queryGroupClause); + } + + public virtual void VisitAsExpression (AsExpression asExpression) + { + VisitChildren (asExpression); + } + + public virtual void VisitIsExpression (IsExpression isExpression) + { + VisitChildren (isExpression); + } + + public virtual void VisitDefaultValueExpression (DefaultValueExpression defaultValueExpression) + { + VisitChildren (defaultValueExpression); + } + + public virtual void VisitUndocumentedExpression (UndocumentedExpression undocumentedExpression) + { + VisitChildren (undocumentedExpression); + } + + public virtual void VisitArrayInitializerExpression (ArrayInitializerExpression arrayInitializerExpression) + { + VisitChildren (arrayInitializerExpression); + } + + public virtual void VisitArraySpecifier (ArraySpecifier arraySpecifier) + { + VisitChildren (arraySpecifier); + } + + public virtual void VisitNamedArgumentExpression (NamedArgumentExpression namedArgumentExpression) + { + VisitChildren (namedArgumentExpression); + } + + public virtual void VisitNamedExpression (NamedExpression namedExpression) + { + VisitChildren (namedExpression); + } + + public virtual void VisitEmptyExpression (EmptyExpression emptyExpression) + { + VisitChildren (emptyExpression); + } + + public virtual void VisitPatternPlaceholder(AstNode placeholder, PatternMatching.Pattern pattern) + { + VisitChildren (placeholder); + } + } + + /// + /// AST visitor with a default implementation that visits all node depth-first. + /// + public abstract class DepthFirstAstVisitor : IAstVisitor + { + protected virtual T VisitChildren (AstNode node) + { + AstNode next; + for (var child = node.FirstChild; child != null; child = next) { + // Store next to allow the loop to continue + // if the visitor removes/replaces child. + next = child.NextSibling; + child.AcceptVisitor (this); + } + return default (T); + } + + public virtual T VisitCompilationUnit (CompilationUnit unit) + { + return VisitChildren (unit); + } + + public virtual T VisitComment (Comment comment) + { + return VisitChildren (comment); + } + + public virtual T VisitNewLine(NewLineNode newLineNode) + { + return VisitChildren(newLineNode); + } + + public virtual T VisitWhitespace(WhitespaceNode whitespaceNode) + { + return VisitChildren(whitespaceNode); + } + + public virtual T VisitText(TextNode textNode) + { + return VisitChildren(textNode); + } + + public virtual T VisitDocumentationReference (DocumentationReference documentationReference) + { + return VisitChildren (documentationReference); + } + + public virtual T VisitPreProcessorDirective (PreProcessorDirective preProcessorDirective) + { + return VisitChildren (preProcessorDirective); + } + + public virtual T VisitIdentifier (Identifier identifier) + { + return VisitChildren (identifier); + } + + public virtual T VisitCSharpTokenNode (CSharpTokenNode token) + { + return VisitChildren (token); + } + + public virtual T VisitPrimitiveType (PrimitiveType primitiveType) + { + return VisitChildren (primitiveType); + } + + public virtual T VisitComposedType (ComposedType composedType) + { + return VisitChildren (composedType); + } + + public virtual T VisitSimpleType(SimpleType simpleType) + { + return VisitChildren (simpleType); + } + + public virtual T VisitMemberType(MemberType memberType) + { + return VisitChildren (memberType); + } + + public virtual T VisitAttribute (Attribute attribute) + { + return VisitChildren (attribute); + } + + public virtual T VisitAttributeSection (AttributeSection attributeSection) + { + return VisitChildren (attributeSection); + } + + public virtual T VisitDelegateDeclaration (DelegateDeclaration delegateDeclaration) + { + return VisitChildren (delegateDeclaration); + } + + public virtual T VisitNamespaceDeclaration (NamespaceDeclaration namespaceDeclaration) + { + return VisitChildren (namespaceDeclaration); + } + + public virtual T VisitTypeDeclaration (TypeDeclaration typeDeclaration) + { + return VisitChildren (typeDeclaration); + } + + public virtual T VisitTypeParameterDeclaration (TypeParameterDeclaration typeParameterDeclaration) + { + return VisitChildren (typeParameterDeclaration); + } + + public virtual T VisitEnumMemberDeclaration (EnumMemberDeclaration enumMemberDeclaration) + { + return VisitChildren (enumMemberDeclaration); + } + + public virtual T VisitUsingDeclaration (UsingDeclaration usingDeclaration) + { + return VisitChildren (usingDeclaration); + } + + public virtual T VisitUsingAliasDeclaration (UsingAliasDeclaration usingDeclaration) + { + return VisitChildren (usingDeclaration); + } + + public virtual T VisitExternAliasDeclaration(ExternAliasDeclaration externAliasDeclaration) + { + return VisitChildren (externAliasDeclaration); + } + + public virtual T VisitConstructorDeclaration (ConstructorDeclaration constructorDeclaration) + { + return VisitChildren (constructorDeclaration); + } + + public virtual T VisitConstructorInitializer (ConstructorInitializer constructorInitializer) + { + return VisitChildren (constructorInitializer); + } + + public virtual T VisitDestructorDeclaration (DestructorDeclaration destructorDeclaration) + { + return VisitChildren (destructorDeclaration); + } + + public virtual T VisitEventDeclaration (EventDeclaration eventDeclaration) + { + return VisitChildren (eventDeclaration); + } + + public virtual T VisitCustomEventDeclaration (CustomEventDeclaration eventDeclaration) + { + return VisitChildren (eventDeclaration); + } + + public virtual T VisitFieldDeclaration (FieldDeclaration fieldDeclaration) + { + return VisitChildren (fieldDeclaration); + } + + public virtual T VisitFixedFieldDeclaration (FixedFieldDeclaration fixedFieldDeclaration) + { + return VisitChildren (fixedFieldDeclaration); + } + + public virtual T VisitFixedVariableInitializer (FixedVariableInitializer fixedVariableInitializer) + { + return VisitChildren (fixedVariableInitializer); + } + + public virtual T VisitIndexerDeclaration (IndexerDeclaration indexerDeclaration) + { + return VisitChildren (indexerDeclaration); + } + + public virtual T VisitMethodDeclaration (MethodDeclaration methodDeclaration) + { + return VisitChildren (methodDeclaration); + } + + public virtual T VisitOperatorDeclaration (OperatorDeclaration operatorDeclaration) + { + return VisitChildren (operatorDeclaration); + } + + public virtual T VisitPropertyDeclaration (PropertyDeclaration propertyDeclaration) + { + return VisitChildren (propertyDeclaration); + } + + public virtual T VisitAccessor (Accessor accessor) + { + return VisitChildren (accessor); + } + + public virtual T VisitVariableInitializer (VariableInitializer variableInitializer) + { + return VisitChildren (variableInitializer); + } + + public virtual T VisitParameterDeclaration (ParameterDeclaration parameterDeclaration) + { + return VisitChildren (parameterDeclaration); + } + + public virtual T VisitConstraint (Constraint constraint) + { + return VisitChildren (constraint); + } + + public virtual T VisitBlockStatement (BlockStatement blockStatement) + { + return VisitChildren (blockStatement); + } + + public virtual T VisitExpressionStatement (ExpressionStatement expressionStatement) + { + return VisitChildren (expressionStatement); + } + + public virtual T VisitBreakStatement (BreakStatement breakStatement) + { + return VisitChildren (breakStatement); + } + + public virtual T VisitCheckedStatement (CheckedStatement checkedStatement) + { + return VisitChildren (checkedStatement); + } + + public virtual T VisitContinueStatement (ContinueStatement continueStatement) + { + return VisitChildren (continueStatement); + } + + public virtual T VisitDoWhileStatement (DoWhileStatement doWhileStatement) + { + return VisitChildren (doWhileStatement); + } + + public virtual T VisitEmptyStatement (EmptyStatement emptyStatement) + { + return VisitChildren (emptyStatement); + } + + public virtual T VisitFixedStatement (FixedStatement fixedStatement) + { + return VisitChildren (fixedStatement); + } + + public virtual T VisitForeachStatement (ForeachStatement foreachStatement) + { + return VisitChildren (foreachStatement); + } + + public virtual T VisitForStatement (ForStatement forStatement) + { + return VisitChildren (forStatement); + } + + public virtual T VisitGotoCaseStatement (GotoCaseStatement gotoCaseStatement) + { + return VisitChildren (gotoCaseStatement); + } + + public virtual T VisitGotoDefaultStatement (GotoDefaultStatement gotoDefaultStatement) + { + return VisitChildren (gotoDefaultStatement); + } + + public virtual T VisitGotoStatement (GotoStatement gotoStatement) + { + return VisitChildren (gotoStatement); + } + + public virtual T VisitIfElseStatement (IfElseStatement ifElseStatement) + { + return VisitChildren (ifElseStatement); + } + + public virtual T VisitLabelStatement (LabelStatement labelStatement) + { + return VisitChildren (labelStatement); + } + + public virtual T VisitLockStatement (LockStatement lockStatement) + { + return VisitChildren (lockStatement); + } + + public virtual T VisitReturnStatement (ReturnStatement returnStatement) + { + return VisitChildren (returnStatement); + } + + public virtual T VisitSwitchStatement (SwitchStatement switchStatement) + { + return VisitChildren (switchStatement); + } + + public virtual T VisitSwitchSection (SwitchSection switchSection) + { + return VisitChildren (switchSection); + } + + public virtual T VisitCaseLabel (CaseLabel caseLabel) + { + return VisitChildren (caseLabel); + } + + public virtual T VisitThrowStatement (ThrowStatement throwStatement) + { + return VisitChildren (throwStatement); + } + + public virtual T VisitTryCatchStatement (TryCatchStatement tryCatchStatement) + { + return VisitChildren (tryCatchStatement); + } + + public virtual T VisitCatchClause (CatchClause catchClause) + { + return VisitChildren (catchClause); + } + + public virtual T VisitUncheckedStatement (UncheckedStatement uncheckedStatement) + { + return VisitChildren (uncheckedStatement); + } + + public virtual T VisitUnsafeStatement (UnsafeStatement unsafeStatement) + { + return VisitChildren (unsafeStatement); + } + + public virtual T VisitUsingStatement (UsingStatement usingStatement) + { + return VisitChildren (usingStatement); + } + + public virtual T VisitVariableDeclarationStatement (VariableDeclarationStatement variableDeclarationStatement) + { + return VisitChildren (variableDeclarationStatement); + } + + public virtual T VisitWhileStatement (WhileStatement whileStatement) + { + return VisitChildren (whileStatement); + } + + public virtual T VisitYieldBreakStatement (YieldBreakStatement yieldBreakStatement) + { + return VisitChildren (yieldBreakStatement); + } + + public virtual T VisitYieldReturnStatement (YieldReturnStatement yieldReturnStatement) + { + return VisitChildren (yieldReturnStatement); + } + + public virtual T VisitAnonymousMethodExpression (AnonymousMethodExpression anonymousMethodExpression) + { + return VisitChildren (anonymousMethodExpression); + } + + public virtual T VisitLambdaExpression (LambdaExpression lambdaExpression) + { + return VisitChildren (lambdaExpression); + } + + public virtual T VisitAssignmentExpression (AssignmentExpression assignmentExpression) + { + return VisitChildren (assignmentExpression); + } + + public virtual T VisitBaseReferenceExpression (BaseReferenceExpression baseReferenceExpression) + { + return VisitChildren (baseReferenceExpression); + } + + public virtual T VisitBinaryOperatorExpression (BinaryOperatorExpression binaryOperatorExpression) + { + return VisitChildren (binaryOperatorExpression); + } + + public virtual T VisitCastExpression (CastExpression castExpression) + { + return VisitChildren (castExpression); + } + + public virtual T VisitCheckedExpression (CheckedExpression checkedExpression) + { + return VisitChildren (checkedExpression); + } + + public virtual T VisitConditionalExpression (ConditionalExpression conditionalExpression) + { + return VisitChildren (conditionalExpression); + } + + public virtual T VisitIdentifierExpression (IdentifierExpression identifierExpression) + { + return VisitChildren (identifierExpression); + } + + public virtual T VisitIndexerExpression (IndexerExpression indexerExpression) + { + return VisitChildren (indexerExpression); + } + + public virtual T VisitInvocationExpression (InvocationExpression invocationExpression) + { + return VisitChildren (invocationExpression); + } + + public virtual T VisitDirectionExpression (DirectionExpression directionExpression) + { + return VisitChildren (directionExpression); + } + + public virtual T VisitMemberReferenceExpression (MemberReferenceExpression memberReferenceExpression) + { + return VisitChildren (memberReferenceExpression); + } + + public virtual T VisitNullReferenceExpression (NullReferenceExpression nullReferenceExpression) + { + return VisitChildren (nullReferenceExpression); + } + + public virtual T VisitObjectCreateExpression (ObjectCreateExpression objectCreateExpression) + { + return VisitChildren (objectCreateExpression); + } + + public virtual T VisitAnonymousTypeCreateExpression(AnonymousTypeCreateExpression anonymousTypeCreateExpression) + { + return VisitChildren (anonymousTypeCreateExpression); + } + + public virtual T VisitArrayCreateExpression (ArrayCreateExpression arrayCreateExpression) + { + return VisitChildren (arrayCreateExpression); + } + + public virtual T VisitParenthesizedExpression (ParenthesizedExpression parenthesizedExpression) + { + return VisitChildren (parenthesizedExpression); + } + + public virtual T VisitPointerReferenceExpression (PointerReferenceExpression pointerReferenceExpression) + { + return VisitChildren (pointerReferenceExpression); + } + + public virtual T VisitPrimitiveExpression(PrimitiveExpression primitiveExpression) + { + return VisitChildren (primitiveExpression); + } + + public virtual T VisitSizeOfExpression (SizeOfExpression sizeOfExpression) + { + return VisitChildren (sizeOfExpression); + } + + public virtual T VisitStackAllocExpression (StackAllocExpression stackAllocExpression) + { + return VisitChildren (stackAllocExpression); + } + + public virtual T VisitThisReferenceExpression(ThisReferenceExpression thisReferenceExpression) + { + return VisitChildren (thisReferenceExpression); + } + + public virtual T VisitTypeOfExpression (TypeOfExpression typeOfExpression) + { + return VisitChildren (typeOfExpression); + } + + public virtual T VisitTypeReferenceExpression(TypeReferenceExpression typeReferenceExpression) + { + return VisitChildren (typeReferenceExpression); + } + + public virtual T VisitUnaryOperatorExpression (UnaryOperatorExpression unaryOperatorExpression) + { + return VisitChildren (unaryOperatorExpression); + } + + public virtual T VisitUncheckedExpression (UncheckedExpression uncheckedExpression) + { + return VisitChildren (uncheckedExpression); + } + + public virtual T VisitQueryExpression(QueryExpression queryExpression) + { + return VisitChildren (queryExpression); + } + + public virtual T VisitQueryContinuationClause(QueryContinuationClause queryContinuationClause) + { + return VisitChildren (queryContinuationClause); + } + + public virtual T VisitQueryFromClause(QueryFromClause queryFromClause) + { + return VisitChildren (queryFromClause); + } + + public virtual T VisitQueryLetClause(QueryLetClause queryLetClause) + { + return VisitChildren (queryLetClause); + } + + public virtual T VisitQueryWhereClause(QueryWhereClause queryWhereClause) + { + return VisitChildren (queryWhereClause); + } + + public virtual T VisitQueryJoinClause(QueryJoinClause queryJoinClause) + { + return VisitChildren (queryJoinClause); + } + + public virtual T VisitQueryOrderClause(QueryOrderClause queryOrderClause) + { + return VisitChildren (queryOrderClause); + } + + public virtual T VisitQueryOrdering(QueryOrdering queryOrdering) + { + return VisitChildren (queryOrdering); + } + + public virtual T VisitQuerySelectClause(QuerySelectClause querySelectClause) + { + return VisitChildren (querySelectClause); + } + + public virtual T VisitQueryGroupClause(QueryGroupClause queryGroupClause) + { + return VisitChildren (queryGroupClause); + } + + public virtual T VisitAsExpression (AsExpression asExpression) + { + return VisitChildren (asExpression); + } + + public virtual T VisitIsExpression (IsExpression isExpression) + { + return VisitChildren (isExpression); + } + + public virtual T VisitDefaultValueExpression (DefaultValueExpression defaultValueExpression) + { + return VisitChildren (defaultValueExpression); + } + + public virtual T VisitUndocumentedExpression (UndocumentedExpression undocumentedExpression) + { + return VisitChildren (undocumentedExpression); + } + + public virtual T VisitArrayInitializerExpression (ArrayInitializerExpression arrayInitializerExpression) + { + return VisitChildren (arrayInitializerExpression); + } + + public virtual T VisitArraySpecifier (ArraySpecifier arraySpecifier) + { + return VisitChildren (arraySpecifier); + } + + public virtual T VisitNamedArgumentExpression (NamedArgumentExpression namedArgumentExpression) + { + return VisitChildren (namedArgumentExpression); + } + + public virtual T VisitNamedExpression (NamedExpression namedExpression) + { + return VisitChildren (namedExpression); + } + + public virtual T VisitEmptyExpression (EmptyExpression emptyExpression) + { + return VisitChildren (emptyExpression); + } + + public virtual T VisitPatternPlaceholder(AstNode placeholder, PatternMatching.Pattern pattern) + { + return VisitChildren (placeholder); + } + } + /// /// AST visitor with a default implementation that visits all node depth-first. /// @@ -55,6 +1250,26 @@ namespace ICSharpCode.NRefactory.CSharp return VisitChildren (comment, data); } + public virtual S VisitNewLine(NewLineNode newLineNode, T data) + { + return VisitChildren(newLineNode, data); + } + + public virtual S VisitWhitespace(WhitespaceNode whitespaceNode, T data) + { + return VisitChildren(whitespaceNode, data); + } + + public virtual S VisitText(TextNode textNode, T data) + { + return VisitChildren(textNode, data); + } + + public virtual S VisitDocumentationReference (DocumentationReference documentationReference, T data) + { + return VisitChildren (documentationReference, data); + } + public virtual S VisitPreProcessorDirective (PreProcessorDirective preProcessorDirective, T data) { return VisitChildren (preProcessorDirective, data); diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/DocumentationReference.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/DocumentationReference.cs new file mode 100644 index 0000000000..9c599ce6b3 --- /dev/null +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/DocumentationReference.cs @@ -0,0 +1,149 @@ +// Copyright (c) AlphaSierraPapa for the SharpDevelop Team +// +// Permission is hereby granted, free of charge, to any person obtaining a copy of this +// software and associated documentation files (the "Software"), to deal in the Software +// without restriction, including without limitation the rights to use, copy, modify, merge, +// publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons +// to whom the Software is furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in all copies or +// substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, +// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR +// PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE +// FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +// DEALINGS IN THE SOFTWARE. + +using System; +using ICSharpCode.NRefactory.TypeSystem; + +namespace ICSharpCode.NRefactory.CSharp +{ + /// + /// Represents a 'cref' reference in XML documentation. + /// + public class DocumentationReference : AstNode + { + public static readonly Role DeclaringTypeRole = new Role("DeclaringType", AstType.Null); + public static readonly Role ConversionOperatorReturnTypeRole = new Role("ConversionOperatorReturnType", AstType.Null); + + EntityType entityType; + OperatorType operatorType; + bool hasParameterList; + + /// + /// Gets/Sets the entity type. + /// Possible values are: + /// EntityType.Operator for operators, + /// EntityType.Indexer for indexers, + /// EntityType.TypeDefinition for references to primitive types, + /// and EntityType.None for everything else. + /// + public EntityType EntityType { + get { return entityType; } + set { + ThrowIfFrozen(); + entityType = value; + } + } + + /// + /// Gets/Sets the operator type. + /// This property is only used when EntityType==Operator. + /// + public OperatorType OperatorType { + get { return operatorType; } + set { + ThrowIfFrozen(); + operatorType = value; + } + } + + /// + /// Gets/Sets whether a parameter list was provided. + /// + public bool HasParameterList { + get { return hasParameterList; } + set { + ThrowIfFrozen(); + hasParameterList = value; + } + } + + public override NodeType NodeType { + get { return NodeType.Unknown; } + } + + /// + /// Gets/Sets the declaring type. + /// + public AstType DeclaringType { + get { return GetChildByRole(DeclaringTypeRole); } + set { SetChildByRole(DeclaringTypeRole, value); } + } + + /// + /// Gets/sets the member name. + /// This property is only used when EntityType==None. + /// + public string MemberName { + get { return GetChildByRole(Roles.Identifier).Name; } + set { SetChildByRole(Roles.Identifier, Identifier.Create(value)); } + } + + /// + /// Gets/Sets the return type of conversion operators. + /// This property is only used when EntityType==Operator and OperatorType is explicit or implicit. + /// + public AstType ConversionOperatorReturnType { + get { return GetChildByRole(ConversionOperatorReturnTypeRole); } + set { SetChildByRole(ConversionOperatorReturnTypeRole, value); } + } + + public AstNodeCollection TypeArguments { + get { return GetChildrenByRole (Roles.TypeArgument); } + } + + public AstNodeCollection Parameters { + get { return GetChildrenByRole (Roles.Parameter); } + } + + protected internal override bool DoMatch(AstNode other, ICSharpCode.NRefactory.PatternMatching.Match match) + { + DocumentationReference o = other as DocumentationReference; + if (!(o != null && this.EntityType == o.EntityType && this.HasParameterList == o.HasParameterList)) + return false; + if (this.EntityType == EntityType.Operator) { + if (this.OperatorType != o.OperatorType) + return false; + if (this.OperatorType == OperatorType.Implicit || this.OperatorType == OperatorType.Explicit) { + if (!this.ConversionOperatorReturnType.DoMatch(o.ConversionOperatorReturnType, match)) + return false; + } + } else if (this.EntityType == EntityType.None) { + if (!MatchString(this.MemberName, o.MemberName)) + return false; + if (!this.TypeArguments.DoMatch(o.TypeArguments, match)) + return false; + } + return this.Parameters.DoMatch(o.Parameters, match); + } + + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitDocumentationReference (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitDocumentationReference (this); + } + + public override S AcceptVisitor(IAstVisitor visitor, T data) + { + return visitor.VisitDocumentationReference (this, data); + } + } +} diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/ErrorNode.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/ErrorNode.cs index 53dfd7126f..ee5f885215 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/ErrorNode.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/ErrorNode.cs @@ -58,7 +58,16 @@ namespace ICSharpCode.NRefactory.CSharp { } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return default (T); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { // nothing return default (S); diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/AnonymousMethodExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/AnonymousMethodExpression.cs index 91fc0c4177..07de16197a 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/AnonymousMethodExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/AnonymousMethodExpression.cs @@ -34,17 +34,26 @@ namespace ICSharpCode.NRefactory.CSharp /// public class AnonymousMethodExpression : Expression { - public readonly static Role AsyncModifierRole = LambdaExpression.AsyncModifierRole; + public readonly static TokenRole DelegateKeywordRole = new TokenRole ("delegate"); + public readonly static TokenRole AsyncModifierRole = LambdaExpression.AsyncModifierRole; - public bool IsAsync { get; set; } + bool isAsync; + + public bool IsAsync { + get { return isAsync; } + set { ThrowIfFrozen(); isAsync = value; } + } // used to tell the difference between delegate {} and delegate () {} + bool hasParameterList; + public bool HasParameterList { - get; set; + get { return hasParameterList; } + set { ThrowIfFrozen(); hasParameterList = value; } } public CSharpTokenNode DelegateToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (DelegateKeywordRole); } } public CSharpTokenNode LParToken { @@ -82,7 +91,17 @@ namespace ICSharpCode.NRefactory.CSharp { } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitAnonymousMethodExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitAnonymousMethodExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitAnonymousMethodExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/AnonymousTypeCreateExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/AnonymousTypeCreateExpression.cs index 496a2cfdb5..944bf61f56 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/AnonymousTypeCreateExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/AnonymousTypeCreateExpression.cs @@ -33,8 +33,10 @@ namespace ICSharpCode.NRefactory.CSharp /// public class AnonymousTypeCreateExpression : Expression { + public readonly static TokenRole NewKeywordRole = new TokenRole ("new"); + public CSharpTokenNode NewToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (NewKeywordRole); } } public CSharpTokenNode LParToken { @@ -64,7 +66,17 @@ namespace ICSharpCode.NRefactory.CSharp { } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitAnonymousTypeCreateExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitAnonymousTypeCreateExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitAnonymousTypeCreateExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ArrayCreateExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ArrayCreateExpression.cs index f9bee2a68b..c9f1b2a62b 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ArrayCreateExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ArrayCreateExpression.cs @@ -26,9 +26,14 @@ namespace ICSharpCode.NRefactory.CSharp /// public class ArrayCreateExpression : Expression { + public readonly static TokenRole NewKeywordRole = new TokenRole ("new"); public readonly static Role AdditionalArraySpecifierRole = new Role("AdditionalArraySpecifier"); public readonly static Role InitializerRole = new Role("Initializer", ArrayInitializerExpression.Null); + public CSharpTokenNode NewToken { + get { return GetChildByRole (NewKeywordRole); } + } + public AstType Type { get { return GetChildByRole (Roles.Type); } set { SetChildByRole (Roles.Type, value); } @@ -51,7 +56,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (InitializerRole, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitArrayCreateExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitArrayCreateExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitArrayCreateExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ArrayInitializerExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ArrayInitializerExpression.cs index d4858d8b23..ffb3712f26 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ArrayInitializerExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ArrayInitializerExpression.cs @@ -58,7 +58,16 @@ namespace ICSharpCode.NRefactory.CSharp } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return default (T); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return default (S); } @@ -82,7 +91,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.RBrace); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitArrayInitializerExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitArrayInitializerExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitArrayInitializerExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/AsExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/AsExpression.cs index 59f4652da9..cf9cfb4f9a 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/AsExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/AsExpression.cs @@ -31,13 +31,15 @@ namespace ICSharpCode.NRefactory.CSharp /// public class AsExpression : Expression { + public readonly static TokenRole AsKeywordRole = new TokenRole ("as"); + public Expression Expression { get { return GetChildByRole (Roles.Expression); } set { SetChildByRole(Roles.Expression, value); } } public CSharpTokenNode AsToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (AsKeywordRole); } } public AstType Type { @@ -55,7 +57,17 @@ namespace ICSharpCode.NRefactory.CSharp AddChild (type, Roles.Type); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitAsExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitAsExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitAsExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/AssignmentExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/AssignmentExpression.cs index c214eedc16..14021d3236 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/AssignmentExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/AssignmentExpression.cs @@ -36,9 +36,20 @@ namespace ICSharpCode.NRefactory.CSharp { // reuse roles from BinaryOperatorExpression public readonly static Role LeftRole = BinaryOperatorExpression.LeftRole; - public readonly static Role OperatorRole = BinaryOperatorExpression.OperatorRole; public readonly static Role RightRole = BinaryOperatorExpression.RightRole; + public readonly static TokenRole AssignRole = new TokenRole ("="); + public readonly static TokenRole AddRole = new TokenRole ("+="); + public readonly static TokenRole SubtractRole = new TokenRole ("-="); + public readonly static TokenRole MultiplyRole = new TokenRole ("*="); + public readonly static TokenRole DivideRole = new TokenRole ("/="); + public readonly static TokenRole ModulusRole = new TokenRole ("%="); + public readonly static TokenRole ShiftLeftRole = new TokenRole ("<<="); + public readonly static TokenRole ShiftRightRole = new TokenRole (">>="); + public readonly static TokenRole BitwiseAndRole = new TokenRole ("&="); + public readonly static TokenRole BitwiseOrRole = new TokenRole ("|="); + public readonly static TokenRole ExclusiveOrRole = new TokenRole ("^="); + public AssignmentExpression() { } @@ -67,7 +78,7 @@ namespace ICSharpCode.NRefactory.CSharp } public CSharpTokenNode OperatorToken { - get { return GetChildByRole (OperatorRole); } + get { return GetChildByRole (GetOperatorRole(Operator)); } } public Expression Right { @@ -75,7 +86,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole(RightRole, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitAssignmentExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitAssignmentExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitAssignmentExpression (this, data); } @@ -87,31 +108,31 @@ namespace ICSharpCode.NRefactory.CSharp && this.Left.DoMatch(o.Left, match) && this.Right.DoMatch(o.Right, match); } - public static string GetOperatorSymbol(AssignmentOperatorType op) + public static TokenRole GetOperatorRole(AssignmentOperatorType op) { switch (op) { case AssignmentOperatorType.Assign: - return "="; + return AssignRole; case AssignmentOperatorType.Add: - return "+="; + return AddRole; case AssignmentOperatorType.Subtract: - return "-="; + return SubtractRole; case AssignmentOperatorType.Multiply: - return "*="; + return MultiplyRole; case AssignmentOperatorType.Divide: - return "/="; + return DivideRole; case AssignmentOperatorType.Modulus: - return "%="; + return ModulusRole; case AssignmentOperatorType.ShiftLeft: - return "<<="; + return ShiftLeftRole; case AssignmentOperatorType.ShiftRight: - return ">>="; + return ShiftRightRole; case AssignmentOperatorType.BitwiseAnd: - return "&="; + return BitwiseAndRole; case AssignmentOperatorType.BitwiseOr: - return "|="; + return BitwiseOrRole; case AssignmentOperatorType.ExclusiveOr: - return "^="; + return ExclusiveOrRole; default: throw new NotSupportedException("Invalid value for AssignmentOperatorType"); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/BaseReferenceExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/BaseReferenceExpression.cs index 2214e3eaac..399c36c22b 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/BaseReferenceExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/BaseReferenceExpression.cs @@ -47,7 +47,17 @@ namespace ICSharpCode.NRefactory.CSharp } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitBaseReferenceExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitBaseReferenceExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitBaseReferenceExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/BinaryOperatorExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/BinaryOperatorExpression.cs index 6a2d94ed79..819d90f534 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/BinaryOperatorExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/BinaryOperatorExpression.cs @@ -34,8 +34,27 @@ namespace ICSharpCode.NRefactory.CSharp /// public class BinaryOperatorExpression : Expression { + public readonly static TokenRole BitwiseAndRole = new TokenRole ("&"); + public readonly static TokenRole BitwiseOrRole = new TokenRole ("|"); + public readonly static TokenRole ConditionalAndRole = new TokenRole ("&&"); + public readonly static TokenRole ConditionalOrRole = new TokenRole ("||"); + public readonly static TokenRole ExclusiveOrRole = new TokenRole ("^"); + public readonly static TokenRole GreaterThanRole = new TokenRole (">"); + public readonly static TokenRole GreaterThanOrEqualRole = new TokenRole (">="); + public readonly static TokenRole EqualityRole = new TokenRole ("=="); + public readonly static TokenRole InEqualityRole = new TokenRole ("!="); + public readonly static TokenRole LessThanRole = new TokenRole ("<"); + public readonly static TokenRole LessThanOrEqualRole = new TokenRole ("<="); + public readonly static TokenRole AddRole = new TokenRole ("+"); + public readonly static TokenRole SubtractRole = new TokenRole ("-"); + public readonly static TokenRole MultiplyRole = new TokenRole ("*"); + public readonly static TokenRole DivideRole = new TokenRole ("/"); + public readonly static TokenRole ModulusRole = new TokenRole ("%"); + public readonly static TokenRole ShiftLeftRole = new TokenRole ("<<"); + public readonly static TokenRole ShiftRightRole = new TokenRole (">>"); + public readonly static TokenRole NullCoalescingRole = new TokenRole ("??"); + public readonly static Role LeftRole = new Role("Left", Expression.Null); - public readonly static Role OperatorRole = new Role("Operator", CSharpTokenNode.Null); public readonly static Role RightRole = new Role("Right", Expression.Null); public BinaryOperatorExpression() @@ -60,15 +79,25 @@ namespace ICSharpCode.NRefactory.CSharp } public CSharpTokenNode OperatorToken { - get { return GetChildByRole (OperatorRole); } + get { return GetChildByRole (GetOperatorRole (Operator)); } } public Expression Right { get { return GetChildByRole (RightRole); } - set { SetChildByRole(RightRole, value); } + set { SetChildByRole (RightRole, value); } + } + + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitBinaryOperatorExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitBinaryOperatorExpression (this); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitBinaryOperatorExpression (this, data); } @@ -80,47 +109,47 @@ namespace ICSharpCode.NRefactory.CSharp && this.Left.DoMatch(o.Left, match) && this.Right.DoMatch(o.Right, match); } - public static string GetOperatorSymbol(BinaryOperatorType op) + public static TokenRole GetOperatorRole (BinaryOperatorType op) { switch (op) { case BinaryOperatorType.BitwiseAnd: - return "&"; + return BitwiseAndRole; case BinaryOperatorType.BitwiseOr: - return "|"; + return BitwiseOrRole; case BinaryOperatorType.ConditionalAnd: - return "&&"; + return ConditionalAndRole; case BinaryOperatorType.ConditionalOr: - return "||"; + return ConditionalOrRole; case BinaryOperatorType.ExclusiveOr: - return "^"; + return ExclusiveOrRole; case BinaryOperatorType.GreaterThan: - return ">"; + return GreaterThanRole; case BinaryOperatorType.GreaterThanOrEqual: - return ">="; + return GreaterThanOrEqualRole; case BinaryOperatorType.Equality: - return "=="; + return EqualityRole; case BinaryOperatorType.InEquality: - return "!="; + return InEqualityRole; case BinaryOperatorType.LessThan: - return "<"; + return LessThanRole; case BinaryOperatorType.LessThanOrEqual: - return "<="; + return LessThanOrEqualRole; case BinaryOperatorType.Add: - return "+"; + return AddRole; case BinaryOperatorType.Subtract: - return "-"; + return SubtractRole; case BinaryOperatorType.Multiply: - return "*"; + return MultiplyRole; case BinaryOperatorType.Divide: - return "/"; + return DivideRole; case BinaryOperatorType.Modulus: - return "%"; + return ModulusRole; case BinaryOperatorType.ShiftLeft: - return "<<"; + return ShiftLeftRole; case BinaryOperatorType.ShiftRight: - return ">>"; + return ShiftRightRole; case BinaryOperatorType.NullCoalescing: - return "??"; + return NullCoalescingRole; default: throw new NotSupportedException("Invalid value for BinaryOperatorType"); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/CastExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/CastExpression.cs index 6a3f1ceb93..96f41bcf34 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/CastExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/CastExpression.cs @@ -59,7 +59,17 @@ namespace ICSharpCode.NRefactory.CSharp AddChild (expression, Roles.Expression); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitCastExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitCastExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitCastExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/CheckedExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/CheckedExpression.cs index f9fd9ab9db..66bdcb54dc 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/CheckedExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/CheckedExpression.cs @@ -31,8 +31,10 @@ namespace ICSharpCode.NRefactory.CSharp /// public class CheckedExpression : Expression { + public readonly static TokenRole CheckedKeywordRole = new TokenRole ("checked"); + public CSharpTokenNode CheckedToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (CheckedKeywordRole); } } public CSharpTokenNode LParToken { @@ -57,7 +59,17 @@ namespace ICSharpCode.NRefactory.CSharp AddChild (expression, Roles.Expression); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitCheckedExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitCheckedExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitCheckedExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ConditionalExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ConditionalExpression.cs index 3a98ed7ed7..fb2d5cb594 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ConditionalExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ConditionalExpression.cs @@ -32,9 +32,9 @@ namespace ICSharpCode.NRefactory.CSharp public class ConditionalExpression : Expression { public readonly static Role ConditionRole = Roles.Condition; - public readonly static Role QuestionMarkRole = new Role("QuestionMark", CSharpTokenNode.Null); + public readonly static TokenRole QuestionMarkRole = new TokenRole("?"); public readonly static Role TrueRole = new Role("True", Expression.Null); - public readonly static Role ColonRole = Roles.Colon; + public readonly static TokenRole ColonRole = Roles.Colon; public readonly static Role FalseRole = new Role("False", Expression.Null); public Expression Condition { @@ -71,7 +71,17 @@ namespace ICSharpCode.NRefactory.CSharp AddChild (falseExpression, FalseRole); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitConditionalExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitConditionalExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitConditionalExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/DefaultValueExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/DefaultValueExpression.cs index 28fb4adc45..0aab343f3c 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/DefaultValueExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/DefaultValueExpression.cs @@ -31,8 +31,10 @@ namespace ICSharpCode.NRefactory.CSharp /// public class DefaultValueExpression : Expression { + public readonly static TokenRole DefaultKeywordRole = new TokenRole ("default"); + public CSharpTokenNode DefaultToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (DefaultKeywordRole); } } public CSharpTokenNode LParToken { @@ -57,7 +59,17 @@ namespace ICSharpCode.NRefactory.CSharp AddChild (type, Roles.Type); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitDefaultValueExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitDefaultValueExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitDefaultValueExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/DirectionExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/DirectionExpression.cs index d99182d335..a17c117bbc 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/DirectionExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/DirectionExpression.cs @@ -38,13 +38,16 @@ namespace ICSharpCode.NRefactory.CSharp /// public class DirectionExpression : Expression { + public readonly static TokenRole RefKeywordRole = new TokenRole ("ref"); + public readonly static TokenRole OutKeywordRole = new TokenRole ("out"); + public FieldDirection FieldDirection { get; set; } public CSharpTokenNode FieldDirectionToken { - get { return GetChildByRole (Roles.Keyword); } + get { return FieldDirection == ICSharpCode.NRefactory.CSharp.FieldDirection.Ref ? GetChildByRole (RefKeywordRole) : GetChildByRole (OutKeywordRole); } } public Expression Expression { @@ -62,7 +65,17 @@ namespace ICSharpCode.NRefactory.CSharp AddChild (expression, Roles.Expression); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitDirectionExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitDirectionExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitDirectionExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/EmptyExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/EmptyExpression.cs index e333090eb2..7dc5da777e 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/EmptyExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/EmptyExpression.cs @@ -30,7 +30,7 @@ namespace ICSharpCode.NRefactory.CSharp /// /// Type<[EMPTY]> /// - public class EmptyExpression : Expression, IRelocatable + public class EmptyExpression : Expression { TextLocation location; @@ -55,14 +55,17 @@ namespace ICSharpCode.NRefactory.CSharp this.location = location; } - #region IRelocationable implementation - void IRelocatable.SetStartLocation (TextLocation startLocation) + public override void AcceptVisitor (IAstVisitor visitor) { - this.location = startLocation; + visitor.VisitEmptyExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitEmptyExpression (this); } - #endregion - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitEmptyExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ErrorExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ErrorExpression.cs index 0b8b0c7278..bd6506c81a 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ErrorExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ErrorExpression.cs @@ -1,4 +1,4 @@ -// +// // ErrorExpression.cs // // Author: @@ -52,8 +52,18 @@ namespace ICSharpCode.NRefactory.CSharp this.location = location; } + public override void AcceptVisitor (IAstVisitor visitor) + { + // nothing + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + // nothing + return default (T); + } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override S AcceptVisitor (IAstVisitor visitor, T data) { // nothing return default(S); diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/Expression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/Expression.cs index f61e67f0b7..d9bbed466e 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/Expression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/Expression.cs @@ -41,7 +41,16 @@ namespace ICSharpCode.NRefactory.CSharp } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return default (T); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return default (S); } @@ -72,7 +81,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return NodeType.Pattern; } } - public override S AcceptVisitor(IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitPatternPlaceholder(this, child); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitPatternPlaceholder(this, child); + } + + public override S AcceptVisitor(IAstVisitor visitor, T data) { return visitor.VisitPatternPlaceholder(this, child, data); } @@ -202,30 +221,15 @@ namespace ICSharpCode.NRefactory.CSharp return new CastExpression { Type = type, Expression = this }; } - public CastExpression CastTo(Type type) - { - return new CastExpression { Type = AstType.Create(type), Expression = this }; - } - public AsExpression CastAs(AstType type) { return new AsExpression { Type = type, Expression = this }; } - public AsExpression CastAs(Type type) - { - return new AsExpression { Type = AstType.Create(type), Expression = this }; - } - public IsExpression IsType(AstType type) { return new IsExpression { Type = type, Expression = this }; } - - public IsExpression IsType(Type type) - { - return new IsExpression { Type = AstType.Create(type), Expression = this }; - } #endregion } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/IdentifierExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/IdentifierExpression.cs index 892807fd3b..1b567de94d 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/IdentifierExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/IdentifierExpression.cs @@ -52,7 +52,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole (Roles.Identifier).Name; } set { - SetChildByRole(Roles.Identifier, CSharp.Identifier.Create (value, TextLocation.Empty)); + SetChildByRole(Roles.Identifier, CSharp.Identifier.Create (value)); } } @@ -60,7 +60,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildrenByRole (Roles.TypeArgument); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitIdentifierExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitIdentifierExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitIdentifierExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/IndexerExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/IndexerExpression.cs index 1d7d9a4642..cbc80c2cf0 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/IndexerExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/IndexerExpression.cs @@ -68,7 +68,17 @@ namespace ICSharpCode.NRefactory.CSharp { } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitIndexerExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitIndexerExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitIndexerExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/InvocationExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/InvocationExpression.cs index b609ae8864..ad768d5419 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/InvocationExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/InvocationExpression.cs @@ -50,7 +50,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.RPar); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitInvocationExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitInvocationExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitInvocationExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/IsExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/IsExpression.cs index d01fe48b1b..163cef0412 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/IsExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/IsExpression.cs @@ -31,13 +31,15 @@ namespace ICSharpCode.NRefactory.CSharp /// public class IsExpression : Expression { + public readonly static TokenRole IsKeywordRole = new TokenRole ("is"); + public Expression Expression { get { return GetChildByRole(Roles.Expression); } set { SetChildByRole(Roles.Expression, value); } } public CSharpTokenNode IsToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (IsKeywordRole); } } public AstType Type { @@ -45,7 +47,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole(Roles.Type, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitIsExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitIsExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitIsExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/LambdaExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/LambdaExpression.cs index 2b6a39d6b9..001ffcb323 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/LambdaExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/LambdaExpression.cs @@ -33,11 +33,16 @@ namespace ICSharpCode.NRefactory.CSharp /// public class LambdaExpression : Expression { - public readonly static Role AsyncModifierRole = new Role("AsyncModifier", CSharpTokenNode.Null); - public readonly static Role ArrowRole = new Role("Arrow", CSharpTokenNode.Null); + public readonly static TokenRole AsyncModifierRole = new TokenRole ("async"); + public readonly static TokenRole ArrowRole = new TokenRole ("=>"); public static readonly Role BodyRole = new Role("Body", AstNode.Null); - public bool IsAsync { get; set; } + bool isAsync; + + public bool IsAsync { + get { return isAsync; } + set { ThrowIfFrozen(); isAsync = value; } + } public AstNodeCollection Parameters { get { return GetChildrenByRole (Roles.Parameter); } @@ -52,7 +57,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (BodyRole, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitLambdaExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitLambdaExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitLambdaExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/MemberReferenceExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/MemberReferenceExpression.cs index cf0c1808fa..98bc50232e 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/MemberReferenceExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/MemberReferenceExpression.cs @@ -43,7 +43,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole (Roles.Identifier).Name; } set { - SetChildByRole (Roles.Identifier, Identifier.Create (value, TextLocation.Empty)); + SetChildByRole (Roles.Identifier, Identifier.Create (value)); } } @@ -87,7 +87,17 @@ namespace ICSharpCode.NRefactory.CSharp { } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitMemberReferenceExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitMemberReferenceExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitMemberReferenceExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/NamedArgumentExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/NamedArgumentExpression.cs index 6b63038632..b7b8ada50a 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/NamedArgumentExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/NamedArgumentExpression.cs @@ -41,7 +41,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole (Roles.Identifier).Name; } set { - SetChildByRole(Roles.Identifier, CSharp.Identifier.Create (value, TextLocation.Empty)); + SetChildByRole(Roles.Identifier, CSharp.Identifier.Create (value)); } } @@ -63,7 +63,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (Roles.Expression, value); } } - public override S AcceptVisitor(IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitNamedArgumentExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitNamedArgumentExpression (this); + } + + public override S AcceptVisitor(IAstVisitor visitor, T data) { return visitor.VisitNamedArgumentExpression(this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/NamedExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/NamedExpression.cs index eb57e75e15..663e3686d4 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/NamedExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/NamedExpression.cs @@ -51,7 +51,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole (Roles.Identifier).Name; } set { - SetChildByRole(Roles.Identifier, CSharp.Identifier.Create (value, TextLocation.Empty)); + SetChildByRole(Roles.Identifier, CSharp.Identifier.Create (value)); } } @@ -73,7 +73,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (Roles.Expression, value); } } - public override S AcceptVisitor(IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitNamedExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitNamedExpression (this); + } + + public override S AcceptVisitor(IAstVisitor visitor, T data) { return visitor.VisitNamedExpression(this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/NullReferenceExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/NullReferenceExpression.cs index 3a92c97f30..a7a3ab7b5b 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/NullReferenceExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/NullReferenceExpression.cs @@ -53,7 +53,17 @@ namespace ICSharpCode.NRefactory.CSharp this.location = location; } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitNullReferenceExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitNullReferenceExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitNullReferenceExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ObjectCreateExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ObjectCreateExpression.cs index 0e72c04b11..a9665f8c77 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ObjectCreateExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ObjectCreateExpression.cs @@ -33,10 +33,11 @@ namespace ICSharpCode.NRefactory.CSharp /// public class ObjectCreateExpression : Expression { + public readonly static TokenRole NewKeywordRole = new TokenRole ("new"); public readonly static Role InitializerRole = ArrayCreateExpression.InitializerRole; public CSharpTokenNode NewToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (NewKeywordRole); } } public AstType Type { @@ -79,7 +80,17 @@ namespace ICSharpCode.NRefactory.CSharp { } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitObjectCreateExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitObjectCreateExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitObjectCreateExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ParenthesizedExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ParenthesizedExpression.cs index 8c32a42ddf..7dddcb3fb3 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ParenthesizedExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ParenthesizedExpression.cs @@ -1,6 +1,6 @@ // // ParenthesizedExpression.cs -// +// // Author: // Mike Krüger // @@ -53,7 +53,17 @@ namespace ICSharpCode.NRefactory.CSharp Expression = expr; } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitParenthesizedExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitParenthesizedExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitParenthesizedExpression (this, data); } @@ -63,5 +73,26 @@ namespace ICSharpCode.NRefactory.CSharp ParenthesizedExpression o = other as ParenthesizedExpression; return o != null && this.Expression.DoMatch(o.Expression, match); } + + /// + /// Gets whether the expression acts like a parenthesized expression, + /// i.e. whether information about the expected type (for lambda type inference) flows + /// into the inner expression. + /// + /// Returns true for ParenthesizedExpression, CheckedExpression or UncheckedExpression; false otherwise. + public static bool ActsAsParenthesizedExpression(AstNode expression) + { + return expression is ParenthesizedExpression || expression is CheckedExpression || expression is UncheckedExpression; + } + + /// + /// Unpacks the given expression if it is a ParenthesizedExpression, CheckedExpression or UncheckedExpression. + /// + public static Expression UnpackParenthesizedExpression(Expression expr) + { + while (ActsAsParenthesizedExpression(expr)) + expr = expr.GetChildByRole(Roles.Expression); + return expr; + } } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/PointerReferenceExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/PointerReferenceExpression.cs index a1b7f051f1..a7152fd1db 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/PointerReferenceExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/PointerReferenceExpression.cs @@ -33,19 +33,23 @@ namespace ICSharpCode.NRefactory.CSharp /// public class PointerReferenceExpression : Expression { - public readonly static Role ArrowRole = new Role("Arrow", CSharpTokenNode.Null); + public readonly static TokenRole ArrowRole = new TokenRole ("->"); public Expression Target { get { return GetChildByRole (Roles.TargetExpression); } set { SetChildByRole(Roles.TargetExpression, value); } } + public CSharpTokenNode ArrowToken { + get { return GetChildByRole (ArrowRole); } + } + public string MemberName { get { return GetChildByRole (Roles.Identifier).Name; } set { - SetChildByRole(Roles.Identifier, Identifier.Create (value, TextLocation.Empty)); + SetChildByRole(Roles.Identifier, Identifier.Create (value)); } } @@ -53,7 +57,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildrenByRole (Roles.TypeArgument); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitPointerReferenceExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitPointerReferenceExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitPointerReferenceExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/PrimitiveExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/PrimitiveExpression.cs index 6e39fc2779..9f867fe1eb 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/PrimitiveExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/PrimitiveExpression.cs @@ -24,12 +24,14 @@ // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN // THE SOFTWARE. +using System; + namespace ICSharpCode.NRefactory.CSharp { /// /// Represents a literal value. /// - public class PrimitiveExpression : Expression, IRelocatable + public class PrimitiveExpression : Expression { public static readonly object AnyValue = new object(); @@ -47,20 +49,30 @@ namespace ICSharpCode.NRefactory.CSharp } } + object value; + public object Value { - get; - set; + get { return this.value; } + set { + ThrowIfFrozen(); + this.value = value; + } } public string LiteralValue { - get { - return literalValue; + get { return literalValue; } + set { + if (value == null) + throw new ArgumentNullException(); + ThrowIfFrozen(); + literalValue = value; } } public PrimitiveExpression (object value) { this.Value = value; + this.literalValue = ""; } public PrimitiveExpression (object value, string literalValue) @@ -76,14 +88,17 @@ namespace ICSharpCode.NRefactory.CSharp this.literalValue = literalValue ?? ""; } - #region IRelocationable implementation - void IRelocatable.SetStartLocation (TextLocation startLocation) + public override void AcceptVisitor (IAstVisitor visitor) { - this.startLocation = startLocation; + visitor.VisitPrimitiveExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitPrimitiveExpression (this); } - #endregion - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitPrimitiveExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/QueryExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/QueryExpression.cs index 5e7ffaa67d..e5f36ae10d 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/QueryExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/QueryExpression.cs @@ -36,7 +36,16 @@ namespace ICSharpCode.NRefactory.CSharp } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return default (T); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return default (S); } @@ -52,7 +61,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildrenByRole(ClauseRole); } } - public override S AcceptVisitor(IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitQueryExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitQueryExpression (this); + } + + public override S AcceptVisitor(IAstVisitor visitor, T data) { return visitor.VisitQueryExpression (this, data); } @@ -92,7 +111,7 @@ namespace ICSharpCode.NRefactory.CSharp public class QueryContinuationClause : QueryClause { public static readonly Role PrecedingQueryRole = new Role("PrecedingQuery", QueryExpression.Null); - public static readonly Role IntoKeywordRole = Roles.Keyword; + public static readonly TokenRole IntoKeywordRole = new TokenRole ("into"); public QueryExpression PrecedingQuery { get { return GetChildByRole(PrecedingQueryRole); } @@ -104,7 +123,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole (Roles.Identifier).Name; } set { - SetChildByRole(Roles.Identifier, CSharp.Identifier.Create (value, TextLocation.Empty)); + SetChildByRole(Roles.Identifier, CSharp.Identifier.Create (value)); } } @@ -112,7 +131,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.Identifier); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitQueryContinuationClause (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitQueryContinuationClause (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitQueryContinuationClause (this, data); } @@ -126,8 +155,8 @@ namespace ICSharpCode.NRefactory.CSharp public class QueryFromClause : QueryClause { - public static readonly Role FromKeywordRole = Roles.Keyword; - public static readonly Role InKeywordRole = Roles.InKeyword; + public static readonly TokenRole FromKeywordRole = new TokenRole ("from"); + public static readonly TokenRole InKeywordRole = new TokenRole ("in"); public AstType Type { get { return GetChildByRole (Roles.Type); } @@ -139,7 +168,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole (Roles.Identifier).Name; } set { - SetChildByRole(Roles.Identifier, CSharp.Identifier.Create (value, TextLocation.Empty)); + SetChildByRole(Roles.Identifier, CSharp.Identifier.Create (value)); } } @@ -152,7 +181,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (Roles.Expression, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitQueryFromClause (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitQueryFromClause (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitQueryFromClause (this, data); } @@ -167,8 +206,10 @@ namespace ICSharpCode.NRefactory.CSharp public class QueryLetClause : QueryClause { + public readonly static TokenRole LetKeywordRole = new TokenRole ("let"); + public CSharpTokenNode LetKeyword { - get { return GetChildByRole(Roles.Keyword); } + get { return GetChildByRole(LetKeywordRole); } } public string Identifier { @@ -176,7 +217,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole(Roles.Identifier).Name; } set { - SetChildByRole(Roles.Identifier, CSharp.Identifier.Create (value, TextLocation.Empty)); + SetChildByRole(Roles.Identifier, CSharp.Identifier.Create (value)); } } @@ -193,7 +234,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole(Roles.Expression, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitQueryLetClause (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitQueryLetClause (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitQueryLetClause (this, data); } @@ -208,8 +259,10 @@ namespace ICSharpCode.NRefactory.CSharp public class QueryWhereClause : QueryClause { + public readonly static TokenRole WhereKeywordRole = new TokenRole ("where"); + public CSharpTokenNode WhereKeyword { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (WhereKeywordRole); } } public Expression Condition { @@ -217,7 +270,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (Roles.Condition, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitQueryWhereClause (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitQueryWhereClause (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitQueryWhereClause (this, data); } @@ -234,16 +297,16 @@ namespace ICSharpCode.NRefactory.CSharp /// public class QueryJoinClause : QueryClause { - public static readonly Role JoinKeywordRole = Roles.Keyword; + public static readonly TokenRole JoinKeywordRole = new TokenRole ("join"); public static readonly Role TypeRole = Roles.Type; public static readonly Role JoinIdentifierRole = Roles.Identifier; - public static readonly Role InKeywordRole = Roles.InKeyword; + public static readonly TokenRole InKeywordRole = new TokenRole ("in"); public static readonly Role InExpressionRole = Roles.Expression; - public static readonly Role OnKeywordRole = new Role("OnKeyword", CSharpTokenNode.Null); + public static readonly TokenRole OnKeywordRole = new TokenRole ("on"); public static readonly Role OnExpressionRole = new Role("OnExpression", Expression.Null); - public static readonly Role EqualsKeywordRole = new Role("EqualsKeyword", CSharpTokenNode.Null); + public static readonly TokenRole EqualsKeywordRole = new TokenRole ("equals"); public static readonly Role EqualsExpressionRole = new Role("EqualsExpression", Expression.Null); - public static readonly Role IntoKeywordRole = new Role("IntoKeyword", CSharpTokenNode.Null); + public static readonly TokenRole IntoKeywordRole = new TokenRole ("into"); public static readonly Role IntoIdentifierRole = new Role("IntoIdentifier", Identifier.Null); public bool IsGroupJoin { @@ -264,7 +327,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole(JoinIdentifierRole).Name; } set { - SetChildByRole(JoinIdentifierRole, Identifier.Create (value, TextLocation.Empty)); + SetChildByRole(JoinIdentifierRole, Identifier.Create (value)); } } @@ -308,7 +371,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole (IntoIdentifierRole).Name; } set { - SetChildByRole(IntoIdentifierRole, Identifier.Create (value, TextLocation.Empty)); + SetChildByRole(IntoIdentifierRole, Identifier.Create (value)); } } @@ -316,7 +379,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole(IntoIdentifierRole); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitQueryJoinClause (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitQueryJoinClause (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitQueryJoinClause (this, data); } @@ -334,17 +407,28 @@ namespace ICSharpCode.NRefactory.CSharp public class QueryOrderClause : QueryClause { + public static readonly TokenRole OrderbyKeywordRole = new TokenRole ("orderby"); public static readonly Role OrderingRole = new Role("Ordering"); - public CSharpTokenNode Keyword { - get { return GetChildByRole (Roles.Keyword); } + public CSharpTokenNode OrderbyToken { + get { return GetChildByRole (OrderbyKeywordRole); } } public AstNodeCollection Orderings { get { return GetChildrenByRole (OrderingRole); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitQueryOrderClause (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitQueryOrderClause (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitQueryOrderClause (this, data); } @@ -358,6 +442,9 @@ namespace ICSharpCode.NRefactory.CSharp public class QueryOrdering : AstNode { + public readonly static TokenRole AscendingKeywordRole = new TokenRole ("ascending"); + public readonly static TokenRole DescendingKeywordRole = new TokenRole ("descending"); + public override NodeType NodeType { get { return NodeType.Unknown; } } @@ -373,10 +460,20 @@ namespace ICSharpCode.NRefactory.CSharp } public CSharpTokenNode DirectionToken { - get { return GetChildByRole (Roles.Keyword); } + get { return Direction == QueryOrderingDirection.Ascending ? GetChildByRole (AscendingKeywordRole) : GetChildByRole (DescendingKeywordRole); } + } + + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitQueryOrdering (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitQueryOrdering (this); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitQueryOrdering (this, data); } @@ -397,8 +494,10 @@ namespace ICSharpCode.NRefactory.CSharp public class QuerySelectClause : QueryClause { + public readonly static TokenRole SelectKeywordRole = new TokenRole ("select"); + public CSharpTokenNode SelectKeyword { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (SelectKeywordRole); } } public Expression Expression { @@ -406,7 +505,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (Roles.Expression, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitQuerySelectClause (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitQuerySelectClause (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitQuerySelectClause (this, data); } @@ -420,9 +529,9 @@ namespace ICSharpCode.NRefactory.CSharp public class QueryGroupClause : QueryClause { - public static readonly Role GroupKeywordRole = Roles.Keyword; + public static readonly TokenRole GroupKeywordRole = new TokenRole ("group"); public static readonly Role ProjectionRole = new Role("Projection", Expression.Null); - public static readonly Role ByKeywordRole = new Role("ByKeyword", CSharpTokenNode.Null); + public static readonly TokenRole ByKeywordRole = new TokenRole ("by"); public static readonly Role KeyRole = new Role("Key", Expression.Null); public CSharpTokenNode GroupKeyword { @@ -443,7 +552,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (KeyRole, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitQueryGroupClause (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitQueryGroupClause (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitQueryGroupClause (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/SizeOfExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/SizeOfExpression.cs index eba12d3e02..8a794960ce 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/SizeOfExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/SizeOfExpression.cs @@ -31,8 +31,10 @@ namespace ICSharpCode.NRefactory.CSharp /// public class SizeOfExpression : Expression { + public readonly static TokenRole SizeofKeywordRole = new TokenRole ("sizeof"); + public CSharpTokenNode SizeOfToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (SizeofKeywordRole); } } public CSharpTokenNode LParToken { @@ -57,7 +59,17 @@ namespace ICSharpCode.NRefactory.CSharp AddChild (type, Roles.Type); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitSizeOfExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitSizeOfExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitSizeOfExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/StackAllocExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/StackAllocExpression.cs index f69d92286d..ad9f58c1bc 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/StackAllocExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/StackAllocExpression.cs @@ -31,8 +31,10 @@ namespace ICSharpCode.NRefactory.CSharp /// public class StackAllocExpression : Expression { + public readonly static TokenRole StackallocKeywordRole = new TokenRole ("stackalloc"); + public CSharpTokenNode StackAllocToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (StackallocKeywordRole); } } public AstType Type { @@ -53,7 +55,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.RBracket); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitStackAllocExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitStackAllocExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitStackAllocExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ThisReferenceExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ThisReferenceExpression.cs index 7d2bd33ebf..481ef6658f 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ThisReferenceExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/ThisReferenceExpression.cs @@ -46,8 +46,18 @@ namespace ICSharpCode.NRefactory.CSharp return new TextLocation (Location.Line, Location.Column + "this".Length); } } - - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitThisReferenceExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitThisReferenceExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitThisReferenceExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/TypeOfExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/TypeOfExpression.cs index 31e0b7bf3b..fd2e93ab81 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/TypeOfExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/TypeOfExpression.cs @@ -32,8 +32,10 @@ namespace ICSharpCode.NRefactory.CSharp /// public class TypeOfExpression : Expression { + public readonly static TokenRole TypeofKeywordRole = new TokenRole ("typeof"); + public CSharpTokenNode TypeOfToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (TypeofKeywordRole); } } public CSharpTokenNode LParToken { @@ -58,7 +60,17 @@ namespace ICSharpCode.NRefactory.CSharp AddChild (type, Roles.Type); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitTypeOfExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitTypeOfExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitTypeOfExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/TypeReferenceExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/TypeReferenceExpression.cs index c568f824a9..129e1364a6 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/TypeReferenceExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/TypeReferenceExpression.cs @@ -31,7 +31,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole(Roles.Type, value); } } - public override S AcceptVisitor(IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitTypeReferenceExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitTypeReferenceExpression (this); + } + + public override S AcceptVisitor(IAstVisitor visitor, T data) { return visitor.VisitTypeReferenceExpression(this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/UnaryOperatorExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/UnaryOperatorExpression.cs index 4e6851d981..70d178728d 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/UnaryOperatorExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/UnaryOperatorExpression.cs @@ -34,7 +34,15 @@ namespace ICSharpCode.NRefactory.CSharp /// public class UnaryOperatorExpression : Expression { - public readonly static Role OperatorRole = BinaryOperatorExpression.OperatorRole; + public readonly static TokenRole NotRole = new TokenRole ("!"); + public readonly static TokenRole BitNotRole = new TokenRole ("~"); + public readonly static TokenRole MinusRole = new TokenRole ("-"); + public readonly static TokenRole PlusRole = new TokenRole ("+"); + public readonly static TokenRole IncrementRole = new TokenRole ("++"); + public readonly static TokenRole DecrementRole = new TokenRole ("--"); + public readonly static TokenRole DereferenceRole = new TokenRole ("*"); + public readonly static TokenRole AddressOfRole = new TokenRole ("&"); + public readonly static TokenRole AwaitRole = new TokenRole ("await"); public UnaryOperatorExpression() { @@ -52,7 +60,7 @@ namespace ICSharpCode.NRefactory.CSharp } public CSharpTokenNode OperatorToken { - get { return GetChildByRole (OperatorRole); } + get { return GetChildByRole (GetOperatorRole (Operator)); } } public Expression Expression { @@ -60,7 +68,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (Roles.Expression, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitUnaryOperatorExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitUnaryOperatorExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitUnaryOperatorExpression (this, data); } @@ -72,29 +90,29 @@ namespace ICSharpCode.NRefactory.CSharp && this.Expression.DoMatch(o.Expression, match); } - public static string GetOperatorSymbol(UnaryOperatorType op) + public static TokenRole GetOperatorRole(UnaryOperatorType op) { switch (op) { case UnaryOperatorType.Not: - return "!"; + return NotRole; case UnaryOperatorType.BitNot: - return "~"; + return BitNotRole; case UnaryOperatorType.Minus: - return "-"; + return MinusRole; case UnaryOperatorType.Plus: - return "+"; + return PlusRole; case UnaryOperatorType.Increment: case UnaryOperatorType.PostIncrement: - return "++"; + return IncrementRole; case UnaryOperatorType.PostDecrement: case UnaryOperatorType.Decrement: - return "--"; + return DecrementRole; case UnaryOperatorType.Dereference: - return "*"; + return DereferenceRole; case UnaryOperatorType.AddressOf: - return "&"; + return AddressOfRole; case UnaryOperatorType.Await: - return "await"; + return AwaitRole; default: throw new NotSupportedException("Invalid value for UnaryOperatorType"); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/UncheckedExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/UncheckedExpression.cs index 6bd835775b..5b8686a26c 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/UncheckedExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/UncheckedExpression.cs @@ -31,8 +31,10 @@ namespace ICSharpCode.NRefactory.CSharp /// public class UncheckedExpression : Expression { + public readonly static TokenRole UncheckedKeywordRole = new TokenRole ("unchecked"); + public CSharpTokenNode UncheckedToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (UncheckedKeywordRole); } } public CSharpTokenNode LParToken { @@ -57,7 +59,17 @@ namespace ICSharpCode.NRefactory.CSharp AddChild (expression, Roles.Expression); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitUncheckedExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitUncheckedExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitUncheckedExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/UndocumentedExpression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/UndocumentedExpression.cs index 3a6d628553..0efc0d70fe 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/UndocumentedExpression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Expressions/UndocumentedExpression.cs @@ -42,12 +42,30 @@ namespace ICSharpCode.NRefactory.CSharp /// public class UndocumentedExpression : Expression { + public readonly static TokenRole ArglistKeywordRole = new TokenRole ("__arglist"); + public readonly static TokenRole RefvalueKeywordRole = new TokenRole ("__refvalue"); + public readonly static TokenRole ReftypeKeywordRole = new TokenRole ("__reftype"); + public readonly static TokenRole MakerefKeywordRole = new TokenRole ("__makeref"); + public UndocumentedExpressionType UndocumentedExpressionType { get; set; } public CSharpTokenNode UndocumentedToken { - get { return GetChildByRole (Roles.Keyword); } + get { + switch (UndocumentedExpressionType) { + case ICSharpCode.NRefactory.CSharp.UndocumentedExpressionType.ArgListAccess: + case ICSharpCode.NRefactory.CSharp.UndocumentedExpressionType.ArgList: + return GetChildByRole (ArglistKeywordRole); + case ICSharpCode.NRefactory.CSharp.UndocumentedExpressionType.RefValue: + return GetChildByRole (RefvalueKeywordRole); + case ICSharpCode.NRefactory.CSharp.UndocumentedExpressionType.RefType: + return GetChildByRole (ReftypeKeywordRole); + case ICSharpCode.NRefactory.CSharp.UndocumentedExpressionType.MakeRef: + return GetChildByRole (MakerefKeywordRole); + } + return CSharpTokenNode.Null; + } } public CSharpTokenNode LParToken { @@ -62,7 +80,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.RPar); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitUndocumentedExpression (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitUndocumentedExpression (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitUndocumentedExpression (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/Attribute.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/Attribute.cs index 4335103388..74fd9d7e30 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/Attribute.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/Attribute.cs @@ -54,7 +54,17 @@ namespace ICSharpCode.NRefactory.CSharp set; } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitAttribute (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitAttribute (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitAttribute (this, data); } @@ -69,9 +79,8 @@ namespace ICSharpCode.NRefactory.CSharp { if (IsNull) return "Null"; - var w = new System.IO.StringWriter (); - AcceptVisitor (new CSharpOutputVisitor (w, new CSharpFormattingOptions ()), null); - return w.ToString (); + else + return GetText(); } } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/AttributeSection.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/AttributeSection.cs index cf142593cb..cd065b9c14 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/AttributeSection.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/AttributeSection.cs @@ -54,7 +54,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return NodeType.Pattern; } } - public override S AcceptVisitor(IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitPatternPlaceholder (this, child); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitPatternPlaceholder (this, child); + } + + public override S AcceptVisitor(IAstVisitor visitor, T data) { return visitor.VisitPatternPlaceholder(this, child, data); } @@ -71,9 +81,6 @@ namespace ICSharpCode.NRefactory.CSharp } #endregion - public static readonly Role AttributeRole = new Role("Attribute"); - public static readonly Role TargetRole = new Role("Target", CSharpTokenNode.Null); - public override NodeType NodeType { get { return NodeType.Unknown; @@ -89,7 +96,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole (Roles.Identifier).Name; } set { - SetChildByRole (Roles.Identifier, CSharp.Identifier.Create (value, TextLocation.Empty)); + SetChildByRole (Roles.Identifier, CSharp.Identifier.Create (value)); } } @@ -103,14 +110,24 @@ namespace ICSharpCode.NRefactory.CSharp } public AstNodeCollection Attributes { - get { return base.GetChildrenByRole (AttributeRole); } + get { return base.GetChildrenByRole (Roles.Attribute); } } public CSharpTokenNode RBracketToken { get { return GetChildByRole (Roles.RBracket); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitAttributeSection (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitAttributeSection (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitAttributeSection (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/Comment.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/Comment.cs index b0e8ab5f22..83c00c9bf0 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/Comment.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/Comment.cs @@ -43,10 +43,14 @@ namespace ICSharpCode.NRefactory.CSharp /// /// Inactive code (code in non-taken "#if") /// - InactiveCode + InactiveCode, + /// + /// "/** */" comment + /// + MultiLineDocumentation } - public class Comment : AstNode, IRelocatable + public class Comment : AstNode { public override NodeType NodeType { get { @@ -54,19 +58,25 @@ namespace ICSharpCode.NRefactory.CSharp } } + CommentType commentType; + public CommentType CommentType { - get; - set; + get { return commentType; } + set { ThrowIfFrozen(); commentType = value; } } + bool startsLine; + public bool StartsLine { - get; - set; + get { return startsLine; } + set { ThrowIfFrozen(); startsLine = value; } } + string content; + public string Content { - get; - set; + get { return content; } + set { ThrowIfFrozen(); content = value; } } TextLocation startLocation; @@ -96,16 +106,17 @@ namespace ICSharpCode.NRefactory.CSharp this.endLocation = endLocation; } - #region IRelocationable implementation - void IRelocatable.SetStartLocation (TextLocation startLocation) + public override void AcceptVisitor (IAstVisitor visitor) { - int lineDelta = startLocation.Line - this.startLocation.Line; - endLocation = new TextLocation (endLocation.Line + lineDelta, lineDelta != 0 ? endLocation.Column : endLocation.Column + startLocation.Column - this.startLocation.Column); - this.startLocation = startLocation; + visitor.VisitComment (this); } - #endregion - - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitComment (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitComment (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/Constraint.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/Constraint.cs index 4994c215c8..cfd15f7afd 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/Constraint.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/Constraint.cs @@ -36,10 +36,6 @@ namespace ICSharpCode.NRefactory.CSharp /// public class Constraint : AstNode { - public readonly static Role ColonRole = TypeDeclaration.ColonRole; - public readonly static Role BaseTypeRole = TypeDeclaration.BaseTypeRole; - public readonly static Role TypeParameterRole = new Role ("TypeParameter", SimpleType.Null); - public override NodeType NodeType { get { return NodeType.Unknown; @@ -48,18 +44,29 @@ namespace ICSharpCode.NRefactory.CSharp public SimpleType TypeParameter { get { - return GetChildByRole (TypeParameterRole); + return GetChildByRole (Roles.ConstraintTypeParameter); } set { - SetChildByRole(TypeParameterRole, value); + SetChildByRole(Roles.ConstraintTypeParameter, value); } } public AstNodeCollection BaseTypes { - get { return GetChildrenByRole (BaseTypeRole); } + get { + return GetChildrenByRole(Roles.BaseType); } + } + + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitConstraint (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitConstraint (this); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitConstraint (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/DelegateDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/DelegateDeclaration.cs index c226d8ffd8..088afa90b3 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/DelegateDeclaration.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/DelegateDeclaration.cs @@ -24,45 +24,27 @@ // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN // THE SOFTWARE. -using System.Collections.Generic; -using System.Linq; +using ICSharpCode.NRefactory.TypeSystem; namespace ICSharpCode.NRefactory.CSharp { /// /// delegate ReturnType Name<TypeParameters>(Parameters) where Constraints; /// - public class DelegateDeclaration : AttributedNode + public class DelegateDeclaration : EntityDeclaration { public override NodeType NodeType { - get { - return NodeType.TypeDeclaration; - } + get { return NodeType.TypeDeclaration; } } - public AstType ReturnType { - get { return GetChildByRole (Roles.Type); } - set { SetChildByRole (Roles.Type, value); } + public override EntityType EntityType { + get { return EntityType.TypeDefinition; } } - public string Name { - get { - return GetChildByRole (Roles.Identifier).Name; - } - set { - SetChildByRole (Roles.Identifier, Identifier.Create (value, TextLocation.Empty)); - } + public CSharpTokenNode DelegateToken { + get { return GetChildByRole(Roles.DelegateKeyword); } } - - public Identifier NameToken { - get { - return GetChildByRole (Roles.Identifier); - } - set { - SetChildByRole (Roles.Identifier, value); - } - } - + public AstNodeCollection TypeParameters { get { return GetChildrenByRole (Roles.TypeParameter); } } @@ -83,7 +65,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildrenByRole (Roles.Constraint); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitDelegateDeclaration (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitDelegateDeclaration (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitDelegateDeclaration (this, data); } @@ -91,8 +83,8 @@ namespace ICSharpCode.NRefactory.CSharp protected internal override bool DoMatch(AstNode other, PatternMatching.Match match) { DelegateDeclaration o = other as DelegateDeclaration; - return o != null && this.MatchAttributesAndModifiers(o, match) - && this.ReturnType.DoMatch(o.ReturnType, match) && MatchString(this.Name, o.Name) + return o != null && MatchString(this.Name, o.Name) + && this.MatchAttributesAndModifiers(o, match) && this.ReturnType.DoMatch(o.ReturnType, match) && this.TypeParameters.DoMatch(o.TypeParameters, match) && this.Parameters.DoMatch(o.Parameters, match) && this.Constraints.DoMatch(o.Constraints, match); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/ExternAliasDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/ExternAliasDeclaration.cs index f238f1aa2b..9404d417f4 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/ExternAliasDeclaration.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/ExternAliasDeclaration.cs @@ -31,8 +31,6 @@ namespace ICSharpCode.NRefactory.CSharp /// public class ExternAliasDeclaration : AstNode { - public static readonly Role AliasRole = new Role ("Alias", CSharpTokenNode.Null); - public override NodeType NodeType { get { return NodeType.Unknown; @@ -40,11 +38,11 @@ namespace ICSharpCode.NRefactory.CSharp } public CSharpTokenNode ExternToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (Roles.ExternKeyword); } } public CSharpTokenNode AliasToken { - get { return GetChildByRole (AliasRole); } + get { return GetChildByRole (Roles.AliasKeyword); } } public string Name { @@ -52,7 +50,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole (Roles.Identifier).Name; } set { - SetChildByRole (Roles.Identifier, Identifier.Create (value, TextLocation.Empty)); + SetChildByRole (Roles.Identifier, Identifier.Create (value)); } } @@ -69,7 +67,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.Semicolon); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitExternAliasDeclaration (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitExternAliasDeclaration (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitExternAliasDeclaration (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/NamespaceDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/NamespaceDeclaration.cs index d8736adc43..01198222b4 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/NamespaceDeclaration.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/NamespaceDeclaration.cs @@ -43,6 +43,10 @@ namespace ICSharpCode.NRefactory.CSharp } } + public CSharpTokenNode NamespaceToken { + get { return GetChildByRole (Roles.NamespaceKeyword); } + } + public string Name { get { StringBuilder builder = new StringBuilder (); @@ -54,7 +58,7 @@ namespace ICSharpCode.NRefactory.CSharp return builder.ToString (); } set { - GetChildrenByRole(Roles.Identifier).ReplaceWith(value.Split('.').Select(ident => Identifier.Create (ident, TextLocation.Empty))); + GetChildrenByRole(Roles.Identifier).ReplaceWith(value.Split('.').Select(ident => Identifier.Create (ident))); } } @@ -109,7 +113,17 @@ namespace ICSharpCode.NRefactory.CSharp AddChild (child, MemberRole); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitNamespaceDeclaration (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitNamespaceDeclaration (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitNamespaceDeclaration (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/NewLineNode.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/NewLineNode.cs new file mode 100644 index 0000000000..a2cba46c8e --- /dev/null +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/NewLineNode.cs @@ -0,0 +1,132 @@ +using System; +namespace ICSharpCode.NRefactory.CSharp +{ + public enum NewLineType { + Unix, + Windows, + Mac + } + + /// + /// A New line node represents a line break in the text. + /// + public abstract class NewLineNode : AstNode + { + public override NodeType NodeType { + get { + return NodeType.Whitespace; + } + } + + public abstract NewLineType NewLineType { + get; + } + + TextLocation startLocation; + public override TextLocation StartLocation { + get { + return startLocation; + } + } + + public override TextLocation EndLocation { + get { + return new TextLocation (startLocation.Line + 1, 1); + } + } + + public NewLineNode() : this (TextLocation.Empty) + { + } + + public NewLineNode(TextLocation startLocation) + { + this.startLocation = startLocation; + } + + public override void AcceptVisitor(IAstVisitor visitor) + { + visitor.VisitNewLine (this); + } + + public override T AcceptVisitor(IAstVisitor visitor) + { + return visitor.VisitNewLine (this); + } + + public override S AcceptVisitor(IAstVisitor visitor, T data) + { + return visitor.VisitNewLine (this, data); + } + } + + public class UnixNewLine : NewLineNode + { + public override NewLineType NewLineType { + get { + return NewLineType.Unix; + } + } + + public UnixNewLine() + { + } + + public UnixNewLine(TextLocation startLocation) : base (startLocation) + { + } + + protected internal override bool DoMatch(AstNode other, PatternMatching.Match match) + { + var o = other as UnixNewLine; + return o != null; + } + } + + public class WindowsNewLine : NewLineNode + { + public override NewLineType NewLineType { + get { + return NewLineType.Windows; + } + } + + public WindowsNewLine() + { + } + + public WindowsNewLine(TextLocation startLocation) : base (startLocation) + { + } + + protected internal override bool DoMatch(AstNode other, PatternMatching.Match match) + { + var o = other as WindowsNewLine; + return o != null; + } + } + + public class MacNewLine : NewLineNode + { + public override NewLineType NewLineType { + get { + return NewLineType.Mac; + } + } + + public MacNewLine() + { + } + + public MacNewLine(TextLocation startLocation) : base (startLocation) + { + } + + protected internal override bool DoMatch(AstNode other, PatternMatching.Match match) + { + var o = other as MacNewLine; + return o != null; + } + } +} + diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/PreProcessorDirective.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/PreProcessorDirective.cs index 0497557170..953f326c19 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/PreProcessorDirective.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/PreProcessorDirective.cs @@ -46,7 +46,7 @@ namespace ICSharpCode.NRefactory.CSharp Line = 12 } - public class PreProcessorDirective : AstNode, IRelocatable + public class PreProcessorDirective : AstNode { public override NodeType NodeType { get { @@ -93,16 +93,17 @@ namespace ICSharpCode.NRefactory.CSharp this.endLocation = endLocation; } - #region IRelocationable implementation - void IRelocatable.SetStartLocation (TextLocation startLocation) + public override void AcceptVisitor (IAstVisitor visitor) { - int lineDelta = startLocation.Line - this.startLocation.Line; - endLocation = new TextLocation (endLocation.Line + lineDelta, lineDelta != 0 ? endLocation.Column : endLocation.Column + startLocation.Column - this.startLocation.Column); - this.startLocation = startLocation; + visitor.VisitPreProcessorDirective (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitPreProcessorDirective (this); } - #endregion - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitPreProcessorDirective (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/TextNode.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/TextNode.cs new file mode 100644 index 0000000000..4c7f9b9425 --- /dev/null +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/TextNode.cs @@ -0,0 +1,94 @@ +// +// TextNode.cs +// +// Author: +// Mike Krüger +// +// Copyright (c) 2012 Xamarin Inc. (http://xamarin.com) +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +// THE SOFTWARE. + +using System; +namespace ICSharpCode.NRefactory.CSharp +{ + /// + /// A text node contains text without syntactic or semantic information. + /// (non parseable part of a text) + /// + public class TextNode : AstNode + { + public override NodeType NodeType { + get { + return NodeType.Whitespace; + } + } + + public string Text { + get; + set; + } + + TextLocation startLocation; + public override TextLocation StartLocation { + get { + return startLocation; + } + } + + TextLocation endLocation; + public override TextLocation EndLocation { + get { + return endLocation; + } + } + + public TextNode(string text) : this (text, TextLocation.Empty, TextLocation.Empty) + { + } + + public TextNode(string text, TextLocation startLocation, TextLocation endLocation) + { + this.Text = text; + this.startLocation = startLocation; + this.endLocation = endLocation; + } + + public override void AcceptVisitor(IAstVisitor visitor) + { + visitor.VisitText (this); + } + + public override T AcceptVisitor(IAstVisitor visitor) + { + return visitor.VisitText (this); + } + + public override S AcceptVisitor(IAstVisitor visitor, T data) + { + return visitor.VisitText (this, data); + } + + protected internal override bool DoMatch(AstNode other, PatternMatching.Match match) + { + var o = other as TextNode; + return o != null && o.Text == Text; + } + } +} + diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/TypeDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/TypeDeclaration.cs index 018e0491e1..d4ac6eaf65 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/TypeDeclaration.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/TypeDeclaration.cs @@ -41,66 +41,78 @@ namespace ICSharpCode.NRefactory.CSharp /// /// class Name<TypeParameters> : BaseTypes where Constraints; /// - public class TypeDeclaration : AttributedNode + public class TypeDeclaration : EntityDeclaration { - public readonly static Role ColonRole = Roles.Colon; - public readonly static Role BaseTypeRole = new Role("BaseType", AstType.Null); - public readonly static Role MemberRole = new Role("Member"); - public override NodeType NodeType { - get { - return NodeType.TypeDeclaration; - } + get { return NodeType.TypeDeclaration; } } - public ClassType ClassType { - get; - set; + public override EntityType EntityType { + get { return EntityType.TypeDefinition; } } - public string Name { + ClassType classType; + + public CSharpTokenNode TypeKeyword { get { - return GetChildByRole (Roles.Identifier).Name; - } - set { - SetChildByRole (Roles.Identifier, Identifier.Create (value, TextLocation.Empty)); + switch (classType) { + case ClassType.Class: + return GetChildByRole(Roles.ClassKeyword); + case ClassType.Struct: + return GetChildByRole(Roles.StructKeyword); + case ClassType.Interface: + return GetChildByRole(Roles.InterfaceKeyword); + case ClassType.Enum: + return GetChildByRole(Roles.EnumKeyword); + default: + return CSharpTokenNode.Null; + } } } - public Identifier NameToken { - get { - return GetChildByRole (Roles.Identifier); - } + public ClassType ClassType { + get { return classType; } set { - SetChildByRole (Roles.Identifier, value); + ThrowIfFrozen(); + classType = value; } } - + public AstNodeCollection TypeParameters { get { return GetChildrenByRole (Roles.TypeParameter); } } public AstNodeCollection BaseTypes { - get { return GetChildrenByRole (BaseTypeRole); } + get { return GetChildrenByRole(Roles.BaseType); } } public AstNodeCollection Constraints { - get { return GetChildrenByRole (Roles.Constraint); } + get { return GetChildrenByRole(Roles.Constraint); } } public CSharpTokenNode LBraceToken { get { return GetChildByRole (Roles.LBrace); } } - public AstNodeCollection Members { - get { return GetChildrenByRole (MemberRole); } + public AstNodeCollection Members { + get { return GetChildrenByRole (Roles.TypeMemberRole); } } public CSharpTokenNode RBraceToken { get { return GetChildByRole (Roles.RBrace); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitTypeDeclaration (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitTypeDeclaration (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitTypeDeclaration (this, data); } @@ -108,8 +120,8 @@ namespace ICSharpCode.NRefactory.CSharp protected internal override bool DoMatch(AstNode other, PatternMatching.Match match) { TypeDeclaration o = other as TypeDeclaration; - return o != null && this.ClassType == o.ClassType && this.MatchAttributesAndModifiers(o, match) - && MatchString(this.Name, o.Name) && this.TypeParameters.DoMatch(o.TypeParameters, match) + return o != null && this.ClassType == o.ClassType && MatchString(this.Name, o.Name) + && this.MatchAttributesAndModifiers(o, match) && this.TypeParameters.DoMatch(o.TypeParameters, match) && this.BaseTypes.DoMatch(o.BaseTypes, match) && this.Constraints.DoMatch(o.Constraints, match) && this.Members.DoMatch(o.Members, match); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/TypeParameterDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/TypeParameterDeclaration.cs index d7a38e958c..ede85f16a3 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/TypeParameterDeclaration.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/TypeParameterDeclaration.cs @@ -30,8 +30,9 @@ namespace ICSharpCode.NRefactory.CSharp /// public class TypeParameterDeclaration : AstNode { - public static readonly Role AttributeRole = AttributedNode.AttributeRole; - public static readonly Role VarianceRole = new Role("Variance", CSharpTokenNode.Null); + public static readonly Role AttributeRole = EntityDeclaration.AttributeRole; + public static readonly TokenRole OutVarianceKeywordRole = new TokenRole ("out"); + public static readonly TokenRole InVarianceKeywordRole = new TokenRole ("in"); public override NodeType NodeType { get { return NodeType.Unknown; } @@ -41,8 +42,24 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildrenByRole (AttributeRole); } } + VarianceModifier variance; + public VarianceModifier Variance { - get; set; + get { return variance; } + set { ThrowIfFrozen(); variance = value; } + } + + public CSharpTokenNode VarianceToken { + get { + switch (Variance) { + case VarianceModifier.Covariant: + return GetChildByRole(OutVarianceKeywordRole); + case VarianceModifier.Contravariant: + return GetChildByRole(InVarianceKeywordRole); + default: + return CSharpTokenNode.Null; + } + } } public string Name { @@ -50,7 +67,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole (Roles.Identifier).Name; } set { - SetChildByRole(Roles.Identifier, Identifier.Create (value, TextLocation.Empty)); + SetChildByRole(Roles.Identifier, Identifier.Create (value)); } } @@ -62,8 +79,27 @@ namespace ICSharpCode.NRefactory.CSharp SetChildByRole (Roles.Identifier, value); } } + + public TypeParameterDeclaration () + { + } + + public TypeParameterDeclaration (string name) + { + Name = name; + } + + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitTypeParameterDeclaration (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitTypeParameterDeclaration (this); + } - public override S AcceptVisitor(IAstVisitor visitor, T data = default(T)) + public override S AcceptVisitor(IAstVisitor visitor, T data) { return visitor.VisitTypeParameterDeclaration(this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/UsingAliasDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/UsingAliasDeclaration.cs index 8a69357c6e..9924132d35 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/UsingAliasDeclaration.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/UsingAliasDeclaration.cs @@ -31,6 +31,7 @@ namespace ICSharpCode.NRefactory.CSharp /// public class UsingAliasDeclaration : AstNode { + public static readonly TokenRole UsingKeywordRole = new TokenRole ("using"); public static readonly Role AliasRole = new Role("Alias", Identifier.Null); public static readonly Role ImportRole = UsingDeclaration.ImportRole; @@ -41,7 +42,7 @@ namespace ICSharpCode.NRefactory.CSharp } public CSharpTokenNode UsingToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (UsingKeywordRole); } } public string Alias { @@ -49,7 +50,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole (AliasRole).Name; } set { - SetChildByRole(AliasRole, Identifier.Create (value, TextLocation.Empty)); + SetChildByRole(AliasRole, Identifier.Create (value)); } } @@ -72,17 +73,27 @@ namespace ICSharpCode.NRefactory.CSharp public UsingAliasDeclaration (string alias, string nameSpace) { - AddChild (Identifier.Create (alias, TextLocation.Empty), AliasRole); + AddChild (Identifier.Create (alias), AliasRole); AddChild (new SimpleType (nameSpace), ImportRole); } public UsingAliasDeclaration (string alias, AstType import) { - AddChild (Identifier.Create (alias, TextLocation.Empty), AliasRole); + AddChild (Identifier.Create (alias), AliasRole); AddChild (import, ImportRole); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitUsingAliasDeclaration (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitUsingAliasDeclaration (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitUsingAliasDeclaration (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/UsingDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/UsingDeclaration.cs index 31ae7ddfc8..c5ae723512 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/UsingDeclaration.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/UsingDeclaration.cs @@ -35,6 +35,7 @@ namespace ICSharpCode.NRefactory.CSharp /// public class UsingDeclaration : AstNode { + public static readonly TokenRole UsingKeywordRole = new TokenRole ("using"); public static readonly Role ImportRole = new Role("Import", AstType.Null); public override NodeType NodeType { @@ -44,7 +45,7 @@ namespace ICSharpCode.NRefactory.CSharp } public CSharpTokenNode UsingToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (UsingKeywordRole); } } public AstType Import { @@ -74,7 +75,17 @@ namespace ICSharpCode.NRefactory.CSharp AddChild (import, ImportRole); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitUsingDeclaration (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitUsingDeclaration (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitUsingDeclaration (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/WhitespaceNode.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/WhitespaceNode.cs new file mode 100644 index 0000000000..c7e37f704d --- /dev/null +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/GeneralScope/WhitespaceNode.cs @@ -0,0 +1,91 @@ +// +// WhitespaceNode.cs +// +// Author: +// Mike Krüger +// +// Copyright (c) 2012 Xamarin Inc. (http://xamarin.com) +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +// THE SOFTWARE. + +using System; +namespace ICSharpCode.NRefactory.CSharp +{ + /// + /// A Whitespace node contains only whitespaces. + /// + public class WhitespaceNode : AstNode + { + public override NodeType NodeType { + get { + return NodeType.Whitespace; + } + } + + public string WhiteSpaceText { + get; + set; + } + + TextLocation startLocation; + public override TextLocation StartLocation { + get { + return startLocation; + } + } + + public override TextLocation EndLocation { + get { + return new TextLocation (startLocation.Line, startLocation.Column + WhiteSpaceText.Length); + } + } + + public WhitespaceNode(string whiteSpaceText) : this (whiteSpaceText, TextLocation.Empty) + { + } + + public WhitespaceNode(string whiteSpaceText, TextLocation startLocation) + { + this.WhiteSpaceText = WhiteSpaceText; + this.startLocation = startLocation; + } + + public override void AcceptVisitor(IAstVisitor visitor) + { + visitor.VisitWhitespace (this); + } + + public override T AcceptVisitor(IAstVisitor visitor) + { + return visitor.VisitWhitespace (this); + } + + public override S AcceptVisitor(IAstVisitor visitor, T data) + { + return visitor.VisitWhitespace (this, data); + } + + protected internal override bool DoMatch(AstNode other, PatternMatching.Match match) + { + var o = other as WhitespaceNode; + return o != null && o.WhiteSpaceText == WhiteSpaceText; + } + } +} + diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/IAstVisitor.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/IAstVisitor.cs index 00e804ccee..58836e655d 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/IAstVisitor.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/IAstVisitor.cs @@ -20,6 +20,268 @@ using System; namespace ICSharpCode.NRefactory.CSharp { + /// + /// AST visitor. + /// + public interface IAstVisitor + { + void VisitAnonymousMethodExpression(AnonymousMethodExpression anonymousMethodExpression); + void VisitUndocumentedExpression(UndocumentedExpression undocumentedExpression); + void VisitArrayCreateExpression(ArrayCreateExpression arrayCreateExpression); + void VisitArrayInitializerExpression(ArrayInitializerExpression arrayInitializerExpression); + void VisitAsExpression(AsExpression asExpression); + void VisitAssignmentExpression(AssignmentExpression assignmentExpression); + void VisitBaseReferenceExpression(BaseReferenceExpression baseReferenceExpression); + void VisitBinaryOperatorExpression(BinaryOperatorExpression binaryOperatorExpression); + void VisitCastExpression(CastExpression castExpression); + void VisitCheckedExpression(CheckedExpression checkedExpression); + void VisitConditionalExpression(ConditionalExpression conditionalExpression); + void VisitDefaultValueExpression(DefaultValueExpression defaultValueExpression); + void VisitDirectionExpression(DirectionExpression directionExpression); + void VisitIdentifierExpression(IdentifierExpression identifierExpression); + void VisitIndexerExpression(IndexerExpression indexerExpression); + void VisitInvocationExpression(InvocationExpression invocationExpression); + void VisitIsExpression(IsExpression isExpression); + void VisitLambdaExpression(LambdaExpression lambdaExpression); + void VisitMemberReferenceExpression(MemberReferenceExpression memberReferenceExpression); + void VisitNamedArgumentExpression(NamedArgumentExpression namedArgumentExpression); + void VisitNamedExpression(NamedExpression namedExpression); + void VisitNullReferenceExpression(NullReferenceExpression nullReferenceExpression); + void VisitObjectCreateExpression(ObjectCreateExpression objectCreateExpression); + void VisitAnonymousTypeCreateExpression(AnonymousTypeCreateExpression anonymousTypeCreateExpression); + void VisitParenthesizedExpression(ParenthesizedExpression parenthesizedExpression); + void VisitPointerReferenceExpression(PointerReferenceExpression pointerReferenceExpression); + void VisitPrimitiveExpression(PrimitiveExpression primitiveExpression); + void VisitSizeOfExpression(SizeOfExpression sizeOfExpression); + void VisitStackAllocExpression(StackAllocExpression stackAllocExpression); + void VisitThisReferenceExpression(ThisReferenceExpression thisReferenceExpression); + void VisitTypeOfExpression(TypeOfExpression typeOfExpression); + void VisitTypeReferenceExpression(TypeReferenceExpression typeReferenceExpression); + void VisitUnaryOperatorExpression(UnaryOperatorExpression unaryOperatorExpression); + void VisitUncheckedExpression(UncheckedExpression uncheckedExpression); + void VisitEmptyExpression (EmptyExpression emptyExpression); + + void VisitQueryExpression(QueryExpression queryExpression); + void VisitQueryContinuationClause(QueryContinuationClause queryContinuationClause); + void VisitQueryFromClause(QueryFromClause queryFromClause); + void VisitQueryLetClause(QueryLetClause queryLetClause); + void VisitQueryWhereClause(QueryWhereClause queryWhereClause); + void VisitQueryJoinClause(QueryJoinClause queryJoinClause); + void VisitQueryOrderClause(QueryOrderClause queryOrderClause); + void VisitQueryOrdering(QueryOrdering queryOrdering); + void VisitQuerySelectClause(QuerySelectClause querySelectClause); + void VisitQueryGroupClause(QueryGroupClause queryGroupClause); + + void VisitAttribute(Attribute attribute); + void VisitAttributeSection(AttributeSection attributeSection); + void VisitDelegateDeclaration(DelegateDeclaration delegateDeclaration); + void VisitNamespaceDeclaration(NamespaceDeclaration namespaceDeclaration); + void VisitTypeDeclaration(TypeDeclaration typeDeclaration); + void VisitUsingAliasDeclaration(UsingAliasDeclaration usingAliasDeclaration); + void VisitUsingDeclaration(UsingDeclaration usingDeclaration); + void VisitExternAliasDeclaration(ExternAliasDeclaration externAliasDeclaration); + + void VisitBlockStatement(BlockStatement blockStatement); + void VisitBreakStatement(BreakStatement breakStatement); + void VisitCheckedStatement(CheckedStatement checkedStatement); + void VisitContinueStatement(ContinueStatement continueStatement); + void VisitDoWhileStatement(DoWhileStatement doWhileStatement); + void VisitEmptyStatement(EmptyStatement emptyStatement); + void VisitExpressionStatement(ExpressionStatement expressionStatement); + void VisitFixedStatement(FixedStatement fixedStatement); + void VisitForeachStatement(ForeachStatement foreachStatement); + void VisitForStatement(ForStatement forStatement); + void VisitGotoCaseStatement(GotoCaseStatement gotoCaseStatement); + void VisitGotoDefaultStatement(GotoDefaultStatement gotoDefaultStatement); + void VisitGotoStatement(GotoStatement gotoStatement); + void VisitIfElseStatement(IfElseStatement ifElseStatement); + void VisitLabelStatement(LabelStatement labelStatement); + void VisitLockStatement(LockStatement lockStatement); + void VisitReturnStatement(ReturnStatement returnStatement); + void VisitSwitchStatement(SwitchStatement switchStatement); + void VisitSwitchSection(SwitchSection switchSection); + void VisitCaseLabel(CaseLabel caseLabel); + void VisitThrowStatement(ThrowStatement throwStatement); + void VisitTryCatchStatement(TryCatchStatement tryCatchStatement); + void VisitCatchClause(CatchClause catchClause); + void VisitUncheckedStatement(UncheckedStatement uncheckedStatement); + void VisitUnsafeStatement(UnsafeStatement unsafeStatement); + void VisitUsingStatement(UsingStatement usingStatement); + void VisitVariableDeclarationStatement(VariableDeclarationStatement variableDeclarationStatement); + void VisitWhileStatement(WhileStatement whileStatement); + void VisitYieldBreakStatement(YieldBreakStatement yieldBreakStatement); + void VisitYieldReturnStatement(YieldReturnStatement yieldReturnStatement); + + void VisitAccessor(Accessor accessor); + void VisitConstructorDeclaration(ConstructorDeclaration constructorDeclaration); + void VisitConstructorInitializer(ConstructorInitializer constructorInitializer); + void VisitDestructorDeclaration(DestructorDeclaration destructorDeclaration); + void VisitEnumMemberDeclaration(EnumMemberDeclaration enumMemberDeclaration); + void VisitEventDeclaration(EventDeclaration eventDeclaration); + void VisitCustomEventDeclaration(CustomEventDeclaration customEventDeclaration); + void VisitFieldDeclaration(FieldDeclaration fieldDeclaration); + void VisitIndexerDeclaration(IndexerDeclaration indexerDeclaration); + void VisitMethodDeclaration(MethodDeclaration methodDeclaration); + void VisitOperatorDeclaration(OperatorDeclaration operatorDeclaration); + void VisitParameterDeclaration(ParameterDeclaration parameterDeclaration); + void VisitPropertyDeclaration(PropertyDeclaration propertyDeclaration); + void VisitVariableInitializer(VariableInitializer variableInitializer); + void VisitFixedFieldDeclaration(FixedFieldDeclaration fixedFieldDeclaration); + void VisitFixedVariableInitializer(FixedVariableInitializer fixedVariableInitializer); + + void VisitCompilationUnit(CompilationUnit compilationUnit); + void VisitSimpleType(SimpleType simpleType); + void VisitMemberType(MemberType memberType); + void VisitComposedType(ComposedType composedType); + void VisitArraySpecifier(ArraySpecifier arraySpecifier); + void VisitPrimitiveType(PrimitiveType primitiveType); + + void VisitComment(Comment comment); + void VisitNewLine(NewLineNode newLineNode); + void VisitWhitespace(WhitespaceNode whitespaceNode); + void VisitText(TextNode textNode); + void VisitPreProcessorDirective(PreProcessorDirective preProcessorDirective); + void VisitDocumentationReference(DocumentationReference documentationReference); + + void VisitTypeParameterDeclaration(TypeParameterDeclaration typeParameterDeclaration); + void VisitConstraint(Constraint constraint); + void VisitCSharpTokenNode(CSharpTokenNode cSharpTokenNode); + void VisitIdentifier(Identifier identifier); + + void VisitPatternPlaceholder(AstNode placeholder, PatternMatching.Pattern pattern); + } + + /// + /// AST visitor. + /// + public interface IAstVisitor + { + S VisitAnonymousMethodExpression(AnonymousMethodExpression anonymousMethodExpression); + S VisitUndocumentedExpression(UndocumentedExpression undocumentedExpression); + S VisitArrayCreateExpression(ArrayCreateExpression arrayCreateExpression); + S VisitArrayInitializerExpression(ArrayInitializerExpression arrayInitializerExpression); + S VisitAsExpression(AsExpression asExpression); + S VisitAssignmentExpression(AssignmentExpression assignmentExpression); + S VisitBaseReferenceExpression(BaseReferenceExpression baseReferenceExpression); + S VisitBinaryOperatorExpression(BinaryOperatorExpression binaryOperatorExpression); + S VisitCastExpression(CastExpression castExpression); + S VisitCheckedExpression(CheckedExpression checkedExpression); + S VisitConditionalExpression(ConditionalExpression conditionalExpression); + S VisitDefaultValueExpression(DefaultValueExpression defaultValueExpression); + S VisitDirectionExpression(DirectionExpression directionExpression); + S VisitIdentifierExpression(IdentifierExpression identifierExpression); + S VisitIndexerExpression(IndexerExpression indexerExpression); + S VisitInvocationExpression(InvocationExpression invocationExpression); + S VisitIsExpression(IsExpression isExpression); + S VisitLambdaExpression(LambdaExpression lambdaExpression); + S VisitMemberReferenceExpression(MemberReferenceExpression memberReferenceExpression); + S VisitNamedArgumentExpression(NamedArgumentExpression namedArgumentExpression); + S VisitNamedExpression(NamedExpression namedExpression); + S VisitNullReferenceExpression(NullReferenceExpression nullReferenceExpression); + S VisitObjectCreateExpression(ObjectCreateExpression objectCreateExpression); + S VisitAnonymousTypeCreateExpression(AnonymousTypeCreateExpression anonymousTypeCreateExpression); + S VisitParenthesizedExpression(ParenthesizedExpression parenthesizedExpression); + S VisitPointerReferenceExpression(PointerReferenceExpression pointerReferenceExpression); + S VisitPrimitiveExpression(PrimitiveExpression primitiveExpression); + S VisitSizeOfExpression(SizeOfExpression sizeOfExpression); + S VisitStackAllocExpression(StackAllocExpression stackAllocExpression); + S VisitThisReferenceExpression(ThisReferenceExpression thisReferenceExpression); + S VisitTypeOfExpression(TypeOfExpression typeOfExpression); + S VisitTypeReferenceExpression(TypeReferenceExpression typeReferenceExpression); + S VisitUnaryOperatorExpression(UnaryOperatorExpression unaryOperatorExpression); + S VisitUncheckedExpression(UncheckedExpression uncheckedExpression); + S VisitEmptyExpression (EmptyExpression emptyExpression); + + S VisitQueryExpression(QueryExpression queryExpression); + S VisitQueryContinuationClause(QueryContinuationClause queryContinuationClause); + S VisitQueryFromClause(QueryFromClause queryFromClause); + S VisitQueryLetClause(QueryLetClause queryLetClause); + S VisitQueryWhereClause(QueryWhereClause queryWhereClause); + S VisitQueryJoinClause(QueryJoinClause queryJoinClause); + S VisitQueryOrderClause(QueryOrderClause queryOrderClause); + S VisitQueryOrdering(QueryOrdering queryOrdering); + S VisitQuerySelectClause(QuerySelectClause querySelectClause); + S VisitQueryGroupClause(QueryGroupClause queryGroupClause); + + S VisitAttribute(Attribute attribute); + S VisitAttributeSection(AttributeSection attributeSection); + S VisitDelegateDeclaration(DelegateDeclaration delegateDeclaration); + S VisitNamespaceDeclaration(NamespaceDeclaration namespaceDeclaration); + S VisitTypeDeclaration(TypeDeclaration typeDeclaration); + S VisitUsingAliasDeclaration(UsingAliasDeclaration usingAliasDeclaration); + S VisitUsingDeclaration(UsingDeclaration usingDeclaration); + S VisitExternAliasDeclaration(ExternAliasDeclaration externAliasDeclaration); + + S VisitBlockStatement(BlockStatement blockStatement); + S VisitBreakStatement(BreakStatement breakStatement); + S VisitCheckedStatement(CheckedStatement checkedStatement); + S VisitContinueStatement(ContinueStatement continueStatement); + S VisitDoWhileStatement(DoWhileStatement doWhileStatement); + S VisitEmptyStatement(EmptyStatement emptyStatement); + S VisitExpressionStatement(ExpressionStatement expressionStatement); + S VisitFixedStatement(FixedStatement fixedStatement); + S VisitForeachStatement(ForeachStatement foreachStatement); + S VisitForStatement(ForStatement forStatement); + S VisitGotoCaseStatement(GotoCaseStatement gotoCaseStatement); + S VisitGotoDefaultStatement(GotoDefaultStatement gotoDefaultStatement); + S VisitGotoStatement(GotoStatement gotoStatement); + S VisitIfElseStatement(IfElseStatement ifElseStatement); + S VisitLabelStatement(LabelStatement labelStatement); + S VisitLockStatement(LockStatement lockStatement); + S VisitReturnStatement(ReturnStatement returnStatement); + S VisitSwitchStatement(SwitchStatement switchStatement); + S VisitSwitchSection(SwitchSection switchSection); + S VisitCaseLabel(CaseLabel caseLabel); + S VisitThrowStatement(ThrowStatement throwStatement); + S VisitTryCatchStatement(TryCatchStatement tryCatchStatement); + S VisitCatchClause(CatchClause catchClause); + S VisitUncheckedStatement(UncheckedStatement uncheckedStatement); + S VisitUnsafeStatement(UnsafeStatement unsafeStatement); + S VisitUsingStatement(UsingStatement usingStatement); + S VisitVariableDeclarationStatement(VariableDeclarationStatement variableDeclarationStatement); + S VisitWhileStatement(WhileStatement whileStatement); + S VisitYieldBreakStatement(YieldBreakStatement yieldBreakStatement); + S VisitYieldReturnStatement(YieldReturnStatement yieldReturnStatement); + + S VisitAccessor(Accessor accessor); + S VisitConstructorDeclaration(ConstructorDeclaration constructorDeclaration); + S VisitConstructorInitializer(ConstructorInitializer constructorInitializer); + S VisitDestructorDeclaration(DestructorDeclaration destructorDeclaration); + S VisitEnumMemberDeclaration(EnumMemberDeclaration enumMemberDeclaration); + S VisitEventDeclaration(EventDeclaration eventDeclaration); + S VisitCustomEventDeclaration(CustomEventDeclaration customEventDeclaration); + S VisitFieldDeclaration(FieldDeclaration fieldDeclaration); + S VisitIndexerDeclaration(IndexerDeclaration indexerDeclaration); + S VisitMethodDeclaration(MethodDeclaration methodDeclaration); + S VisitOperatorDeclaration(OperatorDeclaration operatorDeclaration); + S VisitParameterDeclaration(ParameterDeclaration parameterDeclaration); + S VisitPropertyDeclaration(PropertyDeclaration propertyDeclaration); + S VisitVariableInitializer(VariableInitializer variableInitializer); + S VisitFixedFieldDeclaration(FixedFieldDeclaration fixedFieldDeclaration); + S VisitFixedVariableInitializer(FixedVariableInitializer fixedVariableInitializer); + + S VisitCompilationUnit(CompilationUnit compilationUnit); + S VisitSimpleType(SimpleType simpleType); + S VisitMemberType(MemberType memberType); + S VisitComposedType(ComposedType composedType); + S VisitArraySpecifier(ArraySpecifier arraySpecifier); + S VisitPrimitiveType(PrimitiveType primitiveType); + + S VisitComment(Comment comment); + S VisitWhitespace(WhitespaceNode whitespaceNode); + S VisitText(TextNode textNode); + S VisitNewLine(NewLineNode newLineNode); + S VisitPreProcessorDirective(PreProcessorDirective preProcessorDirective); + S VisitDocumentationReference(DocumentationReference documentationReference); + + S VisitTypeParameterDeclaration(TypeParameterDeclaration typeParameterDeclaration); + S VisitConstraint(Constraint constraint); + S VisitCSharpTokenNode(CSharpTokenNode cSharpTokenNode); + S VisitIdentifier(Identifier identifier); + + S VisitPatternPlaceholder(AstNode placeholder, PatternMatching.Pattern pattern); + } + /// /// AST visitor. /// @@ -137,7 +399,11 @@ namespace ICSharpCode.NRefactory.CSharp S VisitPrimitiveType(PrimitiveType primitiveType, T data); S VisitComment(Comment comment, T data); + S VisitNewLine(NewLineNode newLineNode, T data); + S VisitWhitespace(WhitespaceNode whitespaceNode, T data); + S VisitText(TextNode textNode, T data); S VisitPreProcessorDirective(PreProcessorDirective preProcessorDirective, T data); + S VisitDocumentationReference(DocumentationReference documentationReference, T data); S VisitTypeParameterDeclaration(TypeParameterDeclaration typeParameterDeclaration, T data); S VisitConstraint(Constraint constraint, T data); diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Identifier.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Identifier.cs index 3c692706d1..3321de2a03 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Identifier.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Identifier.cs @@ -1,6 +1,6 @@ // // Identifier.cs -// +// // Author: // Mike Krüger // @@ -28,7 +28,7 @@ using System; namespace ICSharpCode.NRefactory.CSharp { - public class Identifier : AstNode, IRelocatable + public class Identifier : AstNode { public new static readonly Identifier Null = new NullIdentifier (); sealed class NullIdentifier : Identifier @@ -39,7 +39,16 @@ namespace ICSharpCode.NRefactory.CSharp } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return default (T); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return default (S); } @@ -59,9 +68,10 @@ namespace ICSharpCode.NRefactory.CSharp string name; public string Name { get { return this.name; } - set { + set { if (value == null) throw new ArgumentNullException("value"); + ThrowIfFrozen(); this.name = value; } } @@ -71,25 +81,26 @@ namespace ICSharpCode.NRefactory.CSharp get { return startLocation; } - } - public virtual bool IsVerbatim { + const uint verbatimBit = 1u << AstNodeFlagsUsedBits; + + public bool IsVerbatim { get { - return false; + return (flags & verbatimBit) != 0; + } + set { + ThrowIfFrozen(); + if (value) + flags |= verbatimBit; + else + flags &= ~verbatimBit; } } - #region IRelocationable implementation - void IRelocatable.SetStartLocation (TextLocation startLocation) - { - this.startLocation = startLocation; - } - #endregion - public override TextLocation EndLocation { get { - return new TextLocation (StartLocation.Line, StartLocation.Column + (Name ?? "").Length); + return new TextLocation (StartLocation.Line, StartLocation.Column + (Name ?? "").Length + (IsVerbatim ? 1 : 0)); } } @@ -116,22 +127,32 @@ namespace ICSharpCode.NRefactory.CSharp if (string.IsNullOrEmpty(name)) return Identifier.Null; if (name[0] == '@') - return new VerbatimIdentifier(name.Substring (1), location); + return new Identifier (name.Substring (1), location) { IsVerbatim = true }; else return new Identifier (name, location); } public static Identifier Create (string name, TextLocation location, bool isVerbatim) { - if (string.IsNullOrEmpty(name)) + if (string.IsNullOrEmpty (name)) return Identifier.Null; if (isVerbatim) - return new VerbatimIdentifier(name, location); + return new Identifier (name, location) { IsVerbatim = true }; return new Identifier (name, location); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitIdentifier (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitIdentifier (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitIdentifier (this, data); } @@ -141,24 +162,5 @@ namespace ICSharpCode.NRefactory.CSharp Identifier o = other as Identifier; return o != null && !o.IsNull && MatchString(this.Name, o.Name); } - - class VerbatimIdentifier : Identifier - { - public override TextLocation EndLocation { - get { - return new TextLocation (StartLocation.Line, StartLocation.Column + (Name ?? "").Length + 1); // @"..." - } - } - - public override bool IsVerbatim { - get { - return true; - } - } - - public VerbatimIdentifier(string name, TextLocation location) : base (name, location) - { - } - } } } \ No newline at end of file diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/IdentifierExpressionBackreference.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/IdentifierExpressionBackreference.cs index 89da7231ce..0ce09e2443 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/IdentifierExpressionBackreference.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/IdentifierExpressionBackreference.cs @@ -48,7 +48,7 @@ namespace ICSharpCode.NRefactory.CSharp CSharp.AstNode referenced = (CSharp.AstNode)match.Get(referencedGroupName).Last(); if (referenced == null) return false; - return ident.Identifier == referenced.GetChildByRole(CSharp.AstNode.Roles.Identifier).Name; + return ident.Identifier == referenced.GetChildByRole(CSharp.Roles.Identifier).Name; } } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/MemberType.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/MemberType.cs index b551e77eee..b017d45ba7 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/MemberType.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/MemberType.cs @@ -28,6 +28,8 @@ using System; using System.Collections.Generic; using System.Linq; using System.Text; +using ICSharpCode.NRefactory.CSharp.TypeSystem; +using ICSharpCode.NRefactory.TypeSystem; namespace ICSharpCode.NRefactory.CSharp { @@ -35,7 +37,15 @@ namespace ICSharpCode.NRefactory.CSharp { public static readonly Role TargetRole = new Role("Target", AstType.Null); - public bool IsDoubleColon { get; set; } + bool isDoubleColon; + + public bool IsDoubleColon { + get { return isDoubleColon; } + set { + ThrowIfFrozen(); + isDoubleColon = value; + } + } public AstType Target { get { return GetChildByRole(TargetRole); } @@ -47,7 +57,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole (Roles.Identifier).Name; } set { - SetChildByRole (Roles.Identifier, Identifier.Create (value, TextLocation.Empty)); + SetChildByRole (Roles.Identifier, Identifier.Create (value)); } } @@ -87,7 +97,17 @@ namespace ICSharpCode.NRefactory.CSharp { } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitMemberType (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitMemberType (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitMemberType (this, data); } @@ -114,6 +134,28 @@ namespace ICSharpCode.NRefactory.CSharp } return b.ToString(); } + + public override ITypeReference ToTypeReference(SimpleNameLookupMode lookupMode = SimpleNameLookupMode.Type) + { + TypeOrNamespaceReference t; + if (this.IsDoubleColon) { + SimpleType st = this.Target as SimpleType; + if (st != null) { + t = new AliasNamespaceReference(st.Identifier); + } else { + t = null; + } + } else { + t = this.Target.ToTypeReference(lookupMode) as TypeOrNamespaceReference; + } + if (t == null) + return SpecialType.UnknownType; + var typeArguments = new List(); + foreach (var ta in this.TypeArguments) { + typeArguments.Add(ta.ToTypeReference(lookupMode)); + } + return new MemberTypeOrNamespaceReference(t, this.MemberName, typeArguments); + } } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/ObservableAstVisitor.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/ObservableAstVisitor.cs index e765752660..3d47dd81fc 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/ObservableAstVisitor.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/ObservableAstVisitor.cs @@ -60,9 +60,38 @@ namespace ICSharpCode.NRefactory.CSharp handler (comment, data); return VisitChildren (comment, data); } - - public event Action PreProcessorDirectiveVisited; + public event Action NewLineVisited; + + S IAstVisitor.VisitNewLine(NewLineNode newLineNode, T data) + { + var handler = NewLineVisited; + if (handler != null) + handler(newLineNode, data); + return VisitChildren(newLineNode, data); + } + + public event Action WhitespaceVisited; + + S IAstVisitor.VisitWhitespace(WhitespaceNode whitespace, T data) + { + var handler = WhitespaceVisited; + if (handler != null) + handler(whitespace, data); + return VisitChildren(whitespace, data); + } + + public event Action TextVisited; + + S IAstVisitor.VisitText(TextNode textNode, T data) + { + var handler = TextVisited; + if (handler != null) + handler(textNode, data); + return VisitChildren(textNode, data); + } + + public event Action PreProcessorDirectiveVisited; S IAstVisitor.VisitPreProcessorDirective (PreProcessorDirective preProcessorDirective, T data) { var handler = PreProcessorDirectiveVisited; @@ -71,6 +100,16 @@ namespace ICSharpCode.NRefactory.CSharp return VisitChildren (preProcessorDirective, data); } + public event Action DocumentationReferenceVisited; + + S IAstVisitor.VisitDocumentationReference (DocumentationReference documentationReference, T data) + { + var handler = DocumentationReferenceVisited; + if (handler != null) + handler (documentationReference, data); + return VisitChildren (documentationReference, data); + } + public event Action IdentifierVisited; S IAstVisitor.VisitIdentifier (Identifier identifier, T data) diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/PrimitiveType.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/PrimitiveType.cs index 92705e96a4..bc367b3b6e 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/PrimitiveType.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/PrimitiveType.cs @@ -26,13 +26,30 @@ using System; using System.Collections.Generic; using System.Linq; +using ICSharpCode.NRefactory.CSharp.Resolver; +using ICSharpCode.NRefactory.TypeSystem; +using ICSharpCode.NRefactory.TypeSystem.Implementation; namespace ICSharpCode.NRefactory.CSharp { - public class PrimitiveType : AstType, IRelocatable + public class PrimitiveType : AstType { - public string Keyword { get; set; } - public TextLocation Location { get; set; } + TextLocation location; + string keyword = string.Empty; + + public string Keyword { + get { return keyword; } + set { + if (value == null) + throw new ArgumentNullException(); + ThrowIfFrozen(); + keyword = value; + } + } + + public KnownTypeCode KnownTypeCode { + get { return GetTypeCodeForPrimitiveType(this.Keyword); } + } public PrimitiveType() { @@ -46,29 +63,31 @@ namespace ICSharpCode.NRefactory.CSharp public PrimitiveType(string keyword, TextLocation location) { this.Keyword = keyword; - this.Location = location; + this.location = location; } public override TextLocation StartLocation { get { - return Location; + return location; } } public override TextLocation EndLocation { get { - return new TextLocation (Location.Line, Location.Column + (Keyword != null ? Keyword.Length : 0)); + return new TextLocation (location.Line, location.Column + keyword.Length); } } - - #region IRelocationable implementation - void IRelocatable.SetStartLocation (TextLocation startLocation) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitPrimitiveType (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) { - this.Location = startLocation; + return visitor.VisitPrimitiveType (this); } - #endregion - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitPrimitiveType (this, data); } @@ -81,7 +100,56 @@ namespace ICSharpCode.NRefactory.CSharp public override string ToString() { - return Keyword ?? base.ToString(); + return Keyword; + } + + public override ITypeReference ToTypeReference(SimpleNameLookupMode lookupMode = SimpleNameLookupMode.Type) + { + KnownTypeCode typeCode = GetTypeCodeForPrimitiveType(this.Keyword); + if (typeCode == KnownTypeCode.None) + return new UnknownType(null, this.Keyword); + else + return KnownTypeReference.Get(typeCode); + } + + public static KnownTypeCode GetTypeCodeForPrimitiveType(string keyword) + { + switch (keyword) { + case "string": + return KnownTypeCode.String; + case "int": + return KnownTypeCode.Int32; + case "uint": + return KnownTypeCode.UInt32; + case "object": + return KnownTypeCode.Object; + case "bool": + return KnownTypeCode.Boolean; + case "sbyte": + return KnownTypeCode.SByte; + case "byte": + return KnownTypeCode.Byte; + case "short": + return KnownTypeCode.Int16; + case "ushort": + return KnownTypeCode.UInt16; + case "long": + return KnownTypeCode.Int64; + case "ulong": + return KnownTypeCode.UInt64; + case "float": + return KnownTypeCode.Single; + case "double": + return KnownTypeCode.Double; + case "decimal": + return KnownTypeCode.Decimal; + case "char": + return KnownTypeCode.Char; + case "void": + return KnownTypeCode.Void; + default: + return KnownTypeCode.None; + } } } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Roles.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Roles.cs new file mode 100644 index 0000000000..a7408c91d7 --- /dev/null +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Roles.cs @@ -0,0 +1,96 @@ +// +// Roles.cs +// +// Author: +// Mike Krüger +// +// Copyright (c) 2012 Xamarin +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +// THE SOFTWARE. + +using System; + +namespace ICSharpCode.NRefactory.CSharp +{ + public static class Roles + { + public static readonly Role Root = AstNode.RootRole; + + // some pre defined constants for common roles + public static readonly Role Identifier = new Role ("Identifier", CSharp.Identifier.Null); + public static readonly Role Body = new Role ("Body", CSharp.BlockStatement.Null); + public static readonly Role Parameter = new Role ("Parameter"); + public static readonly Role Argument = new Role ("Argument", CSharp.Expression.Null); + public static readonly Role Type = new Role ("Type", CSharp.AstType.Null); + public static readonly Role Expression = new Role ("Expression", CSharp.Expression.Null); + public static readonly Role TargetExpression = new Role ("Target", CSharp.Expression.Null); + public readonly static Role Condition = new Role ("Condition", CSharp.Expression.Null); + public static readonly Role TypeParameter = new Role ("TypeParameter"); + public static readonly Role TypeArgument = new Role ("TypeArgument", CSharp.AstType.Null); + public readonly static Role Constraint = new Role ("Constraint"); + public static readonly Role Variable = new Role ("Variable", VariableInitializer.Null); + public static readonly Role EmbeddedStatement = new Role ("EmbeddedStatement", CSharp.Statement.Null); + public readonly static Role TypeMemberRole = new Role ("TypeMember"); + + + // public static readonly TokenRole Keyword = new TokenRole ("Keyword", CSharpTokenNode.Null); +// public static readonly TokenRole InKeyword = new TokenRole ("InKeyword", CSharpTokenNode.Null); + + // some pre defined constants for most used punctuation + public static readonly TokenRole LPar = new TokenRole ("("); + public static readonly TokenRole RPar = new TokenRole (")"); + public static readonly TokenRole LBracket = new TokenRole ("["); + public static readonly TokenRole RBracket = new TokenRole ("]"); + public static readonly TokenRole LBrace = new TokenRole ("{"); + public static readonly TokenRole RBrace = new TokenRole ("}"); + public static readonly TokenRole LChevron = new TokenRole ("<"); + public static readonly TokenRole RChevron = new TokenRole (">"); + public static readonly TokenRole Comma = new TokenRole (","); + public static readonly TokenRole Dot = new TokenRole ("."); + public static readonly TokenRole Semicolon = new TokenRole (";"); + public static readonly TokenRole Assign = new TokenRole ("="); + public static readonly TokenRole Colon = new TokenRole (":"); + public static readonly TokenRole DoubleColon = new TokenRole ("::"); + public static readonly Role Comment = new Role ("Comment"); + public static readonly Role NewLine = new Role ("NewLine"); + public static readonly Role Whitespace = new Role ("Whitespace"); + public static readonly Role Text = new Role ("Text"); + public static readonly Role PreProcessorDirective = new Role ("PreProcessorDirective"); + public static readonly Role Error = new Role ("Error"); + + public readonly static Role BaseType = new Role ("BaseType", AstType.Null); + + public static readonly Role Attribute = new Role ("Attribute"); + public static readonly Role AttributeTargetRole = new Role ("AttributeTarget", CSharpTokenNode.Null); + + public readonly static TokenRole WhereKeyword = new TokenRole ("where"); + public readonly static Role ConstraintTypeParameter = new Role ("TypeParameter", SimpleType.Null); + public readonly static TokenRole DelegateKeyword = new TokenRole ("delegate"); + public static readonly TokenRole ExternKeyword = new TokenRole ("extern"); + public static readonly TokenRole AliasKeyword = new TokenRole ("alias"); + public static readonly TokenRole NamespaceKeyword = new TokenRole ("namespace"); + + public static readonly TokenRole EnumKeyword = new TokenRole ("enum"); + public static readonly TokenRole InterfaceKeyword = new TokenRole ("interface"); + public static readonly TokenRole StructKeyword = new TokenRole ("struct"); + public static readonly TokenRole ClassKeyword = new TokenRole ("class"); + + } +} + diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/SimpleType.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/SimpleType.cs index 76481cbb18..072432b46b 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/SimpleType.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/SimpleType.cs @@ -28,6 +28,9 @@ using System; using System.Collections.Generic; using System.Linq; using System.Text; +using ICSharpCode.NRefactory.CSharp.Resolver; +using ICSharpCode.NRefactory.CSharp.TypeSystem; +using ICSharpCode.NRefactory.TypeSystem; namespace ICSharpCode.NRefactory.CSharp { @@ -44,7 +47,16 @@ namespace ICSharpCode.NRefactory.CSharp } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return default (T); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return default (S); } @@ -53,6 +65,11 @@ namespace ICSharpCode.NRefactory.CSharp { return other == null || other.IsNull; } + + public override ITypeReference ToTypeReference(SimpleNameLookupMode lookupMode) + { + return SpecialType.UnknownType; + } } #endregion @@ -92,7 +109,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole (Roles.Identifier).Name; } set { - SetChildByRole (Roles.Identifier, CSharp.Identifier.Create (value, TextLocation.Empty)); + SetChildByRole (Roles.Identifier, CSharp.Identifier.Create (value)); } } @@ -109,7 +126,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildrenByRole (Roles.TypeArgument); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitSimpleType (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitSimpleType (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitSimpleType (this, data); } @@ -130,6 +157,19 @@ namespace ICSharpCode.NRefactory.CSharp } return b.ToString(); } + + public override ITypeReference ToTypeReference(SimpleNameLookupMode lookupMode = SimpleNameLookupMode.Type) + { + var typeArguments = new List(); + foreach (var ta in this.TypeArguments) { + typeArguments.Add(ta.ToTypeReference(lookupMode)); + } + if (typeArguments.Count == 0 && string.IsNullOrEmpty(this.Identifier)) { + // empty SimpleType is used for typeof(List<>). + return SpecialType.UnboundTypeArgument; + } + return new SimpleTypeOrNamespaceReference(this.Identifier, typeArguments, lookupMode); + } } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/BlockStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/BlockStatement.cs index 066d381380..d30484d8dc 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/BlockStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/BlockStatement.cs @@ -45,7 +45,16 @@ namespace ICSharpCode.NRefactory.CSharp } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return default (T); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return default (S); } @@ -76,7 +85,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return NodeType.Pattern; } } - public override S AcceptVisitor(IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitPatternPlaceholder(this, child); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitPatternPlaceholder(this, child); + } + + public override S AcceptVisitor(IAstVisitor visitor, T data) { return visitor.VisitPatternPlaceholder(this, child, data); } @@ -105,7 +124,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.RBrace); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitBlockStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitBlockStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitBlockStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/BreakStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/BreakStatement.cs index 5c993f8968..056cf55e46 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/BreakStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/BreakStatement.cs @@ -31,11 +31,27 @@ namespace ICSharpCode.NRefactory.CSharp /// public class BreakStatement : Statement { + public static readonly TokenRole BreakKeywordRole = new TokenRole ("break"); + + public CSharpTokenNode BreakToken { + get { return GetChildByRole (BreakKeywordRole); } + } + public CSharpTokenNode SemicolonToken { get { return GetChildByRole (Roles.Semicolon); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitBreakStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitBreakStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitBreakStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/CheckedStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/CheckedStatement.cs index c81724b919..803067aff1 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/CheckedStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/CheckedStatement.cs @@ -31,8 +31,10 @@ namespace ICSharpCode.NRefactory.CSharp /// public class CheckedStatement : Statement { + public static readonly TokenRole CheckedKeywordRole = new TokenRole ("checked"); + public CSharpTokenNode CheckedToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (CheckedKeywordRole); } } public BlockStatement Body { @@ -49,7 +51,17 @@ namespace ICSharpCode.NRefactory.CSharp AddChild (body, Roles.Body); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitCheckedStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitCheckedStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitCheckedStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ContinueStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ContinueStatement.cs index cb8cf30e6e..aac1690b21 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ContinueStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ContinueStatement.cs @@ -31,11 +31,27 @@ namespace ICSharpCode.NRefactory.CSharp /// public class ContinueStatement : Statement { + public static readonly TokenRole ContinueKeywordRole = new TokenRole ("continue"); + + public CSharpTokenNode ContinueToken { + get { return GetChildByRole (ContinueKeywordRole); } + } + public CSharpTokenNode SemicolonToken { get { return GetChildByRole (Roles.Semicolon); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitContinueStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitContinueStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitContinueStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/DoWhileStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/DoWhileStatement.cs index 9e0cc4a43e..ec6e2ce269 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/DoWhileStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/DoWhileStatement.cs @@ -31,8 +31,8 @@ namespace ICSharpCode.NRefactory.CSharp /// public class DoWhileStatement : Statement { - public static readonly Role DoKeywordRole = new Role("DoKeyword", CSharpTokenNode.Null); - public static readonly Role WhileKeywordRole = new Role("WhileKeyword", CSharpTokenNode.Null); + public static readonly TokenRole DoKeywordRole = new TokenRole ("do"); + public static readonly TokenRole WhileKeywordRole = new TokenRole ("while"); public CSharpTokenNode DoToken { get { return GetChildByRole (DoKeywordRole); } @@ -64,7 +64,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.Semicolon); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitDoWhileStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitDoWhileStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitDoWhileStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/EmptyStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/EmptyStatement.cs index e0c8999835..deaa3a9c4a 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/EmptyStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/EmptyStatement.cs @@ -29,7 +29,7 @@ namespace ICSharpCode.NRefactory.CSharp /// /// ; /// - public class EmptyStatement : Statement, IRelocatable + public class EmptyStatement : Statement { public TextLocation Location { get; @@ -48,14 +48,17 @@ namespace ICSharpCode.NRefactory.CSharp } } - #region IRelocationable implementation - void IRelocatable.SetStartLocation (TextLocation startLocation) + public override void AcceptVisitor (IAstVisitor visitor) { - this.Location = startLocation; + visitor.VisitEmptyStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitEmptyStatement (this); } - #endregion - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitEmptyStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ExpressionStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ExpressionStatement.cs index 3954d5e427..1fdc4ddc4b 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ExpressionStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ExpressionStatement.cs @@ -40,7 +40,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.Semicolon); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitExpressionStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitExpressionStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitExpressionStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/FixedStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/FixedStatement.cs index 263cf8fbd5..d44366504b 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/FixedStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/FixedStatement.cs @@ -33,8 +33,10 @@ namespace ICSharpCode.NRefactory.CSharp /// public class FixedStatement : Statement { + public static readonly TokenRole FixedKeywordRole = new TokenRole ("fixed"); + public CSharpTokenNode FixedToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (FixedKeywordRole); } } public CSharpTokenNode LParToken { @@ -59,7 +61,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (Roles.EmbeddedStatement, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitFixedStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitFixedStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitFixedStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ForStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ForStatement.cs index a6c91b322f..d369536d01 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ForStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ForStatement.cs @@ -33,11 +33,12 @@ namespace ICSharpCode.NRefactory.CSharp /// public class ForStatement : Statement { + public static readonly TokenRole ForKeywordRole = new TokenRole ("for"); public readonly static Role InitializerRole = new Role("Initializer", Statement.Null); public readonly static Role IteratorRole = new Role("Iterator", Statement.Null); public CSharpTokenNode ForToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (ForKeywordRole); } } public CSharpTokenNode LParToken { @@ -71,7 +72,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (Roles.EmbeddedStatement, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitForStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitForStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitForStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ForeachStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ForeachStatement.cs index ccd3ecdeb1..b3a9c5f786 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ForeachStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ForeachStatement.cs @@ -31,8 +31,11 @@ namespace ICSharpCode.NRefactory.CSharp /// public class ForeachStatement : Statement { + public static readonly TokenRole ForeachKeywordRole = new TokenRole ("foreach"); + public static readonly TokenRole InKeywordRole = new TokenRole ("in"); + public CSharpTokenNode ForeachToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (ForeachKeywordRole); } } public CSharpTokenNode LParToken { @@ -49,7 +52,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole (Roles.Identifier).Name; } set { - SetChildByRole(Roles.Identifier, Identifier.Create (value, TextLocation.Empty)); + SetChildByRole(Roles.Identifier, Identifier.Create (value)); } } @@ -63,7 +66,7 @@ namespace ICSharpCode.NRefactory.CSharp } public CSharpTokenNode InToken { - get { return GetChildByRole (Roles.InKeyword); } + get { return GetChildByRole (InKeywordRole); } } public Expression InExpression { @@ -80,7 +83,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (Roles.EmbeddedStatement, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitForeachStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitForeachStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitForeachStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/GotoStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/GotoStatement.cs index c02e223d63..7aff7a82fb 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/GotoStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/GotoStatement.cs @@ -31,6 +31,8 @@ namespace ICSharpCode.NRefactory.CSharp /// public class GotoStatement : Statement { + public static readonly TokenRole GotoKeywordRole = new TokenRole ("goto"); + public GotoStatement () { } @@ -41,7 +43,7 @@ namespace ICSharpCode.NRefactory.CSharp } public CSharpTokenNode GotoToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (GotoKeywordRole); } } public string Label { @@ -52,7 +54,7 @@ namespace ICSharpCode.NRefactory.CSharp if (string.IsNullOrEmpty(value)) SetChildByRole(Roles.Identifier, null); else - SetChildByRole(Roles.Identifier, Identifier.Create (value, TextLocation.Empty)); + SetChildByRole(Roles.Identifier, Identifier.Create (value)); } } @@ -60,7 +62,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.Semicolon); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitGotoStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitGotoStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitGotoStatement (this, data); } @@ -77,10 +89,11 @@ namespace ICSharpCode.NRefactory.CSharp /// public class GotoCaseStatement : Statement { - public static readonly Role CaseKeywordRole = new Role("CaseKeyword", CSharpTokenNode.Null); + public static readonly TokenRole GotoKeywordRole = new TokenRole ("goto"); + public static readonly TokenRole CaseKeywordRole = new TokenRole ("case"); public CSharpTokenNode GotoToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (GotoKeywordRole); } } public CSharpTokenNode CaseToken { @@ -99,7 +112,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.Semicolon); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitGotoCaseStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitGotoCaseStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitGotoCaseStatement (this, data); } @@ -116,10 +139,11 @@ namespace ICSharpCode.NRefactory.CSharp /// public class GotoDefaultStatement : Statement { - public static readonly Role DefaultKeywordRole = new Role("DefaultKeyword", CSharpTokenNode.Null); + public static readonly TokenRole GotoKeywordRole = new TokenRole ("goto"); + public static readonly TokenRole DefaultKeywordRole = new TokenRole ("default"); public CSharpTokenNode GotoToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (GotoKeywordRole); } } public CSharpTokenNode DefaultToken { @@ -130,7 +154,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.Semicolon); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitGotoDefaultStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitGotoDefaultStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitGotoDefaultStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/IfElseStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/IfElseStatement.cs index 803d7bf8ad..70ece3fd53 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/IfElseStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/IfElseStatement.cs @@ -31,11 +31,10 @@ namespace ICSharpCode.NRefactory.CSharp /// public class IfElseStatement : Statement { - public readonly static Role IfKeywordRole = Roles.Keyword; + public readonly static TokenRole IfKeywordRole = new TokenRole ("if"); public readonly static Role ConditionRole = Roles.Condition; - public readonly static Role QuestionMarkRole = new Role("QuestionMark", CSharpTokenNode.Null); public readonly static Role TrueRole = new Role("True", Statement.Null); - public readonly static Role ElseKeywordRole = new Role("ElseKeyword", CSharpTokenNode.Null); + public readonly static TokenRole ElseKeywordRole = new TokenRole ("else"); public readonly static Role FalseRole = new Role("False", Statement.Null); public CSharpTokenNode IfToken { @@ -69,7 +68,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (FalseRole, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitIfElseStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitIfElseStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitIfElseStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/LabelStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/LabelStatement.cs index 6b3a08cf86..ef2190bfe8 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/LabelStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/LabelStatement.cs @@ -36,15 +36,30 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole (Roles.Identifier).Name; } set { - SetChildByRole(Roles.Identifier, Identifier.Create (value, TextLocation.Empty)); + SetChildByRole(Roles.Identifier, Identifier.Create (value)); } } + public Identifier LabelToken { + get { return GetChildByRole (Roles.Identifier); } + set { SetChildByRole (Roles.Identifier, value); } + } + public CSharpTokenNode Colon { get { return GetChildByRole (Roles.Colon); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitLabelStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitLabelStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitLabelStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/LockStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/LockStatement.cs index 8a5f2f76f7..e59f993080 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/LockStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/LockStatement.cs @@ -31,8 +31,10 @@ namespace ICSharpCode.NRefactory.CSharp /// public class LockStatement : Statement { + public static readonly TokenRole LockKeywordRole = new TokenRole ("lock"); + public CSharpTokenNode LockToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (LockKeywordRole); } } public CSharpTokenNode LParToken { @@ -53,7 +55,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (Roles.EmbeddedStatement, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitLockStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitLockStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitLockStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ReturnStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ReturnStatement.cs index 8219490d7d..0970bce438 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ReturnStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ReturnStatement.cs @@ -31,8 +31,10 @@ namespace ICSharpCode.NRefactory.CSharp /// public class ReturnStatement : Statement { + public static readonly TokenRole ReturnKeywordRole = new TokenRole ("return"); + public CSharpTokenNode ReturnToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (ReturnKeywordRole); } } public Expression Expression { @@ -53,7 +55,17 @@ namespace ICSharpCode.NRefactory.CSharp AddChild (returnExpression, Roles.Expression); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitReturnStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitReturnStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitReturnStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/Statement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/Statement.cs index 665a5dfd75..6d3ec7d1f7 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/Statement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/Statement.cs @@ -25,7 +25,16 @@ namespace ICSharpCode.NRefactory.CSharp } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return default (T); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return default (S); } @@ -56,7 +65,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return NodeType.Pattern; } } - public override S AcceptVisitor(IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitPatternPlaceholder(this, child); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitPatternPlaceholder(this, child); + } + + public override S AcceptVisitor(IAstVisitor visitor, T data) { return visitor.VisitPatternPlaceholder(this, child, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/SwitchStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/SwitchStatement.cs index bf5ca7a834..fa8e80cd56 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/SwitchStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/SwitchStatement.cs @@ -34,10 +34,11 @@ namespace ICSharpCode.NRefactory.CSharp /// public class SwitchStatement : Statement { + public static readonly TokenRole SwitchKeywordRole = new TokenRole ("switch"); public static readonly Role SwitchSectionRole = new Role("SwitchSection"); public CSharpTokenNode SwitchToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (SwitchKeywordRole); } } public CSharpTokenNode LParToken { @@ -65,7 +66,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.RBrace); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitSwitchStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitSwitchStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitSwitchStatement (this, data); } @@ -98,7 +109,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return NodeType.Pattern; } } - public override S AcceptVisitor(IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitPatternPlaceholder(this, child); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitPatternPlaceholder(this, child); + } + + public override S AcceptVisitor(IAstVisitor visitor, T data) { return visitor.VisitPatternPlaceholder(this, child, data); } @@ -131,7 +152,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildrenByRole (Roles.EmbeddedStatement); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitSwitchSection (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitSwitchSection (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitSwitchSection (this, data); } @@ -145,6 +176,9 @@ namespace ICSharpCode.NRefactory.CSharp public class CaseLabel : AstNode { + public static readonly TokenRole CaseKeywordRole = new TokenRole ("case"); + public static readonly TokenRole DefaultKeywordRole = new TokenRole ("default"); + public override NodeType NodeType { get { return NodeType.Unknown; @@ -158,7 +192,11 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.Expression); } set { SetChildByRole (Roles.Expression, value); } } - + + public CSharpTokenNode ColonToken { + get { return GetChildByRole (Roles.Colon); } + } + public CaseLabel () { } @@ -168,7 +206,17 @@ namespace ICSharpCode.NRefactory.CSharp this.Expression = expression; } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitCaseLabel (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitCaseLabel (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitCaseLabel (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ThrowStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ThrowStatement.cs index 5d42af3ccc..98e27d1e7e 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ThrowStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/ThrowStatement.cs @@ -31,8 +31,10 @@ namespace ICSharpCode.NRefactory.CSharp /// public class ThrowStatement : Statement { + public static readonly TokenRole ThrowKeywordRole = new TokenRole ("throw"); + public CSharpTokenNode ThrowToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (ThrowKeywordRole); } } public Expression Expression { @@ -53,7 +55,17 @@ namespace ICSharpCode.NRefactory.CSharp AddChild (expression, Roles.Expression); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitThrowStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitThrowStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitThrowStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/TryCatchStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/TryCatchStatement.cs index 711a6f491a..b190364959 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/TryCatchStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/TryCatchStatement.cs @@ -34,10 +34,10 @@ namespace ICSharpCode.NRefactory.CSharp /// public class TryCatchStatement : Statement { - public static readonly Role TryKeywordRole = new Role("TryKeyword", CSharpTokenNode.Null); + public static readonly TokenRole TryKeywordRole = new TokenRole ("try"); public static readonly Role TryBlockRole = new Role("TryBlock", BlockStatement.Null); public static readonly Role CatchClauseRole = new Role("CatchClause"); - public static readonly Role FinallyKeywordRole = new Role("FinallyKeyword", CSharpTokenNode.Null); + public static readonly TokenRole FinallyKeywordRole = new TokenRole ("finally"); public static readonly Role FinallyBlockRole = new Role("FinallyBlock", BlockStatement.Null); public CSharpTokenNode TryToken { @@ -62,7 +62,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (FinallyBlockRole, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitTryCatchStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitTryCatchStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitTryCatchStatement (this, data); } @@ -79,6 +89,8 @@ namespace ICSharpCode.NRefactory.CSharp /// public class CatchClause : AstNode { + public static readonly TokenRole CatchKeywordRole = new TokenRole ("catch"); + #region PatternPlaceholder public static implicit operator CatchClause(PatternMatching.Pattern pattern) { @@ -98,7 +110,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return NodeType.Pattern; } } - public override S AcceptVisitor(IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitPatternPlaceholder(this, child); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitPatternPlaceholder(this, child); + } + + public override S AcceptVisitor(IAstVisitor visitor, T data) { return visitor.VisitPatternPlaceholder(this, child, data); } @@ -122,7 +144,7 @@ namespace ICSharpCode.NRefactory.CSharp } public CSharpTokenNode CatchToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (CatchKeywordRole); } } public CSharpTokenNode LParToken { @@ -140,7 +162,7 @@ namespace ICSharpCode.NRefactory.CSharp if (string.IsNullOrEmpty(value)) SetChildByRole (Roles.Identifier, null); else - SetChildByRole (Roles.Identifier, Identifier.Create (value, TextLocation.Empty)); + SetChildByRole (Roles.Identifier, Identifier.Create (value)); } } @@ -162,7 +184,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (Roles.Body, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitCatchClause (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitCatchClause (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitCatchClause (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/UncheckedStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/UncheckedStatement.cs index 086cff8548..765cd9ab3a 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/UncheckedStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/UncheckedStatement.cs @@ -31,8 +31,10 @@ namespace ICSharpCode.NRefactory.CSharp /// public class UncheckedStatement : Statement { + public static readonly TokenRole UncheckedKeywordRole = new TokenRole ("unchecked"); + public CSharpTokenNode UncheckedToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (UncheckedKeywordRole); } } public BlockStatement Body { @@ -49,7 +51,17 @@ namespace ICSharpCode.NRefactory.CSharp AddChild (body, Roles.Body); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitUncheckedStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitUncheckedStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitUncheckedStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/UnsafeStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/UnsafeStatement.cs index fba1ebe439..fa6421ae64 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/UnsafeStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/UnsafeStatement.cs @@ -31,8 +31,10 @@ namespace ICSharpCode.NRefactory.CSharp /// public class UnsafeStatement : Statement { + public static readonly TokenRole UnsafeKeywordRole = new TokenRole ("unsafe"); + public CSharpTokenNode UnsafeToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (UnsafeKeywordRole); } } public BlockStatement Body { @@ -40,7 +42,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (Roles.Body, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitUnsafeStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitUnsafeStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitUnsafeStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/UsingStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/UsingStatement.cs index 030ce03687..c873046759 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/UsingStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/UsingStatement.cs @@ -31,10 +31,11 @@ namespace ICSharpCode.NRefactory.CSharp /// public class UsingStatement : Statement { + public static readonly TokenRole UsingKeywordRole = new TokenRole ("using"); public static readonly Role ResourceAcquisitionRole = new Role("ResourceAcquisition", AstNode.Null); public CSharpTokenNode UsingToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (UsingKeywordRole); } } public CSharpTokenNode LParToken { @@ -58,7 +59,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (Roles.EmbeddedStatement, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitUsingStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitUsingStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitUsingStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/VariableDeclarationStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/VariableDeclarationStatement.cs index c9792125f0..32c141d96f 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/VariableDeclarationStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/VariableDeclarationStatement.cs @@ -31,7 +31,7 @@ namespace ICSharpCode.NRefactory.CSharp { public class VariableDeclarationStatement : Statement { - public static readonly Role ModifierRole = AttributedNode.ModifierRole; + public static readonly Role ModifierRole = EntityDeclaration.ModifierRole; public VariableDeclarationStatement() { @@ -44,8 +44,8 @@ namespace ICSharpCode.NRefactory.CSharp } public Modifiers Modifiers { - get { return AttributedNode.GetModifiers(this); } - set { AttributedNode.SetModifiers(this, value); } + get { return EntityDeclaration.GetModifiers(this); } + set { EntityDeclaration.SetModifiers(this, value); } } public AstType Type { @@ -63,10 +63,20 @@ namespace ICSharpCode.NRefactory.CSharp public VariableInitializer GetVariable (string name) { - return Variables.FirstOrDefault (vi => vi.Name == name); + return Variables.FirstOrNullObject (vi => vi.Name == name); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitVariableDeclarationStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitVariableDeclarationStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitVariableDeclarationStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/WhileStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/WhileStatement.cs index db71887c41..256ddb8641 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/WhileStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/WhileStatement.cs @@ -31,7 +31,7 @@ namespace ICSharpCode.NRefactory.CSharp /// public class WhileStatement : Statement { - public static readonly Role WhileKeywordRole = new Role("WhileKeyword", CSharpTokenNode.Null); + public static readonly TokenRole WhileKeywordRole = new TokenRole ("while"); public CSharpTokenNode WhileToken { get { return GetChildByRole (WhileKeywordRole); } @@ -55,7 +55,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (Roles.EmbeddedStatement, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitWhileStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitWhileStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitWhileStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/YieldBreakStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/YieldBreakStatement.cs index 253253feff..ea5cac4a68 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/YieldBreakStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/YieldBreakStatement.cs @@ -31,8 +31,8 @@ namespace ICSharpCode.NRefactory.CSharp /// public class YieldBreakStatement : Statement { - public static readonly Role YieldKeywordRole = new Role("YieldKeyword", CSharpTokenNode.Null); - public static readonly Role BreakKeywordRole = new Role("BreakKeyword", CSharpTokenNode.Null); + public static readonly TokenRole YieldKeywordRole = new TokenRole ("yield"); + public static readonly TokenRole BreakKeywordRole = new TokenRole ("break"); public CSharpTokenNode YieldToken { get { return GetChildByRole (YieldKeywordRole); } @@ -46,7 +46,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.Semicolon); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitYieldBreakStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitYieldBreakStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitYieldBreakStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/YieldReturnStatement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/YieldReturnStatement.cs index a3b65ac2ab..6539bf0c0a 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/YieldReturnStatement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/Statements/YieldReturnStatement.cs @@ -31,8 +31,8 @@ namespace ICSharpCode.NRefactory.CSharp /// public class YieldReturnStatement : Statement { - public static readonly Role YieldKeywordRole = new Role("YieldKeyword", CSharpTokenNode.Null); - public static readonly Role ReturnKeywordRole = new Role("ReturnKeyword", CSharpTokenNode.Null); + public static readonly TokenRole YieldKeywordRole = new TokenRole ("yield"); + public static readonly TokenRole ReturnKeywordRole = new TokenRole ("return"); public CSharpTokenNode YieldToken { get { return GetChildByRole (YieldKeywordRole); } @@ -51,7 +51,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.Semicolon); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitYieldReturnStatement (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitYieldReturnStatement (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitYieldReturnStatement (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TokenRole.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TokenRole.cs new file mode 100644 index 0000000000..29a67ab272 --- /dev/null +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TokenRole.cs @@ -0,0 +1,33 @@ +using System; + +namespace ICSharpCode.NRefactory.CSharp +{ + /// + /// A specific role only used for C# tokens + /// + public sealed class TokenRole : Role + { + /// + /// Gets the token as string. Note that the token Name and Token value may differ. + /// + public string Token { + get; + private set; + } + + /// + /// Gets the char length of the token. + /// + public int Length { + get; + private set; + } + + public TokenRole (string token) : base (token, CSharpTokenNode.Null) + { + this.Token = token; + this.Length = token.Length; + } + } +} + diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/Accessor.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/Accessor.cs index 1da7986bb3..a920a849c4 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/Accessor.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/Accessor.cs @@ -1,6 +1,6 @@ // // PropertyDeclaration.cs -// +// // Author: // Mike Krüger // @@ -25,13 +25,14 @@ // THE SOFTWARE. using System; +using ICSharpCode.NRefactory.TypeSystem; namespace ICSharpCode.NRefactory.CSharp { /// /// get/set/add/remove /// - public class Accessor : AttributedNode + public class Accessor : EntityDeclaration { public static readonly new Accessor Null = new NullAccessor (); sealed class NullAccessor : Accessor @@ -42,7 +43,16 @@ namespace ICSharpCode.NRefactory.CSharp } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return default (T); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return default (S); } @@ -57,12 +67,26 @@ namespace ICSharpCode.NRefactory.CSharp get { return NodeType.Unknown; } } + public override EntityType EntityType { + get { return EntityType.Method; } + } + public BlockStatement Body { get { return GetChildByRole (Roles.Body); } set { SetChildByRole (Roles.Body, value); } } - public override S AcceptVisitor(IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitAccessor (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitAccessor (this); + } + + public override S AcceptVisitor(IAstVisitor visitor, T data) { return visitor.VisitAccessor (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/ConstructorDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/ConstructorDeclaration.cs index 8f111e9a52..204776793c 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/ConstructorDeclaration.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/ConstructorDeclaration.cs @@ -24,25 +24,16 @@ // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN // THE SOFTWARE. -using System.Collections.Generic; -using System.Linq; +using ICSharpCode.NRefactory.TypeSystem; namespace ICSharpCode.NRefactory.CSharp { - public class ConstructorDeclaration : AttributedNode + public class ConstructorDeclaration : EntityDeclaration { public static readonly Role InitializerRole = new Role("Initializer", ConstructorInitializer.Null); - /// - /// Gets/Sets the name of the class containing the constructor. - /// This property can be used to inform the output visitor about the class name when writing a constructor declaration - /// without writing the complete type declaration. It is ignored when the constructor has a type declaration as parent. - /// - public string Name { get; set; } - - public Identifier IdentifierToken { - get { return GetChildByRole (Roles.Identifier); } - set { SetChildByRole (Roles.Identifier, value); } + public override EntityType EntityType { + get { return EntityType.Constructor; } } public CSharpTokenNode LParToken { @@ -71,11 +62,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (Roles.Body, value); } } - public override NodeType NodeType { - get { return NodeType.Member; } + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitConstructorDeclaration (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitConstructorDeclaration (this); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitConstructorDeclaration (this, data); } @@ -95,6 +92,9 @@ namespace ICSharpCode.NRefactory.CSharp public class ConstructorInitializer : AstNode { + public static readonly TokenRole BaseKeywordRole = new TokenRole ("base"); + public static readonly TokenRole ThisKeywordRole = new TokenRole ("this"); + public static readonly new ConstructorInitializer Null = new NullConstructorInitializer (); class NullConstructorInitializer : ConstructorInitializer { @@ -110,7 +110,16 @@ namespace ICSharpCode.NRefactory.CSharp } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return default (T); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return default (S); } @@ -144,7 +153,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.RPar); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitConstructorInitializer (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitConstructorInitializer (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitConstructorInitializer (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/DestructorDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/DestructorDeclaration.cs index 0e129e4330..5f2411ec86 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/DestructorDeclaration.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/DestructorDeclaration.cs @@ -24,26 +24,20 @@ // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN // THE SOFTWARE. +using ICSharpCode.NRefactory.TypeSystem; + namespace ICSharpCode.NRefactory.CSharp { - public class DestructorDeclaration : AttributedNode + public class DestructorDeclaration : EntityDeclaration { - public static readonly Role TildeRole = new Role("Tilde", CSharpTokenNode.Null); + public static readonly TokenRole TildeRole = new TokenRole ("~"); public CSharpTokenNode TildeToken { get { return GetChildByRole (TildeRole); } } - /// - /// Gets/Sets the name of the class containing the destructor. - /// This property can be used to inform the output visitor about the class name when writing a destructor declaration - /// without writing the complete type declaration. It is ignored when the destructor has a type declaration as parent. - /// - public string Name { get; set; } - - public Identifier IdentifierToken { - get { return GetChildByRole (Roles.Identifier); } - set { SetChildByRole (Roles.Identifier, value); } + public override EntityType EntityType { + get { return EntityType.Destructor; } } public CSharpTokenNode LParToken { @@ -58,11 +52,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (Roles.Body, value); } } - public override NodeType NodeType { - get { return NodeType.Member; } + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitDestructorDeclaration (this); } - - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitDestructorDeclaration (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitDestructorDeclaration (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/AttributedNode.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/EntityDeclaration.cs similarity index 74% rename from src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/AttributedNode.cs rename to src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/EntityDeclaration.cs index f854c594a7..ca8f69338d 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/AttributedNode.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/EntityDeclaration.cs @@ -22,10 +22,18 @@ using System.Linq; namespace ICSharpCode.NRefactory.CSharp { - public abstract class AttributedNode : AstNode + public abstract class EntityDeclaration : AstNode { public static readonly Role AttributeRole = new Role("Attribute"); + public static readonly Role UnattachedAttributeRole = new Role("UnattachedAttribute"); public static readonly Role ModifierRole = new Role("Modifier"); + public static readonly Role PrivateImplementationTypeRole = new Role("PrivateImplementationType", AstType.Null); + + public override NodeType NodeType { + get { return NodeType.Member; } + } + + public abstract NRefactory.TypeSystem.EntityType EntityType { get; } public AstNodeCollection Attributes { get { return base.GetChildrenByRole (AttributeRole); } @@ -36,10 +44,34 @@ namespace ICSharpCode.NRefactory.CSharp set { SetModifiers(this, value); } } + public bool HasModifier (Modifiers mod) + { + return (Modifiers & mod) == mod; + } + public IEnumerable ModifierTokens { get { return GetChildrenByRole (ModifierRole); } } + public virtual string Name { + get { + return GetChildByRole (Roles.Identifier).Name; + } + set { + SetChildByRole (Roles.Identifier, Identifier.Create (value, TextLocation.Empty)); + } + } + + public virtual Identifier NameToken { + get { return GetChildByRole (Roles.Identifier); } + set { SetChildByRole (Roles.Identifier, value); } + } + + public virtual AstType ReturnType { + get { return GetChildByRole (Roles.Type); } + set { SetChildByRole(Roles.Type, value); } + } + internal static Modifiers GetModifiers(AstNode node) { Modifiers m = 0; @@ -73,14 +105,9 @@ namespace ICSharpCode.NRefactory.CSharp } } - protected bool MatchAttributesAndModifiers (AttributedNode o, PatternMatching.Match match) + protected bool MatchAttributesAndModifiers (EntityDeclaration o, PatternMatching.Match match) { return (this.Modifiers == Modifiers.Any || this.Modifiers == o.Modifiers) && this.Attributes.DoMatch (o.Attributes, match); } - - public bool HasModifier (Modifiers mod) - { - return (Modifiers & mod) == mod; - } } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/EnumMemberDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/EnumMemberDeclaration.cs index f646a93853..8f05e4e2ab 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/EnumMemberDeclaration.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/EnumMemberDeclaration.cs @@ -23,30 +23,18 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN // THE SOFTWARE. + using System; +using ICSharpCode.NRefactory.TypeSystem; namespace ICSharpCode.NRefactory.CSharp { - public class EnumMemberDeclaration : AttributedNode + public class EnumMemberDeclaration : EntityDeclaration { public static readonly Role InitializerRole = new Role("Initializer", Expression.Null); - public string Name { - get { - return GetChildByRole (Roles.Identifier).Name; - } - set { - SetChildByRole (Roles.Identifier, Identifier.Create (value, TextLocation.Empty)); - } - } - - public Identifier NameToken { - get { - return GetChildByRole (Roles.Identifier); - } - set { - SetChildByRole (Roles.Identifier, value); - } + public override EntityType EntityType { + get { return EntityType.Field; } } public Expression Initializer { @@ -54,11 +42,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (InitializerRole, value); } } - public override NodeType NodeType { - get { return NodeType.Member; } + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitEnumMemberDeclaration (this); } - - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitEnumMemberDeclaration (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitEnumMemberDeclaration (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/EventDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/EventDeclaration.cs index 752463a2e2..8c1958cf82 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/EventDeclaration.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/EventDeclaration.cs @@ -25,25 +25,33 @@ // THE SOFTWARE. using System.Collections.Generic; +using ICSharpCode.NRefactory.TypeSystem; namespace ICSharpCode.NRefactory.CSharp { - public class EventDeclaration : AttributedNode + public class EventDeclaration : EntityDeclaration { - public override NodeType NodeType { - get { return NodeType.Member; } - } + public static readonly TokenRole EventKeywordRole = new TokenRole ("event"); - public AstType ReturnType { - get { return GetChildByRole (Roles.Type); } - set { SetChildByRole(Roles.Type, value); } + public override EntityType EntityType { + get { return EntityType.Event; } } public AstNodeCollection Variables { get { return GetChildrenByRole (Roles.Variable); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitEventDeclaration (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitEventDeclaration (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitEventDeclaration (this, data); } @@ -56,11 +64,28 @@ namespace ICSharpCode.NRefactory.CSharp } } - public class CustomEventDeclaration : MemberDeclaration + public class CustomEventDeclaration : EntityDeclaration { + public static readonly TokenRole EventKeywordRole = new TokenRole ("event"); + public static readonly TokenRole AddKeywordRole = new TokenRole ("add"); + public static readonly TokenRole RemoveKeywordRole = new TokenRole ("remove"); + public static readonly Role AddAccessorRole = new Role("AddAccessor", Accessor.Null); public static readonly Role RemoveAccessorRole = new Role("RemoveAccessor", Accessor.Null); + public override EntityType EntityType { + get { return EntityType.Event; } + } + + /// + /// Gets/Sets the type reference of the interface that is explicitly implemented. + /// Null node if this member is not an explicit interface implementation. + /// + public AstType PrivateImplementationType { + get { return GetChildByRole (PrivateImplementationTypeRole); } + set { SetChildByRole (PrivateImplementationTypeRole, value); } + } + public CSharpTokenNode LBraceToken { get { return GetChildByRole (Roles.LBrace); } } @@ -79,7 +104,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.RBrace); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitCustomEventDeclaration (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitCustomEventDeclaration (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitCustomEventDeclaration (this, data); } @@ -87,7 +122,9 @@ namespace ICSharpCode.NRefactory.CSharp protected internal override bool DoMatch(AstNode other, PatternMatching.Match match) { CustomEventDeclaration o = other as CustomEventDeclaration; - return o != null && this.MatchMember(o, match) + return o != null && MatchString(this.Name, o.Name) + && this.MatchAttributesAndModifiers(o, match) && this.ReturnType.DoMatch(o.ReturnType, match) + && this.PrivateImplementationType.DoMatch(o.PrivateImplementationType, match) && this.AddAccessor.DoMatch(o.AddAccessor, match) && this.RemoveAccessor.DoMatch(o.RemoveAccessor, match); } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/FieldDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/FieldDeclaration.cs index 2b30b2be30..16406d59d0 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/FieldDeclaration.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/FieldDeclaration.cs @@ -24,27 +24,31 @@ // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN // THE SOFTWARE. -using System.Collections.Generic; -using System.Linq; +using ICSharpCode.NRefactory.TypeSystem; namespace ICSharpCode.NRefactory.CSharp { - public class FieldDeclaration : AttributedNode + public class FieldDeclaration : EntityDeclaration { - public override NodeType NodeType { - get { return NodeType.Member; } - } - - public AstType ReturnType { - get { return GetChildByRole (Roles.Type); } - set { SetChildByRole(Roles.Type, value); } + public override EntityType EntityType { + get { return EntityType.Field; } } public AstNodeCollection Variables { get { return GetChildrenByRole (Roles.Variable); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitFieldDeclaration (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitFieldDeclaration (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitFieldDeclaration (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/FixedFieldDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/FixedFieldDeclaration.cs index ea20b3585a..ebc20c5ef7 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/FixedFieldDeclaration.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/FixedFieldDeclaration.cs @@ -24,31 +24,38 @@ // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN // THE SOFTWARE. using System; +using ICSharpCode.NRefactory.TypeSystem; namespace ICSharpCode.NRefactory.CSharp { - public class FixedFieldDeclaration : AttributedNode + public class FixedFieldDeclaration : EntityDeclaration { + public static readonly TokenRole FixedKeywordRole = new TokenRole ("fixed"); public static readonly Role VariableRole = new Role ("FixedVariable"); - public override NodeType NodeType { - get { return NodeType.Member; } + public override EntityType EntityType { + get { return EntityType.Field; } } public CSharpTokenNode FixedToken { - get { return GetChildByRole (Roles.Keyword); } + get { return GetChildByRole (FixedKeywordRole); } } - public AstType ReturnType { - get { return GetChildByRole (Roles.Type); } - set { SetChildByRole (Roles.Type, value); } - } - public AstNodeCollection Variables { get { return GetChildrenByRole (VariableRole); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitFixedFieldDeclaration (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitFixedFieldDeclaration (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitFixedFieldDeclaration (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/FixedVariableInitializer.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/FixedVariableInitializer.cs index 11bbc138ae..2c320a826c 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/FixedVariableInitializer.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/FixedVariableInitializer.cs @@ -54,7 +54,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole (Roles.Identifier).Name; } set { - SetChildByRole (Roles.Identifier, Identifier.Create (value, TextLocation.Empty)); + SetChildByRole (Roles.Identifier, Identifier.Create (value)); } } @@ -79,8 +79,18 @@ namespace ICSharpCode.NRefactory.CSharp public CSharpTokenNode RBracketToken { get { return GetChildByRole (Roles.RBracket); } } + + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitFixedVariableInitializer (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitFixedVariableInitializer (this); + } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitFixedVariableInitializer (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/IndexerDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/IndexerDeclaration.cs index 221a6dde8c..c175485ab5 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/IndexerDeclaration.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/IndexerDeclaration.cs @@ -24,16 +24,29 @@ // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN // THE SOFTWARE. -using System.Collections.Generic; -using System.Linq; +using ICSharpCode.NRefactory.TypeSystem; namespace ICSharpCode.NRefactory.CSharp { - public class IndexerDeclaration : MemberDeclaration + public class IndexerDeclaration : EntityDeclaration { + public static readonly TokenRole ThisKeywordRole = new TokenRole ("this"); public static readonly Role GetterRole = PropertyDeclaration.GetterRole; public static readonly Role SetterRole = PropertyDeclaration.SetterRole; + public override EntityType EntityType { + get { return EntityType.Indexer; } + } + + /// + /// Gets/Sets the type reference of the interface that is explicitly implemented. + /// Null node if this member is not an explicit interface implementation. + /// + public AstType PrivateImplementationType { + get { return GetChildByRole (PrivateImplementationTypeRole); } + set { SetChildByRole (PrivateImplementationTypeRole, value); } + } + public CSharpTokenNode LBracketToken { get { return GetChildByRole (Roles.LBracket); } } @@ -64,7 +77,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.RBrace); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitIndexerDeclaration (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitIndexerDeclaration (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitIndexerDeclaration (this, data); } @@ -72,7 +95,10 @@ namespace ICSharpCode.NRefactory.CSharp protected internal override bool DoMatch(AstNode other, PatternMatching.Match match) { IndexerDeclaration o = other as IndexerDeclaration; - return o != null && this.MatchMember(o, match) && this.Parameters.DoMatch(o.Parameters, match) + return o != null && MatchString(this.Name, o.Name) + && this.MatchAttributesAndModifiers(o, match) && this.ReturnType.DoMatch(o.ReturnType, match) + && this.PrivateImplementationType.DoMatch(o.PrivateImplementationType, match) + && this.Parameters.DoMatch(o.Parameters, match) && this.Getter.DoMatch(o.Getter, match) && this.Setter.DoMatch(o.Setter, match); } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/MemberDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/MemberDeclaration.cs deleted file mode 100644 index e1463c0771..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/MemberDeclaration.cs +++ /dev/null @@ -1,74 +0,0 @@ -// -// AbstractMember.cs -// -// Author: -// Mike Krüger -// -// Copyright (c) 2009 Novell, Inc (http://www.novell.com) -// -// Permission is hereby granted, free of charge, to any person obtaining a copy -// of this software and associated documentation files (the "Software"), to deal -// in the Software without restriction, including without limitation the rights -// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -// copies of the Software, and to permit persons to whom the Software is -// furnished to do so, subject to the following conditions: -// -// The above copyright notice and this permission notice shall be included in -// all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -// THE SOFTWARE. - -namespace ICSharpCode.NRefactory.CSharp -{ - public abstract class MemberDeclaration : AttributedNode - { - public static readonly Role PrivateImplementationTypeRole = new Role("PrivateImplementationType", AstType.Null); - - public AstType ReturnType { - get { return GetChildByRole (Roles.Type); } - set { SetChildByRole(Roles.Type, value); } - } - - /// - /// Only supported on members that can be declared in an interface. - /// - public AstType PrivateImplementationType { - get { return GetChildByRole (PrivateImplementationTypeRole); } - set { SetChildByRole (PrivateImplementationTypeRole, value); } - } - - public string Name { - get { - return GetChildByRole (Roles.Identifier).Name; - } - set { - SetChildByRole (Roles.Identifier, Identifier.Create (value, TextLocation.Empty)); - } - } - - public Identifier NameToken { - get { - return GetChildByRole (Roles.Identifier); - } - set { - SetChildByRole (Roles.Identifier, value); - } - } - - public override NodeType NodeType { - get { return NodeType.Member; } - } - - protected bool MatchMember(MemberDeclaration o, PatternMatching.Match match) - { - return MatchAttributesAndModifiers(o, match) && this.ReturnType.DoMatch(o.ReturnType, match) - && this.PrivateImplementationType.DoMatch(o.PrivateImplementationType, match) && MatchString(this.Name, o.Name); - } - } -} diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/MethodDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/MethodDeclaration.cs index 129c87e26e..0d4a2340b3 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/MethodDeclaration.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/MethodDeclaration.cs @@ -24,13 +24,25 @@ // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN // THE SOFTWARE. -using System.Collections.Generic; -using System.Linq; +using ICSharpCode.NRefactory.TypeSystem; namespace ICSharpCode.NRefactory.CSharp { - public class MethodDeclaration : MemberDeclaration + public class MethodDeclaration : EntityDeclaration { + public override EntityType EntityType { + get { return EntityType.Method; } + } + + /// + /// Gets/Sets the type reference of the interface that is explicitly implemented. + /// Null node if this member is not an explicit interface implementation. + /// + public AstType PrivateImplementationType { + get { return GetChildByRole (PrivateImplementationTypeRole); } + set { SetChildByRole (PrivateImplementationTypeRole, value); } + } + public AstNodeCollection TypeParameters { get { return GetChildrenByRole (Roles.TypeParameter); } } @@ -63,7 +75,17 @@ namespace ICSharpCode.NRefactory.CSharp } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitMethodDeclaration (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitMethodDeclaration (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitMethodDeclaration (this, data); } @@ -71,7 +93,10 @@ namespace ICSharpCode.NRefactory.CSharp protected internal override bool DoMatch(AstNode other, PatternMatching.Match match) { MethodDeclaration o = other as MethodDeclaration; - return o != null && this.MatchMember(o, match) && this.TypeParameters.DoMatch(o.TypeParameters, match) + return o != null && MatchString(this.Name, o.Name) + && this.MatchAttributesAndModifiers(o, match) && this.ReturnType.DoMatch(o.ReturnType, match) + && this.PrivateImplementationType.DoMatch(o.PrivateImplementationType, match) + && this.TypeParameters.DoMatch(o.TypeParameters, match) && this.Parameters.DoMatch(o.Parameters, match) && this.Constraints.DoMatch(o.Constraints, match) && this.Body.DoMatch(o.Body, match); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/OperatorDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/OperatorDeclaration.cs index 35865d24c0..8e09673577 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/OperatorDeclaration.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/OperatorDeclaration.cs @@ -23,8 +23,9 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN // THE SOFTWARE. -using System.Collections.Generic; -using System.Linq; + +using System; +using ICSharpCode.NRefactory.TypeSystem; namespace ICSharpCode.NRefactory.CSharp { @@ -69,19 +70,61 @@ namespace ICSharpCode.NRefactory.CSharp Explicit = Mono.CSharp.Operator.OpType.Explicit } - public class OperatorDeclaration : AttributedNode + public class OperatorDeclaration : EntityDeclaration { - public static readonly Role OperatorTypeRole = new Role ("OperatorType", CSharpTokenNode.Null); - public static readonly Role OperatorKeywordRole = Roles.Keyword; + public static readonly TokenRole OperatorKeywordRole = new TokenRole ("operator"); + + // Unary operators + public static readonly TokenRole LogicalNotRole = new TokenRole ("!"); + public static readonly TokenRole OnesComplementRole = new TokenRole ("~"); + public static readonly TokenRole IncrementRole = new TokenRole ("++"); + public static readonly TokenRole DecrementRole = new TokenRole ("--"); + public static readonly TokenRole TrueRole = new TokenRole ("true"); + public static readonly TokenRole FalseRole = new TokenRole ("false"); + + // Unary and Binary operators + public static readonly TokenRole AdditionRole = new TokenRole ("+"); + public static readonly TokenRole SubtractionRole = new TokenRole ("-"); + + // Binary operators + public static readonly TokenRole MultiplyRole = new TokenRole ("*"); + public static readonly TokenRole DivisionRole = new TokenRole ("/"); + public static readonly TokenRole ModulusRole = new TokenRole ("%"); + public static readonly TokenRole BitwiseAndRole = new TokenRole ("&"); + public static readonly TokenRole BitwiseOrRole = new TokenRole ("|"); + public static readonly TokenRole ExclusiveOrRole = new TokenRole ("^"); + public static readonly TokenRole LeftShiftRole = new TokenRole ("<<"); + public static readonly TokenRole RightShiftRole = new TokenRole (">>"); + public static readonly TokenRole EqualityRole = new TokenRole ("=="); + public static readonly TokenRole InequalityRole = new TokenRole ("!="); + public static readonly TokenRole GreaterThanRole = new TokenRole (">"); + public static readonly TokenRole LessThanRole = new TokenRole ("<"); + public static readonly TokenRole GreaterThanOrEqualRole = new TokenRole (">="); + public static readonly TokenRole LessThanOrEqualRole = new TokenRole ("<="); + + public static readonly TokenRole ExplicitRole = new TokenRole ("explicit"); + public static readonly TokenRole ImplicitRole = new TokenRole ("implicit"); + + public override EntityType EntityType { + get { return EntityType.Operator; } + } + + OperatorType operatorType; public OperatorType OperatorType { - get; - set; + get { return operatorType; } + set { + ThrowIfFrozen(); + operatorType = value; + } } - public AstType ReturnType { - get { return GetChildByRole (Roles.Type); } - set { SetChildByRole (Roles.Type, value); } + public CSharpTokenNode OperatorToken { + get { return GetChildByRole (OperatorKeywordRole); } + } + + public CSharpTokenNode OperatorTypeToken { + get { return GetChildByRole (GetRole (OperatorType)); } } public CSharpTokenNode LParToken { @@ -109,6 +152,68 @@ namespace ICSharpCode.NRefactory.CSharp return (OperatorType?)Mono.CSharp.Operator.GetType(methodName); } + public static TokenRole GetRole (OperatorType type) + { + switch (type) { + case OperatorType.LogicalNot: + return LogicalNotRole; + case OperatorType.OnesComplement: + return OnesComplementRole; + case OperatorType.Increment: + return IncrementRole; + case OperatorType.Decrement: + return DecrementRole; + case OperatorType.True: + return TrueRole; + case OperatorType.False: + return FalseRole; + + case OperatorType.Addition: + case OperatorType.UnaryPlus: + return AdditionRole; + case OperatorType.Subtraction: + case OperatorType.UnaryNegation: + return SubtractionRole; + + case OperatorType.Multiply: + return MultiplyRole; + case OperatorType.Division: + return DivisionRole; + case OperatorType.Modulus: + return ModulusRole; + case OperatorType.BitwiseAnd: + return BitwiseAndRole; + case OperatorType.BitwiseOr: + return BitwiseOrRole; + case OperatorType.ExclusiveOr: + return ExclusiveOrRole; + case OperatorType.LeftShift: + return LeftShiftRole; + case OperatorType.RightShift: + return RightShiftRole; + case OperatorType.Equality: + return EqualityRole; + case OperatorType.Inequality: + return InequalityRole; + case OperatorType.GreaterThan: + return GreaterThanRole; + case OperatorType.LessThan: + return LessThanRole; + case OperatorType.GreaterThanOrEqual: + return GreaterThanOrEqualRole; + case OperatorType.LessThanOrEqual: + return LessThanOrEqualRole; + + case OperatorType.Implicit: + return ImplicitRole; + case OperatorType.Explicit: + return ExplicitRole; + + default: + throw new System.ArgumentOutOfRangeException (); + } + } + /// /// Gets the method name for the operator type. ("op_Addition", "op_Implicit", etc.) /// @@ -125,17 +230,29 @@ namespace ICSharpCode.NRefactory.CSharp return Mono.CSharp.Operator.GetName ((Mono.CSharp.Operator.OpType)type); } - public override NodeType NodeType { - get { return NodeType.Member; } + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitOperatorDeclaration (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitOperatorDeclaration (this); } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitOperatorDeclaration (this, data); } - public string Name { + public override string Name { get { return GetName (this.OperatorType); } + set { throw new NotSupportedException(); } + } + + public override Identifier NameToken { + get { return Identifier.Null; } + set { throw new NotSupportedException(); } } protected internal override bool DoMatch (AstNode other, PatternMatching.Match match) diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/ParameterDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/ParameterDeclaration.cs index 3329730046..15b4993d23 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/ParameterDeclaration.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/ParameterDeclaration.cs @@ -40,8 +40,11 @@ namespace ICSharpCode.NRefactory.CSharp public class ParameterDeclaration : AstNode { - public static readonly Role AttributeRole = AttributedNode.AttributeRole; - public static readonly Role ModifierRole = new Role("Modifier", CSharpTokenNode.Null); + public static readonly Role AttributeRole = EntityDeclaration.AttributeRole; + public static readonly TokenRole RefModifierRole = new TokenRole("ref"); + public static readonly TokenRole OutModifierRole = new TokenRole("out"); + public static readonly TokenRole ParamsModifierRole = new TokenRole("params"); + public static readonly TokenRole ThisModifierRole = new TokenRole("this"); public override NodeType NodeType { get { @@ -53,9 +56,14 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildrenByRole (AttributeRole); } } + ParameterModifier parameterModifier; + public ParameterModifier ParameterModifier { - get; - set; + get { return parameterModifier; } + set { + ThrowIfFrozen(); + parameterModifier = value; + } } public AstType Type { @@ -68,7 +76,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole (Roles.Identifier).Name; } set { - SetChildByRole (Roles.Identifier, Identifier.Create (value, TextLocation.Empty)); + SetChildByRole (Roles.Identifier, Identifier.Create (value)); } } @@ -86,7 +94,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (Roles.Expression, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitParameterDeclaration (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitParameterDeclaration (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitParameterDeclaration (this, data); } @@ -103,10 +121,11 @@ namespace ICSharpCode.NRefactory.CSharp { } - public ParameterDeclaration(AstType type, string name) + public ParameterDeclaration(AstType type, string name, ParameterModifier modifier = ParameterModifier.None) { - this.Type = type; - this.Name = name; + Type = type; + Name = name; + ParameterModifier = modifier; } } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/PropertyDeclaration.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/PropertyDeclaration.cs index 5362667504..df0fa9876f 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/PropertyDeclaration.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/PropertyDeclaration.cs @@ -23,14 +23,30 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN // THE SOFTWARE. +using ICSharpCode.NRefactory.TypeSystem; namespace ICSharpCode.NRefactory.CSharp { - public class PropertyDeclaration : MemberDeclaration + public class PropertyDeclaration : EntityDeclaration { + public static readonly TokenRole GetKeywordRole = new TokenRole ("get"); + public static readonly TokenRole SetKeywordRole = new TokenRole ("set"); public static readonly Role GetterRole = new Role("Getter", Accessor.Null); public static readonly Role SetterRole = new Role("Setter", Accessor.Null); + public override EntityType EntityType { + get { return EntityType.Property; } + } + + /// + /// Gets/Sets the type reference of the interface that is explicitly implemented. + /// Null node if this member is not an explicit interface implementation. + /// + public AstType PrivateImplementationType { + get { return GetChildByRole (PrivateImplementationTypeRole); } + set { SetChildByRole (PrivateImplementationTypeRole, value); } + } + public CSharpTokenNode LBraceToken { get { return GetChildByRole (Roles.LBrace); } } @@ -49,7 +65,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return GetChildByRole (Roles.RBrace); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitPropertyDeclaration (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitPropertyDeclaration (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitPropertyDeclaration (this, data); } @@ -57,7 +83,9 @@ namespace ICSharpCode.NRefactory.CSharp protected internal override bool DoMatch(AstNode other, PatternMatching.Match match) { PropertyDeclaration o = other as PropertyDeclaration; - return o != null && this.MatchMember(o, match) + return o != null && MatchString(this.Name, o.Name) + && this.MatchAttributesAndModifiers(o, match) && this.ReturnType.DoMatch(o.ReturnType, match) + && this.PrivateImplementationType.DoMatch(o.PrivateImplementationType, match) && this.Getter.DoMatch(o.Getter, match) && this.Setter.DoMatch(o.Setter, match); } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/VariableInitializer.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/VariableInitializer.cs index 314fca0c9e..8b0c3fff2d 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/VariableInitializer.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Ast/TypeMembers/VariableInitializer.cs @@ -28,6 +28,38 @@ namespace ICSharpCode.NRefactory.CSharp { public class VariableInitializer : AstNode { + #region Null + public new static readonly VariableInitializer Null = new NullVariableInitializer (); + + sealed class NullVariableInitializer : VariableInitializer + { + public override bool IsNull { + get { + return true; + } + } + + public override void AcceptVisitor (IAstVisitor visitor) + { + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return default (T); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) + { + return default (S); + } + + protected internal override bool DoMatch(AstNode other, PatternMatching.Match match) + { + return other == null || other.IsNull; + } + } + #endregion + #region PatternPlaceholder public static implicit operator VariableInitializer(PatternMatching.Pattern pattern) { @@ -47,7 +79,17 @@ namespace ICSharpCode.NRefactory.CSharp get { return NodeType.Pattern; } } - public override S AcceptVisitor(IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitPatternPlaceholder (this, child); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitPatternPlaceholder (this, child); + } + + public override S AcceptVisitor(IAstVisitor visitor, T data) { return visitor.VisitPatternPlaceholder(this, child, data); } @@ -85,7 +127,7 @@ namespace ICSharpCode.NRefactory.CSharp return GetChildByRole (Roles.Identifier).Name; } set { - SetChildByRole (Roles.Identifier, Identifier.Create (value, TextLocation.Empty)); + SetChildByRole (Roles.Identifier, Identifier.Create (value)); } } @@ -107,7 +149,17 @@ namespace ICSharpCode.NRefactory.CSharp set { SetChildByRole (Roles.Expression, value); } } - public override S AcceptVisitor (IAstVisitor visitor, T data = default(T)) + public override void AcceptVisitor (IAstVisitor visitor) + { + visitor.VisitVariableInitializer (this); + } + + public override T AcceptVisitor (IAstVisitor visitor) + { + return visitor.VisitVariableInitializer (this); + } + + public override S AcceptVisitor (IAstVisitor visitor, T data) { return visitor.VisitVariableInitializer (this, data); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/CSharpProjectContent.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/CSharpProjectContent.cs index bdc2040490..b7475d4cec 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/CSharpProjectContent.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/CSharpProjectContent.cs @@ -44,7 +44,7 @@ namespace ICSharpCode.NRefactory.CSharp protected CSharpProjectContent(CSharpProjectContent pc) { this.assemblyName = pc.assemblyName; - this.parsedFiles = new Dictionary(pc.parsedFiles); + this.parsedFiles = new Dictionary(pc.parsedFiles, Platform.FileNameComparer); this.assemblyReferences = new List(pc.assemblyReferences); } @@ -87,7 +87,7 @@ namespace ICSharpCode.NRefactory.CSharp return null; } - public ICompilation CreateCompilation() + public virtual ICompilation CreateCompilation() { var solutionSnapshot = new DefaultSolutionSnapshot(); ICompilation compilation = new SimpleCompilation(solutionSnapshot, this, assemblyReferences); @@ -95,28 +95,33 @@ namespace ICSharpCode.NRefactory.CSharp return compilation; } - public ICompilation CreateCompilation(ISolutionSnapshot solutionSnapshot) + public virtual ICompilation CreateCompilation(ISolutionSnapshot solutionSnapshot) { return new SimpleCompilation(solutionSnapshot, this, assemblyReferences); } + protected virtual CSharpProjectContent Clone() + { + return new CSharpProjectContent(this); + } + public IProjectContent SetAssemblyName(string newAssemblyName) { - CSharpProjectContent pc = new CSharpProjectContent(this); + CSharpProjectContent pc = Clone(); pc.assemblyName = newAssemblyName; return pc; } public IProjectContent AddAssemblyReferences(IEnumerable references) { - CSharpProjectContent pc = new CSharpProjectContent(this); + CSharpProjectContent pc = Clone(); pc.assemblyReferences.AddRange(references); return pc; } public IProjectContent RemoveAssemblyReferences(IEnumerable references) { - CSharpProjectContent pc = new CSharpProjectContent(this); + CSharpProjectContent pc = Clone(); pc.assemblyReferences.RemoveAll(r => references.Contains(r)); return pc; } @@ -129,7 +134,7 @@ namespace ICSharpCode.NRefactory.CSharp if (!Platform.FileNameComparer.Equals(oldFile.FileName, newFile.FileName)) throw new ArgumentException("When both oldFile and newFile are specified, they must use the same file name."); } - CSharpProjectContent pc = new CSharpProjectContent(this); + CSharpProjectContent pc = Clone(); if (newFile == null) pc.parsedFiles.Remove(oldFile.FileName); else @@ -139,7 +144,7 @@ namespace ICSharpCode.NRefactory.CSharp public IProjectContent UpdateProjectContent(IEnumerable oldFiles, IEnumerable newFiles) { - CSharpProjectContent pc = new CSharpProjectContent(this); + CSharpProjectContent pc = Clone(); if (oldFiles != null) { foreach (var oldFile in oldFiles) { pc.parsedFiles.Remove(oldFile.FileName); diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/CSharpCompletionEngine.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/CSharpCompletionEngine.cs index 74fab83f42..8f1f98f00c 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/CSharpCompletionEngine.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/CSharpCompletionEngine.cs @@ -59,216 +59,306 @@ namespace ICSharpCode.NRefactory.CSharp.Completion public CSharpCompletionEngine (IDocument document, ICompletionDataFactory factory, IProjectContent content, CSharpTypeResolveContext ctx, CompilationUnit unit, CSharpParsedFile parsedFile) : base (content, ctx, unit, parsedFile) { - if (document == null) + if (document == null) { throw new ArgumentNullException ("document"); - if (factory == null) + } + if (factory == null) { throw new ArgumentNullException ("factory"); + } this.document = document; this.factory = factory; + // Set defaults for additional input properties + this.FormattingPolicy = FormattingOptionsFactory.CreateMono (); + this.EolMarker = Environment.NewLine; + this.IndentString = "\t"; + } + + public bool TryGetCompletionWord (int offset, out int startPos, out int wordLength) + { + startPos = wordLength = 0; + int pos = offset - 1; + while (pos >= 0) { + char c = document.GetCharAt (pos); + if (!char.IsLetterOrDigit (c) && c != '_') + break; + pos--; + } + if (pos == -1) + return false; + + pos++; + startPos = pos; + + while (pos < document.TextLength) { + char c = document.GetCharAt (pos); + if (!char.IsLetterOrDigit (c) && c != '_') + break; + pos++; + } + wordLength = pos - startPos; + return true; } - public IEnumerable GetCompletionData (int offset, bool controlSpace) + + + public IEnumerable GetCompletionData(int offset, bool controlSpace) { this.AutoCompleteEmptyMatch = true; this.AutoSelect = true; this.DefaultCompletionString = null; - SetOffset (offset); + SetOffset(offset); if (offset > 0) { - char lastChar = document.GetCharAt (offset - 1); - var result = MagicKeyCompletion (lastChar, controlSpace) ?? Enumerable.Empty (); - if (controlSpace && char.IsWhiteSpace (lastChar)) { + char lastChar = document.GetCharAt(offset - 1); + var result = MagicKeyCompletion(lastChar, controlSpace) ?? Enumerable.Empty(); + if (controlSpace && char.IsWhiteSpace(lastChar)) { offset -= 2; - while (offset >= 0 && char.IsWhiteSpace (document.GetCharAt (offset))) + while (offset >= 0 && char.IsWhiteSpace (document.GetCharAt (offset))) { offset--; + } if (offset > 0) { - var nonWsResult = MagicKeyCompletion (document.GetCharAt (offset), controlSpace); + var nonWsResult = MagicKeyCompletion(document.GetCharAt(offset), controlSpace); if (nonWsResult != null) { - var text = new HashSet (result.Select (r => r.CompletionText)); - result = result.Concat (nonWsResult.Where (r => !text.Contains (r.CompletionText))); + var text = new HashSet (result.Select(r => r.CompletionText)); + result = result.Concat(nonWsResult.Where(r => !text.Contains(r.CompletionText))); } } } return result; } - return Enumerable.Empty (); + return Enumerable.Empty(); } - IEnumerable GenerateNameProposals (AstType type) + IEnumerable GenerateNameProposals(AstType type) { if (type is PrimitiveType) { var pt = (PrimitiveType)type; switch (pt.Keyword) { - case "object": - yield return "o"; - yield return "obj"; - break; - case "bool": - yield return "b"; - yield return "pred"; - break; - case "double": - case "float": - case "decimal": - yield return "d"; - yield return "f"; - yield return "m"; - break; - default: - yield return "i"; - yield return "j"; - yield return "k"; - break; + case "object": + yield return "o"; + yield return "obj"; + break; + case "bool": + yield return "b"; + yield return "pred"; + break; + case "double": + case "float": + case "decimal": + yield return "d"; + yield return "f"; + yield return "m"; + break; + default: + yield return "i"; + yield return "j"; + yield return "k"; + break; } yield break; } - - var names = new List (); - int offset1 = document.GetOffset (type.StartLocation); - int offset2 = document.GetOffset (type.EndLocation); - - string name = document.GetText (offset1, offset2 - offset1); - int lastNameStart = 0; - for (int i = 1; i < name.Length; i++) { - if (Char.IsUpper (name [i])) { - names.Add (name.Substring (lastNameStart, i - lastNameStart)); - lastNameStart = i; - } + string name; + if (type is SimpleType) { + name = ((SimpleType)type).Identifier; + } else if (type is MemberType) { + name = ((SimpleType)type).Identifier; + } else { + yield break; } - - names.Add (name.Substring (lastNameStart, name.Length - lastNameStart)); - - var possibleName = new StringBuilder (); + + var names = WordParser.BreakWords(name); + + var possibleName = new StringBuilder(); for (int i = 0; i < names.Count; i++) { possibleName.Length = 0; for (int j = i; j < names.Count; j++) { - if (string.IsNullOrEmpty (names [j])) + if (string.IsNullOrEmpty(names [j])) { continue; - if (j == i) - names [j] = Char.ToLower (names [j] [0]) + names [j].Substring (1); - possibleName.Append (names [j]); + } + if (j == i) { + names [j] = Char.ToLower(names [j] [0]) + names [j].Substring(1); + } + possibleName.Append(names [j]); } - yield return possibleName.ToString (); + yield return possibleName.ToString(); } } - IEnumerable MagicKeyCompletion (char completionChar, bool controlSpace) + IEnumerable HandleMemberReferenceCompletion(ExpressionResult expr) { - switch (completionChar) { - // Magic key completion - case ':': - case '.': - if (IsInsideCommentOrString ()) - return Enumerable.Empty (); - var expr = GetExpressionBeforeCursor (); - if (expr == null) + if (expr == null) + return null; + + // do not complete . (but ..) + if (expr.Node is PrimitiveExpression) { + var pexpr = (PrimitiveExpression)expr.Node; + if (!(pexpr.Value is string || pexpr.Value is char) && !pexpr.LiteralValue.Contains('.')) { return null; - // do not complete . (but ..) - if (expr.Item2 is PrimitiveExpression) { - var pexpr = (PrimitiveExpression)expr.Item2; - if (!(pexpr.Value is string || pexpr.Value is char) && !pexpr.LiteralValue.Contains ('.')) - return null; } - - - var resolveResult = ResolveExpression (expr.Item1, expr.Item2, expr.Item3); - - if (resolveResult == null) - return null; - if (expr.Item2 is AstType) - return CreateTypeAndNamespaceCompletionData (location, resolveResult.Item1, expr.Item2, resolveResult.Item2); - return CreateCompletionData (location, resolveResult.Item1, expr.Item2, resolveResult.Item2); - case '#': - if (IsInsideCommentOrString ()) - return null; - return GetDirectiveCompletionData (); + } -// XML doc completion - case '<': - if (IsInsideDocComment ()) - return GetXmlDocumentationCompletionData (); - if (controlSpace) - return DefaultControlSpaceItems (); + var resolveResult = ResolveExpression (expr); + if (resolveResult == null) { return null; - case '>': - if (!IsInsideDocComment ()) + } + if (expr.Node is AstType) { + return CreateTypeAndNamespaceCompletionData(location, resolveResult.Item1, expr.Node, resolveResult.Item2); + } + return CreateCompletionData(location, resolveResult.Item1, expr.Node, resolveResult.Item2); + } + + bool IsInPreprocessorDirective() + { + var text = GetMemberTextToCaret().Item1; + var miniLexer = new MiniLexer(text); + miniLexer.Parse(); + return miniLexer.IsInPreprocessorDirective; + } + + IEnumerable HandleObjectInitializer(CompilationUnit unit, AstNode n) + { + var p = n.Parent; + while (p != null && !(p is ObjectCreateExpression)) { + p = p.Parent; + } + if (p != null) { + var contextList = new CompletionDataWrapper(this); + var initializerResult = ResolveExpression(p, unit); + if (initializerResult != null && initializerResult.Item1.Type.Kind != TypeKind.Unknown) { + + foreach (var m in initializerResult.Item1.Type.GetMembers (m => m.IsPublic && (m.EntityType == EntityType.Property || m.EntityType == EntityType.Field))) { + contextList.AddMember(m); + } + var enumerableType = typeof(IEnumerable<>).ToTypeReference().Resolve(ctx); + // check if we may be in a collection initializer, or enumerable initializer + if (enumerableType.Kind == TypeKind.Unknown || !initializerResult.Item1.Type.GetDefinition().IsDerivedFrom(enumerableType.GetDefinition())) { + return contextList.Result; + } + } + } + return null; + } + + IEnumerable MagicKeyCompletion(char completionChar, bool controlSpace) + { + ExpressionResult expr; + Tuple resolveResult; + switch (completionChar) { + // Magic key completion + case ':': + case '.': + if (IsInsideCommentStringOrDirective()) { + return Enumerable.Empty(); + } + return HandleMemberReferenceCompletion(GetExpressionBeforeCursor()); + case '#': + if (!IsInPreprocessorDirective()) + return null; + return GetDirectiveCompletionData(); + // XML doc completion + case '<': + if (IsInsideDocComment()) { + return GetXmlDocumentationCompletionData(); + } + if (controlSpace) { + return DefaultControlSpaceItems(); + } return null; - string lineText = document.GetText (document.GetLineByNumber (location.Line)); - int startIndex = Math.Min (location.Column - 1, lineText.Length - 1); + case '>': + if (!IsInsideDocComment()) { + return null; + } + string lineText = document.GetText(document.GetLineByNumber(location.Line)); + int startIndex = Math.Min(location.Column - 1, lineText.Length - 1); - while (startIndex >= 0 && lineText [startIndex] != '<') { - --startIndex; - if (lineText [startIndex] == '/') { // already closed. - startIndex = -1; - break; + while (startIndex >= 0 && lineText [startIndex] != '<') { + --startIndex; + if (lineText [startIndex] == '/') { + // already closed. + startIndex = -1; + break; + } } - } - if (startIndex >= 0) { - int endIndex = startIndex; - while (endIndex <= location.Column && endIndex < lineText.Length && !Char.IsWhiteSpace (lineText [endIndex])) { - endIndex++; + if (startIndex >= 0) { + int endIndex = startIndex; + while (endIndex <= location.Column && endIndex < lineText.Length && !Char.IsWhiteSpace (lineText [endIndex])) { + endIndex++; + } + string tag = endIndex - startIndex - 1 > 0 ? lineText.Substring(startIndex + 1, endIndex - startIndex - 2) : null; + if (!string.IsNullOrEmpty(tag) && commentTags.IndexOf(tag) >= 0) { + document.Insert(offset, ""); + } } - string tag = endIndex - startIndex - 1 > 0 ? lineText.Substring (startIndex + 1, endIndex - startIndex - 2) : null; - if (!string.IsNullOrEmpty (tag) && commentTags.IndexOf (tag) >= 0) - document.Insert (offset, ""); - } - return null; + return null; // Parameter completion - case '(': - if (IsInsideCommentOrString ()) - return null; - var invoke = GetInvocationBeforeCursor (true); - if (invoke == null) - return null; - if (invoke.Item2 is TypeOfExpression) - return CreateTypeList (); - var invocationResult = ResolveExpression (invoke.Item1, invoke.Item2, invoke.Item3); - if (invocationResult == null) - return null; - var methodGroup = invocationResult.Item1 as MethodGroupResolveResult; - if (methodGroup != null) - return CreateParameterCompletion (methodGroup, invocationResult.Item2, invoke.Item2, 0, controlSpace); - - if (controlSpace) - return DefaultControlSpaceItems (invoke); + case '(': + if (IsInsideCommentStringOrDirective()) { + return null; + } + var invoke = GetInvocationBeforeCursor(true); + if (invoke == null) { + if (controlSpace) + return DefaultControlSpaceItems(invoke); + return null; + } + if (invoke.Node is TypeOfExpression) { + return CreateTypeList(); + } + var invocationResult = ResolveExpression(invoke); + if (invocationResult == null) { + return null; + } + var methodGroup = invocationResult.Item1 as MethodGroupResolveResult; + if (methodGroup != null) { + return CreateParameterCompletion(methodGroup, invocationResult.Item2, invoke.Node, invoke.Unit, 0, controlSpace); + } - return null; - case '=': - return controlSpace ? DefaultControlSpaceItems () : null; - case ',': - int cpos2; - if (!GetParameterCompletionCommandOffset (out cpos2)) + if (controlSpace) { + return DefaultControlSpaceItems(invoke); + } return null; + case '=': + return controlSpace ? DefaultControlSpaceItems() : null; + case ',': + int cpos2; + if (!GetParameterCompletionCommandOffset(out cpos2)) { + return null; + } // completionContext = CompletionWidget.CreateCodeCompletionContext (cpos2); // int currentParameter2 = MethodParameterDataProvider.GetCurrentParameterIndex (CompletionWidget, completionContext) - 1; // return CreateParameterCompletion (CreateResolver (), location, ExpressionContext.MethodBody, provider.Methods, currentParameter); - break; + break; // Completion on space: - case ' ': - if (IsInsideCommentOrString ()) - return null; - - int tokenIndex = offset; - string token = GetPreviousToken (ref tokenIndex, false); + case ' ': + int tokenIndex = offset; + string token = GetPreviousToken(ref tokenIndex, false); + if (IsInsideCommentStringOrDirective()) { + if (IsInPreprocessorDirective()) + return HandleKeywordCompletion(tokenIndex, token); + return null; + } // check propose name, for context (but only in control space context) //IType isAsType = null; - var isAsExpression = GetExpressionAt (offset); - if (controlSpace && isAsExpression != null && isAsExpression.Item2 is VariableDeclarationStatement && token != "new") { - var parent = isAsExpression.Item2 as VariableDeclarationStatement; - var proposeNameList = new CompletionDataWrapper (this); + var isAsExpression = GetExpressionAt(offset); + if (controlSpace && isAsExpression != null && isAsExpression.Node is VariableDeclarationStatement && token != "new") { + var parent = isAsExpression.Node as VariableDeclarationStatement; + var proposeNameList = new CompletionDataWrapper(this); + if (parent.Variables.Count != 1) + return DefaultControlSpaceItems(isAsExpression, controlSpace); + + foreach (var possibleName in GenerateNameProposals (parent.Type)) { + if (possibleName.Length > 0) { + proposeNameList.Result.Add(factory.CreateLiteralCompletionData(possibleName.ToString())); + } + } - foreach (var possibleName in GenerateNameProposals (parent.Type)) { - if (possibleName.Length > 0) - proposeNameList.Result.Add (factory.CreateLiteralCompletionData (possibleName.ToString ())); + AutoSelect = false; + AutoCompleteEmptyMatch = false; + return proposeNameList.Result; } - - AutoSelect = false; - AutoCompleteEmptyMatch = false; - return proposeNameList.Result; - } // int tokenIndex = offset; // string token = GetPreviousToken (ref tokenIndex, false); // if (result.ExpressionContext == ExpressionContext.ObjectInitializer) { @@ -278,51 +368,58 @@ namespace ICSharpCode.NRefactory.CSharp.Completion // if (objectInitializer != null && objectInitializer.ArrayDimensions == 0 && objectInitializer.PointerNestingLevel == 0 && (token == "{" || token == ",")) // return CreateCtrlSpaceCompletionData (completionContext, result); // } - if (token == "=") { - int j = tokenIndex; - string prevToken = GetPreviousToken (ref j, false); - if (prevToken == "=" || prevToken == "+" || prevToken == "-") { - token = prevToken + token; - tokenIndex = j; - } - } - switch (token) { - case "(": - case ",": - int cpos; - if (!GetParameterCompletionCommandOffset (out cpos)) - break; - int currentParameter = GetCurrentParameterIndex (cpos, 0) - 1; - if (currentParameter < 0) - return null; - invoke = GetInvocationBeforeCursor (token == "("); - if (invoke == null) - return null; - invocationResult = ResolveExpression (invoke.Item1, invoke.Item2, invoke.Item3); - if (invocationResult == null) - return null; - methodGroup = invocationResult.Item1 as MethodGroupResolveResult; - if (methodGroup != null) - return CreateParameterCompletion (methodGroup, invocationResult.Item2, invoke.Item2, currentParameter, controlSpace); - return null; - case "=": - case "==": - GetPreviousToken (ref tokenIndex, false); + if (token == "=") { + int j = tokenIndex; + string prevToken = GetPreviousToken(ref j, false); + if (prevToken == "=" || prevToken == "+" || prevToken == "-") { + token = prevToken + token; + tokenIndex = j; + } + } + switch (token) { + case "(": + case ",": + int cpos; + if (!GetParameterCompletionCommandOffset(out cpos)) { + break; + } + int currentParameter = GetCurrentParameterIndex(cpos, 0) - 1; + if (currentParameter < 0) { + return null; + } + invoke = GetInvocationBeforeCursor(token == "("); + if (invoke == null) { + return null; + } + invocationResult = ResolveExpression(invoke); + if (invocationResult == null) { + return null; + } + methodGroup = invocationResult.Item1 as MethodGroupResolveResult; + if (methodGroup != null) { + return CreateParameterCompletion(methodGroup, invocationResult.Item2, invoke.Node, invoke.Unit, currentParameter, controlSpace); + } + return null; + case "=": + case "==": + GetPreviousToken(ref tokenIndex, false); + var expressionOrVariableDeclaration = GetExpressionAt(tokenIndex); + if (expressionOrVariableDeclaration == null) { + return null; + } - var expressionOrVariableDeclaration = GetExpressionAt (tokenIndex); - if (expressionOrVariableDeclaration == null) - return null; + resolveResult = ResolveExpression(expressionOrVariableDeclaration); - resolveResult = ResolveExpression (expressionOrVariableDeclaration.Item1, expressionOrVariableDeclaration.Item2, expressionOrVariableDeclaration.Item3); - if (resolveResult == null) - return null; - if (resolveResult.Item1.Type.Kind == TypeKind.Enum) { - var wrapper = new CompletionDataWrapper (this); - AddContextCompletion (wrapper, resolveResult.Item2, expressionOrVariableDeclaration.Item2); - AddEnumMembers (wrapper, resolveResult.Item1.Type, resolveResult.Item2); - AutoCompleteEmptyMatch = false; - return wrapper.Result; - } + if (resolveResult == null) { + return null; + } + if (resolveResult.Item1.Type.Kind == TypeKind.Enum) { + var wrapper = new CompletionDataWrapper(this); + AddContextCompletion(wrapper, resolveResult.Item2, expressionOrVariableDeclaration.Node, expressionOrVariableDeclaration.Unit); + AddEnumMembers(wrapper, resolveResult.Item1.Type, resolveResult.Item2); + AutoCompleteEmptyMatch = false; + return wrapper.Result; + } // // if (resolvedType.FullName == DomReturnType.Bool.FullName) { // CompletionDataList completionList = new ProjectDomCompletionDataList (); @@ -347,231 +444,360 @@ namespace ICSharpCode.NRefactory.CSharp.Completion // } // return completionList; // } - return null; - case "+=": - case "-=": - GetPreviousToken (ref tokenIndex, false); + return null; + case "+=": + case "-=": + GetPreviousToken(ref tokenIndex, false); - expressionOrVariableDeclaration = GetExpressionAt (tokenIndex); - if (expressionOrVariableDeclaration == null) - return null; + expressionOrVariableDeclaration = GetExpressionAt(tokenIndex); + if (expressionOrVariableDeclaration == null) { + return null; + } - resolveResult = ResolveExpression (expressionOrVariableDeclaration.Item1, expressionOrVariableDeclaration.Item2, expressionOrVariableDeclaration.Item3); - if (resolveResult == null) - return null; + resolveResult = ResolveExpression(expressionOrVariableDeclaration); + if (resolveResult == null) { + return null; + } - var mrr = resolveResult.Item1 as MemberResolveResult; - if (mrr != null) { - var evt = mrr.Member as IEvent; - if (evt == null) - return null; - var delegateType = evt.ReturnType; - if (delegateType.Kind != TypeKind.Delegate) - return null; + var mrr = resolveResult.Item1 as MemberResolveResult; + if (mrr != null) { + var evt = mrr.Member as IEvent; + if (evt == null) { + return null; + } + var delegateType = evt.ReturnType; + if (delegateType.Kind != TypeKind.Delegate) { + return null; + } - var wrapper = new CompletionDataWrapper (this); - if (currentType != null) { -// bool includeProtected = DomType.IncludeProtected (dom, typeFromDatabase, resolver.CallingType); - foreach (var method in currentType.Methods) { - if (MatchDelegate (delegateType, method) /*&& method.IsAccessibleFrom (dom, resolver.CallingType, resolver.CallingMember, includeProtected) &&*/) { - wrapper.AddMember (method); -// data.SetText (data.CompletionText + ";"); + var wrapper = new CompletionDataWrapper(this); + if (currentType != null) { + // bool includeProtected = DomType.IncludeProtected (dom, typeFromDatabase, resolver.CallingType); + foreach (var method in currentType.Methods) { + if (MatchDelegate(delegateType, method) /*&& method.IsAccessibleFrom (dom, resolver.CallingType, resolver.CallingMember, includeProtected) &&*/) { + wrapper.AddMember(method); + // data.SetText (data.CompletionText + ";"); + } + } + } + if (token == "+=") { + string parameterDefinition = AddDelegateHandlers(wrapper, delegateType); + string varName = GetPreviousMemberReferenceExpression(tokenIndex); + wrapper.Result.Add(factory.CreateEventCreationCompletionData(varName, delegateType, evt, parameterDefinition, currentMember, currentType)); } - } - } - if (token == "+=") { - string parameterDefinition = AddDelegateHandlers (wrapper, delegateType); - string varName = GetPreviousMemberReferenceExpression (tokenIndex); - wrapper.Result.Add (factory.CreateEventCreationCompletionData (varName, delegateType, evt, parameterDefinition, currentMember, currentType)); - } - return wrapper.Result; + return wrapper.Result; + } + return null; + case ":": + if (currentMember == null) { + token = GetPreviousToken(ref tokenIndex, false); + token = GetPreviousToken(ref tokenIndex, false); + if (token == "enum") + return HandleEnumContext(); + var wrapper = new CompletionDataWrapper(this); + + AddTypesAndNamespaces(wrapper, GetState(), null, t => currentType != null && !currentType.ReflectionName.Equals(t.ReflectionName) ? t : null); + return wrapper.Result; + } + return null; } - return null; - case ":": - -/* Breaks constructor initializer case: - * if (currentMember == null) { - var wrapper = new CompletionDataWrapper (this); - AddTypesAndNamespaces (wrapper, GetState (), null, t => currentType != null ? !currentType.Equals (t) : true); - return wrapper.Result; - }*/ - return null; - } - var keywordCompletion = HandleKeywordCompletion (tokenIndex, token); - if (keywordCompletion == null && controlSpace) - goto default; - return keywordCompletion; + var keywordCompletion = HandleKeywordCompletion(tokenIndex, token); + if (keywordCompletion == null && controlSpace) { + goto default; + } + return keywordCompletion; // Automatic completion - default: - if (IsInsideCommentOrString ()) - return null; - if (IsInLinqContext (offset)) { - tokenIndex = offset; - token = GetPreviousToken (ref tokenIndex, false); // token last typed - if (linqKeywords.Contains (token)) { - if (token == "from") // after from no auto code completion. + default: + if (IsInsideCommentStringOrDirective()) { + return null; + } + if (IsInLinqContext(offset)) { + if (!controlSpace && !(char.IsLetter(completionChar) || completionChar == '_')) { return null; - return DefaultControlSpaceItems (); + } + tokenIndex = offset; + token = GetPreviousToken(ref tokenIndex, false); + // token last typed + if (!char.IsWhiteSpace(completionChar) && !linqKeywords.Contains(token)) { + token = GetPreviousToken(ref tokenIndex, false); + } + // token last typed + + if (linqKeywords.Contains(token)) { + if (token == "from") { + // after from no auto code completion. + return null; + } + return DefaultControlSpaceItems(); + } + var dataList = new CompletionDataWrapper(this); + AddKeywords(dataList, linqKeywords); + return dataList.Result; } - var dataList = new CompletionDataWrapper (this); - AddKeywords (dataList, linqKeywords); - return dataList.Result; - } - - if (currentType != null && currentType.Kind == TypeKind.Enum) - return HandleEnumContext (); - - var contextList = new CompletionDataWrapper (this); - var identifierStart = GetExpressionAtCursor (); - - if (identifierStart != null && identifierStart.Item2 is TypeParameterDeclaration) - return null; - - if (identifierStart != null && identifierStart.Item2 is VariableInitializer && location <= ((VariableInitializer)identifierStart.Item2).NameToken.EndLocation) { - return controlSpace ? HandleAccessorContext () ?? DefaultControlSpaceItems (identifierStart) : null; - } - if (!(char.IsLetter (completionChar) || completionChar == '_') && (!controlSpace || identifierStart == null || !(identifierStart.Item2 is ArrayInitializerExpression))) { - return controlSpace ? HandleAccessorContext () ?? DefaultControlSpaceItems (identifierStart) : null; - } - - char prevCh = offset > 2 ? document.GetCharAt (offset - 2) : ';'; - char nextCh = offset < document.TextLength ? document.GetCharAt (offset) : ' '; - const string allowedChars = ";,[](){}+-*/%^?:&|~!<>="; - if (!Char.IsWhiteSpace (nextCh) && allowedChars.IndexOf (nextCh) < 0) - return null; - if (!(Char.IsWhiteSpace (prevCh) || allowedChars.IndexOf (prevCh) >= 0)) - return null; - - // Do not pop up completion on identifier identifier (should be handled by keyword completion). - tokenIndex = offset - 1; - token = GetPreviousToken (ref tokenIndex, false); - if (token == "class" || token == "namespace") // after these always follows a name - return null; - int prevTokenIndex = tokenIndex; - var prevToken2 = GetPreviousToken (ref prevTokenIndex, false); - if (identifierStart == null && !string.IsNullOrEmpty (token) && !(IsInsideComment (tokenIndex) || IsInsideString (tokenIndex)) && (prevToken2 == ";" || prevToken2 == "{" || prevToken2 == "}")) { - char last = token [token.Length - 1]; - if (char.IsLetterOrDigit (last) || last == '_' || token == ">") { - return HandleKeywordCompletion (tokenIndex, token); + if (currentType != null && currentType.Kind == TypeKind.Enum) { + return HandleEnumContext(); } - } - if (identifierStart == null) { - var accCtx = HandleAccessorContext (); - if (accCtx != null) - return accCtx; - return DefaultControlSpaceItems (null, controlSpace); - } - CSharpResolver csResolver; - AstNode n = identifierStart.Item2; - // Handle foreach (type name _ - if (n is IdentifierExpression) { - var prev = n.GetPrevNode () as ForeachStatement; - if (prev != null && prev.InExpression.IsNull) { - if (controlSpace) { - contextList.AddCustom ("in"); - return contextList.Result; + var contextList = new CompletionDataWrapper(this); + var identifierStart = GetExpressionAtCursor(); + if (identifierStart != null) { + if (identifierStart.Node is TypeParameterDeclaration) { + return null; + } + + if (identifierStart.Node is MemberReferenceExpression) { + return HandleMemberReferenceCompletion(new ExpressionResult(((MemberReferenceExpression)identifierStart.Node).Target, identifierStart.Unit)); + } + + if (identifierStart.Node is Identifier) { + // May happen in variable names + return controlSpace ? DefaultControlSpaceItems(identifierStart) : null; + } + + if (identifierStart.Node is VariableInitializer && location <= ((VariableInitializer)identifierStart.Node).NameToken.EndLocation) { + return controlSpace ? HandleAccessorContext() ?? DefaultControlSpaceItems(identifierStart) : null; + } + + if (identifierStart.Node is CatchClause) { + if (((CatchClause)identifierStart.Node).VariableNameToken.Contains(location)) { + return null; + } + identifierStart = null; } + } + if (!(char.IsLetter(completionChar) || completionChar == '_') && (!controlSpace || identifierStart == null || !(identifierStart.Node.Parent is ArrayInitializerExpression))) { + return controlSpace ? HandleAccessorContext() ?? DefaultControlSpaceItems(identifierStart) : null; + } + + char prevCh = offset > 2 ? document.GetCharAt(offset - 2) : ';'; + char nextCh = offset < document.TextLength ? document.GetCharAt(offset) : ' '; + const string allowedChars = ";,.[](){}+-*/%^?:&|~!<>="; + if (!Char.IsWhiteSpace(nextCh) && allowedChars.IndexOf(nextCh) < 0) { return null; } - } - if (n != null && n.Parent is InvocationExpression) { - var invokeResult = ResolveExpression (identifierStart.Item1, ((InvocationExpression)n.Parent).Target, identifierStart.Item3); - var mgr = invokeResult != null ? invokeResult.Item1 as MethodGroupResolveResult : null; - if (mgr != null) { - foreach (var method in mgr.Methods) { - foreach (var p in method.Parameters) { - contextList.AddVariable (p); + if (!(Char.IsWhiteSpace(prevCh) || allowedChars.IndexOf(prevCh) >= 0)) { + return null; + } + + // Do not pop up completion on identifier identifier (should be handled by keyword completion). + tokenIndex = offset - 1; + token = GetPreviousToken(ref tokenIndex, false); + if (token == "class" || token == "interface" || token == "struct" || token == "enum" || token == "namespace") { + // after these always follows a name + return null; + } + var keywordresult = HandleKeywordCompletion(tokenIndex, token); + if (keywordresult != null) { + return keywordresult; + } + + int prevTokenIndex = tokenIndex; + var prevToken2 = GetPreviousToken(ref prevTokenIndex, false); + if (prevToken2 == "delegate") { + // after these always follows a name + return null; + } + + if (identifierStart == null && !string.IsNullOrEmpty(token) && !IsInsideCommentStringOrDirective() && (prevToken2 == ";" || prevToken2 == "{" || prevToken2 == "}")) { + char last = token [token.Length - 1]; + if (char.IsLetterOrDigit(last) || last == '_' || token == ">") { + return HandleKeywordCompletion(tokenIndex, token); + } + } + + if (identifierStart == null) { + var accCtx = HandleAccessorContext(); + if (accCtx != null) { + return accCtx; + } + return DefaultControlSpaceItems(null, controlSpace); + } + CSharpResolver csResolver; + AstNode n = identifierStart.Node; + if (n != null && n.Parent is AnonymousTypeCreateExpression) { + AutoSelect = false; + } + + // Handle foreach (type name _ + if (n is IdentifierExpression) { + var prev = n.GetPrevNode() as ForeachStatement; + if (prev != null && prev.InExpression.IsNull) { + if (controlSpace) { + contextList.AddCustom("in"); + return contextList.Result; + } + return null; + } + } + + // Handle object/enumerable initialzer expressions: "new O () { P$" + if (n is IdentifierExpression && n.Parent is ArrayInitializerExpression) { + var result = HandleObjectInitializer(identifierStart.Unit, n); + if (result != null) + return result; + } + + if (n != null && n.Parent is InvocationExpression) { + var invokeParent = (InvocationExpression)n.Parent; + var invokeResult = ResolveExpression(invokeParent.Target, identifierStart.Unit); + var mgr = invokeResult != null ? invokeResult.Item1 as MethodGroupResolveResult : null; + if (mgr != null) { + int idx = 0; + foreach (var arg in invokeParent.Arguments) { + if (arg == n) { + break; + } + idx++; + } + + foreach (var method in mgr.Methods) { + if (idx < method.Parameters.Count && method.Parameters [idx].Type.Kind == TypeKind.Delegate) { + AutoSelect = false; + AutoCompleteEmptyMatch = false; + } + foreach (var p in method.Parameters) { + contextList.AddVariable(p); + } + } + idx++; + foreach (var list in mgr.GetExtensionMethods ()) { + foreach (var method in list) { + if (idx < method.Parameters.Count && method.Parameters [idx].Type.Kind == TypeKind.Delegate) { + AutoSelect = false; + AutoCompleteEmptyMatch = false; + } + + } + } + } + } + + if (n != null && n.Parent is ObjectCreateExpression) { + var invokeResult = ResolveExpression(n.Parent, identifierStart.Unit); + var mgr = invokeResult != null ? invokeResult.Item1 as ResolveResult : null; + if (mgr != null) { + foreach (var constructor in mgr.Type.GetConstructors ()) { + foreach (var p in constructor.Parameters) { + contextList.AddVariable(p); + } } } } - } - - if (n != null && n.Parent is ObjectCreateExpression) { - var invokeResult = ResolveExpression (identifierStart.Item1, n.Parent, identifierStart.Item3); - var mgr = invokeResult != null ? invokeResult.Item1 as ResolveResult : null; - if (mgr != null) { - foreach (var constructor in mgr.Type.GetConstructors ()) { - foreach (var p in constructor.Parameters) { - contextList.AddVariable (p); + if (n is IdentifierExpression) { + var bop = n.Parent as BinaryOperatorExpression; + Expression evaluationExpr = null; + + if (bop != null && bop.Right == n && (bop.Operator == BinaryOperatorType.Equality || bop.Operator == BinaryOperatorType.InEquality)) { + evaluationExpr = bop.Left; + } + // check for compare to enum case + if (evaluationExpr != null) { + resolveResult = ResolveExpression(evaluationExpr, identifierStart.Unit); + if (resolveResult != null && resolveResult.Item1.Type.Kind == TypeKind.Enum) { + var wrapper = new CompletionDataWrapper(this); + AddContextCompletion(wrapper, resolveResult.Item2, evaluationExpr, identifierStart.Unit); + AddEnumMembers(wrapper, resolveResult.Item1.Type, resolveResult.Item2); + AutoCompleteEmptyMatch = false; + return wrapper.Result; } } } - } - if (n is Identifier && n.Parent is ForeachStatement) { - if (controlSpace) - return DefaultControlSpaceItems (); - return null; - } - if (n is ArrayInitializerExpression) { - // check for new [] {...} expression -> no need to resolve the type there - var parent = n.Parent as ArrayCreateExpression; - if (parent != null && parent.Type.IsNull) - return DefaultControlSpaceItems (); + if (n is Identifier && n.Parent is ForeachStatement) { + if (controlSpace) { + return DefaultControlSpaceItems(); + } + return null; + } + if (n is ArrayInitializerExpression) { + // check for new [] {...} expression -> no need to resolve the type there + var parent = n.Parent as ArrayCreateExpression; + if (parent != null && parent.Type.IsNull) { + return DefaultControlSpaceItems(); + } - var initalizerResult = ResolveExpression (identifierStart.Item1, n.Parent, identifierStart.Item3); + var initalizerResult = ResolveExpression(n.Parent, identifierStart.Unit); - var concreteNode = identifierStart.Item3.GetNodeAt (location); - // check if we're on the right side of an initializer expression - if (concreteNode != null && concreteNode.Parent != null && concreteNode.Parent.Parent != null && concreteNode.Identifier != "a" && concreteNode.Parent.Parent is NamedExpression) { - return DefaultControlSpaceItems (); - } + var concreteNode = identifierStart.Unit.GetNodeAt(location); + // check if we're on the right side of an initializer expression + if (concreteNode != null && concreteNode.Parent != null && concreteNode.Parent.Parent != null && concreteNode.Identifier != "a" && concreteNode.Parent.Parent is NamedExpression) { + return DefaultControlSpaceItems(); + } - if (initalizerResult != null && initalizerResult.Item1.Type.Kind != TypeKind.Unknown) { - - foreach (var property in initalizerResult.Item1.Type.GetProperties ()) { - if (!property.IsPublic) - continue; - contextList.AddMember (property); + if (initalizerResult != null && initalizerResult.Item1.Type.Kind != TypeKind.Unknown) { + + foreach (var property in initalizerResult.Item1.Type.GetProperties ()) { + if (!property.IsPublic) { + continue; + } + contextList.AddMember(property); + } + foreach (var field in initalizerResult.Item1.Type.GetFields ()) { + if (!field.IsPublic) { + continue; + } + contextList.AddMember(field); + } + return contextList.Result; } - foreach (var field in initalizerResult.Item1.Type.GetFields ()) { - if (!field.IsPublic) - continue; - contextList.AddMember (field); + return DefaultControlSpaceItems(); + } + if (IsAttributeContext(n)) { + // add attribute targets + if (currentType == null) { + contextList.AddCustom("assembly"); + contextList.AddCustom("module"); + contextList.AddCustom("type"); + } else { + contextList.AddCustom("param"); + contextList.AddCustom("field"); + contextList.AddCustom("property"); + contextList.AddCustom("method"); + contextList.AddCustom("event"); } - return contextList.Result; + contextList.AddCustom("return"); } - return DefaultControlSpaceItems (); - } - if (n != null/* && !(identifierStart.Item2 is TypeDeclaration)*/) { - csResolver = new CSharpResolver (ctx); - var nodes = new List (); - nodes.Add (n); - if (n.Parent is ICSharpCode.NRefactory.CSharp.Attribute) - nodes.Add (n.Parent); - var navigator = new NodeListResolveVisitorNavigator (nodes); - var visitor = new ResolveVisitor (csResolver, identifierStart.Item1, navigator); - visitor.Scan (identifierStart.Item3); - try { - csResolver = visitor.GetResolverStateBefore (n); - } catch (Exception) { - csResolver = GetState (); - } - // add attribute properties. - if (n.Parent is ICSharpCode.NRefactory.CSharp.Attribute) { - var resolved = visitor.GetResolveResult (n.Parent); - if (resolved != null && resolved.Type != null) { - foreach (var property in resolved.Type.GetProperties (p => p.Accessibility == Accessibility.Public)) { - contextList.AddMember (property); - } - foreach (var field in resolved.Type.GetFields (p => p.Accessibility == Accessibility.Public)) { - contextList.AddMember (field); + if (n is MemberType) { + resolveResult = ResolveExpression(((MemberType)n).Target, identifierStart.Unit); + return CreateTypeAndNamespaceCompletionData(location, resolveResult.Item1, ((MemberType)n).Target, resolveResult.Item2); + } + if (n != null/* && !(identifierStart.Item2 is TypeDeclaration)*/) { + csResolver = new CSharpResolver (ctx); + var nodes = new List (); + nodes.Add(n); + if (n.Parent is ICSharpCode.NRefactory.CSharp.Attribute) { + nodes.Add(n.Parent); + } + var astResolver = new CSharpAstResolver (csResolver, identifierStart.Unit, CSharpParsedFile); + astResolver.ApplyNavigator(new NodeListResolveVisitorNavigator (nodes)); + try { + csResolver = astResolver.GetResolverStateBefore(n); + } catch (Exception) { + csResolver = GetState(); + } + // add attribute properties. + if (n.Parent is ICSharpCode.NRefactory.CSharp.Attribute) { + var resolved = astResolver.Resolve(n.Parent); + if (resolved != null && resolved.Type != null) { + foreach (var property in resolved.Type.GetProperties (p => p.Accessibility == Accessibility.Public)) { + contextList.AddMember(property); + } + foreach (var field in resolved.Type.GetFields (p => p.Accessibility == Accessibility.Public)) { + contextList.AddMember(field); + } } } + } else { + csResolver = GetState(); } - } else { - csResolver = GetState (); - } - // identifier has already started with the first letter - offset--; - AddContextCompletion (contextList, csResolver, identifierStart.Item2); - return contextList.Result; + offset--; + AddContextCompletion(contextList, csResolver, identifierStart.Node, identifierStart.Unit); + return contextList.Result; // if (stub.Parent is BlockStatement) // result = FindExpression (dom, completionContext, -1); @@ -640,44 +866,62 @@ namespace ICSharpCode.NRefactory.CSharp.Completion } return null; } - - IEnumerable HandleEnumContext () + + string[] validEnumBaseTypes = { "byte", "sbyte", "short", "int", "long", "ushort", "uint", "ulong" }; + IEnumerable HandleEnumContext() { - var cu = ParseStub ("a", false); - if (cu == null) + var cu = ParseStub("a", false); + if (cu == null) { return null; - var member = cu.GetNodeAt (location); - if (member != null && member.NameToken.EndLocation < location) - return DefaultControlSpaceItems (); + } + + var curType = cu.GetNodeAt (location); + if (curType == null || curType.ClassType != ClassType.Enum) { + cu = ParseStub("a {}", false); + var node = cu.GetNodeAt(location); + if (node != null) { + var wrapper = new CompletionDataWrapper(this); + AddKeywords(wrapper, validEnumBaseTypes); + return wrapper.Result; + } + } + + var member = cu.GetNodeAt(location); + if (member != null && member.NameToken.EndLocation < location) { + return DefaultControlSpaceItems(); + } return null; } - bool IsInLinqContext (int offset) + bool IsInLinqContext(int offset) { string token; - while (null != (token = GetPreviousToken (ref offset, true)) && !IsInsideComment (offset) && !IsInsideString (offset)) { - if (token == "from") + while (null != (token = GetPreviousToken (ref offset, true)) && !IsInsideCommentStringOrDirective ()) { + if (token == "from") { return true; - if (token == ";") + } + if (token == ";" || token == "{") { return false; + } } return false; } - IEnumerable HandleAccessorContext () + IEnumerable HandleAccessorContext() { - var unit = ParseStub ("get; }", false); - var node = unit.GetNodeAt (location, cn => !(cn is CSharpTokenNode)); - if (node is Accessor) + var unit = ParseStub("get; }", false); + var node = unit.GetNodeAt(location, cn => !(cn is CSharpTokenNode)); + if (node is Accessor) { node = node.Parent; - var contextList = new CompletionDataWrapper (this); + } + var contextList = new CompletionDataWrapper(this); if (node is PropertyDeclaration) { - contextList.AddCustom ("get"); - contextList.AddCustom ("set"); - AddKeywords (contextList, accessorModifierKeywords); + contextList.AddCustom("get"); + contextList.AddCustom("set"); + AddKeywords(contextList, accessorModifierKeywords); } else if (node is CustomEventDeclaration) { - contextList.AddCustom ("add"); - contextList.AddCustom ("remove"); + contextList.AddCustom("add"); + contextList.AddCustom("remove"); } else { return null; } @@ -685,48 +929,57 @@ namespace ICSharpCode.NRefactory.CSharp.Completion return contextList.Result; } - IEnumerable DefaultControlSpaceItems (Tuple xp = null, bool controlSpace = true) + IEnumerable DefaultControlSpaceItems(ExpressionResult xp = null, bool controlSpace = true) { - var wrapper = new CompletionDataWrapper (this); - if (offset >= document.TextLength) + var wrapper = new CompletionDataWrapper(this); + if (offset >= document.TextLength) { offset = document.TextLength - 1; + } while (offset > 1 && char.IsWhiteSpace (document.GetCharAt (offset))) { offset--; } - location = document.GetLocation (offset); - if (xp == null) - xp = GetExpressionAtCursor (); + location = document.GetLocation(offset); + + if (xp == null) { + xp = GetExpressionAtCursor(); + } AstNode node; + CompilationUnit unit; Tuple rr; if (xp != null) { - node = xp.Item2; - rr = ResolveExpression (xp.Item1, node, xp.Item3); + node = xp.Node; + rr = ResolveExpression(node, xp.Unit); + unit = xp.Unit; } else { - var unit = ParseStub ("a"); - node = unit.GetNodeAt (location); - rr = ResolveExpression (CSharpParsedFile, node, unit); + unit = ParseStub("a", false); + node = unit.GetNodeAt(location); + rr = ResolveExpression(node, unit); } + if (node is Identifier && node.Parent is ForeachStatement) { var foreachStmt = (ForeachStatement)node.Parent; foreach (var possibleName in GenerateNameProposals (foreachStmt.VariableType)) { - if (possibleName.Length > 0) - wrapper.Result.Add (factory.CreateLiteralCompletionData (possibleName.ToString ())); + if (possibleName.Length > 0) { + wrapper.Result.Add(factory.CreateLiteralCompletionData(possibleName.ToString())); + } } AutoSelect = false; AutoCompleteEmptyMatch = false; return wrapper.Result; } - + if (node is Identifier && node.Parent is ParameterDeclaration) { - if (!controlSpace) + if (!controlSpace) { return null; + } // Try Parameter name case var param = node.Parent as ParameterDeclaration; if (param != null) { foreach (var possibleName in GenerateNameProposals (param.Type)) { - if (possibleName.Length > 0) - wrapper.Result.Add (factory.CreateLiteralCompletionData (possibleName.ToString ())); + if (possibleName.Length > 0) { + wrapper.Result.Add(factory.CreateLiteralCompletionData(possibleName.ToString())); + } } AutoSelect = false; AutoCompleteEmptyMatch = false; @@ -734,199 +987,254 @@ namespace ICSharpCode.NRefactory.CSharp.Completion } } if (Unit != null && (node == null || node is TypeDeclaration)) { - var constructor = Unit.GetNodeAt (location.Line, location.Column - 3); + var constructor = Unit.GetNodeAt(location.Line, location.Column - 3); if (constructor != null && !constructor.ColonToken.IsNull && constructor.Initializer.IsNull) { - wrapper.AddCustom ("this"); - wrapper.AddCustom ("base"); + wrapper.AddCustom("this"); + wrapper.AddCustom("base"); return wrapper.Result; } } - CSharpResolver csResolver; - if (node != null) { - var nodes = new List (); - var n = node; - nodes.Add (n); - if (n.Parent is ICSharpCode.NRefactory.CSharp.Attribute) - nodes.Add (n.Parent); - var navigator = new NodeListResolveVisitorNavigator (nodes); - - var visitor = new ResolveVisitor (GetState (), xp != null ? xp.Item1 : CSharpParsedFile, navigator); - visitor.Scan (node); - try { - csResolver = visitor.GetResolverStateBefore (node); - } catch (Exception) { - csResolver = GetState (); + + var initializer = node != null ? node.Parent as ArrayInitializerExpression : null; + if (initializer != null) { + var result = HandleObjectInitializer(unit, initializer); + if (result != null) + return result; + } + CSharpResolver csResolver = null; + if (rr != null) { + csResolver = rr.Item2; + } + if (csResolver == null) { + if (node != null) { + csResolver = GetState(); + //var astResolver = new CSharpAstResolver (csResolver, node, xp != null ? xp.Item1 : CSharpParsedFile); + + try { + //csResolver = astResolver.GetResolverStateBefore (node); + Console.WriteLine(csResolver.LocalVariables.Count()); + } catch (Exception e) { + Console.WriteLine("E!!!" + e); + } + + } else { + csResolver = GetState(); } - - } else { - csResolver = GetState (); } - AddContextCompletion (wrapper, csResolver, node); + AddContextCompletion(wrapper, csResolver, node, unit); return wrapper.Result; } - void AddContextCompletion (CompletionDataWrapper wrapper, CSharpResolver state, AstNode node) + void AddContextCompletion(CompletionDataWrapper wrapper, CSharpResolver state, AstNode node, CompilationUnit unit) { - if (state != null) { + if (state != null && !(node is AstType)) { foreach (var variable in state.LocalVariables) { - wrapper.AddVariable (variable); + if (variable.Region.IsInside(location.Line, location.Column - 1)) { + continue; + } + wrapper.AddVariable(variable); } } - if (currentMember is IUnresolvedParameterizedMember) { - var param = (IParameterizedMember)currentMember.CreateResolved (ctx); + if (currentMember is IUnresolvedParameterizedMember && !(node is AstType)) { + var param = (IParameterizedMember)currentMember.CreateResolved(ctx); foreach (var p in param.Parameters) { - wrapper.AddVariable (p); + wrapper.AddVariable(p); } } if (currentMember is IUnresolvedMethod) { var method = (IUnresolvedMethod)currentMember; foreach (var p in method.TypeParameters) { - wrapper.AddTypeParameter (p); + wrapper.AddTypeParameter(p); } } - Predicate typePred = null; - if (node is Attribute) { - var attribute = Compilation.FindType (typeof(System.Attribute)); + Func typePred = null; + if (IsAttributeContext(node)) { + var attribute = Compilation.FindType(KnownTypeCode.Attribute); typePred = t => { - return t.GetAllBaseTypeDefinitions ().Any (bt => bt.Equals (attribute)); + return t.GetAllBaseTypeDefinitions().Any(bt => bt.Equals(attribute)) ? t : null; }; } - AddTypesAndNamespaces (wrapper, state, node, typePred); + AddTypesAndNamespaces(wrapper, state, node, typePred); - wrapper.Result.Add (factory.CreateLiteralCompletionData ("global")); - if (currentMember != null) { - AddKeywords (wrapper, statementStartKeywords); - AddKeywords (wrapper, expressionLevelKeywords); - } else if (currentType != null) { - AddKeywords (wrapper, typeLevelKeywords); - } else { - AddKeywords (wrapper, globalLevelKeywords); - } - var prop = currentMember as IUnresolvedProperty; - if (prop != null && prop.Setter != null && prop.Setter.Region.IsInside (location)) - wrapper.AddCustom ("value"); - if (currentMember is IUnresolvedEvent) - wrapper.AddCustom ("value"); + wrapper.Result.Add(factory.CreateLiteralCompletionData("global")); - if (IsInSwitchContext (node)) { - wrapper.AddCustom ("case"); - wrapper.AddCustom ("default"); + if (!(node is AstType)) { + if (currentMember != null) { + AddKeywords(wrapper, statementStartKeywords); + AddKeywords(wrapper, expressionLevelKeywords); + } else if (currentType != null) { + AddKeywords(wrapper, typeLevelKeywords); + } else { + AddKeywords(wrapper, globalLevelKeywords); + } + var prop = currentMember as IUnresolvedProperty; + if (prop != null && prop.Setter != null && prop.Setter.Region.IsInside(location)) { + wrapper.AddCustom("value"); + } + if (currentMember is IUnresolvedEvent) { + wrapper.AddCustom("value"); + } + + if (IsInSwitchContext(node)) { + wrapper.AddCustom("case"); + } + } else { + if (((AstType)node).Parent is ParameterDeclaration) { + AddKeywords(wrapper, parameterTypePredecessorKeywords); + } } - AddKeywords (wrapper, primitiveTypesKeywords); - wrapper.Result.AddRange (factory.CreateCodeTemplateCompletionData ()); + AddKeywords(wrapper, primitiveTypesKeywords); + if (currentMember != null) { + wrapper.AddCustom("var"); + } + wrapper.Result.AddRange(factory.CreateCodeTemplateCompletionData()); - if (node != null && node.Role == AstNode.Roles.Argument) { - var resolved = ResolveExpression (CSharpParsedFile, node.Parent, Unit); + if (node != null && node.Role == Roles.Argument) { + var resolved = ResolveExpression(node.Parent, unit); var invokeResult = resolved != null ? resolved.Item1 as CSharpInvocationResolveResult : null; if (invokeResult != null) { int argNum = 0; - foreach (var arg in node.Parent.Children.Where (c => c.Role == AstNode.Roles.Argument)) { - if (arg == node) + foreach (var arg in node.Parent.Children.Where (c => c.Role == Roles.Argument)) { + if (arg == node) { break; + } argNum++; } var param = argNum < invokeResult.Member.Parameters.Count ? invokeResult.Member.Parameters [argNum] : null; if (param != null && param.Type.Kind == TypeKind.Enum) { - AddEnumMembers (wrapper, param.Type, state); + AddEnumMembers(wrapper, param.Type, state); } } } } - static bool IsInSwitchContext (AstNode node) + static bool IsInSwitchContext(AstNode node) { var n = node; - while (n != null && !(n is MemberDeclaration)) { - if (n is SwitchStatement) + while (n != null && !(n is EntityDeclaration)) { + if (n is SwitchStatement) { return true; - if (n is BlockStatement) + } + if (n is BlockStatement) { return false; + } n = n.Parent; } return false; } - void AddTypesAndNamespaces (CompletionDataWrapper wrapper, CSharpResolver state, AstNode node, Predicate typePred = null, Predicate memberPred = null) + void AddTypesAndNamespaces(CompletionDataWrapper wrapper, CSharpResolver state, AstNode node, Func typePred = null, Predicate memberPred = null) { - var currentMember = ctx.CurrentMember; if (currentType != null) { for (var ct = currentType; ct != null; ct = ct.DeclaringTypeDefinition) { foreach (var nestedType in ct.NestedTypes) { - if (typePred == null || typePred (nestedType.Resolve (ctx))) { - string name = nestedType.Name; - if (node is Attribute && name.EndsWith ("Attribute") && name.Length > "Attribute".Length) - name = name.Substring (0, name.Length - "Attribute".Length); - wrapper.AddType (nestedType, name); + string name = nestedType.Name; + if (IsAttributeContext(node) && name.EndsWith("Attribute") && name.Length > "Attribute".Length) + name = name.Substring(0, name.Length - "Attribute".Length); + + if (typePred == null) { + wrapper.AddType(nestedType, name); + continue; } + + wrapper.AddType(typePred(nestedType.Resolve(ctx)), name); + continue; } } - if (this.currentMember != null) { - var def = ctx.CurrentTypeDefinition ?? Compilation.MainAssembly.GetTypeDefinition (currentType); - foreach (var member in def.GetMembers ()) { - if (memberPred == null || memberPred (member)) - wrapper.AddMember (member); - } - var declaring = def.DeclaringTypeDefinition; - while (declaring != null) { - foreach (var member in declaring.GetMembers (m => m.IsStatic)) { - if (memberPred == null || memberPred (member)) - wrapper.AddMember (member); + if (this.currentMember != null && !(node is AstType)) { + var def = ctx.CurrentTypeDefinition ?? Compilation.MainAssembly.GetTypeDefinition(currentType); + if (def != null) { + foreach (var member in def.GetMembers ()) { + if (member is IMethod && ((IMethod)member).FullName == "System.Object.Finalize") { + continue; + } + if (member.EntityType == EntityType.Operator) { + continue; + } + if (member.IsExplicitInterfaceImplementation) { + continue; + } + if (memberPred == null || memberPred(member)) { + wrapper.AddMember(member); + } + } + var declaring = def.DeclaringTypeDefinition; + while (declaring != null) { + foreach (var member in declaring.GetMembers (m => m.IsStatic)) { + if (memberPred == null || memberPred(member)) { + wrapper.AddMember(member); + } + } + declaring = declaring.DeclaringTypeDefinition; } - declaring = declaring.DeclaringTypeDefinition; } } foreach (var p in currentType.TypeParameters) { - wrapper.AddTypeParameter (p); + wrapper.AddTypeParameter(p); } } + var scope = CSharpParsedFile.GetUsingScope(location).Resolve(Compilation); - for (var n = state.CurrentUsingScope; n != null; n = n.Parent) { + for (var n = scope; n != null; n = n.Parent) { foreach (var pair in n.UsingAliases) { - wrapper.AddNamespace (pair.Key); + wrapper.AddNamespace(pair.Key); } foreach (var u in n.Usings) { foreach (var type in u.Types) { - if (typePred == null || typePred (type)) { + IType addType = typePred != null ? typePred(type) : type; + if (addType != null) { string name = type.Name; - if (node is Attribute && name.EndsWith ("Attribute") && name.Length > "Attribute".Length) - name = name.Substring (0, name.Length - "Attribute".Length); - wrapper.AddType (type, name); + if (IsAttributeContext(node) && name.EndsWith("Attribute") && name.Length > "Attribute".Length) { + name = name.Substring(0, name.Length - "Attribute".Length); + } + wrapper.AddType(addType, name); } } } foreach (var type in n.Namespace.Types) { - if (typePred == null || typePred (type)) - wrapper.AddType (type, type.Name); + IType addType = typePred != null ? typePred(type) : type; + if (addType != null) { + wrapper.AddType(addType, addType.Name); + } } foreach (var curNs in n.Namespace.ChildNamespaces) { - wrapper.AddNamespace (curNs.Name); + wrapper.AddNamespace(curNs.Name); } } } - IEnumerable HandleKeywordCompletion (int wordStart, string word) + IEnumerable HandleKeywordCompletion(int wordStart, string word) { - if (IsInsideCommentOrString ()) + if (IsInsideCommentStringOrDirective()) { + if (IsInPreprocessorDirective()) { + if (word == "if" || word == "elif") { + if (wordStart > 0 && document.GetCharAt(wordStart - 1) == '#') { + return factory.CreatePreProcessorDefinesCompletionData(); + } + } + } return null; + } switch (word) { - case "using": - case "namespace": - if (currentType != null) - return null; - var wrapper = new CompletionDataWrapper (this); - AddTypesAndNamespaces (wrapper, GetState (), null, t => false); - return wrapper.Result; - case "case": - return CreateCaseCompletionData (location); + case "using": + case "namespace": + if (currentType != null) { + return null; + } + var wrapper = new CompletionDataWrapper(this); + AddTypesAndNamespaces(wrapper, GetState(), null, t => null); + return wrapper.Result; + case "case": + return CreateCaseCompletionData(location); // case ",": // case ":": // if (result.ExpressionContext == ExpressionContext.InheritableType) { @@ -986,26 +1294,29 @@ namespace ICSharpCode.NRefactory.CSharp.Completion // return completionList; // } // break; - case "is": - case "as": - if (currentType == null) - return null; - IType isAsType = null; - var isAsExpression = GetExpressionAt (wordStart); - if (isAsExpression != null) { - var parent = isAsExpression.Item2.Parent; - if (parent is VariableInitializer) - parent = parent.Parent; - if (parent is VariableDeclarationStatement) { - var resolved = ResolveExpression (isAsExpression.Item1, parent, isAsExpression.Item3); - if (resolved != null) - isAsType = resolved.Item1.Type; + case "is": + case "as": + if (currentType == null) { + return null; } - } - - var isAsWrapper = new CompletionDataWrapper (this); - AddTypesAndNamespaces (isAsWrapper, GetState (), null, t => isAsType == null || t.GetDefinition ().IsDerivedFrom (isAsType.GetDefinition ())); - return isAsWrapper.Result; + IType isAsType = null; + var isAsExpression = GetExpressionAt(wordStart); + if (isAsExpression != null) { + var parent = isAsExpression.Node.Parent; + if (parent is VariableInitializer) { + parent = parent.Parent; + } + if (parent is VariableDeclarationStatement) { + var resolved = ResolveExpression(parent, isAsExpression.Unit); + if (resolved != null) { + isAsType = resolved.Item1.Type; + } + } + } + var isAsWrapper = new CompletionDataWrapper(this); + var def = isAsType != null ? isAsType.GetDefinition() : null; + AddTypesAndNamespaces(isAsWrapper, GetState(), null, t => t.GetDefinition() == null || def == null || t.GetDefinition().IsDerivedFrom(def) ? t : null, m => false); + return isAsWrapper.Result; // { // CompletionDataList completionList = new ProjectDomCompletionDataList (); // ExpressionResult expressionResult = FindExpression (dom, completionContext, wordStart - document.Caret.Offset); @@ -1055,310 +1366,289 @@ namespace ICSharpCode.NRefactory.CSharp.Completion // result.ExpressionContext = ExpressionContext.TypeName; // return CreateCtrlSpaceCompletionData (completionContext, result); // } - case "override": + case "override": // Look for modifiers, in order to find the beginning of the declaration - int firstMod = wordStart; - int i = wordStart; - for (int n = 0; n < 3; n++) { - string mod = GetPreviousToken (ref i, true); - if (mod == "public" || mod == "protected" || mod == "private" || mod == "internal" || mod == "sealed") { - firstMod = i; - } else if (mod == "static") { - // static methods are not overridable + int firstMod = wordStart; + int i = wordStart; + for (int n = 0; n < 3; n++) { + string mod = GetPreviousToken(ref i, true); + if (mod == "public" || mod == "protected" || mod == "private" || mod == "internal" || mod == "sealed") { + firstMod = i; + } else if (mod == "static") { + // static methods are not overridable + return null; + } else { + break; + } + } + if (!IsLineEmptyUpToEol()) { return null; - } else - break; - } - if (!IsLineEmptyUpToEol ()) + } + if (currentType != null && (currentType.Kind == TypeKind.Class || currentType.Kind == TypeKind.Struct)) { + string modifiers = document.GetText(firstMod, wordStart - firstMod); + return GetOverrideCompletionData(currentType, modifiers); + } return null; - var overrideCls = CSharpParsedFile.GetInnermostTypeDefinition (location); - if (overrideCls != null && (overrideCls.Kind == TypeKind.Class || overrideCls.Kind == TypeKind.Struct)) { - string modifiers = document.GetText (firstMod, wordStart - firstMod); - return GetOverrideCompletionData (overrideCls, modifiers); - } - return null; - case "partial": + case "partial": // Look for modifiers, in order to find the beginning of the declaration - firstMod = wordStart; - i = wordStart; - for (int n = 0; n < 3; n++) { - string mod = GetPreviousToken (ref i, true); - if (mod == "public" || mod == "protected" || mod == "private" || mod == "internal" || mod == "sealed") { - firstMod = i; - } else if (mod == "static") { - // static methods are not overridable + firstMod = wordStart; + i = wordStart; + for (int n = 0; n < 3; n++) { + string mod = GetPreviousToken(ref i, true); + if (mod == "public" || mod == "protected" || mod == "private" || mod == "internal" || mod == "sealed") { + firstMod = i; + } else if (mod == "static") { + // static methods are not overridable + return null; + } else { + break; + } + } + if (!IsLineEmptyUpToEol()) { return null; - } else - break; - } - if (!IsLineEmptyUpToEol ()) - return null; + } + var state = GetState(); - overrideCls = CSharpParsedFile.GetInnermostTypeDefinition (location); - if (overrideCls != null && (overrideCls.Kind == TypeKind.Class || overrideCls.Kind == TypeKind.Struct)) { - string modifiers = document.GetText (firstMod, wordStart - firstMod); - return GetPartialCompletionData (overrideCls, modifiers); - } - return null; + if (state.CurrentTypeDefinition != null && (state.CurrentTypeDefinition.Kind == TypeKind.Class || state.CurrentTypeDefinition.Kind == TypeKind.Struct)) { + string modifiers = document.GetText(firstMod, wordStart - firstMod); + return GetPartialCompletionData(state.CurrentTypeDefinition, modifiers); + } + return null; - case "public": - case "protected": - case "private": - case "internal": - case "sealed": - case "static": - var accessorContext = HandleAccessorContext (); - if (accessorContext != null) - return accessorContext; - wrapper = new CompletionDataWrapper (this); - var state = GetState (); - AddTypesAndNamespaces (wrapper, state, null, null, m => false); - AddKeywords (wrapper, typeLevelKeywords); - AddKeywords (wrapper, primitiveTypesKeywords); - return wrapper.Result; - case "new": - int j = offset - 4; + case "public": + case "protected": + case "private": + case "internal": + case "sealed": + case "static": + var accessorContext = HandleAccessorContext(); + if (accessorContext != null) { + return accessorContext; + } + wrapper = new CompletionDataWrapper(this); + state = GetState(); + if (currentType != null) { + AddTypesAndNamespaces(wrapper, state, null, null, m => false); + AddKeywords(wrapper, primitiveTypesKeywords); + } + AddKeywords(wrapper, typeLevelKeywords); + return wrapper.Result; + case "new": + int j = offset - 4; // string token = GetPreviousToken (ref j, true); - IType hintType = null; - var expressionOrVariableDeclaration = GetNewExpressionAt (j); - AstNode newParentNode = null; - AstType hintTypeAst = null; - if (expressionOrVariableDeclaration != null) { - newParentNode = expressionOrVariableDeclaration.Item2.Parent; - if (newParentNode is VariableInitializer) - newParentNode = newParentNode.Parent; - } - if (newParentNode is InvocationExpression) { - var invoke = (InvocationExpression)newParentNode; - var resolved = ResolveExpression (expressionOrVariableDeclaration.Item1, invoke, expressionOrVariableDeclaration.Item3); - if (resolved != null) { - var mgr = resolved.Item1 as CSharpInvocationResolveResult; - if (mgr != null) { - int i1 = 0; - foreach (var a in invoke.Arguments) { - if (a == expressionOrVariableDeclaration.Item2) { - if (mgr.Member.Parameters.Count > i1) - hintType = mgr.Member.Parameters [i1].Type; - break; + IType hintType = null; + var expressionOrVariableDeclaration = GetNewExpressionAt(j); + AstNode newParentNode = null; + AstType hintTypeAst = null; + if (expressionOrVariableDeclaration != null) { + newParentNode = expressionOrVariableDeclaration.Node.Parent; + if (newParentNode is VariableInitializer) { + newParentNode = newParentNode.Parent; + } + } + if (newParentNode is InvocationExpression) { + var invoke = (InvocationExpression)newParentNode; + var resolved = ResolveExpression(invoke, expressionOrVariableDeclaration.Unit); + if (resolved != null) { + var mgr = resolved.Item1 as CSharpInvocationResolveResult; + if (mgr != null) { + int i1 = 0; + foreach (var a in invoke.Arguments) { + if (a == expressionOrVariableDeclaration.Node) { + if (mgr.Member.Parameters.Count > i1) { + hintType = mgr.Member.Parameters [i1].Type; + } + break; + } + i1++; } - i1++; } } } - } - if (newParentNode is ObjectCreateExpression) { - var invoke = (ObjectCreateExpression)newParentNode; - var resolved = ResolveExpression (expressionOrVariableDeclaration.Item1, invoke, expressionOrVariableDeclaration.Item3); - if (resolved != null) { - var mgr = resolved.Item1 as CSharpInvocationResolveResult; - if (mgr != null) { - int i1 = 0; - foreach (var a in invoke.Arguments) { - if (a == expressionOrVariableDeclaration.Item2) { - if (mgr.Member.Parameters.Count > i1) - hintType = mgr.Member.Parameters [i1].Type; - break; + if (newParentNode is ObjectCreateExpression) { + var invoke = (ObjectCreateExpression)newParentNode; + var resolved = ResolveExpression(invoke, expressionOrVariableDeclaration.Unit); + if (resolved != null) { + var mgr = resolved.Item1 as CSharpInvocationResolveResult; + if (mgr != null) { + int i1 = 0; + foreach (var a in invoke.Arguments) { + if (a == expressionOrVariableDeclaration.Node) { + if (mgr.Member.Parameters.Count > i1) { + hintType = mgr.Member.Parameters [i1].Type; + } + break; + } + i1++; } - i1++; } } } - } - - if (newParentNode is AssignmentExpression) { - var assign = (AssignmentExpression)newParentNode; - var resolved = ResolveExpression (expressionOrVariableDeclaration.Item1, assign.Left, expressionOrVariableDeclaration.Item3); - if (resolved != null) { - hintType = resolved.Item1.Type; + + if (newParentNode is AssignmentExpression) { + var assign = (AssignmentExpression)newParentNode; + var resolved = ResolveExpression(assign.Left, expressionOrVariableDeclaration.Unit); + if (resolved != null) { + hintType = resolved.Item1.Type; + } } - } - - if (newParentNode is VariableDeclarationStatement) { - var varDecl = (VariableDeclarationStatement)newParentNode; - hintTypeAst = varDecl.Type; - var resolved = ResolveExpression (expressionOrVariableDeclaration.Item1, varDecl.Type, expressionOrVariableDeclaration.Item3); - if (resolved != null) { - hintType = resolved.Item1.Type; + + if (newParentNode is VariableDeclarationStatement) { + var varDecl = (VariableDeclarationStatement)newParentNode; + hintTypeAst = varDecl.Type; + var resolved = ResolveExpression(varDecl.Type, expressionOrVariableDeclaration.Unit); + if (resolved != null) { + hintType = resolved.Item1.Type; + } } - } - - if (newParentNode is FieldDeclaration) { - var varDecl = (FieldDeclaration)newParentNode; - hintTypeAst = varDecl.ReturnType; - var resolved = ResolveExpression (expressionOrVariableDeclaration.Item1, varDecl.ReturnType, expressionOrVariableDeclaration.Item3); - if (resolved != null) - hintType = resolved.Item1.Type; - } - return CreateTypeCompletionData (hintType, hintTypeAst); -// IType callingType = NRefactoryResolver.GetTypeAtCursor (Document.CompilationUnit, Document.FileName, new TextLocation (document.Caret.Line, document.Caret.Column)); -// ExpressionContext newExactContext = new NewCSharpExpressionFinder (dom).FindExactContextForNewCompletion (document, Document.CompilationUnit, Document.FileName, callingType); -// if (newExactContext is ExpressionContext.TypeExpressionContext) -// return CreateTypeCompletionData (location, callingType, newExactContext, ((ExpressionContext.TypeExpressionContext)newExactContext).Type, ((ExpressionContext.TypeExpressionContext)newExactContext).UnresolvedType); -// if (newExactContext == null) { -// int j = offset - 4; -// -// string yieldToken = GetPreviousToken (ref j, true); -// if (token == "return") { -// NRefactoryResolver resolver = CreateResolver (); -// resolver.SetupResolver (new TextLocation (completionContext.TriggerLine, completionContext.TriggerLineOffset)); -// IReturnType returnType = resolver.CallingMember.ReturnType; -// if (yieldToken == "yield" && returnType.GenericArguments.Count > 0) -// returnType = returnType.GenericArguments [0]; -// if (resolver.CallingMember != null) -// return CreateTypeCompletionData (location, callingType, newExactContext, null, returnType); -// } -// } -// return CreateCtrlSpaceCompletionData (completionContext, null); - case "if": - case "elif": - if (wordStart > 0 && document.GetCharAt (wordStart - 1) == '#') - return factory.CreatePreProcessorDefinesCompletionData (); - return null; - case "yield": - var yieldDataList = new CompletionDataWrapper (this); - DefaultCompletionString = "return"; - yieldDataList.AddCustom ("break"); - yieldDataList.AddCustom ("return"); - return yieldDataList.Result; - case "in": - var inList = new CompletionDataWrapper (this); - var node = Unit.GetNodeAt (location); - var rr = ResolveExpression (CSharpParsedFile, node, Unit); - AddContextCompletion (inList, rr != null ? rr.Item2 : GetState (), node); - return inList.Result; -// case "where": -// CompletionDataList whereDataList = new CompletionDataList (); -// NRefactoryResolver constraintResolver = CreateResolver (); -// constraintResolver.SetupResolver (new TextLocation (completionContext.TriggerLine, completionContext.TriggerLineOffset)); -// if (constraintResolver.CallingMember is IMethod) { -// foreach (ITypeParameter tp in ((IMethod)constraintResolver.CallingMember).TypeParameters) { -// whereDataList.Add (tp.Name, "md-keyword"); -// } -// } else { -// if (constraintResolver.CallingType != null) { -// foreach (ITypeParameter tp in constraintResolver.CallingType.TypeParameters) { -// whereDataList.Add (tp.Name, "md-keyword"); -// } -// } -// } -// -// return whereDataList; + + if (newParentNode is FieldDeclaration) { + var varDecl = (FieldDeclaration)newParentNode; + hintTypeAst = varDecl.ReturnType; + var resolved = ResolveExpression(varDecl.ReturnType, expressionOrVariableDeclaration.Unit); + if (resolved != null) { + hintType = resolved.Item1.Type; + } + } + + if (newParentNode is ReturnStatement) { + //var varDecl = (ReturnStatement)newParentNode; + if (ctx.CurrentMember != null) { + hintType = ctx.CurrentMember.ReturnType; + } + } + + return CreateTypeCompletionData(hintType, hintTypeAst); + case "yield": + var yieldDataList = new CompletionDataWrapper(this); + DefaultCompletionString = "return"; + yieldDataList.AddCustom("break"); + yieldDataList.AddCustom("return"); + return yieldDataList.Result; + case "in": + var inList = new CompletionDataWrapper(this); + + var expr = GetExpressionAtCursor(); + var rr = ResolveExpression(expr); + + AddContextCompletion(inList, rr != null ? rr.Item2 : GetState(), expr.Node, Unit); + return inList.Result; } -// if (IsInLinqContext (result)) { -// if (linqKeywords.Contains (word)) { -// if (word == "from") // after from no auto code completion. -// return null; -// result.Expression = ""; -// return CreateCtrlSpaceCompletionData (completionContext, result); -// } -// CompletionDataList dataList = new ProjectDomCompletionDataList (); -// CompletionDataCollector col = new CompletionDataCollector (this, dom, dataList, Document.CompilationUnit, null, new TextLocation (completionContext.TriggerLine, completionContext.TriggerLineOffset)); -// foreach (string kw in linqKeywords) { -// col.Add (kw, "md-keyword"); -// } -// return dataList; -// } return null; } - bool IsLineEmptyUpToEol () + bool IsLineEmptyUpToEol() { - var line = document.GetLineByNumber (location.Line); + var line = document.GetLineByNumber(location.Line); for (int j = offset; j < line.EndOffset; j++) { - char ch = document.GetCharAt (j); - if (!char.IsWhiteSpace (ch)) + char ch = document.GetCharAt(j); + if (!char.IsWhiteSpace(ch)) { return false; + } } return true; } - string GetLineIndent (int lineNr) + string GetLineIndent(int lineNr) { - var line = document.GetLineByNumber (lineNr); + var line = document.GetLineByNumber(lineNr); for (int j = offset; j < line.EndOffset; j++) { - char ch = document.GetCharAt (j); - if (!char.IsWhiteSpace (ch)) - return document.GetText (line.Offset, j - line.Offset - 1); + char ch = document.GetCharAt(j); + if (!char.IsWhiteSpace(ch)) { + return document.GetText(line.Offset, j - line.Offset - 1); + } } return ""; } - - IEnumerable CreateTypeCompletionData (IType hintType, AstType hintTypeAst) + static CSharpAmbience amb = new CSharpAmbience (); + + IEnumerable CreateTypeCompletionData(IType hintType, AstType hintTypeAst) { - var wrapper = new CompletionDataWrapper (this); - var state = GetState (); - Predicate pred = null; + var wrapper = new CompletionDataWrapper(this); + var state = GetState(); + Func pred = null; if (hintType != null) { if (hintType.Kind != TypeKind.Unknown) { - var lookup = new MemberLookup (ctx.CurrentTypeDefinition, Compilation.MainAssembly); + var lookup = new MemberLookup(ctx.CurrentTypeDefinition, Compilation.MainAssembly); pred = t => { // check if type is in inheritance tree. - if (hintType.GetDefinition () != null && !t.GetDefinition ().IsDerivedFrom (hintType.GetDefinition ())) - return false; - + if (hintType.GetDefinition() != null && !t.GetDefinition().IsDerivedFrom(hintType.GetDefinition())) { + return null; + } + if (t.Kind == TypeKind.Interface && hintType.Kind != TypeKind.Array) { + return null; + } // check for valid constructors - if (t.GetConstructors ().Count () == 0) - return true; - bool isProtectedAllowed = currentType != null ? currentType.Resolve (ctx).GetDefinition ().IsDerivedFrom (t.GetDefinition ()) : false; - return t.GetConstructors ().Any (m => lookup.IsAccessible (m, isProtectedAllowed)); + if (t.GetConstructors().Count() > 0) { + bool isProtectedAllowed = currentType != null ? currentType.Resolve(ctx).GetDefinition().IsDerivedFrom(t.GetDefinition()) : false; + if (!t.GetConstructors().Any(m => lookup.IsAccessible(m, isProtectedAllowed))) + return null; + } + + var typeInference = new TypeInference(Compilation); + typeInference.Algorithm = TypeInferenceAlgorithm.ImprovedReturnAllResults; + var inferedType = typeInference.FindTypeInBounds(new [] { t }, new [] { hintType }); + wrapper.AddType(inferedType, amb.ConvertType(inferedType)); + return null; }; - DefaultCompletionString = GetShortType (hintType, GetState ()); - wrapper.AddType (hintType, DefaultCompletionString); + if (!(hintType.Kind == TypeKind.Interface && hintType.Kind != TypeKind.Array)) { + DefaultCompletionString = GetShortType(hintType, GetState()); + wrapper.AddType(hintType, DefaultCompletionString); + } + if (hintType is ParameterizedType && hintType.TypeParameterCount == 1 && hintType.FullName == "System.Collections.Generic.IEnumerable") { + var arg = ((ParameterizedType)hintType).TypeArguments.FirstOrDefault(); + var array = new ArrayTypeReference(arg.ToTypeReference(), 1).Resolve(ctx); + wrapper.AddType(array, amb.ConvertType(array)); + } } else { - DefaultCompletionString = hintTypeAst.ToString (); - wrapper.AddType (hintType, DefaultCompletionString); + DefaultCompletionString = hintTypeAst.ToString(); + wrapper.AddType(hintType, DefaultCompletionString); } } - AddTypesAndNamespaces (wrapper, state, null, pred, m => false); - AddKeywords (wrapper, primitiveTypesKeywords.Where (k => k != "void")); + AddTypesAndNamespaces(wrapper, state, null, pred, m => false); + if (hintType == null || hintType == SpecialType.UnknownType) + AddKeywords(wrapper, primitiveTypesKeywords.Where(k => k != "void")); CloseOnSquareBrackets = true; AutoCompleteEmptyMatch = true; return wrapper.Result; } - IEnumerable GetOverrideCompletionData (IUnresolvedTypeDefinition type, string modifiers) + IEnumerable GetOverrideCompletionData(IUnresolvedTypeDefinition type, string modifiers) { var wrapper = new CompletionDataWrapper (this); - var alreadyInserted = new Dictionary (); - bool addedVirtuals = false; + var alreadyInserted = new List (); + //bool addedVirtuals = false; int declarationBegin = offset; int j = declarationBegin; for (int i = 0; i < 3; i++) { - switch (GetPreviousToken (ref j, true)) { - case "public": - case "protected": - case "private": - case "internal": - case "sealed": - case "override": - declarationBegin = j; - break; - case "static": - return null; // don't add override completion for static members + switch (GetPreviousToken(ref j, true)) { + case "public": + case "protected": + case "private": + case "internal": + case "sealed": + case "override": + declarationBegin = j; + break; + case "static": + return null; // don't add override completion for static members } } - foreach (var baseType in type.Resolve (ctx).GetAllBaseTypeDefinitions ()) { - AddVirtuals (alreadyInserted, wrapper, type.Resolve (ctx).GetDefinition (), modifiers, baseType, declarationBegin); - addedVirtuals = true; - } - if (!addedVirtuals) - AddVirtuals (alreadyInserted, wrapper, type.Resolve (ctx).GetDefinition (), modifiers, Compilation.FindType (typeof(object)).GetDefinition (), declarationBegin); + AddVirtuals(alreadyInserted, wrapper, modifiers, type.Resolve(ctx), declarationBegin); return wrapper.Result; } - IEnumerable GetPartialCompletionData (IUnresolvedTypeDefinition type, string modifiers) + IEnumerable GetPartialCompletionData(ITypeDefinition type, string modifiers) { var wrapper = new CompletionDataWrapper (this); - var partialType = type.Resolve (ctx); - if (partialType != null) { - int declarationBegin = offset; - int j = declarationBegin; - for (int i = 0; i < 3; i++) { - switch (GetPreviousToken (ref j, true)) { + int declarationBegin = offset; + int j = declarationBegin; + for (int i = 0; i < 3; i++) { + switch (GetPreviousToken(ref j, true)) { case "public": case "protected": case "private": @@ -1369,121 +1659,107 @@ namespace ICSharpCode.NRefactory.CSharp.Completion break; case "static": return null; // don't add override completion for static members - } - } - - var methods = new List (); - // gather all partial methods without implementation -/* TODO: foreach (var method in partialType.GetMethods ()) { - if (method.IsPartial && method.BodyRegion.IsEmpty) { - methods.Add (method); - } } - - // now filter all methods that are implemented in the compound class - foreach (var part in partialType.GetParts ()) { - if (part == type) - continue; - for (int i = 0; i < methods.Count; i++) { - var curMethod = methods [i]; - var method = GetImplementation (partialType, curMethod); - if (method != null && !method.BodyRegion.IsEmpty) { - methods.RemoveAt (i); - i--; + } + + var methods = new List (); + + foreach (var part in type.Parts) { + foreach (var method in part.Methods) { + if (method.BodyRegion.IsEmpty) { + if (GetImplementation(type, method) != null) { continue; } + methods.Add(method); } - } - */ - - foreach (var method in methods) { - wrapper.Add (factory.CreateNewOverrideCompletionData (declarationBegin, type, method)); - } - + } } + + foreach (var method in methods) { + wrapper.Add(factory.CreateNewPartialCompletionData(declarationBegin, method.DeclaringTypeDefinition, method)); + } + return wrapper.Result; } - IMethod GetImplementation (ITypeDefinition type, IMethod method) + IMethod GetImplementation(ITypeDefinition type, IUnresolvedMethod method) { foreach (var cur in type.Methods) { if (cur.Name == method.Name && cur.Parameters.Count == method.Parameters.Count && !cur.BodyRegion.IsEmpty) { bool equal = true; - for (int i = 0; i < cur.Parameters.Count; i++) { + /*for (int i = 0; i < cur.Parameters.Count; i++) { if (!cur.Parameters [i].Type.Equals (method.Parameters [i].Type)) { equal = false; break; } - } - if (equal) + }*/ + if (equal) { return cur; + } } } return null; } - static string GetNameWithParamCount (IMember member) - { - var e = member as IMethod; - if (e == null || e.TypeParameters.Count == 0) - return member.Name; - return e.Name + "`" + e.TypeParameters.Count; - } - - void AddVirtuals (Dictionary alreadyInserted, CompletionDataWrapper col, ITypeDefinition type, string modifiers, ITypeDefinition curType, int declarationBegin) + void AddVirtuals(List alreadyInserted, CompletionDataWrapper col, string modifiers, IType curType, int declarationBegin) { - if (curType == null) + if (curType == null) { return; - foreach (var m in curType.Methods.Where (m => !m.IsConstructor && !m.IsDestructor).Cast ().Concat (curType.Properties.Cast ())) { - if (m.IsSynthetic || curType.Kind != TypeKind.Interface && !(m.IsVirtual || m.IsOverride || m.IsAbstract)) + } + foreach (var m in curType.GetMembers ().Reverse ()) { + if (m.IsSynthetic || curType.Kind != TypeKind.Interface && !m.IsOverridable) { continue; + } // filter out the "Finalize" methods, because finalizers should be done with destructors. - if (m is IMethod && m.Name == "Finalize") + if (m is IMethod && m.Name == "Finalize") { continue; + } - var data = factory.CreateNewOverrideCompletionData (declarationBegin, type.Parts.First (), m); - string text = GetNameWithParamCount (m); - + var data = factory.CreateNewOverrideCompletionData(declarationBegin, currentType, m); // check if the member is already implemented - bool foundMember = type.Members.Any (cm => GetNameWithParamCount (cm) == text); - if (!foundMember && !alreadyInserted.ContainsKey (text)) { - alreadyInserted [text] = true; - data.CompletionCategory = col.GetCompletionCategory (curType); - col.Add (data); + bool foundMember = curType.GetMembers().Any(cm => SignatureComparer.Ordinal.Equals(cm, m) && cm.DeclaringTypeDefinition == curType.GetDefinition()); + if (foundMember) { + continue; } + if (alreadyInserted.Any(cm => SignatureComparer.Ordinal.Equals(cm, m))) + continue; + alreadyInserted.Add (m); + data.CompletionCategory = col.GetCompletionCategory(m.DeclaringTypeDefinition); + col.Add(data); } } - static void AddKeywords (CompletionDataWrapper wrapper, IEnumerable keywords) + static void AddKeywords(CompletionDataWrapper wrapper, IEnumerable keywords) { foreach (string keyword in keywords) { - wrapper.AddCustom (keyword); + wrapper.AddCustom(keyword); } } - public string GetPreviousMemberReferenceExpression (int tokenIndex) + public string GetPreviousMemberReferenceExpression(int tokenIndex) { - string result = GetPreviousToken (ref tokenIndex, false); - result = GetPreviousToken (ref tokenIndex, false); + string result = GetPreviousToken(ref tokenIndex, false); + result = GetPreviousToken(ref tokenIndex, false); if (result != ".") { result = null; } else { var names = new List (); while (result == ".") { - result = GetPreviousToken (ref tokenIndex, false); + result = GetPreviousToken(ref tokenIndex, false); if (result == "this") { - names.Add ("handle"); + names.Add("handle"); } else if (result != null) { - string trimmedName = result.Trim (); - if (trimmedName.Length == 0) + string trimmedName = result.Trim(); + if (trimmedName.Length == 0) { break; - names.Insert (0, trimmedName); + } + names.Insert(0, trimmedName); } - result = GetPreviousToken (ref tokenIndex, false); + result = GetPreviousToken(ref tokenIndex, false); } - result = String.Join ("", names.ToArray ()); + result = String.Join("", names.ToArray()); foreach (char ch in result) { - if (!char.IsLetterOrDigit (ch) && ch != '_') { + if (!char.IsLetterOrDigit(ch) && ch != '_') { result = ""; break; } @@ -1492,45 +1768,49 @@ namespace ICSharpCode.NRefactory.CSharp.Completion return result; } - bool MatchDelegate (IType delegateType, IUnresolvedMethod method) + bool MatchDelegate(IType delegateType, IUnresolvedMethod method) { - var delegateMethod = delegateType.GetDelegateInvokeMethod (); - if (delegateMethod == null || delegateMethod.Parameters.Count != method.Parameters.Count) + var delegateMethod = delegateType.GetDelegateInvokeMethod(); + if (delegateMethod == null || delegateMethod.Parameters.Count != method.Parameters.Count) { return false; + } for (int i = 0; i < delegateMethod.Parameters.Count; i++) { - if (!delegateMethod.Parameters [i].Type.Equals (method.Parameters [i].Type.Resolve (ctx))) + if (!delegateMethod.Parameters [i].Type.Equals(method.Parameters [i].Type.Resolve(ctx))) { return false; + } } return true; } - string AddDelegateHandlers (CompletionDataWrapper completionList, IType delegateType, bool addSemicolon = true, bool addDefault = true) + string AddDelegateHandlers(CompletionDataWrapper completionList, IType delegateType, bool addSemicolon = true, bool addDefault = true) { - IMethod delegateMethod = delegateType.GetDelegateInvokeMethod (); - var thisLineIndent = GetLineIndent (location.Line); + IMethod delegateMethod = delegateType.GetDelegateInvokeMethod(); + var thisLineIndent = GetLineIndent(location.Line); string delegateEndString = EolMarker + thisLineIndent + "}" + (addSemicolon ? ";" : ""); - bool containsDelegateData = completionList.Result.Any (d => d.DisplayText.StartsWith ("delegate(")); - if (addDefault) - completionList.AddCustom ("delegate", "Creates anonymous delegate.", "delegate {" + EolMarker + thisLineIndent + IndentString + "|" + delegateEndString); + //bool containsDelegateData = completionList.Result.Any(d => d.DisplayText.StartsWith("delegate(")); + if (addDefault) { + completionList.AddCustom("delegate", "Creates anonymous delegate.", "delegate {" + EolMarker + thisLineIndent + IndentString + "|" + delegateEndString); + } var sb = new StringBuilder ("("); var sbWithoutTypes = new StringBuilder ("("); for (int k = 0; k < delegateMethod.Parameters.Count; k++) { if (k > 0) { - sb.Append (", "); - sbWithoutTypes.Append (", "); + sb.Append(", "); + sbWithoutTypes.Append(", "); } var parameterType = delegateMethod.Parameters [k].Type; - sb.Append (GetShortType (parameterType, GetState ())); - sb.Append (" "); - sb.Append (delegateMethod.Parameters [k].Name); - sbWithoutTypes.Append (delegateMethod.Parameters [k].Name); - } - sb.Append (")"); - sbWithoutTypes.Append (")"); - completionList.AddCustom ("delegate" + sb, "Creates anonymous delegate.", "delegate" + sb + " {" + EolMarker + thisLineIndent + IndentString + "|" + delegateEndString); - if (!completionList.Result.Any (data => data.DisplayText == sbWithoutTypes.ToString ())) - completionList.AddCustom (sbWithoutTypes.ToString (), "Creates lambda expression.", sbWithoutTypes + " => |" + (addSemicolon ? ";" : "")); + sb.Append(GetShortType(parameterType, GetState())); + sb.Append(" "); + sb.Append(delegateMethod.Parameters [k].Name); + sbWithoutTypes.Append(delegateMethod.Parameters [k].Name); + } + sb.Append(")"); + sbWithoutTypes.Append(")"); + completionList.AddCustom("delegate" + sb, "Creates anonymous delegate.", "delegate" + sb + " {" + EolMarker + thisLineIndent + IndentString + "|" + delegateEndString); + if (!completionList.Result.Any(data => data.DisplayText == sbWithoutTypes.ToString())) { + completionList.AddCustom(sbWithoutTypes.ToString(), "Creates lambda expression.", sbWithoutTypes + " => |" + (addSemicolon ? ";" : "")); + } /* TODO:Make factory method out of it. // It's needed to temporarly disable inserting auto matching bracket because the anonymous delegates are selectable with '(' // otherwise we would end up with () => ) @@ -1541,32 +1821,36 @@ namespace ICSharpCode.NRefactory.CSharp.Completion MonoDevelop.SourceEditor.DefaultSourceEditorOptions.Instance.AutoInsertMatchingBracket = savedValue; }; }*/ - return sb.ToString (); + return sb.ToString(); } - bool IsAccessibleFrom (IEntity member, ITypeDefinition calledType, IMember currentMember, bool includeProtected) + bool IsAccessibleFrom(IEntity member, ITypeDefinition calledType, IMember currentMember, bool includeProtected) { - if (currentMember == null) + if (currentMember == null) { return member.IsStatic || member.IsPublic; -// if (currentMember is MonoDevelop.Projects.Dom.BaseResolveResult.BaseMemberDecorator) -// return member.IsPublic | member.IsProtected; + } + // if (currentMember is MonoDevelop.Projects.Dom.BaseResolveResult.BaseMemberDecorator) + // return member.IsPublic | member.IsProtected; // if (member.IsStatic && !IsStatic) // return false; - if (member.IsPublic || calledType != null && calledType.Kind == TypeKind.Interface && !member.IsProtected) + if (member.IsPublic || calledType != null && calledType.Kind == TypeKind.Interface && !member.IsProtected) { return true; + } if (member.DeclaringTypeDefinition != null) { - if (member.DeclaringTypeDefinition.Kind == TypeKind.Interface) - return IsAccessibleFrom (member.DeclaringTypeDefinition, calledType, currentMember, includeProtected); + if (member.DeclaringTypeDefinition.Kind == TypeKind.Interface) { + return IsAccessibleFrom(member.DeclaringTypeDefinition, calledType, currentMember, includeProtected); + } - if (member.IsProtected && !(member.DeclaringTypeDefinition.IsProtectedOrInternal && !includeProtected)) + if (member.IsProtected && !(member.DeclaringTypeDefinition.IsProtectedOrInternal && !includeProtected)) { return includeProtected; + } } if (member.IsInternal || member.IsProtectedAndInternal || member.IsProtectedOrInternal) { - var type1 = member is ITypeDefinition ? (ITypeDefinition)member : member.DeclaringTypeDefinition; - var type2 = currentMember is ITypeDefinition ? (ITypeDefinition)currentMember : currentMember.DeclaringTypeDefinition; + //var type1 = member is ITypeDefinition ? (ITypeDefinition)member : member.DeclaringTypeDefinition; + //var type2 = currentMember is ITypeDefinition ? (ITypeDefinition)currentMember : currentMember.DeclaringTypeDefinition; bool result = true; // easy case, projects are the same -/*// if (type1.ProjectContent == type2.ProjectContent) { + /*// if (type1.ProjectContent == type2.ProjectContent) { // result = true; // } else if (type1.ProjectContent != null) { @@ -1585,14 +1869,16 @@ namespace ICSharpCode.NRefactory.CSharp.Completion return member.IsProtectedAndInternal ? includeProtected && result : result; } - if (!(currentMember is IType) && (currentMember.DeclaringTypeDefinition == null || member.DeclaringTypeDefinition == null)) + if (!(currentMember is IType) && (currentMember.DeclaringTypeDefinition == null || member.DeclaringTypeDefinition == null)) { return false; + } // inner class var declaringType = currentMember.DeclaringTypeDefinition; while (declaringType != null) { - if (declaringType.ReflectionName == currentMember.DeclaringType.ReflectionName) + if (declaringType.ReflectionName == currentMember.DeclaringType.ReflectionName) { return true; + } declaringType = declaringType.DeclaringTypeDefinition; } @@ -1600,367 +1886,506 @@ namespace ICSharpCode.NRefactory.CSharp.Completion return currentMember.DeclaringTypeDefinition != null && member.DeclaringTypeDefinition.FullName == currentMember.DeclaringTypeDefinition.FullName; } - IEnumerable CreateTypeAndNamespaceCompletionData (TextLocation location, ResolveResult resolveResult, AstNode resolvedNode, CSharpResolver state) + static bool IsAttributeContext(AstNode node) + { + AstNode n = node; + while (n is AstType) { + n = n.Parent; + } + return n is Attribute; + } + + IType GuessHintType(AstNode resolvedNode) { - if (resolveResult == null || resolveResult.IsError) + ObjectCreateExpression oce = resolvedNode.Parent as ObjectCreateExpression ?? (ObjectCreateExpression)resolvedNode.Ancestors.FirstOrDefault(n => n is ObjectCreateExpression); + if (oce != null && oce.Parent is ReturnStatement) { + return ctx.CurrentMember != null ? ctx.CurrentMember.ReturnType : null; + } + return null; + } + + IEnumerable CreateTypeAndNamespaceCompletionData(TextLocation location, ResolveResult resolveResult, AstNode resolvedNode, CSharpResolver state) + { + if (resolveResult == null || resolveResult.IsError) { return null; + } + + var hintType = GuessHintType(resolvedNode); var result = new CompletionDataWrapper (this); if (resolveResult is NamespaceResolveResult) { var nr = (NamespaceResolveResult)resolveResult; - foreach (var cl in nr.Namespace.Types) { - result.AddType (cl, cl.Name); + if (!(resolvedNode.Parent is UsingDeclaration || resolvedNode.Parent != null && resolvedNode.Parent.Parent is UsingDeclaration)) { + foreach (var cl in nr.Namespace.Types) { + string name = cl.Name; + if (hintType != null && hintType.Kind != TypeKind.Array && cl.Kind == TypeKind.Interface) { + continue; + } + if (IsAttributeContext(resolvedNode) && name.EndsWith("Attribute") && name.Length > "Attribute".Length) { + name = name.Substring(0, name.Length - "Attribute".Length); + } + result.AddType(cl, name); + } } foreach (var ns in nr.Namespace.ChildNamespaces) { - result.AddNamespace (ns.Name); + result.AddNamespace(ns.Name); } } else if (resolveResult is TypeResolveResult) { var type = resolveResult.Type; foreach (var nested in type.GetNestedTypes ()) { - result.AddType (nested, nested.Name); + if (hintType != null && hintType.Kind != TypeKind.Array && nested.Kind == TypeKind.Interface) { + continue; + } + result.AddType(nested, nested.Name); } } return result.Result; } - - IEnumerable CreateTypeList () + + IEnumerable CreateTypeList() { foreach (var cl in Compilation.RootNamespace.Types) { - yield return factory.CreateTypeCompletionData (cl, cl.Name); + yield return factory.CreateTypeCompletionData(cl, cl.Name); } foreach (var ns in Compilation.RootNamespace.ChildNamespaces) { - yield return factory.CreateNamespaceCompletionData (ns.Name); + yield return factory.CreateNamespaceCompletionData(ns.Name); } } - IEnumerable CreateParameterCompletion (MethodGroupResolveResult resolveResult, CSharpResolver state, AstNode invocation, int parameter, bool controlSpace) + IEnumerable CreateParameterCompletion(MethodGroupResolveResult resolveResult, CSharpResolver state, AstNode invocation, CompilationUnit unit, int parameter, bool controlSpace) { - var result = new CompletionDataWrapper (this); - var addedEnums = new HashSet (); - var addedDelegates = new HashSet (); + var result = new CompletionDataWrapper(this); + var addedEnums = new HashSet(); + var addedDelegates = new HashSet(); foreach (var method in resolveResult.Methods) { - if (method.Parameters.Count <= parameter) + if (method.Parameters.Count <= parameter) { continue; + } var resolvedType = method.Parameters [parameter].Type; if (resolvedType.Kind == TypeKind.Enum) { - if (addedEnums.Contains (resolvedType.ReflectionName)) + if (addedEnums.Contains(resolvedType.ReflectionName)) { continue; - addedEnums.Add (resolvedType.ReflectionName); - AddEnumMembers (result, resolvedType, state); + } + addedEnums.Add(resolvedType.ReflectionName); + AddEnumMembers(result, resolvedType, state); } else if (resolvedType.Kind == TypeKind.Delegate) { -// if (addedDelegates.Contains (resolvedType.DecoratedFullName)) -// continue; -// addedDelegates.Add (resolvedType.DecoratedFullName); -// string parameterDefinition = AddDelegateHandlers (completionList, resolvedType, false, addedDelegates.Count == 1); -// string varName = "Handle" + method.Parameters [parameter].ReturnType.Name + method.Parameters [parameter].Name; -// result.Add (new EventCreationCompletionData (document, varName, resolvedType, null, parameterDefinition, resolver.Unit.GetMemberAt (location), resolvedType) { AddSemicolon = false }); - + if (addedDelegates.Contains(resolvedType.ReflectionName)) + continue; + string parameterDefinition = AddDelegateHandlers(result, resolvedType); + string varName = "Handle" + method.Parameters [parameter].Type.Name + method.Parameters [parameter].Name; + result.Result.Add(factory.CreateEventCreationCompletionData(varName, resolvedType, null, parameterDefinition, currentMember, currentType)); } } if (!controlSpace) { - if (addedEnums.Count + addedDelegates.Count == 0) - return Enumerable.Empty (); + if (addedEnums.Count + addedDelegates.Count == 0) { + return Enumerable.Empty(); + } AutoCompleteEmptyMatch = false; AutoSelect = false; } - AddContextCompletion (result, state, invocation); + AddContextCompletion(result, state, invocation, unit); -// resolver.AddAccessibleCodeCompletionData (ExpressionContext.MethodBody, cdc); -// if (addedDelegates.Count > 0) { -// foreach (var data in result.Result) { -// if (data is MemberCompletionData) -// ((MemberCompletionData)data).IsDelegateExpected = true; -// } -// } + // resolver.AddAccessibleCodeCompletionData (ExpressionContext.MethodBody, cdc); + // if (addedDelegates.Count > 0) { + // foreach (var data in result.Result) { + // if (data is MemberCompletionData) + // ((MemberCompletionData)data).IsDelegateExpected = true; + // } + // } return result.Result; } - string GetShortType (IType type, CSharpResolver state) + string GetShortType(IType type, CSharpResolver state) { var builder = new TypeSystemAstBuilder (state); - var shortType = builder.ConvertType (type); - using (var w = new System.IO.StringWriter ()) { - var visitor = new CSharpOutputVisitor (w, FormattingPolicy); - shortType.AcceptVisitor (visitor, null); - return w.ToString (); + var dt = state.CurrentTypeDefinition; + var declaring = type.DeclaringType != null ? type.DeclaringType.GetDefinition() : null; + if (declaring != null) { + while (dt != null) { + if (dt.Equals(declaring)) { + builder.AlwaysUseShortTypeNames = true; + break; + } + dt = dt.DeclaringTypeDefinition; + } } + var shortType = builder.ConvertType(type); + return shortType.GetText(FormattingPolicy); } - void AddEnumMembers (CompletionDataWrapper completionList, IType resolvedType, CSharpResolver state) + void AddEnumMembers(CompletionDataWrapper completionList, IType resolvedType, CSharpResolver state) { - if (resolvedType.Kind != TypeKind.Enum) + if (resolvedType.Kind != TypeKind.Enum) { return; - string typeString = GetShortType (resolvedType, state); - if (typeString.Contains (".")) - completionList.AddType (resolvedType, typeString); + } + string typeString = GetShortType(resolvedType, state); + if (typeString.Contains(".")) { + completionList.AddType(resolvedType, typeString); + } foreach (var field in resolvedType.GetFields ()) { - if (field.IsConst || field.IsStatic) - completionList.Result.Add (factory.CreateEntityCompletionData (field, typeString + "." + field.Name)); + if (field.IsConst || field.IsStatic) { + completionList.Result.Add(factory.CreateEntityCompletionData(field, typeString + "." + field.Name)); + } } DefaultCompletionString = typeString; } - IEnumerable CreateCompletionData (TextLocation location, ResolveResult resolveResult, AstNode resolvedNode, CSharpResolver state) + IEnumerable CreateCompletionData(TextLocation location, ResolveResult resolveResult, AstNode resolvedNode, CSharpResolver state) { - if (resolveResult == null /*|| resolveResult.IsError*/) + if (resolveResult == null /*|| resolveResult.IsError*/) { return null; + } if (resolveResult is NamespaceResolveResult) { var nr = (NamespaceResolveResult)resolveResult; - var namespaceContents = new CompletionDataWrapper (this); + var namespaceContents = new CompletionDataWrapper(this); foreach (var cl in nr.Namespace.Types) { - namespaceContents.AddType (cl, cl.Name); + namespaceContents.AddType(cl, cl.Name); } foreach (var ns in nr.Namespace.ChildNamespaces) { - namespaceContents.AddNamespace (ns.Name); + namespaceContents.AddNamespace(ns.Name); } return namespaceContents.Result; } IType type = resolveResult.Type; - var typeDef = resolveResult.Type.GetDefinition (); - var lookup = new MemberLookup (ctx.CurrentTypeDefinition, Compilation.MainAssembly); - var result = new CompletionDataWrapper (this); - bool isProtectedAllowed = false; + //var typeDef = resolveResult.Type.GetDefinition(); + var result = new CompletionDataWrapper(this); bool includeStaticMembers = false; if (resolveResult is LocalResolveResult) { - isProtectedAllowed = currentType != null && typeDef != null ? typeDef.GetAllBaseTypeDefinitions ().Any (bt => bt.Equals (currentType)) : false; if (resolvedNode is IdentifierExpression) { var mrr = (LocalResolveResult)resolveResult; includeStaticMembers = mrr.Variable.Name == mrr.Type.Name; } - } else { - isProtectedAllowed = currentType != null && typeDef != null ? currentType.Resolve (ctx).GetDefinition ().GetAllBaseTypeDefinitions ().Any (bt => bt.Equals (typeDef)) : false; } if (resolveResult is TypeResolveResult && type.Kind == TypeKind.Enum) { foreach (var field in type.GetFields ()) { - result.AddMember (field); + result.AddMember(field); } foreach (var m in type.GetMethods ()) { - if (m.Name == "TryParse") - result.AddMember (m); + if (m.Name == "TryParse") { + result.AddMember(m); + } } return result.Result; } + var lookup = new MemberLookup(ctx.CurrentTypeDefinition, Compilation.MainAssembly); + bool isProtectedAllowed = resolveResult is ThisResolveResult ? true : lookup.IsProtectedAccessAllowed(type); + bool skipNonStaticMembers = (resolveResult is TypeResolveResult); + if (resolveResult is MemberResolveResult && resolvedNode is IdentifierExpression) { var mrr = (MemberResolveResult)resolveResult; includeStaticMembers = mrr.Member.Name == mrr.Type.Name; + + TypeResolveResult trr; + if (state.IsVariableReferenceWithSameType(resolveResult, ((IdentifierExpression)resolvedNode).Identifier, out trr)) { + if (currentMember != null && mrr.Member.IsStatic ^ currentMember.IsStatic) { + skipNonStaticMembers = true; + + if (trr.Type.Kind == TypeKind.Enum) { + foreach (var field in trr.Type.GetFields ()) { + result.AddMember(field); + } + foreach (var m in trr.Type.GetMethods ()) { + if (m.Name == "TryParse" && m.IsStatic) { + result.AddMember(m); + } + } + return result.Result; + } + } + } + // ADD Aliases + var scope = CSharpParsedFile.GetUsingScope(location).Resolve(Compilation); + + for (var n = scope; n != null; n = n.Parent) { + foreach (var pair in n.UsingAliases) { + if (pair.Key == mrr.Member.Name) { + foreach (var r in CreateCompletionData (location, pair.Value, resolvedNode, state)) { + if (r is IEntityCompletionData && ((IEntityCompletionData)r).Entity is IMember) { + result.AddMember((IMember)((IEntityCompletionData)r).Entity); + } else { + result.Add(r); + } + } + } + } + } + + + } + if (resolveResult is TypeResolveResult && (resolvedNode is IdentifierExpression || resolvedNode is MemberReferenceExpression)) { + includeStaticMembers = true; } -// Console.WriteLine ("type:" + type +"/"+type.GetType ()); -// Console.WriteLine ("IS PROT ALLOWED:" + isProtectedAllowed); -// Console.WriteLine (resolveResult); -// Console.WriteLine (currentMember != null ? currentMember.IsStatic : "currentMember == null"); + // Console.WriteLine ("type:" + type +"/"+type.GetType ()); + // Console.WriteLine ("current:" + ctx.CurrentTypeDefinition); + // Console.WriteLine ("IS PROT ALLOWED:" + isProtectedAllowed + " static: "+ includeStaticMembers); + // Console.WriteLine (resolveResult); + // Console.WriteLine ("node:" + resolvedNode); + // Console.WriteLine (currentMember != null ? currentMember.IsStatic : "currentMember == null"); - if (resolvedNode.Annotation () == null) { //tags the created expression as part of an object create expression. + if (resolvedNode.Annotation() == null) { + //tags the created expression as part of an object create expression. + + var filteredList = new List(); foreach (var member in type.GetMembers ()) { - if (!lookup.IsAccessible (member, isProtectedAllowed)) { - // Console.WriteLine ("skip access: " + member.FullName); + if (member.EntityType == EntityType.Indexer || member.EntityType == EntityType.Operator || member.EntityType == EntityType.Constructor || member.EntityType == EntityType.Destructor) { + continue; + } + if (member.IsExplicitInterfaceImplementation) { + continue; + } + // Console.WriteLine ("member:" + member + member.IsShadowing); + if (!lookup.IsAccessible(member, isProtectedAllowed)) { + // Console.WriteLine ("skip access: " + member.FullName); + continue; + } + if (resolvedNode is BaseReferenceExpression && member.IsAbstract) { continue; } - if (resolvedNode is BaseReferenceExpression && member.IsAbstract) + bool memberIsStatic = member.IsStatic; + if (!includeStaticMembers && memberIsStatic && !(resolveResult is TypeResolveResult)) { + // Console.WriteLine ("skip static member: " + member.FullName); continue; + } + var field = member as IField; + if (field != null) { + memberIsStatic |= field.IsConst; + } + + if (!memberIsStatic && skipNonStaticMembers) { + continue; + } - if (!includeStaticMembers && member.IsStatic && !(resolveResult is TypeResolveResult)) { - // Console.WriteLine ("skip static member: " + member.FullName); + if (member is IMethod && ((IMethod)member).FullName == "System.Object.Finalize") { + continue; + } + if (member.EntityType == EntityType.Operator) { continue; } - if (!member.IsStatic && (resolveResult is TypeResolveResult)) { - // Console.WriteLine ("skip non static member: " + member.FullName); + if (member.IsExplicitInterfaceImplementation) { continue; } - // Console.WriteLine ("add : "+ member.FullName + " --- " + member.IsStatic); - result.AddMember (member); + if (member.IsShadowing) { + filteredList.RemoveAll(m => m.Name == member.Name); + } + + filteredList.Add(member); + } + + foreach (var member in filteredList) { + // Console.WriteLine ("add:" + member + "/" + member.IsStatic); + result.AddMember(member); } } if (resolveResult is TypeResolveResult || includeStaticMembers) { foreach (var nested in type.GetNestedTypes ()) { - result.AddType (nested, nested.Name); + result.AddType(nested, nested.Name); } } else { - foreach (var meths in state.GetAllExtensionMethods (type)) { + foreach (var meths in state.GetExtensionMethods (type)) { foreach (var m in meths) { - result.AddMember (m); + result.AddMember(m); } } } -// IEnumerable objects = resolveResult.CreateResolveResult (dom, resolver != null ? resolver.CallingMember : null); -// CompletionDataCollector col = new CompletionDataCollector (this, dom, result, Document.CompilationUnit, resolver != null ? resolver.CallingType : null, location); -// col.HideExtensionParameter = !resolveResult.StaticResolve; -// col.NamePrefix = expressionResult.Expression; -// bool showOnlyTypes = expressionResult.Contexts.Any (ctx => ctx == ExpressionContext.InheritableType || ctx == ExpressionContext.Constraints); -// if (objects != null) { -// foreach (object obj in objects) { -// if (expressionResult.ExpressionContext != null && expressionResult.ExpressionContext.FilterEntry (obj)) -// continue; -// if (expressionResult.ExpressionContext == ExpressionContext.NamespaceNameExcepted && !(obj is Namespace)) -// continue; -// if (showOnlyTypes && !(obj is IType)) -// continue; -// CompletionData data = col.Add (obj); -// if (data != null && expressionResult.ExpressionContext == ExpressionContext.Attribute && data.CompletionText != null && data.CompletionText.EndsWith ("Attribute")) { -// string newText = data.CompletionText.Substring (0, data.CompletionText.Length - "Attribute".Length); -// data.SetText (newText); -// } -// } -// } + // IEnumerable objects = resolveResult.CreateResolveResult (dom, resolver != null ? resolver.CallingMember : null); + // CompletionDataCollector col = new CompletionDataCollector (this, dom, result, Document.CompilationUnit, resolver != null ? resolver.CallingType : null, location); + // col.HideExtensionParameter = !resolveResult.StaticResolve; + // col.NamePrefix = expressionResult.Expression; + // bool showOnlyTypes = expressionResult.Contexts.Any (ctx => ctx == ExpressionContext.InheritableType || ctx == ExpressionContext.Constraints); + // if (objects != null) { + // foreach (object obj in objects) { + // if (expressionResult.ExpressionContext != null && expressionResult.ExpressionContext.FilterEntry (obj)) + // continue; + // if (expressionResult.ExpressionContext == ExpressionContext.NamespaceNameExcepted && !(obj is Namespace)) + // continue; + // if (showOnlyTypes && !(obj is IType)) + // continue; + // CompletionData data = col.Add (obj); + // if (data != null && expressionResult.ExpressionContext == ExpressionContext.Attribute && data.CompletionText != null && data.CompletionText.EndsWith ("Attribute")) { + // string newText = data.CompletionText.Substring (0, data.CompletionText.Length - "Attribute".Length); + // data.SetText (newText); + // } + // } + // } return result.Result; } - IEnumerable CreateCaseCompletionData (TextLocation location) + IEnumerable CreateCaseCompletionData(TextLocation location) { - var unit = ParseStub ("a: break;"); - if (unit == null) + var unit = ParseStub("a: break;"); + if (unit == null) { return null; - var s = unit.GetNodeAt (location); - if (s == null) + } + var s = unit.GetNodeAt(location); + if (s == null) { return null; + } - var offset = document.GetOffset (s.Expression.StartLocation); - var expr = GetExpressionAt (offset); - if (expr == null) + var offset = document.GetOffset(s.Expression.StartLocation); + var expr = GetExpressionAt(offset); + if (expr == null) { return null; + } - var resolveResult = ResolveExpression (expr.Item1, expr.Item2, expr.Item3); - if (resolveResult == null || resolveResult.Item1.Type.Kind != TypeKind.Enum) + var resolveResult = ResolveExpression(expr); + if (resolveResult == null || resolveResult.Item1.Type.Kind != TypeKind.Enum) { return null; + } var wrapper = new CompletionDataWrapper (this); - AddEnumMembers (wrapper, resolveResult.Item1.Type, resolveResult.Item2); + AddEnumMembers(wrapper, resolveResult.Item1.Type, resolveResult.Item2); AutoCompleteEmptyMatch = false; return wrapper.Result; } #region Parsing methods - Tuple GetExpressionBeforeCursor () + ExpressionResult GetExpressionBeforeCursor() { CompilationUnit baseUnit; if (currentMember == null) { - baseUnit = ParseStub ("st {}", false); - var type = baseUnit.GetNodeAt (location); + baseUnit = ParseStub("a", false); + var type = baseUnit.GetNodeAt(location); + if (type == null) { + baseUnit = ParseStub("a;", false); + type = baseUnit.GetNodeAt(location); + } + if (type == null) { - baseUnit = ParseStub ("a;", false); - type = baseUnit.GetNodeAt (location); + baseUnit = ParseStub("A a;", false); + type = baseUnit.GetNodeAt(location); } if (type != null) { - // insert target type into compilation unit, to respect the - var target = type.Target; - target.Remove (); - var node = Unit.GetNodeAt (location) ?? Unit; - node.AddChild (target, AstNode.Roles.Type); - return Tuple.Create (CSharpParsedFile, (AstNode)target, Unit); + return new ExpressionResult ((AstNode)type.Target, baseUnit); } } - if (currentMember == null && currentType == null) - return null; - baseUnit = ParseStub ("a()"); - var curNode = baseUnit.GetNodeAt (location); + baseUnit = ParseStub("a()", false); + var curNode = baseUnit.GetNodeAt(location); + + // hack for local variable declaration missing ';' issue - remove that if it works. + if (curNode is EntityDeclaration || baseUnit.GetNodeAt(location) == null) { + baseUnit = ParseStub("a()"); + curNode = baseUnit.GetNodeAt(location); + } + // Hack for handle object initializer continuation expressions - if (curNode is AttributedNode || baseUnit.GetNodeAt (location) == null) { - baseUnit = ParseStub ("a()};"); + if (curNode is EntityDeclaration || baseUnit.GetNodeAt(location) == null) { + baseUnit = ParseStub("a()};"); } - - var memberLocation = currentMember != null ? currentMember.Region.Begin : currentType.Region.Begin; - var mref = baseUnit.GetNodeAt (location); + var mref = baseUnit.GetNodeAt(location); + if (currentMember == null && currentType == null) { + if (mref != null) { + return new ExpressionResult ((AstNode)mref.Target, baseUnit); + } + return null; + } + //var memberLocation = currentMember != null ? currentMember.Region.Begin : currentType.Region.Begin; if (mref == null) { - var invoke = baseUnit.GetNodeAt (location); - if (invoke != null) + var invoke = baseUnit.GetNodeAt(location); + if (invoke != null) { mref = invoke.Target as MemberReferenceExpression; + } } - Expression expr = null; + AstNode expr = null; if (mref != null) { - expr = mref.Target.Clone (); - mref.Parent.ReplaceWith (expr); + expr = mref.Target.Clone(); + mref.Parent.ReplaceWith(expr); } else { - Expression tref = baseUnit.GetNodeAt (location); + Expression tref = baseUnit.GetNodeAt(location); MemberType memberType = tref != null ? ((TypeReferenceExpression)tref).Type as MemberType : null; if (memberType == null) { - memberType = baseUnit.GetNodeAt (location); + memberType = baseUnit.GetNodeAt(location); if (memberType != null) { - tref = baseUnit.GetNodeAt (location); - if (tref == null) { - tref = new TypeReferenceExpression (memberType.Clone ()); - memberType.Parent.AddChild (tref, AstNode.Roles.Expression); + if (memberType.Parent is ObjectCreateExpression) { + var mt = memberType.Target.Clone(); + memberType.ReplaceWith(mt); + expr = mt; + goto exit; + } else { + tref = baseUnit.GetNodeAt(location); + if (tref == null) { + tref = new TypeReferenceExpression (memberType.Clone()); + memberType.Parent.AddChild(tref, Roles.Expression); + } + if (tref is ObjectCreateExpression) { + expr = new TypeReferenceExpression (memberType.Target.Clone()); + expr.AddAnnotation(new ObjectCreateExpression ()); + } } } - if (tref is ObjectCreateExpression) { - expr = new TypeReferenceExpression (memberType.Target.Clone ()); - expr.AddAnnotation (new ObjectCreateExpression ()); - } } - - if (memberType == null) + + if (memberType == null) { return null; - if (expr == null) - expr = new TypeReferenceExpression (memberType.Target.Clone ()); - tref.ReplaceWith (expr); + } + if (expr == null) { + expr = new TypeReferenceExpression (memberType.Target.Clone()); + } + tref.ReplaceWith(expr); } - - var member = Unit.GetNodeAt (memberLocation); - var member2 = baseUnit.GetNodeAt (memberLocation); - member2.Remove (); - member.ReplaceWith (member2); - var tsvisitor = new TypeSystemConvertVisitor (this.CSharpParsedFile.FileName); - Unit.AcceptVisitor (tsvisitor, null); - return Tuple.Create (tsvisitor.ParsedFile, (AstNode)expr, Unit); + exit: + return new ExpressionResult ((AstNode)expr, baseUnit); } - - Tuple GetExpressionAtCursor () + + ExpressionResult GetExpressionAtCursor() { -// if (currentMember == null && currentType == null) -// return null; + // TextLocation memberLocation; + // if (currentMember != null) { + // memberLocation = currentMember.Region.Begin; + // } else if (currentType != null) { + // memberLocation = currentType.Region.Begin; + // } else { + // memberLocation = location; + // } + var baseUnit = ParseStub("a"); - TextLocation memberLocation; - if (currentMember != null) { - memberLocation = currentMember.Region.Begin; - } else if (currentType != null) { - memberLocation = currentType.Region.Begin; - } else { - memberLocation = location; - } - var baseUnit = ParseStub (""); var tmpUnit = baseUnit; - AstNode expr = baseUnit.GetNodeAt (location.Line, location.Column - 1); - + AstNode expr = baseUnit.GetNodeAt(location, n => n is IdentifierExpression || n is MemberReferenceExpression); + if (expr == null) { + expr = baseUnit.GetNodeAt(location.Line, location.Column - 1); + } if (expr == null) - expr = baseUnit.GetNodeAt (location.Line, location.Column - 1); - + expr = baseUnit.GetNodeAt(location.Line, location.Column - 1); // try insertStatement - if (expr == null && baseUnit.GetNodeAt (location.Line, location.Column) != null) { - tmpUnit = baseUnit = ParseStub ("a();", false); - expr = baseUnit.GetNodeAt (location.Line, location.Column + 1); + if (expr == null && baseUnit.GetNodeAt(location.Line, location.Column) != null) { + tmpUnit = baseUnit = ParseStub("a();", false); + expr = baseUnit.GetNodeAt(location.Line, location.Column + 1); } - + if (expr == null) { - baseUnit = ParseStub ("()"); - expr = baseUnit.GetNodeAt (location.Line, location.Column - 1); + baseUnit = ParseStub("()"); + expr = baseUnit.GetNodeAt(location.Line, location.Column - 1); + if (expr == null) { + expr = baseUnit.GetNodeAt(location.Line, location.Column - 1); + } } - - // try initializer expression + if (expr == null) { - baseUnit = ParseStub ("a = b};", false); - expr = baseUnit.GetNodeAt (location.Line, location.Column - 1); + baseUnit = ParseStub("a", false); + expr = baseUnit.GetNodeAt(location, n => n is IdentifierExpression || n is MemberReferenceExpression || n is CatchClause); } - + // try statement if (expr == null) { - expr = tmpUnit.GetNodeAt (location.Line, location.Column - 1); + expr = tmpUnit.GetNodeAt(location.Line, location.Column - 1); baseUnit = tmpUnit; } - + if (expr == null) { - var block = tmpUnit.GetNodeAt (location); - var node = block != null ? block.Statements.LastOrDefault () : null; - + var block = tmpUnit.GetNodeAt(location); + var node = block != null ? block.Statements.LastOrDefault() : null; + var forStmt = node != null ? node.PrevSibling as ForStatement : null; if (forStmt != null && forStmt.EmbeddedStatement.IsNull) { expr = forStmt; @@ -1972,326 +2397,188 @@ namespace ICSharpCode.NRefactory.CSharp.Completion } if (expr == null) { - var forStmt = tmpUnit.GetNodeAt (location.Line, location.Column - 3); + var forStmt = tmpUnit.GetNodeAt(location.Line, location.Column - 3); if (forStmt != null && forStmt.EmbeddedStatement.IsNull) { - forStmt.VariableNameToken = Identifier.Create ("stub"); + forStmt.VariableNameToken = Identifier.Create("stub"); expr = forStmt.VariableNameToken; baseUnit = tmpUnit; } } - - if (expr == null) { - expr = tmpUnit.GetNodeAt (location.Line, location.Column - 1); + expr = tmpUnit.GetNodeAt(location.Line, location.Column - 1); baseUnit = tmpUnit; } - + // try parameter declaration type if (expr == null) { - baseUnit = ParseStub (">", false, "{}"); - expr = baseUnit.GetNodeAt (location.Line, location.Column - 1); + baseUnit = ParseStub(">", false, "{}"); + expr = baseUnit.GetNodeAt(location.Line, location.Column - 1); } - + // try parameter declaration method if (expr == null) { - baseUnit = ParseStub ("> ()", false, "{}"); - expr = baseUnit.GetNodeAt (location.Line, location.Column - 1); + baseUnit = ParseStub("> ()", false, "{}"); + expr = baseUnit.GetNodeAt(location.Line, location.Column - 1); } - - if (expr == null) + + // try expression in anonymous type "new { sample = x$" case + if (expr == null) { + baseUnit = ParseStub("a", false); + expr = baseUnit.GetNodeAt(location.Line, location.Column); + if (expr != null) { + expr = baseUnit.GetNodeAt(location.Line, location.Column) ?? expr; + } + if (expr == null) { + expr = baseUnit.GetNodeAt(location.Line, location.Column); + } + } + if (expr == null) { return null; - var member = Unit.GetNodeAt (memberLocation); - var member2 = baseUnit.GetNodeAt (memberLocation); - if (member != null && member2 != null) { - member2.Remove (); - - if (member is TypeDeclaration) { - member.AddChild (member2, TypeDeclaration.MemberRole); - } else { - member.ReplaceWith (member2); - } - } else { - var tsvisitor2 = new TypeSystemConvertVisitor (CSharpParsedFile.FileName); - Unit.AcceptVisitor (tsvisitor2, null); - return Tuple.Create (tsvisitor2.ParsedFile, expr, baseUnit); } - var tsvisitor = new TypeSystemConvertVisitor (CSharpParsedFile.FileName); - Unit.AcceptVisitor (tsvisitor, null); - return Tuple.Create (tsvisitor.ParsedFile, expr, Unit); + return new ExpressionResult (expr, baseUnit); } - Tuple GetExpressionAt (int offset) + ExpressionResult GetExpressionAt(int offset) { var parser = new CSharpParser (); - string text = this.document.GetText (0, this.offset); + string text = this.document.GetText(0, this.offset); var sb = new StringBuilder (text); - sb.Append ("a;"); - AppendMissingClosingBrackets (sb, text, false); - var stream = new System.IO.StringReader (sb.ToString ()); - var completionUnit = parser.Parse (stream, CSharpParsedFile.FileName, 0); - stream.Close (); - var loc = document.GetLocation (offset); - - var expr = completionUnit.GetNodeAt (loc, n => n is Expression || n is VariableDeclarationStatement); - if (expr == null) + sb.Append("a;"); + AppendMissingClosingBrackets(sb, text, false); + var stream = new System.IO.StringReader (sb.ToString()); + var completionUnit = parser.Parse(stream, CSharpParsedFile.FileName, 0); + stream.Close(); + var loc = document.GetLocation(offset); + + var expr = completionUnit.GetNodeAt(loc, n => n is Expression || n is VariableDeclarationStatement); + if (expr == null) { return null; - var tsvisitor = new TypeSystemConvertVisitor (CSharpParsedFile.FileName); - completionUnit.AcceptVisitor (tsvisitor, null); - - return Tuple.Create (tsvisitor.ParsedFile, expr, completionUnit); + } + return new ExpressionResult (expr, completionUnit); } - Tuple GetNewExpressionAt (int offset) + ExpressionResult GetNewExpressionAt(int offset) { var parser = new CSharpParser (); - string text = this.document.GetText (0, this.offset); + string text = this.document.GetText(0, this.offset); var sb = new StringBuilder (text); - sb.Append ("a ();"); - AppendMissingClosingBrackets (sb, text, false); + sb.Append("a ();"); + AppendMissingClosingBrackets(sb, text, false); - var stream = new System.IO.StringReader (sb.ToString ()); - var completionUnit = parser.Parse (stream, CSharpParsedFile.FileName, 0); - stream.Close (); - var loc = document.GetLocation (offset); + var stream = new System.IO.StringReader (sb.ToString()); + var completionUnit = parser.Parse(stream, CSharpParsedFile.FileName, 0); + stream.Close(); + var loc = document.GetLocation(offset); - var expr = completionUnit.GetNodeAt (loc, n => n is Expression); + var expr = completionUnit.GetNodeAt(loc, n => n is Expression); if (expr == null) { // try without ";" sb = new StringBuilder (text); - sb.Append ("a ()"); - AppendMissingClosingBrackets (sb, text, false); - stream = new System.IO.StringReader (sb.ToString ()); - completionUnit = parser.Parse (stream, CSharpParsedFile.FileName, 0); - stream.Close (); - loc = document.GetLocation (offset); + sb.Append("a ()"); + AppendMissingClosingBrackets(sb, text, false); + stream = new System.IO.StringReader (sb.ToString()); + completionUnit = parser.Parse(stream, CSharpParsedFile.FileName, 0); + stream.Close(); + loc = document.GetLocation(offset); - expr = completionUnit.GetNodeAt (loc, n => n is Expression); - if (expr == null) + expr = completionUnit.GetNodeAt(loc, n => n is Expression); + if (expr == null) { return null; + } } - var tsvisitor = new TypeSystemConvertVisitor (CSharpParsedFile.FileName); - completionUnit.AcceptVisitor (tsvisitor, null); - - return Tuple.Create (tsvisitor.ParsedFile, expr, completionUnit); + return new ExpressionResult (expr, completionUnit); } #endregion #region Helper methods - string GetPreviousToken (ref int i, bool allowLineChange) + string GetPreviousToken(ref int i, bool allowLineChange) { char c; - if (i <= 0) + if (i <= 0) { return null; + } do { - c = document.GetCharAt (--i); + c = document.GetCharAt(--i); } while (i > 0 && char.IsWhiteSpace (c) && (allowLineChange ? true : c != '\n')); - if (i == 0) + if (i == 0) { return null; + } - if (!char.IsLetterOrDigit (c)) + if (!char.IsLetterOrDigit(c)) { return new string (c, 1); + } int endOffset = i + 1; do { - c = document.GetCharAt (i - 1); - if (!(char.IsLetterOrDigit (c) || c == '_')) + c = document.GetCharAt(i - 1); + if (!(char.IsLetterOrDigit(c) || c == '_')) { break; + } i--; } while (i > 0); - return document.GetText (i, endOffset - i); - } - - bool GetParameterCompletionCommandOffset (out int cpos) - { - // Start calculating the parameter offset from the beginning of the - // current member, instead of the beginning of the file. - cpos = offset - 1; - var mem = currentMember; - if (mem == null || (mem is IType)) - return false; - int startPos = document.GetOffset (mem.Region.BeginLine, mem.Region.BeginColumn); - int parenDepth = 0; - int chevronDepth = 0; - while (cpos > startPos) { - char c = document.GetCharAt (cpos); - if (c == ')') - parenDepth++; - if (c == '>') - chevronDepth++; - if (parenDepth == 0 && c == '(' || chevronDepth == 0 && c == '<') { - int p = GetCurrentParameterIndex (cpos + 1, startPos); - if (p != -1) { - cpos++; - return true; - } else { - return false; - } - } - if (c == '(') - parenDepth--; - if (c == '<') - chevronDepth--; - cpos--; - } - return false; - } - - int GetCurrentParameterIndex (int offset, int memberStart) - { - int cursor = this.offset; - int i = offset; - - if (i > cursor) - return -1; - if (i == cursor) - return 1; // parameters are 1 based - int index = memberStart + 1; - int parentheses = 0; - int bracket = 0; - bool insideQuote = false, insideString = false, insideSingleLineComment = false, insideMultiLineComment = false; - do { - char c = document.GetCharAt (i - 1); - switch (c) { - case '\\': - if (insideString || insideQuote) - i++; - break; - case '\'': - if (!insideString && !insideSingleLineComment && !insideMultiLineComment) - insideQuote = !insideQuote; - break; - case '"': - if (!insideQuote && !insideSingleLineComment && !insideMultiLineComment) - insideString = !insideString; - break; - case '/': - if (!insideQuote && !insideString && !insideMultiLineComment) { - if (document.GetCharAt (i) == '/') - insideSingleLineComment = true; - if (document.GetCharAt (i) == '*') - insideMultiLineComment = true; - } - break; - case '*': - if (insideMultiLineComment && document.GetCharAt (i) == '/') - insideMultiLineComment = false; - break; - case '\n': - case '\r': - insideSingleLineComment = false; - break; - case '{': - if (!insideQuote && !insideString && !insideSingleLineComment && !insideMultiLineComment) - bracket++; - break; - case '}': - if (!insideQuote && !insideString && !insideSingleLineComment && !insideMultiLineComment) - bracket--; - break; - case '(': - if (!insideQuote && !insideString && !insideSingleLineComment && !insideMultiLineComment) - parentheses++; - break; - case ')': - if (!insideQuote && !insideString && !insideSingleLineComment && !insideMultiLineComment) - parentheses--; - break; - case ',': - if (!insideQuote && !insideString && !insideSingleLineComment && !insideMultiLineComment && parentheses == 1 && bracket == 0) - index++; - break; - } - i++; - } while (i <= cursor && parentheses >= 0); - - return parentheses != 1 || bracket > 0 ? -1 : index; - } - - CSharpResolver GetState () - { - return new CSharpResolver (ctx); - /*var state = new CSharpResolver (ctx); - - state.CurrentMember = currentMember; - state.CurrentTypeDefinition = currentType; - state.CurrentUsingScope = CSharpParsedFile.GetUsingScope (location); - if (state.CurrentMember != null) { - var node = Unit.GetNodeAt (location); - if (node == null) - return state; - var navigator = new NodeListResolveVisitorNavigator (new[] { node }); - var visitor = new ResolveVisitor (state, CSharpParsedFile, navigator); - Unit.AcceptVisitor (visitor, null); - try { - var newState = visitor.GetResolverStateBefore (node); - if (newState != null) - state = newState; - } catch (Exception) { - } - } - - return state;*/ + return document.GetText(i, endOffset - i); } + #endregion #region Preprocessor - IEnumerable GetDirectiveCompletionData () + IEnumerable GetDirectiveCompletionData() { - yield return factory.CreateLiteralCompletionData ("if"); - yield return factory.CreateLiteralCompletionData ("else"); - yield return factory.CreateLiteralCompletionData ("elif"); - yield return factory.CreateLiteralCompletionData ("endif"); - yield return factory.CreateLiteralCompletionData ("define"); - yield return factory.CreateLiteralCompletionData ("undef"); - yield return factory.CreateLiteralCompletionData ("warning"); - yield return factory.CreateLiteralCompletionData ("error"); - yield return factory.CreateLiteralCompletionData ("pragma"); - yield return factory.CreateLiteralCompletionData ("line"); - yield return factory.CreateLiteralCompletionData ("line hidden"); - yield return factory.CreateLiteralCompletionData ("line default"); - yield return factory.CreateLiteralCompletionData ("region"); - yield return factory.CreateLiteralCompletionData ("endregion"); + yield return factory.CreateLiteralCompletionData("if"); + yield return factory.CreateLiteralCompletionData("else"); + yield return factory.CreateLiteralCompletionData("elif"); + yield return factory.CreateLiteralCompletionData("endif"); + yield return factory.CreateLiteralCompletionData("define"); + yield return factory.CreateLiteralCompletionData("undef"); + yield return factory.CreateLiteralCompletionData("warning"); + yield return factory.CreateLiteralCompletionData("error"); + yield return factory.CreateLiteralCompletionData("pragma"); + yield return factory.CreateLiteralCompletionData("line"); + yield return factory.CreateLiteralCompletionData("line hidden"); + yield return factory.CreateLiteralCompletionData("line default"); + yield return factory.CreateLiteralCompletionData("region"); + yield return factory.CreateLiteralCompletionData("endregion"); } #endregion #region Xml Comments static readonly List commentTags = new List (new string[] { "c", "code", "example", "exception", "include", "list", "listheader", "item", "term", "description", "para", "param", "paramref", "permission", "remarks", "returns", "see", "seealso", "summary", "value" }); - IEnumerable GetXmlDocumentationCompletionData () + IEnumerable GetXmlDocumentationCompletionData() { - yield return factory.CreateLiteralCompletionData ("c", "Set text in a code-like font"); - yield return factory.CreateLiteralCompletionData ("code", "Set one or more lines of source code or program output"); - yield return factory.CreateLiteralCompletionData ("example", "Indicate an example"); - yield return factory.CreateLiteralCompletionData ("exception", "Identifies the exceptions a method can throw", "exception cref=\"|\">"); - yield return factory.CreateLiteralCompletionData ("include", "Includes comments from a external file", "include file=\"|\" path=\"\">"); - yield return factory.CreateLiteralCompletionData ("list", "Create a list or table", "list type=\"|\">"); - yield return factory.CreateLiteralCompletionData ("listheader", "Define the heading row"); - yield return factory.CreateLiteralCompletionData ("item", "Defines list or table item"); - - yield return factory.CreateLiteralCompletionData ("term", "A term to define"); - yield return factory.CreateLiteralCompletionData ("description", "Describes a list item"); - yield return factory.CreateLiteralCompletionData ("para", "Permit structure to be added to text"); - - yield return factory.CreateLiteralCompletionData ("param", "Describe a parameter for a method or constructor", "param name=\"|\">"); - yield return factory.CreateLiteralCompletionData ("paramref", "Identify that a word is a parameter name", "paramref name=\"|\"/>"); - - yield return factory.CreateLiteralCompletionData ("permission", "Document the security accessibility of a member", "permission cref=\"|\""); - yield return factory.CreateLiteralCompletionData ("remarks", "Describe a type"); - yield return factory.CreateLiteralCompletionData ("returns", "Describe the return value of a method"); - yield return factory.CreateLiteralCompletionData ("see", "Specify a link", "see cref=\"|\"/>"); - yield return factory.CreateLiteralCompletionData ("seealso", "Generate a See Also entry", "seealso cref=\"|\"/>"); - yield return factory.CreateLiteralCompletionData ("summary", "Describe a member of a type"); - yield return factory.CreateLiteralCompletionData ("typeparam", "Describe a type parameter for a generic type or method"); - yield return factory.CreateLiteralCompletionData ("typeparamref", "Identify that a word is a type parameter name"); - yield return factory.CreateLiteralCompletionData ("value", "Describe a property"); + yield return factory.CreateLiteralCompletionData("c", "Set text in a code-like font"); + yield return factory.CreateLiteralCompletionData("code", "Set one or more lines of source code or program output"); + yield return factory.CreateLiteralCompletionData("example", "Indicate an example"); + yield return factory.CreateLiteralCompletionData("exception", "Identifies the exceptions a method can throw", "exception cref=\"|\">"); + yield return factory.CreateLiteralCompletionData("include", "Includes comments from a external file", "include file=\"|\" path=\"\">"); + yield return factory.CreateLiteralCompletionData("list", "Create a list or table", "list type=\"|\">"); + yield return factory.CreateLiteralCompletionData("listheader", "Define the heading row"); + yield return factory.CreateLiteralCompletionData("item", "Defines list or table item"); + + yield return factory.CreateLiteralCompletionData("term", "A term to define"); + yield return factory.CreateLiteralCompletionData("description", "Describes a list item"); + yield return factory.CreateLiteralCompletionData("para", "Permit structure to be added to text"); + + yield return factory.CreateLiteralCompletionData("param", "Describe a parameter for a method or constructor", "param name=\"|\">"); + yield return factory.CreateLiteralCompletionData("paramref", "Identify that a word is a parameter name", "paramref name=\"|\"/>"); + + yield return factory.CreateLiteralCompletionData("permission", "Document the security accessibility of a member", "permission cref=\"|\""); + yield return factory.CreateLiteralCompletionData("remarks", "Describe a type"); + yield return factory.CreateLiteralCompletionData("returns", "Describe the return value of a method"); + yield return factory.CreateLiteralCompletionData("see", "Specify a link", "see cref=\"|\"/>"); + yield return factory.CreateLiteralCompletionData("seealso", "Generate a See Also entry", "seealso cref=\"|\"/>"); + yield return factory.CreateLiteralCompletionData("summary", "Describe a member of a type"); + yield return factory.CreateLiteralCompletionData("typeparam", "Describe a type parameter for a generic type or method"); + yield return factory.CreateLiteralCompletionData("typeparamref", "Identify that a word is a type parameter name"); + yield return factory.CreateLiteralCompletionData("value", "Describe a property"); } #endregion @@ -2302,7 +2589,8 @@ namespace ICSharpCode.NRefactory.CSharp.Completion "true", "false", "typeof", "checked", "unchecked", "from", "break", "checked", "unchecked", "const", "continue", "do", "finally", "fixed", "for", "foreach", "goto", "if", "lock", "return", "stackalloc", "switch", "throw", "try", "unsafe", - "using", "while", "yield", "dynamic", "var", "dynamic" + "using", "while", "yield", "dynamic", "var", "dynamic", + "catch" }; static string[] globalLevelKeywords = new string [] { "namespace", "using", "extern", "public", "internal", @@ -2321,6 +2609,7 @@ namespace ICSharpCode.NRefactory.CSharp.Completion "override", "readonly", "virtual", "volatile" }; static string[] linqKeywords = new string[] { "from", "where", "select", "group", "into", "orderby", "join", "let", "in", "on", "equals", "by", "ascending", "descending" }; + static string[] parameterTypePredecessorKeywords = new string[] { "out", "ref", "params" }; #endregion } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/CSharpCompletionEngineBase.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/CSharpCompletionEngineBase.cs index 86103a3578..4bfa2f9d46 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/CSharpCompletionEngineBase.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/CSharpCompletionEngineBase.cs @@ -1,4 +1,4 @@ -// +// // CSharpCompletionEngineBase.cs // // Author: @@ -85,120 +85,280 @@ namespace ICSharpCode.NRefactory.CSharp.Completion this.CSharpParsedFile = parsedFile; } - IUnresolvedTypeDefinition FindInnerType (IUnresolvedTypeDefinition parent, TextLocation location) + + public IMemberProvider MemberProvider { + get; + set; + } + + protected void SetOffset (int offset) { - if (parent == null) - return null; - var currentType = parent; - foreach (var type in parent.NestedTypes) { - if (type.Region.Begin < location && location < type.Region.End) - currentType = FindInnerType (type, location); - } + Reset (); - return currentType; + this.offset = offset; + this.location = document.GetLocation (offset); + var provider = MemberProvider ?? new DefaultMemberProvider (this); + provider.GetCurrentMembers (offset, out currentType, out currentMember); } - - bool IsInsideType (IUnresolvedEntity currentType, TextLocation location) + + protected bool GetParameterCompletionCommandOffset(out int cpos) { - int startOffset = document.GetOffset (currentType.Region.Begin); - int endOffset = document.GetOffset (location); - bool foundEndBracket = false; - - var bracketStack = new Stack (); + // Start calculating the parameter offset from the beginning of the + // current member, instead of the beginning of the file. + cpos = offset - 1; + var mem = currentMember; + if (mem == null || (mem is IType)) { + return false; + } + int startPos = document.GetOffset(mem.Region.BeginLine, mem.Region.BeginColumn); + int parenDepth = 0; + int chevronDepth = 0; + Stack indexStack = new Stack(); + while (cpos > startPos) { + char c = document.GetCharAt(cpos); + if (c == ')') { + parenDepth++; + } + if (c == '>') { + chevronDepth++; + } + if (c == '}') { + if (indexStack.Count > 0) { + parenDepth = indexStack.Pop(); + } else { + parenDepth = 0; + } + chevronDepth = 0; + } + if (indexStack.Count == 0 && (parenDepth == 0 && c == '(' || chevronDepth == 0 && c == '<')) { + int p = GetCurrentParameterIndex (cpos + 1, startPos); + if (p != -1) { + cpos++; + return true; + } else { + return false; + } + } + if (c == '(') { + parenDepth--; + } + if (c == '<') { + chevronDepth--; + } + if (c == '{') { + indexStack.Push (parenDepth); + chevronDepth = 0; + } + cpos--; + } + return false; + } - bool isInString = false, isInChar = false; - bool isInLineComment = false, isInBlockComment = false; + protected int GetCurrentParameterIndex (int offset, int memberStart) + { + int cursor = this.offset; + int i = offset; - for (int i = startOffset; i < endOffset; i++) { - char ch = document.GetCharAt (i); - switch (ch) { - case '(': - case '[': - case '{': - if (!isInString && !isInChar && !isInLineComment && !isInBlockComment) - bracketStack.Push (ch); - break; - case ')': - case ']': - case '}': - if (!isInString && !isInChar && !isInLineComment && !isInBlockComment) - if (bracketStack.Count > 0) - bracketStack.Pop (); - break; - case '\r': - case '\n': - isInLineComment = false; - break; - case '/': - if (isInBlockComment) { - if (i > 0 && document.GetCharAt (i - 1) == '*') - isInBlockComment = false; - } else if (!isInString && !isInChar && i + 1 < document.TextLength) { - char nextChar = document.GetCharAt (i + 1); - if (nextChar == '/') - isInLineComment = true; - if (!isInLineComment && nextChar == '*') - isInBlockComment = true; + if (i > cursor) { + return -1; + } + if (i == cursor) { + return 1; + } + // parameters are 1 based + int index = memberStart + 1; + int parentheses = 0; + int bracket = 0; + bool insideQuote = false, insideString = false, insideSingleLineComment = false, insideMultiLineComment = false; + Stack indexStack = new Stack (); + do { + char c = document.GetCharAt (i - 1); + switch (c) { + case '\\': + if (insideString || insideQuote) { + i++; + } + break; + case '\'': + if (!insideString && !insideSingleLineComment && !insideMultiLineComment) { + insideQuote = !insideQuote; + } + break; + case '"': + if (!insideQuote && !insideSingleLineComment && !insideMultiLineComment) { + insideString = !insideString; + } + break; + case '/': + if (!insideQuote && !insideString && !insideMultiLineComment) { + if (document.GetCharAt (i) == '/') { + insideSingleLineComment = true; } - break; - case '"': - if (!(isInChar || isInLineComment || isInBlockComment)) - isInString = !isInString; - break; - case '\'': - if (!(isInString || isInLineComment || isInBlockComment)) - isInChar = !isInChar; - break; - default : - break; + if (document.GetCharAt (i) == '*') { + insideMultiLineComment = true; + } + } + break; + case '*': + if (insideMultiLineComment && document.GetCharAt (i) == '/') { + insideMultiLineComment = false; + } + break; + case '\n': + case '\r': + insideSingleLineComment = false; + break; + case '{': + if (!insideQuote && !insideString && !insideSingleLineComment && !insideMultiLineComment) { + bracket++; + indexStack.Push (index); } + break; + case '}': + if (!insideQuote && !insideString && !insideSingleLineComment && !insideMultiLineComment) { + bracket--; + if (indexStack.Count > 0) + index = indexStack.Pop (); + } + break; + case '(': + if (!insideQuote && !insideString && !insideSingleLineComment && !insideMultiLineComment) { + parentheses++; + } + break; + case ')': + if (!insideQuote && !insideString && !insideSingleLineComment && !insideMultiLineComment) { + parentheses--; + } + break; + case ',': + if (!insideQuote && !insideString && !insideSingleLineComment && !insideMultiLineComment && parentheses == 1 && bracket == 0) { + index++; + } + break; + } - return bracketStack.Any (t => t == '{'); + i++; + } while (i <= cursor && parentheses >= 0); + Console.WriteLine (indexStack.Count >= 0 || parentheses != 1 || bracket > 0 ? -1 : index); + return indexStack.Count >= 0 || parentheses != 1 || bracket > 0 ? -1 : index; } - protected void SetOffset (int offset) + + #region Context helper methods + public class MiniLexer { - Reset (); - - this.offset = offset; - this.location = document.GetLocation (offset); - - this.currentType = null; - - foreach (var type in CSharpParsedFile.TopLevelTypeDefinitions) { - if (type.Region.Begin < location) - currentType = type; + readonly string text; + + public bool IsFistNonWs = true; + public bool IsInSingleComment = false; + public bool IsInString = false; + public bool IsInVerbatimString = false; + public bool IsInChar = false; + public bool IsInMultiLineComment = false; + public bool IsInPreprocessorDirective = false; + + public MiniLexer(string text) + { + this.text = text; } - currentType = FindInnerType (currentType, location); - - // location is beyond last reported end region, now we need to check, if the end region changed - if (currentType != null && currentType.Region.End < location) { - if (!IsInsideType (currentType, location)) - currentType = null; + + public void Parse(Action act = null) + { + Parse(0, text.Length, act); } - this.currentMember = null; - if (this.currentType != null) { - foreach (var member in currentType.Members) { - if (member.Region.Begin < location && (currentMember == null || currentMember.Region.Begin < member.Region.Begin)) - currentMember = member; + + public void Parse(int start, int length, Action act = null) + { + for (int i = start; i < length; i++) { + char ch = text [i]; + char nextCh = i + 1 < text.Length ? text [i + 1] : '\0'; + switch (ch) { + case '#': + if (IsFistNonWs) + IsInPreprocessorDirective = true; + break; + case '/': + if (IsInString || IsInChar || IsInVerbatimString) + break; + if (nextCh == '/') { + i++; + IsInSingleComment = true; + } + if (nextCh == '*') + IsInMultiLineComment = true; + break; + case '*': + if (IsInString || IsInChar || IsInVerbatimString || IsInSingleComment) + break; + if (nextCh == '/') { + i++; + IsInMultiLineComment = false; + } + break; + case '@': + if (IsInString || IsInChar || IsInVerbatimString || IsInSingleComment || IsInMultiLineComment) + break; + if (nextCh == '"') { + i++; + IsInVerbatimString = true; + } + break; + case '\n': + case '\r': + IsInSingleComment = false; + IsInString = false; + IsInChar = false; + IsFistNonWs = true; + break; + case '\\': + if (IsInString || IsInChar) + i++; + break; + case '"': + if (IsInSingleComment || IsInMultiLineComment || IsInChar) + break; + if (IsInVerbatimString) { + if (nextCh == '"') { + i++; + break; + } + IsInVerbatimString = false; + break; + } + IsInString = !IsInString; + break; + case '\'': + if (IsInSingleComment || IsInMultiLineComment || IsInString || IsInVerbatimString) + break; + IsInChar = !IsInChar; + break; + } + if (act != null) + act(ch); + IsFistNonWs &= ch == ' ' || ch == '\t' || ch == '\n' || ch == '\r'; } } - - // location is beyond last reported end region, now we need to check, if the end region changed - // NOTE: Enums are a special case, there the "last" field needs to be treated as current member - if (currentMember != null && currentMember.Region.End < location && currentType.Kind != TypeKind.Enum) { - if (!IsInsideType (currentMember, location)) - currentMember = null; - } - var stack = GetBracketStack (GetMemberTextToCaret ().Item1); - if (stack.Count == 0) - currentMember = null; } - - #region Context helper methods - protected bool IsInsideCommentOrString () + + protected bool IsInsideCommentStringOrDirective() + { + var text = GetMemberTextToCaret(); + var lexer = new MiniLexer(text.Item1); + lexer.Parse(); + return + lexer.IsInSingleComment || + lexer.IsInString || + lexer.IsInVerbatimString || + lexer.IsInChar || + lexer.IsInMultiLineComment || + lexer.IsInPreprocessorDirective; + } + + protected bool IsInsideDocComment () { var text = GetMemberTextToCaret (); bool inSingleComment = false, inString = false, inVerbatimString = false, inChar = false, inMultiLineComment = false; + bool singleLineIsDoc = false; for (int i = 0; i < text.Item1.Length - 1; i++) { char ch = text.Item1 [i]; @@ -211,6 +371,10 @@ namespace ICSharpCode.NRefactory.CSharp.Completion if (nextCh == '/') { i++; inSingleComment = true; + singleLineIsDoc = i + 1 < text.Item1.Length && text.Item1 [i + 1] == '/'; + if (singleLineIsDoc) { + i++; + } } if (nextCh == '*') inMultiLineComment = true; @@ -262,78 +426,115 @@ namespace ICSharpCode.NRefactory.CSharp.Completion } } - return inSingleComment || inString || inVerbatimString || inChar || inMultiLineComment; - } - - protected bool IsInsideComment (int offset) - { - var loc = document.GetLocation (offset); - return Unit.GetNodeAt (loc.Line, loc.Column) != null; + return inSingleComment && singleLineIsDoc; } - - protected bool IsInsideDocComment () - { - var loc = document.GetLocation (offset); - var cmt = Unit.GetNodeAt (loc.Line, loc.Column - 1); - return cmt != null && cmt.CommentType == CommentType.Documentation; - } - - protected bool IsInsideString (int offset) + + protected CSharpResolver GetState () { + return new CSharpResolver (ctx); + /*var state = new CSharpResolver (ctx); - var loc = document.GetLocation (offset); - var expr = Unit.GetNodeAt (loc.Line, loc.Column); - return expr != null && expr.Value is string; + state.CurrentMember = currentMember; + state.CurrentTypeDefinition = currentType; + state.CurrentUsingScope = CSharpParsedFile.GetUsingScope (location); + if (state.CurrentMember != null) { + var node = Unit.GetNodeAt (location); + if (node == null) + return state; + var navigator = new NodeListResolveVisitorNavigator (new[] { node }); + var visitor = new ResolveVisitor (state, CSharpParsedFile, navigator); + Unit.AcceptVisitor (visitor, null); + try { + var newState = visitor.GetResolverStateBefore (node); + if (newState != null) + state = newState; + } catch (Exception) { + } + } + + return state;*/ } - #endregion + #endregion #region Basic parsing/resolving functions - Stack> GetBracketStack (string memberText) + static Stack> GetBracketStack (string memberText) { var bracketStack = new Stack> (); - bool isInString = false, isInChar = false; - bool isInLineComment = false, isInBlockComment = false; + bool inSingleComment = false, inString = false, inVerbatimString = false, inChar = false, inMultiLineComment = false; - for (int pos = 0; pos < memberText.Length; pos++) { - char ch = memberText [pos]; + for (int i = 0; i < memberText.Length; i++) { + char ch = memberText [i]; + char nextCh = i + 1 < memberText.Length ? memberText [i + 1] : '\0'; switch (ch) { case '(': case '[': case '{': - if (!isInString && !isInChar && !isInLineComment && !isInBlockComment) - bracketStack.Push (Tuple.Create (ch, pos)); + if (inString || inChar || inVerbatimString || inSingleComment || inMultiLineComment) + break; + bracketStack.Push (Tuple.Create (ch, i)); break; case ')': case ']': case '}': - if (!isInString && !isInChar && !isInLineComment && !isInBlockComment) + if (inString || inChar || inVerbatimString || inSingleComment || inMultiLineComment) + break; if (bracketStack.Count > 0) bracketStack.Pop (); break; - case '\r': - case '\n': - isInLineComment = false; - break; case '/': - if (isInBlockComment) { - if (pos > 0 && memberText [pos - 1] == '*') - isInBlockComment = false; - } else if (!isInString && !isInChar && pos + 1 < memberText.Length) { - char nextChar = memberText [pos + 1]; - if (nextChar == '/') - isInLineComment = true; - if (!isInLineComment && nextChar == '*') - isInBlockComment = true; + if (inString || inChar || inVerbatimString) + break; + if (nextCh == '/') { + i++; + inSingleComment = true; } + if (nextCh == '*') + inMultiLineComment = true; + break; + case '*': + if (inString || inChar || inVerbatimString || inSingleComment) + break; + if (nextCh == '/') { + i++; + inMultiLineComment = false; + } + break; + case '@': + if (inString || inChar || inVerbatimString || inSingleComment || inMultiLineComment) + break; + if (nextCh == '"') { + i++; + inVerbatimString = true; + } + break; + case '\n': + case '\r': + inSingleComment = false; + inString = false; + inChar = false; + break; + case '\\': + if (inString || inChar) + i++; break; case '"': - if (!(isInChar || isInLineComment || isInBlockComment)) - isInString = !isInString; + if (inSingleComment || inMultiLineComment || inChar) + break; + if (inVerbatimString) { + if (nextCh == '"') { + i++; + break; + } + inVerbatimString = false; + break; + } + inString = !inString; break; case '\'': - if (!(isInString || isInLineComment || isInBlockComment)) - isInChar = !isInChar; + if (inSingleComment || inMultiLineComment || inString || inVerbatimString) + break; + inChar = !inChar; break; default : break; @@ -342,28 +543,31 @@ namespace ICSharpCode.NRefactory.CSharp.Completion return bracketStack; } - protected void AppendMissingClosingBrackets (StringBuilder wrapper, string memberText, bool appendSemicolon) + public static void AppendMissingClosingBrackets (StringBuilder wrapper, string memberText, bool appendSemicolon) { var bracketStack = GetBracketStack (memberText); bool didAppendSemicolon = !appendSemicolon; - char lastBracket = '\0'; + //char lastBracket = '\0'; while (bracketStack.Count > 0) { var t = bracketStack.Pop (); switch (t.Item1) { case '(': wrapper.Append (')'); - didAppendSemicolon = false; - lastBracket = ')'; + if (appendSemicolon) + didAppendSemicolon = false; + //lastBracket = ')'; break; case '[': wrapper.Append (']'); - didAppendSemicolon = false; - lastBracket = ']'; + if (appendSemicolon) + didAppendSemicolon = false; + //lastBracket = ']'; break; case '<': wrapper.Append ('>'); - didAppendSemicolon = false; - lastBracket = '>'; + if (appendSemicolon) + didAppendSemicolon = false; + //lastBracket = '>'; break; case '{': int o = t.Item2 - 1; @@ -389,61 +593,44 @@ namespace ICSharpCode.NRefactory.CSharp.Completion break; } } - if (currentMember == null && lastBracket == ']') { - // attribute context - wrapper.Append ("class GenAttr {}"); - } else { - if (!didAppendSemicolon) - wrapper.Append (';'); - } + if (!didAppendSemicolon) + wrapper.Append (';'); } - protected CompilationUnit ParseStub (string continuation, bool appendSemicolon = true, string afterContinuation = null) + protected CompilationUnit ParseStub(string continuation, bool appendSemicolon = true, string afterContinuation = null) { - var mt = GetMemberTextToCaret (); - if (mt == null) + var mt = GetMemberTextToCaret(); + if (mt == null) { return null; - + } + string memberText = mt.Item1; - bool wrapInClass = mt.Item2; - - var wrapper = new StringBuilder (); - + var memberLocation = mt.Item2; + int closingBrackets = 1; + int generatedLines = 0; + var wrapper = new StringBuilder(); + bool wrapInClass = memberLocation != new TextLocation(1, 1); if (wrapInClass) { -/* foreach (var child in Unit.Children) { - if (child is UsingDeclaration) { - var offset = document.GetOffset (child.StartLocation); - wrapper.Append (document.GetText (offset, document.GetOffset (child.EndLocation) - offset)); - } - }*/ - wrapper.Append ("class Stub {"); - wrapper.AppendLine (); + wrapper.Append("class Stub {"); + wrapper.AppendLine(); + closingBrackets++; + generatedLines++; } - - wrapper.Append (memberText); - wrapper.Append (continuation); - AppendMissingClosingBrackets (wrapper, memberText, appendSemicolon); - wrapper.Append (afterContinuation); - - if (wrapInClass) - wrapper.Append ('}'); - - TextLocation memberLocation; - if (currentMember != null && currentType.Kind != TypeKind.Enum) { - memberLocation = currentMember.Region.Begin; - } else if (currentType != null) { - memberLocation = currentType.Region.Begin; - } else { - memberLocation = new TextLocation (1, 1); + wrapper.Append(memberText); + wrapper.Append(continuation); + AppendMissingClosingBrackets(wrapper, memberText, appendSemicolon); + wrapper.Append(afterContinuation); + if (closingBrackets > 0) { + wrapper.Append(new string('}', closingBrackets)); } - using (var stream = new System.IO.StringReader (wrapper.ToString ())) { try { var parser = new CSharpParser (); - return parser.Parse (stream, "stub.cs", wrapInClass ? memberLocation.Line - 2 : 0); + var result = parser.Parse(stream, "stub.cs", memberLocation.Line - 1 - generatedLines); + return result; } catch (Exception) { - Console.WriteLine ("------"); - Console.WriteLine (wrapper); + Console.WriteLine("------"); + Console.WriteLine(wrapper); throw; } } @@ -456,79 +643,111 @@ namespace ICSharpCode.NRefactory.CSharp.Completion cachedText = null; } - protected Tuple GetMemberTextToCaret () + protected Tuple GetMemberTextToCaret() { int startOffset; - if (currentMember != null && currentType.Kind != TypeKind.Enum) { - startOffset = document.GetOffset (currentMember.Region.BeginLine, currentMember.Region.BeginColumn); + if (currentMember != null && currentType != null && currentType.Kind != TypeKind.Enum) { + startOffset = document.GetOffset(currentMember.Region.Begin); } else if (currentType != null) { - startOffset = document.GetOffset (currentType.Region.BeginLine, currentType.Region.BeginColumn); + startOffset = document.GetOffset(currentType.Region.Begin); } else { startOffset = 0; } while (startOffset > 0) { - char ch = document.GetCharAt (startOffset - 1); - if (ch != ' ' && ch != '\t') + char ch = document.GetCharAt(startOffset - 1); + if (ch != ' ' && ch != '\t') { break; + } --startOffset; } if (cachedText == null) cachedText = document.GetText (startOffset, offset - startOffset); - return Tuple.Create (cachedText, startOffset != 0); + return Tuple.Create (cachedText, document.GetLocation (startOffset)); } - protected Tuple GetInvocationBeforeCursor (bool afterBracket) + protected ExpressionResult GetInvocationBeforeCursor(bool afterBracket) { CompilationUnit baseUnit; - if (currentMember == null) { - baseUnit = ParseStub ("", false); - var section = baseUnit.GetNodeAt (location.Line, location.Column - 2); - var attr = section != null ? section.Attributes.LastOrDefault () : null; - if (attr != null) { - // insert target type into compilation unit, to respect the - attr.Remove (); - var node = Unit.GetNodeAt (location) ?? Unit; - node.AddChild (attr, AttributeSection.AttributeRole); - return Tuple.Create (CSharpParsedFile, (AstNode)attr, Unit); - } - } - if (currentMember == null && currentType == null) { - return null; - } - baseUnit = ParseStub (afterBracket ? "" : "x"); + baseUnit = ParseStub("a", false); - var memberLocation = currentMember != null ? currentMember.Region.Begin : currentType.Region.Begin; - var mref = baseUnit.GetNodeAt (location.Line, location.Column - 1, n => n is InvocationExpression || n is ObjectCreateExpression); + var section = baseUnit.GetNodeAt(location.Line, location.Column - 2); + var attr = section != null ? section.Attributes.LastOrDefault() : null; + if (attr != null) { + return new ExpressionResult((AstNode)attr, baseUnit); + } + + //var memberLocation = currentMember != null ? currentMember.Region.Begin : currentType.Region.Begin; + var mref = baseUnit.GetNodeAt(location.Line, location.Column - 1, n => n is InvocationExpression || n is ObjectCreateExpression); AstNode expr = null; if (mref is InvocationExpression) { expr = ((InvocationExpression)mref).Target; } else if (mref is ObjectCreateExpression) { expr = mref; } else { - baseUnit = ParseStub (")};", false); - mref = baseUnit.GetNodeAt (location.Line, location.Column - 1, n => n is InvocationExpression || n is ObjectCreateExpression); + baseUnit = ParseStub(")};", false); + mref = baseUnit.GetNodeAt(location.Line, location.Column - 1, n => n is InvocationExpression || n is ObjectCreateExpression); if (mref is InvocationExpression) { expr = ((InvocationExpression)mref).Target; } else if (mref is ObjectCreateExpression) { expr = mref; } - if (expr == null) - return null; } - var member = Unit.GetNodeAt (memberLocation); - var member2 = baseUnit.GetNodeAt (memberLocation); - member2.Remove (); - member.ReplaceWith (member2); - var tsvisitor = new TypeSystemConvertVisitor (CSharpParsedFile.FileName); - Unit.AcceptVisitor (tsvisitor, null); - return Tuple.Create (tsvisitor.ParsedFile, (AstNode)expr, Unit); + + if (expr == null) { + // work around for missing ';' bug in mcs: + baseUnit = ParseStub("a", true); + + section = baseUnit.GetNodeAt(location.Line, location.Column - 2); + attr = section != null ? section.Attributes.LastOrDefault() : null; + if (attr != null) { + return new ExpressionResult((AstNode)attr, baseUnit); + } + + //var memberLocation = currentMember != null ? currentMember.Region.Begin : currentType.Region.Begin; + mref = baseUnit.GetNodeAt(location.Line, location.Column - 1, n => n is InvocationExpression || n is ObjectCreateExpression); + expr = null; + if (mref is InvocationExpression) { + expr = ((InvocationExpression)mref).Target; + } else if (mref is ObjectCreateExpression) { + expr = mref; + } + } + + if (expr == null) { + return null; + } + return new ExpressionResult ((AstNode)expr, baseUnit); + } + + public class ExpressionResult + { + public AstNode Node { get; private set; } + public CompilationUnit Unit { get; private set; } + + + public ExpressionResult (AstNode item2, CompilationUnit item3) + { + this.Node = item2; + this.Unit = item3; + } + + public override string ToString () + { + return string.Format ("[ExpressionResult: Node={0}, Unit={1}]", Node, Unit); + } } - protected Tuple ResolveExpression (CSharpParsedFile file, AstNode expr, CompilationUnit unit) + protected Tuple ResolveExpression (ExpressionResult tuple) { - if (expr == null) + return ResolveExpression (tuple.Node, tuple.Unit); + } + + protected Tuple ResolveExpression(AstNode expr, CompilationUnit unit) + { + if (expr == null) { return null; + } AstNode resolveNode; if (expr is Expression || expr is AstType) { resolveNode = expr; @@ -537,26 +756,145 @@ namespace ICSharpCode.NRefactory.CSharp.Completion } else { resolveNode = expr; } + try { + var ctx = CSharpParsedFile.GetResolver(Compilation, location); + var root = expr.AncestorsAndSelf.FirstOrDefault(n => n is EntityDeclaration || n is CompilationUnit); + if (root == null) { + return null; + } + var csResolver = new CSharpAstResolver (ctx, root, CSharpParsedFile); + var result = csResolver.Resolve(resolveNode); + var state = csResolver.GetResolverStateBefore(resolveNode); + return Tuple.Create(result, state); + } catch (Exception e) { + Console.WriteLine(e); + return null; + } + } + + #endregion + + class DefaultMemberProvider : IMemberProvider + { + CSharpCompletionEngineBase engine; + + + public DefaultMemberProvider (CSharpCompletionEngineBase engine) + { + this.engine = engine; + } + + public void GetCurrentMembers (int offset, out IUnresolvedTypeDefinition currentType, out IUnresolvedMember currentMember) + { + //var document = engine.document; + var location = engine.location; -// var newContent = ProjectContent.UpdateProjectContent (CSharpParsedFile, file); + currentType = null; - var csResolver = new CSharpResolver (ctx); + foreach (var type in engine.CSharpParsedFile.TopLevelTypeDefinitions) { + if (type.Region.Begin < location) + currentType = type; + } + currentType = FindInnerType (currentType, location); - var navigator = new NodeListResolveVisitorNavigator (new[] { resolveNode }); - var visitor = new ResolveVisitor (csResolver, CSharpParsedFile, navigator); + // location is beyond last reported end region, now we need to check, if the end region changed + if (currentType != null && currentType.Region.End < location) { + if (!IsInsideType (currentType, location)) + currentType = null; + } + currentMember = null; + if (currentType != null) { + foreach (var member in currentType.Members) { + if (member.Region.Begin < location && (currentMember == null || currentMember.Region.Begin < member.Region.Begin)) + currentMember = member; + } + } + + // location is beyond last reported end region, now we need to check, if the end region changed + // NOTE: Enums are a special case, there the "last" field needs to be treated as current member + if (currentMember != null && currentMember.Region.End < location && currentType.Kind != TypeKind.Enum) { + if (!IsInsideType (currentMember, location)) + currentMember = null; + } + var stack = GetBracketStack (engine.GetMemberTextToCaret ().Item1); + if (stack.Count == 0) + currentMember = null; + } + + IUnresolvedTypeDefinition FindInnerType (IUnresolvedTypeDefinition parent, TextLocation location) + { + if (parent == null) + return null; + var currentType = parent; + foreach (var type in parent.NestedTypes) { + if (type.Region.Begin < location && location < type.Region.End) + currentType = FindInnerType (type, location); + } - visitor.Scan (unit); - var state = visitor.GetResolverStateBefore (resolveNode); - var result = visitor.GetResolveResult (resolveNode); - return Tuple.Create (result, state); + return currentType; } - protected static void Print (AstNode node) + bool IsInsideType (IUnresolvedEntity currentType, TextLocation location) { - var v = new CSharpOutputVisitor (Console.Out, new CSharpFormattingOptions ()); - node.AcceptVisitor (v, null); - } + var document = engine.document; + + int startOffset = document.GetOffset (currentType.Region.Begin); + int endOffset = document.GetOffset (location); + //bool foundEndBracket = false; - #endregion + var bracketStack = new Stack (); + + bool isInString = false, isInChar = false; + bool isInLineComment = false, isInBlockComment = false; + + for (int i = startOffset; i < endOffset; i++) { + char ch = document.GetCharAt (i); + switch (ch) { + case '(': + case '[': + case '{': + if (!isInString && !isInChar && !isInLineComment && !isInBlockComment) + bracketStack.Push (ch); + break; + case ')': + case ']': + case '}': + if (!isInString && !isInChar && !isInLineComment && !isInBlockComment) + if (bracketStack.Count > 0) + bracketStack.Pop (); + break; + case '\r': + case '\n': + isInLineComment = false; + break; + case '/': + if (isInBlockComment) { + if (i > 0 && document.GetCharAt (i - 1) == '*') + isInBlockComment = false; + } else if (!isInString && !isInChar && i + 1 < document.TextLength) { + char nextChar = document.GetCharAt (i + 1); + if (nextChar == '/') + isInLineComment = true; + if (!isInLineComment && nextChar == '*') + isInBlockComment = true; + } + break; + case '"': + if (!(isInChar || isInLineComment || isInBlockComment)) + isInString = !isInString; + break; + case '\'': + if (!(isInString || isInLineComment || isInBlockComment)) + isInChar = !isInChar; + break; + default : + break; + } + } + return bracketStack.Any (t => t == '{'); + } + } + + } } \ No newline at end of file diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/CSharpParameterCompletionEngine.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/CSharpParameterCompletionEngine.cs index 6ad0c84469..76c266244c 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/CSharpParameterCompletionEngine.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/CSharpParameterCompletionEngine.cs @@ -31,6 +31,7 @@ using ICSharpCode.NRefactory.Semantics; using ICSharpCode.NRefactory.TypeSystem; using ICSharpCode.NRefactory.CSharp.Resolver; using ICSharpCode.NRefactory.CSharp.TypeSystem; +using System.Linq; namespace ICSharpCode.NRefactory.CSharp.Completion { @@ -38,26 +39,31 @@ namespace ICSharpCode.NRefactory.CSharp.Completion { internal IParameterCompletionDataFactory factory; - public CSharpParameterCompletionEngine (IDocument document, IParameterCompletionDataFactory factory, IProjectContent content, CSharpTypeResolveContext ctx, CompilationUnit unit, CSharpParsedFile parsedFile) : base (content, ctx, unit, parsedFile) + public CSharpParameterCompletionEngine(IDocument document, IParameterCompletionDataFactory factory, IProjectContent content, CSharpTypeResolveContext ctx, CompilationUnit unit, CSharpParsedFile parsedFile) : base (content, ctx, unit, parsedFile) { - if (document == null) - throw new ArgumentNullException ("document"); - if (factory == null) - throw new ArgumentNullException ("factory"); + if (document == null) { + throw new ArgumentNullException("document"); + } + if (factory == null) { + throw new ArgumentNullException("factory"); + } this.document = document; this.factory = factory; } - public Tuple GetIndexerBeforeCursor () + public ExpressionResult GetIndexerBeforeCursor() { CompilationUnit baseUnit; - if (currentMember == null && currentType == null) + if (currentMember == null && currentType == null) { + return null; + } + if (Unit == null) { return null; - baseUnit = ParseStub ("x] = a[1"); + } + baseUnit = ParseStub("x] = a[1"); - var memberLocation = currentMember != null ? currentMember.Region.Begin : currentType.Region.Begin; - var mref = baseUnit.GetNodeAt (location, n => n is IndexerExpression); - Print (baseUnit); + //var memberLocation = currentMember != null ? currentMember.Region.Begin : currentType.Region.Begin; + var mref = baseUnit.GetNodeAt(location, n => n is IndexerExpression); AstNode expr; if (mref is IndexerExpression) { expr = ((IndexerExpression)mref).Target; @@ -65,58 +71,138 @@ namespace ICSharpCode.NRefactory.CSharp.Completion return null; } - var member = Unit.GetNodeAt (memberLocation); - var member2 = baseUnit.GetNodeAt (memberLocation); - member2.Remove (); - member.ReplaceWith (member2); - var tsvisitor = new TypeSystemConvertVisitor (CSharpParsedFile.FileName); - Unit.AcceptVisitor (tsvisitor, null); - return Tuple.Create (tsvisitor.ParsedFile, (AstNode)expr, Unit); + return new ExpressionResult((AstNode)expr, baseUnit); } - public IParameterDataProvider GetParameterDataProvider (int offset, char completionChar) + public ExpressionResult GetConstructorInitializerBeforeCursor() { - if (offset <= 0) + CompilationUnit baseUnit; + if (currentMember == null && currentType == null) { return null; - if (completionChar != '(' && completionChar != '<' && completionChar != '[' && completionChar != ',') + } + if (Unit == null) { return null; + } + baseUnit = ParseStub("a) {}", false); - SetOffset (offset); - if (IsInsideCommentOrString ()) + var expr = baseUnit.GetNodeAt (location); + if (expr == null) { return null; + } + return new ExpressionResult((AstNode)expr, baseUnit); + } + + public ExpressionResult GetTypeBeforeCursor() + { + CompilationUnit baseUnit; + if (currentMember == null && currentType == null) { + return null; + } + if (Unit == null) { + return null; + } + baseUnit = ParseStub("x> a"); - var invoke = GetInvocationBeforeCursor (true) ?? GetIndexerBeforeCursor (); - if (invoke == null) + //var memberLocation = currentMember != null ? currentMember.Region.Begin : currentType.Region.Begin; + var expr = baseUnit.GetNodeAt(location.Line, location.Column + 1); + if (expr == null) return null; + // '>' position + return new ExpressionResult((AstNode)expr, baseUnit); + } + + IEnumerable CollectMethods(AstNode resolvedNode, MethodGroupResolveResult resolveResult) + { + // var lookup = new MemberLookup (ctx.CurrentTypeDefinition, Compilation.MainAssembly); + bool onlyStatic = false; + if (resolvedNode is IdentifierExpression && currentMember != null && currentMember.IsStatic) { + onlyStatic = true; + } + foreach (var method in resolveResult.Methods) { + if (method.IsConstructor) { + continue; + } + // if (!lookup.IsAccessible (member, true)) + // continue; + if (onlyStatic && !method.IsStatic) { + continue; + } + yield return method; + } + + foreach (var extMethods in resolveResult.GetExtensionMethods ()) { + foreach (var method in extMethods) { + yield return method; + } + } + } + + public IParameterDataProvider GetParameterDataProvider(int offset, char completionChar) + { + if (offset <= 0) { + return null; + } + if (completionChar != '(' && completionChar != '<' && completionChar != '[' && completionChar != ',') { + return null; + } + + SetOffset(offset); + if (IsInsideCommentStringOrDirective()) { + return null; + } + ResolveResult resolveResult; switch (completionChar) { - case '(': - if (invoke.Item2 is ObjectCreateExpression) { - var createType = ResolveExpression (invoke.Item1, ((ObjectCreateExpression)invoke.Item2).Type, invoke.Item3); - return factory.CreateConstructorProvider (createType.Item1.Type); - } + case '(': + var invoke = GetInvocationBeforeCursor(true) ?? GetConstructorInitializerBeforeCursor(); + if (invoke == null) { + return null; + } + if (invoke.Node is ConstructorInitializer) { + var init = (ConstructorInitializer)invoke.Node; + if (init.ConstructorInitializerType == ConstructorInitializerType.This) { + return factory.CreateConstructorProvider(document.GetOffset(invoke.Node.StartLocation), ctx.CurrentTypeDefinition); + } else { + var baseType = ctx.CurrentTypeDefinition.DirectBaseTypes.FirstOrDefault(bt => bt.Kind != TypeKind.Interface); + if (baseType == null) { + return null; + } + return factory.CreateConstructorProvider(document.GetOffset(invoke.Node.StartLocation), baseType); + } + } + if (invoke.Node is ObjectCreateExpression) { + var createType = ResolveExpression(((ObjectCreateExpression)invoke.Node).Type, invoke.Unit); + if (createType.Item1.Type.Kind == TypeKind.Unknown) + return null; + return factory.CreateConstructorProvider(document.GetOffset(invoke.Node.StartLocation), createType.Item1.Type); + } - if (invoke.Item2 is ICSharpCode.NRefactory.CSharp.Attribute) { - var attribute = ResolveExpression (invoke.Item1, invoke.Item2, invoke.Item3); - if (attribute == null || attribute.Item1 == null) + if (invoke.Node is ICSharpCode.NRefactory.CSharp.Attribute) { + var attribute = ResolveExpression(invoke); + if (attribute == null || attribute.Item1 == null) { + return null; + } + return factory.CreateConstructorProvider(document.GetOffset(invoke.Node.StartLocation), attribute.Item1.Type); + } + var invocationExpression = ResolveExpression(invoke); + if (invocationExpression == null || invocationExpression.Item1 == null || invocationExpression.Item1.IsError) { return null; - return factory.CreateConstructorProvider (attribute.Item1.Type); - } - var invocationExpression = ResolveExpression (invoke.Item1, invoke.Item2, invoke.Item3); - if (invocationExpression == null || invocationExpression.Item1 == null || invocationExpression.Item1.IsError) - return null; - resolveResult = invocationExpression.Item1; - if (resolveResult is MethodGroupResolveResult) - return factory.CreateMethodDataProvider (resolveResult as MethodGroupResolveResult); - if (resolveResult is MemberResolveResult) { - var mr = resolveResult as MemberResolveResult; - if (mr.Member is IMethod) - return factory.CreateMethodDataProvider ((IMethod)mr.Member); - } + } + resolveResult = invocationExpression.Item1; + if (resolveResult is MethodGroupResolveResult) { + return factory.CreateMethodDataProvider(document.GetOffset(invoke.Node.StartLocation), CollectMethods(invoke.Node, resolveResult as MethodGroupResolveResult)); + } + if (resolveResult is MemberResolveResult) { + var mr = resolveResult as MemberResolveResult; + if (mr.Member is IMethod) { + return factory.CreateMethodDataProvider(document.GetOffset(invoke.Node.StartLocation), new [] { (IMethod)mr.Member }); + } + } - if (resolveResult.Type.Kind == TypeKind.Delegate) - return factory.CreateDelegateDataProvider (resolveResult.Type); + if (resolveResult.Type.Kind == TypeKind.Delegate) { + return factory.CreateDelegateDataProvider(document.GetOffset(invoke.Node.StartLocation), resolveResult.Type); + } // // if (result.ExpressionContext == ExpressionContext.BaseConstructorCall) { @@ -129,202 +215,264 @@ namespace ICSharpCode.NRefactory.CSharp.Completion // if (resolvedType != null && resolvedType.ClassType == ClassType.Delegate) { // return new NRefactoryParameterDataProvider (textEditorData, result.Expression, resolvedType); // } - break; - case ',': - if (invoke.Item2 is ObjectCreateExpression) { - var createType = ResolveExpression (invoke.Item1, ((ObjectCreateExpression)invoke.Item2).Type, invoke.Item3); - return factory.CreateConstructorProvider (createType.Item1.Type); - } - - if (invoke.Item2 is ICSharpCode.NRefactory.CSharp.Attribute) { - var attribute = ResolveExpression (invoke.Item1, invoke.Item2, invoke.Item3); - if (attribute == null || attribute.Item1 == null) + break; + case ',': + invoke = GetInvocationBeforeCursor(true) ?? GetIndexerBeforeCursor(); + if (invoke == null) { + invoke = GetTypeBeforeCursor(); + if (invoke != null) { + if (GetCurrentParameterIndex(document.GetOffset(invoke.Node.StartLocation), offset) < 0) + return null; + var typeExpression = ResolveExpression(invoke); + if (typeExpression == null || typeExpression.Item1 == null || typeExpression.Item1.IsError) { + return null; + } + + return factory.CreateTypeParameterDataProvider(document.GetOffset(invoke.Node.StartLocation), CollectAllTypes(typeExpression.Item1.Type)); + } return null; - return factory.CreateConstructorProvider (attribute.Item1.Type); - } + } + if (GetCurrentParameterIndex(document.GetOffset(invoke.Node.StartLocation), offset) < 0) + return null; + if (invoke.Node is ObjectCreateExpression) { + var createType = ResolveExpression(((ObjectCreateExpression)invoke.Node).Type, invoke.Unit); + return factory.CreateConstructorProvider(document.GetOffset(invoke.Node.StartLocation), createType.Item1.Type); + } - invocationExpression = ResolveExpression (invoke.Item1, invoke.Item2, invoke.Item3); + if (invoke.Node is ICSharpCode.NRefactory.CSharp.Attribute) { + var attribute = ResolveExpression(invoke); + if (attribute == null || attribute.Item1 == null) { + return null; + } + return factory.CreateConstructorProvider(document.GetOffset(invoke.Node.StartLocation), attribute.Item1.Type); + } - if (invocationExpression == null || invocationExpression.Item1 == null || invocationExpression.Item1.IsError) - return null; + invocationExpression = ResolveExpression(invoke); - resolveResult = invocationExpression.Item1; - if (resolveResult is MethodGroupResolveResult) - return factory.CreateMethodDataProvider (resolveResult as MethodGroupResolveResult); - if (resolveResult is MemberResolveResult) { - if (resolveResult.Type.Kind == TypeKind.Delegate) - return factory.CreateDelegateDataProvider (resolveResult.Type); - var mr = resolveResult as MemberResolveResult; - if (mr.Member is IMethod) - return factory.CreateMethodDataProvider ((IMethod)mr.Member); - } - if (resolveResult != null) - return factory.CreateIndexerParameterDataProvider (resolveResult.Type, invoke.Item2); - break; -// case '<': -// if (string.IsNullOrEmpty (result.Expression)) -// return null; -// return new NRefactoryTemplateParameterDataProvider (textEditorData, resolver, GetUsedNamespaces (), result, new TextLocation (completionContext.TriggerLine, completionContext.TriggerLineOffset)); + if (invocationExpression == null || invocationExpression.Item1 == null || invocationExpression.Item1.IsError) { + return null; + } + + resolveResult = invocationExpression.Item1; + if (resolveResult is MethodGroupResolveResult) { + return factory.CreateMethodDataProvider(document.GetOffset(invoke.Node.StartLocation), CollectMethods(invoke.Node, resolveResult as MethodGroupResolveResult)); + } + if (resolveResult is MemberResolveResult) { + if (resolveResult.Type.Kind == TypeKind.Delegate) { + return factory.CreateDelegateDataProvider(document.GetOffset(invoke.Node.StartLocation), resolveResult.Type); + } + var mr = resolveResult as MemberResolveResult; + if (mr.Member is IMethod) { + return factory.CreateMethodDataProvider(document.GetOffset(invoke.Node.StartLocation), new [] { (IMethod)mr.Member }); + } + } + if (resolveResult != null) { + return factory.CreateIndexerParameterDataProvider(document.GetOffset(invoke.Node.StartLocation), resolveResult.Type, invoke.Node); + } + break; + case '<': + invoke = GetTypeBeforeCursor(); + if (invoke == null) { + return null; + } + var tExpr = ResolveExpression(invoke); + if (tExpr == null || tExpr.Item1 == null || tExpr.Item1.IsError) { + return null; + } - case '[': - var indexerExpression = ResolveExpression (invoke.Item1, invoke.Item2, invoke.Item3); - if (indexerExpression == null || indexerExpression.Item1 == null || indexerExpression.Item1.IsError) - return null; - return factory.CreateIndexerParameterDataProvider (indexerExpression.Item1.Type, invoke.Item2); + return factory.CreateTypeParameterDataProvider(document.GetOffset(invoke.Node.StartLocation), CollectAllTypes(tExpr.Item1.Type)); + case '[': + invoke = GetIndexerBeforeCursor(); + if (invoke == null) { + return null; + } + var indexerExpression = ResolveExpression(invoke); + if (indexerExpression == null || indexerExpression.Item1 == null || indexerExpression.Item1.IsError) { + return null; + } + return factory.CreateIndexerParameterDataProvider(document.GetOffset(invoke.Node.StartLocation), indexerExpression.Item1.Type, invoke.Node); } return null; } - List GetUsedNamespaces () + IEnumerable CollectAllTypes(IType baseType) + { + var state = GetState(); + for (var n = state.CurrentUsingScope; n != null; n = n.Parent) { + foreach (var u in n.Usings) { + foreach (var type in u.Types) { + if (type.TypeParameterCount > 0 && type.Name == baseType.Name) { + yield return type; + } + } + } + + foreach (var type in n.Namespace.Types) { + if (type.TypeParameterCount > 0 && type.Name == baseType.Name) { + yield return type; + } + } + } + } + + List GetUsedNamespaces() { - var scope = CSharpParsedFile.GetUsingScope (location); - var result = new List (); - var resolver = new CSharpResolver (ctx); + var scope = CSharpParsedFile.GetUsingScope(location); + var result = new List(); + var resolver = new CSharpResolver(ctx); while (scope != null) { - result.Add (scope.NamespaceName); + result.Add(scope.NamespaceName); foreach (var u in scope.Usings) { - var ns = u.ResolveNamespace (resolver); - if (ns == null) + var ns = u.ResolveNamespace(resolver); + if (ns == null) { continue; - result.Add (ns.FullName); + } + result.Add(ns.FullName); } scope = scope.Parent; } return result; } - public int GetCurrentParameterIndex (int triggerOffset) + public int GetCurrentParameterIndex(int triggerOffset, int endOffset) { - SetOffset (triggerOffset); - var text = GetMemberTextToCaret (); - if (text.Item1.EndsWith ("(")) + char lastChar = document.GetCharAt(endOffset - 1); + if (lastChar == '(' || lastChar == '<') { return 0; - var parameter = new Stack (); - + } + var parameter = new Stack(); + var bracketStack = new Stack>(); bool inSingleComment = false, inString = false, inVerbatimString = false, inChar = false, inMultiLineComment = false; - - for (int i = 0; i < text.Item1.Length; i++) { - char ch = text.Item1 [i]; - char nextCh = i + 1 < text.Item1.Length ? text.Item1 [i + 1] : '\0'; - + for (int i = triggerOffset; i < endOffset; i++) { + char ch = document.GetCharAt(i); + char nextCh = i + 1 < document.TextLength ? document.GetCharAt(i + 1) : '\0'; switch (ch) { - case '(': - if (inString || inChar || inVerbatimString || inSingleComment || inMultiLineComment) + case '{': + if (inString || inChar || inVerbatimString || inSingleComment || inMultiLineComment) { + break; + } + bracketStack.Push(parameter); + parameter = new Stack(); break; - parameter.Push (0); - break; - case ')': - if (inString || inChar || inVerbatimString || inSingleComment || inMultiLineComment) + case '[': + case '(': + if (inString || inChar || inVerbatimString || inSingleComment || inMultiLineComment) { + break; + } + parameter.Push(0); break; - if (parameter.Count > 0) - parameter.Pop (); - break; - case ',': - if (inString || inChar || inVerbatimString || inSingleComment || inMultiLineComment) + case '}': + if (inString || inChar || inVerbatimString || inSingleComment || inMultiLineComment) { + break; + } + if (bracketStack.Count > 0) { + parameter = bracketStack.Pop(); + } else { + return -1; + } break; - if (parameter.Count > 0) - parameter.Push (parameter.Pop () + 1); - break; - case '/': - if (inString || inChar || inVerbatimString) + case ']': + case ')': + if (inString || inChar || inVerbatimString || inSingleComment || inMultiLineComment) { + break; + } + if (parameter.Count > 0) { + parameter.Pop(); + } else { + return -1; + } break; - if (nextCh == '/') { - i++; - inSingleComment = true; - } - if (nextCh == '*') - inMultiLineComment = true; - break; - case '*': - if (inString || inChar || inVerbatimString || inSingleComment) + case '<': + if (inString || inChar || inVerbatimString || inSingleComment || inMultiLineComment) { + break; + } + parameter.Push(0); break; - if (nextCh == '/') { - i++; - inMultiLineComment = false; - } - break; - case '@': - if (inString || inChar || inVerbatimString || inSingleComment || inMultiLineComment) + case '>': + if (inString || inChar || inVerbatimString || inSingleComment || inMultiLineComment) { + break; + } + if (parameter.Count > 0) { + parameter.Pop(); + } break; - if (nextCh == '"') { - i++; - inVerbatimString = true; - } - break; - case '\n': - case '\r': - inSingleComment = false; - inString = false; - inChar = false; - break; - case '\\': - if (inString || inChar) - i++; - break; - case '"': - if (inSingleComment || inMultiLineComment || inChar) + case ',': + if (inString || inChar || inVerbatimString || inSingleComment || inMultiLineComment) { + break; + } + if (parameter.Count > 0) { + parameter.Push(parameter.Pop() + 1); + } + break; + case '/': + if (inString || inChar || inVerbatimString) { + break; + } + if (nextCh == '/') { + i++; + inSingleComment = true; + } + if (nextCh == '*') { + inMultiLineComment = true; + } + break; + case '*': + if (inString || inChar || inVerbatimString || inSingleComment) { + break; + } + if (nextCh == '/') { + i++; + inMultiLineComment = false; + } break; - if (inVerbatimString) { + case '@': + if (inString || inChar || inVerbatimString || inSingleComment || inMultiLineComment) { + break; + } if (nextCh == '"') { i++; + inVerbatimString = true; + } + break; + case '\n': + case '\r': + inSingleComment = false; + inString = false; + inChar = false; + break; + case '\\': + if (inString || inChar) { + i++; + } + break; + case '"': + if (inSingleComment || inMultiLineComment || inChar) { break; } - inVerbatimString = false; + if (inVerbatimString) { + if (nextCh == '"') { + i++; + break; + } + inVerbatimString = false; + break; + } + inString = !inString; break; - } - inString = !inString; - break; - case '\'': - if (inSingleComment || inMultiLineComment || inString || inVerbatimString) + case '\'': + if (inSingleComment || inMultiLineComment || inString || inVerbatimString) { + break; + } + inChar = !inChar; break; - inChar = !inChar; - break; } } - if (parameter.Count == 0) + if (parameter.Count == 0 || bracketStack.Count > 0) { return -1; - return parameter.Pop () + 1; - } - - /* - public override bool GetParameterCompletionCommandOffset (out int cpos) - { - // Start calculating the parameter offset from the beginning of the - // current member, instead of the beginning of the file. - cpos = textEditorData.Caret.Offset - 1; - var parsedDocument = Document.ParsedDocument; - if (parsedDocument == null) - return false; - IMember mem = currentMember; - if (mem == null || (mem is IType)) - return false; - int startPos = textEditorData.LocationToOffset (mem.Region.BeginLine, mem.Region.BeginColumn); - int parenDepth = 0; - int chevronDepth = 0; - while (cpos > startPos) { - char c = textEditorData.GetCharAt (cpos); - if (c == ')') - parenDepth++; - if (c == '>') - chevronDepth++; - if (parenDepth == 0 && c == '(' || chevronDepth == 0 && c == '<') { - int p = MethodParameterDataProvider.GetCurrentParameterIndex (CompletionWidget, cpos + 1, startPos); - if (p != -1) { - cpos++; - return true; - } else { - return false; - } - } - if (c == '(') - parenDepth--; - if (c == '<') - chevronDepth--; - cpos--; } - return false; - }*/ + return parameter.Pop() + 1; + } } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/ICompletionDataFactory.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/ICompletionDataFactory.cs index e2647f32cb..fe367f4eb0 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/ICompletionDataFactory.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/ICompletionDataFactory.cs @@ -63,6 +63,7 @@ namespace ICSharpCode.NRefactory.CSharp.Completion ICompletionData CreateEventCreationCompletionData (string varName, IType delegateType, IEvent evt, string parameterDefinition, IUnresolvedMember currentMember, IUnresolvedTypeDefinition currentType); ICompletionData CreateNewOverrideCompletionData (int declarationBegin, IUnresolvedTypeDefinition type, IMember m); + ICompletionData CreateNewPartialCompletionData (int declarationBegin, IUnresolvedTypeDefinition type, IUnresolvedMember m); IEnumerable CreateCodeTemplateCompletionData (); diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CreateLinkAction.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/IMemberProvider.cs similarity index 72% rename from src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CreateLinkAction.cs rename to src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/IMemberProvider.cs index 11212a1c9a..689fe96148 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CreateLinkAction.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/IMemberProvider.cs @@ -1,10 +1,10 @@ // -// CreateLinkAction.cs +// IMemberProvider.cs // // Author: -// Mike Krüger +// Mike Krüger // -// Copyright (c) 2011 Mike Krüger +// Copyright (c) 2012 Xamarin Inc. // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal @@ -25,20 +25,16 @@ // THE SOFTWARE. using System; using System.Collections.Generic; +using ICSharpCode.NRefactory.TypeSystem; +using ICSharpCode.NRefactory.Editor; +using ICSharpCode.NRefactory.CSharp.TypeSystem; +using System.Linq; -namespace ICSharpCode.NRefactory.CSharp.Refactoring +namespace ICSharpCode.NRefactory.CSharp.Completion { - public abstract class CreateLinkAction : Action + public interface IMemberProvider { - public IEnumerable Linked { - get; - private set; - } - - public CreateLinkAction (IEnumerable linked) - { - this.Linked = linked; - } + void GetCurrentMembers (int offset, out IUnresolvedTypeDefinition currentType, out IUnresolvedMember currentMember); } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/IParameterCompletionDataFactory.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/IParameterCompletionDataFactory.cs index 56321bdb18..54ebe1c84e 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/IParameterCompletionDataFactory.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Completion/IParameterCompletionDataFactory.cs @@ -27,20 +27,21 @@ using System; using ICSharpCode.NRefactory.TypeSystem; using ICSharpCode.NRefactory.Completion; using ICSharpCode.NRefactory.CSharp.Resolver; +using System.Collections.Generic; namespace ICSharpCode.NRefactory.CSharp.Completion { public interface IParameterCompletionDataFactory { - IParameterDataProvider CreateConstructorProvider (IType type); + IParameterDataProvider CreateConstructorProvider (int startOffset, IType type); - IParameterDataProvider CreateMethodDataProvider (MethodGroupResolveResult par1); + IParameterDataProvider CreateMethodDataProvider (int startOffset, IEnumerable methods); - IParameterDataProvider CreateMethodDataProvider (IMethod method); - - IParameterDataProvider CreateDelegateDataProvider (IType type); + IParameterDataProvider CreateDelegateDataProvider (int startOffset, IType type); + + IParameterDataProvider CreateIndexerParameterDataProvider (int startOffset, IType type, AstNode resolvedNode); - IParameterDataProvider CreateIndexerParameterDataProvider (IType type, AstNode resolvedNode); + IParameterDataProvider CreateTypeParameterDataProvider (int startOffset, IEnumerable types); } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/AstFormattingVisitor.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/AstFormattingVisitor.cs index d4f7fef6ea..a47de80581 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/AstFormattingVisitor.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/AstFormattingVisitor.cs @@ -1,6 +1,6 @@ -// +// // AstFormattingVisitor.cs -// +// // Author: // Mike Krüger // @@ -24,6 +24,7 @@ // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN // THE SOFTWARE. using System; +using System.Diagnostics; using System.Text; using System.Collections.Generic; using System.Linq; @@ -33,33 +34,61 @@ using ICSharpCode.NRefactory.CSharp.Refactoring; namespace ICSharpCode.NRefactory.CSharp { - public class AstFormattingVisitor : DepthFirstAstVisitor - { - CSharpFormattingOptions policy; - IDocument document; - IActionFactory factory; - List changes = new List (); - Indent curIndent = new Indent (); + public enum FormattingMode { + OnTheFly, + Intrusive + } - public int IndentLevel { - get { - return curIndent.Level; + public class AstFormattingVisitor : DepthFirstAstVisitor + { + sealed class TextReplaceAction + { + internal readonly int Offset; + internal readonly int RemovalLength; + internal readonly string NewText; + internal TextReplaceAction DependsOn; + +#if DEBUG + internal readonly string StackTrace; +#endif + + public TextReplaceAction (int offset, int removalLength, string newText) + { + this.Offset = offset; + this.RemovalLength = removalLength; + this.NewText = newText ?? string.Empty; + #if DEBUG + this.StackTrace = Environment.StackTrace; + #endif } - set { - curIndent.Level = value; + + public override bool Equals(object obj) + { + TextReplaceAction other = obj as TextReplaceAction; + if (other == null) { + return false; + } + return this.Offset == other.Offset && this.RemovalLength == other.RemovalLength && this.NewText == other.NewText; + } + + public override int GetHashCode() + { + return 0; } - } - - public int CurrentSpaceIndents { - get; - set; - } - public List Changes { - get { return this.changes; } + public override string ToString() + { + return string.Format("[TextReplaceAction: Offset={0}, RemovalLength={1}, NewText={2}]", Offset, RemovalLength, NewText); + } } - - public bool CorrectBlankLines { + + CSharpFormattingOptions policy; + IDocument document; + List changes = new List (); + Indent curIndent; + readonly TextEditorOptions options; + + public FormattingMode FormattingMode { get; set; } @@ -69,206 +98,286 @@ namespace ICSharpCode.NRefactory.CSharp set; } - public string EolMarker { get; set; } - - public AstFormattingVisitor (CSharpFormattingOptions policy, IDocument document, IActionFactory factory, - bool tabsToSpaces = false, int indentationSize = 4) + public AstFormattingVisitor(CSharpFormattingOptions policy, IDocument document, TextEditorOptions options = null) { - if (factory == null) - throw new ArgumentNullException ("factory"); + if (policy == null) { + throw new ArgumentNullException("policy"); + } + if (document == null) { + throw new ArgumentNullException("document"); + } this.policy = policy; this.document = document; - this.curIndent.TabsToSpaces = tabsToSpaces; - this.curIndent.TabSize = indentationSize; - this.factory = factory; - this.EolMarker = Environment.NewLine; - CorrectBlankLines = true; + this.options = options ?? TextEditorOptions.Default; + curIndent = new Indent(this.options); + } + + /// + /// Applies the changes to the input document. + /// + public void ApplyChanges() + { + ApplyChanges(0, document.TextLength, document.Replace, (o, l, v) => document.GetText(o, l) == v); + } + + public void ApplyChanges(int startOffset, int length) + { + ApplyChanges(startOffset, length, document.Replace, (o, l, v) => document.GetText(o, l) == v); + } + + /// + /// Applies the changes to the given Script instance. + /// + public void ApplyChanges(Script script) + { + ApplyChanges(0, document.TextLength, script.Replace); + } + + public void ApplyChanges(int startOffset, int length, Script script) + { + ApplyChanges(startOffset, length, script.Replace); + } + + public void ApplyChanges(int startOffset, int length, Action documentReplace, Func filter = null) + { + int endOffset = startOffset + length; + TextReplaceAction previousChange = null; + int delta = 0; + var depChanges = new List (); + foreach (var change in changes.OrderBy(c => c.Offset)) { + if (previousChange != null) { + if (change.Equals(previousChange)) { + // ignore duplicate changes + continue; + } + if (change.Offset < previousChange.Offset + previousChange.RemovalLength) { + #if DEBUG + Console.WriteLine ("change 1:" + change); + Console.WriteLine (change.StackTrace); + + Console.WriteLine ("change 2:" + change); + Console.WriteLine (previousChange.StackTrace); + #endif + throw new InvalidOperationException ("Detected overlapping changes " + change + "/" + previousChange); + } + } + previousChange = change; + + bool skipChange = change.Offset < startOffset || change.Offset > endOffset; + skipChange |= filter != null && filter(change.Offset + delta, change.RemovalLength, change.NewText); + skipChange &= !depChanges.Contains(change); + + if (!skipChange) { + documentReplace(change.Offset + delta, change.RemovalLength, change.NewText); + delta += change.NewText.Length - change.RemovalLength; + if (change.DependsOn != null) { + depChanges.Add(change.DependsOn); + } + } + } + changes.Clear(); } - public override object VisitCompilationUnit (CompilationUnit unit, object data) + public override void VisitCompilationUnit(CompilationUnit unit) { - base.VisitCompilationUnit (unit, data); - return null; + base.VisitCompilationUnit(unit); } - public void EnsureBlankLinesAfter (AstNode node, int blankLines) + public void EnsureBlankLinesAfter(AstNode node, int blankLines) { - if (!CorrectBlankLines) + if (FormattingMode != FormattingMode.Intrusive) return; var loc = node.EndLocation; int line = loc.Line; do { line++; } while (line < document.LineCount && IsSpacing(document.GetLineByNumber(line))); - var start = document.GetOffset (node.EndLocation); + var start = document.GetOffset(node.EndLocation); int foundBlankLines = line - loc.Line - 1; - StringBuilder sb = new StringBuilder (); - for (int i = 0; i < blankLines - foundBlankLines; i++) - sb.Append (this.EolMarker); + StringBuilder sb = new StringBuilder(); + for (int i = 0; i < blankLines - foundBlankLines; i++) { + sb.Append(this.options.EolMarker); + } int ws = start; - while (ws < document.TextLength && IsSpacing (document.GetCharAt (ws))) + while (ws < document.TextLength && IsSpacing (document.GetCharAt (ws))) { ws++; + } int removedChars = ws - start; if (foundBlankLines > blankLines) { - removedChars += document.GetLineByNumber (loc.Line + foundBlankLines - blankLines).EndOffset - - document.GetLineByNumber (loc.Line).EndOffset; + removedChars += document.GetLineByNumber(loc.Line + foundBlankLines - blankLines).EndOffset + - document.GetLineByNumber(loc.Line).EndOffset; } - AddChange (start, removedChars, sb.ToString ()); + AddChange(start, removedChars, sb.ToString()); } - public void EnsureBlankLinesBefore (AstNode node, int blankLines) + public void EnsureBlankLinesBefore(AstNode node, int blankLines) { - if (!CorrectBlankLines) + if (FormattingMode != FormattingMode.Intrusive) return; var loc = node.StartLocation; int line = loc.Line; do { line--; } while (line > 0 && IsSpacing(document.GetLineByNumber(line))); - int end = document.GetOffset (loc.Line, 1); - int start = document.GetOffset (line + 1, 1); + int end = document.GetOffset(loc.Line, 1); + int start = document.GetOffset(line + 1, 1); StringBuilder sb = new StringBuilder (); - for (int i = 0; i < blankLines; i++) - sb.Append (this.EolMarker); - AddChange (start, end - start, sb.ToString ()); + for (int i = 0; i < blankLines; i++) { + sb.Append(this.options.EolMarker); + } + AddChange(start, end - start, sb.ToString()); } - public override object VisitUsingDeclaration (UsingDeclaration usingDeclaration, object data) + public override void VisitUsingDeclaration(UsingDeclaration usingDeclaration) { - if (!(usingDeclaration.PrevSibling is UsingDeclaration || usingDeclaration.PrevSibling is UsingAliasDeclaration)) - EnsureBlankLinesBefore (usingDeclaration, policy.BlankLinesBeforeUsings); - if (!(usingDeclaration.NextSibling is UsingDeclaration || usingDeclaration.NextSibling is UsingAliasDeclaration)) - EnsureBlankLinesAfter (usingDeclaration, policy.BlankLinesAfterUsings); - - return null; + if (!(usingDeclaration.PrevSibling is UsingDeclaration || usingDeclaration.PrevSibling is UsingAliasDeclaration)) { + EnsureBlankLinesBefore(usingDeclaration, policy.BlankLinesBeforeUsings); + } + if (!(usingDeclaration.NextSibling is UsingDeclaration || usingDeclaration.NextSibling is UsingAliasDeclaration)) { + EnsureBlankLinesAfter(usingDeclaration, policy.BlankLinesAfterUsings); + } } - public override object VisitUsingAliasDeclaration (UsingAliasDeclaration usingDeclaration, object data) + public override void VisitUsingAliasDeclaration(UsingAliasDeclaration usingDeclaration) { - if (!(usingDeclaration.PrevSibling is UsingDeclaration || usingDeclaration.PrevSibling is UsingAliasDeclaration)) - EnsureBlankLinesBefore (usingDeclaration, policy.BlankLinesBeforeUsings); - if (!(usingDeclaration.NextSibling is UsingDeclaration || usingDeclaration.NextSibling is UsingAliasDeclaration)) - EnsureBlankLinesAfter (usingDeclaration, policy.BlankLinesAfterUsings); - return null; + if (!(usingDeclaration.PrevSibling is UsingDeclaration || usingDeclaration.PrevSibling is UsingAliasDeclaration)) { + EnsureBlankLinesBefore(usingDeclaration, policy.BlankLinesBeforeUsings); + } + if (!(usingDeclaration.NextSibling is UsingDeclaration || usingDeclaration.NextSibling is UsingAliasDeclaration)) { + EnsureBlankLinesAfter(usingDeclaration, policy.BlankLinesAfterUsings); + } } - public override object VisitNamespaceDeclaration (NamespaceDeclaration namespaceDeclaration, object data) + public override void VisitNamespaceDeclaration(NamespaceDeclaration namespaceDeclaration) { - var firstNsMember = namespaceDeclaration.Members.FirstOrDefault (); - if (firstNsMember != null) - EnsureBlankLinesBefore (firstNsMember, policy.BlankLinesBeforeFirstDeclaration); - FixIndentationForceNewLine (namespaceDeclaration.StartLocation); - EnforceBraceStyle (policy.NamespaceBraceStyle, namespaceDeclaration.LBraceToken, namespaceDeclaration.RBraceToken); - if (policy.IndentNamespaceBody) - IndentLevel++; - object result = base.VisitNamespaceDeclaration (namespaceDeclaration, data); - if (policy.IndentNamespaceBody) - IndentLevel--; - FixIndentation (namespaceDeclaration.RBraceToken.StartLocation); - return result; + var firstNsMember = namespaceDeclaration.Members.FirstOrDefault(); + if (firstNsMember != null) { + EnsureBlankLinesBefore(firstNsMember, policy.BlankLinesBeforeFirstDeclaration); + } + FixIndentationForceNewLine(namespaceDeclaration.StartLocation); + EnforceBraceStyle(policy.NamespaceBraceStyle, namespaceDeclaration.LBraceToken, namespaceDeclaration.RBraceToken); + if (policy.IndentNamespaceBody) { + curIndent.Push(IndentType.Block); + } + base.VisitNamespaceDeclaration(namespaceDeclaration); + if (policy.IndentNamespaceBody) { + curIndent.Pop (); + } + FixIndentation(namespaceDeclaration.RBraceToken.StartLocation); } - public override object VisitTypeDeclaration (TypeDeclaration typeDeclaration, object data) + public override void VisitTypeDeclaration(TypeDeclaration typeDeclaration) { - FormatAttributedNode (typeDeclaration); + FormatAttributedNode(typeDeclaration); BraceStyle braceStyle; bool indentBody = false; switch (typeDeclaration.ClassType) { - case ClassType.Class: - braceStyle = policy.ClassBraceStyle; - indentBody = policy.IndentClassBody; - break; - case ClassType.Struct: - braceStyle = policy.StructBraceStyle; - indentBody = policy.IndentStructBody; - break; - case ClassType.Interface: - braceStyle = policy.InterfaceBraceStyle; - indentBody = policy.IndentInterfaceBody; - break; - case ClassType.Enum: - braceStyle = policy.EnumBraceStyle; - indentBody = policy.IndentEnumBody; - break; - default: - throw new InvalidOperationException ("unsupported class type : " + typeDeclaration.ClassType); - } - EnforceBraceStyle (braceStyle, typeDeclaration.LBraceToken, typeDeclaration.RBraceToken); + case ClassType.Class: + braceStyle = policy.ClassBraceStyle; + indentBody = policy.IndentClassBody; + break; + case ClassType.Struct: + braceStyle = policy.StructBraceStyle; + indentBody = policy.IndentStructBody; + break; + case ClassType.Interface: + braceStyle = policy.InterfaceBraceStyle; + indentBody = policy.IndentInterfaceBody; + break; + case ClassType.Enum: + braceStyle = policy.EnumBraceStyle; + indentBody = policy.IndentEnumBody; + break; + default: + throw new InvalidOperationException("unsupported class type : " + typeDeclaration.ClassType); + } + + EnforceBraceStyle(braceStyle, typeDeclaration.LBraceToken, typeDeclaration.RBraceToken); - if (indentBody) - IndentLevel++; - object result = base.VisitTypeDeclaration (typeDeclaration, data); - if (indentBody) - IndentLevel--; + if (indentBody) { + curIndent.Push(IndentType.Block); + } + base.VisitTypeDeclaration(typeDeclaration); + if (indentBody) { + curIndent.Pop (); + } - if (typeDeclaration.NextSibling is TypeDeclaration || typeDeclaration.NextSibling is DelegateDeclaration) - EnsureBlankLinesAfter (typeDeclaration, policy.BlankLinesBetweenTypes); - return result; + if (typeDeclaration.NextSibling is TypeDeclaration || typeDeclaration.NextSibling is DelegateDeclaration) { + EnsureBlankLinesAfter(typeDeclaration, policy.BlankLinesBetweenTypes); + } + } - bool IsSimpleAccessor (Accessor accessor) + bool IsSimpleAccessor(Accessor accessor) { - if (accessor.IsNull || accessor.Body.IsNull || accessor.Body.FirstChild == null) + if (accessor.IsNull || accessor.Body.IsNull || accessor.Body.FirstChild == null) { return true; - if (accessor.Body.Statements.Count () != 1) + } + if (accessor.Body.Statements.Count() != 1) { return false; - return !(accessor.Body.Statements.FirstOrDefault () is BlockStatement); + } + return !(accessor.Body.Statements.FirstOrDefault() is BlockStatement); } - bool IsSpacing (char ch) + bool IsSpacing(char ch) { return ch == ' ' || ch == '\t'; } - bool IsSpacing (ISegment segment) + bool IsSpacing(ISegment segment) { int endOffset = segment.EndOffset; for (int i = segment.Offset; i < endOffset; i++) { - if (!IsSpacing(document.GetCharAt(i))) + if (!IsSpacing(document.GetCharAt(i))) { return false; + } } return true; } - int SearchLastNonWsChar (int startOffset, int endOffset) + int SearchLastNonWsChar(int startOffset, int endOffset) { - startOffset = System.Math.Max (0, startOffset); - endOffset = System.Math.Max (startOffset, endOffset); - if (startOffset >= endOffset) + startOffset = System.Math.Max(0, startOffset); + endOffset = System.Math.Max(startOffset, endOffset); + if (startOffset >= endOffset) { return startOffset; + } int result = -1; bool inComment = false; for (int i = startOffset; i < endOffset && i < document.TextLength; i++) { - char ch = document.GetCharAt (i); - if (IsSpacing (ch)) + char ch = document.GetCharAt(i); + if (IsSpacing(ch)) { continue; - if (ch == '/' && i + 1 < document.TextLength && document.GetCharAt (i + 1) == '/') + } + if (ch == '/' && i + 1 < document.TextLength && document.GetCharAt(i + 1) == '/') { return result; - if (ch == '/' && i + 1 < document.TextLength && document.GetCharAt (i + 1) == '*') { + } + if (ch == '/' && i + 1 < document.TextLength && document.GetCharAt(i + 1) == '*') { inComment = true; i++; continue; } - if (inComment && ch == '*' && i + 1 < document.TextLength && document.GetCharAt (i + 1) == '/') { + if (inComment && ch == '*' && i + 1 < document.TextLength && document.GetCharAt(i + 1) == '/') { inComment = false; i++; continue; } - if (!inComment) + if (!inComment) { result = i; + } } return result; } - void ForceSpace (int startOffset, int endOffset, bool forceSpace) + void ForceSpace(int startOffset, int endOffset, bool forceSpace) { - int lastNonWs = SearchLastNonWsChar (startOffset, endOffset); - AddChange (lastNonWs + 1, System.Math.Max (0, endOffset - lastNonWs - 1), forceSpace ? " " : ""); + int lastNonWs = SearchLastNonWsChar(startOffset, endOffset); + AddChange(lastNonWs + 1, System.Math.Max(0, endOffset - lastNonWs - 1), forceSpace ? " " : ""); } // void ForceSpacesAfter (AstNode n, bool forceSpaces) // { @@ -283,19 +392,21 @@ namespace ICSharpCode.NRefactory.CSharp // ForceSpace (offset - 1, i, forceSpaces); // } - void ForceSpacesAfter (AstNode n, bool forceSpaces) + void ForceSpacesAfter(AstNode n, bool forceSpaces) { - if (n == null) + if (n == null) { return; + } TextLocation location = n.EndLocation; - int offset = document.GetOffset (location); - if (location.Column > document.GetLineByNumber (location.Line).Length) + int offset = document.GetOffset(location); + if (location.Column > document.GetLineByNumber(location.Line).Length) { return; + } int i = offset; while (i < document.TextLength && IsSpacing (document.GetCharAt (i))) { i++; } - ForceSpace (offset - 1, i, forceSpaces); + ForceSpace(offset - 1, i, forceSpaces); } // int ForceSpacesBefore (AstNode n, bool forceSpaces) @@ -303,10 +414,10 @@ namespace ICSharpCode.NRefactory.CSharp // if (n == null || n.IsNull) // return 0; // AstLocation location = n.StartLocation; -// +// // int offset = data.LocationToOffset (location.Line, location.Column); // int i = offset - 1; -// +// // while (i >= 0 && IsSpacing (data.GetCharAt (i))) { // i--; // } @@ -314,741 +425,811 @@ namespace ICSharpCode.NRefactory.CSharp // return i; // } - int ForceSpacesBefore (AstNode n, bool forceSpaces) + int ForceSpacesBefore(AstNode n, bool forceSpaces) { - if (n == null || n.IsNull) + if (n == null || n.IsNull) { return 0; + } TextLocation location = n.StartLocation; // respect manual line breaks. - if (location.Column <= 1 || GetIndentation (location.Line).Length == location.Column - 1) + if (location.Column <= 1 || GetIndentation(location.Line).Length == location.Column - 1) { return 0; - - int offset = document.GetOffset (location); + } + + int offset = document.GetOffset(location); int i = offset - 1; while (i >= 0 && IsSpacing (document.GetCharAt (i))) { i--; } - ForceSpace (i, offset, forceSpaces); + ForceSpace(i, offset, forceSpaces); return i; } - public override object VisitPropertyDeclaration (PropertyDeclaration propertyDeclaration, object data) + int ForceSpacesBeforeRemoveNewLines(AstNode n) { - FormatAttributedNode (propertyDeclaration); + if (n == null || n.IsNull) { + return 0; + } + int offset = document.GetOffset(n.StartLocation); + int i = offset - 1; + while (i >= 0) { + char ch = document.GetCharAt(i); + if (!IsSpacing(ch) && ch != '\r' && ch != '\n') + break; + i--; + } + var length = System.Math.Max(0, (offset - 1) - i); + AddChange(i + 1, length, " "); + return i; + } + + public override void VisitPropertyDeclaration(PropertyDeclaration propertyDeclaration) + { + FormatAttributedNode(propertyDeclaration); bool oneLine = false; switch (policy.PropertyFormatting) { - case PropertyFormatting.AllowOneLine: - bool isSimple = IsSimpleAccessor (propertyDeclaration.Getter) && IsSimpleAccessor (propertyDeclaration.Setter); - if (!isSimple || propertyDeclaration.LBraceToken.StartLocation.Line != propertyDeclaration.RBraceToken.StartLocation.Line) { - EnforceBraceStyle (policy.PropertyBraceStyle, propertyDeclaration.LBraceToken, propertyDeclaration.RBraceToken); - } else { - ForceSpacesBefore (propertyDeclaration.Getter, true); - ForceSpacesBefore (propertyDeclaration.Setter, true); - ForceSpacesBefore (propertyDeclaration.RBraceToken, true); - oneLine = true; - } - break; - case PropertyFormatting.ForceNewLine: - EnforceBraceStyle (policy.PropertyBraceStyle, propertyDeclaration.LBraceToken, propertyDeclaration.RBraceToken); - break; - case PropertyFormatting.ForceOneLine: - isSimple = IsSimpleAccessor (propertyDeclaration.Getter) && IsSimpleAccessor (propertyDeclaration.Setter); - if (isSimple) { - int offset = this.document.GetOffset (propertyDeclaration.LBraceToken.StartLocation); + case PropertyFormatting.AllowOneLine: + bool isSimple = IsSimpleAccessor(propertyDeclaration.Getter) && IsSimpleAccessor(propertyDeclaration.Setter); + if (!isSimple || propertyDeclaration.LBraceToken.StartLocation.Line != propertyDeclaration.RBraceToken.StartLocation.Line) { + EnforceBraceStyle(policy.PropertyBraceStyle, propertyDeclaration.LBraceToken, propertyDeclaration.RBraceToken); + } else { + ForceSpacesBefore(propertyDeclaration.Getter, true); + ForceSpacesBefore(propertyDeclaration.Setter, true); + ForceSpacesBefore(propertyDeclaration.RBraceToken, true); + oneLine = true; + } + break; + case PropertyFormatting.ForceNewLine: + EnforceBraceStyle(policy.PropertyBraceStyle, propertyDeclaration.LBraceToken, propertyDeclaration.RBraceToken); + break; + case PropertyFormatting.ForceOneLine: + isSimple = IsSimpleAccessor(propertyDeclaration.Getter) && IsSimpleAccessor(propertyDeclaration.Setter); + if (isSimple) { + int offset = this.document.GetOffset(propertyDeclaration.LBraceToken.StartLocation); - int start = SearchWhitespaceStart (offset); - int end = SearchWhitespaceEnd (offset); - AddChange (start, offset - start, " "); - AddChange (offset + 1, end - offset - 2, " "); + int start = SearchWhitespaceStart(offset); + int end = SearchWhitespaceEnd(offset); + AddChange(start, offset - start, " "); + AddChange(offset + 1, end - offset - 2, " "); - offset = this.document.GetOffset (propertyDeclaration.RBraceToken.StartLocation); - start = SearchWhitespaceStart (offset); - AddChange (start, offset - start, " "); - oneLine = true; + offset = this.document.GetOffset(propertyDeclaration.RBraceToken.StartLocation); + start = SearchWhitespaceStart(offset); + AddChange(start, offset - start, " "); + oneLine = true; - } else { - EnforceBraceStyle (policy.PropertyBraceStyle, propertyDeclaration.LBraceToken, propertyDeclaration.RBraceToken); - } - break; + } else { + EnforceBraceStyle(policy.PropertyBraceStyle, propertyDeclaration.LBraceToken, propertyDeclaration.RBraceToken); + } + break; + } + if (policy.IndentPropertyBody) { + curIndent.Push(IndentType.Block); } - if (policy.IndentPropertyBody) - IndentLevel++; ///System.Console.WriteLine ("one line: " + oneLine); if (!propertyDeclaration.Getter.IsNull) { if (!oneLine) { - if (!IsLineIsEmptyUpToEol (propertyDeclaration.Getter.StartLocation)) { - int offset = this.document.GetOffset (propertyDeclaration.Getter.StartLocation); - int start = SearchWhitespaceStart (offset); + if (!IsLineIsEmptyUpToEol(propertyDeclaration.Getter.StartLocation)) { + int offset = this.document.GetOffset(propertyDeclaration.Getter.StartLocation); + int start = SearchWhitespaceStart(offset); string indentString = this.curIndent.IndentString; - AddChange (start, offset - start, this.EolMarker + indentString); + AddChange(start, offset - start, this.options.EolMarker + indentString); } else { - FixIndentation (propertyDeclaration.Getter.StartLocation); + FixIndentation(propertyDeclaration.Getter.StartLocation); } } else { - int offset = this.document.GetOffset (propertyDeclaration.Getter.StartLocation); - int start = SearchWhitespaceStart (offset); - AddChange (start, offset - start, " "); + int offset = this.document.GetOffset(propertyDeclaration.Getter.StartLocation); + int start = SearchWhitespaceStart(offset); + AddChange(start, offset - start, " "); - ForceSpacesBefore (propertyDeclaration.Getter.Body.LBraceToken, true); - ForceSpacesBefore (propertyDeclaration.Getter.Body.RBraceToken, true); + ForceSpacesBefore(propertyDeclaration.Getter.Body.LBraceToken, true); + ForceSpacesBefore(propertyDeclaration.Getter.Body.RBraceToken, true); } if (!propertyDeclaration.Getter.Body.IsNull) { if (!policy.AllowPropertyGetBlockInline || propertyDeclaration.Getter.Body.LBraceToken.StartLocation.Line != propertyDeclaration.Getter.Body.RBraceToken.StartLocation.Line) { - EnforceBraceStyle (policy.PropertyGetBraceStyle, propertyDeclaration.Getter.Body.LBraceToken, propertyDeclaration.Getter.Body.RBraceToken); + EnforceBraceStyle(policy.PropertyGetBraceStyle, propertyDeclaration.Getter.Body.LBraceToken, propertyDeclaration.Getter.Body.RBraceToken); } else { nextStatementIndent = " "; } - VisitBlockWithoutFixIndentation (propertyDeclaration.Getter.Body, policy.IndentBlocks, data); + VisitBlockWithoutFixingBraces(propertyDeclaration.Getter.Body, policy.IndentBlocks); } } if (!propertyDeclaration.Setter.IsNull) { if (!oneLine) { - if (!IsLineIsEmptyUpToEol (propertyDeclaration.Setter.StartLocation)) { - int offset = this.document.GetOffset (propertyDeclaration.Setter.StartLocation); - int start = SearchWhitespaceStart (offset); + if (!IsLineIsEmptyUpToEol(propertyDeclaration.Setter.StartLocation)) { + int offset = this.document.GetOffset(propertyDeclaration.Setter.StartLocation); + int start = SearchWhitespaceStart(offset); string indentString = this.curIndent.IndentString; - AddChange (start, offset - start, this.EolMarker + indentString); + AddChange(start, offset - start, this.options.EolMarker + indentString); } else { - FixIndentation (propertyDeclaration.Setter.StartLocation); + FixIndentation(propertyDeclaration.Setter.StartLocation); } } else { - int offset = this.document.GetOffset (propertyDeclaration.Setter.StartLocation); - int start = SearchWhitespaceStart (offset); - AddChange (start, offset - start, " "); + int offset = this.document.GetOffset(propertyDeclaration.Setter.StartLocation); + int start = SearchWhitespaceStart(offset); + AddChange(start, offset - start, " "); - ForceSpacesBefore (propertyDeclaration.Setter.Body.LBraceToken, true); - ForceSpacesBefore (propertyDeclaration.Setter.Body.RBraceToken, true); + ForceSpacesBefore(propertyDeclaration.Setter.Body.LBraceToken, true); + ForceSpacesBefore(propertyDeclaration.Setter.Body.RBraceToken, true); } if (!propertyDeclaration.Setter.Body.IsNull) { if (!policy.AllowPropertySetBlockInline || propertyDeclaration.Setter.Body.LBraceToken.StartLocation.Line != propertyDeclaration.Setter.Body.RBraceToken.StartLocation.Line) { - EnforceBraceStyle (policy.PropertySetBraceStyle, propertyDeclaration.Setter.Body.LBraceToken, propertyDeclaration.Setter.Body.RBraceToken); + EnforceBraceStyle(policy.PropertySetBraceStyle, propertyDeclaration.Setter.Body.LBraceToken, propertyDeclaration.Setter.Body.RBraceToken); } else { nextStatementIndent = " "; } - VisitBlockWithoutFixIndentation (propertyDeclaration.Setter.Body, policy.IndentBlocks, data); + VisitBlockWithoutFixingBraces(propertyDeclaration.Setter.Body, policy.IndentBlocks); } } - if (policy.IndentPropertyBody) - IndentLevel--; - if (IsMember (propertyDeclaration.NextSibling)) - EnsureBlankLinesAfter (propertyDeclaration, policy.BlankLinesBetweenMembers); - return null; + if (policy.IndentPropertyBody) { + curIndent.Pop (); + } + if (IsMember(propertyDeclaration.NextSibling)) { + EnsureBlankLinesAfter(propertyDeclaration, policy.BlankLinesBetweenMembers); + } } - public override object VisitIndexerDeclaration (IndexerDeclaration indexerDeclaration, object data) + public override void VisitIndexerDeclaration(IndexerDeclaration indexerDeclaration) { - ForceSpacesBefore (indexerDeclaration.LBracketToken, policy.SpaceBeforeIndexerDeclarationBracket); - ForceSpacesAfter (indexerDeclaration.LBracketToken, policy.SpaceWithinIndexerDeclarationBracket); - ForceSpacesBefore (indexerDeclaration.RBracketToken, policy.SpaceWithinIndexerDeclarationBracket); + ForceSpacesBefore(indexerDeclaration.LBracketToken, policy.SpaceBeforeIndexerDeclarationBracket); + ForceSpacesAfter(indexerDeclaration.LBracketToken, policy.SpaceWithinIndexerDeclarationBracket); + ForceSpacesBefore(indexerDeclaration.RBracketToken, policy.SpaceWithinIndexerDeclarationBracket); - FormatCommas (indexerDeclaration, policy.SpaceBeforeIndexerDeclarationParameterComma, policy.SpaceAfterIndexerDeclarationParameterComma); + FormatCommas(indexerDeclaration, policy.SpaceBeforeIndexerDeclarationParameterComma, policy.SpaceAfterIndexerDeclarationParameterComma); - FormatAttributedNode (indexerDeclaration); - EnforceBraceStyle (policy.PropertyBraceStyle, indexerDeclaration.LBraceToken, indexerDeclaration.RBraceToken); - if (policy.IndentPropertyBody) - IndentLevel++; + FormatAttributedNode(indexerDeclaration); + EnforceBraceStyle(policy.PropertyBraceStyle, indexerDeclaration.LBraceToken, indexerDeclaration.RBraceToken); + if (policy.IndentPropertyBody) { + curIndent.Push(IndentType.Block); + } if (!indexerDeclaration.Getter.IsNull) { - FixIndentation (indexerDeclaration.Getter.StartLocation); + FixIndentation(indexerDeclaration.Getter.StartLocation); if (!indexerDeclaration.Getter.Body.IsNull) { if (!policy.AllowPropertyGetBlockInline || indexerDeclaration.Getter.Body.LBraceToken.StartLocation.Line != indexerDeclaration.Getter.Body.RBraceToken.StartLocation.Line) { - EnforceBraceStyle (policy.PropertyGetBraceStyle, indexerDeclaration.Getter.Body.LBraceToken, indexerDeclaration.Getter.Body.RBraceToken); + EnforceBraceStyle(policy.PropertyGetBraceStyle, indexerDeclaration.Getter.Body.LBraceToken, indexerDeclaration.Getter.Body.RBraceToken); } else { nextStatementIndent = " "; } - VisitBlockWithoutFixIndentation (indexerDeclaration.Getter.Body, policy.IndentBlocks, data); + VisitBlockWithoutFixingBraces(indexerDeclaration.Getter.Body, policy.IndentBlocks); } } if (!indexerDeclaration.Setter.IsNull) { - FixIndentation (indexerDeclaration.Setter.StartLocation); + FixIndentation(indexerDeclaration.Setter.StartLocation); if (!indexerDeclaration.Setter.Body.IsNull) { if (!policy.AllowPropertySetBlockInline || indexerDeclaration.Setter.Body.LBraceToken.StartLocation.Line != indexerDeclaration.Setter.Body.RBraceToken.StartLocation.Line) { - EnforceBraceStyle (policy.PropertySetBraceStyle, indexerDeclaration.Setter.Body.LBraceToken, indexerDeclaration.Setter.Body.RBraceToken); + EnforceBraceStyle(policy.PropertySetBraceStyle, indexerDeclaration.Setter.Body.LBraceToken, indexerDeclaration.Setter.Body.RBraceToken); } else { nextStatementIndent = " "; } - VisitBlockWithoutFixIndentation (indexerDeclaration.Setter.Body, policy.IndentBlocks, data); + VisitBlockWithoutFixingBraces(indexerDeclaration.Setter.Body, policy.IndentBlocks); } } - if (policy.IndentPropertyBody) - IndentLevel--; - if (IsMember (indexerDeclaration.NextSibling)) - EnsureBlankLinesAfter (indexerDeclaration, policy.BlankLinesBetweenMembers); - return null; + if (policy.IndentPropertyBody) { + curIndent.Pop (); + } + if (IsMember(indexerDeclaration.NextSibling)) { + EnsureBlankLinesAfter(indexerDeclaration, policy.BlankLinesBetweenMembers); + } } - static bool IsSimpleEvent (AstNode node) + static bool IsSimpleEvent(AstNode node) { return node is EventDeclaration; } - public override object VisitCustomEventDeclaration (CustomEventDeclaration eventDeclaration, object data) + public override void VisitCustomEventDeclaration(CustomEventDeclaration eventDeclaration) { - FormatAttributedNode (eventDeclaration); - EnforceBraceStyle (policy.EventBraceStyle, eventDeclaration.LBraceToken, eventDeclaration.RBraceToken); - if (policy.IndentEventBody) - IndentLevel++; + FormatAttributedNode(eventDeclaration); + EnforceBraceStyle(policy.EventBraceStyle, eventDeclaration.LBraceToken, eventDeclaration.RBraceToken); + if (policy.IndentEventBody) { + curIndent.Push(IndentType.Block); + } if (!eventDeclaration.AddAccessor.IsNull) { - FixIndentation (eventDeclaration.AddAccessor.StartLocation); + FixIndentation(eventDeclaration.AddAccessor.StartLocation); if (!eventDeclaration.AddAccessor.Body.IsNull) { if (!policy.AllowEventAddBlockInline || eventDeclaration.AddAccessor.Body.LBraceToken.StartLocation.Line != eventDeclaration.AddAccessor.Body.RBraceToken.StartLocation.Line) { - EnforceBraceStyle (policy.EventAddBraceStyle, eventDeclaration.AddAccessor.Body.LBraceToken, eventDeclaration.AddAccessor.Body.RBraceToken); + EnforceBraceStyle(policy.EventAddBraceStyle, eventDeclaration.AddAccessor.Body.LBraceToken, eventDeclaration.AddAccessor.Body.RBraceToken); } else { nextStatementIndent = " "; } - VisitBlockWithoutFixIndentation (eventDeclaration.AddAccessor.Body, policy.IndentBlocks, data); + VisitBlockWithoutFixingBraces(eventDeclaration.AddAccessor.Body, policy.IndentBlocks); } } if (!eventDeclaration.RemoveAccessor.IsNull) { - FixIndentation (eventDeclaration.RemoveAccessor.StartLocation); + FixIndentation(eventDeclaration.RemoveAccessor.StartLocation); if (!eventDeclaration.RemoveAccessor.Body.IsNull) { if (!policy.AllowEventRemoveBlockInline || eventDeclaration.RemoveAccessor.Body.LBraceToken.StartLocation.Line != eventDeclaration.RemoveAccessor.Body.RBraceToken.StartLocation.Line) { - EnforceBraceStyle (policy.EventRemoveBraceStyle, eventDeclaration.RemoveAccessor.Body.LBraceToken, eventDeclaration.RemoveAccessor.Body.RBraceToken); + EnforceBraceStyle(policy.EventRemoveBraceStyle, eventDeclaration.RemoveAccessor.Body.LBraceToken, eventDeclaration.RemoveAccessor.Body.RBraceToken); } else { nextStatementIndent = " "; } - VisitBlockWithoutFixIndentation (eventDeclaration.RemoveAccessor.Body, policy.IndentBlocks, data); + VisitBlockWithoutFixingBraces(eventDeclaration.RemoveAccessor.Body, policy.IndentBlocks); } } - if (policy.IndentEventBody) - IndentLevel--; + if (policy.IndentEventBody) { + curIndent.Pop (); + } - if (eventDeclaration.NextSibling is EventDeclaration && IsSimpleEvent (eventDeclaration) && IsSimpleEvent (eventDeclaration.NextSibling)) { - EnsureBlankLinesAfter (eventDeclaration, policy.BlankLinesBetweenEventFields); - } else if (IsMember (eventDeclaration.NextSibling)) { - EnsureBlankLinesAfter (eventDeclaration, policy.BlankLinesBetweenMembers); + if (eventDeclaration.NextSibling is EventDeclaration && IsSimpleEvent(eventDeclaration) && IsSimpleEvent(eventDeclaration.NextSibling)) { + EnsureBlankLinesAfter(eventDeclaration, policy.BlankLinesBetweenEventFields); + } else if (IsMember(eventDeclaration.NextSibling)) { + EnsureBlankLinesAfter(eventDeclaration, policy.BlankLinesBetweenMembers); } - return null; } - public override object VisitEventDeclaration (EventDeclaration eventDeclaration, object data) + public override void VisitEventDeclaration(EventDeclaration eventDeclaration) { - FormatAttributedNode (eventDeclaration); - if (eventDeclaration.NextSibling is EventDeclaration && IsSimpleEvent (eventDeclaration) && IsSimpleEvent (eventDeclaration.NextSibling)) { - EnsureBlankLinesAfter (eventDeclaration, policy.BlankLinesBetweenEventFields); - } else if (IsMember (eventDeclaration.NextSibling)) { - EnsureBlankLinesAfter (eventDeclaration, policy.BlankLinesBetweenMembers); + FormatAttributedNode(eventDeclaration); + if (eventDeclaration.NextSibling is EventDeclaration && IsSimpleEvent(eventDeclaration) && IsSimpleEvent(eventDeclaration.NextSibling)) { + EnsureBlankLinesAfter(eventDeclaration, policy.BlankLinesBetweenEventFields); + } else if (IsMember(eventDeclaration.NextSibling)) { + EnsureBlankLinesAfter(eventDeclaration, policy.BlankLinesBetweenMembers); } - return null; + + var lastLoc = eventDeclaration.StartLocation; + curIndent.Push(IndentType.Block); + foreach (var initializer in eventDeclaration.Variables) { + if (lastLoc.Line != initializer.StartLocation.Line) { + FixStatementIndentation(initializer.StartLocation); + lastLoc = initializer.StartLocation; + } + initializer.AcceptVisitor(this); + } + curIndent.Pop (); } - public override object VisitAccessor (Accessor accessor, object data) + public override void VisitAccessor(Accessor accessor) { - FixIndentationForceNewLine (accessor.StartLocation); - object result = base.VisitAccessor (accessor, data); - return result; + FixIndentationForceNewLine(accessor.StartLocation); + base.VisitAccessor(accessor); } - public override object VisitFieldDeclaration (FieldDeclaration fieldDeclaration, object data) + public override void VisitFieldDeclaration(FieldDeclaration fieldDeclaration) { - FormatAttributedNode (fieldDeclaration); - FormatCommas (fieldDeclaration, policy.SpaceBeforeFieldDeclarationComma, policy.SpaceAfterFieldDeclarationComma); + FormatAttributedNode(fieldDeclaration); + fieldDeclaration.ReturnType.AcceptVisitor(this); + FormatCommas(fieldDeclaration, policy.SpaceBeforeFieldDeclarationComma, policy.SpaceAfterFieldDeclarationComma); if (fieldDeclaration.NextSibling is FieldDeclaration || fieldDeclaration.NextSibling is FixedFieldDeclaration) { - EnsureBlankLinesAfter (fieldDeclaration, policy.BlankLinesBetweenFields); - } else if (IsMember (fieldDeclaration.NextSibling)) { - EnsureBlankLinesAfter (fieldDeclaration, policy.BlankLinesBetweenMembers); + EnsureBlankLinesAfter(fieldDeclaration, policy.BlankLinesBetweenFields); + } else if (IsMember(fieldDeclaration.NextSibling)) { + EnsureBlankLinesAfter(fieldDeclaration, policy.BlankLinesBetweenMembers); + } + + var lastLoc = fieldDeclaration.StartLocation; + curIndent.Push(IndentType.Block); + foreach (var initializer in fieldDeclaration.Variables) { + if (lastLoc.Line != initializer.StartLocation.Line) { + FixStatementIndentation(initializer.StartLocation); + lastLoc = initializer.StartLocation; + } + initializer.AcceptVisitor(this); } - return base.VisitFieldDeclaration (fieldDeclaration, data); + curIndent.Pop (); } - public override object VisitFixedFieldDeclaration (FixedFieldDeclaration fixedFieldDeclaration, object data) + public override void VisitFixedFieldDeclaration(FixedFieldDeclaration fixedFieldDeclaration) { - FormatAttributedNode (fixedFieldDeclaration); - FormatCommas (fixedFieldDeclaration, policy.SpaceBeforeFieldDeclarationComma, policy.SpaceAfterFieldDeclarationComma); + FormatAttributedNode(fixedFieldDeclaration); + FormatCommas(fixedFieldDeclaration, policy.SpaceBeforeFieldDeclarationComma, policy.SpaceAfterFieldDeclarationComma); if (fixedFieldDeclaration.NextSibling is FieldDeclaration || fixedFieldDeclaration.NextSibling is FixedFieldDeclaration) { - EnsureBlankLinesAfter (fixedFieldDeclaration, policy.BlankLinesBetweenFields); - } else if (IsMember (fixedFieldDeclaration.NextSibling)) { - EnsureBlankLinesAfter (fixedFieldDeclaration, policy.BlankLinesBetweenMembers); + EnsureBlankLinesAfter(fixedFieldDeclaration, policy.BlankLinesBetweenFields); + } else if (IsMember(fixedFieldDeclaration.NextSibling)) { + EnsureBlankLinesAfter(fixedFieldDeclaration, policy.BlankLinesBetweenMembers); + } + + var lastLoc = fixedFieldDeclaration.StartLocation; + curIndent.Push(IndentType.Block); + foreach (var initializer in fixedFieldDeclaration.Variables) { + if (lastLoc.Line != initializer.StartLocation.Line) { + FixStatementIndentation(initializer.StartLocation); + lastLoc = initializer.StartLocation; + } + initializer.AcceptVisitor(this); } - return base.VisitFixedFieldDeclaration (fixedFieldDeclaration, data); + curIndent.Pop (); } - public override object VisitEnumMemberDeclaration (EnumMemberDeclaration enumMemberDeclaration, object data) + public override void VisitEnumMemberDeclaration(EnumMemberDeclaration enumMemberDeclaration) { - FormatAttributedNode (enumMemberDeclaration); - return base.VisitEnumMemberDeclaration (enumMemberDeclaration, data); + FormatAttributedNode(enumMemberDeclaration); + base.VisitEnumMemberDeclaration(enumMemberDeclaration); } - public override object VisitDelegateDeclaration (DelegateDeclaration delegateDeclaration, object data) + public override void VisitDelegateDeclaration(DelegateDeclaration delegateDeclaration) { - FormatAttributedNode (delegateDeclaration); + FormatAttributedNode(delegateDeclaration); - ForceSpacesBefore (delegateDeclaration.LParToken, policy.SpaceBeforeDelegateDeclarationParentheses); - if (delegateDeclaration.Parameters.Any ()) { - ForceSpacesAfter (delegateDeclaration.LParToken, policy.SpaceWithinDelegateDeclarationParentheses); - ForceSpacesBefore (delegateDeclaration.RParToken, policy.SpaceWithinDelegateDeclarationParentheses); + ForceSpacesBefore(delegateDeclaration.LParToken, policy.SpaceBeforeDelegateDeclarationParentheses); + if (delegateDeclaration.Parameters.Any()) { + ForceSpacesAfter(delegateDeclaration.LParToken, policy.SpaceWithinDelegateDeclarationParentheses); + ForceSpacesBefore(delegateDeclaration.RParToken, policy.SpaceWithinDelegateDeclarationParentheses); } else { - ForceSpacesAfter (delegateDeclaration.LParToken, policy.SpaceBetweenEmptyDelegateDeclarationParentheses); - ForceSpacesBefore (delegateDeclaration.RParToken, policy.SpaceBetweenEmptyDelegateDeclarationParentheses); + ForceSpacesAfter(delegateDeclaration.LParToken, policy.SpaceBetweenEmptyDelegateDeclarationParentheses); + ForceSpacesBefore(delegateDeclaration.RParToken, policy.SpaceBetweenEmptyDelegateDeclarationParentheses); } - FormatCommas (delegateDeclaration, policy.SpaceBeforeDelegateDeclarationParameterComma, policy.SpaceAfterDelegateDeclarationParameterComma); + FormatCommas(delegateDeclaration, policy.SpaceBeforeDelegateDeclarationParameterComma, policy.SpaceAfterDelegateDeclarationParameterComma); if (delegateDeclaration.NextSibling is TypeDeclaration || delegateDeclaration.NextSibling is DelegateDeclaration) { - EnsureBlankLinesAfter (delegateDeclaration, policy.BlankLinesBetweenTypes); - } else if (IsMember (delegateDeclaration.NextSibling)) { - EnsureBlankLinesAfter (delegateDeclaration, policy.BlankLinesBetweenMembers); + EnsureBlankLinesAfter(delegateDeclaration, policy.BlankLinesBetweenTypes); + } else if (IsMember(delegateDeclaration.NextSibling)) { + EnsureBlankLinesAfter(delegateDeclaration, policy.BlankLinesBetweenMembers); } - return base.VisitDelegateDeclaration (delegateDeclaration, data); + base.VisitDelegateDeclaration(delegateDeclaration); } - static bool IsMember (AstNode nextSibling) + static bool IsMember(AstNode nextSibling) { return nextSibling != null && nextSibling.NodeType == NodeType.Member; } - void FormatAttributedNode (AstNode node) + void FormatAttributedNode(AstNode node) { - if (node == null) + if (node == null) { return; + } AstNode child = node.FirstChild; while (child != null && child is AttributeSection) { - FixIndentationForceNewLine (child.StartLocation); + FixIndentationForceNewLine(child.StartLocation); child = child.NextSibling; } - if (child != null) - FixIndentationForceNewLine (child.StartLocation); + if (child != null) { + FixIndentationForceNewLine(child.StartLocation); + } } - public override object VisitMethodDeclaration (MethodDeclaration methodDeclaration, object data) + public override void VisitMethodDeclaration(MethodDeclaration methodDeclaration) { - FormatAttributedNode (methodDeclaration); + FormatAttributedNode(methodDeclaration); - ForceSpacesBefore (methodDeclaration.LParToken, policy.SpaceBeforeMethodDeclarationParentheses); - if (methodDeclaration.Parameters.Any ()) { - ForceSpacesAfter (methodDeclaration.LParToken, policy.SpaceWithinMethodDeclarationParentheses); - ForceSpacesBefore (methodDeclaration.RParToken, policy.SpaceWithinMethodDeclarationParentheses); + ForceSpacesBefore(methodDeclaration.LParToken, policy.SpaceBeforeMethodDeclarationParentheses); + if (methodDeclaration.Parameters.Any()) { + ForceSpacesAfter(methodDeclaration.LParToken, policy.SpaceWithinMethodDeclarationParentheses); + ForceSpacesBefore(methodDeclaration.RParToken, policy.SpaceWithinMethodDeclarationParentheses); } else { - ForceSpacesAfter (methodDeclaration.LParToken, policy.SpaceBetweenEmptyMethodDeclarationParentheses); - ForceSpacesBefore (methodDeclaration.RParToken, policy.SpaceBetweenEmptyMethodDeclarationParentheses); + ForceSpacesAfter(methodDeclaration.LParToken, policy.SpaceBetweenEmptyMethodDeclarationParentheses); + ForceSpacesBefore(methodDeclaration.RParToken, policy.SpaceBetweenEmptyMethodDeclarationParentheses); } - FormatCommas (methodDeclaration, policy.SpaceBeforeMethodDeclarationParameterComma, policy.SpaceAfterMethodDeclarationParameterComma); + FormatCommas(methodDeclaration, policy.SpaceBeforeMethodDeclarationParameterComma, policy.SpaceAfterMethodDeclarationParameterComma); if (!methodDeclaration.Body.IsNull) { - EnforceBraceStyle (policy.MethodBraceStyle, methodDeclaration.Body.LBraceToken, methodDeclaration.Body.RBraceToken); - if (policy.IndentMethodBody) - IndentLevel++; - base.VisitBlockStatement (methodDeclaration.Body, data); - if (policy.IndentMethodBody) - IndentLevel--; + EnforceBraceStyle(policy.MethodBraceStyle, methodDeclaration.Body.LBraceToken, methodDeclaration.Body.RBraceToken); + VisitBlockWithoutFixingBraces(methodDeclaration.Body, policy.IndentMethodBody); + } + if (IsMember(methodDeclaration.NextSibling)) { + EnsureBlankLinesAfter(methodDeclaration, policy.BlankLinesBetweenMembers); } - if (IsMember (methodDeclaration.NextSibling)) - EnsureBlankLinesAfter (methodDeclaration, policy.BlankLinesBetweenMembers); - - return null; } - public override object VisitOperatorDeclaration (OperatorDeclaration operatorDeclaration, object data) + public override void VisitOperatorDeclaration(OperatorDeclaration operatorDeclaration) { - FormatAttributedNode (operatorDeclaration); + FormatAttributedNode(operatorDeclaration); - ForceSpacesBefore (operatorDeclaration.LParToken, policy.SpaceBeforeMethodDeclarationParentheses); - if (operatorDeclaration.Parameters.Any ()) { - ForceSpacesAfter (operatorDeclaration.LParToken, policy.SpaceWithinMethodDeclarationParentheses); - ForceSpacesBefore (operatorDeclaration.RParToken, policy.SpaceWithinMethodDeclarationParentheses); + ForceSpacesBefore(operatorDeclaration.LParToken, policy.SpaceBeforeMethodDeclarationParentheses); + if (operatorDeclaration.Parameters.Any()) { + ForceSpacesAfter(operatorDeclaration.LParToken, policy.SpaceWithinMethodDeclarationParentheses); + ForceSpacesBefore(operatorDeclaration.RParToken, policy.SpaceWithinMethodDeclarationParentheses); } else { - ForceSpacesAfter (operatorDeclaration.LParToken, policy.SpaceBetweenEmptyMethodDeclarationParentheses); - ForceSpacesBefore (operatorDeclaration.RParToken, policy.SpaceBetweenEmptyMethodDeclarationParentheses); + ForceSpacesAfter(operatorDeclaration.LParToken, policy.SpaceBetweenEmptyMethodDeclarationParentheses); + ForceSpacesBefore(operatorDeclaration.RParToken, policy.SpaceBetweenEmptyMethodDeclarationParentheses); } - FormatCommas (operatorDeclaration, policy.SpaceBeforeMethodDeclarationParameterComma, policy.SpaceAfterMethodDeclarationParameterComma); + FormatCommas(operatorDeclaration, policy.SpaceBeforeMethodDeclarationParameterComma, policy.SpaceAfterMethodDeclarationParameterComma); if (!operatorDeclaration.Body.IsNull) { - EnforceBraceStyle (policy.MethodBraceStyle, operatorDeclaration.Body.LBraceToken, operatorDeclaration.Body.RBraceToken); - if (policy.IndentMethodBody) - IndentLevel++; - base.VisitBlockStatement (operatorDeclaration.Body, data); - if (policy.IndentMethodBody) - IndentLevel--; - } - if (IsMember (operatorDeclaration.NextSibling)) - EnsureBlankLinesAfter (operatorDeclaration, policy.BlankLinesBetweenMembers); - - return null; + EnforceBraceStyle(policy.MethodBraceStyle, operatorDeclaration.Body.LBraceToken, operatorDeclaration.Body.RBraceToken); + VisitBlockWithoutFixingBraces(operatorDeclaration.Body, policy.IndentMethodBody); + } + if (IsMember(operatorDeclaration.NextSibling)) { + EnsureBlankLinesAfter(operatorDeclaration, policy.BlankLinesBetweenMembers); + } } - public override object VisitConstructorDeclaration (ConstructorDeclaration constructorDeclaration, object data) + public override void VisitConstructorDeclaration(ConstructorDeclaration constructorDeclaration) { - FormatAttributedNode (constructorDeclaration); + FormatAttributedNode(constructorDeclaration); - ForceSpacesBefore (constructorDeclaration.LParToken, policy.SpaceBeforeConstructorDeclarationParentheses); - if (constructorDeclaration.Parameters.Any ()) { - ForceSpacesAfter (constructorDeclaration.LParToken, policy.SpaceWithinConstructorDeclarationParentheses); - ForceSpacesBefore (constructorDeclaration.RParToken, policy.SpaceWithinConstructorDeclarationParentheses); + ForceSpacesBefore(constructorDeclaration.LParToken, policy.SpaceBeforeConstructorDeclarationParentheses); + if (constructorDeclaration.Parameters.Any()) { + ForceSpacesAfter(constructorDeclaration.LParToken, policy.SpaceWithinConstructorDeclarationParentheses); + ForceSpacesBefore(constructorDeclaration.RParToken, policy.SpaceWithinConstructorDeclarationParentheses); } else { - ForceSpacesAfter (constructorDeclaration.LParToken, policy.SpaceBetweenEmptyConstructorDeclarationParentheses); - ForceSpacesBefore (constructorDeclaration.RParToken, policy.SpaceBetweenEmptyConstructorDeclarationParentheses); + ForceSpacesAfter(constructorDeclaration.LParToken, policy.SpaceBetweenEmptyConstructorDeclarationParentheses); + ForceSpacesBefore(constructorDeclaration.RParToken, policy.SpaceBetweenEmptyConstructorDeclarationParentheses); } - FormatCommas (constructorDeclaration, policy.SpaceBeforeConstructorDeclarationParameterComma, policy.SpaceAfterConstructorDeclarationParameterComma); - - object result = null; + FormatCommas(constructorDeclaration, policy.SpaceBeforeConstructorDeclarationParameterComma, policy.SpaceAfterConstructorDeclarationParameterComma); + if (!constructorDeclaration.Body.IsNull) { - EnforceBraceStyle (policy.ConstructorBraceStyle, constructorDeclaration.Body.LBraceToken, constructorDeclaration.Body.RBraceToken); - if (policy.IndentMethodBody) - IndentLevel++; - result = base.VisitBlockStatement (constructorDeclaration.Body, data); - if (policy.IndentMethodBody) - IndentLevel--; - } - if (IsMember (constructorDeclaration.NextSibling)) - EnsureBlankLinesAfter (constructorDeclaration, policy.BlankLinesBetweenMembers); - return result; + EnforceBraceStyle(policy.ConstructorBraceStyle, constructorDeclaration.Body.LBraceToken, constructorDeclaration.Body.RBraceToken); + VisitBlockWithoutFixingBraces(constructorDeclaration.Body, policy.IndentMethodBody); + } + if (IsMember(constructorDeclaration.NextSibling)) { + EnsureBlankLinesAfter(constructorDeclaration, policy.BlankLinesBetweenMembers); + } } - public override object VisitDestructorDeclaration (DestructorDeclaration destructorDeclaration, object data) + public override void VisitDestructorDeclaration(DestructorDeclaration destructorDeclaration) { - FormatAttributedNode (destructorDeclaration); + FormatAttributedNode(destructorDeclaration); CSharpTokenNode lParen = destructorDeclaration.LParToken; - int offset = this.document.GetOffset (lParen.StartLocation); - ForceSpaceBefore (offset, policy.SpaceBeforeConstructorDeclarationParentheses); + int offset = this.document.GetOffset(lParen.StartLocation); + ForceSpaceBefore(offset, policy.SpaceBeforeConstructorDeclarationParentheses); - object result = null; if (!destructorDeclaration.Body.IsNull) { - EnforceBraceStyle (policy.DestructorBraceStyle, destructorDeclaration.Body.LBraceToken, destructorDeclaration.Body.RBraceToken); - if (policy.IndentMethodBody) - IndentLevel++; - result = base.VisitBlockStatement (destructorDeclaration.Body, data); - if (policy.IndentMethodBody) - IndentLevel--; - } - if (IsMember (destructorDeclaration.NextSibling)) - EnsureBlankLinesAfter (destructorDeclaration, policy.BlankLinesBetweenMembers); - return result; + EnforceBraceStyle(policy.DestructorBraceStyle, destructorDeclaration.Body.LBraceToken, destructorDeclaration.Body.RBraceToken); + VisitBlockWithoutFixingBraces(destructorDeclaration.Body, policy.IndentMethodBody); + } + if (IsMember(destructorDeclaration.NextSibling)) { + EnsureBlankLinesAfter(destructorDeclaration, policy.BlankLinesBetweenMembers); + } } #region Statements - public override object VisitExpressionStatement (ExpressionStatement expressionStatement, object data) + public override void VisitExpressionStatement(ExpressionStatement expressionStatement) { - FixStatementIndentation (expressionStatement.StartLocation); - FixSemicolon (expressionStatement.SemicolonToken); - return base.VisitExpressionStatement (expressionStatement, data); + base.VisitExpressionStatement(expressionStatement); + FixSemicolon(expressionStatement.SemicolonToken); } - object VisitBlockWithoutFixIndentation (BlockStatement blockStatement, bool indent, object data) + void VisitBlockWithoutFixingBraces(BlockStatement blockStatement, bool indent) { - if (indent) - IndentLevel++; - object result = base.VisitBlockStatement (blockStatement, data); - if (indent) - IndentLevel--; - return result; + if (indent) { + curIndent.Push(IndentType.Block); + } + foreach (var child in blockStatement.Children) { + if (child.Role == Roles.LBrace || child.Role == Roles.RBrace) { + continue; + } + if (child is Statement) { + FixStatementIndentation(child.StartLocation); + child.AcceptVisitor(this); + } else if (child is Comment) { + child.AcceptVisitor(this); + } else { + // pre processor directives at line start, if they are there. + if (child.StartLocation.Column > 1) + FixStatementIndentation(child.StartLocation); + } + } + if (indent) { + curIndent.Pop (); + } } - public override object VisitBlockStatement (BlockStatement blockStatement, object data) + public override void VisitBlockStatement(BlockStatement blockStatement) { - FixIndentation (blockStatement.StartLocation); - object result = VisitBlockWithoutFixIndentation (blockStatement, policy.IndentBlocks, data); - FixIndentation (blockStatement.EndLocation, -1); - return result; + FixIndentation(blockStatement.StartLocation); + VisitBlockWithoutFixingBraces(blockStatement, policy.IndentBlocks); + FixIndentation(blockStatement.EndLocation, -1); } - public override object VisitComment (Comment comment, object data) + public override void VisitComment(Comment comment) { - if (comment.StartsLine && !HadErrors && comment.StartLocation.Column > 1) - FixIndentation (comment.StartLocation); - return null; + if (comment.StartsLine && !HadErrors && (!policy.KeepCommentsAtFirstColumn || comment.StartLocation.Column > 1)) { + FixIndentation(comment.StartLocation); + } } - public override object VisitBreakStatement (BreakStatement breakStatement, object data) + public override void VisitBreakStatement(BreakStatement breakStatement) { - FixStatementIndentation (breakStatement.StartLocation); - return null; + FixSemicolon(breakStatement.SemicolonToken); } - public override object VisitCheckedStatement (CheckedStatement checkedStatement, object data) + public override void VisitCheckedStatement(CheckedStatement checkedStatement) { - FixStatementIndentation (checkedStatement.StartLocation); - return FixEmbeddedStatment (policy.StatementBraceStyle, policy.FixedBraceForcement, checkedStatement.Body); + FixEmbeddedStatment(policy.StatementBraceStyle, policy.FixedBraceForcement, checkedStatement.Body); } - public override object VisitContinueStatement (ContinueStatement continueStatement, object data) + public override void VisitContinueStatement(ContinueStatement continueStatement) { - FixStatementIndentation (continueStatement.StartLocation); - return null; + FixSemicolon(continueStatement.SemicolonToken); } - public override object VisitEmptyStatement (EmptyStatement emptyStatement, object data) + public override void VisitEmptyStatement(EmptyStatement emptyStatement) { - FixStatementIndentation (emptyStatement.StartLocation); - return null; + // Empty } - public override object VisitFixedStatement (FixedStatement fixedStatement, object data) + public override void VisitFixedStatement(FixedStatement fixedStatement) { - FixStatementIndentation (fixedStatement.StartLocation); - return FixEmbeddedStatment (policy.StatementBraceStyle, policy.FixedBraceForcement, fixedStatement.EmbeddedStatement); + FixEmbeddedStatment(policy.StatementBraceStyle, policy.FixedBraceForcement, fixedStatement.EmbeddedStatement); } - public override object VisitForeachStatement (ForeachStatement foreachStatement, object data) + public override void VisitForeachStatement(ForeachStatement foreachStatement) { - FixStatementIndentation (foreachStatement.StartLocation); - ForceSpacesBefore (foreachStatement.LParToken, policy.SpaceBeforeForeachParentheses); + ForceSpacesBefore(foreachStatement.LParToken, policy.SpaceBeforeForeachParentheses); - ForceSpacesAfter (foreachStatement.LParToken, policy.SpacesWithinForeachParentheses); - ForceSpacesBefore (foreachStatement.RParToken, policy.SpacesWithinForeachParentheses); + ForceSpacesAfter(foreachStatement.LParToken, policy.SpacesWithinForeachParentheses); + ForceSpacesBefore(foreachStatement.RParToken, policy.SpacesWithinForeachParentheses); - return FixEmbeddedStatment (policy.StatementBraceStyle, policy.ForEachBraceForcement, foreachStatement.EmbeddedStatement); + FixEmbeddedStatment(policy.StatementBraceStyle, policy.ForEachBraceForcement, foreachStatement.EmbeddedStatement); } - object FixEmbeddedStatment (BraceStyle braceStyle, BraceForcement braceForcement, AstNode node) + void FixEmbeddedStatment(BraceStyle braceStyle, BraceForcement braceForcement, AstNode node) { - return FixEmbeddedStatment (braceStyle, braceForcement, null, false, node); + FixEmbeddedStatment(braceStyle, braceForcement, null, false, node); } - object FixEmbeddedStatment (BraceStyle braceStyle, BraceForcement braceForcement, CSharpTokenNode token, bool allowInLine, AstNode node) + void FixEmbeddedStatment(BraceStyle braceStyle, BraceForcement braceForcement, CSharpTokenNode token, bool allowInLine, AstNode node, bool statementAlreadyIndented = false) { - if (node == null) - return null; - int originalLevel = curIndent.Level; + if (node == null) { + return; + } bool isBlock = node is BlockStatement; + TextReplaceAction beginBraceAction = null; + TextReplaceAction endBraceAction = null; + switch (braceForcement) { - case BraceForcement.DoNotChange: - //nothing - break; - case BraceForcement.AddBraces: - if (!isBlock) { - AstNode n = node.Parent.GetCSharpNodeBefore (node); - int start = document.GetOffset (n.EndLocation); - var next = n.GetNextNode (); - int offset = document.GetOffset (next.StartLocation); - string startBrace = ""; - switch (braceStyle) { - case BraceStyle.EndOfLineWithoutSpace: - startBrace = "{"; - break; - case BraceStyle.EndOfLine: - startBrace = " {"; - break; - case BraceStyle.NextLine: - startBrace = this.EolMarker + curIndent.IndentString + "{"; - break; - case BraceStyle.NextLineShifted2: - case BraceStyle.NextLineShifted: - startBrace = this.EolMarker + curIndent.IndentString + curIndent.SingleIndent + "{"; - break; + case BraceForcement.DoNotChange: + //nothing + break; + case BraceForcement.AddBraces: + if (!isBlock) { + AstNode n = node.Parent.GetCSharpNodeBefore(node); + int start = document.GetOffset(n.EndLocation); + string startBrace = ""; + switch (braceStyle) { + case BraceStyle.EndOfLineWithoutSpace: + startBrace = "{"; + break; + case BraceStyle.BannerStyle: + case BraceStyle.EndOfLine: + startBrace = " {"; + break; + case BraceStyle.NextLine: + startBrace = this.options.EolMarker + curIndent.IndentString + "{"; + break; + case BraceStyle.NextLineShifted2: + case BraceStyle.NextLineShifted: + curIndent.Push(IndentType.Block); + startBrace = this.options.EolMarker + curIndent.IndentString + "{"; + curIndent.Pop(); + break; + } + beginBraceAction = AddChange(start, 0, startBrace); } - if (IsLineIsEmptyUpToEol (document.GetOffset (node.StartLocation))) - startBrace += this.EolMarker + GetIndentation (node.StartLocation.Line); - AddChange (start, offset - start, startBrace); - } - break; - case BraceForcement.RemoveBraces: - if (isBlock) { - BlockStatement block = node as BlockStatement; - if (block.Statements.Count () == 1) { - int offset1 = document.GetOffset (node.StartLocation); - int start = SearchWhitespaceStart (offset1); - - int offset2 = document.GetOffset (node.EndLocation); - int end = SearchWhitespaceStart (offset2 - 1); - - AddChange (start, offset1 - start + 1, null); - AddChange (end + 1, offset2 - end, null); - node = block.FirstChild; - isBlock = false; + break; + case BraceForcement.RemoveBraces: + if (isBlock) { + BlockStatement block = node as BlockStatement; + if (block.Statements.Count() == 1) { + int offset1 = document.GetOffset(node.StartLocation); + int start = SearchWhitespaceStart(offset1); + + int offset2 = document.GetOffset(node.EndLocation); + int end = SearchWhitespaceStart(offset2 - 1); + + beginBraceAction = AddChange(start, offset1 - start + 1, null); + endBraceAction = AddChange(end + 1, offset2 - end, null); + node = block.FirstChild; + isBlock = false; + } } - } - break; + break; } if (isBlock) { BlockStatement block = node as BlockStatement; - if (allowInLine && block.StartLocation.Line == block.EndLocation.Line && block.Statements.Count () <= 1) { - if (block.Statements.Count () == 1) + if (allowInLine && block.StartLocation.Line == block.EndLocation.Line && block.Statements.Count() <= 1) { + if (block.Statements.Count() == 1) { nextStatementIndent = " "; + } } else { - EnforceBraceStyle (braceStyle, block.LBraceToken, block.RBraceToken); + if (!statementAlreadyIndented) { + EnforceBraceStyle(braceStyle, block.LBraceToken, block.RBraceToken); + } + } + if (braceStyle == BraceStyle.NextLineShifted2) { + curIndent.Push(IndentType.Block); } - if (braceStyle == BraceStyle.NextLineShifted2) - curIndent.Level++; } else { if (allowInLine && token.StartLocation.Line == node.EndLocation.Line) { nextStatementIndent = " "; } } - if (policy.IndentBlocks && - !(policy.AlignEmbeddedIfStatements && node is IfElseStatement && node.Parent is IfElseStatement || - policy.AlignEmbeddedUsingStatements && node is UsingStatement && node.Parent is UsingStatement)) - curIndent.Level++; - object result = isBlock ? base.VisitBlockStatement ((BlockStatement)node, null) : node.AcceptVisitor (this, null); - curIndent.Level = originalLevel; + if (policy.IndentBlocks && !(policy.AlignEmbeddedIfStatements && node is IfElseStatement && node.Parent is IfElseStatement || policy.AlignEmbeddedUsingStatements && node is UsingStatement && node.Parent is UsingStatement)) { + curIndent.Push(IndentType.Block); + } + if (isBlock) { + VisitBlockWithoutFixingBraces((BlockStatement)node, false); + } else { + if (!statementAlreadyIndented) { + FixStatementIndentation(node.StartLocation); + } + node.AcceptVisitor(this); + } + if (policy.IndentBlocks && !(policy.AlignEmbeddedIfStatements && node is IfElseStatement && node.Parent is IfElseStatement || policy.AlignEmbeddedUsingStatements && node is UsingStatement && node.Parent is UsingStatement)) { + curIndent.Pop(); + } switch (braceForcement) { - case BraceForcement.DoNotChange: - break; - case BraceForcement.AddBraces: - if (!isBlock) { - int offset = document.GetOffset (node.EndLocation); - if (!char.IsWhiteSpace (document.GetCharAt (offset))) - offset++; - string startBrace = ""; - switch (braceStyle) { - case BraceStyle.DoNotChange: - startBrace = null; - break; - case BraceStyle.EndOfLineWithoutSpace: - startBrace = this.EolMarker + curIndent.IndentString + "}"; - break; - case BraceStyle.EndOfLine: - startBrace = this.EolMarker + curIndent.IndentString + "}"; - break; - case BraceStyle.NextLine: - startBrace = this.EolMarker + curIndent.IndentString + "}"; - break; - case BraceStyle.NextLineShifted2: - case BraceStyle.NextLineShifted: - startBrace = this.EolMarker + curIndent.IndentString + curIndent.SingleIndent + "}"; - break; + case BraceForcement.DoNotChange: + break; + case BraceForcement.AddBraces: + if (!isBlock) { + int offset = document.GetOffset(node.EndLocation); + if (!char.IsWhiteSpace(document.GetCharAt(offset))) { + offset++; + } + string startBrace = ""; + switch (braceStyle) { + case BraceStyle.DoNotChange: + startBrace = null; + break; + case BraceStyle.EndOfLineWithoutSpace: + startBrace = this.options.EolMarker + curIndent.IndentString + "}"; + break; + case BraceStyle.EndOfLine: + startBrace = this.options.EolMarker + curIndent.IndentString + "}"; + break; + case BraceStyle.NextLine: + startBrace = this.options.EolMarker + curIndent.IndentString + "}"; + break; + case BraceStyle.BannerStyle: + case BraceStyle.NextLineShifted2: + case BraceStyle.NextLineShifted: + curIndent.Push(IndentType.Block); + startBrace = this.options.EolMarker + curIndent.IndentString + "}"; + curIndent.Pop (); + break; + + } + if (startBrace != null) { + endBraceAction = AddChange(offset, 0, startBrace); + } } - if (startBrace != null) - AddChange (offset, 0, startBrace); - } - break; + break; + } + if (beginBraceAction != null && endBraceAction != null) { + beginBraceAction.DependsOn = endBraceAction; + endBraceAction.DependsOn = beginBraceAction; } - return result; } - void EnforceBraceStyle (BraceStyle braceStyle, AstNode lbrace, AstNode rbrace) + void EnforceBraceStyle(BraceStyle braceStyle, AstNode lbrace, AstNode rbrace) { - if (lbrace.IsNull || rbrace.IsNull) + if (lbrace.IsNull || rbrace.IsNull) { return; + } -// LineSegment lbraceLineSegment = data.Document.GetLine (lbrace.StartLocation.Line); - int lbraceOffset = document.GetOffset (lbrace.StartLocation); + // LineSegment lbraceLineSegment = data.Document.GetLine (lbrace.StartLocation.Line); + int lbraceOffset = document.GetOffset(lbrace.StartLocation); -// LineSegment rbraceLineSegment = data.Document.GetLine (rbrace.StartLocation.Line); - int rbraceOffset = document.GetOffset (rbrace.StartLocation); - int whitespaceStart = SearchWhitespaceStart (lbraceOffset); - int whitespaceEnd = SearchWhitespaceLineStart (rbraceOffset); + // LineSegment rbraceLineSegment = data.Document.GetLine (rbrace.StartLocation.Line); + int rbraceOffset = document.GetOffset(rbrace.StartLocation); + int whitespaceStart = SearchWhitespaceStart(lbraceOffset); + int whitespaceEnd = SearchWhitespaceLineStart(rbraceOffset); string startIndent = ""; string endIndent = ""; switch (braceStyle) { - case BraceStyle.DoNotChange: - startIndent = endIndent = null; - break; - case BraceStyle.EndOfLineWithoutSpace: - startIndent = ""; - endIndent = IsLineIsEmptyUpToEol (rbraceOffset) ? curIndent.IndentString : this.EolMarker + curIndent.IndentString; - break; - case BraceStyle.EndOfLine: - var prevNode = lbrace.GetPrevNode (); - if (prevNode is Comment) { - // delete old bracket - AddChange (whitespaceStart, lbraceOffset - whitespaceStart + 1, ""); + case BraceStyle.DoNotChange: + startIndent = endIndent = null; + break; + case BraceStyle.EndOfLineWithoutSpace: + startIndent = ""; + endIndent = IsLineIsEmptyUpToEol(rbraceOffset) ? curIndent.IndentString : this.options.EolMarker + curIndent.IndentString; + break; + case BraceStyle.BannerStyle: + var prevNode = lbrace.GetPrevNode(); + if (prevNode is Comment) { + // delete old bracket + AddChange(whitespaceStart, lbraceOffset - whitespaceStart + 1, ""); - while (prevNode is Comment) { - prevNode = prevNode.GetPrevNode (); + while (prevNode is Comment) { + prevNode = prevNode.GetPrevNode(); + } + whitespaceStart = document.GetOffset(prevNode.EndLocation); + lbraceOffset = whitespaceStart; + startIndent = " {"; + } else { + startIndent = " "; } - whitespaceStart = document.GetOffset (prevNode.EndLocation); - lbraceOffset = whitespaceStart; - startIndent = " {"; - } else { - startIndent = " "; - } - endIndent = IsLineIsEmptyUpToEol (rbraceOffset) ? curIndent.IndentString : this.EolMarker + curIndent.IndentString; - break; - case BraceStyle.NextLine: - startIndent = this.EolMarker + curIndent.IndentString; - endIndent = IsLineIsEmptyUpToEol (rbraceOffset) ? curIndent.IndentString : this.EolMarker + curIndent.IndentString; - break; - case BraceStyle.NextLineShifted2: - case BraceStyle.NextLineShifted: - startIndent = this.EolMarker + curIndent.IndentString + curIndent.SingleIndent; - endIndent = IsLineIsEmptyUpToEol (rbraceOffset) ? curIndent.IndentString + curIndent.SingleIndent : this.EolMarker + curIndent.IndentString + curIndent.SingleIndent; - break; + curIndent.Push(IndentType.Block); + endIndent = IsLineIsEmptyUpToEol(rbraceOffset) ? curIndent.IndentString : this.options.EolMarker + curIndent.IndentString; + curIndent.Pop(); + break; + case BraceStyle.EndOfLine: + prevNode = lbrace.GetPrevNode(); + if (prevNode is Comment) { + // delete old bracket + AddChange(whitespaceStart, lbraceOffset - whitespaceStart + 1, ""); + + while (prevNode is Comment) { + prevNode = prevNode.GetPrevNode(); + } + whitespaceStart = document.GetOffset(prevNode.EndLocation); + lbraceOffset = whitespaceStart; + startIndent = " {"; + } else { + startIndent = " "; + } + endIndent = IsLineIsEmptyUpToEol(rbraceOffset) ? curIndent.IndentString : this.options.EolMarker + curIndent.IndentString; + break; + case BraceStyle.NextLine: + startIndent = this.options.EolMarker + curIndent.IndentString; + endIndent = IsLineIsEmptyUpToEol(rbraceOffset) ? curIndent.IndentString : this.options.EolMarker + curIndent.IndentString; + break; + case BraceStyle.NextLineShifted2: + case BraceStyle.NextLineShifted: + curIndent.Push(IndentType.Block); + startIndent = this.options.EolMarker + curIndent.IndentString; + endIndent = IsLineIsEmptyUpToEol(rbraceOffset) ? curIndent.IndentString : this.options.EolMarker + curIndent.IndentString; + curIndent.Pop (); + break; } - if (lbraceOffset > 0 && startIndent != null) - AddChange (whitespaceStart, lbraceOffset - whitespaceStart, startIndent); - if (rbraceOffset > 0 && endIndent != null) - AddChange (whitespaceEnd, rbraceOffset - whitespaceEnd, endIndent); + if (lbraceOffset > 0 && startIndent != null) { + AddChange(whitespaceStart, lbraceOffset - whitespaceStart, startIndent); + } + if (rbraceOffset > 0 && endIndent != null) { + AddChange(whitespaceEnd, rbraceOffset - whitespaceEnd, endIndent); + } } - void AddChange (int offset, int removedChars, string insertedText) + TextReplaceAction AddChange(int offset, int removedChars, string insertedText) { - if (changes.Any (c => c.Offset == offset && c.RemovedChars == removedChars - && c.InsertedText == insertedText)) - return; - string currentText = document.GetText (offset, removedChars); - if (currentText == insertedText) - return; - if (currentText.Any (c => !(char.IsWhiteSpace (c) || c == '\r' || c == '\t' || c == '{' || c == '}'))) - throw new InvalidOperationException ("Tried to remove non ws chars: '" + currentText + "'"); - foreach (var change in changes) { - if (change.Offset == offset) { - if (removedChars > 0 && insertedText == change.InsertedText) { - change.RemovedChars = removedChars; -// change.InsertedText = insertedText; - return; - } - if (!string.IsNullOrEmpty (change.InsertedText)) { - change.InsertedText += insertedText; - } else { - change.InsertedText = insertedText; - } - change.RemovedChars = System.Math.Max (removedChars, change.RemovedChars); - return; - } - } - //Console.WriteLine ("offset={0}, removedChars={1}, insertedText={2}", offset, removedChars, insertedText == null ? "" : insertedText.Replace ("\n", "\\n").Replace ("\r", "\\r").Replace ("\t", "\\t").Replace (" ", ".")); - //Console.WriteLine (Environment.StackTrace); - - changes.Add (factory.CreateTextReplaceAction (offset, removedChars, insertedText)); + var action = new TextReplaceAction (offset, removedChars, insertedText); + changes.Add(action); + return action; } - public bool IsLineIsEmptyUpToEol (TextLocation startLocation) + public bool IsLineIsEmptyUpToEol(TextLocation startLocation) { - return IsLineIsEmptyUpToEol (document.GetOffset (startLocation) - 1); + return IsLineIsEmptyUpToEol(document.GetOffset(startLocation) - 1); } - bool IsLineIsEmptyUpToEol (int startOffset) + bool IsLineIsEmptyUpToEol(int startOffset) { for (int offset = startOffset - 1; offset >= 0; offset--) { - char ch = document.GetCharAt (offset); - if (ch != ' ' && ch != '\t') + char ch = document.GetCharAt(offset); + if (ch != ' ' && ch != '\t') { return ch == '\n' || ch == '\r'; + } } return true; } - int SearchWhitespaceStart (int startOffset) + int SearchWhitespaceStart(int startOffset) { - if (startOffset < 0) + if (startOffset < 0) { throw new ArgumentOutOfRangeException ("startoffset", "value : " + startOffset); + } for (int offset = startOffset - 1; offset >= 0; offset--) { - char ch = document.GetCharAt (offset); - if (!Char.IsWhiteSpace (ch)) { + char ch = document.GetCharAt(offset); + if (!Char.IsWhiteSpace(ch)) { return offset + 1; } } return 0; } - int SearchWhitespaceEnd (int startOffset) + int SearchWhitespaceEnd(int startOffset) { - if (startOffset > document.TextLength) + if (startOffset > document.TextLength) { throw new ArgumentOutOfRangeException ("startoffset", "value : " + startOffset); + } for (int offset = startOffset + 1; offset < document.TextLength; offset++) { - char ch = document.GetCharAt (offset); - if (!Char.IsWhiteSpace (ch)) { + char ch = document.GetCharAt(offset); + if (!Char.IsWhiteSpace(ch)) { return offset + 1; } } return document.TextLength - 1; } - int SearchWhitespaceLineStart (int startOffset) + int SearchWhitespaceLineStart(int startOffset) { - if (startOffset < 0) + if (startOffset < 0) { throw new ArgumentOutOfRangeException ("startoffset", "value : " + startOffset); + } for (int offset = startOffset - 1; offset >= 0; offset--) { - char ch = document.GetCharAt (offset); + char ch = document.GetCharAt(offset); if (ch != ' ' && ch != '\t') { return offset + 1; } @@ -1056,469 +1237,520 @@ namespace ICSharpCode.NRefactory.CSharp return 0; } - public override object VisitForStatement (ForStatement forStatement, object data) + public override void VisitForStatement(ForStatement forStatement) { - FixStatementIndentation (forStatement.StartLocation); foreach (AstNode node in forStatement.Children) { - if (node.Role == ForStatement.Roles.Semicolon) { - if (node.NextSibling is CSharpTokenNode || node.NextSibling is EmptyStatement) + if (node.Role == Roles.Semicolon) { + if (node.NextSibling is CSharpTokenNode || node.NextSibling is EmptyStatement) { continue; - ForceSpacesBefore (node, policy.SpaceBeforeForSemicolon); - ForceSpacesAfter (node, policy.SpaceAfterForSemicolon); + } + ForceSpacesBefore(node, policy.SpaceBeforeForSemicolon); + ForceSpacesAfter(node, policy.SpaceAfterForSemicolon); } } - ForceSpacesBefore (forStatement.LParToken, policy.SpaceBeforeForParentheses); + ForceSpacesBefore(forStatement.LParToken, policy.SpaceBeforeForParentheses); - ForceSpacesAfter (forStatement.LParToken, policy.SpacesWithinForParentheses); - ForceSpacesBefore (forStatement.RParToken, policy.SpacesWithinForParentheses); + ForceSpacesAfter(forStatement.LParToken, policy.SpacesWithinForParentheses); + ForceSpacesBefore(forStatement.RParToken, policy.SpacesWithinForParentheses); - return FixEmbeddedStatment (policy.StatementBraceStyle, policy.ForBraceForcement, forStatement.EmbeddedStatement); + FixEmbeddedStatment(policy.StatementBraceStyle, policy.ForBraceForcement, forStatement.EmbeddedStatement); } - public override object VisitGotoStatement (GotoStatement gotoStatement, object data) + public override void VisitGotoStatement(GotoStatement gotoStatement) { - FixStatementIndentation (gotoStatement.StartLocation); - return VisitChildren (gotoStatement, data); + VisitChildren(gotoStatement); + FixSemicolon(gotoStatement.SemicolonToken); } - public override object VisitIfElseStatement (IfElseStatement ifElseStatement, object data) + public override void VisitIfElseStatement(IfElseStatement ifElseStatement) { - ForceSpacesBefore (ifElseStatement.LParToken, policy.SpaceBeforeIfParentheses); + ForceSpacesBefore(ifElseStatement.LParToken, policy.SpaceBeforeIfParentheses); - ForceSpacesAfter (ifElseStatement.LParToken, policy.SpacesWithinIfParentheses); - ForceSpacesBefore (ifElseStatement.RParToken, policy.SpacesWithinIfParentheses); + ForceSpacesAfter(ifElseStatement.LParToken, policy.SpacesWithinIfParentheses); + ForceSpacesBefore(ifElseStatement.RParToken, policy.SpacesWithinIfParentheses); - if (!(ifElseStatement.Parent is IfElseStatement && ((IfElseStatement)ifElseStatement.Parent).FalseStatement == ifElseStatement)) - FixStatementIndentation (ifElseStatement.StartLocation); + if (!(ifElseStatement.Parent is IfElseStatement && ((IfElseStatement)ifElseStatement.Parent).FalseStatement == ifElseStatement)) { + FixStatementIndentation(ifElseStatement.StartLocation); + } - if (!ifElseStatement.Condition.IsNull) - ifElseStatement.Condition.AcceptVisitor (this, data); + if (!ifElseStatement.Condition.IsNull) { + ifElseStatement.Condition.AcceptVisitor(this); + } - if (!ifElseStatement.TrueStatement.IsNull) - FixEmbeddedStatment (policy.StatementBraceStyle, policy.IfElseBraceForcement, ifElseStatement.IfToken, policy.AllowIfBlockInline, ifElseStatement.TrueStatement); + if (!ifElseStatement.TrueStatement.IsNull) { + FixEmbeddedStatment(policy.StatementBraceStyle, policy.IfElseBraceForcement, ifElseStatement.IfToken, policy.AllowIfBlockInline, ifElseStatement.TrueStatement); + } if (!ifElseStatement.FalseStatement.IsNull) { - PlaceOnNewLine (policy.PlaceElseOnNewLine || !(ifElseStatement.TrueStatement is BlockStatement) && policy.IfElseBraceForcement != BraceForcement.AddBraces, ifElseStatement.ElseToken); + PlaceOnNewLine(policy.PlaceElseOnNewLine || !(ifElseStatement.TrueStatement is BlockStatement) && policy.IfElseBraceForcement != BraceForcement.AddBraces, ifElseStatement.ElseToken); var forcement = policy.IfElseBraceForcement; if (ifElseStatement.FalseStatement is IfElseStatement) { forcement = BraceForcement.DoNotChange; - PlaceOnNewLine (policy.PlaceElseIfOnNewLine, ((IfElseStatement)ifElseStatement.FalseStatement).IfToken); + PlaceOnNewLine(policy.PlaceElseIfOnNewLine, ((IfElseStatement)ifElseStatement.FalseStatement).IfToken); } - FixEmbeddedStatment (policy.StatementBraceStyle, forcement, ifElseStatement.ElseToken, policy.AllowIfBlockInline, ifElseStatement.FalseStatement); + FixEmbeddedStatment(policy.StatementBraceStyle, forcement, ifElseStatement.ElseToken, policy.AllowIfBlockInline, ifElseStatement.FalseStatement, ifElseStatement.FalseStatement is IfElseStatement); } - - return null; } - public override object VisitLabelStatement (LabelStatement labelStatement, object data) + public override void VisitLabelStatement(LabelStatement labelStatement) { // TODO - return VisitChildren (labelStatement, data); + VisitChildren(labelStatement); } - public override object VisitLockStatement (LockStatement lockStatement, object data) + public override void VisitLockStatement(LockStatement lockStatement) { - FixStatementIndentation (lockStatement.StartLocation); - ForceSpacesBefore (lockStatement.LParToken, policy.SpaceBeforeLockParentheses); + ForceSpacesBefore(lockStatement.LParToken, policy.SpaceBeforeLockParentheses); - ForceSpacesAfter (lockStatement.LParToken, policy.SpacesWithinLockParentheses); - ForceSpacesBefore (lockStatement.RParToken, policy.SpacesWithinLockParentheses); + ForceSpacesAfter(lockStatement.LParToken, policy.SpacesWithinLockParentheses); + ForceSpacesBefore(lockStatement.RParToken, policy.SpacesWithinLockParentheses); - return FixEmbeddedStatment (policy.StatementBraceStyle, policy.FixedBraceForcement, lockStatement.EmbeddedStatement); + FixEmbeddedStatment(policy.StatementBraceStyle, policy.FixedBraceForcement, lockStatement.EmbeddedStatement); } - public override object VisitReturnStatement (ReturnStatement returnStatement, object data) + public override void VisitReturnStatement(ReturnStatement returnStatement) { - FixStatementIndentation (returnStatement.StartLocation); - return VisitChildren (returnStatement, data); + VisitChildren(returnStatement); + FixSemicolon(returnStatement.SemicolonToken); } - public override object VisitSwitchStatement (SwitchStatement switchStatement, object data) + public override void VisitSwitchStatement(SwitchStatement switchStatement) { - FixStatementIndentation (switchStatement.StartLocation); - ForceSpacesBefore (switchStatement.LParToken, policy.SpaceBeforeSwitchParentheses); + ForceSpacesBefore(switchStatement.LParToken, policy.SpaceBeforeSwitchParentheses); - ForceSpacesAfter (switchStatement.LParToken, policy.SpacesWithinSwitchParentheses); - ForceSpacesBefore (switchStatement.RParToken, policy.SpacesWithinSwitchParentheses); + ForceSpacesAfter(switchStatement.LParToken, policy.SpacesWithinSwitchParentheses); + ForceSpacesBefore(switchStatement.RParToken, policy.SpacesWithinSwitchParentheses); - EnforceBraceStyle (policy.StatementBraceStyle, switchStatement.LBraceToken, switchStatement.RBraceToken); - object result = VisitChildren (switchStatement, data); - return result; + EnforceBraceStyle(policy.StatementBraceStyle, switchStatement.LBraceToken, switchStatement.RBraceToken); + VisitChildren(switchStatement); } - public override object VisitSwitchSection (SwitchSection switchSection, object data) + public override void VisitSwitchSection(SwitchSection switchSection) { - if (policy.IndentSwitchBody) - curIndent.Level++; + if (policy.IndentSwitchBody) { + curIndent.Push(IndentType.Block); + } foreach (CaseLabel label in switchSection.CaseLabels) { - FixStatementIndentation (label.StartLocation); + FixStatementIndentation(label.StartLocation); + label.AcceptVisitor(this); + } + if (policy.IndentCaseBody) { + curIndent.Push(IndentType.Block); } - if (policy.IndentCaseBody) - curIndent.Level++; foreach (var stmt in switchSection.Statements) { if (stmt is BreakStatement && !policy.IndentBreakStatements && policy.IndentCaseBody) { - curIndent.Level--; - stmt.AcceptVisitor (this, null); - curIndent.Level++; + curIndent.Pop(); + FixStatementIndentation(stmt.StartLocation); + stmt.AcceptVisitor(this); + curIndent.Push(IndentType.Block); continue; } - stmt.AcceptVisitor (this, null); + FixStatementIndentation(stmt.StartLocation); + stmt.AcceptVisitor(this); + } + if (policy.IndentCaseBody) { + curIndent.Pop (); + } + + if (policy.IndentSwitchBody) { + curIndent.Pop (); } - if (policy.IndentCaseBody) - curIndent.Level--; - - if (policy.IndentSwitchBody) - curIndent.Level--; - return null; } - public override object VisitCaseLabel (CaseLabel caseLabel, object data) + public override void VisitCaseLabel(CaseLabel caseLabel) { - // handled in switchsection - return null; + FixSemicolon(caseLabel.ColonToken); } - public override object VisitThrowStatement (ThrowStatement throwStatement, object data) + public override void VisitThrowStatement(ThrowStatement throwStatement) { - FixStatementIndentation (throwStatement.StartLocation); - return VisitChildren (throwStatement, data); + VisitChildren(throwStatement); + FixSemicolon(throwStatement.SemicolonToken); } - public override object VisitTryCatchStatement (TryCatchStatement tryCatchStatement, object data) + public override void VisitTryCatchStatement(TryCatchStatement tryCatchStatement) { - FixStatementIndentation (tryCatchStatement.StartLocation); - - if (!tryCatchStatement.TryBlock.IsNull) - FixEmbeddedStatment (policy.StatementBraceStyle, BraceForcement.DoNotChange, tryCatchStatement.TryBlock); + if (!tryCatchStatement.TryBlock.IsNull) { + FixEmbeddedStatment(policy.StatementBraceStyle, BraceForcement.DoNotChange, tryCatchStatement.TryBlock); + } foreach (CatchClause clause in tryCatchStatement.CatchClauses) { - PlaceOnNewLine (policy.PlaceCatchOnNewLine, clause.CatchToken); + PlaceOnNewLine(policy.PlaceCatchOnNewLine, clause.CatchToken); if (!clause.LParToken.IsNull) { - ForceSpacesBefore (clause.LParToken, policy.SpaceBeforeCatchParentheses); + ForceSpacesBefore(clause.LParToken, policy.SpaceBeforeCatchParentheses); - ForceSpacesAfter (clause.LParToken, policy.SpacesWithinCatchParentheses); - ForceSpacesBefore (clause.RParToken, policy.SpacesWithinCatchParentheses); + ForceSpacesAfter(clause.LParToken, policy.SpacesWithinCatchParentheses); + ForceSpacesBefore(clause.RParToken, policy.SpacesWithinCatchParentheses); } - FixEmbeddedStatment (policy.StatementBraceStyle, BraceForcement.DoNotChange, clause.Body); + FixEmbeddedStatment(policy.StatementBraceStyle, BraceForcement.DoNotChange, clause.Body); } if (!tryCatchStatement.FinallyBlock.IsNull) { - PlaceOnNewLine (policy.PlaceFinallyOnNewLine, tryCatchStatement.FinallyToken); + PlaceOnNewLine(policy.PlaceFinallyOnNewLine, tryCatchStatement.FinallyToken); - FixEmbeddedStatment (policy.StatementBraceStyle, BraceForcement.DoNotChange, tryCatchStatement.FinallyBlock); + FixEmbeddedStatment(policy.StatementBraceStyle, BraceForcement.DoNotChange, tryCatchStatement.FinallyBlock); } - return VisitChildren (tryCatchStatement, data); } - public override object VisitCatchClause (CatchClause catchClause, object data) + public override void VisitCatchClause(CatchClause catchClause) { // Handled in TryCatchStatement - return null; } - public override object VisitUncheckedStatement (UncheckedStatement uncheckedStatement, object data) + public override void VisitUncheckedStatement(UncheckedStatement uncheckedStatement) { - FixStatementIndentation (uncheckedStatement.StartLocation); - return FixEmbeddedStatment (policy.StatementBraceStyle, policy.FixedBraceForcement, uncheckedStatement.Body); + FixEmbeddedStatment(policy.StatementBraceStyle, policy.FixedBraceForcement, uncheckedStatement.Body); } - public override object VisitUnsafeStatement (UnsafeStatement unsafeStatement, object data) + public override void VisitUnsafeStatement(UnsafeStatement unsafeStatement) { - FixStatementIndentation (unsafeStatement.StartLocation); - return FixEmbeddedStatment (policy.StatementBraceStyle, BraceForcement.DoNotChange, unsafeStatement.Body); + FixEmbeddedStatment(policy.StatementBraceStyle, BraceForcement.DoNotChange, unsafeStatement.Body); } - public override object VisitUsingStatement (UsingStatement usingStatement, object data) + public override void VisitUsingStatement(UsingStatement usingStatement) { - FixStatementIndentation (usingStatement.StartLocation); - ForceSpacesBefore (usingStatement.LParToken, policy.SpaceBeforeUsingParentheses); + ForceSpacesBefore(usingStatement.LParToken, policy.SpaceBeforeUsingParentheses); - ForceSpacesAfter (usingStatement.LParToken, policy.SpacesWithinUsingParentheses); - ForceSpacesBefore (usingStatement.RParToken, policy.SpacesWithinUsingParentheses); + ForceSpacesAfter(usingStatement.LParToken, policy.SpacesWithinUsingParentheses); + ForceSpacesBefore(usingStatement.RParToken, policy.SpacesWithinUsingParentheses); - return FixEmbeddedStatment (policy.StatementBraceStyle, policy.UsingBraceForcement, usingStatement.EmbeddedStatement); + FixEmbeddedStatment(policy.StatementBraceStyle, policy.UsingBraceForcement, usingStatement.EmbeddedStatement); } - public override object VisitVariableDeclarationStatement (VariableDeclarationStatement variableDeclarationStatement, object data) + public override void VisitVariableDeclarationStatement(VariableDeclarationStatement variableDeclarationStatement) { - if (!variableDeclarationStatement.SemicolonToken.IsNull) - FixStatementIndentation (variableDeclarationStatement.StartLocation); - if ((variableDeclarationStatement.Modifiers & Modifiers.Const) == Modifiers.Const) { - ForceSpacesAround (variableDeclarationStatement.Type, true); + ForceSpacesAround(variableDeclarationStatement.Type, true); } else { - ForceSpacesAfter (variableDeclarationStatement.Type, true); + ForceSpacesAfter(variableDeclarationStatement.Type, true); } + var lastLoc = variableDeclarationStatement.StartLocation; foreach (var initializer in variableDeclarationStatement.Variables) { - initializer.AcceptVisitor (this, data); + if (lastLoc.Line != initializer.StartLocation.Line) { + FixStatementIndentation(initializer.StartLocation); + lastLoc = initializer.StartLocation; + } + initializer.AcceptVisitor(this); } - FormatCommas (variableDeclarationStatement, policy.SpaceBeforeLocalVariableDeclarationComma, policy.SpaceAfterLocalVariableDeclarationComma); - FixSemicolon (variableDeclarationStatement.SemicolonToken); - return null; + + FormatCommas(variableDeclarationStatement, policy.SpaceBeforeLocalVariableDeclarationComma, policy.SpaceAfterLocalVariableDeclarationComma); + FixSemicolon(variableDeclarationStatement.SemicolonToken); } - public override object VisitDoWhileStatement (DoWhileStatement doWhileStatement, object data) + public override void VisitDoWhileStatement(DoWhileStatement doWhileStatement) { - FixStatementIndentation (doWhileStatement.StartLocation); - PlaceOnNewLine (policy.PlaceWhileOnNewLine, doWhileStatement.WhileToken); - return FixEmbeddedStatment (policy.StatementBraceStyle, policy.WhileBraceForcement, doWhileStatement.EmbeddedStatement); + PlaceOnNewLine(policy.PlaceWhileOnNewLine, doWhileStatement.WhileToken); + FixEmbeddedStatment(policy.StatementBraceStyle, policy.WhileBraceForcement, doWhileStatement.EmbeddedStatement); } - public override object VisitWhileStatement (WhileStatement whileStatement, object data) + public override void VisitWhileStatement(WhileStatement whileStatement) { - FixStatementIndentation (whileStatement.StartLocation); - ForceSpacesBefore (whileStatement.LParToken, policy.SpaceBeforeWhileParentheses); + ForceSpacesBefore(whileStatement.LParToken, policy.SpaceBeforeWhileParentheses); - ForceSpacesAfter (whileStatement.LParToken, policy.SpacesWithinWhileParentheses); - ForceSpacesBefore (whileStatement.RParToken, policy.SpacesWithinWhileParentheses); + ForceSpacesAfter(whileStatement.LParToken, policy.SpacesWithinWhileParentheses); + ForceSpacesBefore(whileStatement.RParToken, policy.SpacesWithinWhileParentheses); - return FixEmbeddedStatment (policy.StatementBraceStyle, policy.WhileBraceForcement, whileStatement.EmbeddedStatement); + FixEmbeddedStatment(policy.StatementBraceStyle, policy.WhileBraceForcement, whileStatement.EmbeddedStatement); } - public override object VisitYieldBreakStatement (YieldBreakStatement yieldBreakStatement, object data) + public override void VisitYieldBreakStatement(YieldBreakStatement yieldBreakStatement) { - FixStatementIndentation (yieldBreakStatement.StartLocation); - return null; + FixSemicolon(yieldBreakStatement.SemicolonToken); } - public override object VisitYieldReturnStatement (YieldReturnStatement yieldStatement, object data) + public override void VisitYieldReturnStatement(YieldReturnStatement yieldStatement) { - FixStatementIndentation (yieldStatement.StartLocation); - return null; + yieldStatement.Expression.AcceptVisitor(this); + FixSemicolon(yieldStatement.SemicolonToken); } - public override object VisitVariableInitializer (VariableInitializer variableInitializer, object data) + public override void VisitVariableInitializer(VariableInitializer variableInitializer) { - if (!variableInitializer.AssignToken.IsNull) - ForceSpacesAround (variableInitializer.AssignToken, policy.SpaceAroundAssignment); - if (!variableInitializer.Initializer.IsNull) - variableInitializer.Initializer.AcceptVisitor (this, data); - return data; + if (!variableInitializer.AssignToken.IsNull) { + ForceSpacesAround(variableInitializer.AssignToken, policy.SpaceAroundAssignment); + } + if (!variableInitializer.Initializer.IsNull) { + variableInitializer.Initializer.AcceptVisitor(this); + } } #endregion #region Expressions - public override object VisitComposedType (ComposedType composedType, object data) + public override void VisitComposedType(ComposedType composedType) { - var spec = composedType.ArraySpecifiers.FirstOrDefault (); - if (spec != null) - ForceSpacesBefore (spec.LBracketToken, policy.SpaceBeforeArrayDeclarationBrackets); + var spec = composedType.ArraySpecifiers.FirstOrDefault(); + if (spec != null) { + ForceSpacesBefore(spec.LBracketToken, policy.SpaceBeforeArrayDeclarationBrackets); + } - return base.VisitComposedType (composedType, data); + base.VisitComposedType(composedType); } - public override object VisitAssignmentExpression (AssignmentExpression assignmentExpression, object data) + public override void VisitAnonymousMethodExpression(AnonymousMethodExpression anonymousMethodExpression) { - ForceSpacesAround (assignmentExpression.OperatorToken, policy.SpaceAroundAssignment); - return base.VisitAssignmentExpression (assignmentExpression, data); + if (!anonymousMethodExpression.Body.IsNull) { + EnforceBraceStyle(policy.AnonymousMethodBraceStyle, anonymousMethodExpression.Body.LBraceToken, anonymousMethodExpression.Body.RBraceToken); + } + base.VisitAnonymousMethodExpression(anonymousMethodExpression); } - public override object VisitBinaryOperatorExpression (BinaryOperatorExpression binaryOperatorExpression, object data) + public override void VisitAssignmentExpression(AssignmentExpression assignmentExpression) + { + ForceSpacesAround(assignmentExpression.OperatorToken, policy.SpaceAroundAssignment); + base.VisitAssignmentExpression(assignmentExpression); + } + + public override void VisitBinaryOperatorExpression(BinaryOperatorExpression binaryOperatorExpression) { bool forceSpaces = false; switch (binaryOperatorExpression.Operator) { - case BinaryOperatorType.Equality: - case BinaryOperatorType.InEquality: - forceSpaces = policy.SpaceAroundEqualityOperator; - break; - case BinaryOperatorType.GreaterThan: - case BinaryOperatorType.GreaterThanOrEqual: - case BinaryOperatorType.LessThan: - case BinaryOperatorType.LessThanOrEqual: - forceSpaces = policy.SpaceAroundRelationalOperator; - break; - case BinaryOperatorType.ConditionalAnd: - case BinaryOperatorType.ConditionalOr: - forceSpaces = policy.SpaceAroundLogicalOperator; - break; - case BinaryOperatorType.BitwiseAnd: - case BinaryOperatorType.BitwiseOr: - case BinaryOperatorType.ExclusiveOr: - forceSpaces = policy.SpaceAroundBitwiseOperator; - break; - case BinaryOperatorType.Add: - case BinaryOperatorType.Subtract: - forceSpaces = policy.SpaceAroundAdditiveOperator; - break; - case BinaryOperatorType.Multiply: - case BinaryOperatorType.Divide: - case BinaryOperatorType.Modulus: - forceSpaces = policy.SpaceAroundMultiplicativeOperator; - break; - case BinaryOperatorType.ShiftLeft: - case BinaryOperatorType.ShiftRight: - forceSpaces = policy.SpaceAroundShiftOperator; - break; - case BinaryOperatorType.NullCoalescing: - forceSpaces = policy.SpaceAroundNullCoalescingOperator; - break; - } - ForceSpacesAround (binaryOperatorExpression.OperatorToken, forceSpaces); - - return base.VisitBinaryOperatorExpression (binaryOperatorExpression, data); - } - - public override object VisitConditionalExpression (ConditionalExpression conditionalExpression, object data) - { - ForceSpacesBefore (conditionalExpression.QuestionMarkToken, policy.SpaceBeforeConditionalOperatorCondition); - ForceSpacesAfter (conditionalExpression.QuestionMarkToken, policy.SpaceAfterConditionalOperatorCondition); - ForceSpacesBefore (conditionalExpression.ColonToken, policy.SpaceBeforeConditionalOperatorSeparator); - ForceSpacesAfter (conditionalExpression.ColonToken, policy.SpaceAfterConditionalOperatorSeparator); - return base.VisitConditionalExpression (conditionalExpression, data); - } - - public override object VisitCastExpression (CastExpression castExpression, object data) + case BinaryOperatorType.Equality: + case BinaryOperatorType.InEquality: + forceSpaces = policy.SpaceAroundEqualityOperator; + break; + case BinaryOperatorType.GreaterThan: + case BinaryOperatorType.GreaterThanOrEqual: + case BinaryOperatorType.LessThan: + case BinaryOperatorType.LessThanOrEqual: + forceSpaces = policy.SpaceAroundRelationalOperator; + break; + case BinaryOperatorType.ConditionalAnd: + case BinaryOperatorType.ConditionalOr: + forceSpaces = policy.SpaceAroundLogicalOperator; + break; + case BinaryOperatorType.BitwiseAnd: + case BinaryOperatorType.BitwiseOr: + case BinaryOperatorType.ExclusiveOr: + forceSpaces = policy.SpaceAroundBitwiseOperator; + break; + case BinaryOperatorType.Add: + case BinaryOperatorType.Subtract: + forceSpaces = policy.SpaceAroundAdditiveOperator; + break; + case BinaryOperatorType.Multiply: + case BinaryOperatorType.Divide: + case BinaryOperatorType.Modulus: + forceSpaces = policy.SpaceAroundMultiplicativeOperator; + break; + case BinaryOperatorType.ShiftLeft: + case BinaryOperatorType.ShiftRight: + forceSpaces = policy.SpaceAroundShiftOperator; + break; + case BinaryOperatorType.NullCoalescing: + forceSpaces = policy.SpaceAroundNullCoalescingOperator; + break; + } + ForceSpacesAround(binaryOperatorExpression.OperatorToken, forceSpaces); + + base.VisitBinaryOperatorExpression(binaryOperatorExpression); + // Handle line breaks in binary opeartor expression. + if (binaryOperatorExpression.Left.EndLocation.Line != binaryOperatorExpression.Right.StartLocation.Line) { + curIndent.Push(IndentType.Block); + if (binaryOperatorExpression.OperatorToken.StartLocation.Line == binaryOperatorExpression.Right.StartLocation.Line) { + FixStatementIndentation(binaryOperatorExpression.OperatorToken.StartLocation); + } else { + FixStatementIndentation(binaryOperatorExpression.Right.StartLocation); + } + curIndent.Pop (); + } + } + + public override void VisitConditionalExpression(ConditionalExpression conditionalExpression) + { + ForceSpacesBefore(conditionalExpression.QuestionMarkToken, policy.SpaceBeforeConditionalOperatorCondition); + ForceSpacesAfter(conditionalExpression.QuestionMarkToken, policy.SpaceAfterConditionalOperatorCondition); + ForceSpacesBefore(conditionalExpression.ColonToken, policy.SpaceBeforeConditionalOperatorSeparator); + ForceSpacesAfter(conditionalExpression.ColonToken, policy.SpaceAfterConditionalOperatorSeparator); + base.VisitConditionalExpression(conditionalExpression); + } + + public override void VisitCastExpression(CastExpression castExpression) { if (castExpression.RParToken != null) { - ForceSpacesAfter (castExpression.LParToken, policy.SpacesWithinCastParentheses); - ForceSpacesBefore (castExpression.RParToken, policy.SpacesWithinCastParentheses); + ForceSpacesAfter(castExpression.LParToken, policy.SpacesWithinCastParentheses); + ForceSpacesBefore(castExpression.RParToken, policy.SpacesWithinCastParentheses); - ForceSpacesAfter (castExpression.RParToken, policy.SpaceAfterTypecast); + ForceSpacesAfter(castExpression.RParToken, policy.SpaceAfterTypecast); } - return base.VisitCastExpression (castExpression, data); + base.VisitCastExpression(castExpression); } - void ForceSpacesAround (AstNode node, bool forceSpaces) + void ForceSpacesAround(AstNode node, bool forceSpaces) { - if (node.IsNull) + if (node.IsNull) { return; - ForceSpacesBefore (node, forceSpaces); - ForceSpacesAfter (node, forceSpaces); + } + ForceSpacesBefore(node, forceSpaces); + ForceSpacesAfter(node, forceSpaces); } - void FormatCommas (AstNode parent, bool before, bool after) + void FormatCommas(AstNode parent, bool before, bool after) { - if (parent.IsNull) + if (parent.IsNull) { return; - foreach (CSharpTokenNode comma in parent.Children.Where (node => node.Role == FieldDeclaration.Roles.Comma)) { - ForceSpacesAfter (comma, after); - ForceSpacesBefore (comma, before); + } + foreach (CSharpTokenNode comma in parent.Children.Where (node => node.Role == Roles.Comma)) { + ForceSpacesAfter(comma, after); + ForceSpacesBefore(comma, before); } } - public override object VisitInvocationExpression (InvocationExpression invocationExpression, object data) + public override void VisitInvocationExpression(InvocationExpression invocationExpression) { - ForceSpacesBefore (invocationExpression.LParToken, policy.SpaceBeforeMethodCallParentheses); - if (invocationExpression.Arguments.Any ()) { - ForceSpacesAfter (invocationExpression.LParToken, policy.SpaceWithinMethodCallParentheses); - ForceSpacesBefore (invocationExpression.RParToken, policy.SpaceWithinMethodCallParentheses); + ForceSpacesBefore(invocationExpression.LParToken, policy.SpaceBeforeMethodCallParentheses); + if (invocationExpression.Arguments.Any()) { + ForceSpacesAfter(invocationExpression.LParToken, policy.SpaceWithinMethodCallParentheses); + ForceSpacesBefore(invocationExpression.RParToken, policy.SpaceWithinMethodCallParentheses); } else { - ForceSpacesAfter (invocationExpression.LParToken, policy.SpaceBetweenEmptyMethodCallParentheses); - ForceSpacesBefore (invocationExpression.RParToken, policy.SpaceBetweenEmptyMethodCallParentheses); + ForceSpacesAfter(invocationExpression.LParToken, policy.SpaceBetweenEmptyMethodCallParentheses); + ForceSpacesBefore(invocationExpression.RParToken, policy.SpaceBetweenEmptyMethodCallParentheses); } - FormatCommas (invocationExpression, policy.SpaceBeforeMethodCallParameterComma, policy.SpaceAfterMethodCallParameterComma); + FormatCommas(invocationExpression, policy.SpaceBeforeMethodCallParameterComma, policy.SpaceAfterMethodCallParameterComma); - return base.VisitInvocationExpression (invocationExpression, data); + base.VisitInvocationExpression(invocationExpression); } - public override object VisitIndexerExpression (IndexerExpression indexerExpression, object data) + public override void VisitIndexerExpression(IndexerExpression indexerExpression) { - ForceSpacesBefore (indexerExpression.LBracketToken, policy.SpacesBeforeBrackets); - ForceSpacesAfter (indexerExpression.LBracketToken, policy.SpacesWithinBrackets); - ForceSpacesBefore (indexerExpression.RBracketToken, policy.SpacesWithinBrackets); - FormatCommas (indexerExpression, policy.SpaceBeforeBracketComma, policy.SpaceAfterBracketComma); + ForceSpacesBefore(indexerExpression.LBracketToken, policy.SpacesBeforeBrackets); + ForceSpacesAfter(indexerExpression.LBracketToken, policy.SpacesWithinBrackets); + ForceSpacesBefore(indexerExpression.RBracketToken, policy.SpacesWithinBrackets); + FormatCommas(indexerExpression, policy.SpaceBeforeBracketComma, policy.SpaceAfterBracketComma); - return base.VisitIndexerExpression (indexerExpression, data); + base.VisitIndexerExpression(indexerExpression); } - public override object VisitParenthesizedExpression (ParenthesizedExpression parenthesizedExpression, object data) + public override void VisitParenthesizedExpression(ParenthesizedExpression parenthesizedExpression) { - ForceSpacesAfter (parenthesizedExpression.LParToken, policy.SpacesWithinParentheses); - ForceSpacesBefore (parenthesizedExpression.RParToken, policy.SpacesWithinParentheses); - return base.VisitParenthesizedExpression (parenthesizedExpression, data); + ForceSpacesAfter(parenthesizedExpression.LParToken, policy.SpacesWithinParentheses); + ForceSpacesBefore(parenthesizedExpression.RParToken, policy.SpacesWithinParentheses); + base.VisitParenthesizedExpression(parenthesizedExpression); } - public override object VisitSizeOfExpression (SizeOfExpression sizeOfExpression, object data) + public override void VisitSizeOfExpression(SizeOfExpression sizeOfExpression) { - ForceSpacesBefore (sizeOfExpression.LParToken, policy.SpaceBeforeSizeOfParentheses); - ForceSpacesAfter (sizeOfExpression.LParToken, policy.SpacesWithinSizeOfParentheses); - ForceSpacesBefore (sizeOfExpression.RParToken, policy.SpacesWithinSizeOfParentheses); - return base.VisitSizeOfExpression (sizeOfExpression, data); + ForceSpacesBefore(sizeOfExpression.LParToken, policy.SpaceBeforeSizeOfParentheses); + ForceSpacesAfter(sizeOfExpression.LParToken, policy.SpacesWithinSizeOfParentheses); + ForceSpacesBefore(sizeOfExpression.RParToken, policy.SpacesWithinSizeOfParentheses); + base.VisitSizeOfExpression(sizeOfExpression); } - public override object VisitTypeOfExpression (TypeOfExpression typeOfExpression, object data) + public override void VisitTypeOfExpression(TypeOfExpression typeOfExpression) { - ForceSpacesBefore (typeOfExpression.LParToken, policy.SpaceBeforeTypeOfParentheses); - ForceSpacesAfter (typeOfExpression.LParToken, policy.SpacesWithinTypeOfParentheses); - ForceSpacesBefore (typeOfExpression.RParToken, policy.SpacesWithinTypeOfParentheses); - return base.VisitTypeOfExpression (typeOfExpression, data); + ForceSpacesBefore(typeOfExpression.LParToken, policy.SpaceBeforeTypeOfParentheses); + ForceSpacesAfter(typeOfExpression.LParToken, policy.SpacesWithinTypeOfParentheses); + ForceSpacesBefore(typeOfExpression.RParToken, policy.SpacesWithinTypeOfParentheses); + base.VisitTypeOfExpression(typeOfExpression); } - public override object VisitCheckedExpression (CheckedExpression checkedExpression, object data) + public override void VisitCheckedExpression(CheckedExpression checkedExpression) { - ForceSpacesAfter (checkedExpression.LParToken, policy.SpacesWithinCheckedExpressionParantheses); - ForceSpacesBefore (checkedExpression.RParToken, policy.SpacesWithinCheckedExpressionParantheses); - return base.VisitCheckedExpression (checkedExpression, data); + ForceSpacesAfter(checkedExpression.LParToken, policy.SpacesWithinCheckedExpressionParantheses); + ForceSpacesBefore(checkedExpression.RParToken, policy.SpacesWithinCheckedExpressionParantheses); + base.VisitCheckedExpression(checkedExpression); } - public override object VisitUncheckedExpression (UncheckedExpression uncheckedExpression, object data) + public override void VisitUncheckedExpression(UncheckedExpression uncheckedExpression) { - ForceSpacesAfter (uncheckedExpression.LParToken, policy.SpacesWithinCheckedExpressionParantheses); - ForceSpacesBefore (uncheckedExpression.RParToken, policy.SpacesWithinCheckedExpressionParantheses); - return base.VisitUncheckedExpression (uncheckedExpression, data); + ForceSpacesAfter(uncheckedExpression.LParToken, policy.SpacesWithinCheckedExpressionParantheses); + ForceSpacesBefore(uncheckedExpression.RParToken, policy.SpacesWithinCheckedExpressionParantheses); + base.VisitUncheckedExpression(uncheckedExpression); } - public override object VisitObjectCreateExpression (ObjectCreateExpression objectCreateExpression, object data) + public override void VisitObjectCreateExpression(ObjectCreateExpression objectCreateExpression) { - ForceSpacesBefore (objectCreateExpression.LParToken, policy.SpaceBeforeNewParentheses); + ForceSpacesBefore(objectCreateExpression.LParToken, policy.SpaceBeforeNewParentheses); - if (objectCreateExpression.Arguments.Any ()) { - if (!objectCreateExpression.LParToken.IsNull) - ForceSpacesAfter (objectCreateExpression.LParToken, policy.SpacesWithinNewParentheses); - if (!objectCreateExpression.RParToken.IsNull) - ForceSpacesBefore (objectCreateExpression.RParToken, policy.SpacesWithinNewParentheses); + if (objectCreateExpression.Arguments.Any()) { + if (!objectCreateExpression.LParToken.IsNull) { + ForceSpacesAfter(objectCreateExpression.LParToken, policy.SpacesWithinNewParentheses); + } + if (!objectCreateExpression.RParToken.IsNull) { + ForceSpacesBefore(objectCreateExpression.RParToken, policy.SpacesWithinNewParentheses); + } } else { - if (!objectCreateExpression.LParToken.IsNull) - ForceSpacesAfter (objectCreateExpression.LParToken, policy.SpacesBetweenEmptyNewParentheses); - if (!objectCreateExpression.RParToken.IsNull) - ForceSpacesBefore (objectCreateExpression.RParToken, policy.SpacesBetweenEmptyNewParentheses); + if (!objectCreateExpression.LParToken.IsNull) { + ForceSpacesAfter(objectCreateExpression.LParToken, policy.SpacesBetweenEmptyNewParentheses); + } + if (!objectCreateExpression.RParToken.IsNull) { + ForceSpacesBefore(objectCreateExpression.RParToken, policy.SpacesBetweenEmptyNewParentheses); + } } - FormatCommas (objectCreateExpression, policy.SpaceBeforeNewParameterComma, policy.SpaceAfterNewParameterComma); + FormatCommas(objectCreateExpression, policy.SpaceBeforeNewParameterComma, policy.SpaceAfterNewParameterComma); - return base.VisitObjectCreateExpression (objectCreateExpression, data); + base.VisitObjectCreateExpression(objectCreateExpression); } - public override object VisitArrayCreateExpression (ArrayCreateExpression arrayObjectCreateExpression, object data) + public override void VisitArrayCreateExpression(ArrayCreateExpression arrayObjectCreateExpression) { - FormatCommas (arrayObjectCreateExpression, policy.SpaceBeforeMethodCallParameterComma, policy.SpaceAfterMethodCallParameterComma); - return base.VisitArrayCreateExpression (arrayObjectCreateExpression, data); + FormatCommas(arrayObjectCreateExpression, policy.SpaceBeforeMethodCallParameterComma, policy.SpaceAfterMethodCallParameterComma); + base.VisitArrayCreateExpression(arrayObjectCreateExpression); } - public override object VisitLambdaExpression (LambdaExpression lambdaExpression, object data) + public override void VisitArrayInitializerExpression(ArrayInitializerExpression arrayInitializerExpression) { - ForceSpacesAfter (lambdaExpression.ArrowToken, true); - ForceSpacesBefore (lambdaExpression.ArrowToken, true); + if (policy.ArrayInitializerWrapping == Wrapping.WrapAlways) { + EnforceBraceStyle(policy.ArrayInitializerBraceStyle, arrayInitializerExpression.LBraceToken, arrayInitializerExpression.RBraceToken); + curIndent.Push(IndentType.Block); + foreach (var init in arrayInitializerExpression.Elements) { + FixStatementIndentation(init.StartLocation); + init.AcceptVisitor(this); + } + curIndent.Pop(); + } else if (policy.ArrayInitializerWrapping == Wrapping.DoNotWrap) { + ForceSpacesBeforeRemoveNewLines(arrayInitializerExpression.LBraceToken); + ForceSpacesBeforeRemoveNewLines(arrayInitializerExpression.RBraceToken); + foreach (var init in arrayInitializerExpression.Elements) { + ForceSpacesBeforeRemoveNewLines(init); + init.AcceptVisitor(this); + } + } else { + base.VisitArrayInitializerExpression(arrayInitializerExpression); + } + } + + public override void VisitLambdaExpression(LambdaExpression lambdaExpression) + { + ForceSpacesAfter(lambdaExpression.ArrowToken, true); + ForceSpacesBefore(lambdaExpression.ArrowToken, true); - return base.VisitLambdaExpression (lambdaExpression, data); + base.VisitLambdaExpression(lambdaExpression); + } + + public override void VisitNamedArgumentExpression(NamedArgumentExpression namedArgumentExpression) + { + ForceSpacesAfter(namedArgumentExpression.ColonToken, policy.SpaceInNamedArgumentAfterDoubleColon); + base.VisitNamedArgumentExpression(namedArgumentExpression); } #endregion - void ForceSpaceBefore (int offset, bool forceSpace) + void ForceSpaceBefore(int offset, bool forceSpace) { bool insertedSpace = false; do { - char ch = document.GetCharAt (offset); + char ch = document.GetCharAt(offset); //Console.WriteLine (ch); - if (!IsSpacing (ch) && (insertedSpace || !forceSpace)) + if (!IsSpacing(ch) && (insertedSpace || !forceSpace)) { break; + } if (ch == ' ' && forceSpace) { if (insertedSpace) { - AddChange (offset, 1, null); + AddChange(offset, 1, null); } else { insertedSpace = true; } } else if (forceSpace) { if (!insertedSpace) { - AddChange (offset, IsSpacing (ch) ? 1 : 0, " "); + AddChange(offset, IsSpacing(ch) ? 1 : 0, " "); insertedSpace = true; - } else if (IsSpacing (ch)) { - AddChange (offset, 1, null); + } else if (IsSpacing(ch)) { + AddChange(offset, 1, null); } } @@ -1554,90 +1786,93 @@ namespace ICSharpCode.NRefactory.CSharp } return result; } - */ + */ - public void FixSemicolon (CSharpTokenNode semicolon) + public void FixSemicolon(CSharpTokenNode semicolon) { - if (semicolon.IsNull) + if (semicolon.IsNull) { return; - int endOffset = document.GetOffset (semicolon.StartLocation); + } + int endOffset = document.GetOffset(semicolon.StartLocation); int offset = endOffset; while (offset - 1 > 0 && char.IsWhiteSpace (document.GetCharAt (offset - 1))) { offset--; } if (offset < endOffset) { - AddChange (offset, endOffset - offset, null); + AddChange(offset, endOffset - offset, null); } - } + } - void PlaceOnNewLine (bool newLine, AstNode keywordNode) + void PlaceOnNewLine(bool newLine, AstNode keywordNode) { - if (keywordNode == null) + if (keywordNode == null) { return; - int offset = document.GetOffset (keywordNode.StartLocation); + } + int offset = document.GetOffset(keywordNode.StartLocation); - int whitespaceStart = SearchWhitespaceStart (offset); - string indentString = newLine ? this.EolMarker + this.curIndent.IndentString : " "; - AddChange (whitespaceStart, offset - whitespaceStart, indentString); + int whitespaceStart = SearchWhitespaceStart(offset); + string indentString = newLine ? this.options.EolMarker + this.curIndent.IndentString : " "; + AddChange(whitespaceStart, offset - whitespaceStart, indentString); } string nextStatementIndent = null; - void FixStatementIndentation (TextLocation location) + void FixStatementIndentation(TextLocation location) { - int offset = document.GetOffset (location); + int offset = document.GetOffset(location); if (offset <= 0) { - Console.WriteLine ("possible wrong offset"); - Console.WriteLine (Environment.StackTrace); + Console.WriteLine("possible wrong offset"); + Console.WriteLine(Environment.StackTrace); return; } - bool isEmpty = IsLineIsEmptyUpToEol (offset); - int lineStart = SearchWhitespaceLineStart (offset); - string indentString = nextStatementIndent == null ? (isEmpty ? "" : this.EolMarker) + this.curIndent.IndentString : nextStatementIndent; + bool isEmpty = IsLineIsEmptyUpToEol(offset); + int lineStart = SearchWhitespaceLineStart(offset); + string indentString = nextStatementIndent == null ? (isEmpty ? "" : this.options.EolMarker) + this.curIndent.IndentString : nextStatementIndent; nextStatementIndent = null; - AddChange (lineStart, offset - lineStart, indentString); + AddChange(lineStart, offset - lineStart, indentString); } - void FixIndentation (TextLocation location) + void FixIndentation(TextLocation location) { - FixIndentation (location, 0); + FixIndentation(location, 0); } - void FixIndentation (TextLocation location, int relOffset) + void FixIndentation(TextLocation location, int relOffset) { if (location.Line < 1 || location.Line > document.LineCount) { - Console.WriteLine ("Invalid location " + location); - Console.WriteLine (Environment.StackTrace); + Console.WriteLine("Invalid location " + location); + Console.WriteLine(Environment.StackTrace); return; } - - string lineIndent = GetIndentation (location.Line); + + string lineIndent = GetIndentation(location.Line); string indentString = this.curIndent.IndentString; if (indentString != lineIndent && location.Column - 1 + relOffset == lineIndent.Length) { - AddChange (document.GetOffset (location.Line, 1), lineIndent.Length, indentString); + AddChange(document.GetOffset(location.Line, 1), lineIndent.Length, indentString); } } - void FixIndentationForceNewLine (TextLocation location) + void FixIndentationForceNewLine(TextLocation location) { - string lineIndent = GetIndentation (location.Line); + string lineIndent = GetIndentation(location.Line); string indentString = this.curIndent.IndentString; if (location.Column - 1 == lineIndent.Length) { - AddChange (document.GetOffset (location.Line, 1), lineIndent.Length, indentString); - } else { - int offset = document.GetOffset (location); - int start = SearchWhitespaceLineStart (offset); - if (start > 0) { - char ch = document.GetCharAt (start - 1); + AddChange(document.GetOffset(location.Line, 1), lineIndent.Length, indentString); + } else { + int offset = document.GetOffset(location); + int start = SearchWhitespaceLineStart(offset); + if (start > 0) { + char ch = document.GetCharAt(start - 1); if (ch == '\n') { start--; - if (start > 1 && document.GetCharAt (start - 1) == '\r') + if (start > 1 && document.GetCharAt(start - 1) == '\r') { start--; + } } else if (ch == '\r') { start--; } - AddChange (start, offset - start, this.EolMarker + indentString); + AddChange(start, offset - start, this.options.EolMarker + indentString); } } } @@ -1645,15 +1880,17 @@ namespace ICSharpCode.NRefactory.CSharp string GetIndentation(int lineNumber) { IDocumentLine line = document.GetLineByNumber(lineNumber); - StringBuilder b = new StringBuilder(); + StringBuilder b = new StringBuilder (); int endOffset = line.EndOffset; for (int i = line.Offset; i < endOffset; i++) { char c = document.GetCharAt(i); - if (!IsSpacing(c)) + if (!IsSpacing(c)) { break; + } b.Append(c); } return b.ToString(); } } } + diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/CSharpFormattingOptions.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/CSharpFormattingOptions.cs index 17c4a5899d..0cf8d42a0e 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/CSharpFormattingOptions.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/CSharpFormattingOptions.cs @@ -37,7 +37,8 @@ namespace ICSharpCode.NRefactory.CSharp EndOfLineWithoutSpace, NextLine, NextLineShifted, - NextLineShifted2 + NextLineShifted2, + BannerStyle } public enum BraceForcement @@ -47,12 +48,6 @@ namespace ICSharpCode.NRefactory.CSharp AddBraces } - public enum ArrayInitializerPlacement - { - AlwaysNewLine, - AlwaysSameLine - } - public enum PropertyFormatting { AllowOneLine, @@ -60,6 +55,12 @@ namespace ICSharpCode.NRefactory.CSharp ForceNewLine } + public enum Wrapping { + DoNotWrap, + WrapAlways, + WrapIfTooLong + } + public class CSharpFormattingOptions { public string Name { @@ -321,11 +322,6 @@ namespace ICSharpCode.NRefactory.CSharp get; set; } - - public ArrayInitializerPlacement PlaceArrayInitializersOnNewLine { - get; - set; - } #endregion #region Spaces @@ -726,6 +722,10 @@ namespace ICSharpCode.NRefactory.CSharp set; } + public bool SpaceInNamedArgumentAfterDoubleColon { + get; + set; + } #endregion #region Blank Lines @@ -765,119 +765,31 @@ namespace ICSharpCode.NRefactory.CSharp } #endregion - - public CSharpFormattingOptions () + + + #region Keep formatting + public bool KeepCommentsAtFirstColumn { + get; + set; + } + #endregion + + #region Wrapping + + public Wrapping ArrayInitializerWrapping { + get; + set; + } + + public BraceStyle ArrayInitializerBraceStyle { + get; + set; + } + + #endregion + + internal CSharpFormattingOptions() { - IndentNamespaceBody = true; - IndentClassBody = IndentInterfaceBody = IndentStructBody = IndentEnumBody = true; - IndentMethodBody = IndentPropertyBody = IndentEventBody = true; - IndentBlocks = true; - IndentSwitchBody = false; - IndentCaseBody = true; - IndentBreakStatements = true; - NamespaceBraceStyle = BraceStyle.NextLine; - ClassBraceStyle = InterfaceBraceStyle = StructBraceStyle = EnumBraceStyle = BraceStyle.NextLine; - MethodBraceStyle = ConstructorBraceStyle = DestructorBraceStyle = BraceStyle.NextLine; - AnonymousMethodBraceStyle = BraceStyle.EndOfLine; - - PropertyBraceStyle = PropertyGetBraceStyle = PropertySetBraceStyle = BraceStyle.EndOfLine; - AllowPropertyGetBlockInline = AllowPropertySetBlockInline = true; - - EventBraceStyle = EventAddBraceStyle = EventRemoveBraceStyle = BraceStyle.EndOfLine; - AllowEventAddBlockInline = AllowEventRemoveBlockInline = true; - StatementBraceStyle = BraceStyle.EndOfLine; - - PlaceElseOnNewLine = false; - PlaceCatchOnNewLine = false; - PlaceFinallyOnNewLine = false; - PlaceWhileOnNewLine = false; - PlaceArrayInitializersOnNewLine = ArrayInitializerPlacement.AlwaysSameLine; - - SpaceBeforeMethodCallParentheses = true; - SpaceBeforeMethodDeclarationParentheses = true; - SpaceBeforeConstructorDeclarationParentheses = true; - SpaceBeforeDelegateDeclarationParentheses = true; - SpaceAfterMethodCallParameterComma = true; - SpaceAfterConstructorDeclarationParameterComma = true; - - SpaceBeforeNewParentheses = true; - SpacesWithinNewParentheses = false; - SpacesBetweenEmptyNewParentheses = false; - SpaceBeforeNewParameterComma = false; - SpaceAfterNewParameterComma = true; - - SpaceBeforeIfParentheses = true; - SpaceBeforeWhileParentheses = true; - SpaceBeforeForParentheses = true; - SpaceBeforeForeachParentheses = true; - SpaceBeforeCatchParentheses = true; - SpaceBeforeSwitchParentheses = true; - SpaceBeforeLockParentheses = true; - SpaceBeforeUsingParentheses = true; - SpaceAroundAssignment = true; - SpaceAroundLogicalOperator = true; - SpaceAroundEqualityOperator = true; - SpaceAroundRelationalOperator = true; - SpaceAroundBitwiseOperator = true; - SpaceAroundAdditiveOperator = true; - SpaceAroundMultiplicativeOperator = true; - SpaceAroundShiftOperator = true; - SpaceAroundNullCoalescingOperator = true; - SpacesWithinParentheses = false; - SpaceWithinMethodCallParentheses = false; - SpaceWithinMethodDeclarationParentheses = false; - SpacesWithinIfParentheses = false; - SpacesWithinWhileParentheses = false; - SpacesWithinForParentheses = false; - SpacesWithinForeachParentheses = false; - SpacesWithinCatchParentheses = false; - SpacesWithinSwitchParentheses = false; - SpacesWithinLockParentheses = false; - SpacesWithinUsingParentheses = false; - SpacesWithinCastParentheses = false; - SpacesWithinSizeOfParentheses = false; - SpacesWithinTypeOfParentheses = false; - SpacesWithinCheckedExpressionParantheses = false; - SpaceBeforeConditionalOperatorCondition = true; - SpaceAfterConditionalOperatorCondition = true; - SpaceBeforeConditionalOperatorSeparator = true; - SpaceAfterConditionalOperatorSeparator = true; - - SpacesWithinBrackets = false; - SpacesBeforeBrackets = true; - SpaceBeforeBracketComma = false; - SpaceAfterBracketComma = true; - - SpaceBeforeForSemicolon = false; - SpaceAfterForSemicolon = true; - SpaceAfterTypecast = false; - - AlignEmbeddedIfStatements = true; - AlignEmbeddedUsingStatements = true; - PropertyFormatting = PropertyFormatting.AllowOneLine; - SpaceBeforeMethodDeclarationParameterComma = false; - SpaceAfterMethodDeclarationParameterComma = true; - SpaceBeforeFieldDeclarationComma = false; - SpaceAfterFieldDeclarationComma = true; - SpaceBeforeLocalVariableDeclarationComma = false; - SpaceAfterLocalVariableDeclarationComma = true; - - SpaceBeforeIndexerDeclarationBracket = true; - SpaceWithinIndexerDeclarationBracket = false; - SpaceBeforeIndexerDeclarationParameterComma = false; - - - SpaceAfterIndexerDeclarationParameterComma = true; - - BlankLinesBeforeUsings = 0; - BlankLinesAfterUsings = 1; - - - BlankLinesBeforeFirstDeclaration = 0; - BlankLinesBetweenTypes = 1; - BlankLinesBetweenFields = 0; - BlankLinesBetweenEventFields = 0; - BlankLinesBetweenMembers = 1; } /*public static CSharpFormattingOptions Load (FilePath selectedFile) @@ -889,7 +801,7 @@ namespace ICSharpCode.NRefactory.CSharp public static CSharpFormattingOptions Load (System.IO.Stream input) { - CSharpFormattingOptions result = new CSharpFormattingOptions (); + CSharpFormattingOptions result = FormattingOptionsFactory.CreateMonoOptions (); result.Name = "noname"; using (XmlTextReader reader = new XmlTextReader (input)) { while (reader.Read ()) { diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/FormattingOptionsFactory.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/FormattingOptionsFactory.cs new file mode 100644 index 0000000000..331a1579cc --- /dev/null +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/FormattingOptionsFactory.cs @@ -0,0 +1,339 @@ +// +// FormattingOptionsFactory.cs +// +// Author: +// Mike Krüger +// +// Copyright (c) 2012 Xamarin Inc. (http://xamarin.com) +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +// THE SOFTWARE. +using System; + +namespace ICSharpCode.NRefactory.CSharp +{ + /// + /// The formatting options factory creates pre defined formatting option styles. + /// + public static class FormattingOptionsFactory + { + /// + /// Creates empty CSharpFormatting options. + /// + public static CSharpFormattingOptions CreateEmpty() + { + return new CSharpFormattingOptions(); + } + + /// + /// Creates mono indent style CSharpFormatting options. + /// + public static CSharpFormattingOptions CreateMono() + { + return new CSharpFormattingOptions() { + IndentNamespaceBody = true, + IndentClassBody = true, + IndentInterfaceBody = true, + IndentStructBody = true, + IndentEnumBody = true, + IndentMethodBody = true, + IndentPropertyBody = true, + IndentEventBody = true, + IndentBlocks = true, + IndentSwitchBody = false, + IndentCaseBody = true, + IndentBreakStatements = true, + NamespaceBraceStyle = BraceStyle.NextLine, + ClassBraceStyle = BraceStyle.NextLine, + InterfaceBraceStyle = BraceStyle.NextLine, + StructBraceStyle = BraceStyle.NextLine, + EnumBraceStyle = BraceStyle.NextLine, + MethodBraceStyle = BraceStyle.NextLine, + ConstructorBraceStyle = BraceStyle.NextLine, + DestructorBraceStyle = BraceStyle.NextLine, + AnonymousMethodBraceStyle = BraceStyle.EndOfLine, + + PropertyBraceStyle = BraceStyle.EndOfLine, + PropertyGetBraceStyle = BraceStyle.EndOfLine, + PropertySetBraceStyle = BraceStyle.EndOfLine, + AllowPropertyGetBlockInline = true, + AllowPropertySetBlockInline = true, + + EventBraceStyle = BraceStyle.EndOfLine, + EventAddBraceStyle = BraceStyle.EndOfLine, + EventRemoveBraceStyle = BraceStyle.EndOfLine, + AllowEventAddBlockInline = true, + AllowEventRemoveBlockInline = true, + StatementBraceStyle = BraceStyle.EndOfLine, + + PlaceElseOnNewLine = false, + PlaceCatchOnNewLine = false, + PlaceFinallyOnNewLine = false, + PlaceWhileOnNewLine = false, + ArrayInitializerWrapping = Wrapping.WrapIfTooLong, + ArrayInitializerBraceStyle = BraceStyle.EndOfLine, + + SpaceBeforeMethodCallParentheses = true, + SpaceBeforeMethodDeclarationParentheses = true, + SpaceBeforeConstructorDeclarationParentheses = true, + SpaceBeforeDelegateDeclarationParentheses = true, + SpaceAfterMethodCallParameterComma = true, + SpaceAfterConstructorDeclarationParameterComma = true, + + SpaceBeforeNewParentheses = true, + SpacesWithinNewParentheses = false, + SpacesBetweenEmptyNewParentheses = false, + SpaceBeforeNewParameterComma = false, + SpaceAfterNewParameterComma = true, + + SpaceBeforeIfParentheses = true, + SpaceBeforeWhileParentheses = true, + SpaceBeforeForParentheses = true, + SpaceBeforeForeachParentheses = true, + SpaceBeforeCatchParentheses = true, + SpaceBeforeSwitchParentheses = true, + SpaceBeforeLockParentheses = true, + SpaceBeforeUsingParentheses = true, + SpaceAroundAssignment = true, + SpaceAroundLogicalOperator = true, + SpaceAroundEqualityOperator = true, + SpaceAroundRelationalOperator = true, + SpaceAroundBitwiseOperator = true, + SpaceAroundAdditiveOperator = true, + SpaceAroundMultiplicativeOperator = true, + SpaceAroundShiftOperator = true, + SpaceAroundNullCoalescingOperator = true, + SpacesWithinParentheses = false, + SpaceWithinMethodCallParentheses = false, + SpaceWithinMethodDeclarationParentheses = false, + SpacesWithinIfParentheses = false, + SpacesWithinWhileParentheses = false, + SpacesWithinForParentheses = false, + SpacesWithinForeachParentheses = false, + SpacesWithinCatchParentheses = false, + SpacesWithinSwitchParentheses = false, + SpacesWithinLockParentheses = false, + SpacesWithinUsingParentheses = false, + SpacesWithinCastParentheses = false, + SpacesWithinSizeOfParentheses = false, + SpacesWithinTypeOfParentheses = false, + SpacesWithinCheckedExpressionParantheses = false, + SpaceBeforeConditionalOperatorCondition = true, + SpaceAfterConditionalOperatorCondition = true, + SpaceBeforeConditionalOperatorSeparator = true, + SpaceAfterConditionalOperatorSeparator = true, + + SpacesWithinBrackets = false, + SpacesBeforeBrackets = true, + SpaceBeforeBracketComma = false, + SpaceAfterBracketComma = true, + + SpaceBeforeForSemicolon = false, + SpaceAfterForSemicolon = true, + SpaceAfterTypecast = false, + + AlignEmbeddedIfStatements = true, + AlignEmbeddedUsingStatements = true, + PropertyFormatting = PropertyFormatting.AllowOneLine, + SpaceBeforeMethodDeclarationParameterComma = false, + SpaceAfterMethodDeclarationParameterComma = true, + SpaceBeforeFieldDeclarationComma = false, + SpaceAfterFieldDeclarationComma = true, + SpaceBeforeLocalVariableDeclarationComma = false, + SpaceAfterLocalVariableDeclarationComma = true, + + SpaceBeforeIndexerDeclarationBracket = true, + SpaceWithinIndexerDeclarationBracket = false, + SpaceBeforeIndexerDeclarationParameterComma = false, + SpaceInNamedArgumentAfterDoubleColon = true, + + SpaceAfterIndexerDeclarationParameterComma = true, + + BlankLinesBeforeUsings = 0, + BlankLinesAfterUsings = 1, + + + BlankLinesBeforeFirstDeclaration = 0, + BlankLinesBetweenTypes = 1, + BlankLinesBetweenFields = 0, + BlankLinesBetweenEventFields = 0, + BlankLinesBetweenMembers = 1, + + KeepCommentsAtFirstColumn = true, + }; + } + + /// + /// Creates sharp develop indent style CSharpFormatting options. + /// + public static CSharpFormattingOptions CreateSharpDevelop() + { + return new CSharpFormattingOptions() { + IndentNamespaceBody = true, + IndentClassBody = true, + IndentInterfaceBody = true, + IndentStructBody = true, + IndentEnumBody = true, + IndentMethodBody = true, + IndentPropertyBody = true, + IndentEventBody = true, + IndentBlocks = true, + IndentSwitchBody = true, + IndentCaseBody = true, + IndentBreakStatements = true, + + NamespaceBraceStyle = BraceStyle.NextLine, + ClassBraceStyle = BraceStyle.NextLine, + InterfaceBraceStyle = BraceStyle.NextLine, + StructBraceStyle = BraceStyle.NextLine, + EnumBraceStyle = BraceStyle.NextLine, + MethodBraceStyle = BraceStyle.NextLine, + ConstructorBraceStyle = BraceStyle.NextLine, + DestructorBraceStyle = BraceStyle.NextLine, + AnonymousMethodBraceStyle = BraceStyle.EndOfLine, + PropertyBraceStyle = BraceStyle.EndOfLine, + PropertyGetBraceStyle = BraceStyle.EndOfLine, + PropertySetBraceStyle = BraceStyle.EndOfLine, + AllowPropertyGetBlockInline = true, + AllowPropertySetBlockInline = true, + + EventBraceStyle = BraceStyle.EndOfLine, + EventAddBraceStyle = BraceStyle.EndOfLine, + EventRemoveBraceStyle = BraceStyle.EndOfLine, + AllowEventAddBlockInline = true, + AllowEventRemoveBlockInline = true, + StatementBraceStyle = BraceStyle.EndOfLine, + + PlaceElseOnNewLine = false, + PlaceCatchOnNewLine = false, + PlaceFinallyOnNewLine = false, + PlaceWhileOnNewLine = false, + ArrayInitializerWrapping = Wrapping.WrapIfTooLong, + ArrayInitializerBraceStyle = BraceStyle.EndOfLine, + + SpaceBeforeMethodCallParentheses = false, + SpaceBeforeMethodDeclarationParentheses = false, + SpaceBeforeConstructorDeclarationParentheses = false, + SpaceBeforeDelegateDeclarationParentheses = false, + SpaceAfterMethodCallParameterComma = true, + SpaceAfterConstructorDeclarationParameterComma = true, + + SpaceBeforeNewParentheses = false, + SpacesWithinNewParentheses = false, + SpacesBetweenEmptyNewParentheses = false, + SpaceBeforeNewParameterComma = false, + SpaceAfterNewParameterComma = true, + + SpaceBeforeIfParentheses = true, + SpaceBeforeWhileParentheses = true, + SpaceBeforeForParentheses = true, + SpaceBeforeForeachParentheses = true, + SpaceBeforeCatchParentheses = true, + SpaceBeforeSwitchParentheses = true, + SpaceBeforeLockParentheses = true, + SpaceBeforeUsingParentheses = true, + + SpaceAroundAssignment = true, + SpaceAroundLogicalOperator = true, + SpaceAroundEqualityOperator = true, + SpaceAroundRelationalOperator = true, + SpaceAroundBitwiseOperator = true, + SpaceAroundAdditiveOperator = true, + SpaceAroundMultiplicativeOperator = true, + SpaceAroundShiftOperator = true, + SpaceAroundNullCoalescingOperator = true, + SpacesWithinParentheses = false, + SpaceWithinMethodCallParentheses = false, + SpaceWithinMethodDeclarationParentheses = false, + SpacesWithinIfParentheses = false, + SpacesWithinWhileParentheses = false, + SpacesWithinForParentheses = false, + SpacesWithinForeachParentheses = false, + SpacesWithinCatchParentheses = false, + SpacesWithinSwitchParentheses = false, + SpacesWithinLockParentheses = false, + SpacesWithinUsingParentheses = false, + SpacesWithinCastParentheses = false, + SpacesWithinSizeOfParentheses = false, + SpacesWithinTypeOfParentheses = false, + SpacesWithinCheckedExpressionParantheses = false, + SpaceBeforeConditionalOperatorCondition = true, + SpaceAfterConditionalOperatorCondition = true, + SpaceBeforeConditionalOperatorSeparator = true, + SpaceAfterConditionalOperatorSeparator = true, + + SpacesWithinBrackets = false, + SpacesBeforeBrackets = true, + SpaceBeforeBracketComma = false, + SpaceAfterBracketComma = true, + + SpaceBeforeForSemicolon = false, + SpaceAfterForSemicolon = true, + SpaceAfterTypecast = false, + + AlignEmbeddedIfStatements = true, + AlignEmbeddedUsingStatements = true, + PropertyFormatting = PropertyFormatting.AllowOneLine, + SpaceBeforeMethodDeclarationParameterComma = false, + SpaceAfterMethodDeclarationParameterComma = true, + SpaceBeforeFieldDeclarationComma = false, + SpaceAfterFieldDeclarationComma = true, + SpaceBeforeLocalVariableDeclarationComma = false, + SpaceAfterLocalVariableDeclarationComma = true, + + SpaceBeforeIndexerDeclarationBracket = true, + SpaceWithinIndexerDeclarationBracket = false, + SpaceBeforeIndexerDeclarationParameterComma = false, + SpaceInNamedArgumentAfterDoubleColon = true, + + SpaceAfterIndexerDeclarationParameterComma = true, + + BlankLinesBeforeUsings = 0, + BlankLinesAfterUsings = 1, + + BlankLinesBeforeFirstDeclaration = 0, + BlankLinesBetweenTypes = 1, + BlankLinesBetweenFields = 0, + BlankLinesBetweenEventFields = 0, + BlankLinesBetweenMembers = 1, + + KeepCommentsAtFirstColumn = true, + }; + } + + /// + /// Creates allman indent style CSharpFormatting options used in Visual Studio. + /// + public static CSharpFormattingOptions CreateAllman() + { + var baseOptions = CreateSharpDevelop(); + baseOptions.AnonymousMethodBraceStyle = BraceStyle.EndOfLine; + baseOptions.PropertyBraceStyle = BraceStyle.EndOfLine; + baseOptions.PropertyGetBraceStyle = BraceStyle.EndOfLine; + baseOptions.PropertySetBraceStyle = BraceStyle.EndOfLine; + + baseOptions.EventBraceStyle = BraceStyle.EndOfLine; + baseOptions.EventAddBraceStyle = BraceStyle.EndOfLine; + baseOptions.EventRemoveBraceStyle = BraceStyle.EndOfLine; + baseOptions.StatementBraceStyle = BraceStyle.EndOfLine; + baseOptions.ArrayInitializerBraceStyle = BraceStyle.EndOfLine; + return baseOptions; + } + } +} + diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/GeneratedCodeSettings.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/GeneratedCodeSettings.cs new file mode 100644 index 0000000000..827a3dc949 --- /dev/null +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/GeneratedCodeSettings.cs @@ -0,0 +1,216 @@ +// +// GeneratedCodeSettings.cs +// +// Author: +// Mike Krüger +// +// Copyright (c) 2012 Xamarin Inc. (http://xamarin.com) +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +// THE SOFTWARE. + +using System; +using System.Collections.Generic; + +namespace ICSharpCode.NRefactory.CSharp +{ + public enum GeneratedCodeMember + { + Unknown, + + StaticFields, + InstanceFields, + StaticProperties, + InstanceProperties, + Indexer, + Constructors, + StaticMethods, + InstanceMethods, + StaticEvents, + InstanceEvents, + Operators, + NestedTypes + } + + public class GeneratedCodeSettings + { + List codeMemberOrder; + + public List CodeMemberOrder { + get { + return codeMemberOrder; + } + set { + codeMemberOrder = value; + } + } + + public bool GenerateCategoryComments { + get; + set; + } + + public bool SubOrderAlphabetical { + get; + set; + } + + public void Apply (AstNode rootNode) + { + if (rootNode == null) + throw new ArgumentNullException ("rootNode"); + rootNode.AcceptVisitor (new GenerateCodeVisitior (this)); + } + + public virtual string GetCategoryLabel(GeneratedCodeMember memberCategory) + { + switch (memberCategory) { + case GeneratedCodeMember.StaticFields: + return "Static Fields"; + case GeneratedCodeMember.InstanceFields: + return "Fields"; + case GeneratedCodeMember.StaticProperties: + return "Static Properties"; + case GeneratedCodeMember.InstanceProperties: + return "Properties"; + case GeneratedCodeMember.Indexer: + return "Indexer"; + case GeneratedCodeMember.Constructors: + return "Constructors"; + case GeneratedCodeMember.StaticMethods: + return "Static Methods"; + case GeneratedCodeMember.InstanceMethods: + return "Methods"; + case GeneratedCodeMember.StaticEvents: + return "Static Events"; + case GeneratedCodeMember.InstanceEvents: + return "Events"; + case GeneratedCodeMember.Operators: + return "Operators"; + case GeneratedCodeMember.NestedTypes: + return "Nested Types"; + } + return null; + } + + class GenerateCodeVisitior : DepthFirstAstVisitor + { + GeneratedCodeSettings settings; + + public GenerateCodeVisitior(GeneratedCodeSettings settings) + { + if (settings == null) + throw new ArgumentNullException("settings"); + this.settings = settings; + } + + GeneratedCodeMember GetCodeMemberCategory(EntityDeclaration x) + { + bool isStatic = x.HasModifier(Modifiers.Static) || x.HasModifier(Modifiers.Const); + if (x is FieldDeclaration) + return isStatic ? GeneratedCodeMember.StaticFields : GeneratedCodeMember.InstanceFields; + if (x is IndexerDeclaration) + return GeneratedCodeMember.Indexer; + if (x is PropertyDeclaration) + return isStatic ? GeneratedCodeMember.StaticProperties : GeneratedCodeMember.InstanceProperties; + if (x is ConstructorDeclaration || x is DestructorDeclaration) + return GeneratedCodeMember.Constructors; + if (x is MethodDeclaration) + return isStatic ? GeneratedCodeMember.StaticMethods : GeneratedCodeMember.InstanceMethods; + if (x is OperatorDeclaration) + return GeneratedCodeMember.Operators; + if (x is EventDeclaration || x is CustomEventDeclaration) + return isStatic ? GeneratedCodeMember.StaticEvents : GeneratedCodeMember.InstanceEvents; + + if (x is TypeDeclaration) + return GeneratedCodeMember.NestedTypes; + + return GeneratedCodeMember.Unknown; + } + + public override void VisitTypeDeclaration (TypeDeclaration typeDeclaration) + { + if (typeDeclaration.ClassType == ClassType.Enum) + return; + var entities = new List (typeDeclaration.Members); + entities.Sort ((x, y) => { + int i1 = settings.CodeMemberOrder.IndexOf (GetCodeMemberCategory (x)); + int i2 = settings.CodeMemberOrder.IndexOf (GetCodeMemberCategory (y)); + if (i1 != i2) + return i1.CompareTo (i2); + if (settings.SubOrderAlphabetical) + return (x.Name ?? "").CompareTo ((y.Name ?? "")); + return entities.IndexOf (x).CompareTo (entities.IndexOf (y)); + }); + typeDeclaration.Members.Clear (); + typeDeclaration.Members.AddRange (entities); + + if (settings.GenerateCategoryComments) { + var curCat = GeneratedCodeMember.Unknown; + foreach (var mem in entities) { + if (mem.NextSibling is EntityDeclaration) + mem.Parent.InsertChildAfter (mem, new UnixNewLine (), Roles.NewLine); + + var cat = GetCodeMemberCategory (mem); + if (cat == curCat) + continue; + curCat = cat; + var label = settings.GetCategoryLabel (curCat); + if (string.IsNullOrEmpty (label)) + continue; + + var cmt = new Comment ("", CommentType.SingleLine); + var cmt2 = new Comment (" " + label, CommentType.SingleLine); + var cmt3 = new Comment ("", CommentType.SingleLine); + mem.Parent.InsertChildsBefore (mem, Roles.Comment, cmt, cmt2, cmt3); + if (cmt.PrevSibling is EntityDeclaration) + mem.Parent.InsertChildBefore (cmt, new UnixNewLine (), Roles.NewLine); + + mem.Parent.InsertChildAfter (cmt3, new UnixNewLine (), Roles.NewLine); + } + } + } + } + + static Lazy defaultSettings = new Lazy( + () => new GeneratedCodeSettings() { + CodeMemberOrder = new List() { + GeneratedCodeMember.StaticFields, + GeneratedCodeMember.InstanceFields, + GeneratedCodeMember.StaticProperties, + GeneratedCodeMember.InstanceProperties, + GeneratedCodeMember.Indexer, + GeneratedCodeMember.Constructors, + GeneratedCodeMember.StaticMethods, + GeneratedCodeMember.InstanceMethods, + GeneratedCodeMember.StaticEvents, + GeneratedCodeMember.InstanceEvents, + GeneratedCodeMember.Operators, + GeneratedCodeMember.NestedTypes + }, + GenerateCategoryComments = true, + SubOrderAlphabetical = true + }); + + public static GeneratedCodeSettings Default { + get { + return defaultSettings.Value; + } + } + } +} \ No newline at end of file diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/Indent.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/Indent.cs index 017d8c9b49..322aa211d2 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/Indent.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/Indent.cs @@ -1,4 +1,4 @@ -// +// // Indent.cs // // Author: @@ -24,66 +24,75 @@ // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN // THE SOFTWARE. using System; +using System.Collections.Generic; namespace ICSharpCode.NRefactory.CSharp { + public enum IndentType { + Block, + Continuation, + Label + } + public class Indent { - public int Level { - get; - set; - } + readonly Stack indentStack = new Stack (); + readonly TextEditorOptions options; + + int curIndent; - public int ExtraSpaces { - get; - set; - } - - public bool TabsToSpaces { - get; - set; + public Indent(TextEditorOptions options) + { + this.options = options; } - public int TabSize { - get; - set; - } - public Indent () + public void Push(IndentType type) { + indentStack.Push(type); + curIndent += GetIndent(type); + Update(); } - public Indent (int level, int extraSpaces) + public void Pop() { - this.Level = level; - this.ExtraSpaces = extraSpaces; + curIndent -= GetIndent(indentStack.Pop()); + Update(); } - public static Indent operator+ (Indent left, Indent right) + int GetIndent(IndentType indentType) { - return new Indent (left.Level + right.Level, left.ExtraSpaces + right.ExtraSpaces); + switch (indentType) { + case IndentType.Block: + return options.IndentSize; + case IndentType.Continuation: + return options.ContinuationIndent; + case IndentType.Label: + return options.LabelIndent; + default: + throw new ArgumentOutOfRangeException(); + } } - public static Indent operator- (Indent left, Indent right) + void Update() { - return new Indent (left.Level - right.Level, left.ExtraSpaces - right.ExtraSpaces); - } - - public string IndentString { - get { - return (TabsToSpaces ? new string (' ', Level * TabSize) : new string ('\t', Level)) + new string (' ', ExtraSpaces); + if (options.TabsToSpaces) { + indentString = new string(' ', curIndent); + return; } + indentString = new string('\t', curIndent / options.TabSize) + new string(' ', curIndent % options.TabSize); } - public string SingleIndent { + string indentString; + public string IndentString { get { - return TabsToSpaces ? new string (' ', TabSize) : "\t"; + return indentString; } } - public override string ToString () + public override string ToString() { - return string.Format ("[Indent: Level={0}, ExtraSpaces={1}]", Level, ExtraSpaces); + return string.Format("[Indent: curIndent={0}]", curIndent); } } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/TextEditorOptions.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/TextEditorOptions.cs new file mode 100644 index 0000000000..6ea1763749 --- /dev/null +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Formatter/TextEditorOptions.cs @@ -0,0 +1,106 @@ +// +// TextEditorOptions.cs +// +// Author: +// Mike Krüger +// +// Copyright (c) 2012 Xamarin Inc. (http://xamarin.com) +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +// THE SOFTWARE. + +using System; + +namespace ICSharpCode.NRefactory.CSharp +{ + /// + /// The text editor options class holds basic information about the text editor settings that influences code generation and formatting beside + /// the CSharpFormattingOptions. + /// + public class TextEditorOptions + { + public static readonly TextEditorOptions Default = new TextEditorOptions (); + + /// + /// Gets or sets a value indicating if tabs need to be replaced by spaces. If that is true, all indenting will be done with spaces only, + /// otherwise the indenting will start with tabs. + /// + public bool TabsToSpaces { + get; + set; + } + + /// + /// Gets or sets the size of the tab chacter as spaces. + /// + public int TabSize { + get; + set; + } + + /// + /// Gets or sets the size of a single indent as spaces. + /// + public int IndentSize { + get; + set; + } + + /// + /// Gets or sets the continuation indent. A continuation indent is the indent that will be put after an embedded statement that is no block. + /// + public int ContinuationIndent { + get; + set; + } + + /// + /// Gets or sets the label indent. A label indent is the indent that will be put before an label. + /// (Note: it may be negative -IndentSize would cause that labels are unindented) + /// + public int LabelIndent { + get; + set; + } + + /// + /// Gets or sets the eol marker. + /// + public string EolMarker { + get; + set; + } + + /// + /// If true blank lines will be indented up to the indent level, otherwise blank lines will have the length 0. + /// + public bool IndentBlankLines { + get; + set; + } + + public TextEditorOptions() + { + TabsToSpaces = false; + TabSize = 4; + IndentSize = 4; + ContinuationIndent = 4; + EolMarker = Environment.NewLine; + } + } +} diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/ICSharpCode.NRefactory.CSharp.csproj b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/ICSharpCode.NRefactory.CSharp.csproj index ec347efe29..a31cf0eb33 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/ICSharpCode.NRefactory.CSharp.csproj +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/ICSharpCode.NRefactory.CSharp.csproj @@ -30,20 +30,24 @@ ..\ICSharpCode.NRefactory\bin\Debug\ - true - Full False False DEBUG;TRACE;FULL_AST ..\ICSharpCode.NRefactory\bin\Release\ - false - PdbOnly True False TRACE;FULL_AST + + PdbOnly + false + + + full + true + @@ -55,11 +59,16 @@ + + Properties\GlobalAssemblyInfo.cs + + + @@ -118,7 +127,6 @@ - @@ -152,7 +160,7 @@ - + @@ -161,7 +169,6 @@ - @@ -197,7 +204,6 @@ - @@ -208,7 +214,6 @@ - @@ -229,8 +234,6 @@ - - @@ -238,42 +241,15 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + - - + @@ -292,15 +268,16 @@ - + + @@ -317,6 +294,82 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -327,14 +380,22 @@ + + + + + + + + \ No newline at end of file diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/CSharpAmbience.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/CSharpAmbience.cs index f35db3766b..c370e58e4c 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/CSharpAmbience.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/CSharpAmbience.cs @@ -1,4 +1,4 @@ -// Copyright (c) AlphaSierraPapa for the SharpDevelop Team +// Copyright (c) AlphaSierraPapa for the SharpDevelop Team // // Permission is hereby granted, free of charge, to any person obtaining a copy of this // software and associated documentation files (the "Software"), to deal in the Software @@ -32,175 +32,213 @@ namespace ICSharpCode.NRefactory.CSharp public ConversionFlags ConversionFlags { get; set; } #region ConvertEntity - public string ConvertEntity(IEntity e) + public string ConvertEntity(IEntity entity) { - StringWriter writer = new StringWriter(); - - if (e.EntityType == EntityType.TypeDefinition) { - ConvertTypeDeclaration((ITypeDefinition)e, writer); - } else { - ConvertMember((IMember)e, writer); - } + if (entity == null) + throw new ArgumentNullException("entity"); - return writer.ToString().TrimEnd(); + StringWriter writer = new StringWriter(); + ConvertEntity(entity, new TextWriterOutputFormatter(writer), FormattingOptionsFactory.CreateMono ()); + return writer.ToString(); } - void ConvertMember(IMember member, StringWriter writer) + public void ConvertEntity(IEntity entity, IOutputFormatter formatter, CSharpFormattingOptions formattingPolicy) { + if (entity == null) + throw new ArgumentNullException("entity"); + if (formatter == null) + throw new ArgumentNullException("formatter"); + if (formattingPolicy == null) + throw new ArgumentNullException("options"); + TypeSystemAstBuilder astBuilder = CreateAstBuilder(); - astBuilder.ShowParameterNames = (ConversionFlags & ConversionFlags.ShowParameterNames) == ConversionFlags.ShowParameterNames; + EntityDeclaration node = astBuilder.ConvertEntity(entity); + PrintModifiers(node.Modifiers, formatter); - AttributedNode node = (AttributedNode)astBuilder.ConvertEntity(member); - PrintModifiers(node.Modifiers, writer); + if ((ConversionFlags & ConversionFlags.ShowDefinitionKeyword) == ConversionFlags.ShowDefinitionKeyword) { + if (node is TypeDeclaration) { + switch (((TypeDeclaration)node).ClassType) { + case ClassType.Class: + formatter.WriteKeyword("class"); + break; + case ClassType.Struct: + formatter.WriteKeyword("struct"); + break; + case ClassType.Interface: + formatter.WriteKeyword("interface"); + break; + case ClassType.Enum: + formatter.WriteKeyword("enum"); + break; + default: + throw new Exception("Invalid value for ClassType"); + } + formatter.Space(); + } else if (node is DelegateDeclaration) { + formatter.WriteKeyword("delegate"); + formatter.Space(); + } else if (node is EventDeclaration) { + formatter.WriteKeyword("event"); + formatter.Space(); + } + } if ((ConversionFlags & ConversionFlags.ShowReturnType) == ConversionFlags.ShowReturnType) { - var rt = node.GetChildByRole(AstNode.Roles.Type); - if (rt != AstNode.Roles.Type.NullObject) { - writer.Write(rt.AcceptVisitor(CreatePrinter(writer), null)); - writer.Write(' '); + var rt = node.GetChildByRole(Roles.Type); + if (!rt.IsNull) { + rt.AcceptVisitor(new CSharpOutputVisitor(formatter, formattingPolicy)); + formatter.Space(); } } - WriteMemberDeclarationName(member, writer); + if (entity is ITypeDefinition) + WriteTypeDeclarationName((ITypeDefinition)entity, formatter, formattingPolicy); + else + WriteMemberDeclarationName((IMember)entity, formatter, formattingPolicy); - if ((ConversionFlags & ConversionFlags.ShowParameterList) == ConversionFlags.ShowParameterList - && member is IParameterizedMember && member.EntityType != EntityType.Property) { - writer.Write((node is IndexerDeclaration) ? '[' : '('); + if ((ConversionFlags & ConversionFlags.ShowParameterList) == ConversionFlags.ShowParameterList && HasParameters(entity)) { + formatter.WriteToken(entity.EntityType == EntityType.Indexer ? "[" : "("); bool first = true; - foreach (var param in node.GetChildrenByRole(AstNode.Roles.Parameter)) { - if (first) + foreach (var param in node.GetChildrenByRole(Roles.Parameter)) { + if (first) { first = false; - else - writer.Write(", "); - param.AcceptVisitor(CreatePrinter(writer), null); + } else { + formatter.WriteToken(","); + formatter.Space(); + } + param.AcceptVisitor(new CSharpOutputVisitor(formatter, formattingPolicy)); } - writer.Write((node is IndexerDeclaration) ? ']' : ')'); + formatter.WriteToken(entity.EntityType == EntityType.Indexer ? "]" : ")"); } - if ((ConversionFlags & ConversionFlags.ShowBody) == ConversionFlags.ShowBody) { - IProperty property = member as IProperty; + + if ((ConversionFlags & ConversionFlags.ShowBody) == ConversionFlags.ShowBody && !(node is TypeDeclaration)) { + IProperty property = entity as IProperty; if (property != null) { - writer.Write(" { "); - if (property.CanGet) - writer.Write("get; "); - if (property.CanSet) - writer.Write("set; "); - writer.Write('}'); + formatter.Space(); + formatter.WriteToken("{"); + formatter.Space(); + if (property.CanGet) { + formatter.WriteKeyword("get"); + formatter.WriteToken(";"); + formatter.Space(); + } + if (property.CanSet) { + formatter.WriteKeyword("set"); + formatter.WriteToken(";"); + formatter.Space(); + } + formatter.WriteToken("}"); } else { - writer.Write(';'); + formatter.WriteToken(";"); } } } - + + bool HasParameters(IEntity e) + { + switch (e.EntityType) { + case EntityType.TypeDefinition: + return ((ITypeDefinition)e).Kind == TypeKind.Delegate; + case EntityType.Indexer: + case EntityType.Method: + case EntityType.Operator: + case EntityType.Constructor: + case EntityType.Destructor: + return true; + default: + return false; + } + } + TypeSystemAstBuilder CreateAstBuilder() { TypeSystemAstBuilder astBuilder = new TypeSystemAstBuilder(); + astBuilder.AddAnnotations = true; astBuilder.ShowModifiers = (ConversionFlags & ConversionFlags.ShowModifiers) == ConversionFlags.ShowModifiers; astBuilder.ShowAccessibility = (ConversionFlags & ConversionFlags.ShowAccessibility) == ConversionFlags.ShowAccessibility; astBuilder.AlwaysUseShortTypeNames = (ConversionFlags & ConversionFlags.UseFullyQualifiedTypeNames) != ConversionFlags.UseFullyQualifiedTypeNames; + astBuilder.ShowParameterNames = (ConversionFlags & ConversionFlags.ShowParameterNames) == ConversionFlags.ShowParameterNames; return astBuilder; } - void ConvertTypeDeclaration(ITypeDefinition typeDef, StringWriter writer) - { - TypeSystemAstBuilder astBuilder = CreateAstBuilder(); - TypeDeclaration typeDeclaration = (TypeDeclaration)astBuilder.ConvertEntity(typeDef); - PrintModifiers(typeDeclaration.Modifiers, writer); - if ((ConversionFlags & ConversionFlags.ShowDefinitionKeyWord) == ConversionFlags.ShowDefinitionKeyWord) { - switch (typeDeclaration.ClassType) { - case ClassType.Class: - writer.Write("class"); - break; - case ClassType.Struct: - writer.Write("struct"); - break; - case ClassType.Interface: - writer.Write("interface"); - break; - case ClassType.Enum: - writer.Write("enum"); - break; - default: - throw new Exception("Invalid value for ClassType"); - } - writer.Write(' '); - } - WriteTypeDeclarationName(typeDef, writer); - } - - void WriteTypeDeclarationName(ITypeDefinition typeDef, StringWriter writer) + void WriteTypeDeclarationName(ITypeDefinition typeDef, IOutputFormatter formatter, CSharpFormattingOptions formattingPolicy) { TypeSystemAstBuilder astBuilder = CreateAstBuilder(); if (typeDef.DeclaringTypeDefinition != null) { - WriteTypeDeclarationName(typeDef.DeclaringTypeDefinition, writer); - writer.Write('.'); - } else if ((ConversionFlags & ConversionFlags.UseFullyQualifiedMemberNames) == ConversionFlags.UseFullyQualifiedMemberNames) { - writer.Write(typeDef.Namespace); - writer.Write('.'); + WriteTypeDeclarationName(typeDef.DeclaringTypeDefinition, formatter, formattingPolicy); + formatter.WriteToken("."); + } else if ((ConversionFlags & ConversionFlags.UseFullyQualifiedTypeNames) == ConversionFlags.UseFullyQualifiedTypeNames) { + formatter.WriteIdentifier(typeDef.Namespace); + formatter.WriteToken("."); } - writer.Write(typeDef.Name); + formatter.WriteIdentifier(typeDef.Name); if ((ConversionFlags & ConversionFlags.ShowTypeParameterList) == ConversionFlags.ShowTypeParameterList) { - CreatePrinter(writer).WriteTypeParameters(((TypeDeclaration)astBuilder.ConvertEntity(typeDef)).TypeParameters); + var outputVisitor = new CSharpOutputVisitor(formatter, formattingPolicy); + outputVisitor.WriteTypeParameters(astBuilder.ConvertEntity(typeDef).GetChildrenByRole(Roles.TypeParameter)); } } - void WriteMemberDeclarationName(IMember member, StringWriter writer) + void WriteMemberDeclarationName(IMember member, IOutputFormatter formatter, CSharpFormattingOptions formattingPolicy) { TypeSystemAstBuilder astBuilder = CreateAstBuilder(); - if ((ConversionFlags & ConversionFlags.UseFullyQualifiedMemberNames) == ConversionFlags.UseFullyQualifiedMemberNames) { - writer.Write(ConvertType(member.DeclaringType)); - writer.Write('.'); + if ((ConversionFlags & ConversionFlags.ShowDeclaringType) == ConversionFlags.ShowDeclaringType) { + ConvertType(member.DeclaringType, formatter, formattingPolicy); + formatter.WriteToken("."); } switch (member.EntityType) { case EntityType.Indexer: - writer.Write("this"); + formatter.WriteKeyword("this"); break; case EntityType.Constructor: - writer.Write(member.DeclaringType.Name); + formatter.WriteIdentifier(member.DeclaringType.Name); break; case EntityType.Destructor: - writer.Write('~'); - writer.Write(member.DeclaringType.Name); + formatter.WriteToken("~"); + formatter.WriteIdentifier(member.DeclaringType.Name); break; case EntityType.Operator: switch (member.Name) { case "op_Implicit": - writer.Write("implicit operator "); - writer.Write(ConvertType(member.ReturnType)); + formatter.WriteKeyword("implicit"); + formatter.Space(); + formatter.WriteKeyword("operator"); + formatter.Space(); + ConvertType(member.ReturnType, formatter, formattingPolicy); break; case "op_Explicit": - writer.Write("explicit operator "); - writer.Write(ConvertType(member.ReturnType)); + formatter.WriteKeyword("explicit"); + formatter.Space(); + formatter.WriteKeyword("operator"); + formatter.Space(); + ConvertType(member.ReturnType, formatter, formattingPolicy); break; default: - writer.Write("operator "); + formatter.WriteKeyword("operator"); + formatter.Space(); var operatorType = OperatorDeclaration.GetOperatorType(member.Name); if (operatorType.HasValue) - writer.Write(OperatorDeclaration.GetToken(operatorType.Value)); + formatter.WriteToken(OperatorDeclaration.GetToken(operatorType.Value)); else - writer.Write(member.Name); + formatter.WriteIdentifier(member.Name); break; } break; default: - writer.Write(member.Name); + formatter.WriteIdentifier(member.Name); break; } if ((ConversionFlags & ConversionFlags.ShowTypeParameterList) == ConversionFlags.ShowTypeParameterList && member.EntityType == EntityType.Method) { - CreatePrinter(writer).WriteTypeParameters(astBuilder.ConvertEntity(member).GetChildrenByRole(AstNode.Roles.TypeParameter)); + var outputVisitor = new CSharpOutputVisitor(formatter, formattingPolicy); + outputVisitor.WriteTypeParameters(astBuilder.ConvertEntity(member).GetChildrenByRole(Roles.TypeParameter)); } } - CSharpOutputVisitor CreatePrinter(StringWriter writer) - { - return new CSharpOutputVisitor(writer, new CSharpFormattingOptions()); - } - - void PrintModifiers(Modifiers modifiers, StringWriter writer) + void PrintModifiers(Modifiers modifiers, IOutputFormatter formatter) { foreach (var m in CSharpModifierToken.AllModifiers) { if ((modifiers & m) == m) { - writer.Write(CSharpModifierToken.GetModifierName(m)); - writer.Write(' '); + formatter.WriteKeyword(CSharpModifierToken.GetModifierName(m)); + formatter.Space(); } } } @@ -210,25 +248,24 @@ namespace ICSharpCode.NRefactory.CSharp { TypeSystemAstBuilder astBuilder = CreateAstBuilder(); AstNode astNode = astBuilder.ConvertVariable(v); - CSharpFormattingOptions formatting = new CSharpFormattingOptions(); - StringWriter writer = new StringWriter(); - astNode.AcceptVisitor(new CSharpOutputVisitor(writer, formatting), null); - return writer.ToString().TrimEnd(';', '\r', '\n'); + return astNode.GetText().TrimEnd(';', '\r', '\n'); } public string ConvertType(IType type) { + if (type == null) + throw new ArgumentNullException("type"); + TypeSystemAstBuilder astBuilder = CreateAstBuilder(); AstType astType = astBuilder.ConvertType(type); - CSharpFormattingOptions formatting = new CSharpFormattingOptions(); - StringWriter writer = new StringWriter(); - astType.AcceptVisitor(new CSharpOutputVisitor(writer, formatting), null); - return writer.ToString(); + return astType.GetText(); } - public string WrapAttribute(string attribute) + public void ConvertType(IType type, IOutputFormatter formatter, CSharpFormattingOptions formattingPolicy) { - return "[" + attribute + "]"; + TypeSystemAstBuilder astBuilder = CreateAstBuilder(); + AstType astType = astBuilder.ConvertType(type); + astType.AcceptVisitor(new CSharpOutputVisitor(formatter, formattingPolicy)); } public string WrapComment(string comment) diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/CSharpOutputVisitor.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/CSharpOutputVisitor.cs index 1aebea0f54..7b7b455c5e 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/CSharpOutputVisitor.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/CSharpOutputVisitor.cs @@ -15,7 +15,6 @@ // FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR // OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. - using System; using System.Collections.Generic; using System.Diagnostics; @@ -32,7 +31,7 @@ namespace ICSharpCode.NRefactory.CSharp /// /// Outputs the AST. /// - public class CSharpOutputVisitor : IAstVisitor + public class CSharpOutputVisitor : IAstVisitor { readonly IOutputFormatter formatter; readonly CSharpFormattingOptions policy; @@ -58,80 +57,50 @@ namespace ICSharpCode.NRefactory.CSharp public CSharpOutputVisitor (TextWriter textWriter, CSharpFormattingOptions formattingPolicy) { - if (textWriter == null) + if (textWriter == null) { throw new ArgumentNullException ("textWriter"); - if (formattingPolicy == null) + } + if (formattingPolicy == null) { throw new ArgumentNullException ("formattingPolicy"); + } this.formatter = new TextWriterOutputFormatter (textWriter); this.policy = formattingPolicy; } public CSharpOutputVisitor (IOutputFormatter formatter, CSharpFormattingOptions formattingPolicy) { - if (formatter == null) + if (formatter == null) { throw new ArgumentNullException ("formatter"); - if (formattingPolicy == null) + } + if (formattingPolicy == null) { throw new ArgumentNullException ("formattingPolicy"); + } this.formatter = formatter; this.policy = formattingPolicy; } #region StartNode/EndNode - public event EventHandler OutputStarted; - - protected virtual void OnOutputStarted (AstNodeEventArgs e) + void StartNode(AstNode node) { - EventHandler handler = this.OutputStarted; - if (handler != null) - handler (this, e); - } - - public event EventHandler OutputFinished; - - protected virtual void OnOutputFinished (AstNodeEventArgs e) - { - EventHandler handler = this.OutputFinished; - if (handler != null) - handler (this, e); - } - - [Serializable] - public sealed class AstNodeEventArgs : EventArgs - { - public AstNode AstNode { - get; - private set; - } - - public AstNodeEventArgs (AstNode node) - { - this.AstNode = node; + // Ensure that nodes are visited in the proper nested order. + // Jumps to different subtrees are allowed only for the child of a placeholder node. + Debug.Assert(containerStack.Count == 0 || node.Parent == containerStack.Peek() || containerStack.Peek().NodeType == NodeType.Pattern); + if (positionStack.Count > 0) { + WriteSpecialsUpToNode(node); } + containerStack.Push(node); + positionStack.Push(node.FirstChild); + formatter.StartNode(node); } - void StartNode (AstNode node) + void EndNode(AstNode node) { - // Ensure that nodes are visited in the proper nested order. - // Jumps to different subtrees are allowed only for the child of a placeholder node. - Debug.Assert (containerStack.Count == 0 || node.Parent == containerStack.Peek () || containerStack.Peek ().NodeType == NodeType.Pattern); - if (positionStack.Count > 0) - WriteSpecialsUpToNode (node); - containerStack.Push (node); - positionStack.Push (node.FirstChild); - OnOutputStarted (new AstNodeEventArgs (node)); - formatter.StartNode (node); - } - - object EndNode (AstNode node) - { - Debug.Assert (node == containerStack.Peek ()); - AstNode pos = positionStack.Pop (); - Debug.Assert (pos == null || pos.Parent == node); - WriteSpecials (pos, null); - containerStack.Pop (); - OnOutputFinished (new AstNodeEventArgs (node)); - formatter.EndNode (node); - return null; + Debug.Assert(node == containerStack.Peek()); + AstNode pos = positionStack.Pop(); + Debug.Assert(pos == null || pos.Parent == node); + WriteSpecials(pos, null); + containerStack.Pop(); + formatter.EndNode(node); } #endregion @@ -139,11 +108,11 @@ namespace ICSharpCode.NRefactory.CSharp /// /// Writes all specials from start to end (exclusive). Does not touch the positionStack. /// - void WriteSpecials (AstNode start, AstNode end) + void WriteSpecials(AstNode start, AstNode end) { for (AstNode pos = start; pos != end; pos = pos.NextSibling) { - if (pos.Role == AstNode.Roles.Comment || pos.Role == AstNode.Roles.PreProcessorDirective) { - pos.AcceptVisitor (this, null); + if (pos.Role == Roles.Comment || pos.Role == Roles.NewLine || pos.Role == Roles.PreProcessorDirective) { + pos.AcceptVisitor(this); } } } @@ -152,22 +121,23 @@ namespace ICSharpCode.NRefactory.CSharp /// Writes all specials between the current position (in the positionStack) and the next /// node with the specified role. Advances the current position. /// - void WriteSpecialsUpToRole (Role role) + void WriteSpecialsUpToRole(Role role) { - WriteSpecialsUpToRole (role, null); + WriteSpecialsUpToRole(role, null); } - void WriteSpecialsUpToRole (Role role, AstNode nextNode) + void WriteSpecialsUpToRole(Role role, AstNode nextNode) { - if (positionStack.Count == 0) + if (positionStack.Count == 0) { return; + } // Look for the role between the current position and the nextNode. for (AstNode pos = positionStack.Peek(); pos != null && pos != nextNode; pos = pos.NextSibling) { if (pos.Role == role) { - WriteSpecials (positionStack.Pop (), pos); + WriteSpecials(positionStack.Pop(), pos); // Push the next sibling because the node matching the role is not a special, // and should be considered to be already handled. - positionStack.Push (pos.NextSibling); + positionStack.Push(pos.NextSibling); // This is necessary for OptionalComma() to work correctly. break; } @@ -178,16 +148,17 @@ namespace ICSharpCode.NRefactory.CSharp /// Writes all specials between the current position (in the positionStack) and the specified node. /// Advances the current position. /// - void WriteSpecialsUpToNode (AstNode node) + void WriteSpecialsUpToNode(AstNode node) { - if (positionStack.Count == 0) + if (positionStack.Count == 0) { return; + } for (AstNode pos = positionStack.Peek(); pos != null; pos = pos.NextSibling) { if (pos == node) { - WriteSpecials (positionStack.Pop (), pos); + WriteSpecials(positionStack.Pop(), pos); // Push the next sibling because the node itself is not a special, // and should be considered to be already handled. - positionStack.Push (pos.NextSibling); + positionStack.Push(pos.NextSibling); // This is necessary for OptionalComma() to work correctly. break; } @@ -201,13 +172,15 @@ namespace ICSharpCode.NRefactory.CSharp /// /// The next node after the comma. /// When set prevents printing a space after comma. - void Comma (AstNode nextNode, bool noSpaceAfterComma = false) + void Comma(AstNode nextNode, bool noSpaceAfterComma = false) { - WriteSpecialsUpToRole (AstNode.Roles.Comma, nextNode); - Space (policy.SpaceBeforeBracketComma); // TODO: Comma policy has changed. - formatter.WriteToken (","); + WriteSpecialsUpToRole(Roles.Comma, nextNode); + Space(policy.SpaceBeforeBracketComma); + // TODO: Comma policy has changed. + formatter.WriteToken(","); lastWritten = LastWritten.Other; - Space (!noSpaceAfterComma && policy.SpaceAfterBracketComma); // TODO: Comma policy has changed. + Space(!noSpaceAfterComma && policy.SpaceAfterBracketComma); + // TODO: Comma policy has changed. } /// @@ -217,10 +190,12 @@ namespace ICSharpCode.NRefactory.CSharp { // Look if there's a comma after the current node, and insert it if it exists. AstNode pos = positionStack.Peek(); - while (pos != null && pos.NodeType == NodeType.Whitespace) + while (pos != null && pos.NodeType == NodeType.Whitespace) { pos = pos.NextSibling; - if (pos != null && pos.Role == AstNode.Roles.Comma) + } + if (pos != null && pos.Role == Roles.Comma) { Comma(null, noSpaceAfterComma: true); + } } /// @@ -230,34 +205,36 @@ namespace ICSharpCode.NRefactory.CSharp { // Look if there's a semicolon after the current node, and insert it if it exists. AstNode pos = positionStack.Peek(); - while (pos != null && pos.NodeType == NodeType.Whitespace) + while (pos != null && pos.NodeType == NodeType.Whitespace) { pos = pos.NextSibling; - if (pos != null && pos.Role == AstNode.Roles.Semicolon) + } + if (pos != null && pos.Role == Roles.Semicolon) { Semicolon(); + } } - void WriteCommaSeparatedList (IEnumerable list) + void WriteCommaSeparatedList(IEnumerable list) { bool isFirst = true; foreach (AstNode node in list) { if (isFirst) { isFirst = false; } else { - Comma (node); + Comma(node); } - node.AcceptVisitor (this, null); + node.AcceptVisitor(this); } } - void WriteCommaSeparatedListInParenthesis (IEnumerable list, bool spaceWithin) + void WriteCommaSeparatedListInParenthesis(IEnumerable list, bool spaceWithin) { - LPar (); - if (list.Any ()) { - Space (spaceWithin); - WriteCommaSeparatedList (list); - Space (spaceWithin); + LPar(); + if (list.Any()) { + Space(spaceWithin); + WriteCommaSeparatedList(list); + Space(spaceWithin); } - RPar (); + RPar(); } #if DOTNET35 @@ -283,26 +260,26 @@ namespace ICSharpCode.NRefactory.CSharp #endif - void WriteCommaSeparatedListInBrackets (IEnumerable list, bool spaceWithin) + void WriteCommaSeparatedListInBrackets(IEnumerable list, bool spaceWithin) { - WriteToken ("[", AstNode.Roles.LBracket); - if (list.Any ()) { - Space (spaceWithin); - WriteCommaSeparatedList (list); - Space (spaceWithin); + WriteToken(Roles.LBracket); + if (list.Any()) { + Space(spaceWithin); + WriteCommaSeparatedList(list); + Space(spaceWithin); } - WriteToken ("]", AstNode.Roles.RBracket); + WriteToken(Roles.RBracket); } - void WriteCommaSeparatedListInBrackets (IEnumerable list) + void WriteCommaSeparatedListInBrackets(IEnumerable list) { - WriteToken ("[", AstNode.Roles.LBracket); - if (list.Any ()) { - Space (policy.SpacesWithinBrackets); - WriteCommaSeparatedList (list); - Space (policy.SpacesWithinBrackets); + WriteToken(Roles.LBracket); + if (list.Any()) { + Space(policy.SpacesWithinBrackets); + WriteCommaSeparatedList(list); + Space(policy.SpacesWithinBrackets); } - WriteToken ("]", AstNode.Roles.RBracket); + WriteToken(Roles.RBracket); } #endregion @@ -310,32 +287,57 @@ namespace ICSharpCode.NRefactory.CSharp /// /// Writes a keyword, and all specials up to /// - void WriteKeyword (string keyword, Role tokenRole = null) + void WriteKeyword(TokenRole tokenRole) + { + WriteKeyword(tokenRole.Token, tokenRole); + } + + void WriteKeyword(string token, Role tokenRole = null) + { + if (tokenRole != null) { + WriteSpecialsUpToRole(tokenRole); + } + if (lastWritten == LastWritten.KeywordOrIdentifier) { + formatter.Space(); + } + formatter.WriteKeyword(token); + lastWritten = LastWritten.KeywordOrIdentifier; + } + +/* void WriteKeyword (string keyword, Role tokenRole) { - WriteSpecialsUpToRole (tokenRole ?? AstNode.Roles.Keyword); + WriteSpecialsUpToRole (tokenRole); if (lastWritten == LastWritten.KeywordOrIdentifier) formatter.Space (); formatter.WriteKeyword (keyword); lastWritten = LastWritten.KeywordOrIdentifier; - } + }*/ - void WriteIdentifier (string identifier, Role identifierRole = null) + void WriteIdentifier(string identifier, Role identifierRole = null) { - WriteSpecialsUpToRole (identifierRole ?? AstNode.Roles.Identifier); - if (IsKeyword (identifier, containerStack.Peek ())) { - if (lastWritten == LastWritten.KeywordOrIdentifier) - Space (); // this space is not strictly required, so we call Space() - formatter.WriteToken ("@"); + WriteSpecialsUpToRole(identifierRole ?? Roles.Identifier); + if (IsKeyword(identifier, containerStack.Peek())) { + if (lastWritten == LastWritten.KeywordOrIdentifier) { + Space(); + } + // this space is not strictly required, so we call Space() + formatter.WriteToken("@"); } else if (lastWritten == LastWritten.KeywordOrIdentifier) { - formatter.Space (); // this space is strictly required, so we directly call the formatter + formatter.Space(); + // this space is strictly required, so we directly call the formatter } - formatter.WriteIdentifier (identifier); + formatter.WriteIdentifier(identifier); lastWritten = LastWritten.KeywordOrIdentifier; } - void WriteToken (string token, Role tokenRole) + void WriteToken(TokenRole tokenRole) { - WriteSpecialsUpToRole (tokenRole); + WriteToken(tokenRole.Token, tokenRole); + } + + void WriteToken(string token, Role tokenRole) + { + WriteSpecialsUpToRole(tokenRole); // Avoid that two +, - or ? tokens are combined into a ++, -- or ?? token. // Note that we don't need to handle tokens like = because there's no valid // C# program that contains the single token twice in a row. @@ -343,77 +345,79 @@ namespace ICSharpCode.NRefactory.CSharp // for ?, this can happen in "a is int? ? b : c" or "a as int? ?? 0"; // and for /, this can happen with "1/ *ptr" or "1/ //comment".) if (lastWritten == LastWritten.Plus && token [0] == '+' - || lastWritten == LastWritten.Minus && token [0] == '-' - || lastWritten == LastWritten.Ampersand && token [0] == '&' - || lastWritten == LastWritten.QuestionMark && token [0] == '?' - || lastWritten == LastWritten.Division && token [0] == '*') { - formatter.Space (); - } - formatter.WriteToken (token); - if (token == "+") + || lastWritten == LastWritten.Minus && token [0] == '-' + || lastWritten == LastWritten.Ampersand && token [0] == '&' + || lastWritten == LastWritten.QuestionMark && token [0] == '?' + || lastWritten == LastWritten.Division && token [0] == '*') { + formatter.Space(); + } + formatter.WriteToken(token); + if (token == "+") { lastWritten = LastWritten.Plus; - else if (token == "-") + } else if (token == "-") { lastWritten = LastWritten.Minus; - else if (token == "&") + } else if (token == "&") { lastWritten = LastWritten.Ampersand; - else if (token == "?") + } else if (token == "?") { lastWritten = LastWritten.QuestionMark; - else if (token == "/") + } else if (token == "/") { lastWritten = LastWritten.Division; - else + } else { lastWritten = LastWritten.Other; + } } - void LPar () + void LPar() { - WriteToken ("(", AstNode.Roles.LPar); + WriteToken(Roles.LPar); } - void RPar () + void RPar() { - WriteToken (")", AstNode.Roles.RPar); + WriteToken(Roles.RPar); } /// /// Marks the end of a statement /// - void Semicolon () + void Semicolon() { - Role role = containerStack.Peek ().Role; // get the role of the current node + Role role = containerStack.Peek().Role; + // get the role of the current node if (!(role == ForStatement.InitializerRole || role == ForStatement.IteratorRole || role == UsingStatement.ResourceAcquisitionRole)) { - WriteToken (";", AstNode.Roles.Semicolon); - NewLine (); + WriteToken(Roles.Semicolon); + NewLine(); } } /// /// Writes a space depending on policy. /// - void Space (bool addSpace = true) + void Space(bool addSpace = true) { if (addSpace) { - formatter.Space (); + formatter.Space(); lastWritten = LastWritten.Whitespace; } } - void NewLine () + void NewLine() { - formatter.NewLine (); + formatter.NewLine(); lastWritten = LastWritten.Whitespace; } - void OpenBrace (BraceStyle style) + void OpenBrace(BraceStyle style) { - WriteSpecialsUpToRole (AstNode.Roles.LBrace); - formatter.OpenBrace (style); + WriteSpecialsUpToRole(Roles.LBrace); + formatter.OpenBrace(style); lastWritten = LastWritten.Other; } - void CloseBrace (BraceStyle style) + void CloseBrace(BraceStyle style) { - WriteSpecialsUpToRole (AstNode.Roles.RBrace); - formatter.CloseBrace (style); + WriteSpecialsUpToRole(Roles.RBrace); + formatter.CloseBrace(style); lastWritten = LastWritten.Other; } @@ -440,21 +444,26 @@ namespace ICSharpCode.NRefactory.CSharp /// /// Determines whether the specified identifier is a keyword in the given context. /// - public static bool IsKeyword (string identifier, AstNode context) + public static bool IsKeyword(string identifier, AstNode context) { - if (unconditionalKeywords.Contains (identifier)) + if (unconditionalKeywords.Contains(identifier)) { return true; + } foreach (AstNode ancestor in context.Ancestors) { - if (ancestor is QueryExpression && queryKeywords.Contains (identifier)) + if (ancestor is QueryExpression && queryKeywords.Contains(identifier)) { return true; + } if (identifier == "await") { // with lambdas/anonymous methods, - if (ancestor is LambdaExpression) + if (ancestor is LambdaExpression) { return ((LambdaExpression)ancestor).IsAsync; - if (ancestor is AnonymousMethodExpression) + } + if (ancestor is AnonymousMethodExpression) { return ((AnonymousMethodExpression)ancestor).IsAsync; - if (ancestor is AttributedNode) - return (((AttributedNode)ancestor).Modifiers & Modifiers.Async) == Modifiers.Async; + } + if (ancestor is EntityDeclaration) { + return (((EntityDeclaration)ancestor).Modifiers & Modifiers.Async) == Modifiers.Async; + } } } return false; @@ -462,162 +471,168 @@ namespace ICSharpCode.NRefactory.CSharp #endregion #region Write constructs - void WriteTypeArguments (IEnumerable typeArguments) + void WriteTypeArguments(IEnumerable typeArguments) { - if (typeArguments.Any ()) { - WriteToken ("<", AstNode.Roles.LChevron); - WriteCommaSeparatedList (typeArguments); - WriteToken (">", AstNode.Roles.RChevron); + if (typeArguments.Any()) { + WriteToken(Roles.LChevron); + WriteCommaSeparatedList(typeArguments); + WriteToken(Roles.RChevron); } } - public void WriteTypeParameters (IEnumerable typeParameters) + public void WriteTypeParameters(IEnumerable typeParameters) { - if (typeParameters.Any ()) { - WriteToken ("<", AstNode.Roles.LChevron); - WriteCommaSeparatedList (typeParameters); - WriteToken (">", AstNode.Roles.RChevron); + if (typeParameters.Any()) { + WriteToken(Roles.LChevron); + WriteCommaSeparatedList(typeParameters); + WriteToken(Roles.RChevron); } } - void WriteModifiers (IEnumerable modifierTokens) + void WriteModifiers(IEnumerable modifierTokens) { foreach (CSharpModifierToken modifier in modifierTokens) { - modifier.AcceptVisitor (this, null); + modifier.AcceptVisitor(this); } } - void WriteQualifiedIdentifier (IEnumerable identifiers) + void WriteQualifiedIdentifier(IEnumerable identifiers) { bool first = true; foreach (Identifier ident in identifiers) { if (first) { first = false; - if (lastWritten == LastWritten.KeywordOrIdentifier) - formatter.Space (); + if (lastWritten == LastWritten.KeywordOrIdentifier) { + formatter.Space(); + } } else { - WriteSpecialsUpToRole (AstNode.Roles.Dot, ident); - formatter.WriteToken ("."); + WriteSpecialsUpToRole(Roles.Dot, ident); + formatter.WriteToken("."); lastWritten = LastWritten.Other; } - WriteSpecialsUpToNode (ident); - formatter.WriteIdentifier (ident.Name); + WriteSpecialsUpToNode(ident); + formatter.WriteIdentifier(ident.Name); lastWritten = LastWritten.KeywordOrIdentifier; } } - void WriteEmbeddedStatement (Statement embeddedStatement) + void WriteEmbeddedStatement(Statement embeddedStatement) { - if (embeddedStatement.IsNull) + if (embeddedStatement.IsNull) { + NewLine(); return; + } BlockStatement block = embeddedStatement as BlockStatement; - if (block != null) - VisitBlockStatement (block, null); - else { - NewLine (); - formatter.Indent (); - embeddedStatement.AcceptVisitor (this, null); - formatter.Unindent (); + if (block != null) { + VisitBlockStatement(block); + } else { + NewLine(); + formatter.Indent(); + embeddedStatement.AcceptVisitor(this); + formatter.Unindent(); } } - void WriteMethodBody (BlockStatement body) + void WriteMethodBody(BlockStatement body) { - if (body.IsNull) - Semicolon (); - else - VisitBlockStatement (body, null); + if (body.IsNull) { + Semicolon(); + } else { + VisitBlockStatement(body); + } } - void WriteAttributes (IEnumerable attributes) + void WriteAttributes(IEnumerable attributes) { foreach (AttributeSection attr in attributes) { - attr.AcceptVisitor (this, null); + attr.AcceptVisitor(this); } } - void WritePrivateImplementationType (AstType privateImplementationType) + void WritePrivateImplementationType(AstType privateImplementationType) { if (!privateImplementationType.IsNull) { - privateImplementationType.AcceptVisitor (this, null); - WriteToken (".", AstNode.Roles.Dot); + privateImplementationType.AcceptVisitor(this); + WriteToken(Roles.Dot); } } #endregion #region Expressions - public object VisitAnonymousMethodExpression (AnonymousMethodExpression anonymousMethodExpression, object data) + public void VisitAnonymousMethodExpression(AnonymousMethodExpression anonymousMethodExpression) { - StartNode (anonymousMethodExpression); + StartNode(anonymousMethodExpression); if (anonymousMethodExpression.IsAsync) { - WriteKeyword ("async", AnonymousMethodExpression.AsyncModifierRole); - Space (); + WriteKeyword(AnonymousMethodExpression.AsyncModifierRole); + Space(); } - WriteKeyword ("delegate"); + WriteKeyword(AnonymousMethodExpression.DelegateKeywordRole); if (anonymousMethodExpression.HasParameterList) { - Space (policy.SpaceBeforeMethodDeclarationParentheses); - WriteCommaSeparatedListInParenthesis (anonymousMethodExpression.Parameters, policy.SpaceWithinMethodDeclarationParentheses); + Space(policy.SpaceBeforeMethodDeclarationParentheses); + WriteCommaSeparatedListInParenthesis(anonymousMethodExpression.Parameters, policy.SpaceWithinMethodDeclarationParentheses); } - anonymousMethodExpression.Body.AcceptVisitor (this, data); - return EndNode (anonymousMethodExpression); + anonymousMethodExpression.Body.AcceptVisitor(this); + EndNode(anonymousMethodExpression); } - public object VisitUndocumentedExpression (UndocumentedExpression undocumentedExpression, object data) + public void VisitUndocumentedExpression(UndocumentedExpression undocumentedExpression) { - StartNode (undocumentedExpression); + StartNode(undocumentedExpression); switch (undocumentedExpression.UndocumentedExpressionType) { case UndocumentedExpressionType.ArgList: case UndocumentedExpressionType.ArgListAccess: - WriteKeyword ("__arglist"); + WriteKeyword(UndocumentedExpression.ArglistKeywordRole); break; case UndocumentedExpressionType.MakeRef: - WriteKeyword ("__makeref"); + WriteKeyword(UndocumentedExpression.MakerefKeywordRole); break; case UndocumentedExpressionType.RefType: - WriteKeyword ("__reftype"); + WriteKeyword(UndocumentedExpression.ReftypeKeywordRole); break; case UndocumentedExpressionType.RefValue: - WriteKeyword ("__refvalue"); + WriteKeyword(UndocumentedExpression.RefvalueKeywordRole); break; } if (undocumentedExpression.Arguments.Count > 0) { - Space (policy.SpaceBeforeMethodCallParentheses); - WriteCommaSeparatedListInParenthesis (undocumentedExpression.Arguments, policy.SpaceWithinMethodCallParentheses); + Space(policy.SpaceBeforeMethodCallParentheses); + WriteCommaSeparatedListInParenthesis(undocumentedExpression.Arguments, policy.SpaceWithinMethodCallParentheses); } - return EndNode (undocumentedExpression); + EndNode(undocumentedExpression); } - public object VisitArrayCreateExpression (ArrayCreateExpression arrayCreateExpression, object data) + public void VisitArrayCreateExpression(ArrayCreateExpression arrayCreateExpression) { - StartNode (arrayCreateExpression); - WriteKeyword ("new"); - arrayCreateExpression.Type.AcceptVisitor (this, data); - if (arrayCreateExpression.Arguments.Count > 0) - WriteCommaSeparatedListInBrackets (arrayCreateExpression.Arguments); - foreach (var specifier in arrayCreateExpression.AdditionalArraySpecifiers) - specifier.AcceptVisitor (this, data); - arrayCreateExpression.Initializer.AcceptVisitor (this, data); - return EndNode (arrayCreateExpression); + StartNode(arrayCreateExpression); + WriteKeyword(ArrayCreateExpression.NewKeywordRole); + arrayCreateExpression.Type.AcceptVisitor(this); + if (arrayCreateExpression.Arguments.Count > 0) { + WriteCommaSeparatedListInBrackets(arrayCreateExpression.Arguments); + } + foreach (var specifier in arrayCreateExpression.AdditionalArraySpecifiers) { + specifier.AcceptVisitor(this); + } + arrayCreateExpression.Initializer.AcceptVisitor(this); + EndNode(arrayCreateExpression); } - public object VisitArrayInitializerExpression (ArrayInitializerExpression arrayInitializerExpression, object data) + public void VisitArrayInitializerExpression(ArrayInitializerExpression arrayInitializerExpression) { - StartNode (arrayInitializerExpression); + StartNode(arrayInitializerExpression); // "new List { { 1 } }" and "new List { 1 }" are the same semantically. // We also use the same AST for both: we always use two nested ArrayInitializerExpressions // for collection initializers, even if the user did not write nested brackets. // The output visitor will output nested braces only if they are necessary, // or if the braces tokens exist in the AST. bool bracesAreOptional = arrayInitializerExpression.Elements.Count == 1 - && IsObjectOrCollectionInitializer(arrayInitializerExpression.Parent) - && !CanBeConfusedWithObjectInitializer(arrayInitializerExpression.Elements.Single()); + && IsObjectOrCollectionInitializer(arrayInitializerExpression.Parent) + && !CanBeConfusedWithObjectInitializer(arrayInitializerExpression.Elements.Single()); if (bracesAreOptional && arrayInitializerExpression.LBraceToken.IsNull) { - arrayInitializerExpression.Elements.Single().AcceptVisitor(this, data); + arrayInitializerExpression.Elements.Single().AcceptVisitor(this); } else { PrintInitializerElements(arrayInitializerExpression.Elements); } - return EndNode (arrayInitializerExpression); + EndNode(arrayInitializerExpression); } bool CanBeConfusedWithObjectInitializer(Expression expr) @@ -630,22 +645,26 @@ namespace ICSharpCode.NRefactory.CSharp bool IsObjectOrCollectionInitializer(AstNode node) { - if (!(node is ArrayInitializerExpression)) + if (!(node is ArrayInitializerExpression)) { return false; - if (node.Parent is ObjectCreateExpression) + } + if (node.Parent is ObjectCreateExpression) { return node.Role == ObjectCreateExpression.InitializerRole; - if (node.Parent is NamedExpression) - return node.Role == NamedExpression.Roles.Expression; + } + if (node.Parent is NamedExpression) { + return node.Role == Roles.Expression; + } return false; } void PrintInitializerElements(AstNodeCollection elements) { BraceStyle style; - if (policy.PlaceArrayInitializersOnNewLine == ArrayInitializerPlacement.AlwaysNewLine) + if (policy.ArrayInitializerWrapping == Wrapping.WrapAlways) { style = BraceStyle.NextLine; - else + } else { style = BraceStyle.EndOfLine; + } OpenBrace(style); bool isFirst = true; foreach (AstNode node in elements) { @@ -655,46 +674,46 @@ namespace ICSharpCode.NRefactory.CSharp Comma(node, noSpaceAfterComma: true); NewLine(); } - node.AcceptVisitor(this, null); + node.AcceptVisitor(this); } OptionalComma(); NewLine(); CloseBrace(style); } - public object VisitAsExpression (AsExpression asExpression, object data) + public void VisitAsExpression(AsExpression asExpression) { - StartNode (asExpression); - asExpression.Expression.AcceptVisitor (this, data); - Space (); - WriteKeyword ("as"); - Space (); - asExpression.Type.AcceptVisitor (this, data); - return EndNode (asExpression); + StartNode(asExpression); + asExpression.Expression.AcceptVisitor(this); + Space(); + WriteKeyword(AsExpression.AsKeywordRole); + Space(); + asExpression.Type.AcceptVisitor(this); + EndNode(asExpression); } - public object VisitAssignmentExpression (AssignmentExpression assignmentExpression, object data) + public void VisitAssignmentExpression(AssignmentExpression assignmentExpression) { - StartNode (assignmentExpression); - assignmentExpression.Left.AcceptVisitor (this, data); - Space (policy.SpaceAroundAssignment); - WriteToken (AssignmentExpression.GetOperatorSymbol (assignmentExpression.Operator), AssignmentExpression.OperatorRole); - Space (policy.SpaceAroundAssignment); - assignmentExpression.Right.AcceptVisitor (this, data); - return EndNode (assignmentExpression); + StartNode(assignmentExpression); + assignmentExpression.Left.AcceptVisitor(this); + Space(policy.SpaceAroundAssignment); + WriteToken(AssignmentExpression.GetOperatorRole(assignmentExpression.Operator)); + Space(policy.SpaceAroundAssignment); + assignmentExpression.Right.AcceptVisitor(this); + EndNode(assignmentExpression); } - public object VisitBaseReferenceExpression (BaseReferenceExpression baseReferenceExpression, object data) + public void VisitBaseReferenceExpression(BaseReferenceExpression baseReferenceExpression) { - StartNode (baseReferenceExpression); - WriteKeyword ("base"); - return EndNode (baseReferenceExpression); + StartNode(baseReferenceExpression); + WriteKeyword("base", baseReferenceExpression.Role); + EndNode(baseReferenceExpression); } - public object VisitBinaryOperatorExpression (BinaryOperatorExpression binaryOperatorExpression, object data) + public void VisitBinaryOperatorExpression(BinaryOperatorExpression binaryOperatorExpression) { - StartNode (binaryOperatorExpression); - binaryOperatorExpression.Left.AcceptVisitor (this, data); + StartNode(binaryOperatorExpression); + binaryOperatorExpression.Left.AcceptVisitor(this); bool spacePolicy; switch (binaryOperatorExpression.Operator) { case BinaryOperatorType.BitwiseAnd: @@ -735,349 +754,355 @@ namespace ICSharpCode.NRefactory.CSharp default: throw new NotSupportedException ("Invalid value for BinaryOperatorType"); } - Space (spacePolicy); - WriteToken (BinaryOperatorExpression.GetOperatorSymbol (binaryOperatorExpression.Operator), BinaryOperatorExpression.OperatorRole); - Space (spacePolicy); - binaryOperatorExpression.Right.AcceptVisitor (this, data); - return EndNode (binaryOperatorExpression); + Space(spacePolicy); + WriteToken(BinaryOperatorExpression.GetOperatorRole(binaryOperatorExpression.Operator)); + Space(spacePolicy); + binaryOperatorExpression.Right.AcceptVisitor(this); + EndNode(binaryOperatorExpression); } - public object VisitCastExpression (CastExpression castExpression, object data) + public void VisitCastExpression(CastExpression castExpression) { - StartNode (castExpression); - LPar (); - Space (policy.SpacesWithinCastParentheses); - castExpression.Type.AcceptVisitor (this, data); - Space (policy.SpacesWithinCastParentheses); - RPar (); - Space (policy.SpaceAfterTypecast); - castExpression.Expression.AcceptVisitor (this, data); - return EndNode (castExpression); + StartNode(castExpression); + LPar(); + Space(policy.SpacesWithinCastParentheses); + castExpression.Type.AcceptVisitor(this); + Space(policy.SpacesWithinCastParentheses); + RPar(); + Space(policy.SpaceAfterTypecast); + castExpression.Expression.AcceptVisitor(this); + EndNode(castExpression); } - public object VisitCheckedExpression (CheckedExpression checkedExpression, object data) + public void VisitCheckedExpression(CheckedExpression checkedExpression) { - StartNode (checkedExpression); - WriteKeyword ("checked"); - LPar (); - Space (policy.SpacesWithinCheckedExpressionParantheses); - checkedExpression.Expression.AcceptVisitor (this, data); - Space (policy.SpacesWithinCheckedExpressionParantheses); - RPar (); - return EndNode (checkedExpression); + StartNode(checkedExpression); + WriteKeyword(CheckedExpression.CheckedKeywordRole); + LPar(); + Space(policy.SpacesWithinCheckedExpressionParantheses); + checkedExpression.Expression.AcceptVisitor(this); + Space(policy.SpacesWithinCheckedExpressionParantheses); + RPar(); + EndNode(checkedExpression); } - public object VisitConditionalExpression (ConditionalExpression conditionalExpression, object data) + public void VisitConditionalExpression(ConditionalExpression conditionalExpression) { - StartNode (conditionalExpression); - conditionalExpression.Condition.AcceptVisitor (this, data); + StartNode(conditionalExpression); + conditionalExpression.Condition.AcceptVisitor(this); - Space (policy.SpaceBeforeConditionalOperatorCondition); - WriteToken ("?", ConditionalExpression.QuestionMarkRole); - Space (policy.SpaceAfterConditionalOperatorCondition); + Space(policy.SpaceBeforeConditionalOperatorCondition); + WriteToken(ConditionalExpression.QuestionMarkRole); + Space(policy.SpaceAfterConditionalOperatorCondition); - conditionalExpression.TrueExpression.AcceptVisitor (this, data); + conditionalExpression.TrueExpression.AcceptVisitor(this); - Space (policy.SpaceBeforeConditionalOperatorSeparator); - WriteToken (":", ConditionalExpression.ColonRole); - Space (policy.SpaceAfterConditionalOperatorSeparator); + Space(policy.SpaceBeforeConditionalOperatorSeparator); + WriteToken(ConditionalExpression.ColonRole); + Space(policy.SpaceAfterConditionalOperatorSeparator); - conditionalExpression.FalseExpression.AcceptVisitor (this, data); + conditionalExpression.FalseExpression.AcceptVisitor(this); - return EndNode (conditionalExpression); + EndNode(conditionalExpression); } - public object VisitDefaultValueExpression (DefaultValueExpression defaultValueExpression, object data) + public void VisitDefaultValueExpression(DefaultValueExpression defaultValueExpression) { - StartNode (defaultValueExpression); + StartNode(defaultValueExpression); - WriteKeyword ("default"); - LPar (); - Space (policy.SpacesWithinTypeOfParentheses); - defaultValueExpression.Type.AcceptVisitor (this, data); - Space (policy.SpacesWithinTypeOfParentheses); - RPar (); + WriteKeyword(DefaultValueExpression.DefaultKeywordRole); + LPar(); + Space(policy.SpacesWithinTypeOfParentheses); + defaultValueExpression.Type.AcceptVisitor(this); + Space(policy.SpacesWithinTypeOfParentheses); + RPar(); - return EndNode (defaultValueExpression); + EndNode(defaultValueExpression); } - public object VisitDirectionExpression (DirectionExpression directionExpression, object data) + public void VisitDirectionExpression(DirectionExpression directionExpression) { - StartNode (directionExpression); + StartNode(directionExpression); switch (directionExpression.FieldDirection) { case FieldDirection.Out: - WriteKeyword ("out"); + WriteKeyword(DirectionExpression.OutKeywordRole); break; case FieldDirection.Ref: - WriteKeyword ("ref"); + WriteKeyword(DirectionExpression.RefKeywordRole); break; default: throw new NotSupportedException ("Invalid value for FieldDirection"); } - Space (); - directionExpression.Expression.AcceptVisitor (this, data); + Space(); + directionExpression.Expression.AcceptVisitor(this); - return EndNode (directionExpression); + EndNode(directionExpression); } - public object VisitIdentifierExpression (IdentifierExpression identifierExpression, object data) + public void VisitIdentifierExpression(IdentifierExpression identifierExpression) { - StartNode (identifierExpression); - WriteIdentifier (identifierExpression.Identifier); - WriteTypeArguments (identifierExpression.TypeArguments); - return EndNode (identifierExpression); + StartNode(identifierExpression); + WriteIdentifier(identifierExpression.Identifier); + WriteTypeArguments(identifierExpression.TypeArguments); + EndNode(identifierExpression); } - public object VisitIndexerExpression (IndexerExpression indexerExpression, object data) + public void VisitIndexerExpression(IndexerExpression indexerExpression) { - StartNode (indexerExpression); - indexerExpression.Target.AcceptVisitor (this, data); - Space (policy.SpaceBeforeMethodCallParentheses); - WriteCommaSeparatedListInBrackets (indexerExpression.Arguments); - return EndNode (indexerExpression); + StartNode(indexerExpression); + indexerExpression.Target.AcceptVisitor(this); + Space(policy.SpaceBeforeMethodCallParentheses); + WriteCommaSeparatedListInBrackets(indexerExpression.Arguments); + EndNode(indexerExpression); } - public object VisitInvocationExpression (InvocationExpression invocationExpression, object data) + public void VisitInvocationExpression(InvocationExpression invocationExpression) { - StartNode (invocationExpression); - invocationExpression.Target.AcceptVisitor (this, data); - Space (policy.SpaceBeforeMethodCallParentheses); - WriteCommaSeparatedListInParenthesis (invocationExpression.Arguments, policy.SpaceWithinMethodCallParentheses); - return EndNode (invocationExpression); + StartNode(invocationExpression); + invocationExpression.Target.AcceptVisitor(this); + Space(policy.SpaceBeforeMethodCallParentheses); + WriteCommaSeparatedListInParenthesis(invocationExpression.Arguments, policy.SpaceWithinMethodCallParentheses); + EndNode(invocationExpression); } - public object VisitIsExpression (IsExpression isExpression, object data) + public void VisitIsExpression(IsExpression isExpression) { - StartNode (isExpression); - isExpression.Expression.AcceptVisitor (this, data); - Space (); - WriteKeyword ("is"); - isExpression.Type.AcceptVisitor (this, data); - return EndNode (isExpression); + StartNode(isExpression); + isExpression.Expression.AcceptVisitor(this); + Space(); + WriteKeyword(IsExpression.IsKeywordRole); + isExpression.Type.AcceptVisitor(this); + EndNode(isExpression); } - public object VisitLambdaExpression (LambdaExpression lambdaExpression, object data) + public void VisitLambdaExpression(LambdaExpression lambdaExpression) { - StartNode (lambdaExpression); + StartNode(lambdaExpression); if (lambdaExpression.IsAsync) { - WriteKeyword ("async", LambdaExpression.AsyncModifierRole); - Space (); + WriteKeyword(LambdaExpression.AsyncModifierRole); + Space(); } - if (LambdaNeedsParenthesis (lambdaExpression)) { - WriteCommaSeparatedListInParenthesis (lambdaExpression.Parameters, policy.SpaceWithinMethodDeclarationParentheses); + if (LambdaNeedsParenthesis(lambdaExpression)) { + WriteCommaSeparatedListInParenthesis(lambdaExpression.Parameters, policy.SpaceWithinMethodDeclarationParentheses); } else { - lambdaExpression.Parameters.Single ().AcceptVisitor (this, data); + lambdaExpression.Parameters.Single().AcceptVisitor(this); } - Space (); - WriteToken ("=>", LambdaExpression.ArrowRole); - Space (); - lambdaExpression.Body.AcceptVisitor (this, data); - return EndNode (lambdaExpression); + Space(); + WriteToken(LambdaExpression.ArrowRole); + Space(); + lambdaExpression.Body.AcceptVisitor(this); + EndNode(lambdaExpression); } - bool LambdaNeedsParenthesis (LambdaExpression lambdaExpression) + bool LambdaNeedsParenthesis(LambdaExpression lambdaExpression) { - if (lambdaExpression.Parameters.Count != 1) + if (lambdaExpression.Parameters.Count != 1) { return true; - var p = lambdaExpression.Parameters.Single (); + } + var p = lambdaExpression.Parameters.Single(); return !(p.Type.IsNull && p.ParameterModifier == ParameterModifier.None); } - public object VisitMemberReferenceExpression (MemberReferenceExpression memberReferenceExpression, object data) + public void VisitMemberReferenceExpression(MemberReferenceExpression memberReferenceExpression) { - StartNode (memberReferenceExpression); - memberReferenceExpression.Target.AcceptVisitor (this, data); - WriteToken (".", MemberReferenceExpression.Roles.Dot); - WriteIdentifier (memberReferenceExpression.MemberName); - WriteTypeArguments (memberReferenceExpression.TypeArguments); - return EndNode (memberReferenceExpression); + StartNode(memberReferenceExpression); + memberReferenceExpression.Target.AcceptVisitor(this); + WriteToken(Roles.Dot); + WriteIdentifier(memberReferenceExpression.MemberName); + WriteTypeArguments(memberReferenceExpression.TypeArguments); + EndNode(memberReferenceExpression); } - public object VisitNamedArgumentExpression (NamedArgumentExpression namedArgumentExpression, object data) + public void VisitNamedArgumentExpression(NamedArgumentExpression namedArgumentExpression) { - StartNode (namedArgumentExpression); - WriteIdentifier (namedArgumentExpression.Identifier); - WriteToken(":", NamedArgumentExpression.Roles.Colon); - Space (); - namedArgumentExpression.Expression.AcceptVisitor (this, data); - return EndNode (namedArgumentExpression); + StartNode(namedArgumentExpression); + namedArgumentExpression.IdentifierToken.AcceptVisitor(this); + WriteToken(Roles.Colon); + Space(); + namedArgumentExpression.Expression.AcceptVisitor(this); + EndNode(namedArgumentExpression); } - public object VisitNamedExpression (NamedExpression namedExpression, object data) + public void VisitNamedExpression(NamedExpression namedExpression) { - StartNode (namedExpression); - WriteIdentifier (namedExpression.Identifier); + StartNode(namedExpression); + namedExpression.IdentifierToken.AcceptVisitor(this); Space(); - WriteToken("=", NamedArgumentExpression.Roles.Assign); - Space (); - namedExpression.Expression.AcceptVisitor (this, data); - return EndNode (namedExpression); + WriteToken(Roles.Assign); + Space(); + namedExpression.Expression.AcceptVisitor(this); + EndNode(namedExpression); } - public object VisitNullReferenceExpression (NullReferenceExpression nullReferenceExpression, object data) + public void VisitNullReferenceExpression(NullReferenceExpression nullReferenceExpression) { - StartNode (nullReferenceExpression); - WriteKeyword ("null"); - return EndNode (nullReferenceExpression); + StartNode(nullReferenceExpression); + WriteKeyword("null", nullReferenceExpression.Role); + EndNode(nullReferenceExpression); } - public object VisitObjectCreateExpression (ObjectCreateExpression objectCreateExpression, object data) + public void VisitObjectCreateExpression(ObjectCreateExpression objectCreateExpression) { - StartNode (objectCreateExpression); - WriteKeyword ("new"); - objectCreateExpression.Type.AcceptVisitor (this, data); + StartNode(objectCreateExpression); + WriteKeyword(ObjectCreateExpression.NewKeywordRole); + objectCreateExpression.Type.AcceptVisitor(this); bool useParenthesis = objectCreateExpression.Arguments.Any() || objectCreateExpression.Initializer.IsNull; // also use parenthesis if there is an '(' token - if (!objectCreateExpression.LParToken.IsNull) + if (!objectCreateExpression.LParToken.IsNull) { useParenthesis = true; + } if (useParenthesis) { - Space (policy.SpaceBeforeMethodCallParentheses); - WriteCommaSeparatedListInParenthesis (objectCreateExpression.Arguments, policy.SpaceWithinMethodCallParentheses); + Space(policy.SpaceBeforeMethodCallParentheses); + WriteCommaSeparatedListInParenthesis(objectCreateExpression.Arguments, policy.SpaceWithinMethodCallParentheses); } - objectCreateExpression.Initializer.AcceptVisitor (this, data); - return EndNode (objectCreateExpression); + objectCreateExpression.Initializer.AcceptVisitor(this); + EndNode(objectCreateExpression); } - public object VisitAnonymousTypeCreateExpression (AnonymousTypeCreateExpression anonymousTypeCreateExpression, object data) + public void VisitAnonymousTypeCreateExpression(AnonymousTypeCreateExpression anonymousTypeCreateExpression) { - StartNode (anonymousTypeCreateExpression); - WriteKeyword ("new"); + StartNode(anonymousTypeCreateExpression); + WriteKeyword(AnonymousTypeCreateExpression.NewKeywordRole); PrintInitializerElements(anonymousTypeCreateExpression.Initializers); - return EndNode (anonymousTypeCreateExpression); + EndNode(anonymousTypeCreateExpression); } - public object VisitParenthesizedExpression (ParenthesizedExpression parenthesizedExpression, object data) + public void VisitParenthesizedExpression(ParenthesizedExpression parenthesizedExpression) { - StartNode (parenthesizedExpression); - LPar (); - Space (policy.SpacesWithinParentheses); - parenthesizedExpression.Expression.AcceptVisitor (this, data); - Space (policy.SpacesWithinParentheses); - RPar (); - return EndNode (parenthesizedExpression); + StartNode(parenthesizedExpression); + LPar(); + Space(policy.SpacesWithinParentheses); + parenthesizedExpression.Expression.AcceptVisitor(this); + Space(policy.SpacesWithinParentheses); + RPar(); + EndNode(parenthesizedExpression); } - public object VisitPointerReferenceExpression (PointerReferenceExpression pointerReferenceExpression, object data) + public void VisitPointerReferenceExpression(PointerReferenceExpression pointerReferenceExpression) { - StartNode (pointerReferenceExpression); - pointerReferenceExpression.Target.AcceptVisitor (this, data); - WriteToken ("->", PointerReferenceExpression.ArrowRole); - WriteIdentifier (pointerReferenceExpression.MemberName); - WriteTypeArguments (pointerReferenceExpression.TypeArguments); - return EndNode (pointerReferenceExpression); + StartNode(pointerReferenceExpression); + pointerReferenceExpression.Target.AcceptVisitor(this); + WriteToken(PointerReferenceExpression.ArrowRole); + WriteIdentifier(pointerReferenceExpression.MemberName); + WriteTypeArguments(pointerReferenceExpression.TypeArguments); + EndNode(pointerReferenceExpression); } - public object VisitEmptyExpression (EmptyExpression emptyExpression, object data) + public void VisitEmptyExpression(EmptyExpression emptyExpression) { - StartNode (emptyExpression); - return EndNode (emptyExpression); + StartNode(emptyExpression); + EndNode(emptyExpression); } #region VisitPrimitiveExpression - public object VisitPrimitiveExpression (PrimitiveExpression primitiveExpression, object data) + public void VisitPrimitiveExpression(PrimitiveExpression primitiveExpression) { - StartNode (primitiveExpression); - if (!string.IsNullOrEmpty (primitiveExpression.LiteralValue)) { - formatter.WriteToken (primitiveExpression.LiteralValue); + StartNode(primitiveExpression); + if (!string.IsNullOrEmpty(primitiveExpression.LiteralValue)) { + formatter.WriteToken(primitiveExpression.LiteralValue); } else { - WritePrimitiveValue (primitiveExpression.Value); + WritePrimitiveValue(primitiveExpression.Value); } - return EndNode (primitiveExpression); + EndNode(primitiveExpression); } - void WritePrimitiveValue (object val) + void WritePrimitiveValue(object val) { if (val == null) { // usually NullReferenceExpression should be used for this, but we'll handle it anyways - WriteKeyword ("null"); + WriteKeyword("null"); return; } if (val is bool) { if ((bool)val) { - WriteKeyword ("true"); + WriteKeyword("true"); } else { - WriteKeyword ("false"); + WriteKeyword("false"); } return; } if (val is string) { - formatter.WriteToken ("\"" + ConvertString (val.ToString ()) + "\""); + formatter.WriteToken("\"" + ConvertString(val.ToString()) + "\""); lastWritten = LastWritten.Other; } else if (val is char) { - formatter.WriteToken ("'" + ConvertCharLiteral ((char)val) + "'"); + formatter.WriteToken("'" + ConvertCharLiteral((char)val) + "'"); lastWritten = LastWritten.Other; } else if (val is decimal) { - formatter.WriteToken (((decimal)val).ToString (NumberFormatInfo.InvariantInfo) + "m"); + formatter.WriteToken(((decimal)val).ToString(NumberFormatInfo.InvariantInfo) + "m"); lastWritten = LastWritten.Other; } else if (val is float) { float f = (float)val; - if (float.IsInfinity (f) || float.IsNaN (f)) { + if (float.IsInfinity(f) || float.IsNaN(f)) { // Strictly speaking, these aren't PrimitiveExpressions; // but we still support writing these to make life easier for code generators. - WriteKeyword ("float"); - WriteToken (".", AstNode.Roles.Dot); - if (float.IsPositiveInfinity (f)) - WriteIdentifier ("PositiveInfinity"); - else if (float.IsNegativeInfinity (f)) - WriteIdentifier ("NegativeInfinity"); - else - WriteIdentifier ("NaN"); + WriteKeyword("float"); + WriteToken(Roles.Dot); + if (float.IsPositiveInfinity(f)) { + WriteIdentifier("PositiveInfinity"); + } else if (float.IsNegativeInfinity(f)) { + WriteIdentifier("NegativeInfinity"); + } else { + WriteIdentifier("NaN"); + } return; } - formatter.WriteToken (f.ToString ("R", NumberFormatInfo.InvariantInfo) + "f"); + formatter.WriteToken(f.ToString("R", NumberFormatInfo.InvariantInfo) + "f"); lastWritten = LastWritten.Other; } else if (val is double) { double f = (double)val; - if (double.IsInfinity (f) || double.IsNaN (f)) { + if (double.IsInfinity(f) || double.IsNaN(f)) { // Strictly speaking, these aren't PrimitiveExpressions; // but we still support writing these to make life easier for code generators. - WriteKeyword ("double"); - WriteToken (".", AstNode.Roles.Dot); - if (double.IsPositiveInfinity (f)) - WriteIdentifier ("PositiveInfinity"); - else if (double.IsNegativeInfinity (f)) - WriteIdentifier ("NegativeInfinity"); - else - WriteIdentifier ("NaN"); + WriteKeyword("double"); + WriteToken(Roles.Dot); + if (double.IsPositiveInfinity(f)) { + WriteIdentifier("PositiveInfinity"); + } else if (double.IsNegativeInfinity(f)) { + WriteIdentifier("NegativeInfinity"); + } else { + WriteIdentifier("NaN"); + } return; } - string number = f.ToString ("R", NumberFormatInfo.InvariantInfo); - if (number.IndexOf ('.') < 0 && number.IndexOf ('E') < 0) + string number = f.ToString("R", NumberFormatInfo.InvariantInfo); + if (number.IndexOf('.') < 0 && number.IndexOf('E') < 0) { number += ".0"; - formatter.WriteToken (number); + } + formatter.WriteToken(number); // needs space if identifier follows number; this avoids mistaking the following identifier as type suffix lastWritten = LastWritten.KeywordOrIdentifier; } else if (val is IFormattable) { StringBuilder b = new StringBuilder (); -// if (primitiveExpression.LiteralFormat == LiteralFormat.HexadecimalNumber) { -// b.Append("0x"); -// b.Append(((IFormattable)val).ToString("x", NumberFormatInfo.InvariantInfo)); -// } else { - b.Append (((IFormattable)val).ToString (null, NumberFormatInfo.InvariantInfo)); -// } + // if (primitiveExpression.LiteralFormat == LiteralFormat.HexadecimalNumber) { + // b.Append("0x"); + // b.Append(((IFormattable)val).ToString("x", NumberFormatInfo.InvariantInfo)); + // } else { + b.Append(((IFormattable)val).ToString(null, NumberFormatInfo.InvariantInfo)); + // } if (val is uint || val is ulong) { - b.Append ("u"); + b.Append("u"); } if (val is long || val is ulong) { - b.Append ("L"); + b.Append("L"); } - formatter.WriteToken (b.ToString ()); + formatter.WriteToken(b.ToString()); // needs space if identifier follows number; this avoids mistaking the following identifier as type suffix lastWritten = LastWritten.KeywordOrIdentifier; } else { - formatter.WriteToken (val.ToString ()); + formatter.WriteToken(val.ToString()); lastWritten = LastWritten.Other; } } - static string ConvertCharLiteral (char ch) + static string ConvertCharLiteral(char ch) { - if (ch == '\'') + if (ch == '\'') { return "\\'"; - return ConvertChar (ch); + } + return ConvertChar(ch); } /// @@ -1107,11 +1132,11 @@ namespace ICSharpCode.NRefactory.CSharp return "\\v"; default: if (char.IsControl(ch) || char.IsSurrogate(ch) || - // print all uncommon white spaces as numbers - (char.IsWhiteSpace(ch) && ch != ' ')) { - return "\\u" + ((int)ch).ToString ("x4"); + // print all uncommon white spaces as numbers + (char.IsWhiteSpace(ch) && ch != ' ')) { + return "\\u" + ((int)ch).ToString("x4"); } else { - return ch.ToString (); + return ch.ToString(); } } } @@ -1123,101 +1148,103 @@ namespace ICSharpCode.NRefactory.CSharp { StringBuilder sb = new StringBuilder (); foreach (char ch in str) { - if (ch == '"') - sb.Append ("\\\""); - else - sb.Append (ConvertChar (ch)); + if (ch == '"') { + sb.Append("\\\""); + } else { + sb.Append(ConvertChar(ch)); + } } - return sb.ToString (); + return sb.ToString(); } #endregion - public object VisitSizeOfExpression (SizeOfExpression sizeOfExpression, object data) + public void VisitSizeOfExpression(SizeOfExpression sizeOfExpression) { - StartNode (sizeOfExpression); + StartNode(sizeOfExpression); - WriteKeyword ("sizeof"); - LPar (); - Space (policy.SpacesWithinSizeOfParentheses); - sizeOfExpression.Type.AcceptVisitor (this, data); - Space (policy.SpacesWithinSizeOfParentheses); - RPar (); + WriteKeyword(SizeOfExpression.SizeofKeywordRole); + LPar(); + Space(policy.SpacesWithinSizeOfParentheses); + sizeOfExpression.Type.AcceptVisitor(this); + Space(policy.SpacesWithinSizeOfParentheses); + RPar(); - return EndNode (sizeOfExpression); + EndNode(sizeOfExpression); } - public object VisitStackAllocExpression (StackAllocExpression stackAllocExpression, object data) + public void VisitStackAllocExpression(StackAllocExpression stackAllocExpression) { - StartNode (stackAllocExpression); - WriteKeyword ("stackalloc"); - stackAllocExpression.Type.AcceptVisitor (this, data); - WriteCommaSeparatedListInBrackets (new[] { stackAllocExpression.CountExpression }); - return EndNode (stackAllocExpression); + StartNode(stackAllocExpression); + WriteKeyword(StackAllocExpression.StackallocKeywordRole); + stackAllocExpression.Type.AcceptVisitor(this); + WriteCommaSeparatedListInBrackets(new[] { stackAllocExpression.CountExpression }); + EndNode(stackAllocExpression); } - public object VisitThisReferenceExpression (ThisReferenceExpression thisReferenceExpression, object data) + public void VisitThisReferenceExpression(ThisReferenceExpression thisReferenceExpression) { - StartNode (thisReferenceExpression); - WriteKeyword ("this"); - return EndNode (thisReferenceExpression); + StartNode(thisReferenceExpression); + WriteKeyword("this", thisReferenceExpression.Role); + EndNode(thisReferenceExpression); } - public object VisitTypeOfExpression (TypeOfExpression typeOfExpression, object data) + public void VisitTypeOfExpression(TypeOfExpression typeOfExpression) { - StartNode (typeOfExpression); + StartNode(typeOfExpression); - WriteKeyword ("typeof"); - LPar (); - Space (policy.SpacesWithinTypeOfParentheses); - typeOfExpression.Type.AcceptVisitor (this, data); - Space (policy.SpacesWithinTypeOfParentheses); - RPar (); + WriteKeyword(TypeOfExpression.TypeofKeywordRole); + LPar(); + Space(policy.SpacesWithinTypeOfParentheses); + typeOfExpression.Type.AcceptVisitor(this); + Space(policy.SpacesWithinTypeOfParentheses); + RPar(); - return EndNode (typeOfExpression); + EndNode(typeOfExpression); } - public object VisitTypeReferenceExpression (TypeReferenceExpression typeReferenceExpression, object data) + public void VisitTypeReferenceExpression(TypeReferenceExpression typeReferenceExpression) { - StartNode (typeReferenceExpression); - typeReferenceExpression.Type.AcceptVisitor (this, data); - return EndNode (typeReferenceExpression); + StartNode(typeReferenceExpression); + typeReferenceExpression.Type.AcceptVisitor(this); + EndNode(typeReferenceExpression); } - public object VisitUnaryOperatorExpression (UnaryOperatorExpression unaryOperatorExpression, object data) + public void VisitUnaryOperatorExpression(UnaryOperatorExpression unaryOperatorExpression) { - StartNode (unaryOperatorExpression); + StartNode(unaryOperatorExpression); UnaryOperatorType opType = unaryOperatorExpression.Operator; - string opSymbol = UnaryOperatorExpression.GetOperatorSymbol (opType); + var opSymbol = UnaryOperatorExpression.GetOperatorRole(opType); if (opType == UnaryOperatorType.Await) { - WriteKeyword (opSymbol, UnaryOperatorExpression.OperatorRole); + WriteKeyword(opSymbol); } else if (!(opType == UnaryOperatorType.PostIncrement || opType == UnaryOperatorType.PostDecrement)) { - WriteToken (opSymbol, UnaryOperatorExpression.OperatorRole); + WriteToken(opSymbol); } - unaryOperatorExpression.Expression.AcceptVisitor (this, data); - if (opType == UnaryOperatorType.PostIncrement || opType == UnaryOperatorType.PostDecrement) - WriteToken (opSymbol, UnaryOperatorExpression.OperatorRole); - return EndNode (unaryOperatorExpression); + unaryOperatorExpression.Expression.AcceptVisitor(this); + if (opType == UnaryOperatorType.PostIncrement || opType == UnaryOperatorType.PostDecrement) { + WriteToken(opSymbol); + } + EndNode(unaryOperatorExpression); } - public object VisitUncheckedExpression (UncheckedExpression uncheckedExpression, object data) + public void VisitUncheckedExpression(UncheckedExpression uncheckedExpression) { - StartNode (uncheckedExpression); - WriteKeyword ("unchecked"); - LPar (); - Space (policy.SpacesWithinCheckedExpressionParantheses); - uncheckedExpression.Expression.AcceptVisitor (this, data); - Space (policy.SpacesWithinCheckedExpressionParantheses); - RPar (); - return EndNode (uncheckedExpression); + StartNode(uncheckedExpression); + WriteKeyword(UncheckedExpression.UncheckedKeywordRole); + LPar(); + Space(policy.SpacesWithinCheckedExpressionParantheses); + uncheckedExpression.Expression.AcceptVisitor(this); + Space(policy.SpacesWithinCheckedExpressionParantheses); + RPar(); + EndNode(uncheckedExpression); } #endregion #region Query Expressions - public object VisitQueryExpression (QueryExpression queryExpression, object data) + public void VisitQueryExpression(QueryExpression queryExpression) { - StartNode (queryExpression); + StartNode(queryExpression); bool indent = !(queryExpression.Parent is QueryContinuationClause); if (indent) { formatter.Indent(); @@ -1228,303 +1255,307 @@ namespace ICSharpCode.NRefactory.CSharp if (first) { first = false; } else { - if (!(clause is QueryContinuationClause)) - NewLine (); + if (!(clause is QueryContinuationClause)) { + NewLine(); + } } - clause.AcceptVisitor (this, data); + clause.AcceptVisitor(this); } - if (indent) + if (indent) { formatter.Unindent(); - return EndNode (queryExpression); - } - - public object VisitQueryContinuationClause (QueryContinuationClause queryContinuationClause, object data) - { - StartNode (queryContinuationClause); - queryContinuationClause.PrecedingQuery.AcceptVisitor (this, data); - Space (); - WriteKeyword ("into", QueryContinuationClause.IntoKeywordRole); - Space (); - WriteIdentifier (queryContinuationClause.Identifier); - return EndNode (queryContinuationClause); - } - - public object VisitQueryFromClause (QueryFromClause queryFromClause, object data) - { - StartNode (queryFromClause); - WriteKeyword ("from", QueryFromClause.FromKeywordRole); - queryFromClause.Type.AcceptVisitor (this, data); - Space (); - WriteIdentifier (queryFromClause.Identifier); - Space (); - WriteKeyword ("in", QueryFromClause.InKeywordRole); - Space (); - queryFromClause.Expression.AcceptVisitor (this, data); - return EndNode (queryFromClause); - } - - public object VisitQueryLetClause (QueryLetClause queryLetClause, object data) - { - StartNode (queryLetClause); - WriteKeyword ("let"); - Space (); - WriteIdentifier (queryLetClause.Identifier); - Space (policy.SpaceAroundAssignment); - WriteToken ("=", QueryLetClause.Roles.Assign); - Space (policy.SpaceAroundAssignment); - queryLetClause.Expression.AcceptVisitor (this, data); - return EndNode (queryLetClause); - } - - public object VisitQueryWhereClause (QueryWhereClause queryWhereClause, object data) - { - StartNode (queryWhereClause); - WriteKeyword ("where"); - Space (); - queryWhereClause.Condition.AcceptVisitor (this, data); - return EndNode (queryWhereClause); - } - - public object VisitQueryJoinClause (QueryJoinClause queryJoinClause, object data) - { - StartNode (queryJoinClause); - WriteKeyword ("join", QueryJoinClause.JoinKeywordRole); - queryJoinClause.Type.AcceptVisitor (this, data); - Space (); - WriteIdentifier (queryJoinClause.JoinIdentifier, QueryJoinClause.JoinIdentifierRole); - Space (); - WriteKeyword ("in", QueryJoinClause.InKeywordRole); - Space (); - queryJoinClause.InExpression.AcceptVisitor (this, data); - Space (); - WriteKeyword ("on", QueryJoinClause.OnKeywordRole); - Space (); - queryJoinClause.OnExpression.AcceptVisitor (this, data); - Space (); - WriteKeyword ("equals", QueryJoinClause.EqualsKeywordRole); - Space (); - queryJoinClause.EqualsExpression.AcceptVisitor (this, data); + } + EndNode(queryExpression); + } + + public void VisitQueryContinuationClause(QueryContinuationClause queryContinuationClause) + { + StartNode(queryContinuationClause); + queryContinuationClause.PrecedingQuery.AcceptVisitor(this); + Space(); + WriteKeyword(QueryContinuationClause.IntoKeywordRole); + Space(); + queryContinuationClause.IdentifierToken.AcceptVisitor(this); + EndNode(queryContinuationClause); + } + + public void VisitQueryFromClause(QueryFromClause queryFromClause) + { + StartNode(queryFromClause); + WriteKeyword(QueryFromClause.FromKeywordRole); + queryFromClause.Type.AcceptVisitor(this); + Space(); + queryFromClause.IdentifierToken.AcceptVisitor(this); + Space(); + WriteKeyword(QueryFromClause.InKeywordRole); + Space(); + queryFromClause.Expression.AcceptVisitor(this); + EndNode(queryFromClause); + } + + public void VisitQueryLetClause(QueryLetClause queryLetClause) + { + StartNode(queryLetClause); + WriteKeyword(QueryLetClause.LetKeywordRole); + Space(); + queryLetClause.IdentifierToken.AcceptVisitor(this); + Space(policy.SpaceAroundAssignment); + WriteToken(Roles.Assign); + Space(policy.SpaceAroundAssignment); + queryLetClause.Expression.AcceptVisitor(this); + EndNode(queryLetClause); + } + + public void VisitQueryWhereClause(QueryWhereClause queryWhereClause) + { + StartNode(queryWhereClause); + WriteKeyword(QueryWhereClause.WhereKeywordRole); + Space(); + queryWhereClause.Condition.AcceptVisitor(this); + EndNode(queryWhereClause); + } + + public void VisitQueryJoinClause(QueryJoinClause queryJoinClause) + { + StartNode(queryJoinClause); + WriteKeyword(QueryJoinClause.JoinKeywordRole); + queryJoinClause.Type.AcceptVisitor(this); + Space(); + WriteIdentifier(queryJoinClause.JoinIdentifier, QueryJoinClause.JoinIdentifierRole); + Space(); + WriteKeyword(QueryJoinClause.InKeywordRole); + Space(); + queryJoinClause.InExpression.AcceptVisitor(this); + Space(); + WriteKeyword(QueryJoinClause.OnKeywordRole); + Space(); + queryJoinClause.OnExpression.AcceptVisitor(this); + Space(); + WriteKeyword(QueryJoinClause.EqualsKeywordRole); + Space(); + queryJoinClause.EqualsExpression.AcceptVisitor(this); if (queryJoinClause.IsGroupJoin) { - Space (); - WriteKeyword ("into", QueryJoinClause.IntoKeywordRole); - WriteIdentifier (queryJoinClause.IntoIdentifier, QueryJoinClause.IntoIdentifierRole); + Space(); + WriteKeyword(QueryJoinClause.IntoKeywordRole); + WriteIdentifier(queryJoinClause.IntoIdentifier, QueryJoinClause.IntoIdentifierRole); } - return EndNode (queryJoinClause); + EndNode(queryJoinClause); } - public object VisitQueryOrderClause (QueryOrderClause queryOrderClause, object data) + public void VisitQueryOrderClause(QueryOrderClause queryOrderClause) { - StartNode (queryOrderClause); - WriteKeyword ("orderby"); - Space (); - WriteCommaSeparatedList (queryOrderClause.Orderings); - return EndNode (queryOrderClause); + StartNode(queryOrderClause); + WriteKeyword(QueryOrderClause.OrderbyKeywordRole); + Space(); + WriteCommaSeparatedList(queryOrderClause.Orderings); + EndNode(queryOrderClause); } - public object VisitQueryOrdering (QueryOrdering queryOrdering, object data) + public void VisitQueryOrdering(QueryOrdering queryOrdering) { - StartNode (queryOrdering); - queryOrdering.Expression.AcceptVisitor (this, data); + StartNode(queryOrdering); + queryOrdering.Expression.AcceptVisitor(this); switch (queryOrdering.Direction) { case QueryOrderingDirection.Ascending: - Space (); - WriteKeyword ("ascending"); + Space(); + WriteKeyword(QueryOrdering.AscendingKeywordRole); break; case QueryOrderingDirection.Descending: - Space (); - WriteKeyword ("descending"); + Space(); + WriteKeyword(QueryOrdering.DescendingKeywordRole); break; } - return EndNode (queryOrdering); + EndNode(queryOrdering); } - public object VisitQuerySelectClause (QuerySelectClause querySelectClause, object data) + public void VisitQuerySelectClause(QuerySelectClause querySelectClause) { - StartNode (querySelectClause); - WriteKeyword ("select"); - Space (); - querySelectClause.Expression.AcceptVisitor (this, data); - return EndNode (querySelectClause); + StartNode(querySelectClause); + WriteKeyword(QuerySelectClause.SelectKeywordRole); + Space(); + querySelectClause.Expression.AcceptVisitor(this); + EndNode(querySelectClause); } - public object VisitQueryGroupClause (QueryGroupClause queryGroupClause, object data) + public void VisitQueryGroupClause(QueryGroupClause queryGroupClause) { - StartNode (queryGroupClause); - WriteKeyword ("group", QueryGroupClause.GroupKeywordRole); - Space (); - queryGroupClause.Projection.AcceptVisitor (this, data); - Space (); - WriteKeyword ("by", QueryGroupClause.ByKeywordRole); - Space (); - queryGroupClause.Key.AcceptVisitor (this, data); - return EndNode (queryGroupClause); + StartNode(queryGroupClause); + WriteKeyword(QueryGroupClause.GroupKeywordRole); + Space(); + queryGroupClause.Projection.AcceptVisitor(this); + Space(); + WriteKeyword(QueryGroupClause.ByKeywordRole); + Space(); + queryGroupClause.Key.AcceptVisitor(this); + EndNode(queryGroupClause); } #endregion #region GeneralScope - public object VisitAttribute (Attribute attribute, object data) - { - StartNode (attribute); - attribute.Type.AcceptVisitor (this, data); - if (attribute.Arguments.Count != 0 || !attribute.GetChildByRole (AstNode.Roles.LPar).IsNull) { - Space (policy.SpaceBeforeMethodCallParentheses); - WriteCommaSeparatedListInParenthesis (attribute.Arguments, policy.SpaceWithinMethodCallParentheses); - } - return EndNode (attribute); - } - - public object VisitAttributeSection (AttributeSection attributeSection, object data) - { - StartNode (attributeSection); - WriteToken ("[", AstNode.Roles.LBracket); - if (!string.IsNullOrEmpty (attributeSection.AttributeTarget)) { - WriteToken (attributeSection.AttributeTarget, AttributeSection.TargetRole); - WriteToken (":", AttributeSection.Roles.Colon); - Space (); - } - WriteCommaSeparatedList (attributeSection.Attributes); - WriteToken ("]", AstNode.Roles.RBracket); - if (attributeSection.Parent is ParameterDeclaration || attributeSection.Parent is TypeParameterDeclaration) - Space (); - else - NewLine (); - return EndNode (attributeSection); - } - - public object VisitDelegateDeclaration (DelegateDeclaration delegateDeclaration, object data) - { - StartNode (delegateDeclaration); - WriteAttributes (delegateDeclaration.Attributes); - WriteModifiers (delegateDeclaration.ModifierTokens); - WriteKeyword ("delegate"); - delegateDeclaration.ReturnType.AcceptVisitor (this, data); - Space (); - WriteIdentifier (delegateDeclaration.Name); - WriteTypeParameters (delegateDeclaration.TypeParameters); - Space (policy.SpaceBeforeDelegateDeclarationParentheses); - WriteCommaSeparatedListInParenthesis (delegateDeclaration.Parameters, policy.SpaceWithinMethodDeclarationParentheses); + public void VisitAttribute(Attribute attribute) + { + StartNode(attribute); + attribute.Type.AcceptVisitor(this); + if (attribute.Arguments.Count != 0 || !attribute.GetChildByRole(Roles.LPar).IsNull) { + Space(policy.SpaceBeforeMethodCallParentheses); + WriteCommaSeparatedListInParenthesis(attribute.Arguments, policy.SpaceWithinMethodCallParentheses); + } + EndNode(attribute); + } + + public void VisitAttributeSection(AttributeSection attributeSection) + { + StartNode(attributeSection); + WriteToken(Roles.LBracket); + if (!string.IsNullOrEmpty(attributeSection.AttributeTarget)) { + WriteToken(attributeSection.AttributeTarget, Roles.AttributeTargetRole); + WriteToken(Roles.Colon); + Space(); + } + WriteCommaSeparatedList(attributeSection.Attributes); + WriteToken(Roles.RBracket); + if (attributeSection.Parent is ParameterDeclaration || attributeSection.Parent is TypeParameterDeclaration) { + Space(); + } else { + NewLine(); + } + EndNode(attributeSection); + } + + public void VisitDelegateDeclaration(DelegateDeclaration delegateDeclaration) + { + StartNode(delegateDeclaration); + WriteAttributes(delegateDeclaration.Attributes); + WriteModifiers(delegateDeclaration.ModifierTokens); + WriteKeyword(Roles.DelegateKeyword); + delegateDeclaration.ReturnType.AcceptVisitor(this); + Space(); + delegateDeclaration.NameToken.AcceptVisitor(this); + WriteTypeParameters(delegateDeclaration.TypeParameters); + Space(policy.SpaceBeforeDelegateDeclarationParentheses); + WriteCommaSeparatedListInParenthesis(delegateDeclaration.Parameters, policy.SpaceWithinMethodDeclarationParentheses); foreach (Constraint constraint in delegateDeclaration.Constraints) { - constraint.AcceptVisitor (this, data); + constraint.AcceptVisitor(this); } - Semicolon (); - return EndNode (delegateDeclaration); + Semicolon(); + EndNode(delegateDeclaration); } - public object VisitNamespaceDeclaration (NamespaceDeclaration namespaceDeclaration, object data) + public void VisitNamespaceDeclaration(NamespaceDeclaration namespaceDeclaration) { - StartNode (namespaceDeclaration); - WriteKeyword ("namespace"); - WriteQualifiedIdentifier (namespaceDeclaration.Identifiers); - OpenBrace (policy.NamespaceBraceStyle); - foreach (var member in namespaceDeclaration.Members) - member.AcceptVisitor (this, data); - CloseBrace (policy.NamespaceBraceStyle); - OptionalSemicolon (); - NewLine (); - return EndNode (namespaceDeclaration); + StartNode(namespaceDeclaration); + WriteKeyword(Roles.NamespaceKeyword); + WriteQualifiedIdentifier(namespaceDeclaration.Identifiers); + OpenBrace(policy.NamespaceBraceStyle); + foreach (var member in namespaceDeclaration.Members) { + member.AcceptVisitor(this); + } + CloseBrace(policy.NamespaceBraceStyle); + OptionalSemicolon(); + NewLine(); + EndNode(namespaceDeclaration); } - public object VisitTypeDeclaration (TypeDeclaration typeDeclaration, object data) + public void VisitTypeDeclaration(TypeDeclaration typeDeclaration) { - StartNode (typeDeclaration); - WriteAttributes (typeDeclaration.Attributes); - WriteModifiers (typeDeclaration.ModifierTokens); + StartNode(typeDeclaration); + WriteAttributes(typeDeclaration.Attributes); + WriteModifiers(typeDeclaration.ModifierTokens); BraceStyle braceStyle; switch (typeDeclaration.ClassType) { case ClassType.Enum: - WriteKeyword ("enum"); + WriteKeyword(Roles.EnumKeyword); braceStyle = policy.EnumBraceStyle; break; case ClassType.Interface: - WriteKeyword ("interface"); + WriteKeyword(Roles.InterfaceKeyword); braceStyle = policy.InterfaceBraceStyle; break; case ClassType.Struct: - WriteKeyword ("struct"); + WriteKeyword(Roles.StructKeyword); braceStyle = policy.StructBraceStyle; break; default: - WriteKeyword ("class"); + WriteKeyword(Roles.ClassKeyword); braceStyle = policy.ClassBraceStyle; break; } - WriteIdentifier (typeDeclaration.Name); - WriteTypeParameters (typeDeclaration.TypeParameters); - if (typeDeclaration.BaseTypes.Any ()) { - Space (); - WriteToken (":", TypeDeclaration.ColonRole); - Space (); - WriteCommaSeparatedList (typeDeclaration.BaseTypes); + typeDeclaration.NameToken.AcceptVisitor(this); + WriteTypeParameters(typeDeclaration.TypeParameters); + if (typeDeclaration.BaseTypes.Any()) { + Space(); + WriteToken(Roles.Colon); + Space(); + WriteCommaSeparatedList(typeDeclaration.BaseTypes); } foreach (Constraint constraint in typeDeclaration.Constraints) { - constraint.AcceptVisitor (this, data); + constraint.AcceptVisitor(this); } - OpenBrace (braceStyle); + OpenBrace(braceStyle); if (typeDeclaration.ClassType == ClassType.Enum) { bool first = true; foreach (var member in typeDeclaration.Members) { if (first) { first = false; } else { - Comma (member, noSpaceAfterComma: true); - NewLine (); + Comma(member, noSpaceAfterComma: true); + NewLine(); } - member.AcceptVisitor (this, data); + member.AcceptVisitor(this); } OptionalComma(); - NewLine (); + NewLine(); } else { foreach (var member in typeDeclaration.Members) { - member.AcceptVisitor (this, data); + member.AcceptVisitor(this); } } - CloseBrace (braceStyle); - OptionalSemicolon (); - NewLine (); - return EndNode (typeDeclaration); + CloseBrace(braceStyle); + OptionalSemicolon(); + NewLine(); + EndNode(typeDeclaration); } - public object VisitUsingAliasDeclaration (UsingAliasDeclaration usingAliasDeclaration, object data) + public void VisitUsingAliasDeclaration(UsingAliasDeclaration usingAliasDeclaration) { - StartNode (usingAliasDeclaration); - WriteKeyword ("using"); - WriteIdentifier (usingAliasDeclaration.Alias, UsingAliasDeclaration.AliasRole); - Space (policy.SpaceAroundEqualityOperator); - WriteToken ("=", AstNode.Roles.Assign); - Space (policy.SpaceAroundEqualityOperator); - usingAliasDeclaration.Import.AcceptVisitor (this, data); - Semicolon (); - return EndNode (usingAliasDeclaration); + StartNode(usingAliasDeclaration); + WriteKeyword(UsingAliasDeclaration.UsingKeywordRole); + WriteIdentifier(usingAliasDeclaration.Alias, UsingAliasDeclaration.AliasRole); + Space(policy.SpaceAroundEqualityOperator); + WriteToken(Roles.Assign); + Space(policy.SpaceAroundEqualityOperator); + usingAliasDeclaration.Import.AcceptVisitor(this); + Semicolon(); + EndNode(usingAliasDeclaration); } - public object VisitUsingDeclaration (UsingDeclaration usingDeclaration, object data) + public void VisitUsingDeclaration(UsingDeclaration usingDeclaration) { - StartNode (usingDeclaration); - WriteKeyword ("using"); - usingDeclaration.Import.AcceptVisitor (this, data); - Semicolon (); - return EndNode (usingDeclaration); + StartNode(usingDeclaration); + WriteKeyword(UsingDeclaration.UsingKeywordRole); + usingDeclaration.Import.AcceptVisitor(this); + Semicolon(); + EndNode(usingDeclaration); } - public object VisitExternAliasDeclaration (ExternAliasDeclaration externAliasDeclaration, object data) + public void VisitExternAliasDeclaration(ExternAliasDeclaration externAliasDeclaration) { - StartNode (externAliasDeclaration); - WriteKeyword ("extern"); - Space (); - WriteKeyword ("alias"); - Space (); - externAliasDeclaration.NameToken.AcceptVisitor (this, data); - Semicolon (); - return EndNode (externAliasDeclaration); + StartNode(externAliasDeclaration); + WriteKeyword(Roles.ExternKeyword); + Space(); + WriteKeyword(Roles.AliasKeyword); + Space(); + externAliasDeclaration.NameToken.AcceptVisitor(this); + Semicolon(); + EndNode(externAliasDeclaration); } #endregion #region Statements - public object VisitBlockStatement (BlockStatement blockStatement, object data) + public void VisitBlockStatement(BlockStatement blockStatement) { - StartNode (blockStatement); + StartNode(blockStatement); BraceStyle style; if (blockStatement.Parent is AnonymousMethodExpression || blockStatement.Parent is LambdaExpression) { style = policy.AnonymousMethodBraceStyle; @@ -1535,196 +1566,199 @@ namespace ICSharpCode.NRefactory.CSharp } else if (blockStatement.Parent is MethodDeclaration) { style = policy.MethodBraceStyle; } else if (blockStatement.Parent is Accessor) { - if (blockStatement.Parent.Role == PropertyDeclaration.GetterRole) + if (blockStatement.Parent.Role == PropertyDeclaration.GetterRole) { style = policy.PropertyGetBraceStyle; - else if (blockStatement.Parent.Role == PropertyDeclaration.SetterRole) + } else if (blockStatement.Parent.Role == PropertyDeclaration.SetterRole) { style = policy.PropertySetBraceStyle; - else if (blockStatement.Parent.Role == CustomEventDeclaration.AddAccessorRole) + } else if (blockStatement.Parent.Role == CustomEventDeclaration.AddAccessorRole) { style = policy.EventAddBraceStyle; - else if (blockStatement.Parent.Role == CustomEventDeclaration.RemoveAccessorRole) + } else if (blockStatement.Parent.Role == CustomEventDeclaration.RemoveAccessorRole) { style = policy.EventRemoveBraceStyle; - else - throw new NotSupportedException ("Unknown type of accessor"); + } else { + style = policy.StatementBraceStyle; + } } else { style = policy.StatementBraceStyle; } - OpenBrace (style); + OpenBrace(style); foreach (var node in blockStatement.Statements) { - node.AcceptVisitor (this, data); + node.AcceptVisitor(this); } - CloseBrace (style); - NewLine (); - return EndNode (blockStatement); + CloseBrace(style); + if (!(blockStatement.Parent is Expression)) + NewLine(); + EndNode(blockStatement); } - public object VisitBreakStatement (BreakStatement breakStatement, object data) + public void VisitBreakStatement(BreakStatement breakStatement) { - StartNode (breakStatement); - WriteKeyword ("break"); - Semicolon (); - return EndNode (breakStatement); + StartNode(breakStatement); + WriteKeyword("break"); + Semicolon(); + EndNode(breakStatement); } - public object VisitCheckedStatement (CheckedStatement checkedStatement, object data) + public void VisitCheckedStatement(CheckedStatement checkedStatement) { - StartNode (checkedStatement); - WriteKeyword ("checked"); - checkedStatement.Body.AcceptVisitor (this, data); - return EndNode (checkedStatement); + StartNode(checkedStatement); + WriteKeyword(CheckedStatement.CheckedKeywordRole); + checkedStatement.Body.AcceptVisitor(this); + EndNode(checkedStatement); } - public object VisitContinueStatement (ContinueStatement continueStatement, object data) + public void VisitContinueStatement(ContinueStatement continueStatement) { - StartNode (continueStatement); - WriteKeyword ("continue"); - Semicolon (); - return EndNode (continueStatement); + StartNode(continueStatement); + WriteKeyword("continue"); + Semicolon(); + EndNode(continueStatement); } - public object VisitDoWhileStatement (DoWhileStatement doWhileStatement, object data) + public void VisitDoWhileStatement(DoWhileStatement doWhileStatement) { - StartNode (doWhileStatement); - WriteKeyword ("do", DoWhileStatement.DoKeywordRole); - WriteEmbeddedStatement (doWhileStatement.EmbeddedStatement); - WriteKeyword ("while", DoWhileStatement.WhileKeywordRole); - Space (policy.SpaceBeforeWhileParentheses); - LPar (); - Space (policy.SpacesWithinWhileParentheses); - doWhileStatement.Condition.AcceptVisitor (this, data); - Space (policy.SpacesWithinWhileParentheses); - RPar (); - Semicolon (); - return EndNode (doWhileStatement); + StartNode(doWhileStatement); + WriteKeyword(DoWhileStatement.DoKeywordRole); + WriteEmbeddedStatement(doWhileStatement.EmbeddedStatement); + WriteKeyword(DoWhileStatement.WhileKeywordRole); + Space(policy.SpaceBeforeWhileParentheses); + LPar(); + Space(policy.SpacesWithinWhileParentheses); + doWhileStatement.Condition.AcceptVisitor(this); + Space(policy.SpacesWithinWhileParentheses); + RPar(); + Semicolon(); + EndNode(doWhileStatement); } - public object VisitEmptyStatement (EmptyStatement emptyStatement, object data) + public void VisitEmptyStatement(EmptyStatement emptyStatement) { - StartNode (emptyStatement); - Semicolon (); - return EndNode (emptyStatement); + StartNode(emptyStatement); + Semicolon(); + EndNode(emptyStatement); } - public object VisitExpressionStatement (ExpressionStatement expressionStatement, object data) + public void VisitExpressionStatement(ExpressionStatement expressionStatement) { - StartNode (expressionStatement); - expressionStatement.Expression.AcceptVisitor (this, data); - Semicolon (); - return EndNode (expressionStatement); + StartNode(expressionStatement); + expressionStatement.Expression.AcceptVisitor(this); + Semicolon(); + EndNode(expressionStatement); } - public object VisitFixedStatement (FixedStatement fixedStatement, object data) + public void VisitFixedStatement(FixedStatement fixedStatement) { - StartNode (fixedStatement); - WriteKeyword ("fixed"); - Space (policy.SpaceBeforeUsingParentheses); - LPar (); - Space (policy.SpacesWithinUsingParentheses); - fixedStatement.Type.AcceptVisitor (this, data); - Space (); - WriteCommaSeparatedList (fixedStatement.Variables); - Space (policy.SpacesWithinUsingParentheses); - RPar (); - WriteEmbeddedStatement (fixedStatement.EmbeddedStatement); - return EndNode (fixedStatement); + StartNode(fixedStatement); + WriteKeyword(FixedStatement.FixedKeywordRole); + Space(policy.SpaceBeforeUsingParentheses); + LPar(); + Space(policy.SpacesWithinUsingParentheses); + fixedStatement.Type.AcceptVisitor(this); + Space(); + WriteCommaSeparatedList(fixedStatement.Variables); + Space(policy.SpacesWithinUsingParentheses); + RPar(); + WriteEmbeddedStatement(fixedStatement.EmbeddedStatement); + EndNode(fixedStatement); } - public object VisitForeachStatement (ForeachStatement foreachStatement, object data) + public void VisitForeachStatement(ForeachStatement foreachStatement) { - StartNode (foreachStatement); - WriteKeyword ("foreach"); - Space (policy.SpaceBeforeForeachParentheses); - LPar (); - Space (policy.SpacesWithinForeachParentheses); - foreachStatement.VariableType.AcceptVisitor (this, data); - Space (); - WriteIdentifier (foreachStatement.VariableName); - WriteKeyword ("in", ForeachStatement.Roles.InKeyword); - Space (); - foreachStatement.InExpression.AcceptVisitor (this, data); - Space (policy.SpacesWithinForeachParentheses); - RPar (); - WriteEmbeddedStatement (foreachStatement.EmbeddedStatement); - return EndNode (foreachStatement); + StartNode(foreachStatement); + WriteKeyword(ForeachStatement.ForeachKeywordRole); + Space(policy.SpaceBeforeForeachParentheses); + LPar(); + Space(policy.SpacesWithinForeachParentheses); + foreachStatement.VariableType.AcceptVisitor(this); + Space(); + foreachStatement.VariableNameToken.AcceptVisitor(this); + WriteKeyword(ForeachStatement.InKeywordRole); + Space(); + foreachStatement.InExpression.AcceptVisitor(this); + Space(policy.SpacesWithinForeachParentheses); + RPar(); + WriteEmbeddedStatement(foreachStatement.EmbeddedStatement); + EndNode(foreachStatement); } - public object VisitForStatement (ForStatement forStatement, object data) + public void VisitForStatement(ForStatement forStatement) { - StartNode (forStatement); - WriteKeyword ("for"); - Space (policy.SpaceBeforeForParentheses); - LPar (); - Space (policy.SpacesWithinForParentheses); + StartNode(forStatement); + WriteKeyword(ForStatement.ForKeywordRole); + Space(policy.SpaceBeforeForParentheses); + LPar(); + Space(policy.SpacesWithinForParentheses); - WriteCommaSeparatedList (forStatement.Initializers); - Space (policy.SpaceBeforeForSemicolon); - WriteToken (";", AstNode.Roles.Semicolon); - Space (policy.SpaceAfterForSemicolon); + WriteCommaSeparatedList(forStatement.Initializers); + Space(policy.SpaceBeforeForSemicolon); + WriteToken(Roles.Semicolon); + Space(policy.SpaceAfterForSemicolon); - forStatement.Condition.AcceptVisitor (this, data); - Space (policy.SpaceBeforeForSemicolon); - WriteToken (";", AstNode.Roles.Semicolon); - Space (policy.SpaceAfterForSemicolon); - - WriteCommaSeparatedList (forStatement.Iterators); + forStatement.Condition.AcceptVisitor(this); + Space(policy.SpaceBeforeForSemicolon); + WriteToken(Roles.Semicolon); + if (forStatement.Iterators.Any()) { + Space(policy.SpaceAfterForSemicolon); + WriteCommaSeparatedList(forStatement.Iterators); + } - Space (policy.SpacesWithinForParentheses); - RPar (); - WriteEmbeddedStatement (forStatement.EmbeddedStatement); - return EndNode (forStatement); + Space(policy.SpacesWithinForParentheses); + RPar(); + WriteEmbeddedStatement(forStatement.EmbeddedStatement); + EndNode(forStatement); } - public object VisitGotoCaseStatement (GotoCaseStatement gotoCaseStatement, object data) + public void VisitGotoCaseStatement(GotoCaseStatement gotoCaseStatement) { - StartNode (gotoCaseStatement); - WriteKeyword ("goto"); - WriteKeyword ("case", GotoCaseStatement.CaseKeywordRole); - Space (); - gotoCaseStatement.LabelExpression.AcceptVisitor (this, data); - Semicolon (); - return EndNode (gotoCaseStatement); + StartNode(gotoCaseStatement); + WriteKeyword(GotoCaseStatement.GotoKeywordRole); + WriteKeyword(GotoCaseStatement.CaseKeywordRole); + Space(); + gotoCaseStatement.LabelExpression.AcceptVisitor(this); + Semicolon(); + EndNode(gotoCaseStatement); } - public object VisitGotoDefaultStatement (GotoDefaultStatement gotoDefaultStatement, object data) + public void VisitGotoDefaultStatement(GotoDefaultStatement gotoDefaultStatement) { - StartNode (gotoDefaultStatement); - WriteKeyword ("goto"); - WriteKeyword ("default", GotoDefaultStatement.DefaultKeywordRole); - Semicolon (); - return EndNode (gotoDefaultStatement); + StartNode(gotoDefaultStatement); + WriteKeyword(GotoDefaultStatement.GotoKeywordRole); + WriteKeyword(GotoDefaultStatement.DefaultKeywordRole); + Semicolon(); + EndNode(gotoDefaultStatement); } - public object VisitGotoStatement (GotoStatement gotoStatement, object data) + public void VisitGotoStatement(GotoStatement gotoStatement) { - StartNode (gotoStatement); - WriteKeyword ("goto"); - WriteIdentifier (gotoStatement.Label); - Semicolon (); - return EndNode (gotoStatement); + StartNode(gotoStatement); + WriteKeyword(GotoStatement.GotoKeywordRole); + WriteIdentifier(gotoStatement.Label); + Semicolon(); + EndNode(gotoStatement); } - public object VisitIfElseStatement (IfElseStatement ifElseStatement, object data) + public void VisitIfElseStatement(IfElseStatement ifElseStatement) { - StartNode (ifElseStatement); - WriteKeyword ("if", IfElseStatement.IfKeywordRole); - Space (policy.SpaceBeforeIfParentheses); - LPar (); - Space (policy.SpacesWithinIfParentheses); - ifElseStatement.Condition.AcceptVisitor (this, data); - Space (policy.SpacesWithinIfParentheses); - RPar (); - WriteEmbeddedStatement (ifElseStatement.TrueStatement); + StartNode(ifElseStatement); + WriteKeyword(IfElseStatement.IfKeywordRole); + Space(policy.SpaceBeforeIfParentheses); + LPar(); + Space(policy.SpacesWithinIfParentheses); + ifElseStatement.Condition.AcceptVisitor(this); + Space(policy.SpacesWithinIfParentheses); + RPar(); + WriteEmbeddedStatement(ifElseStatement.TrueStatement); if (!ifElseStatement.FalseStatement.IsNull) { - WriteKeyword ("else", IfElseStatement.ElseKeywordRole); - WriteEmbeddedStatement (ifElseStatement.FalseStatement); + WriteKeyword(IfElseStatement.ElseKeywordRole); + WriteEmbeddedStatement(ifElseStatement.FalseStatement); } - return EndNode (ifElseStatement); + EndNode(ifElseStatement); } - public object VisitLabelStatement (LabelStatement labelStatement, object data) + public void VisitLabelStatement(LabelStatement labelStatement) { - StartNode (labelStatement); - WriteIdentifier (labelStatement.Label); - WriteToken (":", LabelStatement.Roles.Colon); + StartNode(labelStatement); + WriteIdentifier(labelStatement.Label); + WriteToken(Roles.Colon); bool foundLabelledStatement = false; for (AstNode tmp = labelStatement.NextSibling; tmp != null; tmp = tmp.NextSibling) { if (tmp.Role == labelStatement.Role) { @@ -1733,765 +1767,850 @@ namespace ICSharpCode.NRefactory.CSharp } if (!foundLabelledStatement) { // introduce an EmptyStatement so that the output becomes syntactically valid - WriteToken(";", LabelStatement.Roles.Semicolon); + WriteToken(Roles.Semicolon); } - NewLine (); - return EndNode (labelStatement); + NewLine(); + EndNode(labelStatement); } - public object VisitLockStatement (LockStatement lockStatement, object data) + public void VisitLockStatement(LockStatement lockStatement) { - StartNode (lockStatement); - WriteKeyword ("lock"); - Space (policy.SpaceBeforeLockParentheses); - LPar (); - Space (policy.SpacesWithinLockParentheses); - lockStatement.Expression.AcceptVisitor (this, data); - Space (policy.SpacesWithinLockParentheses); - RPar (); - WriteEmbeddedStatement (lockStatement.EmbeddedStatement); - return EndNode (lockStatement); + StartNode(lockStatement); + WriteKeyword(LockStatement.LockKeywordRole); + Space(policy.SpaceBeforeLockParentheses); + LPar(); + Space(policy.SpacesWithinLockParentheses); + lockStatement.Expression.AcceptVisitor(this); + Space(policy.SpacesWithinLockParentheses); + RPar(); + WriteEmbeddedStatement(lockStatement.EmbeddedStatement); + EndNode(lockStatement); } - public object VisitReturnStatement (ReturnStatement returnStatement, object data) + public void VisitReturnStatement(ReturnStatement returnStatement) { - StartNode (returnStatement); - WriteKeyword ("return"); + StartNode(returnStatement); + WriteKeyword(ReturnStatement.ReturnKeywordRole); if (!returnStatement.Expression.IsNull) { - Space (); - returnStatement.Expression.AcceptVisitor (this, data); - } - Semicolon (); - return EndNode (returnStatement); - } - - public object VisitSwitchStatement (SwitchStatement switchStatement, object data) - { - StartNode (switchStatement); - WriteKeyword ("switch"); - Space (policy.SpaceBeforeSwitchParentheses); - LPar (); - Space (policy.SpacesWithinSwitchParentheses); - switchStatement.Expression.AcceptVisitor (this, data); - Space (policy.SpacesWithinSwitchParentheses); - RPar (); - OpenBrace (policy.StatementBraceStyle); - if (!policy.IndentSwitchBody) - formatter.Unindent (); + Space(); + returnStatement.Expression.AcceptVisitor(this); + } + Semicolon(); + EndNode(returnStatement); + } + + public void VisitSwitchStatement(SwitchStatement switchStatement) + { + StartNode(switchStatement); + WriteKeyword(SwitchStatement.SwitchKeywordRole); + Space(policy.SpaceBeforeSwitchParentheses); + LPar(); + Space(policy.SpacesWithinSwitchParentheses); + switchStatement.Expression.AcceptVisitor(this); + Space(policy.SpacesWithinSwitchParentheses); + RPar(); + OpenBrace(policy.StatementBraceStyle); + if (!policy.IndentSwitchBody) { + formatter.Unindent(); + } - foreach (var section in switchStatement.SwitchSections) - section.AcceptVisitor (this, data); + foreach (var section in switchStatement.SwitchSections) { + section.AcceptVisitor(this); + } - if (!policy.IndentSwitchBody) - formatter.Indent (); - CloseBrace (policy.StatementBraceStyle); - NewLine (); - return EndNode (switchStatement); + if (!policy.IndentSwitchBody) { + formatter.Indent(); + } + CloseBrace(policy.StatementBraceStyle); + NewLine(); + EndNode(switchStatement); } - public object VisitSwitchSection (SwitchSection switchSection, object data) + public void VisitSwitchSection(SwitchSection switchSection) { - StartNode (switchSection); + StartNode(switchSection); bool first = true; foreach (var label in switchSection.CaseLabels) { - if (!first) - NewLine (); - label.AcceptVisitor (this, data); + if (!first) { + NewLine(); + } + label.AcceptVisitor(this); first = false; } - if (policy.IndentCaseBody) - formatter.Indent (); + bool isBlock = switchSection.Statements.Count == 1 && switchSection.Statements.Single() is BlockStatement; + if (policy.IndentCaseBody && !isBlock) { + formatter.Indent(); + } + + if (!isBlock) + NewLine(); foreach (var statement in switchSection.Statements) { - NewLine (); - statement.AcceptVisitor (this, data); + statement.AcceptVisitor(this); } - if (policy.IndentCaseBody) - formatter.Unindent (); + if (policy.IndentCaseBody && !isBlock) { + formatter.Unindent(); + } - return EndNode (switchSection); + EndNode(switchSection); } - public object VisitCaseLabel (CaseLabel caseLabel, object data) + public void VisitCaseLabel(CaseLabel caseLabel) { - StartNode (caseLabel); + StartNode(caseLabel); if (caseLabel.Expression.IsNull) { - WriteKeyword ("default"); + WriteKeyword(CaseLabel.DefaultKeywordRole); } else { - WriteKeyword ("case"); - Space (); - caseLabel.Expression.AcceptVisitor (this, data); + WriteKeyword(CaseLabel.CaseKeywordRole); + Space(); + caseLabel.Expression.AcceptVisitor(this); } - WriteToken (":", CaseLabel.Roles.Colon); - return EndNode (caseLabel); + WriteToken(Roles.Colon); + EndNode(caseLabel); } - public object VisitThrowStatement (ThrowStatement throwStatement, object data) + public void VisitThrowStatement(ThrowStatement throwStatement) { - StartNode (throwStatement); - WriteKeyword ("throw"); + StartNode(throwStatement); + WriteKeyword(ThrowStatement.ThrowKeywordRole); if (!throwStatement.Expression.IsNull) { - Space (); - throwStatement.Expression.AcceptVisitor (this, data); + Space(); + throwStatement.Expression.AcceptVisitor(this); } - Semicolon (); - return EndNode (throwStatement); + Semicolon(); + EndNode(throwStatement); } - public object VisitTryCatchStatement (TryCatchStatement tryCatchStatement, object data) + public void VisitTryCatchStatement(TryCatchStatement tryCatchStatement) { - StartNode (tryCatchStatement); - WriteKeyword ("try", TryCatchStatement.TryKeywordRole); - tryCatchStatement.TryBlock.AcceptVisitor (this, data); - foreach (var catchClause in tryCatchStatement.CatchClauses) - catchClause.AcceptVisitor (this, data); + StartNode(tryCatchStatement); + WriteKeyword(TryCatchStatement.TryKeywordRole); + tryCatchStatement.TryBlock.AcceptVisitor(this); + foreach (var catchClause in tryCatchStatement.CatchClauses) { + catchClause.AcceptVisitor(this); + } if (!tryCatchStatement.FinallyBlock.IsNull) { - WriteKeyword ("finally", TryCatchStatement.FinallyKeywordRole); - tryCatchStatement.FinallyBlock.AcceptVisitor (this, data); + WriteKeyword(TryCatchStatement.FinallyKeywordRole); + tryCatchStatement.FinallyBlock.AcceptVisitor(this); } - return EndNode (tryCatchStatement); + EndNode(tryCatchStatement); } - public object VisitCatchClause (CatchClause catchClause, object data) + public void VisitCatchClause(CatchClause catchClause) { - StartNode (catchClause); - WriteKeyword ("catch"); + StartNode(catchClause); + WriteKeyword(CatchClause.CatchKeywordRole); if (!catchClause.Type.IsNull) { - Space (policy.SpaceBeforeCatchParentheses); - LPar (); - Space (policy.SpacesWithinCatchParentheses); - catchClause.Type.AcceptVisitor (this, data); + Space(policy.SpaceBeforeCatchParentheses); + LPar(); + Space(policy.SpacesWithinCatchParentheses); + catchClause.Type.AcceptVisitor(this); if (!string.IsNullOrEmpty(catchClause.VariableName)) { - Space (); - WriteIdentifier (catchClause.VariableName); + Space(); + catchClause.VariableNameToken.AcceptVisitor(this); } - Space (policy.SpacesWithinCatchParentheses); - RPar (); + Space(policy.SpacesWithinCatchParentheses); + RPar(); } - catchClause.Body.AcceptVisitor (this, data); - return EndNode (catchClause); + catchClause.Body.AcceptVisitor(this); + EndNode(catchClause); } - public object VisitUncheckedStatement (UncheckedStatement uncheckedStatement, object data) + public void VisitUncheckedStatement(UncheckedStatement uncheckedStatement) { - StartNode (uncheckedStatement); - WriteKeyword ("unchecked"); - uncheckedStatement.Body.AcceptVisitor (this, data); - return EndNode (uncheckedStatement); + StartNode(uncheckedStatement); + WriteKeyword(UncheckedStatement.UncheckedKeywordRole); + uncheckedStatement.Body.AcceptVisitor(this); + EndNode(uncheckedStatement); } - public object VisitUnsafeStatement (UnsafeStatement unsafeStatement, object data) + public void VisitUnsafeStatement(UnsafeStatement unsafeStatement) { - StartNode (unsafeStatement); - WriteKeyword ("unsafe"); - unsafeStatement.Body.AcceptVisitor (this, data); - return EndNode (unsafeStatement); + StartNode(unsafeStatement); + WriteKeyword(UnsafeStatement.UnsafeKeywordRole); + unsafeStatement.Body.AcceptVisitor(this); + EndNode(unsafeStatement); } - public object VisitUsingStatement (UsingStatement usingStatement, object data) + public void VisitUsingStatement(UsingStatement usingStatement) { - StartNode (usingStatement); - WriteKeyword ("using"); - Space (policy.SpaceBeforeUsingParentheses); - LPar (); - Space (policy.SpacesWithinUsingParentheses); + StartNode(usingStatement); + WriteKeyword(UsingStatement.UsingKeywordRole); + Space(policy.SpaceBeforeUsingParentheses); + LPar(); + Space(policy.SpacesWithinUsingParentheses); - usingStatement.ResourceAcquisition.AcceptVisitor (this, data); + usingStatement.ResourceAcquisition.AcceptVisitor(this); - Space (policy.SpacesWithinUsingParentheses); - RPar (); + Space(policy.SpacesWithinUsingParentheses); + RPar(); - WriteEmbeddedStatement (usingStatement.EmbeddedStatement); + WriteEmbeddedStatement(usingStatement.EmbeddedStatement); - return EndNode (usingStatement); + EndNode(usingStatement); } - public object VisitVariableDeclarationStatement (VariableDeclarationStatement variableDeclarationStatement, object data) + public void VisitVariableDeclarationStatement(VariableDeclarationStatement variableDeclarationStatement) { - StartNode (variableDeclarationStatement); - WriteModifiers (variableDeclarationStatement.GetChildrenByRole (VariableDeclarationStatement.ModifierRole)); - variableDeclarationStatement.Type.AcceptVisitor (this, data); - Space (); - WriteCommaSeparatedList (variableDeclarationStatement.Variables); - Semicolon (); - return EndNode (variableDeclarationStatement); + StartNode(variableDeclarationStatement); + WriteModifiers(variableDeclarationStatement.GetChildrenByRole(VariableDeclarationStatement.ModifierRole)); + variableDeclarationStatement.Type.AcceptVisitor(this); + Space(); + WriteCommaSeparatedList(variableDeclarationStatement.Variables); + Semicolon(); + EndNode(variableDeclarationStatement); } - public object VisitWhileStatement (WhileStatement whileStatement, object data) + public void VisitWhileStatement(WhileStatement whileStatement) { - StartNode (whileStatement); - WriteKeyword ("while", WhileStatement.WhileKeywordRole); - Space (policy.SpaceBeforeWhileParentheses); - LPar (); - Space (policy.SpacesWithinWhileParentheses); - whileStatement.Condition.AcceptVisitor (this, data); - Space (policy.SpacesWithinWhileParentheses); - RPar (); - WriteEmbeddedStatement (whileStatement.EmbeddedStatement); - return EndNode (whileStatement); + StartNode(whileStatement); + WriteKeyword(WhileStatement.WhileKeywordRole); + Space(policy.SpaceBeforeWhileParentheses); + LPar(); + Space(policy.SpacesWithinWhileParentheses); + whileStatement.Condition.AcceptVisitor(this); + Space(policy.SpacesWithinWhileParentheses); + RPar(); + WriteEmbeddedStatement(whileStatement.EmbeddedStatement); + EndNode(whileStatement); } - public object VisitYieldBreakStatement (YieldBreakStatement yieldBreakStatement, object data) + public void VisitYieldBreakStatement(YieldBreakStatement yieldBreakStatement) { - StartNode (yieldBreakStatement); - WriteKeyword ("yield", YieldBreakStatement.YieldKeywordRole); - WriteKeyword ("break", YieldBreakStatement.BreakKeywordRole); - Semicolon (); - return EndNode (yieldBreakStatement); + StartNode(yieldBreakStatement); + WriteKeyword(YieldBreakStatement.YieldKeywordRole); + WriteKeyword(YieldBreakStatement.BreakKeywordRole); + Semicolon(); + EndNode(yieldBreakStatement); } - public object VisitYieldReturnStatement (YieldReturnStatement yieldReturnStatement, object data) + public void VisitYieldReturnStatement(YieldReturnStatement yieldReturnStatement) { - StartNode (yieldReturnStatement); - WriteKeyword ("yield", YieldReturnStatement.YieldKeywordRole); - WriteKeyword ("return", YieldReturnStatement.ReturnKeywordRole); - Space (); - yieldReturnStatement.Expression.AcceptVisitor (this, data); - Semicolon (); - return EndNode (yieldReturnStatement); + StartNode(yieldReturnStatement); + WriteKeyword(YieldReturnStatement.YieldKeywordRole); + WriteKeyword(YieldReturnStatement.ReturnKeywordRole); + Space(); + yieldReturnStatement.Expression.AcceptVisitor(this); + Semicolon(); + EndNode(yieldReturnStatement); } #endregion #region TypeMembers - public object VisitAccessor (Accessor accessor, object data) + public void VisitAccessor(Accessor accessor) { - StartNode (accessor); - WriteAttributes (accessor.Attributes); - WriteModifiers (accessor.ModifierTokens); + StartNode(accessor); + WriteAttributes(accessor.Attributes); + WriteModifiers(accessor.ModifierTokens); if (accessor.Role == PropertyDeclaration.GetterRole) { - WriteKeyword ("get"); + WriteKeyword("get"); } else if (accessor.Role == PropertyDeclaration.SetterRole) { - WriteKeyword ("set"); + WriteKeyword("set"); } else if (accessor.Role == CustomEventDeclaration.AddAccessorRole) { - WriteKeyword ("add"); + WriteKeyword("add"); } else if (accessor.Role == CustomEventDeclaration.RemoveAccessorRole) { - WriteKeyword ("remove"); + WriteKeyword("remove"); } - WriteMethodBody (accessor.Body); - return EndNode (accessor); + WriteMethodBody(accessor.Body); + EndNode(accessor); } - public object VisitConstructorDeclaration (ConstructorDeclaration constructorDeclaration, object data) + public void VisitConstructorDeclaration(ConstructorDeclaration constructorDeclaration) { - StartNode (constructorDeclaration); - WriteAttributes (constructorDeclaration.Attributes); - WriteModifiers (constructorDeclaration.ModifierTokens); + StartNode(constructorDeclaration); + WriteAttributes(constructorDeclaration.Attributes); + WriteModifiers(constructorDeclaration.ModifierTokens); TypeDeclaration type = constructorDeclaration.Parent as TypeDeclaration; - WriteIdentifier (type != null ? type.Name : constructorDeclaration.Name); - Space (policy.SpaceBeforeConstructorDeclarationParentheses); - WriteCommaSeparatedListInParenthesis (constructorDeclaration.Parameters, policy.SpaceWithinMethodDeclarationParentheses); + StartNode(constructorDeclaration.NameToken); + WriteIdentifier(type != null ? type.Name : constructorDeclaration.Name); + EndNode(constructorDeclaration.NameToken); + Space(policy.SpaceBeforeConstructorDeclarationParentheses); + WriteCommaSeparatedListInParenthesis(constructorDeclaration.Parameters, policy.SpaceWithinMethodDeclarationParentheses); if (!constructorDeclaration.Initializer.IsNull) { - Space (); - constructorDeclaration.Initializer.AcceptVisitor (this, data); + Space(); + constructorDeclaration.Initializer.AcceptVisitor(this); } - WriteMethodBody (constructorDeclaration.Body); - return EndNode (constructorDeclaration); + WriteMethodBody(constructorDeclaration.Body); + EndNode(constructorDeclaration); } - public object VisitConstructorInitializer (ConstructorInitializer constructorInitializer, object data) + public void VisitConstructorInitializer(ConstructorInitializer constructorInitializer) { - StartNode (constructorInitializer); - WriteToken (":", ConstructorInitializer.Roles.Colon); - Space (); + StartNode(constructorInitializer); + WriteToken(Roles.Colon); + Space(); if (constructorInitializer.ConstructorInitializerType == ConstructorInitializerType.This) { - WriteKeyword ("this"); + WriteKeyword(ConstructorInitializer.ThisKeywordRole); } else { - WriteKeyword ("base"); + WriteKeyword(ConstructorInitializer.BaseKeywordRole); } - Space (policy.SpaceBeforeMethodCallParentheses); - WriteCommaSeparatedListInParenthesis (constructorInitializer.Arguments, policy.SpaceWithinMethodCallParentheses); - return EndNode (constructorInitializer); + Space(policy.SpaceBeforeMethodCallParentheses); + WriteCommaSeparatedListInParenthesis(constructorInitializer.Arguments, policy.SpaceWithinMethodCallParentheses); + EndNode(constructorInitializer); } - public object VisitDestructorDeclaration (DestructorDeclaration destructorDeclaration, object data) + public void VisitDestructorDeclaration(DestructorDeclaration destructorDeclaration) { - StartNode (destructorDeclaration); - WriteAttributes (destructorDeclaration.Attributes); - WriteModifiers (destructorDeclaration.ModifierTokens); - WriteToken ("~", DestructorDeclaration.TildeRole); + StartNode(destructorDeclaration); + WriteAttributes(destructorDeclaration.Attributes); + WriteModifiers(destructorDeclaration.ModifierTokens); + WriteToken(DestructorDeclaration.TildeRole); TypeDeclaration type = destructorDeclaration.Parent as TypeDeclaration; - WriteIdentifier (type != null ? type.Name : destructorDeclaration.Name); - Space (policy.SpaceBeforeConstructorDeclarationParentheses); - LPar (); - RPar (); - WriteMethodBody (destructorDeclaration.Body); - return EndNode (destructorDeclaration); + StartNode(destructorDeclaration.NameToken); + WriteIdentifier(type != null ? type.Name : destructorDeclaration.Name); + EndNode(destructorDeclaration.NameToken); + Space(policy.SpaceBeforeConstructorDeclarationParentheses); + LPar(); + RPar(); + WriteMethodBody(destructorDeclaration.Body); + EndNode(destructorDeclaration); + } + + public void VisitEnumMemberDeclaration(EnumMemberDeclaration enumMemberDeclaration) + { + StartNode(enumMemberDeclaration); + WriteAttributes(enumMemberDeclaration.Attributes); + WriteModifiers(enumMemberDeclaration.ModifierTokens); + enumMemberDeclaration.NameToken.AcceptVisitor(this); + if (!enumMemberDeclaration.Initializer.IsNull) { + Space(policy.SpaceAroundAssignment); + WriteToken(Roles.Assign); + Space(policy.SpaceAroundAssignment); + enumMemberDeclaration.Initializer.AcceptVisitor(this); + } + EndNode(enumMemberDeclaration); } - public object VisitEnumMemberDeclaration (EnumMemberDeclaration enumMemberDeclaration, object data) + public void VisitEventDeclaration(EventDeclaration eventDeclaration) { - StartNode (enumMemberDeclaration); - WriteAttributes (enumMemberDeclaration.Attributes); - WriteModifiers (enumMemberDeclaration.ModifierTokens); - WriteIdentifier (enumMemberDeclaration.Name); - if (!enumMemberDeclaration.Initializer.IsNull) { - Space (policy.SpaceAroundAssignment); - WriteToken ("=", EnumMemberDeclaration.Roles.Assign); - Space (policy.SpaceAroundAssignment); - enumMemberDeclaration.Initializer.AcceptVisitor (this, data); - } - return EndNode (enumMemberDeclaration); - } - - public object VisitEventDeclaration (EventDeclaration eventDeclaration, object data) - { - StartNode (eventDeclaration); - WriteAttributes (eventDeclaration.Attributes); - WriteModifiers (eventDeclaration.ModifierTokens); - WriteKeyword ("event"); - eventDeclaration.ReturnType.AcceptVisitor (this, data); - Space (); - WriteCommaSeparatedList (eventDeclaration.Variables); - Semicolon (); - return EndNode (eventDeclaration); - } - - public object VisitCustomEventDeclaration (CustomEventDeclaration customEventDeclaration, object data) - { - StartNode (customEventDeclaration); - WriteAttributes (customEventDeclaration.Attributes); - WriteModifiers (customEventDeclaration.ModifierTokens); - WriteKeyword ("event"); - customEventDeclaration.ReturnType.AcceptVisitor (this, data); - Space (); - WritePrivateImplementationType (customEventDeclaration.PrivateImplementationType); - WriteIdentifier (customEventDeclaration.Name); - OpenBrace (policy.EventBraceStyle); + StartNode(eventDeclaration); + WriteAttributes(eventDeclaration.Attributes); + WriteModifiers(eventDeclaration.ModifierTokens); + WriteKeyword(EventDeclaration.EventKeywordRole); + eventDeclaration.ReturnType.AcceptVisitor(this); + Space(); + WriteCommaSeparatedList(eventDeclaration.Variables); + Semicolon(); + EndNode(eventDeclaration); + } + + public void VisitCustomEventDeclaration(CustomEventDeclaration customEventDeclaration) + { + StartNode(customEventDeclaration); + WriteAttributes(customEventDeclaration.Attributes); + WriteModifiers(customEventDeclaration.ModifierTokens); + WriteKeyword(CustomEventDeclaration.EventKeywordRole); + customEventDeclaration.ReturnType.AcceptVisitor(this); + Space(); + WritePrivateImplementationType(customEventDeclaration.PrivateImplementationType); + customEventDeclaration.NameToken.AcceptVisitor(this); + OpenBrace(policy.EventBraceStyle); // output add/remove in their original order foreach (AstNode node in customEventDeclaration.Children) { if (node.Role == CustomEventDeclaration.AddAccessorRole || node.Role == CustomEventDeclaration.RemoveAccessorRole) { - node.AcceptVisitor (this, data); + node.AcceptVisitor(this); } } - CloseBrace (policy.EventBraceStyle); - NewLine (); - return EndNode (customEventDeclaration); + CloseBrace(policy.EventBraceStyle); + NewLine(); + EndNode(customEventDeclaration); } - public object VisitFieldDeclaration (FieldDeclaration fieldDeclaration, object data) + public void VisitFieldDeclaration(FieldDeclaration fieldDeclaration) { - StartNode (fieldDeclaration); - WriteAttributes (fieldDeclaration.Attributes); - WriteModifiers (fieldDeclaration.ModifierTokens); - fieldDeclaration.ReturnType.AcceptVisitor (this, data); - Space (); - WriteCommaSeparatedList (fieldDeclaration.Variables); - Semicolon (); - return EndNode (fieldDeclaration); + StartNode(fieldDeclaration); + WriteAttributes(fieldDeclaration.Attributes); + WriteModifiers(fieldDeclaration.ModifierTokens); + fieldDeclaration.ReturnType.AcceptVisitor(this); + Space(); + WriteCommaSeparatedList(fieldDeclaration.Variables); + Semicolon(); + EndNode(fieldDeclaration); } - public object VisitFixedFieldDeclaration (FixedFieldDeclaration fixedFieldDeclaration, object data) + public void VisitFixedFieldDeclaration(FixedFieldDeclaration fixedFieldDeclaration) { - StartNode (fixedFieldDeclaration); - WriteAttributes (fixedFieldDeclaration.Attributes); - WriteModifiers (fixedFieldDeclaration.ModifierTokens); - WriteKeyword ("fixed"); - Space (); - fixedFieldDeclaration.ReturnType.AcceptVisitor (this, data); - Space (); - WriteCommaSeparatedList (fixedFieldDeclaration.Variables); - Semicolon (); - return EndNode (fixedFieldDeclaration); + StartNode(fixedFieldDeclaration); + WriteAttributes(fixedFieldDeclaration.Attributes); + WriteModifiers(fixedFieldDeclaration.ModifierTokens); + WriteKeyword(FixedFieldDeclaration.FixedKeywordRole); + Space(); + fixedFieldDeclaration.ReturnType.AcceptVisitor(this); + Space(); + WriteCommaSeparatedList(fixedFieldDeclaration.Variables); + Semicolon(); + EndNode(fixedFieldDeclaration); } - public object VisitFixedVariableInitializer (FixedVariableInitializer fixedVariableInitializer, object data) + public void VisitFixedVariableInitializer(FixedVariableInitializer fixedVariableInitializer) { - StartNode (fixedVariableInitializer); - WriteIdentifier (fixedVariableInitializer.Name); + StartNode(fixedVariableInitializer); + fixedVariableInitializer.NameToken.AcceptVisitor(this); if (!fixedVariableInitializer.CountExpression.IsNull) { - WriteToken ("[", AstNode.Roles.LBracket); - Space (policy.SpacesWithinBrackets); - fixedVariableInitializer.CountExpression.AcceptVisitor (this, data); - Space (policy.SpacesWithinBrackets); - WriteToken ("]", AstNode.Roles.RBracket); - } - return EndNode (fixedVariableInitializer); - } - - public object VisitIndexerDeclaration (IndexerDeclaration indexerDeclaration, object data) - { - StartNode (indexerDeclaration); - WriteAttributes (indexerDeclaration.Attributes); - WriteModifiers (indexerDeclaration.ModifierTokens); - indexerDeclaration.ReturnType.AcceptVisitor (this, data); - WritePrivateImplementationType (indexerDeclaration.PrivateImplementationType); - WriteKeyword ("this"); - Space (policy.SpaceBeforeMethodDeclarationParentheses); - WriteCommaSeparatedListInBrackets (indexerDeclaration.Parameters, policy.SpaceWithinMethodDeclarationParentheses); - OpenBrace (policy.PropertyBraceStyle); + WriteToken(Roles.LBracket); + Space(policy.SpacesWithinBrackets); + fixedVariableInitializer.CountExpression.AcceptVisitor(this); + Space(policy.SpacesWithinBrackets); + WriteToken(Roles.RBracket); + } + EndNode(fixedVariableInitializer); + } + + public void VisitIndexerDeclaration(IndexerDeclaration indexerDeclaration) + { + StartNode(indexerDeclaration); + WriteAttributes(indexerDeclaration.Attributes); + WriteModifiers(indexerDeclaration.ModifierTokens); + indexerDeclaration.ReturnType.AcceptVisitor(this); + WritePrivateImplementationType(indexerDeclaration.PrivateImplementationType); + WriteKeyword(IndexerDeclaration.ThisKeywordRole); + Space(policy.SpaceBeforeMethodDeclarationParentheses); + WriteCommaSeparatedListInBrackets(indexerDeclaration.Parameters, policy.SpaceWithinMethodDeclarationParentheses); + OpenBrace(policy.PropertyBraceStyle); // output get/set in their original order foreach (AstNode node in indexerDeclaration.Children) { if (node.Role == IndexerDeclaration.GetterRole || node.Role == IndexerDeclaration.SetterRole) { - node.AcceptVisitor (this, data); + node.AcceptVisitor(this); } } - CloseBrace (policy.PropertyBraceStyle); - NewLine (); - return EndNode (indexerDeclaration); + CloseBrace(policy.PropertyBraceStyle); + NewLine(); + EndNode(indexerDeclaration); } - public object VisitMethodDeclaration (MethodDeclaration methodDeclaration, object data) + public void VisitMethodDeclaration(MethodDeclaration methodDeclaration) { - StartNode (methodDeclaration); - WriteAttributes (methodDeclaration.Attributes); - WriteModifiers (methodDeclaration.ModifierTokens); - methodDeclaration.ReturnType.AcceptVisitor (this, data); - Space (); - WritePrivateImplementationType (methodDeclaration.PrivateImplementationType); - WriteIdentifier (methodDeclaration.Name); - WriteTypeParameters (methodDeclaration.TypeParameters); - Space (policy.SpaceBeforeMethodDeclarationParentheses); - WriteCommaSeparatedListInParenthesis (methodDeclaration.Parameters, policy.SpaceWithinMethodDeclarationParentheses); + StartNode(methodDeclaration); + WriteAttributes(methodDeclaration.Attributes); + WriteModifiers(methodDeclaration.ModifierTokens); + methodDeclaration.ReturnType.AcceptVisitor(this); + Space(); + WritePrivateImplementationType(methodDeclaration.PrivateImplementationType); + methodDeclaration.NameToken.AcceptVisitor(this); + WriteTypeParameters(methodDeclaration.TypeParameters); + Space(policy.SpaceBeforeMethodDeclarationParentheses); + WriteCommaSeparatedListInParenthesis(methodDeclaration.Parameters, policy.SpaceWithinMethodDeclarationParentheses); foreach (Constraint constraint in methodDeclaration.Constraints) { - constraint.AcceptVisitor (this, data); + constraint.AcceptVisitor(this); } - WriteMethodBody (methodDeclaration.Body); - return EndNode (methodDeclaration); + WriteMethodBody(methodDeclaration.Body); + EndNode(methodDeclaration); } - public object VisitOperatorDeclaration (OperatorDeclaration operatorDeclaration, object data) + public void VisitOperatorDeclaration(OperatorDeclaration operatorDeclaration) { - StartNode (operatorDeclaration); - WriteAttributes (operatorDeclaration.Attributes); - WriteModifiers (operatorDeclaration.ModifierTokens); + StartNode(operatorDeclaration); + WriteAttributes(operatorDeclaration.Attributes); + WriteModifiers(operatorDeclaration.ModifierTokens); if (operatorDeclaration.OperatorType == OperatorType.Explicit) { - WriteKeyword ("explicit", OperatorDeclaration.OperatorTypeRole); + WriteKeyword(OperatorDeclaration.ExplicitRole); } else if (operatorDeclaration.OperatorType == OperatorType.Implicit) { - WriteKeyword ("implicit", OperatorDeclaration.OperatorTypeRole); + WriteKeyword(OperatorDeclaration.ImplicitRole); } else { - operatorDeclaration.ReturnType.AcceptVisitor (this, data); + operatorDeclaration.ReturnType.AcceptVisitor(this); } - WriteKeyword ("operator", OperatorDeclaration.OperatorKeywordRole); - Space (); + WriteKeyword(OperatorDeclaration.OperatorKeywordRole); + Space(); if (operatorDeclaration.OperatorType == OperatorType.Explicit - || operatorDeclaration.OperatorType == OperatorType.Implicit) { - operatorDeclaration.ReturnType.AcceptVisitor (this, data); + || operatorDeclaration.OperatorType == OperatorType.Implicit) { + operatorDeclaration.ReturnType.AcceptVisitor(this); } else { - WriteToken (OperatorDeclaration.GetToken (operatorDeclaration.OperatorType), OperatorDeclaration.OperatorTypeRole); + WriteToken(OperatorDeclaration.GetToken(operatorDeclaration.OperatorType), OperatorDeclaration.GetRole(operatorDeclaration.OperatorType)); } - Space (policy.SpaceBeforeMethodDeclarationParentheses); - WriteCommaSeparatedListInParenthesis (operatorDeclaration.Parameters, policy.SpaceWithinMethodDeclarationParentheses); - WriteMethodBody (operatorDeclaration.Body); - return EndNode (operatorDeclaration); + Space(policy.SpaceBeforeMethodDeclarationParentheses); + WriteCommaSeparatedListInParenthesis(operatorDeclaration.Parameters, policy.SpaceWithinMethodDeclarationParentheses); + WriteMethodBody(operatorDeclaration.Body); + EndNode(operatorDeclaration); } - public object VisitParameterDeclaration (ParameterDeclaration parameterDeclaration, object data) + public void VisitParameterDeclaration(ParameterDeclaration parameterDeclaration) { - StartNode (parameterDeclaration); - WriteAttributes (parameterDeclaration.Attributes); + StartNode(parameterDeclaration); + WriteAttributes(parameterDeclaration.Attributes); switch (parameterDeclaration.ParameterModifier) { case ParameterModifier.Ref: - WriteKeyword ("ref", ParameterDeclaration.ModifierRole); + WriteKeyword(ParameterDeclaration.RefModifierRole); break; case ParameterModifier.Out: - WriteKeyword ("out", ParameterDeclaration.ModifierRole); + WriteKeyword(ParameterDeclaration.OutModifierRole); break; case ParameterModifier.Params: - WriteKeyword ("params", ParameterDeclaration.ModifierRole); + WriteKeyword(ParameterDeclaration.ParamsModifierRole); break; case ParameterModifier.This: - WriteKeyword ("this", ParameterDeclaration.ModifierRole); + WriteKeyword(ParameterDeclaration.ThisModifierRole); break; } - parameterDeclaration.Type.AcceptVisitor (this, data); - if (!parameterDeclaration.Type.IsNull && !string.IsNullOrEmpty (parameterDeclaration.Name)) - Space (); - if (!string.IsNullOrEmpty (parameterDeclaration.Name)) - WriteIdentifier (parameterDeclaration.Name); + parameterDeclaration.Type.AcceptVisitor(this); + if (!parameterDeclaration.Type.IsNull && !string.IsNullOrEmpty(parameterDeclaration.Name)) { + Space(); + } + if (!string.IsNullOrEmpty(parameterDeclaration.Name)) { + parameterDeclaration.NameToken.AcceptVisitor(this); + } if (!parameterDeclaration.DefaultExpression.IsNull) { - Space (policy.SpaceAroundAssignment); - WriteToken ("=", ParameterDeclaration.Roles.Assign); - Space (policy.SpaceAroundAssignment); - parameterDeclaration.DefaultExpression.AcceptVisitor (this, data); + Space(policy.SpaceAroundAssignment); + WriteToken(Roles.Assign); + Space(policy.SpaceAroundAssignment); + parameterDeclaration.DefaultExpression.AcceptVisitor(this); } - return EndNode (parameterDeclaration); + EndNode(parameterDeclaration); } - public object VisitPropertyDeclaration (PropertyDeclaration propertyDeclaration, object data) + public void VisitPropertyDeclaration(PropertyDeclaration propertyDeclaration) { - StartNode (propertyDeclaration); - WriteAttributes (propertyDeclaration.Attributes); - WriteModifiers (propertyDeclaration.ModifierTokens); - propertyDeclaration.ReturnType.AcceptVisitor (this, data); - Space (); - WritePrivateImplementationType (propertyDeclaration.PrivateImplementationType); - WriteIdentifier (propertyDeclaration.Name); - OpenBrace (policy.PropertyBraceStyle); + StartNode(propertyDeclaration); + WriteAttributes(propertyDeclaration.Attributes); + WriteModifiers(propertyDeclaration.ModifierTokens); + propertyDeclaration.ReturnType.AcceptVisitor(this); + Space(); + WritePrivateImplementationType(propertyDeclaration.PrivateImplementationType); + propertyDeclaration.NameToken.AcceptVisitor(this); + OpenBrace(policy.PropertyBraceStyle); // output get/set in their original order foreach (AstNode node in propertyDeclaration.Children) { if (node.Role == IndexerDeclaration.GetterRole || node.Role == IndexerDeclaration.SetterRole) { - node.AcceptVisitor (this, data); + node.AcceptVisitor(this); } } - CloseBrace (policy.PropertyBraceStyle); - NewLine (); - return EndNode (propertyDeclaration); + CloseBrace(policy.PropertyBraceStyle); + NewLine(); + EndNode(propertyDeclaration); } #endregion #region Other nodes - public object VisitVariableInitializer (VariableInitializer variableInitializer, object data) + public void VisitVariableInitializer(VariableInitializer variableInitializer) { - StartNode (variableInitializer); - WriteIdentifier (variableInitializer.Name); + StartNode(variableInitializer); + variableInitializer.NameToken.AcceptVisitor(this); if (!variableInitializer.Initializer.IsNull) { - Space (policy.SpaceAroundAssignment); - WriteToken ("=", VariableInitializer.Roles.Assign); - Space (policy.SpaceAroundAssignment); - variableInitializer.Initializer.AcceptVisitor (this, data); + Space(policy.SpaceAroundAssignment); + WriteToken(Roles.Assign); + Space(policy.SpaceAroundAssignment); + variableInitializer.Initializer.AcceptVisitor(this); } - return EndNode (variableInitializer); + EndNode(variableInitializer); } - public object VisitCompilationUnit (CompilationUnit compilationUnit, object data) + public void VisitCompilationUnit(CompilationUnit compilationUnit) { // don't do node tracking as we visit all children directly - foreach (AstNode node in compilationUnit.Children) - node.AcceptVisitor (this, data); - return null; + foreach (AstNode node in compilationUnit.Children) { + node.AcceptVisitor(this); + } } - public object VisitSimpleType (SimpleType simpleType, object data) + public void VisitSimpleType(SimpleType simpleType) { - StartNode (simpleType); - WriteIdentifier (simpleType.Identifier); - WriteTypeArguments (simpleType.TypeArguments); - return EndNode (simpleType); + StartNode(simpleType); + WriteIdentifier(simpleType.Identifier); + WriteTypeArguments(simpleType.TypeArguments); + EndNode(simpleType); } - public object VisitMemberType (MemberType memberType, object data) + public void VisitMemberType(MemberType memberType) { - StartNode (memberType); - memberType.Target.AcceptVisitor (this, data); - if (memberType.IsDoubleColon) - WriteToken ("::", MemberType.Roles.Dot); - else - WriteToken (".", MemberType.Roles.Dot); - WriteIdentifier (memberType.MemberName); - WriteTypeArguments (memberType.TypeArguments); - return EndNode (memberType); + StartNode(memberType); + memberType.Target.AcceptVisitor(this); + if (memberType.IsDoubleColon) { + WriteToken(Roles.DoubleColon); + } else { + WriteToken(Roles.Dot); + } + WriteIdentifier(memberType.MemberName); + WriteTypeArguments(memberType.TypeArguments); + EndNode(memberType); } - public object VisitComposedType (ComposedType composedType, object data) + public void VisitComposedType(ComposedType composedType) { - StartNode (composedType); - composedType.BaseType.AcceptVisitor (this, data); - if (composedType.HasNullableSpecifier) - WriteToken ("?", ComposedType.NullableRole); - for (int i = 0; i < composedType.PointerRank; i++) - WriteToken ("*", ComposedType.PointerRole); - foreach (var node in composedType.ArraySpecifiers) - node.AcceptVisitor (this, data); - return EndNode (composedType); + StartNode(composedType); + composedType.BaseType.AcceptVisitor(this); + if (composedType.HasNullableSpecifier) { + WriteToken(ComposedType.NullableRole); + } + for (int i = 0; i < composedType.PointerRank; i++) { + WriteToken(ComposedType.PointerRole); + } + foreach (var node in composedType.ArraySpecifiers) { + node.AcceptVisitor(this); + } + EndNode(composedType); } - public object VisitArraySpecifier (ArraySpecifier arraySpecifier, object data) + public void VisitArraySpecifier(ArraySpecifier arraySpecifier) { - StartNode (arraySpecifier); - WriteToken ("[", ArraySpecifier.Roles.LBracket); - foreach (var comma in arraySpecifier.GetChildrenByRole(ArraySpecifier.Roles.Comma)) { - WriteSpecialsUpToNode (comma); - formatter.WriteToken (","); + StartNode(arraySpecifier); + WriteToken(Roles.LBracket); + foreach (var comma in arraySpecifier.GetChildrenByRole(Roles.Comma)) { + WriteSpecialsUpToNode(comma); + formatter.WriteToken(","); lastWritten = LastWritten.Other; } - WriteToken ("]", ArraySpecifier.Roles.RBracket); - return EndNode (arraySpecifier); + WriteToken(Roles.RBracket); + EndNode(arraySpecifier); } - public object VisitPrimitiveType (PrimitiveType primitiveType, object data) + public void VisitPrimitiveType(PrimitiveType primitiveType) { - StartNode (primitiveType); - WriteKeyword (primitiveType.Keyword); + StartNode(primitiveType); + WriteKeyword(primitiveType.Keyword); if (primitiveType.Keyword == "new") { // new() constraint - LPar (); - RPar (); + LPar(); + RPar(); } - return EndNode (primitiveType); + EndNode(primitiveType); } - public object VisitComment (Comment comment, object data) + public void VisitComment(Comment comment) { if (lastWritten == LastWritten.Division) { // When there's a comment starting after a division operator // "1.0 / /*comment*/a", then we need to insert a space in front of the comment. - formatter.Space (); + formatter.Space(); } formatter.StartNode(comment); - formatter.WriteComment (comment.CommentType, comment.Content); + formatter.WriteComment(comment.CommentType, comment.Content); formatter.EndNode(comment); lastWritten = LastWritten.Whitespace; - return null; } - - public object VisitPreProcessorDirective (PreProcessorDirective preProcessorDirective, object data) + + public void VisitNewLine(NewLineNode newLineNode) + { + formatter.StartNode(newLineNode); + formatter.NewLine(); + formatter.EndNode(newLineNode); + } + + public void VisitWhitespace(WhitespaceNode whitespaceNode) + { + // unused + } + + public void VisitText(TextNode textNode) + { + // unused + } + + public void VisitPreProcessorDirective(PreProcessorDirective preProcessorDirective) { - formatter.StartNode (preProcessorDirective); + formatter.StartNode(preProcessorDirective); formatter.WritePreProcessorDirective(preProcessorDirective.Type, preProcessorDirective.Argument); - formatter.EndNode (preProcessorDirective); + formatter.EndNode(preProcessorDirective); lastWritten = LastWritten.Whitespace; - return null; } - public object VisitTypeParameterDeclaration (TypeParameterDeclaration typeParameterDeclaration, object data) + public void VisitTypeParameterDeclaration(TypeParameterDeclaration typeParameterDeclaration) { - StartNode (typeParameterDeclaration); - WriteAttributes (typeParameterDeclaration.Attributes); + StartNode(typeParameterDeclaration); + WriteAttributes(typeParameterDeclaration.Attributes); switch (typeParameterDeclaration.Variance) { case VarianceModifier.Invariant: break; case VarianceModifier.Covariant: - WriteKeyword ("out"); + WriteKeyword(TypeParameterDeclaration.OutVarianceKeywordRole); break; case VarianceModifier.Contravariant: - WriteKeyword ("in"); + WriteKeyword(TypeParameterDeclaration.InVarianceKeywordRole); break; default: throw new NotSupportedException ("Invalid value for VarianceModifier"); } - WriteIdentifier (typeParameterDeclaration.Name); - return EndNode (typeParameterDeclaration); + typeParameterDeclaration.NameToken.AcceptVisitor(this); + EndNode(typeParameterDeclaration); } - public object VisitConstraint (Constraint constraint, object data) + public void VisitConstraint(Constraint constraint) { - StartNode (constraint); - Space (); - WriteKeyword ("where"); - WriteIdentifier (constraint.TypeParameter.Identifier); - Space (); - WriteToken (":", Constraint.ColonRole); - Space (); - WriteCommaSeparatedList (constraint.BaseTypes); - return EndNode (constraint); + StartNode(constraint); + Space(); + WriteKeyword(Roles.WhereKeyword); + WriteIdentifier(constraint.TypeParameter.Identifier); + Space(); + WriteToken(Roles.Colon); + Space(); + WriteCommaSeparatedList(constraint.BaseTypes); + EndNode(constraint); } - public object VisitCSharpTokenNode (CSharpTokenNode cSharpTokenNode, object data) + public void VisitCSharpTokenNode(CSharpTokenNode cSharpTokenNode) { CSharpModifierToken mod = cSharpTokenNode as CSharpModifierToken; if (mod != null) { - StartNode (mod); - WriteKeyword (CSharpModifierToken.GetModifierName (mod.Modifier)); - return EndNode (mod); + StartNode(mod); + WriteKeyword(CSharpModifierToken.GetModifierName(mod.Modifier)); + EndNode(mod); } else { throw new NotSupportedException ("Should never visit individual tokens"); } } - public object VisitIdentifier (Identifier identifier, object data) + public void VisitIdentifier(Identifier identifier) { - StartNode (identifier); - WriteIdentifier (identifier.Name); - return EndNode (identifier); + StartNode(identifier); + WriteIdentifier(identifier.Name); + EndNode(identifier); } #endregion #region Pattern Nodes - public object VisitPatternPlaceholder (AstNode placeholder, PatternMatching.Pattern pattern, object data) + public void VisitPatternPlaceholder(AstNode placeholder, PatternMatching.Pattern pattern) { - StartNode (placeholder); - VisitNodeInPattern(pattern, data); - return EndNode (placeholder); + StartNode(placeholder); + VisitNodeInPattern(pattern); + EndNode(placeholder); } - void VisitAnyNode (AnyNode anyNode, object data) + void VisitAnyNode(AnyNode anyNode) { - if (!string.IsNullOrEmpty (anyNode.GroupName)) { - WriteIdentifier (anyNode.GroupName); - WriteToken (":", AstNode.Roles.Colon); + if (!string.IsNullOrEmpty(anyNode.GroupName)) { + WriteIdentifier(anyNode.GroupName); + WriteToken(Roles.Colon); } } - void VisitBackreference (Backreference backreference, object data) + void VisitBackreference(Backreference backreference) { - WriteKeyword ("backreference"); - LPar (); - WriteIdentifier (backreference.ReferencedGroupName); - RPar (); + WriteKeyword("backreference"); + LPar(); + WriteIdentifier(backreference.ReferencedGroupName); + RPar(); } - void VisitIdentifierExpressionBackreference (IdentifierExpressionBackreference identifierExpressionBackreference, object data) + void VisitIdentifierExpressionBackreference(IdentifierExpressionBackreference identifierExpressionBackreference) { - WriteKeyword ("identifierBackreference"); - LPar (); - WriteIdentifier (identifierExpressionBackreference.ReferencedGroupName); - RPar (); + WriteKeyword("identifierBackreference"); + LPar(); + WriteIdentifier(identifierExpressionBackreference.ReferencedGroupName); + RPar(); } - void VisitChoice (Choice choice, object data) + void VisitChoice(Choice choice) { - WriteKeyword ("choice"); - Space (); - LPar (); - NewLine (); - formatter.Indent (); + WriteKeyword("choice"); + Space(); + LPar(); + NewLine(); + formatter.Indent(); foreach (INode alternative in choice) { - VisitNodeInPattern (alternative, data); - if (alternative != choice.Last ()) - WriteToken (",", AstNode.Roles.Comma); - NewLine (); + VisitNodeInPattern(alternative); + if (alternative != choice.Last()) { + WriteToken(Roles.Comma); + } + NewLine(); } - formatter.Unindent (); - RPar (); + formatter.Unindent(); + RPar(); } - void VisitNamedNode (NamedNode namedNode, object data) + void VisitNamedNode(NamedNode namedNode) { - if (!string.IsNullOrEmpty (namedNode.GroupName)) { - WriteIdentifier (namedNode.GroupName); - WriteToken (":", AstNode.Roles.Colon); + if (!string.IsNullOrEmpty(namedNode.GroupName)) { + WriteIdentifier(namedNode.GroupName); + WriteToken(Roles.Colon); } - VisitNodeInPattern (namedNode.ChildNode, data); + VisitNodeInPattern(namedNode.ChildNode); } - void VisitRepeat (Repeat repeat, object data) + void VisitRepeat(Repeat repeat) { - WriteKeyword ("repeat"); - LPar (); + WriteKeyword("repeat"); + LPar(); if (repeat.MinCount != 0 || repeat.MaxCount != int.MaxValue) { - WriteIdentifier (repeat.MinCount.ToString ()); - WriteToken (",", AstNode.Roles.Comma); - WriteIdentifier (repeat.MaxCount.ToString ()); - WriteToken (",", AstNode.Roles.Comma); + WriteIdentifier(repeat.MinCount.ToString()); + WriteToken(Roles.Comma); + WriteIdentifier(repeat.MaxCount.ToString()); + WriteToken(Roles.Comma); } - VisitNodeInPattern (repeat.ChildNode, data); - RPar (); + VisitNodeInPattern(repeat.ChildNode); + RPar(); } - void VisitOptionalNode (OptionalNode optionalNode, object data) + void VisitOptionalNode(OptionalNode optionalNode) { - WriteKeyword ("optional"); - LPar (); - VisitNodeInPattern (optionalNode.ChildNode, data); - RPar (); + WriteKeyword("optional"); + LPar(); + VisitNodeInPattern(optionalNode.ChildNode); + RPar(); } - void VisitNodeInPattern (INode childNode, object data) + void VisitNodeInPattern(INode childNode) { if (childNode is AstNode) { - ((AstNode)childNode).AcceptVisitor(this, data); + ((AstNode)childNode).AcceptVisitor(this); } else if (childNode is IdentifierExpressionBackreference) { - VisitIdentifierExpressionBackreference((IdentifierExpressionBackreference)childNode, data); + VisitIdentifierExpressionBackreference((IdentifierExpressionBackreference)childNode); } else if (childNode is Choice) { - VisitChoice((Choice)childNode, data); + VisitChoice((Choice)childNode); } else if (childNode is AnyNode) { - VisitAnyNode((AnyNode)childNode, data); + VisitAnyNode((AnyNode)childNode); } else if (childNode is Backreference) { - VisitBackreference((Backreference)childNode, data); + VisitBackreference((Backreference)childNode); } else if (childNode is NamedNode) { - VisitNamedNode((NamedNode)childNode, data); + VisitNamedNode((NamedNode)childNode); } else if (childNode is OptionalNode) { - VisitOptionalNode((OptionalNode)childNode, data); + VisitOptionalNode((OptionalNode)childNode); } else if (childNode is Repeat) { - VisitRepeat((Repeat)childNode, data); + VisitRepeat((Repeat)childNode); } else { WritePrimitiveValue(childNode); } } #endregion + + #region Documentation Reference + public void VisitDocumentationReference(DocumentationReference documentationReference) + { + StartNode(documentationReference); + if (!documentationReference.DeclaringType.IsNull) { + documentationReference.DeclaringType.AcceptVisitor(this); + if (documentationReference.EntityType != EntityType.TypeDefinition) { + WriteToken(Roles.Dot); + } + } + switch (documentationReference.EntityType) { + case EntityType.TypeDefinition: + // we already printed the DeclaringType + break; + case EntityType.Indexer: + WriteKeyword(IndexerDeclaration.ThisKeywordRole); + break; + case EntityType.Operator: + var opType = documentationReference.OperatorType; + if (opType == OperatorType.Explicit) { + WriteKeyword(OperatorDeclaration.ExplicitRole); + } else if (opType == OperatorType.Implicit) { + WriteKeyword(OperatorDeclaration.ImplicitRole); + } + WriteKeyword(OperatorDeclaration.OperatorKeywordRole); + Space(); + if (opType == OperatorType.Explicit || opType == OperatorType.Implicit) { + documentationReference.ConversionOperatorReturnType.AcceptVisitor(this); + } else { + WriteToken(OperatorDeclaration.GetToken(opType), OperatorDeclaration.GetRole(opType)); + } + break; + default: + WriteIdentifier(documentationReference.MemberName); + break; + } + WriteTypeArguments(documentationReference.TypeArguments); + if (documentationReference.HasParameterList) { + Space(policy.SpaceBeforeMethodDeclarationParentheses); + if (documentationReference.EntityType == EntityType.Indexer) { + WriteCommaSeparatedListInBrackets(documentationReference.Parameters, policy.SpaceWithinMethodDeclarationParentheses); + } else { + WriteCommaSeparatedListInParenthesis(documentationReference.Parameters, policy.SpaceWithinMethodDeclarationParentheses); + } + } + EndNode(documentationReference); + } + #endregion } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/CodeDomConvertVisitor.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/CodeDomConvertVisitor.cs index d5f85f247e..6b55c1490e 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/CodeDomConvertVisitor.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/CodeDomConvertVisitor.cs @@ -1,4 +1,4 @@ -// Copyright (c) AlphaSierraPapa for the SharpDevelop Team +// Copyright (c) AlphaSierraPapa for the SharpDevelop Team // // Permission is hereby granted, free of charge, to any person obtaining a copy of this // software and associated documentation files (the "Software"), to deal in the Software @@ -36,7 +36,7 @@ namespace ICSharpCode.NRefactory.CSharp /// /// The conversion is intended for use in the SharpDevelop forms designer. /// - public class CodeDomConvertVisitor : IAstVisitor + public class CodeDomConvertVisitor : IAstVisitor { //ICompilation compilation = MinimalResolveContext.Instance; CSharpAstResolver resolver; @@ -171,7 +171,7 @@ namespace ICSharpCode.NRefactory.CSharp string MakeSnippet(AstNode node) { StringWriter w = new StringWriter(); - CSharpOutputVisitor v = new CSharpOutputVisitor(w, new CSharpFormattingOptions()); + CSharpOutputVisitor v = new CSharpOutputVisitor(w, FormattingOptionsFactory.CreateMono ()); node.AcceptVisitor(v); return w.ToString(); } @@ -190,17 +190,17 @@ namespace ICSharpCode.NRefactory.CSharp return new CodeSnippetStatement(MakeSnippet(stmt)); } - CodeObject IAstVisitor.VisitAnonymousMethodExpression(AnonymousMethodExpression anonymousMethodExpression, object data) + CodeObject IAstVisitor.VisitAnonymousMethodExpression(AnonymousMethodExpression anonymousMethodExpression) { return MakeSnippetExpression(anonymousMethodExpression); } - CodeObject IAstVisitor.VisitUndocumentedExpression(UndocumentedExpression undocumentedExpression, object data) + CodeObject IAstVisitor.VisitUndocumentedExpression(UndocumentedExpression undocumentedExpression) { return MakeSnippetExpression(undocumentedExpression); } - CodeObject IAstVisitor.VisitArrayCreateExpression(ArrayCreateExpression arrayCreateExpression, object data) + CodeObject IAstVisitor.VisitArrayCreateExpression(ArrayCreateExpression arrayCreateExpression) { CodeArrayCreateExpression ace = new CodeArrayCreateExpression(); int dimensions = arrayCreateExpression.Arguments.Count; @@ -223,29 +223,29 @@ namespace ICSharpCode.NRefactory.CSharp return ace; } - CodeObject IAstVisitor.VisitArrayInitializerExpression(ArrayInitializerExpression arrayInitializerExpression, object data) + CodeObject IAstVisitor.VisitArrayInitializerExpression(ArrayInitializerExpression arrayInitializerExpression) { // Array initializers should be handled by the parent node return MakeSnippetExpression(arrayInitializerExpression); } - CodeObject IAstVisitor.VisitAsExpression(AsExpression asExpression, object data) + CodeObject IAstVisitor.VisitAsExpression(AsExpression asExpression) { return MakeSnippetExpression(asExpression); } - CodeObject IAstVisitor.VisitAssignmentExpression(AssignmentExpression assignmentExpression, object data) + CodeObject IAstVisitor.VisitAssignmentExpression(AssignmentExpression assignmentExpression) { // assignments are only supported as statements, not as expressions return MakeSnippetExpression(assignmentExpression); } - CodeObject IAstVisitor.VisitBaseReferenceExpression(BaseReferenceExpression baseReferenceExpression, object data) + CodeObject IAstVisitor.VisitBaseReferenceExpression(BaseReferenceExpression baseReferenceExpression) { return new CodeBaseReferenceExpression(); } - CodeObject IAstVisitor.VisitBinaryOperatorExpression(BinaryOperatorExpression binaryOperatorExpression, object data) + CodeObject IAstVisitor.VisitBinaryOperatorExpression(BinaryOperatorExpression binaryOperatorExpression) { CodeBinaryOperatorType op; switch (binaryOperatorExpression.Operator) { @@ -322,27 +322,27 @@ namespace ICSharpCode.NRefactory.CSharp return new CodeBinaryOperatorExpression(Convert(binaryOperatorExpression.Left), op, Convert(binaryOperatorExpression.Right)); } - CodeObject IAstVisitor.VisitCastExpression(CastExpression castExpression, object data) + CodeObject IAstVisitor.VisitCastExpression(CastExpression castExpression) { return new CodeCastExpression(Convert(castExpression.Type), Convert(castExpression.Expression)); } - CodeObject IAstVisitor.VisitCheckedExpression(CheckedExpression checkedExpression, object data) + CodeObject IAstVisitor.VisitCheckedExpression(CheckedExpression checkedExpression) { return MakeSnippetExpression(checkedExpression); } - CodeObject IAstVisitor.VisitConditionalExpression(ConditionalExpression conditionalExpression, object data) + CodeObject IAstVisitor.VisitConditionalExpression(ConditionalExpression conditionalExpression) { return MakeSnippetExpression(conditionalExpression); } - CodeObject IAstVisitor.VisitDefaultValueExpression(DefaultValueExpression defaultValueExpression, object data) + CodeObject IAstVisitor.VisitDefaultValueExpression(DefaultValueExpression defaultValueExpression) { return new CodeDefaultValueExpression(Convert(defaultValueExpression.Type)); } - CodeObject IAstVisitor.VisitDirectionExpression(DirectionExpression directionExpression, object data) + CodeObject IAstVisitor.VisitDirectionExpression(DirectionExpression directionExpression) { System.CodeDom.FieldDirection direction; if (directionExpression.FieldDirection == FieldDirection.Out) { @@ -353,7 +353,7 @@ namespace ICSharpCode.NRefactory.CSharp return new CodeDirectionExpression(direction, Convert(directionExpression.Expression)); } - CodeObject IAstVisitor.VisitIdentifierExpression(IdentifierExpression identifierExpression, object data) + CodeObject IAstVisitor.VisitIdentifierExpression(IdentifierExpression identifierExpression) { ResolveResult rr = Resolve(identifierExpression); LocalResolveResult lrr = rr as LocalResolveResult; @@ -386,7 +386,7 @@ namespace ICSharpCode.NRefactory.CSharp return new CodeVariableReferenceExpression(identifierExpression.Identifier); } - CodeObject IAstVisitor.VisitIndexerExpression(IndexerExpression indexerExpression, object data) + CodeObject IAstVisitor.VisitIndexerExpression(IndexerExpression indexerExpression) { if (Resolve(indexerExpression) is ArrayAccessResolveResult) return new CodeArrayIndexerExpression(Convert(indexerExpression.Target), Convert(indexerExpression.Arguments)); @@ -394,7 +394,7 @@ namespace ICSharpCode.NRefactory.CSharp return new CodeIndexerExpression(Convert(indexerExpression.Target), Convert(indexerExpression.Arguments)); } - CodeObject IAstVisitor.VisitInvocationExpression(InvocationExpression invocationExpression, object data) + CodeObject IAstVisitor.VisitInvocationExpression(InvocationExpression invocationExpression) { MemberResolveResult rr = Resolve(invocationExpression) as MemberResolveResult; CSharpInvocationResolveResult csRR = rr as CSharpInvocationResolveResult; @@ -426,17 +426,17 @@ namespace ICSharpCode.NRefactory.CSharp return MakeSnippetExpression(invocationExpression); } - CodeObject IAstVisitor.VisitIsExpression(IsExpression isExpression, object data) + CodeObject IAstVisitor.VisitIsExpression(IsExpression isExpression) { return MakeSnippetExpression(isExpression); } - CodeObject IAstVisitor.VisitLambdaExpression(LambdaExpression lambdaExpression, object data) + CodeObject IAstVisitor.VisitLambdaExpression(LambdaExpression lambdaExpression) { return MakeSnippetExpression(lambdaExpression); } - CodeObject IAstVisitor.VisitMemberReferenceExpression(MemberReferenceExpression memberReferenceExpression, object data) + CodeObject IAstVisitor.VisitMemberReferenceExpression(MemberReferenceExpression memberReferenceExpression) { CodeExpression target = Convert(memberReferenceExpression.Target); ResolveResult rr = Resolve(memberReferenceExpression); @@ -471,75 +471,75 @@ namespace ICSharpCode.NRefactory.CSharp } } - CodeObject IAstVisitor.VisitNamedArgumentExpression(NamedArgumentExpression namedArgumentExpression, object data) + CodeObject IAstVisitor.VisitNamedArgumentExpression(NamedArgumentExpression namedArgumentExpression) { return MakeSnippetExpression(namedArgumentExpression); } - CodeObject IAstVisitor.VisitNamedExpression(NamedExpression namedExpression, object data) + CodeObject IAstVisitor.VisitNamedExpression(NamedExpression namedExpression) { return MakeSnippetExpression(namedExpression); } - CodeObject IAstVisitor.VisitNullReferenceExpression(NullReferenceExpression nullReferenceExpression, object data) + CodeObject IAstVisitor.VisitNullReferenceExpression(NullReferenceExpression nullReferenceExpression) { return new CodePrimitiveExpression(null); } - CodeObject IAstVisitor.VisitObjectCreateExpression(ObjectCreateExpression objectCreateExpression, object data) + CodeObject IAstVisitor.VisitObjectCreateExpression(ObjectCreateExpression objectCreateExpression) { if (!objectCreateExpression.Initializer.IsNull) return MakeSnippetExpression(objectCreateExpression); return new CodeObjectCreateExpression(Convert(objectCreateExpression.Type), Convert(objectCreateExpression.Arguments)); } - CodeObject IAstVisitor.VisitAnonymousTypeCreateExpression(AnonymousTypeCreateExpression anonymousTypeCreateExpression, object data) + CodeObject IAstVisitor.VisitAnonymousTypeCreateExpression(AnonymousTypeCreateExpression anonymousTypeCreateExpression) { return MakeSnippetExpression(anonymousTypeCreateExpression); } - CodeObject IAstVisitor.VisitParenthesizedExpression(ParenthesizedExpression parenthesizedExpression, object data) + CodeObject IAstVisitor.VisitParenthesizedExpression(ParenthesizedExpression parenthesizedExpression) { // CodeDom generators will insert parentheses where necessary return Convert(parenthesizedExpression.Expression); } - CodeObject IAstVisitor.VisitPointerReferenceExpression(PointerReferenceExpression pointerReferenceExpression, object data) + CodeObject IAstVisitor.VisitPointerReferenceExpression(PointerReferenceExpression pointerReferenceExpression) { return MakeSnippetExpression(pointerReferenceExpression); } - CodeObject IAstVisitor.VisitPrimitiveExpression(PrimitiveExpression primitiveExpression, object data) + CodeObject IAstVisitor.VisitPrimitiveExpression(PrimitiveExpression primitiveExpression) { return new CodePrimitiveExpression(primitiveExpression.Value); } - CodeObject IAstVisitor.VisitSizeOfExpression(SizeOfExpression sizeOfExpression, object data) + CodeObject IAstVisitor.VisitSizeOfExpression(SizeOfExpression sizeOfExpression) { return MakeSnippetExpression(sizeOfExpression); } - CodeObject IAstVisitor.VisitStackAllocExpression(StackAllocExpression stackAllocExpression, object data) + CodeObject IAstVisitor.VisitStackAllocExpression(StackAllocExpression stackAllocExpression) { return MakeSnippetExpression(stackAllocExpression); } - CodeObject IAstVisitor.VisitThisReferenceExpression(ThisReferenceExpression thisReferenceExpression, object data) + CodeObject IAstVisitor.VisitThisReferenceExpression(ThisReferenceExpression thisReferenceExpression) { return new CodeThisReferenceExpression(); } - CodeObject IAstVisitor.VisitTypeOfExpression(TypeOfExpression typeOfExpression, object data) + CodeObject IAstVisitor.VisitTypeOfExpression(TypeOfExpression typeOfExpression) { return new CodeTypeOfExpression(Convert(typeOfExpression.Type)); } - CodeObject IAstVisitor.VisitTypeReferenceExpression(TypeReferenceExpression typeReferenceExpression, object data) + CodeObject IAstVisitor.VisitTypeReferenceExpression(TypeReferenceExpression typeReferenceExpression) { return new CodeTypeReferenceExpression(Convert(typeReferenceExpression.Type)); } - CodeObject IAstVisitor.VisitUnaryOperatorExpression(UnaryOperatorExpression unaryOperatorExpression, object data) + CodeObject IAstVisitor.VisitUnaryOperatorExpression(UnaryOperatorExpression unaryOperatorExpression) { switch (unaryOperatorExpression.Operator) { case UnaryOperatorType.Not: @@ -559,72 +559,72 @@ namespace ICSharpCode.NRefactory.CSharp } } - CodeObject IAstVisitor.VisitUncheckedExpression(UncheckedExpression uncheckedExpression, object data) + CodeObject IAstVisitor.VisitUncheckedExpression(UncheckedExpression uncheckedExpression) { return MakeSnippetExpression(uncheckedExpression); } - CodeObject IAstVisitor.VisitEmptyExpression(EmptyExpression emptyExpression, object data) + CodeObject IAstVisitor.VisitEmptyExpression(EmptyExpression emptyExpression) { return null; } - CodeObject IAstVisitor.VisitQueryExpression(QueryExpression queryExpression, object data) + CodeObject IAstVisitor.VisitQueryExpression(QueryExpression queryExpression) { return MakeSnippetExpression(queryExpression); } - CodeObject IAstVisitor.VisitQueryContinuationClause(QueryContinuationClause queryContinuationClause, object data) + CodeObject IAstVisitor.VisitQueryContinuationClause(QueryContinuationClause queryContinuationClause) { throw new NotSupportedException(); } - CodeObject IAstVisitor.VisitQueryFromClause(QueryFromClause queryFromClause, object data) + CodeObject IAstVisitor.VisitQueryFromClause(QueryFromClause queryFromClause) { throw new NotSupportedException(); } - CodeObject IAstVisitor.VisitQueryLetClause(QueryLetClause queryLetClause, object data) + CodeObject IAstVisitor.VisitQueryLetClause(QueryLetClause queryLetClause) { throw new NotSupportedException(); } - CodeObject IAstVisitor.VisitQueryWhereClause(QueryWhereClause queryWhereClause, object data) + CodeObject IAstVisitor.VisitQueryWhereClause(QueryWhereClause queryWhereClause) { throw new NotSupportedException(); } - CodeObject IAstVisitor.VisitQueryJoinClause(QueryJoinClause queryJoinClause, object data) + CodeObject IAstVisitor.VisitQueryJoinClause(QueryJoinClause queryJoinClause) { throw new NotSupportedException(); } - CodeObject IAstVisitor.VisitQueryOrderClause(QueryOrderClause queryOrderClause, object data) + CodeObject IAstVisitor.VisitQueryOrderClause(QueryOrderClause queryOrderClause) { throw new NotSupportedException(); } - CodeObject IAstVisitor.VisitQueryOrdering(QueryOrdering queryOrdering, object data) + CodeObject IAstVisitor.VisitQueryOrdering(QueryOrdering queryOrdering) { throw new NotSupportedException(); } - CodeObject IAstVisitor.VisitQuerySelectClause(QuerySelectClause querySelectClause, object data) + CodeObject IAstVisitor.VisitQuerySelectClause(QuerySelectClause querySelectClause) { throw new NotSupportedException(); } - CodeObject IAstVisitor.VisitQueryGroupClause(QueryGroupClause queryGroupClause, object data) + CodeObject IAstVisitor.VisitQueryGroupClause(QueryGroupClause queryGroupClause) { throw new NotSupportedException(); } - CodeObject IAstVisitor.VisitAttribute(Attribute attribute, object data) + CodeObject IAstVisitor.VisitAttribute(Attribute attribute) { throw new NotSupportedException(); } - CodeObject IAstVisitor.VisitAttributeSection(AttributeSection attributeSection, object data) + CodeObject IAstVisitor.VisitAttributeSection(AttributeSection attributeSection) { throw new NotSupportedException(); } @@ -655,7 +655,7 @@ namespace ICSharpCode.NRefactory.CSharp return result.ToArray(); } - CodeObject IAstVisitor.VisitDelegateDeclaration(DelegateDeclaration delegateDeclaration, object data) + CodeObject IAstVisitor.VisitDelegateDeclaration(DelegateDeclaration delegateDeclaration) { CodeTypeDelegate d = new CodeTypeDelegate(delegateDeclaration.Name); d.Attributes = ConvertMemberAttributes(delegateDeclaration.Modifiers); @@ -696,7 +696,7 @@ namespace ICSharpCode.NRefactory.CSharp return a; } - CodeObject IAstVisitor.VisitNamespaceDeclaration(NamespaceDeclaration namespaceDeclaration, object data) + CodeObject IAstVisitor.VisitNamespaceDeclaration(NamespaceDeclaration namespaceDeclaration) { CodeNamespace ns = new CodeNamespace(namespaceDeclaration.Name); foreach (AstNode node in namespaceDeclaration.Members) { @@ -715,9 +715,9 @@ namespace ICSharpCode.NRefactory.CSharp Stack typeStack = new Stack(); - CodeObject IAstVisitor.VisitTypeDeclaration(TypeDeclaration typeDeclaration, object data) + CodeObject IAstVisitor.VisitTypeDeclaration(TypeDeclaration typeDeclaration) { - bool isNestedType = typeStack.Count > 0; + //bool isNestedType = typeStack.Count > 0; CodeTypeDeclaration typeDecl = new CodeTypeDeclaration(typeDeclaration.Name); typeDecl.Attributes = ConvertMemberAttributes(typeDeclaration.Modifiers); typeDecl.CustomAttributes.AddRange(Convert(typeDeclaration.Attributes)); @@ -757,42 +757,42 @@ namespace ICSharpCode.NRefactory.CSharp typeStack.Peek().Members.Add(member); } - CodeObject IAstVisitor.VisitUsingAliasDeclaration(UsingAliasDeclaration usingAliasDeclaration, object data) + CodeObject IAstVisitor.VisitUsingAliasDeclaration(UsingAliasDeclaration usingAliasDeclaration) { return new CodeSnippetTypeMember(MakeSnippet(usingAliasDeclaration)); } - CodeObject IAstVisitor.VisitUsingDeclaration(UsingDeclaration usingDeclaration, object data) + CodeObject IAstVisitor.VisitUsingDeclaration(UsingDeclaration usingDeclaration) { return new CodeNamespaceImport(usingDeclaration.Namespace); } - CodeObject IAstVisitor.VisitExternAliasDeclaration(ExternAliasDeclaration externAliasDeclaration, object data) + CodeObject IAstVisitor.VisitExternAliasDeclaration(ExternAliasDeclaration externAliasDeclaration) { return new CodeSnippetTypeMember(MakeSnippet(externAliasDeclaration)); } - CodeObject IAstVisitor.VisitBlockStatement(BlockStatement blockStatement, object data) + CodeObject IAstVisitor.VisitBlockStatement(BlockStatement blockStatement) { return new CodeConditionStatement(new CodePrimitiveExpression(true), ConvertBlock(blockStatement)); } - CodeObject IAstVisitor.VisitBreakStatement(BreakStatement breakStatement, object data) + CodeObject IAstVisitor.VisitBreakStatement(BreakStatement breakStatement) { return MakeSnippetStatement(breakStatement); } - CodeObject IAstVisitor.VisitCheckedStatement(CheckedStatement checkedStatement, object data) + CodeObject IAstVisitor.VisitCheckedStatement(CheckedStatement checkedStatement) { return MakeSnippetStatement(checkedStatement); } - CodeObject IAstVisitor.VisitContinueStatement(ContinueStatement continueStatement, object data) + CodeObject IAstVisitor.VisitContinueStatement(ContinueStatement continueStatement) { return MakeSnippetStatement(continueStatement); } - CodeObject IAstVisitor.VisitDoWhileStatement(DoWhileStatement doWhileStatement, object data) + CodeObject IAstVisitor.VisitDoWhileStatement(DoWhileStatement doWhileStatement) { // do { } while (expr); // @@ -807,12 +807,12 @@ namespace ICSharpCode.NRefactory.CSharp ); } - CodeObject IAstVisitor.VisitEmptyStatement(EmptyStatement emptyStatement, object data) + CodeObject IAstVisitor.VisitEmptyStatement(EmptyStatement emptyStatement) { return null; } - CodeObject IAstVisitor.VisitExpressionStatement(ExpressionStatement expressionStatement, object data) + CodeObject IAstVisitor.VisitExpressionStatement(ExpressionStatement expressionStatement) { AssignmentExpression assignment = expressionStatement.Expression as AssignmentExpression; if (assignment != null && assignment.Operator == AssignmentOperatorType.Assign) { @@ -821,17 +821,17 @@ namespace ICSharpCode.NRefactory.CSharp return new CodeExpressionStatement(Convert(expressionStatement.Expression)); } - CodeObject IAstVisitor.VisitFixedStatement(FixedStatement fixedStatement, object data) + CodeObject IAstVisitor.VisitFixedStatement(FixedStatement fixedStatement) { return MakeSnippetStatement(fixedStatement); } - CodeObject IAstVisitor.VisitForeachStatement(ForeachStatement foreachStatement, object data) + CodeObject IAstVisitor.VisitForeachStatement(ForeachStatement foreachStatement) { return MakeSnippetStatement(foreachStatement); } - CodeObject IAstVisitor.VisitForStatement(ForStatement forStatement, object data) + CodeObject IAstVisitor.VisitForStatement(ForStatement forStatement) { if (forStatement.Initializers.Count != 1 || forStatement.Iterators.Count != 1) return MakeSnippetStatement(forStatement); @@ -843,22 +843,22 @@ namespace ICSharpCode.NRefactory.CSharp ); } - CodeObject IAstVisitor.VisitGotoCaseStatement(GotoCaseStatement gotoCaseStatement, object data) + CodeObject IAstVisitor.VisitGotoCaseStatement(GotoCaseStatement gotoCaseStatement) { return MakeSnippetStatement(gotoCaseStatement); } - CodeObject IAstVisitor.VisitGotoDefaultStatement(GotoDefaultStatement gotoDefaultStatement, object data) + CodeObject IAstVisitor.VisitGotoDefaultStatement(GotoDefaultStatement gotoDefaultStatement) { return MakeSnippetStatement(gotoDefaultStatement); } - CodeObject IAstVisitor.VisitGotoStatement(GotoStatement gotoStatement, object data) + CodeObject IAstVisitor.VisitGotoStatement(GotoStatement gotoStatement) { return new CodeGotoStatement(gotoStatement.Label); } - CodeObject IAstVisitor.VisitIfElseStatement(IfElseStatement ifElseStatement, object data) + CodeObject IAstVisitor.VisitIfElseStatement(IfElseStatement ifElseStatement) { return new CodeConditionStatement( Convert(ifElseStatement.Condition), @@ -866,42 +866,42 @@ namespace ICSharpCode.NRefactory.CSharp ConvertEmbeddedStatement(ifElseStatement.FalseStatement)); } - CodeObject IAstVisitor.VisitLabelStatement(LabelStatement labelStatement, object data) + CodeObject IAstVisitor.VisitLabelStatement(LabelStatement labelStatement) { return new CodeLabeledStatement(labelStatement.Label); } - CodeObject IAstVisitor.VisitLockStatement(LockStatement lockStatement, object data) + CodeObject IAstVisitor.VisitLockStatement(LockStatement lockStatement) { return MakeSnippetStatement(lockStatement); } - CodeObject IAstVisitor.VisitReturnStatement(ReturnStatement returnStatement, object data) + CodeObject IAstVisitor.VisitReturnStatement(ReturnStatement returnStatement) { return new CodeMethodReturnStatement(Convert(returnStatement.Expression)); } - CodeObject IAstVisitor.VisitSwitchStatement(SwitchStatement switchStatement, object data) + CodeObject IAstVisitor.VisitSwitchStatement(SwitchStatement switchStatement) { return MakeSnippetStatement(switchStatement); } - CodeObject IAstVisitor.VisitSwitchSection(SwitchSection switchSection, object data) + CodeObject IAstVisitor.VisitSwitchSection(SwitchSection switchSection) { throw new NotSupportedException(); } - CodeObject IAstVisitor.VisitCaseLabel(CaseLabel caseLabel, object data) + CodeObject IAstVisitor.VisitCaseLabel(CaseLabel caseLabel) { throw new NotSupportedException(); } - CodeObject IAstVisitor.VisitThrowStatement(ThrowStatement throwStatement, object data) + CodeObject IAstVisitor.VisitThrowStatement(ThrowStatement throwStatement) { return new CodeThrowExceptionStatement(Convert(throwStatement.Expression)); } - CodeObject IAstVisitor.VisitTryCatchStatement(TryCatchStatement tryCatchStatement, object data) + CodeObject IAstVisitor.VisitTryCatchStatement(TryCatchStatement tryCatchStatement) { List catchClauses = new List(); foreach (var catchClause in tryCatchStatement.CatchClauses) { @@ -913,27 +913,27 @@ namespace ICSharpCode.NRefactory.CSharp ConvertBlock(tryCatchStatement.FinallyBlock)); } - CodeObject IAstVisitor.VisitCatchClause(CatchClause catchClause, object data) + CodeObject IAstVisitor.VisitCatchClause(CatchClause catchClause) { throw new NotSupportedException(); } - CodeObject IAstVisitor.VisitUncheckedStatement(UncheckedStatement uncheckedStatement, object data) + CodeObject IAstVisitor.VisitUncheckedStatement(UncheckedStatement uncheckedStatement) { return MakeSnippetStatement(uncheckedStatement); } - CodeObject IAstVisitor.VisitUnsafeStatement(UnsafeStatement unsafeStatement, object data) + CodeObject IAstVisitor.VisitUnsafeStatement(UnsafeStatement unsafeStatement) { return MakeSnippetStatement(unsafeStatement); } - CodeObject IAstVisitor.VisitUsingStatement(UsingStatement usingStatement, object data) + CodeObject IAstVisitor.VisitUsingStatement(UsingStatement usingStatement) { return MakeSnippetStatement(usingStatement); } - CodeObject IAstVisitor.VisitVariableDeclarationStatement(VariableDeclarationStatement variableDeclarationStatement, object data) + CodeObject IAstVisitor.VisitVariableDeclarationStatement(VariableDeclarationStatement variableDeclarationStatement) { if (variableDeclarationStatement.Variables.Count != 1) return MakeSnippetStatement(variableDeclarationStatement); @@ -954,27 +954,27 @@ namespace ICSharpCode.NRefactory.CSharp } } - CodeObject IAstVisitor.VisitWhileStatement(WhileStatement whileStatement, object data) + CodeObject IAstVisitor.VisitWhileStatement(WhileStatement whileStatement) { return new CodeIterationStatement(null, Convert(whileStatement.Condition), null, ConvertEmbeddedStatement(whileStatement.EmbeddedStatement)); } - CodeObject IAstVisitor.VisitYieldBreakStatement(YieldBreakStatement yieldBreakStatement, object data) + CodeObject IAstVisitor.VisitYieldBreakStatement(YieldBreakStatement yieldBreakStatement) { return MakeSnippetStatement(yieldBreakStatement); } - CodeObject IAstVisitor.VisitYieldReturnStatement(YieldReturnStatement yieldStatement, object data) + CodeObject IAstVisitor.VisitYieldReturnStatement(YieldReturnStatement yieldStatement) { return MakeSnippetStatement(yieldStatement); } - CodeObject IAstVisitor.VisitAccessor(Accessor accessor, object data) + CodeObject IAstVisitor.VisitAccessor(Accessor accessor) { throw new NotSupportedException(); } - CodeObject IAstVisitor.VisitConstructorDeclaration(ConstructorDeclaration constructorDeclaration, object data) + CodeObject IAstVisitor.VisitConstructorDeclaration(ConstructorDeclaration constructorDeclaration) { CodeConstructor ctor = new CodeConstructor(); ctor.Attributes = ConvertMemberAttributes(constructorDeclaration.Modifiers); @@ -990,17 +990,17 @@ namespace ICSharpCode.NRefactory.CSharp return ctor; } - CodeObject IAstVisitor.VisitConstructorInitializer(ConstructorInitializer constructorInitializer, object data) + CodeObject IAstVisitor.VisitConstructorInitializer(ConstructorInitializer constructorInitializer) { throw new NotSupportedException(); } - CodeObject IAstVisitor.VisitDestructorDeclaration(DestructorDeclaration destructorDeclaration, object data) + CodeObject IAstVisitor.VisitDestructorDeclaration(DestructorDeclaration destructorDeclaration) { return new CodeSnippetTypeMember(MakeSnippet(destructorDeclaration)); } - CodeObject IAstVisitor.VisitEnumMemberDeclaration(EnumMemberDeclaration enumMemberDeclaration, object data) + CodeObject IAstVisitor.VisitEnumMemberDeclaration(EnumMemberDeclaration enumMemberDeclaration) { TypeDeclaration td = enumMemberDeclaration.Parent as TypeDeclaration; CodeMemberField f = new CodeMemberField(td != null ? td.Name : "Enum", enumMemberDeclaration.Name); @@ -1010,7 +1010,7 @@ namespace ICSharpCode.NRefactory.CSharp return f; } - CodeObject IAstVisitor.VisitEventDeclaration(EventDeclaration eventDeclaration, object data) + CodeObject IAstVisitor.VisitEventDeclaration(EventDeclaration eventDeclaration) { foreach (VariableInitializer vi in eventDeclaration.Variables) { if (!vi.Initializer.IsNull) { @@ -1028,12 +1028,12 @@ namespace ICSharpCode.NRefactory.CSharp return null; } - CodeObject IAstVisitor.VisitCustomEventDeclaration(CustomEventDeclaration customEventDeclaration, object data) + CodeObject IAstVisitor.VisitCustomEventDeclaration(CustomEventDeclaration customEventDeclaration) { return new CodeSnippetTypeMember(MakeSnippet(customEventDeclaration)); } - CodeObject IAstVisitor.VisitFieldDeclaration(FieldDeclaration fieldDeclaration, object data) + CodeObject IAstVisitor.VisitFieldDeclaration(FieldDeclaration fieldDeclaration) { foreach (VariableInitializer vi in fieldDeclaration.Variables) { CodeMemberField f = new CodeMemberField(Convert(fieldDeclaration.ReturnType), vi.Name); @@ -1045,7 +1045,7 @@ namespace ICSharpCode.NRefactory.CSharp return null; } - CodeObject IAstVisitor.VisitIndexerDeclaration(IndexerDeclaration indexerDeclaration, object data) + CodeObject IAstVisitor.VisitIndexerDeclaration(IndexerDeclaration indexerDeclaration) { CodeMemberProperty p = new CodeMemberProperty(); p.Attributes = ConvertMemberAttributes(indexerDeclaration.Modifiers); @@ -1066,7 +1066,7 @@ namespace ICSharpCode.NRefactory.CSharp return p; } - CodeObject IAstVisitor.VisitMethodDeclaration(MethodDeclaration methodDeclaration, object data) + CodeObject IAstVisitor.VisitMethodDeclaration(MethodDeclaration methodDeclaration) { CodeMemberMethod m = new CodeMemberMethod(); m.Attributes = ConvertMemberAttributes(methodDeclaration.Modifiers); @@ -1084,7 +1084,7 @@ namespace ICSharpCode.NRefactory.CSharp return m; } - CodeObject IAstVisitor.VisitOperatorDeclaration(OperatorDeclaration operatorDeclaration, object data) + CodeObject IAstVisitor.VisitOperatorDeclaration(OperatorDeclaration operatorDeclaration) { CodeMemberMethod m = new CodeMemberMethod(); m.Attributes = ConvertMemberAttributes(operatorDeclaration.Modifiers); @@ -1100,7 +1100,7 @@ namespace ICSharpCode.NRefactory.CSharp return m; } - CodeObject IAstVisitor.VisitParameterDeclaration(ParameterDeclaration parameterDeclaration, object data) + CodeObject IAstVisitor.VisitParameterDeclaration(ParameterDeclaration parameterDeclaration) { var p = new CodeParameterDeclarationExpression(Convert(parameterDeclaration.Type), parameterDeclaration.Name); p.CustomAttributes.AddRange(Convert(parameterDeclaration.Attributes)); @@ -1126,7 +1126,7 @@ namespace ICSharpCode.NRefactory.CSharp return result.ToArray(); } - CodeObject IAstVisitor.VisitPropertyDeclaration(PropertyDeclaration propertyDeclaration, object data) + CodeObject IAstVisitor.VisitPropertyDeclaration(PropertyDeclaration propertyDeclaration) { CodeMemberProperty p = new CodeMemberProperty(); p.Attributes = ConvertMemberAttributes(propertyDeclaration.Modifiers); @@ -1146,22 +1146,22 @@ namespace ICSharpCode.NRefactory.CSharp return p; } - CodeObject IAstVisitor.VisitVariableInitializer(VariableInitializer variableInitializer, object data) + CodeObject IAstVisitor.VisitVariableInitializer(VariableInitializer variableInitializer) { throw new NotSupportedException(); // should be handled by the parent node } - CodeObject IAstVisitor.VisitFixedFieldDeclaration(FixedFieldDeclaration fixedFieldDeclaration, object data) + CodeObject IAstVisitor.VisitFixedFieldDeclaration(FixedFieldDeclaration fixedFieldDeclaration) { return new CodeSnippetTypeMember(MakeSnippet(fixedFieldDeclaration)); } - CodeObject IAstVisitor.VisitFixedVariableInitializer(FixedVariableInitializer fixedVariableInitializer, object data) + CodeObject IAstVisitor.VisitFixedVariableInitializer(FixedVariableInitializer fixedVariableInitializer) { throw new NotSupportedException(); // should be handled by the parent node } - CodeObject IAstVisitor.VisitCompilationUnit(CompilationUnit compilationUnit, object data) + CodeObject IAstVisitor.VisitCompilationUnit(CompilationUnit compilationUnit) { CodeCompileUnit cu = new CodeCompileUnit(); foreach (AstNode node in compilationUnit.Children) { @@ -1179,7 +1179,7 @@ namespace ICSharpCode.NRefactory.CSharp return cu; } - CodeObject IAstVisitor.VisitSimpleType(SimpleType simpleType, object data) + CodeObject IAstVisitor.VisitSimpleType(SimpleType simpleType) { if (useFullyQualifiedTypeNames) { IType type = Resolve(simpleType).Type; @@ -1191,7 +1191,7 @@ namespace ICSharpCode.NRefactory.CSharp return tr; } - CodeObject IAstVisitor.VisitMemberType(MemberType memberType, object data) + CodeObject IAstVisitor.VisitMemberType(MemberType memberType) { if (memberType.IsDoubleColon && new SimpleType("global").IsMatch(memberType.Target)) { var tr = new CodeTypeReference(memberType.MemberName, CodeTypeReferenceOptions.GlobalReference); @@ -1211,7 +1211,7 @@ namespace ICSharpCode.NRefactory.CSharp return target; } - CodeObject IAstVisitor.VisitComposedType(ComposedType composedType, object data) + CodeObject IAstVisitor.VisitComposedType(ComposedType composedType) { CodeTypeReference typeRef = Convert(composedType.BaseType); if (typeRef == null) @@ -1225,38 +1225,52 @@ namespace ICSharpCode.NRefactory.CSharp return typeRef; } - CodeObject IAstVisitor.VisitArraySpecifier(ArraySpecifier arraySpecifier, object data) + CodeObject IAstVisitor.VisitArraySpecifier(ArraySpecifier arraySpecifier) { throw new NotSupportedException(); // handled by parent node } - CodeObject IAstVisitor.VisitPrimitiveType(PrimitiveType primitiveType, object data) + CodeObject IAstVisitor.VisitPrimitiveType(PrimitiveType primitiveType) { - string keyword = primitiveType.Keyword; - KnownTypeCode typeCode = TypeSystemConvertVisitor.GetTypeCodeForPrimitiveType(keyword); + KnownTypeCode typeCode = primitiveType.KnownTypeCode; if (typeCode != KnownTypeCode.None) { KnownTypeReference ktr = KnownTypeReference.Get(typeCode); return new CodeTypeReference(ktr.Namespace + "." + ktr.Name); } - return new CodeTypeReference(keyword); + return new CodeTypeReference(primitiveType.Keyword); } - CodeObject IAstVisitor.VisitComment (Comment comment, object data) + CodeObject IAstVisitor.VisitComment (Comment comment) { return new CodeComment (comment.Content, comment.CommentType == CommentType.Documentation); } - - CodeObject IAstVisitor.VisitPreProcessorDirective (PreProcessorDirective preProcessorDirective, object data) + + CodeObject IAstVisitor.VisitNewLine(NewLineNode newLineNode) + { + throw new NotSupportedException(); + } + + CodeObject IAstVisitor.VisitWhitespace(WhitespaceNode whitespaceNode) + { + throw new NotSupportedException(); + } + + CodeObject IAstVisitor.VisitText(TextNode textNode) + { + throw new NotSupportedException(); + } + + CodeObject IAstVisitor.VisitPreProcessorDirective (PreProcessorDirective preProcessorDirective) { return new CodeComment ("#" + preProcessorDirective.Type.ToString ().ToLower ()); } - CodeObject IAstVisitor.VisitTypeParameterDeclaration(TypeParameterDeclaration typeParameterDeclaration, object data) + CodeObject IAstVisitor.VisitTypeParameterDeclaration(TypeParameterDeclaration typeParameterDeclaration) { throw new NotSupportedException(); // type parameters and constraints are handled together } - CodeObject IAstVisitor.VisitConstraint(Constraint constraint, object data) + CodeObject IAstVisitor.VisitConstraint(Constraint constraint) { throw new NotSupportedException(); } @@ -1285,17 +1299,22 @@ namespace ICSharpCode.NRefactory.CSharp return result.ToArray(); } - CodeObject IAstVisitor.VisitCSharpTokenNode(CSharpTokenNode cSharpTokenNode, object data) + CodeObject IAstVisitor.VisitCSharpTokenNode(CSharpTokenNode cSharpTokenNode) + { + return null; + } + + CodeObject IAstVisitor.VisitIdentifier(Identifier identifier) { return null; } - CodeObject IAstVisitor.VisitIdentifier(Identifier identifier, object data) + CodeObject IAstVisitor.VisitPatternPlaceholder(AstNode placeholder, ICSharpCode.NRefactory.PatternMatching.Pattern pattern) { return null; } - CodeObject IAstVisitor.VisitPatternPlaceholder(AstNode placeholder, ICSharpCode.NRefactory.PatternMatching.Pattern pattern, object data) + CodeObject IAstVisitor.VisitDocumentationReference(DocumentationReference documentationReference) { return null; } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/InsertParenthesesVisitor.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/InsertParenthesesVisitor.cs index 340955c159..0b7e2424ce 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/InsertParenthesesVisitor.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/InsertParenthesesVisitor.cs @@ -27,7 +27,7 @@ namespace ICSharpCode.NRefactory.CSharp /// would incorrectly result in "2 * 1 + 1". By running InsertParenthesesVisitor, the necessary /// parentheses are inserted: "2 * (1 + 1)". /// - public class InsertParenthesesVisitor : DepthFirstAstVisitor + public class InsertParenthesesVisitor : DepthFirstAstVisitor { /// /// Gets/Sets whether the visitor should insert parentheses to make the code better looking. @@ -126,25 +126,25 @@ namespace ICSharpCode.NRefactory.CSharp } // Primary expressions - public override object VisitMemberReferenceExpression(MemberReferenceExpression memberReferenceExpression, object data) + public override void VisitMemberReferenceExpression(MemberReferenceExpression memberReferenceExpression) { ParenthesizeIfRequired(memberReferenceExpression.Target, Primary); - return base.VisitMemberReferenceExpression(memberReferenceExpression, data); + base.VisitMemberReferenceExpression(memberReferenceExpression); } - public override object VisitPointerReferenceExpression(PointerReferenceExpression pointerReferenceExpression, object data) + public override void VisitPointerReferenceExpression(PointerReferenceExpression pointerReferenceExpression) { ParenthesizeIfRequired(pointerReferenceExpression.Target, Primary); - return base.VisitPointerReferenceExpression(pointerReferenceExpression, data); + base.VisitPointerReferenceExpression(pointerReferenceExpression); } - public override object VisitInvocationExpression(InvocationExpression invocationExpression, object data) + public override void VisitInvocationExpression(InvocationExpression invocationExpression) { ParenthesizeIfRequired(invocationExpression.Target, Primary); - return base.VisitInvocationExpression(invocationExpression, data); + base.VisitInvocationExpression(invocationExpression); } - public override object VisitIndexerExpression(IndexerExpression indexerExpression, object data) + public override void VisitIndexerExpression(IndexerExpression indexerExpression) { ParenthesizeIfRequired(indexerExpression.Target, Primary); ArrayCreateExpression ace = indexerExpression.Target as ArrayCreateExpression; @@ -152,20 +152,20 @@ namespace ICSharpCode.NRefactory.CSharp // require parentheses for "(new int[1])[0]" Parenthesize(indexerExpression.Target); } - return base.VisitIndexerExpression(indexerExpression, data); + base.VisitIndexerExpression(indexerExpression); } // Unary expressions - public override object VisitUnaryOperatorExpression(UnaryOperatorExpression unaryOperatorExpression, object data) + public override void VisitUnaryOperatorExpression(UnaryOperatorExpression unaryOperatorExpression) { ParenthesizeIfRequired(unaryOperatorExpression.Expression, GetPrecedence(unaryOperatorExpression)); UnaryOperatorExpression child = unaryOperatorExpression.Expression as UnaryOperatorExpression; if (child != null && InsertParenthesesForReadability) Parenthesize(child); - return base.VisitUnaryOperatorExpression(unaryOperatorExpression, data); + base.VisitUnaryOperatorExpression(unaryOperatorExpression); } - public override object VisitCastExpression(CastExpression castExpression, object data) + public override void VisitCastExpression(CastExpression castExpression) { ParenthesizeIfRequired(castExpression.Expression, InsertParenthesesForReadability ? Primary : Unary); // There's a nasty issue in the C# grammar: cast expressions including certain operators are ambiguous in some cases @@ -211,7 +211,7 @@ namespace ICSharpCode.NRefactory.CSharp break; } } - return base.VisitCastExpression(castExpression, data); + base.VisitCastExpression(castExpression); } static bool TypeCanBeMisinterpretedAsExpression(AstType type) @@ -227,7 +227,7 @@ namespace ICSharpCode.NRefactory.CSharp } // Binary Operators - public override object VisitBinaryOperatorExpression(BinaryOperatorExpression binaryOperatorExpression, object data) + public override void VisitBinaryOperatorExpression(BinaryOperatorExpression binaryOperatorExpression) { int precedence = GetPrecedence(binaryOperatorExpression); if (binaryOperatorExpression.Operator == BinaryOperatorType.NullCoalescing) { @@ -255,7 +255,7 @@ namespace ICSharpCode.NRefactory.CSharp ParenthesizeIfRequired(binaryOperatorExpression.Right, precedence + 1); } } - return base.VisitBinaryOperatorExpression(binaryOperatorExpression, data); + base.VisitBinaryOperatorExpression(binaryOperatorExpression); } BinaryOperatorType? GetBinaryOperatorType(Expression expr) @@ -267,7 +267,7 @@ namespace ICSharpCode.NRefactory.CSharp return null; } - public override object VisitIsExpression(IsExpression isExpression, object data) + public override void VisitIsExpression(IsExpression isExpression) { if (InsertParenthesesForReadability) { // few people know the precedence of 'is', so always put parentheses in nice-looking mode. @@ -275,10 +275,10 @@ namespace ICSharpCode.NRefactory.CSharp } else { ParenthesizeIfRequired(isExpression.Expression, RelationalAndTypeTesting); } - return base.VisitIsExpression(isExpression, data); + base.VisitIsExpression(isExpression); } - public override object VisitAsExpression(AsExpression asExpression, object data) + public override void VisitAsExpression(AsExpression asExpression) { if (InsertParenthesesForReadability) { // few people know the precedence of 'as', so always put parentheses in nice-looking mode. @@ -286,11 +286,11 @@ namespace ICSharpCode.NRefactory.CSharp } else { ParenthesizeIfRequired(asExpression.Expression, RelationalAndTypeTesting); } - return base.VisitAsExpression(asExpression, data); + base.VisitAsExpression(asExpression); } // Conditional operator - public override object VisitConditionalExpression(ConditionalExpression conditionalExpression, object data) + public override void VisitConditionalExpression(ConditionalExpression conditionalExpression) { // Associativity here is a bit tricky: // (a ? b : c ? d : e) == (a ? b : (c ? d : e)) @@ -306,10 +306,10 @@ namespace ICSharpCode.NRefactory.CSharp ParenthesizeIfRequired(conditionalExpression.TrueExpression, Conditional); ParenthesizeIfRequired(conditionalExpression.FalseExpression, Conditional); } - return base.VisitConditionalExpression(conditionalExpression, data); + base.VisitConditionalExpression(conditionalExpression); } - public override object VisitAssignmentExpression(AssignmentExpression assignmentExpression, object data) + public override void VisitAssignmentExpression(AssignmentExpression assignmentExpression) { // assignment is right-associative ParenthesizeIfRequired(assignmentExpression.Left, Assignment + 1); @@ -318,12 +318,12 @@ namespace ICSharpCode.NRefactory.CSharp } else { ParenthesizeIfRequired(assignmentExpression.Right, Assignment); } - return base.VisitAssignmentExpression(assignmentExpression, data); + base.VisitAssignmentExpression(assignmentExpression); } // don't need to handle lambdas, they have lowest precedence and unambiguous associativity - public override object VisitQueryExpression(QueryExpression queryExpression, object data) + public override void VisitQueryExpression(QueryExpression queryExpression) { // Query expressions are strange beasts: // "var a = -from b in c select d;" is valid, so queries bind stricter than unary expressions. @@ -339,7 +339,7 @@ namespace ICSharpCode.NRefactory.CSharp if (queryExpression.Parent is UnaryOperatorExpression || queryExpression.Parent is BinaryOperatorExpression) Parenthesize(queryExpression); } - return base.VisitQueryExpression(queryExpression, data); + base.VisitQueryExpression(queryExpression); } } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/TextWriterOutputFormatter.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/TextWriterOutputFormatter.cs index ed55fc671a..e8d481b219 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/TextWriterOutputFormatter.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/OutputVisitor/TextWriterOutputFormatter.cs @@ -29,6 +29,7 @@ namespace ICSharpCode.NRefactory.CSharp readonly TextWriter textWriter; int indentation; bool needsIndent = true; + bool isAtStartOfLine = true; public int Indentation { get { @@ -53,18 +54,21 @@ namespace ICSharpCode.NRefactory.CSharp { WriteIndentation(); textWriter.Write(ident); + isAtStartOfLine = false; } public void WriteKeyword(string keyword) { WriteIndentation(); textWriter.Write(keyword); + isAtStartOfLine = false; } public void WriteToken(string token) { WriteIndentation(); textWriter.Write(token); + isAtStartOfLine = false; } public void Space() @@ -75,10 +79,10 @@ namespace ICSharpCode.NRefactory.CSharp public void OpenBrace(BraceStyle style) { - bool isAtStartOfLine = needsIndent; switch (style) { case BraceStyle.DoNotChange: case BraceStyle.EndOfLine: + case BraceStyle.BannerStyle: WriteIndentation(); if (!isAtStartOfLine) textWriter.Write(' '); @@ -125,16 +129,20 @@ namespace ICSharpCode.NRefactory.CSharp Unindent(); WriteIndentation(); textWriter.Write('}'); + isAtStartOfLine = false; break; + case BraceStyle.BannerStyle: case BraceStyle.NextLineShifted: WriteIndentation(); textWriter.Write('}'); + isAtStartOfLine = false; Unindent(); break; case BraceStyle.NextLineShifted2: Unindent(); WriteIndentation(); textWriter.Write('}'); + isAtStartOfLine = false; Unindent(); break; default: @@ -142,7 +150,7 @@ namespace ICSharpCode.NRefactory.CSharp } } - void WriteIndentation() + protected void WriteIndentation() { if (needsIndent) { needsIndent = false; @@ -156,6 +164,7 @@ namespace ICSharpCode.NRefactory.CSharp { textWriter.WriteLine(); needsIndent = true; + isAtStartOfLine = true; } public void Indent() @@ -176,16 +185,19 @@ namespace ICSharpCode.NRefactory.CSharp textWriter.Write("//"); textWriter.WriteLine(content); needsIndent = true; + isAtStartOfLine = true; break; case CommentType.MultiLine: textWriter.Write("/*"); textWriter.Write(content); textWriter.Write("*/"); + isAtStartOfLine = false; break; case CommentType.Documentation: textWriter.Write("///"); textWriter.WriteLine(content); needsIndent = true; + isAtStartOfLine = true; break; default: textWriter.Write(content); @@ -196,7 +208,7 @@ namespace ICSharpCode.NRefactory.CSharp public void WritePreProcessorDirective(PreProcessorDirectiveType type, string argument) { // pre-processor directive must start on its own line - if (!needsIndent) + if (!isAtStartOfLine) NewLine(); WriteIndentation(); textWriter.Write('#'); @@ -210,6 +222,10 @@ namespace ICSharpCode.NRefactory.CSharp public virtual void StartNode(AstNode node) { + // Write out the indentation, so that overrides of this method + // can rely use the current output length to identify the position of the node + // in the output. + WriteIndentation(); } public virtual void EndNode(AstNode node) diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/CSharpParser.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/CSharpParser.cs index 22bbd9bb2b..3c6929bae6 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/CSharpParser.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/CSharpParser.cs @@ -23,12 +23,12 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN // THE SOFTWARE. - using System; using System.Linq; using System.Collections.Generic; using System.IO; using System.Text; +using ICSharpCode.NRefactory.Editor; using Mono.CSharp; using ICSharpCode.NRefactory.TypeSystem; @@ -50,7 +50,7 @@ namespace ICSharpCode.NRefactory.CSharp } } - public LocationsBag LocationsBag { + public LocationsBag LocationsBag { get; private set; } @@ -66,6 +66,61 @@ namespace ICSharpCode.NRefactory.CSharp return new TextLocation (loc.Row, loc.Column); } + public override void Visit(ModuleContainer mc) + { + bool first = true; + foreach (var container in mc.Containers) { + var nspace = container as NamespaceContainer; + if (nspace == null) { + container.Accept(this); + continue; + } + NamespaceDeclaration nDecl = null; + var loc = LocationsBag.GetLocations(nspace); + + if (nspace.NS != null && !string.IsNullOrEmpty(nspace.NS.Name)) { + nDecl = new NamespaceDeclaration (); + if (loc != null) { + nDecl.AddChild(new CSharpTokenNode (Convert(loc [0])), Roles.NamespaceKeyword); + } + ConvertNamespaceName(nspace.RealMemberName, nDecl); + if (loc != null && loc.Count > 1) { + nDecl.AddChild(new CSharpTokenNode (Convert(loc [1])), Roles.LBrace); + } + AddToNamespace(nDecl); + namespaceStack.Push(nDecl); + } + + if (nspace.Usings != null) { + foreach (var us in nspace.Usings) { + us.Accept(this); + } + } + + if (first) { + first = false; + AddAttributeSection(Unit, mc); + } + + if (nspace.Containers != null) { + foreach (var subContainer in nspace.Containers) { + subContainer.Accept(this); + } + } + if (nDecl != null) { + AddAttributeSection (nDecl, nspace.UnattachedAttributes, EntityDeclaration.UnattachedAttributeRole); + if (loc != null && loc.Count > 2) + nDecl.AddChild (new CSharpTokenNode (Convert (loc [2])), Roles.RBrace); + if (loc != null && loc.Count > 3) + nDecl.AddChild (new CSharpTokenNode (Convert (loc [3])), Roles.Semicolon); + + namespaceStack.Pop (); + } else { + AddAttributeSection (unit, nspace.UnattachedAttributes, EntityDeclaration.UnattachedAttributeRole); + } + } + AddAttributeSection (unit, mc.UnattachedAttributes, EntityDeclaration.UnattachedAttributeRole); + } #region Global Stack namespaceStack = new Stack (); @@ -76,15 +131,15 @@ namespace ICSharpCode.NRefactory.CSharp return; var loc = LocationsBag.GetLocations (texpr.TypeArguments); if (loc != null && loc.Count >= 2) - result.AddChild (new CSharpTokenNode (Convert (loc [loc.Count - 2]), 1), AstType.Roles.LChevron); + result.AddChild (new CSharpTokenNode (Convert (loc [loc.Count - 2])), Roles.LChevron); int i = 0; foreach (var arg in texpr.TypeArguments.Args) { - result.AddChild (ConvertToType (arg), AstType.Roles.TypeArgument); + result.AddChild (ConvertToType (arg), Roles.TypeArgument); if (loc != null && i < loc.Count - 2) - result.AddChild (new CSharpTokenNode (Convert (loc [i++]), 1), AstType.Roles.Comma); + result.AddChild (new CSharpTokenNode (Convert (loc [i++])), Roles.Comma); } if (loc != null && loc.Count >= 2) - result.AddChild (new CSharpTokenNode (Convert (loc [loc.Count - 1]), 1), AstType.Roles.RChevron); + result.AddChild (new CSharpTokenNode (Convert (loc [loc.Count - 1])), Roles.RChevron); } AstType ConvertToType (TypeParameter spec) @@ -102,23 +157,23 @@ namespace ICSharpCode.NRefactory.CSharp result.AddChild (ConvertToType (memberName.Left), MemberType.TargetRole); var loc = LocationsBag.GetLocations (memberName.Left); if (loc != null) - result.AddChild (new CSharpTokenNode (Convert (loc [0]), 1), MemberType.Roles.Dot); - result.AddChild (Identifier.Create (memberName.Name, Convert (memberName.Location)), MemberType.Roles.Identifier); + result.AddChild (new CSharpTokenNode (Convert (loc [0])), Roles.Dot); + result.AddChild (Identifier.Create (memberName.Name, Convert (memberName.Location)), Roles.Identifier); } else { result = new SimpleType () { IdentifierToken = Identifier.Create (memberName.Name, Convert (memberName.Location)) }; } if (memberName.TypeParameters != null) { var chevronLocs = LocationsBag.GetLocations (memberName.TypeParameters); if (chevronLocs != null) - result.AddChild (new CSharpTokenNode (Convert (chevronLocs[chevronLocs.Count - 2]), 1), InvocationExpression.Roles.LChevron); + result.AddChild (new CSharpTokenNode (Convert (chevronLocs [chevronLocs.Count - 2])), Roles.LChevron); for (int i = 0; i < memberName.TypeParameters.Count; i++) { - var param = memberName.TypeParameters[i]; - result.AddChild (new SimpleType (Identifier.Create (param.Name, Convert (param.Location))), AstType.Roles.TypeArgument); + var param = memberName.TypeParameters [i]; + result.AddChild (new SimpleType (Identifier.Create (param.Name, Convert (param.Location))), Roles.TypeArgument); if (chevronLocs != null && i < chevronLocs.Count - 2) - result.AddChild (new CSharpTokenNode (Convert (chevronLocs [i]), 1), InvocationExpression.Roles.Comma); + result.AddChild (new CSharpTokenNode (Convert (chevronLocs [i])), Roles.Comma); } if (chevronLocs != null) - result.AddChild (new CSharpTokenNode (Convert (chevronLocs[chevronLocs.Count - 1]), 1), InvocationExpression.Roles.RChevron); + result.AddChild (new CSharpTokenNode (Convert (chevronLocs [chevronLocs.Count - 1])), Roles.RChevron); } return result; } @@ -147,7 +202,7 @@ namespace ICSharpCode.NRefactory.CSharp var memberType = new MemberType (); memberType.AddChild (ConvertToType (ma.LeftExpression), MemberType.TargetRole); - memberType.AddChild (new CSharpTokenNode (Convert (ma.DotLocation), 1), MemberType.Roles.Dot); + memberType.AddChild (new CSharpTokenNode (Convert (ma.DotLocation)), Roles.Dot); memberType.MemberNameToken = Identifier.Create (ma.Name, Convert (ma.Location)); @@ -169,15 +224,15 @@ namespace ICSharpCode.NRefactory.CSharp var ccSpec = cc.Spec; while (ccSpec != null) { if (ccSpec.IsNullable) { - result.AddChild (new CSharpTokenNode (Convert (ccSpec.Location), 1), ComposedType.NullableRole); + result.AddChild (new CSharpTokenNode (Convert (ccSpec.Location)), ComposedType.NullableRole); } else if (ccSpec.IsPointer) { - result.AddChild (new CSharpTokenNode (Convert (ccSpec.Location), 1), ComposedType.PointerRole); + result.AddChild (new CSharpTokenNode (Convert (ccSpec.Location)), ComposedType.PointerRole); } else { var location = LocationsBag.GetLocations (ccSpec); var spec = new ArraySpecifier () { Dimensions = ccSpec.Dimension }; - spec.AddChild (new CSharpTokenNode (Convert (ccSpec.Location), 1), FieldDeclaration.Roles.LBracket); + spec.AddChild (new CSharpTokenNode (Convert (ccSpec.Location)), Roles.LBracket); if (location != null) - spec.AddChild (new CSharpTokenNode (Convert (location [0]), 1), FieldDeclaration.Roles.RBracket); + spec.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.RBracket); result.ArraySpecifiers.Add (spec); } @@ -197,12 +252,10 @@ namespace ICSharpCode.NRefactory.CSharp return new PrimitiveType ("new", Convert (sce.Location)); } } - System.Console.WriteLine ("Error while converting :" + typeName + " - unknown type name"); - System.Console.WriteLine (Environment.StackTrace); return new SimpleType ("unknown"); } - IEnumerable GetAttributes (List optAttributes) + IEnumerable GetAttributes (IEnumerable optAttributes) { if (optAttributes == null) yield break; @@ -213,49 +266,52 @@ namespace ICSharpCode.NRefactory.CSharp result.HasArgumentList = loc != null; int pos = 0; if (loc != null) - result.AddChild (new CSharpTokenNode (Convert (loc [pos++]), 1), AttributeSection.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (loc [pos++])), Roles.LPar); if (attr.PositionalArguments != null) { foreach (var arg in attr.PositionalArguments) { var na = arg as NamedArgument; if (na != null) { var newArg = new NamedArgumentExpression (); - newArg.AddChild (Identifier.Create (na.Name, Convert (na.Location)), NamedArgumentExpression.Roles.Identifier); + newArg.AddChild (Identifier.Create (na.Name, Convert (na.Location)), Roles.Identifier); var argLoc = LocationsBag.GetLocations (na); if (argLoc != null) - newArg.AddChild (new CSharpTokenNode (Convert (argLoc [0]), 1), NamedArgumentExpression.Roles.Colon); - newArg.AddChild ((Expression)na.Expr.Accept (this), NamedExpression.Roles.Expression); - result.AddChild (newArg, Attribute.Roles.Argument); + newArg.AddChild (new CSharpTokenNode (Convert (argLoc [0])), Roles.Colon); + if (na.Expr != null) + newArg.AddChild ((Expression)na.Expr.Accept (this), Roles.Expression); + result.AddChild (newArg, Roles.Argument); } else { - result.AddChild ((Expression)arg.Expr.Accept (this), Attribute.Roles.Argument); + if (arg.Expr != null) + result.AddChild ((Expression)arg.Expr.Accept (this), Roles.Argument); } if (loc != null && pos + 1 < loc.Count) - result.AddChild (new CSharpTokenNode (Convert (loc [pos++]), 1), AttributeSection.Roles.Comma); + result.AddChild (new CSharpTokenNode (Convert (loc [pos++])), Roles.Comma); } } if (attr.NamedArguments != null) { foreach (NamedArgument na in attr.NamedArguments) { var newArg = new NamedExpression (); - newArg.AddChild (Identifier.Create (na.Name, Convert (na.Location)), NamedExpression.Roles.Identifier); + newArg.AddChild (Identifier.Create (na.Name, Convert (na.Location)), Roles.Identifier); var argLoc = LocationsBag.GetLocations (na); if (argLoc != null) - newArg.AddChild (new CSharpTokenNode (Convert (argLoc[0]), 1), NamedExpression.Roles.Assign); - newArg.AddChild ((Expression)na.Expr.Accept (this), NamedExpression.Roles.Expression); - result.AddChild (newArg, Attribute.Roles.Argument); + newArg.AddChild (new CSharpTokenNode (Convert (argLoc [0])), Roles.Assign); + if (na.Expr != null) + newArg.AddChild ((Expression)na.Expr.Accept (this), Roles.Expression); + result.AddChild (newArg, Roles.Argument); if (loc != null && pos + 1 < loc.Count) - result.AddChild (new CSharpTokenNode (Convert (loc [pos++]), 1), AttributeSection.Roles.Comma); + result.AddChild (new CSharpTokenNode (Convert (loc [pos++])), Roles.Comma); } } if (loc != null && pos < loc.Count) - result.AddChild (new CSharpTokenNode (Convert (loc [pos++]), 1), AttributeSection.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (loc [pos++])), Roles.RPar); yield return result; } } - AttributeSection ConvertAttributeSection (List optAttributes) + AttributeSection ConvertAttributeSection (IEnumerable optAttributes) { if (optAttributes == null) return null; @@ -263,66 +319,92 @@ namespace ICSharpCode.NRefactory.CSharp var loc = LocationsBag.GetLocations (optAttributes); int pos = 0; if (loc != null) - result.AddChild (new CSharpTokenNode (Convert (loc [pos++]), 1), AttributeSection.Roles.LBracket); + result.AddChild (new CSharpTokenNode (Convert (loc [pos++])), Roles.LBracket); - string target = optAttributes.First ().ExplicitTarget; + var first = optAttributes.FirstOrDefault (); + string target = first != null ? first.ExplicitTarget : null; if (!string.IsNullOrEmpty (target)) { if (loc != null && pos < loc.Count - 1) { - result.AddChild (Identifier.Create (target, Convert (loc [pos++])), AttributeSection.Roles.Identifier); + result.AddChild (Identifier.Create (target, Convert (loc [pos++])), Roles.Identifier); } else { - result.AddChild (Identifier.Create (target), AttributeSection.Roles.Identifier); + result.AddChild (Identifier.Create (target), Roles.Identifier); } if (loc != null && pos < loc.Count) - result.AddChild (new CSharpTokenNode (Convert (loc [pos++]), 1), AttributeSection.Roles.Colon); + result.AddChild (new CSharpTokenNode (Convert (loc [pos++])), Roles.Colon); } foreach (var attr in GetAttributes (optAttributes)) { - result.AddChild (attr, AttributeSection.AttributeRole); + result.AddChild (attr, Roles.Attribute); } // optional comma if (loc != null && pos < loc.Count - 1 && !loc [pos].Equals (loc [pos + 1])) - result.AddChild (new CSharpTokenNode (Convert (loc [pos++]), 1), AttributeSection.Roles.Comma); + result.AddChild (new CSharpTokenNode (Convert (loc [pos++])), Roles.Comma); if (loc != null && pos < loc.Count) - result.AddChild (new CSharpTokenNode (Convert (loc [pos++]), 1), AttributeSection.Roles.RBracket); + result.AddChild (new CSharpTokenNode (Convert (loc [pos++])), Roles.RBracket); return result; } - public override void Visit (UsingsBag.Namespace nspace) + public override void Visit(NamespaceContainer nspace) { NamespaceDeclaration nDecl = null; - if (nspace.Name != null) { + var loc = LocationsBag.GetLocations(nspace); + + if (nspace.NS != null && !string.IsNullOrEmpty(nspace.NS.Name)) { nDecl = new NamespaceDeclaration (); - nDecl.AddChild (new CSharpTokenNode (Convert (nspace.NamespaceLocation), "namespace".Length), NamespaceDeclaration.Roles.Keyword); - ConvertNamespaceName (nspace.Name, nDecl); - nDecl.AddChild (new CSharpTokenNode (Convert (nspace.OpenBrace), 1), NamespaceDeclaration.Roles.LBrace); - AddToNamespace (nDecl); - namespaceStack.Push (nDecl); + if (loc != null) { + nDecl.AddChild(new CSharpTokenNode (Convert(loc [0])), Roles.NamespaceKeyword); + } + ConvertNamespaceName(nspace.RealMemberName, nDecl); + if (loc != null && loc.Count > 1) { + nDecl.AddChild(new CSharpTokenNode (Convert(loc [1])), Roles.LBrace); + } + AddToNamespace(nDecl); + namespaceStack.Push(nDecl); } - VisitNamespaceUsings (nspace); - VisitNamespaceBody (nspace); + if (nspace.Usings != null) { + foreach (var us in nspace.Usings) { + us.Accept(this); + } + } + + if (nspace.Containers != null) { + foreach (var container in nspace.Containers) { + container.Accept(this); + } + } if (nDecl != null) { - nDecl.AddChild (new CSharpTokenNode (Convert (nspace.CloseBrace), 1), NamespaceDeclaration.Roles.RBrace); - if (!nspace.OptSemicolon.IsNull) - nDecl.AddChild (new CSharpTokenNode (Convert (nspace.OptSemicolon), 1), NamespaceDeclaration.Roles.Semicolon); + AddAttributeSection(nDecl, nspace.UnattachedAttributes, EntityDeclaration.UnattachedAttributeRole); + if (loc != null && loc.Count > 2) + nDecl.AddChild (new CSharpTokenNode (Convert (loc [2])), Roles.RBrace); + if (loc != null && loc.Count > 3) + nDecl.AddChild (new CSharpTokenNode (Convert (loc [3])), Roles.Semicolon); namespaceStack.Pop (); } } - +// public override void Visit (UsingsBag.Namespace nspace) +// { +// +// +// VisitNamespaceUsings (nspace); +// VisitNamespaceBody (nspace); +// +// } +// void ConvertNamespaceName (MemberName memberName, NamespaceDeclaration namespaceDecl) { AstNode insertPos = null; while (memberName != null) { Identifier newIdent = Identifier.Create (memberName.Name, Convert (memberName.Location)); - namespaceDecl.InsertChildBefore (insertPos, newIdent, NamespaceDeclaration.Roles.Identifier); + namespaceDecl.InsertChildBefore (insertPos, newIdent, Roles.Identifier); insertPos = newIdent; if (!memberName.DotLocation.IsNull) { - var dotToken = new CSharpTokenNode (Convert (memberName.DotLocation), 1); - namespaceDecl.InsertChildBefore (insertPos, dotToken, NamespaceDeclaration.Roles.Dot); + var dotToken = new CSharpTokenNode (Convert (memberName.DotLocation)); + namespaceDecl.InsertChildBefore (insertPos, dotToken, Roles.Dot); insertPos = dotToken; } @@ -330,33 +412,44 @@ namespace ICSharpCode.NRefactory.CSharp } } - public override void Visit (UsingsBag.Using u) + public override void Visit (UsingNamespace un) { - UsingDeclaration ud = new UsingDeclaration (); - ud.AddChild (new CSharpTokenNode (Convert (u.UsingLocation), "using".Length), UsingDeclaration.Roles.Keyword); - ud.AddChild (ConvertToType (u.NSpace), UsingDeclaration.ImportRole); - ud.AddChild (new CSharpTokenNode (Convert (u.SemicolonLocation), 1), UsingDeclaration.Roles.Semicolon); + var ud = new UsingDeclaration (); + var loc = LocationsBag.GetLocations (un); + ud.AddChild (new CSharpTokenNode (Convert (un.Location)), UsingDeclaration.UsingKeywordRole); + if (un.NamespaceExpression != null) + ud.AddChild (ConvertToType (un.NamespaceExpression), UsingDeclaration.ImportRole); + if (loc != null) + ud.AddChild (new CSharpTokenNode (Convert (loc [0])), Roles.Semicolon); AddToNamespace (ud); } - - public override void Visit (UsingsBag.AliasUsing u) + + public override void Visit (UsingAliasNamespace uan) { - UsingAliasDeclaration ud = new UsingAliasDeclaration (); - ud.AddChild (new CSharpTokenNode (Convert (u.UsingLocation), "using".Length), UsingAliasDeclaration.Roles.Keyword); - ud.AddChild (Identifier.Create (u.Identifier.Value, Convert (u.Identifier.Location)), UsingAliasDeclaration.AliasRole); - ud.AddChild (new CSharpTokenNode (Convert (u.AssignLocation), 1), UsingAliasDeclaration.Roles.Assign); - ud.AddChild (ConvertToType (u.Nspace), UsingAliasDeclaration.ImportRole); - ud.AddChild (new CSharpTokenNode (Convert (u.SemicolonLocation), 1), UsingAliasDeclaration.Roles.Semicolon); + var ud = new UsingAliasDeclaration (); + var loc = LocationsBag.GetLocations (uan); + + ud.AddChild (new CSharpTokenNode (Convert (uan.Location)), UsingAliasDeclaration.UsingKeywordRole); + ud.AddChild (Identifier.Create (uan.Alias.Value, Convert (uan.Alias.Location)), UsingAliasDeclaration.AliasRole); + if (loc != null) + ud.AddChild (new CSharpTokenNode (Convert (loc [0])), Roles.Assign); + if (uan.NamespaceExpression != null) + ud.AddChild (ConvertToType (uan.NamespaceExpression), UsingAliasDeclaration.ImportRole); + if (loc != null && loc.Count > 1) + ud.AddChild (new CSharpTokenNode (Convert (loc [1])), Roles.Semicolon); AddToNamespace (ud); } - - public override void Visit (UsingsBag.ExternAlias u) + + public override void Visit (UsingExternAlias uea) { var ud = new ExternAliasDeclaration (); - ud.AddChild (new CSharpTokenNode (Convert (u.ExternLocation), "extern".Length), ExternAliasDeclaration.Roles.Keyword); - ud.AddChild (new CSharpTokenNode (Convert (u.AliasLocation), "alias".Length), ExternAliasDeclaration.AliasRole); - ud.AddChild (Identifier.Create (u.Identifier.Value, Convert (u.Identifier.Location)), ExternAliasDeclaration.Roles.Identifier); - ud.AddChild (new CSharpTokenNode (Convert (u.SemicolonLocation), 1), UsingAliasDeclaration.Roles.Semicolon); + var loc = LocationsBag.GetLocations (uea); + ud.AddChild (new CSharpTokenNode (Convert (uea.Location)), Roles.ExternKeyword); + if (loc != null) + ud.AddChild (new CSharpTokenNode (Convert (loc [0])), Roles.AliasKeyword); + ud.AddChild (Identifier.Create (uea.Alias.Value, Convert (uea.Alias.Location)), Roles.Identifier); + if (loc != null && loc.Count > 1) + ud.AddChild (new CSharpTokenNode (Convert (loc [1])), Roles.Semicolon); AddToNamespace (ud); } @@ -364,19 +457,19 @@ namespace ICSharpCode.NRefactory.CSharp { if (memberName.Left != null) { // left.name - var t = new MemberType(); + var t = new MemberType (); // t.IsDoubleColon = memberName.IsDoubleColon; t.AddChild (ConvertImport (memberName.Left), MemberType.TargetRole); if (!memberName.DotLocation.IsNull) - t.AddChild (new CSharpTokenNode (Convert (memberName.DotLocation), 1), MemberType.Roles.Dot); + t.AddChild (new CSharpTokenNode (Convert (memberName.DotLocation)), Roles.Dot); - t.AddChild (Identifier.Create (memberName.Name, Convert(memberName.Location)), MemberType.Roles.Identifier); + t.AddChild (Identifier.Create (memberName.Name, Convert (memberName.Location)), Roles.Identifier); AddTypeArguments (t, memberName); return t; } else { - SimpleType t = new SimpleType(); - t.AddChild (Identifier.Create (memberName.Name, Convert(memberName.Location)), SimpleType.Roles.Identifier); + SimpleType t = new SimpleType (); + t.AddChild (Identifier.Create (memberName.Name, Convert (memberName.Location)), Roles.Identifier); AddTypeArguments (t, memberName); return t; } @@ -390,31 +483,31 @@ namespace ICSharpCode.NRefactory.CSharp Stack typeStack = new Stack (); - public override void Visit (Class c) + public override void Visit(Class c) { - TypeDeclaration newType = new TypeDeclaration (); + var newType = new TypeDeclaration (); newType.ClassType = ClassType.Class; - AddAttributeSection (newType, c); + AddAttributeSection(newType, c); - var location = LocationsBag.GetMemberLocation (c); - AddModifiers (newType, location); + var location = LocationsBag.GetMemberLocation(c); + AddModifiers(newType, location); int curLoc = 0; - if (location != null) - newType.AddChild (new CSharpTokenNode (Convert (location[curLoc++]), "class".Length), TypeDeclaration.Roles.Keyword); + if (location != null && location.Count > 0) + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.ClassKeyword); - newType.AddChild (Identifier.Create (c.MemberName.Name, Convert (c.MemberName.Location)), AstNode.Roles.Identifier); + newType.AddChild (Identifier.Create (c.MemberName.Name, Convert (c.MemberName.Location)), Roles.Identifier); AddTypeParameters (newType, c.MemberName); if (c.TypeBaseExpressions != null) { if (location != null && curLoc < location.Count) - newType.AddChild (new CSharpTokenNode (Convert (location[curLoc++]), 1), AstNode.Roles.Colon); + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.Colon); var commaLocations = LocationsBag.GetLocations (c.TypeBaseExpressions); int i = 0; foreach (var baseTypes in c.TypeBaseExpressions) { - newType.AddChild (ConvertToType (baseTypes), TypeDeclaration.BaseTypeRole); + newType.AddChild (ConvertToType (baseTypes), Roles.BaseType); if (commaLocations != null && i < commaLocations.Count) { - newType.AddChild (new CSharpTokenNode (Convert (commaLocations [i]), 1), TypeDeclaration.Roles.Comma); + newType.AddChild (new CSharpTokenNode (Convert (commaLocations [i])), Roles.Comma); i++; } } @@ -422,45 +515,47 @@ namespace ICSharpCode.NRefactory.CSharp AddConstraints (newType, c.CurrentTypeParameters); if (location != null && curLoc < location.Count) - newType.AddChild (new CSharpTokenNode (Convert (location[curLoc++]), 1), AstNode.Roles.LBrace); + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.LBrace); typeStack.Push (newType); base.Visit (c); + AddAttributeSection (newType, c.UnattachedAttributes, EntityDeclaration.UnattachedAttributeRole); + if (location != null && curLoc < location.Count) { - newType.AddChild (new CSharpTokenNode (Convert (location[curLoc++]), 1), AstNode.Roles.RBrace); + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.RBrace); - if (c.HasOptionalSemicolon) - newType.AddChild (new CSharpTokenNode (Convert (c.OptionalSemicolon), 1), AstNode.Roles.Semicolon); + if (location != null && curLoc < location.Count) + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.Semicolon); } else { // parser error, set end node to max value. - newType.AddChild (new ErrorNode (), AstNode.Roles.Error); + newType.AddChild (new ErrorNode (), Roles.Error); } typeStack.Pop (); AddType (newType); } - public override void Visit (Struct s) + public override void Visit(Struct s) { - TypeDeclaration newType = new TypeDeclaration (); + var newType = new TypeDeclaration(); newType.ClassType = ClassType.Struct; - AddAttributeSection (newType, s); - var location = LocationsBag.GetMemberLocation (s); - AddModifiers (newType, location); + AddAttributeSection(newType, s); + var location = LocationsBag.GetMemberLocation(s); + AddModifiers(newType, location); int curLoc = 0; - if (location != null) - newType.AddChild (new CSharpTokenNode (Convert (location[curLoc++]), "struct".Length), TypeDeclaration.Roles.Keyword); - newType.AddChild (Identifier.Create (s.MemberName.Name, Convert (s.MemberName.Location)), AstNode.Roles.Identifier); + if (location != null && location.Count > 0) + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.StructKeyword); + newType.AddChild (Identifier.Create (s.MemberName.Name, Convert (s.MemberName.Location)), Roles.Identifier); AddTypeParameters (newType, s.MemberName); if (s.TypeBaseExpressions != null) { if (location != null && curLoc < location.Count) - newType.AddChild (new CSharpTokenNode (Convert (location[curLoc++]), 1), AstNode.Roles.Colon); + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.Colon); var commaLocations = LocationsBag.GetLocations (s.TypeBaseExpressions); int i = 0; foreach (var baseTypes in s.TypeBaseExpressions) { - newType.AddChild (ConvertToType (baseTypes), TypeDeclaration.BaseTypeRole); + newType.AddChild (ConvertToType (baseTypes), Roles.BaseType); if (commaLocations != null && i < commaLocations.Count) { - newType.AddChild (new CSharpTokenNode (Convert (commaLocations [i]), 1), TypeDeclaration.Roles.Comma); + newType.AddChild (new CSharpTokenNode (Convert (commaLocations [i])), Roles.Comma); i++; } } @@ -468,44 +563,44 @@ namespace ICSharpCode.NRefactory.CSharp AddConstraints (newType, s.CurrentTypeParameters); if (location != null && curLoc < location.Count) - newType.AddChild (new CSharpTokenNode (Convert (location[curLoc++]), 1), AstNode.Roles.LBrace); + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.LBrace); typeStack.Push (newType); base.Visit (s); if (location != null && location.Count > 2) { if (location != null && curLoc < location.Count) - newType.AddChild (new CSharpTokenNode (Convert (location[curLoc++]), 1), AstNode.Roles.RBrace); - if (s.HasOptionalSemicolon) - newType.AddChild (new CSharpTokenNode (Convert (s.OptionalSemicolon), 1), AstNode.Roles.Semicolon); + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.RBrace); + if (location != null && curLoc < location.Count) + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.Semicolon); } else { // parser error, set end node to max value. - newType.AddChild (new ErrorNode (), AstNode.Roles.Error); + newType.AddChild (new ErrorNode (), Roles.Error); } typeStack.Pop (); AddType (newType); } - public override void Visit (Interface i) + public override void Visit(Interface i) { - TypeDeclaration newType = new TypeDeclaration (); + var newType = new TypeDeclaration(); newType.ClassType = ClassType.Interface; - AddAttributeSection (newType, i); - var location = LocationsBag.GetMemberLocation (i); - AddModifiers (newType, location); + AddAttributeSection(newType, i); + var location = LocationsBag.GetMemberLocation(i); + AddModifiers(newType, location); int curLoc = 0; - if (location != null) - newType.AddChild (new CSharpTokenNode (Convert (location[curLoc++]), "interface".Length), TypeDeclaration.Roles.Keyword); - newType.AddChild (Identifier.Create (i.MemberName.Name, Convert (i.MemberName.Location)), AstNode.Roles.Identifier); + if (location != null && location.Count > 0) + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.InterfaceKeyword); + newType.AddChild (Identifier.Create (i.MemberName.Name, Convert (i.MemberName.Location)), Roles.Identifier); AddTypeParameters (newType, i.MemberName); if (i.TypeBaseExpressions != null) { if (location != null && curLoc < location.Count) - newType.AddChild (new CSharpTokenNode (Convert (location[curLoc++]), 1), AstNode.Roles.Colon); + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.Colon); var commaLocations = LocationsBag.GetLocations (i.TypeBaseExpressions); int j = 0; foreach (var baseTypes in i.TypeBaseExpressions) { - newType.AddChild (ConvertToType (baseTypes), TypeDeclaration.BaseTypeRole); + newType.AddChild (ConvertToType (baseTypes), Roles.BaseType); if (commaLocations != null && j < commaLocations.Count) { - newType.AddChild (new CSharpTokenNode (Convert (commaLocations [j]), 1), TypeDeclaration.Roles.Comma); + newType.AddChild (new CSharpTokenNode (Convert (commaLocations [j])), Roles.Comma); j++; } } @@ -513,52 +608,54 @@ namespace ICSharpCode.NRefactory.CSharp AddConstraints (newType, i.CurrentTypeParameters); if (location != null && curLoc < location.Count) - newType.AddChild (new CSharpTokenNode (Convert (location[curLoc++]), 1), AstNode.Roles.LBrace); + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.LBrace); typeStack.Push (newType); base.Visit (i); if (location != null && location.Count > 2) { if (location != null && curLoc < location.Count) - newType.AddChild (new CSharpTokenNode (Convert (location[curLoc++]), 1), AstNode.Roles.RBrace); - if (i.HasOptionalSemicolon) - newType.AddChild (new CSharpTokenNode (Convert (i.OptionalSemicolon), 1), AstNode.Roles.Semicolon); + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.RBrace); + if (location != null && curLoc < location.Count) + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.Semicolon); } else { // parser error, set end node to max value. - newType.AddChild (new ErrorNode (), AstNode.Roles.Error); + newType.AddChild (new ErrorNode (), Roles.Error); } typeStack.Pop (); AddType (newType); } - public override void Visit (Mono.CSharp.Delegate d) + public override void Visit(Mono.CSharp.Delegate d) { DelegateDeclaration newDelegate = new DelegateDeclaration (); - var location = LocationsBag.GetMemberLocation (d); - AddAttributeSection (newDelegate, d); - AddModifiers (newDelegate, location); - if (location != null) - newDelegate.AddChild (new CSharpTokenNode (Convert (location[0]), "delegate".Length), TypeDeclaration.Roles.Keyword); - newDelegate.AddChild (ConvertToType (d.ReturnType), AstNode.Roles.Type); - newDelegate.AddChild (Identifier.Create (d.MemberName.Name, Convert (d.MemberName.Location)), AstNode.Roles.Identifier); + var location = LocationsBag.GetMemberLocation(d); + AddAttributeSection(newDelegate, d); + AddModifiers(newDelegate, location); + if (location != null && location.Count > 0) { + newDelegate.AddChild(new CSharpTokenNode (Convert(location [0])), Roles.DelegateKeyword); + } + if (d.ReturnType != null) + newDelegate.AddChild (ConvertToType (d.ReturnType), Roles.Type); + newDelegate.AddChild (Identifier.Create (d.MemberName.Name, Convert (d.MemberName.Location)), Roles.Identifier); AddTypeParameters (newDelegate, d.MemberName); - if (location != null) - newDelegate.AddChild (new CSharpTokenNode (Convert (location[1]), 1), DelegateDeclaration.Roles.LPar); + if (location != null && location.Count > 1) + newDelegate.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.LPar); AddParameter (newDelegate, d.Parameters); - if (location != null) { - newDelegate.AddChild (new CSharpTokenNode (Convert (location[2]), 1), DelegateDeclaration.Roles.RPar); + if (location != null && location.Count > 2) { + newDelegate.AddChild (new CSharpTokenNode (Convert (location [2])), Roles.RPar); } AddConstraints (newDelegate, d.CurrentTypeParameters); - if (location != null) { - newDelegate.AddChild (new CSharpTokenNode (Convert (location[3]), 1), DelegateDeclaration.Roles.Semicolon); + if (location != null && location.Count > 3) { + newDelegate.AddChild (new CSharpTokenNode (Convert (location [3])), Roles.Semicolon); } AddType (newDelegate); } - void AddType (AttributedNode child) + void AddType (EntityDeclaration child) { if (typeStack.Count > 0) { - typeStack.Peek ().AddChild (child, TypeDeclaration.MemberRole); + typeStack.Peek ().AddChild (child, Roles.TypeMemberRole); } else { AddToNamespace (child); } @@ -573,44 +670,43 @@ namespace ICSharpCode.NRefactory.CSharp } } - public override void Visit (Mono.CSharp.Enum e) + public override void Visit(Mono.CSharp.Enum e) { - TypeDeclaration newType = new TypeDeclaration (); - AddAttributeSection (newType, e); + var newType = new TypeDeclaration(); newType.ClassType = ClassType.Enum; - var location = LocationsBag.GetMemberLocation (e); + AddAttributeSection(newType, e); + var location = LocationsBag.GetMemberLocation(e); - AddModifiers (newType, location); + AddModifiers(newType, location); int curLoc = 0; - if (location != null) - newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++]), "enum".Length), TypeDeclaration.Roles.Keyword); - newType.AddChild (Identifier.Create (e.MemberName.Name, Convert (e.MemberName.Location)), AstNode.Roles.Identifier); + if (location != null && location.Count > 0) + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.EnumKeyword); + newType.AddChild (Identifier.Create (e.MemberName.Name, Convert (e.MemberName.Location)), Roles.Identifier); if (e.BaseTypeExpression != null) { if (location != null && curLoc < location.Count) - newType.AddChild (new CSharpTokenNode (Convert (location[curLoc++]), 1), AstNode.Roles.Colon); - newType.AddChild (ConvertToType (e.BaseTypeExpression), TypeDeclaration.BaseTypeRole); + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.Colon); + newType.AddChild (ConvertToType (e.BaseTypeExpression), Roles.BaseType); } if (location != null && curLoc < location.Count) - newType.AddChild (new CSharpTokenNode (Convert (location[curLoc++]), 1), AstNode.Roles.LBrace); + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.LBrace); typeStack.Push (newType); - foreach (EnumMember member in e.OrderedAllMembers) { + foreach (EnumMember member in e.Members) { Visit (member); if (location != null && curLoc < location.Count - 1) //last one is closing brace - newType.AddChild (new CSharpTokenNode (Convert (location[curLoc++]), 1), AstNode.Roles.Comma); + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.Comma); } if (location != null && location.Count > 2) { if (location != null && curLoc < location.Count) - newType.AddChild (new CSharpTokenNode (Convert (location[curLoc++]), 1), AstNode.Roles.RBrace); - - if (e.HasOptionalSemicolon) - newType.AddChild (new CSharpTokenNode (Convert (e.OptionalSemicolon), 1), AstNode.Roles.Semicolon); + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.RBrace); + if (location != null && curLoc < location.Count) + newType.AddChild (new CSharpTokenNode (Convert (location [curLoc++])), Roles.Semicolon); } else { // parser error, set end node to max value. - newType.AddChild (new ErrorNode (), AstNode.Roles.Error); + newType.AddChild (new ErrorNode (), Roles.Error); } typeStack.Pop (); AddType (newType); @@ -620,14 +716,14 @@ namespace ICSharpCode.NRefactory.CSharp { EnumMemberDeclaration newField = new EnumMemberDeclaration (); AddAttributeSection (newField, em); - newField.AddChild (Identifier.Create (em.Name, Convert (em.Location)), AstNode.Roles.Identifier); + newField.AddChild (Identifier.Create (em.Name, Convert (em.Location)), Roles.Identifier); if (em.Initializer != null) { - newField.AddChild (new CSharpTokenNode (Convert (em.Initializer.Location), 1), EnumMemberDeclaration.Roles.Assign); + newField.AddChild (new CSharpTokenNode (Convert (em.Initializer.Location)), Roles.Assign); newField.AddChild ((Expression)em.Initializer.Accept (this), EnumMemberDeclaration.InitializerRole); } //Console.WriteLine (newField.StartLocation +"-" + newField.EndLocation); - typeStack.Peek ().AddChild (newField, TypeDeclaration.MemberRole); + typeStack.Peek ().AddChild (newField, Roles.TypeMemberRole); } #endregion @@ -641,20 +737,22 @@ namespace ICSharpCode.NRefactory.CSharp var newField = new FixedFieldDeclaration (); AddAttributeSection (newField, f); AddModifiers (newField, location); - if (location != null) - newField.AddChild (new CSharpTokenNode (Convert (location [0]), "fixed".Length), FixedFieldDeclaration.Roles.Keyword); - newField.AddChild (ConvertToType (f.TypeExpression), FixedFieldDeclaration.Roles.Type); + if (location != null && location.Count > 0) + newField.AddChild (new CSharpTokenNode (Convert (location [0])), FixedFieldDeclaration.FixedKeywordRole); + + if (f.TypeExpression != null) + newField.AddChild (ConvertToType (f.TypeExpression), Roles.Type); var variable = new FixedVariableInitializer (); - variable.AddChild (Identifier.Create (f.MemberName.Name, Convert (f.MemberName.Location)), FixedFieldDeclaration.Roles.Identifier); - if (!f.Initializer.IsNull) { + variable.AddChild (Identifier.Create (f.MemberName.Name, Convert (f.MemberName.Location)), Roles.Identifier); + if (f.Initializer != null && !f.Initializer.IsNull) { var bracketLocations = LocationsBag.GetLocations (f.Initializer); if (bracketLocations != null && bracketLocations.Count > 1) - variable.AddChild (new CSharpTokenNode (Convert (bracketLocations [0]), 1), FixedFieldDeclaration.Roles.LBracket); + variable.AddChild (new CSharpTokenNode (Convert (bracketLocations [0])), Roles.LBracket); - variable.AddChild ((Expression)f.Initializer.Accept (this), FieldDeclaration.Roles.Expression); + variable.AddChild ((Expression)f.Initializer.Accept (this), Roles.Expression); if (bracketLocations != null && bracketLocations.Count > 1) - variable.AddChild (new CSharpTokenNode (Convert (bracketLocations [0]), 1), FixedFieldDeclaration.Roles.RBracket); + variable.AddChild (new CSharpTokenNode (Convert (bracketLocations [0])), Roles.RBracket); } newField.AddChild (variable, FixedFieldDeclaration.VariableRole); @@ -662,65 +760,65 @@ namespace ICSharpCode.NRefactory.CSharp foreach (var decl in f.Declarators) { var declLoc = LocationsBag.GetLocations (decl); if (declLoc != null) - newField.AddChild (new CSharpTokenNode (Convert (declLoc [0]), 1), FieldDeclaration.Roles.Comma); + newField.AddChild (new CSharpTokenNode (Convert (declLoc [0])), Roles.Comma); variable = new FixedVariableInitializer (); - variable.AddChild (Identifier.Create (decl.Name.Value, Convert (decl.Name.Location)), FieldDeclaration.Roles.Identifier); + variable.AddChild (Identifier.Create (decl.Name.Value, Convert (decl.Name.Location)), Roles.Identifier); if (!decl.Initializer.IsNull) { var bracketLocations = LocationsBag.GetLocations (f.Initializer); if (bracketLocations != null && bracketLocations.Count > 1) - variable.AddChild (new CSharpTokenNode (Convert (bracketLocations [0]), 1), FixedFieldDeclaration.Roles.LBracket); - variable.AddChild ((Expression)decl.Initializer.Accept (this), FieldDeclaration.Roles.Expression); + variable.AddChild (new CSharpTokenNode (Convert (bracketLocations [0])), Roles.LBracket); + variable.AddChild ((Expression)decl.Initializer.Accept (this), Roles.Expression); if (bracketLocations != null && bracketLocations.Count > 1) - variable.AddChild (new CSharpTokenNode (Convert (bracketLocations [0]), 1), FixedFieldDeclaration.Roles.RBracket); + variable.AddChild (new CSharpTokenNode (Convert (bracketLocations [0])), Roles.RBracket); } newField.AddChild (variable, FixedFieldDeclaration.VariableRole); } } if (location != null) - newField.AddChild (new CSharpTokenNode (Convert (location[1]), 1), FieldDeclaration.Roles.Semicolon); - typeStack.Peek ().AddChild (newField, TypeDeclaration.MemberRole); + newField.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.Semicolon); + typeStack.Peek ().AddChild (newField, Roles.TypeMemberRole); } - public override void Visit (Field f) + public override void Visit(Field f) { - var location = LocationsBag.GetMemberLocation (f); + var location = LocationsBag.GetMemberLocation(f); FieldDeclaration newField = new FieldDeclaration (); AddAttributeSection (newField, f); AddModifiers (newField, location); - newField.AddChild (ConvertToType (f.TypeExpression), FieldDeclaration.Roles.Type); + newField.AddChild (ConvertToType (f.TypeExpression), Roles.Type); VariableInitializer variable = new VariableInitializer (); - variable.AddChild (Identifier.Create (f.MemberName.Name, Convert (f.MemberName.Location)), FieldDeclaration.Roles.Identifier); + variable.AddChild (Identifier.Create (f.MemberName.Name, Convert (f.MemberName.Location)), Roles.Identifier); if (f.Initializer != null) { if (location != null) - variable.AddChild (new CSharpTokenNode (Convert (location[0]), 1), FieldDeclaration.Roles.Assign); - variable.AddChild ((Expression)f.Initializer.Accept (this), VariableInitializer.Roles.Expression); + variable.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.Assign); + variable.AddChild ((Expression)f.Initializer.Accept (this), Roles.Expression); } - newField.AddChild (variable, FieldDeclaration.Roles.Variable); + newField.AddChild (variable, Roles.Variable); if (f.Declarators != null) { foreach (var decl in f.Declarators) { var declLoc = LocationsBag.GetLocations (decl); if (declLoc != null) - newField.AddChild (new CSharpTokenNode (Convert (declLoc [0]), 1), FieldDeclaration.Roles.Comma); + newField.AddChild (new CSharpTokenNode (Convert (declLoc [0])), Roles.Comma); variable = new VariableInitializer (); - variable.AddChild (Identifier.Create (decl.Name.Value, Convert (decl.Name.Location)), VariableInitializer.Roles.Identifier); + variable.AddChild (Identifier.Create (decl.Name.Value, Convert (decl.Name.Location)), Roles.Identifier); if (decl.Initializer != null) { if (declLoc != null) - variable.AddChild (new CSharpTokenNode (Convert (declLoc [1]), 1), FieldDeclaration.Roles.Assign); - variable.AddChild ((Expression)decl.Initializer.Accept (this), VariableInitializer.Roles.Expression); + variable.AddChild (new CSharpTokenNode (Convert (declLoc [1])), Roles.Assign); + variable.AddChild ((Expression)decl.Initializer.Accept (this), Roles.Expression); } - newField.AddChild (variable, FieldDeclaration.Roles.Variable); + newField.AddChild (variable, Roles.Variable); } } if (location != null) - newField.AddChild (new CSharpTokenNode (Convert (location[location.Count - 1]), 1), FieldDeclaration.Roles.Semicolon); + newField.AddChild (new CSharpTokenNode (Convert (location [location.Count - 1])), Roles.Semicolon); - typeStack.Peek ().AddChild (newField, TypeDeclaration.MemberRole); + typeStack.Peek ().AddChild (newField, Roles.TypeMemberRole); } public override void Visit (Const f) @@ -731,36 +829,36 @@ namespace ICSharpCode.NRefactory.CSharp AddAttributeSection (newField, f); AddModifiers (newField, location); if (location != null) - newField.AddChild (new CSharpModifierToken (Convert (location [0]), Modifiers.Const), AttributedNode.ModifierRole); - newField.AddChild (ConvertToType (f.TypeExpression), FieldDeclaration.Roles.Type); + newField.AddChild (new CSharpModifierToken (Convert (location [0]), Modifiers.Const), EntityDeclaration.ModifierRole); + newField.AddChild (ConvertToType (f.TypeExpression), Roles.Type); VariableInitializer variable = new VariableInitializer (); - variable.AddChild (Identifier.Create (f.MemberName.Name, Convert (f.MemberName.Location)), VariableInitializer.Roles.Identifier); + variable.AddChild (Identifier.Create (f.MemberName.Name, Convert (f.MemberName.Location)), Roles.Identifier); if (f.Initializer != null) { - variable.AddChild (new CSharpTokenNode (Convert (f.Initializer.Location), 1), VariableInitializer.Roles.Assign); - variable.AddChild ((Expression)f.Initializer.Accept (this), VariableInitializer.Roles.Expression); + variable.AddChild (new CSharpTokenNode (Convert (f.Initializer.Location)), Roles.Assign); + variable.AddChild ((Expression)f.Initializer.Accept (this), Roles.Expression); } - newField.AddChild (variable, FieldDeclaration.Roles.Variable); + newField.AddChild (variable, Roles.Variable); if (f.Declarators != null) { foreach (var decl in f.Declarators) { var declLoc = LocationsBag.GetLocations (decl); if (declLoc != null) - newField.AddChild (new CSharpTokenNode (Convert (declLoc[0]), 1), FieldDeclaration.Roles.Comma); + newField.AddChild (new CSharpTokenNode (Convert (declLoc [0])), Roles.Comma); variable = new VariableInitializer (); - variable.AddChild (Identifier.Create (decl.Name.Value, Convert (decl.Name.Location)), FieldDeclaration.Roles.Identifier); + variable.AddChild (Identifier.Create (decl.Name.Value, Convert (decl.Name.Location)), Roles.Identifier); if (decl.Initializer != null) { - variable.AddChild (new CSharpTokenNode (Convert (decl.Initializer.Location), 1), FieldDeclaration.Roles.Assign); - variable.AddChild ((Expression)decl.Initializer.Accept (this), VariableInitializer.Roles.Expression); + variable.AddChild (new CSharpTokenNode (Convert (decl.Initializer.Location)), Roles.Assign); + variable.AddChild ((Expression)decl.Initializer.Accept (this), Roles.Expression); } - newField.AddChild (variable, FieldDeclaration.Roles.Variable); + newField.AddChild (variable, Roles.Variable); } } if (location != null) - newField.AddChild (new CSharpTokenNode (Convert (location[1]), 1), FieldDeclaration.Roles.Semicolon); + newField.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.Semicolon); - typeStack.Peek ().AddChild (newField, TypeDeclaration.MemberRole); + typeStack.Peek ().AddChild (newField, Roles.TypeMemberRole); } @@ -776,40 +874,41 @@ namespace ICSharpCode.NRefactory.CSharp if (o.OperatorType == Operator.OpType.Implicit) { - if (location != null) { - newOperator.AddChild (new CSharpTokenNode (Convert (location[0]), "implicit".Length), OperatorDeclaration.OperatorTypeRole); - newOperator.AddChild (new CSharpTokenNode (Convert (location[1]), "operator".Length), OperatorDeclaration.OperatorKeywordRole); + if (location != null && location.Count > 0) { + newOperator.AddChild (new CSharpTokenNode (Convert (location [0])), OperatorDeclaration.ImplicitRole); + if (location.Count > 1) + newOperator.AddChild (new CSharpTokenNode (Convert (location [1])), OperatorDeclaration.OperatorKeywordRole); } - newOperator.AddChild (ConvertToType (o.TypeExpression), AstNode.Roles.Type); + newOperator.AddChild (ConvertToType (o.TypeExpression), Roles.Type); } else if (o.OperatorType == Operator.OpType.Explicit) { - if (location != null) { - newOperator.AddChild (new CSharpTokenNode (Convert (location[0]), "explicit".Length), OperatorDeclaration.OperatorTypeRole); - newOperator.AddChild (new CSharpTokenNode (Convert (location[1]), "operator".Length), OperatorDeclaration.OperatorKeywordRole); + if (location != null && location.Count > 0) { + newOperator.AddChild (new CSharpTokenNode (Convert (location [0])), OperatorDeclaration.ExplicitRole); + if (location.Count > 1) + newOperator.AddChild (new CSharpTokenNode (Convert (location [1])), OperatorDeclaration.OperatorKeywordRole); } - newOperator.AddChild (ConvertToType (o.TypeExpression), AstNode.Roles.Type); + newOperator.AddChild (ConvertToType (o.TypeExpression), Roles.Type); } else { - newOperator.AddChild (ConvertToType (o.TypeExpression), AstNode.Roles.Type); - - if (location != null) - newOperator.AddChild (new CSharpTokenNode (Convert (location[0]), "operator".Length), OperatorDeclaration.OperatorKeywordRole); + newOperator.AddChild (ConvertToType (o.TypeExpression), Roles.Type); + + if (location != null && location.Count > 0) + newOperator.AddChild (new CSharpTokenNode (Convert (location [0])), OperatorDeclaration.OperatorKeywordRole); - int opLength = OperatorDeclaration.GetToken(newOperator.OperatorType).Length; - if (location != null) - newOperator.AddChild (new CSharpTokenNode (Convert (location[1]), opLength), OperatorDeclaration.OperatorTypeRole); + if (location != null && location.Count > 1) + newOperator.AddChild (new CSharpTokenNode (Convert (location [1])), OperatorDeclaration.GetRole (newOperator.OperatorType)); } - if (location != null) - newOperator.AddChild (new CSharpTokenNode (Convert (location[2]), 1), OperatorDeclaration.Roles.LPar); + if (location != null && location.Count > 2) + newOperator.AddChild (new CSharpTokenNode (Convert (location [2])), Roles.LPar); AddParameter (newOperator, o.ParameterInfo); - if (location != null) - newOperator.AddChild (new CSharpTokenNode (Convert (location[3]), 1), OperatorDeclaration.Roles.RPar); + if (location != null && location.Count > 3) + newOperator.AddChild (new CSharpTokenNode (Convert (location [3])), Roles.RPar); if (o.Block != null) { - newOperator.AddChild ((BlockStatement)o.Block.Accept (this), OperatorDeclaration.Roles.Body); + newOperator.AddChild ((BlockStatement)o.Block.Accept (this), Roles.Body); } else { if (location != null && location.Count >= 5) - newOperator.AddChild (new CSharpTokenNode (Convert (location[4]), 1), MethodDeclaration.Roles.Semicolon); + newOperator.AddChild (new CSharpTokenNode (Convert (location [4])), Roles.Semicolon); } - typeStack.Peek ().AddChild (newOperator, TypeDeclaration.MemberRole); + typeStack.Peek ().AddChild (newOperator, Roles.TypeMemberRole); } public void AddAttributeSection (AstNode parent, Attributable a) @@ -819,14 +918,19 @@ namespace ICSharpCode.NRefactory.CSharp AddAttributeSection (parent, a.OptAttributes); } - public void AddAttributeSection (AstNode parent, Attributes attrs) + public void AddAttributeSection (AstNode parent, Attributes attrs, Role role) { if (attrs == null) return; foreach (var attr in attrs.Sections) { - parent.AddChild (ConvertAttributeSection (attr), AttributedNode.AttributeRole); + parent.AddChild (ConvertAttributeSection (attr), EntityDeclaration.AttributeRole); } } + + public void AddAttributeSection (AstNode parent, Attributes attrs) + { + AddAttributeSection (parent, attrs, EntityDeclaration.AttributeRole); + } public override void Visit (Indexer indexer) { @@ -834,31 +938,31 @@ namespace ICSharpCode.NRefactory.CSharp AddAttributeSection (newIndexer, indexer); var location = LocationsBag.GetMemberLocation (indexer); AddModifiers (newIndexer, location); - newIndexer.AddChild (ConvertToType (indexer.TypeExpression), IndexerDeclaration.Roles.Type); + newIndexer.AddChild (ConvertToType (indexer.TypeExpression), Roles.Type); AddExplicitInterface (newIndexer, indexer.MemberName); var name = indexer.MemberName; - newIndexer.AddChild (Identifier.Create ("this", Convert (name.Location)), IndexerDeclaration.Roles.Identifier); + newIndexer.AddChild (Identifier.Create ("this", Convert (name.Location)), Roles.Identifier); - if (location != null) - newIndexer.AddChild (new CSharpTokenNode (Convert (location [0]), 1), IndexerDeclaration.Roles.LBracket); + if (location != null && location.Count > 0) + newIndexer.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LBracket); AddParameter (newIndexer, indexer.ParameterInfo); - if (location != null) - newIndexer.AddChild (new CSharpTokenNode (Convert (location[1]), 1), IndexerDeclaration.Roles.RBracket); + if (location != null && location.Count > 1) + newIndexer.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RBracket); - if (location != null) - newIndexer.AddChild (new CSharpTokenNode (Convert (location[2]), 1), IndexerDeclaration.Roles.LBrace); + if (location != null && location.Count > 2) + newIndexer.AddChild (new CSharpTokenNode (Convert (location [2])), Roles.LBrace); if (indexer.Get != null) { Accessor getAccessor = new Accessor (); var getLocation = LocationsBag.GetMemberLocation (indexer.Get); AddAttributeSection (getAccessor, indexer.Get); AddModifiers (getAccessor, getLocation); if (getLocation != null) - getAccessor.AddChild (new CSharpTokenNode (Convert (indexer.Get.Location), "get".Length), PropertyDeclaration.Roles.Keyword); + getAccessor.AddChild (new CSharpTokenNode (Convert (indexer.Get.Location)), PropertyDeclaration.GetKeywordRole); if (indexer.Get.Block != null) { - getAccessor.AddChild ((BlockStatement)indexer.Get.Block.Accept (this), MethodDeclaration.Roles.Body); + getAccessor.AddChild ((BlockStatement)indexer.Get.Block.Accept (this), Roles.Body); } else { if (getLocation != null && getLocation.Count > 0) - newIndexer.AddChild (new CSharpTokenNode (Convert (getLocation[0]), 1), MethodDeclaration.Roles.Semicolon); + newIndexer.AddChild (new CSharpTokenNode (Convert (getLocation [0])), Roles.Semicolon); } newIndexer.AddChild (getAccessor, PropertyDeclaration.GetterRole); } @@ -869,24 +973,25 @@ namespace ICSharpCode.NRefactory.CSharp AddAttributeSection (setAccessor, indexer.Set); AddModifiers (setAccessor, setLocation); if (setLocation != null) - setAccessor.AddChild (new CSharpTokenNode (Convert (indexer.Set.Location), "set".Length), PropertyDeclaration.Roles.Keyword); + setAccessor.AddChild (new CSharpTokenNode (Convert (indexer.Set.Location)), PropertyDeclaration.SetKeywordRole); if (indexer.Set.Block != null) { - setAccessor.AddChild ((BlockStatement)indexer.Set.Block.Accept (this), MethodDeclaration.Roles.Body); + setAccessor.AddChild ((BlockStatement)indexer.Set.Block.Accept (this), Roles.Body); } else { if (setLocation != null && setLocation.Count > 0) - newIndexer.AddChild (new CSharpTokenNode (Convert (setLocation[0]), 1), MethodDeclaration.Roles.Semicolon); + newIndexer.AddChild (new CSharpTokenNode (Convert (setLocation [0])), Roles.Semicolon); } newIndexer.AddChild (setAccessor, PropertyDeclaration.SetterRole); } if (location != null) { - newIndexer.AddChild (new CSharpTokenNode (Convert (location[3]), 1), IndexerDeclaration.Roles.RBrace); + if (location.Count > 3) + newIndexer.AddChild (new CSharpTokenNode (Convert (location [3])), Roles.RBrace); } else { // parser error, set end node to max value. - newIndexer.AddChild (new ErrorNode (), AstNode.Roles.Error); + newIndexer.AddChild (new ErrorNode (), Roles.Error); } - typeStack.Peek ().AddChild (newIndexer, TypeDeclaration.MemberRole); + typeStack.Peek ().AddChild (newIndexer, Roles.TypeMemberRole); } public override void Visit (Method m) @@ -895,37 +1000,37 @@ namespace ICSharpCode.NRefactory.CSharp AddAttributeSection (newMethod, m); var location = LocationsBag.GetMemberLocation (m); AddModifiers (newMethod, location); - newMethod.AddChild (ConvertToType (m.TypeExpression), AstNode.Roles.Type); + newMethod.AddChild (ConvertToType (m.TypeExpression), Roles.Type); AddExplicitInterface (newMethod, m.MethodName); - newMethod.AddChild (Identifier.Create (m.MethodName.Name, Convert (m.Location)), AstNode.Roles.Identifier); + newMethod.AddChild (Identifier.Create (m.MethodName.Name, Convert (m.Location)), Roles.Identifier); AddTypeParameters (newMethod, m.MemberName); - if (location != null) - newMethod.AddChild (new CSharpTokenNode (Convert (location[0]), 1), MethodDeclaration.Roles.LPar); + if (location != null && location.Count > 0) + newMethod.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); AddParameter (newMethod, m.ParameterInfo); - if (location != null) - newMethod.AddChild (new CSharpTokenNode (Convert (location[1]), 1), MethodDeclaration.Roles.RPar); + if (location != null && location.Count > 1) + newMethod.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); AddConstraints (newMethod, m.CurrentTypeParameters); if (m.Block != null) { var bodyBlock = (BlockStatement)m.Block.Accept (this); // if (m.Block is ToplevelBlock) { -// newMethod.AddChild (bodyBlock.FirstChild.NextSibling, MethodDeclaration.Roles.Body); +// newMethod.AddChild (bodyBlock.FirstChild.NextSibling, Roles.Body); // } else { - newMethod.AddChild (bodyBlock, MethodDeclaration.Roles.Body); + newMethod.AddChild (bodyBlock, Roles.Body); // } } else if (location != null) { if (location.Count < 3) { // parser error, set end node to max value. - newMethod.AddChild (new ErrorNode (), AstNode.Roles.Error); + newMethod.AddChild (new ErrorNode (), Roles.Error); } else { - newMethod.AddChild (new CSharpTokenNode (Convert (location[2]), 1), MethodDeclaration.Roles.Semicolon); + newMethod.AddChild (new CSharpTokenNode (Convert (location [2])), Roles.Semicolon); } } - typeStack.Peek ().AddChild (newMethod, TypeDeclaration.MemberRole); + typeStack.Peek ().AddChild (newMethod, Roles.TypeMemberRole); } static Dictionary modifierTable = new Dictionary (); @@ -969,19 +1074,20 @@ namespace ICSharpCode.NRefactory.CSharp keywordTable [(int)BuiltinTypeSpec.Type.SByte] = "sbyte"; keywordTable [(int)BuiltinTypeSpec.Type.Decimal] = "decimal"; keywordTable [(int)BuiltinTypeSpec.Type.Char] = "char"; + keywordTable [(int)BuiltinTypeSpec.Type.Bool] = "bool"; } - void AddModifiers (AttributedNode parent, LocationsBag.MemberLocations location) + void AddModifiers (EntityDeclaration parent, LocationsBag.MemberLocations location) { if (location == null || location.Modifiers == null) return; foreach (var modifier in location.Modifiers) { ICSharpCode.NRefactory.CSharp.Modifiers mod; if (!modifierTable.TryGetValue (modifier.Item1, out mod)) { - Console.WriteLine ("modifier "+ modifier.Item1 + " can't be converted,"); + Console.WriteLine ("modifier " + modifier.Item1 + " can't be converted,"); } - parent.AddChild (new CSharpModifierToken (Convert (modifier.Item2), mod), AttributedNode.ModifierRole); + parent.AddChild (new CSharpModifierToken (Convert (modifier.Item2), mod), EntityDeclaration.ModifierRole); } } @@ -991,12 +1097,12 @@ namespace ICSharpCode.NRefactory.CSharp AddAttributeSection (newProperty, p); var location = LocationsBag.GetMemberLocation (p); AddModifiers (newProperty, location); - newProperty.AddChild (ConvertToType (p.TypeExpression), AstNode.Roles.Type); + newProperty.AddChild (ConvertToType (p.TypeExpression), Roles.Type); AddExplicitInterface (newProperty, p.MemberName); - newProperty.AddChild (Identifier.Create (p.MemberName.Name, Convert (p.Location)), PropertyDeclaration.Roles.Identifier); + newProperty.AddChild (Identifier.Create (p.MemberName.Name, Convert (p.Location)), Roles.Identifier); - if (location != null) - newProperty.AddChild (new CSharpTokenNode (Convert (location[0]), 1), MethodDeclaration.Roles.LBrace); + if (location != null && location.Count > 0) + newProperty.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LBrace); Accessor getAccessor = null; if (p.Get != null) { @@ -1004,13 +1110,13 @@ namespace ICSharpCode.NRefactory.CSharp AddAttributeSection (getAccessor, p.Get); var getLocation = LocationsBag.GetMemberLocation (p.Get); AddModifiers (getAccessor, getLocation); - getAccessor.AddChild (new CSharpTokenNode (Convert (p.Get.Location), "get".Length), PropertyDeclaration.Roles.Keyword); + getAccessor.AddChild (new CSharpTokenNode (Convert (p.Get.Location)), PropertyDeclaration.GetKeywordRole); if (p.Get.Block != null) { - getAccessor.AddChild ((BlockStatement)p.Get.Block.Accept (this), MethodDeclaration.Roles.Body); + getAccessor.AddChild ((BlockStatement)p.Get.Block.Accept (this), Roles.Body); } else { if (getLocation != null && getLocation.Count > 0) - getAccessor.AddChild (new CSharpTokenNode (Convert (getLocation[0]), 1), MethodDeclaration.Roles.Semicolon); + getAccessor.AddChild (new CSharpTokenNode (Convert (getLocation [0])), Roles.Semicolon); } } @@ -1020,13 +1126,13 @@ namespace ICSharpCode.NRefactory.CSharp AddAttributeSection (setAccessor, p.Set); var setLocation = LocationsBag.GetMemberLocation (p.Set); AddModifiers (setAccessor, setLocation); - setAccessor.AddChild (new CSharpTokenNode (Convert (p.Set.Location), "set".Length), PropertyDeclaration.Roles.Keyword); + setAccessor.AddChild (new CSharpTokenNode (Convert (p.Set.Location)), PropertyDeclaration.SetKeywordRole); if (p.Set.Block != null) { - setAccessor.AddChild ((BlockStatement)p.Set.Block.Accept (this), MethodDeclaration.Roles.Body); + setAccessor.AddChild ((BlockStatement)p.Set.Block.Accept (this), Roles.Body); } else { if (setLocation != null && setLocation.Count > 0) - setAccessor.AddChild (new CSharpTokenNode (Convert (setLocation[0]), 1), MethodDeclaration.Roles.Semicolon); + setAccessor.AddChild (new CSharpTokenNode (Convert (setLocation [0])), Roles.Semicolon); } } if (getAccessor != null && setAccessor != null) { @@ -1045,13 +1151,13 @@ namespace ICSharpCode.NRefactory.CSharp } if (location != null && location.Count > 1) { - newProperty.AddChild (new CSharpTokenNode (Convert (location[1]), 1), MethodDeclaration.Roles.RBrace); + newProperty.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RBrace); } else { // parser error, set end node to max value. - newProperty.AddChild (new ErrorNode (), AstNode.Roles.Error); + newProperty.AddChild (new ErrorNode (), Roles.Error); } - typeStack.Peek ().AddChild (newProperty, TypeDeclaration.MemberRole); + typeStack.Peek ().AddChild (newProperty, Roles.TypeMemberRole); } public override void Visit (Constructor c) @@ -1060,13 +1166,13 @@ namespace ICSharpCode.NRefactory.CSharp AddAttributeSection (newConstructor, c); var location = LocationsBag.GetMemberLocation (c); AddModifiers (newConstructor, location); - newConstructor.AddChild (Identifier.Create (c.MemberName.Name, Convert (c.MemberName.Location)), AstNode.Roles.Identifier); - if (location != null) - newConstructor.AddChild (new CSharpTokenNode (Convert (location[0]), 1), MethodDeclaration.Roles.LPar); + newConstructor.AddChild (Identifier.Create (c.MemberName.Name, Convert (c.MemberName.Location)), Roles.Identifier); + if (location != null && location.Count > 0) + newConstructor.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); AddParameter (newConstructor, c.ParameterInfo); - if (location != null) - newConstructor.AddChild (new CSharpTokenNode (Convert (location[1]), 1), MethodDeclaration.Roles.RPar); + if (location != null && location.Count > 1) + newConstructor.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); if (c.Initializer != null) { var initializer = new ConstructorInitializer (); @@ -1074,22 +1180,21 @@ namespace ICSharpCode.NRefactory.CSharp var initializerLocation = LocationsBag.GetLocations (c.Initializer); if (initializerLocation != null) - newConstructor.AddChild (new CSharpTokenNode (Convert (initializerLocation[0]), 1), ConstructorDeclaration.Roles.Colon); + newConstructor.AddChild (new CSharpTokenNode (Convert (initializerLocation [0])), Roles.Colon); if (initializerLocation != null && initializerLocation.Count > 1) { // this and base has the same length - initializer.AddChild (new CSharpTokenNode (Convert (c.Initializer.Location), "this".Length), ConstructorDeclaration.Roles.Keyword); - initializer.AddChild (new CSharpTokenNode (Convert (initializerLocation[1]), 1), ConstructorDeclaration.Roles.LPar); + initializer.AddChild (new CSharpTokenNode (Convert (c.Initializer.Location)), initializer.ConstructorInitializerType == ConstructorInitializerType.This ? ConstructorInitializer.ThisKeywordRole : ConstructorInitializer.BaseKeywordRole); + initializer.AddChild (new CSharpTokenNode (Convert (initializerLocation [1])), Roles.LPar); AddArguments (initializer, LocationsBag.GetLocations (c.Initializer.Arguments), c.Initializer.Arguments); - initializer.AddChild (new CSharpTokenNode (Convert (initializerLocation[2]), 1), ConstructorDeclaration.Roles.RPar); + initializer.AddChild (new CSharpTokenNode (Convert (initializerLocation [2])), Roles.RPar); newConstructor.AddChild (initializer, ConstructorDeclaration.InitializerRole); } } if (c.Block != null) - newConstructor.AddChild ((BlockStatement)c.Block.Accept (this), ConstructorDeclaration.Roles.Body); - - typeStack.Peek ().AddChild (newConstructor, TypeDeclaration.MemberRole); + newConstructor.AddChild ((BlockStatement)c.Block.Accept (this), Roles.Body); + typeStack.Peek ().AddChild (newConstructor, Roles.TypeMemberRole); } public override void Visit (Destructor d) @@ -1098,19 +1203,21 @@ namespace ICSharpCode.NRefactory.CSharp AddAttributeSection (newDestructor, d); var location = LocationsBag.GetMemberLocation (d); AddModifiers (newDestructor, location); - if (location != null) - newDestructor.AddChild (new CSharpTokenNode (Convert (location[0]), 1), DestructorDeclaration.TildeRole); - newDestructor.AddChild (Identifier.Create (d.MemberName.Name, Convert (d.MemberName.Location)), AstNode.Roles.Identifier); + if (location != null && location.Count > 0) + newDestructor.AddChild (new CSharpTokenNode (Convert (location [0])), DestructorDeclaration.TildeRole); + newDestructor.AddChild (Identifier.Create (d.Identifier, Convert (d.MemberName.Location)), Roles.Identifier); - if (location != null) { - newDestructor.AddChild (new CSharpTokenNode (Convert (location[1]), 1), DestructorDeclaration.Roles.LPar); - newDestructor.AddChild (new CSharpTokenNode (Convert (location[2]), 1), DestructorDeclaration.Roles.RPar); + if (location != null && location.Count > 1) { + newDestructor.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.LPar); + + if (location.Count > 2) + newDestructor.AddChild (new CSharpTokenNode (Convert (location [2])), Roles.RPar); } if (d.Block != null) - newDestructor.AddChild ((BlockStatement)d.Block.Accept (this), DestructorDeclaration.Roles.Body); + newDestructor.AddChild ((BlockStatement)d.Block.Accept (this), Roles.Body); - typeStack.Peek ().AddChild (newDestructor, TypeDeclaration.MemberRole); + typeStack.Peek ().AddChild (newDestructor, Roles.TypeMemberRole); } public override void Visit (EventField e) @@ -1120,52 +1227,52 @@ namespace ICSharpCode.NRefactory.CSharp var location = LocationsBag.GetMemberLocation (e); AddModifiers (newEvent, location); - if (location != null) - newEvent.AddChild (new CSharpTokenNode (Convert (location[0]), "event".Length), EventDeclaration.Roles.Keyword); - newEvent.AddChild (ConvertToType (e.TypeExpression), AstNode.Roles.Type); + if (location != null && location.Count > 0) + newEvent.AddChild (new CSharpTokenNode (Convert (location [0])), EventDeclaration.EventKeywordRole); + newEvent.AddChild (ConvertToType (e.TypeExpression), Roles.Type); VariableInitializer variable = new VariableInitializer (); - variable.AddChild (Identifier.Create (e.MemberName.Name, Convert (e.MemberName.Location)), FieldDeclaration.Roles.Identifier); + variable.AddChild (Identifier.Create (e.MemberName.Name, Convert (e.MemberName.Location)), Roles.Identifier); if (e.Initializer != null) { - if (location != null) - variable.AddChild (new CSharpTokenNode (Convert (location[0]), 1), FieldDeclaration.Roles.Assign); - variable.AddChild ((Expression)e.Initializer.Accept (this), VariableInitializer.Roles.Expression); + if (location != null && location.Count > 0) + variable.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.Assign); + variable.AddChild ((Expression)e.Initializer.Accept (this), Roles.Expression); } - newEvent.AddChild (variable, FieldDeclaration.Roles.Variable); + newEvent.AddChild (variable, Roles.Variable); if (e.Declarators != null) { foreach (var decl in e.Declarators) { var declLoc = LocationsBag.GetLocations (decl); if (declLoc != null) - newEvent.AddChild (new CSharpTokenNode (Convert (declLoc [0]), 1), FieldDeclaration.Roles.Comma); + newEvent.AddChild (new CSharpTokenNode (Convert (declLoc [0])), Roles.Comma); variable = new VariableInitializer (); - variable.AddChild (Identifier.Create (decl.Name.Value, Convert (decl.Name.Location)), VariableInitializer.Roles.Identifier); + variable.AddChild (Identifier.Create (decl.Name.Value, Convert (decl.Name.Location)), Roles.Identifier); if (decl.Initializer != null) { if (declLoc != null) - variable.AddChild (new CSharpTokenNode (Convert (declLoc [1]), 1), FieldDeclaration.Roles.Assign); - variable.AddChild ((Expression)decl.Initializer.Accept (this), VariableInitializer.Roles.Expression); + variable.AddChild (new CSharpTokenNode (Convert (declLoc [1])), Roles.Assign); + variable.AddChild ((Expression)decl.Initializer.Accept (this), Roles.Expression); } - newEvent.AddChild (variable, FieldDeclaration.Roles.Variable); + newEvent.AddChild (variable, Roles.Variable); } } - if (location != null) - newEvent.AddChild (new CSharpTokenNode (Convert (location[1]), ";".Length), EventDeclaration.Roles.Semicolon); + if (location != null && location.Count > 1) + newEvent.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.Semicolon); - typeStack.Peek ().AddChild (newEvent, TypeDeclaration.MemberRole); + typeStack.Peek ().AddChild (newEvent, Roles.TypeMemberRole); } - + void AddExplicitInterface (AstNode parent, MemberName memberName) { if (memberName == null || memberName.ExplicitInterface == null) return; - parent.AddChild (ConvertToType (memberName.ExplicitInterface), MemberDeclaration.PrivateImplementationTypeRole); + parent.AddChild (ConvertToType (memberName.ExplicitInterface), EntityDeclaration.PrivateImplementationTypeRole); var privateImplTypeLoc = LocationsBag.GetLocations (memberName.ExplicitInterface); if (privateImplTypeLoc != null) - parent.AddChild (new CSharpTokenNode (Convert (privateImplTypeLoc[0]), 1), MethodDeclaration.Roles.Dot); + parent.AddChild (new CSharpTokenNode (Convert (privateImplTypeLoc [0])), Roles.Dot); } public override void Visit (EventProperty ep) @@ -1175,25 +1282,25 @@ namespace ICSharpCode.NRefactory.CSharp var location = LocationsBag.GetMemberLocation (ep); AddModifiers (newEvent, location); - if (location != null) - newEvent.AddChild (new CSharpTokenNode (Convert (location[0]), "event".Length), CustomEventDeclaration.Roles.Keyword); - newEvent.AddChild (ConvertToType (ep.TypeExpression), CustomEventDeclaration.Roles.Type); + if (location != null && location.Count > 0) + newEvent.AddChild (new CSharpTokenNode (Convert (location [0])), CustomEventDeclaration.EventKeywordRole); + newEvent.AddChild (ConvertToType (ep.TypeExpression), Roles.Type); AddExplicitInterface (newEvent, ep.MemberName); - newEvent.AddChild (Identifier.Create (ep.MemberName.Name, Convert (ep.Location)), CustomEventDeclaration.Roles.Identifier); + newEvent.AddChild (Identifier.Create (ep.MemberName.Name, Convert (ep.Location)), Roles.Identifier); if (location != null && location.Count >= 2) - newEvent.AddChild (new CSharpTokenNode (Convert (location[1]), 1), CustomEventDeclaration.Roles.LBrace); + newEvent.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.LBrace); if (ep.Add != null) { Accessor addAccessor = new Accessor (); AddAttributeSection (addAccessor, ep.Add); var addLocation = LocationsBag.GetMemberLocation (ep.Add); AddModifiers (addAccessor, addLocation); - addAccessor.AddChild (new CSharpTokenNode (Convert (ep.Add.Location), "add".Length), CustomEventDeclaration.Roles.Keyword); + addAccessor.AddChild (new CSharpTokenNode (Convert (ep.Add.Location)), CustomEventDeclaration.AddKeywordRole); if (ep.Add.Block != null) - addAccessor.AddChild ((BlockStatement)ep.Add.Block.Accept (this), CustomEventDeclaration.Roles.Body); + addAccessor.AddChild ((BlockStatement)ep.Add.Block.Accept (this), Roles.Body); newEvent.AddChild (addAccessor, CustomEventDeclaration.AddAccessorRole); } @@ -1202,20 +1309,20 @@ namespace ICSharpCode.NRefactory.CSharp AddAttributeSection (removeAccessor, ep.Remove); var removeLocation = LocationsBag.GetMemberLocation (ep.Remove); AddModifiers (removeAccessor, removeLocation); - removeAccessor.AddChild (new CSharpTokenNode (Convert (ep.Remove.Location), "remove".Length), CustomEventDeclaration.Roles.Keyword); + removeAccessor.AddChild (new CSharpTokenNode (Convert (ep.Remove.Location)), CustomEventDeclaration.RemoveKeywordRole); if (ep.Remove.Block != null) - removeAccessor.AddChild ((BlockStatement)ep.Remove.Block.Accept (this), CustomEventDeclaration.Roles.Body); + removeAccessor.AddChild ((BlockStatement)ep.Remove.Block.Accept (this), Roles.Body); newEvent.AddChild (removeAccessor, CustomEventDeclaration.RemoveAccessorRole); } if (location != null && location.Count >= 3) { - newEvent.AddChild (new CSharpTokenNode (Convert (location[2]), 1), CustomEventDeclaration.Roles.RBrace); + newEvent.AddChild (new CSharpTokenNode (Convert (location [2])), Roles.RBrace); } else { // parser error, set end node to max value. - newEvent.AddChild (new ErrorNode (), AstNode.Roles.Error); + newEvent.AddChild (new ErrorNode (), Roles.Error); } - typeStack.Peek ().AddChild (newEvent, TypeDeclaration.MemberRole); + typeStack.Peek ().AddChild (newEvent, Roles.TypeMemberRole); } #endregion @@ -1230,37 +1337,37 @@ namespace ICSharpCode.NRefactory.CSharp public override object Visit (BlockVariableDeclaration blockVariableDeclaration) { var result = new VariableDeclarationStatement (); - result.AddChild (ConvertToType (blockVariableDeclaration.TypeExpression), VariableDeclarationStatement.Roles.Type); + result.AddChild (ConvertToType (blockVariableDeclaration.TypeExpression), Roles.Type); var varInit = new VariableInitializer (); var location = LocationsBag.GetLocations (blockVariableDeclaration); - varInit.AddChild (Identifier.Create (blockVariableDeclaration.Variable.Name, Convert (blockVariableDeclaration.Variable.Location)), VariableInitializer.Roles.Identifier); + varInit.AddChild (Identifier.Create (blockVariableDeclaration.Variable.Name, Convert (blockVariableDeclaration.Variable.Location)), Roles.Identifier); if (blockVariableDeclaration.Initializer != null) { - if (location != null) - varInit.AddChild (new CSharpTokenNode (Convert (location[0]), 1), VariableInitializer.Roles.Assign); - varInit.AddChild ((Expression)blockVariableDeclaration.Initializer.Accept (this), VariableInitializer.Roles.Expression); + if (location != null && location.Count > 0) + varInit.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.Assign); + varInit.AddChild ((Expression)blockVariableDeclaration.Initializer.Accept (this), Roles.Expression); } - result.AddChild (varInit, VariableDeclarationStatement.Roles.Variable); + result.AddChild (varInit, Roles.Variable); if (blockVariableDeclaration.Declarators != null) { foreach (var decl in blockVariableDeclaration.Declarators) { var loc = LocationsBag.GetLocations (decl); var init = new VariableInitializer (); if (loc != null && loc.Count > 0) - result.AddChild (new CSharpTokenNode (Convert (loc [0]), 1), VariableInitializer.Roles.Comma); - init.AddChild (Identifier.Create (decl.Variable.Name, Convert (decl.Variable.Location)), VariableInitializer.Roles.Identifier); + result.AddChild (new CSharpTokenNode (Convert (loc [0])), Roles.Comma); + init.AddChild (Identifier.Create (decl.Variable.Name, Convert (decl.Variable.Location)), Roles.Identifier); if (decl.Initializer != null) { if (loc != null && loc.Count > 1) - init.AddChild (new CSharpTokenNode (Convert (loc [1]), 1), VariableInitializer.Roles.Assign); - init.AddChild ((Expression)decl.Initializer.Accept (this), VariableInitializer.Roles.Expression); + init.AddChild (new CSharpTokenNode (Convert (loc [1])), Roles.Assign); + init.AddChild ((Expression)decl.Initializer.Accept (this), Roles.Expression); } else { } - result.AddChild (init, VariableDeclarationStatement.Roles.Variable); + result.AddChild (init, Roles.Variable); } } if (location != null && (blockVariableDeclaration.Initializer == null || location.Count > 1)) - result.AddChild (new CSharpTokenNode (Convert (location[location.Count - 1]), 1), VariableDeclarationStatement.Roles.Semicolon); + result.AddChild (new CSharpTokenNode (Convert (location [location.Count - 1])), Roles.Semicolon); return result; } @@ -1269,44 +1376,44 @@ namespace ICSharpCode.NRefactory.CSharp var result = new VariableDeclarationStatement (); var location = LocationsBag.GetLocations (blockVariableDeclaration); - if (location != null) + if (location != null && location.Count > 0) result.AddChild (new CSharpModifierToken (Convert (location [0]), ICSharpCode.NRefactory.CSharp.Modifiers.Const), VariableDeclarationStatement.ModifierRole); - result.AddChild (ConvertToType (blockVariableDeclaration.TypeExpression), VariableDeclarationStatement.Roles.Type); + result.AddChild (ConvertToType (blockVariableDeclaration.TypeExpression), Roles.Type); var varInit = new VariableInitializer (); - varInit.AddChild (Identifier.Create (blockVariableDeclaration.Variable.Name, Convert (blockVariableDeclaration.Variable.Location)), VariableInitializer.Roles.Identifier); + varInit.AddChild (Identifier.Create (blockVariableDeclaration.Variable.Name, Convert (blockVariableDeclaration.Variable.Location)), Roles.Identifier); if (blockVariableDeclaration.Initializer != null) { - if (location != null) - varInit.AddChild (new CSharpTokenNode (Convert (location[1]), 1), VariableInitializer.Roles.Assign); - varInit.AddChild ((Expression)blockVariableDeclaration.Initializer.Accept (this), VariableInitializer.Roles.Expression); + if (location != null && location.Count > 1) + varInit.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.Assign); + varInit.AddChild ((Expression)blockVariableDeclaration.Initializer.Accept (this), Roles.Expression); } - result.AddChild (varInit, VariableDeclarationStatement.Roles.Variable); + result.AddChild (varInit, Roles.Variable); if (blockVariableDeclaration.Declarators != null) { foreach (var decl in blockVariableDeclaration.Declarators) { var loc = LocationsBag.GetLocations (decl); var init = new VariableInitializer (); - init.AddChild (Identifier.Create (decl.Variable.Name, Convert (decl.Variable.Location)), VariableInitializer.Roles.Identifier); + init.AddChild (Identifier.Create (decl.Variable.Name, Convert (decl.Variable.Location)), Roles.Identifier); if (decl.Initializer != null) { if (loc != null) - init.AddChild (new CSharpTokenNode (Convert (loc[0]), 1), VariableInitializer.Roles.Assign); - init.AddChild ((Expression)decl.Initializer.Accept (this), VariableInitializer.Roles.Expression); + init.AddChild (new CSharpTokenNode (Convert (loc [0])), Roles.Assign); + init.AddChild ((Expression)decl.Initializer.Accept (this), Roles.Expression); if (loc != null && loc.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (loc[1]), 1), VariableInitializer.Roles.Comma); + result.AddChild (new CSharpTokenNode (Convert (loc [1])), Roles.Comma); } else { if (loc != null && loc.Count > 0) - result.AddChild (new CSharpTokenNode (Convert (loc[0]), 1), VariableInitializer.Roles.Comma); + result.AddChild (new CSharpTokenNode (Convert (loc [0])), Roles.Comma); } - result.AddChild (init, VariableDeclarationStatement.Roles.Variable); + result.AddChild (init, Roles.Variable); } } if (location != null) { - result.AddChild (new CSharpTokenNode (Convert (location[location.Count - 1]), 1), VariableDeclarationStatement.Roles.Semicolon); + result.AddChild (new CSharpTokenNode (Convert (location [location.Count - 1])), Roles.Semicolon); } else { // parser error, set end node to max value. - result.AddChild (new ErrorNode (), AstNode.Roles.Error); + result.AddChild (new ErrorNode (), Roles.Error); } return result; } @@ -1339,19 +1446,20 @@ namespace ICSharpCode.NRefactory.CSharp var location = LocationsBag.GetLocations (ifStatement); - result.AddChild (new CSharpTokenNode (Convert (ifStatement.loc), "if".Length), IfElseStatement.IfKeywordRole); + result.AddChild (new CSharpTokenNode (Convert (ifStatement.loc)), IfElseStatement.IfKeywordRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), IfElseStatement.Roles.LPar); - result.AddChild ((Expression)ifStatement.Expr.Accept (this), IfElseStatement.Roles.Condition); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); + if (ifStatement.Expr != null) + result.AddChild ((Expression)ifStatement.Expr.Accept (this), Roles.Condition); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), IfElseStatement.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); if (ifStatement.TrueStatement != null) result.AddChild ((Statement)ifStatement.TrueStatement.Accept (this), IfElseStatement.TrueRole); if (ifStatement.FalseStatement != null) { - if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[2]), "else".Length), IfElseStatement.ElseKeywordRole); + if (location != null && location.Count > 2) + result.AddChild (new CSharpTokenNode (Convert (location [2])), IfElseStatement.ElseKeywordRole); result.AddChild ((Statement)ifStatement.FalseStatement.Accept (this), IfElseStatement.FalseRole); } @@ -1362,17 +1470,19 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new DoWhileStatement (); var location = LocationsBag.GetLocations (doStatement); - result.AddChild (new CSharpTokenNode (Convert (doStatement.loc), "do".Length), DoWhileStatement.DoKeywordRole); - result.AddChild ((Statement)doStatement.EmbeddedStatement.Accept (this), WhileStatement.Roles.EmbeddedStatement); + result.AddChild (new CSharpTokenNode (Convert (doStatement.loc)), DoWhileStatement.DoKeywordRole); + if (doStatement.EmbeddedStatement != null) + result.AddChild ((Statement)doStatement.EmbeddedStatement.Accept (this), Roles.EmbeddedStatement); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), "while".Length), DoWhileStatement.WhileKeywordRole); + result.AddChild (new CSharpTokenNode (Convert (location [0])), DoWhileStatement.WhileKeywordRole); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), DoWhileStatement.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.LPar); if (doStatement.expr != null) - result.AddChild ((Expression)doStatement.expr.Accept (this), DoWhileStatement.Roles.Condition); + result.AddChild ((Expression)doStatement.expr.Accept (this), Roles.Condition); if (location != null && location.Count > 2) { - result.AddChild (new CSharpTokenNode (Convert (location[2]), 1), DoWhileStatement.Roles.RPar); - result.AddChild (new CSharpTokenNode (Convert (location[3]), 1), DoWhileStatement.Roles.Semicolon); + result.AddChild (new CSharpTokenNode (Convert (location [2])), Roles.RPar); + if (location.Count > 3) + result.AddChild (new CSharpTokenNode (Convert (location [3])), Roles.Semicolon); } return result; @@ -1382,16 +1492,16 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new WhileStatement (); var location = LocationsBag.GetLocations (whileStatement); - result.AddChild (new CSharpTokenNode (Convert (whileStatement.loc), "while".Length), WhileStatement.WhileKeywordRole); + result.AddChild (new CSharpTokenNode (Convert (whileStatement.loc)), WhileStatement.WhileKeywordRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location [0]), 1), WhileStatement.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); if (whileStatement.expr != null) - result.AddChild ((Expression)whileStatement.expr.Accept (this), WhileStatement.Roles.Condition); + result.AddChild ((Expression)whileStatement.expr.Accept (this), Roles.Condition); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location [1]), 1), WhileStatement.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); if (whileStatement.Statement != null) - result.AddChild ((Statement)whileStatement.Statement.Accept (this), WhileStatement.Roles.EmbeddedStatement); + result.AddChild ((Statement)whileStatement.Statement.Accept (this), Roles.EmbeddedStatement); return result; } @@ -1416,26 +1526,26 @@ namespace ICSharpCode.NRefactory.CSharp var location = LocationsBag.GetLocations (forStatement); - result.AddChild (new CSharpTokenNode (Convert (forStatement.loc), "for".Length), ForStatement.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (forStatement.loc)), ForStatement.ForKeywordRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location [0]), 1), ForStatement.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); AddStatementOrList (result, forStatement.Initializer, ForStatement.InitializerRole); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location [1]), 1), ForStatement.Roles.Semicolon); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.Semicolon); if (forStatement.Condition != null) - result.AddChild ((Expression)forStatement.Condition.Accept (this), ForStatement.Roles.Condition); + result.AddChild ((Expression)forStatement.Condition.Accept (this), Roles.Condition); if (location != null && location.Count >= 3) - result.AddChild (new CSharpTokenNode (Convert (location [2]), 1), ForStatement.Roles.Semicolon); + result.AddChild (new CSharpTokenNode (Convert (location [2])), Roles.Semicolon); AddStatementOrList (result, forStatement.Iterator, ForStatement.IteratorRole); if (location != null && location.Count >= 4) - result.AddChild (new CSharpTokenNode (Convert (location [3]), 1), ForStatement.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [3])), Roles.RPar); if (forStatement.Statement != null) - result.AddChild ((Statement)forStatement.Statement.Accept (this), ForStatement.Roles.EmbeddedStatement); + result.AddChild ((Statement)forStatement.Statement.Accept (this), Roles.EmbeddedStatement); return result; } @@ -1445,10 +1555,10 @@ namespace ICSharpCode.NRefactory.CSharp var result = new ExpressionStatement (); var expr = statementExpression.Expr.Accept (this) as Expression; if (expr != null) - result.AddChild ((Expression)expr, ExpressionStatement.Roles.Expression); + result.AddChild ((Expression)expr, Roles.Expression); var location = LocationsBag.GetLocations (statementExpression); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), ExpressionStatement.Roles.Semicolon); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.Semicolon); return result; } @@ -1457,7 +1567,7 @@ namespace ICSharpCode.NRefactory.CSharp var result = new ExpressionStatement (); var expr = statementErrorExpression.Expr.Accept (this) as Expression; if (expr != null) - result.AddChild ((Expression)expr, ExpressionStatement.Roles.Expression); + result.AddChild ((Expression)expr, Roles.Expression); return result; } @@ -1468,10 +1578,10 @@ namespace ICSharpCode.NRefactory.CSharp return result; var expr = statementExpression.Expression.Accept (this) as Expression; if (expr != null) - result.AddChild (expr, ExpressionStatement.Roles.Expression); + result.AddChild (expr, Roles.Expression); var location = LocationsBag.GetLocations (statementExpression); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), ExpressionStatement.Roles.Semicolon); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.Semicolon); return result; } @@ -1479,13 +1589,13 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new ReturnStatement (); - result.AddChild (new CSharpTokenNode (Convert (returnStatement.loc), "return".Length), ReturnStatement.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (returnStatement.loc)), ReturnStatement.ReturnKeywordRole); if (returnStatement.Expr != null) - result.AddChild ((Expression)returnStatement.Expr.Accept (this), ReturnStatement.Roles.Expression); + result.AddChild ((Expression)returnStatement.Expr.Accept (this), Roles.Expression); var location = LocationsBag.GetLocations (returnStatement); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), ReturnStatement.Roles.Semicolon); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.Semicolon); return result; } @@ -1494,11 +1604,11 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new GotoStatement (); var location = LocationsBag.GetLocations (gotoStatement); - result.AddChild (new CSharpTokenNode (Convert (gotoStatement.loc), "goto".Length), GotoStatement.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (gotoStatement.loc)), GotoStatement.GotoKeywordRole); var loc = location != null ? Convert (location [0]) : TextLocation.Empty; - result.AddChild (Identifier.Create (gotoStatement.Target, loc), GotoStatement.Roles.Identifier); + result.AddChild (Identifier.Create (gotoStatement.Target, loc), Roles.Identifier); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location [1]), 1), GotoStatement.Roles.Semicolon); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.Semicolon); return result; } @@ -1506,21 +1616,22 @@ namespace ICSharpCode.NRefactory.CSharp public override object Visit (LabeledStatement labeledStatement) { var result = new LabelStatement (); - result.AddChild (Identifier.Create (labeledStatement.Name, Convert (labeledStatement.loc)), LabelStatement.Roles.Identifier); + result.AddChild (Identifier.Create (labeledStatement.Name, Convert (labeledStatement.loc)), Roles.Identifier); var location = LocationsBag.GetLocations (labeledStatement); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location [0]), 1), LabelStatement.Roles.Colon); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.Colon); return result; } public override object Visit (GotoDefault gotoDefault) { var result = new GotoDefaultStatement (); - result.AddChild (new CSharpTokenNode (Convert (gotoDefault.loc), "goto".Length), GotoDefaultStatement.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (gotoDefault.loc)), GotoDefaultStatement.GotoKeywordRole); var location = LocationsBag.GetLocations (gotoDefault); - if (location != null && location.Count > 1) { - result.AddChild (new CSharpTokenNode (Convert (location[0]), "default".Length), GotoDefaultStatement.DefaultKeywordRole); - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), GotoDefaultStatement.Roles.Semicolon); + if (location != null) { + result.AddChild (new CSharpTokenNode (Convert (location [0])), GotoDefaultStatement.DefaultKeywordRole); + if (location.Count > 1) + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.Semicolon); } return result; @@ -1529,14 +1640,15 @@ namespace ICSharpCode.NRefactory.CSharp public override object Visit (GotoCase gotoCase) { var result = new GotoCaseStatement (); - result.AddChild (new CSharpTokenNode (Convert (gotoCase.loc), "goto".Length), GotoCaseStatement.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (gotoCase.loc)), GotoCaseStatement.GotoKeywordRole); var location = LocationsBag.GetLocations (gotoCase); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), "case".Length), GotoCaseStatement.CaseKeywordRole); - result.AddChild ((Expression)gotoCase.Expr.Accept (this), GotoCaseStatement.Roles.Expression); + result.AddChild (new CSharpTokenNode (Convert (location [0])), GotoCaseStatement.CaseKeywordRole); + if (gotoCase.Expr != null) + result.AddChild ((Expression)gotoCase.Expr.Accept (this), Roles.Expression); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), GotoCaseStatement.Roles.Semicolon); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.Semicolon); return result; } @@ -1545,11 +1657,11 @@ namespace ICSharpCode.NRefactory.CSharp var result = new ThrowStatement (); var location = LocationsBag.GetLocations (throwStatement); - result.AddChild (new CSharpTokenNode (Convert (throwStatement.loc), "throw".Length), ThrowStatement.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (throwStatement.loc)), ThrowStatement.ThrowKeywordRole); if (throwStatement.Expr != null) - result.AddChild ((Expression)throwStatement.Expr.Accept (this), ThrowStatement.Roles.Expression); + result.AddChild ((Expression)throwStatement.Expr.Accept (this), Roles.Expression); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), ThrowStatement.Roles.Semicolon); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.Semicolon); return result; } @@ -1558,9 +1670,9 @@ namespace ICSharpCode.NRefactory.CSharp var result = new BreakStatement (); var location = LocationsBag.GetLocations (breakStatement); - result.AddChild (new CSharpTokenNode (Convert (breakStatement.loc), "break".Length), BreakStatement.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (breakStatement.loc)), BreakStatement.BreakKeywordRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), BreakStatement.Roles.Semicolon); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.Semicolon); return result; } @@ -1568,9 +1680,9 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new ContinueStatement (); var location = LocationsBag.GetLocations (continueStatement); - result.AddChild (new CSharpTokenNode (Convert (continueStatement.loc), "continue".Length), ContinueStatement.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (continueStatement.loc)), ContinueStatement.ContinueKeywordRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), ContinueStatement.Roles.Semicolon); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.Semicolon); return result; } @@ -1582,11 +1694,11 @@ namespace ICSharpCode.NRefactory.CSharp public UsingStatement CreateUsingStatement (Block blockStatement) { var usingResult = new UsingStatement (); - Mono.CSharp.Statement cur = blockStatement.Statements[0]; + Mono.CSharp.Statement cur = blockStatement.Statements [0]; if (cur is Using) { Using u = (Using)cur; - usingResult.AddChild (new CSharpTokenNode (Convert (u.loc), "using".Length), UsingStatement.Roles.Keyword); - usingResult.AddChild (new CSharpTokenNode (Convert (blockStatement.StartLocation), 1), UsingStatement.Roles.LPar); + usingResult.AddChild (new CSharpTokenNode (Convert (u.loc)), UsingStatement.UsingKeywordRole); + usingResult.AddChild (new CSharpTokenNode (Convert (blockStatement.StartLocation)), Roles.LPar); if (u.Variables != null) { var initializer = new VariableInitializer () { NameToken = Identifier.Create (u.Variables.Variable.Name, Convert (u.Variables.Variable.Location)), @@ -1594,20 +1706,37 @@ namespace ICSharpCode.NRefactory.CSharp var loc = LocationsBag.GetLocations (u.Variables); if (loc != null) - initializer.AddChild (new CSharpTokenNode (Convert (loc[0]), 1), VariableInitializer.Roles.Assign); + initializer.AddChild (new CSharpTokenNode (Convert (loc [0])), Roles.Assign); if (u.Variables.Initializer != null) initializer.Initializer = u.Variables.Initializer.Accept (this) as Expression; - var varDec = new VariableDeclarationStatement () { + + var varDec = new VariableDeclarationStatement () { Type = ConvertToType (u.Variables.TypeExpression), Variables = { initializer } }; + + if (u.Variables.Declarators != null) { + foreach (var decl in u.Variables.Declarators) { + var declLoc = LocationsBag.GetLocations (decl); + var init = new VariableInitializer (); + if (declLoc != null && declLoc.Count > 0) + varDec.AddChild (new CSharpTokenNode (Convert (declLoc [0])), Roles.Comma); + init.AddChild (Identifier.Create (decl.Variable.Name, Convert (decl.Variable.Location)), Roles.Identifier); + if (decl.Initializer != null) { + if (declLoc != null && declLoc.Count > 1) + init.AddChild (new CSharpTokenNode (Convert (declLoc [1])), Roles.Assign); + init.AddChild ((Expression)decl.Initializer.Accept (this), Roles.Expression); + } + varDec.AddChild (init, Roles.Variable); + } + } usingResult.AddChild (varDec, UsingStatement.ResourceAcquisitionRole); } cur = u.Statement; - usingResult.AddChild (new CSharpTokenNode (Convert (blockStatement.EndLocation), 1), UsingStatement.Roles.RPar); + usingResult.AddChild (new CSharpTokenNode (Convert (blockStatement.EndLocation)), Roles.RPar); if (cur != null) - usingResult.AddChild ((Statement)cur.Accept (this), UsingStatement.Roles.EmbeddedStatement); + usingResult.AddChild ((Statement)cur.Accept (this), Roles.EmbeddedStatement); } return usingResult; } @@ -1621,7 +1750,7 @@ namespace ICSharpCode.NRefactory.CSharp if (stmt == null) continue; /* if (curLocal < localVariables.Count && IsLower (localVariables[curLocal].Location, stmt.loc)) { - result.AddChild (CreateVariableDeclaration (localVariables[curLocal]), AstNode.Roles.Statement); + result.AddChild (CreateVariableDeclaration (localVariables[curLocal]), Roles.Statement); curLocal++; }*/ if (stmt is Block && !(stmt is ToplevelBlock || stmt is ExplicitBlock)) { @@ -1640,11 +1769,11 @@ namespace ICSharpCode.NRefactory.CSharp return blockStatement.Statements.Last ().Accept (this); } var result = new BlockStatement (); - result.AddChild (new CSharpTokenNode (Convert (blockStatement.StartLocation), 1), AstNode.Roles.LBrace); + result.AddChild (new CSharpTokenNode (Convert (blockStatement.StartLocation)), Roles.LBrace); int curLocal = 0; AddBlockChildren (result, blockStatement, ref curLocal); - result.AddChild (new CSharpTokenNode (Convert (blockStatement.EndLocation), 1), AstNode.Roles.RBrace); + result.AddChild (new CSharpTokenNode (Convert (blockStatement.EndLocation)), Roles.RBrace); return result; } @@ -1653,49 +1782,54 @@ namespace ICSharpCode.NRefactory.CSharp var result = new SwitchStatement (); var location = LocationsBag.GetLocations (switchStatement); - result.AddChild (new CSharpTokenNode (Convert (switchStatement.loc), "switch".Length), SwitchStatement.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (switchStatement.loc)), SwitchStatement.SwitchKeywordRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location [0]), 1), SwitchStatement.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); if (switchStatement.Expr != null) - result.AddChild ((Expression)switchStatement.Expr.Accept (this), SwitchStatement.Roles.Expression); + result.AddChild ((Expression)switchStatement.Expr.Accept (this), Roles.Expression); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), SwitchStatement.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); if (location != null && location.Count > 2) - result.AddChild (new CSharpTokenNode (Convert (location[2]), 1), SwitchStatement.Roles.LBrace); - foreach (var section in switchStatement.Sections) { - var newSection = new SwitchSection (); - foreach (var caseLabel in section.Labels) { - var newLabel = new CaseLabel (); - if (caseLabel.Label != null) { - newLabel.AddChild (new CSharpTokenNode (Convert (caseLabel.Location), "case".Length), SwitchStatement.Roles.Keyword); - newLabel.AddChild ((Expression)caseLabel.Label.Accept (this), SwitchStatement.Roles.Expression); - var colonLocation = LocationsBag.GetLocations (caseLabel); - if (colonLocation != null) - newLabel.AddChild (new CSharpTokenNode (Convert (colonLocation [0]), 1), SwitchStatement.Roles.Colon); - } else { - newLabel.AddChild (new CSharpTokenNode (Convert (caseLabel.Location), "default".Length), SwitchStatement.Roles.Keyword); - newLabel.AddChild (new CSharpTokenNode (new TextLocation (caseLabel.Location.Row, caseLabel.Location.Column + "default".Length), 1), SwitchStatement.Roles.Colon); + result.AddChild (new CSharpTokenNode (Convert (location [2])), Roles.LBrace); + if (switchStatement.Sections != null) { + foreach (var section in switchStatement.Sections) { + var newSection = new SwitchSection (); + if (section.Labels != null) { + foreach (var caseLabel in section.Labels) { + var newLabel = new CaseLabel (); + if (caseLabel.Label != null) { + newLabel.AddChild (new CSharpTokenNode (Convert (caseLabel.Location)), CaseLabel.CaseKeywordRole); + if (caseLabel.Label != null) + newLabel.AddChild ((Expression)caseLabel.Label.Accept (this), Roles.Expression); + var colonLocation = LocationsBag.GetLocations (caseLabel); + if (colonLocation != null) + newLabel.AddChild (new CSharpTokenNode (Convert (colonLocation [0])), Roles.Colon); + } else { + newLabel.AddChild (new CSharpTokenNode (Convert (caseLabel.Location)), CaseLabel.DefaultKeywordRole); + newLabel.AddChild (new CSharpTokenNode (new TextLocation (caseLabel.Location.Row, caseLabel.Location.Column + "default".Length)), Roles.Colon); + } + newSection.AddChild (newLabel, SwitchSection.CaseLabelRole); + } } - newSection.AddChild (newLabel, SwitchSection.CaseLabelRole); - } - - var blockStatement = section.Block; - var bodyBlock = new BlockStatement (); - int curLocal = 0; - AddBlockChildren (bodyBlock, blockStatement, ref curLocal); - foreach (var statement in bodyBlock.Statements) { - statement.Remove (); - newSection.AddChild (statement, SwitchSection.Roles.EmbeddedStatement); + var blockStatement = section.Block; + var bodyBlock = new BlockStatement (); + int curLocal = 0; + AddBlockChildren (bodyBlock, blockStatement, ref curLocal); + foreach (var statement in bodyBlock.Statements) { + statement.Remove (); + newSection.AddChild (statement, Roles.EmbeddedStatement); + + } + result.AddChild (newSection, SwitchStatement.SwitchSectionRole); } - result.AddChild (newSection, SwitchStatement.SwitchSectionRole); } if (location != null && location.Count > 3) { - result.AddChild (new CSharpTokenNode (Convert (location[3]), 1), SwitchStatement.Roles.RBrace); + result.AddChild (new CSharpTokenNode (Convert (location [3])), Roles.RBrace); } else { // parser error, set end node to max value. - result.AddChild (new ErrorNode (), AstNode.Roles.Error); + result.AddChild (new ErrorNode (), Roles.Error); } return result; @@ -1705,15 +1839,17 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new LockStatement (); var location = LocationsBag.GetLocations (lockStatement); - result.AddChild (new CSharpTokenNode (Convert (lockStatement.loc), "lock".Length), LockStatement.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (lockStatement.loc)), LockStatement.LockKeywordRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), LockStatement.Roles.LPar); - result.AddChild ((Expression)lockStatement.Expr.Accept (this), LockStatement.Roles.Expression); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); + if (lockStatement.Expr != null) + result.AddChild ((Expression)lockStatement.Expr.Accept (this), Roles.Expression); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), LockStatement.Roles.RPar); - result.AddChild ((Statement)lockStatement.Statement.Accept (this), LockStatement.Roles.EmbeddedStatement); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); + if (lockStatement.Statement != null) + result.AddChild ((Statement)lockStatement.Statement.Accept (this), Roles.EmbeddedStatement); return result; } @@ -1721,25 +1857,27 @@ namespace ICSharpCode.NRefactory.CSharp public override object Visit (Unchecked uncheckedStatement) { var result = new UncheckedStatement (); - result.AddChild (new CSharpTokenNode (Convert (uncheckedStatement.loc), "unchecked".Length), UncheckedStatement.Roles.Keyword); - result.AddChild ((BlockStatement)uncheckedStatement.Block.Accept (this), UncheckedStatement.Roles.Body); + result.AddChild (new CSharpTokenNode (Convert (uncheckedStatement.loc)), UncheckedStatement.UncheckedKeywordRole); + if (uncheckedStatement.Block != null) + result.AddChild ((BlockStatement)uncheckedStatement.Block.Accept (this), Roles.Body); return result; } - public override object Visit (Checked checkedStatement) { var result = new CheckedStatement (); - result.AddChild (new CSharpTokenNode (Convert (checkedStatement.loc), "checked".Length), CheckedStatement.Roles.Keyword); - result.AddChild ((BlockStatement)checkedStatement.Block.Accept (this), CheckedStatement.Roles.Body); + result.AddChild (new CSharpTokenNode (Convert (checkedStatement.loc)), CheckedStatement.CheckedKeywordRole); + if (checkedStatement.Block != null) + result.AddChild ((BlockStatement)checkedStatement.Block.Accept (this), Roles.Body); return result; } public override object Visit (Unsafe unsafeStatement) { var result = new UnsafeStatement (); - result.AddChild (new CSharpTokenNode (Convert (unsafeStatement.loc), "unsafe".Length), UnsafeStatement.Roles.Keyword); - result.AddChild ((BlockStatement)unsafeStatement.Block.Accept (this), UnsafeStatement.Roles.Body); + result.AddChild (new CSharpTokenNode (Convert (unsafeStatement.loc)), UnsafeStatement.UnsafeKeywordRole); + if (unsafeStatement.Block != null) + result.AddChild ((BlockStatement)unsafeStatement.Block.Accept (this), Roles.Body); return result; } @@ -1748,45 +1886,46 @@ namespace ICSharpCode.NRefactory.CSharp var result = new FixedStatement (); var location = LocationsBag.GetLocations (fixedStatement); - result.AddChild (new CSharpTokenNode (Convert (fixedStatement.loc), "fixed".Length), FixedStatement.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (fixedStatement.loc)), FixedStatement.FixedKeywordRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), FixedStatement.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); if (fixedStatement.Variables != null) { var blockVariableDeclaration = fixedStatement.Variables; - result.AddChild (ConvertToType (blockVariableDeclaration.TypeExpression), FixedStatement.Roles.Type); + result.AddChild (ConvertToType (blockVariableDeclaration.TypeExpression), Roles.Type); var varInit = new VariableInitializer (); var initLocation = LocationsBag.GetLocations (blockVariableDeclaration); - varInit.AddChild (Identifier.Create (blockVariableDeclaration.Variable.Name, Convert (blockVariableDeclaration.Variable.Location)), VariableInitializer.Roles.Identifier); + varInit.AddChild (Identifier.Create (blockVariableDeclaration.Variable.Name, Convert (blockVariableDeclaration.Variable.Location)), Roles.Identifier); if (blockVariableDeclaration.Initializer != null) { if (initLocation != null) - varInit.AddChild (new CSharpTokenNode (Convert (location[0]), 1), VariableInitializer.Roles.Assign); - varInit.AddChild ((Expression)blockVariableDeclaration.Initializer.Accept (this), VariableInitializer.Roles.Expression); + varInit.AddChild (new CSharpTokenNode (Convert (initLocation [0])), Roles.Assign); + varInit.AddChild ((Expression)blockVariableDeclaration.Initializer.Accept (this), Roles.Expression); } - result.AddChild (varInit, FixedStatement.Roles.Variable); + result.AddChild (varInit, Roles.Variable); if (blockVariableDeclaration.Declarators != null) { foreach (var decl in blockVariableDeclaration.Declarators) { var loc = LocationsBag.GetLocations (decl); var init = new VariableInitializer (); if (loc != null && loc.Count > 0) - result.AddChild (new CSharpTokenNode (Convert (loc [0]), 1), VariableInitializer.Roles.Comma); - init.AddChild (Identifier.Create (decl.Variable.Name, Convert (decl.Variable.Location)), VariableInitializer.Roles.Identifier); + result.AddChild (new CSharpTokenNode (Convert (loc [0])), Roles.Comma); + init.AddChild (Identifier.Create (decl.Variable.Name, Convert (decl.Variable.Location)), Roles.Identifier); if (decl.Initializer != null) { if (loc != null && loc.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (loc [1]), 1), VariableInitializer.Roles.Assign); - init.AddChild ((Expression)decl.Initializer.Accept (this), VariableInitializer.Roles.Expression); + init.AddChild (new CSharpTokenNode (Convert (loc [1])), Roles.Assign); + init.AddChild ((Expression)decl.Initializer.Accept (this), Roles.Expression); } else { } - result.AddChild (init, FixedStatement.Roles.Variable); + result.AddChild (init, Roles.Variable); } } } if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), FixedStatement.Roles.RPar); - result.AddChild ((Statement)fixedStatement.Statement.Accept (this), FixedStatement.Roles.EmbeddedStatement); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); + if (fixedStatement.Statement != null) + result.AddChild ((Statement)fixedStatement.Statement.Accept (this), Roles.EmbeddedStatement); return result; } @@ -1799,13 +1938,14 @@ namespace ICSharpCode.NRefactory.CSharp result = (TryCatchStatement)tryFinallyStatement.Stmt.Accept (this); } else { result = new TryCatchStatement (); - result.AddChild (new CSharpTokenNode (Convert (tryFinallyStatement.loc), "try".Length), TryCatchStatement.TryKeywordRole); + result.AddChild (new CSharpTokenNode (Convert (tryFinallyStatement.loc)), TryCatchStatement.TryKeywordRole); if (tryFinallyStatement.Stmt != null) result.AddChild ((BlockStatement)tryFinallyStatement.Stmt.Accept (this), TryCatchStatement.TryBlockRole); } if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), "finally".Length), TryCatchStatement.FinallyKeywordRole); - result.AddChild ((BlockStatement)tryFinallyStatement.Fini.Accept (this), TryCatchStatement.FinallyBlockRole); + result.AddChild (new CSharpTokenNode (Convert (location [0])), TryCatchStatement.FinallyKeywordRole); + if (tryFinallyStatement.Fini != null) + result.AddChild ((BlockStatement)tryFinallyStatement.Fini.Accept (this), TryCatchStatement.FinallyBlockRole); return result; } @@ -1814,21 +1954,22 @@ namespace ICSharpCode.NRefactory.CSharp { CatchClause result = new CatchClause (); var location = LocationsBag.GetLocations (ctch); - result.AddChild (new CSharpTokenNode (Convert (ctch.loc), "catch".Length), CatchClause.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (ctch.loc)), CatchClause.CatchKeywordRole); if (ctch.TypeExpression != null) { if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), CatchClause.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); - result.AddChild (ConvertToType (ctch.TypeExpression), CatchClause.Roles.Type); + if (ctch.TypeExpression != null) + result.AddChild (ConvertToType (ctch.TypeExpression), Roles.Type); if (ctch.Variable != null && !string.IsNullOrEmpty (ctch.Variable.Name)) - result.AddChild (Identifier.Create (ctch.Variable.Name, Convert (ctch.Variable.Location)), CatchClause.Roles.Identifier); + result.AddChild (Identifier.Create (ctch.Variable.Name, Convert (ctch.Variable.Location)), Roles.Identifier); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), CatchClause.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); } if (ctch.Block != null) - result.AddChild ((BlockStatement)ctch.Block.Accept (this), CatchClause.Roles.Body); + result.AddChild ((BlockStatement)ctch.Block.Accept (this), Roles.Body); return result; } @@ -1836,7 +1977,7 @@ namespace ICSharpCode.NRefactory.CSharp public override object Visit (TryCatch tryCatchStatement) { var result = new TryCatchStatement (); - result.AddChild (new CSharpTokenNode (Convert (tryCatchStatement.loc), "try".Length), TryCatchStatement.TryKeywordRole); + result.AddChild (new CSharpTokenNode (Convert (tryCatchStatement.loc)), TryCatchStatement.TryKeywordRole); if (tryCatchStatement.Block != null) result.AddChild ((BlockStatement)tryCatchStatement.Block.Accept (this), TryCatchStatement.TryBlockRole); if (tryCatchStatement.Clauses != null) { @@ -1855,17 +1996,17 @@ namespace ICSharpCode.NRefactory.CSharp var result = new UsingStatement (); var location = LocationsBag.GetLocations (usingStatement); - result.AddChild (new CSharpTokenNode (Convert (usingStatement.loc), "using".Length), UsingStatement.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (usingStatement.loc)), UsingStatement.UsingKeywordRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location [0]), 1), UsingStatement.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); if (usingStatement.Expr != null) result.AddChild ((AstNode)usingStatement.Expr.Accept (this), UsingStatement.ResourceAcquisitionRole); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location [1]), 1), UsingStatement.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); if (usingStatement.Statement != null) - result.AddChild ((Statement)usingStatement.Statement.Accept (this), UsingStatement.Roles.EmbeddedStatement); + result.AddChild ((Statement)usingStatement.Statement.Accept (this), Roles.EmbeddedStatement); return result; } @@ -1875,27 +2016,27 @@ namespace ICSharpCode.NRefactory.CSharp var location = LocationsBag.GetLocations (foreachStatement); - result.AddChild (new CSharpTokenNode (Convert (foreachStatement.loc), "foreach".Length), ForeachStatement.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (foreachStatement.loc)), ForeachStatement.ForeachKeywordRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location [0]), 1), ForeachStatement.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); if (foreachStatement.TypeExpression != null) - result.AddChild (ConvertToType (foreachStatement.TypeExpression), ForeachStatement.Roles.Type); + result.AddChild (ConvertToType (foreachStatement.TypeExpression), Roles.Type); if (foreachStatement.Variable != null) - result.AddChild (Identifier.Create (foreachStatement.Variable.Name, Convert (foreachStatement.Variable.Location)), ForeachStatement.Roles.Identifier); + result.AddChild (Identifier.Create (foreachStatement.Variable.Name, Convert (foreachStatement.Variable.Location)), Roles.Identifier); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location [1]), "in".Length), ForeachStatement.Roles.InKeyword); + result.AddChild (new CSharpTokenNode (Convert (location [1])), ForeachStatement.InKeywordRole); if (foreachStatement.Expr != null) - result.AddChild ((Expression)foreachStatement.Expr.Accept (this), ForeachStatement.Roles.Expression); + result.AddChild ((Expression)foreachStatement.Expr.Accept (this), Roles.Expression); if (location != null && location.Count > 2) - result.AddChild (new CSharpTokenNode (Convert (location [2]), 1), ForeachStatement.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [2])), Roles.RPar); if (foreachStatement.Statement != null) - result.AddChild ((Statement)foreachStatement.Statement.Accept (this), ForeachStatement.Roles.EmbeddedStatement); + result.AddChild ((Statement)foreachStatement.Statement.Accept (this), Roles.EmbeddedStatement); return result; } @@ -1905,13 +2046,13 @@ namespace ICSharpCode.NRefactory.CSharp var result = new YieldReturnStatement (); var location = LocationsBag.GetLocations (yieldStatement); - result.AddChild (new CSharpTokenNode (Convert (yieldStatement.loc), "yield".Length), YieldReturnStatement.YieldKeywordRole); + result.AddChild (new CSharpTokenNode (Convert (yieldStatement.loc)), YieldReturnStatement.YieldKeywordRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), "return".Length), YieldReturnStatement.ReturnKeywordRole); + result.AddChild (new CSharpTokenNode (Convert (location [0])), YieldReturnStatement.ReturnKeywordRole); if (yieldStatement.Expr != null) - result.AddChild ((Expression)yieldStatement.Expr.Accept (this), YieldReturnStatement.Roles.Expression); + result.AddChild ((Expression)yieldStatement.Expr.Accept (this), Roles.Expression); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), ";".Length), YieldReturnStatement.Roles.Semicolon); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.Semicolon); return result; } @@ -1920,10 +2061,11 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new YieldBreakStatement (); var location = LocationsBag.GetLocations (yieldBreakStatement); - result.AddChild (new CSharpTokenNode (Convert (yieldBreakStatement.loc), "yield".Length), YieldBreakStatement.YieldKeywordRole); - if (location != null && location.Count > 1) { - result.AddChild (new CSharpTokenNode (Convert (location[0]), "break".Length), YieldBreakStatement.BreakKeywordRole); - result.AddChild (new CSharpTokenNode (Convert (location[1]), ";".Length), YieldBreakStatement.Roles.Semicolon); + result.AddChild (new CSharpTokenNode (Convert (yieldBreakStatement.loc)), YieldBreakStatement.YieldKeywordRole); + if (location != null) { + result.AddChild (new CSharpTokenNode (Convert (location [0])), YieldBreakStatement.BreakKeywordRole); + if (location.Count > 1) + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.Semicolon); } return result; } @@ -1949,7 +2091,7 @@ namespace ICSharpCode.NRefactory.CSharp public override object Visit (LocalVariableReference localVariableReference) { - return Identifier.Create (localVariableReference.Name, Convert (localVariableReference.Location));; + return Identifier.Create (localVariableReference.Name, Convert (localVariableReference.Location)); } public override object Visit (MemberAccess memberAccess) @@ -1958,20 +2100,20 @@ namespace ICSharpCode.NRefactory.CSharp if (memberAccess.LeftExpression is Indirection) { var ind = memberAccess.LeftExpression as Indirection; result = new PointerReferenceExpression (); - result.AddChild ((Expression)ind.Expr.Accept (this), PointerReferenceExpression.Roles.TargetExpression); - result.AddChild (new CSharpTokenNode (Convert (ind.Location), "->".Length), PointerReferenceExpression.ArrowRole); + result.AddChild ((Expression)ind.Expr.Accept (this), Roles.TargetExpression); + result.AddChild (new CSharpTokenNode (Convert (ind.Location)), PointerReferenceExpression.ArrowRole); } else { result = new MemberReferenceExpression (); if (memberAccess.LeftExpression != null) { var leftExpr = memberAccess.LeftExpression.Accept (this); - result.AddChild ((Expression)leftExpr, MemberReferenceExpression.Roles.TargetExpression); + result.AddChild ((Expression)leftExpr, Roles.TargetExpression); } if (!memberAccess.DotLocation.IsNull) { - result.AddChild (new CSharpTokenNode (Convert (memberAccess.DotLocation), 1), MemberReferenceExpression.Roles.Dot); + result.AddChild (new CSharpTokenNode (Convert (memberAccess.DotLocation)), Roles.Dot); } } - result.AddChild (Identifier.Create (memberAccess.Name, Convert (memberAccess.Location)), MemberReferenceExpression.Roles.Identifier); + result.AddChild (Identifier.Create (memberAccess.Name, Convert (memberAccess.Location)), Roles.Identifier); AddTypeArguments (result, memberAccess); return result; @@ -1983,7 +2125,7 @@ namespace ICSharpCode.NRefactory.CSharp result.Target = new SimpleType (qualifiedAliasMember.alias, Convert (qualifiedAliasMember.Location)); result.IsDoubleColon = true; var location = LocationsBag.GetLocations (qualifiedAliasMember); - result.AddChild (Identifier.Create (qualifiedAliasMember.Name, location != null ? Convert (location[0]) : TextLocation.Empty), MemberReferenceExpression.Roles.Identifier); + result.AddChild (Identifier.Create (qualifiedAliasMember.Name, location != null ? Convert (location [0]) : TextLocation.Empty), Roles.Identifier); return new TypeReferenceExpression () { Type = result }; } @@ -2007,7 +2149,7 @@ namespace ICSharpCode.NRefactory.CSharp public override object Visit (SimpleName simpleName) { var result = new IdentifierExpression (); - result.AddChild (Identifier.Create (simpleName.Name, Convert (simpleName.Location)), IdentifierExpression.Roles.Identifier); + result.AddChild (Identifier.Create (simpleName.Name, Convert (simpleName.Location)), Roles.Identifier); AddTypeArguments (result, simpleName); return result; } @@ -2016,17 +2158,17 @@ namespace ICSharpCode.NRefactory.CSharp { return booleanExpression.Expr.Accept (this); } - public override object Visit (Mono.CSharp.ParenthesizedExpression parenthesizedExpression) { var result = new ParenthesizedExpression (); var location = LocationsBag.GetLocations (parenthesizedExpression); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), ParenthesizedExpression.Roles.LPar); - result.AddChild ((Expression)parenthesizedExpression.Expr.Accept (this), ParenthesizedExpression.Roles.Expression); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); + if (parenthesizedExpression.Expr != null) + result.AddChild ((Expression)parenthesizedExpression.Expr.Accept (this), Roles.Expression); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), ParenthesizedExpression.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); return result; } @@ -2034,54 +2176,56 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new UnaryOperatorExpression (); switch (unaryExpression.Oper) { - case Unary.Operator.UnaryPlus: - result.Operator = UnaryOperatorType.Plus; - break; - case Unary.Operator.UnaryNegation: - result.Operator = UnaryOperatorType.Minus; - break; - case Unary.Operator.LogicalNot: - result.Operator = UnaryOperatorType.Not; - break; - case Unary.Operator.OnesComplement: - result.Operator = UnaryOperatorType.BitNot; - break; - case Unary.Operator.AddressOf: - result.Operator = UnaryOperatorType.AddressOf; - break; - } - result.AddChild (new CSharpTokenNode (Convert (unaryExpression.Location), 1), UnaryOperatorExpression.OperatorRole); - result.AddChild ((Expression)unaryExpression.Expr.Accept (this), UnaryOperatorExpression.Roles.Expression); + case Unary.Operator.UnaryPlus: + result.Operator = UnaryOperatorType.Plus; + break; + case Unary.Operator.UnaryNegation: + result.Operator = UnaryOperatorType.Minus; + break; + case Unary.Operator.LogicalNot: + result.Operator = UnaryOperatorType.Not; + break; + case Unary.Operator.OnesComplement: + result.Operator = UnaryOperatorType.BitNot; + break; + case Unary.Operator.AddressOf: + result.Operator = UnaryOperatorType.AddressOf; + break; + } + result.AddChild (new CSharpTokenNode (Convert (unaryExpression.Location)), UnaryOperatorExpression.GetOperatorRole (result.Operator)); + if (unaryExpression.Expr != null) + result.AddChild ((Expression)unaryExpression.Expr.Accept (this), Roles.Expression); return result; } public override object Visit (UnaryMutator unaryMutatorExpression) { var result = new UnaryOperatorExpression (); - + if (unaryMutatorExpression.Expr == null) + return result; var expression = (Expression)unaryMutatorExpression.Expr.Accept (this); switch (unaryMutatorExpression.UnaryMutatorMode) { - case UnaryMutator.Mode.PostDecrement: - result.Operator = UnaryOperatorType.PostDecrement; - result.AddChild (expression, UnaryOperatorExpression.Roles.Expression); - result.AddChild (new CSharpTokenNode (Convert (unaryMutatorExpression.Location), 2), UnaryOperatorExpression.OperatorRole); - break; - case UnaryMutator.Mode.PostIncrement: - result.Operator = UnaryOperatorType.PostIncrement; - result.AddChild (expression, UnaryOperatorExpression.Roles.Expression); - result.AddChild (new CSharpTokenNode (Convert (unaryMutatorExpression.Location), 2), UnaryOperatorExpression.OperatorRole); - break; + case UnaryMutator.Mode.PostDecrement: + result.Operator = UnaryOperatorType.PostDecrement; + result.AddChild (expression, Roles.Expression); + result.AddChild (new CSharpTokenNode (Convert (unaryMutatorExpression.Location)), UnaryOperatorExpression.DecrementRole); + break; + case UnaryMutator.Mode.PostIncrement: + result.Operator = UnaryOperatorType.PostIncrement; + result.AddChild (expression, Roles.Expression); + result.AddChild (new CSharpTokenNode (Convert (unaryMutatorExpression.Location)), UnaryOperatorExpression.IncrementRole); + break; - case UnaryMutator.Mode.PreIncrement: - result.Operator = UnaryOperatorType.Increment; - result.AddChild (new CSharpTokenNode (Convert (unaryMutatorExpression.Location), 2), UnaryOperatorExpression.OperatorRole); - result.AddChild (expression, UnaryOperatorExpression.Roles.Expression); - break; - case UnaryMutator.Mode.PreDecrement: - result.Operator = UnaryOperatorType.Decrement; - result.AddChild (new CSharpTokenNode (Convert (unaryMutatorExpression.Location), 2), UnaryOperatorExpression.OperatorRole); - result.AddChild (expression, UnaryOperatorExpression.Roles.Expression); - break; + case UnaryMutator.Mode.PreIncrement: + result.Operator = UnaryOperatorType.Increment; + result.AddChild (new CSharpTokenNode (Convert (unaryMutatorExpression.Location)), UnaryOperatorExpression.IncrementRole); + result.AddChild (expression, Roles.Expression); + break; + case UnaryMutator.Mode.PreDecrement: + result.Operator = UnaryOperatorType.Decrement; + result.AddChild (new CSharpTokenNode (Convert (unaryMutatorExpression.Location)), UnaryOperatorExpression.DecrementRole); + result.AddChild (expression, Roles.Expression); + break; } return result; @@ -2091,28 +2235,32 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new UnaryOperatorExpression (); result.Operator = UnaryOperatorType.Dereference; - var location = LocationsBag.GetLocations (indirectionExpression); - if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 2), UnaryOperatorExpression.OperatorRole); - result.AddChild ((Expression)indirectionExpression.Expr.Accept (this), UnaryOperatorExpression.Roles.Expression); + result.AddChild (new CSharpTokenNode (Convert (indirectionExpression.Location)), UnaryOperatorExpression.DereferenceRole); + if (indirectionExpression.Expr != null) + result.AddChild ((Expression)indirectionExpression.Expr.Accept (this), Roles.Expression); return result; } public override object Visit (Is isExpression) { var result = new IsExpression (); - result.AddChild ((Expression)isExpression.Expr.Accept (this), IsExpression.Roles.Expression); - result.AddChild (new CSharpTokenNode (Convert (isExpression.Location), "is".Length), IsExpression.Roles.Keyword); - result.AddChild (ConvertToType (isExpression.ProbeType), IsExpression.Roles.Type); + if (isExpression.Expr != null) + result.AddChild ((Expression)isExpression.Expr.Accept (this), Roles.Expression); + result.AddChild (new CSharpTokenNode (Convert (isExpression.Location)), IsExpression.IsKeywordRole); + + if (isExpression.ProbeType != null) + result.AddChild (ConvertToType (isExpression.ProbeType), Roles.Type); return result; } public override object Visit (As asExpression) { var result = new AsExpression (); - result.AddChild ((Expression)asExpression.Expr.Accept (this), AsExpression.Roles.Expression); - result.AddChild (new CSharpTokenNode (Convert (asExpression.Location), "as".Length), AsExpression.Roles.Keyword); - result.AddChild (ConvertToType (asExpression.ProbeType), AsExpression.Roles.Type); + if (asExpression.Expr != null) + result.AddChild ((Expression)asExpression.Expr.Accept (this), Roles.Expression); + result.AddChild (new CSharpTokenNode (Convert (asExpression.Location)), AsExpression.AsKeywordRole); + if (asExpression.ProbeType != null) + result.AddChild (ConvertToType (asExpression.ProbeType), Roles.Type); return result; } @@ -2121,33 +2269,33 @@ namespace ICSharpCode.NRefactory.CSharp var result = new CastExpression (); var location = LocationsBag.GetLocations (castExpression); - result.AddChild (new CSharpTokenNode (Convert (castExpression.Location), 1), CastExpression.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (castExpression.Location)), Roles.LPar); if (castExpression.TargetType != null) - result.AddChild (ConvertToType (castExpression.TargetType), CastExpression.Roles.Type); + result.AddChild (ConvertToType (castExpression.TargetType), Roles.Type); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), CastExpression.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.RPar); if (castExpression.Expr != null) - result.AddChild ((Expression)castExpression.Expr.Accept (this), CastExpression.Roles.Expression); + result.AddChild ((Expression)castExpression.Expr.Accept (this), Roles.Expression); return result; } public override object Visit (ComposedCast composedCast) { var result = new ComposedType (); - result.AddChild (ConvertToType (composedCast.Left), ComposedType.Roles.Type); + result.AddChild (ConvertToType (composedCast.Left), Roles.Type); var spec = composedCast.Spec; while (spec != null) { if (spec.IsNullable) { - result.AddChild (new CSharpTokenNode (Convert (spec.Location), 1), ComposedType.NullableRole); + result.AddChild (new CSharpTokenNode (Convert (spec.Location)), ComposedType.NullableRole); } else if (spec.IsPointer) { - result.AddChild (new CSharpTokenNode (Convert (spec.Location), 1), ComposedType.PointerRole); + result.AddChild (new CSharpTokenNode (Convert (spec.Location)), ComposedType.PointerRole); } else { var aSpec = new ArraySpecifier (); - aSpec.AddChild (new CSharpTokenNode (Convert (spec.Location), 1), ComposedType.Roles.LBracket); + aSpec.AddChild (new CSharpTokenNode (Convert (spec.Location)), Roles.LBracket); var location = LocationsBag.GetLocations (spec); if (location != null) - aSpec.AddChild (new CSharpTokenNode (Convert (spec.Location), 1), ComposedType.Roles.RBracket); + aSpec.AddChild (new CSharpTokenNode (Convert (spec.Location)), Roles.RBracket); result.AddChild (aSpec, ComposedType.ArraySpecifierRole); } spec = spec.Next; @@ -2159,88 +2307,81 @@ namespace ICSharpCode.NRefactory.CSharp public override object Visit (Mono.CSharp.DefaultValueExpression defaultValueExpression) { var result = new DefaultValueExpression (); - result.AddChild (new CSharpTokenNode (Convert (defaultValueExpression.Location), "default".Length), CastExpression.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (defaultValueExpression.Location)), DefaultValueExpression.DefaultKeywordRole); var location = LocationsBag.GetLocations (defaultValueExpression); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), CastExpression.Roles.LPar); - result.AddChild (ConvertToType (defaultValueExpression.Expr), CastExpression.Roles.Type); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); + result.AddChild (ConvertToType (defaultValueExpression.Expr), Roles.Type); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), CastExpression.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); return result; } public override object Visit (Binary binaryExpression) { var result = new BinaryOperatorExpression (); - int opLength = 1; switch (binaryExpression.Oper) { - case Binary.Operator.Multiply: - result.Operator = BinaryOperatorType.Multiply; - break; - case Binary.Operator.Division: - result.Operator = BinaryOperatorType.Divide; - break; - case Binary.Operator.Modulus: - result.Operator = BinaryOperatorType.Modulus; - break; - case Binary.Operator.Addition: - result.Operator = BinaryOperatorType.Add; - break; - case Binary.Operator.Subtraction: - result.Operator = BinaryOperatorType.Subtract; - break; - case Binary.Operator.LeftShift: - result.Operator = BinaryOperatorType.ShiftLeft; - opLength = 2; - break; - case Binary.Operator.RightShift: - result.Operator = BinaryOperatorType.ShiftRight; - opLength = 2; - break; - case Binary.Operator.LessThan: - result.Operator = BinaryOperatorType.LessThan; - break; - case Binary.Operator.GreaterThan: - result.Operator = BinaryOperatorType.GreaterThan; - break; - case Binary.Operator.LessThanOrEqual: - result.Operator = BinaryOperatorType.LessThanOrEqual; - opLength = 2; - break; - case Binary.Operator.GreaterThanOrEqual: - result.Operator = BinaryOperatorType.GreaterThanOrEqual; - opLength = 2; - break; - case Binary.Operator.Equality: - result.Operator = BinaryOperatorType.Equality; - opLength = 2; - break; - case Binary.Operator.Inequality: - result.Operator = BinaryOperatorType.InEquality; - opLength = 2; - break; - case Binary.Operator.BitwiseAnd: - result.Operator = BinaryOperatorType.BitwiseAnd; - break; - case Binary.Operator.ExclusiveOr: - result.Operator = BinaryOperatorType.ExclusiveOr; - break; - case Binary.Operator.BitwiseOr: - result.Operator = BinaryOperatorType.BitwiseOr; - break; - case Binary.Operator.LogicalAnd: - result.Operator = BinaryOperatorType.ConditionalAnd; - opLength = 2; - break; - case Binary.Operator.LogicalOr: - result.Operator = BinaryOperatorType.ConditionalOr; - opLength = 2; - break; - } - - result.AddChild ((Expression)binaryExpression.Left.Accept (this), BinaryOperatorExpression.LeftRole); - result.AddChild (new CSharpTokenNode (Convert (binaryExpression.Location), opLength), BinaryOperatorExpression.OperatorRole); - result.AddChild ((Expression)binaryExpression.Right.Accept (this), BinaryOperatorExpression.RightRole); + case Binary.Operator.Multiply: + result.Operator = BinaryOperatorType.Multiply; + break; + case Binary.Operator.Division: + result.Operator = BinaryOperatorType.Divide; + break; + case Binary.Operator.Modulus: + result.Operator = BinaryOperatorType.Modulus; + break; + case Binary.Operator.Addition: + result.Operator = BinaryOperatorType.Add; + break; + case Binary.Operator.Subtraction: + result.Operator = BinaryOperatorType.Subtract; + break; + case Binary.Operator.LeftShift: + result.Operator = BinaryOperatorType.ShiftLeft; + break; + case Binary.Operator.RightShift: + result.Operator = BinaryOperatorType.ShiftRight; + break; + case Binary.Operator.LessThan: + result.Operator = BinaryOperatorType.LessThan; + break; + case Binary.Operator.GreaterThan: + result.Operator = BinaryOperatorType.GreaterThan; + break; + case Binary.Operator.LessThanOrEqual: + result.Operator = BinaryOperatorType.LessThanOrEqual; + break; + case Binary.Operator.GreaterThanOrEqual: + result.Operator = BinaryOperatorType.GreaterThanOrEqual; + break; + case Binary.Operator.Equality: + result.Operator = BinaryOperatorType.Equality; + break; + case Binary.Operator.Inequality: + result.Operator = BinaryOperatorType.InEquality; + break; + case Binary.Operator.BitwiseAnd: + result.Operator = BinaryOperatorType.BitwiseAnd; + break; + case Binary.Operator.ExclusiveOr: + result.Operator = BinaryOperatorType.ExclusiveOr; + break; + case Binary.Operator.BitwiseOr: + result.Operator = BinaryOperatorType.BitwiseOr; + break; + case Binary.Operator.LogicalAnd: + result.Operator = BinaryOperatorType.ConditionalAnd; + break; + case Binary.Operator.LogicalOr: + result.Operator = BinaryOperatorType.ConditionalOr; + break; + } + + if (binaryExpression.Left != null) + result.AddChild ((Expression)binaryExpression.Left.Accept (this), BinaryOperatorExpression.LeftRole); + result.AddChild (new CSharpTokenNode (Convert (binaryExpression.Location)), BinaryOperatorExpression.GetOperatorRole (result.Operator)); + if (binaryExpression.Right != null) + result.AddChild ((Expression)binaryExpression.Right.Accept (this), BinaryOperatorExpression.RightRole); return result; } @@ -2248,9 +2389,11 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new BinaryOperatorExpression (); result.Operator = BinaryOperatorType.NullCoalescing; - result.AddChild ((Expression)nullCoalescingOperator.LeftExpression.Accept (this), BinaryOperatorExpression.LeftRole); - result.AddChild (new CSharpTokenNode (Convert (nullCoalescingOperator.Location), 2), BinaryOperatorExpression.OperatorRole); - result.AddChild ((Expression)nullCoalescingOperator.RightExpression.Accept (this), BinaryOperatorExpression.RightRole); + if (nullCoalescingOperator.LeftExpression != null) + result.AddChild ((Expression)nullCoalescingOperator.LeftExpression.Accept (this), BinaryOperatorExpression.LeftRole); + result.AddChild (new CSharpTokenNode (Convert (nullCoalescingOperator.Location)), BinaryOperatorExpression.NullCoalescingRole); + if (nullCoalescingOperator.RightExpression != null) + result.AddChild ((Expression)nullCoalescingOperator.RightExpression.Accept (this), BinaryOperatorExpression.RightRole); return result; } @@ -2258,14 +2401,17 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new ConditionalExpression (); - result.AddChild ((Expression)conditionalExpression.Expr.Accept (this), ConditionalExpression.Roles.Condition); + if (conditionalExpression.Expr != null) + result.AddChild ((Expression)conditionalExpression.Expr.Accept (this), Roles.Condition); var location = LocationsBag.GetLocations (conditionalExpression); - result.AddChild (new CSharpTokenNode (Convert (conditionalExpression.Location), 1), ConditionalExpression.QuestionMarkRole); - result.AddChild ((Expression)conditionalExpression.TrueExpr.Accept (this), ConditionalExpression.TrueRole); + result.AddChild (new CSharpTokenNode (Convert (conditionalExpression.Location)), ConditionalExpression.QuestionMarkRole); + if (conditionalExpression.TrueExpr != null) + result.AddChild ((Expression)conditionalExpression.TrueExpr.Accept (this), ConditionalExpression.TrueRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), ConditionalExpression.ColonRole); - result.AddChild ((Expression)conditionalExpression.FalseExpr.Accept (this), ConditionalExpression.FalseRole); + result.AddChild (new CSharpTokenNode (Convert (location [0])), ConditionalExpression.ColonRole); + if (conditionalExpression.FalseExpr != null) + result.AddChild ((Expression)conditionalExpression.FalseExpr.Accept (this), ConditionalExpression.FalseRole); return result; } @@ -2286,39 +2432,39 @@ namespace ICSharpCode.NRefactory.CSharp case Parameter.Modifier.OUT: parameterDeclarationExpression.ParameterModifier = ParameterModifier.Out; if (location != null) - parameterDeclarationExpression.AddChild (new CSharpTokenNode (Convert (location [0]), "out".Length), ParameterDeclaration.Roles.Keyword); + parameterDeclarationExpression.AddChild (new CSharpTokenNode (Convert (location [0])), ParameterDeclaration.OutModifierRole); break; case Parameter.Modifier.REF: parameterDeclarationExpression.ParameterModifier = ParameterModifier.Ref; if (location != null) - parameterDeclarationExpression.AddChild (new CSharpTokenNode (Convert (location [0]), "ref".Length), ParameterDeclaration.Roles.Keyword); + parameterDeclarationExpression.AddChild (new CSharpTokenNode (Convert (location [0])), ParameterDeclaration.RefModifierRole); break; case Parameter.Modifier.PARAMS: parameterDeclarationExpression.ParameterModifier = ParameterModifier.Params; if (location != null) - parameterDeclarationExpression.AddChild (new CSharpTokenNode (Convert (location [0]), "params".Length), ParameterDeclaration.Roles.Keyword); + parameterDeclarationExpression.AddChild (new CSharpTokenNode (Convert (location [0])), ParameterDeclaration.ParamsModifierRole); break; default: if (p.HasExtensionMethodModifier) { parameterDeclarationExpression.ParameterModifier = ParameterModifier.This; if (location != null) { - parameterDeclarationExpression.AddChild (new CSharpTokenNode (Convert (location [0]), "this".Length), ParameterDeclaration.Roles.Keyword); + parameterDeclarationExpression.AddChild (new CSharpTokenNode (Convert (location [0])), ParameterDeclaration.ThisModifierRole); } } break; } if (p.TypeExpression != null) // lambdas may have no types (a, b) => ... - parameterDeclarationExpression.AddChild (ConvertToType (p.TypeExpression), ParameterDeclaration.Roles.Type); + parameterDeclarationExpression.AddChild (ConvertToType (p.TypeExpression), Roles.Type); if (p.Name != null) - parameterDeclarationExpression.AddChild (Identifier.Create (p.Name, Convert (p.Location)), ParameterDeclaration.Roles.Identifier); + parameterDeclarationExpression.AddChild (Identifier.Create (p.Name, Convert (p.Location)), Roles.Identifier); if (p.HasDefaultValue) { - if (location != null) - parameterDeclarationExpression.AddChild (new CSharpTokenNode (Convert (location [1]), 1), ParameterDeclaration.Roles.Assign); - parameterDeclarationExpression.AddChild ((Expression)p.DefaultValue.Accept (this), ParameterDeclaration.Roles.Expression); + if (location != null && location.Count > 1) + parameterDeclarationExpression.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.Assign); + parameterDeclarationExpression.AddChild ((Expression)p.DefaultValue.Accept (this), Roles.Expression); } - parent.AddChild (parameterDeclarationExpression, InvocationExpression.Roles.Parameter); + parent.AddChild (parameterDeclarationExpression, Roles.Parameter); if (paramLocation != null && i < paramLocation.Count) { - parent.AddChild (new CSharpTokenNode (Convert (paramLocation [i]), 1), ParameterDeclaration.Roles.Comma); + parent.AddChild (new CSharpTokenNode (Convert (paramLocation [i])), Roles.Comma); } } } @@ -2329,14 +2475,14 @@ namespace ICSharpCode.NRefactory.CSharp return; var chevronLocs = LocationsBag.GetLocations (memberName.TypeParameters); if (chevronLocs != null) - parent.AddChild (new CSharpTokenNode (Convert (chevronLocs[chevronLocs.Count - 2]), 1), InvocationExpression.Roles.LChevron); + parent.AddChild (new CSharpTokenNode (Convert (chevronLocs [chevronLocs.Count - 2])), Roles.LChevron); for (int i = 0; i < memberName.TypeParameters.Count; i++) { if (chevronLocs != null && i > 0 && i - 1 < chevronLocs.Count) - parent.AddChild (new CSharpTokenNode (Convert (chevronLocs[i - 1]), 1), InvocationExpression.Roles.Comma); - var arg = memberName.TypeParameters[i]; + parent.AddChild (new CSharpTokenNode (Convert (chevronLocs [i - 1])), Roles.Comma); + var arg = memberName.TypeParameters [i]; if (arg == null) continue; - TypeParameterDeclaration tp = new TypeParameterDeclaration(); + TypeParameterDeclaration tp = new TypeParameterDeclaration (); List varianceLocation; switch (arg.Variance) { @@ -2344,13 +2490,13 @@ namespace ICSharpCode.NRefactory.CSharp tp.Variance = VarianceModifier.Contravariant; varianceLocation = LocationsBag.GetLocations (arg); if (varianceLocation != null) - tp.AddChild (new CSharpTokenNode (Convert (varianceLocation[0]), "out".Length), TypeParameterDeclaration.VarianceRole); + tp.AddChild (new CSharpTokenNode (Convert (varianceLocation [0])), TypeParameterDeclaration.InVarianceKeywordRole); break; case Variance.Covariant: tp.Variance = VarianceModifier.Covariant; varianceLocation = LocationsBag.GetLocations (arg); if (varianceLocation != null) - tp.AddChild (new CSharpTokenNode (Convert (varianceLocation[0]), "out".Length), TypeParameterDeclaration.VarianceRole); + tp.AddChild (new CSharpTokenNode (Convert (varianceLocation [0])), TypeParameterDeclaration.OutVarianceKeywordRole); break; default: tp.Variance = VarianceModifier.Invariant; @@ -2361,18 +2507,18 @@ namespace ICSharpCode.NRefactory.CSharp AddAttributeSection (tp, arg.OptAttributes); switch (arg.Variance) { - case Variance.Covariant: - tp.Variance = VarianceModifier.Covariant; - break; - case Variance.Contravariant: - tp.Variance = VarianceModifier.Contravariant; - break; + case Variance.Covariant: + tp.Variance = VarianceModifier.Covariant; + break; + case Variance.Contravariant: + tp.Variance = VarianceModifier.Contravariant; + break; } - tp.AddChild (Identifier.Create (arg.Name, Convert (arg.Location)), InvocationExpression.Roles.Identifier); - parent.AddChild (tp, InvocationExpression.Roles.TypeParameter); + tp.AddChild (Identifier.Create (arg.Name, Convert (arg.Location)), Roles.Identifier); + parent.AddChild (tp, Roles.TypeParameter); } if (chevronLocs != null) - parent.AddChild (new CSharpTokenNode (Convert (chevronLocs[chevronLocs.Count - 1]), 1), InvocationExpression.Roles.RChevron); + parent.AddChild (new CSharpTokenNode (Convert (chevronLocs [chevronLocs.Count - 1])), Roles.RChevron); } void AddTypeArguments (AstNode parent, MemberName memberName) @@ -2381,19 +2527,19 @@ namespace ICSharpCode.NRefactory.CSharp return; var chevronLocs = LocationsBag.GetLocations (memberName.TypeParameters); if (chevronLocs != null) - parent.AddChild (new CSharpTokenNode (Convert (chevronLocs[chevronLocs.Count - 2]), 1), InvocationExpression.Roles.LChevron); + parent.AddChild (new CSharpTokenNode (Convert (chevronLocs [chevronLocs.Count - 2])), Roles.LChevron); for (int i = 0; i < memberName.TypeParameters.Count; i++) { - var arg = memberName.TypeParameters[i]; + var arg = memberName.TypeParameters [i]; if (arg == null) continue; - parent.AddChild (ConvertToType (arg), InvocationExpression.Roles.TypeArgument); + parent.AddChild (ConvertToType (arg), Roles.TypeArgument); if (chevronLocs != null && i < chevronLocs.Count - 2) - parent.AddChild (new CSharpTokenNode (Convert (chevronLocs[i]), 1), InvocationExpression.Roles.Comma); + parent.AddChild (new CSharpTokenNode (Convert (chevronLocs [i])), Roles.Comma); } if (chevronLocs != null) - parent.AddChild (new CSharpTokenNode (Convert (chevronLocs[chevronLocs.Count - 1]), 1), InvocationExpression.Roles.RChevron); + parent.AddChild (new CSharpTokenNode (Convert (chevronLocs [chevronLocs.Count - 1])), Roles.RChevron); } void AddTypeArguments (AstNode parent, ATypeNameExpression memberName) @@ -2402,27 +2548,27 @@ namespace ICSharpCode.NRefactory.CSharp return; var chevronLocs = LocationsBag.GetLocations (memberName.TypeArguments); if (chevronLocs != null) - parent.AddChild (new CSharpTokenNode (Convert (chevronLocs[chevronLocs.Count - 2]), 1), InvocationExpression.Roles.LChevron); + parent.AddChild (new CSharpTokenNode (Convert (chevronLocs [chevronLocs.Count - 2])), Roles.LChevron); for (int i = 0; i < memberName.TypeArguments.Count; i++) { - var arg = memberName.TypeArguments.Args[i]; + var arg = memberName.TypeArguments.Args [i]; if (arg == null) continue; - parent.AddChild (ConvertToType (arg), InvocationExpression.Roles.TypeArgument); + parent.AddChild (ConvertToType (arg), Roles.TypeArgument); if (chevronLocs != null && i < chevronLocs.Count - 2) - parent.AddChild (new CSharpTokenNode (Convert (chevronLocs[i]), 1), InvocationExpression.Roles.Comma); + parent.AddChild (new CSharpTokenNode (Convert (chevronLocs [i])), Roles.Comma); } if (chevronLocs != null) - parent.AddChild (new CSharpTokenNode (Convert (chevronLocs[chevronLocs.Count - 1]), 1), InvocationExpression.Roles.RChevron); + parent.AddChild (new CSharpTokenNode (Convert (chevronLocs [chevronLocs.Count - 1])), Roles.RChevron); } - void AddConstraints (AstNode parent, TypeParameters d) + void AddConstraints(AstNode parent, TypeParameters d) { if (d == null) return; for (int i = d.Count - 1; i >= 0; i--) { - var typeParameter = d[i]; + var typeParameter = d [i]; if (typeParameter == null) continue; var c = typeParameter.Constraints; @@ -2430,18 +2576,21 @@ namespace ICSharpCode.NRefactory.CSharp continue; var location = LocationsBag.GetLocations (c); var constraint = new Constraint (); - constraint.AddChild (new CSharpTokenNode (Convert (c.Location), "where".Length), InvocationExpression.Roles.Keyword); - constraint.AddChild (new SimpleType (Identifier.Create (c.TypeParameter.Value, Convert (c.TypeParameter.Location))), Constraint.TypeParameterRole); + constraint.AddChild (new CSharpTokenNode (Convert (c.Location)), Roles.WhereKeyword); + constraint.AddChild (new SimpleType (Identifier.Create (c.TypeParameter.Value, Convert (c.TypeParameter.Location))), Roles.ConstraintTypeParameter); if (location != null) - constraint.AddChild (new CSharpTokenNode (Convert (location [0]), 1), Constraint.ColonRole); + constraint.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.Colon); var commaLocs = LocationsBag.GetLocations (c.ConstraintExpressions); int curComma = 0; - foreach (var expr in c.ConstraintExpressions) { - constraint.AddChild (ConvertToType (expr), Constraint.BaseTypeRole); - if (commaLocs != null && curComma < commaLocs.Count) - constraint.AddChild (new CSharpTokenNode (Convert (commaLocs[curComma++]), 1), InvocationExpression.Roles.Comma); + if (c.ConstraintExpressions != null) { + foreach (var expr in c.ConstraintExpressions) { + constraint.AddChild (ConvertToType (expr), Roles.BaseType); + if (commaLocs != null && curComma < commaLocs.Count) + constraint.AddChild (new CSharpTokenNode (Convert (commaLocs [curComma++])), Roles.Comma); + } } - parent.AddChild (constraint, AstNode.Roles.Constraint); + + parent.AddChild (constraint, Roles.Constraint); } } @@ -2449,23 +2598,23 @@ namespace ICSharpCode.NRefactory.CSharp { if (arg is NamedArgument) { var na = (NamedArgument)arg; - NamedArgumentExpression newArg = new NamedArgumentExpression(); - newArg.AddChild (Identifier.Create (na.Name, Convert (na.Location)), NamedArgumentExpression.Roles.Identifier); + NamedArgumentExpression newArg = new NamedArgumentExpression (); + newArg.AddChild (Identifier.Create (na.Name, Convert (na.Location)), Roles.Identifier); var loc = LocationsBag.GetLocations (na); if (loc != null) - newArg.AddChild (new CSharpTokenNode (Convert (loc[0]), 1), NamedArgumentExpression.Roles.Colon); + newArg.AddChild (new CSharpTokenNode (Convert (loc [0])), Roles.Colon); if (arg.ArgType == Argument.AType.Out || arg.ArgType == Argument.AType.Ref) { DirectionExpression direction = new DirectionExpression (); direction.FieldDirection = arg.ArgType == Argument.AType.Out ? FieldDirection.Out : FieldDirection.Ref; var argLocation = LocationsBag.GetLocations (arg); if (argLocation != null) - direction.AddChild (new CSharpTokenNode (Convert (argLocation[0]), "123".Length), InvocationExpression.Roles.Keyword); - direction.AddChild ((Expression)arg.Expr.Accept (this), InvocationExpression.Roles.Expression); - newArg.AddChild (direction, NamedArgumentExpression.Roles.Expression); + direction.AddChild (new CSharpTokenNode (Convert (argLocation [0])), arg.ArgType == Argument.AType.Out ? DirectionExpression.OutKeywordRole : DirectionExpression.RefKeywordRole); + direction.AddChild ((Expression)arg.Expr.Accept (this), Roles.Expression); + newArg.AddChild (direction, Roles.Expression); } else { - newArg.AddChild ((Expression)na.Expr.Accept (this), NamedArgumentExpression.Roles.Expression); + newArg.AddChild ((Expression)na.Expr.Accept (this), Roles.Expression); } return newArg; } @@ -2475,8 +2624,8 @@ namespace ICSharpCode.NRefactory.CSharp direction.FieldDirection = arg.ArgType == Argument.AType.Out ? FieldDirection.Out : FieldDirection.Ref; var argLocation = LocationsBag.GetLocations (arg); if (argLocation != null) - direction.AddChild (new CSharpTokenNode (Convert (argLocation[0]), "123".Length), InvocationExpression.Roles.Keyword); - direction.AddChild ((Expression)arg.Expr.Accept (this), InvocationExpression.Roles.Expression); + direction.AddChild (new CSharpTokenNode (Convert (argLocation [0])), arg.ArgType == Argument.AType.Out ? DirectionExpression.OutKeywordRole : DirectionExpression.RefKeywordRole); + direction.AddChild ((Expression)arg.Expr.Accept (this), Roles.Expression); return direction; } @@ -2490,13 +2639,13 @@ namespace ICSharpCode.NRefactory.CSharp var commaLocations = LocationsBag.GetLocations (args); for (int i = 0; i < args.Count; i++) { - parent.AddChild (ConvertArgument (args[i]), InvocationExpression.Roles.Argument); + parent.AddChild (ConvertArgument (args [i]), Roles.Argument); if (commaLocations != null && i < commaLocations.Count) { - parent.AddChild (new CSharpTokenNode (Convert (commaLocations[i]), 1), InvocationExpression.Roles.Comma); + parent.AddChild (new CSharpTokenNode (Convert (commaLocations [i])), Roles.Comma); } } if (commaLocations != null && commaLocations.Count > args.Count) - parent.AddChild (new CSharpTokenNode (Convert (commaLocations[args.Count]), 1), InvocationExpression.Roles.Comma); + parent.AddChild (new CSharpTokenNode (Convert (commaLocations [args.Count])), Roles.Comma); } public override object Visit (Invocation invocationExpression) @@ -2504,13 +2653,13 @@ namespace ICSharpCode.NRefactory.CSharp var result = new InvocationExpression (); var location = LocationsBag.GetLocations (invocationExpression); if (invocationExpression.Exp != null) - result.AddChild ((Expression)invocationExpression.Exp.Accept (this), InvocationExpression.Roles.TargetExpression); + result.AddChild ((Expression)invocationExpression.Exp.Accept (this), Roles.TargetExpression); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), InvocationExpression.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); AddArguments (result, location, invocationExpression.Arguments); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), InvocationExpression.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); return result; } @@ -2518,16 +2667,16 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new ObjectCreateExpression (); var location = LocationsBag.GetLocations (newExpression); - result.AddChild (new CSharpTokenNode (Convert (newExpression.Location), "new".Length), ObjectCreateExpression.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (newExpression.Location)), ObjectCreateExpression.NewKeywordRole); if (newExpression.TypeRequested != null) - result.AddChild (ConvertToType (newExpression.TypeRequested), ObjectCreateExpression.Roles.Type); + result.AddChild (ConvertToType (newExpression.TypeRequested), Roles.Type); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), ObjectCreateExpression.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); AddArguments (result, location, newExpression.Arguments); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), ObjectCreateExpression.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); return result; } @@ -2538,18 +2687,20 @@ namespace ICSharpCode.NRefactory.CSharp if (newAnonymousType.Parameters == null) return result; foreach (var par in newAnonymousType.Parameters) { + if (par == null) + continue; var location = LocationsBag.GetLocations (par); if (location == null) { if (par.Expr != null) - result.AddChild ((Expression)par.Expr.Accept (this), AnonymousTypeCreateExpression.Roles.Expression); + result.AddChild ((Expression)par.Expr.Accept (this), Roles.Expression); } else { var namedExpression = new NamedExpression (); - namedExpression.AddChild (Identifier.Create (par.Name, Convert (par.Location)), AnonymousTypeCreateExpression.Roles.Identifier); - namedExpression.AddChild (new CSharpTokenNode (Convert (location[0]), 1), AnonymousTypeCreateExpression.Roles.Assign); + namedExpression.AddChild (Identifier.Create (par.Name, Convert (par.Location)), Roles.Identifier); + namedExpression.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.Assign); if (par.Expr != null) - namedExpression.AddChild ((Expression)par.Expr.Accept (this), AnonymousTypeCreateExpression.Roles.Expression); - result.AddChild (namedExpression, AnonymousTypeCreateExpression.Roles.Expression); + namedExpression.AddChild ((Expression)par.Expr.Accept (this), Roles.Expression); + result.AddChild (namedExpression, Roles.Expression); } } return result; @@ -2570,74 +2721,72 @@ namespace ICSharpCode.NRefactory.CSharp var commaLoc = LocationsBag.GetLocations (minit.Initializers); int curComma = 0; if (initLoc != null) - init.AddChild (new CSharpTokenNode (Convert (initLoc [0]), 1), ArrayInitializerExpression.Roles.LBrace); + init.AddChild (new CSharpTokenNode (Convert (initLoc [0])), Roles.LBrace); foreach (var expr in minit.Initializers) { var collectionInit = expr as CollectionElementInitializer; if (collectionInit != null) { var parent = new ArrayInitializerExpression (); - var braceLocs = LocationsBag.GetLocations (expr); - if (braceLocs != null) - parent.AddChild (new CSharpTokenNode (Convert (braceLocs [0]), 1), ArrayInitializerExpression.Roles.LBrace); - + parent.AddChild (new CSharpTokenNode (Convert (expr.Location)), Roles.LBrace); + for (int i = 0; i < collectionInit.Arguments.Count; i++) { var arg = collectionInit.Arguments [i] as CollectionElementInitializer.ElementInitializerArgument; if (arg == null) continue; - parent.AddChild ((ICSharpCode.NRefactory.CSharp.Expression)arg.Expr.Accept (this), ArrayInitializerExpression.Roles.Expression); + parent.AddChild ((ICSharpCode.NRefactory.CSharp.Expression)arg.Expr.Accept (this), Roles.Expression); } + var braceLocs = LocationsBag.GetLocations (expr); if (braceLocs != null) - parent.AddChild (new CSharpTokenNode (Convert (braceLocs [1]), 1), ArrayInitializerExpression.Roles.RBrace); + parent.AddChild (new CSharpTokenNode (Convert (braceLocs [0])), Roles.RBrace); - init.AddChild (parent, ArrayInitializerExpression.Roles.Expression); + init.AddChild (parent, Roles.Expression); } else { var eleInit = expr as ElementInitializer; if (eleInit != null) { var nexpr = new NamedExpression (); - nexpr.AddChild (Identifier.Create (eleInit.Name, Convert (eleInit.Location)), NamedArgumentExpression.Roles.Identifier); + nexpr.AddChild (Identifier.Create (eleInit.Name, Convert (eleInit.Location)), Roles.Identifier); var assignLoc = LocationsBag.GetLocations (eleInit); if (assignLoc != null) - nexpr.AddChild (new CSharpTokenNode (Convert (assignLoc [0]), 1), NamedArgumentExpression.Roles.Assign); + nexpr.AddChild (new CSharpTokenNode (Convert (assignLoc [0])), Roles.Assign); if (eleInit.Source != null) { if (eleInit.Source is CollectionOrObjectInitializers) { var arrInit = new ArrayInitializerExpression (); AddConvertCollectionOrObjectInitializers (arrInit, eleInit.Source as CollectionOrObjectInitializers); - nexpr.AddChild (arrInit, NamedArgumentExpression.Roles.Expression); + nexpr.AddChild (arrInit, Roles.Expression); } else { - nexpr.AddChild ((Expression)eleInit.Source.Accept (this), NamedArgumentExpression.Roles.Expression); + nexpr.AddChild ((Expression)eleInit.Source.Accept (this), Roles.Expression); } } - init.AddChild (nexpr, ArrayInitializerExpression.Roles.Expression); + init.AddChild (nexpr, Roles.Expression); } } if (commaLoc != null && curComma < commaLoc.Count) - init.AddChild (new CSharpTokenNode (Convert (commaLoc [curComma++]), 1), ArrayInitializerExpression.Roles.Comma); + init.AddChild (new CSharpTokenNode (Convert (commaLoc [curComma++])), Roles.Comma); } if (initLoc != null) { if (initLoc.Count == 3) // optional comma - init.AddChild (new CSharpTokenNode (Convert (initLoc [1]), 1), ArrayInitializerExpression.Roles.Comma); - init.AddChild (new CSharpTokenNode (Convert (initLoc [initLoc.Count - 1]), 1), ArrayInitializerExpression.Roles.RBrace); + init.AddChild (new CSharpTokenNode (Convert (initLoc [1])), Roles.Comma); + init.AddChild (new CSharpTokenNode (Convert (initLoc [initLoc.Count - 1])), Roles.RBrace); } } - public override object Visit (NewInitialize newInitializeExpression) { var result = new ObjectCreateExpression (); - result.AddChild (new CSharpTokenNode (Convert (newInitializeExpression.Location), "new".Length), ObjectCreateExpression.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (newInitializeExpression.Location)), ObjectCreateExpression.NewKeywordRole); if (newInitializeExpression.TypeRequested != null) - result.AddChild (ConvertToType (newInitializeExpression.TypeRequested), ObjectCreateExpression.Roles.Type); + result.AddChild (ConvertToType (newInitializeExpression.TypeRequested), Roles.Type); var location = LocationsBag.GetLocations (newInitializeExpression); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), ObjectCreateExpression.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); AddArguments (result, location, newInitializeExpression.Arguments); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), ObjectCreateExpression.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); var init = ConvertCollectionOrObjectInitializers (newInitializeExpression.Initializers); if (init != null) @@ -2646,15 +2795,14 @@ namespace ICSharpCode.NRefactory.CSharp return result; } - public override object Visit (ArrayCreation arrayCreationExpression) { var result = new ArrayCreateExpression (); var location = LocationsBag.GetLocations (arrayCreationExpression); - result.AddChild (new CSharpTokenNode (Convert (arrayCreationExpression.Location), "new".Length), ArrayCreateExpression.Roles.Keyword); - if (arrayCreationExpression.NewType != null) - result.AddChild (ConvertToType (arrayCreationExpression.NewType), ArrayCreateExpression.Roles.Type); + result.AddChild (new CSharpTokenNode (Convert (arrayCreationExpression.Location)), ArrayCreateExpression.NewKeywordRole); + if (arrayCreationExpression.TypeExpression != null) + result.AddChild (ConvertToType (arrayCreationExpression.TypeExpression), Roles.Type); var next = arrayCreationExpression.Rank; if (arrayCreationExpression.Arguments != null) { @@ -2662,47 +2810,47 @@ namespace ICSharpCode.NRefactory.CSharp next = next.Next; if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), ArrayCreateExpression.Roles.LBracket); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LBracket); var commaLocations = LocationsBag.GetLocations (arrayCreationExpression.Arguments); - for (int i = 0 ;i < arrayCreationExpression.Arguments.Count; i++) { - result.AddChild ((Expression)arrayCreationExpression.Arguments[i].Accept (this), ArrayCreateExpression.Roles.Argument); + for (int i = 0; i < arrayCreationExpression.Arguments.Count; i++) { + result.AddChild ((Expression)arrayCreationExpression.Arguments [i].Accept (this), Roles.Argument); if (commaLocations != null && i < commaLocations.Count) - result.AddChild (new CSharpTokenNode (Convert (commaLocations [i]), 1), ArrayCreateExpression.Roles.Comma); + result.AddChild (new CSharpTokenNode (Convert (commaLocations [i])), Roles.Comma); } if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), ArrayCreateExpression.Roles.RBracket); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RBracket); } while (next != null) { ArraySpecifier spec = new ArraySpecifier (next.Dimension); var loc = LocationsBag.GetLocations (next); - spec.AddChild (new CSharpTokenNode (Convert (next.Location), 1), ArraySpecifier.Roles.LBracket); + spec.AddChild (new CSharpTokenNode (Convert (next.Location)), Roles.LBracket); result.AddChild (spec, ArrayCreateExpression.AdditionalArraySpecifierRole); if (loc != null) - result.AddChild (new CSharpTokenNode (Convert (loc[0]), 1), ArraySpecifier.Roles.RBracket); + result.AddChild (new CSharpTokenNode (Convert (loc [0])), Roles.RBracket); next = next.Next; } if (arrayCreationExpression.Initializers != null && arrayCreationExpression.Initializers.Count != 0) { var initLocation = LocationsBag.GetLocations (arrayCreationExpression.Initializers); - ArrayInitializerExpression initializer = new ArrayInitializerExpression(); + ArrayInitializerExpression initializer = new ArrayInitializerExpression (); - initializer.AddChild (new CSharpTokenNode (Convert (arrayCreationExpression.Initializers.Location), 1), ArrayCreateExpression.Roles.LBrace); + initializer.AddChild (new CSharpTokenNode (Convert (arrayCreationExpression.Initializers.Location)), Roles.LBrace); var commaLocations = LocationsBag.GetLocations (arrayCreationExpression.Initializers.Elements); for (int i = 0; i < arrayCreationExpression.Initializers.Count; i++) { - var init = arrayCreationExpression.Initializers[i]; + var init = arrayCreationExpression.Initializers [i]; if (init == null) continue; - initializer.AddChild ((Expression)init.Accept (this), ArrayInitializerExpression.Roles.Expression); + initializer.AddChild ((Expression)init.Accept (this), Roles.Expression); if (commaLocations != null && i < commaLocations.Count) { - initializer.AddChild (new CSharpTokenNode (Convert (commaLocations [i]), 1), IndexerExpression.Roles.Comma); + initializer.AddChild (new CSharpTokenNode (Convert (commaLocations [i])), Roles.Comma); } } if (initLocation != null) - initializer.AddChild (new CSharpTokenNode (Convert (initLocation[initLocation.Count - 1]), 1), ArrayCreateExpression.Roles.RBrace); + initializer.AddChild (new CSharpTokenNode (Convert (initLocation [initLocation.Count - 1])), Roles.RBrace); result.AddChild (initializer, ArrayCreateExpression.InitializerRole); } @@ -2721,73 +2869,73 @@ namespace ICSharpCode.NRefactory.CSharp var result = new UndocumentedExpression () { UndocumentedExpressionType = UndocumentedExpressionType.ArgListAccess }; - result.AddChild (new CSharpTokenNode (Convert (argListAccessExpression.Location), "__arglist".Length), UndocumentedExpression.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (argListAccessExpression.Location)), UndocumentedExpression.ArglistKeywordRole); return result; } #region Undocumented expressions public override object Visit (Arglist argListExpression) { - var result = new UndocumentedExpression () { UndocumentedExpressionType = UndocumentedExpressionType.ArgListAccess }; - result.AddChild (new CSharpTokenNode (Convert (argListExpression.Location), "__arglist".Length), UndocumentedExpression.Roles.Keyword); + var result = new UndocumentedExpression () { UndocumentedExpressionType = UndocumentedExpressionType.ArgList }; + result.AddChild (new CSharpTokenNode (Convert (argListExpression.Location)), UndocumentedExpression.ArglistKeywordRole); var location = LocationsBag.GetLocations (argListExpression); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), UndocumentedExpression.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); AddArguments (result, location, argListExpression.Arguments); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), UndocumentedExpression.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); return result; } public override object Visit (MakeRefExpr makeRefExpr) { - var result = new UndocumentedExpression () { UndocumentedExpressionType = UndocumentedExpressionType.RefValue }; - result.AddChild (new CSharpTokenNode (Convert (makeRefExpr.Location), "__makeref".Length), UndocumentedExpression.Roles.Keyword); + var result = new UndocumentedExpression () { UndocumentedExpressionType = UndocumentedExpressionType.MakeRef }; + result.AddChild (new CSharpTokenNode (Convert (makeRefExpr.Location)), UndocumentedExpression.MakerefKeywordRole); var location = LocationsBag.GetLocations (makeRefExpr); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), UndocumentedExpression.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); if (makeRefExpr.Expr != null) - result.AddChild ((Expression)makeRefExpr.Expr.Accept (this), UndocumentedExpression.Roles.Argument); + result.AddChild ((Expression)makeRefExpr.Expr.Accept (this), Roles.Argument); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), UndocumentedExpression.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); return result; } public override object Visit (RefTypeExpr refTypeExpr) { - var result = new UndocumentedExpression () { UndocumentedExpressionType = UndocumentedExpressionType.RefValue }; - result.AddChild (new CSharpTokenNode (Convert (refTypeExpr.Location), "__reftype".Length), UndocumentedExpression.Roles.Keyword); + var result = new UndocumentedExpression () { UndocumentedExpressionType = UndocumentedExpressionType.RefType }; + result.AddChild (new CSharpTokenNode (Convert (refTypeExpr.Location)), UndocumentedExpression.ReftypeKeywordRole); var location = LocationsBag.GetLocations (refTypeExpr); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), UndocumentedExpression.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); if (refTypeExpr.Expr != null) - result.AddChild ((Expression)refTypeExpr.Expr.Accept (this), UndocumentedExpression.Roles.Argument); + result.AddChild ((Expression)refTypeExpr.Expr.Accept (this), Roles.Argument); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), UndocumentedExpression.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); return result; } public override object Visit (RefValueExpr refValueExpr) { var result = new UndocumentedExpression () { UndocumentedExpressionType = UndocumentedExpressionType.RefValue }; - result.AddChild (new CSharpTokenNode (Convert (refValueExpr.Location), "__refvalue".Length), UndocumentedExpression.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (refValueExpr.Location)), UndocumentedExpression.RefvalueKeywordRole); var location = LocationsBag.GetLocations (refValueExpr); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), UndocumentedExpression.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); if (refValueExpr.Expr != null) - result.AddChild ((Expression)refValueExpr.Expr.Accept (this), UndocumentedExpression.Roles.Argument); + result.AddChild ((Expression)refValueExpr.Expr.Accept (this), Roles.Argument); if (refValueExpr.FullNamedExpression != null) - result.AddChild ((Expression)refValueExpr.FullNamedExpression.Accept (this), UndocumentedExpression.Roles.Argument); + result.AddChild ((Expression)refValueExpr.FullNamedExpression.Accept (this), Roles.Argument); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), UndocumentedExpression.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); return result; } #endregion @@ -2796,12 +2944,13 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new TypeOfExpression (); var location = LocationsBag.GetLocations (typeOfExpression); - result.AddChild (new CSharpTokenNode (Convert (typeOfExpression.Location), "typeof".Length), TypeOfExpression.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (typeOfExpression.Location)), TypeOfExpression.TypeofKeywordRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), TypeOfExpression.Roles.LPar); - result.AddChild (ConvertToType (typeOfExpression.TypeExpression), TypeOfExpression.Roles.Type); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); + if (typeOfExpression.TypeExpression != null) + result.AddChild (ConvertToType (typeOfExpression.TypeExpression), Roles.Type); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), TypeOfExpression.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); return result; } @@ -2809,12 +2958,13 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new SizeOfExpression (); var location = LocationsBag.GetLocations (sizeOfExpression); - result.AddChild (new CSharpTokenNode (Convert (sizeOfExpression.Location), "sizeof".Length), TypeOfExpression.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (sizeOfExpression.Location)), SizeOfExpression.SizeofKeywordRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), TypeOfExpression.Roles.LPar); - result.AddChild (ConvertToType (sizeOfExpression.TypeExpression), TypeOfExpression.Roles.Type); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); + if (sizeOfExpression.TypeExpression != null) + result.AddChild (ConvertToType (sizeOfExpression.TypeExpression), Roles.Type); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), TypeOfExpression.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); return result; } @@ -2822,12 +2972,13 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new CheckedExpression (); var location = LocationsBag.GetLocations (checkedExpression); - result.AddChild (new CSharpTokenNode (Convert (checkedExpression.Location), "checked".Length), TypeOfExpression.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (checkedExpression.Location)), CheckedExpression.CheckedKeywordRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), TypeOfExpression.Roles.LPar); - result.AddChild ((Expression)checkedExpression.Expr.Accept (this), TypeOfExpression.Roles.Expression); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); + if (checkedExpression.Expr != null) + result.AddChild ((Expression)checkedExpression.Expr.Accept (this), Roles.Expression); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), TypeOfExpression.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); return result; } @@ -2835,12 +2986,13 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new UncheckedExpression (); var location = LocationsBag.GetLocations (uncheckedExpression); - result.AddChild (new CSharpTokenNode (Convert (uncheckedExpression.Location), "unchecked".Length), TypeOfExpression.Roles.Keyword); - if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), TypeOfExpression.Roles.LPar); - result.AddChild ((Expression)uncheckedExpression.Expr.Accept (this), TypeOfExpression.Roles.Expression); + result.AddChild (new CSharpTokenNode (Convert (uncheckedExpression.Location)), UncheckedExpression.UncheckedKeywordRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), TypeOfExpression.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.LPar); + if (uncheckedExpression.Expr != null) + result.AddChild ((Expression)uncheckedExpression.Expr.Accept (this), Roles.Expression); + if (location != null && location.Count > 1) + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.RPar); return result; } @@ -2849,11 +3001,12 @@ namespace ICSharpCode.NRefactory.CSharp IndexerExpression result = new IndexerExpression (); var location = LocationsBag.GetLocations (elementAccessExpression); - result.AddChild ((Expression)elementAccessExpression.Expr.Accept (this), IndexerExpression.Roles.TargetExpression); - result.AddChild (new CSharpTokenNode (Convert (elementAccessExpression.Location), 1), TypeOfExpression.Roles.LBracket); + if (elementAccessExpression.Expr != null) + result.AddChild ((Expression)elementAccessExpression.Expr.Accept (this), Roles.TargetExpression); + result.AddChild (new CSharpTokenNode (Convert (elementAccessExpression.Location)), Roles.LBracket); AddArguments (result, location, elementAccessExpression.Arguments); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), TypeOfExpression.Roles.RBracket); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.RBracket); return result; } @@ -2870,13 +3023,15 @@ namespace ICSharpCode.NRefactory.CSharp var location = LocationsBag.GetLocations (stackAllocExpression); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), "stackalloc".Length), StackAllocExpression.Roles.Keyword); - result.AddChild (ConvertToType (stackAllocExpression.TypeExpression), StackAllocExpression.Roles.Type); + result.AddChild (new CSharpTokenNode (Convert (location [0])), StackAllocExpression.StackallocKeywordRole); + if (stackAllocExpression.TypeExpression != null) + result.AddChild (ConvertToType (stackAllocExpression.TypeExpression), Roles.Type); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), 1), StackAllocExpression.Roles.LBracket); - result.AddChild ((Expression)stackAllocExpression.CountExpression.Accept (this), StackAllocExpression.Roles.Expression); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.LBracket); + if (stackAllocExpression.CountExpression != null) + result.AddChild ((Expression)stackAllocExpression.CountExpression.Accept (this), Roles.Expression); if (location != null && location.Count > 2) - result.AddChild (new CSharpTokenNode (Convert (location[2]), 1), StackAllocExpression.Roles.RBracket); + result.AddChild (new CSharpTokenNode (Convert (location [2])), Roles.RBracket); return result; } @@ -2887,7 +3042,7 @@ namespace ICSharpCode.NRefactory.CSharp result.Operator = AssignmentOperatorType.Assign; if (simpleAssign.Target != null) result.AddChild ((Expression)simpleAssign.Target.Accept (this), AssignmentExpression.LeftRole); - result.AddChild (new CSharpTokenNode (Convert (simpleAssign.Location), 1), AssignmentExpression.OperatorRole); + result.AddChild (new CSharpTokenNode (Convert (simpleAssign.Location)), AssignmentExpression.AssignRole); if (simpleAssign.Source != null) { result.AddChild ((Expression)simpleAssign.Source.Accept (this), AssignmentExpression.RightRole); } @@ -2897,45 +3052,44 @@ namespace ICSharpCode.NRefactory.CSharp public override object Visit (CompoundAssign compoundAssign) { var result = new AssignmentExpression (); - int opLength = 2; switch (compoundAssign.Op) { - case Binary.Operator.Multiply: - result.Operator = AssignmentOperatorType.Multiply; - break; - case Binary.Operator.Division: - result.Operator = AssignmentOperatorType.Divide; - break; - case Binary.Operator.Modulus: - result.Operator = AssignmentOperatorType.Modulus; - break; - case Binary.Operator.Addition: - result.Operator = AssignmentOperatorType.Add; - break; - case Binary.Operator.Subtraction: - result.Operator = AssignmentOperatorType.Subtract; - break; - case Binary.Operator.LeftShift: - result.Operator = AssignmentOperatorType.ShiftLeft; - opLength = 3; - break; - case Binary.Operator.RightShift: - result.Operator = AssignmentOperatorType.ShiftRight; - opLength = 3; - break; - case Binary.Operator.BitwiseAnd: - result.Operator = AssignmentOperatorType.BitwiseAnd; - break; - case Binary.Operator.BitwiseOr: - result.Operator = AssignmentOperatorType.BitwiseOr; - break; - case Binary.Operator.ExclusiveOr: - result.Operator = AssignmentOperatorType.ExclusiveOr; - break; - } - - result.AddChild ((Expression)compoundAssign.Target.Accept (this), AssignmentExpression.LeftRole); - result.AddChild (new CSharpTokenNode (Convert (compoundAssign.Location), opLength), AssignmentExpression.OperatorRole); - result.AddChild ((Expression)compoundAssign.Source.Accept (this), AssignmentExpression.RightRole); + case Binary.Operator.Multiply: + result.Operator = AssignmentOperatorType.Multiply; + break; + case Binary.Operator.Division: + result.Operator = AssignmentOperatorType.Divide; + break; + case Binary.Operator.Modulus: + result.Operator = AssignmentOperatorType.Modulus; + break; + case Binary.Operator.Addition: + result.Operator = AssignmentOperatorType.Add; + break; + case Binary.Operator.Subtraction: + result.Operator = AssignmentOperatorType.Subtract; + break; + case Binary.Operator.LeftShift: + result.Operator = AssignmentOperatorType.ShiftLeft; + break; + case Binary.Operator.RightShift: + result.Operator = AssignmentOperatorType.ShiftRight; + break; + case Binary.Operator.BitwiseAnd: + result.Operator = AssignmentOperatorType.BitwiseAnd; + break; + case Binary.Operator.BitwiseOr: + result.Operator = AssignmentOperatorType.BitwiseOr; + break; + case Binary.Operator.ExclusiveOr: + result.Operator = AssignmentOperatorType.ExclusiveOr; + break; + } + + if (compoundAssign.Target != null) + result.AddChild ((Expression)compoundAssign.Target.Accept (this), AssignmentExpression.LeftRole); + result.AddChild (new CSharpTokenNode (Convert (compoundAssign.Location)), AssignmentExpression.GetOperatorRole (result.Operator)); + if (compoundAssign.Source != null) + result.AddChild ((Expression)compoundAssign.Source.Accept (this), AssignmentExpression.RightRole); return result; } @@ -2946,19 +3100,20 @@ namespace ICSharpCode.NRefactory.CSharp int l = 0; if (anonymousMethodExpression.IsAsync) { result.IsAsync = true; - result.AddChild (new CSharpTokenNode (Convert (location[l++]), "async".Length), AnonymousMethodExpression.AsyncModifierRole); + result.AddChild (new CSharpTokenNode (Convert (location [l++])), AnonymousMethodExpression.AsyncModifierRole); } if (location != null) { - result.AddChild (new CSharpTokenNode (Convert (location[l++]), "delegate".Length), AnonymousMethodExpression.Roles.Keyword); + result.AddChild (new CSharpTokenNode (Convert (location [l++])), AnonymousMethodExpression.DelegateKeywordRole); if (location.Count > l) { result.HasParameterList = true; - result.AddChild (new CSharpTokenNode (Convert (location[l++]), 1), AnonymousMethodExpression.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (location [l++])), Roles.LPar); AddParameter (result, anonymousMethodExpression.Parameters); - result.AddChild (new CSharpTokenNode (Convert (location[l++]), 1), AnonymousMethodExpression.Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [l++])), Roles.RPar); } } - result.AddChild ((BlockStatement)anonymousMethodExpression.Block.Accept (this), AnonymousMethodExpression.Roles.Body); + if (anonymousMethodExpression.Block != null) + result.AddChild ((BlockStatement)anonymousMethodExpression.Block.Accept (this), Roles.Body); return result; } @@ -2969,19 +3124,19 @@ namespace ICSharpCode.NRefactory.CSharp int l = 0; if (lambdaExpression.IsAsync) { result.IsAsync = true; - result.AddChild (new CSharpTokenNode (Convert (location [l++]), "async".Length), LambdaExpression.AsyncModifierRole); + result.AddChild (new CSharpTokenNode (Convert (location [l++])), LambdaExpression.AsyncModifierRole); } if (location == null || location.Count == l + 1) { AddParameter (result, lambdaExpression.Parameters); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location [l++]), "=>".Length), LambdaExpression.ArrowRole); + result.AddChild (new CSharpTokenNode (Convert (location [l++])), LambdaExpression.ArrowRole); } else { - result.AddChild (new CSharpTokenNode (Convert (location [l++]), 1), LambdaExpression.Roles.LPar); + result.AddChild (new CSharpTokenNode (Convert (location [l++])), Roles.LPar); AddParameter (result, lambdaExpression.Parameters); if (location != null) { - result.AddChild (new CSharpTokenNode (Convert (location [l++]), 1), LambdaExpression.Roles.RPar); - result.AddChild (new CSharpTokenNode (Convert (location [l++]), "=>".Length), LambdaExpression.ArrowRole); + result.AddChild (new CSharpTokenNode (Convert (location [l++])), Roles.RPar); + result.AddChild (new CSharpTokenNode (Convert (location [l++])), LambdaExpression.ArrowRole); } } if (lambdaExpression.Block != null) { @@ -3005,21 +3160,21 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new ArrayInitializerExpression (); var location = LocationsBag.GetLocations (arrayInitializer); - result.AddChild (new CSharpTokenNode (Convert (arrayInitializer.Location), "{".Length), ArrayInitializerExpression.Roles.LBrace); + result.AddChild (new CSharpTokenNode (Convert (arrayInitializer.Location)), Roles.LBrace); var commaLocations = LocationsBag.GetLocations (arrayInitializer.Elements); for (int i = 0; i < arrayInitializer.Count; i++) { - var init = arrayInitializer[i]; + var init = arrayInitializer [i]; if (init == null) continue; - result.AddChild ((Expression)init.Accept (this), ArrayInitializerExpression.Roles.Expression); + result.AddChild ((Expression)init.Accept (this), Roles.Expression); if (commaLocations != null && i < commaLocations.Count) - result.AddChild (new CSharpTokenNode (Convert (commaLocations[i]), ",".Length), ArrayInitializerExpression.Roles.Comma); + result.AddChild (new CSharpTokenNode (Convert (commaLocations [i])), Roles.Comma); } if (location != null) { if (location.Count == 2) // optional comma - result.AddChild (new CSharpTokenNode (Convert (location[1]), ",".Length), ArrayInitializerExpression.Roles.Comma); - result.AddChild (new CSharpTokenNode (Convert (location[location.Count - 1]), "}".Length), ArrayInitializerExpression.Roles.RBrace); + result.AddChild (new CSharpTokenNode (Convert (location [1])), Roles.Comma); + result.AddChild (new CSharpTokenNode (Convert (location [location.Count - 1])), Roles.RBrace); } return result; } @@ -3037,9 +3192,9 @@ namespace ICSharpCode.NRefactory.CSharp QueryClause clause = (QueryClause)currentClause.Accept (this); if (clause is QueryContinuationClause) { // insert preceding query at beginning of QueryContinuationClause - clause.InsertChildAfter(null, result, QueryContinuationClause.PrecedingQueryRole); + clause.InsertChildAfter (null, result, QueryContinuationClause.PrecedingQueryRole); // create a new QueryExpression for the remaining query - result = new QueryExpression(); + result = new QueryExpression (); } result.AddChild (clause, QueryExpression.ClauseRole); currentClause = currentClause.next; @@ -3052,50 +3207,55 @@ namespace ICSharpCode.NRefactory.CSharp { if (queryStart.Expr == null) { var intoClause = new QueryContinuationClause (); - intoClause.AddChild (new CSharpTokenNode (Convert (queryStart.Location), "into".Length), QueryContinuationClause.IntoKeywordRole); - intoClause.AddChild (Identifier.Create (queryStart.IntoVariable.Name, Convert(queryStart.IntoVariable.Location)), QueryContinuationClause.Roles.Identifier); + intoClause.AddChild (new CSharpTokenNode (Convert (queryStart.Location)), QueryContinuationClause.IntoKeywordRole); + intoClause.AddChild (Identifier.Create (queryStart.IntoVariable.Name, Convert (queryStart.IntoVariable.Location)), Roles.Identifier); return intoClause; } var fromClause = new QueryFromClause (); - var location = LocationsBag.GetLocations (queryStart); - - fromClause.AddChild (new CSharpTokenNode (Convert (queryStart.Location), "from".Length), QueryFromClause.FromKeywordRole); + + fromClause.AddChild (new CSharpTokenNode (Convert (queryStart.Location)), QueryFromClause.FromKeywordRole); if (queryStart.IdentifierType != null) - fromClause.AddChild (ConvertToType (queryStart.IdentifierType), QueryFromClause.Roles.Type); + fromClause.AddChild (ConvertToType (queryStart.IdentifierType), Roles.Type); - fromClause.AddChild (Identifier.Create (queryStart.IntoVariable.Name, Convert(queryStart.IntoVariable.Location)), QueryFromClause.Roles.Identifier); + fromClause.AddChild (Identifier.Create (queryStart.IntoVariable.Name, Convert (queryStart.IntoVariable.Location)), Roles.Identifier); + var location = LocationsBag.GetLocations (queryStart); if (location != null) - fromClause.AddChild (new CSharpTokenNode (Convert (location[0]), "in".Length), QueryFromClause.InKeywordRole); - fromClause.AddChild ((Expression)queryStart.Expr.Accept (this), QueryFromClause.Roles.Expression); + fromClause.AddChild (new CSharpTokenNode (Convert (location [0])), QueryFromClause.InKeywordRole); + + if (queryStart.Expr != null) + fromClause.AddChild ((Expression)queryStart.Expr.Accept (this), Roles.Expression); return fromClause; } public override object Visit (Mono.CSharp.Linq.SelectMany queryStart) { var fromClause = new QueryFromClause (); - var location = LocationsBag.GetLocations (queryStart); - - fromClause.AddChild (new CSharpTokenNode (Convert (queryStart.Location), "from".Length), QueryFromClause.FromKeywordRole); + + fromClause.AddChild (new CSharpTokenNode (Convert (queryStart.Location)), QueryFromClause.FromKeywordRole); if (queryStart.IdentifierType != null) - fromClause.AddChild (ConvertToType (queryStart.IdentifierType), QueryFromClause.Roles.Type); + fromClause.AddChild (ConvertToType (queryStart.IdentifierType), Roles.Type); - fromClause.AddChild (Identifier.Create (queryStart.IntoVariable.Name, Convert(queryStart.IntoVariable.Location)), QueryFromClause.Roles.Identifier); + fromClause.AddChild (Identifier.Create (queryStart.IntoVariable.Name, Convert (queryStart.IntoVariable.Location)), Roles.Identifier); + var location = LocationsBag.GetLocations (queryStart); if (location != null) - fromClause.AddChild (new CSharpTokenNode (Convert (location[0]), "in".Length), QueryFromClause.InKeywordRole); - fromClause.AddChild ((Expression)queryStart.Expr.Accept (this), QueryFromClause.Roles.Expression); + fromClause.AddChild (new CSharpTokenNode (Convert (location [0])), QueryFromClause.InKeywordRole); + + if (queryStart.Expr != null) + fromClause.AddChild ((Expression)queryStart.Expr.Accept (this), Roles.Expression); return fromClause; } public override object Visit (Mono.CSharp.Linq.Select sel) { var result = new QuerySelectClause (); - result.AddChild (new CSharpTokenNode (Convert (sel.Location), "select".Length), QueryWhereClause.Roles.Keyword); - result.AddChild ((Expression)sel.Expr.Accept (this), QueryWhereClause.Roles.Expression); + result.AddChild (new CSharpTokenNode (Convert (sel.Location)), QuerySelectClause.SelectKeywordRole); + if (sel.Expr != null) + result.AddChild ((Expression)sel.Expr.Accept (this), Roles.Expression); return result; } @@ -3103,11 +3263,13 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new QueryGroupClause (); var location = LocationsBag.GetLocations (groupBy); - result.AddChild (new CSharpTokenNode (Convert (groupBy.Location), "group".Length), QueryGroupClause.GroupKeywordRole); - result.AddChild ((Expression)groupBy.ElementSelector.Accept (this), QueryGroupClause.ProjectionRole); + result.AddChild (new CSharpTokenNode (Convert (groupBy.Location)), QueryGroupClause.GroupKeywordRole); + if (groupBy.ElementSelector != null) + result.AddChild ((Expression)groupBy.ElementSelector.Accept (this), QueryGroupClause.ProjectionRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), "by".Length), QueryGroupClause.ByKeywordRole); - result.AddChild ((Expression)groupBy.Expr.Accept (this), QueryGroupClause.KeyRole); + result.AddChild (new CSharpTokenNode (Convert (location [0])), QueryGroupClause.ByKeywordRole); + if (groupBy.Expr != null) + result.AddChild ((Expression)groupBy.Expr.Accept (this), QueryGroupClause.KeyRole); return result; } @@ -3116,11 +3278,12 @@ namespace ICSharpCode.NRefactory.CSharp var result = new QueryLetClause (); var location = LocationsBag.GetLocations (l); - result.AddChild (new CSharpTokenNode (Convert (l.Location), "let".Length), QueryLetClause.Roles.Keyword); - result.AddChild (Identifier.Create (l.IntoVariable.Name, Convert (l.IntoVariable.Location)), Identifier.Roles.Identifier); + result.AddChild (new CSharpTokenNode (Convert (l.Location)), QueryLetClause.LetKeywordRole); + result.AddChild (Identifier.Create (l.IntoVariable.Name, Convert (l.IntoVariable.Location)), Roles.Identifier); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), 1), QueryLetClause.Roles.Assign); - result.AddChild ((Expression)l.Expr.Accept (this), QueryLetClause.Roles.Expression); + result.AddChild (new CSharpTokenNode (Convert (location [0])), Roles.Assign); + if (l.Expr != null) + result.AddChild ((Expression)l.Expr.Accept (this), Roles.Expression); return result; } @@ -3129,8 +3292,9 @@ namespace ICSharpCode.NRefactory.CSharp var result = new QueryWhereClause (); var location = LocationsBag.GetLocations (w); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), "where".Length), QueryWhereClause.Roles.Keyword); - result.AddChild ((Expression)w.Expr.Accept (this), QueryWhereClause.Roles.Condition); + result.AddChild (new CSharpTokenNode (Convert (location [0])), QueryWhereClause.WhereKeywordRole); + if (w.Expr != null) + result.AddChild ((Expression)w.Expr.Accept (this), Roles.Condition); return result; } @@ -3138,23 +3302,24 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new QueryJoinClause (); var location = LocationsBag.GetLocations (join); - result.AddChild (new CSharpTokenNode (Convert (join.Location), "join".Length), QueryJoinClause.JoinKeywordRole); + result.AddChild (new CSharpTokenNode (Convert (join.Location)), QueryJoinClause.JoinKeywordRole); result.AddChild (Identifier.Create (join.JoinVariable.Name, Convert (join.JoinVariable.Location)), QueryJoinClause.JoinIdentifierRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), "in".Length), QueryJoinClause.InKeywordRole); - - result.AddChild ((Expression)join.Expr.Accept (this), QueryJoinClause.InExpressionRole); + result.AddChild (new CSharpTokenNode (Convert (location [0])), QueryJoinClause.InKeywordRole); + + if (join.Expr != null) + result.AddChild ((Expression)join.Expr.Accept (this), QueryJoinClause.InExpressionRole); if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), "on".Length), QueryJoinClause.OnKeywordRole); + result.AddChild (new CSharpTokenNode (Convert (location [1])), QueryJoinClause.OnKeywordRole); var outer = join.OuterSelector.Statements.FirstOrDefault () as ContextualReturn; if (outer != null) result.AddChild ((Expression)outer.Expr.Accept (this), QueryJoinClause.OnExpressionRole); if (location != null && location.Count > 2) - result.AddChild (new CSharpTokenNode (Convert (location[2]), "equals".Length), QueryJoinClause.EqualsKeywordRole); + result.AddChild (new CSharpTokenNode (Convert (location [2])), QueryJoinClause.EqualsKeywordRole); var inner = join.InnerSelector.Statements.FirstOrDefault () as ContextualReturn; if (inner != null) @@ -3167,30 +3332,33 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new QueryJoinClause (); var location = LocationsBag.GetLocations (join); - result.AddChild (new CSharpTokenNode (Convert (join.Location), "join".Length), QueryJoinClause.JoinKeywordRole); + result.AddChild (new CSharpTokenNode (Convert (join.Location)), QueryJoinClause.JoinKeywordRole); // mcs seems to have swapped IntoVariable with JoinVariable, so we'll swap it back here result.AddChild (Identifier.Create (join.IntoVariable.Name, Convert (join.IntoVariable.Location)), QueryJoinClause.JoinIdentifierRole); if (location != null) - result.AddChild (new CSharpTokenNode (Convert (location[0]), "in".Length), QueryJoinClause.InKeywordRole); + result.AddChild (new CSharpTokenNode (Convert (location [0])), QueryJoinClause.InKeywordRole); + if (join.Expr != null) + result.AddChild ((Expression)join.Expr.Accept (this), QueryJoinClause.InExpressionRole); + + if (location != null && location.Count > 1) + result.AddChild (new CSharpTokenNode (Convert (location [1])), QueryJoinClause.OnKeywordRole); + var outer = join.OuterSelector.Statements.FirstOrDefault () as ContextualReturn; if (outer != null) result.AddChild ((Expression)outer.Expr.Accept (this), QueryJoinClause.OnExpressionRole); - if (location != null && location.Count > 1) - result.AddChild (new CSharpTokenNode (Convert (location[1]), "on".Length), QueryJoinClause.OnKeywordRole); - result.AddChild ((Expression)join.Expr.Accept (this), QueryJoinClause.InExpressionRole); - + if (location != null && location.Count > 2) - result.AddChild (new CSharpTokenNode (Convert (location[2]), "equals".Length), QueryJoinClause.EqualsKeywordRole); + result.AddChild (new CSharpTokenNode (Convert (location [2])), QueryJoinClause.EqualsKeywordRole); var inner = join.InnerSelector.Statements.FirstOrDefault () as ContextualReturn; if (inner != null) result.AddChild ((Expression)inner.Expr.Accept (this), QueryJoinClause.EqualsExpressionRole); if (location != null && location.Count > 3) - result.AddChild (new CSharpTokenNode (Convert (location[3]), "into".Length), QueryJoinClause.IntoKeywordRole); + result.AddChild (new CSharpTokenNode (Convert (location [3])), QueryJoinClause.IntoKeywordRole); result.AddChild (Identifier.Create (join.JoinVariable.Name, Convert (join.JoinVariable.Location)), QueryJoinClause.IntoIdentifierRole); return result; @@ -3201,12 +3369,12 @@ namespace ICSharpCode.NRefactory.CSharp var result = new QueryOrderClause (); var ordering = new QueryOrdering (); - - ordering.AddChild ((Expression)orderByAscending.Expr.Accept (this), QueryWhereClause.Roles.Expression); + if (orderByAscending.Expr != null) + ordering.AddChild ((Expression)orderByAscending.Expr.Accept (this), Roles.Expression); var location = LocationsBag.GetLocations (orderByAscending); if (location != null) { ordering.Direction = QueryOrderingDirection.Ascending; - ordering.AddChild (new CSharpTokenNode (Convert (location[0]), "ascending".Length), QueryWhereClause.Roles.Keyword); + ordering.AddChild (new CSharpTokenNode (Convert (location [0])), QueryOrdering.AscendingKeywordRole); } result.AddChild (ordering, QueryOrderClause.OrderingRole); return result; @@ -3217,28 +3385,28 @@ namespace ICSharpCode.NRefactory.CSharp var result = new QueryOrderClause (); var ordering = new QueryOrdering (); - - ordering.AddChild ((Expression)orderByDescending.Expr.Accept (this), QueryWhereClause.Roles.Expression); + if (orderByDescending.Expr != null) + ordering.AddChild ((Expression)orderByDescending.Expr.Accept (this), Roles.Expression); var location = LocationsBag.GetLocations (orderByDescending); if (location != null) { ordering.Direction = QueryOrderingDirection.Descending; - ordering.AddChild (new CSharpTokenNode (Convert (location[0]), "ascending".Length), QueryWhereClause.Roles.Keyword); + ordering.AddChild (new CSharpTokenNode (Convert (location [0])), QueryOrdering.DescendingKeywordRole); } result.AddChild (ordering, QueryOrderClause.OrderingRole); return result; - } + } public override object Visit (Mono.CSharp.Linq.ThenByAscending thenByAscending) { var result = new QueryOrderClause (); var ordering = new QueryOrdering (); - - ordering.AddChild ((Expression)thenByAscending.Expr.Accept (this), QueryWhereClause.Roles.Expression); + if (thenByAscending.Expr != null) + ordering.AddChild ((Expression)thenByAscending.Expr.Accept (this), Roles.Expression); var location = LocationsBag.GetLocations (thenByAscending); if (location != null) { ordering.Direction = QueryOrderingDirection.Ascending; - ordering.AddChild (new CSharpTokenNode (Convert (location[0]), "ascending".Length), QueryWhereClause.Roles.Keyword); + ordering.AddChild (new CSharpTokenNode (Convert (location [0])), QueryOrdering.AscendingKeywordRole); } result.AddChild (ordering, QueryOrderClause.OrderingRole); return result; @@ -3249,12 +3417,12 @@ namespace ICSharpCode.NRefactory.CSharp var result = new QueryOrderClause (); var ordering = new QueryOrdering (); - - ordering.AddChild ((Expression)thenByDescending.Expr.Accept (this), QueryWhereClause.Roles.Expression); + if (thenByDescending.Expr != null) + ordering.AddChild ((Expression)thenByDescending.Expr.Accept (this), Roles.Expression); var location = LocationsBag.GetLocations (thenByDescending); if (location != null) { ordering.Direction = QueryOrderingDirection.Descending; - ordering.AddChild (new CSharpTokenNode (Convert (location[0]), "ascending".Length), QueryWhereClause.Roles.Keyword); + ordering.AddChild (new CSharpTokenNode (Convert (location [0])), QueryOrdering.DescendingKeywordRole); } result.AddChild (ordering, QueryOrderClause.OrderingRole); return result; @@ -3264,9 +3432,9 @@ namespace ICSharpCode.NRefactory.CSharp { var result = new UnaryOperatorExpression (); result.Operator = UnaryOperatorType.Await; - result.AddChild (new CSharpTokenNode (Convert (awaitExpr.Location), 1), UnaryOperatorExpression.OperatorRole); + result.AddChild (new CSharpTokenNode (Convert (awaitExpr.Location)), UnaryOperatorExpression.AwaitRole); if (awaitExpr.Expression != null) - result.AddChild ((Expression)awaitExpr.Expression.Accept (this), UnaryOperatorExpression.Roles.Expression); + result.AddChild ((Expression)awaitExpr.Expression.Accept (this), Roles.Expression); return result; } #endregion @@ -3274,12 +3442,13 @@ namespace ICSharpCode.NRefactory.CSharp public CSharpParser () { - CompilerArguments = new string[] { "-v", "-unsafe"}; + CompilerSettings = new CompilerSettings (); + CompilerSettings.Unsafe = true; } - public CSharpParser (string[] args) + public CSharpParser (CompilerSettings args) { - CompilerArguments = args; + CompilerSettings = args; } static AstNode GetOuterLeft (AstNode node) @@ -3297,7 +3466,7 @@ namespace ICSharpCode.NRefactory.CSharp var next = node.NextSibling; if (next == null) return node.Parent; - return GetOuterLeft(next); + return GetOuterLeft (next); } static void InsertComments (CompilerCompilationUnit top, ConversionVisitor conversionVisitor) @@ -3308,14 +3477,20 @@ namespace ICSharpCode.NRefactory.CSharp AstNode newLeaf = null; var comment = special as SpecialsBag.Comment; if (comment != null) { - if (conversionVisitor.convertTypeSystemMode && (comment.CommentType != SpecialsBag.CommentType.Documentation)) + // HACK: multiline documentation comment detection; better move this logic into the mcs tokenizer + bool isMultilineDocumentationComment = ( + comment.CommentType == SpecialsBag.CommentType.Multi + && comment.Content.StartsWith("*", StringComparison.Ordinal) + && !comment.Content.StartsWith("**", StringComparison.Ordinal) + ); + if (conversionVisitor.convertTypeSystemMode && !(comment.CommentType == SpecialsBag.CommentType.Documentation || isMultilineDocumentationComment)) continue; - var type = (CommentType)comment.CommentType; + var type = isMultilineDocumentationComment ? CommentType.MultiLineDocumentation : (CommentType)comment.CommentType; var start = new TextLocation (comment.Line, comment.Col); var end = new TextLocation (comment.EndLine, comment.EndCol); newLeaf = new Comment (type, start, end) { StartsLine = comment.StartsLine, - Content = comment.Content + Content = isMultilineDocumentationComment ? comment.Content.Substring(1) : comment.Content }; } else { var directive = special as SpecialsBag.PreProcessorDirective; @@ -3339,9 +3514,9 @@ namespace ICSharpCode.NRefactory.CSharp node = node.Parent; } if (newLeaf is Comment) { - node.InsertChildBefore (leaf, (Comment)newLeaf, AstNode.Roles.Comment); + node.InsertChildBefore (leaf, (Comment)newLeaf, Roles.Comment); } else { - node.InsertChildBefore (leaf, (PreProcessorDirective)newLeaf, AstNode.Roles.PreProcessorDirective); + node.InsertChildBefore (leaf, (PreProcessorDirective)newLeaf, Roles.PreProcessorDirective); } leaf = newLeaf; break; @@ -3351,9 +3526,9 @@ namespace ICSharpCode.NRefactory.CSharp if (nextLeaf == null) { var node = leaf.Parent ?? conversionVisitor.Unit; if (newLeaf is Comment) { - node.AddChild ((Comment)newLeaf, AstNode.Roles.Comment); + node.AddChild ((Comment)newLeaf, Roles.Comment); } else { - node.AddChild ((PreProcessorDirective)newLeaf, AstNode.Roles.PreProcessorDirective); + node.AddChild ((PreProcessorDirective)newLeaf, Roles.PreProcessorDirective); } leaf = newLeaf; break; @@ -3363,9 +3538,9 @@ namespace ICSharpCode.NRefactory.CSharp if (leaf.EndLocation <= newLeaf.StartLocation && newLeaf.StartLocation <= nextLeaf.StartLocation) { var node = leaf.Parent ?? conversionVisitor.Unit; if (newLeaf is Comment) { - node.InsertChildAfter (leaf, (Comment)newLeaf, AstNode.Roles.Comment); + node.InsertChildAfter (leaf, (Comment)newLeaf, Roles.Comment); } else { - node.InsertChildAfter (leaf, (PreProcessorDirective)newLeaf, AstNode.Roles.PreProcessorDirective); + node.InsertChildAfter (leaf, (PreProcessorDirective)newLeaf, Roles.PreProcessorDirective); } leaf = newLeaf; break; @@ -3385,9 +3560,9 @@ namespace ICSharpCode.NRefactory.CSharp this.fileName = fileName; } - public override void Print (AbstractMessage msg) + public override void Print (AbstractMessage msg, bool showFullPath) { - base.Print (msg); + base.Print (msg, showFullPath); var newError = new Error (msg.IsWarning ? ErrorType.Warning : ErrorType.Error, msg.Text, new DomRegion (fileName, msg.Location.Row, msg.Location.Column)); Errors.Add (newError); } @@ -3402,7 +3577,7 @@ namespace ICSharpCode.NRefactory.CSharp public bool HasErrors { get { - return errorReportPrinter.ErrorsCount + errorReportPrinter.FatalCounter > 0; + return errorReportPrinter.ErrorsCount > 0; } } @@ -3412,6 +3587,11 @@ namespace ICSharpCode.NRefactory.CSharp } } + public CompilationUnit Parse (ITextSource textSource, string fileName, int lineModifier = 0) + { + return Parse (textSource.CreateReader (), fileName, lineModifier); + } + public CompilationUnit Parse (TextReader reader, string fileName, int lineModifier = 0) { // TODO: can we optimize this to avoid the text->stream->text roundtrip? @@ -3423,41 +3603,32 @@ namespace ICSharpCode.NRefactory.CSharp w.Write (buffer, 0, read); w.Flush (); // we can't close the StreamWriter because that would also close the MemoryStream stream.Position = 0; + return Parse (stream, fileName, lineModifier); } } - public static void AdjustLineLocations (AstNode node, int lineModifier) + public CompilationUnit Parse(CompilerCompilationUnit top, string fileName, int lineModifier = 0) { - if (node is IRelocatable) { - ((IRelocatable)node).SetStartLocation (new TextLocation (node.StartLocation.Line + lineModifier, node.StartLocation.Column)); - } - foreach (var child in node.Children) { - AdjustLineLocations (child, lineModifier); - } - } - - public CompilationUnit Parse (CompilerCompilationUnit top, string fileName, int lineModifier = 0) - { - if (top == null) + if (top == null) { return null; + } CSharpParser.ConversionVisitor conversionVisitor = new ConversionVisitor (GenerateTypeSystemMode, top.LocationsBag); - top.UsingsBag.Global.Accept (conversionVisitor); - conversionVisitor.AddAttributeSection (conversionVisitor.Unit, top.ModuleCompiled); - InsertComments (top, conversionVisitor); - if (CompilationUnitCallback != null) - CompilationUnitCallback (top); - if (lineModifier != 0) - AdjustLineLocations (conversionVisitor.Unit, lineModifier); - if (top.LastYYValue is Mono.CSharp.Expression) - conversionVisitor.Unit.TopExpression = ((Mono.CSharp.Expression)top.LastYYValue).Accept (conversionVisitor) as AstNode; + top.ModuleCompiled.Accept(conversionVisitor); + InsertComments(top, conversionVisitor); + if (CompilationUnitCallback != null) { + CompilationUnitCallback(top); + } + if (top.LastYYValue is Mono.CSharp.Expression) { + conversionVisitor.Unit.TopExpression = ((Mono.CSharp.Expression)top.LastYYValue).Accept(conversionVisitor) as AstNode; + } conversionVisitor.Unit.FileName = fileName; return conversionVisitor.Unit; } - public string[] CompilerArguments { + public CompilerSettings CompilerSettings { get; - private set; + internal set; } public Action CompilationUnitCallback { @@ -3475,52 +3646,67 @@ namespace ICSharpCode.NRefactory.CSharp return Parse (new StringReader (program), fileName); } - public CompilationUnit Parse (Stream stream, string fileName, int lineModifier = 0) + internal static object parseLock = new object (); + + public CompilationUnit Parse(Stream stream, string fileName, int lineModifier = 0) { - lock (CompilerCallableEntryPoint.parseLock) { + lock (parseLock) { errorReportPrinter = new ErrorReportPrinter (""); - CompilerCompilationUnit top = CompilerCallableEntryPoint.ParseFile (CompilerArguments, stream, fileName, errorReportPrinter); - var unit = Parse (top, fileName, lineModifier); + var ctx = new CompilerContext (CompilerSettings, errorReportPrinter); + ctx.Settings.TabSize = 1; + var reader = new SeekableStreamReader (stream, Encoding.UTF8); + var file = new SourceFile (fileName, fileName, 0); + Location.Initialize (new List (new [] { file })); + var module = new ModuleContainer (ctx); + var parser = Driver.Parse (reader, file, module, lineModifier); + + var top = new CompilerCompilationUnit () { + ModuleCompiled = module, + LocationsBag = parser.LocationsBag, + SpecialsBag = parser.Lexer.sbag + }; + var unit = Parse (top, fileName, lineModifier); unit.Errors.AddRange (errorReportPrinter.Errors); + CompilerCallableEntryPoint.Reset (); return unit; } } - public IEnumerable ParseTypeMembers (TextReader reader, int lineModifier = 0) + public IEnumerable ParseTypeMembers (TextReader reader, int lineModifier = 0) { string code = "unsafe partial class MyClass { " + Environment.NewLine + reader.ReadToEnd () + "}"; var cu = Parse (new StringReader (code), "parsed.cs", lineModifier - 1); if (cu == null) - return Enumerable.Empty (); + return Enumerable.Empty (); var td = cu.Children.FirstOrDefault () as TypeDeclaration; if (td != null) return td.Members; - return Enumerable.Empty (); + return Enumerable.Empty (); } - public IEnumerable ParseStatements(TextReader reader, int lineModifier = 0) + public IEnumerable ParseStatements (TextReader reader, int lineModifier = 0) { - string code = "void M() { " + Environment.NewLine + reader.ReadToEnd() + "}"; - var members = ParseTypeMembers(new StringReader(code), lineModifier - 1); - var method = members.FirstOrDefault() as MethodDeclaration; + string code = "void M() { " + Environment.NewLine + reader.ReadToEnd () + "}"; + var members = ParseTypeMembers (new StringReader (code), lineModifier - 1); + var method = members.FirstOrDefault () as MethodDeclaration; if (method != null && method.Body != null) return method.Body.Statements; return Enumerable.Empty (); } - public AstType ParseTypeReference(TextReader reader) + public AstType ParseTypeReference (TextReader reader) { - string code = reader.ReadToEnd() + " a;"; - var members = ParseTypeMembers(new StringReader(code)); - var field = members.FirstOrDefault() as FieldDeclaration; + string code = reader.ReadToEnd () + " a;"; + var members = ParseTypeMembers (new StringReader (code)); + var field = members.FirstOrDefault () as FieldDeclaration; if (field != null) return field.ReturnType; return AstType.Null; } - public AstNode ParseExpression(TextReader reader) + public AstNode ParseExpression (TextReader reader) { - var es = ParseStatements(new StringReader("tmp = " + Environment.NewLine + reader.ReadToEnd() + ";"), -1).FirstOrDefault() as ExpressionStatement; + var es = ParseStatements (new StringReader ("tmp = " + Environment.NewLine + reader.ReadToEnd () + ";"), -1).FirstOrDefault () as ExpressionStatement; if (es != null) { AssignmentExpression ae = es.Expression as AssignmentExpression; if (ae != null) @@ -3532,10 +3718,20 @@ namespace ICSharpCode.NRefactory.CSharp /// /// Parses a file snippet; guessing what the code snippet represents (compilation unit, type members, block, type reference, expression). /// - public AstNode ParseSnippet(TextReader reader) + public AstNode ParseSnippet (TextReader reader) { // TODO: add support for parsing a part of a file - throw new NotImplementedException(); + throw new NotImplementedException (); + } + + public DocumentationReference ParseDocumentationReference (string cref) + { + if (cref == null) + throw new ArgumentNullException ("cref"); + cref = cref.Replace ('{', '<').Replace ('}', '>'); + // TODO: add support for parsing cref attributes + // (documentation_parsing production, see DocumentationBuilder.HandleXrefCommon) + throw new NotImplementedException (); } } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/AssemblyInfo.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/AssemblyInfo.cs deleted file mode 100644 index 252e3fb1e5..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/AssemblyInfo.cs +++ /dev/null @@ -1,43 +0,0 @@ -// -// AssemblyInfo.cs -// -// Author: -// Marek Safar (marek.safar@gmail.com) -// -// Copyright (C) 2007 Novell, Inc (http://www.novell.com) -// -// Permission is hereby granted, free of charge, to any person obtaining -// a copy of this software and associated documentation files (the -// "Software"), to deal in the Software without restriction, including -// without limitation the rights to use, copy, modify, merge, publish, -// distribute, sublicense, and/or sell copies of the Software, and to -// permit persons to whom the Software is furnished to do so, subject to -// the following conditions: -// -// The above copyright notice and this permission notice shall be -// included in all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -// - -using System.Reflection; -using System.Runtime.CompilerServices; - -[assembly: AssemblyTitle ("Mono C# Compiler")] -[assembly: AssemblyProduct ("Mono C# Compiler")] -[assembly: AssemblyCopyright ("2001 - 2009 Novell, Inc.")] -[assembly: AssemblyCompany ("Novell, Inc.")] -[assembly: AssemblyCulture ("")] -[assembly: AssemblyConfiguration ("")] - -[assembly: AssemblyVersion ("1.0")] -[assembly: AssemblyFileVersion ("1.0")] - -[assembly: AssemblyDescription ("Mono C# Compiler")] - diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/ChangeLog b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/ChangeLog deleted file mode 100644 index bb00893065..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/ChangeLog +++ /dev/null @@ -1,34100 +0,0 @@ -2010-07-28 Marek Safar - - * anonymous.cs, assign.cs, attribute.cs, decl.cs, delegate.cs, - doc.cs, dynamic.cs, ecore.cs, expression.cs, generic.cs, import.cs, - iterators.cs, linq.cs, membercache.cs, method.cs, report.cs, - statement.cs, typemanager.cs: Major name lookup fixes to deal with - C# 3.0 invocable members, correctly handle accessibility hidding and - property-like different get/set base accessors. - - Also fixes bugs #624870, #618522, #616068, #444180, #333891 - -2010-07-14 Marek Safar - - * namespace.cs, import.cs: When importing nested type via type - arguments set their parent type correctly (Fixes #622051). - -2010-07-14 Marek Safar - - A fix for bug #622104 - * attribute.cs: Add default lookup flags. - -2010-07-12 Marek Safar - - * generic.cs: Don't use Report directly. - - * expression.cs, ecore.cs: UserOperatorCall uses MethodSpec without - MethodGroupExpr, will be simplified later. - -2010-07-09 Marek Safar - - * property.cs, parameters.cs: Inflated IndexerSpec parameters. - - * import.cs: Don't build unused parameters. - -2010-07-08 Marek Safar - - * expression.cs (Invocation): Don't recreate simple-name expression. - -2010-07-07 Marek Safar - - * ecore.cs: Don't report NRE warning for lifted null. - -2010-07-07 Marek Safar - - * typemanager.cs, convert.cs, expression.cs: Another reference - equality implementation attack (Fixes #620025, #579058). - -2010-07-05 Marek Safar - - * context.cs, expression.cs, ecore.cs: BaseThis is fully based on - this expression (Fixes #619904). - -2010-07-05 Marek Safar - - * membercache.cs, class.cs: Don't use base member to check for - property or indexer base implementation. - -2010-07-03 Marek Safar - - * membercache.cs: Copy Membercache member state flags for 2 stage - inflate (Fixes #619555). - - * ecore.cs: Use resolved accessors everywhere. - -2010-07-02 Marek Safar - - A fix for bug #360820 - * membercache.cs, property.cs: Check accessors of base property and - not the closest one. - -2010-07-02 Marek Safar - - * modifiers.cs, membercache.cs, import.cs, class.cs: Moved imported - override method checks into import. - - * expression.cs: Removed redundant check. - -2010-06-30 Marek Safar - - * nullable.cs, expression.cs, statement.cs, method.cs, ecore.cs, - delegate.cs, cs-parser.jay, visit.cs: Use MemberAccess to resolve - base access expression, it has all bits done correctly. - -2010-06-30 Marek Safar - - * support.cs: Removed unused code. - - * ecore.cs: Don't use memberlookup for operators. - -2010-06-30 Marek Safar - - * typemanager.cs, membercache.cs, convert.cs, expression.cs, - ecore.cs: Replace remaining MethodLookup with correct user operator - lookup (to do correct deep lookup). Clean up most of outstanding - quirks in binary operator overload resolution. - -2010-06-29 Marek Safar - - * import.cs: Operators must have between 1 and 2 parameters. - - * method.cs: Switch destructor to direct membercache lookup - -2010-06-29 Marek Safar - - * driver.cs, expression.cs: Use Membercache for StringConcat when - it got all what is needed. - -2010-06-29 Marek Safar - - * membercache.cs, expression.cs, statement.cs, doc.cs, ecore.cs: - Changed FindMembers to allocate a new list only when a filter is - used. Saves decent chunk of memory and should save even more in the - future when the filter is not used that often. - -2010-06-28 Marek Safar - - * field.cs, property.cs, assign.cs, const.cs, expression.cs, - ecore.cs, class.cs, cs-parser.jay, enum.cs: Don't use intermediate - structure for simple type fields (saves memory and makes few things - simpler). Clean up some hacks mostly for events. - -2010-06-25 Marek Safar - - * statement.cs, cs-parser.jay: Don't create expensive block for - simple statements. - -2010-06-24 Marek Safar - - * statement.cs, report.cs: Rethrow internal error when reporting is - disabled. - - * ecore.cs: Check for identical name only when simple name is set. - Fixes #616667 - -2010-06-24 Marek Safar - - A fix for bug #616809 - * generic.cs, expression.cs, ecore.cs: Added a new type expression - for open generic type to pass unbound type arguments to typeof - expression. - -2010-06-24 Marek Safar - - * statement.cs: Foreach collection implementation refactoring to - search for GetEnumerator more preciselly. Fixes #431453 and more - unreported bugs. - - * linq.cs, decl.cs, ecore.cs, delegate.cs: Update methodgroup api. - -2010-06-23 Marek Safar - - * cs-parser.jay: Track more locations. - -2010-06-22 Marek Safar - - * cs-tokenizer.cs, location.cs, cs-parser.jay: Track more locations. - -2010-06-18 Marek Safar - - * cs-tokenizer.cs, anonymous.cs, expression.cs, statement.cs, - support.cs, location.cs, cs-parser.jay: Some work on full ast mode. - -2010-06-18 Marek Safar - - * convert.cs, typespec.cs, method.cs: Fixed few more dynamic - conversion. - -2010-06-18 Marek Safar - - * typemanager.cs, namespace.cs: Report more predefined types and - imported types collision types as a warning. - Fixes #537414, #601157 - -2010-06-18 Marek Safar - - * generic.cs: Overrides base method constraint can use method type - parameter. - - * import.cs: Removed redundant cache. - -2010-06-17 Marek Safar - - * generic.cs: Propagate type only inflate downwards. - -2010-06-17 Marek Safar - - A fix for bug #614955 - * method.cs: Do not reject binary dynamic operators. - -2010-06-17 Marek Safar - - * typespec.cs: Internal types have no generic parameters. - Fixes #615022. - -2010-06-17 Marek Safar - - A fix for bug #614955 - * cs-parser.jay: Correctly set expression mode for default parameter - values. - -2010-06-17 Marek Safar - - A fix for bug #615023 - * ecore.cs: Resolve dynamic namespace and keyword collision in the - favour of the keyword. - -2010-06-17 Marek Safar - - A fix for bug #614917 - * convert.cs: Allow more undocumented 0 like values to enum type - conversions. - -2010-06-17 Marek Safar - - * generic.cs, method.cs: Inflate copied type parameters from base - class or explicit interfaces. - - * convert.cs: Fixed conversion between two type parameters. - Fixes #614471 - -2010-06-16 Marek Safar - - * membercache.cs, convert.cs: Correctly resize an array used by - GetUserOperator. - -2010-06-15 Marek Safar - - A fix for bug #599601 - * dynamic.cs, ecore.cs: A new flag for dynamic resolver to ignore - generated member access left expression. - -2010-06-16 Marek Safar - - * expression.cs: Dispatch dynamic invocation solely on left - expression type. - -2010-06-16 Marek Safar - - * expression.cs, statement.cs: Always persist explicit cast - semantic at expression level. - -2010-06-15 Marek Safar - - * expression.cs, attribute.cs: Enable generic type parameters - attribute check. - -2010-06-15 Marek Safar - - A fix for bug #612146 - * generic.cs: Don't use fixed array for inflated type parameter - interface constraints. - -2010-06-15 Marek Safar - - * typespec.cs: ElementTypeSpec has to use its own ITypeDefinition. - - * report.cs: Unwrap elements for related symbols reporting. - -2010-06-15 Marek Safar - - A fix for bug #612796 - * cs-tokenizer.cs: Offset correctly keywords the first character - comparison. - -2010-06-15 Marek Safar - - A fix for bug #613397 - * expression.cs: Removed too aggressive object initializers - optimization. - -2010-06-15 Marek Safar - - * parameter.cs, property.cs, membercache.cs, decl.cs, iterators.cs, - anonymous.cs, expression.cs, support.cs, method.cs, pending.cs, - class.cs, cs-parser.jay: Simplify parsing of accessors by removing - any intermediate steps and fake nodes, also saves few MBs of memory. - -2010-06-11 Marek Safar - - * modifiers.cs, rootcontext.cs, location.cs, cs-parser.jay: More - precise modifiers parsing. - -2010-06-09 Marek Safar - - * cs-tokenizer.cs, anonymous.cs, expression.cs, cs-parser.jay: - Fixed few shift/reduce conflicts. - -2010-06-09 Marek Safar - - * typemanager.cs, parameter.cs, dynamic.cs, typespec.cs, - expression.cs, ecore.cs, cs-parser.jay: Fully parse composed type - specifiers and stop using string in AST. - -2010-06-07 Marek Safar - - * typemanager.cs, eval.cs, iterators.cs, anonymous.cs, expression.cs - method.cs, class.cs, delegate.cs, cs-parser.jay, driver.cs, visit.cs - enum.cs: Hold location of predefined types. - -2010-06-07 Marek Safar - - A fix for bug #610878 - * pending.cs: Clone cached list before modifying. - -2010-06-04 Marek Safar - - * convert.cs, typespec.cs, expression.cs: Start using array member - kind for better conversion checks. - - * import.cs, report.cs: Report better error message for runtime - reflection bugs. - -2010-06-04 Marek Safar - - * membercache.cs, convert.cs, nullable.cs, expression.cs: Optimize - user defined conversion probing and simplify user conversion for - nullabe types. Fixes #610940. - -2010-06-03 Marek Safar - - A fix for bug #610919 - * parameter.cs, property.cs, cs-parser.jay: Use independent implicit - parameters for explicit event accessors. Anonymous method capturing - won't otherwise work for event implicit parameter. - -2010-06-02 Marek Safar - - A fix for bug #610088 - * nullable.cs, expression.cs, statement.cs, method.cs, ecore.cs: - Ignore overrides for base overload resolution as for non-base - expressions and convert the best candidate to closest override - afterwards. - -2010-06-01 Marek Safar - - A fix for bug #610139 - * generic.cs, convert.cs: Recursively check effective base interface - -2010-06-01 Marek Safar - - * statement.cs: Handle nullable types and type parameters in using - statement, avoid boxing value types. Also fixes #571010 - -2010-06-01 Marek Safar - - * convert.cs, expression.cs: Emit unbox for underlying nullable - type boxing cast. - -2010-05-29 Marek Safar - - A fix for bug #610126 - * expression.cs: Don't use branch optimization for types bigger than - int. - -2010-05-28 Marek Safar - - A fix for bug #609088 - * import.cs: Check private modifier correctly. - -2010-05-28 Marek Safar - - A fix for bug #609049 - * ecore.cs: Don't ignore override methods when looking for base - member. - -2010-05-27 Marek Safar - - A fix for bugs #608007, #572540, #566130, #476358 - - * generic.cs, linq.cs, expression.cs, statement.cs, cs-parser.jay: - More tricky refactoring of implicit linq blocks. - -2010-05-25 Marek Safar - - * linq.cs, cs-parser.jay: Keep location for all linq clauses. - -2010-05-25 Marek Safar - - * context.cs, expression.cs, cs-parser.jay: Don't store current - block in This expression (it's too early for linq blocks). - -2010-05-21 Marek Safar - - * expression.cs: Use constrained prefix more broadly to avoid boxing. - -2010-05-20 Marek Safar - - A fix for bug #591149 - * nullable.cs: Don't double wrap same expression. - -2010-05-20 Marek Safar - - A fix for bug #569827 - * anonymous.cs: Any issued error in probing mode means no match. - -2010-05-20 Marek Safar - - * expression.cs: Search for base indexer using the closest match - rule. - -2010-05-20 Marek Safar - - A fix for bug #572071 - * method.cs: Set override constraints using unexpanded interface - list. - -2010-05-20 Marek Safar - - A fix for bug #572071 - * ecore.cs: Include secondary extension method lookup in probing - mode. - -2010-05-19 Marek Safar - - A fix for bug #515801 - * typespec.cs (MayBecomeEqualGenericTypes): Recursively check - type arguments. - -2010-05-19 Marek Safar - - A fix for bug #515801 - * pending.cs: Advance counter correctly. - -2010-05-19 Marek Safar - - A fix for bug #480139 - * method.cs, pending.cs: Indexer override uses base name. - -2010-05-19 Marek Safar - - A fix for bug #424064 - * generic.cs: Replace original with inflated type parameter on - failure. - -2010-05-19 Marek Safar - - A fix for bug #359733 - * parameter.cs: Extension attribute can be defined in each assembly. - -2010-05-18 Marek Safar - - A fix for bug #446507 - * method.cs: Only one method can implement an interface. - -2010-05-18 Marek Safar - - A fix for bug #594905 - * convert.cs, constant.cs, expression.cs, literal.cs, ecore.cs: - Typed null can be used as a source for expression methods. - -2010-05-18 Marek Safar - - A fix for bug #606551 - * namespace.cs: Using directive imports only types and not nested - namespaces. - -2010-05-17 Marek Safar - - * typespec.cs, expression.cs, statement.cs, ecore.cs, complete.cs, - delegate.cs: Member instance is resolved after member overload - definitely resolves static/instance property of member expression. - Fixes #545047, #358848, #456605, #460016, #603299 - -2010-05-12 Marek Safar - - A fix for bug #604981 - * generic.cs, decl.cs, anonymous.cs: Reset more type arguments - details for nested anonymous methods stories. - -2010-05-11 Marek Safar - - A fix for bug #604735 - * namespace.cs: Don't report namespace collision. - -2010-05-11 Marek Safar - - A fix for bug #604748 - * class.cs, typespec.cs: Search full imported attribute hierarchy - for AttributeUsage. - -2010-05-11 Marek Safar - - * namespace.cs: Ignore missing dependencies failure at - initialization. - -2010-05-11 Marek Safar - - A fix for bug #604640 - * namespace.cs: Don't resolve using constraints too early. - -2010-05-11 Marek Safar - - A fix for bug #604239 - * generic.cs: Copy partial type constraints to partial container. - -2010-05-10 Marek Safar - - A fix for bug #557210 - * import.cs: Relax underlying enum field rules. - -2010-05-10 Marek Safar - - A fix for bug #603476 - * property.cs: Implement IParametersMember for indexer accessors. - -2010-05-07 Marek Safar - - A fix for bug #601141 - * class.cs: Update all partial modifiers. - -2010-05-06 Marek Safar - - A fix for bug #601708 - * method.cs, membercache.cs: Destructors cannot be hidden. - -2010-05-06 Marek Safar - - A fix for bug #602551 - * class.cs: Resursive reference of type definition is allowed. - -2010-05-06 Marek Safar - - * anonymous.cs: Mutate cached storey instance types too. - -2010-05-06 Marek Safar - - A fix for bug #602443 - * convert.cs: Explicit enum conversion cannot involve user operators - -2010-05-05 Miguel de Icaza - - * class.cs (TypeContainer.DefineBaseTypes) - (TypeContainer.CheckRecursiveDefinition): check for the iface not - being null, as we could have failed resolution and crashed; - Fixes #442144 - - * cs-parser.jay: Productions to catch common mistakes when other - punctuation operators are used instead of comma. Fixes 571702 - -2010-05-05 Marek Safar - - * anonymous.cs: Mutate correct set of constraints. - -2010-05-05 Marek Safar - - A fix for bug #602842 - * expression.cs: Resolve all array bound arguments. - -2010-05-05 Marek Safar - - * import.cs: Don't import private fields. - -2010-04-30 Marek Safar - - Partially based on patch by - - * eval.cs, ecore.cs: Fixed eval show methods. - -2010-04-30 Marek Safar - - * generic.cs, delegate.cs: Implement output type inference of - methodgroup now when the specification was cleared at least little - bit. - -2010-04-29 Marek Safar - - A fix for bug #575611 - * class.cs: Fix recursive unmanaged recursice sruct check. - -2010-04-29 Marek Safar - - A fix for bug #479776 - * expression.cs: Implement typeof unbounded nested generic types. - -2010-04-29 Marek Safar - - A fix for bug #474953 - * class.cs: Fix valid recursive base type definition. - -2010-04-29 Marek Safar - - A fix for bug #421737 - * convert.cs, expression.cs: A boxing conversion exists from a - nullable-type to a reference type, if a boxing conversion exists - from the underlying non-nullable-value-type to the reference type. - -2010-04-29 Marek Safar - - A fix for bug #376875 - * import.cs: Import volatile modifier. - -2010-04-29 Marek Safar - - A fix for bug #372412 - * typespec.cs, expression.cs, codegen.cs: Emit readonly prefix for - generic arrays. - -2010-04-29 Marek Safar - - A fix for bug #568955 - * statements.cs: Handle recursive scope initializers. - -2010-04-28 Marek Safar - - A fix for bug #566511 - * anonymous.cs: Always get inflated version of hoisted variable - on generic type definition. - -2010-04-28 Marek Safar - - * import.cs, membercache.cs: Relax rules for valid properties. - -2010-04-28 Marek Safar - - * import.cs: Intern arrays used in generic arguments. - -2010-04-28 Marek Safar - - A fix for bug #600398 - * convert.cs: Actually use effective base type for the comparison. - -2010-04-28 Marek Safar - - A fix for bug #600326 - * ecore.cs: Pass arity to base member lookup. - -2010-04-28 Marek Safar - - A fix for bug #573385 - * expression.cs: MemberAccess is of generic type based on right - arity length only. - -2010-05-28 Marek Safar - - * cs-tokenizer.cs: Made tab size configurable. - -2010-05-27 Marek Safar - - * attribute.cs: Ensure Obsolete members are defined before doing - ctor look-up. - -2010-05-27 Marek Safar - - * visit.cs: Add DOM visitor skeleton. - - * *.cs: Updated. - -2010-05-27 Marek Safar - - * attribute.cs, codegen.cs: Drop COMPILER_ACCESS hack. - -2010-05-27 Marek Safar - - * *.cs: Major rewrite of compiler internals to better work with - unmodified System.Reflection.Emit. Some of the key changes are - - TypeSpec replaces reflection specific System.Type. - - All Type(TypeSpec) operations are now done in compiler therefore - no dependency on SRE to inflate generic members and types or to - query unclosed types. - - MemberCache is now the only and full hierarchical topology. - - Generic constraints are implemented properly. - - And as a bonus compilation is on average 30% faster. - -2010-04-15 Jb Evain - - * dmcs.exe.config: update the runtime version to .net 4.0 RTM. - -2010-04-12 Marek Safar - - * expression.cs, attribute.cs, parameter.cs: More attribute type - checks. - -2010-04-12 Marek Safar - - A fix for bug #593342 - - * generic.cs, parameter.cs, argument.cs, field.cs, property.cs, - decl.cs, roottypes.cs, constant.cs, nullable.cs, expression.cs, - method.cs, ecore.cs, class.cs, delegate.cs, attribute.cs, - codegen.cs: Add custom attribute encoder to deal with unfinished - types and easier corlib bootstrap from its own types. - -2010-03-26 Marek Safar - - * cs-parser.jay: Report invalid constraint types. - -2010-03-16 Jb Evain - - * Makefile: rename the net_2_1 profile to moonlight. - -2010-03-11 Marek Safar - - * statement.cs, cs-parser.jay: Use correct location for empty - statements. - -2010-03-11 Marek Safar - - * cs-parser.jay: Disable Location from expression. - - * generic.cs: Check constraints for overrides in the parser. - -2010-03-09 Marek Safar - - * cs-parser.jay (GetLocation): Use an expression when available. - -2010-03-04 Marek Safar - - A fix for bug #582579 - * ecore.cs (FieldExpr): Don't optimize cross reference loads. - -2010-03-04 Marek Safar - - A patch by kornelpal@gmail.com - - * dynamic.cs, anonymous.cs, rootcontext.cs, class.cs: Don't make - compiler generated classes sealed by default. Emit and close top - level compiler generated classes as well. - - * support.cs: Use RuntimeHelpers.GetHashCode. - -2010-03-03 Rolf Bjarne Kvinge - - * Makefile: We need to use the internal bootstrapping gmcs for - net_2_1_bootstrap too now. - -2010-03-02 Raja R Harinath - - * expression.cs (IndexerAccess.ResolveAccessor): Add CS1540 check. - -2010-03-02 Marek Safar - - * cs-tokenizer.cs: Missed few locations in previous fix. - -2010-03-02 Marek Safar - - * cs-tokenizer.cs, argument.cs, dynamic.cs, assign.cs, anonymous.cs, - nullable.cs, expression.cs, statement.cs, cs-parser.jay, cfold.cs: - Report correct location for operator errors. - -2010-03-02 Marek Safar - - * typemanager.cs (IsDynamicType): Don't check external types when - the attribute is not external. - -2010-02-24 Marek Safar - - A fix for bug #582579 - * decl.cs (IsExposedFromAssembly): Use PartialContainer for parent - modifiers. - -2010-02-24 Marek Safar - - A fix for bug #581804 - * ecore.cs: Fixed type comparison. - -2010-02-08 Miguel de Icaza - - * namespace.cs (CompletionGetTypesStartingWith): Do not include - private types in the completion results. - - * cs-parser.jay: Bubble completions after "from x in ?" and "from x - ... let ?" - -2010-02-17 Marek Safar - - * generic.cs, field.cs, decl.cs, cs-parser.jay: Simplify special - constraint parsing. - -2010-02-14 Miguel de Icaza - - * eval.cs: Do not do the report printer dance unless the user has - set the DescribeTypes feature. - -2010-02-10 Marek Safar - - * argument.cs, dynamic.cs, expression.cs: Track RC API changes. - -2010-02-08 Marek Safar - - A fix for bug #577029 - * anonymous.cs: Fixed TypeBuilder* check. - -2010-02-06 Miguel de Icaza - - * eval.cs (CompileBlock): Also undo if there are problems during - semantic analysis, fixes various cases where invalid C# code would - be reported, but the internal changes would not be undone. - -2010-02-03 Miguel de Icaza - - * driver.cs: Change the --fatal flag to allow a number to be - passed, this ignores the first N fatal errors. Useful to debug - errors that do not happen on the first hit. - - * cs-parser.jay (invocation_expression): accept both the - CLOSE_PARENS and COMPLETE_COMPLETION, this allows completions - inside an invocation. - - * driver.cs: Expose FatalErrors. - - * eval.cs: Initialize the printer's Fatal property from the - Driver's FatalError flag, this allows csharp --fatal to work - again. - - Add support for calling Describe (typeof (TYPE)) if the expression - entered is a TYPE. - -2010-02-02 Marek Safar - - A fix for bug #574991 - * rootcontext.cs, class.cs, driver.cs: Hide enhanced warnings behind - --lint. - -2010-02-02 Marek Safar - - A fix for bug #575986 - * expression.cs: Don't mutate typeof type definitions. - -2010-01-28 Marek Safar - - * decl.cs: Use only one set of modifiers. - -2010-01-26 Marek Safar - - A fix for bug #573329 - * eval.cs: Don't disable error reporting completely on silent mode. - -2010-01-25 Marek Safar - - A fix for bug #573312 - * constant.cs, expression.cs, ecore.cs: Emit correct offset for - pointer index of unknown size types greater than 2. - -2010-01-15 Marek Safar - - * *.cs: Use only 1 member kind enum. - -2010-01-15 Marek Safar - - * *.cs: Add event specification. - -2010-01-14 Marek Safar - - * membercache.cs: Extracted from decl.cs. - - * *.cs: Put more infrastructure in place. - -2010-01-13 Marek Safar - - * *.cs: Add property specification, unused yet. - -2010-01-13 Marek Safar - - * property.cs: Move all property based declarations into a new file. - -2010-01-13 Marek Safar - - * expression.cs (Conditional): Resolve reduced expression. - -2010-01-13 Marek Safar - - * *.cs: Introduced non-generic method specification. - -2010-01-07 Marek Safar - - * method.cs: Move all method based declarations into a new file. - -2010-01-07 Marek Safar - - * *.cs: Extract field specification. - -2009-12-17 Marek Safar - - * field.cs: Extracted from class.cs - -2009-12-15 Marek Safar - - * attribute.cs (GetFixedBuffer): Work on field definition only. - -2009-12-15 Marek Safar - - * *.cs: Clean up NET_4_0 conditional where possible. - -2009-12-14 Rodrigo Kumpera - - support.cs (DynamicType): Assembly property returns the assembly builder. - This is required due to how compiler context works in corlib. - -2009-12-14 Marek Safar - - A fix for bug #564376 - * assign.cs (LocalTemporary): Removed no longer needed special - by-ref handling. - -2009-12-11 Marek Safar - - * modifiers.cs, decl.cs, iterators.cs, const.cs, anonymous.cs, - class.cs, delegate.cs, cs-parser.jay, enum.cs: Turn modifiers into - enum for easier debugging. - -2009-12-10 Marek Safar - - * decl.cs, anonymous.cs, class.cs: Sealed Define it's now main entry - point. - - * parameter.cs, delegate.cs, dynamic.cs: Don't use builder methods - directly. - -2009-12-10 Marek Safar - - * cs-parser.jay, statement.cs: Handle parser error in code - completition. - -2009-12-10 Marek Safar - - * ecore.cs: Ignore base imported methods when they are already - in method bag. - - * eval.cs: Handle non-existent keys. - - * report.cs, driver.cs: Make fatal work with console printer only. - -2009-12-08 Rodrigo Kumpera - - * typemanager.cs (MakeGenericMethod): Fix stupid mistake. - -2009-12-08 Rodrigo Kumpera - - * typemanager.cs: Add MakeGenericMethod that checks if the method - is really the generic method definition. - - ecore.cs (MethodGroupExpr:IsApplicable): Use new TypeManager function - to inflate generic methods. - -2009-12-08 Marek Safar - - A fix for bug #561149 - * anonymous.cs: Use actual type parameters when checking for generic - method host. - -2009-12-08 Marek Safar - - A fix for bug #561369 - * expression.cs (DoNumericPromotion): Fixed typo. - -2009-12-08 Marek Safar - - *.cs: Moving to generics world. - - cs-parser.jay: Removed current_array_type. - -2009-12-07 Marek Safar - - *.cs: Moving to generics world. - -2009-12-04 Marek Safar - - *.cs: Moving to generics world (day 2). - -2009-12-03 Marek Safar - - *.cs: Moving to generics world. - -2009-12-02 Marek Safar - - * typemanager.cs, parameter.cs, class.cs, delegate.cs, attribute.cs: - Encode dynamic type attribute for elements where attributes cannot - be used. - -2009-12-01 Marek Safar - - argument.cs, assign.cs, expression.cs, cs-parser.jay: Named - arguments by ref. - -2009-12-01 Marek Safar - - A fix for bug #360455 - * class.cs: Never report a unused warning for generic events to - workaround wrong expression type. - -2009-11-30 Marek Safar - - A fix for bug #558305 - * decl.cs, class.cs: Check partial method definitions using correct - flag. - -2009-11-30 Marek Safar - - * argument.cs: Don't cache rarely used dynamic flag. - -2009-11-27 Marek Safar - - * cs-parser.jay: Use jay global stacks (saves over 3MB for corlib). - -2009-11-27 Marek Safar - - * ecore.cs (SimpleName): Removed no longer needed in_transit as - Resolve is now non-reentrant (saves ~0.6MB for corlib). - -2009-11-26 Marek Safar - - A fix for bug #545081 - * decl.cs: Check private nested types of nested types recursively. - -2009-11-26 Marek Safar - - A fix for bug #558305 - * location.cs: Ignore self referencing #line directive - -2009-11-26 Marek Safar - - A fix for bug #558292 - * class.cs: Allow single unsafe fixed buffer fields. - -2009-11-26 Marek Safar - - * expression: Optimize few more zero-based operations. - -2009-11-26 Marek Safar - - * cs-tokenizer.cs, cs-parser.jay: Simplify literal parsing, also - avoids boxing of literal values. - -2009-11-26 Marek Safar - - * cs-tokenizer.cs, argument.cs, eval.cs, linq.cs, decl.cs, - expression.cs, ecore.cs, location.cs, cs-parser.jay, attribute.cs, - codegen.cs: LocatedToken redesing to avoid excessive allocation and - boxing (saves ~7MB for corlib). Also fixes presise token location. - -2009-11-25 Marek Safar - - * ecore.cs, cs-parser.jay: Keep parser structures local. Share - common data buckers. - -2009-11-24 Marek Safar - - * expression.cs: Lower static array initializer barrier. - - * support.cs, driver.cs: Share reader buffer. - -2009-11-23 Marek Safar - - * cs-tokenizer.cs, support.cs: Some tokenizer optimizations. - -2009-11-23 Marek Safar - - * cs-tokenizer.cs, support.cs: Use Dictionary instead of Hashtable, - cleanup some obsolete code. - -2009-11-20 Marek Safar - - * context.cs, expression.cs, ecore.cs, complete.cs: Cleaned up - Expression.Resolve. - -2009-11-20 Marek Safar - - * *.cs: Resolved expressions are never resolved again, this helps to - uncover some not easy to find bugs and improve the performance. - -2009-11-19 Marek Safar - - * *.cs: Made constant expressions fully compatible with any other - expression. - -2009-11-19 Marek Safar - - * *.cs: DoResolve is a worker method and has to be protected. - -2009-11-18 Marek Safar - - * *.cs: More context specific handling. - -2009-11-17 Marek Safar - - * *.cs: More context specific handling. - -2009-11-16 Marek Safar - - * dynamic.cs, class.cs: Removed few fixed user types conversions. - - * symbolwriter.cs: Uses public ILOffset. - -2009-11-13 Marek Safar - - A fix for bug #553650 - * generic.cs: Another missing TypeToCoreType, still too many to fix. - -2009-11-13 Marek Safar - - A fix for bug #555170 - - * class.cs, delegate.cs, enum.cs: Constants have to be available - for parameters resolve. - -2009-11-12 Marek Safar - - * typemanager.cs, argument.cs, support.cs, delegate.cs: Dynamic - arrays. - -2009-11-12 Marek Safar - - * argument.cs, context.cs, expression.cs, ecore.cs: Dynamic binding - with a statically known candidate set. - -2009-11-11 Scott Peterson - - * generic.cs: Made type inflation for generic constraint checks - recursive. This fixes BGO #553655. - -2009-11-11 Marek Safar - - * dynamic.cs, decl.cs, expression.cs, ecore.cs: More dynamic type - checks. - -2009-11-10 Marek Safar - - * typemanager.cs, generic.cs, parameter.cs, argument.cs, dynamic.cs, - linq.cs, rootcontext.cs, ecore.cs, class.cs, delegate.cs, - attribute.cs: Add some dynamic error checking. - -2009-11-07 Marek Safar - - A fix for bug #553465 - - * expression.cs: Fixed mixed version of expression tree anonymous - type. - -2009-11-06 Marek Safar - - A fix for bug #553031 - - * linq.cs, expression.cs, class.cs, cs-parser.jay: Initialize - expression tree version of anonymous type with members declaration. - -2009-11-05 Marek Safar - - * parameter.cs: Handle nullable parameter default expression. - - * argument.cs, dynamic.cs, expression.cs, support.cs, ecore.cs, - class.cs, attribute.cs: Check for wrong dynamic arguments. - -2009-11-05 Marek Safar - - * statement.cs: Dynamic statements. - -2009-11-04 Marek Safar - - * dynamic.cs, assign.cs, context.cs, expression.cs, ecore.cs: - Compound assignments over dynamic type. - -2009-11-03 Marek Safar - - * argument.cs, dynamic.cs, expression.cs, delegate.cs: Dynamic - constructor arguments. - -2009-10-30 Marek Safar - - * dynamic.cs, convert.cs, assign.cs, constant.cs, expression.cs, - codegen.cs: Unary mutator on dynamic member access expression. - -2009-10-29 Marek Safar - - A fix for bug #550580 - * convert.cs: Don't eliminate explicit precission casts. - -2009-10-28 Marek Safar - - A fix for bug #550404 - - * parameter.cs, iterators.cs, context.cs, anonymous.cs, - expression.cs, statement.cs, ecore.cs: Quote any nested expression - tree. - -2009-10-27 Marek Safar - - * constant.cs, nullable.cs: Create nullable-null as LiftedNull - constant. - - * class.cs: Allow nullable binary user operators. - -2009-10-26 Marek Safar - - * expression.cs: Move binary expression optimization at the end of - resolve. - -2009-10-23 Marek Safar - - * constant.cs, nullable.cs, expression.cs, literal.cs, cfold.cs: - Separate NullConstant from NullLiteral. - -2009-10-23 Marek Safar - - * typemanager.cs, eval.cs, decl.cs, roottypes.cs, context.cs, - anonymous.cs, expression.cs, rootcontext.cs, ecore.cs, class.cs, - flowanalysis.cs, cs-parser.jay, driver.cs, codegen.cs: Split - ModuleContainer. Add common unclosed member check routine. - -2009-10-22 Marek Safar - - * argument.cs: Use literal flag for real literals only. - - * dynamic.cs: Use correct return type for custom delegates. - -2009-10-22 Marek Safar - - * dynamic.cs, expression.cs: Pass logical binary flag to dynamic - resolver. - -2009-10-22 Marek Safar - - * dynamic.cs, ecore.cs: Dynamic invocation with void return type. - -2009-10-21 Marek Safar - - * dynamic.cs, convert.cs, expression.cs, ecore.cs: Wrap array index - conversion. - -2009-10-21 Marek Safar - - * typemanager.cs, dynamic.cs, expression.cs: Don't resolve runtime - binder flags. - -2009-10-20 Marek Safar - - * argument.cs, dynamic.cs, expression.cs: Latest API update. - -2009-10-19 Marek Safar - - * typemanager.cs, expression.cs: Dynamic array initializer. - -2009-10-16 Marek Safar - - * typemanager.cs, rootcontext.cs: Clear -nostdlib flag when object - is imported. - -2009-10-16 Marek Safar - - A fix for bug #493523, #507067 - * convert.cs, nullable.cs, expression.cs: Do implicit and explicit - standard nullable conversion using underlying standard conversion - and not full conversion. - -2009-10-15 Marek Safar - - * dynamic.cs, expression.cs, ecore.cs, delegate.cs: Check return - type in VerifyArgumentsCompat. - -2009-10-15 Marek Safar - - * nullable.cs, expression.cs, statement.cs, namespace.cs, ecore.cs: - Reject variable used with type arguments. - -2009-10-14 Marek Safar - - * argument.cs, dynamic.cs, assign.cs, expression.cs, ecore.cs: - Implement dynamic expressions assignment. - -2009-10-14 Marek Safar - - * expression.cs: Build underlying expression when resolving unary - mutators. - -2009-10-14 Marek Safar - - * expression.cs: Emit enum array initializer using binary blob. - -2009-10-08 Marek Safar - - * typemanager.cs, constant.cs: Optimize decimal constants which fit - to long range. - -2009-10-07 Marek Safar - - * typemanager.cs: Reset object_type. - - * assign: Made SimpleAssign public. - -2009-10-06 Marek Safar - - * typemanager.cs, decl.cs, namespace.cs, ecore.cs, class.cs: Pass - invocation assembly to IsThisOrFriendAssembly. - -2009-10-05 Marek Safar - - * expression.cs: Equality comparison of generic parameter with - class constraint. - -2009-10-05 Marek Safar - - A fix for bug #543570 - * generic.cs: Import predefined constraints correctly. - -2009-10-02 Marek Safar - - * ecore.cs: Don't crash on overloads with optional paremeters where - arguments count overflows. - - * parameter.cs: Import optional parameter constants using optional - value type. - -2009-10-01 Marek Safar - - * Makefile: Default is gmcs compiler. - -2009-10-01 Marek Safar - - * cs-parser.jay: Fixed few NRE. - -2009-10-01 Marek Safar - - * cs-parser.jay, driver.cs: Expose parser exception in verbose mode. - -2009-09-30 Marek Safar - - * linq.cs, convert.cs, assign.cs, expression.cs, ecore.cs: Add - ShimExpression, ImplicitCast. - -2009-09-30 Marek Safar - - A fix for bug #542959 - * delegate.cs: Emit correct delegate instance variable when there - are static and non-static overloads. - -2009-09-29 Marek Safar - - * dynamic.cs, linq.cs, anonymous.cs, expression.cs, statement.cs, - ecore.cs, cs-parser.jay: Unary expression dynamic compiler. - -2009-09-28 Marek Safar - - A fix for bug #542487 - * ecore.cs: Resolve extension methods hidden by properties. - -2009-09-25 Marek Safar - - * expression.cs, ecore.cs: More dynamic binary expressions. - -2009-09-22 Marek Safar - - * nullable.cs, expression.cs: Fixed null lifted conversion for - bitwise enum operations. - -2009-09-22 Marek Safar - - * convert.cs, ecore.cs: Fixed explicit unsafe coversion of long - values in checked context. - -2009-09-22 Marek Safar - - * expression.cs, ecore.cs: Fixed array index constant conversion. - -2009-09-20 Miguel de Icaza - - * expression.cs: Do not crash when MemberLookup returns something - that is not a MemberExpr here. Report error 582 instead. - - Fixes #499988. - -2009-09-18 Marek Safar - - * decl.cs, class.cs: Check protected property accessors. - -2009-09-18 Marek Safar - - * dynamic.cs, assign.cs: Dynamic compound assignment. - -2009-09-17 Marek Safar - - * expression.cs: Fixed compound assignment explicit conversion. - -2009-09-17 Marek Safar - - * expression.cs, ecore.cs: Cannot infer variables from method group. - -2009-09-16 Marek Safar - - * argument.cs, dynamic.cs, convert.cs, context.cs, anonymous.cs, - constant.cs, nullable.cs, expression.cs, literal.cs, ecore.cs, - codegen.cs: Dynamic binary operations scaffolding. - -2009-09-15 Marek Safar - - * expression.cs: Fixes nullable promotion for enum type variables. - -2009-09-11 Marek Safar - - * driver.cs, dynamic.cs: Reset more static variables. - -2009-09-11 Marek Safar - - * dynamic.cs, expression.cs, rootcontext.cs, namespace.cs, ecore.cs, - driver.cs: Introduced Expression::MakeExpression. - -2009-09-11 Marek Safar - - * eval.cs: Exposed MessageOutput instead of cleaning up eval API. - -2009-09-09 Marek Safar - - * eval.cs, report.cs: Use Console.Out for all eval error or warning - output. - -2009-09-09 Marek Safar - - A fix for bug #518707 - * expression.cs (Is): Optimize only generic parameter type - expression probing value type generic parameter. - -2009-09-09 Marek Safar - - A fix for bug #532571 - * ecore.cs: Check for simple name type arguments used with - non-generic type. - -2009-09-08 Marek Safar - - A fix for bug #497421 - * generic.cs (CheckConstraint): Don't use buildin types to check for - parameterless constructor. - -2009-09-08 Marek Safar - - A fix for bug #537402 - * generic.cs (CheckConstraint): Correctly inflate generic type - arguments when checking generic method. - -2009-09-08 Marek Safar - - A fix for bug #536463 - * decl.cs (AddToContainer): Don't report collision between explicit - and parameterless non-explicit members. - -2009-09-08 Marek Safar - - * eval.cs: Reset more static stuff. - -2009-09-07 Marek Safar - - A fix for bug #324625 - * expression.cs, ecore.cs: Create nested generic type expression - using declaring and not current type. - -2009-09-07 Marek Safar - - * *.cs: Changed Report class to accept various output printers and - be an instance class. An expression resolver can now use different - message reporter for each call and Report.Error can safely throw - an exception. Part of ongoing work to turn mcs into proper library. - -2009-09-04 Marek Safar - - * statement.cs, ecore.cs: Removed error reporting from emit code. - -2009-09-04 Marek Safar - - * cs-parser.jay, parameter.cs: Moved parser check out of constructor - -2009-09-03 Marek Safar - - * anonymous.cs, expression.cs, statement.cs, cs-parser.jay: Moved - parser checks out of constructors. - -2009-09-02 Marek Safar - - * expression.cs, statement.cs, ecore.cs: Use common Report.Error. - -2009-09-02 Marek Safar - - A fix for bug #535448 - * anonymous.cs, class.cs: Copy return label between all contexts. - -2009-09-02 Marek Safar - - A fix for bug #535395 - * namespace.cs: Resolve context can be null. - -2009-08-25 Marek Safar - - A fix for bug #533912 - * generic.cs: Use correct context for constraints resolving. - -2009-08-25 Marek Safar - - A fix for bug #532630 - * driver.cs: Trim conditional symbols. - -2009-08-25 Marek Safar - - * context.cs: New file. - - * *.exe.sources, *.csproj: Updated. - -2009-08-25 Marek Safar - - * generic.cs, parameter.cs, decl.cs, statement.cs, namespace.cs, - class.cs, generic-mcs.cs, codegen.cs: Add GetSignatureForError to - IMembercontext, some small cleanups. - -2009-08-24 Marek Safar - - * *.cs: Split ResolveContext and EmitContext. - -2009-08-24 Marek Safar - - * *.cs: Only ResolveContext implements IMemberContext. - -2009-08-21 Marek Safar - - * *.cs: Renamed IResolveContext to IMemberContext. - -2009-08-21 Marek Safar - - * *.cs: Detached ResolveContext from EmitContext. - -2009-08-21 Marek Safar - - * codegen.cs: Moved flow-analysis to BlockContext. - -2009-08-21 Marek Safar - - * *.cs: Detached BlockContext from EmitContext. - -2009-08-20 Gonzalo Paniagua Javier - - * statement.cs: avoid nullref when the return value of GetEnumerator() - does not contain any MoveNext() method. - -2009-08-19 Marek Safar - - * *.cs: Removed IResolveContext::GenericDeclContainer. - -2009-08-19 Marek Safar - - * class.cs, delegate.cs: Changed Delegate to be TypeContainer based. - -2009-08-19 Marek Safar - - * generic.cs, iterators.cs, expression.cs, statement.cs, ecore.cs, - cs-parser.jay, attribute.cs, codegen.cs: Better error reports. - -2009-08-18 Marek Safar - - * *.cs: Removed boolean fields from EmitContext. - -2009-08-18 Marek Safar - - * *.cs: Add IResolveContext::IsStatic. - -2009-08-18 Marek Safar - - * *.cs: Moved TopBlock's methods from EmitContext to TopBlock. - -2009-08-17 Marek Safar - - * *.cs: Removed DeclContainer from EmitContext. - -2009-08-17 Marek Safar - - * *.cs: Add IResolveContext::CurrentTypeParameters. - -2009-08-14 Marek Safar - - * *.cs: Removed TypeContainer and ContainerType from EmitContext. - -2009-08-14 Marek Safar - - * decl.cs, expression.cs, namespace.cs, ecore.cs, class.cs, - codegen.cs: Add IResolveContext::LookupExtensionMethod. - -2009-08-13 Marek Safar - - * decl.cs: Look in PartialContainer for parent type parameters. - -2009-08-13 Marek Safar - - * decl.cs, namespace.cs, ecore.cs, class.cs, attribute.cs, - codegen.cs: Add IResolveContext::LookupTypeParameter. - -2009-08-13 Marek Safar - - * lambda.cs, expression.cs, statement.cs, namespace.cs, ecore.cs: - Moved resolved logic from Emit to Resolve. - -2009-08-13 Marek Safar - - * parameter.cs, decl.cs, roottypes.cs, class.cs, attribute.cs, - codegen.cs: Reworked atttributes handling of ResolveContext. - -2009-08-12 Marek Safar - - * decl.cs, ecore.cs, class.cs, attribute.cs, codegen.cs: Pushed - LookupNamespaceOrType to ResolveContext. - -2009-08-12 Marek Safar - - * typemanager.cs, decl.cs, expression.cs, namespace.cs, ecore.cs, - class.cs: Removed unused parameters and methods. - -2009-08-11 Marek Safar - - * generic.cs, lambda.cs, anonymous.cs, statement.cs, generic-mcs.cs, - codegen.cs: Finding the best common type of a set of expressions for - lambda statements. - -2009-08-07 Marek Safar - - * dynamic.cs, expression.cs: More dynamic conversions. - -2009-08-06 Miguel de Icaza - - * generic.cs: This loop was incorrect, it was increment ii, but - checking for `i'. This was a change introduced to fix #327497, - now we fix #424012. - - * class.cs: Catch another case for cs0533 error, fixes #324782. - -2009-08-06 Rodrigo Kumpera - - * typemanager.cs (GetGenericArguments): SRE returns null for - generic methods on type builder instances if they are not generic - themselves. For example, for Foo::Bar() it returns null, but - not for Foo::Bar<>() or Foo::Bar(). - -2009-08-05 Marek Safar - - * argument.cs, dynamic.cs, expression.cs, ecore.cs, class.cs, - delegate.cs: Work on dynamic binding. - -2009-08-04 Marek Safar - - A second fix for bug #525342 - * class.cs: Attach partial method attributes to method - implementation. - -2009-08-03 Marek Safar - - * typemanager.cs, parameter.cs, support.cs, class.cs: Dynamic type - restrictions. - - * rootcontext.cs: Default to langversion v4. - -2009-08-03 Marek Safar - - * pending.cs: Check return type before member info is set. - -2009-08-03 Marek Safar - - * anonymous.cs: Fully initialize generic hoisted field expression. - -2009-08-02 Miguel de Icaza - - * cs-parser.jay: Flag variables declared on the interactive shell - as used to prevent the 168 warning about local variable not being - used. - -2009-07-31 Marek Safar - - * parameter.cs, dynamic.cs, support.cs, class.cs, delegate.cs, - attribute.cs: Emit dynamic export attribute. - -2009-07-30 Marek Safar - - * expression.cs: More verifier work. - -2009-07-29 Marek Safar - - * nullable.cs: Fixed SRE crash during corlib compilation. - -2009-07-29 Marek Safar - - * generic.cs, typemanager.cs, decl.cs, iterators.cs, convert.cs, - nullable.cs, expression.cs, ecore.cs, class.cs, attribute.cs: - More TypeManager.TypeToCoreType needed. - -2009-07-29 Marek Safar - - * anonymous.cs: Update after recent SRE fixes. - -2009-07-28 Marek Safar - - * typemanager.cs, expression.cs, ecore.cs, delegate.cs: Use correct - version of GetFieldHandle for fields of generic types. - -2009-07-27 Marek Safar - - * typemanager.cs, argument.cs, convert.cs, assign.cs, expression.cs, - ecore.cs: Add TypeManager.IsDynamicType, - PredefinedAttributes.Dynamic. - -2009-07-27 Marek Safar - - A fix for bug #415375 - * expression.cs: Fixed object and reference type parameter - comparison. - -2009-07-27 Marek Safar - - A fix for bug #525342 - * class.cs: Attach partial method attributes to method - implementation. - -2009-07-24 Marek Safar - - * argument.cs, dynamic.cs, expression.cs, class.cs, attribute.cs: - Dynamic arguments. - -2009-07-24 Marek Safar - - * anonymous.cs (MutateField): Add imported types handling. - -2009-07-23 Marek Safar - - * expression.cs, delegate.cs: Moved arguments resolve into their - counterparts expressions. Removed argument resolve from - CollectionElementInitializer. - -2009-07-23 Marek Safar - - A fix for bug #523683 - * convert.cs, delegate.cs: Use common overload mechanism for method - group conversion check. - -2009-07-22 Marek Safar - - A fix for bug #523899 - * generics.cs: Exact type inference with other bound types. - -2009-07-22 Raja R Harinath - - Don't complain when the same type is implemented by the output - assembly as well as multiple referenced assemblies - * namespace.cs (RootNamespace.LookupTypeReflection): Add - 'must_be_unique' flag. - (GlobalRootNamespace): Update to changes. - (Namespace.LookupType): Pass 'must_be_unique' only when we don't - already have a type in hand. - -2009-07-22 Marek Safar - - * expression.cs: More verifier instrumentation. - - * statement.cs: Do proper throw expression conversion. - -2009-07-22 Marek Safar - - A fix for bug #522789 - * expression.cs: Mutate invocation return type. - -2009-07-16 Marek Safar - - * anonymous.cs: Split assignable and readonly generated variable - references. - -2009-07-16 Marek Safar - - A fix for bug #521671 - * statement.cs: Fixed crash when checking missing type. - -2009-07-16 Marek Safar - - * typemanager.cs, generic.cs, argument.cs, linq.cs, convert.cs, - assign.cs, expression.cs, statement.cs, support.cs, ecore.cs, - class.cs, driver.cs: Work on dynamic binding. - - * dynamic.cs: New file. - - * *.sources, *.proj: Updated. - -2009-07-15 Marek Safar - - * expression.cs (Conditional): Avoid double Resolve. - -2009-07-13 Marcus Griep - - * ecore.cs: Fix obscure bug with resolving members of interfaces - that hide parent interface members. Fixes bug #444388 and corrects - bug #323096 - -2009-07-13 Marek Safar - - * expression.cs (LocalVariableReference): Bounce resolve. - -2009-07-10 Marek Safar - - * typemanager.cs, lambda.cs, parameter.cs, convert.cs, anonymous.cs, - expression.cs, literal.cs, ecore.cs, complete.cs: Moved internal - types to new class. - - * support.cs: New dynamic type wrapper. - -2009-07-08 Marek Safar - - * ecore.cs, cs-parser.jay: Better error reporting for implicitly - typed local variable. - -2009-07-06 Marek Safar - - A fix for bug #519005 - * anonymous.cs: Use null_type as no return type placeholder. - -2009-07-02 Marek Safar - - * generic.cs: Handle type inference of identical type parameters - with different bounds. - -2009-07-01 Marek Safar - - * expression.cs, class.cs: Events variance. - - * cs-parser.jay: Interface events error messages. - -2009-07-01 Marek Safar - - * generic.cs, argument.cs: Updated type inference logic to C# 4.0. - -2009-06-29 Marek Safar - - * parameter.cs, convert.cs, expression.cs, class.cs: Default - parameter expression can be value-type New. - - * cs-parser.jay: Clean up too many parameter modifier boolean flags. - -2009-06-26 Marek Safar - - * generic.cs, argument.cs, expression.cs, ecore.cs, cs-parser.jay: - Implemented C# 4.0 named arguments. - -2009-06-24 Marek Safar - - * typemanager.cs, parameter.cs, iterators.cs, convert.cs, - expression.cs, ecore.cs, delegate.cs: Removed unnecessary ArgList - parameter modifier. Also fixes bug #515497. - -2009-06-24 Marek Safar - - * *.cs: Replaced ArrayList with Arguments in need of a nonsequential - arguments expression to be implemented. - - *.sources: Add argument.cs - -2009-06-23 Marek Safar - - * parameter.cs: Moved GetParameterIndexByName to base class. - - * expression.cs, statement.cs, ecore.cs, delegate.cs: Removed - unused AType. Use argument's version of GetExpressionTree. - -2009-06-22 Marek Safar - - * expression.cs, cs-parser.jay, attribute.cs, codegen.cs: Named - arguments grammar. - -2009-06-17 Marek Safar - - A fix for bug #514096 - * class.cs: Allow IntPtr/UIntPtr fields to be volatile. - -2009-06-17 Marek Safar - - * expression.cs: The first multi-dimensional array nested array - initializers was not checked. - - * statement.cs (Switch): Fixed error message to reflect 2.0 changes. - -2009-06-17 Marek Safar - - A fix for bug #513400 - * nullable.cs (EmitEquality): Operands emit could be simplified for - built-in types when we now emit user operators differently. - -2009-06-16 Marek Safar - - * ecore.cs: Report inaccessible delegate methods correctly. - -2009-06-16 Marek Safar - - * parameter.cs, expression.cs, ecore.cs, class.cs, delegate.cs, - cs-parser.jay: Implemented C# 4.0 optional parameters. - -2009-06-16 Marek Safar - - * driver.cs: Removed broken DefineManifestResource. - -2009-06-16 Raja R Harinath - - * Makefile [net_2_0_bootstrap]: Don't explicitly mention net_1_1. - Use $(BOOTSTRAP_PROFILE) instead. - -2009-06-12 Jb Evain - - * rootcontext.cs: add a Platform field. - * driver.cs: handle /platform. - * codegen.cs: pass the proper flags according to - the platform when saving the assembly. - -2009-06-11 Marek Safar - - * parameter.cs, const.cs, report.cs, cs-parser.jay, attribute.cs: - Add optional parameters grammar. - -2009-06-10 Marek Safar - - * eval.cs, anonymous.cs, report.cs, rootcontext.cs, cs-parser.jay, - driver.cs: Split lang version and metadata version. - -2009-06-10 Marek Safar - - * decl.cs: Better overload ctor collision error message. - -2009-06-05 Jb Evain - - * driver.cs (EmbededResource): avoid using an internal method - in gmcs to embed manifest resources. - -2009-06-04 Sebastien Pouliot - - * generic.cs, parameter.cs: Avoid using 'var' so we can bootstrap - the compiler from older mono versions (like moon's bots) - -2009-06-04 Marek Safar - - * namespace.cs (LookupTypeReflection): Ignore collisions between - forwarded types. - -2009-06-04 Marek Safar - - * codegen.cs: Enabled generic type forwarders. - -2009-06-04 Marek Safar - - * dmcs.*: Add another version of SRE compiler. - -2009-06-03 Marek Safar - - * generic.cs, typemanager.cs, parameter.cs, convert.cs, - generic-mcs.cs: Fixed variant type conversions. - -2009-06-02 Marek Safar - - A fix for bug #507863 - * codegen.cs: Fixes a crash on invalid string value attribute. - -2009-06-01 Marek Safar - - A fix for bug #508334 - * typemanager.cs, parameter.cs, convert.cs, expression.cs, ecore.cs, - cs-parser.jay: Fully import __arglist modifier. - -2009-05-29 Marek Safar - - * generic.cs, typemanager.cs, parameter.cs, ecore.cs, class.cs, - delegate.cs, generic-mcs.cs: Rewrote type variance checks to - actually work with closed generic types. - -2009-05-27 Alan McGovern - - * class.cs, decl.cs, delegate.cs, parameter.cs: - Fix the build by replacing the use of 'var' with the actual type. - -2009-05-27 Marek Safar - - * generic.cs, parameter.cs, decl.cs, ecore.cs, class.cs, delegate.cs - cs-parser.jay, generic-mcs.cs: Report wrong variant types - declarations. - - * driver.cs, rootcontext.cs, report.cs: Add 3.0 language version - filter. - -2009-05-26 Rodrigo Kumpera - Marek Safar - - A fix for bug #377509 - * parameter.cs: Use predefined and not empty name for implicit - setters. - -2009-05-21 Marek Safar - - * class.cs: Don't report wrong warnings for event fields. - -2009-05-21 Marek Safar - - A fix for bug #504667 - * class.cs: Check for static class using parent container instead of - parent type. - -2009-05-08 Marek Safar - - A fix for bug #496922 - * expression.cs: Always use temporary variable when using object - initializer. - -2009-04-28 Marek Safar - - A fix for bug #495112 - * class.cs (IsUnmanagedType): Handle recursive unmanaged types using - local cache. - -2009-04-27 Miguel de Icaza - - * driver.cs: Add a flag to work as a replacement for CSC in VS. - -2009-04-24 Miguel de Icaza - - * complete.cs: No idea how gonzalo got a null in the list, but - avoid crashing. - -2009-04-24 Miguel de Icaza - - * complete.cs (CompletionElementInitializer): New completion class - to support completing inside a C# 3 element initializer, so this - allows completion for Silverlight situations where it is very - common to do: - - new TextBlock () { Fo - - (CompletionSimpleName): Expose the prefix that was - passed to the simple name. - - * cs-parser.jay (object_or_collection_initializer): Add support - for element_initializers. - - * expression.cs (CollectionOrObjectInitializers.DoResolve): - special case completion expressions as this method aggressively - collects data before it operates, and errors were being thrown - earlier than we were able to complete. - -2009-04-23 Miguel de Icaza - - * eval.cs: Make getcompletions silent and enable debugging output - if the -v option is passed. - - * namespace.cs (NamespaceEntry.CompletionGetTypesStartingWith): - Consider looking up the namespace that matches the prefix being - used. - - This is part of the support for allowing completions like: - `System.Co' to complete to System.Console. - - * complete.cs (CompletionSimpleName.AppendResults): Make this - routine reusable. - -2009-04-21 Raja R Harinath - - * cs-parser.jay (GetTokenName): Mark GENERATE_COMPLETION and - COMPLETE_COMPLETION as internal. - -2009-04-17 Miguel de Icaza - - * complete.cs: Include namespace resolution in simple names as - well as global types and types in the using scope in the - resolution. - - * namespace.cs: Supporting infrastrcture to provide completions - based on the current using scope. - - * eval.cs: Introduce an entry point that allows for initialization - to return a list of the files passed on the command line. - -2009-04-14 Marek Safar - - A fix for bug #494243 - * report.cs (SymbolRelatedToPreviousError): Fixed NRE. - -2009-04-13 Marek Safar - - A fix for bug #493887 - * statement.cs: Don't skip string multi-section with default or - null label when populating string hashtable. - -2009-04-06 Marek Safar - - A fix for bug #492329 - * expression.cs (New): Load variable when assigning type parameter - to ref variable. - -2009-04-06 Marek Safar - - A fix for bug #488960 - * decl.cs: Compare MVAR types using non-null values. - -2009-03-27 Marek Safar - - * typemanager.cs, expression.cs: Removed unused nullable checks. - -2009-03-27 Marek Safar - - * *.cs: Removed some gmcs conditionals. - -2009-03-26 Marek Safar - - * generic.cs, support.cs: Moved generics stuff out of support.cs - -2009-03-24 Marek Safar - - * ecore.cs, expression.cs: Use queried type for MethodGroupExpr - DeclaringType. - -2009-03-23 Marek Safar - - * attribute.cs: Consider all members for error reporting when - checking named arguments. - -2009-03-23 Marek Safar - - A fix for bug #487625 - * namespace.cs: Use a warning for all predefined type conflicts. - -2009-03-23 Marek Safar - - A fix for bug #485706 - * statement.cs: Explicitly type catch type argument to pass verifier - check. - -2009-03-22 Miguel de Icaza - - Initial support to provide code completion facilities to consumers - of the evaluator API. - - * cs-tokenizer.cs (CompleteOnEOF): this new property is used to - support the completion engine. When we reach the end of the - input stream instead of returning EOF, when this flag is true the - tokenizer instead produces: - - One GENERATE_COMPLETION token: this token then must be - handled in the grammar at every point where the user - would likely request a completion. - - As many COMPLETE_COMPLETION tokens as necessary. These - tokens are generated to assist the parser in unwinding and - producing a valid parse tree. - - The parser rules do not have to be perfect, the parser needs to be - augmented with judicious use of GENERATE_COMPLETION tokens to - improve the areas where we can provide completion and the parser - needs to add support for COMPLETE_COMPLETION tokens in productions - to make them work. - - It is common to not have enough support for COMPLETE_COMPLETION - under certain rules and that even if we generated the - GENERATE_COMPLETION token that the resulting tree will be invalid - due to the missing rules that support COMPLETE_COMPLETION. - - The final EOF token is produced by having the parser notify the - tokenizer when it reaches the root production that the next token - should be EOF. - - * support.cs (CompletionResult): New Exception. This exception - is thrown to return the completion results when one of the special - completion expressions is reached. - - This exception is thrown by the completing ExpressionStatements - classes that live in complete.cs - - * complete.cs (CompletingExpression): a new base class for - completing expressions. This derives from the - ExpressionStatement class and not from Expression as it allows - completion to happen not only where expressions are expected in - the grammar, but also where statements are expected. - - (CompletionSimpleName): A new class used to provide completions - for SimpleNames. This currently only resolves to local - variables from the evaluator context (GetVars call). - - (CompletionMemberAccess): Implements support for completing member - access patterns. - - * cs-parser.jay: Add support for completion in a few places. - - * eval.cs (GetCompletions): New public API for the evaluator that - returns a list of possible completions given the input. The - return value is an array of completions - - * anonymous.cs (Compatible): If the exception thrown from the - resolved expression is a CompletionResult exception let that one - through instead of printing a diagnostic error in the try/catch. -< -2009-03-22 Miguel de Icaza - - * - - * driver.cs (Main): Use Environment.Exit to quit quickly and - prevent the compiler from doing the usual wait for helper thread - to terminate. - - This is to prevent a slowdown that was reported by Gonzalo on - ASP.NET - -2009-03-19 Marek Safar - - * ecore.cs: Load build-in types directly instead of accessing - an internal field. - -2009-03-18 Marek Safar - - * ecore.cs: Always use unbox.any when available. - -2009-03-18 Marek Safar - - * class.cs: Always set TypeAttributes.BeforeFieldInit conditionally. - -2009-03-17 Marek Safar - - * generic.cs: Removed obsolete version of type inference. - -2009-03-16 Marek Safar - - * typemanager.cs, decl.cs, roottypes.cs, anonymous.cs, nullable.cs, - expression.cs, rootcontext.cs, namespace.cs, ecore.cs, class.cs, - delegate.cs, flowanalysis.cs, cs-parser.jay, driver.cs, - attribute.cs, codegen.cs: Changed RootTypes to be ModuleContainer. - -2009-03-11 Marek Safar - - A fix for bug #482996 - * anonymous.cs: Make sure we are not infering return type when - checking type compatibility. - -2009-03-11 Marek Safar - - * typemanager.cs, generic.cs, parameter.cs, decl.cs, const.cs, - rootcontext.cs, namespace.cs, class.cs, delegate.cs, driver.cs, - generic-mcs.cs, attribute.cs, codegen.cs: Maintain predefined - attributes in their own structure. Needed when accessing their - properties before they are resolved. - -2009-03-09 Marek Safar - - * cs-tokenizer.cs: Optimized GetKeyword using an array instead of - hashtable (~10x faster). - - * driver.cs: Removed wrong Reset. - -2009-03-08 Marek Safar - - * class.cs: Use correct common base type for unmanaged delayed - check. - - * rootcontext.cs: Wrap unhandled exception. - -2009-03-06 Raja R Harinath - - Make SeekableStreamReader self-tuning and arbitrarily seekable - * support.cs (SeekableStreamReader.ResetStream): New. Allocates - the buffer. - (SeekableStreamReader.Position.set): Use it. Simplify logic - which, as a side-effect, makes it arbitrarily-seekable. Tune the - buffer size when the stream needs to be re-read from the beginning. - -2009-03-05 Marek Safar - - A fix for bug #480100 - * parameter.cs: A parameter is not hoisted when used directly as ET. - -2009-03-04 Marek Safar - - * statement.cs: Fixed an issue when using variable is of interface - type. - -2009-03-03 Marek Safar - - A fix for bug #480319 - * report.cs, driver.cs: Support -warnaserror-: option. - -2009-03-03 Marek Safar - - A fix for bug #480867 - * typemanager.cs, expression.cs, ecore.cs: Changed method group - expression to have no valid type. - -2009-03-03 Marek Safar - - A fix for bug #481258 - * class.cs: Set extension method flag in partial container. - -2009-03-03 Marek Safar - - * statement.cs, typemanager.cs: Use expression for StringEmitter. - - * attribute.cs: Add sanity check. - -2009-02-27 Marek Safar - - * class.cs: Add external constructor error. - -2009-02-26 Marek Safar - - A fix for bug #475354 - * convert.cs, nullable.cs, expression.cs, statement.cs: Emit - correctly user defined nullable equality operators. - -2009-02-25 Marek Safar - - A fix for bug #479532 - * expression.cs: Implement NewInitialize::AddressOf. - -2009-02-25 Marek Safar - - A fix for bug #413633 - * expression.cs: Iterate all base class-constraint types. - -2009-02-24 Marek Safar - - A fix for bug #479209 - * literal.cs: Mutate null underlying type. - -2009-02-24 Marek Safar - - A fix for bug #476295 - * convert.cs: Avoid wrapping implicitly convertible reference type. - -2009-02-23 Marek Safar - - * iterators.cs: Create MemberName correctly. - -2009-02-23 Marek Safar - - A fix for bug #478655 - * literal.cs: Check also underlying null type conversion. - -2009-02-21 Marek Safar - - * generic.cs, ecore.cs, class.cs: Removed redundant AsAccessible. - -2009-02-20 Marek Safar - - A fix for bug #477447 - * statement.cs: Add reference to correct parent storey when this - is accessible from deep children storey (more than 1 level). - -2009-02-19 Marek Safar - - A fix for bug #475860 by David Mitchell - * class.cs: Define base type members before setting up member cache. - -2009-02-18 Marek Safar - - A fix for bug #477378 - * nullable.cs, expression.cs, statement.cs: More precise null type - sanity checks. - -2009-02-18 Marek Safar - - A fix for bug #472805 - * typemanager.cs, namespace.cs: Import only visible extension method - types. - -2009-02-18 Marek Safar - - A fix for bug #476895 - * attribute.cs: Use correct resolve context for attribute type. - -2009-02-18 Marek Safar - - A fix for bug #476266 - * anonymous.cs: Mutate multi-dimensional arrays. - -2009-02-18 Marek Safar - - A fix for bug #476400 - * statement.cs, expression.cs: Removed wrong Dispose optimization. - -2009-02-18 Marek Safar - - A fix for bug #476811 - * generics.cs: Fixed null-literal check. - -2009-02-17 Marek Safar - - * typemanager.cs, convert.cs, flowanalysis.cs, driver.cs, - expression.cs, ecore.cs, rootcontext.cs, eval.cs, class.cs: More - messing with static variables. - -2009-02-16 Marek Safar - - A fix for bug #475965 - * generics.cs: Check generic parameter type after extracting from - Expression. - -2009-02-16 Marek Safar - - A fix for bug #475823 - * convert.cs, expression.cs, literal.cs, ecore.cs, cfold.cs: Add - typed-null support. - -2009-02-14 Marek Safar - - * modifiers.cs, decl.cs, ecore.cs, class.cs, flowanalysis.cs: - Simplified event field definition using backing field and not - field builder directly. - - * expression.cs (EmitLdArg): Optimize fast paths. - -2009-02-13 Marek Safar - - A fix for bug #475327 - * expression.cs (ArrayCreation): Don't mutate values optimized away. - -2009-02-13 Marek Safar - - A fix for bug #475342 - * cs-parser.jay: Using 'super' instead of 'base' to call base - constructor crashes compiler. - -2009-02-13 Marek Safar - - A fix for bug #475354 - * expression.cs (Constantify): Add nullable types. - - * const.cs (EmitDecimalConstant): Avoid explicit cast. - -2009-02-12 Marek Safar - - A fix for bug #475246 - * expression.cs: More broken flowanalysis hacking needed. - -2009-02-12 Marek Safar - - * attribute.cs: Compare only ref/out array modifiers. - -2009-02-11 Marek Safar - - * statement.cs: Use member cache when looking for foreach members. - -2009-02-11 Marek Safar - - * expression.cs: Don't expose internal initializer types. - - * statement.cs: Check also explicit conversions for goto case. - -2009-02-11 Marek Safar - - * convert.cs, statement.cs: Removed usage of IsAssignableFrom. - -2009-02-10 Marek Safar - - * *.cs: Replace null-type with NullLiteral where appropriate. - -2009-02-09 Marek Safar - - * expression.cs: Initializer of reference argument use temporary - variable to be verifiable. - - * parameter.cs: Share EmitLdArg. - -2009-02-09 Marek Safar - - A fix for bug #473559 - * class.cs: Fixed: Not reporting error about nested class with the - same name. - -2009-02-06 Scott Peterson - - Contributed under the MIT/X11 license. - - * generic.cs: Added VerifyVariantTypeParameters which performs new - variance verification logic. The old logic, based on the spec, was - wrong because the spec is full of LIES! - - * generic-mcs.cs: Stubbed out the VerifyVariantTypeParameters method. - - *typemanager.cs: Moved variance verification logic to GenericTypeExpr. - - * class.cs: - * ecore.cs: Added calls to the new variance verification logic. - - * parameter.cs: - * delegate.cs: Removed calls to the old variance verification logic. - -2009-02-06 Marek Safar - - * delegate.cs: Use cached Invoke method directly. - -2009-02-06 Marek Safar - - * expression.cs: Emit expression tree for hoisted variable access. - -2009-02-04 Marek Safar - - * namespace.cs: Add better extension class check. - -2009-02-05 Scott Peterson - - * generic.cs: Fixed typeo (TypeParameter.Variacne). - -2009-02-04 Scott Peterson - - This patch adds initial generic variance support to the compiler. - It is contributed under the MIT/X11 license. - - * typemanager.cs: Modified ImplementsInterface to check variance. - Added VerifyVariantTypeParameters which checks the specified type to see - if it uses a variant type parameter as a type argument (which is not - allowed). Added IsVariantOf which determins if the first type is a - variant of the second. NOTE: This only supports reference types at - the moment to conform with the current level of VM support. When the - VM supports value types, this will follow step. - - * generic.cs: Added the Variance enum. Added a Variance property to - TypeParameter and added variance support to definition phase. Added a - Variance property to TypeParameterName. Also check to make sure that - no variant types appear in generic method parameters. - - * cs-tokenizer.cs: Modified parse_less_than to tokenize the variance - keywords if the langversion supports it. - - * parameter.cs: Added Parameter.VerifyNoVariantTypeParameters to ensure - that variant types are only used in legal positions. Also added - ParametersCompiled.VerifyNoVariantTypeParameters to check all of its - parameters. - - * decl.cs: Construct TypeParameter with the variance information. - - * convert.cs: Checks variance in ImplicitReferenceConversionExists - and ImplicitConversionStandard. - - * rootcontext.cs: Added new "Future" language version. - - * class.cs: In TypeContainer.DoDefineMembers, ensure that contravariant - type parameters are not used as type arguments in interface inheritance. - In MemberBase.DoMemberDependentChecks, ensure that contravariant type - parameters are not used as method return types. In MemberBase. - ResolveMemberType, ensure that variant type parameters are not used - as type arguments. Also call VerifyNoVariantTypeParameters on every - set of parameters which are resolved. - - * delegate.cs: Modified Delegate.Define to ensure that variant - parameters are not used as type arguments and that a contravariant - parameter is not used as the return type. Also call - VerifyNoVariantTypeParameters on the delegate parameters. - - * cs-parser.jay: Modified grammar to support "in" and "out" keywords - to specify generic variance. - - * driver.cs: Added support for LanguageVersion.Future in the form of - "-langversion:future". - - * generic-mcs.cs: Stubbed out new members in generic.cs. - -2009-02-03 Marek Safar - - * class.cs, generic.cs: Emit type parameter constraints for nested - types. - -2009-02-02 Marek Safar - - A fix for bug #471213 - * class.cs: Avoid emitting backing field for abstract event fields. - -2009-02-01 Marek Safar - - A fix for bug #359731 - * cs-tokenizer.cs, cs-parser.jay: Correctly parse nested query - expressions. - -2009-01-30 Marek Safar - - A fix for bug #470767 - * statement.cs: Introduced BlockScopeExpression, needed when - expression tree conversion has to emit scope variables. - -2009-01-29 Marek Safar - - * class.cs: Remove duplicate CallingConvention. - -2009-01-29 Marek Safar - - *.cs: Rename Parameters to ParametersCompiled and ParametersImported - when I finally found the right naming convention. - -2009-01-29 Marek Safar - - * cs-tokenizer.cs: Put back different open parens optimization. - -2009-01-28 Marek Safar - - A fix for bug #470227 - * cs-tokenizer.cs: Remove too agressive parser optimization. - -2009-01-28 Marek Safar - - A fix for bug #324319 - * class.cs: Remove too early base type resolve. - -2009-01-27 Marek Safar - - A fix for bug #324319 - * ecore.cs: Explicitly type null when assigning to type argument to - make pass verifier check. - -2009-01-27 Marek Safar - - * anonymous.cs: Fixed recent regression when initializing captured - this. - -2009-01-26 Marek Safar - - A fix for bug #469019 - * anonymous.cs: Use all parent type parameters when instantiating - nested generic storey. - -2009-01-26 Marek Safar - - * expression.cs: Check for null instance methodgroup expression. - -2009-01-26 Marek Safar - - A fix for bug #469244 - * cs-tokenizer.cs, cs-parser.jay: Fixed parsing of nullable type - instance inside a conditional expression. - -2009-01-23 Marek Safar - - * typemanager.cs, generic.cs, parameter.cs, decl.cs, anonymous.cs, - expression.cs, report.cs, ecore.cs, attribute.cs: Use common - GetElementType and HasElementType. IsValueType clean up. - -2009-01-23 Marek Safar - - * nullable.cs: Use common EmitCall. - - * expression.cs: Emit constraint. for virtual calls only. - -2009-01-23 Marek Safar - - * typemanager.cs, generic.cs, eval.cs, convert.cs, const.cs, - expression.cs, statement.cs, rootcontext.cs, ecore.cs, class.cs, - driver.cs, attribute.cs, enum.cs: Split IsValueType and IsStruct - checks. - -2009-01-22 Jb Evain - - * anonymous.cs: make anonymous types' ToString implementation - match what csc outputs. - -2009-01-21 Marek Safar - - * typemanager.cs, ecore.cs, iterator.cs: TypeLookupExpression clean - up. - -2009-01-17 Marek Safar - - * convert.cs, ecore.cs: Explicitly casts type arguments to pass - verifier checks. - -2009-01-16 Marek Safar - - * nullable.cs (LiftedBinaryOperator): Check for all possible null - expressions. - -2009-01-15 Marek Safar - - A fix for bug #466634 - * statement.cs: Add reference for nested storey when only this - is captured. - -2009-01-15 Marek Safar - - A fix for bug #466474 - * codegen.cs: Emit SecurityPermissionAttribute when -unsafe option - was specified. - -2009-01-15 Marek Safar - - * iterators.cs, anonymous.cs, expression.cs, statement.cs, ecore.cs: - Fixed nested stories parent referencing process. Also fixes #463985. - -2009-01-06 Marek Safar - - * decl.cs, iterators.cs, expression.cs, statement.cs, doc.cs, - class.cs, cs-parser.jay, codegen.cs: Clean up destructor - implementation. Also fixes #463108. - -2009-01-05 Marek Safar - - A fix for bug #416109 - * decl.cs: Issue correct CLSAttribute warning location. - -2009-01-05 Marek Safar - - A fix for bug #456775 - * attribute.cs: Use attribute owner scope when resolving attribute - arguments. - -2009-01-05 Marek Safar - - A fix for bug #457257 - * decl.cs: Fixed incorrect member declaring type comparison. - -2009-01-05 Marek Safar - - A fix for bug #460896 - * driver.cs: Handle /RES resources as embeddable. - -2009-01-05 Marek Safar - - A fix for bug #462515 - * ecore.cs: Report inacessible members upwards. - -2009-01-05 Marek Safar - - A fix for bug #463190, #463192 - * decl.cs, namespace.cs: Also import internal extension classes. - -2009-01-04 Marek Safar - - A fix for bug #463415 - * generic.cs: Use right index for RemoveDependentTypes. - -2009-01-02 Marek Safar - - A fix for bug #463196 - * expression.cs: Fixed enum to null comparison. - -2009-01-02 Marek Safar - - A fix for bug #463121 - * nullable.cs: Fixed nullable user equality operator comparison. - -2009-01-02 Marek Safar - - A fix for bug #462950 - * class.cs, decl.cs: Use full explicit name when defining automatic - property backing field. - -2009-01-02 Marek Safar - - A fix for bug #462592 - * pending.cs: Emit type arguments for generic proxy method. - -2008-12-30 Marek Safar - - * expression.cs (As): Mutate all type arguments. - -2008-12-29 Marek Safar - - A fix for bug #462622 - * anonymous.cs: Resolve anonymous type GetHashCode in unchecked - context. - -2008-12-29 Marek Safar - - A fix for bug #450782 - * ecore.cs: Consider more variables of form V.I to be fixed. - -2008-12-29 Marek Safar - - A fix for bug #460712 - * typemanager.cs: Core types could be imported. - -2008-12-28 Marek Safar - - A fix for bugs #460847, #460772, #458049, #457339, #447807 - * generic.cs, parameter.cs, lambda.cs, linq.cs, anonymous.cs - statement.cs, ecore.cs, class.cs, delegate.cs, flowanalysis.cs - cs-parser.jay, driver.cs: LINQ implementation upgrade to deal with - user lambdas used inside query clauses. - -2008-12-18 Marek Safar - - A fix for bug #460229 - * cs-tokenizer.cs: Ignore wrongly placed BOM markers. - -2008-12-18 Marek Safar - - A fix for bug #459952 - * decl.cs, namespace.cs: Use common CheckAccessLevel. - -2008-12-18 Marek Safar - - A fix for bug #459630 - * convert.cs: Enum to valuetype conversion is not allowed. - -2008-12-18 Marek Safar - - A fix for bug #457087 - * generic.cs: Don't crash when constraint comes from type - declaration. - -2008-12-16 Marek Safar - - A fix for bug #459221 - * anonymous.cs, statement.cs: Delay only captured this - initialization. - -2008-12-12 Marek Safar - - A fix for bug #457489 - * anonymous.cs, statement.cs: Split anonymous storey instantiation - and initialization to capture scope initializers correctly. - -2008-12-11 Marek Safar - - * generic.cs, parameter.cs, expression.cs, statement.cs, doc.cs: - ParameterReference refactoring. - -2008-12-03 Marek Safar - - * typemanager.cs, namespace.cs, driver.cs: Allow ExtensionAttribute - to be imported from any assembly. - -2008-12-03 Marek Safar - - * parameter.cs, lambda.cs, linq.cs, iterators.cs, anonymous.cs - statement.cs, class.cs, cs-parser.jay: Removed duplicate parameters - from anonymous method and lambda expression. - -2008-12-01 Marek Safar - - A fix for bug #448560 - * expression.cs (As): Box any generic type arguments to be - verifiable. - -2008-11-29 Raja R Harinath - - Add tripwire for implicit conversion bugs - * ecore.cs (MethodGroupExpr.Error_ArgumentCountWrong): New helper - for CS1501 error. - (MethodGroupExpr.OverloadResolve): Add sanity check between - IsApplicable and VerifyArgumentsCompat. - (VerifyArgumentsCompat): Report CS1501 where appropriate. - -2008-11-29 Raja R Harinath - - Fix build break in System.Data_test - * convert.cs (ImplicitConversionExists): Move NullLiteral - conversions ... - (ImplicitStandardConversionExists): ... here. - -2008-11-28 Marek Safar - - * literal.cs: Emit correctly explicit null to nullable cast. - -2008-11-28 Marek Safar - - * ecore.cs, generics.cs: Fixed crash when type arguments fail to - resolve. - -2008-11-28 Marek Safar - - A fix for bug #449005 - * convert.cs, nullable.cs: Use only one implicit nullable - conversion. - -2008-11-27 Marek Safar - - * convert.cs, literal.cs: More Convert cleanup is needed. - -2008-11-27 Marek Safar - - * decl.cs, class.cs: Fixed misleading error message. - -2008-11-26 Marek Safar - - A fix for bug #449005 - * nullable.cs (EmitEquality): Disable optimization for user operator - operands. - -2008-11-25 Marek Safar - - A fix for bug #447027 - * anonymous.cs (HoistedVariable): Cache also outer access to deal - with context variables stored as expression instances. - -2008-11-25 Marek Safar - - A fix for bug #447027 - * delegate.cs: Fixed delegate VerifyMethod logic. - -2008-11-24 Marek Safar - - * ecore.cs, delegate.cs: MethodGroup expressions can be applicable - but not verifiable. - -2008-11-21 Marek Safar - - * typemanager.cs, decl.cs, anonymous.cs, class.cs, enum.cs: Rewrote - member type resolve to follow normal flow, instead of random - property access. - -2008-11-21 Marek Safar - - * iterators.cs (GetEnumeratorStatement): Re-use already resolved - type. - -2008-11-21 Marek Safar - - * const.cs: Emit decimal array constant as literal. - -2008-11-20 Marek Safar - - * iterators.cs, ecore.cs: Removed CurrentBlock statement. - -2008-11-19 Marek Safar - - * eval.cs, location.cs, driver.cs (Location.SourceFiles): Turned - into real property (saves 8 MB for corlib compilation). - -2008-11-19 Marek Safar - - * generic.cs, lambda.cs, linq.cs, iterators.cs, anonymous.cs, - nullable.cs, expression.cs, statement.cs, ecore.cs, cs-parser.jay - generic-mcs.cs: Small cleanup of TypeArguments. - -2008-11-18 Marek Safar - - * generic.cs, iterators.cs, anonymous.cs, nullable.cs, ecore.cs, - expression.cs, namespace.cs, generic-mcs.cs, class.cs: Small cleanup - of ConstructedType expression, renamed to GenericTypeExpr. - -2008-11-17 Marek Safar - - A fix for bug #445303 - * location.cs (IsConditionalDefined): Handle undefined global - defines. - -2008-11-17 Marek Safar - - A fix for bug #444678 - * expression.cs (TryReduceConstant): Always create new constant - instance. - -2008-11-17 Marek Safar - - A fix for bug #444673 - * ecore.cs: Ignore open generic types when used as generic type - instance fields. - -2008-11-17 Marek Safar - - A fix for bug #445458 - * expression.cs, cs-parser.jay: Don't crash when an expression - statement is null. - -2008-11-17 Marek Safar - - A fix for bug #445464 - * expression.cs, cs-parser.jay: Fixed typeof of non-generic type - inside unbound type. - -2008-11-14 Jb Evain - - * driver.cs: ignore empty -nowarn argument such as - the one in -nowarn:12,13,,. - -2008-11-13 Marek Safar - - A fix for bug #444271 - * anonymous.cs: Rescan parent storeys when best candidate was - undone. - -2008-11-13 Marek Safar - - * generic.cs, expression.cs, ecore.cs, cs-parser.jay: Removed - useless UnboundTypeExpression. - - * attribute.cs: Do check obsolete attribute on generic types. - -2008-11-12 Marek Safar - - A fix for bugs #425680, #400139 - * ecore.cs, expression.cs: Trying to do some almost_matched_members - refactoring. - -2008-11-11 Marek Safar - - A fix for bug #435747 - * assign.cs, expression.cs: Cleanup New assignment to emit correcly - compound value types assignment. Few micro optimizations added. - -2008-11-10 Marek Safar - - A fix for bug #442610 - * anonymous.cs (MutateConstructor): More SRE hacking. - -2008-11-10 Marek Safar - - A fix for bug #442579 - * ecore.cs: Also initialize expanded form of a method with 1 params - parameter. - -2008-11-06 Marek Safar - - * expression.cs (UnaryMutator): Do early l-side check. - -2008-11-05 Miguel de Icaza - - * codegen.cs (InitDynamic): also setup Assembly.Name like we do in - Init, otherwise we would crash later on when checking for friend - assemblies. - - * eval.cs: Do not hide errors from invalid calls to LoadAssembly. - Otherwise we never get any meaningful information as to what - failed. - -2008-11-05 Marek Safar - - A fix for bug #436318 - * driver.cs, report.cs: Add -warnaserror:Wn to command line options. - -2008-11-05 Miguel de Icaza - - * namespace.cs: Turns out that it was a really bad idea to hide - the errors for namespaces not found here in eval mode. - - * eval.cs: When we process using clauses, only enter those into - the list of valid using clauses after they have been validated. - - The above change gives the proper semantics: it does not - senselessly report the same errors with broken using statements by - never storing them in the first place when they are invalid. - -2008-11-05 Marek Safar - - A fix for bug #421839 - * cs-parser.jay: Remove expression from coalesce rule to force lower - priority than the assignment operator. - -2008-11-05 Marek Safar - - A fix for bug #437875 - * nullable.cs: Compile correctly method group operand used with null - coalescing operator. - -2008-11-04 Marek Safar - - A fix for bug #434589 - * expression.cs (Binary): Ignore lifted conversions when at least - one operand is of reference type. - -2008-11-04 Marek Safar - - * cs-parser.jay: Better syntax error report. - -2008-11-03 Marek Safar - - A fix for bug #436792 - * cs-parser.jay: Use GetLocation to access location. - -2008-11-03 Marek Safar - - A fix for bug #440774 - * cs-parser.jay: Also set current_array_type when parsing local - variables types. - -2008-11-03 Marek Safar - - A fix for bug #440785 - * expression.cs (As): Don't resolve self modifing expression - multiple times. - -2008-11-03 Marek Safar - - A fix for bug #439447 - * cs-tokenizer.cs: Tokenize surrogates only where allowed. - -2008-11-03 Marek Safar - - A fix for bug #437571 - * cs-parser.jay: Fixes internal error for invalid expression - statements. - -2008-10-17 Marek Safar - - * ecore.cs: Resolve correctly ambiguous params delegate methods. - -2008-10-17 Marek Safar - - * generic.cs, anonymous.cs: Simplified GetDeclarations. - -2008-10-17 Marek Safar - - * cs-tokenizer.cs: More precise cast parsing. - -2008-10-16 Martin Baulig - - * anonymous.cs (AnonymousMethodStorey): Put back the - `hoisted_locals' hashtable and use it in EmitType(). - -2008-10-15 Marek Safar - - * cs-tokenizer.cs, nullable.cs, expression.cs, statement.cs, - cs-parser.jay: Tokenizer optimizations and memory reduction, saves - ~5MB for corlib. - -2008-10-14 Marek Safar - - * cs-tokenizer.cs: Add bool type to the list of valid cast tokens. - -2008-10-14 Marek Safar - - * statement.cs: Mutate scope initializers. - -2008-10-14 Marek Safar - - * expression.cs: Use typeless value for This constant. - - * ecore.cs: Access FieldInfo via GetConstructedFieldInfo. - -2008-10-14 Marek Safar - - * cs-tokenizer.cs, cs-parser.jay: Unify context sensite keyword - tokenizer. - -2008-10-13 Marek Safar - - * cs-tokenizer.cs: Add missing alias qualifier and dotted generic - type to type cast. - -2008-10-13 Marek Safar - - * cs-tokenizer.cs, expression.cs, cs-parser.jay: Reworked parens - parser and tokenizer. Fixes many ambiguities including #433258. - -2008-10-10 Marek Safar - - * cs-parser.jay: Fixed missing accessor recovery. - -2008-10-10 Marek Safar - - A fix for bug #433701 - * expression.cs: Better error message. - -2008-10-10 Marek Safar - - * cs-parser.jay, expression.cs: Start reporting real parser errors. - - * Makefile: Disabled unused debug symbols. - - Also fixes: #320556, #321097, #321656, #321876, #351316 - -2008-10-09 Miguel de Icaza - - * eval.cs: rename "" to "{interactive}", to work - around a requirement in the compiler that this be a valid - filename, and in Windows it is not (433886). - -2008-10-09 Marek Safar - - * cs-tokenizer.cs, cs-parser.jay: Fixed more subtle parser problems - -2008-10-08 Marek Safar - - * cs-tokenizer.cs, eval.cs, anonymous.cs, statement.cs, class.cs - cs-parser.jay: Generic type declaration and type arguments cleanup. - -2008-10-05 Marek Safar - - * cs-parser.jay: Allow parsing weird array creation construct. - -2008-10-05 Marek Safar - - * cs-parser.jay: Conflicts reduction. - -2008-10-04 Marek Safar - - * cs-parser.jay: Conflicts reduction. - -2008-10-04 Raja R Harinath - - Fix #398325 - * flowanalysis.cs (MyBitvector.MakeShared): Rename from 'Shared' - property. Add a 'count' hint about the use of the shared vector. - Ensure that we don't leak out dirty bits. - (UsageVector.MergeChild): Throw away information about variables - in child vectors. - Based on patch and analysis by Moritz Kroll . - -2008-10-03 Marek Safar - - A fix for bug #431746 - * iterators.cs, anonymous.cs: Re-initialize hoisted iterator - parameters when iterator is created. - -2008-10-03 Marek Safar - - A fix for bug #431827 - * expression.cs: Fixed right based pointer arithmetic operations - emit. - -2008-10-03 Marek Safar - - A fix for bug #353779 - * assign.cs, expression.cs: Fixed compound assignment conversions. - -2008-10-02 Marek Safar - - A fix for bug #375262 - * statement.cs: Refactor ArrayForeach to be usable with string - indexer. Optimized single dimentional arrays foreach. - -2008-10-02 Marek Safar - - A fix for bug #431255 - * anonymous.cs, expression.cs: Removed broken optimization. - -2008-10-01 Marek Safar - - * anonymous.cs: Use full type parameters of parent generic - containers. Removed unnecessary AddParentStoreyReference call. - -2008-10-01 Marek Safar - - A fix for bug #324702 - * class.cs: Use better shorter names for explicit interface member - implementations. - - * ecore.cs, typemanager.cs: Convert only mscorlib predefined names. - -2008-10-01 Marek Safar - - * expression.cs: Use new interface to check fixed expression. - -2008-10-01 Marek Safar - - A fix for bug #421101 - * expression.cs, statement.cs, ecore.cs: Use IFixedExpression - interface to check for fixed fixed-buffers. - -2008-10-01 Marek Safar - - A fix for bug #429264 - * assign.cs, anonymous.cs, ecore.cs: More type mutators added. - - * delegate.cs: Removed unnecessary casts. - -2008-09-30 Marek Safar - - A fix for bug #352151 - * decl.cs, iterators.cs, anonymous.cs, report.cs, namespace.cs, - class.cs: Fixed already defined explicit interface members check. - -2008-09-29 Rodrigo Kumpera - - cs-tokenizer.cs: Fix typo. - -2008-09-28 Miguel de Icaza - - * eval.cs (InteractiveBase): The quit command now just sets a - flag, instead of calling Environment.Exit(), it is milder on - embedded hosts. - - CompiledMethod is now in Mono.CSharp, not nested inside - the Evaluator, it was inconvenient to use. - -2008-09-27 Miguel de Icaza - - * eval.cs (Evaluator): Introduce Compile method, to allow compiled - code to be invoked without having to reparse. - -2008-09-27 Miguel de Icaza - - * ecore.cs: The recent changes to FieldExpr broke this as well. - Fixes LINQ queries in the interactive shell. - - * Multiple files: indentation fixing for the Mono coding - guidelines for the switch statement. - - * eval.cs: Make the Evaluator API thread safe. - -2008-09-26 Marek Safar - - * anonymous.cs, statement.cs, class.cs, cs-parser.jay: Simplified - constructor parsing. - -2008-09-26 Marek Safar - - A fix for bug #325326 - * statement.cs: Check possible mistaken empty statement using - explicit blocks only. - -2008-09-25 Miguel de Icaza - - * eval.cs (LoadAssembly, ReferenceAssembly): Call - RootNamespace.ComputeNamespaces to update the internal list of - namespaces, this is no longer done for us. - - (InteractiveBase): Use the Evaluator APIs instead of calling into - Driver directly - -2008-09-25 Marek Safar - - A fix for bug #429264 - * expression.cs: Missing mutator for access to multidimensional - arrays. - -2008-09-25 Marek Safar - - * class.cs, statement: Emit DebuggerHidden attribute for iterator - entry wrapper. - - * driver.cs: Missing input argument check. - -2008-09-25 Marek Safar - - * typemanager.cs, generic.cs, eval.cs, decl.cs, anonymous.cs, - expression.cs, statement.cs, rootcontext.cs, class.cs, - cs-parser.jay, driver.cs, generic-mcs.cs, enum.cs: Removed obsolete - DefineMembers. - -2008-09-24 Miguel de Icaza - - * ecore.cs (FieldExpr): Only initialize eclass when we return a - fully constructed FieldExpr, fixes the regression introduced in - the last commit. - - * ecore.cs, expression.cs: Plug back the eclass initialization as - otherwise it regresses `csharp'. - -2008-09-24 Marek Safar - - * typemanager.cs, decl.cs, convert.cs, assign.cs, expression.cs, - ecore.cs, attribute.cs: Moved obsolete method checks from emit - phase to resolve phase. It resolves problems with expression trees - and fixes bugs #323796, #325156. - -2008-09-23 Marek Safar - - * codegen.cs: Report better error when symbol writer is missing. - -2008-09-23 Marek Safar - - * codegen.cs: Set .NET symbol writer. - - * decl.cs: Guard against null generic arguments. - - * report.cs: Don't report exactly same additional details. - -2008-09-22 Marek Safar - - A fix for bug #324917 - * cs-parser.jay: Add missing multidimensional non-expression type - ranks. - -2008-09-22 Marek Safar - - A fix for bug #428191 - * anonymous.cs: Create an outer generic fields also for non-storey - anonymous methods. - -2008-09-22 Marek Safar - - A fix for bug #378294 - * class.cs: Make fixed size buffers gmcs feature only. - -2008-09-22 Marek Safar - - A fix for bug #355622, #324993 - * assign.cs, const.cs, class.cs: Create new EmitContext for each - field initializer. - -2008-09-19 Marek Safar - - * nullable.cs, expression.cs, namespace.cs, delegate.cs: Duplicate - error reporting. - -2008-09-19 Marek Safar - - A fix for bug #416110 - * generic.cs: Struct constraint results in default ctor and - ValueType base type constraint to be set. - -2008-09-19 Marek Safar - - A fix for bug #423791 - * generic.cs: Fixed params output type type-inference. - -2008-09-19 Marek Safar - - * cs-parser.jay, expression.cs: Fixed few expression crashes. - -2008-09-19 Marek Safar - - * cs-tokenizer.cs: Don't break on extra partial modifier. - -2008-09-19 Marek Safar - - A fix for bug #427592 - * generic.cs: Use common parameter resolve method. - -2008-09-18 Marek Safar - - A fix for bug #414758 - * expression.cs, ecore.cs: Fixed crash when accessing non-static - property. - -2008-09-18 Marek Safar - - * driver.cs, namespace.cs: Read types and namespaces after all - requested assemblies are loaded, fixes issues with System.Core - auto-reference, and #419888. - -2008-09-18 Marek Safar - - A fix for bug #417705 - * cs-parser.jay: Fixed as/is operator expression split. - -2008-09-18 Marek Safar - - * const.cs, expression.cs, statement.cs, ecore.cs, cs-parser.jay: - Fixed expression tree representation of empty new expression and - new initializer expression. - -2008-09-18 Miguel de Icaza - - * eval.cs: Remove warning, keep reference to driver around. - - * Hide fields that do not need to be public. - -2008-09-17 Marek Safar - - A fix for bug #426385 - * expression.cs (ImplicitlyTypedArrayCreation): Use full implicit - conversion for array elements. - -2008-09-17 Marek Safar - - * expression.cs, statement.cs, class.cs, cs-parser.jay: Fixed - void parsing conflicts. - -2008-09-15 Marek Safar - - A fix for bug #425601 - * driver.cs, typemanager.cs, namespace.cs: Automatically reference - System.Core only when there is no custom ExtensionAttribute - implementation. - -2008-09-15 Miguel de Icaza - - * namespace.cs: Do not report CS0246 (name - -2008-09-12 Marek Safar - - A fix for bug #425669 - * generic.cs: Don't cache generic static anonymous method - containers. - -2008-09-12 Marek Safar - - * generic.cs, class.cs, delegate.cs: Check recursive inherited - conflicting constraints. - -2008-09-12 Raja R Harinath - - * cs-tokenizer.cs (consume_identifier): Allow partial methods in - mcs too. - -2008-09-12 Marek Safar - - * literal.cs, convert.cs, expression.cs, statement.cs: More null - to null pointer conversion fixes. - -2008-09-11 Marek Safar - - * cs-parser.jay, expression.cs: An implicitly typed local variable - declarator cannot use an array initializer. - -2008-09-11 Marek Safar - - * cs-parser.jay: Reduced number of printed tokens, add sorting. - -2008-09-11 Marek Safar - - * generic.cs (InflatedConstraints): Don't crash when constraints - are different. - - * cs-parser.jay: const_declarator is a block. - - * constant.cs: Check for not allowed NaN conversions. - -2008-09-10 Miguel de Icaza - - * driver.cs: Drop --shell argument, the compiler is no longer a - REPL. - - * eval.cs: Move most of the code that deals with evaluation into - this file and document the public API from repl.cs - - * repl.cs: Remove from here. - -2008-09-10 Marek Safar - - A fix for bug #424684 - * generic.cs: Generic class constraints must come first. - -2008-09-09 Miguel de Icaza - - * cs-parser.jay: Improve error reporting for syntax errors in - statements and expressions, we now report the expected tokens - instead of reporting the useless "; expected". - - Drop the strings from the token declaration, it turns out that - they did not do what I thought they did. Instead they were adding - two sets of tokens to the tables. - -2008-09-09 Marek Safar - - * typemanager.cs, generic.cs, parameter.cs, expression.cs, class.cs, - delegate.cs: Share special type check. - -2008-09-09 Marek Safar - - A fix for bug #423981 - * expression.cs (EmitBranchable): Correctly emit inverted float conditions. - -2008-09-09 Marek Safar - - * ecore.cs (ReducedConstantExpression): Implemented ConvertExplicitly and - ConvertImplicitly. - -2008-09-09 Marek Safar - - A fix for bugs: #324750, #335946 - * cs-tokenizer.cs, cs-parser.jay, expression.cs: Use a custom - lookup rule to determine ?-based tokens. - -2008-09-08 Miguel de Icaza - - * repl.cs (OptionalAssign.EmitStatement): It is possible that some - expressions (like event adding or removing) end up here, so we - need to treat those as statements. - - Add LoadAssembly method. - -2008-09-04 Miguel de Icaza - - * repl.cs: Add Time method. - -2008-09-05 Marek Safar - - * cs-tokenizer.cs: Fixed swaped UTF-16 surrogates parsing. - -2008-09-05 Miguel de Icaza - - * repl.cs: Add workaround for old compilers. - -2008-09-04 Jb Evain - - * repl.cs (PrettyPrint): pretty print everything that - implements IDictionary, as well as IEnumerables. Also, - add a quit helper property. - -2008-09-04 Marek Safar - - * constant.cs: Better error reporting for decimal literals. - - * class.cs, attribute.cs, typemanager.cs: Emit more fixed buffer - field attributes. - -2008-09-04 Marek Safar - Miguel de Icaza - - A fix for bug #422951 - * assign.cs (Assign.DoResolve): Perform the type conversions - checks before we attempt to initialize `New' initializers. - -2008-09-04 Marek Safar - - A fix for bug #422853 - * delegate.cs (DelegateCreation): Add special handling for - EmptyExpression.Null instance expression which is just another - hack for undecided member instance exression. - -2008-09-04 Marek Safar - - * expression.cs, ecore.cs: Emit full expression tree for reduced - binary expressions. - -2008-09-04 Marek Safar - - * expression.cs (This): Guard against multi-resolving. - - * ecore.cs, statement.cs (Throw): Simplified. - - * flowanalysis.cs: Also verify event fields. - -2008-09-04 Miguel de Icaza - - * assign.cs (Assign.DoResolve): Perform the type conversions - checks before we attempt to initialize `New' initializers. - - * repl.cs (PrettyPrint): Add Hashtable prettyprint - - * anonymous.cs (AnonymousTypeClass): On EvalMode make the class - public. - - * repl.cs: Update help. - -2008-09-03 Miguel de Icaza - - * driver.cs (ProcessDefaultConfig): Now it encapsulates all the - handling of the default config handling, including the special - treatment of System.Core assembly. - - Fixes the REPL processing for LINQ. - -2008-09-03 Marek Safar - - A fix for bug #422507 - * expression.cs (UnboxCast): Add missing child expression mutator. - -2008-09-03 Marek Safar - - * driver.cs: Don't self reference System.Core assembly. - -2008-09-03 Marek Safar - - A fix for bug #422507 - * expression.cs (StringConcat): Add missing type mutator. - -2008-09-03 Marek Safar - - * generic.cs (TypeInferenceContext): Follow equality rule for - constructed type lower bound type inference. - -2008-09-02 Miguel de Icaza - - * getline.cs (CmdRefresh): Apply patch from Douglas S. Blank - which updates the cursor position on - refresh. - -2008-09-02 Marek Safar - - A fix for bug #367145 - * driver.cs: Fixed import of extension methods when using -noconfig - option. - -2008-09-02 Marek Safar - - * iterator.cs: Don't emit GetEnumerator method twice but call a generic - version from non-generic implementation instead. - -2008-09-01 Marek Safar - - A fix for bug #418908 - * class.cs: Use AddScopeStatement for field initializers. - -2008-09-01 Marek Safar - - A fix for bug #415385 - * ecore.cs, convert.cs: Do method group conversion for equal group types. - -2008-09-01 Marek Safar - - A fix for bug #421736 - * iterators.cs: Don't crash on unreachable iterators. - -2008-09-01 Marek Safar - - A fix for bug #421628 - * parameter.cs, attribute.cs: Clone also parameter attributes. - -2008-08-30 Miguel de Icaza - - * namespace.cs (LookupType): In EvalMode, try to replace - the TypeBuilder from our cache with a Type as Reflection.Emit does - not like to mix code from older assemblies emitted and new - assemblies emitted. - - This sounds like a serious Mono bug that prevents multiple - assemblies to be generated and consumed at the same time. - - * cs-parser.jay (push_current_class): Do not make interactive - classes internal or private, make them public as we currently - generate each new class in a new assembly. - -2008-08-29 Miguel de Icaza - - * decl.cs, roottypes.cs, class.cs:: Add an infrastructure to - remove types that are entered into the global namespace during - parsing so that we can remove them on failure. - - * cs-parser.jay: Parsing: we now keep track of types that are - entered into global variables and queue those in case the parsing - or resolution fail. - - This happens in a few situations: during partial-input, we invoke - the parser repeatedly for example with the string "class X", this - would cause X to be registed, and we need to remove this - registration so that another parse attempt later with say "class X {" - would actually work. - - Additionally, if there is an error in the resolution phase, for - example: "class X : NonExistant {}" th - - * cs-parser.jay: Be more precise with the errors being raised, - instead of flagging all exceptions during parsing to be attributed - to the parsing process, distinguish those from errors happening in - the actions and hint that using -v would produce the actual - exception. - - * repl.cs: Do not load all compiler references on each reset, - doing the partial reset takes care of this. - -2008-08-28 Miguel de Icaza - - * repl.cs: Add support for loading all the files from - ~/.config/csharp/*cs as startup scripts and ~/.config/csharp/*.dll - as shell libraries. - - Introduce a micro-parser that is able to deambiguate on its input - whether we are dealing with a compilation unit (namespace, class, - interface, struct, delegate) declaration or a statement. This - allows both declarations and statements to be entered. - - Set history size by default to 300 lines. - - Instead of distinguishing based on the parser.InteractiveResult, - have only two cases: statements were parsed, or a compilation unit - was. Always pull the Using statement additions from the - compilation unit parse. - - * cs-tokenizer.cs: Rename tokens to better describe their intent - (EvalStatementParserCharacter and EvalCompilationUnitParserCharacter). - - * rootcontext.cs: Split EvalMode into EvalMode and StatementMode. - EvalMode is used to trigger the lookup of global variables while - StatementMode is used turn variable declarations into static - fields. - - * getline.cs: Allow history size to be set. - -2008-08-29 Marek Safar - - A fix for bug #360755 - * ecore.cs (SimpleName): Exclude indexers from simple name resolve. - -2008-08-29 Marek Safar - - * generic.cs, iterators.cs, codegen.cs: Removed unused variable. - - * typemanager.cs, statement.cs, ecore.cs, enum.cs: Don't reconstruct enum - member name, it is too confusing - - * decl.cs, class.cs: Don't report unused fields with attached attribute. - - * rootcontext.cs: Finally default to warning level 4. - -2008-08-28 Marek Safar - - * class.cs (CheckBase): Ignore overloaded operators. - -2008-08-28 Marek Safar - - A fix for bug #420830 - * expression.cs, cs-parser.jay: Put back InvocationOrCast expression. - -2008-08-28 Marek Safar - - A fix for bug #420832 - * anonymous.cs, iterators.cs: Also clone hoisted this iterator variable. - -2008-08-28 Marek Safar - - A fix for bug #420386 - * nullables.cs: Fixed logic of nullable user comparison operators involving - null values. - -2008-08-28 Marek Safar - - * attribute (IsClsCompliant): Use FALSE value for pointer types. - -2008-08-27 Miguel de Icaza - - * repl.cs: Add support for aborting the running code with C-c. - -2008-08-27 Raja R Harinath - - * cs-parser.jay (CS1002): Dump 'yyToken' with Report.ExtraInformation. - -2008-08-27 Miguel de Icaza - - * cs-parser.jay (interactive_statement_list): A new set of rules - for hosting statements that uses the "interactive_" prefix. - - * repl.cs: Add support for parsing `using' as a statement or as a - directive. Deambiguating before passing this to the parser. - - We need to distinguish statement_expressions that occur at the - toplevel vs those that occur embedded into expressions. - - * getline.cs: Applied patch from Stuart Carnie - that fixes the cursor key handling, and a history bug. - -2008-08-26 Miguel de Icaza - - * Makefile: Drop BOOTSTRAP_COMPILER as that was masking the - limitations in Console, instead the 2.0 bootstrap libraries now - include the Console bits. - - Also, remove the use of Nullables from getline.cs - - ------------ - - Interactive support for the C# compiler. Use gmcs --shell to - enter a read-eval-print loop shell. - - Docs: http://www.mono-project.com/CsharpRepl - - * sources: include repl.cs here and getline.cs for gmcs.exe, - everything else is getline.cs impaired. - - * Makefile: when bootstrapping pass a special flag - BOOTSTRAP_COMPILER which we use to prevent failures in compilation - as we use NET_2_0 define to pull 2.0 APIs from System.Console. - This distinguishes those two cases. - - * repl.cs: Support for a read-eval-print loop. Will be soon - refactored into eval support and then REPL on top of it. - - * ecore.cs: If a simplename lookup fails, before erroring out, - if we are in EvalMode to resolve the name to a declaration in the - Eval-land. - - This means that variable declarations that happened in previous - classes (as repl puts every statement in a separate class) are - made visible in this way. - - * cs-parser.jay: UnexpectedEOF, a new flag that is set if we - triggered an error due to the end of file being reached. This is - used to do multi-line input, and notify the caller that the user - needs to provide more text before a successful parse. - - Add new grammar rules after the INTERACTIVE_PARSER token is seen - to drive the evaluation with a custom wrapper. - - * driver.cs: Add support for --shell, and refactor some code to be - reused from repl.cs - - * namespace.cs: Add support for serializing the contents of the - namespaces and reloading them. - - * getline.cs: A managed implementation of ReadLine under - X11/Apache2 license terms. Easy to embed in other applications as - well. - - * namespace.cs: Add some functions to save and restore the - namespace state. - - * rootcontext.cs: New public field. - - * cs-tokenizer.cs: Add support for one of the possible characters - we introduce into the token stream. - - This patch does not affect the regular tokenization process, the - only performance hit would happen if there is an invalid character - on the input string. - - * support.cs: Move isatty helper routine here. - - * codegen.cs: Small cleanup, and add a mechanism to initialize the - code generator for in-memory assemblies. - -2008-08-26 Marek Safar - - * generic.cs, ecore.cs, delegate.cs, cs-parser.jay, expression.cs: A type - parameter cannot be always used as a type. - -2008-08-21 Marek Safar - - * convert.cs, expression.cs: Use single ExplicitReferenceConversion routine. - -2008-08-21 Marek Safar - - * convert.cs: Implement explicit array to IList conversion. - -2008-08-20 Marek Safar - - A fix for bug #362740 - * cs-tokenizer.cs: Handle UTF-16 surrogates. - -2008-08-20 Marek Safar - - * generic.cs, support.cs, typemanager.cs, lambda.cs, parameter.cs, - pending.cs, ecore.cs, linq.cs, class.cs, decl.cs, delegate.cs, - flowanalysis.cs, iterators.cs, cs-parser.jay, convert.cs, anonymous.cs, - expression.cs, attribute.cs, statement.cs, doc.cs: Refactored parameters - handling to use just one type of infrastructure and deal with generics - more effectivelly. - -2008-07-23 Martin Baulig - - *** Merged this from trunk revision 108527 *** - - * statement.cs - (ExplicitBlock.EmitSymbolInfo): Moved to `ToplevelBlock'. - (ToplevelBlock.EmitSymbolInfo): Tell the symbol writer about the - scope variable. - -2008-08-15 Marek Safar - - * ecore.cs, linq.cs, const.cs, expression.cs, statement.cs: More robust - error checks. - -2008-08-15 Marek Safar - - * delegate.cs: Fixed compiler crash when creating delegate using partial - method. - - * typemanager.cs: MulticastDelegate is not a delegate. - -2008-08-14 Marek Safar - - * expression.cs, ecore.cs, anonymous.cs, class.cs: Fixed missing error - checks. - -2008-08-14 Raja R Harinath - - * cs-parser.jay (type): Allow 'var' in mcs too. - (local_variable_type): Likewise. - -2008-08-14 Marek Safar - - * driver.cs: Removed broken -noconfig variants. - -2008-08-14 Marek Safar - - A fix for bug #417078 - * expression.cs: Emit correctly left side pointer operators. - -2008-08-13 Marek Safar - - * generic.cs, lambda.cs: Inflate method generic arguments only. - -2008-08-12 Marek Safar - - * class.cs: Fixed struct layout check regression. - -2008-08-12 Marek Safar - - * cs-parser.jay, enum.cs: Simplified enum parsing. - - * decl.cs: Check all type parameters conflicts. - - * expression.cs, statement.cs, attribute.cs: More expression checks. - -2008-08-11 Marek Safar - - * generic.cs: Add type inference types restriction. - - * parameter.cs, class.cs, delegate.cs, iterators.cs, cs-parser.jay, - anonymous.cs, expression.cs: Allocate less accessor parameters. - -2008-08-08 Marek Safar - - * typemanager.cs, ecore.cs: Ambiguous operators can come from different - classes. - -2008-08-08 Marek Safar - - * convert.cs, delegate.cs: Fixed delegate compatibility conversion. - -2008-08-07 Marek Safar - - * class.cs, decl.cs, iterator.cs, ecore.cs: Refactor base type resolving. - Also fixes #362146 and #381592. - -2008-08-07 Marek Safar - - * ecore.cs: Reduced constant cannot be used as an attribute value. - - * cs-parser.jay: Base expression has to be a type. - - * expression.cs (Conditional): Uses ReducedExpression. - -2008-08-06 Marek Safar - - A fix for bug #376826 - * parameter.cs, ecore.cs, anonymous.cs, expression.cs, statement.cs: An - address of hoisted local variable or parameter cannot be taken. - -2008-08-05 Marek Safar - - * ecore.cs, constant.cs, expression.cs, statement.cs: Resolve correctly - anonymous method inside checked/unchecked expression. - -2008-08-05 Marek Safar - - * typemanager.cs (IsEqual): Guard against null. - - * ecore.cs, class.cs, convert.cs, const.cs, constant.cs, expression.cs, - attribute.cs, enum.cs, statement.cs: Pass EmitContext to constant conversion - routine. Fixed few misleading conversion errors. - -2008-08-04 Marek Safar - - * class.cs: Consider generics when checking cycles in struct layout. - -2008-08-04 Raja R Harinath - - * cs-tokenizer.cs (get_cmd_arg): Simplify. Don't be too pedantic. - -2008-08-04 Marek Safar - - A fix for bug #414165 - * anonymous.cs: Use same anonymous implementation method for all anonymous - method emits. - -2008-08-04 Marek Safar - - * generic.cs, anonymous.cs, statement.cs: Emit inherited anonymous method - constraints. - -2008-08-04 Marek Safar - - * cs-parser.jay: Typeof argument has to be a type expression. - - * namespace.cs: Check alias and namespace definitions collisions. - - * class.cs, pending.cs: Moved explicit interface accessor implementation - check. - - * delegate.cs, expression.cs: Verify special name invocations. - -2008-08-01 Marek Safar - - * cs-parser.jay: Don't choke on empty generic type arguments. - - * cs-tokenizer.cs: Handle escaped preprocessor directives. - - * expression.cs, ecore.cs: Minor expressions bugs. - -2008-08-01 Marek Safar - - * cs-parser.jay: Removed duplicate interface declaration (fixes 2 conflicts) - and added more error handling. - - * class.cs, iterators.cs, anonymous.cs: Removed useless interface parameter. - - * modifiers.cs, enum.cs: Fixed. - -2008-07-31 Jb Evain - - * driver.cs: remove -pkg ability of smcs. - -2008-07-30 Marek Safar - - * statement.cs (Switch): Correctly set empty default target for single - blocks. - -2008-07-30 Marek Safar - - * typemanager.cs, assign.cs, driver.cs, expression.cs, statement.cs: Rewrote - string switch statement implementation to use string dictionary which - significantly (2-8x) improves performance of generated code. - -2008-07-29 Marek Safar - - A fix for bug #412880 by Atsushi Enomoto - * modifiers.cs (GetDescription): Fixed FamANDAssem case. - -2008-07-29 Marek Safar - - A fix for bug #412595 - * typemanager.cs, convert.cs, expression.cs: Some types are never - convertible to each other. - -2008-07-29 Marek Safar - - * nullable.cs (CreateNullConstant): An error messages update. - -2008-07-29 Marek Safar - - A fix for bug #412595 - * cfold.cs: Don't cast undefined bool constant. - -2008-07-29 Martin Baulig - - * symbolwriter.cs - (SymbolWriter.Reset): New public static method. - - * driver.cs - (CompilerCallableEntryPoint.Reset): Call SymbolWriter.Reset(). - -2008-07-28 Marek Safar - - * cs-tokenizer.cs (IsLambdaOpenParens): Optimized using more stop tokens. - - * expression.cs (ElementAccess): Exact size allocation. - -2008-07-26 Marek Safar - - * driver.cs: Replaced outdated UnixParseOption with CSCParseOption. - -2008-07-25 Marek Safar - - * flowanalysis.cs (StructInfo): Fixed detection of dynamic types. - - * class.cs: Removed $PRIVATE$ field hack which caused problems during - flow analysis. - -2008-07-25 Marek Safar - - A fix for bug #412217 - * assign.cs: Mutate also assignment type. - -2008-07-25 Marek Safar - - A fix for bug #323644 - * typemanager.cs (IsValidProperty): Verify DefaultMemberName when checking - indexers. - -2008-07-25 Marek Safar - - A fix for bug #412134 - * expression.cs (ResolveOperatorEnum): Do implicit conversion of - non-enumerable operands when overloading equality or bitwise operators. - -2008-07-25 Marek Safar - - * anonymous.cs: Cache closed generic anonymous method delegates. - -2008-07-24 Marek Safar - - * lambda.cs, linq.cs, class.cs, iterators.cs, cs-parser.jay, assign.cs, - anonymous.cs, statement.cs: Always emit anonymous method as static method - when is instance free. Use nesting for nested anynomous methods blocks. - -2008-07-23 Marek Safar - - * anonymous.cs (MutateGenericMethod): Added extra code path for imported - types. - -2008-07-23 Marek Safar - - * expression.cs: Removed MakeSimpleCall. - -2008-07-23 Marek Safar - - A fix for bug #323012 - * class.cs, pending.cs: Emit proxy for indexers when they differ in name. - Base method implementing interface has to be public. - -2008-07-23 Marek Safar - - * cs-parser.jay: Don't break on missing argument. - -2008-07-22 Marek Safar - - A fix for bug #320993 - * report.cs, parameter.cs, class.cs, decl.cs, delegate.cs, attribute.cs, - enum.cs, codegen.cs: Report CLS compliance errors as warnings. - -2008-07-22 Marek Safar - - A fix for bug #320748 - * convert.cs: Implicit user operators cannot convert to interfaces - -2008-07-22 Marek Safar - - A fix for bug #312686 - * driver.cs: Ignore empty assembly references. - -2008-07-22 Marek Safar - - A fix for bug #387040 - * ecore.cs: Skip constrains check for an explicit implementation. - -2008-07-21 Marek Safar - - A fix for bug #409045 - * cs-tokenizer.cs, rootcontext.cs, class.cs, location.cs, delegate.cs, - cs-parser.jay, driver.cs, expression.cs, attribute.cs: Conditional - identifiers are file specific unless passed as input arguments. - -2008-07-21 Marek Safar - - * typemanager.cs, parameter.cs, class.cs, attribute.cs: Use an attribute - to emit UnmanagedMarshal data under 2.0 profile. - -2008-07-21 Marek Safar - - A fix for bug #410369 - * parameter.cs: Clone correctly ParamsParameter. - -2008-07-21 Marek Safar - - * expression.cs (Argument): Always report type for type based expressions - errors. - -2008-07-18 Marek Safar - - A fix for bug #410666 - * anonymous.cs: Correctly initialize generic storey reference. - -2008-07-18 Marek Safar - - * convert.cs: Don't box same type arguments. - -2008-07-18 Marek Safar - - * ecore.cs, linq.cs, delegate.cs, constant.cs, nullable.cs, expression.cs: - Finished missing generic type mutators. - -2008-07-18 Marek Safar - - * iterators.cs, statement.cs: Finished statements CloneTo. - -2008-07-18 Marek Safar - - * anonymous.cs: ExpressionTreeProxy is of Value type expression. - - * expression.cs: Emit optimized default value expressions in expression tree - array initializer. - -2008-07-18 Marek Safar - - * ecore.cs, cs-parser.jay, statement.cs: Error reporting fixes. - -2008-07-17 Marek Safar - - A fix for bug #367536 - * cs-parser.jay: Check static constructor of generic types for an access - modifier. - -2008-07-17 Marek Safar - - A fix for bug #353800 - * lambda.cs: Emit ret for contextual statements. - - * codegen.cs: Keep both resolved and unreachable flags, otherwise we end - up emitting redundant ret for all anonymous methods with return. - -2008-07-17 Marek Safar - - A fix for bug #365188 - * ecore.cs, anonymous.cs, expression.cs, codegen.cs, statement.cs: Don't - create anonymous method storey in unreachable block. - -2008-07-17 Marek Safar - - * generic.cs, typemanager.cs, cs-tokenizer.cs, parameter.cs, namespace.cs, - class.cs, delegate.cs, flowanalysis.cs, iterators.cs, anonymous.cs, - driver.cs, nullable.cs, expression.cs, attribute.cs, codegen.cs, - statement.cs: Fixed relevant defects found by Gendarme. - -2008-07-17 Marek Safar - - A fix for bug #325291 - * modifiers.cs, class.cs, cs-parser.jay, anonymous.cs, codegen.cs, - statement.cs: Replaced IAnonymousHost with top level block flag. - -2008-07-17 Marek Safar - - * cs-parser.jay: Clean up unused open_parens. - -2008-07-17 Marek Safar - - * ecore.cs: Custom error message for a range variable assignment. - -2008-07-16 Marek Safar - - * constant.cs, typemanager.cs: Emit empty string ("") as string.Empty field - load. - -2008-07-16 Marek Safar - - * literal.cs: Null literal is of object type. - -2008-07-16 Marek Safar - - * nullable.cs (LiftedBinaryOperator): Always lift unwrapped nullable - expression of nullable equality comparison. - -2008-07-15 Marek Safar - - * expression.cs(PointerArithmetic): Removed redundant assignment. - -2008-07-15 Marek Safar - - * decl.cs (GetSignatureForError): Report full namespace name for containers. - -2008-07-14 Marek Safar - - A fix for bug #408361 - * anonymous.cs (MutateGenericMethod): Store generic type arguments before - they are replaced by GetMethod. - -2008-07-14 Marek Safar - - A fix for bug #408721 by jeremie.laval@gmail.com - * expression.cs (Indirection): Implemented CloneTo. - -2008-07-14 Marek Safar - - * statement.cs (AssignableSlots): Temporary disabled variable initialization - assert check. - -2008-07-14 Marek Safar - - * report.cs (EnableReporting): Don't reinitialize 0-based values. - -2008-07-11 Marek Safar - - * linq.cs: Reset tranparent parameter counter in probing mode. - -2008-07-11 Marek Safar - - * anonymous.cs: Mutate anonymous method type. - -2008-07-11 Marek Safar - - * ecore.cs, anonymous.cs: Mutate field expressions. - -2008-07-10 Marek Safar - - A fix for bug #369670 - * linq.cs, statement.cs: Use explicit block for query expressions variables. - -2008-07-10 Marek Safar - - * report.cs, ecore.cs: Flush recorder only when silent mode is off. - -2008-07-10 Raja R Harinath - - Fix bug #314902 - * cs-tokenizer.cs (is_punct): If a generic lookahead is looking - only one '>', and finds a '>>', abort the generic lookahead. - -2008-07-10 Marek Safar - - A fix for bug #319902 - * cs-tokenizer.cs: Always look-ahed for `>=' when tokenizing `>'. - -2008-07-10 Marek Safar - - A fix for bug #406371 - * statement.cs: Moved EmitSymbolInfo to Block. - -2008-07-09 Marek Safar - - * ecore.cs: Report better error for extension method overload failures. - -2008-07-09 Marek Safar - - * expression.cs (Is): No need to box reference values. - -2008-07-09 Marek Safar - - * class.cs: Use event resolve context when initializing CreateEmitContext. - -2008-07-09 Marek Safar - - A fix for bug #394436 - * anonymous.cs, class.cs, expression.cs, lambda.cs: Emit correctly extension - method used inside expression trees. Added more LINQ to expression tree - conversions. - -2008-07-08 Marek Safar - - A fix for bug #378189, #370577 - * lambda.cs, ecore.cs: Implemented 3.0 enhancement to better conversion - from expression. - -2008-07-08 Marek Safar - - * anonymous.cs, class.cs, decl.cs: Emit CompilerGenerated attribute - hierarchically. - -2008-07-08 Marek Safar - - A fix for bug #406702 - * anonymous.cs: Always park anonymous method in the nearest parent storey. - -2008-07-07 Marek Safar - - A fix for bug #406648 - * cs-parser.jay: Report nullable use in mcs for some cases. - -2008-07-07 Marek Safar - - * ecore.cs: Improved argument mismatch error messages. - -2008-07-07 Marek Safar - - * anonymous.cs: Don't cache generic delegates when reference MVAR argument. - -2008-07-07 Marek Safar - - * expression.cs (TypeOf): Mutate type argument. - -2008-07-04 Marek Safar - - * class.cs: Report missing partial modifier for correct type. - -2008-07-04 Marek Safar - - * ecore.cs, expression.cs (VariableReference): Variable property is - protected. - -2008-07-04 Marek Safar - - * ecore.cs, convert.cs: Made OpcodeCast more memory efficient. - -2008-07-04 Marek Safar - - * anonymous.cs, class.cs, lambda.cs, iterator.cs: Cache static anonymous - method delegates. - -2008-07-04 Marek Safar - - * anonymous.cs, class.cs, expression.cs, iterator.cs, statement.cs: Reduce - anonymous method storey to an instance method when only "this" is hoisted. - -2008-07-03 Marek Safar - - A fix for bug #321615 - * expression.cs: Pointer comparisons use unsigned operator. - -2008-07-03 Marek Safar - - * expression.cs: Fixed native pointer conversions. Also fixes #321615. - -2008-07-02 Marek Safar - - A fix for bug #404905 - * class.cs: Always initialize local unsafe variables. - -2008-06-30 Marek Safar - - A fix for bug #396987 - * expression.cs (NewInitialize): Clear local temporary variable for next run - -2008-06-27 Marek Safar - - A fix for bug #401020 - * ecore.cs: Both types and modifiers have to match for ref and out arguments - -2008-06-27 Marek Safar - - A fix for bug #398319 - * cs-parser.jay: Implemented undocumented base access expression inside - anonymous types. - -2008-06-26 Marek Safar - - A fix for bug #404227 - * cs-parser.jay: Parse namespace declaration using qualified identifier. - -2008-06-26 Marek Safar - - A fix for bug #404227 - * convert.cs: Fixed explicit array to interface cast. - -2008-06-26 Marek Safar - - A fix for bug #403894 - * delegate.cs: Mutate DelegateInvocation type. - -2008-06-26 Marek Safar - - A fix for bug #379348 - * delegate.cs: Box a load of generic parameters. - -2008-06-26 Marek Safar - - * expression.cs: Add an array creation arguments mutate. - -2008-06-26 Marek Safar - - A fix for bug #386068 - * anonymous.cs, expression.cs: Emit correctly hoisted expression tree - parameter. - -2008-06-25 Marek Safar - - * ecore.cs, expression.cs: Fixed broken TypeCast clone, implemented few more - CloneTo. - -2008-06-25 Marek Safar - - A fix for bug #403518 - * delegate.cs: Type correctly anonymous method new invocation. - -2008-06-24 Marek Safar - - A fix for bug #394826 - * anonymous.cs: Fully qualify members when resolving anonymous type internal - calls. - -2008-06-24 Marek Safar - - A fix for bug #394826 - * anonymous.cs, iterators.cs: Construct generic storey only when is really - needed. - -2008-06-24 Marek Safar - - * class.cs: Clone indexer parameters for localized capturing. - -2008-06-24 Marek Safar - - A fix for bug #402379 - * expression.cs: Don't crash when an object initializer resolve fails. - -2008-06-24 Marek Safar - - A fix for bug #402888 - * expression.cs: Mutate conditional expression. - -2008-06-24 Marek Safar - - A fix for bug #401012 - * class.cs: Keep StructLayout in shared container. - -2008-06-24 Marek Safar - - A fix for bug #400438 - * decl.cs, class.cs: Only properties can be automatically implemented. - -2008-06-24 Marek Safar - - * statement.cs (ChangeToIterator): Copy also labels. - -2008-06-23 Marek Safar - - * ecore.cs: Pass type argument details to parent extension method. - -2008-06-23 Marek Safar - - A fix for bug #375966 - * delegate.cs: Fixed IsTypeCovariant generic type conversions. - -2008-06-23 Raja R Harinath - - * Makefile (bootstrap-libs): Pass NO_DIR_CHECK to sub-make. - -2008-06-22 Marek Safar - - A fix for bug #394347 - * anonymous.cs: Cache compatible delegates as compatibility check produces - a new method every time. - -2008-06-20 Marek Safar - - * anonymous.cs: Propagate storey reference for single references. - -2008-06-20 Marek Safar - - A fix for bug #387615 - * assign.cs, expression.cs: Correctly clone compound assignment. - -2008-06-19 Marek Safar - - A fix for bug #359611, #359604 - * anonymous.cs: Mutate all types of hoisted parameters. - -2008-06-19 Marek Safar - - * typemanager.cs, lambda.cs, parameter.cs, ecore.cs, linq.cs, class.cs - delegate.cs, iterators.cs, cs-parser.jay, assign.cs, anonymous.cs, driver.cs - expression.cs, codegen.cs, statement.cs - - Fixes bugs: #318652, #323223, #234779, #325069, #325476, #332532, #334465, - #345907, #349190, #353276, #355256, #359617, #378542, #384584, #396530 - - ** Anonymous methods, lambda expressions rewrite ** - - Anonymous expressions are now resolved when an explicit block is resolved - and they don't require any registration procedure anymore. Further, - anonymous methods are defined when explicit block is emitted which allows - better control of whole process and opens possibilities for more - optimizations as well as alternative to reverse whole process. - - A concept of `MutateHoistedGenericType' was introduced to keep the resolve - process consistent and to correctly emit hoisted generic methods when they - have at least 1 hoisted variable. - -2008-06-17 Martin Baulig - - * class.cs: Also emit the `[DebuggerHidden]' attribute on the main - iterator method. - (AbstractPropertyEventMethod.IsDebuggerHidden): New protected - virtual property; check it in Emit(). - (PropertyMethod.IsDebuggerHidden): Override, check whether we're - an iterator. - (MethodOrOperator.ResolveMethods): Set `DEBUGGER_HIDDEN' if we're - an iterator. - (Indexer.Define): Likewise. - -2008-06-17 Marek Safar - - * convert.cs: Don't use IsInterface on type arguments. - - * delegate.cs: DelegateInvocation uses MethodInfo. - - * parameter.cs: Removed IsTypeParameter. - - * generic-mcs.cs: More missing stuff. - -2008-06-16 Martin Baulig - - * modifiers.cs - (Modifiers.DEBUGGER_HIDDEN): New public const. - - * typemanager.cs - (TypeManager.GetDebuggerHiddenAttribute): New public static method. - - * class.cs - (MethodOrOperator.Emit): Check `Modifiers.DEBUGGER_HIDDEN'. - (AbstractPropertyEventMethod): Likewise. - (Constructor.Emit): Likewise. - (SourceMethod.SetCompilerGenerated): Removed. - - * iterator.cs: Set `Modifiers.DEBUGGER_HIDDEN' everywhere except - on MoveNext(). - - * anonymous.cs - (RootScopeInfo.DoDefineMembers): Set `Modifiers.DEBUGGER_HIDDEN' - if we're an `IteratorHost'. - (AnonymousMethodMethod..ctor): Don't set - `Modifiers.COMPILER_GENERATED'; csc only sets this on the class, - not on the method. - -2008-06-16 Marek Safar - - * statement.cs: Clean-up foreach statements. - -2008-06-12 Marek Safar - - * class.cs: Stop using public method which should not exist - (MethodBuilder.SetGenericMethodSignature). - -2008-06-11 Martin Baulig - - * location.cs - (Location.LookupFile): Add `CompilationUnit' argument; when given - a relative file name, make it relative to the directory the .cs - file is located in instead of using the current directory. - -2008-06-11 Martin Baulig - - * class.cs - (IMethodData.EmitExtraSymbolInfo): Added `SourceMethod' argument. - (MethodOrOperator.EmitExtraSymbolInfo): Likewise. - (SourceMethod.SetRealMethodName): Moved here from the symbol writer. - (SourceMethod.SetCompilerGenerated): Likewise. - -2008-06-11 Marek Safar - - * codegen.cs, driver: Only write symbol file when it's asked for. - -2008-06-11 Marek Safar - - * codegen.cs: Don't use assembly writer error handling for symbol writer. - -2008-06-10 Martin Baulig - - * symbolwriter.cs: Reflect latest MarkSequencePoint() API changes. - -2008-06-09 Marek Safar - - A fix for bug #316290 - * expression.cs: Include decimal operators in predefined table. - - * parameters.cs: More readonlyness. - -2008-06-09 Marek Safar - - A fix for bug #397213 - * cs-parser.jay: One more missing current_local_parameters reset. - -2008-06-09 Marek Safar - - A fix for bug #396633 - * class.cs: Host backing field in partial container. - -2008-06-09 Marek Safar - - A fix for bug #397068 - * expression.cs: Check both operand types when predefined operator is used. - -2008-06-05 Martin Baulig - - Merged the `debugger-kahalo' branch. - - * class.cs - (MethodData.Emit): Call SymbolWriter.SetCompilerGenerated() if - we're an iterator method. - (SourceMethod): Reflect latest symbol writer changes; - SymbolWriter.OpenMethod() now takes a `ICompileUnit' argument and - now `start_row' and `end_row'. - (Constructor.Emit): Fix the logic whether to emit symbol information. - - * iterator.cs: Call SymbolWriter.SetCompilerGenerated() on all the - generated methods. - - * location.cs - (CompilationUnit): New public class; derives from `SourceFile'. - (SourceFileEntry.DefineSymbolInfo): New public method. - (SourceFileEntry.SetChecksum): New public method. - (Location): Encode hidden line numbers by using `column == 255'; - the .ctor now accepts `column == -1' to mark a hidden line number. - (Location.Hidden): New public property. - (Location.CheckPoint): Add `CompilationUnit'. - (Location.SourceFiles): Change return type to `CompilationUnit[]'. - (Location.Push): Add `CompilationUnit compile_unit' argument. - (Location.CompilationUnit): New public property. - - * statement.cs - (ToplevelBlock.Emit): Add `ec.Mark (EndLocation)'. - - * cs-parser.jay: `SourceFile' -> `CompilationUnit'. - - * driver.cs: `SourceFile' -> `CompilationUnit'. - - * cs-tokenizer.cs: `SourceFile' -> `CompilationUnit'. - - * namespace.cs: `SourceFile' -> `CompilationUnit'. - - * cs-tokenizer.cs: Add support for `#pragma checksum' and - `#line hidden'. - - * symbolwriter.cs - (SymbolWriter.MarkSequencePoint): Take a `Location' and use the - new symbol writer API to also pass the file. - -2008-06-05 Marek Safar - - * statement.cs: Emit catch variable assignment using variable expression. - -2008-06-05 Marek Safar - - * ecore.cs, expression.cs, statement.cs: Make TemporaryVariable compatible - with other variable types. - -2008-06-04 Marek Safar - - * ecore.cs, expression.cs, statement.cs, typemanager.cs: Removed custom - GetLength method emit, it breaks resolve rules. - -2008-06-02 Atsushi Enomoto - Marek Safar - - A fix for bug #395542 - * cs-parser.jay: The trailing comma is allowed in anonymous type member - declaration. - -2008-06-02 Marek Safar - - A fix for bug #395287 - * class.cs, modifiers.cs: Automatic properties method base modifiers checks. - -2008-05-31 Marek Safar - - A fix for bug #395845 - * class.cs, nullable.cs: User unary operator is allowed to have nullable and - non-nullable parameter type. - -2008-05-31 Marek Safar - - * class.cs: Handle contructor initializer as a statement in top-level block. - -2008-05-30 Marek Safar - - * attribute.cs: Don't mix old and new corlib types when emitting corlib - security attributes. - -2008-05-24 Marek Safar - - * ecore.cs, expression.cs: Small IVariable refactoring. - -2008-05-22 Marek Safar - - * assign.cs (LocalTemporary): Implemented CreateExpressionTree. - -2008-05-21 Marek Safar - - * cs-parser.jay: Removed redundant catch type check. - -2008-05-21 Marek Safar - - A fix for bug #390372 - * nullable.cs: Set correct return type. - -2008-05-21 Marek Safar - - A fix for bug #391062 - * typemanager.cs: Fixed crash when comparing null types. - -2008-05-21 Marek Safar - - A fix for bug #391871 - * cs-parser.jay: Better error handling for invalid catch type. - -2008-05-20 Marek Safar - - A fix for bug #392155 - * cs-tokenizer.cs: Fixed casting of byte and decimal expression. - -2008-05-15 Marek Safar - - A fix for bug #390666 - * ecore.cs (BetterExpressionConversion): Unwrap each Expression - expressions. - -2008-05-15 Marek Safar - - * class.cs, expression.cs, statement.cs: Removed a hack, setting block flag - in getter. - -2008-05-13 Marek Safar - - A fix for bug #389625 - * delegate.cs, generic.cs: Some progress on method group return type - inference. - -2008-05-13 Marek Safar - - A fix for bug #378419 - * namespace.cs: Inspect also parent namespaces not only namespace entries. - -2008-05-12 Marek Safar - - * class.cs (Constructor): Added IsCompilerGenerated. - -2008-05-12 Marek Safar - - * expression.cs: Enum binary operators can accept non-enum operand only when - is implicitly convertible to underlying type. - -2008-05-12 Marek Safar - - A fix for bug #389272 - * support.cs: Workaround System.InvalidOperationException for enums. - -2008-05-12 Marek Safar - - A fix for bug #389073 - * convert.cs: More undocumented explicit IntPtr/UIntPtr conversions. - -2008-05-10 Marek Safar - - * driver.cs: Split Parse. - - * location.cs (LookupFile): Uses string.Empty. - -2008-05-07 Marek Safar - - * expression.cs, parameter.cs: Small ParameterReference clean up. - -2008-05-07 Marek Safar - - * anonymous.cs, codegen.cs, convert.cs, ecore.cs: Removed uber ugly TempEc - hack. Fixes #387502. - -2008-05-06 Martin Baulig - - * class.cs (Constructor.Emit): Fix the logic whether to emit - symbol information. - -2008-05-06 Raja R Harinath - - Fix #385503 - * iterators.cs (Iterator.CurrentBlock.DoEmit): Don't emit - InvalidOperationException when the iterator is before the start or - after the end. - -2008-05-06 Marek Safar - - * nullable.cs (NullCoalescingOperator): Result is underlying type of left, - when left is nullable type. - -2008-05-06 Marek Safar - - A fix for bug #386628 - * expression.cs (LocalVariableReference): Continue in resolving when - variable is not assigned. - -2008-05-05 Marek Safar - - * nullable.cs, statement.cs (Unwrap): Store non-variable expression in all - nullable operations. - -2008-05-04 Marek Safar - - * nullable.cs, statement.cs (Unwrap): Don't duplicate variable expressions, - it saves many redundant temporary variables for nullable operations. - -2008-05-03 Marek Safar - - * assign.cs: EventAddOrRemove is a statement and cannot have a type. - - * cfold.cs, constant.cs, expression.cs: Share Error_OperatorCannotBeApplied - method. - - * nullable.cs: Constant coalescing operator optimizations. - -2008-05-03 Marek Safar - - * constant.cs: Use unsigned conversion for values which are unsigned only. - -2008-05-03 Marek Safar - - * convert.cs, literal.cs, nullabel.cs, typemanager.cs: Implemeted null - coalescing operator as it should be. - -2008-05-02 Marek Safar - - A fix for bug #371016 - * expression.cs: All predefined delegate operators require implicit method - group conversion. - -2008-05-02 Marek Safar - - * constant.cs: Emit long constant as uint when fits the range. - - * convert.cs, expression.cs: Fixed few unsafe conversions. - -2008-05-02 Marek Safar - - * convert.cs, literal.cs: Don't wrap implicit reference conversion to object - -2008-05-02 Raja R Harinath - - Fix #385758 - * convert.cs (ImplicitNumericConversion): Don't modify the type of - 'expr'. - * ecore.cs (EmptyCast.Create): Flatten nested EmptyCasts. - -2008-05-01 Marek Safar - - * constant.cs, literal.cs: IsLiteral property for error reporting. - - * ecore.cs, expression.cs: Implemented Property expression. - -2008-05-01 Marek Safar - - * class.cs, modifiers.cs, flowanalysis.cs: New BACKING_FIELD flag. - - * nullable.cs: Implemented nullable coalescing null operator. - - * ecore.cs, expression.cs: Expression trees work. - -2008-05-01 Marek Safar - - * ecore.cs: CreateExpressionTree is finally abstract. - - * expression.cs, linq.cs: Updated. - -2008-05-01 Marek Safar - - * expression.cs, ecore.cs: Block base access expression inside expression - tree. - -2008-05-01 Marek Safar - - A fix for bug #385058 - * expression.cs: User-defined operator implementations always take - precedence over predefined operator implementations. - -2008-04-30 Marek Safar - - * assign.cs, anonymous.cs, lambda.cs, nullable.cs, ecore.cs, linq.cs, - class.cs, iterators.cs, expression.cs, attribute.cs: Filled a few more - expression tree conversions. - -2008-04-30 Marek Safar - - * typemanager.cs, ecore.cs, class.cs, expression.cs, doc.cs: Merged all - operators method details to Operator class. - -2008-04-30 Marek Safar - - * anonymous.cs: Pass unsafe flags to anonymous container. - - * ecore.cs, expression.cs, statement.cs: Block unsafe pointer operations - inside expression tree. - -2008-04-29 Martin Baulig - - * cs-tokenizer.cs (Tokenizer.Position): Added `line'. - (Tokenizer.PopPosition): Also restore the `line'. - -2008-04-29 Marek Safar - - * delegate.cs: Implemented Invoke expression. - -2008-04-29 Marek Safar - - * expression.cs: Fixed equality reference comparison regression. - -2008-04-29 Marek Safar - - * ecore.cs: Clean up EmptyCast hack. - - * expression.cs, nullable.cs: Implemented enum binary and unary operations - using correct conversion rules. Also fixes #383993. - -2008-04-28 Martin Baulig - - * class.cs (Constructor.Emit): Don't emit debugging information - for generated default .ctor's. - -2008-04-28 Marek Safar - - * convert.cs: Empty-cast ushort to int conversion. - -2008-04-28 Marek Safar - - A fix for bug #384191 - * ecore.cs, expression.cs: Fixed expression cloning. - -2008-04-28 Marek Safar - - * ecore.cs, delegate.cs, assign.cs: Few tweaks for recent changes. - -2008-04-28 Raja R Harinath - - Fix #381559, test-638.cs, test-639.cs - * assign.cs (CompoundAssign.Helper): New wrapper. - (CompoundAssign.DoResolve): Use it to wrap the nested 'target' - access. - * ecore.cs (MethodGroupExpr.VerifyArgumentsCompat) : - Pass unconverted expressions to the params array creation expression. - (FieldExpr.EmitAssign): Don't special-case StringConcat. - (PropertyExpr.EmitAssign): Likewise. - * expression.cs (ArrayCreation.ResolveArrayElement): Keep track of the - element if it is of kind CompoundAssign.Helper. - (ArrayCreation.Emit): If we saw a CompoundAssign.Helper, emit it - first before anything else. - (ArrayAccess.EmitAssign): Don't special-case StringConcat. - (ArrayAccess.LoadArrayAndArguments): Simplify. - -2008-04-27 Marek Safar - - * expression.cs: Fixed cloning of typeof(void). - -2008-04-27 Raja R Harinath - - * assign.cs (Assign.DoResolve): Remove support for EventExprs. - (Assign.Emit): Likewise. Move it to ... - (CompoundAssign.DoResolve): ... here and ... - (CompoundAssign.Emit): ... here. - (EventAddOrRemove): New helper to handle += and -= on events, and - avoid the use of BinaryDelegates. - * ecore.cs (EventExpr.DoResolveLValue): Emit CS0070 unconditionally. - (EventExpr.EmitAddOrRemove): Improve. - * delegate.cs (DelegateInvocation.DoResolve): Simplify slightly. - - * cs-parser.jay (type) : Don't - create VarExprs for 'foo.bar.var'. - * ecore.cs (VarExpr.InferType): Rename from DoResolveLValue, which - is a highly inappropriate name for its functionality. - -2008-04-26 Raja R Harinath - - Simplify handling of multiple assignments - * assign.cs (Assign): Clear out all 'embedded assign' gunk. Make - inheritable-only. - (SimpleAssign): New. Class to be used for normal assignments. - * anonymous.cs, class.cs, cs-parser.jay: Update to changes. - * expression.cs, parameter.cs, statement.cs: Likewise. - -2008-04-25 Marek Safar - - * ecore.cs, expression.cs, nullable.cs: Implemeted enum binary add operation - for incompatible underlying types, more to come, uff. - -2008-04-26 Raja R Harinath - - Fix gtest-388.cs - * expression.cs (VariableReference.EmitAssign) : - Handle 'leave_copy'. - -2008-04-25 Marek Safar - - * expression.cs, nullable.cs: Implemented UnaryPlus expression. - -2008-04-24 Raja R Harinath - - Fix test-636.cs. Sprinkle a few more 'EmitSideEffect's around - * expression.cs (Unary.TryReduceConstant): Unwrap SideEffectConstant. - * statement.cs (While, Do, For): Allow test to have side effects. - (For.DoEmit): Always emit InitStatement. - - Fix test-635.cs - * expression.cs (Binary.DoResolve) : - Always create SideEffectConstant. - (Binary.EnumLiftUp): Don't assume that the enumeration constant is - of type EnumConstant. - - * expression.cs (Binary.EmitBranchable) : - Handle 'right' being SideEffectConstant of type 'bool'. - - * expression.cs (Binary.EmitBranchable) : - Use left.EmitBranchable instead of open coding it, so as to - improve optimization opportunities. - - * constant.cs (SideEffectConstant.EmitSideEffect): Simplify slightly. - - * ecore.cs (Expression.EmitBranchable): Document some non-obvious - assumptions. - (Expression.EmitSideEffect): Document. - -2008-04-23 Marek Safar - - * expression.cs: Implemented NewArrayBounds, TypeIs, and TypeAs expressions. - -2008-04-23 Marek Safar - - * constant.cs, statement.cs: Use EmitSideEffect for constant if statement. - -2008-04-23 Marek Safar - - * ecore.cs, expression.cs, delegate.cs: Implemeted delegate instantiation - conversion to expression tree. - -2008-04-23 Marek Safar - - * ecore.cs: Removed unused expression. - -2008-04-22 Marek Safar - - * expression.cs: Implemented NegateChecked and New expressions. - -2008-04-22 Marek Safar - - * convert.cs, nullable.cs, expression.cs: Implemented Negate expression. - -2008-04-22 Raja R Harinath - - Fix #351102 - * anonymous.cs (AnonymousMethodExpression.DoResolve): Mark as - needing final 'ret' instruction. - -2008-04-22 Marek Safar - - * expression.cs: Disabled lifted binary conversion on ISO-1 profiles. - -2008-04-21 Marek Safar - - * expression.cs: Emit ldnull and not null expression as an instance argument - of static method expression calls. - -2008-04-21 Marek Safar - - A fix for bug #378200 - * expression.cs: Fixed crash when creating parameterless expression tree - method call. - -2008-04-21 Marek Safar - - A fix for bug #375297 - * anonymous.cs: Fixed crash when inferring from null argument anonymous - method. - -2008-04-21 Marek Safar - - A fix for bug #377596 - * decl.cs, class.cs: Emit delegate type argument attributes. - -2008-04-21 Marek Safar - - A fix for bug #365314 - * generic.cs, ecore.cs: Type parameter declaration cannot be of generic type - -2008-04-21 Marek Safar - - * cs-parser.jay, expression.cs: ComposedCast can work with type expressions - only. - -2008-04-21 Marek Safar - - * generic.cs (TypeParameter): Removed redundant location. - -2008-04-19 Marek Safar - - * generic.cs, parameter.cs, namespace.cs, ecore.cs, class.cs, decl.cs, - delegate.cs, iterators.cs, cs-parser.jay, const.cs, enum.cs: Use - FullNamedExpression in all declaration type expression, statements will come - later. - -2008-04-18 Marek Safar - - * generic.cs, namespace.cs, ecore.cs, class.cs, decl.cs, generic-mcs.cs, - nullable.cs, expression.cs, enum.cs, doc.cs: Cleaning up type expressions. - -2008-04-18 Marek Safar - - * parameter.cs, delegate.cs, cs-parser.jay, expression.cs: Removed unused - code. - -2008-04-17 Marek Safar - - * decl.cs, class.cs, generic.cs: Verify partial parts type parameters and - constraints. - -2008-04-17 Marek Safar - - * decl.cs, class.cs, cs-parser.jay, ecore.cs, expression.cs: Unify all type - name expressions. - Also fixes #340463. - -2008-04-17 Raja R Harinath - - Hook up 'EmitSideEffect' - * constant.cs (Constant.EmitSideEffect): New. - (SideEffectConstant.Emit): Simplify. Use EmitSideEffect. - (SideEffectConstant.EmitSideEffect): New. - * ecore.cs (BoxedCast.EmitBranchable): Remove. We can't use an - unconditional branch in EmitBranchable. - (FieldExpr.EmitBranchable): New. - * expression.cs (Unary.EmitSideEffect): New. - (Binary.EmitSideEffect): New. - (VariableReference.EmitSideEffect): New. Do nothing. - -2008-04-16 Raja R Harinath - - Introduce 'EmitSideEffect' - * ecore.cs (Expression.EmitSideEffect): New. - (TypeCast): Rename from EmptyCast. - (EmptyCast): New. - (EmptyCast.EmitBranchable, EmptyCast.EmitSideEffect): Implement. - (BoxedCast.EmitBranchable, BoxedCast.EmitSideEffect): Implement. - * convert.cs, nullable.cs: Update to changes. - -2008-04-16 Marek Safar - - * class.cs, cs-parser.jay: Early check for base types expression. - -2008-04-16 Marek Safar - - * decl.cs (MemberName): Declare PrettyName as obsolete. - -2008-04-16 Marek Safar - - * namespace.cs: Use MemberName comparison. - -2008-04-16 Raja R Harinath - - Fix build break - * decl.cs (MemberName.PrettyName): New. Replaces the misnamed - FullName. - (MemberName.MethodName, MemberName.GetSignatureForError): Improve. - (MemberName.FullyQualifiedName): New. Provides the functionality - that users assume FullName would have. - * ecore.cs, namespace.cs: Update to changes. - - * statement.cs (Using.assign): Make into ExpressionStatement. - (Using.EmitPreTryBody): Simplify. - -2008-04-16 Marek Safar - - * report.cs: ColorFormat is protected. - - * rootcontext.cs: Unused fields clean-up. - - * namespace.cs: Made UsingEntry name private. - -2008-04-16 Marek Safar - - * cs-tokenizer.cs, location.cs: Removed unused field. - -2008-04-16 Jan Oravec - Raja R Harinath - - Fix #379822 - * constant.cs (SideEffectConstant.value): Rename from 'left'. - (SideEffectConstant.side_effect): Rename from 'right'. - (SideEffectConstant..ctor): Normalize 'side_effect'. - (SideEffectConstant.Emit): Emit 'value', not 'side_effect' as the - value of this constant. - * cfold.cs: Update to changes. - -2008-04-15 Marek Safar - - * cs-paser.jay: Removed unused variable. - - * driver.cs: Made Compile instance method. - -2008-04-15 Raja R Harinath - - * flowanalysis.cs (FlowBranching.MergeChild): Simplify. - -2008-04-15 Marek Safar - - * cs-paser.jay, namespace.cs: Simplified handling of namespace imports. - -2008-04-13 Jb Evain - - * namespace.cs: update the System.Core fullname for 2.1 - * driver.cs: update the list of required assemblies for 2.1. - Merged from the Moonlight 2 branch. - -2008-04-11 Marek Safar - - * assign.cs, ecore.cs, expression.cs, nullable.cs: More work on nullable - types and user defined operators. User operators arguments has to be checked - for null value before invocation, which also means no operator is called - when any argument is not convertible to unwrapped nullable type. - -2008-04-09 Marek Safar - - * convert.cs, ecore.cs, expression.cs, nullable.cs: Initial refactoring - of Unary expressions to follow operator overloading rules precisely. - Also fixes #321794, #323794 - -2008-04-08 Marek Safar - - * cs-parser.jay, expression.cs: Don't wrap Indirection expression in Unary - expression. - -2008-04-08 Marek Safar - - * expression.cs, ecore.cs: Implemented MemberInit expression. - -2008-04-08 Raja R Harinath - - Fix mono/tests/exception4.cs - * statement.cs (ExceptionStatement, TryCatch): Revert to using - ec.NeedReturnLabel () rather emitting a 'nop'. - - * statement.cs (ExceptionStatement.SomeCodeFollows): A hook for a - simple heuristic. - (TryCatch.SomeCodeFollows): Likewise. - * flowanalysis.cs (FlowBranchingException): Call 'SomeCodeFollows' - for 'break', 'continue' and 'return' statements inside a try. - We're fairly sure that the generated IL stream will have more - instructions textually following the try. - (FlowBranchingTryCatch): Likewise. - - * statement.cs (Throw.Resolve): Move CS0156 and CS0724 testing ... - * flowanalysis.cs (FlowBranching.CheckRethrow): ... here and to its - overrides. - - * statement.cs (CollectionForeach.DisposableWrapper): Make a true - wrapper -- forward everything to CollectionForeach. - (CollectionForeach.NonDisposableWrapper): New. - (CollectionForeach.EmitFinallyBody): Use 'endfinally' instruction - instead of a pop + branch to end. - -2008-04-07 Marek Safar - - A fix for bug #377485 - * assign.cs, expression.cs, decl.cs, class.cs, ecore.cs, namespace.cs: - Propagate location for extension method groups. Report conversion failure at - right place. - -2008-04-07 Marek Safar - - * anonymous.cs, expression.cs, ecore.cs, typemanager.cs: Implemented - ListInit and Field expressions. - -2008-04-06 Raja R Harinath - - * iterators.cs (Iterator.EmitMoveNext): Remove try/fault wrapper. - Since $PC is always -1 inside the body of MoveNext, the fault - handler is a no-op. - * flowanalysis.cs (FlowBranchingException.EmitFinally): Kill. - * statement.cs (ExceptionStatement.emit_finally): Likewise. - (ExceptionStatement.ResolveFinally): Drop 'branching' argument. - - The denouement! Fix #324708 - * iterators.cs (Iterator.EmitMoveNext): Reset $PC to -1 on entry. - (Iterator.EmitYieldBreak): We no longer need to reset $PC. - * statement.cs (ExceptionStatement.DoEmit): Actually emit the - 'finally' inside the finally clause. - - * statement.cs (ExceptionStatement.DoEmit): Emit try/finally block - inside an iterator. Don't emit the body of the 'finally' inside - the finally clause yet. - - Use the ResumableStatement infrastructure for MoveNext () - * iterators.cs (Iterator.EmitMoveNext_NoResumePoints): New. - (Iterator.EmitMoveNext): Use 'resume_points'. Get rid of - 'old_resume_points'. Move dispatcher upfront. - (Iterator.MarkYield): Mark the 'resume_point' of a Yield. - * statement.cs (ExceptionStatement.DoEmit): Emit a dispatcher if - in an enumerator. This encodes the main fix in this patch series - -- we can only jump into the first instruction of a try from the - outside, but we want to emit try/finally regions in iterators and - resume in the middle of them. - -2008-04-05 Raja R Harinath - - * statement.cs (ExceptionStatement.ResolveFinally): Move setting - of NeedReturnLabel here. - - Introduce a common point for emitting try/finally to IL - * statement.cs (ExceptionStatement.DoEmit): New. Combines all the - features of the various subclasses, which are now driven by ... - (ExceptionStatement.EmitPreTryBody): ... this and ... - (ExceptionStatement.EmitTryBody): ... this and the original - EmitFinallyBody. - (TryFinally, Lock, Using, UsingTemporary, DisposableWrapper): - Remove DoEmit and update to follow above protocol. - - * statement.cs (ExceptionStatement.EmitForDispose): If all labels - of the dispatcher are the same, skip emitting the 'switch'. - * iterator.cs (Iterator.EmitDispose): Update to changes. - - Clean up handling of 'using' statement - * statement.cs (UsingTemporary): New. Carved out of ... - (Using): ... this. Simplify drastically. Handle exactly - one variable. - * cs-parser.jay (using_statement): Split. Create UsingTemporary - or Using as appropriate. If there are multiple variable declared, - create nested Using statements. - (resource_acquisition): Kill. - - * statement.cs (ExceptionStatement.EmitForDispose): Use - EmitFinallyBody, not EmitFinally. - - * flowanalysis.cs (FlowBranching.StealFinallyClauses): Remove. - * iterator.cs: Update to changes. - - Start using the ResumableStatement infrastructure - * statement.cs (ResumeableStatement.PrepareForDispose): New. - (ResumableStatement.EmitForDispose): New. - (ExceptionStatement): Override them. - * iterators.cs (Iterator.EmitDispose): Use PrepareForDispose and - EmitForDispose to create the body of the Dispose method. Don't - use OldResumePoint. - - * iterator.cs (Iterator.AddResumePoint): Move here from ... - * statement.cs (Toplevel.AddResumePoint): ... here. - (Toplevel.MoveNextStatement.Resolve): Create FlowBranchingIterator. - * flowanalysis.cs (FlowBranchingIterator): New. - * codegen.cs (EmitContext): Update to changes. - - * iterators.cs (Iterator.OldResumePoint): Rename from ResumePoint. - (Iterator.old_resume_points): Rename from 'resume_points'. - (Iterator.MoveNextStatement): Remove unused class. - - New infrastructure for try/finally in iterators (still unused) - * flowanalysis.cs (FlowBranching.AddResumePoint): New. - (FlowBranchingToplevel.AddResumePoint): Hook into - ToplevelBlock.AddResumePoint. - (FlowBranchingTryCatch): Move CS01626 and CS01631 checks here. - (FlowBranchingException): Hook into ExceptionBlock.AddResumePoint. - * statement.cs (ToplevelBlock.AddResumePoint): New. Collect - resume points and assign program-counter values. - (ExceptionBlock.AddResumePoint): Collect resume points for - de-muxer at the top of try block. - * iterators.cs (Yield.CheckContext): Simplify. - (Yield.Resolve): Use FlowBranching.AddResumePoint. - -2008-04-04 Raja R Harinath - - * flowanalysis.cs (FlowBranching.AddReturnOrigin): Change Location - argument to an ExitStatement. - (FlowBranchingException): Refactor saved origins code. - * statement.cs (ExitStatement): Update to cahges. - * iterator.cs (YieldBreak): Likewise. - - * statement.cs (ResumableStatement): New. Common base class for - YieldReturn and ExceptionStatement. - (ExitStatement): New. Common base class for Return and YieldBreak. - (Return): Update to changes. - * iterator.cs (YieldBreak): Likewise. - * lambda.cs (ContextualReturn): Likewise. - - Fix #377028 - * ecore.cs (Expression.ResolveAsTypeStep): If '!silent' attempt to - emit a meaningful error message. - - Fix #324765, #319508 - * flowanalysis.cs (VariableInfo.IsEverAssigned): New. - (VariableInfo.SetAssigned): Set it. - * statement.cs (Block.UsageWarning): Use 'IsEverAssigned' to - determine if CS0219 or CS0168 is appropriate. Don't use - flow-analysis information. - (Block.Resolve): Use ec.EndFlowBranching, not ec.DoEndFlowBranching. - * codegen.cs (EmitContext.DoEndFlowBranching): Kill. Inline into ... - (EmitContext.EndFlowBranching): ... this. - -2008-04-03 Marek Safar - - * class.cs, typemanager.cs: Emit volatile field with IsVolatile modifier. - -2008-04-03 Marek Safar - - A fix for bug #376508 - * convert.cs, expression.cs: Fixed difference between ImplicitConversion and - ImplicitConversionExists. - -2008-04-03 Marek Safar - - * expression.cs (Binary): Added remaining binary operators to expression - tree builder. - - * nullable.cs: Optimize shift with null argument. - -2008-04-03 Raja R Harinath - - Fix minor IL regression - * statement.cs (TryCatch..ctor): Add 'inside_try_finally' argument. - (TryCatch.DoEmit): Use it to avoid creating another ExceptionBlock. - * cs-parser.jay (try_statement): Update to changes. - - * statement.cs (TryFinally.need_exc_block): Delete. - (TryFinally): Update to changes. - - Now all ExceptionStatements are unconditional - * statement.cs (CollectionForeach.DisposableWrapper): New. - Extract out the try/finally code into a new wrapper. - (CollectionForeach.Resolve): Use it to simplify the code. - -2008-04-02 Raja R Harinath - - Start at simplifying ExceptionStatement semantics a bit - * statement.cs (TryCatch, TryFinally): Split 'Try' into two pieces. - * cs-parser.jay (try_statement): Update to changes. - (opt_catch_clauses): Remove. - * flowanalysis.cs: Update to changes. - (FlowBranching.BranchingType.TryCatch): New. - (FlowBranchingTryCatch): New. - - * flowanalysis.cs (FlowBranching.BranchingType.SwitchSection): Kill. - (FlowBranching.CreateBranching): Update to changes. - (FlowBranchingBlock.AddSibling): Add sanity check. - * codegen.cs (EmitContext.StartFlowBranching) : - Update to changes. - - * iterators.cs (Iterator.MarkFinally): Remove. - * statement.cs (ExceptionStatement): Update to changes. - - Add support for skipping over finally blocks at runtime. First - in a series to fix #324708 - * iterators.cs (Iterator.SkipFinally): New LocalBuilder. - (Iterator.EmitMoveNext): Initialize it. - * statement.cs (ExceptionStatement.EmitFinally): Use it to emit a - branch over the body of the 'finally' clause. - -2008-03-31 Raja R Harinath - - Avoid lopsided use of Foo/DoFoo names - * statement.cs (ExpressionStatement.EmitFinallyBody): - Rename from EmitFinally. - (ExpressionStatement.EmitFinally): Rename from DoEmitFinally. - * iterator.cs: Update to changes. - -2008-04-02 Marek Safar - - * ecore.cs, expression.cs, nullable.cs: ConditionalLogicalOperator is now - based on UserOperatorCall. More binary nullable operators clean up. - -2008-04-02 Martin Baulig - - * symbolwriter.cs: Remove the `#if !DISABLE_TERRANIA_CHANGES' conditionals. - -2008-04-02 Marek Safar - - * nullable.cs: Merge user and empty conversions when lifting expression - trees. - - * expression.cs (StringConcat): Implemented expression tree representation. - -2008-04-01 Marek Safar - - * nullable.cs: When lifting null literal and a user operator exists, no call - is made. - -2008-04-01 Marek Safar - - * nullable.cs, ecore.cs, expression.cs: Convert null arithmetic to lifted - null. - -2008-04-01 Marek Safar - - * nullable.cs, expression.cs: Use namespace instead heavily nested - monster abstract class. - -2008-04-01 Marek Safar - - * ecore.cs, convert.cs, constant.cs, nullable.cs, expression.cs: Implemented - lifting of null literal and user operators. Clean up of some temporary - nullable hacks. - -2008-03-30 Raja R Harinath - - Fix #368224, test-629.cs - * flowanalysis.cs (FlowBranching.StealFinallyClauses): Return true - if it crossed an unwind-protect boundary. - * iterators.cs (Yield.CheckContext): Relax check for 'yield break'. - (Yield.Resolve, Yield.DoEmit): Track whether the yield occurs - inside an unwind-protected region. - (YieldBreak.Resolve, YieldBreak.DoEmit): Likewise. - (Iterator.MarkYield): Add 'unwind_protect' parameter. Emit a - 'leave' instead of a 'br' if unwind-protected. - (Iterator.EmitYieldBreak): Likewise. - -2008-03-29 Gert Driesen - - * driver.cs: Only define versioninfo resources if no win32 resource - file was specified. - -2008-03-28 Marek Safar - - A fix for bug #372375 - * convert.cs: Fixed boxing of nullable types. - -2008-03-28 Marek Safar - - * typemanager.cs: Initialize InternalsVisibleTo as the very first optional - type. - -2008-03-28 Marek Safar - - A fix for bug #374619 - * nullable.cs: Fixed guarding of EmitBitwiseBoolean. - -2008-03-27 Marek Safar - - * lambda.cs: Check return type only for invocation. - -2008-03-27 Marek Safar - - A fix for bug #374214 - * ecore.cs: Correctly report argument type mismatch. - -2008-03-27 Marek Safar - - * convert.cs (ImplicitReferenceConversionCore): Correctly compare enum type - and not rely on broken IsEnum. - -2008-03-27 Marek Safar - - * nullable.cs: New file, extracted from generic.cs. - - * generic.cs, generic-mcs.cs, *.csproj, *.sources: Updated. - -2008-03-27 Marek Safar - - * generic.cs, convert.cs, generic-mcs.cs, expression.cs: Added lifting of - predefined comparison operators and null literals. - - * report.cs: New warning ID. - -2008-03-25 Marek Safar - - A fix for bug #370577 - * lambda.cs: Check return type too. - -2008-03-25 Marek Safar - - A fix for bug #372846 - * class.cs: Automatic properties can be declared as unsafe. - -2008-03-20 Marek Safar - - * location.cs: Use string based concatenation. - - * expression.cs: LiftedBinaryOperator is gmcs only. - -2008-03-20 Marek Safar - - * generic.cs, literal.cs, ecore.cs, expression.cs: Ongoing work on nullable - conversions rules and expression trees. - -2008-03-19 Marek Safar - - * delegate.cs: Use extension method source as delegate target. - -2008-03-19 Marek Safar - - * generic.cs, generic-mcs.cs, expression.cs, ecore.cs: Rewrote nullable - binary operations to be purely based on binary operations and optimized - emitted code (30% less in some cases). Introduced ReducedExpression for ETs - and other ET refactoring. - - * typemanager.cs: Fixed warning. - -2008-03-17 Marek Safar - - * class.cs, decl.cs, delegate.cs: Do protected modifier check on each member - - * symbolwriter.cs: Fixed. - -2008-03-17 Marek Safar - - * anonymous.cs, driver.cs: Reset anonymous types counters. - -2008-03-17 Marek Safar - - * ecore.cs (MethodGroupExpr): Skip first candidate, it's already the best. - - * class.cs: Use fullname for all type member definitions. - -2008-02-19 Martin Baulig - - * class.cs - (IMethodData.EmitExtraSymbolInfo): New interface method. - (MethodData.Emit): Call method.EmitExtraSymbolInfo(). - (MethodOrOperator.EmitExtraSymbolInfo): Implement this new - interface method here as an empty public virtual method. - - * anonymous.cs - (AnonymousMethodMethod.ctor): Added `string real_name' argument. - (AnonymousMethodMethod.EmitExtraSymbolInfo): Override and call - CodeGen.SymbolWriter.SetRealMethodName(). - -2008-02-18 Martin Baulig - - * anonymous.cs - (ScopeInfo.EmitType): Override this and emit debugging - information for captured variables. - (RootScopeInfo.EmitType): Override this and emit symbol - information for a captured `this'. - -2008-02-15 Martin Baulig - - * iterators.cs: Emit debugging info. - - * codegen.cs - (EmitContext.Flags): Add `OmitDebuggingInfo'. - (EmitContext.OmitDebuggingInfo): New public property. - - * statement.cs - (While): Override Emit() and don't emit symbol info there; do it - inside DoEmit() instead. - (Block.Emit): Omit symbol information while emitting the scope - initializers; don't ec.Mark() the `EndLocation'. Fix the lexical - block logic. - (ExplicitBlock.IsIterator): Moved here from `ToplevelBlock'. - (ToplevelBlock.MakeIterator): Pass the `flags' to `ExplicitBlock's - .ctor to make `IsIterator' work. - -2008-03-14 Martin Baulig - - * symbolwriter.cs: Added the new symbol writer function from the - debugger's `terrania' branch; temporarily enclose them inside - `#if !DISABLE_TERRANIA_CHANGES' conditionals until I'm back from - my vacations. - -2008-03-14 Martin Baulig - - * symbolwriter.cs - (SymbolWriter): Make this a public static class. - - * codegen.cs - (CodeGen.SymbolWriter): Removed; use the new static `SymbolWriter' - class instead of using `if (CodeGen.SymbolWriter != null)' everywhere. - -2008-03-14 Marek Safar - - A fix for bug #370577 - * statement.cs, lambda.cs: Added extra limitations when dealing with void - return type. - -2008-03-14 Marek Safar - - * typemanager.cs (CSharpName): Made 250 times faster. - -2008-03-13 Marek Safar - - * ecore.cs, expression.cs: Emit conversion for ET shift argument. - -2008-03-12 Marek Safar - - * generic.cs, typemanager.cs, enum.cs, codegen.cs, statement.cs: Try not to - crash when predefined field does not exist. - -2008-03-12 Marek Safar - - * ecore.cs (PropertyExpr): Fixed IsSingleDimensionalArrayLength regression. - -2008-03-12 Marek Safar - - * class.cs (FixedField): Don't crash when contructors are missing. - -2008-03-11 Marek Safar - - * typemanager.cs, namespace.cs, literal.cs, ecore.cs, class.cs, decl.cs, - convert.cs, constant.cs, expression.cs, statement.cs: Use same method to - check internal types accessibility for internal and external types. - Replaced EnumToUnderlying by GetEnumUnderlyingType. - -2008-03-11 Marek Safar - - * support.cs, typemanager.cs, pending.cs, ecore.cs, class.cs, delegate.cs - convert.cs, const.cs, anonymous.cs, constant.cs, expression.cs, - attribute.cs, statement: Use corect instance of predefined types (work - related to #364674). - -2008-03-07 Marek Safar - - * expression.cs (TypeOfVoid): Fixed predefined method initialization. - -2008-03-07 Marek Safar - - * generic.cs, typemanager.cs, parameter.cs, rootcontext.cs, ecore.cs, - class.cs, delegate.cs, iterators.cs, const.cs, constant.cs, driver.cs, - expression.cs, attribute.cs, codegen.cs, statement.cs: TypeManager optional - predefined types clean up, delayed predefined types members initialization - (work related to #364674). - -2008-03-05 Marek Safar - - * typemanager.cs (IsFriendAssembly): InternalsVisibleTo is not mandatory. - -2008-03-05 Marek Safar - - * typemanager.cs, parameter.cs, rootcontext.cs, ecore.cs, class.cs, decl.cs, - delegate.cs, convert.cs, driver.cs, attribute.cs, codegen.cs: TypeManager - predefined types clean up (work related to #364674). - -2008-03-04 Marek Safar - - * ecore.cs: Print an error message instead of throwing exception. - -2008-03-04 Marek Safar - - * generic.cs, typemanager.cs, literal.cs, convert.cs, cfold.cs, constant.cs, - expression.cs, statement.cs: Unififed null literal representation. - -2008-03-03 Marek Safar - - * anonymous.cs, cfold.cs, convert.cs, delegate.cs, doc.cs, ecore.cs, - expression.cs: Refactored binary operators resolve phase and improved speed. - The nullable code is still missing and won't work correctly, more fixes - required. - - It also fixes #323726, #324312, #324248, and many other unreported issues. - -2008-02-29 Zoltan Varga - - * report.cs (FeatureIsNotAvailable): Use 'mcs1' instead of 'mcs', and 'mcs' - instead of 'gmcs'. - -2008-02-27 Marek Safar - - * ecore.cs: Clean-up and split BetterConversion. - -2008-02-25 Raja R Harinath - - Fix #363791 - * enum.cs (EnumMember.Value): Only access 'value' if - ResolveValue says it's ok. - (EnumMember.DoResolveValue): Don't set prev_member.value. - (Enum.GetDefinition): Reverse arguments of Equals -- - EnumMember.Value can return 'null'. - - * statement.cs (Switch.Error_AlreadyOccurs): Fix typo in name. - -2008-02-22 Marek Safar - - * generic.cs, expression.cs: More ongoing work on expression trees. - -2008-02-21 Marek Safar - - * class.cs, typemanager.cs: Rewrote operator matching logic to correctly - handle missing matches when mutiple operators exist. - -2008-02-20 Marek Safar - - A fix for bug #363218 - * expression.cs (ArrayCreation.Clone): Deal with multi-dimensional - initializers. - -2008-02-20 Marek Safar - - * expression.cs, constant.cs, cfold.cs: Yet another side-effect constant - update. This time to deal correctly with SideEffectConstant expression used - as an argument for another constant folding. - -2008-02-20 Raja R Harinath - - * typemanager.cs (DropGenericMethodArguments): Ensure we get an underlying - MethodBuilder. - -2008-02-19 Marek Safar - - * constant.cs, cfold.cs: SideEffectConstant results can apply for folding. - -2008-02-19 Marek Safar - - A fix for bug #328136 - * expression.cs: Do not fold immediately LogicalAnd operators when the left - side is a false constant, because we still need to evaluate the right-hand - side. - - * statement.cs (If): Emit two types of boolean constants (simple constant, - side-effect constant). - -2008-02-19 Marek Safar - - * constant.cs (SideEffectConstant): Don't emit boolean constant. - - * expression.cs: Fold immediately LogicalAnd operators when both sides are - constants. - -2008-02-18 Marek Safar - - A fix for bug #361457 - * ecore.cs (IsApplicable): Params methods have lower priority. - - * support.cs: Return correct parameter modifier for params types. - -2008-02-18 Marek Safar - - * generic.cs (TypeParameter): Cache attribute target name. - - * support.cs: Removed unused variable. - - * typemanager.cs: Removed debugging leftover. - - * ecore.cs: Use local type instead of a property; - - * class.cs (VerifyMembers): Consider also parent to test whether type member - is local or public. - - * expression.cs (FullMethodDesc): Removed. - - * attribute.cs (IsValidArgumentType): Made static. - -2008-02-17 Raja R Harinath - - Cleanup to be more readable. - * Makefile (GMCS_PROFILE): Remove. - (COMPILER_NAME): New helper. - -2008-02-15 Miguel de Icaza - - * cs-tokenizer.cs: if a conditional expression happens inside a - (...) this also means that we do not need to de-ambiguate between - an parenthesized expression and a cast. - - Fixes 346484. - - * constant.cs (SideEffectConstant): a constant value that happens - to have a side effect. - - Fixes the build regressions introduced by the fix for #359789 - -2008-02-14 Rodrigo Kumpera - - * expression.cs (Conditional.Emit): when emitting the ternary - operator, use local variables to generate code verifiable code. - - The verifier cannot infer that the type on stack before the - stloc.0 is executed is of type ParentB. This happens because the - stack merge algorithm uses only parent types when deciding which - is the common type. This is described in Part III 1.8.1.3 of ECMA - 335. - - This code compiled with mcs is not verifiable under MS. The MS - verifier picks the first common interface of Foo and Bar, which is - wrong, but doesn't use a full join type of the 2 interfaces. - - CSC uses a clever hack to compile such code in a verifiable - way. It stores the intermediate values in a local variable with - the expected type. - - Fixes: #358102 - -2008-02-14 Miguel de Icaza - - * expression.cs: Do not fold BitwiseAnd operators when the left - side is a false constant, because we still need to evaluate the - right-hand side. - - Fixes #359789 - - * support.cs: Instead of throwing an InternalErrorException when - the position of the stream is outside the boundary of our buffer, - reset the state of the reader, and restart the reading from the - beginning of the file. - -2008-02-14 Marek Safar - - * generic.cs (TypeParameter.GetMembers): Is not supported operation. - -2008-02-14 Marek Safar - - A fix for bug #361686 - * decl.cs: A protected types used inside a private class which parents - derives from the protected class are accessible. - -2008-02-13 Marek Safar - - * generic.cs (ConstraintChecker): Use cached member lookup when looking for - the parameterless constructor. - -2008-02-13 Marek Safar - - * generic.cs, typemanager.cs, iterators.cs, codegen.cs: Refactored core - lookup methods to use standard member cache when doing member lookup. - -2008-02-12 Marek Safar - - * driver.cs: Don't report full path for referenced module as assembly error. - -2008-02-12 Marek Safar - - * Makefile: Fixed `qh' target to work on all machines. - - * report.cs, typemanager.cs, parameter.cs, ecore.cs, class.cs, anonymous.cs, - expression.cs, codegen.cs, statement.cs, doc.cs: Replaced type IsSubclassOf - and HasElementType with TypeManager implementation. - -2008-02-08 Marek Safar - - A fix for bugs #325134, #359749 - * expression.cs, ecore.cs: Try to resolve an extension method even if the - first binds point to non-method member expression. - -2008-02-08 Marek Safar - - * cs-parser.jay: Null coalescing operator is not part of ISO-1. - -2008-02-08 Marek Safar - - A fix for bugs #321394, #323028 - * generic.cs, parameter.cs, ecore.cs, class.cs, decl.cs, delegate.cs: - Reworked naive IsAccessibleAs implementation to handle nested types. - -2008-02-05 Jb Evain - - * class.cs: use generic type comparison for parameters - as well. - -2008-02-05 Marek Safar - - A fix for bug #325372 - * class.cs: Use generic type comparison when testing method signatures. - -2008-02-05 Marek Safar - - A fix for bug #357047 - * ecore.cs: Applied C# 3.0 changes to better conversion. - -2008-02-05 Marek Safar - - A fix for bug #358374 - * cs-parser.jay: Correctly set modifiers for all constructor types. - -2008-02-04 Marek Safar - - A fix for bug #355251 - * generic.cs: Added base class constraint based type inference. - -2008-02-01 Marek Safar - - A fix for bug #357255 - * decl.cs: One more missing visibility check. - -2008-02-01 Marek Safar - - * support.cs: Fixed broken return. - -2008-01-25 Marek Safar - - * report.cs: Correctly reset warnings count after probing. - -2008-01-25 Martin Baulig - - * namespace.cs - (NamespaceEntry.SymbolFileID): Make this work again after - MemberName.ToString() is gone. - -2008-01-25 Marek Safar - - * expression.cs: Implemented Divide, Equal, ExclusiveOr, GreaterThanOrEqual - expressions. - -2008-01-25 Marek Safar - - * generic.cs: Use full implicit conversion for type inference fixing. - -2008-01-24 Marek Safar - - * ecore.cs, expression.cs, generic.cs: Implemented Convert, ConvertChecked. - Fixed user operator conversions. - -2008-01-24 Marek Safar - - * generic.cs: Do nullable type to null comparison optimization during - resolve phase. - -2008-01-24 Marek Safar - - A fix for bug #355163 - * generic.cs: Enabled l-value resolve on nullable expressions. - -2008-01-24 Marek Safar - - A fix for bug #353986 - * class.cs: Ingore static ctors with parameters for any further checks. - -2008-01-24 Marek Safar - - A fix for bug #354310 - * namespace.cs: Removed redundant check. - -2008-01-24 Marek Safar - - A fix for bug #354928 - * expression.cs: ElementInitializers can be resolved only once. - -2008-01-24 Marek Safar - - * convert.cs, ecore.cs, expression.cs, generic.cs: Implemented Coalesce and - Condition expressions. - -2008-01-23 Marek Safar - - * codegen.cs: Fixed AssemblyBuilder initialization on other platforms. - -2008-01-22 Marek Safar - - * ecore.cs, expression.cs, generic.cs: Implicit bool? to bool conversion is - not allowed. - - * generic.cs: Implemented coalesce expression. - -2008-01-22 Marek Safar - - A fix for bug #355145 - * anonymous.cs, convert.cs, ecore.cs, generic.cs, lambda.cs: Implemented - expression tree type inference. - -2008-01-22 Raja R Harinath - - Fix #354663 - * expression.cs (Binary.IsUnsignedType): Fix typo. - -2008-01-22 Marek Safar - - * ecore.cs, expression.cs, generic.cs: Implemented NewArrayInit expression. - -2008-01-22 Marek Safar - - A fix for bug #355161 - * ecore.cs, expression.cs: Wider range of extension method supported - expressions. - -2008-01-22 Gert Driesen - - * codegen.cs: Use magic value for AssemblyBuilderAccess to instruct - AssemblyBuilder to operate in compiler context. Fixes mcs part of - bug #354970. - -2008-01-22 Marek Safar - - A fix for bug #355148 - * ecore.cs, expression.cs: Correctly report misused ref and out modifiers. - -2008-01-22 Miguel de Icaza - - * expression.cs (CreateExpressionTree): Add support for or and - logical or, and indent following the coding conventions. - - * typemanager.cs (LinqExpression): renamed from - ExpressionTreeManager, for a shorter name. - - Use TypeManager.CoreLookupType to lookup types from our core - assemblies and turn those into "Type" variables. - - Consumers that previously used "Namespace" and "Type" from this - class should instead use the TypeExpression which is a type that - is fully resolved (without involving the regular C# resolution - rules). - - This typically looks like this: - - TypeExpression texpr = new TypeExpression (LinqExpression.expression_type, loc); - new MemberAccess (texpr, name, type_arguments, loc) - - This avoids the problem in: #355178 - -2008-01-21 Marek Safar - - * cs-parser.jay, expression.cs: Check `namespace alias qualifier' language - feature in parser only as we do in other cases. - -2008-01-21 Marek Safar - - * attribute.cs, ecore.cs, class.cs, delegate.cs, expression.cs, linq.cs, - typemanager.cs: A refactoring of params arguments to reuse existing - expressions (params -> array initializer) to emit params argument instead - of specialized handling. - It was required by expression tree implementation and it has other benefits - as well, we now apply same optimization for params arguments as we do for - array initializers. - -2008-01-18 Marek Safar - - A fix for bug #353526 - * generic.cs: A type inference of params arguments may not required any - temporary array creation. - -2008-01-18 Marek Safar - - A fix for bug #353534 - * generic.cs, ecore.cs, expression.cs: A method group type inference is - supported for delegates only. - -2008-01-18 Marek Safar - - * generic.cs: Fixed 3.0 type inference fixing phase to determine a unique - type for more than 1 candidates. - -2008-01-18 Marek Safar - - * typemanager.cs, ecore.cs, expression.cs: Implemented ArrayLength and Call - expressions. - -2008-01-16 Marek Safar - - * generic.cs, typemanager.cs, lambda.cs, parameter.cs, ecore.cs, constant.cs, - expression.cs: Implemented Add, And, AndAlso, and ArrayIndex (without unary - operator) expressions. - -2008-01-16 Zoltan Varga - - * statement.cs: Avoid declaring an IL variable for this_variable since it is - not accessed from the generated IL. - -2008-01-14 Marek Safar - - * typemanager.cs, lambda.cs, parameter.cs, ecore.cs, class.cs, delegate.cs, - iterators.cs, convert.cs, assign.cs, anonymous.cs, expression.cs, - statement.cs: The first expression tree implementation drop, mostly - infrastructure work. - -2008-01-14 Marek Safar - - * ecore.cs (IsNestedChild): Refactored. - -2008-01-11 Marek Safar - - * lambda.cs: Don't use a cast on unknown expression statement. - -2008-01-10 Geoff Norton - - * cs-tokenizer.cs: One more token to distinguish between method and lambda - arguments - -2008-01-09 Marek Safar - - * doc.cs: Report better /doc crash details. - -2008-01-09 Marek Safar - - A fix for bug #352536 - * ecore.cs, assign.cs, codegen.cs: Check event assignments. - -2008-01-08 Marek Safar - - A fix for bug #352287 - * ecore.cs, expression.cs: Do `this' access checking in all member access - expressions. - -2008-01-08 Marek Safar - - * rootcontext.cs, driver.cs: Switch to linq mode by default. - - * report.cs: Reset message stacks. - -2008-01-08 Marek Safar - - * generic.cs (InferInPhases): Correctly calculate params position. - -2008-01-08 Marek Safar - - * cs-tokenizer.cs: No need to parse full string when parsing lambda - arguments. - -2008-01-07 Marek Safar - - * cs-tokenizer.cs: Enabled lambda arguments micro-parser for all profiles. - - * decl.cs (LookupNamespaceOrType): Don't cache names which caused an error. - - * driver.cs: Updated --help option. - -2008-01-07 Marek Safar - - * generic.cs (InferParamsTypeArguments): Removed. - (InferInPhases): Add params type inference. - (LowerBoundInference): Fixed scoring mechanism. - - * cs-tokenizer.cs (PreProcessPragma): Use Location instead of line. - -2008-01-06 Gert Driesen - - * typemanager.cs: On 2.0 profile, GetPublicKeyToken returns an empty - byte array for unsigned "baked" assemblies. - -2008-01-05 Gert Driesen - - * codegen.cs: AssemblyName.GetPublicKey returns a zero-length byte - array for assemblies that are not strongnamed. - -2008-01-04 Marek Safar - - A fix for bug #351481 - * expression.cs (MemberAccess.ResolveNamespaceOrType): Use correct - declaring type for nested generic types. - -2008-01-04 Marek Safar - - * namespace.cs, class.cs, decl.cs, cs-parser.jay: Use GetSignatureForError - instead of ToString. - -2008-01-03 Marek Safar - - A fix for bug #351047 - * expression.cs (Binary.ResolveOperator): Allow equality operators between - null and structs only when equality and inequality operators are defined - either as an user-operators or predefined operators. - -2008-01-03 Marek Safar - - A fix for bug #351047 - * generic.cs, typemanager.cs, class.cs: New IsReferenceType helper method. - -2008-01-03 Marek Safar - - A fix for bug #351257 - * cs-tokenizer.cs: Advance line number for '\r' correctly. - -2008-01-03 Marek Safar - - A fix for bug #351157 - * class.cs (Using): Fixed yet another broken cloning. - - (Block): Put back more sensible default value for statements. - -2008-01-01 Gert Driesen - - * codegen.cs: Allow AssemblyVersion with only major version component. - Fixes bug #351055. - -2007-12-29 Marek Safar - - A fix for bug #324654 - * class.cs: Use FullName property as member name. - -2007-12-28 Marek Safar - - A fix for bug #342117 - * generic.cs (ConstraintChecker): Struct constraint also satisfies default - constructor constraint. - -2007-12-28 Marek Safar - - A fix for bug #338273 - * class.cs (ProbertyBase): Access modifier checks are required for overrides - only. - -2007-12-28 Marek Safar - - A fix for bug #350839 - * ecore.cs (MethodroupExpr): Probing hacks are no longer required. - -2007-12-27 AdTsai (http://code.google.com/u/AdTsai/) - - Reviewed by Ben Maurer, Miguel de Icaza, patches from Google's - GHOP: - - http://code.google.com/p/google-highly-open-participation-mono/issues/detail?id=4 - - * statement.cs: Changed some Hashtables to use HybridDictionaries - instead. It was observed that some HashTables only contained a few - items in the vast majority of cases. Since HybridDictionary is - more efficient on small sets (<10 elements), "known_variables" - from class ExplicitBlock as well as "labels" and "constants " from - class Block were changed to HybridDictionaries. - - Atsai results: (56216kb->54987kb) - - Miguel results (bootstrap of mcs): 59819kb -> 59290kb - - -2007-12-27 AdTsai (http://code.google.com/u/AdTsai/) - - Reviewed by Ben Maurer, Miguel de Icaza, patches from Google's - GHOP: - - http://code.google.com/p/google-highly-open-participation-mono/issues/detail?id=4 - - * expression.cs: foreach loop to for loop, saved on allocation of - enumerator (59333kb->59141kb) - - * statement.cs. Changed foreach loops to for loops, saved on - allocation of enumerator (59141kb->59006kb) - - * decl.cs: ArrayLists in .NET 1.1 allocate 16 elements by default - when constructed with no specified capacity. This was causing a - few ArrayLists to allocate more memory than they would potentially - need in the Block class and MemberCache class. Setting the - ArrayLists to construct with a capacity of 1 saves some - memory. (56216kb->55585kb) - -2007-12-27 Marek Safar - - A fix for bug #347189 (2nd issue) - * expression.cs (MemberAccess): Nested type can be found in base non-generic - type. - -2007-12-27 Miguel de Icaza - - * report.cs: Do not use colors if stdout and stderr are not a - terminal. - -2007-12-27 Marek Safar - - A fix for bug #346998 - * ecore.cs (MethodGroupExpr): Implemented override filter for generic - overloads. - -2007-12-27 Marek Safar - - A fix for bug #343465 - * class.cs: Explicit method name for nested types uses dots only. - -2007-12-27 Marek Safar - - A fix for bug #343707 - * cs-tokenizer.cs: Advance line number for mixed CR/LF files correctly. - -2007-12-27 Marek Safar - - * ecore.cs: Report type inference errors only when arguments count matches - parameter count. - - * generic.cs (NullCoalescingOperator): Cannot be applied to null. - - * expression.cs, report.cs: New warning. - - * typemanager.cs: Catch anonymous method type too. - -2007-12-23 Marek Safar - - A fix for bug #346379 - * expression.cs (UnaryMutator): Emit size of type for pointer mutator. - -2007-12-23 Marek Safar - - A fix for bug #347359 - * expression.cs (Invocation): Don't resolve already resolved expression. - -2007-12-23 Marek Safar - - A fix for bug #347189 - * class.cs (FixedField): Use non-dependent code only in the define phase. - -2007-12-23 Marek Safar - - A fix for bug #348076 - * ecore.cs (FieldExpr.DoResolve): Allow any variable based expression. - -2007-12-22 Marek Safar - - * ecore.cs (MethodGroupExpr.OverloadResolve): Set type arguments for - discovered extension methods. - -2007-12-22 Marek Safar - - * ecore.cs, namespace.cs, expression.cs: Removed broken ResolveGeneric - method. - -2007-12-21 Miguel de Icaza - - * report.cs (ErrorMessage): Add support for using colors on - terminals that support it. - -2007-12-21 Marek Safar - - * ecore.cs: Use information about expanded params for error reporting. - -2007-12-21 Marek Safar - - * ecore.cs, generic.cs, delegate.cs: Refactoring of method overloading code - and logic for params overloads. - -2007-12-15 Miguel de Icaza - - * generic.cs (NullCoalescingOperator.CloneTo): implement this one, - as this is also created from the parser. Fixes #349034 - -2007-12-12 Miguel de Icaza - - * statement.cs (Throw.CloneTo): it is valid to have empty - expressions for throw. - -2007-12-03 Marek Safar - - * cs-parser.jay: Set delegate constraint parsing region correctly. - -2007-12-03 Marek Safar - - A fix for bug #345467 - * typemanager.cs (IsEqual): Compare generic parameters position only. - -2007-11-28 Marek Safar - - * expression.cs (BaseAccess): Type arguments can be null. - -2007-11-27 Raja R Harinath - - * statement.cs (Block.Resolve): Ensure flow-branching tree is - consistent even when an error has occured. - (Switch.Resolve): Likewise. - -2007-11-22 Marek Safar - - A fix for bug #334505 - * class.cs: Don't ignore InternalsVisibleTo attribute for internal - overrides. - -2007-11-22 Marek Safar - - * ecore.cs, typemanager.cs, delegate.cs, expression.cs: The first of - refactorings required to resolve extension methods correctly when mixing - generics and non-generics members. - -2007-11-20 Marek Safar - - A fix for bug #342584 - * convert.cs: Added not documented explicit IntPtr/UIntPtr to enum - conversion. - -2007-11-19 Marek Safar - - A fix for bug #342512 - * delegate.cs: Use delegate argument expression when is available. Don't - emit virtual call when class is sealed. - -2007-11-16 Marek Safar - - A fix for bug #325423 - * assign.cs (FieldInitializer): Use resolved expression for emit. - - * class.cs: Print less confusing error message. - -2007-11-16 Marek Safar - - * cs-tokenizer.cs: Removed GMCS ifdefs. - - * rootcontext.cs, report.cs: Report unavailable gmcs features used by - mcs. - - * cs-parser.jay: Disabled nullable check. - - * generic-mcs: Copied more generic stuff. - -2007-11-16 Marek Safar - - * gcs-parser.jay: Merged to cs-parser.jay. - - * generic.cs, typemanager.cs, cs-tokenizer.cs, linq.cs, Makefile - * *.csproj, *.sources: Updated to use only jay parser file. - -2007-11-16 Marek Safar - - * gcs-parser.jay: Added nullable and default expression feature checks. - -2007-11-16 Marek Safar - - * gcs-parser.jay, cs-parser.jay, class.cs: Unified parameters parsing, - it fixes many TODOs and hidden bugs. - - * expression: Removed duplicate error check. - -2007-11-15 Marek Safar - - * gcs-parser.jay, statement.cs, decl.cs, ecore.cs: Try to resolve an - implicitly type local variable only when it is used in a declaration. - -2007-11-15 Marek Safar - - * attribute.cs: Use CS0612 for empty strings. - -2007-11-14 Marek Safar - - * lambda.cs, statement.cs: Contextual return may act as a statement. - -2007-11-14 Marek Safar - - A fix for a regression cause by #324222 - * class.cs: Don't report unused even when it implements an interface. - -2007-11-13 Marek Safar - - A fix for bug #341205 - * ecore.cs, expression.cs: Method group expression cannot do static - method access with an instance reference check before overloading takes - a place. - -2007-11-13 Marek Safar - - A fix for bug #325359 - * class.cs: Use predictable name for automatically generated property. - -2007-11-12 Marek Safar - - A fix for bug #324996 - * expression.cs (Is): Handle case where D is nullable and T is not - correctly. - - * generics.cs (Nullable.HasValue): Nullable HasValue expression. - -2007-11-12 Marek Safar - - * generic.cs, literal.cs, ecore.cs, class.cs, delegate.cs, const.cs, - anonymous.cs, expression.cs, attribute.cs, codegen.cs, statement.cs: - Flush small error reporting changes. - -2007-11-09 Marek Safar - - A fix for bug #324996 - * expression.cs: Rewrote Is expression implementation to work with - generics, nullable types, anonymous method. A const result expression - uses existing infrastructure instead of custom not fully-featured one. - -2007-11-08 Marek Safar - - A fix for bug #340202 - * class.cs: Consider generics for volatile field. - -2007-11-08 Marek Safar - - A fix for bug #335594 - * expression.cs: Use conversion rules when handling string addition. - -2007-11-07 Marek Safar - - A fix for bug #336651 - * expression.cs: Fixed a crash when probing is on. - -2007-11-07 Marek Safar - - A fix for bug #324242 - * covert.cs: Added a conversion from any nullable-type with an - underlying enum-type to the type System.Enum. - -2007-11-07 Marek Safar - - A fix for bug #324222 - * class.cs: Report all non-used event fields. - -2007-11-07 Marek Safar - - A fix for bug #325161 - * cs-parser.jay, gcs-parser.jay, decl.cs: Implemented namespace alias - qualifier for generic types. - -2007-11-07 Marek Safar - - A fix for bug #322971 - * expression.cs, ecore.cs: Added intermediate result value check for - indexers. - -2007-11-07 Marek Safar - - A fix for bug #324754 - * cs-parser.jay, gcs-parser.jay, class.cs: Try to create an interator - when it was requested. - -2007-11-07 Marek Safar - - A fix for bug #325101 - * expression.cs: Do type not value comparison for `is' expression. - -2007-11-07 Marek Safar - - A fix for bug #320236 - * convert.cs: Don't apply user conversion on underlying target type. - -2007-11-06 Marek Safar - - * expression.cs: Don't use unresolved expression for error reporting. - -2007-11-06 Marek Safar - - A fix for bugs #337712, #324490 - * ecore.cs (MethodGroupExpr): Refactored to handle delegate method - overloading resolution too. - - * delegate.cs: Uses MethodGroupExpr for overloading resolution. It makes - the process consistent and more robust. - - * expression.cs, linq.cs, report.cs: Update. - -2007-11-02 Marek Safar - - A fix for bug #332909 - * attribute.cs: Resolve attributes in correct context using error - handling procedure. - - * rootcontext.cs: Define Obsolete attribute members as core members. - -2007-11-02 Marek Safar - - * statement.cs: Removed unused methods. - -2007-10-31 Wade Berrier - - * Makefile: reenable copy of gmcs.exe.config, but include it in EXTRA - DIST (it doesn't get included because PROGRAM isn't defined to be gmcs - during 'make dist') - -2007-10-31 Marek Safar - - A fix for bug #338102 - * decl.cs (CheckExistingMembersOverloads): Workaround issue with generic - methods registered as non-generics. - -2007-10-31 Marek Safar - - A fix for bugs #337712, #324490 - * delegate.cs: Delegate covariance and contravariance is not allowed for - value types. - -2007-10-31 Marek Safar - - A fix for bug #337719 - * cs-tokenizer.cs: Restore identifier buffer when parsing contextual - `from' keyword. - -2007-10-30 Marek Safar - - * Makefile (net_2_0_bootstrap/mcs.exe.config): Reverted copy gmcs.exe.config. - -2007-10-29 Marek Safar - - * cs-tokenizer.cs, gcs-parser.jay, driver.cs: Fixed parsing of nested - query expressions. - -2007-10-29 Raja R Harinath - - * Makefile (net_2_0_bootstrap/mcs.exe.config): Copy gmcs.exe.config. - -2007-10-29 Marek Safar - - A fix for bug #334652 - * ecore.cs (MethodGroupExpr.OverloadResolve): Do also lookup for - extension methods when we have not found the best candidate in normal - container. - -2007-10-27 Marek Safar - - * AssemblyInfo.cs: Keep up-to-date. - -2007-10-27 Marek Safar - - * Makefile: Fixed generics compiler name. - -2007-10-27 Marek Safar - - * lambda.test: removed, lambda parsing is done differently. - - * gen-il.cs, gen-treedump.cs, old-code.cs : Obsolete. - -2007-10-27 Gert Driesen - - * Makefile: Removed dependency on gmcs.exe.config. Fixes build. - -2007-10-27 Marek Safar - - * Makefile, *.sources : All C# compilers are in mcs folder. - - * *.cs: Use existing 2_1 define for smcs. - -2007-10-26 Marek Safar - - A fix for bug #335847 - * assign.cs, expression.cs: Couple of changes to avoid creating a - temporary variable for each object initializer assignment statement. It - simplifies struct initialization too, otherwise two temporary variables - would be required. - Implemented optimization of redundant default element initializers. - -2007-10-25 Marek Safar - - A fix for bug #336766 - * expression.cs (Class.CheckBase): Use generic name when method is - generic. - -2007-10-25 Marek Safar - - A fix for bug #334737 - * expression.cs (IndexerAccess.EmitAssign): Emit local temporary - variable and not variable argument for prepared copies. - -2007-10-24 Marek Safar - - A fix for bug #325110 - * class.cs, expression.cs, attribute.cs: Use open generic method when - checking conditional attribute. - -2007-10-24 Marek Safar - - * report.cs, cs-tokenizer.cs, class.cs, cs-parser.jay, anonymous.cs, - expression.cs, statement.cs: Renamed method FeatureIsNotISO to - FeatureIsNotAvailable. - -2007-10-24 Marek Safar - - ** C# 3.0 Partial methods - - * cs-tokenizer.cs, support.cs, class.cs, decl.cs: Implemented partial - methods support. Because of member cache issue with generics only - non-generics partial methods are fully supported. - -2007-10-23 Marek Safar - - * class.cs, decl.cs: Rewrote member overloads check to cope with - generics and to use member cache for member checking. It also improves - performance and fixes remaining overloads issues. - -2007-10-20 Marek Safar - - * class.cs, const.cs, decl.cs, delegate.cs, enum.cs, generic.cs, - roottypes.cs, typemanager.cs: - - A member cache creation logic changed to add members immediately and - not rely on fallback. The member cache is now only prefered way - how to access and find type declaration members. It saves 5 MB of memory - during MWF compilation and makes code ready for more optimizations and - clean-ups, it's also a pre-requirement for partial methods. - -2007-10-18 Raja R Harinath - - * ecore.cs (Expression.Error_ValueCannotBeConverted): Add special - handling for generic parameters. - -2007-10-15 Marek Safar - - * class.cs (FixedField): Removed redundant volatile check. - -2007-10-15 Marek Safar - - * class.cs, decl.cs: Fixed overload members verification to do only one - check per possible collision. - -2007-10-13 Marek Safar - - A fix for bug #325478 - * anonymous.cs (AnonymousContainer.Compatible): Merge are flags together - and create only one disposable flags container. - -2007-10-12 Marek Safar - - A fix for bug #332442 by Alexandre Gomes - * statement.cs (Fixed): Fixed variables cloning. - -2007-10-12 Marek Safar - - A fix for bug #333342 - * class.cs (EventField): Don't mark value type event as synchronized. - -2007-10-12 Marek Safar - - * ecore.cs, anonymous.cs (MethodGroupExpr): Use score from type - inference to identify best candidate method correctly. - (ProperyExpr): A range variable is read only and cannot be modified. - -2007-10-11 Marek Safar - - * ecore.cs, delegate.cs (MethodGroupExpr): Refactored best candidate - logic to identify best candidate method correctly. - -2007-10-11 Marek Safar - - * location.cs (Equals, GetHashCode): Removed. - -2007-10-11 Marek Safar - - * report.cs: Implemented message recorder. It is used mainly for lambda - expressions to capture otherwise swallowed error messages. - - * anonymous.cs, lambda.cs.cs: Do full parameters check. - - * ecore.cs (ExtensionMethodGroup): Report binding failure at the botton - and not at the top. - (MethodGroupExpr.DoResolve): Use message recorder for error handling. - - * expression.cs (MemberAccess): Always report lookup failure. - - * location.cs: Implemented Equals, GetHashCode. - - * statement.cs (Return.DoResolve): Fixed hardcoded error argument. - -2007-10-10 Jb Evain - - * codegen.cs: re-enable assembly version check. - -2007-10-09 Marek Safar - - * report.cs, anonymous.cs, driver.cs, expression.cs: Added few ISO-2 - checks. - - * namespace.cs (UsingAlias): Do correct version check. - -2007-10-08 Marek Safar - - * expresison.cs, ecore.cs: Issue extension method error message when - appropriate. - - * rootcontext.cs: Added ISO_2 compiler mode option. - -2007-10-08 Marek Safar - - * expresison.cs (UnaryMutator.ResolveOperator): Print more useful error - message. - -2007-10-08 Marek Safar - - * attribute.cs (GetString, GetBoolean): Work with both literal and - constant. - - * ecore.cs, expresison.cs, delegate.cs (Invocation, MethodGroupExpr): - Moved method overload specific methods to MethodGroupExpr. - - (IndexerAccess): Re-wrote resolving mechanism, fixed many issues and - it should be less memory consuming. - -Mon Oct 8 09:29:15 CEST 2007 Paolo Molaro - - * codegen.cs: remove the assembly version check until the buildbot is - fixed. - -2007-10-07 Jb Evain - - * attribute.cs (Attribute.GetString): if the value - expression is a StringConstant, return its string value. - -2007-10-07 Jb Evain - - * typemanager.cs: add `assembly_version_attribute_type`. - * codegen.cs: on attribute emission, check that the - AssemblyVersionAttribute doesn't overflow. - -2007-10-05 Marek Safar - - A fix for bug #324677 - * anonymous.cs, decl.cs: Yes another anonymous container hack. Overwrite - parent container of a scope container with currently resolved one. - -2007-10-05 Marek Safar - - A fix for bug #325534 - * class.cs (Invocation.DoResolve): Check invocation of object finalizer - only. - -2007-10-05 Marek Safar - - A fix for bug #327504 - * class.cs (Operator.Define): Refactored implicit and explicit user - operator conversion rules. - -2007-10-05 Marek Safar - - A fix for bug #327520 - * ecore.cs (ExtensionMethodGroupExpr): Emit resolved extension argument. - -2007-10-04 Marek Safar - - A fix for bug #328022 - * class.cs (MethodData.Define): Use correct method to check whether - a method implementents an accessor. - -2007-10-04 Marek Safar - - A fix for bug #330069 - * statement.cs (Fixed.Resolve): Read the first array element only when - an array is instantiated. - -2007-10-04 Marek Safar - - * expression.cs, assign.cs, generics.cs: Print correct operator when - compound assignment is used. - -2007-10-04 Marek Safar - - A fix for bug #325841 - * expression.cs (ArrayAccess): Use full argument cloning only for - string compound concatenation. - -2007-10-03 Marek Safar - - A fix for bug #328774 - * ecore.cs (FieldExpr.EmitAssign): Fixed string concatenation compound - assignment. - (PropertyExpr.EmitAssign): Fixed string concatenation compound - assignment. - -2007-10-03 Raja R Harinath - - Fix #328490 - * ecore.cs (SimpleName.DoSimpleNameResolve): Handle Property and - Event accessibility checks here. Remove some bogus code that - accidently made GenericMethods work. - (PropertyExpr.IsAccessibleFrom, EventExpr.IsAccessibleFrom): New. - -2007-09-25 Marek Safar - - * expression.cs (ArrayCreation): Fixed cloning of an implicit types. - - * statement.cs (Block): Refactored AddVariable to allow error handling - customization. - - * generic.cs: New stub. - -2007-09-23 Marek Safar - - * anonymous.cs, codegen.cs: Changed InferReturnType to be EmitContext - flag. - -2007-09-17 Marek Safar - - * class.cs: Use partial container to record whether any partial part - contains static field initializer and therefore default contructor has - to be defined. - -2007-09-14 Marek Safar - - * class.cs (TypeContainer.AddPartial): Fixed an issue reported on - mono-list when only one of two partial parts has defined accessibility - modifier. - -2007-09-14 Marek Safar - - A fix for bug #82845 - - * class.cs (TypeContainer): Set correct resolve context for all field - initializers. - -2007-09-13 Marek Safar - - * assign.cs: Fixed a crash when field is resolved twice with an error. - - * codegen.cs: Changed InFieldInitializer to be flag. - - * anonymous.cs, ecore.cs, expression.cs: Update after - IsInFieldInitializer rename. - - * const.cs: Removed unused parameter. - - * class.cs: Changed the way how we resolve and emit field initializers. - The field initilizers have to have access to contructor block to emit - compiler generated code. - -2007-09-13 Marek Safar - - * expression.cs (MemberAccess.DoResolve): DeclSpace is broken by - generics use TypeContainer instead. - -2007-09-12 Marek Safar - - * generic.cs (TypeInferenceContext.InflateGenericArgument): Stub. - - * lambda.cs (ResolveParameters): Use more powerful - InflateGenericArgument. - - * parameters.cs: Better exception message. - -2007-09-10 Marek Safar - - * anonymous.cs (AnonymousMethodExpression.CompatibleChecks): Report - correct expression block type. - - * ecore.cs (Expression.Error_MemberLookupFailed): Made virtual. - - * expression.cs (Invocation): Extracted method group resolve to - DoResolveOverload. - -2007-09-07 Marek Safar - - * ecore.cs (Expression.MemberLookupFinal): Removed unused loc parameter. - (MethodGroupExpr.ResolveGeneric): Use existing method group instance. - - * expression.cs (MemberAccess.DoResolve): Uses generic resolver for - generic extension methods. - -2007-09-06 Marek Safar - - A fix for bug #82676 (Do I get it right now?) - * convert.cs (Binary.ResolveOperator): An interface is converted to the - object before a standard conversion is applied. - -2007-09-06 Marek Safar - - * convert.cs (ImplicitReferenceConversionCore): Reverted wrong fix of - #82676. - -2007-09-05 Marek Safar - - A fix for bug #82676 - * convert.cs (ImplicitReferenceConversionCore): Check both sides for - non-generic interface types. - -2007-09-05 Marek Safar - - A fix for bug #82690 - * ecore.cs (PropertyExpr.EmitAssign): Leave a copy does just that. - -2007-09-05 Marek Safar - - A fix for bug #82571 - * anonymous.cs (AnonymousMethod.DoCreateMethodHost): Use internal - modifier for container based methods. - -2007-09-05 Marek Safar - - A fix for bug #82676 - * convert.cs (ImplicitReferenceConversionCore): From any class-type S to - any interface-type T means to any of interface type T. - -2007-09-04 Marek Safar - - * namespace.cs: We have 2 versions of System.Core assembly. - -2007-09-04 Marek Safar - - A fix for bug #82652 - * class.cs (Class.GetClassBases): Compare types and not expressions. - -2007-09-04 Marek Safar - - A fix for bug #82620 - * expression.cs (Invocation.EmitArguments): Duplicate params arguments - actually never worked before. - (IndexerAccess): Emit prepared arguments before they are modified. - -2007-09-04 Marek Safar - - A fix for bug #82563 - * assign.cs: Revert wrong fix. - - * expression.cs (VariableReference.EmitAssign): Handle ref reference - correctly. - (ArrayAccess): Changed the way we emit compound (prepared) assignments. - Instead of ldelema/stdind we have to use temporary variables to handle - cases like String.Concat (params string[]). - -2007-08-31 Marek Safar - - * class.cs: EmitAttributes to Emit rename. - - * decl.cs (MemberCore.GetClsCompliantAttributeValue): Parent can be - null. - (MemberCore.HasClsCompliantAttribute): Don't depend on - GetClsCompliantAttributeValue execution. - -2007-08-31 Marek Safar - - * anonymous.cs: Use shorter type prefix. - - * ecore.cs (SimpleName.DoSimpleNameResolve): Use transparent identifiers - when exist. - - * expression.cs (LocalVariableReference.DoResolveBase): Don't capture - variables when probing is on. - - * statement.cs (LocaLInfo.Clone): Clone correctly resolved and - unresolved variables. - (TopLevelBlock.GetTransparentIdentifier): Default implementation doesn't - handle transparent identifiers. - -2007-08-26 Marek Safar - - * attribute.cs (IsClsCompliant): Add nullable types test. - -2007-08-24 Atsushi Enomoto - - * doc.cs : catch other types of exception than XmlException to - report CS1570. Fixed bug #82565. - -2007-08-23 Marek Safar - - * anonymous.cs (AnonymousMethodExpressin.ExplicitTypeInference): - The number of delegate parameters has to match. - (AnonymousMethodExpressin.VerifyParameterCompatibility): Handles generic - arrays. - -2007-08-21 Marek Safar - - * anonymous.cs (AnonymousMethod): Generate private anonymous method - to fix problem with private arguments. - -2007-08-20 Marek Safar - - * anonymous.cs (AnonymousTypeClass): An anonymous type can be empty. - - * decl.cs (MemberName): Ignore generic type with no generic arguments. - - * expression.cs (AnonymousTypeDeclaration): An anonymous type can be - empty. Add cloning suport. - - * roottypes.cs (GetAnonymousType): Fixed argument comparison logic. - -2007-08-20 Marek Safar - - * convert.cs, ecore.cs, expression.cs, literal.cs: Use factory method - to create EmptyCast. It handles EmptyConstantCast specialization for - constants. - -2007-08-18 Marek Safar - - * expression.cs (Binary.is_unsigned): Handle unsafe types too. - (EmitArrayArgument): One routine for array arguments. - (ArrayCreation.MakeByteBlob): Fixed an array alignment. - -2007-08-17 Marek Safar - - * cs-tokenizer.cs (GetKeyword): Handle from keyword in a different way. - -2007-08-17 Marek Safar - - * anonymous.cs: MemberLookupFinal update. - - * class.cs (ConstructorInitializer): Is expression based. - - * delegate.cs: MethodGroupExpr update. - - * ecore.cs (Error_MemberLookupFailed): Improved to report better error - messages. - (Error_MemberLookupFailed): Customizable error override. - (MethodGroupExpr): Keep queried type for later usage. - (MethodGroupExpr.OverloadResolve): Catch errors related to overload - resolve. - - * expression.cs: Error_MemberLookupFailed refactoring. - (New.DoResolve): Resolve as much as possible. - (ElementInitializer.Error_MemberLookupFailed): Object initializer - customization for invalid member types. - - * statement.cs: MethodGroupExpr update. - -2007-08-16 Marek Safar - - * modifier.cs (Check): Check all modifiers and not only accessibility - ones. - -2007-08-16 Marek Safar - - * ecore.cs (Expression.Error_ValueCannotBeConverted): Report always a - type and not an expression. - -2007-08-16 Marek Safar - - * statement.cs (Catch.Clone): Type and variable can be null. - -2007-08-16 Marek Safar - - A fix for bug #81979 - * assign.cs (Assign.Emit): Prepare arguments for string concatenation. - I am really not sure whether this is the best fix. - - * expression.cs (VariableReference.EmitAssign): Do prepare_load test - only once. - -2007-08-14 Marek Safar - - ** C# 3.0 Object and collection initializers (major re-write) - - * assign.cs (DoResolve): Initializers are not assign related. - - * codegen.cs (EmitContext.CurrentInitializerVariable): Holds a varible - used during collection or object initialization. - - * expression.cs (Error_InvalidArguments): Add initializers specific - messages. More will come later because it requires some general - refactoring. - (New.DoResolve): Better error handling for unsafe types. - (EmptyExpressionStatement): New class. - (ElementInitializer): An object initializer expression. - (CollectionElementInitializer): A collection initializer expression. - (CollectionOrObjectInitializers): A block of object or collection - initializers. - (NewInitialize): New expression with element/object initializers. - - * statement.cs: Reverted object/collection initializer hacks. - - * typemanager.cs (CSharpName): Filter __arglist type. - -2007-08-09 Marek Safar - - ** C# 3.0 Anonymous Types (update to the latest standard) - - * expression.cs (Binary.ResolveOperator): Threat all null based types - same. - (AnonymousTypeDeclaration): Renamed from AnonymousType and simplified. - (AnonymousTypeParameter): Updated. - - * anonymous.cs (CompilerGeneratedClass): Add custom name overload. - (AnonymousTypeClass): New anonymous type container. - - * class.cs (AddField): Return operation result. - - * generic.cs: Another empty TypeArguments overload. - - * roottypes.cs (AddAnonymousType, GetAnonymousType): Anonymous types - are stored at top of normal hierarchy. - - * typemanager.cs (CSharpName): Filter anonymous types. - -2007-08-09 Marek Safar - - * expression.cs (StringConcat.Append): Handle 3 and more concatenation - as single Concat call. How could we miss that :-( - -2007-08-08 Marek Safar - - * expression.cs (ArrayCreation.CloneTo): Allocate exact size. - -2007-08-07 Miguel de Icaza - - * expression.cs: Fix the previous commit, the creation of the - arguments array list needs also to be conditional on the arguments - not being null. - - * class.cs: Add a little bit of help to help narrow down problems. - - * expression.cs (ArrayCreation.CloneTo): Argument can be null, do - not try to copy in that case. - - * driver.cs: When building SMCS, include a new different set of - default assemblies here. Do this here so we can control whether - to include the default assemblies with /noconfig. - -2007-08-03 Marek Safar - - A fix for bug #81979 - * expression.cs (TypeOf.GetAttributableValue): Check for type arguments - only. - -2007-08-03 Marek Safar - - A fix for bug #82300 - - * anonymous.cs (AnonymousContainer.Define): Don't define anything when - we are in probing scope. - -2007-08-03 Marek Safar - - A fix for bug #82301 - - * statement.cs (Catch.CloneTo): Clone blocks in the right order. - (Statement.CloneTo): Clone and not map children blocks. - -2007-08-03 Marek Safar - - A fix for bug #82299 - - * expression.cs (LocalVariableReference.CloneTo): Remap local info - variable too. - - * statement.cs (Statement.CloneTo): Clone variables before statements - to allow remaping of local variables. - -2007-08-03 Marek Safar - - A fix for bug #82296 - - * anonymous.cs, - * report.cs: Log crash details for future clone problems. - - * statement.cs (Return.Clone): Don't clone non-existent expression. - -2007-08-03 Raja R Harinath - - * class.cs (TypeContainer.AddBasesForPart): Make virtual. - (Class.AddBasesForPart): Move CS0537 check here from ... - * cs-parser.jay (class_declaration): ... here. Move calling of - 'AddBasesForPart' to ... - (class_bases): ... here. - (struct_declaration, interface_declaration): Update to changes. - -2007-08-02 Marek Safar - - A fix for bug #81923 - - * statement.cs (Using.ResolveLocalVariableDecls): Only non-user implicit - conversion is allowed. - -2007-08-02 Marek Safar - - A fix for bug #81564 - - * ecore.cs (EventExpr): Add IsBase handling. - - * expression.cs (BaseAccess.CommonResolve): Events can use base accessor - too. - -2007-08-02 Raja R Harinath - - Reduce some differences between cs-parser.jay in mcs/ and gmcs/. - * cs-parser.jay: Some whitespace cleanups. - (current_delegate): New. - (type_name): New. - (struct_declaration): Make similar to gmcs/cs-parser.jay -- add - a dummy code block, and use 'type_name' instead of 'member_name'. - (interface_declaration, class_declaration): Likewise. - (delegate_declaration): Likewise. Rearrange slightly and use - 'current_delegate'. - * cs-tokenizer.cs (handle_where): Rename from handle_constraints. - (GetKeyword): Update to change. Use '!foo' instead of 'foo == false'. - -2007-08-02 Marek Safar - - A fix for bug #82039 - - * ecore.cs (TypeLookup.GetSignatureForError): Use name when type is not - available. - - * typemanager.cs (CSharpName): Split to string overload. - -2007-08-02 Marek Safar - - * expression.cs, - * report.cs: Updated warning CS0472. - -2007-08-01 Marek Safar - - A fix for bug #82181 - * cs-parser.jay, - * cs-tokenizer.cs: Ignore partial keyword inside block expression. - -2007-08-01 Marek Safar - - A fix for bug #82277 - * statememnt.cs (Block.Clone): Don't clone explicit blocks twice. - -2007-08-01 Marek Safar - - ** C# 3.0 Type Inference (major bits are working) - - * anonymous.cs (AnonymousMethodExpression): Removed refactored fields. - (.ImplicitStandardConversionExists): Uses compatible. - (.ExplicitTypeInference): Infers type arguments based on explicit arguments - (.InferReturnType): New method. - (.Compatible): Refactored. - (.ResolveParameters): Uses factory to create resolved parameters. - (.CompatibleMethod): Add probing mode support. - (AnonymousContainer): Removed unused fields. Split Define and Resolve to - clearly distinguish between 2 different operations. - (LambdaMethod): Moved to lambda.cs. - (AnonymousMethod): Removed unused fields and methods. - (AnonymousDelegate): Simplified. - - * codegen.cs (ResolveTopBlock): Updated renamed Resolve to Define. - - * convert. cs (ImplicitConversionStandard): Compatible works differently. - - * delegate.cs (Delegate): New mehods to reduce code duplication. - (.GetConstructor): New method. - (.GetInvokeMethod): New method. - (DelegateCreation): Updated. - - * ecore.cs (ResolveOverloadExtensions): Don't crash when extension method - does not exist. - (OverloadResolve): Made probing little bit faster. - - * expression.cs (ParameterReference.DoResolveLValue): Reference can be null - when probing is on. - - * generic.cs (TypeInferenceContext): Dummy implementation. - - * iterators.cs: Updated after Resolve/Define rename. - - * lambda.cs (LambdaExpression) - (.ResolveParameters): Handles both type of arguments and type inference too. - - * parameter.cs (ImplicitLambdaParameter.Resolve): Sanity check. - (InflateTypes): Updated. - - * support.cs (InflateTypes): Changed signature and updated. - - * typemanager.cs (LookupMemberCache): Better dynamic type check. - (MemberLookup_FindMembers): More MS tricks. - (GetParameterData): Ditto. - (GetDelegateParameters): Uses quick path for dynamic types. - -2007-08-01 Marek Safar - - * class.cs (MethodData.Define): EmitContext is required for generic stuff - only. - -2007-07-31 Marek Safar - - * statement.cs (ProcessParameters): Don't crash when parameters have wrong - syntax. - -2007-07-26 Jb Evain - - * typemanager.cs (TypeManager.GetConstructor): Add a method overload - which takes a boolean 'report_errors', similar to the GetMethod. - (InitCodeHelpers): StructLayoutAttribute.ctor(int16) is not visible - in .net 2.1, do not report errors here. - - * typemanager.cs (TypeManager.InitCoreTypes): System.ArgIterator, - System.Runtime.CompilerServices.RequiredAttributeAttribute and - System.Runtime.CompilerServices.TypeForwardedToAttribute are internal - in .net 2.1. - - * typemanager.cs (TypeManager.InitCoreTypes): Move the resolution - of the type InternalsVisibleToAttribute before the first call - to CoreLookupType which is allowed to fail (third boolean parameter - to true). Because, during the resolution for a type that is not - immediately found, we try to check if the type is not defined in - a friend assembly, and to do so, we need the - InternalVisibleToAttribute. - -2007-07-23 Miguel de Icaza - - * expression.cs (Binary): Add support for the brain-dead CSC 2.x - feature that allows structs to be compared against null and inline - the result as true or false. - - Notice that the same code is not permitted inside a generic block - of code that would do: - - class Foo where T : struct { - bool Eval (T x) - { - return x == null; - } - } - - It is only allowed if the type of T is not bound (no where - clause). In my opinion, this CSC 2 behavior is broken but people - seem to be using it (IronRuby does, a few bug reports on bugzilla - have it and some people have complained about it). - - All of the users that depend on this behavior have code that is - very likely broken. - - * report.cs (Warning, Error): make these take object arguments, - not strings, as that allows us to take advantage of Format. - -2007-07-20 William Holmes - - * decl.cs: Changed MemberName.CountTypeArguments to also check the - Left member variable for the Count. - * doc.cs: Changed DocUtil.GetMethodDocCommentName to call - MemberName.CountTypeArguments to avoid a NRE. - - This code is contributed under the MIT X11 license - -2007-07-18 Marek Safar - - * cs-tokenizer.cs: Improved lambda parsing and removed old code. - -2007-07-18 Atsushi Enomoto - - * doc.cs : generic method arguments are written as ``x while generic - type arguments are `x. Combined with the previous change, fixed bug - #79706. - -2007-07-18 Raja R Harinath - - Fix #82120 - * expression.cs (Binary.ResolveOperator): When converting - 'a + (- b)' to 'a - b', ensure that the unary '-' is discarded. - -2007-07-18 Atsushi Enomoto - - * doc.cs : when T: or whatever x: is specified, it does not really - check the doc comment's syntax correctness. Fixed bug #82006. - -2007-07-18 Marek Safar - - * anonymous.cs (AnonymouseMethodExpression): Refactored to work with - LambdaExpression better. - - * cs-tokenizer.cs: Changed a way how we detect lambda parameters. - - * driver.cs (LambdaTypeParseTest): Removed, tested method is gone. - - * ecore.cs (Expression.MemberLookupFailed): Don't show currect context - as it can be generated. - - * expression.cs (Invocation.Error_InvalidArguments): Show correct - modifiers. - - * lambda.cs (LambdaExpression): Refactored to share same code with - AnonymousMethodExpression. - -2007-07-17 Marek Safar - - * anonymous.cs (MakeName): Include host name for easier debugging. - (LambdaMethod): New class for lambda spcecific stuff. - - * attribute.cs: Set EmitContext return type. - - * class.cs: Set EmitContext return type. - - * codegen.cs (EmitContext): Return type cannot be null to stop messing - with null/void meaning. - - * iterators.cs (ContainerType): Implemented. - - * rootcontext.cs: Set value of TypeManager.bool_type at early stage. - - * statement.cs (Return): Updated to lambda expressions. - (Block.CloneTo): Parent can be null. - -2007-07-13 Marek Safar - - A fix for bug #81917 - * attribute.cs (AttributeTester.GetFixedBuffer): More robust testing. - - * class.cs (FixedField): Check whether field is in unsafe scope. - - * ecore.cs (FieldExpr.DoResolve): Create fixed buffer expression here. - (FieldExpr.Emit): Fixed buffers cannot be volatile. - - * expression.cs (ElementAccess.Resolve): Move fixed buffers resolve to - FieldExpr. - - * statement.cs (Fixed.Resolve): Simplified fixed buffers. - -2007-07-13 Marek Safar - - * cs-tokenizer.cs, class.cs, decl.cs, driver.cs, namespace.cs, - rootcontext.cs, expression.cs, statement.cs: Updated to use WarningLevel - from Report class. - -2007-07-13 Marek Safar - - * ecore.cs (FieldExpr.AddressOf): Less confusing warning message. - -2007-07-13 Marek Safar - - * anonymous.cs (AnonymousMethodExpression): Parameters are r/o. - (AnonymousContainer.ResolveNoDefine): Another ec to aec flag conversion. - - * codegen.cs(EmitContext): Add ProbingMode flag. - - * delegate.cs (DelegateInvocation): Set few instance variables as r/o. - - * driver.cs: For now set both warning values. - - * ecore.cs (SimpleName): Name is readonly. - (MethodGroup.OverloadResolve): One quick path for probing. - - * expression.cs (Unary): Set Oper r/o. - (Binary): Set Oper r/o. - (ParameterReference): Set few instance variables as r/o. - (ParameterReference.DoResolveBase): Don't capture aruments when - the probing is on. - (Invocation.CloneTo): Fixed typo, looks easy, yeah. - (Arglist): arguments are private. - (SizeOf): type is private and r/o. - (MemberAccess): arguments are private. - - * report.cs: Enhanced reporting on/off capabilities. - - * lambda.cs: Uses ec.IsInProbingMode. - (ContextualReturn): Derives from return. - - * rootcontext.cs: For now set both warning values. - - * statement.cs (CloneContext.RemapBlockCopy): Remaps block to cloned - copy if one exists. - (Return.Resolve): Don't die immediately. - (Block.Resolve): Speed-up probing. - (Block.CloneTo): Clone only child blocks. - -Fri Jul 13 11:19:28 CEST 2007 Paolo Molaro - - * iterators.cs: reverted Miguel's latest change (r81925) as it - breaks the build in System. - -2007-07-13 Miguel de Icaza - - * iterators.cs (Yield.CheckContext): Check for the iterator type - also here as we can call into Yield even in codepaths that are not - directly checked by - (MethodOrOperator is the only path that was checked). - - In addition to the standard check, use a more specific check for - constructors to report a more verbose error. - -2007-07-12 Miguel de Icaza - - * ecore.cs (FieldExpr.AddressOf): Do not stop processing here, - report the warning and continue - - * statement.cs (Using.EmitLocalVariableDecls): We were leaving - values on the stack on the call to Emit. Use EmitStatement if - possible, or using Emit + Pop if not possible. Fixes #82064 - -2007-07-12 Raja R Harinath - - * expression.cs (Invocation.IsApplicable): Reorganize slightly to - avoid try...finally in some cases. - -2007-07-10 Marek Safar - - * attribute.cs (Attribute.ResolveConstructor): Uses method group. - - * class.cs (ConstructorInitializer.Resolve): Use and keep method group - instead of method. Re-use standard error handling. - (ConstructorInitializer.Emit): Simplified. - - * delegate.cs: Updated after Invocation.EmitCall change. - - * ecore.cs (GetOperatorTrueOrFalse): Uses MethodGroupExpr only. - (SimpleName.SimpleNameResolve): Set and reset in_transit flag correctly. - (ExtensionMethodGroupExpr): Refactored to use same OverloadResolve - method and don't permanently changing input arguments. - (MethodGroupExpr): Introduced resolved best_candidate, when method group - is resolved it has one of the candidates is the best one which is later - used to emit. Removed a few unused method. - (MethodGroupExpr.MakeUnionSet): Moved from Invocation, it belongs here. - - * expression.cs (StaticCallExpr.MakeSimpleCall): Uses method group. - (Binary.ResolveOperator): Ditto. - (ConditionalLogicalOperator.DoResolve): Ditto. - (Invocation): Uses method group. - (Invocation.DoResolve): Simplified. - (Invocation.EmitCall): Removed useless is_static. - (Invocation.Emit): Delegate to method group. - (Invocation.EmitStatement): Simplified. - (New): Uses method group. - (MemberAccess.DoResolve): Don't destroy original expression. - - * statement.cs (ForEach.Resolve): Use null for no method arguments. - -2007-07-04 Marek Safar - - * ecore.cs (VarExpr.DoResolveLValue): More restriction checks. - - * anonymous.cs, - * lambda.cs: Add custom error message type. - -2007-07-03 Marek Safar - - * lambda.cs: Simplified little bit. - - * parameter.cs: Introduced ImplicitLambdaParameter. - (Parameters.CreateFullyResolved): New factory instead of ctor. - - * anonymous.cs, - * class.cs, - * delegate.cs: Updated parameter creation. - -2007-07-03 Marek Safar - - * ecore.cs (SimpleName.GetSignatureForError): Display correctly generic - arguments. - - * generic.cs: Synchronized with gmcs. - -2007-07-03 Marek Safar - - * class.cs (Indexer): Check return type as soon as possible. - - * cs-parser.jay: Initialize implicit_value_parameter_type for interface - members too. - - * ecore.cs (VarExpr.DoResolveLValue): Set eclass value. - - * expression.cs (Invocation.Error_InvalidArguments): Show type only. - - * parameter.cs (Parameter): Use expression type when it is available. - - * support.cs (ReflectionParameters.ParameterDesc): Show an extension - method modifier for the first parameter only. - -2007-06-24 Marek Safar - - A fix for bug #81938 - * typemanager.cs (ChangeType): Fixed couple of char conversions. - - * constant.cs: Tide up an exception message. - -2007-06-22 Marek Safar - - * ecore.cs (SimpleName.DoSimpleNameResolve): Better error reporting when - an uninitialized variable is used. - - * expression.cs (LocalVariableReference.DoResolve): Ditto. - -2007-06-22 Marek Safar - - * ecore.cs (SimpleName.TypeOrNamespaceNotFound): Allow to override type - not found error handling. - - * expression.cs (ArrayCreation): Removed redundant fields and little bit - simplified. - (ArrayCreation.ResolveArrayElement): To be ready to customization. - (ArrayCreation.DoResolve): Simplified. - (ImplicitlyTypedArrayCreation.DoResolve): Implicitly typed arrays have - its own resolve process. - (ImplicitlyTypedArrayCreation.ResolveArrayElement): Conversion magic. - -2007-06-20 Marek Safar - - * namespace.cs (NamespaceEntry.Error_AmbiguousTypeReference): Print - more error details. - -2007-06-20 Marek Safar - - * cs-tokenizer.cs: Removed var related stuff. - - * ecore.cs (Expression.ResolveAsContextualType): Introduced new method. - (VarExpr): Changed to derive from SimpleName. VarExpr now behaves as - a type and a keyword at same time. - - * decl.cs (MembeName.GetTypeExpression): Create VarExpr when type name - matches to "var". - - * expression.cs (ImplicitlyTypedArrayCreation): New empty class for - implicitly typed arrays, more changes will follow. - - * statement.cs (LocalInfo.Resolve): Resolve type as contextual type. - -2007-06-19 Marek Safar - - * ecore.cs (VarExpr): Removed Handled field. - - * statement.cs (Using.ResolveLocalVariableDecls): Refactored to use - build-in assign functionality. - (ForEach.Resolve): Removed all implicitly typed local variable code and - simplified. - (ArrayForeach.Resolve): Infer implicitly typed local variable here. - (CollectionForeach.Resolve): Infer implicitly typed local variable here. - -2007-06-18 Marek Safar - - * assign.cs: Removed implicitly typed local variable check. - - * expression.cs (LocalVariableReference.DoResolve): Add check for self - referencing implicitly typed local variable. - (LocalVariableReference.DoResolveLValue): Infer implicitly typed local - variable here. - - * statement.cs (Fixed): Removed unsupported implicitly typed local - variable code. - -2007-06-15 Marek Safar - - * decl.cs (MemberName): Moved all Unbound stuff to parser. - -2007-06-14 Marek Safar - - A fix for bugs #81855 and #76274 - * attribute.cs (AttachTo): Always set owner for global attributes to - prefined owner. - - * ecore.cs (Error_TypeDoesNotContainDefinition): A type location can be - usefull too. - - * cs-parser.jay: Assembly and module attributes must precede all other - elements except using clauses and extern alias declarations. - -2007-06-13 Marek Safar - - A fix for bug #81748 - * cs-tokenizer.cs, - * expression.cs: More checks for non ISO-1 features. - -2007-06-12 Marek Safar - - A fix for bug #81807 - * statement.cs(Switch.TableSwitchEmit): Define null label when it's not - present inside switch statement and it is required by nullable check. - -2007-06-12 Marek Safar - - A fix for bug #81840 - * ecore.cs (SimpleName.ResolveAsTypeStep): Look for non-generic type - when type matching fails. - - * namespace.cs: Tiny error message change. - -2007-06-12 Marek Safar - - * decl.cs (CheckAbstractAndExtern): Moved to MemberCore for easier error - reporting. Added automatic property check. - - * class.cs: Updated after CheckAbstractAndExtern relocation. - (AEventPropertyAccessor.GetSignatureForError): Customized. - -2007-06-11 Marek Safar - - * class.cs (DefineBaseTypes): Base type can be undefined. - - * ecore.cs (TypeLookup): Minor refactoring. - (DoResolveAsTypeStep): Removed redundant check. - - * namespace.cs (Lookup): Removed redundant check. - - * rootcontext.cs (BootstrapCorlib_ResolveType): Uses normal - ResolveAsTypeTerminal step. - (BootstrapCorlib_*): Simplified. - (PopulateCoreType): Core types can be now external. - -2007-06-07 Marek Safar - - * anonymous.cs (VerifyExplicitParameterCompatibility): Add flag to do - verification only. - (InferTypeArguments): Infers anonymous expression type arguments. - (Compatible): Split to Compatible and InferTypeArguments. - - * lambda.cs: Updated. - -2007-06-08 Marek Safar - - * anonymous.cs (AnonymousContainer): Marked as compiler generated. - -2007-06-07 Raja R Harinath - - Fix #80477, cs0135-2.cs, cs0135-3.cs - * statement.cs (ToplevelBlock.ProcessParameters): Add parameter - names to the "known" variables list. - (Block.CheckInvariantMeaningInBlock): Handle the fact the - parameter names are also "known". - (Block.CheckError136): Remove. - (ExplicitBlock.CloneTo): New. Set 'known_variables' in target to - null. - -2007-06-07 Marek Safar - - * ecore.cs (MethodGroupExpr.OverloadResolve): Print full method definition. - -2007-06-06 Marek Safar - - * ecore.cs (SimpleName.Emit): Emitting unresolved simple name is - internal error not an user error. - - * expression.cs (IsApplicable): Refactored to make debugging easier. - - * support.cs: More tricks for non-mono runtimes. - - * typemanager.cs (CoreLookupType): Made public. - (InitSystemCore): All linq specific stuff moved to linq.cs - -2007-06-05 Marek Safar - - * typemanager.cs (CSharpSignature): One more missing build-in types - replacement. - More tricks for non-mono runtime. - -2007-06-05 Raja R Harinath - - * statement.cs (Block.CheckError136_InParents): Remove. - (Block.AddVariable): Use GetParameterInfo instead. - (ToplevelBlock.ProcessArguments): Likewise. - -2007-06-04 Raja R Harinath - - * statement.cs (ToplevelBlock.CloneTo): New. Copy over parameter - information too. - (ToplevelBlock.GetParameterInfo): Split out of ... - (ToplevelBlock.GetParameterRefernce): ... this. - (ToplevelBlock.ParameterMap): Remove. - * expression.cs (ParameterReference): Update to use - ToplevelParameterInfo. - - * statement.cs (ToplevelBlock.ProcessParameters): Workaround some - regression. - - * flowanalysis.cs (FlowBranching.CheckOutParameters): Move ... - * statement.cs (ToplevelBlock.CheckOutParameters): ... here. - - * statement.cs (ToplevelBlock.ResolveMeta): Move CS0136 checks ... - (ToplevelBlock.ProcessParameters) ... here. - (ToplevelBlock..ctor): Invoke it. - - * statement.cs (ToplevelBlock.ResolveMeta): Add sanity checks for - new parameters. - - * statement.cs (IKnownVariable): New interface. - (LocalInfo): Implement it. - (ToplevelParameterInfo): New class. - (ExplicitBlock.AddKnownVariable): Use IKnownVariable. - (ExplicitBlock.GetKnownVariable): Likewise. Rename from - GetKnownVariableInfo. - -2007-06-03 Raja R Harinath - - Partly speed up CS0136 error checks. - * statement.cs (ExplicitBlock.GetKnownVariableInfo): Remove - 'recurse' parameter. - (Block.DoCheckError136): Only check errors in parameters. Move - local variable checks ... - (Block.AddVariable): ... here, and ... - (ToplevelBlock.ResolveMeta): ... here. - -2007-06-02 Raja R Harinath - - * statement.cs (Block.IsChildOf): Remove. - - * statement.cs (Statement.Clone): Move special case code ... - (Block.CloneTo): ... here. - -2007-05-29 Raja R Harinath - - * statement.cs (ToplevelBlock.container): Remove field. It's - redundant with 'Parent'. - (ToplevelBlock.ContainerBlock): Remove accessor. - (ToplevelBlock..ctor): Update to changes. Register anonymous - child with parent here, ... - * cs-parser.jay (end_anonymous): ... not here. Don't modify - current_block. - (start_anonymous): Don't save current_block. - (top_current_block): Remove. - - * statement.cs (Block.Flags): Remove IsExplicit and IsToplevel flags. - (Block.Resolve): Update to changes. - (Block..ctor): Move setting of "correct" 'Toplevel' - and 'Explicit' fields to ... - (ExplicitBlock..ctor, ToplevelBlock..ctor): ... here. - -2007-05-27 Raja R Harinath - - Kill Block.Implicit - * statement.cs (Block.Implicit): Remove. - (Block): Update to changes. - * flowanalysis.cs: Likewise. - - Mildly speed up CheckInvariantMeaningInBlock - * statement.cs (ExplicitBlock.AddKnownVariable): Move here from Block. - Recursively call AddKnownVariable to all enclosing blocks. - (ExplicitBlock.GetKnownVariableInfo): Move here from Block. - Remove recursive calls. - (Block): Update to changes. - - New ExplicitBlock invariants - * statement.cs (Block.Explicit): New field. It points to the - immediately enclosing non-implicit block. - (Block..ctor): Maintain the invariant. - * cs-parser.jay: Take advantage of invariant. - - Introduce ExplicitBlock - * statement.cs (ExplicitBlock): New. - (ToplevelBlock): Derive from it. - (Block.Flags.IsExplicit): Rename from '...Implicit' and invert - sense of flag. - (Block.Implicit): Update to changes. - * cs-parser.jay: Update to changes. - - Remove unused field - * codegen.cs (EmitContext.IsLastStatement): Remove. - * statement.cs (Block.DoEmit): Update to changes. - -2007-05-25 Raja R Harinath - - * cs-parser.jay: Use 'start_block' and 'end_block' rather than - modifying current_block directly. - -2007-05-23 Scott Peterson - - * class.cs: Implemented automatic properties (C# 3.0) - Thanks to Marek for the help. - -2007-05-23 Raja R Harinath - - * flowanalysis.cs (VariableInfo.SetAssigned): When noting a - variable as assigned, note also that all its components are - assigned too. - (MyBitVector.SetRange): New. Function to set multiple bits to true. - -2007-05-19 Marek Safar - - * anonymous.cs, class.cs: Emit Compiler generated attribute when - member is marked as compiler generated. - - * decl.cs (MemberCore): Refactored ModFlags into property. - - * modifiers.cs: Add new modifier (COMPILER_GENERATED). - (Check): Check only accessibility modifiers. - -2007-05-18 Raja R Harinath - - Track all assignable slots in one bit array - * statement.cs (ToplevelBlock.ParameterMap): Convert into array. - (ToplevelBlock.ResolveMeta): Don't create a VariableMap. Move - logic from VariableMap constructor here. Use the same 'offset' - variable that's later used for computing offsets of local - variables. - * flowanalysis.cs (UsageVector.parameters): Remove. - (UsageVector): Update to changes. - (VariableMap): Remove. - - Avoid creating ParameterMap in every block - * statement.cs (Block.ParameterMap): Move ... - (ToplevelBlock.ParameterMap): ... here. - (ToplevelBlock.ResolveMeta): Create VariableMap for parameters - only once. - * flowanalysis.cs (FlowBranching.param_map): Remove. - (FlowBranching.UsageVector): Update to changes. - (FlowBranchingToplevel.CheckOutParameters): Likewise. - - * statement.cs (Block.CloneTo): Clone Toplevel field too. - - * expression.cs (ParameterReference): Distinguish between block - where parameter was referenced and declared. - -2007-05-18 Marek Safar - - * flowanalysis.cs, statement.cs: Put back improved error handling. - -2007-05-15 Scott Peterson - - * assign.cs: - * expression.cs: - Imporved object and collection initialization (C# 3.0). - -2007-05-15 Marek Safar - - A fix for bug #81380 - * expression.cs (Is.DoResolve): Only value types have constant `is' - behaviour. - -2007-05-15 Raja R Harinath - - * statement.cs (ToplevelBlock.child): Remove. - -2007-05-15 Raja R Harinath - - Rationalize ResolveMeta: refactoring - (Block.ResolveMeta): Remove wrong or superfluous comments. Carve - out constant handling code into ... - (Block.DoResolveConstants): ... this. - - Rationalize ResolveMeta: kill local_map - * statement.cs (Block.local_map, Block.LocalMap): Remove. - (Block.AssignableSlots): New. - (Block.ResolveMeta): Make protected. Don't create a VariableMap - for locals -- move code from VariableMap here. Avoid unnecessary - allocations. - * flowanalysis.cs (FlowBranching.local_map): Remove. - (FlowBranching..ctor): Use Block.AssignableSlots. - (VariableMap): Remove unused constructors. - -2007-05-11 Raja R Harinath - - * Makefile [PROFILE=net_2_0_bootstrap]: Add special-case rules. - -2007-05-11 Marek Safar - - * typemanager.cs (IsFriendAssembly): Should not be called for building - assembly. - -2007-05-09 Marek Safar - - * literal.cs (NullConstant): Print null in all cases. - - * expression.cs (Binary.ResolveOperator): Implemented delegate - comparison based on C# 2.0 changes. - -2007-04-28 Scott Peterson - - This code is contributed under the MIT X11 license - - The following enables support for several C# 3.0 language features: - - * cs-tokenizer.cs: Added support for the "var" keyword. - - * ecore.cs: Refactored TypeLookupExpression.DoResolveAsTypeStep(). - Added VarExpr class to facilitate type inferencing. - - * class.cs: Added IDictionary field AnonymousTypes to TypeContainer - to support anonymous types. - - * assign.cs: Added support for type inferencing and initialization. - - * anonymous.cs: Added AnonymousClass class to enable anonymous types. - - * expression.cs: Added implicit array support to ArrayCreation. - Added 5 types and 1 interface: - - IInitializable Implementing classes can inject initializing - statements after object instantiation. - - Initializer Stores data for object initialization. - - AnonymousType An expression for anonymous types. - - AnonymousTypeParameter Stores data about an anonymous type's field. - - NewInitialize An expression for object initialization. - - CollectionInitialize An expression for collection initialization. - - * statement.cs: Added "var" keyword support to the foreach, using, and fixed - statements. - -2007-05-06 Marek Safar - - A fix for bug #81500 - * cs-tokenizer.cs: Add special handling for coalescing operator. - -2007-05-06 Marek Safar - - A fix for bug #81529 - * attribute.cs (GetAttributeUsage): AttributeUsage attribute inherits - its value from base class until it is redefined. - -2007-05-02 Raja R Harinath - - Fix regression in cs0631-3.cs - * cs-parser.jay (operator_declarator): Add opt_attributes to error - fallback. Make error fallback catch more cases. - -2007-05-01 Miguel de Icaza - - * cs-parser.jay: Allow parameters in operator declarations to have - attributes. - -2007-04-27 Miguel de Icaza - - * statement.cs (If.CloneTo): Only clone the FalseStatement if it - exists. - - * lambda.cs (ContextualReturn.Resolve): An expression is valid - inside the ContextualReturn, it does not have to be an - ExpressionStatement. - -2007-04-24 Miguel de Icaza - - * lambda.cs (ContextualReturn.Resolve): if the return type is not - set, set it. - -2007-04-23 Miguel de Icaza - - * anonymous.cs (AnonymousContainer): split the virtual Resolve - method in two methods: ResolveNoDefine and Resolve. - - ResolveNoDefine will stop just after ResolveTopBlock has been - called. - - Resolve will then continue by creating a method and issuing the - call to method.Define (). - - (AnonymousMethod): Split and implement the new Resolve and - ResolveNoDefine as well. - - * lambda.cs (LambdaExpression): Split the anonymous method - resolution code into a separate routine (CoreCompatibilityTest) - from DoCompatibleTest. - - (LambdaExpression.TryBuild): New method, this method tries to - build the LambdaExpression with the given set of types to be used - as the types for the various parameters of the lambda expression. - - If the compilation succeed with the given types, the infered type - of the Anonymous method is returned, otherwise null is returned. - -2007-04-23 Marek Safar - - A fix for bug #81414 - * delegate.cs: Better fix, moved ApplyAttributes from Define to Emit. - -2007-04-22 Miguel de Icaza - - * cs-tokenizer.cs: Change various identifiers here from the - camelCasing to the recommended Linux-like style for instance - variables from the Coding Guidelines. - -2007-04-19 Martin Baulig - - * convert.cs - (Convert.ImplicitReferenceConversionCore): Allow conversions from - System.Enum to System.ValueType. - -2007-04-13 Martin Baulig - - Rewrote implicit reference conversions. We need to distinguish - between implicit reference conversions (13.1.4) and implicit - boxing conversions (13.1.5). - - According to the spec, there's an an implicit conversion - "From a one-dimensional array-type S[] to IList and base - interfaces of this interface, provided there is an implicit - reference conversion from S to T." Note that this does not - include boxing conversions. - - * convert.cs - (Convert.ImplicitTypeParameterBoxingConversion): New method. - (Convert.ImplicitReferenceConversion): Split into - ImplicitReferenceConversionCore() and - ImplicitBoxingConversionExist(). - (Convert.ImplicitReferenceConversionExists): Use the new - ImplicitReferenceConversionCore() and ImplicitBoxingConversionExists(). - -2007-04-12 Martin Baulig - - * convert.cs (Convert.ImplicitReferenceConversion): Move the - `TypeManager.null_type' checks up to the top of the method. - -2007-04-11 Marek Safar - - A fix for bug #81350 - * class.cs, decl.cs, ecore.cs, namespace.cs: The optimization for private - extension methods. - -2007-04-11 Martin Baulig - - * statement.cs (Foreach.CollectionForeach.ProbeCollectionType): - Use `TypeManager.GetInterfaces(t)' rather than `t.GetInterfaces()' - to make this work for generic classes; fixes #79561. - -2007-04-11 Martin Baulig - - * expression.cs (As): Add support for nullable types; fixes #79371. - -2007-04-11 Martin Baulig - - * doc.cs (DocUtil.GetSignatureForDoc): Don't crash if - `type.FullName' is null; fixes #80243. - -2007-04-11 Martin Baulig - - * expression.cs (Invocation.IsApplicable): Don't modify the method - if type inference succeeded, but the method was not applicable. - Fixes #81250. - -2007-04-10 Marek Safar - - A fix for bug #81324 - * namespace.cs (Namespace.LookupExtensionMethod): Always inspect both - internal and external namespaces containers. - -2007-04-10 Martin Baulig - - * delegate.cs (DelegateCreation.ResolveMethodGroupExpr): Use - TypeManager.DropGenericMethodArguments() so we also call - IMethodData.SetMemberIsUsed() for generic methods. Fixes #80357. - -2007-04-10 Martin Baulig - - * iterators.cs (Iterator.CreateIterator): Don't crash if - `method.ReturnType' is null. This happens if something went wrong - while resolving that typ (we already reported an error in this case). - -2007-04-10 Martin Baulig - - * expression.cs (New.DoResolve): Don't call CheckComImport() on - generic interfaces; report the CS0144 directly. - -2007-04-10 Martin Baulig - - * ecore.cs (MemberExpr.ResolveMemberExpr): If `left' is a - `TypeExpr', call ResolveAsTypeTerminal() on it; fixes #81180. - -2007-04-10 Martin Baulig - - * expression.cs (New.DoEmitTypeParameter): Fix #81109. - -2007-04-09 Raja R Harinath - - A better fix - * flowanalysis.cs (UsageVector.MergeChild): Handle child.Block == null. - * statement.cs: Use KillFlowBranching only in ResolveUnreachable. - - Fix #81338 - * statement.cs (For.Resolve): If resolution fails, use - KillFlowBranching. - -2007-04-08 Marek Safar - - * anonymous.cs (MakeName): Make faster and zero-based. - (VerifyExplicitParameterCompatibility): Back to mode where generic - parameter is ignored. - (AnonymousMethodMethod.Emit): Decorate method as compiler generated. - - * class.cs (EmitType): Method can emit another new method. - - * cs-tokenizer.cs (IsLinqEnabled): Fixes static cctor race. - - * driver.cs: Updated. - - * lambda.cs: Reuse predefined empty parameters. - - * parameter.cs: Updated - - * support.cs: Implemented InflateTypes. - - * typemanager.cs (GetFullName): Don't use FullName as it can be null. - (InitSystemCore): Introduced to isolate 3.0 dependencies. - -2007-04-03 Martin Baulig - - Fix #80632. - - * statement.cs (Foreach.CollectionForeach.TryType): Use a custom - version of TypeManager.IsOverride() which also works with generic - types. - -2007-04-03 Martin Baulig - - Fix #81044. - - * convert.cs - (Convert.ExplicitReferenceConversion): We need to cast when - converting from IList to S[]. - -2007-04-01 Marek Safar - - * decl.cs (FindExtensionMethods): Consider all candidates with same name - at this level. - - * expression.cs (MemberAccess.DoResolve): Cache resolved expression. - -2007-03-31 Marek Safar - - * anonymous.cs (AnonymousMethodExpression.Compatible): Handles both - argument and return type inferring. - - * codegen.cs (InferReturnType): Flag whether return can be inferred. - (ReturnType): Turned to property. - - * statement.cs (Return): Implemented return type inferring. - - * support.cs (ReflectionParameters): Use local types if possible. - -2007-03-30 Raja R Harinath - - * flowanalysis.cs (FlowBranching.Reachability): Remove. - (FlowBranching.UsageVector): Update to changes. - - Prepare to kill 'Reachability' - * flowanalysis.cs (UsageVector): Remove 'Reachability' from - argument of constructor. - -2007-03-29 Raja R Harinath - - Prepare to kill 'Reachability' - * flowanalysis.cs (UsageVector.is_unreachable): New. - (UsageVector): Update to maintain 'is_unreachable' in parallel to - 'reachability', and verify they're consistent. - - Fix #81121 - * expression.cs (New.EmitStatement): Handle type parameters here too. - -2007-03-29 Martin Baulig - - Fix #79148. - - * anonymous.cs - (ScopeInfo.ctor): Use `Modifiers.PUBLIC' if we're a nested - CompilerGeneratedClass. - (ScopeInfo.EmitScopeInstance): Make this protected. - (CapturedVariable.EmitInstance): Use `Ldarg_0' if - `ec.CurrentAnonymousMethod.Scope == Scope'. - - * statement.cs (Block.ScopeInfo): Make this a property. - -2007-03-27 Raja R Harinath - - Prepare to kill 'Reachability' - * flowanalysis.cs (FlowBranching.Reachability): Make class private. - (FlowBranching.UsageVector.Reachability): Remove property. - (FlowBranching.UsageVector.IsUnreachable): New property. - (FlowBranching.UsageVector.ResetBarrier): New. - (FlowBranching.UsageVector, FlowBranchingLabeled): Update to changes. - * codegen.cs, statement.cs: Update to changes. - -2007-03-27 Martin Baulig - - Fix #81209. - - * decl.cs - (DeclSpace.LookupNestedTypeInHierarchy): Correctly handle nested - generic types. - -2007-03-26 Raja R Harinath - - * flowanalysis.cs (FlowBranching.Reachability): Use a boolean - instead of TriState. Remove all mention of TriState. - - * flowanalysis.cs (FlowBranching.Reachability): Prepare to be - replaced by a boolean. Add boolean 'is_unreachable' field, check - and maintain invariants. - -2007-03-25 Marek Safar - - * anonymous.cs: Restored checks disabled for uninflated anonymous methods. - -2007-03-25 Marek Safar - - * expression.cs: Stop using obsolete 2.0 opcodes. - -2007-03-25 Marek Safar - - * enum.cs (EnumMember.Define): Fixed regression and slowdown caused by - one of the latests Martin's fixes. - -2007-03-23 Miguel de Icaza - - * expression.cs: On BigEndian systems, swap the bytes, temporary - solution until we get a new bitconverter class. - -2007-03-23 Martin Baulig - - Fix #81158. - - * decl.cs (MemberCache.AddMembers): Add generic methods both as - "Method" and "Method`1". Normally, a cache lookup is done on the - "Method" form (ie. without the generic arity), but this one makes - lookups on the full form work as well. - -2007-03-22 Raja R Harinath - - * flowanalysis.cs (Reachability): Reorganize slightly, and remove - unused properties. - -2007-03-20 Bill Holmes - * class.cs: - Added 2 MemberCoreArrayList objects, ordered_explicit_member_list and - ordered_member_list, to TypeBuilder to store members to be defined - in the order they were parsed in. - - ordered_explicit_member_list contains all properties indexers - and methods that are defined as explicit implementation of an - interface or base class. - - ordered_member_list contains all properties indexers and methods - that are not defined as explicit implementation of an interface - or base class. - - Removed MethodArrayList and IndexerArrayList from TypeBuilder. The - functionality in these removed classes has been replaced with - ComputeIndexerName, EmitIndexerName, HasEqualss, HasGetHashCode, and - CheckEqualsAndGetHashCode members defined and called in the TypeBuilderClass. - - Adding CheckForDuplications to PropertyBase.PropertyMethod and calls - to CheckForDuplications inside GetMethod and SetMethod Define Method - to handle method property and indexer name conflicts. - - Fixes #79434 - - All code is contributed under the MIT/X11 license. - -2007-03-20 Martin Baulig - - * class.cs (TypeContainer.Interfaces): Removed; they're now - included in `TypeContainer.Types'. - -2007-03-20 Martin Baulig - - Fix #77963, #80314 and #81019. Added gtest-317, ..., gtest-320. - - * class.cs (TypeContainer.CreateType): New public method. This is - now called before DefineType() to create the TypeBuilders. - (TypeContainer.DefineType): Don't create the TypeBuilder here; it - has already been created by CreateType(). - (TypeContainer.DefineTypeBuilder): Renamed into CreateTypeBuilder(); - don't resolve our base classes here; this has been moved into - DefineBaseTypes(). We're now called from CreateType(). - (TypeContainer.DefineBaseTypes): New private method; resolve our - base classes here. We're now called from DefineType(). - - * rootcontext.cs - (RootContext.ResolveTree): Call TypeContainer.CreateType() on all - our types first to create all the TypeBuilders. After that, call - TypeContainer.DefineType() on all the types which'll resolve their - base classes and setup the resolve order. - -2007-03-20 Martin Baulig - - * class.cs (TypeContainer.Enums): Removed; they're now included in - `TypeContainer.Types'. - -2007-03-20 Martin Baulig - - * class.cs - (TypeContainer.DefineType): Don't call ResolveMembers() here. - (TypeContainer.DoResolveMembers): Call DefineType() on our - `compiler_generated' classes; moved here from DefineNestedTypes(). - - * rootcontext.cs - (RootContext.ResolveTree): Call ResolveMembers() on all - TypeContainer's in the `type_container_resolve_order'. - -2007-03-19 Marek Safar - - * class.cs: Use corlib to handle InternalMethodImplAttribute. - -2007-03-17 Marek Safar - - * class.cs (EventFieldAccessor.EmitMethod): Don't override existing - implementation flags. - -2007-03-17 Marek Safar - - * class.cs: More optimizations for type parameters. - -2007-03-15 Marek Safar - - * anonymous.cs (AnomymousMethod): Can be now hosted in generic container. - - * ecore.cs, parameter.cs: More common code for both corlibs. - - * typemanager.cs (IsGenericMethod): Simplified. - -2007-03-15 Raja R Harinath - - * flowanalysis.cs (FlowBranching.Reachability): Remove handling of - 'returns'. - * statement.cs, iterators.cs, lambda.cs: Update to changes. - - * statement.cs (Lock.Resolve): Invoke 'ec.NeedReturnLabel' - unconditionally. Simplify explanation. - (Try.Resolve, Using.Resolve): Likewise. - -2007-03-15 Martin Baulig - - Fix #80731. - - * decl.cs (DeclSpace): If we're a partial class, use our - `PartialContainer's `TypeParameters' and `CurrentTypeParameters'. - -2007-03-15 Raja R Harinath - - * flowanalysis.cs (FlowBranching.Reachability): Remove handling of - 'throws'. - (FlowBranching.UsageVector): Update to changes. - (FlowBranching.MergeSiblings): Likewise. - * statement.cs: Likewise. - -2007-03-15 Martin Baulig - - Fix #79302. - - * decl.cs - (MemberCache): Added a special .ctor for type parameters. - - * typemanager.cs - (TypeManager.MemberLookup_FindMembers): `TypeParameter' now has a - `MemberCache'. - -2007-03-09 Martin Baulig - - * enum.cs (Enum): Make this a TypeContainer. - (EnumMember): Derive from `Const'. - - * const.cs - (Const.DoResolveValue): New protected virtual method; move most of - the functionality of ResolveValue() here so we can override it in - `EnumMember'. - (Const.CreateConstantReference): Make this virtual. - - * class.cs (Kind): Add `Kind.Enum'. - (TypeContainer.Emit): Don't emit the enums here; they're already - in the `RootContext.typecontainer_resolve_order'. - - * rootcontext.cs (RootContext.EmitCode): Don't emit the enums - here; they're already in the `typecontainer_resolve_order'. - - * ecore.cs (EnumConstant.ConvertImplicitly): Add - TypeManager.DropGenericTypeArguments(). - - * typemanager.cs - (TypeManager.CSharpEnumValue): Add DropGenericTypeArguments(). - (TypeManager.IsEnumType): Likewise. - (TypeManager.EnumToUnderlying): Likewise. - (TypeManager.IsEqual): Add support for enums. - -2007-03-12 Raja R Harinath - - * typemanager.cs (InitCoreTypes) [NET_2_0]: Allow - DefaultParameterValueAttribute to be undefined, say if System.dll - is not referenced. - -2007-03-11 Marek Safar - - * ecore.cs, parameter.cs, typemanager.cs: Another gmcs fix to work with - any mscorlib. - -2007-03-10 Marek Safar - - * class.cs, parameter.cs: Unified parameters verification. - -2007-03-08 Martin Baulig - - * cs-parser.jay (constructor_header): Pass the location to the - newly created TopLevelBlock. - -2007-03-07 Martin Baulig - - * statement.cs (Block.Resolve): Don't crash on error; bug #80715. - -2007-03-06 Miguel de Icaza - - * convert.cs (ExplicitReferenceConversionExists): Sync this method - with the changes from David, fixes the build. - -2007-03-05 David Mitchell - - * convert.cs: Implement From System.Collecitons.Generic.IList - and its base interfaces to a one-dimensional array type S[], - provided there is an implicit or explicit reference conversion - from S to T. - -2007-03-03 Marek Safar - - * cs-tokenizer.cs: Implemented basic linq grammar. - - * driver.cs: Set linq lang version on demand. - -2007-02-26 Marek Safar - - * cs-parser.jay, expression.cs: Compile empty __arglist correctly. - -2007-02-25 Marek Safar - - * attribute.cs: Replaced DefinePInvoke in favor of S.R.E implementation - (Fixes #80455) - - * class.cs (InterfaceMemberBase): Share common `extern' modifier checks - here. - Check property and event extern attributes. - - * codegen.cs (ModuleClass): HasDefaultCharSet when module defined global - charset. - -2007-02-24 Marek Safar - - A fix for bug #80407 - * ecore.cs: Don't report ambiguity error when methods have same parent. - -2007-02-23 Marek Safar - - A fix for bug #80878 - * class.cs, cs-parser.jay: Event property can host anonymous methods. - -2007-02-22 Marek Safar - - * attribute.cs: Enable ExtensionAttribute presence test. - -2007-02-22 Marek Safar - - * class.cs: Warn about missing GetHashCode only when Equals is override. - - * decl.cs: Check accessibility of type arguments. - - * typemanager.cs: Correctly report nullable array. - -2007-02-20 Marek Safar - - * class.cs, report.cs: Capture more details when things go wrong. - -2007-02-20 Marek Safar - - A fix for bug #80650 - * cs-parser.jay: Anonymous container starts at constructor declaration - and not at block beginning because it has to be usable in constructor - initializer. - - * statement.cs: Use context location and not block one for error reporting. - -2007-02-18 Marek Safar - - A fix for bug #78712 - * class.cs.cs, decl.cs, ecore.cs: LookupAnyGeneric inspects nested types - too. - -2007-02-18 Marek Safar - - A fix for bug #80493 by Atsushi Enomoto - * cs-parser.jay: Ignore invalid attribute target. - -2007-02-18 Marek Safar - - * cs-tokenizer.cs: Ignore '\0' as white space character. - -2007-02-17 Miguel de Icaza - - * cs-parser.jay: Add support for lambda expressions to the mcs - compiler as well. - - * lambda.cs: Only clone when we are probing, not on the final call - (Compatible is the final call). - - * statement.cs (CloneContext): Introduce class to provide block - remapping during clone. - - All statements Clone themselves now. - - (Clone): special handling for blocks, when we clone a block, we - register the block inside this routine, as children of the block - might trigger a lookup. - - * expression.cs: Add support for CloneContext in all expressions. - -2007-02-17 Marek Safar - - A fix for bug #80493 - * statement.cs: Report ambiguous warning when interfaces are not related. - -2007-02-15 Marek Safar - - C# 3.0 extension methods. - - * attribute.cs (Error_MisusedExtensionAttribute): Extension attribute - cannot be used directly. - - * class.cs (Class.Emit): Emit extension attribute if any class method - is extension method. - (Method.Define): Add basic extension method validation conditions. - (Method.Emit): Emit extension attribute for method. - - * codegen.cs (AssemblyClass): Emit extension attribute if at least one - extension method exists. Currently we follow same approach as Microsoft - does, emit even if a method or a class are private but this can change - later. - - * cs-parser.jay: Add handling of `this' keyword in method parameters - context. - - * decl.cs (DeclSpace.IsStaticClass): New property. - (MemberCache.FindExtensionMethods): Looks for extension methods with - defined name and extension type. - - * doc.cs: Updated after OverloadResolve changes. - - * driver.cs: Add new soft reference to System.Core.dll. - - * ecore.cs (MethodLookup): Can return only MethodGroupExpr. - (ExtensionMethodGroupExpr): Represents group of extension methods. - - * expression.cs (Invocation): Moved methods BetterConversion, MoreSpecific, - BetterFunction, IsOverride, IsAncestralType, OverloadResolve - to MethodGroupExpr and made non-static for easier customization. - (Invocation.DoResolve): Add extension method lookup when no standard - method was found. - (MemberAccess.DoResolve): Try extension methods if no member exists. - - * modifiers.cs: Add METHOD_EXTENSION modifier. - - * namespace.cs (RegisterExtensionMethodClass): Register class namespace - as well as candidate extension type. - (ComputeNamespaces): When assembly constains extension methods registers - them. - (Namespace.RegisterExternalExtensionMethodClass): Register type for later - extension method lookup. - (Namespace.LookupExtensionMethod): Looks for extension method in this - namespace. - (NamespaceEntry.LookupExtensionMethod): Does extension methods lookup to - find a method which matches name and extensionType. - - * parameter.cs (Parameter): Add This modifer. - (HasExtensionMethodModifier): New property. - (Resolve): Add extension parameter check. - (ModFlags): turned to property to exclude this modifier as it is not real - parameter modifier. - (Parameters): Implemented ExtensionMethodType and HasExtensionMethodType. - - * support.cs (ParameterData): Add ExtensionMethodType. - (ReflectionParameters): Implemented ExtensionMethodType interface property. - - * typemanager.cs: Add type and ctor extension attribute type. - -2007-02-15 Miguel de Icaza - - * report.cs (DisableErrors, EnableErrors): used to prevent error - output when we are "trying" to compile various methods with - different types. - - * ecore.cs (Expression): Add Clone method that calls the virtual - CloneTo method. The current CloneTo method in Expression throws - an exception so we can track down all the places where this must - be implemented (not using abstract, because that would be a lot of - up-front-work before we can start testing the implementation - idea). - - Important: we only need Clone capabilities for expressions created - by the parser, as the expressions we will be cloning are - expressions in the pre-resolved state. This vastly simplifies - the work required. - - (SimpleName): Add CloneTo that does nothing. - (EmptyCast): Add CloneTo. - - * expression.cs (Binary): Implement CloneTo. - (Invocation.IsApplicable): Store the current ec in - EmitContext.TempEc and restore it on return. This is used so we - do not have to sprinkle hundres of methods with an extra - EmitContext, we know that the only user is the lambda expression - ImplicitConversionExists code. - - (Argument): Add Cloning capabilities. - (LocalVariableReference, ParenthesizedExpression, Unary, Probe, - Cast, Conditional, ArrayCreation, InvocationOrCast, Invocation, - ArglistAccess, ArgList, TypeOf, SizeOf, CheckedExpr, - UnCheckedExpr, ElementAccess, BaseAccess, BaseIndexerAccess, - IndexerAccess): Add Clone capability. - - (LocalVariableReference, This): TODO: needs cloned Block mapping. - - (Argument): Add cloning capability. - - * assign.cs (Assign): Implement CloneTo. - - * anonymous.cs (ImplicitStandardConversionExists): Make virtual. - - * lambda.cs (ImplicitStandardConversionExists): Implement lambda - version by calling Convert with the EmitContext (that we are - currently storing in ec, this is not great, but will do for now, - to avoid passing EmitContext parameters to hundreds of functions - that do not need them now). - - (SetExpression): Remove, it is not needed. - - (ContextualReturn): Implement CloneTo. - - * statement.cs (Statement): Implement cloning infrastructure, - similar to expressions. - - (Block): Partial implementation of Clone for statements. - - (Return): Implement clone. - - * constant.cs (Constant.CloneTo): New method, does nothing. - - * codegen.cs (TempEc): Add a static EmitContext as a temporary - solution, until we decide how to exactly do this. - -2007-02-14 Marek Safar - - A fix for bug #80493 - * class.cs (FindOutBaseMethod): When the base accessor does not exist and - a property is override we need to use second accessor. - -2007-02-13 Marek Safar - - A fix for bug #80418 - * attribute.cs, class.cs: Use correct calling conventions for pinvoke - methods. - -2007-02-13 Marek Safar - - Another fix for bug #80749 - * pending.cs: Abstract class has priority over interfaces. - -2007-02-13 Marek Safar - - Another fix for bug #80749 - * pending.cs: Abstract class has priority over interfaces. - -2007-02-13 Marek Safar - - Another fix for bug #80749 - * pending.cs: Abstract class has priority over interfaces. - -2007-02-13 Marek Safar - - Another fix for bug #80749 - * pending.cs: Abstract class has priority over interfaces. - -2007-02-13 Marek Safar - - * class.cs Better error message. - - * driver.cs: Add shorter versions of -optimize option. - -2007-02-13 Martin Baulig - - * class.cs (Constructor.Emit): Check the return value of - ec.ResolveTopBlock() and return on error. - -2007-02-13 Raja R Harinath - - * ecore.cs (Error_InvalidExpressionStatement): Add a comma to error - message to fix error message regression. - -2007-02-12 Marek Safar - - * delegate.cs: Delegate creation expression cannot be of Nullable type. - -2007-02-12 Marek Safar - - A fix for bug #80749 - * assign.cs (FieldInitializer): FieldInitializer has to keep track of - its parent container. - - * class.cs (DefineFieldInitializers): Each initializer can has different - resolve context. - - * const.cs: Updated. - -2007-02-11 Miguel de Icaza - - * lambda.cs (LambdaExpression.Compatible): Remove some early code, - now all the heavy lifting to check that embedded statements or - expressions have the right form is done in the ContextualReturn. - - (ContextualReturn): New class. - - * ecore.cs (Error_InvalidExpressionStatement): Make a helper - method that can be invoked to report 201, so we do not replicate - this everywhere. - - * cs-parser.jay: Reuse Error_InvalidExpressionStatement. - - * cs-tokenizer.cs (xtoken): Correctly compute the column, it was - treating tabs as spaces. - -2007-02-09 Marek Safar - - A fix for bug #80315 by martin.voelkle@gmail.com (Martin Voelkle) - * assign.cs: Use full implicit conversion for right side check. - -2007-02-09 Marek Safar - - * statement.cs (Switch): Switch over boolean type is not standardized. - -2007-02-08 Marek Safar - - A fix for bug #80755 - * decl.cs (FindBaseEvent): Don't use method cache for events. - -2007-02-07 Marek Safar - - * cs-parser.jay: Better syntax error handling. - - * ecore.cs, enum.cs, statement.cs, typemanager.cs: Print enum member name - instead of underlying type value. - -2007-02-06 Marek Safar - - * driver.cs: Check define identifier before is registered. - - * namespace.cs: Use existing error message. - - * report.cs: New warning. - -2007-02-06 Marek Safar - - A fix for bug #80742 - * expression.cs: Delegate Invoke method can be called directly. - -2007-02-06 Marek Safar - - A fix for bug #80676 - * class.cs (IsEntryPoint): The Main method can have params modifier. - -2007-02-04 Miguel de Icaza - - * parameter.cs (Parameter, Parameters): Add Clone method. - - * anonymous.cs (Compatible): Turn method into virtual method, so - LambdaExpression can implement a different behavior. - - (CompatibleChecks, VerifyExplicitParameterCompatibility): Factor - out the basic checking here, so it can be used by - LambdaExpressions. - - * lambda.cs: Introduce "Compatible" function that will do the - heavy lifting. - -2007-02-02 Marek Safar - - * attribute.cs: Unified one error message. - - * class.cs (Class): Use type attributes and not properties to test static - class. - (IsEntryPoint): Don's pass local variable. - - * convert.cs: Removed duplicate check. - - * decl.cs, doc.cs, ecore.cs (LookupType): Renamed to LookupNamespaceOrType. - - * driver.cs: Don't crash when soft reference does not exist. - - * namespace.cs (EnsureNamespace): Renamed to RegisterNamespace. - (UsingEntry): Removed redundant allocation. - - * parameter.cs: Add fast path for type parameters. - - * support.cs: Don't allocate attribute when it's not used. - -2007-01-30 Miguel de Icaza - - * anonymous.cs - (AnonymousMethodExpression.ImplicitStandardConversionExists): turn - this into a virtual method, so we can override it in LambdaExpression. - - * driver.cs: Improve diagnostics in case of failure. - - * cs-tokenizer.cs: Instead of trying to parse a type and a name, - write a function that is slightly more complex and that parses: - - type identifier [, type identifier]* ) - - The old function would return incorrectly a OPEN_PARENS_LAMBDA for - this expression: - - (canEmpty ? i >= 0 : i > 0) - -2007-01-30 Raja R Harinath - - * cs-tokenizer.cs (parse_namespace_or_typename): Don't throw an - exception on possibly valid code. - -2007-01-29 Raja R Harinath - - * cs-tokenizer.cs (is_punct) ['<']: Update to changes in - Push/PopPosition. - (parse_opt_type_arguments): Remove. It's almost the same as - parse_less_than. - (parse_namespace_or_typename): Use parse_less_than. - -2007-01-28 Miguel de Icaza - - * cs-tokenizer.cs: Typo fix, its not GMCS_SOURCES but GMCS_SOURCE, - this bug took a few hours to find, because the state saved and - restored by PushPosition and PopPosition was ignoring the state of - parse_generic_less_than. - - I can also now remove the handling of OP_LT and OP_GT, this solves - the big mistery. - - * cs-tokenizer.cs: store the location for the ARROW token, we use - that in the parser. - - (PushPosition, PopPosition): save/restore also `current_token', - restore `parse_generic_less_than' (was missing). - - (parse_opt_type_arguments): use parse_type, not - parse_namespace_or_typename to parse types. - - * lambda.cs: Empty new file, will eventually have the lambda - expression implementation. - - * lambda.test: used to test the internal tokenizer. - - * report.cs (FeatureIsNotISO1): Rename from - FeatureIsNotStandardized, because it was about the language level - (1 vs 2) it was not about standarization. - - (FeatureRequiresLINQ): New. - - * support.cs (SeekableStreamReader): Only require that the reader - is a TextReader, not a StreamReader, so we can plug StringReader. - - * cs-tokenizer.cs (parse_type_and_parameter): Returns true if at a - given position in the input stream the following tokens can be - parsed as a type followed by an identifier. - - (is_punct): after a '(' if parse_type_and_parameter returns true, - then return a special token OPEN_PARENS_LAMBDA which is used to - avoid reduce/reduce errors in the grammar for the - lambda_expression rules. - - (parse_type): implement a type parser inside the - tokenizer, the parser only returns true or false depending on - whether the input at a given position can be parsed as a type. - - (peek_token): new method used during type parsing. - -2007-01-28 Raja R Harinath - - Fix #80531 - * anonymous.cs (ScopeInfo.InflateParameters): New. - (AnonymousContainer.Resolve): Use it to redirect types of - delegate parameters. - -2007-01-27 Raja R Harinath - - Fix #80530 - * expression.cs (Error_InvalidArguments): Don't use two different - messages for CS1503. Use ExtraInformation and - SymbolRelatedToPreviousError instead. - - Fix #80358 - * decl.cs (DeclSpace.initialize_type_params): Don't access - 'type_params' of a partial class directly. - -2007-01-26 Miguel de Icaza - - * constant.cs: Removed a handful of out-of-range checks that were - not necessary. - -2007-01-25 Marek Safar - - * expression.cs (CheckUselessComparison): Add additional check for char - constants. - - * namespace.cs: Fixed typo. - -2007-01-23 Miguel de Icaza - - * constant.cs: Bloat removal, CheckRange and CheckUnsigned are - gone, instead we inline the test, preventing the needless casts to - longs, ulongs and doubles for the parameters, avoiding calls to - methods that overchecked stuff, and instead inlined things - nicely. - -2007-01-20 Marek Safar - - * cs-parser.jay: Better parameter error handling. - -2007-01-17 Marek Safar - - A fix for bug #80368, #80522 - * expression.cs (ArrayCreation.only_constant_initializers): Indicates - whether array initializer contains constants only. - (ArrayCreation.Emit): Use better formula to decide when - are array initializers for static initialization. - (ArrayCreation.EmitDynamicInitializers): When the array is small enough we - have to emit even constants otherwise they are pre-initialized. - -2007-01-17 Bill Holmes - Raja R Harinath - - Fix emit order of 'get' vs. 'set'. - * support.cs (Accessors): New. - * cs-parser.jay (accessor_declarations): Use it instead of 'Pair'. - Note the order in which accessors are declared in the source. - * class.cs (PropertyBase.DefineGet, PropertyBase.DefineSet): New. - Refactored from Property.Define and Indexer.Define. - (PropertyBase.DefineAccessors): New helper that calls the above in - appropriate order as noted by the parser. - (Property.Define, Indexer.Define): Update to changes. - (PropertyBase.SetMethod.PropertyInfo): Don't return a null. - -2007-01-17 Raja R Harinath - - Fix cs0029-6.cs and gcs0029-2.cs (regression) - * ecore.cs (EmptyConstantCast.ConvertImplicitly): Check that - there's an implicit conversion from the current type to the target - type before converting the underlying constant. - -2007-01-16 Marek Safar - - * const.cs (ResolveValue): Updated after constant conversion was made more - generic. - - * constant.cs (GetAttributableValue): constant to object conversion is - used for attributes only. - (IntConstant.ConvertImplicitly): Moved from convert to be used in all - constant conversions. - (LongConstant.ConvertImplicitly): Ditto. - - * convert.cs (ImplicitNumericConversion): Extracted constant bussiness. - (ImplicitConversionStandard): Handle constant conversion as extra step. - It solves the issue when constant conversion was called indirectly like - inside array initializer and constant folding was skipped. - - * literal.cs (NullLiteral.ConvertImplicitly): Fixed an issue exposed by - this change. - - * statement.cs(ImplicitConversionStandard): Updated after constant - conversion was made more generic. - -2007-01-16 Sergey P. Kondratyev - - * expression.cs (As.DoResolve): Use GenericConstraints instead of - Constraints, solves the problem where the compiler incorrectly - reported that a type parameter was not constrained to a class (Bug - 80518) - -2007-01-14 Marek Habersack - - * doc-bootstrap.cs: Fix a compilation problem in the bootstrap phase. - -2007-01-14 Marek Safar - - A fix for bug #80368 - * assign.cs (FieldInitializer): New class implements field - initializer statement. - - * attribute.cs: Update after FieldMember rename. - - * class.cs (PropertyBasedMember): New common class for property based - types. - (InterfaceMemberBase): New base class for all members which can be used as - an interface members. - (MethodCore): Moved really common code to InterfaceMemberBase. - (Method.Define): Equal and GetHasCode detection is relevant for methods - only. - (MethodData.Define): Don't assume that public event implements an - interface automatically. - (MethodData.DefineMethodBuilder): Issue an error even if only extern - modifier is used. - (MemberBase): Moved all interface speficic code to InterfaceMemberBase. - (FieldMember): Merged with FieldBase. - (EventProperty.AEventPropertyAccessor): New specialization to check whether - event extern modifier can be used. - (EventField.EventFieldAccessor): Moved event field specific code here. - (Event.AllowedModifiers): Even event can be extern. - (Event.FindOutBaseMethod): New override specific to events. - (Indexer.parameters): Reintroduce parameters because base class holds - only properties common data. - (Indexer.CheckForDuplications): Indexers are threated as methods so we - need do extra parameters check. - - * const.cs: Update after FieldMember rename. - - * decl.cs (MemberCache.FindBaseEvent): New method. - - * doc.cs (GetMethodDocCommentName): Accept parameters as extra argument - to reflect that indexer is now derived from PropertyBased. - - * ecore.cs (GetMemberType): Made public. - (EventExpr.ResolveMemberAccess): Use right event cache and checks for - obsolete event. - - * flowanalysis.cs, statement.cs: Update after FieldMember rename. - - * typemanager.cs (CSharpSignature): Correctly print event accessors. - (RegisterEvent): Removed. - (RegisterPrivateFieldOfEvent): Renamed to RegisterEventField. - (GetPrivateFieldOfEvent): Renamed to GetEventField. - -2007-01-11 Raja R Harinath - - Fix #80249 - * statement.cs (CollectionForeach.TryType): Prefer generic - GetEnumerator over non-generic variant. Fix code to follow comments. - -2007-01-09 Raja R Harinath - - Fix #80446 - * support.cs (ReflectionParameter): Don't use an invalid index on - the generic parameter data. - -2007-01-08 Miguel de Icaza - - * driver.cs: Just add a tiny bit of infrastructure. - -2007-01-02 Marek Safar - - * class.cs (VerifyMembers): Fixed an crash reported on mono mailing list - where field type is struct from current assembly. - - * ecore.cs (EnumConstant.AsString): Report an enum member name whenever - it is possible. - -2007-01-02 Marek Safar - - A fix for bug #80381 - * attribute.cs (AttributeTester.RegisterNonObsoleteType): Registers - the core types. - - * namespace.cs (GlobalRootNamespace.LookupTypeReflection): Better error - messages. - (Namespace.LookupType): Always use core types from corlib when speficied. - - * report.cs: A new warning. - - * rootcontext.cs (BootstrapCorlib_ResolveInterface, - BootstrapCorlib_ResolveClass): Register type as non-obsolete type. - (ResolveCore): Add missing System.Runtime.InteropServices._Attribute. - - * typemanager.cs (CoreLookupType): Register type as non-obsolete type. - (InitCoreTypes): Set expression type of object_type and value_type - immediately after lookup. - -2007-01-01 Miguel de Icaza - - * cs-tokenizer.cs: Accept Pc class characters (Connector - Punctuation) as valid identifiers. Fixes #78259 - - * expression.cs (Invocation.DoResolve): Moved the check for the - use of `this' for doing method calls to the Invocation resolution - step, after overload resolution has taken place instead of doing - the check at the low-level `This.DoResolve' level. - - The `This.DoResolve'(appens before overload resolution, so it has - no way of knowing if the method that will be called will be - instace or static, triggering an erroneous report for cs0188 (Bug - 78113). - - We now do the check for instance method invocations after we know - what method will be called. - - (This.CheckThisUsage): Move the actual use of this structure - checking into its own method and expose it. - - * Everywhere that called Error_ValueCannotBeConverted: pass a new - EmitContext. - - Exceptions: Null.ConvertImplicitly, - Constant.ImplicitConversionRequired as there are too many call - sites for passing the ec. - - * ecore.cs (Expression.Error_ValueCannotBeConverted): Take an - EmitContext, if the value is null, then we do not try to provide - the extra information from the error (If a userdefined conversion - exists, as UserDefinedConversion requires a non null-EmitContext). - - Fixes: #80347 - -2006-12-30 Raja R Harinath - - * flowanalysis.cs (MyBitVector): Document some invariants. - (MyBitVector.Or, MyBitVector.And): Reimplement the optimizations - introduced below, and add a couple of others, - -2006-12-30 Marek Safar - - * attribute.cs (GetMethodObsoleteAttribute): Uses new - GetPropertyFromAccessor and GetEventFromAccessor. - - * class.cs (MethodCore.CheckBase): A new warning when obsolete member - overrides non-obsolete one. - (Indexer.Define): Error message has been moved to the parser. - - * cs-parser.jay: Better syntax errors handling. - - * delegate.cs (NewDelegate.DoResolve): Issue less confusing error message - when an invocation has no arguments. - - * ecore.cs: Removed not used caching. - - * expression.cs (IsSpecialMethodInvocation): Reuses TypeManager - implementation. - - * report.cs: Add a new warning. - - * support.cs (ReflectionParameters): Implements Equals, GetHashCode. - - * typemanager.cs (enumeration_type): Removed. - (CSharpSignature): Reuses IsSpecialMethod. - (IsEqual): Hack for MS BCL. - (GetPropertyFromAccessor): New method. - (GetEventFromAccessor): New method. - (IsSpecialMethod): Fixed to handle more cases. - -2006-12-30 Marek Safar - - * cs-tokenizer.cs (PreProcessDefinition, handle_preprocessing_directive): - Made white spaces array static. - - * ecore.cs (RemoveGenericArity): Optimized. - - * flowanalysis.cs (MyBitVector.Or, MyBitVector.And): Optimized (up to - 10 times faster). - (MyBitVector.initialize_vector): Simplified. - -2006-12-22 Miguel de Icaza - - * ecore.cs: Am not entirely happy with this hack, but it seems to - address the issue in 80257 (a small test case for - CreativeDocs.NET). - - I set the MethodGroupExpr.Type to an internal compiler type - (itself in this case) to force the resolution to take place. Why - it does not take place with a null is beyond me. - -2006-12-20 Marek Safar - - A fix for bug #80288 - * expression.cs (ResolveOperator): Consider user defined conversion for - logical and operator too. - (EmitBranchable): Optimization for logical and when full constant folding - could not be applied but one operand is constant. - -2006-12-19 Marek Safar - - * class.cs (GetClassBases): Write 5 times every day, will never use - FullName for error reporting. - - * decl.cs (AsAccessible, CheckAccessLevel): Always unpack arrays first. - -2006-12-19 Martin Baulig - - * statement.cs (LocalInfo.EmitSymbolInfo): New public method; emit - the symbol file info here. - -2006-12-18 Marek Safar - - * cs-tokenizer.cs (handle_preprocessing_directive): When previous section - of `elseif' is taking then following sections are not taking. - Fixes an issue reported on mono mailing list. - -2006-12-18 Marek Safar - - A fix for bug #80300 - * cs-tokenizer.cs (PreProcessDefinition): Do no define/undefine when - a caller is not taking. - -2006-12-18 Raja R Harinath - - * anonymous.cs: Change several TypeContainer declarations to DeclSpace. - (CompilerGeneratedClass): Use parent.PartialContainer unconditionally. - (RootScopeInfo, AnonymousMethodMethod): Update to changes. - * iterator.cs: Change several TypeContainer declarations to DeclSpace. - * class.cs: Update to changes. - -2006-12-17 Marek Safar - - A fix for bug #79934 - * anonymous.cs (CompilerGeneratedClass): Register class in a shared - partial container. - - * class.cs (ResolveMembers): Register an iterator in current container and - not in shared one. - -2006-12-16 Raja R Harinath - - Fix test-543.cs - * expression.cs (VerifyArgumentsCompat): Allow zero arguments to - satisfy a params annotated parameter. - -2006-12-16 Marek Safar - - A fix for bug #77014 - * expression.cs (Invocation.BetterFunction): Fixed to cope with dynamic - paramters correctly and not rely on hacks in Parameters class. - (Invocation.IsParamsMethodApplicable): Changed to accept params parameter - at any possition. - (Invocation.VerifyArgumentsCompat): Ditto. - (Invocation.EmitArguments): Changed to correctly emit params arguments at - any possition. - - * parameter.cs (HasParams): Don't assume that params is the last one. - - * support.cs (ReflectionParameters.ctor): Look for params attribute - correctly. - (ReflectionParameters.ParameterType): Removed hack when we returned last - parameter for out of range parameters. - (ParameterName, ParameterModifier): Ditto. - -2006-12-14 Marek Safar - - A fix for bug #79987 - * decl.cs (DeclSpace.VerifyClsCompliance): External names cache is null - when assembly is not CLS compliant but type is. I have no idea why is this - allowed. - - * typemanager.cs (Reset): Invalidate AllClsTopLevelTypes cache. - -2006-12-13 Miguel de Icaza - - * class.cs (ConstructorInitializer.Resolve): Allow for ":this()" - in struct constructors, they are basically no-ops. - -2006-12-12 Marek Safar - - * cs-tokenizer.cs (Position): Save preprocessor status too. - -2006-12-12 Marek Safar - - A fix for bug #77794 - * cs-tokenizer.cs (consume_identifier): Check for correct partial context. - -2006-12-12 Marek Safar - - * cs-tokenizer.cs (get_cmd_arg): Support CR as the line terminator. - Fixes #69299. - (pp_expr): Report error for an invalid expression. - (handle_preprocessing_directive): Simplified; add more error checking. - -2006-12-11 Marek Safar - - A fix for bug #74939 - * cs-tokenizer.cs (is_punct): We cannot simply disable preprocessor - directives handling. - -2006-12-10 Marek Safar - - A fix for bugs #80093, and #75984 - * cs-tokenizer.cs (handle_preprocessing_directive): Fixed #if/#else/#endif - logic, it seems to me as it worked before "by coincidence". - (xtoken): Simplified to use reworked handle_preprocessing_directive. - (cleanup): Enabled endif check. - -2006-12-09 Marek Safar - - A fix for bug #80162 - * statement.cs (CollectionForeach.TryType): Generics and non-generics - enumerators are never ambiguous. - -2006-12-08 Raja R Harinath - - Fix #80060 - * cs-tokenizer.cs (parse_less_than): Recognize double-colons too. - -2006-12-06 Marek Safar - - A fix for bug #80144 - * class.cs (EventProperty.Define): Explicit implementation means - that an even is used. - -2006-12-06 Marek Safar - - Fixes the operators implementation (part II) - - * cfold.cs (DoConstantNumericPromotions): Renamed to - DoBinaryNumericPromotions and simplified. - (BinaryFold): Couple of conversion fixes; simplified. - - * constant.cs, ecore.cs, literal.cs - (ToType): Renamed to ConvertImplicitly. - (Reduce): Renamed to ConvertExplicitly. - - * class.cs, convert.cs: Updated. - - * expression.cs: TryReduce doesn't throw an exception. - -2006-12-01 Marek Safar - - A fix for bug #80108 - * ecore.cs (EventExpr.EmitAddOrRemove): Don't crash when right side is not - compatible. - -2006-11-30 Marek Safar - - Fixes unary operators implementation (part I) - Also fixes #80026 - - * cfold.cs (Error_CompileTimeOverflow): Made internal - - * const.cs (IConstant): Changed to use reference to constant and - not constant itself. - Updated IConstant implementations. - - * constant.cs (CreateConstant): New factory method. - Updated IConstant implementation. - - * convert.cs (ImplicitStandardConversionExists): Uses compiler Equals. - - * ecore.cs: Updated to use CreateConstantReference. - - * enum.cs: Reflects IConstant changes. - - * expression.cs (Unary): Reimplemented +,-,~ to conform C# standard. - - * literal.cs (NullConstant): Change to be independently usable. - -2006-11-29 Martin Baulig - - * class.cs (Constructor.Emit): Correctly handle anonymous methods; - we need to emit the scope initializer before calling the base .ctor. - - * anonymous.cs: Merged back from the new anonymous methods branch. - (AnonymousMethodHost): Renamed to `RootScopeInfo'. - - * expression.cs (ParameterReference.DoResolveBase): Create a - "normal" ScopeInfo when capturing parameters rather than using the - root scope; this makes things work with anonymous methods having - parameters. - - * statement.cs - (ToplevelBlock.AnonymousMethodHost): Renamed into `RootScope'. - -2006-11-22 Marek Safar - - A fix for bug #79987 - * class.cs (VerifyClsCompliance): Move redundant CLS compliance attribute - check to a base class. - * decl.cs (VerifyClsCompliance): Warn that CLS compliance cannot be tested - only when assembly has missing attribute. - * report.cs: Update. - -2006-11-21 Marek Safar - - * cs-tokenizer.cs: Merged with gmcs version. - -2006-11-20 Marek Safar - - * cs-tokenizer.cs, - * cs-parser.jay: Better error message when partial keyword is misplaced. - -2006-11-19 Gert Driesen - - A fix for bug #79810 - report.cs: CS1058 only applies to 2.0 profile (gmcs). - codegen.cs: on 2.0 profile, non-exception throwables are wrapped in - a RuntimeWrappedException by default. - -2006-11-18 Marek Safar - - A fix for bug #79843 - * delegate.cs (Delegate.VerifyMethod): Fixed covariance and contravariance - implementation. - (DelegateCreation.Error_NoMatchingMethodForDelegate): Ditto. - -2006-11-18 Marek Safar - - * driver.cs, namespace.cs: Uses faster IndexOf version. - -2006-11-17 Marek Safar - - A fix for bug #79941 - * class.cs (MemberCore.IsDuplicateImplementation): Add more tricks for - operators. - (Operator.Define): Implicit/Explicit operator of same type is duplicate - even if internal name is different. - * convert.cs (GetConversionOperator): Replaced EmitContext with parentType. - (UserDefinedConversion): Simplified as the operators cannot be internal. - * ecore.cs (Error_ValueCannotBeConverted): Take account of user - conversions. - (MethodLookup): Replaced EmitContext with parentType. - * expression.cs: Updated. - -2006-11-09 Raja R Harinath - - * driver.cs (BadAssembly): Handle all the ugliness of - DefineDynamicAssembly. - -2006-11-08 Raja R Harinath - - Address parts of #58244 -- most of what's left is in the runtime - * driver.cs (LoadAssembly): Simplify slightly. Add CS0009 and - CS1509 error checks, and handle them for all assembly loads, not - just the first invocation. - (LoadModule): Likewise. Move handling of 'adder_method' ... - * codegen.cs (AssemblyClass.AddModule): ... here. - -2006-11-02 Marek Safar - - * statement.cs.cs (CollectionForeach.TryType): Issue a error when - IEnumerable is ambiguous. - -2006-10-31 Marek Safar - - A fix for bug #67689 - * statement.cs.cs (CollectionForeach.TryType): Issue a warning when - GetEnumerator is ambiguous. - - * report.cs: Add new warning. - -2006-10-29 Marek Safar - - A fix for bug #78602 - ecore.cs (PropertyExpr.InstanceResolve): The qualifier for access - to protected member can be nested type. - -2006-10-28 Marek Safar - - A fix for bug #78965 - ecore.cs (PropertyExpr.InstanceResolve): The qualifier for access - to protected member must derive from current type. - -2006-10-27 Marek Safar - - assign.cs: Reuses error method. - - ecore.cs (Expression.Error_ValueCannotBeConverted): Report a value - instead of type for constants. - (Expression.Error_ValueAssignment): Common error method. - - * expression.cs (UnaryMutator.ResolveOperator): Value cannot be used - for any assignment. - -2006-10-27 Marek Safar - - A fix for bug #79081 - * expression.cs (MemberAccess.DoResolve): Check nested type - accessibility. - -2006-10-27 Atsushi Enomoto - - * doc.cs : nested delegates were not handled. Fixed bug #79754. - -2006-10-26 Marek Safar - - A fix for bug #76591 - * cs-tokenizer.cs (IsCastToken): Enable a cast of anonymous method. - -2006-10-26 Marek Safar - - * codegen.cs (AssemblyClass.ApplyAttributeBuilder): Don't allow to have - type forwarder of the same type multiple times. - -2006-10-26 Raja R Harinath - - Fix #78820 - * ecore.cs (PropertyExpr.InstanceResolve): Always resolve the - instance as an rvalue, even when we later resolve as an lvalue. - -2006-10-25 Martin Baulig - - * anonymous.cs: Fix #79673. - -2006-10-24 Marek Safar - - A fix for bug #79666 - expression.cs (ArrayCreation.GetAttributableValue): An initializer can be - ignored when is optimized (= default value) as its value is already set. - -2006-10-23 Marek Safar - - A fix for bug #79724 - * report.cs (SymbolRelatedToPreviousError): Uses DeclSpace instead of - TypeContainer for type lookup. - -2006-10-23 Marek Safar - - A fix for bug #79231 - * ecore.cs (ResolveAsBaseTerminal): Removed redundant error test. - * expression.cs (OverloadResolve): Always convert type name for - an error message. - (ResolveNamespaceOrType): Don't confuse a nested type with any - other member. - -2006-10-18 Martin Baulig - - * anonymous.cs: Propagate the IsStatic state, fixes the crasher in banshee. - -2006-10-17 Miguel de Icaza - - * convert.cs: Fix typo, fixes the test-535.cs, we were casting to - an int32, but requesting an int64 from the conversion - -2006-10-12 Martin Baulig - - * anonymous.cs - (AnonymousContainer.Resolve): Inflate the `ReturnType'. Fixes #79592. - -2006-10-12 Martin Baulig - - * statement.cs - (Using.EmitLocalVariableDeclFinally): Small fix for iterators. - -2006-10-11 Miguel de Icaza - - * convert.cs: Remove broken code: I was doing the "Existance" - tests for Implicit conversions. - -2006-10-10 Miguel de Icaza - - * convert.cs: Added one missing case in - ImplicitStandardConversionExists uint64 to intptr. - - Fixes #59800 - - * typemanager.cs (uintptr_type): another core known type. - - * ecore.cs (OperatorCast): routine used to do cast operations that - depend on op_Explicit. We could change some of the Decimal - conversions to use this. - - This one has a probe mechanism that checks both types for an op_ - which it coudl be used to eliminate two classes: CastToDecimal - and CastFromDecimal. - - * convert.cs: Implement the conversions documented in #59800 - -2006-10-10 Martin Baulig - - * iterators.cs (Iterator.Resolve): Call RootScope.ResolveType() - before RootScope.ResolveMembers(). - - * anonymous.cs (ScopeInfo.CapturedScope.ctor): Use the child's - `CurrentType' if appropriate. - -2006-10-09 Marek Safar - - A fix for bug #78568 - * cs-tokenizer.cs (Deambiguate_CloseParens): Expression cannot be cast - when contains binary operators. - * cs-parser.jay: Updated. - -2006-10-09 Martin Baulig - - * delegate.cs - (Delegate.DefineType): Don't call TypeParameter.Resolve() here; - moved that into Define() and also do the other type parameter - checks there. Fixes #79094. Added gtest-292.cs. - - * expression.cs - (ArrayCreation.EmitDynamicInitializers): Use `etype.IsValueType' - since that doesn't include type parameters; don't use `Ldelema' - for type parameters. Fixes #78980. Added gtest-293.cs. - -2006-10-08 Marek Safar - - A fix for #77796 - * convert.cs (ExplicitReferenceConversion): Only enum to enum value - conversion is allowed. - -2006-10-06 Marek Safar - - * ecore.cs (Expression.MemberLookup): Don't register any symbol for - error reporting when no error occurs. - -2006-10-06 Marek Safar - - * cfold.cs (ConstantFold.BinaryFold): Report an error when the conversion - does not exist. - -2006-10-06 Raja R Harinath - - Fix #79584 - * class.cs (DefineTypeBuilder): Check circular dependencies before - setting the parent of the TypeBuilder. - (CheckRecursiveDefinition): Don't use 'BaseType', since - it may not be valid until after DefineTypeBuilder. Use - 'base_type' instead. - -2006-10-04 Martin Baulig - - Merged the Anonymous Methods patch. - - * anonymous.cs, iterators.cs: The new anonymous methods code. - - * statement.cs (Variable): New public abstract class. - (LocalInfo.Variable): New public property. - (LocalInfo.ResolveVariable): New public method. - (Block.Flags): Add `IsIterator'. - (Block.AddVariable): Improved the CS0136 check. - (Block.AnonymousChildren): New public property. - (Block.AddAnonymousChild): New public method. - (ToplevelBlock): Update to use the new anonymous method framework. - (ToplevelBlock.ctor): `container' is now a `Block' and not a - `ToplevelBlock'; this is required to correctly implement the - CS0136 check. - (Fixed, Using): Use `TemporaryVariable' instead of directly - creating the `LocalBuilder'. - - * parameter.cs (Parameter.ResolveVariable): New public method. - (Parameters.ResolveVariable): Likewise. - - * ecore.cs (TemporaryVariable): Use the new `Variable' framework. - - * class.cs (TypeContainer): Replaced the `iterators' list and - corresponding methods with a list of `CompilerGeneratedClass'es. - (TypeContainer.ResolveMembers): New public method. - (Method): `IIteratorContainer' has been replaced by - `IAnonymousHost'. - - * expression.cs (VariableReference): New public abstract base - class for `LocalVariableReference', `ParameterReference' and - `This'. - - * codegen.cs (EmitContext): Removed `capture_context', - `HaveCaptureInfo', `EmitScopeInitFromBlock()' and `Capture*()'. - (EmitContext.EmitThis): Removed. - - * cs-parser.jay: Replace `iterator_container' with - `anonymous_host'. - -2006-10-04 Martin Baulig - - * generic.cs (GenericMethod): Don't make this abstract. - (Constraints.Clone): Added dummy implementation. - -2006-10-04 Raja R Harinath - - Fix #79577 - * namespace.cs (LookForAnyGenericType): Avoid nullref on - 'declspaces'. Avoid allocating arrays willy-nilly. - - Fix #79553 - * cfold.cs (BinaryFold): Move boolean Equality and Inequality - cases out of the switch. - -2006-09-28 Marek Safar - - * namespace.cs (Namespace.Error_NamespaceDoesNotExist): Better error - message when non-generic type is used with the type arguments. - * expression.cs: Updated. - -2006-09-28 Raja R Harinath - - Fix #79013 - * convert.cs (Convert.ImplicitStandardConversionExists): Avoid infloop. - * expression.cs (EmptyExpression.Grab, EmptyExpression.Release): - Change semantics slightly. Don't insist on having only one - temporary EmptyExpression -- just throttle the creation of new ones. - - Fix #79451 - * ecore.cs (Expression.MemberLookup): Enable CS0229 errors for - non-interfaces too. If no methods are found, don't try to create - a MethodGroupExpr. - -2006-09-28 Marek Safar - - * ecore.cs (ResolveAsTypeStep): Print better error when type can be - generic type. - - * namespace.cs (Namespace.LookForAnyGenericType): New method to help - us produce better error message. - -2006-09-27 Marek Safar - - * expression.cs (Binary.ResolveOperator): Warn about a side effect - of the `|' operator. - - * report.cs: A new warning added. - -2006-09-27 Martin Baulig - - * generic.cs (GenericMethod): Don't make this abstract. - -2006-09-27 Martin Baulig - - * report.cs - (InternalErrorException): Added overloaded ctor taking a params array. - -2006-09-26 Marek Safar - - * class.cs, codegen.cs, const.cs, cs-tokenizer.cs, driver.cs, ecore.cs: - Fixed the cases when same error was reported twice. - - * report.cs (SymbolRelatedToPreviousError): Simplified as all our messages - now report symbol information. - -2006-09-25 Martin Baulig - - * class.cs: Completely unified with the gmcs version. - -2006-09-25 Martin Baulig - - * typemanager.cs (TypeManager.IsNullableType): New public function. - (TypeManager.IsNullableTypeOf): Likewise. - (TypeManager.IsNullableValueType): Likewise. - - * class.cs (MethodCore): Added the `GenericMethod' argument from - gmcs and also unified all classes derived from `MethodCore' with gmcs. - -2006-09-24 Raja R Harinath - - * convert.cs: Unify with gmcs version. - -2006-09-24 Marek Safar - - * decl.cs (DeclSpace.VerifyClsCompliance): When type has type parameters - verify them as well. - - * report.cs: New warning. - -2006-09-24 Marek Safar - - * anonymous.cs (AnonymousMethod.Compatible): Cannot generate arguments - for anonymous block with out argument. - -2006-09-24 Marek Safar - - * class.cs (ClassOrStruct.VerifyMembers): Fixed to report correctly - not used private events only. - -2006-09-23 Marek Safar - - * cfold.cs (BinaryFold): On the guest to unify empty constant cast. - - * const.cs (Const.Define): Check for constant type. - (Const.IsConstantTypeValid): Looks for valid constant types. - - * convert.cs (ImplicitReferenceConversion): NullCast to EmptyConstantCast. - - * ecore.cs (EmptyConstantCast): New common class for all constant based - EmptyCast(s). - - * expression.cs (Is.DoResolve): Handle null constant especially. - (New.DoResolve): Check for new void(). - (MemberAccess.DoResolve): Cope with all kind of nulls. - - * literal.cs (NullConstant): Uses EmptyConstantCast. - (NullDefault): Based on EmptyConstantCast. - (NullLiteral): Uses EmptyConstantCast. - - * statement.cs (Block.ResolveMeta): Check for constant type. - -2006-09-22 Martin Baulig - - * delegate.cs, attribute.cs: Merged with the gmcs versions. - -2006-09-22 Raja R Harinath - - * literal.cs (NullDefault): The type of default(IFoo) is 'IFoo', - not the null type. - - Fix part of #79451 - * typemanager.cs (Closure.Filter): Consider PrivateScope attributes. - * decl.cs (DeclSpace.FindMemberToOverride): Likewise. Reorganize - code slightly. - -2006-09-22 Martin Baulig - - * ecore.cs: Merged with the gmcs version. - - * generic.cs (ConstructedType): New dummy class. - (TypeArguments): Don't make this abstract. - - * typemanager.cs - (TypeManager.IsGenericTypeDefinition): New method. - (TypeManager.GetGenericFieldDefinition): Moved here from gmcs. - -2006-09-22 Raja R Harinath - - * expression.cs (ComposedCast): Check for arrays of TypedReference - before creating the type, not after. - -2006-09-21 Marek Safar - - * cfold.cs, const.cs, enum.cs, statement.cs: Updated - after ToType change. - - * constant.cs (Constant.ImplicitConversionRequired): Designed to used - when constant must be implicitly convertible. - - * convert.cs (ImplicitReferenceConversion): Reuse ToType. - - * ecore.cs (NullCast): Derives from NullConstant. - - * expression.cs (Is.DoResolve): Removed useless variables. - (Conditional.DoResolve): Quick hack for `Foo () ? null : null'. - (New.Constantify): Add enum support. - (MemberAccess.DoResolve): Add warning when accessing null constant or - variable. - - * generic.cs (GenericConstraints.IsReferenceType): Another dummy - property. - - * literal.cs (NullConstant): New abstract class with common - functionality for all null specializations. - (NullDefault): Represents default(X) when result can be - reduced to null. - (NullLiteral): Updated. - - * report.cs: Add new warning. - -2006-09-21 Martin Baulig - - * generic.cs (GenericTypeParameterBuilder): Removed this ugly hack. - -2006-09-21 Martin Baulig - - * generic.cs (GenericConstraints): New dummy class. - (Constraints): Likewise. - (TypeParameter): Likewise. - (TypeParameterName): Likewise. - (GenericMethod): Likewise. - - * typemanager.cs (TypeManager.GetGenericArguments): New method. - - * decl.cs: Merged with the gmcs version. - -2006-09-21 Raja R Harinath - - * generic.cs (TypeParameter): Implement IMemberContainer. - (GenericTypeParameterBuilder): New. An abominable repugnant hack. - - * rootcontext.cs: Unify with gmcs version. - - * report.cs: Unify with gmcs version. - * typemanager.cs (AddTypeParameter, LookupTypeParameter): Move - from gmcs/generics.cs. - * generics.cs (TypeParameter): New dummy class. - - * support.cs: Unify with gmcs version. - -2006-09-20 Raja R Harinath - - * ecore.cs (MethodGroupExpr.ResolveGeneric): New dummy method. - * expression.cs (MemberAccess, BaseAccess): Remove GMCS_SOURCE #ifdef. - - * decl.cs (MemberName): Unify with gmcs, except for GetTypeExpression. - * generic.cs (TypeArguments): New dummy class to help avoid #ifdefs. - * mcs.exe.sources: Add generic.cs. - - * codegen.cs: Unify with gmcs version. - - * codegen.cs (IResolveContent.GenericDeclContainer): Copy from gmcs. - (EmitContext): Add GenericDeclContainer implementation. - * decl.cs (MemberCore, DeclSpace): Likewise. - * namespace.cs: Remove #ifdef GMCS_SOURCE. - - * namespace.cs (GetTypeInAssembly): Remove #ifdef GMCS_SOURCE. - MCS TypeManager has a corresponding dummy method. - -2006-09-19 Martin Baulig - - * expression.cs: Completely merged with the gmcs version. - -2006-09-19 Martin Baulig - - * expression.cs (Invocation): Merged with the gmcs version. - (ArrayAccess.GetStoreOpcode): Likewise. - -2006-09-19 Martin Baulig - - * typemanager.cs - (TypeManager.IsGenericMethod): Moved here from ../gmcs/generic.cs. - (TypeManager.IsGenericMethodDefinition): Likewise. - -2006-09-19 Martin Baulig - - * typemanager.cs - (TypeManager.IsEqual): Moved the gmcs implementation here. - (TypeManager.DropGenericTypeArguments): Likewise. - (TypeManager.DropGenericMethodArguments): Likewise. - (TypeManager.GetTypeArguments): Moved here from gmcs. - (TypeManager.HasGenericArguments): Likewise. - -2006-09-19 Martin Baulig - - * expression.cs (Binary): Merged with the gmcs version. - -2006-09-19 Martin Baulig - - * expression.cs (Probe, As, Is): Merged with the gmcs version. - -2006-09-19 Martin Baulig - - * typemanager.cs: Merged with the gmcs version. - -2006-09-16 Raja R Harinath - - * AssemblyInfo.cs [GMCS_SOURCE]: Unify with gmcs source. - * driver.cs: Likewise. - -2006-09-16 Marek Safar - - A fix for #79401 - * class.cs (MethodCore.VerifyClsCompliance): Do check for abstract members - only if parent type is class. - * decl.cs (MemberCore.GetClsCompliantAttributeValue): Fixed missing cache - update. - -2006-09-15 Marek Safar - - * cs-parser.jay, - * expression.cs(MemberAccess.DoResolve): Don't crash when not allowed - keywords are used. - * typemanager.cs(CSharpName): Converts NullType to null. - -2006-09-15 Martin Baulig - - * typemanager.cs - (TypeManager.GetMethodName): Added mcs implementation. - (TypeManager.IsEqual): Likewise. - - * ecore.cs - (SimpleName.RemoveGenericArity): Added dummy implementation. - - * pending.cs: Merged with the gmcs version. - -2006-09-15 Martin Baulig - - * statement.cs: Merge with the gmcs version. - -2006-09-15 Martin Baulig - - * statement.cs (Switch): Merge with the gmcs implementation - (without nullables), which is newer. - -2006-09-15 Martin Baulig - - * statement.cs (Block.Variables): Make this public. - (ToplevelBlock.Parameters): Make this a property. - (Throw.Resolve): Use `TypeManager.IsSubclassOf ()'. - -2006-09-15 Martin Baulig - - * namespace.cs: Merge with the gmcs version. - -2006-09-15 Martin Baulig - - * decl.cs (MemberName): Minor code cleanups. - -2006-09-15 Martin Baulig - - * parameter.cs: Merge with the gmcs version. - -2006-09-15 Martin Baulig - - * enum.cs: Merge with the gmcs version: 3005 is a warning in gmcs - and an error in mcs. - -2006-09-15 Martin Baulig - - * flowanalysis.cs: Merged from GMCS; added the generics code into - a `GMCS_SOURCE' conditional so we can share this file. - -2006-09-08 Martin Baulig - - * typemanager.cs (TypeManager.interlocked_type): New public field. - (TypeManager.int_interlocked_compare-exchange): New public field. - (TypeManager.InitEnumUnderlyingTypes): Also initialize the - enumerator types here and call InitGenericCoreTypes(). - (TypeManager.InitCoreTypes): Call InitEnumeratorTypes() right - after calling InitEnumUnderlyingTypes(). - - * rootcontext.cs - (RootContext.ResolveCore): Added `System.Threading.Interlocked' to - `classes_second_stage'. - -2006-09-14 Marek Safar - - * assign.cs, ecore.cs, expression.cs: Share error message text. - * class.cs (FieldMember.Define): Check for varible of static type. - * driver.cs (LoadAssembly): Uses error output for errors. - * statement.cs: Updated. - -2006-09-08 Marek Safar - - * expression.cs (Error_OperatorCannotBeApplied): Report type instead of - type instance. - -2006-09-07 Martin Baulig - - * driver.cs - (MainDriver): Revert r62663 from Marek; see #70506 for details. - -2006-08-29 Miguel de Icaza - - * cs-parser.jay: Turn 1522 into a warning, instead of an error #79210 - -2006-08-17 Miguel de Icaza - - * cs-tokenizer.cs: Apply patch from Atsushi Enomoto that fixes - #52019 and #79064, the use of the \uXXXX sequence in source code - to represent unicode characters. - -2006-08-15 Marek Safar - - * expression.cs (SizeOf.DoResolve): Check for void type. Fixed enum types - support. - * class.cs, ecore.cs, statement.cs: Merged to one error message. - -2006-08-13 Miguel de Icaza - - * assign.cs: Catch attempts to assign to a method groups in += and - report as 1656 - -2006-08-13 Marek Safar - - A fix for #79056 - * cs-parser.jay: Don't destroy current array type by typeof of array's. - -2006-08-12 Marek Safar - - * class.cs (Method.Define): Issue a warning when generic method looks like - an entry point. - * decl.cs (MemberCore.GetSignatureForError): Print member type arguments - as well. - -2006-08-09 Marek Safar - - * anonymous.cs(AnonymousDelegate.Emit): Uses Constructor filter when - looking for ctor. - * decl.cs (MemberCache.FindMembers): When container is interface we need to - search all base interfaces as a member can be ambiguous. - * delegate.cs (Delegate.FindMembers): Fixed to return valid data for - Constructor member type filter. - (Delegate.ResolveConstructorMethod) Uses Constructor filter. - * ecore.cs: (Expression.MemberLookup): Implemented ambiguity error/warning - reporting for returned memberinfos. - * report.cs: Updated. - * typemanager.cs (TypeManager.LookupBaseInterfacesCache): Uses TypeManager - version to work on all runtimes. - (TypeManager.RealMemberLookup): Removed members filtering. - -2006-08-08 Raja R Harinath - - * ecore.cs (FieldExpr.EmitAssign): Release temporary. - (PropertyExpr.EmitAssign): Likewise. - * expression.cs (Indirection.EmitAssign): Likewise. - (LocalVariableReference.EmitAssign): Likewise. - (ParameterReference.EmitAssign): Likewise. - (Invocation.EmitArguments): Likewise. - (ArrayAccess.EmitAssign): Likewise. - (IndexerAccess.EmitAssign): Likewise. - (This.EmitAssign): Likewise. - (ConditionalLogicalOperator.Emit): Likewise. - - Fix #79026 - * codegen.cs (EmitContext.GetTemporaryLocal): Simplify. Use Stack - instead of ArrayList. If the hashtable has a LocalBuilder, don't - leave it in after returning it. - (EmitContext.FreeTemporaryLocal): Simplify. Update to changes. - -2006-08-06 Marek Safar - - * expresssion.cs (IndexerAccess.DoResolve): Fixed to report correct error - message. - -2006-08-03 Raja R Harinath - - Fix cs0146-3.cs and cs0146-4.cs. - * class.cs (TypeManager.CheckRecursiveDefinition): Check that - enclosing types don't depend on the current type. - -2006-08-02 Raja R Harinath - - Fix #77963 - * class.cs (TypeContainer.DoDefineMembers): Use - FindBaseMemberWithSameName on Parent, since we're interested in - whether we hide inherited members or not. - (FindBaseMemberWithSameName): Make slightly more robust. - - Fix the non-generic testcase from #77396 - * decl.cs (DeclSpace.DeclContainer): Remove override. - - * namespace.cs (NamespaceEntry.Doppelganger): Create slave - declspaces for doppelgangers too. - (UsingEntry): Implement IResolveContext. - (UsingEntry.Resolve): Don't set ToplevelTypes.Namespace. Use - 'this' as the resolve context. - (LocalAliasEntry): Likewise. - - Implement parts of #77403 - * roottypes.cs (RootDeclSpace): New. Used to represent the - toplevel declaration space. Each namespace declaration introduces - a "partial" root declaretion space. - * namespace.cs (NamespaceEntry.SlaveDeclSpace): New. - (NamespaceEntry.ctor): Create a SlaveDeclSpace if necessary. - * cs-parser.jay (CSharpParser.ctor): Initialize 'current_class' - from 'current_namespace.SlaveDeclSpace'. - (namespace_declaration): Likewise. - * class.cs (TypeContainer.ctor): Remove parent==ToplevelTypes - check. It can't happen now. - * decl.cs (DeclSpace.LookupType): Likewise. - * driver.cs (MainDriver): Sanity check. - -2006-08-01 Raja R Harinath - - * decl.cs (DeclSpace.FindNestedType): Remove. - (DeclSpace.LookupNestedTypeINHierarchy): Use PartialContainer and - LookupTypeContainer to get the container of the nested type. - * class.cs (TypeContainer.FindNestedType): Make non-override. - -2006-07-31 Raja R Harinath - - * decl.cs (DeclSpace.PartialContainer): Move field from ... - * class.cs (TypeContainer.PartialContainer): ... here. - (TypeContainer.AddBasesForPart): New helper. - (MemberBase.ParentContainer): Remove. Use Parent.PartialContainer - instead. - * cs-parser.jay (current_class): Convert to DeclSpace. - (struct_declaration, interface_declaration, class_declaration): - Use AddBasesForPart instead of .Bases directly. - * const.cs, iterators.cs: Update to changes. - -2006-07-28 Raja R Harinath - - * class.cs (TypeContainer.AddMemberType): Rename from - AddToTypeContainer. - (TypeContainer.AddMember): Rename from AddToMemberContainer. - (AddTypeContainer): New. Combine AddClassOrStruct and - AddInterface. - (AddPartial): Update. Add 'is_partial' argument. - * roottypes.cs: Update to changes. - * cs-parser.jay (push_current_class): New helper for handling - current_container and current_class. - (struct_declaration, interface_declaration, class_declaration): - Use it. - -2006-07-26 Raja R Harinath - - * roottypes.cs: Rename from tree.cs. - - Rename RootContext.Tree.Types to RootContext.ToplevelTypes. - * tree.cs (Tree, ITreeDump): Remove types. - * rootcontext.cs (tree, Tree): Remove fields. - (root, ToplevelTypes): New. - * *.cs: Update to rename. - - * tree.cs (Tree.RecordDecl): Remove. - (RootTypes.AddToTypeContainer): Record the toplevel type in its - namespace here. - * class.cs, cs-parser.jay: Remove mention of RecordDecl. - -2006-07-23 Raja R Harinath - - * codegen.cs (EmitContext.Flags): Move InCatch, InFinally, - DoFlowAnalysis and OmitStructFlowAnalysis here. - (ec.With): Rename from WithUnsafe and generalize. - (ec.WithCheckState): Remove. All users can be handled by 'With'. - (ec.WithFlowAnalyis): New. - * ecore.cs, expression.cs, statement.cs: Update. - -2006-07-22 Raja R Harinath - - * statement.cs (Block.ResolveMeta): Simplify slightly. - - * codegen.cs (EmitContext.Flags): New enum. Used to represent the - multiple boolean fields. Convert InUnsafe, constant_check_state, - check_state to flags. - (CheckState, ConstantCheckState): Update. - (InUnsafe): New read-only property. - (FlagsHandle): Rename from CheckStateHandle and convert to handle - arbitrary flags. - (WithUnsafe): New helper similar to WithCheckState. - * statement.cs (Block.ResolveMeta): Use WithUnsafe. - (Unsafe.Resolve, Unsafe.DoEmit): Likewise. - -2006-07-21 Raja R Harinath - - Make comparisons use the same IL irrespective of whether they're - in a 'checked' or 'unchecked' context: one of the issues in #78899 - * codegen.cs (EmitContext.CheckState): Make read-only property. - (EmitContext.ConstantCheckState): Likewise. - (EmitContext.CheckStateHandle, EmitContext.WithCheckState): New - helper that implement a save/restore stack for CheckState - values. This is the only way to change check-state. - * ecore.cs (Expression.ExpressionToArrayArgument): Use WithCheckState. - * expression.cs (CheckedExpr.DoResolve, CheckedExpr.Emit): Likewise. - (CheckedExpr.EmitBranchable): New forwarding method. - (UnCheckedExpr): Likewise. - * statement.cs (Block.ResolveMeta): Use WithCheckState. - (Unchecked.Resolve, Unchecked.DoEmit): Likewise. - (Checked.Resolve, checked.DoEmit): Likewise. - -2006-07-20 Miguel de Icaza - - * anonymous.cs: Cache the resolved anonymous delegate, and return - this so that the ResolveTopBlock is only triggered once, not - twice. - - Currently we trigger ResolvetopBlock twice due to a first pass of - argument check compatibility, and a second pass that does the - actual resolution. - -2006-07-15 Marek Safar - - * annonymous.cs (AnonymousMethod.CreateScopeType): Fixed nested type - modifiers. - * rootcontext.cs (Reset): Add helper_classes. - -2006-07-15 Marek Safar - - A fix for #78860 - * statement.cs (Switch.SimpleSwitchEmit): Handle case null at any position - correctly. - -2006-07-13 Miguel de Icaza - - * statement.cs (Lock): Handle expressions of type - TypeManager.null_type specially. Fixes #78770 - -2006-07-08 Marek Safar - - * expression.cs (Binary.ResolveOperator): Don't crash when null is assigned - to an event. - -2006-07-08 Marek Safar - - * attribute.cs (AttributeTester.GetMethodObsoleteAttribute): Fixed to look - for accessors as well. - * ecore.cs (EventExpr): Add AccessorTable. - -2006-07-01 Marek Safar - - A fix for #78738 - * attribute.cs, class.cs, ecore.cs : Add missing location of related symbol - for CS0122 where appropriate. - * typemanager.cs (IsNestedChildOf): Type can be null in the case of top - level attributes. - (Filter): Assembly can be null in the case of top level attributes. - -2006-06-25 Marek Safar - - A fix for #78690 - - * ecore.cs (Expression.MemberLookupFailed): Don't crash when failed lookup - is done at global level. - -2006-06-24 Marek Safar - - A fix for #77002, Implemented TypeForwarder support. - - * attribute.cs (Attribute.GetArgumentType): Reads type argument. - * expression.cs (TypeOf.TypeArgument): Exposes typeof type. - * typemanager.cs (): Add type_forwarder_attr_type. - -2006-06-24 Marek Safar - - * report.cs: Add CS0469 warning. - -2006-06-21 Martin Baulig - - * codegen.cs (CodeGen.Save): Moved the symbol file generation into - the `try'-block, so we also report CS0016 etc. there. - -2006-06-21 Martin Baulig - - * delegate.cs - (Delegate.VerifyMethod): Allow `params' methods; fixes #78678. - -2006-06-21 Martin Baulig - - * expression.cs (Unary.ResolveOperator): In `Operator.AddressOf', - also report CS1686 for parameters. - -2006-06-21 Martin Baulig - - * statement.cs (GotoCase.Resolve): Report a warning (CS0469) - instead of an error if the value is not implicitly convertible to - the switch types; fixes #77964. - -2006-06-21 Raja R Harinath - - Fix #78673 - * class.cs (FieldBase.ResolveInitializer): Stop resolution if - FieldBuilder is null. - - Fix #78662 - * expression.cs (Binary.CheckShiftArguments): Don't overwrite original - 'left' and 'right' before error-checking. - -2006-06-16 Juraj Skripsky - - * ecore.cs (SimpleName.Error_ObjectRefRequired): Do not truncate the name. - Fixed bug #78601. - (MemberExpr.EmitInstance): Use GetSignatureForError () to get full name. - (FieldExpr.DoResolve): likewise. - (PropertyExpr.InstanceResolve): likewise. - (EventExpr.InstanceResolve): likewise. - -2006-06-04 Marek Safar - - * parameter.cs (Parameter.ApplyAttributeBuilder): More DefaultValue - attribute applicable tests for attribute argument. - -2006-06-02 Raja R Harinath - - Fix #78079 - * expression.cs (Binary.DoNumericPromotions): Remove and rewrite. - (Binary.OverloadResolve_PredefinedIntegral): New. - (Binary.OverloadResolve_PredefinedFloating): New. - (Binary.OverloadResolve_PredefinedString): New. - (Binary.ResolveOperator): Use those instead of DoNumericPromotions. - Follow the standard more closely, and treat numeric promotions in - terms of overload resolution. - (Binary.CheckShiftArguments): Simplify. - -2006-06-01 Raja R Harinath - - * flowanalysis.cs (MyBitVector): Simplify representation. - (MyBitVector.Clone): Avoid allocating BitArray. - (MyBitVector.operator&): Rename from MyBitVector.And and make symmetric. - (MyBitVector.operator|): Likewise, with MyBitVector.Or. - (*): Update. Change all references to MyBitVector.And and - MyBitVector.Or to &= and |=. - -2006-05-29 Raja R Harinath - - Fix cs0231-[34].cs. - * cs-parser.jay (formal_parameter_list): Extend the pattern below - to param arguments too. - -2006-05-26 Miguel de Icaza - - * cs-parser.jay: Catch another parsing form for arglist being - followed by other arguments. Fixes #78313. - -2006-05-24 Raja R Harinath - - * flowanalysis.cs (FlowBranchingToplevel.AddReturnOrigin): Move - checking of out parameters to ... - (FlowBranchingToplevel.Merge): ... here. - (FlowBranchingException.AddBreakOrigin): If 'finally_vector' is - set, propagate the origin upward, and only complain if there was - no other error. - (FlowBranchingException.AddContinueOrigin): Likewise. - (FlowBranchingException.AddReturnOrigin): Likewise. - (FlowBranchingException.AddGotoOrigin): Likewise. - -2006-05-23 Raja R Harinath - - * flowanalysis.cs (UsageVector.MergeOrigins): If an origin is - unreachable, skip it. - (FlowBranchingException.Merge): Always propagate jumps, even if - the finally block renders subsequent code unreachable. - -2006-05-18 Raja R Harinath - - Fix #77601 - * statement.cs (Goto.Resolve): Move responsibility for resolving - 'goto' to FlowBranching.AddGotoOrigin. - (Goto.SetResolvedTarget): New. Callback to set the - LabeledStatement that's the target of the goto. - (Goto.DoEmit): Use Leave instead of Br when crossing an - unwind-protect boundary. - * flowanalysis.cs (FlowBranching.AddGotoOrigin): Rename from - LookupLabel and adjust to new semantics. - (FlowBranchingToplevel.AddGotoOrigin): Likewise. - (FlowBranchingBlock.AddGotoOrigin): Likewise. Use - Goto.SetResolvedTarget to update target. - (FlowBranchingLabeled.AddGotoOrigin): Likewise. - (FlowBranchingException.AddGotoOrigin): Rewrite to be similar to - AddBreakOrigin & co. Delay propagation until ... - (FlowBranchingException.Merge): ... this. - - * statement.cs (Block.Resolve): Always depend on flow-branching to - determine unreachability. Kill workaround that originally emitted - only one statement after an "unreachable" label (see infloop in - test-515.cs). - - Fix #77869, #76148, #77755, #75255 and a host of other bugs. - This is still "wrong", but anything better would probably need a - multi-pass algorithm. - * flowanalysis.cs (FlowBranchingLabeled): Salt away a copy of the - usage vector. Force current usage vector to be reachable, to - optimistically signify backward jumps. - (FlowBranchingLabeled.LookupLabel): Note if a backward jump is - detected. - (FlowBranchingLabeled.Merge): New. If no backward jump was - detected, return the original salted-away usage vector instead, - updated with appropriate changes. Print unreachable warning if - necessary. - * statement.cs (Block.Resolve): Don't print unreachable warning on - a labeled statement. - -2006-05-17 Gert Driesen - - * driver.cs: Pass filename without path to AssemblyBuilder's - AddResourceFile. Fixes bug #78407. - -2006-05-17 Raja R Harinath - - * statement.cs (LabeledStatement.Resolve): Move merging of origins ... - * flowanalysis.cs (FlowBranchingLabeled): ... here. - (FlowBranching.MergeChild): Overwrite - reachability information from Labeled branchings too. - -2006-05-16 Raja R Harinath - - * statement.cs (Goto.Resolve): Merge jump origins here ... - * flowanalysis.cs (FlowBranching.Label): ... rather than here. - - * flowanalysis.cs (FlowBranching.LookupLabel): Move CS0159 check ... - (FlowBranchingToplevel.LookupLabel): ... here. Add CS1632 check. - (FlowBranchingGoto.LookupLabel): New. Handle back jumps. - (FlowBranchingBlock.LookupLabel): Call LabeledStatement.AddReference - here, ... - * statement.cs (Goto.Resolve): ... not here. - (Goto.Emit): Remove CS1632 check. - -2006-05-14 Marek Safar - - * ecore.cs (Expression.ResolveAsTypeTerminal): Fixed type in the obsolete - error message. - -2006-05-11 Raja R Harinath - - * flowanalysis.cs (UsageVector.MergeJumpOrigins): Kill. - (FlowBranchingBlock.Label): Use UsageVector.MergeOrigins. - (FlowBranchingException.Label): Likewise. - - * flowanalysis.cs (MyBitVector.SetAll): New. Sets all bits to the - given value. - (MyBitVector.Or): Use it to avoid losing information (Count). - (FlowBranching.MergeOrigins): Likewise. - - * flowanalysis.cs (UsageVector.IsDirty): Remove. - (UsageVector.Parameters, UsageVector.ParameterVector): Likewise. - (UsageVector.Locals, UsageVector.LocalVector): Likewise. - (UsageVector.ToString): Simplify. - (UsageVector.MergeSiblings): Move here from ... - (FlowBranching.Merge): ... here. - (FlowBranchingToplevel.CheckOutParameters): Take an UsageVector, - not a MyBitVector. - -2006-05-10 Raja R Harinath - - * flowanalysis.cs (UsageVector.MergeOrigins): Simplify, now that a - null bitvector is treated as all-true. - - * flowanalysis.cs (MyBitVector.And, MyBitVector.Or): Make lazier. - (MyBitVector): Rationalize invariants. 'vector != null' implies - that we have our own copy of the bitvector. Otherwise, - 'InheritsFrom == null' implies all inherited bits are true. - -2006-05-09 Marek Safar - - * statement.cs (LocalInfo): Add IsConstant. - (LocalInfo.DeclareLocal): Moved from EmitMeta and changed to don't emit - local variable for constants. - -2006-05-09 Raja R Harinath - - * flowanalysis.cs (MyBitVector.Empty): New. - (MyBitVector): Don't allow InheritedFrom to be null. - (MyBitVector.And, MyBitVector.Or): Treat 'null' as all-ones. - (UsageVector, FlowBranching): Update to changes. - - * flowanalysis.cs (FlowBranching.InTryWithCatch): Don't terminate - recursion. The 'Parent == null' condition isn't sufficient for - anonymous methods. - (FlowBranching.AddBreakOrigin): Likewise. - (FlowBranching.AddContinueOrigin): Likewise. - (FlowBranching.AddReturnOrigin): Likewise. - (FlowBranching.StealFinallyClauses): Likewise. - (FlowBranching.MergeTopBlock): Move to FlowBranchingToplevel. - (FlowBranching.CheckOutParameters): Likewise. - (FlowBranchingToplevel): Terminate all the above recursions here. - (FlowBranchingToplevel.End): Rename from MergeTopBlock. - * codegen.cs (EmitContext.ResolveTopBlock): Update to changes. - - * flowanalysis.cs (BranchingType.Toplevel): New. Represents a - toplevel block. - (FlowBranchingToplevel): New. Empty for now. - (FlowBranching.MergeTopBlock): Update. - * codegen.cs (EmitContext.ResolveTopBlock): Create a Toplevel - branching for the anonymous delegate. - (EmitContext.StartFlowBranching): Add ToplevelBlock variant. - - * flowanalysis.cs (UsageVector.MergeOrigins): Reorganize. - (UsageVector.MergeJumpOrigins): Don't ignore current reachability - information at the start of the merge. Reorganize. - -2006-05-07 Marek Safar - - * class.cs (MethodData.Define): Method cannot implement interface accessor. - -2006-05-07 Marek Safar - - * expression.cs (QualifiedAliasMember.ResolveAsTypeStep): Pass location - to newly introduced ctor. - - * namespace.cs (Namespace.Error_NamespaceDoesNotExist): Moved an error - message to one place. - (GlobalRootNamespace.Error_NamespaceDoesNotExist): Custom message for - global namespace. - -2006-05-07 Marek Safar - - * const.cs (Const.Error_ExpressionMustBeConstant): Better error message. - - * ecore.cs (Expression.ResolveAsConstant): Updated. - - * statement.cs (ResolveMeta): Updated. - -2006-05-06 Marek Safar - - * cs-parser.jay: __arglist cannot be used in initializer. - -2006-05-06 Marek Safar - - A fix for #77879 - * namespace.cs (LocalAliasEntry.DoResolve): Don't allow to access nested - private types. - -2006-05-05 Raja R Harinath - - * statement.cs (EmptyStatement.ResolveUnreachable): Override. - (LabeledStatement): Add 'name' parameter. - (LabeledStatement.Name, LabeledStatement.JumpOrigins): New. - (Block.AddLabel): Update to changes. - * cs-parser.jay (labeled_statement): Likewise. - - * flowanalysis.cs (BranchingType.Labeled): New. - (UsageVector.MergeOrigins): Remove unused 'branching' argument. - (FlowBranchingLabeled): New. Does nothing for now, but will - eventually handle 'goto' flows. - * codegen.cs (StartFlowBranching): Add new LabeledStatement variant. - * statement.cs (LabeledStatement.Resolve): Create a FlowBranching - that's terminated ... - (Block.Resolve): ... here. - - * flowanalysis.cs (UsageVector.MergeFinally): Remove. - (UsageVector.MergeFinallyOrigins): Likewise. - (FlowBranching.InTryOrCatch): Likewise. - (FlowBranching.AddFinallyVector): Likewise. - (FlowBranchingException): Update to changes. - - Fix #78290 - * statement.cs (Return.Resolve): Move error checking to ... - * flowbranching.cs (FlowBranching.AddReturnOrigin): ... this. - (FlowBranchingException): Handle return origins like break and - continue origins. - (FlowBranching.UsageVector.CheckOutParameters): Remove. - -2006-05-04 Marek Safar - - A fix for #76122 - * class.cs (TypeContainer.FindMembers): Includes event method in the methods - filter. - -2006-05-04 Marek Safar - - A fix for #77543 - * class.cs (MethodData.Define): Do public accessor check only when method - implements an interface. - -2006-05-04 Raja R Harinath - - Remove special handling of 'break' - * flowanalysis.cs (Reachability): Remove all mention of 'breaks'. - (Reachability.Meet): Simplify. Remove 'do_breaks' argument. - (UsageVector.Break): Remove. - (FlowBranching.Merge): Use 'Reachable.IsUnreachable' to determine - reachability. - (FlowBranchingBreakable.Merge): Don't ResetBreaks. - - * statement.cs (Break.Resolve): Call UsageVector.Goto (), not - UsageVector.Breaks (). Don't set NeedsReturnLabel. - -2006-05-03 Marek Safar - - A fix for #75726 - * pending.cs (PendingImplementation.BaseImplements): A found member cannot - be the interface member. - -2006-05-03 Marek Safar - - A fix for #60069 - * constant.cs (LongConstant.EmitLong): Fixed to catch also negative values - for emitting small (int) values. - -2006-05-03 Raja R Harinath - - Fix #59427 - * flowanalysis.cs (FlowBranchingException.Merge): Ensure - control-flow passes through the 'finally' after merging-in all the - control-flows from 'try' and the 'catch' clauses. - - * flowanalysis.cs (FlowBranching.IsLoop): Remove. - (FlowBranching.IsTryOrCatch): Remove 'is_return' parameter. It's - always true at the only non-recursive entry point. - (FlowBranching.CreateBranching) [BranchingType.Loop]: Return a - FlowBranchingBreakable. - (FlowBranchingLoop): Remove. - * statement.cs (Return.DoResolve): Update to changes. - - Fix #76471, #76665 - * flowanalysis.cs (FlowBranching.BranchingType.Embedded): New. - (FlowBranching.CreateBranching): Handle it: create a - FlowBranchingContinuable. - (FlowBranching.BreakCrossesExceptionBoundary): Remove. - (FlowBranching.AddContinueOrigin): Similar to AddBreakOrigin, - except that it handles the 'continue' command. - (FlowBranching.UsageVector.MergeOrigins): Rename from - MergeBreakOrigins. - (FlowBranchingContinuable): Similar to FlowBranchingBreakable, - except that it overrides AddContinueOrigin. - (FlowBranchingException): Override AddContinueOrigin, similar to - AddBreakOrigin. - * statement.cs (While.Resolve, Foreach.ArrayForeach.Resolve): - Create a new branching around the embedded statement. - (Do.Resolve, For.Resolve): Likewise. Do reachability analysis for - control flow after the embedded statement. - (Continue.Resolve): Move all error checking to AddContinueOrigin. - - * flowanalysis.cs (FlowBranching.IsSwitch): Remove. - (FlowBranching.CreateBranching) [BranchingType.Switch]: Create a - FlowBranchingBreakable. - (FlowBranchingSwitch): Remove. - - Fix test-503.cs - * statement.cs (Break.Resolve): Simplify. Move responsibility for - error reporting to ... - * flowanalysis.cs (FlowBranching.AddBreakOrigin) ... this. - Rename from 'AddBreakVector'. Add new location argument. Return - a bool indicating whether the 'break' crosses an unwind-protect. - (FlowBranchingException.AddBreakOrigin): Add. - (FlowBranchingException.Merge): Propagate 'break's to surrounding - flowbranching after updating with the effects of the 'finally' - clause. - (FlowBranchingBreakable): New common base class for - FlowBranchingLoop and FlowBranchingSwitch. - - * statement.cs (Foreach.ArrayForeach.Resolve): Set barrier after - embedded statement. - (Foreach.CollectionForeach.Resolve): Remove extraneous flowbranching. - -2006-05-02 Raja R Harinath - - * statement.cs (Do.Resolve): If the loop is infinite, set the - barrier. - (While.Resolve, For.Resolve): Set a barrier after the embedded - statement. There's no direct control flow that goes from the end - of the embedded statement to the end of the loop. - * flowanalysis.cs (FlowBranching.Infinite): Remove. - (FlowBranchingLoop.Merge): Don't look at 'Infinite'. The changes - above ensure that the reachability is correctly computed. - - * flowanalysis.cs (Reachability.ResetBarrier): Remove. - (UsageVector.MergeBreakOrigins): If the current path is - unreachable, treat it as if all parameters/locals are initialized. - (FlowBranchingLoop.Merge): Don't clear any barriers. Handle - infinite loops before merging-in break origins. - - * flowanalysis.cs (Reachability.Meet): Simplify code handling 'returns'. - (Reachability.Reachable): Split part into ... - (Reachability.Unreachable): ... this. Simplify. - (Reachability.IsUnreachable): Use 'Unreachable' instead. - - * flowanalysis.cs (Reachability.SetReturnsSometimes): Remove. - (Reachability.SetThrowsSometimes): Likewise. - (FlowBranchingBlock.MergeTopBlock): Don't compare against - TriState.Always, use corresponding property. - * statement.cs (Lock.Resolve, Try.Resolve, Using.Resolve): Likewise. - (Block.Resolve): Likewise. Remove some redundant checks. - -2006-05-02 Raja R Harinath - - * flowanalysis.cs (UsageVector.Throw): Set barrier too. - (Reachability.Meet): Don't bother checking AlwaysThrows -- - barrier is always set. - (FlowBranchingBlock.Merge): Likewise. - -2006-05-01 Raja R Harinath - - * codegen.cs (EmitContext.ResolveTopBlock): Remove redundant - checks for unreachable. - -2006-05-01 Marek Safar - - A fix for #77980 - * flowanalysis.cs (UsageVector.IsAssigned): Add flag to ignore short path. - - * statement.cs (Block.UsageWarning): Uses newly introduced flag to detect - whether field is really assigned. - -2006-04-30 Raja R Harinath - - * flowanalysis.cs (Reachability): Make 4-argument constructor - private. - (Reachability.Meet): Rename from 'And'. Remove static variant. - (Reachability.Always): Rename from the highly misleading - 'Reachability.Never'. - (FlowBranching.Merge): Update to changes. Mark an impossible - situation with a 'throw'. - (*): Update to changes. - -2006-04-29 Raja R Harinath - - * flowanalysis.cs (TriState): Rename from FlowBranching.FlowReturns. - Remove 'Undefined'. - (FlowBranching.TriState_Meet): Rename from AndFlowReturns. Simplify. - (FlowBranching.TriState_Max): Rename from OrFlowReturns. Simplify. - (*): Update to changes. - * statement.cs: Update to changes. - -2006-04-28 Marek Safar - - A fix for #78049 - *class.cs (Method.FindOutBaseMethod): Base method cannot be property method. - -2006-04-28 Raja R Harinath - - * flowanalysis.cs (FlowBranching.MergeTopBlock): Don't create a - dummy UsageVector. - - * flowanalysis.cs (UsageVector.MergeChild): Change FlowBranching - argument to two arguments: an usage-vector and a bool. Move call - to FlowBranching.Merge () ... - (FlowBranching.MergeChild, FlowBranching.MergeTopBlock): ... here. - - * flowanalysis.cs (UsageVector.MergeChild): Move special-case - handling of loop and switch reachability to ... - (FlowBranchingLoop.Merge, FlowBranchingSwitch.Merge): ... these. - -2006-04-27 Raja R Harinath - - * flowanalysis.cs (FlowBranching.InLoop): Move special-case - handling to FlowBranchingLoop.InLoop. - (FlowBranching.InSwitch): Likewise, to FlowBranchingSwitch. - -2006-04-26 Marek Safar - - A fix for #78115 - * anonymous.cs (AnonymousMethod.DoResolve): Moved the check whether - anonymous method is allowed from AnonymousContainer here. - - * attribute.cs, codegen.cs (EmitContext): Add IsAnonymousMethodAllowed. - -2006-04-24 Raja R Harinath - - Fix #78156 - * flowanalysis.cs (MyBitVector.Or): Add null check on argument. - -2006-04-23 Marek Safar - - A fix for #49011. - * constant.cs (FloatConstant.Reduce): Add range checking for checked context. - (DoubleConstant.Reduce): Ditto. - -2006-04-23 Raja R Harinath - - * expression.cs (LocalVariableReference.DoResolveBase): Simplify. - Remove 'lvalue_right_side' argument. Move parts to ... - (LocalVariableReference.ResolveLocalInfo, LocalVariable.DoResolve) - (LocalVariable.DoResolveLValue): ... these. - -2006-04-21 Raja R Harinath - - Fix cs1655.cs - * codegen.cs (EmitContext.InRefOutArgumentResolving): Remove. - * expression.cs (EmptyExpression.LValueMemberOutAccess): New. - (LocalVariableReference.DoResolveBase): Use it to implement new - CS1655 check. - (IndexerAccess.DoResolveLValue): Handle LValueMemberOutAccess. - (Argument.Resolve): Simplify. Move CS1510 check ... - * ecore.cs (Expression.ResolveLValue): ... here. - (UnboxCast.DoResolveLValue): Handle LValueMemberOutAccess. - (PropertyExpr.DoResolveLValue): Likewise. - (FieldExpr.Report_AssignToReadonly): Likewise. - (FieldExpr.DoResolve): Add 'out_access' argument. Use - LValueMemberAccess or LValueMemberOutAccess on instance depending - on it. - (FieldExpr.DoResolveLValue): Pass 'out_access' argument to - DoResolve as appropriate. - -2006-04-20 Raja R Harinath - - Fix #75800 - * expression.cs (Invocation.VerifyArgumentsCompat): Don't try - implicit conversions on 'out' and 'ref' arguments. - - * expression.cs (Invocation.VerifyArgumentsCompat): Reorganize to - improve clarity. Remove dead code. - - Fix #66031 - * statement.cs (Block.UsageWarning): Allow VariableInfo to be null. - (Catch.Resolve): Resolve VarBlock if it exists. - -2006-04-19 Miguel de Icaza - - * statement.cs (Foreach.EmitFinally): Do not emit the enumerator - twice, this was some residual code, the enumerator was emitted - properly in the two branche of if later. - -2006-04-19 Raja R Harinath - - * expression.cs (Cast.ResolveLValue): Remove. The result of a - cast is never an lvalue. - (Cast.DoResolve, Cast.ResolveRest): Combine. - (Argument.Emit): Simplify slightly. Move 'Expr is - IMemoryLocation' check ... - (Argument.Resolve): ... here. - (Argument.Error_LValueRequired): Remove. Inline into only user. - - Simplifications. Fix cs0191-2.cs - * ecore.cs (FieldExpr.DoResolve): Move handling of CS0192, CS0198, - CS1649 and CS1651 to ... - (FieldExpr.Report_AssignToReadonly): ... this. Simplify by moving - the actual selection of the error code and message to a lookup - table. Add a dummy return value to simplify callsites. - (FieldExpr.ResolveLValue): Don't allow a constructor to write to - readonly fields of other instances of the same type. Move CS0197 - warning from ... - * expression.cs (Argument.Resolve): ... here. Simplify code. - Ensure that ec.InRefOutArgumentResolving is only set during LValue - resolution of an out or ref argument. The code simplification - above uses this invariant. - -2006-04-18 Raja R Harinath - - Possibly fix #77752. Fix cs1690-[4-7].cs. - * ecore.cs (Expression.CheckMarshalByRefAccess): Renamed from - CheckMarshallByRefAccess. Drop parameter. - (FieldExpr.CheckMarshalByRefAccess): Update. Change CS1690 to a - warning. - (FieldExpr.DoResolve): Call CheckMarshalByRefAccess on - InstanceExpression. - * report.cs (AllWarnings): Add CS1690. - * expression.cs (Argument.Resolve): Use EmptyExpression.OutAccess - for ref access too. - (LocalVariableReference.DoResolveBase): Update. - -2006-04-09 Marek Safar - - * class.cs (MethodOrOperator): Moved common parts from method class. - detect obsolete attributes. - (Method.Define): Simplified as it reuses code from base. - (Constructor.ValidAttributeTargets): Fixed issue found during - refactoring. - (Destructor.ValidAttributeTargets): Fixed issue found during - refactoring. - (Operator): Finished refactoring set off by #78020. Operator class is now - ordinary method class. - - * anonymous.cs: Updated. - - * decl.cs (DeclSpace): Add IsGeneric - -2006-04-09 Marek Safar - - * class.cs (Constructor.Emit): Don't emit the attributes twice. - -2006-04-09 Marek Safar - - * class.cs (Operator.Emit): Extracted code from MethodData to correctly - detect obsolete attributes. - (Method.CreateEmitContext): Moved to MethodOrOperator. - -2006-04-09 Marek Safar - - A fix for #78048. - * class.cs (TypeContainer.MemberCoreArrayList.DefineContainerMembers): Throw - customized exception to make crash detection easier. - (MethodOrOperator): Started to work on new base class for methods and - operators. - (Method): Derives from MethodOrOperator. - (Constructor.Emit): Emits its own attributes. - (AbstractPropertyEventMethod.Emit): Ditto. - (Operator): Derives from MethodOrOperator, will refactor fully in extra - patch. - (Operator.Emit): It's temporary more tricky than should be. - - * doc.cs (GetMethodDocCommentName): Updated after operator changes. - - * report.cs (InternalErrorException): Add ctor with inner exception. - -2006-04-08 Marek Safar - - A fix for #76744. - * ecore.cs (SimpleName.ResolveAsTypeStep): Report better error when type is - only not visible. - -2006-04-07 Marek Safar - - A fix for #77916. - * expression.cs (ArrayCreation.GetAttributableValue): Creates correctly typed - array. - -2006-04-06 Marek Safar - - * class.cs (Class.ApplyAttributeBuilder): Report an error when ComImport - attribute is present and Guid not. - (Interface.ApplyAttributeBuilder): Ditto. - - * attribute.cs: Add error message. - -2006-04-06 Marek Safar - - A fix for #78020. - - * attribute.cs (Attribute.AttachTo): The attribute can have multiple - sources (it's composite) so hold them in extra array as they are used in - Emit phase only. It worked in the previous versions by mistake. - (Attribute.Emit): Emit attribute for more owners when exist. - - * codegen.cs, class.cs: Updated to don't re-attach attribute twice as now - it has now different behaviour. - -2006-04-04 Marek Safar - - * constant.cs (Constant.IsDefaultInitializer): New method. - - * class.cs: Updated. - - * expression.cs (ArrayCreation.CheckIndices): Add an optimization to don't - re-initialize default values. It saves KBs almost for every assembly. - Thanks Zoltan for the idea. - (ArrayCreation.ResolveInitializers): Renamed from ValidateInitializers. - (ArrayCreation.DoResolve): Resolve only once. - (ArrayCreation.Emit): Emit static initializer only when it is faster. - (ArrayCreation.GetAttributableValue): Cope with optimized values. - -2006-04-03 Zoltan Varga - - * report.cs (Warning, Error): Add 0-, 1-, and 2- argument specializations. - From #77961. - -2006-04-01 Marek Safar - - * assign.cs (Assign.DoResolve): Assignment to same variable can occur - in an embedded statement too. - -2006-04-01 Raja R Harinath - - Fix #77958 - * statement.cs (Switch.EmitObjectInteger) [ulong]: Remove bad cast. - -2006-04-01 Marek Safar - - A fix for #77966. - - * class.cs (TypeContainer.AddPartial): Don't report an error when modifier - was not specified. - - * modifiers.cs: Add DEFAULT_ACCESS_MODIFER. - -2006-03-31 Marek Safar - - * assign.cs (LocalTemporary): Don't require ILGenerator in the resolve - phase. - - * anonymous.cs, assign.cs, ecore.cs, expression.cs: Updated after - LocalTemporary change. - - * class.cs (ClassOrStruct.DefineDefaultConstructor): Moved from - TypeContainer. - (ClassOrStruct.DefineFieldInitializers): Implemented static field - initializers optimization. - (ClassOrStruct.TypeAttr): Moved from modifiers. - (Constructor.CheckBase): Don't crash when static ctor has parameters. - (FieldBase.ResolveInitializer): Resolves initializer. - (FieldBase.HasDefaultInitializer): New property. - - * cs-parser.jay: Removed message. - - * expression.cs (CompilerGeneratedThis): New specialization. - - * modifiers.cs (TypeAttr): Moved to ClassOrStruct.TypeAttr - -2006-03-28 Marek Safar - - * cs-parser.jay, cs-tokenizer.cs: On demand Stack allocation. - -2006-03-27 Marek Safar - - * ecore.cs (Expression.ResolveAsConstant): Clean up, enum constants should - be now EnumConstants only. - -2006-03-27 Marek Safar - - * attribute.cs, driver.cs: Reset more caches. - -2006-03-26 Marek Safar - - * cs-tokenizer.cs (adjust_real): Uses float.Parse for float literals. - -2006-03-26 Marek Safar - - * constant.cs (Constant.Reduce): Replaced EmitContext with single bool - for easier reuse. Updated all overrides. - (IntegralConstant): New base class for all integral constants. - (IntegralConstant.Error_ValueCannotBeConverted): When assigned value if out - of the constant range, report custom error. - (UIntConstant.Reduce): Fixed uint conversion. - - * ecore.cs, literal.cs: Reduce updates. - -2006-03-26 Marek Safar - - A fix for #75813. - - * class.cs (Constructor.Define): Removed extra if for default ctors. - A patch from Atsushi Enomoto. - -2006-03-26 Marek Safar - - * attribute.cs (Attribute.ResolveConstructor): Conversion was moved to - GetAttributableValue. - - * constant.cs (Constant.GetAttributableValue): Does implicit conversion - when required. - - * convert.cs (ImplicitConversionRequired): Error message moved to - DoubleLiteral. - - * ecore.cs (Expression.GetAttributableValue): Add type parameter for - automatic implicit conversion of an output value. - (EnumConstant.GetAttributableValue): Don't reduce the enum constants. - - * expression.cs (ArrayCreation.GetAttributableValue): Add element type - conversion. - (TypeOf.GetAttributableValue): Add extra handling for object type. - - * literal.cs (DoubleLiteral.Error_ValueCannotBeConverted): Doubles can have - special error message. - -2006-03-25 Marek Safar - - * class.cs (Constructor.Emit): Don't crash when struct ctor is - InternalCall. - (Constructor.ApplyAttributeBuilder): Transform MethodImplAttribute to be - compatible with MS runtime. - -2006-03-23 Marek Safar - - * attribute.cs (Attribute.ResolveConstructor): Check for an invalid - attribute arguments here. - - * class.cs (Indexer.Define): The check was moved to attribute class. - -2006-03-22 Marek Safar - - * assign.cs, class.cs, codegen.cs, convert.cs, decl.cs, ecore.cs, - expression.cs, typemanager.cs: Minor changes from gmcs to make merging - easier. - -2006-03-22 Raja R Harinath - - Support ParameterDefaultValueAttribute in gmcs. Also applied to - mcs to keep code differences small. - * attribute.cs (Attribute.GetParameterDefaultValue): New. - * typemanager.cs (parameter_default_value_attribute_type): New. - * parameter.cs (Parameter.ApplyAttributeBuilder): Use them. Add - CS1908 check. - -2006-03-21 Marek Safar - - * expression.cs (StringConcat.Append): Reverted back to no warning state. - -2006-03-21 Marek Safar - - * const.cs (Error_ConstantCanBeInitializedWithNullOnly): Share a message. - - * statement.cs (Block.ResolveMeta): Look for wrong object constants in - the blocks too. - -2006-03-21 Atsushi Enomoto - - * doc-bootstrap.cs : fix build. - -2006-03-20 Marek Safar - - * expression.cs (StringConcat.Append): Issue a warning when empty string - is going to append. - -2006-03-20 Marek Safar - - * assign.cs (CompoundAssign.ResolveSource): Removed. - - * attribute.cs (ResolvePossibleAttributeType): Updated after MemberAccess - clean up. - - * class.cs (TypeContainer.FindMethods): Removed. - (TypeContainer.CheckMemberUsage): Made static. - - * codegen.cs (GetAssemblyName): Uses Length for empty string test. - - * constant.cs (CheckRange): Removed unused type argument. - (CheckUnsigned): Removed unused type argument. - - * cs-parser.jay: Updated after MemberAccess clean up. - Uses Length for empty string test. - - * cs-tokenizer.cs: Uses Length for empty string test. - (IsCastToken): Made static. - (is_hex): Made static. - (real_type_suffix): Made static. - - * decl.cs (SetupCache): Made static. - (OnGenerateDocComment): Removed unused ds argument. - - * delegate.cs (VerifyDelegate): Removed unused argument. - - * doc.cs: Uses Length for empty string test. - - * driver.cs: Uses Length for empty string test. - - * enum.cs (IsValidEnumType): Made static - - * expression.cs (EnumLiftUp): Removed unused argument. - (ResolveMethodGroup): Ditto. - (BetterConversion): Ditto. - (GetVarargsTypes): Ditto. - (UpdateIndices): Ditto. - (ValidateInitializers): Ditto. - (MemberAccess.ctor): Ditto. - (GetIndexersForType): Ditto. - - * flowanalysis.cs: (MergeFinally): Removed unused argument. - - * iterators.cs: Updated after MemberAccess clean up. - - * location.cs: Uses Length for empty string test. - - * namespace.cs: Uses Length for empty string test. - - * report.cs (CheckWarningCode): Made static. - - * statement.cs (LabeledStatement): Removed unused argument. - - * typemanager.cs (FilterNone): Removed. - -2006-03-18 Marek Safar - - * codegen.cs (EmitContext.TestObsoleteMethodUsage): Removed as it become - obsolete. - - * class.cs: Updated. - -2006-03-18 Marek Safar - - * cs-parser.jay.cs: __arglist is not allowed for delegates. - -2006-03-18 Marek Safar - - A fix for #77822. - - * expression.cs (VerifyArgumentsCompat): Reverted to double error - reporting, it's more tricky than I thought. - -2006-03-18 Marek Safar - - A fix for #77816. - - * anonymous.cs.cs (AnonymousMethod): Add host to allow access to - host container. - (AnonymousMethod.ImplicitStandardConversionExists): New method. - (AnonymousMethod.Compatible): Moved parameter resolving to DoResolve. - Add more error reporting; Fixed issue with params. - - * convert.cs (ImplicitStandardConversionExists): Returned conversion check. - - * cs-parser.jay: AnonymousMethod requires host container. - - * delegate.cs (NewDelegate.DoResolve): Updated after Compatible changes. - -2006-03-18 Raja R Harinath - - * class.cs: Change 'TypeContainer ds' constructor argument to - 'DeclSpace parent'. Some classes were missed below due to - different naming convention. - - * class.cs (MemberCore.Parent): Delete. This makes the - ParentContainer changes below enforceable by the compiler. - - Treat pointers to enclosing declaration space as 'DeclSpace', not - 'TypeContainer'. - * class.cs, const.cs, delegate.cs, enum.cs, iterator.cs: Change - 'TypeContainer parent' constructor argument to 'DeclSpace parent'. - - * statement.cs (LocalInfo..ctor): Use DeclSpace argument instead - of TypeContainer. - (Block.AddThisVariable): Likewise. - * class.cs (MethodData.Define, MethodData.Emit): Likewise. - (AbstractPropertyEventMethod.Emit): Likewise. - (AbstractPropertyEventMethod.EmitMethod): Likewise. - (GetMethod.Define, SetMethod.Define): Likewise. - (PropertyMethod.Define, DelegateMethod.Define): Likewise. - (DelegateMethod.EmitMethod): Likewise. - - Fix regression test-partial-13.cs. - Rationalize use of PartialContainer. Ensure that the partial - class semantics can be tied to type-correctness, i.e., any - violation will cause a compile error. - * class.cs, const.cs: Access all fields that belong to class - TypeContainer via ParentContainer. Arguments of EmitContexts and - Resolve()-like functions still use 'Parent'. - - * class.cs (SourceMethod): Use DeclSpace, not TypeContainer. - (*.CreateEmitContext): Change TypeContainer argument to DeclSpace. - (PropertyMethod.CheckModifiers): Remove unused argument. - * codegen.cs (EmitContext..ctor): Change TypeContainer argument to - DeclSpace. - -2006-03-17 Raja R Harinath - - Make semantics of PartialContainer simpler. - * decl.cs (DeclSpace.IsPartial): Remove. - * class.cs (TypeContainer.IsPartial): Likewise. - (TypeContainer..ctor): Set PartialContainer to point to self. - (TypeContainer.GetClsCompliantAttributeValue): Don't use IsPartial. - (TypeContainer.FindNestedType): Likewise. - (MemberCore.ParentContainer): Simplify. Remove deprecation. - -2006-03-17 Marek Safar - - * typemanager.cs.cs (GetInterfaces): Don't recreate 0-sized arrays. - -2006-03-15 Marek Safar - - * class.cs (FieldMember.Emit): ParentContainer is real parent for partial - classes. - -2006-03-15 Marek Safar - - * class.cs (Operator.Define): An error for base conversion was not - reported correctly. - -2006-03-14 Atsushi Enomoto - - * iterator.cs : yield break is allowed in try statement which has - catch clauses. Fixed bug #77767. - -2006-03-13 Marek Safar - - A fix for #77593, #77574. - - * class.cs (MethodCore.CheckBase): Another if for operator. - -2006-03-09 Marek Safar - - * anonymous.cs (AnonymousMethod.Compatible): Don't crash when parameters - were not resolved - - * delegate.cs (Delegate.GetInvokeMethod): Use emitcontext free MemberLookup. - (DelegateCreation.ImplicitStandardConversionExists): New method for just - conversion test. - - *ecore.cs (Expression.MemberLookup): Don't ask for emitcontext when it's - not needed. - - * assign.cs, constant.cs, convert.cs, delegate.cs, expression.cs: - Updated after another emitcontext usage was clean up. It should help us to - synchronize with gmcs easier. - -2006-03-04 Marek Safar - - A fix for #77353. - - * class.cs (SetMethod.DefineParameters): Uses new parameters type ctor. - (Event.Define): ditto - (SetIndexerMethod.DefineParameters): Uses Parameters.MergeGenerated. - - * delegate.cs (Delegate.Define): Uses Parameters.MergeGenerated. - Removed redundant code and set NewSlot for Invoke method too. - - * parameter.cs (Parameters.ctor): Add custom, type ctor. - (Parameters.MergeGenerated): New method. Use this method when you merge - compiler generated argument with user arguments. - -2006-03-03 Marek Safar - - * attribute.cs (ResolveAsTypeTerminal): Removed. - - * ecore.cs (Expression.ResolveAsTypeTerminal): Make virtual to allow - specialization for predefined types; 30% speed up. - Finally placed obsolete check to right place. - (Expression.ResolveType): Removed. - - * enum.cs, expression.cs, parameter.cs, statement.cs, typemanager.cs: - Updated after ResolveType was removed. - - * expression.cs (Cast.ctor): Check void cast. - (Binary.ResolveAsTypeTerminal): Is never type. - (Conditional.ResolveAsTypeTerminal): Is never type. - - * rootcontext.cs (ResolveCore): Set base type to simplify some code later. - -2006-03-01 Raja R Harinath - - Fix #77679. - * expression.cs (ParameterReference.DoResolveBase): Change return - type to bool. - (ParameterReference.DoResolve, ParameterReference.DoResolveLValue): - Update. - - Fix #77628. - * ecore.cs (PropertyExpr.InstanceResolve): Fix CS1540 check. - - Fix #77642. - * typemanager.cs (GetFullNameSignature): Don't nullref on - protected accessors. - -2006-02-27 Marek Safar - - * attribute.cs (Attribute.PosArguments, Attribute.NamedArguments): Use - these two separated members to simplify the code. - (Attribute.Resolve): Refactored to use new fields and methods. - (Attribute.ResolveConstructor): Extracted from ResolveArguments and - implemented obsolete attribute checking. - (Attribute.ResolveNamedArguments): Extracted from ResolveArguments and - implemented obsolete checking again. It look line never ending quest ;-) - (GlobalAttribute.ResolveConstructor): Need to override as the rest. - - * cfold.cs (BinaryFold): TryReduce throws an exception to indicate error. - - * constanct.cs (TryReduce): Throws OverflowException to indicate error. - - *class.cs (Property.Define): Add RegisterProperty call. - - * cs-parser.jay: Replaced ArrayList with fixed array for attribute - argument groups (only 2). - - * ecore.cs (Expression.GetAttributableValue): New virtual method used for - encoding expression to arguments. - (Expression.ExprClassToResolveFlags): Just turned to property. - - * expression.cs (ArrayCreation.ValidateInitializers): Slightly optimized. - (ArrayCreation.GetAttributableValue): Renamed from EncodeAsAttribute and - optimized as well as implemented support for zero-length attributes. - - * typemanager.cs (TypeManager.RegisterProperty, TypeManager.GetProperty): - Add caching of PropertyInfo's. - -2006-02-25 Marek Safar - - * delegate.cs (DelegateCreation.ResolveMethodGroupExpr): Don't report - error multiple times. - -2006-02-25 Marek Safar - - New partial class implementation. - A fix for #77027, #77029, #77403 - - * attribute.cs (Attributable): Made attributes protected. - - * class.cs (TypeContainer): Add PartialContainer and partial_parts as - the replacements of ClassPart and PartialContainer. - (TypeContainer.AddClassOrStruct): Call RecordDecl here. - (TypeContainer.AddInterface): Ditto. - (TypeContainer.AddPartial): The main method for partial classes. It checks - for errors and merges ModFlags and attributes. At the end class is added to - partial_parts list. - (TYpeContainer.DefineDefaultConstructor): Checks whether default ctor is - required here. - (TypeContainer.GetClsCompliantAttributeValue): Cope with partial class too. - (TypeContainer.GetNormalPartialBases): Resolves base classes and interfaces - from the rest of partial classes. - (TypeContainer.GetClassBases): Simplified. - (TypeContainer.DefineTypeBuilder): New method, mostly extracted from - DefineType. - (TypeContainer.DefineDefaultConstructor): Is used by derived classes. - (TypeContainer.HasExplicitLayout): Uses Flags now. - (PartialContainer): Removed. - (ClassOrStruct.AddToContainer): Moved enclosing member name check here. - (StaticClass): Was merged with Class. - (Class.GetClassBases): class and static class bases are verified here. - (Class.TypeAttr): Added static attributes when class is static. - (Struct.RegisterFieldForInitialization): Moved from TypeContainer. - (MemberBase): In some cases we need to call parent container for partial - class. It should be eliminated but it's not easy now. - - * cs-parser.jay: Replaced all PartialContainer with AddPartial. - - * decls.cs (MemberCore.DocComment): Introduced new property as is used by - partial classed to accumulate class comments. - (MemberCore.GetClsCompliantAttributeValue): Moved from TypeContainer. - - * doc.cs (GenerateTypeDocComment): Partial classes clean up. - - * driver.cs (MainDriver): Tree.GetDecl was removed. - - * modifiers.cs (Modifiers): Add partial modifier. - - * tree.cs (Tree.decl): Removed. - (RootTypes): Started to use this class more often for root types - specializations. - -2006-02-22 Marek Safar - - A fix for #77615 - - * attribute.cs (AttributeTester.GetCoClassAttribute): Don't crash when - external interface does not have an attribute. - -2006-02-22 Marek Safar - - Another prerequisites for new partial classs implementation. - - * attribute.cs (Attribute.Equal): Implemented. - (Attribute.Emit): Changed as attributes can be applied more than twice. - (Attributes.Emit): Check for duplicate attributes here. - - * class.cs, decl.cs, delegate.cs, doc.cs, enum.cs: Don't pass DeclSpace - as a parameter, clean-up. - -2006-02-11 Marek Safar - - A fix for #77485 - - * class.cs (TypeContainer.DefineType): Cannot use ResolveType because it - contains obsolete attribute check which can in some cases look for base - type of current class which is not initialized yet. - (TypeContainer.BaseType): Replacement of ptype. - - * decl.cs (MemberCore.CheckObsoleteType): Reuse existing code. - -2006-02-11 Marek Safar - - First of prerequisites for new partial classs implemention. - - * attribute.cs (Attributable): Extended by ResolveContext; - Attributes finally have correct context for resolving in all cases. - (AttachTo): Attribute owner is assigned here. - - * codegen.cs (IResolveContext): Introduce new interface to hold - all information needed in resolving phase. - (EmitContext): Implements IResolveContext; more clean-up needed here. - - * decl.cs (MemberCore): Implemented IResolveContext. - - * anonymous.cs, attribute.cs, class.cs, codegen.cs, const.cs, - decl.cs, ecore.cs, enum.cs, expression.cs, iterators.cs, namespace.cs, - parameter.cs, statement.cs, tree.cs, typemanager.cs: - Refactored to use new IResolveContext instead of EmitContext; cleanup - -2006-02-06 Miguel de Icaza - - * codegen.cs (EmitScopeInitFromBlock): check here the - capture_context, there is no need to make two calls to the - EmitContext. - - * anonymous.cs: Add some debugging messages that might help me - track other instances of this problem in the future (the - regression of test 467). - - * cs-parser.jay: track the variable block, as we need to initalize - any captured variables declared in this block for the "catch" - portion of the "Try" statement. - - * statement.cs (Try.Emit): If the "Catch" has a VarBlock, emit any - scope initialization for captured variables. - - Also, move the emit for the variables after the block location has - been marked. - -2006-02-06 Marek Safar - - * ecore.cs (PropertyExpr.FindAccessors): Just made flags const. - -2006-02-02 Miguel de Icaza - - * anonymous.cs (CaptureContext.EmitInitScope): I was wrong in the - commit yesterday, the initialization for the roots is necessary. - What is not necessary is the scope activation. - -2006-02-02 Raja R Harinath - - * ecore.cs (PropertyExpr.DoResolveLValue): Add CS0206 check. - * expression.cs (IndexerAccess.DoResolveLValue): Add CS1612 and - CS0206 checks. - (Argument.Resolve): Remove CS0206 checks. - -2006-02-01 Miguel de Icaza - - * anonymous.cs (CaptureContext.EmitInitScope): Do not emit the - scopes for all the roots, the scopes will now be emitted when the - Blocks are entered. [This change was wrong, fixed on 2006-02-02] - - (CaptureContext.EmitScopeInitFromBlock): Simply emit the ScopeInfo - code. This reduces a lot of existing cruft. - - * statement.cs (Block.Emit): Call EmitScopeInitFromBlock here, so - that the ScopeInfo is generated as we enter the scope, not at the - time of use, which is what we used to do before. - - * codegen.cs (EmitScopeInitFromBlock): New routine, this is called - every time a Block is about to be emitted if we have a - CaptureContext. - -2006-02-01 Raja R Harinath - - * typemanager.cs (NoTypes, NoTypeExprs): Remove. - (Reset): Update. - * *.cs: Use Type.EmptyTypes instead of TypeManager.NoTypes. - - * typemanager.cs (cons_param_array_attribute): Make private. - (Reset): Set it to null. - (InitCoreHelpers): Don't initialize it. - (ConsParamArrayAttribute): New. Initialize it as needed. - * parameter.cs (ParamsParameter.ApplyAttribute): Update to change. - -2006-01-31 Miguel de Icaza - - * expression.cs: There might be errors reported during the - selection of applicable methods. If there are errors, do not - continue execution as it will lead the compiler to crash. - -2006-01-30 Miguel de Icaza - - * expression.cs: Member access is not allowed on anonymous - methods. Fixes #77402. - -2006-01-30 Raja R Harinath - - Fix #77401 - * cs-parser.jay (VariableDeclaration): Don't set - current_array_type to null. - (field_declaration, event_declaration, declaration_statement): - Set it to null here. - -2006-01-28 Raja R Harinath - - * typemanager.cs (GenericParameterPosition): New. - * doc.cs: Use it. - -2006-01-28 Atsushi Enomoto - - * doc.cs : To process "include" elements, first we should create - another list than XmlNodeList, because it could result in node - removal, which could result in that the XmlNodeList gives up - yielding next node. - - (Also made code identical to gmcs again.) - -2006-01-25 Miguel de Icaza - - * ecore.cs: Introduce an error report that we were not catching - before, if not silent, we must report the error. Gonzalo ran into - it. - -2006-01-23 Miguel de Icaza - - A fix for bug: #76957 - - * iterators.cs (MoveNextMethod.CreateMethodHost): call - ComputeMethodHost before creating the method, this is a new - requirement. - - * anonymous.cs (AnonymousContainer): Now we track all the scopes - that this method references (RegisterScope). The actual scope - where the method is hosted is computed with the ComputeMethodHost - before we create the method. - - Moved the Deepest routine here. - - (AnonymousContainer.ComputeMethodHost): New routine used to - compute the proper ScopeInfo that will host the anonymous method. - - (ScopeInfo): Deal with multiple roots. The problem was that we - did not have a unique root where all ScopeInfos could be hanged - from. Remove `topmost' ScopeInfo, and instead keep an arraylist - of roots. - - Remove AdjustMethodScope which is now computed at the end. Remove - LinkScope which did a partial link, instead link all ScopeInfos - before code generation from the new "LinkScopes" routine. - - Simplify all the Add* routines as they no longer need to maintain - the tree, they just need to record that they are using variables - from a ScopeInfo. - - (IsAncestor, GetAncestorScopes, GetParentScope, LinkScope): New - routines to produce the forest of ScopeInfo trees. - - * class.cs (TypeContainer.AppendMethod): This is just like - AddMethod, but ensures that an interface implementation method - (IEnumerable.XXX) is not inserted at the beginning of the queue of - methods, but at the end. - - We use this functionality to ensure that the generated MoveNext - method in the iterator class is resolved/emitted before the - enumerator methods created. - - This is required because the MoveNext method computes the right - ScopeInfo for the method. And the other methods will eventually - need to resolve and fetch information computed from the anonymous - method. - -2006-01-21 Raja R Harinath - Carlos Alberto Cortez - - Fix rest of #76995. - * namespace.cs (NamespaceEntry.UsingExternalAliases): Don't add to - the 'aliases' hash. - (NamespaceEntry.LookupAlias): Lookup 'extern_aliases' hash too. - (NamespaceEntry.VerifyUsing): Resolve external aliases too. - -2006-01-18 Raja R Harinath - - Fix #76656, cs0231-2.cs. - * cs-parser.jay (formal_parameter_list): Make error case catch - more issues. - (parenthesized_expression_0): Add CS1026 check. - (invocation_expression): Remove unused { $$ = lexer.Location }. - -2006-01-17 Raja R Harinath - - Fix #76824. - * cs-parser.jay (statement_expression): Don't list out the - individual statement-expressions. Convert syntax error into - CS0201 check. - -2006-01-16 Raja R Harinath - - Fix #76874. - * ecore.cs (MemberAccess.CheckIntermediateModification): Remove. - (UnboxCast.DoResolveLValue): New. Move CS0445 check from - CheckIntermediateModification. - (FieldExpr.DoResolve): Add new two-argument version that - allows us to resolve the InstanceExpression as an lvalue. - The one-argument variant is now just a wrapper. - (FieldExpr.DoResolveLValue): Use two-argument DoResolve. - Resolve the lhs as an lvalue if the it has a value type. - (FieldExpr.AssignToReadonly): Move CS1648 and CS1650 checks - from Assign.DoResolve. - (PropertyExpr.InstanceResolve): Allow InstanceExpression to be - resolved as an lvalue. - (PropertyExpr.DoResolve): Update. - (PropertyExpr.DoResolveLValue): Resolve the lhs as an lvalue if it - has a value type. Move CS1612 check here from - CheckIntermediateModification. - * assign.cs (Assign.DoResolve): Remove CS1648 and CS1650 checks. - * expression.cs (EmptyExpression.OutAccess): New. Used as the - 'right_side' of a ResolveLValue on an 'out' argument. - (EmptyExpression.LValueMemberAccess): New. Used as the - 'right_side' of a propagated ResolveLValue on a value type. - (LocalVariableReference.DoResolveBase): Recognize - EmptyExpression.OutAccess and EmptyExpression.LValueMemberAccess. - Add CS1654 check. - (Argument.Resolve): Use EmptyExpression.OutAccess rather than - EmptyExpression.Null. - -2006-01-16 Atsushi Enomoto - - * typemanager.cs : added IsGenericParameter(). In mcs it always - return false. - * doc.cs : for generic parameters, use GenericParameterPosition, - not FullName. - -2006-01-12 Ben Maurer - - * expression.cs: Fix Console.WriteLine ((this = x).foo); - -2006-01-12 Miguel de Icaza - - This fixes the problem where we used ldfld instead of ldflda to - load the "THIS" pointer on captured parameters, when THIS is a - value type. See bug #77205. - - * iterators.cs (CapturedThisReference.Emit): Pass false to - EmitThis (we do not need the address). - - * codegen.cs (EmitThis): it needs to know whether we need the - address of `this' or not. This is used by value types. - - * expression.cs (This.AddressOf): Pass true to the EmitThis call, - every other call passes false. - -2006-01-12 Raja R Harinath - - Fix #77221. - * typemanager.cs (TryGetBaseDefinition): Rename from the mis-named - GetOverride. - * expression.cs (Invocation.OverloadResolve): Update. - (Invocation.DoResolve): Avoid double resolution of invocation. - -2006-01-11 Raja R Harinath - - Fix #77180. - * expression.cs (Unary.Emit): When in /checked+ mode, don't emit - unary negation of floating point types as 0-expr; negation cannot - overflow in floating point types. - - Fix #77204. - * expression.cs (MemberAccess.DoResolve): Disallow the use of '.' - on operands of 'void' type. - - Fix #77200. - * cfold.cs (BinaryFold): Implement folding of BinaryOr, BinaryAnd - and ExclusiveOr for boolean constants too. - -2006-01-09 Raja R Harinath - - Fix #75636. - * expression.cs (Invocation.OverloadResolve): Replace reflected - override methods with their base virtual methods, rather than - skipping over them. - * typemanager.cs (TypeManager.GetOverride): New. - -2006-01-05 Jb Evain - - * class.cs (Property.Define, Indexer.Define): do not tag the - properties as SpecialName | RTSpecialName. - -2006-01-04 Miguel de Icaza - - * class.cs (MethodCore.IsDuplicateImplementation): This method was - doing a low-level comparission of parameter types. It was lacking - a check for __argslist. - -2005-12-30 Miguel de Icaza - - * expression.cs (ParameterReference.DoResolveBase): Allow - reference parameters if they are local to this block. - - This allows the ref and out parameters of a delegate to be used in - an anonymous method, for example: - - delegate void set (out int x); - - set s = delegate (out int x){ - x = 0; - }; - - This is used by functionality introduced late in the C# language. - - * anonymous.cs (AnonymousMethod.Compatible): Allow anonymous - method that take ref and out parameters. - - Fixes #77119 which was a late change in the spec. - -2005-12-23 Miguel de Icaza - - * anonymous.cs (ScopeInfo.LinkScope): Do not link the scope to its - parent if its the same scope. Fixes #77060. - -2005-12-21 Miguel de Icaza - - * driver.cs: Report the case of no source files and no -out: - argument provided. - -2005-12-20 Raja R Harinath - - Fix #77035. - * expression.cs (ComposedCast.GetSignatureForError): Define. - -2005-12-18 Carlos Alberto Cortez - - Fix #76995 - - * namespace.cs (NamespaceEntry): Add extern_aliases as a - ListDictionary, to contain the ExternAliasEntry entries (in - addition to the NamespaceEntry.aliases hashtable). This field is - shared between the original entry and its doppelganger (bodyless - copy of it). - (NamespaceEntry.UsingExternalAlias): Add the extern alias entry to - extern_aliases field. - (NamespaceEntry.Lookup): Move the IsImplicit check after the - lookup in extern_aliases. - -2005-12-16 Raja R Harinath - - Fix #77006. - * class.cs (TypeContainer.Mark_HasEquals): New. - (TypeContainer.Mark_HasGetHashCode): New. - (ClassPart): Override them. - (MethodCore.CheckBase): Use them instead of referring to Parent.Methods. - - Fix #77008. - * enum.cs (EnumMember.EnumMember): Pass the parent_enum as the - 'parent' argument to the base constructor. - - Remove all mention of TypeContainer from decl.cs. - * decl.cs (MemberCore.Parent): Change into a DeclSpace. - (MemberCore.MemberCore): Change type of 'parent' argument to DeclSpace. - (DeclSpace.DeclSpace): Likewise. - (DeclSpace.DefineMembers): Remove unused argument. - * cs-parser.jay (pop_current_class): Update to changes. Simplify - debugging check -- we don't care if the debug code throws an - InvalidCastException instead of an InternalErrorException. - * class.cs (TypeContainer.DefineMembers): Update to changes. - (TypeContainer.DoDefineMembers): Likewise. - (TypeContainer.GetMethods): Likewise. - (PropertyMember.Define): Likewise. - (MemberBase.Parent): New property that forwards to - MemberCore.Parent, but ensures that we get a TypeContainer. - * rootcontext.cs (RootContext.PopulateCoreType): Update to changes. - (RootContext.PopulateTypes): Likewise. Remove special case code - for !RootContext.StdLib: DefineMembers is idempotent. - -2005-12-14 Miguel de Icaza - - * convert.cs (ExplicitConversionCore): Check the return value from - ExplicitConversionCore which can return null on failure. Fixes #76914 - -2005-12-13 Marek Safar - - * class.cs (Method.ApplyAttributeBuilder): Test out modifier properly. - -2005-12-11 Atsushi Enomoto - - * doc.cs : The search for referenced namespace was insufficient to - get global one as it used to do. Fixed bug #76965. - -2005-12-10 Atsushi Enomoto - - * doc.cs : check name in cref in the last phase that whether it is - namespace or not. - -2005-12-09 Atsushi Enomoto - - * cs-tokenizer.cs : reverted the latest change: it somehow broke - Mono.C5. - -2005-12-09 Atsushi Enomoto - - * doc.cs : so it turned out that we cannot skip override check for - interface members. Fixed bug #76954. - -2005-12-09 Atsushi Enomoto - - * cs-tokenizer.cs : fixed bug #75984: - - #warning and #error should not be handled when the source line - is disabled. - - #line is not checked strictly when the source line is disabled. - - #define and #undef is on the other hand checked strictly at any - state. - -2005-12-08 Atsushi Enomoto - - * cs-tokenizer.cs : missing Location (actually, filename) in one of - CS1027 report. - -2005-12-05 Marek Safar - - * attribute.cs (GlobalAttribute.ctor): Pass NamespaceEntry only. - - * class.cs (EmitFieldInitializers): Simplified and fixed to work with - event initializers. - (FieldBase.EmitInitializer): Moved from TypeContainer and simplified. - (FieldBase.Initializer): Initializer is now optional. - (EventField.Define): Only event field can have initializer. - - * codegen.cs (EmitContext): DeclSpace is not readonly (small hack). - - * const.cs (Const): Reuse initializer. - - * cs-parser.jay: Updated after FieldBase changes. - Added current_array_type to simplify array initializers. - - * ecore.cs (NullCast.IsDefaultValue): Implemented. - - * expression.cs, iterators.cs: Updated. - - * namespace.cs (NamespaceEntry): Made UsingFound private. - -2005-12-05 Marek Safar - - * parameterCollection.cs: Obsolete, removed. - * parser.cs: Obsolete, removed. - -2005-12-05 Marek Safar - - Fix #76849. - * class.cs (Constructor.Emit): Set obsolete checking for whole context. - - * enum.cs (Enum.Define): Set obsolete context here. - -2005-12-05 Atsushi Enomoto - - * doc.cs : - - FindDocumentedMember() now expects 1) paramList as null - when "we don't have to check the number of parameters" and - 2) Type.EmptyTypes when "there is no arguments". - - Introduced FoundMember struct to hold the exact type which was - used to find the documented member (the above change broke - test-xml-044; it might be better just to use DeclaringType than - what MS does, like this change does, but it depends on usage.) - -2005-12-05 Atsushi Enomoto - - * doc.cs : documented member might be from DeclaringType for nested - types. Fixed bug #76782. - -2005-12-03 Ben Maurer - - * anonymous.cs: Have the param code handle leaving copies on the - stack etc. Allows anonymous params to take part in the assignment - code (++, +=, etc). Fixes bug #76550 - - * expression.cs: Handle the prepare_for_load/leave_copy by passing - it down to the anon code. - - * iterators.cs: Use dummy var here - - * codegen.cs: Handle new vars - -2005-12-01 Marek Safar - - Fix #76849. - * class.cs (MethodData.Define): Set proper Obsolete context. - - * ecore.cs (FieldExpr.ResolveMemberAccess): Don't check [Obsolete] in - obsolete context. - (FieldExpr.DoResolve): Ditto. - -2005-12-01 Marek Safar - - Fix #76849. - * class.cs (MethodCore.DoDefineParameters): Test [Obsolete] only when - parent is not obsolete. - -2005-12-01 Atsushi Enomoto - - * doc.cs : (FindDocumentedMember) find parameterless members first - and get CS0419 in the early stage. Fixed first case of bug #76727. - -2005-11-30 Marek Safar - - Fix #76859. - * ecore.cs (Expression.ResolveAsConstant): Report constant error only when - no error was reported. - - *expression.cs (Binary.DoResolve): left can be null. - -2005-11-22 Marek Safar - - Fix #76783. - * class.cs (MethodData.Emit): Parameters should be labeled first. - -2005-11-21 Marek Safar - - Fix #76761. - * parameter.cs (Parameter.ApplyAttributeBuilder): Fixed `ref' detection. - -2005-11-18 Marek Safar - - * attribute.cs (AreParametersCompliant): Moved to Parameter. - - * class.cs (MethodCore): Parameter clean up. - (IMethodData): Added ParameterInfo. - (MethodData): Parameter clean up. - (Indexer.Define): Parameter clean up. - - * anonymous.cs, - * codegen.cs, - * cs-parser.jay, - * decl.cs, - * doc.cs, - * ecore.cs, - * flowanalysis.cs, - * iterators.cs, - * pending.cs, - * statement.cs, - * typemanager.cs: Parameter clean up. - - * delegate.cs (Define): Get rid of duplicated code. - - * expression.cs (ParameterReference): Removed useless parameters - and simplified. - (Invocation): Ditto. - - * parameter.cs (ParamsParameter): New class, params specialization. - (ArglistParameter): Attemp to separate arglist. - (Parameter): Refactored to be reusable and faster. - (Parameter.Modifier): Made understandable. - (Parameters): Changed to be used as a class for `this' assembly - parameters. Refactored to use new specialized classes. - - * support.cs (ParameterData): Added Types property. - (InternalParameters): Deleted. - -2005-08-20 Martin Baulig - - Merging this patch from GMCS to fix #75867. - - * anonymous.cs (CaptureContext.CaptureThis): Create the topmost - scope if we don't already have it. - -2005-11-17 Martin Baulig - - * anonymous.cs - (CaptureContext.EmitMethodHostInstance): Use `Ldarg_0' if we - inherit the scope from our parent. Fixes #76653. - -2005-11-16 Atsushi Enomoto - - * doc.cs : the previous patch does not actually fix the bug. - PropertyInfo override check is now implemented and really fixed it. - * expression.cs : Invocation.IsAncestralType() is used from doc.cs. - -2005-11-16 Atsushi Enomoto - - * doc.cs : apply "override filter" also to properties. - Fixed bug #76730. - -2005-11-16 Atsushi Enomoto - - * doc.cs : renamed FindMembers() to FindMethodBase(). For interfaces, - no need to check overrides. For classes, omit those results from - interfaces since they must exist in the class. Fixed bug #76726. - -2005-11-15 Atsushi Enomoto - - * typemanager.cs : (GetFullNameSignature) differentiate indexers - with different parameters. Fixed the second problem in #76685. - -2005-11-15 Atsushi Enomoto - - * doc.cs : (FindDocumentedMember) pass invocation_type as well (to - get expected 'protected' access in CheckValidFamilyAccess()). - Fixed bug #76692. - -2005-11-15 Atsushi Enomoto - - * doc.cs : (GenerateTypeDocComment) Fields could be FixedField. - Fixed bug #76705. CS1569 was incorrectly commented out. - -2005-11-14 Atsushi Enomoto - - * doc.cs : use Invocation.IsOverride() to do real override check. - * expression.cs : made Invocation.IsOverride() internal. - -2005-11-14 Atsushi Enomoto - - * doc.cs : use TypeManager.FindMembers() instead of (possible) - TypeBuilder.FindMembers() and filter overriden base members out. - Fixed bug #76990. - -2005-11-13 Atsushi Enomoto - - * doc.cs : ref/out parameters are represented as '@' (instead of - '&' in type FullName). Fixed bug #76630 (additionally crefs). - -2005-11-13 Atsushi Enomoto - - * doc.cs : when there was no '.' in cref to methods in doc comment, - then parameters were missing in the output. Fixed bug #76691. - -2005-11-13 Atsushi Enomoto - - * driver.cs : don't output docs when there is an error. - Fixed bug #76693. - -2005-11-13 Atsushi Enomoto - - * doc.cs : - Now it should detect indexers. Fixed primary concern in bug #76685. - Fixed CS0419 message to not show the identical member signature in - the message. - -2005-11-13 Atsushi Enomoto - - * doc.cs : (FindDocumentedMember) use TypeManager.MemberLookup() - instead of Type.FindMembers() since it does not handle events. - Fixed bug #71604. - -2005-11-12 Gert Driesen - - * codegen.cs: Fixed typo (speficied -> specified). - -2005-11-11 Marek Safar - - Fix #76369. - * doc.cs (FindDocumentedTypeNonArray): Don't resolve again. - -2005-11-11 Marek Safar - - * attribute.cs: Changed error message. - - * cs-tokenizer.cs: One more check. - -2005-11-10 Marek Safar - - * statement.cs (Block.Resolve): Ignore empty statement. - -2005-11-10 Marek Safar - - * report.cs: Made error/warning methods more strict to avoid - their misuse. - - * anonymous.cs, attribute.cs, class.cs, codegen.cs, constant.cs, - convert.cs, cs-parser.jay, cs-tokenizer.cs, decl.cs, delegate.cs, - doc.cs, driver.cs, ecore.cs, expression.cs, location.cs, - namespace.cs, parameter.cs, statement.cs, typemanager.cs: Updated. - -2005-11-08 Marek Safar - - * attribute.cs (Attribute.GetCoClassAttributeValue): New method. - (AttributeTester.GetCoClassAttribute): Get CoClassAttribute. - - * class.cs (TypeContainer.IsComImport): New property. - (Constructor.Define): Create proper ctor for ComImport types. - - * expression.cs (New.CheckComImport): Fixed. - -2005-11-07 Miguel de Icaza - - * anonymous.cs (CaptureContext.AddParameterToContext): The fact - that a parameter has been captured does not mean that we do not - have to do the rest of the processing. This fixes the second part - of #76592. If there was another anonymous method capturing - values in the past, the Scope would never be set for the second - method that captured the same parameter. - - (CaptureContext.EmitAssignParameter): When `leave_copy' is passed, - properly manipulate the stack. Second part of fix for #76592. - - * expression.cs (New): Add support for invoking "new" on - interfaces that have been flagged with the ComImport attribute and - the CoClass. Fixes #76637 - - * statement.cs (Try.DoEmit): When a variable is captured, do not - try to emit the vi.LocalBuilder variable as it has been captured. - Create a temporary variable and store the results on the - FieldBuilder. Fixes #76642 - -2005-11-07 Marek Safar - - * class.cs (CheckPairedOperators): Made compilable with csc 2.0. - - * ecore.cs (InstanceResolve): Fixed CS1540 detection. - - * expression.cs (Binary.DoResolve): Added && optimalization. - - * typemanager.cs (AddUserType): Removed useless argument. - -2005-11-04 Marek Safar - - * statement.cs (Block.variables): Uses ListDictionary. - -2005-11-03 Marek Safar - - Fix #75969. - * class.cs (PartialContainer.EmitType): Customized to emit - security attributes. - (ClassPart.ApplyAttributeBuilder): Transform security attribute - for partial classes. - -2005-11-03 Marek Safar - - Fix #76599. - * expression.cs (ElementAccess.DoResolveLValue): Fixed buffer - access has to be fixed. - - * typemanager.cs (IsUnmanagedType): Wrong common field type. - -2005-11-01 Marek Safar - - Fix #76590. - * ecore.cs (NullCast.Reduce): Implemented. - - * expression.cs (ArrayCreation.CheckIndices): Correcly check - constant type. - - * statement.cs (SwitchLabel.ResolveAndReduce): Catch null - properly. - (Foreach.Resolve): Catch null properly. - -2005-10-29 Marek Safar - - * cs-tokenizer.cs: Warning text fix. - - * driver.cs: AllWarningNumbers exposed on public interface. - - * report.cs (): Reviewed warning numbers. - (IsValidWarning): Use binary search. - -2005-10-29 Marek Safar - - * driver.cs: Implemeted resource visibility. - (Resources): New class for code sharing between /res: and - /linkres: - -2005-10-28 Marek Safar - - Fix #76568. - * cfold.cs (ConstantFold.BinaryFold): Implemented null cast - folding. - - * convert (Convert.ImplicitReferenceConversion): NullCast holds - contants only. - - * ecore.cs (NullCast): Child is contant only. - - * literal.cs (NullLiteral.Reduce): null can be converted to any - reference type. - -2005-10-28 Kornél Pál - - * driver.cs: Use Encoding.Default as default code page instead - of ISO-28591. - -2005-10-27 Raja R Harinath - - Fix #76085. - * expression.cs (Invocation.Error_InvalidArguments): Handle - __arglist parameters. - (Invocation.VerifyArgumentsCompat): Likewise. - * support.cs (ReflectionParameters.GetSignatureForError): Print - __arglist parameters. - (InternalParamters.GetSignatureForError): Likewise. - * parameter.cs (Parameters.GetSignatureForError): Likewise. - -2005-10-26 Marek Safar - - * attribute.cs (GetPropertyValue): Made public. - - * codegen.cs (AssemblyClass): ResolveClsCompliance renamed to - Resolve. - Add new property WrapNonExceptionThrows to handle 2.0 assembly - attribute. - (AssemblyClass.Emit): Emit RuntimeCompatibilityAttribute when it - is not defined. - - * driver.cs: Reflect method name change. - - * statement.cs (Try.Resolve): Warn when try has both general - exception handlers. - - * typemanager.cs: runtime_compatibility_attr_type new predefined - type. - -2005-10-26 Raja R Harinath - - Fix #76419. - * pending.cs (InterfaceMethod): Allow tm.args [i] to be null -- - treat it as an empty parameter list. - -2005-10-26 Raja R Harinath - - Fix #76271. - * ecore.cs (SimpleName.DoSimpleNameResolve): Make fall-back - ResolveAsTypeStep silent. - * statement.cs (Block.AddConstant): Mark block as used. - (Block.ResolveMeta): Avoid piling on error messages - if a constant initializer resolution fails. - -2005-10-25 Raja R Harinath - - * namespace.cs (RootNamespace.VerifyUsingForAll, Namespace.VerifyUsing): - Remove. - (NamespaceEntry.VerifyAllUsing): New. - (NamespaceEntry.AliasEntry.Resolve): New. Handles common error - behaviour. Delegates actual resolution of alias to ... - (NamespaceEntry.DoResolve): ... this. Renamed from Resolve. - (NamespaceEntry.LocalAliasEntry, NamespaceEntry.ExternAliasEntry): - Update. - * driver.cs (Driver.MainDriver): Update. - - * namespace.cs (NamespaceEntry.DefineNamespace): Remove. - (NamespaceEntry.SymbolFileID): Make into a on-demand computed - property. - (Namespace.DefineNamespaces, RootNamespace.DefineNamespacesForAll): - Remove. - * symbolwriter.cs (SymbolWriter.Initialize): Don't call - RootNamespace.DefineNamespacesForAll. - -2005-10-24 Raja R Harinath - - * typemanager.cs (assemblies, external_aliases, modules) - (AddAssembly, AddExternAlias, AddModule GetAssemblies, Modules) - (ComputeNamespaces, GetRootNamespace): Remove extra staging - overhead. Move resposibility ... - * namespace.cs (GlobalRootNamespace): ... here. Update to changes. - * driver.cs, attribute.cs, codegen.cs: Update to changes. - -2005-10-23 Raja R Harinath - - * namespace.cs (RootNamespace.all_namespaces): Renamed from - cached_namespaces. Improve usage. - (RootNamespace.Reset, RootNamespace.RegisterNamespace) - (RootNamespace.VerifyUsingForAll, RootNamespace.DefineNamespacesForAll): - Move from GlobalRootNamespace and simplify. - (RootNamespace.Global): Make instance variable. - (RootNamespace.RootNamespace): Add "alias name" parameter. - (GlobalRootNamespace): Simplify drastically. - (Namespace.Lookup): Don't use GetNamespace. - * typemanager.cs (GetRootNamespace): Rename from - ComputeNamespaceForAlias. - (NamespaceClash): Use Global.IsNamespace instead of GetNamespace. - -2005-10-23 Marek Safar - - * anonymous.cs (AnonymousContainer): Don't crash when container - doesn't exist. - -2005-10-23 Marek Safar - - * expression.cs (Binary.DoResolve): Warn when comparing same - values. - -2005-10-23 Marek Safar - - Fix #76486. - * expression.cs (Binary.DoResolve): It looks like there are no - convetsion rules in enum context. - -2005-10-19 Carlos Alberto Cortez - - Add support for extern alias qualifiers. - * typemanager.cs: Move some LookupTypeReflection code - to namespace.cs, to have cleaner code. Added some methods - to help us keep track of the extern aliased references. - * driver.cs: Add suport for extern alias assemblies on command - line and check for their warnings/errors. Also keep track of the - extern aliased assemblies. - * namespace.cs: Move the global functionality of Namespace - to GlobalRootNamespace/RootNamespace. Now the global namespace - is GlobalRootNamespace.Globa. Also the code moved from - typemanager.cs lives in GlobalRootNames.cs/RootNamespace.cs. - Finally added LocalAliasEntry (AliasEntry before) and - ExternAliasEntry, to handle alias statements. - * cs-parser.jay: Add support in the grammar for extern alias - statement. - * doc.cs, delegate.cs, expression.cs ecore.cs, symbolwriter.cs: - Update callings to Namespace (now in GlobalRootNamespace). - -2005-10-18 Raja R Harinath - - Fix #76371. - * class.cs (TypeContainer.DefineType): Move updating of - topological sort earlier in the code. - * decl.cs (DeclSpace.ResolveBaseTypeExpr): Don't use TypeBuilder. - -2005-10-18 Marek Safar - - Fix #76273. - * cfold.cs (BinaryFold): Reduce constant in enum conversion. - - * constant.cs (Constant.TryReduce): Moved from Cast class. - (Reduce): Made little bit more OO and fixed missing conversions. - - * ecore.cs (Reduce): Implemented. - (Binary.EnumLiftUp): New method to upgrade values to enum values. - - * literal.cs (Reduce): Implemented. - - * class.cs: Reverted Miguel's wrong commit. - -2005-10-14 Miguel de Icaza - - * ecore.cs (GetMemberType): Report the correct mapping for the MemberCore - -2005-10-14 Atsushi Enomoto - - * cs-parser.jay, expression.cs : CS0214 was missing error location - for constants. Fixed bug #76404. - -2005-10-11 Marek Safar - - Fix #76370. - * convert.cs (ExplicitConversionCore): Fixed object->enum - conversion. - -2005-10-10 Raja R Harinath - - * ecore.cs (PropertyExpr.Emit): Use Invocation.EmitCall to emit - InstanceExpression. - (PropertyExpr.EmitCall): Likewise. - * expression.cs (Invocation.EmitArguments): Handle case where - arguments == null. - (Invocation.EmitCall): Avoid allocating temporary variable if - there are no arguments. - -2005-10-07 Raja R Harinath - - Fix #76323. - * convert.cs (ImplicitConversionStandard): Move conversion of - void* to arbitrary pointer types ... - (ExplicitConversionStandard): .. here. - * ecore.cs (Expression.Error_ValueCannotBeConverted): Fix CS0266 - error to always print typenames. - -2005-10-07 Raja R Harinath - - * convert.cs (GetConversionOperator): Rename from - GetConversionOperators. Move operator selection code from ... - (UserDefinedConversion): ... here. - -2005-10-06 Marek Safar - - * convert.cs (ExplicitConversionCore): Removed duplicate enum - conversion. - -2005-10-05 Marek Safar - - * assign.cs (Assign.DoResolve): Error method changed. - - * cfold.cs (DoConstantNumericPromotions): Error method changed. - - * const.cs (ResolveValue): Reset in_transit immediately. - - * constant.cs: Error method changed. - - * convert.cs: Removed useless location parameter. - (ExplicitNumericConversion): Don't do double enum check. - (ExplicitConversionCore): Renamed from ExplicitConversion. - (ExplicitUnsafe): Extracted from ExplicitConversion. - (ExplicitConversion): Uses for error reporting. - - * ecore.cs (Error_ValueCannotBeConverted): More logic for more - error messages. - (ResolveBoolean): Uses common error method. - (CastToDecimal): Get rid of ec. - (CastFromDecimal): Optimized. - (ConvCast): Get rid of ec. - - * enum.cs (ResolveValue): Reset in_transit immediately. - (Emit): Return after first error. - - * expression.cs: Convert changes. - - * literal.cs: Error method changed. - - * statement.cs: Error method changed. - -2005-10-03 Raja R Harinath - - * support.cs (SeekableStreamReader.Position): Don't error out when - the requested position is just beyond the end of the current - buffered data. - -2005-09-28 Raja R Harinath - - * support.cs (SeekableStreamReader): Simplify drastically. Don't - try to keep in sync with the byte count of the underlying Stream. - However, this limits us to a window size of 2048 characters: i.e., - the maximum lookahead of our lexer/parser can be 2048 characters. - -2005-09-28 Marek Safar - - Fix #76255. - * driver.cs: Fix compilation files with full root path. - -2005-09-25 Miguel de Icaza - - * report.cs (SymbolRelatedToPreviousError): Format the output so - it does not use an open parenthesis that is never closed. - - * driver.cs: Follow coding guidelines - -2005-09-27 Marek Safar - - Fix #72930. - * const.cs (Const.ResolveValue): Check for assigning non-null - value to reference type. - -2005-09-27 Marek Safar - - * anonymous.cs: Implemented ExprClassName. - - * assign.cs (Assign.DoResolve): Don't chrash when type is not - delegate. - - * attribute.cs (ResolveArguments): Enabled MethodImplOptions - check. - - * class.cs (StaticClass.DefineContainerMembers): Report protected - members as error. - - * codegen.cs: if(ed) PRODUCTION. - - * convert.cs (Error_CannotImplicitConversion): Better error - distinction. - - * cs-parser.jay: More error checks. - - * cs-tokenizer.cs (consume_identifier): Fixed Miguel's revert. - - * driver.cs (CSCParseOption): Enabled wrong option check. - - * ecore.cs (Expression.ExprClassName): Turned to property. - (MemberExpr.CheckIntermediateModification): For checking boxed - value types modification. - - * statement.cs (Fixed.Resolve): Expression type must be - convertible to fixed type. - (CollectionForeach.GetEnumeratorFilter,TryType): - Small refactoring for easier error checking. - -2005-09-26 Marek Safar - - * attribute.cs (Attribute.Resolve): Check Obsolete attribute for - attributes. - - * class.cs (GeneratedBaseInitializer): New class for customization - compiler generated initializers. - (MemberBase.DoDefine): Check Obsolete attribute here. - (FieldMember.DoDefine): Ditto. - - * const.cs (ExternalConstant.CreateDecimal): Builder for decimal - constants. - - * decl.cs (MemberCore.EmitContext): Returns valid current ec. - (MemberCore.GetObsoleteAttribute): Removed argument. - (MemberCore.CheckObsoleteness): Obsolete attributes are hierarchic. - (MemberCore.CheckObsoleteType): New helper. - - * delegate.cs, - * enum.cs, - * statement.cs: Updates after MemberCore changes. - - * ecore.cs (TypeExpr.ResolveType): Check type obsoleteness here. - (FieldExpr.ResolveMemberAccess): Fixed decimal constants checks. - - * expression.cs (ComposedCast.DoResolveAsTypeStep): Don't check - obsolete attribute for compiler construct. - (As.DoResolve): Cache result. - - * iterators.cs (Define_Constructor): Use GeneratedBaseInitializer. - -2005-09-26 Raja R Harinath - - Fix #76133. - * expression.cs (This.VerifyFixed): In a value type T, the type of - 'this' is T&, iow, 'this' is either an out or ref parameter. In a - value type R, 'this' is treated as a value parameter. - -2005-09-22 Miguel de Icaza - - * statement.cs (Lock): Use the TemporaryVariable class instead of - manually using local variables as those do not work when variables - are captured. - - * ecore.cs: Moved the TemporaryVariable class from being a nested - class inside Foreach to be a public class that can be employed in - other places. - -2005-09-19 Marek Safar - - * cs-parser.jay: interface_accessors replaced by - accessor_declarations. - - * ecore.cs, literal.cs, statement.cs: NullLiteral holds null - location. - - * statement.cs (GotoCase.Resolve): Convert null constant to - null case. - (SwitchLabel.ResolveAndReduce): Ditto. - (SwitchLabel.NullStringCase): Custom null stamp. - (Switch.SimpleSwitchEmit): Fix from NullLiteral to NullStringCase. - - typemanager.cs (CSharpSignature): Don't skip first argument - for full names. - -2005-09-18 Miguel de Icaza - - * driver.cs: Set InEmacs based on the environment variable EMACS. - - * location.cs (InEmacs): in this mode, do not report column - location as it confuses Emacs. - -2005-09-16 Marek Safar - - * cfold.cs, constant.cs, convert.cs, ecore.cs, - expression.cs, iterators.cs, literal.cs: Store constants and - literals location. - - * class.cs (MemberBase.ShortName): Pass location. - - * cs-parser.jay: Some location fixes. - - * ecore.cs (Expression.Location): Made virtual. - -2005-09-05 Miguel de Icaza - - * expression.cs (Cast.TryReduce): Only reduce to an EnumConstant - if the underlying types are the same, otherwise we need to produce - code that will do the proper cast. - - This was exposed by Marek's constant rewrite which produced - invalid code for the call site: - - enum X : long { a } - void Method (X v) {} - - Method ((X) 5) - - This fixes test-49.cs - -2005-09-05 Atsushi Enomoto - - * attribute.cs : (Attribute.IsValidArgumentType): array of string/ - Type/Object should be allowed as well. Fixed bug #75968. - -2005-09-05 Atsushi Enomoto - - * expression.cs : (Binary.DoResolve): when one is enum constant and - another is constant 0, then return enum one *as enum type*. - Fixed bug 74846. - -2005-09-02 Raja R Harinath - - * attribute.cs (GetMarshal): Work even if "DefineCustom" is - internal. - - Fix #75941. - * ecore.cs (SimpleNameResolve.DoSimpleNameResolve): Disable - flow-branching for LocalVariableReferences in case we were invoked - from a MemberAccess. - * expression.cs (LocalVariableReference.VerifyAssigned): New. - Carved out of ... - (LocalVariableReference.DoResolveBase): ... this. - (MemberAccess.Resolve): Do the check that was disabled during - SimpleNameResolve. - -2005-09-01 Atsushi Enomoto - - * class.cs : - (PartialContainer.Create): check abstract/sealed/static strictly - but abstract/sealed can exist only at one side. Fixed bug #75883. - -2005-09-01 Kornél Pál - - Fix #75945. - * attribute.cs (Attribute.GetMarshal): If ArraySubType is not - specified, don't default to UnmanagedType.I4. - -2005-09-01 Atsushi Enomoto - - * expression.cs : conditional operator should check possibly - incorrect assign expression. Fixed bug #75946. - -2005-08-31 Atsushi Enomoto - - * cs-tokenizer.cs, cs-parser.jay, driver.cs, support.cs : - Reverting the change. gmcs is much complex than mcs on this matter. - -2005-08-31 Atsushi Enomoto - - * cs-tokenizer.cs : To read another token ahead of the actual - consumption, use new SavedToken and cache token instead of moving - back the stream with SeekableStreamReader (it seemed problematic). - * cs-parser.jay, - driver.cs : Thus use StreamReader directly. - * support.cs : Thus removed SeekableStreamReader. - -2005-08-30 Raja R Harinath - - Fix #75934. - * anonymous.cs (ScopeInfo.MakeFieldName): New helper. - (ScopeInfo.EmitScopeType): Use it to construct field names from - names of captured locals. - - Fix #75929. - * ecore.cs (BoxedCast.BoxedCast) [1-argument variant]: Remove. - * convert.cs (ImplicitReferenceConversion, TryImplicitIntConversion): - Pass 'target_type' to BoxedCast. Don't default to 'object'. - (ExplicitConversion): Remove enum cases already handled by - implicit conversion. Move implicit conversion check to the beginning. - * delegate.cs (DelegateCreation.ResolveMethodGroupExpr): Update. - * expression.cs (ArrayCreation.EmitDynamicInitializers): - Don't treat System.Enum as a struct. - -2005-08-30 Jb Evain - - * attribute.cs: handles as expression in parameters. - -2005-08-30 Raja R Harinath - - Fix #75802. - * class.cs (TypeContainer.VerifyClsName): Don't use a - PartialContainer when verifying CLS compliance. - (AbstractPropertyEventMethod): Set Parent here, ... - (PropertyMethod): ... not here. - -2005-08-30 Atsushi Enomoto - - * attribute.cs : escaped attribute name should not be allowed to be - resolved (e.g. @class as classAttribute). Fixed bug #75930. - -2005-08-29 Raja R Harinath - - Fix #75927. - * convert.cs (ImplicitStandardConversionExists): Allow zero also - when converting a long constant to unsigned long. - * expression.cs (Invocation.OverloadResolve): Add sanity check to - detect where IsApplicable and VerifyArgumentsCompat disagree. - -2005-08-29 Raja R Harinath - and Carlos Alberto Cortez - - Fix #75848. - * class.cs (TypeContainer.CanElideInitializer): New helper. - (TypeContainer.EmitFieldInitializers): Use it to determine if we - can safely emitting the initializer of a field. - -2005-08-25 Atsushi Enomoto - - * statement.cs : (Continue.Resolve()) Unlike break, continue is not - allowed inside a switch (without loop). Fixed bug #75433. - -2005-08-26 Kornél Pál - - * AssemblyInfo.cs: Using Consts.MonoVersion instead of MonoVersion.cs. - * mcs.exe.sources: Using Consts.MonoVersion instead of MonoVersion.cs. - -2005-08-25 Atsushi Enomoto - - * driver.cs : kinda reverting the default encoding changes (not exact - revert since I noticed that "codepage:reset" might not work fine). - -2005-08-25 Atsushi Enomoto - - * class.cs : (AbstractPropertyEventMethod) SetupName() now takes - Location. Now getter and setter store location correctly. - (errors/cs0111-12.cs now reports the expected location.) - -2005-08-25 Atsushi Enomoto - - * driver.cs : Use default encoding on the environment. - Removed (now that) extra parameter for SeekableStreamReader. - * support.cs : (SeekableStreamReader) third .ctor() argument for - StreamReader is not required (always true). preamble size could - be acquired in simpler and safe way. - -2005-08-24 Atsushi Enomoto - - * cs-parser.jay: report CS0642 at warning level 3 - and report CS0642 for an if else statement also - fixes bug #74745. Patch by John Luke (and a bit - modified by me). - Removed extra CS0642 warning check for "while", - "for" and "fixed". - * statement.cs: In Block.Resolve(), CS0642 check - is reimplemented to check a sequence of an empty - statement and a block. - - Both fix bug #66777. - -2005-08-24 Marek Safar - - * attribute.cs (GetMethodObsoleteAttribute): Disabled obsolete properties - detection until I fix it. - - * cs-tokenizer.cs: Changed error message. - - * cs-parser.jay: Fixed 2 error locations. - - * ecore.cs (Error_TypeDoesNotContainDefinition): Share error message. - (PropertyExpr.Error_PropertyNotFound): First attempt to detect non C# - properties. - - * enum.cs (GetSignatureForError): Fixed. - - * expression.cs (Invocation.IsSpecialMethodInvocation): Improved special - method detection. - - * class.cs, - * typemanager.cs (RegisterProperty): Removed. - - * statement.cs (CheckInvariantMeaningInBlock): Changed error message. - -2005-08-24 Raja R Harinath - - Fix #75874. - * expression.cs (ArrayAccess.EmitLoadOpcode): Emit ldelem.i for pointers. - (ArrayAccess.GetStoreOpcode): Return stelem.i for pointers. - -2005-08-23 Atsushi Enomoto - - * expression.cs : tiny fix is required for not warning positive ulong. - See test-441.cs. - -2005-08-23 Atsushi Enomoto - - * expression.cs : add CS0652 check for constant and integral - expression. Fixed bug #53974. - -2005-08-23 Atsushi Enomoto - - * expression.cs : in DoNumericPromotions(), check if there is implicit - conversion overload for string (to check CS0034). Fixed bug #52492. - -2005-08-23 Atsushi Enomoto - - * cs-tokenizer.cs : Check newline in char constant. Fixed bug #75245. - -2005-08-23 Atsushi Enomoto - - * ecore.cs : report location when it is *not* Null. - -2005-08-23 Atsushi Enomoto - - * codegen.cs, - ecore.cs, - flowanalysis.cs, - expression.cs: - Added OmitStructFlowAnalysis to EmitContext to handle CS0165 check - correctly. Fixed bug #75721. - -2005-08-23 Raja R Harinath - - * support.cs (SeekableStreamReader.Position): Avoid an expensive - loop that performs 'min (pos, char_count)'. - - Fix #75862. - * expression.cs (Unary.ResolveOperator): Don't discard implicit - converted value in Operator.OnesComplement. - -2005-08-22 Ben Maurer - - * anonymous.cs: If the anon method is pulled into a helper class, - it needs to be `internal' not `private'. Fixes runtime behavior on - msft. bug #75704 - -2005-08-20 Martin Baulig - - * anonymous.cs (CaptureContext.CaptureThis): Create the topmost - scope if we don't already have it. - - * expression.cs (Invocation.EmitCall): Use `ec.EmitThis ()' rather - than `ig.Emit (OpCodes.Ldarg_0)' to make it work inside iterators; - fixes #75867. - -2005-08-17 Marek Safar - - Fix #75803 - * decl.cs (DeclSpace.VerifyClsCompliance): Skip when collision object - is a partial class. - -2005-08-16 Marek Safar - - The big constants rewrite - Fix #75746, #75685 and more - As a side effect saved 1MB for MWF ;-) - - * attribute.cs (GetAttributeArgumentExpression): Use ToType, GetTypedValue. - (GetMarshal, GetMethodImplOptions, GetLayoutKindValue): Values are not - enum based for corlib compilation. - - * cfold.cs (BinaryFold): Convert operand for enum additions. Fixed enum - subtractions. - - * class.cs (FixedField.Define): Use ResolveAsConstant. - - * const.cs (IConstant): Interface constants and enums. - (Const.ResolveValue): New method for constant resolvning. - (ExternalConstant): Constants from imported assemblies. - - * constant.cs (Constant.GetTypedValue): Used to get constant with forced - conversion; like enums. - (Constant.ToType): Converts this constant to different type. - (Constant.Increment): Adds 1. - - * convert.cs (ImplicitConversionRequired): Simplified. - - * cs-parser.jay: Create EnumMember directly. - - * decl.cs (MemberCore.CheckObsoleteness): Checks for ObsoleteAttribute presence. - - * doc.cs (GenerateEnumDocComment): Removed. - - * ecore.cs (Expression.ResolveAsConstant): New constant specific method. - (ConvertIntLiteral): Removed. - (FieldExpr.ResolveMemberAccess): Refactored to remove constant specific if(s). - - * enum.cs (EnumMember): Implement IConstant. - (Enum.IsValidEnumConstant): Removed. - (Enum.GetNextDefaultValue): Removed. - (Enum.FindMembers): Updated. - (Enum.GenerateDocComment): Iterate enum members. - - * expression.cs (Cast.TryReduce): Handle enums correctly. - (New.Constantify): Made public. - (MemberAccess.DoResolve): Removed contant specific if(s). - - * literal.cs (NullLiteral): Implement new abstract methods. - - * statement.cs (GotoCase.Resolve): Use new constant methods. - (SwitchLabel.ResolveAndReduce): Use new constant methods. - - * typemanager.cs (LookupEnum): Removed. - (IsEnumType): Fixed to work with corlib. - (RegisterConstant): Removed. - (LookupConstant): Removed. - (GetConstant): Changed to work with IConstant. - -2005-08-04 Atsushi Enomoto - - * location.cs : Fixed overflown (>255) column number. - -2005-08-03 Raja R Harinath - - First cut of the qualified-alias-member feature. - * cs-tokenizer.cs (Tokenizer.is_punct): Recognize the double-colon - token. - * cs-parser.jay (DOUBLE_COLON): New token. - (namespace_or_type_name): Add rule for recognizing - qualified-alias-members. - (primary_expression): Likewise. - (element_access): Allow QualifiedAliasMember as a possible - type-bearing expression. - (local_variable_type, local_variable_pointer_type): Likewise. - * namespace.cs (NamespaceEntry.LookupAlias): New. Looks up - aliases in the current and enclosing namespace declarations. - (NamespaceEntry.UsingAlias): Add CS0440 warning. - * decl.cs (MemberName.is_double_colon): New. - (MemberName.MemberName): Add new constructor for alias-member. - (MemberName.GetTypeExpression): Generate QualifiedAliasMember too. - * expression.cs (QualifiedAliasMember): New expression type. - -2005-08-02 Atsushi Enomoto - - * location.cs : it borked when no argument was specified. - -2005-08-02 Atsushi Enomoto - - * location.cs : tiny ToString() format fix. - -2005-08-02 Atsushi Enomoto - - * statement.cs : oops, it was missing. - -2005-08-02 Atsushi Enomoto - - A set of fixes for precise line/column location. - - * location.cs : - "token" field now holds a file/line "delta", a line number offset - from the segment, and a column number. See also: - http://lists.ximian.com/pipermail/mono-devel-list/2004- - December/009508.html - Removed static IsNull. Use instance IsNull property instead. - * cs-tokenizer.cs : - For some tokens it stores Location. For Identifier it stores - LocatedToken which is a pair of string name and location. - Column numbers are adjusted only at getChar(). - * report.cs : - Use Location.ToString() for reporting (it now contains column). - * cs-parser.jay : - Largely modified to use LocatedToken instead of - string (IDENTIFIER), and to acquire Location from some tokens. - * namespace.cs, decl.cs, ecore.cs, class.cs, delegate.cs, - iterators.cs, const.cs, anonymous.cs, tree.cs, enum.cs, - codegen.cs : - Now MemberName holds Location. DeclSpace.ctor() receives Location - as a parameter. Removed extra parameters to all derived classes. - Replaced Location.IsNull() with instance property. - * assign.cs, expression.cs : - Added .ctor() overload that omits Location. - * attribute.cs : - Added "nameEscaped" flag that indicates the identifier was escaped - in the source file. This fixes bug #57047. - -2005-08-02 Marek Safar - - * attribute.cs (AttributeTester.GetImportedIgnoreCaseClsType): - New method, looking for lo-case imported cls type. - - * decl.cs (DeclSpace.VerifyClsCompliance): Check CS3005 for types - here. - - * driver.cs: Removed VerifyTopLevelNameClsCompliance usage. - - * enum (Enum.VerifyClsCompliance): Hardcode non-compliant types. - - * typemanager.cs (TypeManager.AllClsTopLevelTypes): Renamed from - all_imported_types. - (TypeManager.LoadAllImportedTypes): Lo-case imported types. - - Optimized to save 3.5 MB for SWF compilation. - -2005-08-01 Marek Safar - - * class.cs (AddToTypeContainer): Use inheritance insted of if(s). - (PartialContainer.Create): Moved logic AddToContainer. - (PartialContainer.MarkForDuplicationCheck): Shares name. - - * decl.cs (DeclSpace.AddToContainer): Check name collisions at one - place. - - * namespace.cs (Namespace.AddDeclSpace): Lazy declspaces - initialization. - (Namespace.GetSignatureForError): New method. - - * tree.cs (Tree.RecordDecl): Moved to AddToContainer. - (RootTypes.AddToTypeContainer): se inheritance insted of if(s). - -2005-08-01 Raja R Harinath - - Fix #75669. - * ecore.cs (Expression.MemberLookupFailed): Use queried_type for - member lookup rather than qualifier_type, since qualifier_type can - be null. - -2005-08-01 Marek Safar - - * enum.cs (Enum.VerifyClsName): Fixed to allow not CLSCompliant - enum member. - -2005-07-31 Miguel de Icaza - - * statement.cs: Copy the local exception into the exception - captured local. Fixes 75674 - -2005-07-31 Raja R Harinath - - Fix #75658. - * expression.cs (Invocation.OverloadResolve): Don't report error - CS1501 if error CS1502 has been reported. - (New.DoResolve): Delegate CS1501 reporting to - Invocation.OverloadResolve. - - Fix #75656. - * statement.cs (Block.CheckInvariantMeaningInBlock): Verify - invariant-meaning-in-block property in an enclosing block if - necessary. - -2005-07-29 Marek Safar - - * statement.cs (SwitchLabel.ResolveAndReduce): Refactored. - (SwitchLabel.Erorr_AlreadyOccurs): Share error message. - (Switch.CheckSwitch): Just save 50kb for SWF. - -2005-07-27 Martin Baulig - - * anonymous.cs (CaptureContext.AddField): Added - `AnonymousContainer am' argument; compute its toplevel scope if - it's not already computed. Fixes #75649. - -2005-07-26 Raja R Harinath - - Fix #75628. - * class.cs (Constructor.Emit): Reset block to null if the block - resolve fails. - -2005-07-25 Marek Safar - - * class.cs (TypeContainer.VerifyMembers): Be compatible in warning 169. - -2005-07-25 Marek Safar - - * class.cs (MethodData.Define): Check whether accessor implementing - interface is public. - - * driver.cs (Driver.parse): Try to be smart and check for `MZ' header. - -2005-07-22 Marek Safar - - Fix #57245 - * namespace.cs (LookupType): Moved same type check to... - - * typemanager.cs (LookupTypeReflection): Don't allow to import more types - with the same name. - -2005-07-21 Raja R Harinath - - * namespace.cs (NamespaceLookupType): Avoid a string allocation when we - already found a typebuilder. - * class.cs (MethodCore.IsDuplicateImplementation): Compare - MemberNames, not strings. - - * const.cs (Error_ExpressionMustBeConst): - Rename from Error_EpressionMustBeConst. - * const.cs, class.cs, statement.cd: Update. - -2005-07-21 Marek Safar - - Fix #65573 - - * const.cs (Const.LookupConstantValue): Report missing contant expression - everytime. - (Error_EpressionMustBeConstant): Only one error method. - - * class.cs, statement.c: Updated. - -2005-07-20 Raja R Harinath - - * statement.cs (Block.Flags): Add back HasVarargs. - (Block.flags): Make protected. - (ToplevelBlock.HasVarargs): Convert to a property that updates flags. - - * typemanager.cs (types, typecontainers, user_types): Remove. - (UserTypes, TypeContainers): Likewise. - (HandleDuplicate, AddDelegateType, AddEnumType): Likewise. - (CleanUp, Reset): Update. - (AddUserType): Combine variants. Now, only updates builder_to_declspace. - (GetNestedType): Use Type.GetNestedType. - (CoreLookupType): Take two arguments, the namespace and the - basename of the type. Update to use the Namespace.Lookup - mechanism. - (InitEnumUnderlyingTypes, InitCoreTypes): Update. - (RealMemberLookup): Use IsNestedChildOf instead of playing with - string concatenation and substring matches. - * class.cs, enum.cs, delegate.cs: Update to changes. - -2005-07-20 Marek Safar - - * constant.cs (Constant.Error_ConstantValueCannotBeConverted): Moved from - Expression and made virtual. - - * convert.cs (ImplicitReferenceConversionExists): Skip for value types. - (ImplicitStandardConversionExists): Fixed `byte' typo ? - - * ecore.cs (Expression.Error_ConstantValueCannotBeConverted): Moved. - - * literal.cs (NullLiteral.Error_ConstantValueCannotBeConverted): Customize - error message. - - * convert.cs, ecore.cs, enum.cs: Reflect Error_ConstantValueCannotBeConverted - change. - -2005-07-18 Marek Safar - - Fix #57707 - * codegen.cs (AssemblyClass.ApplyAttributeBuilder): Check whether - AssemblyCultureAttribute is not used on executable. - - * rootcontext.cs, - * typemanager.cs: Add System.Reflection.AssemblyCultureAttribute. - -2005-07-16 Raja R Harinath - - Fix #60638. - * expression.cs (Binary.Warning_UnintendeReferenceComparison): - New. Reports CS0252/CS0253. - Mostly taken from preliminary patch by Duncak Mak. - (Binary.DoResolveOperator): Store results of operator lookup. - Use them to detect if we need to warn about unintended reference - comparisons. - -2005-07-15 Raja R Harinath - - Fix #72969. - * namespace.cs (Namespace.Lookup): Add back location parameter. - (Namespace.LookupType): Add CS0436 report. Add location parameter. - * delegate.cs, ecore.cs, expression.cs: Update to changes. - - * codegen.cs (EmitContext.DeclSpace): Make readonly. - * namespace.cs (Namespace.Lookup): Carve out type lookup into ... - (Namespace.LookupType): ... this. - (NamespaceEntry.GetUsingTable): Allocate only one zero-sized array - of namespaces. - * typemanager.cs (LookupTypeReflection): Remove buggy code that - purported to handle pointers. - (char_ptr_type, void_ptr_type): Use GetPointerType rather than - CoreLookupType. - -2005-07-15 Marek Safar - - * expression.cs (MemberAccess.ResolveNamespaceOrType): Don't report nested - type as namespace. - -2005-07-15 Raja R Harinath - - * namespace.cs (Namespace.Lookup): Drop location parameter. - (NamespaceEntry.LookupAlias): Remove. Merge into ... - (NamespaceEntry.Lookup): ... this. - (NamespaceEntry.Error_AmbiguousTypeReference): - Move here from DeclSpace. - (NamespaceEntry.LookupNamespaceOrType): Move support for dotted - names ... - * ecore.cs (TypeLookupExpression.DoResolveAsTypeStep): ... here. - * decl.cs (DeclSpace.ErrorAmbiguousTypeReference): - Move to NamespaceEntry. - * delegate.cs, expression.cs: Update to changes. - -2005-07-14 Marek Safar - - * attribute.cs (Attribute.ResolveAttributeType): Renamed from - CheckAttributeType and refactored. - (Attribute.ResolvePossibleAttributeType): Changed to reuse - ResolveAsTypeTerminal error handling. - (ResolveAsTypeTerminal): Introduced because of global attributes extra - handling. - (GetSignatureForError): Print errors in same way. - - * class.cs, - * codegen.cs: Reflect attribute GetSignatureForError change. - - * ecore.cs, - * expression.cs: Add silent parameter to ResolveAsTypeStep. - - * namespace.cs (UsingEntry): Refactored to make fields private. - - * assign.cs, - statement.cs: Error_UnexpectedKind has extra parameter. - -2005-07-14 Raja R Harinath - - * ecore.cs (IAlias): Remove. - * decl.cs (DeclSpace): Don't derive from IAlias. Remove members - that implement the interface. - * namespace.cs (Namespace): Likewise. - (Namespace.declspaces): Renamed from 'defined_names'. - (Namespace.AddDeclSpace): Renamed from 'DefineName'. Take a - DeclSpace instead of an IAlias. - * tree.cs (Tree.AddDecl): Update. - -2005-07-12 Raja R Harinath - - * statement.cs (Block.Flags); Remove HasVarargs. - (Block.HasVarargs): Move to ToplevelBlock. - (Block.ThisVariable, Block.AddThisVariable): Likewise. - (Block.Variables): Make protected. Initialize variable hashtable - if necessary. - (Block.AddVariable): Update. - (Block.Resolve): Update to changes. - (ToplevelBlock.HasVarargs): New boolean. - (ToplevelBlock.ThisVariable): Move here from Block. - (ToplevelBlock.AddThisVariable): Likewise. - (ToplevelBlock.IsThisAssigned): New. Forwards call to this_variable. - * expression.cs (This.ResolveBase): Update to changes. - (ArglistAccess.DoResolve): Likewise. - -2005-07-11 Marek Safar - - Fix #75321 - * ecore.cs, class.cs: Use SetAssigned instead of direct access. - - * class.cs (TypeContainer.VerifyMembers): Distinguish between - not used and not used & assigned. - (FieldBase.ASSIGNED): Moved to MemberCore.Flags. - -2005-07-11 Marek Safar - - Fix #75053 - * expression.cs (Is.DoResolve): null is never provided type. - -2005-07-08 Marek Safar - - Fix #52496 - * cs-parser.jay: Less strict event error rule to catch more errors. - -2005-07-08 Martin Baulig - - Fix test-iter-10.cs - distinguish whether we `yield' in a property - gettter (allowed) or setter (not allowed). - - * class.cs (Accessor): Implement IIteratorContainer. - (Accessor.Yields): New public field. - (PropertyBase.PropertyMethod.Define): Handle iterators on a - per-accessor basis. - - * cs-parser.jay - (get_accessor_declaration, set_accessor_declaration): Set the - `yields' flag on the accessor, not the property. - (property_declaration): Do the iterators check on a per-accessor - basis and not for the whole property. - -2005-07-08 Martin Baulig - - * anonymous.cs (CaptureContext.EmitParameterInstance): Correctly - handle parameters in nested scopes; fixes #74808; see gtest-188.cs. - -2005-07-07 Marek Safar - - Fix #74975 - * attribute.cs (orig_sec_assembly): Holds original version of assembly. - (ExtractSecurityPermissionSet): Cope with self referencing security - attributes properly. - - * driver.cs (SetOutputFile): Made public property OutputFile. - -2005-07-07 Raja R Harinath - - Fix #75486. - * class.cs (TypeContainer.first_nonstatic_field): Rename from - has_nonstatic_fields. Make into a FieldBase pointer. - (TypeContainer.AddField): Add CS0282 check. - (TypeContainer.EmitType): Update. - -2005-07-06 Miguel de Icaza - - * cs-tokenizer.cs (consume_identifier): Do not create strings to - compare if they start with __. - -2005-07-06 Raja R Harinath - - * statement.cs (Switch.SwitchGoverningType): Only look at - UserCasts that don't need implicit standard conversions to one of - the allowed switch types (Fixes test-322.cs). - (LocalInfo.Resolve): Re-enable sanity-test. - -2005-07-06 Marek Safar - - * cs-tokenizer.cs (consume_identifier): Detect double undescores - - * ecore.cs (FieldExpr.AddressOf): Changed volatile error to warning. - - * expression.cs (Invocation.DoResolve): Report error CS0245 here. - -2005-07-06 Raja R Harinath - - Fix #75472. - * ecore.cs (SimpleName.GetSignatureForError): Add. - * expression.cs (MemberAccess.DoResolve): Don't clobber 'expr' field. - (MemberAccess.GetSignatureForError): Add. - -2005-07-05 Marek Safar - - The big error and warning messages review. - - * anonymous.cs, - * assign.cs, - * attribute.cs, - * class.cs, - * codegen.cs, - * convert.cs, - * cs-parser.jay, - * cs-tokenizer.cs, - * decl.cs, - * delegate.cs, - * doc.cs, - * driver.cs, - * ecore.cs, - * enum.cs, - * expression.cs, - * flowanalysis.cs, - * iterators.cs, - * literal.cs, - * location.cs, - * modifiers.cs, - * namespace.cs, - * parameter.cs, - * pending.cs, - * report.cs, - * rootcontext.cs, - * statement.cs, - * support.cs, - * tree.cs, - * typemanager.cs: Updated. - - * class.cs: (MethodCore.SetYields): Moved here to share. - (PropertyMethod.Define): Moved iterator setup here. - - * iterators.cs: Add orig_method to have full access to parent - container. - -2005-07-05 Raja R Harinath - - Make 'fixed variable' handling standards compliant. Fix #70807, #72729. - * ecore.cs (IVariable.VerifyFixed): Remove 'is_expression' parameter. - (FieldExpr.VerifyFixed): Ensure that the field is part of a fixed - variable of struct type. - * expression.cs (Unary.ResolveOperator): Update to change. - (Indirection.VerifyFixed): Likewise. - (LocalVariableReference.VerifyFixed): A local variable is always fixed. - (ParameterReference.VerifyFixed): Value parameters are fixed. - (This.VerifyFixed): Treat 'this' as a value parameter. - * statement.cs (LocalInfo.IsFixed): Remove. - -2005-07-01 Martin Baulig - - * iterators.cs (Iterator.CapturedThisReference.Emit): Use - `ec.EmitThis ()' to get the correct scope. - -2005-07-01 Martin Baulig - - * ecore.cs (FieldExpr.DoResolve): Don't capture the field if it's - instance is a ParameterReference; fixes #75299. - -2005-07-01 Martin Baulig - - Reverted Marek's latest patch (r46725): - - it contains structural changes which are neither mentioned in - the ChangeLog nor explained anywhere; for example the additional - argument of EmitContext's and Iterator's .ctor's and the - TypeContainer.DefineMembers() change. - - structural changes like this should go in in seperate patches - and not be hidden in a huge patch which just seems to affect - warnings and errors. - a big and hard to understand patch. - - it breaks iterators and causes regressions, for instance in - test-iter-03.cs. - -2005-06-30 Raja R Harinath - - Fix #75412. - * expression.cs (Indexers.map): Remove. - (Indexers.Append): Filter out inaccessible setters and getters. - (IndexerAccess.DoResolve, IndexerAccess.DoResolveLValue): Update. - - Fix #75283. - * ecore.cs (MemberExpr.EmitInstance): New. Add CS0120 check. - Refactored from ... - (FieldExpr.EmitInstance, PropertyExpr.EmitInstance): ... these. - (FieldExpr.Emit, PropertyExpr.Emit): Update. - (FieldExpr.EmitAssign, PropertyExpr.EmitAssign): Update. - * expression.cs (Invocation.EmitCall): Add CS0120 check. - -2005-06-30 Marek Safar - - Fix #75322 - * class.cs (FieldBase.GetInitializerExpression): One more field - for backup. - -2005-06-28 Miguel de Icaza - - * pending.cs: Do not define a proxy if the base method is virtual, - it will be picked up by the runtime (bug 75270). - -2005-06-08 Martin Baulig - - The big Iterators rewrite :-) - - * iterators.cs: Rewrite this to use the anonymous methods framework. - - * rootcontext.cs (RootContext.DefineTypes): Define Delegates - before the TypeContainers; see 2test-21.cs. - - * class.cs - (TypeContainer.DefineType): Don't create a new EmitContext if we - already have one (this only happens if we're an Iterator). - (TypeContainer.Define): Also call Define() on all our iterators. - (Method.CreateEmitContext): Added support for iterators. - - * anonymous.cs - (AnonymousContainer): New abstract base class for `AnonymousMethod'. - (AnonymousContainer.CreateMethodHost): Moved here from - AnonymousMethod and made abstract. - (AnonymousContainer.CreateScopeType): New abstract method. - (AnonymousContainer.IsIterator): New public property. - (ScopeInfo.EmitScopeType): Call CreateScopeType() on our Host to - get the ScopeTypeBuilder rather than manually defining it here. - (ScopeInfo.EmitScopeInstance): New public method; correctly handle - iterators here. - - * driver.cs (Driver.MainDriver): Call TypeManager.InitCodeHelpers() - before RootContext.DefineTypes(). - - * codegen.cs (EmitContext.RemapToProxy): Removed. - (EmitContext.CurrentAnonymousMethod): Changed type from - AnonymousMethod -> AnonymousContainer. - (EmitContext.ResolveTopBlock): Protect from being called twice. - (EmitContext.MapVariable, RemapParameter(LValue)): Removed. - (EmitContext.EmitThis): Removed the iterators hacks; use the - anonymous methods framework for that. - - * statement.cs - (ToplevelBlock.Container): Make this a property, not a field. - (ToplevelBlock.ReParent): New public method; move the - ToplevelBlock into a new container. - (Foreach.TemporaryVariable): Simplify. - -2005-06-05 Martin Baulig - - * statement.cs (LocalInfo.CompilerGenerated): New flag. - (Block.AddTemporaryVariable): New public method; creates a new - `LocalInfo' for a temporary variable. - (Block.EmitMeta): Create the LocalBuilders for all the temporary - variables here. - (Foreach.TemporaryVariable): Use Block.AddTemporaryVariable() for - non-iterator variables. - -2005-06-05 Martin Baulig - - * statement.cs (Foreach.TemporaryVariable): Create the - LocalBuilder in the Emit phase and not in Resolve since in some - situations, we don't have an ILGenerator during Resolve; see - 2test-19.cs for an example. - -2005-06-04 Martin Baulig - - **** Merged r45395 from GCS **** - - The big Foreach rewrite - Part II. - - * typemanager.cs (TypeManager.object_getcurrent_void): Replaced - with `PropertyInfo ienumerator_getcurrent'. - - * codegen.cs (VariableStorage): Removed. - - * statement.cs - (Foreach): Derive from Statement, not ExceptionStatement. - (Foreach.CollectionForeach): New nested class. Moved all the code - dealing with collection foreach here. - (Foreach.ForeachHelperMethods): Removed. - (Foreach.TemporaryVariable): Implement IMemoryLocation. - -2005-05-23 Martin Baulig - - * statement.cs (Try.DoResolve): Don't create a `finally' if we - don't need to. Fix #75014. - -2005-05-20 Martin Baulig - - Merged r44808 from GMCS. - - * class.cs (TypeContainer.CircularDepException): Removed. - (TypeContainer.DefineType): Removed the `InTransit' stuff. - (TypeContainer.CheckRecursiveDefinition): Check for circular class - (CS0146) and interface (CS0529) dependencies here. - -2005-06-21 Raja R Harinath - - * expression.cs (Invocation.EmitCall): Fix initialization - 'this_call' to reflect current behaviour. Fix indentation. - - * convert.cs (FindMostEncompassedType): Add two trivial special - cases (number_of_types == 0 || number_of_types == 1). - (FindMostEncompasingType): Likewise. - -2005-06-17 Raja R Harinath - - Some cleanups preparing for the fix of #75283. - * ecore.cs (PropertyExpr.InstanceResolve): Tighten conditions for - error testing. - (EventExpr.InstanceResolve): Likewise. - (EventExpr.DoResolve): Remove redundant checks. - -2005-06-10 Duncan Mak - - * cs-tokenizer.cs (process_directives): New flag for controlling - the processing of preprocessor directives. - (x_token): After seeing a '#', return Token.NONE instead of going - to handle_preprocessing_directive() when not processing - directives. This avoids unnecessary processing during the token peek in - is_punct(). - - This fixes #74939. - - * cs-tokenizer.cs (handle_preprocessing_directive, xtoken): Use - the existing error reporting methods instead of Report.Error. - - * convert.cs (priv_fmt_expr): Remove. It's not needed anymore - after Raja's rewrite. - -2005-06-08 Miguel de Icaza - - * class.cs: Small fix. - -2005-06-08 Raja R Harinath - - Fix #75160. - * class.cs (GetPartialBases): Fix return value check of - part.GetClassBases. - -2005-06-07 Raja R Harinath - - Ensure that partial classes are registered in their enclosing - namespace. Initial part of fix of #75160. - * tree.cs (Tree.RecordDecl): Add new namespace argument. - Register declspace with namespace here, not in - DeclSpace.RecordDecl. - * cs-parser.jay: Pass namespace to RecordDecl. - * class.cs (PartialContainer.Create): Likewise. - (ClassPart.DefineType): New sanity-check. Throws an exception if - called. - * decl.cs (Declspace.RecordDecl): Remove. - * namespace.cs (NamespaceEntry.DefineName): Remove. - -2005-06-06 Marek Safar - - * rootcontext.cs: Reset TargetExt as well. - -2005-06-03 Raja R Harinath - - * ecore.cs (Expression.Resolve): Emit CS0654 error when - -langversion:ISO-1. - -2005-06-02 Raja R Harinath - - Fix #75080, cs0119.cs. - * ecore.cs (Expression.ExprClassToResolveFlags): New. Broken out - of ... - (Expression.Resolve): ... this. Use it. Remove bogus code - allowing ExprClass.Type and ExprClass.Namespace for - ResolveFlags.VariableOrValue. - (Expression.Resolve) [1-argument variant]: Change default resolve - flags based on language version. - (Expression.Error_UnexpectedKind): Use a simple string array - rather than an ArrayList. - * expression.cs (TypeOf.DoResolve): Set eclass to ExprClass.Value, - not ExprClass.Type. - (TypeOfVoid.DoResolve): Likewise. - (MemberAccess.DoResolve) [3-argument variant]: Make private. Drop - flags argument -- it always has the same value. - -2005-05-31 Raja R Harinath - - Fix #75081. - * ecore.cs (Expression.ResolveLValue): Add a Location parameter. - Use it in the error message. - * assign.cs, expression.cs, statement.cs: Update. - -2005-05-30 Raja R Harinath - - Fix #75088. - * ecore.cs (Expression.MemberLookupFailed): Add CS0122 check in - the "almostMatchedMember" case too. - * typemanager.cs (Closure.CheckValidFamilyAccess): Add anything - that failed the accessibility checks to 'almost_match'. - -2005-05-27 Vladimir Vukicevic - - * attribute.cs: Use internal MethodBuilder methods to set - ExactSpelling and SetLastError on PInvoke methods, instead - of passing them via charset. Fixes #75060. - -2005-05-27 Raja R Harinath - - * parameter.cs (Parameter): Remove TODO comment. - (Parameter.DefineParameter): Remove Location parameter. - (Parameters.LabelParameters): Likewise. - * class.cs (Constructor.Emit): Update to change. - (MethodData.Emit): Likewise. - * anonymous.cs (AnonymousMethod.EmitMethod): Likewise. - * delegate.cs (Delegate.Define, Delegate.Emit): Likewise. - -2005-05-27 Atsushi Enomoto - - * parameter.cs, - Removed Parameters.Location and added Parameter.Location instead. - Removed Location parameter from Emit() and GetSignature(). - * anonymous.cs, - class.cs, - cs-parser.jay, - delegate.cs, - iterators.cs, - statement.cs : - Modified all related calls. - -2005-05-26 Raja R Harinath - - Improve user-defined conversion handling. - * convert.cs (GetConversionOperators): Rewrite. Return only the - applicable operators. - (AddConversionOperators): New. Helper for GetConversionOperators. - (FindMostEncompassedType, FindMostEncompassingType): Verify that - there is only one most encompassed/encompassing type. - (FindMostSpecificSource, FindMostSpecificTarget): Remove - "applicable operator" handling. - (UserConversion): Move cache here from GetConversionOperators. - Directly cache the chosen operator, rather than the whole - MethodGroup. - (ExplicitNumericConversion): Fix buggy implementation of Decimal - case. Allow conversion of decimal to sbyte and byte too. - * expression.cs (EmptyExpression.Grab, EmptyExpression.Release): - New static methods. Used to avoid allocating EmptyExpressions in - convert.cs. - -2005-05-24 Duncan Mak - - * ecore.cs (CastFromDecimal): New class for casting a decimal to - another class, used in Convert.ExplicitNumericConversion. - (CastToDecimal): New class, similar to above, but casts to - System.Decimal, used in Convert.ImplicitNumericConversion and also - in explicit convesion from double/float to decimal. - - * convert.cs (ImplicitNumericConversion): Handle implicit - conversions to System.Decimal. - (ExplicitNumericConversion): handle explicit conversions to - System.Decimal. - - This fixes #68711. - -2005-05-20 Miguel de Icaza - - * typemanager.cs (EnumToUnderlying): Do not throw if we do not - know the type at this stage, just break through. Fixes #75008 - -2005-05-19 Martin Baulig - - * delegate.cs - (ImplicitDelegateCreation.Check): Added `bool check_only' argument - to disable error reporting. - - * convert.cs (Convert.ImplicitStandardConversionExists): Use it - here since we don't want to report an error; see the new test-336.cs. - -2005-05-19 Raja R Harinath - - * statement.cs (ToplevelBlock.GetParameterReference) - (ToplevelBlock.IsParameterReference,ToplevelBlock.IsLocalParameter): - Move here from class Block. - * ecore.cs (SimpleName.SimpleNameResolve): Update to changes. - * expression.cs (ParameterReference.DoResolveBase): Likewise. - -2005-05-18 Martin Baulig - - Fix #74978. - - * flowanalysis.cs - (FlowBranching.Reachability): Add non-static public And() and Or() - methods. - (FlowBranchingSwitch): New class; do the `break_origins' thing - like in FlowBranchingLoop. - (FlowBranching.UsageVector.MergeBreakOrigins): Also merge the - reachability, not just locals and parameters. - (FlowBranching.MergeChild): Remove some of the hacks for loop and - switch; MergeBreakOrigins() now takes care of that. - -2005-05-18 Martin Baulig - - * flowanalysis.cs (FlowBranching.UsageVector.MergeChild): If we're - a loop and may leave it, reset the barrier; fixes #74974. - -2005-05-17 Marek Safar - - * attribute.cs (Attribute.ResolveArguments): GuidAttribute check - is back. - - * cs-parser.jay: Catch more lexical errors. - - * report.cs: Add one more Error method. - - * rootcontext.cs, - * typemanager.cs: Register System.Runtime.InteropServices.GuidAttribute - -2005-05-17 Martin Baulig - - * expression.cs (Argument.Resolve): Turn on flow analysis; fix - #70970. - -2005-05-16 Raja R Harinath - - Fix test-382.cs. Emit values of decimal constants. - * class.cs (TypeContainer.RegisterFieldForInitialization): New. - Carved out of ... - (TypeContainer.AddField): ... this. - (TypeContainer.EmitFieldInitializers): Allow the list of fields - with initializers to include 'Const's. - (ClassPart.RegisterFieldForInitialization): Forward to - PartialContainer. - * const.cs (Const.Const): Pass initializer to base class. - (Const.Define): In case of decimal constants, register them for - initialization in a static constructor. - -2005-05-14 Martin Baulig - - * statement.cs (Block.Resolve): Correctly handle unreachable code; - do not call ResolveUnreachable() on unreachable statements in - here, see the comment in the source code. - -2005-05-13 Raja R Harinath - - Fix #74934. - * expression.cs (BinaryResolveOperator): If one of the operands of - an equality comparison is 'null' and the other is a pointer type, - convert the null to a NullPointer. - * convert.cs (ImplicitReferenceConversion): If the expression is a - NullLiteral and the target type is a pointer type, return a - NullPointer instead. - (ImplicitConversionStandard): Likewise. - -2005-05-13 Marek Safar - - * cs-parser.jay: Set readonly context based on special constructs. - - * expression.cs (LocalVariableReference.DoResolveBase): Improved - readonly variable error handling. - - * rootcontext.cs (EmitCode): Don't verify members when error - occurred. - - * statement.cs (LocalInfo): Add reaodnly context information. - (SetReadOnlyContext, GetReadOnlyContext): New methods. - -2005-05-13 Raja R Harinath - - * statement.cs (Block.Resolve): Revert change below. Modify fix - for #74041 to initialize 'resolved' to false only for explicit - blocks. Fixes #74873. - -2005-05-12 Raja R Harinath - - Fix #74920. - * typemanager.cs (unmanaged_enclosing_types): New. - (IsUnmanagedType): Avoid infloops by using - 'unmanaged_enclosing_types' to talk with recursive invocations. - -2005-05-13 Martin Baulig - - * statement.cs (Block.Resolve): Make the `bool unresolved' flag an - instance variable, not a local. Fix #74873. - (Block.ResolveUnreachable): Set it to true here. - -2005-05-11 Duncan Mak - - * cs-tokenizer.cs (get_cmd_arg): Check that 'c' is not -1 before - continuing to process for 'arg'. - (handle_preprocessing_directive): Check the argument of the #endif - directive and report error CS1025 if there are any trailing - characters. - - According to the C# spec, having even whitespace after the #endif - directive is illegal; however, because we call arg.TrimEnd () - beforehand, we have the same behavior as csc, allowing whitespace - after the directive. - - Fixes #74892. - -2005-05-11 Marek Safar - - Fix #74863. - - * class.cs (ConstructorInitializer.GetOverloadedConstructor): Removed. - (Constructor.GetObsoleteAttribute): Implemented correctly. - -2005-05-10 Martin Baulig - - * support.cs (ReflectionParameters.ParameterModifier): Use - `Parameter.Modifier.REF' if we both have `ParameterAttributes.Out' - and `ParameterAttributes.In'. Fixes #74884. - -2005-05-10 Marek Safar - - * class.cs (Method.Define): Catch attempt for Finalizer declaration. - - * expression.cs (Argument.GetParameterModifier): Turned to property. - (Invocation.Error_InvalidArguments): Add more descriptive errors. - - * parameter.cs (Parameter.GetModifierSignature): Translates modifier to - its C# equivalent. - -2005-05-09 Raja R Harinath - - Fix #74852. - * decl.cs (MemberCache.AddMethods): Register override methods, - rather than non-override methods. - * typemanager.cs (RegisterOverride): New. - (IsOverride): Update. - -2005-05-09 Marek Safar - - Fix #73105. - - * ecore.cs (SimpleName.SimpleNameResolve): Add in_transit to catch - recursive declaration. - - * statement.cs (Block.ResolveMeta): Report any error in resolving. - -2005-05-06 Marek Safar - - * cfold (DoConstantNumericPromotions): Don't try to convert 0 enum. - - * expression.cs (Binary.DoResolve): (x && 0) is always 0. - -2005-05-05 Raja R Harinath - - Fix #74797. - * decl.cs (DeclSpace.FamilyAccessible): - Use TypeManager.IsNestedFamilyAccessible. - - Fix reopened #64812. - * typemanager.cs (Closure.Filter): Introduce checks for 'protected - internal'. - -2005-05-04 Raja R Harinath - Abin Thomas - Anoob V E - Harilal P R - - Fix #64812. - * typemanager.cs (Closure.CheckValidFamilyAccess): Don't blindly - allow access to all static members. - -2005-05-04 Martin Baulig - - * ecore.cs (FieldExpr.DoResolveLValue): Always call fb.SetAssigned(). - -2005-05-04 Martin Baulig - - Fix #74655. - - * statement.cs (Switch.SimpleSwitchEmit): Always emit the default - section at the end; make things work if `default' is not the last - section. - -2005-05-04 Martin Baulig - - Fix #70400. - - * statement.cs (Switch): Replaced the `got_default' field with a - `default_section' one. - (Switch.CheckSwitch): Set `default_section' here. - (Switch.Resolve): If we're a constant switch and the constant is - not found, use the default section. - -2005-05-03 Martin Baulig - - * expression.cs (ArrayAccess.EmitGetLength): New public method. - - * statement.cs (Foreach.ArrayForeach): New nested class. - (Foreach.TemporaryVariable): New nested class. - (Foreach.EmitArrayForeach): Removed; this is now in the new - ArrayForeach class. - -2005-05-03 Raja R Harinath - - * pending.cs (BaseImplements): Move the #74773 fix here. This is - more conservative. - (VerifyPendingMethods): Revert change below. - - * typemanager.cs (IsOverride, RegisterNonOverride): New. - * decl.cs (MemberCache.AddMethod): Register "non-override" methods - that used to trigger warning -28. Remove warning -28. - * expression.cs (Invocation.OverloadResolve): Use - TypeManager.IsOverride to distinguish override methods. - - Fix #74773. - * pending.cs (VerifyPendingMethods): If a base type implements the - requested interface, don't bother checking individual methods of - the base type. As a side-effect, this prevents the creation of - unnecessary proxies. - -2005-05-02 Martin Baulig - - Fix #70182. - - * flowanalysis.cs (FlowBranching.UsageVector.MergeJumpOrigins): - Also `And' the locals if the old vector is null. - (FlowBranching.UsageVector.BitVector.And): Allow `vector' being - null; in this case we basically reset all the variables. - -2005-05-02 Martin Baulig - - Fix #74529. - - * flowanalysis.cs (FlowBranching.UsageVector.MergeBreakOrigins): - Added `FlowBranching branching' argument; always `and' the - variables instead of `or'ing them unless we're an infinite loop. - - * statement.cs (While.Resolve): Create a new sibling unless we're - infinite. - -2005-05-02 Martin Baulig - - Fix #70140. - - * class.cs (ConstructorInitializer.Resolve): Added `Block block' - arguments; use it instead of creating a new TopLevelBlock. - (Constructor.Emit): Call `block.ResolveMeta ()' before resolving - our ConstructorInitializer. - - * statement.cs - (TopLevelBlock.TopLevelBranching): New public property. - (TopLevelBlock.ResolveMeta): New public method; call ResolveMeta() - and create our `TopLevelBranching'. - - * codegen.cs (EmitContext.ResolveTopBlock): If we're not an - anonymous method host, use `block.TopLevelBranching' rather than - creating a new branching. - -2005-04-20 Miguel de Icaza - - * anonymous.cs (ScopeInfo.AddChild): when adding a new child to - a ScopeInfo, if any of the current children is a child of the new - entry, move those children there. - -2005-04-30 Martin Baulig - - * statement.cs (Switch.SimpleSwitchEmit): Reset `default_at_end' - at the beginning of a SwitchSection. Fix #73335. - -2005-04-27 Marek Safar - - Fix #74378 - * class.cs (EmitFieldInitializers): Use FieldExpr in initializer. - - * ecore.cs (FieldExpr): Add a new ctor with in_initializer. - (FieldExpr.DoResolve): Obsolete members are ignored for field - initializers. - -2005-04-26 Marek Safar - - * attribute.cs (AreOverloadedMethodParamsClsCompliant): Add array - of arrays detection. - - * class.cs (Interface.VerifyClsCompliance): Add base interfaces - verification. - (Field.VerifyClsCompliance): Volatile fields are not compliant. - - * decl.cs (MemberCache.VerifyClsParameterConflict): Add array of - arrays report. - -2005-04-25 Ben Maurer - - * cs-parser.jay: Use the prefered version of -unsafe in error - message. - -2005-04-22 Marek Safar - - * driver.cs (CompilerCallableEntryPoint.Invoke): Reset under any - circumstances. - -2005-04-20 John Luke - - * driver.cs: fix typo in error message, --outout to --output - -2005-04-20 Marek Safar - - * codegen.cs (InRefOutArgumentResolving): New field. - - * ecore.cs (FieldExpr.DoResolve): Check for assigning to readonly - fields outside contructor. - - * expression.cs (Argument.Resolve): Set InRefOutArgumentResolving. - -2005-04-19 Miguel de Icaza - - * anonymous.cs (CaptureContext.EmitParameterInstance): The - parameter code was not completed ever, so it was not as up-to-date - as local variables. Must finish it. - - The bug fix was to compare the Toplevel of the block, not the - current block. Thanks for Ben for pointing this out. - -2005-04-19 Raja R Harinath - - * decl.cs (AddMethods): Use the declaring type of the problem - method to determine if we want to squash a warning. - -2005-04-19 Marek Safar - - * attribute.cs: Removed debug output. - - * decl.cs (MemberCache.AddMethods): Fixed Finalize ignoring. - - * driver.cs (Driver.parse): Synchronize parser ErrorOutput with - Report.Stderr. - -2005-04-18 Raja R Harinath - - Fix #74481. - * expression.cs (Binary.EqualsNullIsReferenceEquals): New. - (Binary.DoResolveOperator): Use it to avoid blindly optimizing out - all null comparisons against reference types. - -2005-04-18 Marek Safar - - Fix# 74565 - * class.cs (TypeContainer.CircularDepException) New nested - exception class. - (GetPartialBases, GetNormalBases, GetClassBases): Removed error. - (TypeContainer.DefineType): Removed error, reset InTransit before - exit. - (Class.DefineType): Throw exception when is in Transit. - Catch exception and report error. - (Struct.DefineType): Throw exception when is in Transit. - Catch exception and report error. - (Interface.DefineType): Throw exception when is in Transit. - Catch exception and report error. - - * codegen.cs: Add InCatch,InFinally to EmitContext to easily - handle nested exception handlers. - - * flowanalysis.cs (InTryWithCatch): New method, search for try with - a catch. - - * iterators.cs (Yield.CheckContext): Add CS1626 report. Updated - InFinally and InCatch storage. - - * statement.cs (Throw.Resolve): Use InCatch, InFinally from ec. - (Catch.Resolve): Set and Restore ec.InCatch. - (Try.Resolve): Set and Restore ec.InFinally. - (Try.HasCatch): True when try has catch. - -2005-04-17 Atsushi Enomoto - - * doc.cs : In some cases FilterName returns MonoEvent and MonoField - for the same event member, so exclude such cases from warning 419. - Fixed bug #74633. - -2005-04-16 Miguel de Icaza - - * expression.cs (Binary.ResolveOperator): Apply patch from John - Luke to fix bug 59864: operators &, | and ^ on enumerations - require that the same enum type on both sides. - - * driver.cs: Add warnings to old flag usage, this is to assist - people who produce Makefiles and hope that the Makefiles will be - used on Windows. - - * class.cs (TypeContainer.EmitType): Moved the definition of the - special $PRIVATE$ field from the resolve phase to the Emit phase. - During resolve we do not know if we are a struct with - HasExplicitLayout, we know this only after the attributes for the - type are emitted. - - Set the FieldOffset to zero on the dummy field that we create for - the class. Fixes 74590. - -2005-04-16 Raja R Harinath - - Fix #73834. - * ecore.cs (PropertyExpr.resolved): New. - (DoResolve): Use it to handle a case of double resolution here. - Handle a case of identical-name-and-type-name. - * expression.cs (ArrayCreation.CheckIndices): Avoid double - resolution by storing the results of expression resolution back - into the "probes" array. - -2005-04-15 Raja R Harinath - - Fix cs0208-7.cs and cs0208-8.cs. - * typemanager.cs (IsUnmanagedType): Arrays are not allowed - (cf. ECMA standard, behaviour of CSC 1.1 and CSC 2.0). Improve - error reporting to point out the reason a struct is not unmanaged. - -2005-04-13 Atsushi Enomoto - - * doc.cs : In FindDocumentedType(), avoid TypeExpr.ResolveType() and - just use TypeExpr.Type. This fixes bug #74595 when merged to gmcs. - -2005-04-13 Raja R Harinath - - Fix #74528. - * ecore.cs (PropertyExpr.InstanceResolve): Handle a case of - IdenticalNameAndTypeName here. - (EventExpr.InstanceResolve): Likewise. - -2005-04-13 Marek Safar - - C# 2.0 DefaultCharSetAttribute implementation - - * attribute.cs (Attribute.ResolveAsTypeStep): New protected method - which allows us to set GlobalNamespace for every resolve. - (Attribute.ResolveArguments): Cut from Resolve. - (Attribute.GetCharSetValue): Returns CharSet named argument. - (Attribute.DefinePInvokeMethod): Gets default charset from - module settings. - (GlobalAttribute.ResolveAsTypeStep): Override. - (GlobalAttribute.ResolveArguments): Override. - - * class.cs (TypeAttr): Is protected. - - * codegen.cs (ModuleClass.DefaultCharSet): New member. - (ModuleClass.DefaultCharSetType): New memeber. - (ModuleClass.ResolveAttributes): Resolves DefaultCharSetAttribute. - - * decl.cs (Decl.TypeAttr): New protected virtual. Returns default - charset from module. - - * delegate.cs (TypeAttr): Override. - (Delegate.DefineType): Use this TypeAttr. - - * driver.cs (Driver.MainDriver): Call Module.ResolveAttributes - at very early stage (before types are defined) to resolve model - module attributes. It will probably not work with corlib but it - should be ok. - - * enum.cs (Enum.TypeAttr): New protected virtual. Returns default - charset from module. - - * typemanager.cs (default_charset_type): New type. - -2005-04-13 Raja R Harinath - - * decl.cs (MemberCache.AddMethods): Don't warn if - System.Object.Finalize has buggy MethodAttributes. - - * typemanager.cs (IsUnmanagedType): Restore !IsValueType check - removed below. - -2005-04-13 Atsushi Enomoto - - * doc.cs : detect ambiguous reference to overloaded members. - Fixed bug #71603. MS 1.1 csc does not detect it. - -2005-04-13 Atsushi Enomoto - - * doc.cs : delegates must not be referenced with parameters. - Fixed bug #71605. - -2005-04-12 Miguel de Icaza - - * typemanager.cs (IsUnmanagedType): Arrays are allowed. - -2005-04-10 Miguel de Icaza - - * driver.cs (MainDriver): Stop processing if the CLS stage found - errors. - - (CompilerCallableEntryPoint.InvokeCompiler): Always - reset after execution; Take a TextWriter argument for the - output. - - * report.cs: Use the error stream instead of hardcoding stderr. - -2005-04-09 Miguel de Icaza - - * class.cs: Reduce code paths to test, too small of an - optimization to make it worth the extra testing. Always perform - it. - -2005-04-08 Raja R Harinath - - Fix #74510. - * class.cs (OperatorArrayList.CheckPairedOperators): Skip - operators that had errors reported on them. - -2005-04-08 Marek Safar - - * attribute.cs (Attribute.IsValidArgumentType): Test valid named - argument types. - (Attribute.Resolve): Add named argument type checking. - - * class.cs (FixedField.Define): Use IsPrimitiveType - - * expression.cs (Binary.ResolveOperator): Reflect IsCLRType renaming. - - * iterators.cs (Iterator.DefineIterator): Add check for arglist and - unsafe parameter types. - - * statement.cs (Using.ResolveExpression): Add better error description. - - * typemanager.cs (IsCLRType): Renamed to IsPrimitiveType. - -2005-04-08 Raja R Harinath - - Fix #74484. - * attribute.cs (Attribute.GetAttributeUsage): Resolve - AttributeUsageAttribute in the emitcontext of the attribute class, - not in the emitcontext of the attributable entity it was attached to. - * cs-parser.jay: Use 'current_class', not 'current_container', - when creating a GlobalAttribute. - -2005-04-08 Alp Toker - - * pending.cs: The fix to #58413 failed to compile methods implementing - interfaces with/without params modifiers and vice versa, even though - params modifiers aren't part of the signature. Make the modifier check - less strict as in csc. - -2005-04-07 Abin Thomas - Anoob V E - Harilal P R - - Fix #58413. - * pending.cs (TypeAndMethods.mods): New. Store the parameter - modifiers of pending methods. - (PendingImplementation.PendingImplementation): Initialize it. - Add Parameter.Modifier [][] mods and initialize it with ParameterData. - (PendingImplementation.InterFaceMethod): Repalce Type[] argument - with ParameterData. Add check for modifiers. - * class.cs (MethodData.Define): Update to changes. - -2005-04-07 Raja R Harinath - - * ecore.cs (Expression.IsAccessorAccessible): Clarify code somewhat. - -2005-04-07 Marek Safar - - * class.cs (PropertyMethod.Define): Check private accessor in abstract - property. - - * decl.cs (DeclSpace.ApplyAttributeBuilder): Don't allow RequiredAttribute - - * rootcontext.cs, - * typemanager.cs: Registered RequiredAttributeAttribute. - -2005-04-06 Marek Safar - - * class.cs (VerifyMembers): Doesn't need EmitContext argument. - Warning CS0169 is back at level 3. - (IMethodData.SetMemberIsUsed): New method. - - * decl.cs (IsUsed): New value; moved from FieldBase.Status - (SetMemberIsUsed, IsUsed): New methods, encapsulate IsUsed. - - * delegate.cs (ResolveMethodGroupExpr): Call SetMemberIsUsed. - - * ecore.cs (FieldExpr.ResolveMemberAccess): Call SetMemberIsUsed for - contants. - (PropertyExpr.ResolveAccessors): Call SetMemberIsUsed when delegate - is used. - - * expression.cs (OverloadResolve): Call SetMemberIsUsed. when method - is used. - - * rootcontext.cs (RootContext.EmitCode): Call VerifyMembers in extra run - to avoid the problems with nested types. - -2005-04-05 Abin Thomas - Anoob V.E - Harilal P.R - Raja R Harinath - - Fix #73820. - * delegate.cs (Define): Emit ParamArrayAttribute for 'params' - attribute. - * typemanager (GetConstructor): Make public. - -2005-04-05 John Luke - Raja R Harinath - - Fix #62232. - * typemanager.cs (IsUnmanagedType): Check non-public fields of a - struct too. Return false quicker in a few cases. - (VerifyUnManaged): Use it. - -2005-04-05 Raja R Harinath - - Fix #74041. - * statement.cs (Block.Resolve): Initialize 'unreachable' to false, - not 'unreachable_seen'. - -2005-04-04 Marek Safar - - * attribute.cs (Attribute.GetValue): Removed unused. - - * codegen.cs (CodeGen.TrimExt): Removed unused. - - * cs-parser.jay (output): Removed unused. - - * cs-tokenizer.cs (hex_digits): Removed unused. - - * enum.cs (MapToInternalType, GetEnumeratorName): Removed unused. - - * expression.cs (Indirection.LoadExprValue): Removed unused. - (ArrayCreation.ExpressionToArrayArgument): Removed unused. - - * iterators.cs (Iterator.param_types): Removed unused. - - * statement.cs (Goto.block): Removed unused. - (ToplevelBlock.did): Removed unused. - (Switch.ResolveConstantSwitch): Removed unused. - -2005-04-01 Ben Maurer - - * rootcontext.cs: Allow mcs to bootstrap with the compilation - resetting thingy. - -2005-04-01 Raja R Harinath - - Fix #74232 and cs0208-3.cs. - * expression.cs (ComposedCast.DoResolveAsTypeStep): Add CS0208 check. - * typemanager.cs (IsUnmanagedType): Don't allow 'object' as an - unmanaged type. Don't use FieldBuilders when 't' is a - TypeBuilder. Use ModFlags and MemberType fields. - * class.cs (MemberBase.member_type): Rename from MemberType. - (MemberBase.MemberType): New property. Determines member_type on - demand. - (MemberBase.DoDefine): Don't initialize MemberType here. - (FieldMember.Define): Likewise. - -2005-04-01 Marek Safar - - Fix #74241 - * class.cs (Event.Emit): Call Add/Remove emit even for interfaces. - Attributes are emitted there. - -2005-04-01 Raja R Harinath - - * cs-tokenizer.cs (consume_identifier): Treat 'partial' as a - keyword in 'partial enum' too. - * cs-parser.jay (enum_declaration): Add CS0267 check ('partial enum' - is not allowed). - Report from Kamil Skalski . - - Fix #74309. - * rootcontext.cs (ResolveTree): The 'root.Interfaces' list can - have partial containers too. - - * ecore.cs (SimpleName.SimpleNameResolve): Move 'invariant meaning - in block' checks to Block.CheckInvariantMeaningInBlock. - * statement.cs (Block.GetKnownVariableInfo): Make private. - (Block.IsVariableUsedInChildBlock): Remove. - (Block.IsVariableUsedInBlock): Likewise. - (Block.CheckInvariantMeaningInBlock): New. Show location of - conflicting declaration. - (Block.AddVariable): Make error messages less long-winded and more - specific. Show location of conflicting declaration. - * parameter.cs (Parameters.Location): New readonly property. - -2005-03-31 Raja R Harinath - - Clean up semantics of invoking ResolveMemberAccess. - * ecore.cs (SimpleName.DoSimpleNameResolve): If a MemberExpression - can have an instance, ensure that we pass in a non-TypeExpression - to ResolveMemberAccess. Tighten up IdenticalNameAndTypeName checks. - (MemberExpr.DoSimpleNameResolve): Remove type_is_inferred - argument. Update to changes and simplify. - (FieldExpr.Emitinstance): Remove CS0120 check. - (PropertyExpr.EmitInstance): Likewise. - * expression.cs (Argument.Resolve): Likewise. - (Invocation.DoResolve): Update to changes in semantics of - InstanceExpression. - -2005-03-31 Marek Safar - - Fix #74241 - * class.cs (AbstractPropertyEventMethod.EmitMethod): Enable emit method - customization. - - * decl.cs (MemberCache.AddMethods): Fix infinite loop. - -2005-03-31 Raja R Harinath - - Fix difference in behaviour with commandline invocation. - * driver.cs (Driver.Reset): New. - (CompilerCallableEntryPoint): Call it. - - * statement.cs (If.Resolve): Avoid spurious "uninitialized - variable" warnings if the boolean expression failed to resolve. - -2005-03-30 Sebastien Pouliot - - * attribute.cs: Fix the union of several permissions when some of them - are unrestricted (so the result isn't an unrestricted permission set). - Fix #74036. - -2005-03-30 Raja R Harinath - - * ecore.cs (MemberExpr): New class. Convert from interface - IMemberExpr. - (MemberExpr.ResolveMemberAccess): Refactor and move here from - MemberAccess.ResolveMemberAccess. Tighten up pre-conditions and - error checks. - (MethodGroupExpr, FieldExpr, PropertyExpr, EventExpr): Update. - (MethodGroupExpr.IsExplicitImpl): Remove. - (Expression.GetFieldFromEvent): Remove. - (SimpleName.MemberStaticCheck): Remove. - (SimpleName.DoSimpleNameResolve): Update to changes. - * expression.cs (MemberAccess.ResolveMemberAccess): Refactor. - (MemberAccess.IdenticalNameAndTypeName): Remove. - (MemberAccess.error176): Move to MemberExpr. - (MemberAccess.DoResolve): Update to changes. - (BaseAccess.DoResolve): Likewise. - -2005-03-30 Marek Safar - - C# 2.0 Conditional attribute class implementation - - * attribute.cs (AttributeTester.IsAttributeExcluded): New method. - Analyzes class whether it has attribute which has ConditionalAttribute - and its condition is not defined. - - * class.cs (Class.ApplyAttributeBuilder): Add IsAttributeExcluded check. - (Class.IsExcluded): New method. Search for at least one defined - condition in ConditionalAttribute of attribute class. - -2005-03-30 Raja R Harinath - - * ecore.cs (PropertyExpr): Derive from Expression, not - ExpressionStatement. - (PropertyExpr.EmitStatement): Remove. - -2005-03-29 Raja R Harinath - - Fix #74060. - * expression.cs (MemberAccess.ResolveMemberAccess): Allow the - internal field "value__" of an enum be private. The examples for - "value__" that I found on MSDN all used FieldAttributes.Private. - - * decl.cs (MemberCache.AddMethods): Use C# terminology in warning. - Don't mention IL method attribute names. - - Fix #47991. Remove a TODO. - * statement.cs (Block.Toplevel): Make into a field. - (Block.Parameters): Move into ToplevelBlock. - (Block.known_variables): Rename from child_variable_names. - (Block.Block): Remove variants that take Parameters. Initialize - 'Toplevel' with the immediately surrounding toplevel block. - (Block.AddKnownVariable): Rename from AddChildVariableName. Add a - LocalInfo parameter. - (Block.GetKnownVariableInfo): New. - (Block.IsVariableNameUsedInChildBlock): Update. - (Block.IsVariableNameUsedInBlock): New. Checks if a name is used in - the block, even though it may not be in scope. - (Block.AddVariable): Remove Parameters parameter. Use - Toplevel.Parameters instead. - (Block.AddConstant): Remove Parameters parameter. - (Block.GetParameterReference): Update to use Toplevel.Parameters. - (Block.IsParamaterReference): Likewise. - (Block.IsLocalParameter): Likewise. Simplify a lot. - (ToplevelBlock.Parameters): New. Moved from Block. - (ToplevelBlock.ToplevelBlock): Update to changes. Always - initialize Parameters to a non-null value. - * cs-parser.jay: Update to changes. - * ecore.cs (SimpleName.SimpleNameResolve): Emit cs0136 error for - simple names that mean different things in the same block. Use - Block.IsVariableNameUsedInBlock. - -2005-03-28 Raja R Harinath - - * typemanager.cs (TypeHandle.BaseType): Make into an IMemberContainer. - (TypeHandle.TypeHandle): Use LookupMemberCache rather than - GetTypeHandle. It is possible for a reflected type to derive from - a TypeBuilder (e.g., int[] derives from the TypeBuilder - System.Array during mscorlib compilation). - * decl.cs (MemberCache.MemberCache): If the base cache doesn't - contain a method_hash, don't create one either. Don't create a - deep copy of the base cache's method_hash. - (MemberCache.SetupCache): Rename back from DeepCopy. - (MemberCache.AddMethods): Rewrite, now that method_hash isn't - already initialized. If we see an override function, add its - underlying base virtual function to the member_hash too. - - * enum.cs (Enum.LookupEnumValue): Remove debugging code. - -2005-03-26 Raja R Harinath - - Fix #73038. - * assign.cs (Assign.DoResolve): When the RHS of an assignment - fails to resolve, ensure that the LHS is still resolved as an - lvalue. - -2005-03-25 Raja R Harinath - - * enum.cs (Enum.DefineType): Set ec.InEnumContext and - ec.ContainerType. - (Enum.current_ec): Remove. - (Enum.LookupEnumValue): Remove EmitContext argument. - Just uses the one created during DefineType. - (Enum.FindMembers): Update. - * expression.cs (MemberAccess.DoResolve): Update. - -2005-03-22 Marek Safar - - * assign.cs (Assign.DoResolve): Check for CS1717 when - source and target are same (uses Equals). - - * expression.cs (LocalVariableReference, ParameterReference, - This): Implemented Equals, GetHashCode. - - * statement.cs (Block.GetParameterReference): Removed useless - local variable. - -2005-03-22 Raja R Harinath - - Fix cs0128.cs - * statement.cs (Block.AddVariable): Ensure that we skip implicit - blocks before deciding whether the error is cs0136 or cs0128. - - * cs-parser.jay: Pass MemberName to RootContext.Tree.RecordDecl. - (using_alias_directive, using_namespace_directive): Pass - MemberName, not an expression to Namespace.UsingAlias and - Namespace.Using. - (MakeName): Use the MemberName of the namespace. - * namespace.cs (Namespace.MemberName): New. - (UsingEntry.UsingEntry): Take a MemberName, not an expression. - (AliasEntry.AliasEntry, Namespace.Using, Namespace.UsingAlias): - Likewise. - * decl.cs (MemberName.Name): Make readonly. - (MemberName.FromDotted): New "constructor". - (MemberName.Equals, MemberName.GetHashCode): Implement overrides. - (MemberCore.Name): Compute from MemberName on demand. - (MemberCore.SetMemberName): Provide a way to change the - MemberName. - (MemberCore.AddToContainer): Don't take a fullname parameter. - * class.cs (TypeContainer.AddToMemberContainer): Don't add the - fully qualified name of the container to the member name. - (TypeContainer.AddToTypeContainer): Use a fully qualified name - only if the type is a member of the root container. - (TypeContainer.AddMethod, TypeContainer.AddProperty): Use - MemberName.Left rather than searching for an embedded ".". - (PartialContainer.CreatePart): Update to changes in RootContext. - (MemberBase.ShortName): Turn into a property. Use - MemberCore.SetMemberName. - (MemberBase.ExplicitInterfaceName): Remove. - (MemberBase.UpdateMemberName): Remove. - (AbstractPropertyEventMethod.UpdateName): Use SetMemberName. - (PropertyBase.SetMemberName): New override. - * tree.cs (Tree.RecordDecl): Take a MemberName and use it as hash key. - (Tree.GetDecl): New. - (Tree.AllDecls): Rename from Decls. - * attribute.cs, enum.cs, report.cs: Update to changes. - * driver.cs (MainDriver): Use MemberName.FromDotted on - RootContext.MainClass. - -2005-03-21 Marek Safar - - * class.cs (FixedField.Define): Check for CS1664 and more sanity - checks. - - * expression.cs (ElementAccess.DoResolveLValue): Check for CS1708. - -2005-03-18 Marek Safar - - * modifiers.cs (Modifiers.PROPERTY_CUSTOM): New constant for - property accessor modifiers. - - * class.cs (FieldMember.ApplyAttributeBuilder): Don't allow apply - fixed buffer attribute (CS1716). - (PropertyMethod.HasCustomAccessModifier): When property accessor - has custom modifier. - - * ecore (PropertyExpr.DoResolve): Add CS0271 for custom accessor - modifiers. - (PropertyExpr.DoResolveLValue): Add CS0272. - -2005-03-17 Miguel de Icaza - - * convert.cs: When converting to a pointer, use the proper Conv.U - or Conv.I depending on the source data type. - - * cs-tokenizer.cs: Make the size for large decimal constants, - fixes #72957. - -2005-03-17 Martin Baulig - - * anonymous.cs (AnonymousMethod.method_modifiers): Change default - from `Modifiers.INTERNAL' to `Modifiers.PRIVATE'. Fixes #73260. - -2005-03-17 Martin Baulig - - * anonymous.cs (AnonymousMethod.EmitMethod): Changed return type - to bool so we can return an error condition. - (AnonymousDelegate.Emit): Check whether AnonymousMethod.EmitMethod() - returned an error. - -2005-03-16 Zoltan Varga - - * attribute.cs: Encode ThrowOnUnmappableChar and BestFitMapping - attributes. - -2005-03-16 Raja R Harinath - - Remove TypeManager.LookupType and TypeManager.LookupTypeDirect. - Refactor to avoid traversing the list of assemblies, and to avoid - string concatenation. - * typemanager.cs (guid_attr_type): Remove. - (negative_hits, pointers, references): Remove hashes. - (type_hash): New. - (GetConstructedType): New. Uses type_hash to handle constructed - types (arrays, references, pointers). - (GetReferenceType, GetPointerType): Use it. - (GetNestedType): New. Uses type_hash to handle nested types of - reflected types. - (LookupType, LookupTypeDirect): Remove. - (CoreLookupType): Inline parts of old LookupTypeDirect code. Use - 'types' hash and LookupTypeReflection directly. - (params_string, params_object): Use GetConstructedType. - * namespace.cs (Namespace.cached_types): New. Cache of reflected - top-level types. - (Namespace.Lookup): Use cached_types. - (NamespaceEntry.LookupNamespaceOrType): Inline the functionality - provided by old TypeManager.LookupType. - * rootcontext.cs (MakeFQN): Remove. - * decl.cs (DeclSpace.MakeFQN): Likewise. - (DeclSpace.LookupType): Use TypeManager.GetNestedType. - * expression.cs (ComposedCast.DoResolveAsTypeStep): Use - TypeManager.GetConstructedType. - * tree.cs (decl_ns_hash, LookupByNamespace): Remove. - -2005-03-15 Marek Safar - - * class.cs (MethodCore.CheckBase): Report CS1715 for properties and - indexers. - - * cs-parser.jay: Reports CS1527 for any namespace element. - - * delegate.cs (DelegateCreation.Error_NoMatchingMethodForDelegate): - Added CS0407. - - * expression.cs (ParameterReference.IsAssigned): Changed error to - CS0269. - (Error_WrongNumArguments): Moved CS0245 detection here. - - * statement.cs (Return.Resolve): Add CS1622 report. - -2005-03-11 Marek Safar - - * class.cs (StaticClass.DefineContainerMembers): Added CS0720. - -2005-03-11 Zoltan Varga - - * attribute.cs expression.cs: Get rid of some allocations. - -2004-03-11 Atsushi Enomoto - - * doc.cs : just eliminate the latest change. - -2004-03-10 Atsushi Enomoto - - * doc.cs : commented out the latest change. It breaks xml-030.cs - -2004-03-10 Atsushi Enomoto - - * doc.cs : When TypeBuilder did not create Type yet, GetEvents() will - fail. So invoke CreateType() in FindDocumentedType(). - -2004-03-10 Atsushi Enomoto - - * cs-tokenizer.cs : added IsKeyword(). - * doc.cs : Detect keyword incorrectly used as identifier. - Allow identifiers prefixed by @. - -2005-03-10 Marek Safar - - * attributes.cs (Attributes.Emit): Continue after CheckTargets. - It caused exception in namespace resolving (again!). - - * class.cs (Class.ctor): Removed exit. - (PropertyMethod.ctor): ditto. - - * codegen.cs (Codegen.Reset): Reset static data. - (Codegen.ResolveTopBlock): Forward error status from ResolveMeta. - - * cs-tokenizer.cs (Cleanup): Removed. - - * driver.cs (GetSystemDir): Rewrote to one line command. - It caused problem with unloaded dynamic modules. - (UnixParseOption): Removed Exit. - (CompilerCallableEntryPoint.InvokeCompiler): Make static. - (CompilerCallableEntryPoint.Reset): Reset suitable static data. - Now can be mcs used as library. - - * ecore.cs (Expression.ResolveBoolean): Use Location.Null for - empty location. - - * location.cs (Reset): Reset static data. - - * namespace.cs (Reset): Reset static data. - - * report.cs (Report.Reset): Reset static data. - - * rootcontext.cs (RootContext.Reset): Reset static data. - - * tree.cs (RootTypes.ctor): Use Location.Null - - * typemanager.cs (TypeManager.Reset): Reset static data. - (CoreLookupType): Removed Exit. - (TypeHandle.Reset): Reset static data. - -2005-03-10 Raja R Harinath - - Fix #73516. - * typemanager.cs (ComputeNamespaces): Import namespaces from - referenced modules too. - -2005-03-09 Raja R Harinath - - * class.cs (TypeContainer.AddToMemberContainer): Use "." rather - than '.'. - -2005-03-09 Raja R Harinath - - * decl.cs (DeclSpace.LookupType): Don't loop but recurse into - enclosing DeclSpace. This ensures that a name-lookup populates - more caches and there are fewer 'TypeExpression's. Carve out - nested type lookup into ... - (LookupNestedTypeInHierarchy): ... this. - -2005-03-09 Raja R Harinath - - Clean up a few partial-class semantics. - Fixes test-357.cs and cs1618-2.cs. - * cs-parser.jay (struct_declaration): Use 'current_class' as - parent of newly-created struct. Remove call to Register (). - Use 'pop_current_class' to complete handing the current struct. - (interface_declaration): Likewise. - (class_declaration): Likewise. - (enum_declaration): Use 'current_class' as parent of newly created - enum. - (delegate_declaration): Likewise. - (pop_current_class): New function. This is used to handle closing - up the 'current_class' and 'current_container', and pointing them - to the enclosing class/container. - (CSharpParser): Initialize 'current_class' too. - * decl.cs (MemberCore): Add check for invariant: a partial - container is not a parsed entity, and thus does not enclose any - parsed members. - (DeclSpace.TypeResolveEmitContext): Expose 'type_resolve_ec'. - (DeclSpace.BaseTypeExpr): Use it. - (DeclSpace.LookupType): Add check for invariant. - * class.cs (TypeContainer): Add check for invariant: a nested - class should have the same NamespaceEntry as its enclosing class. - (TypeContainer.EmitFieldInitializers): Make virtual. - (TypeContainer.DefineDefaultConstructor): Adhere to invariant in - MemberCore. - (TypeContainer.Register): Remove. - (TypeContainer.DefineType): Set the 'ec' of a PartialContainer to - null. Use TypeResolveEmitContext for resolving base types and - interfaces. Move initialization of Parts.TypeBuilder here from - ... - (TypeContainer.DefineNestedTypes): ... here. - (PartialContainer): Take a Namespace not a NamespaceEntry. - (PartialContainer.Create): Don't use Register. Call the - appropriate Add... function directly. - (ClassPart): Take both the PartialContainer and the enclosing - class as constructor arguments. - (ClassPart.EmitFieldInitializers): Override. - (ClassPart.PartFindNestedTypes): Remove. - (FieldBase.GetInitializerExpression): Resolve the initializer - expression in the emit context of the enclosing class. - * tree.cs (RootTypes): Remove Register (). - -2005-03-08 Marek Safar - - * cs-parser.jay: Removed CS0134. - - * driver.cs: Removed CS1901. - - * expression.cs (SizeOf.DoResolve): Don't report CS0233 - for predefined types. - -2005-03-07 Duncan Mak - - * codegen.cs (Save): Catch UnauthorizedAccessException as - well. Fixes bug #73454. - -2005-03-07 Marek Safar - - * cs-tokenizer.cs (xtoken): Add CS1035. - - * class.cs (MethodData.Define): Add CS0683. - (FieldMember.ctor): Add CS0681. - -2005-03-07 Raja R Harinath - - * ecore.cs (SimpleName.DoResolve): Rename from - SimpleName.DoResolveAllowStatic. - (SimpleName.DoSimpleNameResolve): Remove 'allow_static' argument. - Pass 'intermediate' flag to MemberStaticCheck. - (SimpleName.MemberStaticCheck): Skip "static check" only in case - of "intermediate" lookups via MemberAccess. - (SimpleName.IdenticalNameAndTypeName): New. Carved out of ... - * expression.cs (MemberAccess.IdenticalNameAndTypeName): ... this. - -2005-03-07 Raja R Harinath - - Fix #73394. - * ecore.cs (FieldExpr.EmitInstance): Catch cases of CS0120 that - slipped in because of variable names that are identical to a - builtin type's BCL equivalent ('string String;', 'int Int32;'). - (PropertyExpr.EmitInstance): Likewise. - -2005-03-04 Marek Safar - - * cs-tokenizer.cs (PreProcessPragma): Add warning 1633, 1635. - - * report.cs (warning_ignore_table): Made public. - -2005-03-04 Raja R Harinath - - Fix #73282. - * class.cs (MethodData.Emit): Pass 'container' to - container.GetObsoleteAttribute instead of 'container.Parent'. - -2005-03-03 Marek Safar - - * cs-parser.jay: Add 1534 error test. - - * iterators.cs (Yield.CheckContext): Add error 1629. - (Iterator.ctor): Save unsafe modifier. - (MoveNextMethod.DoEmit): Restore unsafe context. - - * namespace.cs (UsingAlias): Better error message. - -2005-03-03 Dan Winship - - * convert.cs (Error_CannotImplicitConversion): fix two bugs in - the warning message [#73219] - -2005-03-03 Raja R Harinath - - Fix compile with MCS 1.0.0.0. - * cs-tokenizer.cs (PreProcessPragma): Simplify w_disable and - w_restore to not depend on string constant folding. - -2005-03-03 Raja R Harinath - - * decl.cs (DeclSpace.LookupType): Remove 'silent' argument. Move - CS0246 check to users who passed 'silent = false'. - * ecore.cs (TypeLookupExpression.DoResolveAsTypeStep): Add CS0246 - check. - (SimpleName.SimpleNameResolve): Update. - * expression.cs (ComposedCast.DoResolveAsTypeStep): Add CS0246 check. - (MemberAccess.IdenticalNameAndTypeName): Update. - * doc.cs (FindDocumentedTypeNonArray): Update. - -2005-03-03 Raja R Harinath - - * codegen.cs (EmitContext): Remove ResolvingTypeTree. - * parameters.cs (ComputeAndDefineParameters): Remove. - * decl.cs (ResolveBaseTypeExpr): Don't set ResolvingTypeTree. - * delegate.cs (Define): Don't invoke ComputeAndDefineParameters. - Use GetParameterInfo. - -2005-03-02 Marek Safar - - * report.cs (StaticClass.DefineContainerMembers): Add warning 628. - -2005-03-02 Raja R Harinath - - Unify DeclSpace.LookupType and DeclSpace.FindType. - * decl.cs (DeclSpace.FindNestedType): New virtual function. This - is in charge of defining nested types on demand. - (DeclSpace.LookupType): Use it when the current_type is a - TypeBuilder. Use LookupTypeDirect for reflected types. - (DeclSpace.FindType): Remove. - (DeclSpace.LookupInterfaceOrClass): Likewise. - (DeclSpace.DefineTypeAndParents): Likewise. - * ecore.cs (SimpleName.ResolveAsTypeStep): Just call - DeclSpace.LookupType. - * doc.cs (FindDocumentedTypeNonArray): Use DeclSpace.LookupType. - * typemanager.cs (LookupType): Simplify. - (AddUserType): Remove type from negative_hits. - * namespace.cs (Namespace.Lookup): Use TypeManager.LookupTypeDirect. - * class.cs (TypeContainer.FindMembers): Move handling of nested - types ... - (TypeContainer.FindMembers_NestedTypes): ... here. - (TypeContainer.FindNestedType): Implement override. - (ClassPart.FindNestedType): Delegate to PartialContainer. - (ClassPart.PartFindNestedType): Looks up the nested types of the - part alone. - -2005-03-02 Martin Baulig - - * class.cs (TypeContainer.DoDefineMembers): We also need a default - static constructor in static classes. - -2005-03-01 Zoltan Varga - - * attribute.cs: Pass -1 to DefineLPArrayInternal if sizeConst or - sizeParamIndex is not specified. - -2005-03-01 Marek Safar - - Fix #73117 - * report.cs (WarningMessage.IsEnabled): Missing null check. - -2005-02-28 Marek Safar - - * attribute.cs (DefinePInvokeMethod): Fix, all data are stored - in the fields and not in the properties. - -2005-02-28 Zoltan Varga - - * attribute.cs (GetMarshal): Marshal SizeConst and SizeParamIndex - fields as well. - -2005-02-28 Marek Safar - - * attribute.cs: Small refactoring (improved robustness). - (ImplOptions, UnmanagedType, UsageAttribute): Removed members. - (ValidateGuid): Removed. - (Resolve): Removed referenced to above mentioned. - (GetAttributeUsage): Made private and changed to work without - class assistance. - (GetIndexerAttributeValue): Don't crash. - (GetConditionalAttributeValue): Ditto. - (GetClsCompliantAttributeValue): Ditto. - (ExtractSecurityPermissionSet): All attributes exceptions are - error 648. - (GetPropertyValue): New helper. - (GetMethodImplOptions): New method. - (DefinePInvokeMethod): Reuse common code. Implemented handling of - some missing properties. - - * class.cs (ClassOrStruct.ApplyAttributeBuilder): Updated. - (Method.ApplyAttributeBuilder): Updated. - - * decl.cs (DeclSpace.ApplyAttributeBuilder): Don't catch shared - exception. - -2005-02-28 Raja R Harinath - - Fix #73052. - * report.cs (Report.SymbolRelatedToPreviousError): Handle - non-simple types (array, pointer, reference). - -2005-02-28 Marek Safar - - * cs-parser.jay: Add errors 1617, 650, 1007, 531, 547, 548 - - * class.cs (MethodCore.IsDuplicateImplementation): Special error - for operators. - (Method.CheckBase): Catch wrong destructor here. - (MethodData.Define): Add errors 550, 668. - - * cs-tokenizer.cs (PreProcessPragma): Add warning 1634. - - * ecore.cs (PropertyExpr.DoResolveLValue): Fixed wrong error code. - - * pending.cs (VerifyPendingMethods): Add error 551. - - * typemanager.cs (CSharpName): Next error report helper. - -2005-02-25 Marek Safar - - * attribute.cs (Atttribute.Resolve): Add cache for parameter-less - attributes. Removed useless attribute double check. - It saves almost 2MBs for corlib. - -2005-02-25 Raja R Harinath - - Fix #72924. - * statement.cs (ExpressionStatement.Resolve): Make robust to being - called twice in case of error. - -2005-02-23 Chris Toshok - - Fix compiler portions of #72827. - * statement.cs (Block.Emit): call Begin/EndScope on the - EmitContext instead of the ILGenerator. - - * codegen.cs (EmitContext.BeginScope): new method, call - ILGenerator.BeginScope as well as the SymbolWriter's OpenScope (if - we have one.) - (EmitContext.BeginScope): same, but EndScope and CloseScope - - * symbolwriter.cs (SymbolWriter.OpenScope): get the current il - offset and call the superclass's OpenScope(int) with it. - (SymbolWriter.CloseScope): get the current il - offset and call superclass's CloseScope(int) with it. - -2005-02-23 Marek Safar - - * anonymous.cs (AnonymousMethod.Compatible): Fixed to report - CS1677 for out and ref as well. - - * class.cs (Method.Define): Add error CS1599 detection. - - * cs-parser.jay: Add CS1609, CS1670, CS1627 detection. - - * cs-tokenizer.cs (xtoken): Add error CS1646 detection. - - * delegate.cs (Delegate.Define): Add error CS1599 detection. - - * support.cs.cs (ModifierDesc): New helper method. - -2005-02-23 Raja R Harinath - Abin Thomas - Anoob V E - Harilal P R - - Fix #57851, #72718. - * class.cs (ConstructorBuilder.Resolve): Make sure that the second - MemberLookup (used for error reporting) actually returns a result. - Fix error report number (122, not 112). - -2005-02-22 Abin Thomas - Anoob V E - Harilal P R - - Fix #71134. - * pending.cs (PendingImplementation.GetAbstractMethods): - Find NonPublic members too. - -2005-02-22 Marek Safar - - * expression.cs.cs (ConditionalLogicalOperator.DoResolve): - Fixed error 217. - - * class.cs (MethodCore.CheckMethodAgainstBase): - Add error 239 report. - -2005-02-21 Raja R Harinath - - Fix #68955. - * expression.cs (Invocation.IsApplicable): Make public. - (Invocation.IsParamsMethodApplicable): Likewise. - * delegate.cs (Delegate.VerifyApplicability): Don't use - Invocation.VerifyArgumentCompat for parameter applicability - testing. Use Invocation.IsApplicable and - Invocation.IsParamsMethodApplicable. - -2005-02-21 Marek Safar - - * ecore.cs (PropertyExpr.DoResolve): Add error 214 report. - - * class.cs (Operator.Define): Add error 217 report. - -2005-02-21 Raja R Harinath - - * namespace.cs (UsingEntry.Resolve): Undo change below. - -2005-02-21 Raja R Harinath - - Fix #72756. - * ecore.cs (Expression.MemberLookupFailed): Add argument to - disable the error message when the extended MemberLookup also - fails. - (Expression.MemberLookupFinal): Update. - (SimpleName.DoSimpleNameResolve): Update. - * expression.cs (MemberAccess.ResolveNamespaceOrType): - Don't use MemberLookupFinal. - (New.DoResolve): Update. - (BaseAccess.CommonResolve): Update. - -2005-02-21 Raja R Harinath - - Fix #72732. - * attribute.cs (Attribute.ResolveType): If a 'resolve_error' had - occured previously, don't resolve again. - -2005-02-21 Marek Safar - - Fix #69949 - * attribute.cs (Attribute.GetAttributeUsage): Add EmitContext - argument. Call ResolveAttributeUsage for unresolved. - when types doesn't match ctor arguments. - - * class.cs (DoDefineMembers.TypeContainer): Removed safety check - for nested attribute classes. - (Class.attribute_usage): Removed. - (Class.ResolveAttributeUsage): Resolves AttributeUsageAttribute - for attribute class. - - * ecore.cs (IsAttribute): Removed. - - * namespace.cs (UsingEntry.Resolve): Don't destroy NamespaceEntry. - - * rootcontext.cs (RegisterAttribute): Removed, attributes are - now normal types. - (attribute_types): Removed. - (EmitCode): Global attributes are emited as the latest. - -2005-02-18 Marek Safar - - * class.cs (EmitFieldInitializers): Don't emit field initializer - for default values when optimilization is on. - - * constant.cs (Constant.IsDefaultValue): New property. - - * driver.cs: Add /optimize handling. - - * constant.cs, - * ecore.cs, - * literal.cs: Implement new IsDefaultValue property. - - * rootcontext.cs (Optimize): New field, holds /optimize option. - -2005-02-18 Raja R Harinath - - Fix crasher in re-opened #72347. - * namespace.cs (Namespace.Lookup): Return null if - DeclSpace.DefineType returns null. - - Fix #72678. - * expression.cs (Argument.Resolve): Handle a case of CS0120 here. - -2005-02-18 Raja R Harinath - - Fix remainder of #63202. Change semantics of DoResolveLValue: it - now returns null if it cannot resolve to an lvalue. - * ecore.cs (Expression.DoResolveLValue): Return 'null' by default. - (Expression.ResolveLValue): Emit CS0131 error if DoResolveLValue - returned null. Remove check for SimpleName. - (EventExpr.DoResolveLValue): New. - * iterators.cs (Iterator.FieldExpression.DoResolveLValue): New. - * expression.cs (Argument.Error_LValueRequired): New. Move CS1510 - error from ... - (Argument.Resolve): ... here. Use it. Use DoResolveLValue to - avoid CS0131 error. - (Unary.ResolveOperator): Move CS0211 check ... - (Unary.DoResolve): ... here. Use DoResolveLValue to avoid - CS0131 error. - (Unary.DoResolveLValue): Simplify. - (AddressOf.DoResolveLValue): New. - (ArrayAccess.DoResolveLValue): New. - -2005-02-16 Marek Safar - - * attribute.cs (Attribute.Resolve): Add arguments casting for - when types doesn't match ctor arguments. - -2005-02-16 Raja R Harinath - - Fix parts of #63202. - * expression.cs (UnaryMutator.ResolveOperator): Remove redundant - lookup of operator in base type. Ensure that all checks happen - when the operator resolves to an "op_..." method. - -2005-02-15 Raja R Harinath - - Fix #71992. - * namespace.cs (NamespaceEntry.LookupNamespaceOrType): Add - 'ignore_cs0104' parameter. Pass it to ... - (NamespaceEntry.Lookup): ... this. - * decl.cs (DeclSpace.LookupType): Add 'ignore_cs0104' parameter. - * ecore.cs (SimpleName.ResolveAsTypeStep): Update. - (TypeLookupExpression.DoResolveAsTypeStep): Update. - * expression.cs (MemberAccess.IdenticalNameAndTypeName): - Update. Request that cs0104 errors be ignored. - (ComposedCast.ResolveAsTypeStep): Update. - -2005-02-14 Raja R Harinath - - Fix #59209. - * expression.cs (Invocation.BetterFunction): Remove support for - comparing virtual functions and their overrides. - (Invocation.IsOverride): New. - (Invocation.OverloadResolve): Don't consider 'override' functions - during candidate selection. Store them in a lookaside list. - If the selected method is a 'virtual' function, use the list to - find any overrides that are closer to the LHS type. - -2005-02-14 Marek Safar - - * expression.cs (New.DoResolve): Add complex core type reduction. - (New.Constantify): Converts complex core type syntax like 'new int ()' - to simple constant. - -2005-02-14 Raja R Harinath - - * decl.cs (EntryType.EntryType): New constructor to create an - updated copy of a cache entry. - (MemberCache.AddMethods): Use it. - (MemberCache.ClearDeclaredOnly): Remove. - (MemberCache.MemberCache): Update. - -2005-02-11 Miguel de Icaza - - * codegen.cs (EmitContext): Introduce the `MethodIsStatic' - variable. This one is represents the actual low-level declaration - of the method, as opposed to the semantic level `IsStatic'. - - An anonymous method which is hosted into a static method might be - actually an instance method. IsStatic would reflect the - container, while MethodIsStatic represents the actual code - generated. - - * expression.cs (ParameterReference): Use the new MethodIsStatic - instead of IsStatic. - - * anonymous.cs (AnonymousMethod.Compatible): Pass the - Modifiers.STATIC to the Anonymous' Method EmitContext if static is - set on the current EmitContext. - - * expression.cs (Cast): Overload DoResolveLValue so we can pass - resolve our casted expression as an LValue. This triggers the - proper LValue processing that is later required by Assign. - - This fixes 72347. - - * cs-tokenizer.cs (pp_and): recurse on pp_and, fixes #61903. - -2005-02-11 Marek Safar - - C# 2.0 Fixed buffer implementation - - * anonymous.cs: Update after RegisterHelperClass renaming. - - * attribute.cs (AttributeTester.fixed_buffer_cache): - Cache of external fixed buffers. - (AttributeTester.GetFixedBuffer): Returns IFixedBuffer - implementation if field is fixed buffer else null. - - * class.cs - (TypeContainer.AddField): Accept FieldMember instead of Field. - (FieldBase.IsFieldClsCompliant): Extracted code from - VerifyClsCompliance descendant customization. - (FixedField): New class handles fixed buffer fields. - (FixedFieldExternal): Keeps information about imported fixed - buffer. - (IFixedField): Make access to internal or external fixed buffer - same. - - * cs-parser.jay: Add fixed buffer parsing. - - * ecore.cs (FieldExpr.Emit): Add special emit case for fixed - buffer. - - * expression.cs (Indirection): Extended implementation to accept - fixed buffer field. - (PointerArithmetic.Emit): Get element from fixed buffer as well. - (ElementAccess.MakePointerAccess): Get type as parameter. - (DoResolve): Add fixed buffer field expression conversion. - (DoResolveLValue): Ditto. - (FixedBufferPtr): New class. Moved most of original ArrayPtr. - (ArrayPtr): Derives from FixedBufferPtr. - (ArrayPtr.Emit): Add extra emit for array elements. - - * flowanalysis.cs.cs (StructInfo): Use FieldMember. - - * rootcontext.cs (CloseTypes): Emit CompilerGenerated attribute - for compiler generated types. - (RegisterCompilerGeneratedType): Renamed from RegisterHelperClass. - - * statement.cs (Fixed): Refactored to be easier add fixed buffer - and consume less memory. - (Fixed.Resolve): Add fixed buffer case. - - * typemanager.cs (compiler_generated_attr_ctor, - fixed_buffer_attr_ctor): Add new 2.0 compiler attributes. - (HasElementType): Add our own implementation to work on every - runtime. - -2005-02-11 Miguel de Icaza - - * anonymous.cs (CaptureContext): Track whether `this' has been - referenced. - - * expression.cs (This.ResolveBase): Call CaptureThis. Before we - only captured `this' if it was implicitly done (instance - methods/variables were used). - - * codegen.cs (EmitContext.CaptureThis): New method to flag that - `this' must be captured. - -2005-01-30 Miguel de Icaza - - * anonymous.cs (CreateMethodHost): If there Scope.ScopeTypeBuilder - is null it means that there has been no need to capture anything, - so we just create a sibling. - - Renamed `EmitHelperClasses' to `EmitAnonymousHelperClasses' - - Just a partial fix. The other half is fairly elusive. - -2005-02-10 Raja R Harinath - - Fix #52586, cs0121-4.cs. - * decl.cs (MemberCache.DeepCopy): Rename from SetupCache. Take - and return a hashtable. - (MemberCache.ClearDeclaredOnly): New. - (MemberCache.MemberCache): Update to change. Make a deep copy of - the method_hash of a base type too. - (MemberCache.AddMethods): Adapt to having a deep copy of the base - type methods. Overwrite entries with the same MethodHandle so - that the ReflectedType is correct. The process leaves in base - virtual functions and their overrides as distinct entries. - (CacheEntry): Now a class instead of a struct. It shouldn't alter - matters since it was boxed in a ArrayList before. - (CacheEntry.Member, CacheEntry.EntryType): Remove 'readonly' - modifier. - * expression.cs (Invocation.BetterFunction): Simplify. Handle the - case of a virtual function and its override (choose the overload - as better). - (Invocation.OverloadResolve): Avoid 'override' members during - 'applicable_type' calculation. - -2005-02-09 Raja R Harinath - - Combine two near-redundant caches. - * typemanager.cs (method_params): Rename from method_internal_params. - (TypeManager.GetParameterData): New. Replace - Invocation.GetParameterData. - (TypeManager.LookupParametersByBuilder): Remove. - * expression.cs (Invocation.method_parameter_cache): Remove. - (Invocation.GetParameterData): Remove. - Update to changes. - * anonymous.cs, attribute.cs, convert.cs, delegate.cs: - Update to changes. - -2005-02-08 Raja R Harinath - - Fix #72015. - * delegate.cs (Delegate.DefineType): When bootstrapping corlib, if - TypeManager.multicast_delegate_type is null, resolve it by looking - up "System.MulticastDelegate". - * rootcontext.cs (RootContext.ResolveCore): Simplify. - -2005-02-07 Abin Thomas (NOSIP) - Anoob V.E (NOSIP) - Harilal P.R (NOSIP) - - Fix cs0164.cs. - * statement.cs (LabeledStatement.Resolve): Don't set 'referenced'. - (LabeledStatement.AddReference): New. Set 'referenced'. - (Goto.Resolve): Use it. - -2005-02-05 John Luke - - * driver.cs: remove duplicate -doc line in Usage () - -2005-02-04 Raja R Harinath - - * location.cs (Location.AddFile): Fix CS2002 error report. - -2005-02-02 Martin Baulig - - * delegate.cs (Delegate.DefineType): Report an internal error if - TypeManager.multicast_delegate_type is null. See bug #72015 for - details. - -2005-02-02 Raja R Harinath - - Fix a crasher in a variant of #31984. - * const.cs (Constant.CheckBase): New override that defers the - new-or-override check in case the base type hasn't been populated - yet. - (Constant.Define): Ensure the new-or-override check is performed. - -2005-02-01 Duncan Mak - - * const.cs (LookupConstantValue): Check that `ce' is not null - before calling GetValue (). - -2005-02-01 Raja R Harinath - - Fix test-334.cs (#69519). - * cs-parser.jay (using_alias_directive): Pass in an expression to - NamespaceEntry.UsingAlias. - (using_namespace_directive): Pass in an expression to - NamespaceEntry.Using. - (namespace_name): Don't flatten to a string. - * namespace.cs (NamespaceEntry.AliasEntry): Store an expression. - (NamespaceEntry.AliasEntry.Resolve): Lookup using - ResolveAsTypeStep. - (NamespaceEntry.UsingEntry): Likewise. - (NamespaceEntry.Using,NamespaceEntry.UsingAlias): Update to - changes. - (NamespaceEntry.LookupForUsing): Remove. - (NamespaceEntry.LookupNamespaceOrType): Add support for dotted - names. - (NamespaceEntry.Lookup): Remove support for dotted names. - -2005-02-01 Raja R Harinath - - * namespace.cs (NamespaceEntry.NamespaceEntry): Simplify, and - split into two. - (NamespaceEntry.ImplicitParent): Compute on demand. - (NamespaceEntry.Doppelganger): New implicit namespace-entry that - parallels the current. - (NamespaceEntry.LookupForUsing): Use it. - (NamespaceEntry.Lookup): If the current namespace-entry is - implicit, don't search aliases and using tables. - -2005-02-01 Raja R Harinath - - Fix #31984. - * class.cs (TypeContainer.DoDefineMembers): Don't initialize - BaseCache here. - (TypeContainer.BaseCache): Compute on demand. - (TypeContainer.FindMembers): Define constants and types if they're - not already created. - (FieldMember.Define): Move resetting of ec.InUnsafe before error - check. - * const.cs (Constant.Define): Make idempotent. - -2005-01-29 Miguel de Icaza - - * pending.cs: Produce better code (no nops produced by using Ldarg - + value). - - * pending.cs (PendingImplementation.DefineProxy): It was not `arg - i - 1' it should be arg + 1. - - Fixes bug #71819. - -2005-01-28 Raja R Harinath - - * attribute.cs (Attribute.CheckAttributeType): Make private - non-virtual. - (Attribute.ResolveType): Make virtual. - (GlobalAttribute.ResolveType,GlobalAttribute.Resolve): Simplify - handling of RootContext.Tree.Types. - -2005-01-27 Raja R Harinath - - Update attribute-handling to use the SimpleName/MemberAccess - mechanisms. - * cs-parser.jay (attribute): Pass in an expression to the - constructors of Attribute and GlobalAttribute. - * attribute.cs (Attribute): Take an expression for the name. - (Attribute.ResolvePossibleAttributeTypes): New. Resolves the - passed in attribute name expression. - (Attribute.CheckAttributeType): Use it. - * ecore.cs (FullNamedExpression.ResolveAsTypeStep): New. - * expression.cs (MemberAccess.ResolveAsTypeStep): Move body to ... - (MemberAccess.ResolveNamespaceOrType): ... here. Add 'silent' - argument to prevent error messages if the lookup fails. - -2005-01-27 Marek Safar - - * expression.cs (Indirection): Implemented IVariable interface - to support indirection in AddressOf operator. - (PointerArithmetic.Emit): Add optimalization for case where - result can be precomputed. - -2005-01-26 Martin Baulig - - * class.cs (TypeContainer.AttributeTargets): Return the correct - AttributeTargets depending on our `Kind' instead of throwing an - exception; fixes #71632. - -2005-01-26 Marek Safar - - Fix #71257 - * expression.cs (MemberAccess.ResolveMemberAccess): Add CS0176 test for - constant members. - -2005-01-25 Raja R Harinath - - Fix #71602. - * expression.cs (MemberAccess.DoResolve): Don't complain with - cs0572 when the LHS of a member access has identical name and type - name. - -2005-01-25 Marek Safar - - Fix #71651, #71675 - * attribute.cs (ExtractSecurityPermissionSet): Catch exceptions from - CreatePermission. - Create custom PermissionSet only for PermissionSetAttribute. - -2005-01-24 Marek Safar - - Fix #71649 - * class.cs (StaticClass.DefineContainerMembers): Enable enums and - delegates in static class. - -2005-01-24 Martin Baulig - - * flowanalysis.cs (FlowBranching.UsageVector.MergeChild): If we're - merging an implicit block, just use its reachability. - - * statement.cs (Block.Resolve): Make the unreachable code check - work wrt. implicit blocks; see test-337 from #63842. - -2005-01-21 Alp Toker - - * cs-parser.jay: destructor_declaration's container is PartialContainer - not Class when partial types are used, so use Kind prop instead of - 'is'. - -2005-01-22 Miguel de Icaza - - * cs-parser.jay: Improve error reporting when an interface - declares new types. - -2005-01-20 Dick Porter - - * support.cs: SeekableStreamReader fix from Sandor Dobos - (dobos_s@ibcnet.hu) to cope with Position setting when multibyte - chars are read. Fixes bug 70369. - -2005-01-20 Raja R Harinath - - * cs-parser.jay (catch_clause): Simplify current_block handling - somewhat. - -2005-01-17 Miguel de Icaza - - * convert.cs (ImplicitStandardConversionExists): Synchronize the - code with ImplicitStandardConversion to handle the implicit - conversion of method groups into valid delegate invocations. - - The problem is that in parameter handling we were using this code - path. Fixes bug #64698 - -2005-01-19 Raja R Harinath - - * cs-parser.jay: Fix several infelicities. - - Avoid assigning to the parser value stack. Code like - '$3 = null' is unclean. Synthesize a value for the code block - instead. - - Avoid using oob_stack for storing location information. Use ... - (_mark_): ... this. New (empty) rule. Saves the current location - in $$. - (foreach_statement): Avoid using oob_stack for current_block - handling. Use technique used in for_statement and - using_statement. Synthesize a value for the code block to store - additional intermediate information. - -2005-01-13 Miguel de Icaza - - * ecore.cs (IsAccessorAccessible): Accessibility to private fields - of a different type is only allowed to private fields of a - containing type, not on fields of a base class. - - See test-174.cs and error cs0122-9.cs - -2005-01-13 Raja R Harinath - - Fix test-335.cs (bug #58126). - * cs-parser.jay (argument): Split out non-expression parts of the - rule into 'non_simple_argument'. - (invocation_expression): Support parenthesized invocations with - multiple arguments, and with single non-simple arguments. - -2005-01-13 Raja R Harinath - - * cs-tokenizer.cs (xtoken): Reset 'comments_seen' in a couple more - places. - -2005-01-12 Raja R Harinath - - Fix cs0038-1.cs, cs1640-6.cs. - * ecore.cs (Expression.Resolve): Remove special-case for - SimpleName in error-handling. - (Expression.almostMatchedMembers): Relax access permission to - protected. - (Expression.MemberLookupFailed): Handle duplicates in - almostMatchedMembers list. - (SimpleName.DoSimpleNameResolve): Catch CS0038 errors earlier. - * expression.cs (New.DoResolve): Report CS1540 for more cases. - * typemanager.cs (GetFullNameSignature): Use the MethodBase - overload if the passed in MemberInfo is a MethodBase. - -2005-01-12 Marek Safar - - Fix #70749 - * attribute.cs (ExtractSecurityPermissionSet): Don't report error - for non-CAS & merge permission sets properly. - -2005-01-11 Raja R Harinath - - Improve standard-compliance of simple name and member access - resolution. Fixes bugs #52697, #57200, #67520, #69519. - * ecore.cs (FullNamedExpression): New abstract base class - for Namespaces and TypeExpressions. - (ResolveFlags.SimpleName): Remove. - (SimpleName): Remove support for dotted names. - (SimpleName.ResolveAsTypeStep): Simplify. Now just a wrapper to - DeclSpace.FindType and DeclSpace.LookupType. - (SimpleName.DoSimpleNameResolve): Remove support for dotted names. - (Expression.ExprClassName): Make member function. - * expression.cs (MemberAccess.ResolveAsTypeStep): Support LHS being - a namespace. Remove creation of dotted "SimpleName"s. - (MemberAccess.DoResolve): Likewise. - * decl.cs (DeclSpace.Cache): Make private. - (DeclSpace.LookupInterfaceOrClass): Return a FullNamedExpression. - (DeclSpace.FindType): Update. - (DeclSpace.LookupType): Move here from RootContext. Return a - FullNamedExpression. - * namespace.cs (Namespace): Derive from FullNamedExpression - so that it can be part of expression resolution. - (Namespace.Lookup): Return an FullNamedExpression. - (NamespaceEntry.LookupAlias): Lookup aliases only in current - namespace. - * rootcontext.cs (NamespaceLookup): Remove. - (LookupType): Move to DeclSpace. - * attribute.cs (CheckAttributeType): Update. - * doc.cs (FindDocumentedType): Remove allowAlias argument. - (FindDocumentedTypeNonArray): Likewise. - -2005-01-11 Raja R Harinath - - Fix cs0509.cs, cs1632.cs. - * class.cs (TypeContainer.GetNormalBases): Don't assume !IsClass - is the same as IsInterface. - (TypeContainer.GetClassBases): Likewise. - * statement.cs (LabeledStatement.ig): New field. - (LabeledStatement.LabelTarget): Save ILGenerator which created the - label. - (LabeledStatement.DoEmit): Check that the label was created with - the same ILGenerator. - -2005-01-10 Marek Safar - - Fix #71058 - * attribute.cs (GetMethodObsoleteAttribute): Need to transform - accessors to its properties. - - * ecore.cs (PropertyExpr): Add AccessorTable to help track back - from accessors to property. - -2005-01-10 Marek Safar - - Fix #70722 - * class.cs (MethodCore.CheckBase): Test base method obsoleteness - only for overrides. - -2005-01-08 Miguel de Icaza - - * attribute.cs: Check for null and empty strings. - - I have lost another battle to Paolo. - -2005-01-07 Marek Safar - - Fix #70942 - * class.cs (PropertyMethod): Set Parent field in ctors. - (SetMethod.InternalParameters): Add unsafe switch hack. - Override MarkForDuplicationCheck where it is appropriate. - - * decl.cs (MemberCore.MarkForDuplicationCheck): New method. - It says whether container allows members with the same name. - Base default is no. - (DeclSpace.AddToContainer): Use MarkForDuplicationCheck. - Removed is_method parameter. - -2005-01-06 Duncan Mak - - * cs-tokenizer.cs (xtoken): Redo the work for signaling CS1040 - because the previous change led to incorrect reporting of CS1032 - ("Cannot define/undefine preprocessor symbols after first token in - file"). Instead of using `tokens_seen' as the only flag that - triggers CS1040, introduce `comments_seen'. This new flag is used - to signify having seen comments on the current line, so it is - unset after a newline. - -2005-01-06 Atsushi Enomoto - - * doc.cs : When searching for a type, find nested type too. - This fixes bug #71040. - -2005-01-06 Atsushi Enomoto - - * doc.cs : - - Warn missing member comment on those classes which also does not - have doc comments. Fixed bug #71041. - - Don't warn missing doc comment on default constructor. - Fixed bug #71042. - -2005-01-06 Duncan Mak - - * cs-tokenizer.cs (xtoken): After handling traditional C-style - comments, set `tokens_seen' to true. This allows us to detect - misplaced preprocessor directives (i.e. not at the beginning of - the a line, nor after whitespaces). In that case, report error - CS1040. This fixes bug #56460. - - * cs-parser.jay (interface_member_declaration): Add checks for - IsExplicitImpl, and report CS0541 error if an interface member is - defined as an explicit interface declaration. - -2005-01-06 Marek Safar - - Fix #70817 - * class.cs (PropertyMethod): Set Parent field in ctors. - (SetMethod.InternalParameters): Add unsafe switch hack. - - * decl.cs (MemberCore.Parent): Cannot be readonly. - -2005-01-06 Raja R Harinath - - * decl.cs (DeclSpace.ResolveType): Remove. - (DeclSpace.ResolveBaseTypeExpr): Rename from ResolveTypeExpr. - Merge in code from ... - (DeclSpace.GetTypeResolvingEmitContext): ... here. Remove. - * class.cs, enum.cs: Update to changes. - -2005-01-06 Miguel de Icaza - - * anonymous.cs: Ensure that we init the scope of our parent if it - has not been initialized yet. - -2004-12-30 Duncan Mak - - * typemanager.cs (TypeManager.CheckStructCycles): Don't crash here - if field.FieldBuilder is null. Fixes #70758. - - * convert.cs: Fixed some typos and updated some of the comments. - (ImplicitStandardConversionExists): - (TryImplicitIntConversion): If `target_type' is an interface and - the type of `ic' implements this interface, return true or a new - BoxedCast instead of null. This fixes #70468. - -2004-12-29 Duncan Mak - - * expression.cs (Argument.Emit): Check that Expr is - IMemoryLocation before casting to it, and report CS1510 otherwise. - - This fixes #70402. - -2004-12-21 Ben Maurer - - * statement.cs (Block.ThisVariable): remove the recursion here, to - make the --profile more sane. - -2004-12-17 Carlos Cortez - - * driver.cs: Patch to handle a xsp bug that prevents to reference an .exe - assembly, by JB Evain. - -2004-12-17 Raja R Harinath - - * class.cs, decl.cs, ecore.cs, iterators.cs, pending.cs, - rootcontext.cs, typemanager.cs: Make nomenclature consistent. - "parent" refers to enclosing type/class. "base" refers to superclass. - -2004-12-17 Raja R Harinath - - * codegen.cs (CommonAssemblyModulClass.GetClsCompliantAttribute): - Ensure that we only have GlobalAttributes. - * attribute.cs (Attribute.Emit): Make non-virtual. - (GlobalAttribute.Emit): Remove. - (Attribute.Resolve): Make virtual. - (GlobalAttribute.Resolve): New. Set Rootcontext.Tree.Types.NamespaceEntry. - (Attribute.GetConditionalAttributeValue): Take an EmitContext as - the argument. Don't create one. - (Attribute.GetObsoleteAttribute): Likewise. - (Attribute.GetClsCompliantAttributeValue): Likewise. - * class.cs, decl.cs: Update to changes. - -2004-12-17 Marek Safar - - * delegate.cs (NewDelegate.DoResolve): Add error 149 report. - - * ecore.cs (Expression.MemberLookupFailed): Fixed error 143. - - * statement.cs (Foreach.Resolve): Add error 186 report. - -2004-12-16 Marek Safar - - * expression.cs (Conditional.DoResolve): Add warning 429. - - * statement.cs (If.Resolve): Add warning 665. - -2004-12-16 Raja R Harinath - - New invariant: RootContext.Tree.Types.NamespaceEntry == null - except when in the parser, and in GlobalAttribute. - * driver.cs (MainDriver): Reset RootContext.Tree.Types.NamespaceEntry. - * attribute.cs (GlobalAttribute.CheckAttributeType): Reset - RootContext.Tree.Types.NamespaceEntry once work is done. - (GlobalAttribute.Emit): New. Wrapper for Attribute.Emit, but sets - and resets RootContext.Tree.Types.NamespaceEntry. - -2004-12-15 Marek Safar - - * cs-parser.jay: Don't create a block for every variable. - -2004-12-14 Miguel de Icaza - - * location.cs: Provide extra information. - - * statement.cs: The instance is not `ldarg_0.THIS' when accessing - variables from the captured environment, it is the ldarg_0. - -2004-12-14 Marek Safar - - * cs-parser.jay: Changed warning level for 642 to 4 until Miguel - find a conclusion. - - * class.cs: Changed warning level for 169 to avoid developer - displeasure from warning flooding. It will be changed back when they - fix most of current BCL warnings. - - * RootContext.cs: Pushed default WarningLevel to 3. - - * statement.cs: Removed unused variable. - -2004-12-14 Marek Safar - - * class.cs (TypeContainer.GetClassBases): Add error 1521 report. - (TypeContainer.MethodModifiersValid): Refactored to use MemberCore. - Add error 502 report. - (StaticClass.DefineType): Add error 441 report. - (Class.AllowedModifiersProp): New virtual property as temporary - extension to AllowedModifiers. - (Class.DefineType): Add error 418 report. Moved ModFlags check here - to share implementation with StaticClass and don't call virtual - methods from ctor. - - * driver.cs (MainDriver): Add error 1558 test. - - * parameter.cs (Parameter.ApplyAttributeBuilder): Add error 662 - report. Moved error 36 test here. - - * statement.cs (Throw.Resolve): Add error 724 report. - - * typemanager.cs: Add out_attribute_type core type. - -2004-12-13 Marek Safar - - * class.cs (TypeContainer.VerifyClsCompliance): Add error - 3018 report. - (PropertyBase.VerifyClsCompliance): Add errror 3025 report. - - * codegen.cs (ModuleClass.ApplyAttributeBuilder): Add error - 3017 report. - - * decl.cs (MemberCore.VerifyClsCompliance): Add warning 3021. - - * parameter.cs (ReturnParameter.ApplyAttributeBuilder): - Add error 3023 report. - (Parameter.ApplyAttributeBuilder): Add error 3022 report. - - * tree.cs (RootTypes.IsClsCompliaceRequired): Add fake - implementation. - -2004-12-12 John Luke - - * driver.cs (AddArgs): take -- into account when - adding arguments, fixes bug 65710 - -2004-12-12 Martin Baulig - - * expression.cs (Unary.TryReduceNegative): Added support for - SByteConstant and ByteConstant. - (Unary.Reduce): Check error values from TryReduceNegative(). - -2004-12-10 Marek Safar - - * attributes.cs (Attribute.Resolve): Avoid multiple error report - and report exception as error 182. - -2004-12-10 Raja R Harinath - - * driver.cs (Main): Fix message when there are warnings. - -2004-12-09 Miguel de Icaza - - * delegate.cs: Fixed my fix from yesterday, sorry about that. - -2004-12-09 Marek Safar - - * anonymous.cs, class.cs, convert.cs, doc.cs, support.cs: - Reduced number of warnings. - - * class.cs (TypeContainer.VerifyClsCompliance): One if is enough. - -2004-12-08 Miguel de Icaza - - * driver.cs: Removed message. - - * delegate.cs: Fix bug introduced in 1.1.x: 70219. - -2004-12-08 - - * cs-tokenizer.cs: Add workaround for NET 2.0 beta 1 csc bug. - -2004-12-08 Martin Baulig - - * class.cs (TypeContainer.VerifyClsCompliance): Report a CS3003 - instead of a CS3002 for properties and indexer. - -2004-12-08 Martin Baulig - - * decl.cs (MemberName.ToString): Make this work again. - -2004-12-08 Marek Safar - - * attribute.cs (Resolve): Add error 591 detection. - - * class.cs (FieldMember.Define): Add error 1547 detection. - (Indexer.Define): Add error 620 detection. - (Operator.Define): Add error 590 detection. - - * ecore.cs: Missing argument for error 79. - - * expression.cs (ComposedCast.DoResolveAsTypeStep): Add error 611 - detection. - -2004-12-07 Marek Safar - - Fix #70106 - * assign.cs.cs (Assign.DoResolve): Reports error 1648 for value types - only. - -2004-12-07 Atsushi Enomoto - - * cs-parser.jay : handle doc comments on implicit/explicit operators. - Some operator comments were suppressed. - * doc.cs : Implicit/explicit operator name in doc comments are like - "op_Explicit(type)~returnType", so added suffix handling. - -2004-12-07 Martin Baulig - - * decl.cs - (MemberCore.GetObsoleteAttribute): Don't create a new EmitContext. - (MemberCore.GetClsCompliantAttributeValue): Likewise. - (DeclSpace.ec): New protected field; store the EmitContext here. - (DeclSpace.EmitContext): New public property; moved here from - `TypeContainer'. - (DeclSpace.GetClsCompliantAttributeValue): Don't create a new - EmitContext. - - * enum.cs (Enum.Define): Store the EmitContext in the `ec' field. - (Enum.Emit): Don't create a new EmitContext. - - * delegate.cs (Delegate.DefineType): Always create the - EmitContext. - - * iterators.cs (Iterators.DefineIterator): Create a new - EmitContext and store it in `ec'. - -2004-08-24 Martin Baulig - - * typemanager.cs - (TypeManager.IsSubclassOf): Renamed to IsFamilyAccessible; use - this for accessibility checks. - (TypeManager.IsSubclassOrNestedChildOf): Renamed to - IsNestedFamilyAccessible. - (TypeManager.IsSubclassOf): New method, do what the name actually - says. - -2004-12-06 Raja R Harinath - - Fix crash on cs0657-17.cs. - * codegen.cs (CommonAssemblyModulClass.GetClsCompliantAttribute): - Use RootContext.Tree.Types, not 'new RootTypes ()'. - * attribute.cs (GlobalAttribute.CheckAttributeType): Narrow down - the case where the NamespaceEntry gets overwritten. - -2004-12-06 Marek Safar - - Fixed #69195, #56821 - * ecore.cs (ResolveBoolean): Tiny refactoring. - - * expression.cs (Binary.DoResolve): Add warning 429 and skipping - of right expression resolving when left is false constant and - operator is LogicalAnd OR true constant and operator is LogicalOr. - - * statement.cs (ResolveUnreachable): Always reports warning. - -2004-12-05 Miguel de Icaza - - * class.cs: Distinguish between 1721 and 1722 (just a little help - for the programmer). - -2004-12-03 Miguel de Icaza - - * delegate.cs: Only allow this on new versions of the language. - -2004-12-02 Duncan Mak - - * ecore.cs (PropertyExpr.IsAccessorAccessible): Moved to - Expression class. - (Expression.IsAccessorAccessible): Moved from the PropertyExpr to - here as a static method. Take an additional bool out parameter - `must_do_cs1540_check' for signaling to InstanceResolve. - (PropertyExpr.InstanceResolve): Removed the `must_do_cs1540_check' - member field from PropertyExpr class and made it an argument of - the method instead. - (EventExpr.InstanceResolve): Copied from PropertyExpr, removed the - check for MarshalByRefObject, and report CS0122 instead of CS1540. - (EventExpr.DoResolve): Call IsAccessorAccessible on `add_accessor' - and `remove_accessor' as well as InstanceResolve: report CS0122 - where applicable. - - Fixes #70129. - -2004-12-03 Raja R Harinath - - Fix test-327.cs, test-328.cs, and put in early infrastructure - for eventually fixing #52697. - * namespace.cs (NamespaceEntry.LookupForUsing): New method. - (NamespaceEntry.LookupNamespaceOrType): New method, refactored - from other methods. - (NamespaceEntry.Lookup): Remove 'ignore_using' flag. - (AliasEntry.Resolve, UsingEntry.Resolve): Use 'LookupForUsing'. - (VerifyUsing, error246): Update. - * rootcontext.cs (RootContext.NamespaceLookup): Just use - 'NamespaceEntry.LookupNamespaceOrType'. - -2004-12-03 Martin Baulig - - * delegate.cs (NewDelegate.DoResolve): If we have an anonymous - method as our child, call AnonymousMethod.Compatible() on it. - -2004-12-03 Raja R Harinath - - Disable XML documentation support in 'basic' profile. - * decl.cs, class.cs [BOOTSTRAP_WITH_OLDLIB]: Don't import System.Xml. - Redirect XmlElement to System.Object. - * driver.cs, enum.cs, rootcontext.cs: Don't reference System.Xml. - * doc.cs [BOOTSTRAP_WITH_OLDLIB]: Disable compile. - * mcs.exe.sources: Add doc-bootstrap.cs. - * doc-bootstrap.cs: New file. Contains empty stub implementation - of doc.cs. - -2004-12-03 Atsushi Enomoto - - * cs-tokenizer.cs : Only '////' is rejected. Other non-whitespace - comments are allowed. - -2004-12-03 Carlos Alberto Cortez - - * delegate.cs: Add checks for subtypes in paramaters and return values - in VerifyMethod () to add support for Covariance/Contravariance - in delegates. - -2004-12-02 Miguel de Icaza - - * report.cs: Remove extra closing parenthesis. - - * convert.cs (Error_CannotImplicitConversion): If the name of the - types are the same, provide some extra information. - - * class.cs (FieldBase): Use an unused bit field from the field to - encode the `has_offset' property from the FieldMember. This saves - a couple of Ks on bootstrap compilation. - - * delegate.cs (NewDelegate.DoResolve): If we have an anonymous - method as our child, return the AnonymousMethod resolved - expression. - - * expression.cs (New.DoResolve): Allow return values from - NewDelegate to also include AnonymousMethods. - - Fixes #70150. - -2004-12-02 Marek Safar - - Fix bug #70102 - * attribute.cs (Resolve): Improved implementation of params - attribute arguments. - - * support.cs (ParameterData): Add HasParams to be faster. - -2004-12-02 Atsushi Enomoto - - all things are for /doc support: - - * doc.cs: new file that supports XML documentation generation. - * mcs.exe.sources: added doc.cs. - * driver.cs: - Handle /doc command line option. - Report error 2006 instead of 5 for missing file name for /doc. - Generate XML documentation when required, after type resolution. - * cs-tokenizer.cs: - Added support for picking up documentation (/// and /** ... */), - including a new XmlCommentState enumeration. - * cs-parser.jay: - Added lines to fill Documentation element for field, constant, - property, indexer, method, constructor, destructor, operator, event - and class, struct, interface, delegate, enum. - Added lines to warn incorrect comment. - * rootcontext.cs : - Added Documentation field (passed only when /doc was specified). - * decl.cs: - Added DocComment, DocCommentHeader, GenerateDocComment() and - OnGenerateDocComment() and some supporting private members for - /doc feature to MemberCore. - * class.cs: - Added GenerateDocComment() on TypeContainer, MethodCore and Operator. - * delegate.cs: - Added overriden DocCommentHeader. - * enum.cs: - Added overriden DocCommentHeader and GenerateDocComment(). - -2004-12-01 Miguel de Icaza - - * cfold.cs (ConstantFold.DoConstantNumericPromotions): After - unwrapping the enumeration values, chain to - DoConstantNumericPromotions again, so we can promote things to the - fundamental types (takes care of enums that are bytes, sbytes). - - Fixes bug #62054. - -2004-12-01 Raja R Harinath - - * attribute.cs (Attribute.CheckAttributeType): Remove complain flag. - Fix long-standing bug in type-lookup. Use FindType instead of - LookupType when ec.ResolvingTypeTree. - (Attribute.ResolveType, Attribute.Resolve) - (Attribute.DefinePInvokeMethod,GlobalAttribute.CheckAttributeType): - Update to changes. - (Attributes.Search): Remove internal version. Update. - (Attributes.SearchMulti): Update. - (Attributes.GetClsCompliantAttribute): Remove. - (Attributes.GetIndexerNameAttribute): Remove. - * decl.cs (MemberCore.GetClsCompliantAttributeValue): Update to changes. - (DeclSpace.GetClsCompliantAttributeValue): Likewise. - * class.cs (Indexer.Define): Likewise. - -2004-12-01 Marek Safar - - Fix bug #68790 - * ecore.cs: CheckMarshallByRefAccess new virtual method for testing - MarshallByReference members access. - - * expression.cs: Use CheckMarshallByRefAccess; - Better error CS0197 message. - - * report.cs: Print whole related error message. - -2004-11-30 Raja R Harinath - - * Makefile (mcs.exe) [PROFILE=default]: Keep a copy of mcs.exe in - the current directory to help debugging. - -2004-11-29 Marek Safar - - * class (GetClassBases): Better error 60 report. - (EventProperty): Disabled warning 67 detection. - -2004-11-29 Marek Safar - - Fix bug #60324 - * cfold.cs (Assign.DoResolve): Add subtraction for DecimalConstant. - - * constant.cs (DecimalConstant.Emit): Don't use int ctor for - precise values. - -2004-11-29 Marek Safar - - Fix bug #49488 - * assign.cs (Assign.DoResolve): Add error 1648, 1650 report. - - * decl.cs (MemberCore.MemberName): Error 1648 in compiler. - -2004-11-26 Miguel de Icaza - - * attribute.cs (Attribute.Resolve): Refine error reporting and - report a cs0117 if the identifier does not exist, to distinguish - from 0617 which is a miss-use of the actual identifier. - - * ecore.cs (EventExpr.Emit): Refine error report and distinguish - between cs0070 and cs0079. - - * class.cs (MemberBase.DoDefine): When reporting a wrong - accessibility level, we use MethodCore to compare instead of - Method (this was a regression in some refactoring effort). - - So now we correctly report cs0056 again. - - * convert.cs (ImplicitReferenceConversion): Corrected typo, I was - testing the target_type (which was known to be object_type) and - not the source type (which is anonymous_method). - - Fixed reporting of error cs1660. - - * expression.cs (UserCast.Source): Expose the underlying cast. - - * statement.cs (Switch.SwitchGoverningType): Sort the list of - allowed types to find a match to int32 first (most common). - - In addition, it ignores any ImplicitUserConversions that did an - internal implicit conversion (as the switch statement allows only - one integral conversion to exist). - - * class.cs (PartialContainer.Create): rename `name' to - `member_name' for clarity. Then replace the string calls with a - call to MemberName.GetPartialName, as now using - MemberName.ToString is an error (this is due to the side effects - it had, that were fixed in the past). - - This will restore the error reporting on a number of partial class - errors that were missusing this (and getting an exception as a - results, which is now just a plain textual warning, because - yyparse debug output would crash otherwise). - -2004-11-26 Raja R Harinath - - * Makefile (PROGRAM_INSTALL_DIR): Remove. - -2004-11-25 Ben Maurer - - * rootcontext.cs (LookupType): Make sure to cache lookups that - don't give us a negative result. This saves about 5% of corlib - compilation time. - -2004-11-25 Miguel de Icaza - - * report.cs (AbstractMessage.Print): messages are sent to stderr - - * class.cs (TypeContainer.GetClassBases): It is an error to have a - non-interface in the list of interfaces (at this point, either - parent was properly set, or a base class is being listed in the - interfaces section). - - This flags error 1722, and resolves the crash from bug 69259. - -2004-11-25 Ben Maurer - - * statement.cs (Using.EmitExpressionFinally): make this work right - for valuetypes. Fixes 69926. - -2004-11-25 Miguel de Icaza - - * const.cs (Const.ChangeType): Cope with the "0 literal can be - converted to an enum" here, before we try to change the underlying - type. This code exists, but it is a different code path than the - one used while encoding constants. - - * convert.cs (ImplicitReferenceConversionExists): A surprisingly - old bug: when converting from the null literal to a pointer, - return an EmptyCast, not the NullLiteral. - - This fixes #69921, the recent null_type changes probably made this - bug more prominent. - - (ImplicitReferenceConversionExists): In addition, resynchronized - the code here, so it matches the same code in - ImplicitReferenceConversionExists for the `from any class-type S - to any interface-type T'. - - -2004-11-25 Marek Safar - - * cfold.cs (BinaryFold): Add addition for DecimalConstant. - -2004-11-24 Miguel de Icaza - - * cs-parser.jay: Use verbosity accordingly. - -2004-11-24 Marek Safar - - * expression.cs (Unary.ResolveOperator): Do not report warning; - AddressOf reads from variable. - - (LocalVariableReferences.DoResolveBase): Improved my previous fix. - -2004-11-24 Marek Safar - - Fix bug #69462 - - * attribute.cs (Attributable): Removed CheckTargets. - (Attributes.Emit): Explicit attribute targets are tested here. - - * class.cs (EventField.ValidAttributeTargets): Explicit target "field" is - not enabled for interfaces. - - * codegen.cs (CommonAssemblyModulClass.AddAttributes): Removed CheckTargets. - (GetAssemblyName): Ouch next bug there. - -2004-11-23 Carlos Alberto Cortez - - * expression.cs: Error 275 added. - -2004-11-23 Marek Safar - - Fix bug #69177 (Implemented decimal constant support) - - * cfold.cs (DoConstantNumericPromotions: Add DecimalConstant. - (BinaryFold): Add DecimalConstant. - - * const.cs (Define): Decimal constant - (is not constant. - (ChangeType): Add decimal type handling. - (LookupConstantValue): Don't set value for decimal type but - emit DecimalConstantAttribute. Needed for constant optimization. - - * constant.cs (ToDecimal): New method. - (ConvertToDecimal): New method. - (IntConstant): Implemented ConvertToDecimal. - (DecimalConstant.Emit): Emit optimized version for decimals in - int range. - - * expression.cs (ResolveOperator): Changed order of constant - reduction to work correctly with native types which have - overloaded operators. - (ResolveMemberAccess): Extract constant value from attribute - for decimal type. - - * rootcontext.cs (ResolveCore): Add DecimalConstantAttribute. - - * typemanager.cs (TypeManager): Add decimal_constant_attribute_type, - void_decimal_ctor_int_arg, decimal_constant_attribute_ctor. - (ChangeType): Decimal is special. - (TypeToCoreType): Add decimal type. - -2004-11-22 Marek Safar - - * convert.cs (ImplicitConversionRequired): Add error cs0642 for - decimal types. - -2004-11-22 Marek Safar - - * class.cs (EventField.ApplyAttributeBuilder): Fix error - test cs1667-5.cs. - -2004-11-19 Marek Safar - - * class.cs (MemberBase.DoDefine): Fix error cs0508 report. - - * pending.cs (PendingImplementation): Grab only interfaces. - -2004-11-19 Marek Safar - - * statement.cs (ForeachHelperMethods): Add location member and - error 202 detection. - -2004-11-19 Raja R Harinath - - * Makefile (EXTRA_DISTFILES): Remove mcs.exe.config. It's - automatically handled by executable.make. - (PROGRAM): Make profile-specific. - -2004-11-18 Marek Safar - - * expression.cs (DoResolveBase): Fixed wrong warning for out - variables. - -2004-11-18 Martin Baulig - - Merged latest changes into gmcs. Please keep this comment in - here, it makes it easier for me to see what changed in MCS since - the last time I merged. - -2004-11-17 Raja R Harinath - - * typemanager.cs (TypeHandle.GetTypeHandle): Make private. - (TypeHandle.GetMemberCache): New. - (TypeHandle.TypeHandle): Update. - (TypeManager.LookupMemberCache): Rewritten from LookupMemberContainer. - (TypeManager.LookupParentInterfacesCache): - Rename from LookupInterfaceCache. Optimize slightly. - (TypeManager.MemberLookup_FindMembers): Update. - * decl.cs (MemberCache.MemberCache): Set Container to null in the - multi-type variant. - (AddCacheContents): Rename from AddHashtable. - * class.cs (TypeContainer.parent_container): Remove. - (TypeContainer.VerifyClsCompliance): Don't use parent_container. - (TypeContainer.DoDefineMembers): Don't initialize it. - Update to name changes. - -2004-11-17 Miguel de Icaza - - * class.cs (MethodCore.CheckAccessModifiers): New helper routine - that factors the code to check access modifiers on override. - - (PropertyBase): Use the code here. - - Patch from Lluis S'anchez, fixes bug #69361. - -2004-11-15 Miguel de Icaza - - * anonymous.cs (AnonymousMethod.Error_AddressOfCapturedVar): New - routine that is used to report the use of a captured variable - whose address has been taken. - - There are two checks: one when variables are being captured and - the other check is when the address of a variable is taken. - - (because an anonymous methods might be resolved before *or* after - the address has been taken) and - - * expression.cs (Conditional.DoResolve): Remove the special - casing that Martin added to trueExpr and falseExpr being both - NullLiteral. We get the right behavior now just by introducing - the null_type into the compiler. - - * convert.cs (ExplicitConversion): Change the code to use - null_type instead of testing `expr is NullLiteral'. - (ImplicitConversionStandard): use null_type too. - (ImplicitReferenceConversionExists): use null_type too. - (ImplicitReferenceConversion): use null_type too. - - * literal.cs: The type of `NullLiteral' is now null_type instead - of object_type. - (Resolve): Set the type here. - - * typemanager.cs: Introduce null_type. - -2004-11-17 Martin Baulig - - * decl.cs (MemberCache.AddHashtable): Add entries in the opposite - direction, like FindMembers() does. Fixes #69546, testcase is in - test-315.cs. - -2004-11-16 Martin Baulig - - This is based on a patch from Marek Safar, see bug #69082. - Fixes bugs #63705 and #67130. - - * typemanager.cs (TypeManager.LookupInterfaceCache): New public - method; create a MemberCache for an interface type and cache the - result. - - * decl.cs (IMemberContainer.ParentContainer): Removed. - (IMemberContainer.ParentCache): New property. - (MemberCache.SetupCacheForInterface): Removed. - (MemberCache..ctor): Added .ctor which takes a `Type[]'; use this - to create a cache for an interface's "parent". - - * class.cs (TypeContainer.DoDefineMembers): Setup cache for - interfaces too. - -2004-11-16 Martin Baulig - - Merged back from gmcs; these changes already went into gmcs a - couple of weeks ago. - - * typemanager.cs - (TypeManager.AddUserType): Removed the `ifaces' argument. - (TypeManager.RegisterBuilder): Take a `Type []' instead of a - `TypeExpr []'. - (TypeManager.AddUserInterface): Removed. - (TypeManager.ExpandInterfaces): Return a `Type []' instead of a - `TypeExpr []'. - (TypeManager.GetInterfaces): Likewise. - (TypeManager.GetExplicitInterfaces): Likewise. - - * ecore.cs (TypeExpr.GetInterfaces): Removed. - - * class.cs (TypeContainer.base_class_type): Replaced with `ptype'. - (TypeContainer.base_inteface_types): Replaced with `ifaces'. - -2004-11-14 Ben Maurer - - * statement.cs: Avoid adding bools to a hashtable. - -2004-11-07 Miguel de Icaza - - * expression.cs (Invocation.OverloadResolve): Flag error if we are - calling an unsafe method from a safe location. - -2004-11-06 Marek Safar - - Fix #69167 - * codegen.cs (ApplyAttributeBuilder): Do not return; it is only warning. - -2004-11-06 Miguel de Icaza - - * namespace.cs (VerifyUsing): use GetPartialName instead of - ToString. - -2004-11-05 Miguel de Icaza - - * statement.cs (Return.Resolve): Fix regression in typo: if - `in_exc', we have to request a NeedReturnLabel, this was a typo - introduced in the anonymous method check-in. Fixes #69131. - - * Indexers were using the ShortName when defining themselves, - causing a regression in the compiler bootstrap when applying the - patch from 2004-11-02 (first part), now they use their full name - and the bug is gone. - -2004-11-04 Zoltan Varga - - * driver.cs: Strip the path from the names of embedded resources. Fixes - #68519. - -2004-11-04 Raja R Harinath - - Fix error message regression: cs0104-2.cs. - * namespace.cs (NamespaceEntry.Lookup): Remove 'silent' flag. - (AliasEntry.Resolve): Update. - * rootcontext.cs (RootContext.NamespaceLookup): Update. Remove - 'silent' flag. - (RootContext.LookupType): Update. - -2004-11-03 Carlos Alberto Cortez - - * cs-parser.jay: Add support for handling accessor modifiers - * class: Add support port accessor modifiers and error checking, - define PropertyMethod.Define as virtual (not abstract anymore) - * ecore.cs: Add checking for proeprties access with access modifiers - * iterators.cs: Modify Accessor constructor call based in the modified - constructor -2004-11-02 Ben Maurer - - * expression.cs (StringConcat): Handle being called twice, - as when we have a concat in a field init with more than two - ctors in the class - -2004-11-02 Miguel de Icaza - - * class.cs (Event.Define, Indexer.Define, Property.Define): Do not - special case explicit implementations, we should always produce - the .property or .event declaration. - - * decl.cs (MemberName): Renamed GetFullName to GetPartialName - since it will not return correct data if people use this - unresolved in the presence of using statements (see test-313). - - * class.cs (MethodData.Define): If we are an explicit interface - implementation, set the method name to the full name of the - interface plus the name of the method. - - Notice that using the method.MethodName.GetFullName() does not - work, as it will only contain the name as declared on the source - file (it can be a shorthand in the presence of using statements) - and not the fully qualifed type name, for example: - - using System; - - class D : ICloneable { - object ICloneable.Clone () { - } - } - - Would produce a method called `ICloneable.Clone' instead of - `System.ICloneable.Clone'. - - * namespace.cs (Alias.Resolve): Use GetPartialName. - -2004-11-01 Marek Safar - - * cs-parser.jay: Add error 1055 report. - -2004-11-01 Miguel de Icaza - - * assign.cs (Assign.DoResolve): Only do the transform of - assignment into a New if the types are compatible, if not, fall - through and let the implicit code deal with the errors and with - the necessary conversions. - -2004-11-01 Marek Safar - - * cs-parser.jay: Add error 1031 report. - - * cs-tokenizer.cs: Add location for error 1038. - -2004-10-31 Marek Safar - - * cs-parser.jay: Add error 1016 report. - -2004-10-31 Marek Safar - - * cs-parser.jay: Add errors 1575,1611 report. - -2004-10-31 Marek Safar - - * cs-parser.jay: Add error 1001 report. - -2004-10-31 Marek Safar - - Fix #68850 - * attribute.cs (GetMarshal): Add method argument for - caller identification. - - * class.cs, codegen.cs, enum.cs, parameter.cs: Added - agument for GetMarshal and RuntimeMissingSupport. - -2004-10-31 Marek Safar - - * attribute.cs (ExtractSecurityPermissionSet): Removed - TypeManager.code_access_permission_type. - - * typemanager.cs: Removed TypeManager.code_access_permission_type. - -2004-10-27 Miguel de Icaza - - * expression.cs (LocalVariableReference.DoResolveLValue): Check - for obsolete use of a variable here. Fixes regression on errors - cs0619-25 and cs0619-26. - -2004-10-27 Marek Safar - - Fix #62358, implemented security attribute encoding. - - * attribute.cs (Attribute.CheckSecurityActionValididy): New method. - Tests permitted SecurityAction for assembly or other types. - (Assembly.ExtractSecurityPermissionSet): New method. Transforms - data from SecurityPermissionAttribute to PermisionSet class. - - * class.cs (ApplyAttributeBuilder): Added special handling - for System.Security.Permissions.SecurityAttribute based types. - - * codegen.cs (AssemblyClass.ApplyAttributeBuilder): Added - special handling for System.Security.Permissions.SecurityAttribute - based types. - - * enum.cs (ApplyAttributeBuilder): Added special handling - for System.Security.Permissions.SecurityAttribute based types. - - * parameter.cs (ApplyAttributeBuilder): Added special handling - for System.Security.Permissions.SecurityAttribute based types. - - * rootcontext.cs: Next 2 core types. - - * typemanager.cs (TypeManager.security_permission_attr_type): - Built in type for the SecurityPermission Attribute. - (code_access_permission_type): Build in type. - -2004-10-17 Miguel de Icaza - - * expression.cs (LocalVariableReference.DoResolveBase, Emit): - Remove the tests for `ec.RemapToProxy' from here, and encapsulate - all of this information into - EmitContext.EmitCapturedVariableInstance. - - * codegen.cs (EmitCapturedVariableInstance): move here the - funcionality of emitting an ldarg.0 in the presence of a - remapping. This centralizes the instance emit code. - - (EmitContext.EmitThis): If the ScopeInfo contains a THIS field, - then emit a load of this: it means that we have reached the - topmost ScopeInfo: the one that contains the pointer to the - instance of the class hosting the anonymous method. - - * anonymous.cs (AddField, HaveCapturedFields): Propagate field - captures to the topmost CaptureContext. - -2004-10-12 Miguel de Icaza - - * expression.cs (LocalVariableReference): Move the knowledge about - the iterators into codegen's EmitCapturedVariableInstance. - -2004-10-11 Miguel de Icaza - - * codegen.cs (EmitContext.ResolveTopBlock): Emit a 1643 when not - all code paths return a value from an anonymous method (it is the - same as the 161 error, but for anonymous methods). - -2004-10-08 Miguel de Icaza - - The introduction of anonymous methods in the compiler changed - various ways of doing things in the compiler. The most - significant one is the hard split between the resolution phase - and the emission phases of the compiler. - - For instance, routines that referenced local variables no - longer can safely create temporary variables during the - resolution phase: they must do so from the emission phase, - since the variable might have been "captured", hence access to - it can not be done with the local-variable operations from the runtime. - - * statement.cs - - (Block.Flags): New flag `IsTopLevel' to indicate that this block - is a toplevel block. - - (ToplevelBlock): A new kind of Block, these are the blocks that - are created by the parser for all toplevel method bodies. These - include methods, accessors and anonymous methods. - - These contain some extra information not found in regular blocks: - A pointer to an optional CaptureContext (for tracking captured - local variables and parameters). A pointer to the parent - ToplevelBlock. - - (Return.Resolve): Catch missmatches when returning a value from an - anonymous method (error 1662). - Invoke NeedReturnLabel from the Resolve phase instead of the emit - phase. - - (Break.Resolve): ditto. - - (SwitchLabel): instead of defining the labels during the - resolution phase, we now turned the public ILLabel and ILLabelCode - labels into methods called GetILLabelCode() and GetILLabel() that - only define the label during the Emit phase. - - (GotoCase): Track the SwitchLabel instead of the computed label - (its contained therein). Emit the code by using - SwitchLabel.GetILLabelCode (). - - (LocalInfo.Flags.Captured): A new flag has been introduce to track - whether the Local has been captured or not. - - (LocalInfo.IsCaptured): New property, used to tell whether the - local has been captured. - - * anonymous.cs: Vastly updated to contain the anonymous method - support. - - The main classes here are: CaptureContext which tracks any - captured information for a toplevel block and ScopeInfo used to - track the activation frames for various local variables. - - Each toplevel block has an optional capture context associated - with it. When a method contains an anonymous method both the - toplevel method and the anonymous method will create a capture - context. When variables or parameters are captured, they are - recorded on the CaptureContext that owns them, for example: - - void Demo () { - int a; - MyDelegate d = delegate { - a = 1; - } - } - - Here `a' will be recorded as captured on the toplevel - CapturedContext, the inner captured context will not have anything - (it will only have data if local variables or parameters from it - are captured in a nested anonymous method. - - The ScopeInfo is used to track the activation frames for local - variables, for example: - - for (int i = 0; i < 10; i++) - for (int j = 0; j < 10; j++){ - MyDelegate d = delegate { - call (i, j); - } - } - - At runtime this captures a single captured variable `i', but it - captures 10 different versions of the variable `j'. The variable - `i' will be recorded on the toplevel ScopeInfo, while `j' will be - recorded on a child. - - The toplevel ScopeInfo will also track information like the `this' - pointer if instance variables were referenced (this is necessary - as the anonymous method lives inside a nested class in the host - type of the method). - - (AnonymousMethod): Expanded to track the Toplevel, implement - `AnonymousMethod.Compatible' to tell whether an anonymous method - can be converted to a target delegate type. - - The routine now also produces the anonymous method content - - (AnonymousDelegate): A helper class that derives from - DelegateCreation, this is used to generate the code necessary to - produce the delegate for the anonymous method that was created. - - * assign.cs: API adjustments for new changes in - Convert.ImplicitStandardConversionExists. - - * class.cs: Adjustments to cope with the fact that now toplevel - blocks are of type `ToplevelBlock'. - - * cs-parser.jay: Now we produce ToplevelBlocks for toplevel blocks - insteda of standard blocks. - - Flag errors if params arguments are passed to anonymous methods. - - * codegen.cs (EmitContext): Replace `InAnonymousMethod' with - `CurrentAnonymousMethod' which points to the current Anonymous - Method. The variable points to the AnonymousMethod class that - holds the code being compiled. It is set in the new EmitContext - created for the anonymous method. - - (EmitContext.Phase): Introduce a variable and an enumeration to - assist in enforcing some rules about when and where we are allowed - to invoke certain methods (EmitContext.NeedsReturnLabel is the - only one that enfonces this right now). - - (EmitContext.HaveCaptureInfo): new helper method that returns - whether we have a CapturedContext initialized. - - (EmitContext.CaptureVariable): New method used to register that a - LocalInfo must be flagged for capturing. - - (EmitContext.CapturedParameter): New method used to register that a - parameters must be flagged for capturing. - - (EmitContext.CapturedField): New method used to register that a - field must be flagged for capturing. - - (EmitContext.HaveCapturedVariables, - EmitContext.HaveCapturedFields): Return whether there are captured - variables or fields. - - (EmitContext.EmitMethodHostInstance): This is used to emit the - instance for the anonymous method. The instance might be null - (static methods), this (for anonymous methods that capture nothing - and happen to live side-by-side with the current method body) or a - more complicated expression if the method has a CaptureContext. - - (EmitContext.EmitTopBlock): Routine that drives the emission of - code: it will first resolve the top block, then emit any metadata - and then emit the code. The split is done so that we can extract - any anonymous methods and flag any captured variables/parameters. - - (EmitContext.ResolveTopBlock): Triggers the resolution phase, - during this phase, the ILGenerator should not be used as labels - and local variables declared here might not be accessible to any - code that is part of an anonymous method. - - Exceptions to this include the temporary variables that are - created by some statements internally for holding temporary - variables. - - (EmitContext.EmitMeta): New routine, in charge of emitting all the - metadata for a cb - - (EmitContext.TemporaryReturn): This method is typically called - from the Emit phase, and its the only place where we allow the - ReturnLabel to be defined other than the EmitMeta. The reason is - that otherwise we would have to duplicate a lot of logic in the - Resolve phases of various methods that today is on the Emit - phase. - - (EmitContext.NeedReturnLabel): This no longer creates the label, - as the ILGenerator is not valid during the resolve phase. - - (EmitContext.EmitThis): Extended the knowledge in this class to - work in anonymous methods in addition to iterators. - - (EmitContext.EmitCapturedVariableInstance): This emits whatever - code is necessary on the stack to access the instance to a local - variable (the variable will be accessed as a field). - - (EmitContext.EmitParameter, EmitContext.EmitAssignParameter, - EmitContext.EmitAddressOfParameter): Routines to support - parameters (not completed at this point). - - Removals: Removed RemapLocal and RemapLocalLValue. We probably - will also remove the parameters. - - * convert.cs (Convert): Define a `ConstantEC' which points to a - null. This is just to prefity some code that uses - ImplicitStandardConversion code and do not have an EmitContext - handy. - - The idea is to flag explicitly that at that point in time, it is - known that the conversion will not trigger the delegate checking - code in implicit conversions (which requires a valid - EmitContext). - - Everywhere: pass new EmitContext parameter since - ImplicitStandardConversionExists now requires it to check for - anonymous method conversions. - - (Convert.ImplicitStandardConversionExists): If the type of an - expression is the anonymous_method_type, and the type is a - delegate, we invoke the AnonymousMethod.Compatible method to check - whether an implicit conversion is possible. - - (Convert.ImplicitConversionStandard): Only do implicit method - group conversions if the language level is not ISO_1. - - * delegate.cs (Delegate.GetInvokeMethod): Common method to get the - MethodInfo for the Invoke method. used by Delegate and - AnonymousDelegate. - - * expression.cs (Binary.DoNumericPromotions): only allow anonymous - method conversions if the target type is a delegate. - - Removed extra debugging nops. - - (LocalVariableReference): Turn the `local_info' into a public - field. - - Add `prepared' field, the same hack used for FieldExprs to cope - with composed assignments, as Local variables do not necessarily - operate purely on the stack as they used to: they can be captured - fields. - - Add `temp' for a temporary result, like fields. - - Refactor DoResolve and DoResolveLValue into DoResolveBase. - - It now copes with Local variables that are captured and emits the - proper instance variable to load it from a field in the captured - case. - - (ParameterReference.DoResolveBase): During the resolve phase, - capture parameters if we are in an anonymous method. - - (ParameterReference.Emit, ParameterReference.AddressOf): If in an - anonymous method, use the EmitContext helper routines to emit the - parameter reference. - - * iterators.cs: Set RemapToProxy to true/false during the - EmitDispose class. - - * parameters.cs (GetParameterByName): New helper method. - - * typemanager.cs (anonymous_method_type) a new type that - represents an anonyous method. This is always an internal type, - used as a fencepost to test against the anonymous-methodness of an - expression. - -2004-10-20 Marek Safar - - * class.cs (MethodCore.CheckBase): Add errors 505, 533, 544, - 561 report. - (PropertyBase.FindOutParentMethod): Add errors 545, 546 report. - -2004-10-18 Martin Baulig - - * statement.cs (Fixed.Resolve): Don't access the TypeExpr's - `Type' directly, but call ResolveType() on it. - (Catch.Resolve): Likewise. - (Foreach.Resolve): Likewise. - -2004-10-18 Martin Baulig - - * expression.cs (Cast.DoResolve): Don't access the TypeExpr's - `Type' directly, but call ResolveType() on it. - (Probe.DoResolve): Likewise. - (ArrayCreation.LookupType): Likewise. - (TypeOf.DoResolve): Likewise. - (SizeOf.DoResolve): Likewise. - -2004-10-18 Martin Baulig - - * expression.cs (Invocation.BetterFunction): Put back - TypeManager.TypeToCoreType(). - -2004-10-18 Raja R Harinath - - * class.cs (FieldMember.DoDefine): Reset ec.InUnsafe after doing - the ResolveType. - -2004-10-18 Martin Baulig - - * parameter.cs (Parameter.Resolve): Don't access the TypeExpr's - `Type' directly, but call ResolveType() on it. - -2004-10-18 Martin Baulig - - * class.cs (FieldMember.Define): Don't access the TypeExpr's - `Type' directly, but call ResolveType() on it. - (MemberBase.DoDefine): Likewise. - - * expression.cs (New.DoResolve): Don't access the TypeExpr's - `Type' directly, but call ResolveType() on it. - (ComposedCast.DoResolveAsTypeStep): Likewise. - - * statement.cs (LocalInfo.Resolve): Don't access the TypeExpr's - `Type' directly, but call ResolveType() on it. - -2004-10-17 John Luke - - * class.cs (Operator.GetSignatureForError): use CSharpName - - * parameter.cs (Parameter.GetSignatureForError): Returns - correct name even if was not defined. - -2004-10-13 Raja R Harinath - - Fix #65816. - * class.cs (TypeContainer.EmitContext): New property. - (DefineNestedTypes): Create an emitcontext for each part. - (MethodCore.DoDefineParameters): Use container's emitcontext. - Pass type array to InternalParameters. - (MemberBase.DoDefine): Use container's emitcontext. - (FieldMember.Define): Likewise. - (Event.Define): Likewise. - (SetMethod.GetParameterInfo): Change argument to EmitContext. - Pass type array to InternalParameters. - (SetIndexerMethod.GetParameterInfo): Likewise. - (SetMethod.Define): Pass emitcontext to GetParameterInfo. - * delegate.cs (Define): Pass emitcontext to - ComputeAndDefineParameterTypes and GetParameterInfo. Pass type - array to InternalParameters. - * expression.cs (ParameterReference.DoResolveBase): Pass - emitcontext to GetParameterInfo. - (ComposedCast.DoResolveAsTypeStep): Remove check on - ec.ResolvingTypeTree. - * parameter.cs (Parameter.Resolve): Change argument to - EmitContext. Use ResolveAsTypeTerminal. - (Parameter.GetSignature): Change argument to EmitContext. - (Parameters.ComputeSignature): Likewise. - (Parameters.ComputeParameterTypes): Likewise. - (Parameters.GetParameterInfo): Likewise. - (Parameters.ComputeAndDefineParameterTypes): Likewise. - Re-use ComputeParameterTypes. Set ec.ResolvingTypeTree. - * support.cs (InternalParameters..ctor): Remove variant that takes - a DeclSpace. - * typemanager.cs (system_intptr_expr): New. - (InitExpressionTypes): Initialize it. - -2004-10-12 Chris Toshok - - * cs-parser.jay: fix location for try_statement and catch_clause. - -2004-10-11 Martin Baulig - - * report.cs: Don't make --fatal abort on warnings, we have - -warnaserror for that. - -2004-10-07 Raja R Harinath - - More DeclSpace.ResolveType avoidance. - * decl.cs (MemberCore.InUnsafe): New property. - * class.cs (MemberBase.DoDefine): Use ResolveAsTypeTerminal - with newly created EmitContext. - (FieldMember.Define): Likewise. - * delegate.cs (Delegate.Define): Likewise. - * ecore.cs (SimpleName.ResolveAsTypeStep): Lookup with alias - only if normal name-lookup fails. - (TypeExpr.DoResolve): Enable error-checking. - * expression.cs (ArrayCreation.DoResolve): Use ResolveAsTypeTerminal. - (SizeOf.DoResolve): Likewise. - (ComposedCast.DoResolveAsTypeStep): Likewise. - (StackAlloc.DoResolve): Likewise. - * statement.cs (Block.Flags): Add new flag 'Unsafe'. - (Block.Unsafe): New property. - (Block.EmitMeta): Set ec.InUnsafe as appropriate. - (Unsafe): Set 'unsafe' flag of contained block. - (LocalInfo.Resolve): Use ResolveAsTypeTerminal. - (Fixed.Resolve): Likewise. - (Catch.Resolve): Likewise. - (Using.ResolveLocalVariableDecls): Likewise. - (Foreach.Resolve): Likewise. - -2004-10-05 John Luke - - * cs-parser.jay: add location to error CS0175 - -2004-10-04 Miguel de Icaza - - * ecore.cs (Expression.Constantity): Add support for turning null - into a constant. - - * const.cs (Const.Define): Allow constants to be reference types - as long as the value is Null. - -2004-10-04 Juraj Skripsky - - * namespace.cs (NamespaceEntry.Using): No matter which warning - level is set, check if this namespace name has already been added. - -2004-10-03 Ben Maurer - - * expression.cs: reftype [!=]= null should always use br[true,false]. - # 67410 - -2004-10-03 Marek Safar - - Fix #67108 - * attribute.cs: Enum conversion moved to - GetAttributeArgumentExpression to be applied to the all - expressions. - -2004-10-01 Raja R Harinath - - Fix #65833, test-300.cs, cs0122-5.cs, cs0122-6.cs. - * class.c (TypeContainer.DefineType): Flag error if - base types aren't accessible due to access permissions. - * decl.cs (DeclSpace.ResolveType): Move logic to - Expression.ResolveAsTypeTerminal. - (DeclSpace.ResolveTypeExpr): Thin layer over - Expression.ResolveAsTypeTerminal. - (DeclSpace.CheckAccessLevel, DeclSpace.FamilyAccess): - Refactor code into NestedAccess. Use it. - (DeclSpace.NestedAccess): New. - * ecore.cs (Expression.ResolveAsTypeTerminal): Add new - argument to silence errors. Check access permissions. - (TypeExpr.DoResolve, TypeExpr.ResolveType): Update. - * expression.cs (ProbeExpr.DoResolve): Use ResolveAsTypeTerminal. - (Cast.DoResolve): Likewise. - (New.DoResolve): Likewise. - (InvocationOrCast.DoResolve,ResolveStatement): Likewise. - (TypeOf.DoResolve): Likewise. - - * expression.cs (Invocation.BetterConversion): Return the Type of - the better conversion. Implement section 14.4.2.3 more faithfully. - (Invocation.BetterFunction): Make boolean. Make correspondence to - section 14.4.2.2 explicit. - (Invocation.OverloadResolve): Update. - (Invocation): Remove is_base field. - (Invocation.DoResolve): Don't use is_base. Use mg.IsBase. - (Invocation.Emit): Likewise. - -2004-09-27 Raja R Harinath - - * README: Update to changes. - -2004-09-24 Marek Safar - - * cs-parser.jay: Reverted 642 warning fix. - -2004-09-23 Marek Safar - - Fix bug #66615 - * decl.cs (FindMemberWithSameName): Indexer can have more than - 1 argument. - -2004-09-23 Marek Safar - - * expression.cs (LocalVariableReference.DoResolveLValue): - Do not report warning 219 for out values. - (EmptyExpression.Null): New member to avoid extra allocations. - -2004-09-23 Marek Safar - - * cs-parser.jay: Fix wrong warning 642 report. - - * cs-tokenizer.cs (CheckNextToken): New helper; - Inspect next character if is same as expected. - -2004-09-23 Martin Baulig - - * convert.cs (Convert.ImplicitReferenceConversion): Some code cleanup. - (Convert.ImplicitReferenceConversionExists): Likewise. - -2004-09-23 Marek Safar - - * class.cs (Operator.Define): Add error 448 and 559 report. - -2004-09-22 Marek Safar - - * class.cs (MemberBase.IsTypePermitted): New protected - method for checking error CS0610. - -2004-09-22 Marek Safar - - * class.cs (TypeContainer.HasExplicitLayout): New property - Returns whether container has StructLayout attribute set Explicit. - (FieldMember): New abstract class for consts and fields. - (FieldMember.ApplyAttributeBuilder): Add error 636 and 637 report. - (Field): Reuse FieldMember. - - * const.cs (Const): Reuse FieldMember. - - * rootcontext.cs: EmitConstants call moved to class. - -2004-09-22 Martin Baulig - - Thanks to Peter Sestoft for this bug report. - - * expression.cs (Conditional): If both the `trueExpr' and the - `falseExpr' is a NullLiteral, return a NullLiteral. - -2004-09-22 Martin Baulig - - * statement.cs (Foreach.EmitCollectionForeach): If we're in an - iterator, use `enumerator.EmitThis()' instead of `ec.EmitThis()' - for the "get_Current" call. - -2004-09-22 Martin Baulig - - Marek and me just fixed one of our oldest bugs: #28562 :-) - - * ecore.cs (EnumConstant.GetValueAsEnumType): New public method. - - * attribute.cs (Attribute.GetAttributeArgumentExpression): If - we're an EnumConstant, just return that. - (Attribute.Resolve): GetAttributeArgumentExpression() may give us - an EnumConstant. In this case, we need to use GetValueAsEnumType() - to get the value which'll actually be written into the attribute. - However, we have to use GetValue() to access the attribute's value - in the compiler. - -2004-09-22 Marek Safar - - * constant.cs (Constant.IsNegative): New abstract property - IsNegative. - - * expression.cs (ArrayAccess.DoResolve): Add warning 251. - (StackAlloc.DoResolve): Reused IsNegative. - -2004-09-21 Martin Baulig - - * codegen.cs (VariableStorage): Don't store the ILGenerator here; - if we're used in an iterator, we may be called from different - methods. - - * statement.cs (Foreach.EmitFinally): Only emit an `Endfinally' if - we actually have an exception block. - -2004-09-20 John Luke - - * class.cs, cs-parser.jay: Improve the error report for 1520: - report the actual line where the error happens, not where the - class was declared. - - * assign.cs, delegate.cs, ecore.cs, expression.cs, statement.cs: - Pass location information that was available elsewhere. - -2004-09-19 Sebastien Pouliot - - * codegen.cs: Fix bug #56621. It is now possible to use MCS on the MS - runtime to delay sign assemblies. - -2004-09-19 Miguel de Icaza - - * cs-parser.jay: Do not report the stack trace, this is barely - used nowadays. - -2004-08-22 John Luke - - * driver.cs : check that a resource id is not already used - before adding it, report CS1508 if it is, bug #63637 - -2004-09-19 Miguel de Icaza - - * ecore.cs: Removed dead code. - -2004-09-18 Marek Safar - - * class.cs: Do not report warning CS0067 on the interfaces. - -2004-09-16 Marek Safar - - * cs-parser.jay: Add error 504 report. - -2004-09-16 Marek Safar - - * rootcontext.cs: WarningLevel is 4 by default now. - - * statement.cs (Fixed.Resolve): Do not null - VariableInfo. - -2004-09-16 Marek Safar - - Fixed bug #55780 - * ecore.cs (PropertyExpr.FindAccessors): Do not perform - deep search when property is not virtual. - (PropertyExpr.ResolveAccessors): Make one call for both - accessors. - -2004-09-15 Marek Safar - - Fixed bug #65766 - * statement.cs: Error 152 report constains also location. - -2004-09-15 Marek Safar - - Fixed bug #65766 - * const.cs: Explicitly set constant as static. - -2004-09-15 Marek Safar - - Fixed bug #64226 - * cs-parser.jay: Add error 1017 report. - -2004-09-15 Marek Safar - - Fixed bug #59980, #64224 - * expression.cs (Invocation.DoResolve): Fixed error CS0571 test. - - * typemanager.cs (IsSpecialMethod): Simplified - -2004-09-14 Marek Safar - - * decl.cs (MemberCore.Emit): Resuscitated VerifyObsoleteAttribute - condition with better params. - -2004-09-14 Marek Safar - - Fixed bug #65238 - * attribute.cs (Resolve): Property has to have both - accessors. - -2004-09-14 Martin Baulig - - * decl.cs (MemberCore.Emit): Always call VerifyObsoleteAttribute(). - -2004-09-14 Marek Safar - - Fixed bug #61902 - * codegen.cs (TestObsoleteMethodUsage): Trace when method is - called and is obsolete then this member suppress message - when call is inside next [Obsolete] method or type. - - * expression.cs: Use TestObsoleteMethodUsage member. - -2004-09-14 Martin Baulig - - * cs-parser.jay: Sync a bit with the GMCS version. - -2004-09-14 Martin Baulig - - * cs-parser.jay (CSharpParser): Don't derive from GenericsParser. - (CSharpParser.yacc_verbose_flag): New public field. - - * genericparser.cs: Removed. - -2004-09-14 Raja R Harinath - - * cs-parser.jay (event_declaration): Re-enable cs0071 error. - -2004-09-13 Marek Safar - - * class.cs (MethodCore.CheckBase): Fix bug #65757. - -2004-09-10 Martin Baulig - - Backported my MemberName changes from GMCS into MCS. - - - we are now using a special `MemberName' class instead of using - strings; in GMCS, the `MemberName' also contains the type - arguments. - - - changed the grammar rules a bit: - * the old `member_name' is now a `namespace_or_type_name': - The rule is that we use `namespace_or_type_name' everywhere - where we expect either a "member name" (GetEnumerator) or a - "member name" with an explicit interface name - (IEnumerable.GetEnumerator). - In GMCS, the explicit interface name may include type arguments - (IEnumerable.GetEnumerator). - * we use `member_name' instead of just `IDENTIFIER' for - "member names": - The rule is that we use `member_name' wherever a member may - have type parameters in GMCS. - - * decl.cs (MemberName): New public class. - (MemberCore.MemberName): New public readonly field. - (MemberCore.ctor): Take a `MemberName' argument, not a string. - (DeclSpace): Likewise. - - * delegate.cs (Delegate.ctor): Take a MemberName, not a string. - * enum.cs (Enum.ctor): Likewise. - - * namespace.cs (AliasEntry.Alias): Changed type from Expression to - MemberName. - (AliasEntry.ctor): Take a MemberName, not an Expression. - (AliasEntry.UsingAlias): Likewise. - - * class.cs (TypeContainer.ctor): Take a MemberName, not a string. - (IMethodData.MemberName): Changed type from string to MemberName. - (MemberBase.ExplicitInterfaceName): Likewise. - (AbstractPropertyEventMethod.SetupName): Make this private. - (AbstractPropertyEventMethod.ctor): Added `string prefix' - argument; compute the member name here. - (AbstractPropertyEventMethod.UpdateName): Recompute the name based - on the `member.MemberName' and the `prefix'. - - * cs-parser.jay (attribute_name): Use `namespace_or_type_name', - not `type_name'. - (struct_declaration): Use `member_name' instead of `IDENTIFIER'; - thus, we get a `MemberName' instead of a `string'. These - declarations may have type parameters in GMCS. - (interface_method_declaration, delegate_declaration): Likewise. - (class_declaration, interface_declaration): Likewise. - (method_header): Use `namespace_or_type_name' instead of - `member_name'. We may be an explicit interface implementation. - (property_declaration, event_declaration): Likewise. - (member_name): This is now just an `IDENTIFIER', not a - `namespace_or_type_name'. - (type_name, interface_type): Removed. - (namespace_or_type_name): Return a MemberName, not an Expression. - (primary_expression): Use `member_name' instead of `IDENTIFIER'; - call GetTypeExpression() on the MemberName to get an expression. - (IndexerDeclaration.interface_type): Changed type from string to - MemberName. - (MakeName): Operate on MemberName's instead of string's. - -2004-09-13 Raja R Harinath - - Fix bug #55770. - * namespace.cs (AliasEntry.Resolve): Implement section 16.3.1. - (NamespaceEntry.Lookup): Add new argument to flag if we want the - lookup to avoid symbols introduced by 'using'. - * rootcontext.cs (NamespaceLookup): Update. - -2004-09-12 Marek Safar - - * class.cs (TypeContainer.DoDefineMembers): Do not call - DefineDefaultConstructor for static classes. - -2004-09-12 Marek Safar - - * attribute.cs (Attribute.Resolve): Add error 653 report. - - * class.cs (Class.ApplyAttributeBuilder): Add error 641 - report. - (Method.ApplyAttributeBuilder): Add error 685 report. - (Operator.Define): Add error 564 report. - - * cs-tokenizer.cs (handle_hex): Add error 1013 report. - - * expression.cs (Invocation.DoResolve): Add error - 245 and 250 report. - - * parameter.cs (Parameter.ApplyAttributeBuilder): Add - error 674 report. - -2004-09-11 Marek Safar - - * class.cs (ConstructorInitializer.Resolve): - Wrong error number (515->516). - -2004-09-11 Marek Safar - - * class.cs (Indexer.Define): Add error 631 report. - -2004-09-11 Marek Safar - - * ecore.cs (Error_NegativeArrayIndex): Fix 248 error. - -2004-09-11 Marek Safar - - * expression.cs (Probe.DoResolve): Add error CS0241 report. - -2004-09-10 Marek Safar - - * cs-parser.jay: Added error CS0241 report. - -2004-09-10 Raja R Harinath - - * cs-parser.jay (fixed_statement): Introduce a scope for the - declaration in the 'fixed' statement. - -2004-09-09 Marek Safar - - * cs-parser.jay: Added CS0230 error report. - -2004-09-09 Marek Safar - - * cs-parser.jay: Added errors CS0231 and CS0257 report. - -2004-09-09 Marek Safar - - * expression.cs (Argument.Resolve): Added error CS0192 and - CS0199 report. - -2004-09-09 Marek Safar - - C# 2.0 #pragma warning feature - - * cs-tokenizer.cs (PreProcessPragma): New method; - Handles #pragma directive. - - * report.cs (WarningRegions): New class; Support - class for #pragma warning directive. It tests whether - warning is enabled for a given line. - -2004-09-08 Miguel de Icaza - - * const.cs: Add more descriptive error report, tahnks to - Sebastien. - -2004-09-08 Marek Safar - - * ecore.cs (FieldExpr.DoResolveLValue): Fixed CS0198 report. - -2004-09-07 Miguel de Icaza - - * expression.cs: Apply patch from Ben: Remove dead code from - ArrayCreation, and remove the TurnintoConstant call in const.cs, - as that code just threw an exception anwyays. - - * const.cs: Remove the call to the turnintoconstant, for details - see bug: #63144 - - * literal.cs: The type of the null-literal is the null type; So - we use a placeholder type (literal.cs:System.Null, defined here) - for it. - - * expression.cs (Conditional.DoResolve): Remove some old code that - is no longer needed, conversions have been fixed. - - (ArrayCreationExpression.DoResolve): Return false if we fail to - resolve the inner expression. - -2004-09-07 Raja R Harinath - - Fix test-290.cs. - * cs-parser.jay (delegate_declaration): Record a delegate - declaration as a type declaration. - Reported by Jo Vermeulen . - -2004-09-06 Miguel de Icaza - - * parameter.cs: Do not crash if the type can not be resolved. - - * expression.cs: Report errors with unsafe pointers, fixes #64896 - -2004-09-06 Ben Maurer - - * expression.cs: Pointer arith always needs to do a conv.i - if the operand is a long. fix 65320 - -2004-09-04 Marek Safar - - Fixed cs0619-37.cs, cs0619-38.cs - - * enum.cs (GetObsoleteAttribute): Removed. - - * expression.cs (MemberAccess.DoResolve): Test for [Obsolete] - on Enum member is double staged. The first is tested member - and then enum. - -2004-09-04 Marek Safar - - Fixed #56986, #63631, #65231 - - * class.cs: (TypeContainer.AddToMemberContainer): New method, - adds member to name container. - (TypeContainer.AddToTypeContainer): New method, adds type to - name container. - (AddConstant, AddEnum, AddClassOrStruct, AddDelegate, AddMethod, - AddConstructor, AddInterface, AddField, AddProperty, AddEvent, - AddOperator): Simplified by reusing AddToMemberContainer. - (TypeContainer.UserDefinedStaticConstructor): Changed to property - instead of field. - (Method.CheckForDuplications): Fixed implementation to test all - possibilities. - (MemberBase): Detection whether member is explicit interface - implementation is now in constructor. - (MemberBase.UpdateMemberName): Handles IndexerName. - (Accessor): Changed to keep also location information. - (AbstractPropertyEventMethod): Is derived from MemberCore. - (AbstractPropertyEventMethod.IsDummy): Says whether accessor - will be emited or not. - (PropertyBase.AreAccessorsDuplicateImplementation): - Tests whether accessors are not in collision with some method. - (Operator): Is derived from MethodCore to simplify common - operations. - - * decl.cs (Flags.TestMethodDuplication): Test for duplication - must be performed. - (DeclSpace.AddToContainer): Adds the member to defined_names - table. It tests for duplications and enclosing name conflicts. - - * enum.cs (EnumMember): Clean up to reuse the base structures - -2004-09-03 Martin Baulig - - * class.cs (TypeContainer.DefineDefaultConstructor): Put this back - into TypeContainer, to make partial classes work again. - -2004-09-03 Martin Baulig - - * rootcontext.cs (RootContext.V2): Removed. - -2004-03-23 Martin Baulig - - * expression.cs (Invocation.OverloadResolve): Added `bool - may_fail' argument and use it instead of the Location.IsNull() hack. - -2004-09-03 Martin Baulig - - Merged latest changes into gmcs. Please keep this comment in - here, it makes it easier for me to see what changed in MCS since - the last time I merged. - -2004-09-03 Raja R Harinath - - Fix #61128. - * expression.cs (BetterConversion): Don't allow either conversion - to be null. Remove redundant implicit conversion test when 'q == - null' -- when this function is invoked, we already know that the - implicit conversion exists. - (BetterFunction): Assume that 'best' is non-null. Remove - redundant reimplementation of IsApplicable when 'best' is null. - (IsParamsMethodApplicable, IsApplicable): Add new parameter for - number of arguments. - (IsAncestralType): Extract from OverloadResolve. - (OverloadResolve): Make robust to the MethodGroupExpr being - unsorted. Implement all the logic of Section 14.5.5.1, and - support overloading of methods from multiple applicable types. - Clean up logic somewhat. Don't pass null methods to BetterFunction. - - * report.cs (SymbolRelatedToPreviousError): Cleanup output. - (RealError, Warning): Append type of report to related symbol. - -2004-09-03 Marek Safar - - * enum.cs: Fixed CLS-Compliance checks for enum members. - Error tests cs3008-8.cs, cs3014-8.cs - -2004-09-02 Marek Safar - - Fixed bug #62342, #63102 - * class.cs: ImplementIndexer uses member.IsExplicitImpl - like ImplementMethod. - -2004-09-02 Marek Safar - - * attribute.cs (Attribute.GetAttributeArgumentExpression): - Fixed bug #65170. - -2004-09-02 Martin Baulig - - * statement.cs (Using.EmitLocalVariableDeclFinally): Use - TypeManager.GetArgumentTypes() rather than calling GetParameters() - on the MethodBase. - -2004-09-01 Marek Safar - - C# 2.0 Static classes implemented - - * class.cs (TypeContainer): instance_constructors, - initialized_fields, initialized_static_fields, - default_constructor, base_inteface_types are protected to be - accessible from StaticClass. - (TypeContainer.DefineDefaultConstructor): New virtual method - for custom default constructor generating - (StaticClass): New class to handle "Static classes" feature. - - * cs-parser.jay: Handle static keyword on class like instance - of StaticClass. - - * driver.cs: Added "/langversion" command line switch with two - options (iso-1, default). - -2004-08-31 Marek Safar - - * ecore.cs (FieldExpr.Resolve): Fixed bug #64689. - -2004-08-31 Miguel de Icaza - - * delegate.cs: Style. - -2004-08-31 Ben Maurer - - * delegate.cs: Add seperate instance expr field for miguel. - -2004-08-29 Ben Maurer - - * PointerArithmetic (Resolve): make sure we are not doing - pointer arith on void*. Also, make sure we are resolved - by not setting eclass until resolve. - - All callers: Make sure that PointerArithmetic gets resolved. - -2004-08-29 Ben Maurer - - * ArrayCreation (LookupType): If the type does not resolve - to an array, give an error. - -2004-08-27 Marek Safar - - * statement.cs (Try.Resolve): Fixed bug #64222 - -2004-08-27 Martin Baulig - - * class.cs - (TC.OperatorArrayList.OperatorEntry.CheckPairedOperators): Don't - crash here. - -2004-08-26 Marek Safar - - * ecore.cs (Constantify): Get underlying type via - System.Enum.GetUnderlyingType to avoid StackOverflow on the - Windows in special cases. - -2004-08-26 Marek Safar - - * typemanager.cs (GetAddMethod): Used GetAddMethod (true) - for obtaining also private methods. - (GetRemoveMethod): Used GetRemoveMethod (true) - for obtaining also private methods. - -2004-08-24 Martin Baulig - - * class.cs (Method.Define): Set MethodAttributes.SpecialName and - MethodAttributes.HideBySig for operators. - -2004-08-23 Martin Baulig - - Back to the old error reporting system :-) - - * report.cs (Message): Removed. - (Report.MessageData, ErrorData, WarningData): Removed. - (Report.Error, Warning): Back to the old system. - -2004-08-23 Martin Baulig - - * decl.cs (IMemberContainer.Parent): Renamed to ParentContainer. - - * class.cs (TypeContainer.ParentContainer): New public virtual - method; replaces the explicit interface implementation. - (ClassPart.ParentContainer): Override. - -2004-08-23 Martin Baulig - - * statement.cs (Switch): Added support for constant switches; see - #59428 or test-285.cs. - -2004-08-22 Marek Safar - - Fixed bug #62740. - * statement.cs (GetEnumeratorFilter): Removed useless - logic because C# specs is strict. GetEnumerator must be - public. - -2004-08-22 Martin Baulig - - * flowanalysis.cs (FlowBranching.UsageVector.MergeChild): If we're - a switch and may break, reset the barrier. Fixes #59867. - -2004-08-22 Marek Safar - - CLS-Compliance speed up (~5% for corlib) - - * attribute.cs (AttributeTester.VerifyTopLevelNameClsCompliance): - New method. Tests container for CLS-Compliant names - - * class.cs (TypeContainer.VerifyClsName): New method. - Checks whether container name is CLS Compliant. - (Constructor): Implements IMethodData. - - * decl.cs (MemberCache.GetPublicMembers ): New method. Builds - low-case table for CLS Compliance test. - (MemberCache.VerifyClsParameterConflict): New method. - Checks method parameters for CS3006 error. - - * enum.cs (EnumMember): Is derived from MemberCore. - (Enum.VerifyClsName): Optimized for better performance. - -2004-08-06 Marek Safar - - * report.cs: Renamed Error_T to Error and changed all - references. - -2004-08-06 Marek Safar - - * class.cs (TypeContainer.IndexerArrayList): New inner class - container for indexers. - (TypeContainer.DefaultIndexerName): New constant for default - indexer name. Replaced all "Item" with this constant. - (TypeContainer.DefineIndexers): Moved to IndexerArrayList class. - - * typemanager.cs (TypeManager.default_member_ctor): Cache here - DefaultMemberAttribute constructor. - -2004-08-05 Martin Baulig - - * flowanalysis.cs (FlowBranching.UsageVector.MergeJumpOrigins): - Fix bug #59429. - -2004-08-05 Marek Safar - - * mcs.exe.sources: $(EXTRA_SOURCES) are now here to avoid - multi platforms problem. - - * compiler.csproj: Included shared files. - -2004-08-04 Marek Safar - - Fix bug 60333, 55971 in the more general way - * attribute.cs (Attribute.GetAttributeArgumentExpression): - Added arg_type argument for constant conversion. - (Attribute.Resolve): Reuse GetAttributeArgumentExpression. - -2004-08-04 Marek Safar - - Fix bug #59760 - * class.cs (TypeContainer ): New inner classes MethodArrayList, - OperatorArrayList, MethodCoreArrayList for typecontainer - containers. Changed class member types to these new types. - (MethodArrayList.DefineMembers): Added test for CS0659. - -2004-08-04 Miguel de Icaza - - * cfold.cs: Synchronize the folding with the code in expression.cs - Binary.DoNumericPromotions for uint operands. - - * attribute.cs: Revert patch from Raja, it introduced a regression - while building Blam-1.2.1 (hard to isolate a test case). - -2004-08-04 Marek Safar - - Fix for #55382 - * class.cs: - (TypeContainer.Define): Renamed to DefineContainerMembers because of - name collision. - (MethodCore.parent_method): New member. The method we're overriding - if this is an override method. - (MethodCore.CheckBase): Moved from Method class and made common. - (MethodCore.CheckMethodAgainstBase): Moved from MemberBase and made - private. - (MethodCore.CheckForDuplications): New abstract method. For custom - member duplication search in a container - (MethodCore.FindOutParentMethod): New abstract method. Gets parent - method and its return type. - (Event.conflict_symbol): New member. Symbol with same name in the - parent class. - - * decl.cs: - (MemberCache.FindMemberWithSameName): New method. The method - is looking for conflict with inherited symbols. - -2004-08-04 Martin Baulig - - * codegen.cs (VariableStorage.EmitLoadAddress): New public method. - - * statement.cs (Foreach.EmitFinally): Make this work for valuetypes. - -2004-08-03 Marek Safar - - * report.cs (Message): New enum for better error, warning reference in - the code. - (MessageData): New inner abstract class. It generally handles printing of - error and warning messages. - Removed unused Error, Warning, Message methods. - -2004-08-03 Marek Safar - - Fix for cs0592-8.cs test - * attribute.cs - (Attributable.ValidAttributeTargets): Made public. - (Attribute.ExplicitTarget): New member for explicit target value. - (Attribute.CheckTargets): Now we translate explicit attribute - target to Target here. - -2004-08-03 Ben Maurer - - * ecore.cs (MethodGroupExpr): new IsBase property. - - * expression.cs (BaseAccess): Set IsBase on MethodGroupExpr. - - * delegate.cs (DelegateCreation): store a MethodGroupExpr - rather than an instance expr. - - (DelegateCreation.Emit): Use the method group rather than - the instance expression. Also, if you have base.Foo as the - method for a delegate, make sure to emit ldftn, not ldftnvirt. - - (ResolveMethodGroupExpr): Use the MethodGroupExpr. - - (NewDelegate.DoResolve): Only check for the existance of Invoke - if the method is going to be needed. Use MethodGroupExpr. - - (NewDelegate.Emit): Remove, DelegateCreation implements this. - - * expression.cs: For pointer arith., make sure to use - the size of the type, not the size of the pointer to - the type. - -2004-08-03 Marek Safar - - Fix for #60722 - * class.cs (Class): Added error CS0502 test. - -2004-08-03 John Luke - Raja R Harinath - - Fix for #60997. - * attribute.cs (Attribute.complained_before): New flag. - (Attribute.ResolveType, Attribute.Resolve), - (Attribute.DefinePInvokeMethod): Set it. - (Attributes.Search): Pass 'complain' to Attribute.ResolveType. - -2004-08-03 Martin Baulig - - * expression.cs (Binary.ResolveOperator): Don't abort if we can't - use a user-defined operator; we still need to do numeric - promotions in case one argument is a builtin type and the other - one has an implicit conversion to that type. Fixes #62322. - -2004-08-02 Martin Baulig - - * statement.cs (LocalInfo.Flags): Added `IsThis'. - (LocalInfo.IsThis): New public property. - (Block.EmitMeta): Don't create a LocalBuilder for `this'. - -2004-08-01 Martin Baulig - - * class.cs (TypeContainer.GetClassBases): Don't set the default - here since we may get called from GetPartialBases(). - (TypeContainer.DefineType): If GetClassBases() didn't return a - parent, use the default one. - -2004-07-30 Duncan Mak - - * Makefile (mcs2.exe, mcs3.exe): add $(EXTRA_SOURCES). - -2004-07-30 Martin Baulig - - * Makefile (EXTRA_SOURCES): List the symbol writer's sources here. - - * class.cs (SourceMethod): New public class, derive from the - symbol writer's ISourceMethod. - (Method): Use the new symbol writer API. - - * codegen.cs (CodeGen.InitializeSymbolWriter): Take the filename - as argument and use the new symbol writer. - - * location.cs - (SourceFile): Implement the symbol writer's ISourceFile. - (Location.SymbolDocument): Removed. - (Location.SourceFile): New public property. - - * symbolwriter.cs: Use the new symbol writer API. - -2004-07-30 Raja R Harinath - - * Makefile (install-local): Remove. Functionality moved to - executable.make. - -2004-07-28 Lluis Sanchez Gual - - * Makefile: Install mcs.exe.config file together with mcs.exe. - * mcs.exe.config: Added supportedRuntime entry to make sure it runs in the - correct runtime version. - -2004-07-25 Martin Baulig - - * class.cs - (TypeContainer.RegisterOrder): Removed, this was unused. - (TypeContainer, interface_order): Removed. - (TypeContainer.AddClass, AddStruct, AddInterface): Take a - TypeContainer as argument since we can also be called with a - `PartialContainer' for a partial class/struct/interface. - (TypeContainer.IsInterface): Use `Kind == Kind.Interface' instead - of checking whether we're an `Interface' - we could be a - `PartialContainer'. - (PartialContainer.Register): Override; call - AddClass()/AddStruct()/AddInterface() on our parent. - - * cs-parser.jay (interface_member_declaration): Add things to the - `current_container', not the `current_class'. - - * rootcontext.cs (RegisterOrder): The overloaded version which - takes an `Interface' was unused, removed. - - * typemanager.cs (TypeManager.LookupInterface): Return a - `TypeContainer', not an `Interface'. - (TypeManager.IsInterfaceType): The `builder_to_declspace' may - contain a `PartialContainer' for an interface, so check it's - `Kind' to figure out what it is. - -2004-07-25 Martin Baulig - - * class.cs (Class.DefaultTypeAttributes): New public constant. - (Struct.DefaultTypeAttributes): Likewise. - (Interface.DefaultTypeAttributes): Likewise. - (PartialContainer.TypeAttr): Override this and add the - DefaultTypeAttributes. - -2004-07-25 Martin Baulig - - * decl.cs (DeclSpace.Emit): Removed the `TypeContainer' argument, - we can just use the `Parent' field instead. - -2004-07-25 Martin Baulig - - * class.cs (TypeContainer.Emit): Renamed to EmitType(). - -2004-07-25 Martin Baulig - - * class.cs (TypeContainer.DefineMembers): Call DefineMembers() on - our parts before defining any methods. - (TypeContainer.VerifyImplements): Make this virtual. - (ClassPart.VerifyImplements): Override and call VerifyImplements() - on our PartialContainer. - -2004-07-25 Martin Baulig - - * iterators.cs (Iterator.Define): Renamed to DefineIterator(). - - * decl.cs (DeclSpace.Define): Removed the `TypeContainer' - argument, we can just use the `Parent' field instead. - - * class.cs - (MemberBase.CheckBase): Removed the `TypeContainer' argument. - (MemberBase.DoDefine): Likewise. - -2004-07-24 Martin Baulig - - * decl.cs (MemberCore.Parent): New public field. - (DeclSpace.Parent): Moved to MemberCore. - - * class.cs (MethodCore.ds): Removed; use `Parent' instead. - (MemberBase.ctor): Added TypeContainer argument, pass it to our - parent's .ctor. - (FieldBase, Field, Operator): Likewise. - (EventProperty.ctor): Take a TypeContainer instead of a DeclSpace. - (EventField, Event): Likewise. - -2004-07-23 Martin Baulig - - * class.cs (PartialContainer): New public class. - (ClassPart): New public class. - (TypeContainer): Added support for partial classes. - (TypeContainer.GetClassBases): Splitted some of the functionality - out into GetNormalBases() and GetPartialBases(). - - * cs-tokenizer.cs (Token.PARTIAL): New token. - (Tokenizer.consume_identifier): Added some hacks to recognize - `partial', but only if it's immediately followed by `class', - `struct' or `interface'. - - * cs-parser.jay: Added support for partial clases. - -2004-07-23 Martin Baulig - - * class.cs (MethodCore.ds): Made this a `TypeContainer' instead of - a `DeclSpace' and also made it readonly. - (MethodCore.ctor): Take a TypeContainer instead of a DeclSpace. - (Method.ctor, Constructor.ctor, Destruktor.ctor): Likewise. - (PropertyBase.ctor, Property.ctor, Indexer.ctor): Likewise. - - * cs-parser.jay: Pass the `current_class', not the - `current_container' (at the moment, this is still the same thing) - to a new Method, Property, Event, Indexer or Constructor. - -2004-07-23 Martin Baulig - - * cs-parser.jay (CSharpParser): Added a new `current_class' field - and removed the `current_interface' one. - (struct_declaration, class_declaration, interface_declaration): - Set `current_class' to the newly created class/struct/interface; - set their `Bases' and call Register() before parsing their body. - -2004-07-23 Martin Baulig - - * class.cs (Kind): New public enum. - (TypeContainer): Made this class abstract. - (TypeContainer.Kind): New public readonly field. - (TypeContainer.CheckDef): New public method; moved here from - cs-parser.jay. - (TypeContainer.Register): New public abstract method. - (TypeContainer.GetPendingImplementations): New public abstract - method. - (TypeContainer.GetClassBases): Removed the `is_class' and - `is_iface' parameters. - (TypeContainer.DefineNestedTypes): Formerly known as - DoDefineType(). - (ClassOrStruct): Made this class abstract. - - * tree.cs (RootTypes): New public type. - -2004-07-20 Martin Baulig - - * tree.cs (Tree.RecordNamespace): Removed. - (Tree.Namespaces): Removed. - - * rootcontext.cs (RootContext.IsNamespace): Removed. - - * cs-parser.jay (namespace_declaration): Just create a new - NamespaceEntry here. - -2004-07-20 Martin Baulig - - * statement.cs (ExceptionStatement): New abstract class. This is - now used as a base class for everyone who's using `finally'. - (Using.ResolveLocalVariableDecls): Actually ResolveLValue() all - our local variables before using them. - - * flowanalysis.cs (FlowBranching.StealFinallyClauses): New public - virtual method. This is used by Yield.Resolve() to "steal" an - outer block's `finally' clauses. - (FlowBranchingException): The .ctor now takes an ExceptionStatement - argument. - - * codegen.cs (EmitContext.StartFlowBranching): Added overloaded - version which takes an ExceptionStatement. This version must be - used to create exception branchings. - - * iterator.cs - (Yield.Resolve): "Steal" all `finally' clauses from containing blocks. - (Iterator.EmitMoveNext): Added exception support; protect the - block with a `fault' clause, properly handle 'finally' clauses. - (Iterator.EmitDispose): Run all the `finally' clauses here. - -2004-07-20 Martin Baulig - - * iterator.cs: This is the first of a set of changes in the - iterator code. Match the spec more closely: if we're an - IEnumerable, then GetEnumerator() must be called. The first time - GetEnumerator() is called, it returns the current instance; all - subsequent invocations (if any) must create a copy. - -2004-07-19 Miguel de Icaza - - * expression.cs: Resolve the constant expression before returning - it. - -2004-07-19 Martin Baulig - - * iterators.cs (Iterator.MapVariable): Don't define fields twice. - (Iterator.MoveNextMethod.DoEmit): Use `TypeManager.int32_type' as - the return type of the new EmitContext. - -2004-07-18 Martin Baulig - - * class.cs (Property.Define): Fix iterators. - - * iterators.cs (Iterator.Define): Moved the - `container.AddInterator (this)' call here from the .ctor; only do - it if we resolved successfully. - -2004-07-17 Miguel de Icaza - - * cs-tokenizer.cs (handle_preprocessing_directive): Do not return - `true' for preprocessing directives that we parse. The return - value indicates whether we should return to regular tokenizing or - not, not whether it was parsed successfully. - - In the past if we were in: #if false ... #line #endif, we would - resume parsing after `#line'. See bug 61604. - - * typemanager.cs: Removed an old hack from Gonzalo to get corlib - building: IsEnumType should return true only for enums, not for - enums or System.Enum itself. This fixes #61593. - - Likely what happened is that corlib was wrong: mcs depended on - this bug in some places. The bug got fixed, we had to add the - hack, which caused bug 61593. - - * expression.cs (ArrayAccess.GetStoreOpCode): Remove an old hack - that was a workaround for the older conditions. - -2004-07-16 Ben Maurer - - * assign.cs: IAssignMethod has a new interface, as documented - inline. All assignment code now uses this new api. - - * ecore.cs, expression.cs: All classes which implement - IAssignMethod now use the new interface. - - * expression.cs (Invocation): add a hack to EmitCall so that - IndexerAccess can be the target of a compound assignment without - evaluating its arguments twice. - - * statement.cs: Handle changes in Invocation api. - -2004-07-16 Martin Baulig - - * iterators.cs: Rewrote this. We're now using one single Proxy - class for both the IEnumerable and the IEnumerator interface and - `Iterator' derives from Class so we can use the high-level API. - - * class.cs (TypeContainer.AddIterator): New method. - (TypeContainer.DoDefineType): New protected virtual method, which - is called from DefineType(). - (TypeContainer.DoDefineMembers): Call DefineType() and - DefineMembers() on all our iterators. - (TypeContainer.Emit): Call Emit() on all our iterators. - (TypeContainer.CloseType): Call CloseType() on all our iterators. - - * codegen.cs (EmitContext.CurrentIterator): New public field. - -2004-07-15 Martin Baulig - - * typemanager.cs - (TypeManager.not_supported_exception_type): New type. - -2004-07-14 Martin Baulig - - * iterators.cs: Use real error numbers. - -2004-07-14 Martin Baulig - - * iterator.cs (IteratorHandle.IsIEnumerable): The spec explicitly - requires this to be a System.Collection.IEnumerable and not a - class implementing that interface. - (IteratorHandle.IsIEnumerator): Likewise, for IEnumerator. - -2004-07-13 Marek Safar - - * class.cs: Fixed previous fix, it broke some error tests. - -2004-07-12 Martin Baulig - - * enum.cs (Enum.Define): Call Emit() to emit the attributes. - Fixes #61293. - -2004-07-09 Miguel de Icaza - - * assign.cs (LocalTemporary): Add new argument: is_address,If - `is_address' is true, then the value that we store is the address - to the real value, and not the value itself. - - * ecore.cs (PropertyExpr): use the new local temporary - stuff to allow us to handle X.Y += z (where X is a struct) - -2004-07-08 Martin Baulig - - * statement.cs (Lock.Resolve): Set ec.NeedReturnLabel() if we do - not always return, just like we're doing in Using.Resolve(). - -2004-07-07 Miguel de Icaza - - * cs-parser.jay (fixed_statement): flag this as Pinned. - -2004-07-06 Miguel de Icaza - - * typemanager.cs (TypeManager): Removed MakePinned method, this - mechanism is replaced with the .NET 2.x compatible mechanism of - calling `ILGenerator.DeclareLocal (Type t, bool pinned)'. - - * statement.cs (LocalInfo): Remove MakePinned, add Pinned property - Rename `Fixed' to `Pinned' as a flag, to distinguish from the - `IsFixed' property which has a different meaning. - -2004-07-02 Raja R Harinath - - * ecore.cs (DoSimpleNameResolve): Expand CS0038 check to all names - visible from inside a nested class, not just the names of the - immediately enclosing class. - Fix for bug #60730. - -2004-06-24 Raja R Harinath - - * expression.cs (BetterConversion): Remove buggy special-case - handling of "implicit constant expression conversions". At this - point, we already know that the conversion is possible -- we're - only checking to see which is better. - -2004-06-24 Marek Safar - - * cs-parser.jay: Added error CS0210 test. - -2004-06-24 Marek Safar - - * cs-parser.jay: Added error CS0134 test. - -2004-06-24 Marek Safar - - Fix bug #52507 - * cs-parser.jay: Added error CS0145 test. - -2004-06-24 Marek Safar - - * class.cs (Operator.Define): Added test for errors CS0553, CS0554. - -2004-06-23 Ben Maurer - - * expression.cs (StackAlloc.Resolve): The argument may not - be a constant; deal with this case. - -2004-06-23 Marek Safar - - * attribute.cs (IndexerName_GetIndexerName): Renamed to - GetIndexerAttributeValue. - (ScanForIndexerName): Renamed to GetIndexerNameAttribute. - - * class.cs (Indexer.Define): Added error tests for CS0415, - CS0609. - -2004-06-23 Miguel de Icaza - - * attribute.cs (Attribute.Resolve): Keep field code in sync with - property code. - -2004-06-23 Martin Baulig - - * flowanalysis.cs (UsageVector.MergeChild): If we're a loop and we - neither return nor throw, reset the barrier as well. Fixes #60457. - -2004-06-22 Atsushi Enomoto - - * class.cs : EventAttributes is now set to None by default. - This fixes bug #60459. - -2004-06-18 Marek Safar - - Fix bug #60219 - * class.cs (ConstructorInitializer.GetOverloadedConstructor): - Don't throw exception but return null (it's sufficient now). - -2004-06-18 Marek Safar - - * typemanager.cs (GetArgumentTypes): Faster implementation. - -2004-06-18 Martin Baulig - - * attribute.cs (Attribute.Resolve): Check whether we're an - EmptyCast which a Constant child. Fixes #60333. - -2004-06-17 Ben Maurer - - * statement.cs (EmitCollectionForeach): Account for the fact that - not all valuetypes are in areas which we can take the address of. - For these variables, we store to a temporary variable. Also, make - sure that we dont emit a `callvirt' on a valuetype method. - -2004-06-15 Marek Safar - - * expression.cs (StackAlloc.DoReSolve): Added test for - negative parameter (CS0247). - -2004-06-15 Marek Safar - - Fix bug #59792 - * class.cs: (Event.DelegateMethod.Emit): Added synchronization flag. - -2004-06-15 Marek Safar - - Fix bug #59781 - * expression.cs: (Binary.DoNumericPromotions): Added conversion for - ulong. - -2004-06-14 Marek Safar - - Fix bug #58254 & cs1555.cs, cs1556.cs - * driver.cs (MainDriver): Added tests for errors CS1555, CS1556. - -2004-06-14 Marek Safar - - * cs-parser.jay: Added error CS1669 test for indexers. - -2004-06-11 Martin Baulig - - * expression.cs (Invocation.IsParamsMethodApplicable): We need to - call this twice: for params and varargs methods. - -2004-06-11 Marek Safar - - * class.cs: - (FieldBase.DoDefine, PropertyBase.DoDefine): Added error test CS0610. - -2004-06-11 Marek Safar - - * attribute.cs (Attribute.GetValidTargets): Made public. - - * class.cs: - (AbstractPropertyEventMethod): New class for better code sharing. - (AbstractPropertyEventMethod.ApplyAttributeBuilder): Add error - CS1667 report. - (PropertyMethod, DelegateMethod): Derived from AbstractPropertyEventMethod - -2004-06-11 Raja R Harinath - - Fix bug #59477. - * ecore.cs (ResolveFlags): Add new 'Intermediate' flag to tell - that the call to Resolve is part of a MemberAccess. - (Expression.Resolve): Use it for SimpleName resolution. - (SimpleName.SimpleNameResolve, SimpleName.DoResolveAllowStatic): - Add 'intermediate' boolean argument. - (SimpleName.DoSimpleNameResolve): Likewise. Use it to disable an - error message when the SimpleName can be resolved ambiguously - between an expression and a type. - * expression.cs (MemberAccess.IdenticalNameAndTypeName): Make - public. - (MemberAccess.Resolve): Pass 'Intermediate' flag to the Resolve() - call on the left-side. - -2004-06-11 Marek Safar - - * class.cs: - (MethodCore.VerifyClsCompliance): Added test for error CS3000. - -2004-06-11 Marek Safar - - * attribute.cs (Attribute.Emit): Fixed error CS0579 reporting. - -2004-06-11 Martin Baulig - - * expression.cs (Invocation.EmitCall): Use OpCodes.Callvirt for - varargs methods if applicable. - -2004-06-11 Martin Baulig - - * expression.cs (Invocation.EmitCall): Don't use - `method.CallingConvention == CallingConventions.VarArgs' since the - method could also have `CallingConventions.HasThis'. - -2004-06-11 Marek Safar - - * class.cs (Event.GetSignatureForError): Implemented. - Fixed crash in error test cs3010.cs - -2004-06-10 Miguel de Icaza - - * cs-tokenizer.cs: Change the way we track __arglist to be - consistent with the other keywords. - -2004-06-09 Miguel de Icaza - - * codegen.cs: FAQ avoider: turn 1577 into a warning for now until - tomorrow. - -2004-06-09 Sebastien Pouliot - - * codegen.cs: Check that all referenced assemblies have a strongname - before strongnaming the compiled assembly. If not report error CS1577. - Fix bug #56563. Patch by Jackson Harper. - * typemanager.cs: Added a method to return all referenced assemblies. - Fix bug #56563. Patch by Jackson Harper. - -2004-06-08 Marek Safar - - * class.cs: - (Method.ApplyAttributeBuilder): Moved and added conditional - attribute error tests (CS0577, CS0578, CS0243, CS0582, CS0629). - - * delegate.cs: - (DelegateCreation.ResolveMethodGroupExpr): Added error CS1618 test. - -2004-06-08 Marek Safar - - Fixed #59640 - * class.cs: (EventField.attribute_targets): Changed default target. - -2004-06-08 Martin Baulig - - * expression.cs (Invocation.EmitCall): Enable varargs methods. - -2004-06-08 Martin Baulig - - * rootcontext.cs (ResolveCore): Added "System.RuntimeArgumentHandle". - -2004-06-07 Martin Baulig - - Added support for varargs methods. - - * cs-tokenizer.cs (Token.ARGLIST): New token for the `__arglist' - keyword. - - * cs-parser.jay: Added support for `__arglist'. - - * decl.cs (MemberCache.AddMethods): Don't ignore varargs methods. - - * expression.cs (Argument.AType): Added `ArgList'. - (Invocation): Added support for varargs methods. - (ArglistAccess): New public class. - (Arglist): New public class. - - * parameter.cs (Parameter.Modifier): Added `ARGLIST'. - - * statement.cs (Block.Flags): Added `HasVarargs'. We set this on - a method's top-level block if the method has varargs. - - * support.cs (ReflectionParameters, InternalParameters): Added - support for varargs methods. - -2004-06-07 Miguel de Icaza - - * class.cs: Provide location in indexer error report. - - * driver.cs: Use standard names. - - * namespace.cs: Catch the use of using after a namespace has been - declared also on using aliases. - -2004-06-03 Raja R Harinath - - Bug #50820. - * typemanager.cs (closure_private_ok, closure_invocation_type) - (closure_qualifier_type, closure_invocation_assembly) - (FilterWithClosure): Move to ... - (Closure): New internal nested class. - (Closure.CheckValidFamilyAccess): Split out from Closure.Filter. - (MemberLookup, RealMemberLookup): Add new almost_match parameter. - * ecore.cs (almostMatchedMembers): New variable to help report CS1540. - (MemberLookup, MemberLookupFailed): Use it. - * expression.cs (New.DoResolve): Treat the lookup for the - constructor as being qualified by the 'new'ed type. - (Indexers.GetIndexersForTypeOrInterface): Update. - -2004-06-03 Marek Safar - - * attribute.cs - (GetConditionalAttributeValue): New method. Returns - condition of ConditionalAttribute. - (SearchMulti): New method. Returns all attributes of type 't'. - Use it when attribute is AllowMultiple = true. - (IsConditionalMethodExcluded): New method. - - * class.cs - (Method.IsExcluded): Implemented. Returns true if method has conditional - attribute and the conditions is not defined (method is excluded). - (IMethodData): Extended interface for ConditionalAttribute support. - (PropertyMethod.IsExcluded): Implemented. - - * decl.cs - (MemberCore.Flags): Excluded_Undetected, Excluded new caching flags. - - * expression.cs - (Invocation.IsMethodExcluded): Checks the ConditionalAttribute - on the method. - -2004-06-02 Ben Maurer - - * expression.cs (ArrayCreationExpression): Make this just an - `expression'. It can't be a statement, so the code here was - dead. - -2004-06-02 Marek Safar - - Fixed #59072 - * typemanager.cs (GetFullNameSignature): New method for - MethodBase types. - -2004-06-02 Marek Safar - - Fixed #56452 - * class.cs (MemberBase.GetSignatureForError): New virtual method. - Use this method when MethodBuilder is null. - (MethodData.DefineMethodBuilder): Encapsulated code to the new method. - Added test for error CS0626 (MONO reports error for this situation). - (IMethodData.GetSignatureForError): Extended interface. - -2004-06-01 Marek Safar - - * attribute.cs - (AttributeTester.GetObsoleteAttribute): Returns instance of - ObsoleteAttribute when type is obsolete. - - * class.cs - (TypeContainer.VerifyObsoleteAttribute): Override. - (Method.GetSignatureForError): New method for usage when MethodBuilder is null. - (MethodCode.VerifyObsoleteAttribute): Override. - (MemberBase.VerifyObsoleteAttribute): Override. - - * decl.cs - (MemberCore.CheckUsageOfObsoleteAttribute): Tests presence of ObsoleteAttribute - and report proper error. - - *delegate.cs - Delegate.VerifyObsoleteAttribute): Override. - - * ecore.cs - (Expression.CheckObsoleteAttribute): Tests presence of ObsoleteAttribute - and report proper error. - (FieldExpr.DoResolve): Added tests for ObsoleteAttribute. - - * enum.cs - (Enum.GetObsoleteAttribute): Returns ObsoleteAttribute for both enum type - and enum member. - - * expression.cs - (Probe.DoResolve, Cast.DoResolve, LocalVariableReference.DoResolve, - New.DoResolve, SizeOf.DoResolve, TypeOf.DoResolce, MemberAccess.DoResolve): - Added test for ObsoleteAttribute. - - * statement.cs - (Catch): Derived from Statement. - -2004-06-01 Marek Safar - - Fixed bug #59071 & cs0160.cs - - * statement.cs (Try.Resolve): Check here whether order of catch - clauses matches their dependencies. - -2004-05-31 Miguel de Icaza - - * Reverted patch to namespace.cs (Use lookuptypedirect). This - caused a regression: #59343. Referencing nested classes from an - assembly stopped working. - -2004-05-31 Martin Baulig - - MCS is now frozen for beta 2. - -2004-05-30 Ben Maurer - - * convert.cs: add a trivial cache for overload operator resolution. - -2004-05-30 Ben Maurer - - * decl.cs: If possible, use lookuptypedirect here. We can only do - this if there is no `.' after the namespace. Avoids using - LookupType, which does lots of slow processing. - (FindNestedType) New method, does what it says :-). - * namespace.cs: use LookupTypeDirect. - * rootcontext.cs: use membercache, if possible. - * typemanager.cs (LookupTypeDirect): Cache negative hits too. - -2004-05-30 Ben Maurer - - * expression.cs: - According to the spec, - - In a member access of the form E.I, if E is a single identifier, - and if the meaning of E as a simple-name (§7.5.2) is a constant, - field, property, localvariable, or parameter with the same type as - the meaning of E as a type-name (§3.8), then both possible - meanings of E are permitted. - - We did not check that E as a simple-name had the same type as E as - a type name. - - This trivial check gives us 5-7% on bootstrap time. - -2004-05-30 Ben Maurer - - * expression.cs (Invocation.OverloadResolve): Avoid the - use of hashtables and boxing here by allocating on demand. - -2004-05-30 Martin Baulig - - * rootcontext.cs (RootContext.LookupType): Don't cache things if - we're doing a silent lookup. Don't try to lookup nested types in - TypeManager.object_type (thanks to Ben Maurer). - -2004-05-30 Martin Baulig - - Committing a patch from Ben Maurer. - - * rootcontext.cs (RootContext.LookupType): Cache negative results. - -2004-05-29 Martin Baulig - - * class.cs (IMethodData.ShouldIgnore): New method. - - * typemanager.cs (TypeManager.MethodFlags): Don't take a - `Location' argument, we don't need it anywhere. Use - `IMethodData.ShouldIgnore ()' instead of - `MethodData.GetMethodFlags ()'. - (TypeManager.AddMethod): Removed. - (TypeManager.AddMethod2): Renamed to AddMethod. - -2004-05-29 Martin Baulig - - Committing a patch from Benjamin Jemlich . - - * convert.cs (Convert.ImplicitReferenceConversion): If we're - converting from a class type S to an interface type and we already - have an object on the stack, don't box it again. Fixes #52578. - -2004-05-29 Martin Baulig - - * class.cs (ConstructorInitializer.GetOverloadedConstructor): - Added support for `params' parameters. Fixes #59267. - -2004-05-29 Martin Baulig - - * literal.cs (NullPointer): Provide a private .ctor which sets - `type' to TypeManager.object_type. Fixes #59048. - -2004-05-29 Martin Baulig - - * expression.cs (MemberAccess.ResolveMemberAccess): If we're an - EventExpr, set `ee.InstanceExpression = left'. Fixes #59188. - - * ecore.cs (EventExpr.instance_expr): Make the field private. - -2004-05-26 Marek Safar - - Fixed bug #50080 & cs0214-2.cs - * expression.cs (Cast.DoResolve): Check unsafe context here. - - * statement.cs (Resolve.DoResolve): Likewise. - -2004-05-26 Martin Baulig - - * namespace.cs (NamespaceEntry.Lookup): Added `bool silent'. - - * rootcontext.cs (RootContext.NamespaceLookup): Added `bool silent'. - (RootContext.LookupType): Pass down the `silent' flag. - -2004-05-25 Martin Baulig - - * expression.cs - (MethodGroupExpr.IdenticalTypeName): New public property. - (Invocation.DoResolve): Don't report a CS0176 if the "instance" - expression actually refers to a type. - -2004-05-25 Martin Baulig - - * expression.cs (Invocation.DoResolve): Applied Ben Maurer's patch - for #56176 and made it actually work. - -2004-05-25 Martin Baulig - - * ecore.cs (Expression.CacheTemporaries): Make this virtual. - (FieldExpr, PropertyExpr): Override and implement - CacheTemporaries. Fixes #52279. - -2004-05-25 Miguel de Icaza - - * location.cs: In the new compiler listing a file twice is a - warning, not an error. - -2004-05-24 Martin Baulig - - * enum.cs (Enum.DefineType): For the `BaseType' to be a - TypeLookupExpression; otherwise, report a CS1008. Fixes #58571. - -2004-05-24 Martin Baulig - - * decl.cs (DeclSpace.FindType): Try doing an alias lookup before - walking the `using' list. Fixes #53921. - -2004-05-24 Martin Baulig - - * const.cs (Const.LookupConstantValue): Added support for - EmptyCast's; fixes #55251. - -2004-05-24 Martin Baulig - - * ecore.cs (SimpleName.SimpleNameResolve): Renamed to - DoSimpleNameResolve() and provide a SimpleNameResolve() wrapper - which does the CS0135 check. The reason is that we first need to - check whether the variable actually exists. - -2004-05-24 Martin Baulig - - * class.cs (MemberBase.DoDefine): Use DeclSpace.FindType() rather - than RootContext.LookupType() to find the explicit interface - type. Fixes #58584. - -2004-05-24 Raja R Harinath - - * Makefile: Simplify. Use executable.make. - * mcs.exe.sources: New file. List of sources of mcs.exe. - -2004-05-24 Anders Carlsson - - * decl.cs: - * enum.cs: - Use the invariant culture when doing String.Compare for CLS case - sensitivity. - -2004-05-23 Martin Baulig - - * decl.cs (DeclSpace.FindType): Only check the `using' list if we - don't have any dots. Fixes #52622, added cs0246-8.cs. - - * namespace.cs (NamespaceEntry.Lookup): Likewise. - -2004-05-23 Marek Safar - - * class.cs (MemberBase.Define): Reuse MemberType member for - resolved type. Other methods can use it too. - -2004-05-23 Martin Baulig - - * ecore.cs (SimpleName.SimpleNameResolve): Only report a CS0135 if - the variable also exists in the current block (otherwise, we need - to report a CS0103). Fixes #58670. - -2004-05-23 Martin Baulig - - * flowanalysis.cs (Reachability.Reachable): Compute this - on-the-fly rather than storing it as a field. - -2004-05-23 Martin Baulig - - * flowanalysis.cs (Reachability.And): Manually compute the - resulting `barrier' from the reachability. - -2004-05-23 Marek Safar - - Fix bug #57835 - * attribute.cs (AttributeTester.GetMethodObsoleteAttribute): Returns - instance of ObsoleteAttribute when symbol is obsolete. - - * class.cs - (IMethodData): Extended interface for ObsoleteAttribute support. - -2004-05-22 Marek Safar - - * attribute.cs: Fix bug #55970 - -2004-05-22 Marek Safar - - Fix bug #52705 - * attribute.cs - (GetObsoleteAttribute): New method. Creates the instance of - ObsoleteAttribute. - (AttributeTester.GetMemberObsoleteAttribute): Returns instance of - ObsoleteAttribute when member is obsolete. - (AttributeTester.Report_ObsoleteMessage): Common method for - Obsolete error/warning reporting. - - * class.cs - (TypeContainer.base_classs_type): New member for storing parent type. - - * decl.cs - (MemberCore.GetObsoleteAttribute): Returns instance of ObsoleteAttribute - for this MemberCore. - -2004-05-21 Marek Safar - - * attribute.cs, const.cs: Fix bug #58590 - -2004-05-21 Martin Baulig - - * flowanalysis.cs (FlowBranching.MergeTopBlock): Don't check for - out parameters if the end of the method is unreachable. Fixes - #58098. - -2004-05-21 Marek Safar - - * codegen.cs, cs-parser.jay: Removed SetAttributes method. - Hari was right, why extra method. - -2004-05-21 Marek Safar - - * attribute.cs, cs-parser.jay: Fix errors/cs0579-7.cs. - -2004-05-20 Martin Baulig - - Merged this back from gmcs to keep the differences to a minumum. - - * attribute.cs (Attribute.CheckAttributeType): Take an EmitContext - instead of a Declspace. - (Attribute.ResolveType): Likewise. - (Attributes.Search): Likewise. - (Attributes.Contains): Likewise. - (Attributes.GetClsCompliantAttribute): Likewise. - - * class.cs (TypeContainer.VerifyMembers): Added EmitContext - argument. - (MethodData.ApplyAttributes): Take an EmitContext instead of a - DeclSpace. - -2004-05-19 Marek Safar - - Fix bug #58688 (MCS does not report error when the same attribute - is assigned twice) - - * attribute.cs (Attribute.Emit): Distinction between null and default. - -2004-05-19 Raja R Harinath - - * cs-parser.jay (attribute): Create a GlobalAttribute for the case - of a top-level attribute without an attribute target. - * attribute.cs (Attribute.Error_AttributeConstructorMismatch): - Make non-static. - (Attribute.Conditional_GetConditionName), - (Attribute.Obsolete_GetObsoleteMessage): Update. - (Attribute.IndexerName_GetIndexerName): New. Attribute-specific - part of ScanForIndexerName. - (Attribute.CanIgnoreInvalidAttribute): New function. - (Attribute.ScanForIndexerName): Move to ... - (Attributes.ScanForIndexerName): ... here. - (Attributes.Attrs): Rename from now-misnamed AttributeSections. - (Attributes.Search): New internal variant that can choose not to - complain if types aren't resolved. The original signature now - complains. - (Attributes.GetClsCompliantAttribute): Use internal variant, with - complaints suppressed. - (GlobalAttribute.CheckAttributeType): Overwrite ds.NamespaceEntry - only if it not useful. - (CanIgnoreInvalidAttribute): Ignore assembly attribute errors at - top-level for attributes that are shared between the assembly - and a top-level class. - * parameter.cs (ImplicitParameter): Rename from ParameterAtribute. - * class.cs: Update to reflect changes. - (DefineIndexers): Fuse loops. - * codegen.cs (GetAssemblyName): Update to reflect changes. Accept - a couple more variants of attribute names. - -2004-05-18 Marek Safar - - Fix bug #52585 (Implemented explicit attribute declaration) - - * attribute.cs: - (Attributable.ValidAttributeTargets): New abstract method. It gets - list of valid attribute targets for explicit target declaration. - (Attribute.Target): It holds target itself. - (AttributeSection): Removed. - (Attribute.CheckTargets): New method. It checks whether attribute - target is valid for the current element. - - * class.cs: - (EventProperty): New class. For events that are declared like - property (with add and remove accessors). - (EventField): New class. For events that are declared like field. - class.cs - - * cs-parser.jay: Implemented explicit attribute target declaration. - - * class.cs, decl.cs, delegate.cs, enum.cs, parameter.cs: - Override ValidAttributeTargets. - - * parameter.cs: - (ReturnParameter): Class for applying custom attributes on - the return type. - (ParameterAtribute): New class. Class for applying custom - attributes on the parameter type. - -2004-05-17 Miguel de Icaza - - * class.cs (MemberBase.DoDefine): Pass UNSAFE on interface - definitions. - - (Method): Allow UNSAFE here. - - * modifiers.cs: Support unsafe reporting. - -2004-05-17 Marek Safar - - * decl.cs: Fix bug #58478. - -2004-05-17 Gonzalo Paniagua Javier - - * statement.cs: When checking for unreachable code on an EmptyStatement, - set the location. Fixes bug #58488. - -2004-05-13 Miguel de Icaza - - * driver.cs: Add -pkg handling. - - From Gonzalo: UseShelLExecute=false - -2004-05-12 Marek Safar - - * attribute.cs: - (Attribute.GetAttributeTargets): New method. Gets AttributeTargets - for attribute. - (Attribute.IsClsCompliaceRequired): Moved to base for better - accesibility. - (Attribute.UsageAttribute): New property for AttributeUsageAttribute - when attribute is AttributeUsageAttribute. - (Attribute.GetValidTargets): Simplified. - (Attribute.GetAttributeUsage): New method returns AttributeUsage - attribute for this type. - (Attribute.ApplyAttributes): Method renamed to Emit and make - non-static. - (GlobalAttributeSection): New class for special handling of global - attributes (assembly, module). - (AttributeSection.Emit): New method. - - * class.cs: Implemented Attributable abstract methods. - (MethodCore.LabelParameters): Moved to Parameter class. - (Accessor): Is back simple class. - (PropertyMethod): Implemented Attributable abstract class. - (DelegateMethod): Implemented Attributable abstract class. - (Event): New constructor for disctintion between normal Event - and Event with accessors. - - * cs-parser.jay: Used new Event ctor and GlobalAttributeSection. - - * codegen.cs, const.cs, decl.cs, delegate.cs: - (CommonAssemblyModulClass): Implemented Attributable abstract class - and simplified. - - * enum.cs: Implement IAttributeSupport interface. - (EnumMember): New class for emum members. Implemented Attributable - abstract class - - * parameter.cs: - (ParameterBase): Is abstract. - (ReturnParameter): New class for easier [return:] attribute handling. - - * typemanager.cs: Removed builder_to_attr. - -2004-05-11 Raja R Harinath - - Fix bug #57151. - * attribute.cs (Attribute.GetPositionalValue): New function. - * class.cs (TypeContainer.VerifyMembers): New function. - (TypeContainer.Emit): Use it. - (ClassOrStruct): New base class for Class and Struct. - (ClassOrStruct.ApplyAttributeBuilder): New function. Note if - StructLayout(LayoutKind.Explicit) was ascribed to the struct or - class. - (ClassOrStruct.VerifyMembers): If the struct is explicitly laid out, - then each non-static field should have a FieldOffset attribute. - Otherwise, none of the fields should have a FieldOffset attribute. - * rootcontext.cs (RootContext.ResolveCore): Resolve StructLayout - and FieldOffset attributes. - * typemanager.cs (TypeManager.struct_layout_attribute_type) - (TypeManager.field_offset_attribute_type): New core types. - (TypeManager.InitCoreTypes): Initialize them. - -2004-05-11 Michal Moskal - - * class.cs (Event.RemoveDelegateMethod.DelegateMethodInfo): - Return correct type. - From bug #58270. - -2004-05-09 Miguel de Icaza - - * expression.cs (Binary.DoNumericPromotions): 0 long constant can - be implicitly converted to ulong. - - * expression.cs: The logic for allowing operator &, | and ^ worked - was wrong, it worked before because we did not report an error in - an else branch. Fixes 57895. - - * class.cs: Applied patch from iain@mccoy.id.au Iain McCoy to - allow volatile fields to be reference types. - -2004-05-07 Miguel de Icaza - - * driver.cs: Add support for /debug- - -2004-05-07 Raja R Harinath - - * attribute.cs (Attribute.CheckAttributeType, Attribute.ResolveType): - Add a 'complain' parameter to silence errors. - (Attribute.Resolve): Update to changes. Put in sanity check to catch - silently overlooked type-resolutions. - (Attribute.ScanForIndexerName, Attribute.DefinePInvokeMethod): Update - to reflect changes. - (Attributes.Search): New function. - (Attributes.Contains, Attributes.GetClsCompliantAttribute): Use Search. - (Attributes.GetAttributeFullName): Remove hack. - * class.cs (MethodCore.LabelParameters, MethodData.ApplyAttributes): - Update to reflect changes. - * codegen.cs (CommonAssemblyModulClass.GetClsCompliantAttribute): - Use Attributes.Search instead of nested loops. - -2004-05-07 Marek Safar - - * decl.cs: - (MemberCore.Flags): Extended for caching presence of CLSCompliantAttribute. - (MemberCore.VerifyClsCompliance): Implemented CS3019 error report. - (DeclSpace.GetClsCompliantAttributeValue): Returns simple bool. - - * report.cs: (Report.Warning): Renamed to Warning_T because of - parameter collision. - -2004-05-05 Raja R Harinath - - * expression.cs (MemberAccess.ResolveMemberAccess): - Exit with non-zero status after Report.Error. - * rootcontext.cs (RootContext.BootstrapCorlib_ResolveDelegate): - Likewise. - * typemanager.cs (TypeManager.CoreLookupType): Likewise. - -2004-05-04 Lluis Sanchez Gual - - * support.cs: Don't hang when the file is empty. - -2004-05-04 Lluis Sanchez Gual - - * support.cs: In SeekableStreamReader, compute the preamble size of the - underlying stream. Position changes should take into account that initial - count of bytes. - -2004-05-03 Todd Berman - - * driver.cs: remove unused GetSysVersion function. - -2004-05-03 Todd Berman - - * driver.cs: Remove the hack from saturday, as well as the hack - from jackson (LoadAssemblyFromGac), also adds the CWD to the - link_paths to get that bit proper. - -2004-05-01 Todd Berman - - * driver.cs: Try a LoadFrom before a Load, this checks the current - path. This is currently a bug in mono that is be fixed, however, this - provides a workaround for now. This will be removed when the bug - is fixed. - -2004-05-01 Sebastien Pouliot - - * CryptoConvert.cs: Updated to latest version. Fix issue with - incomplete key pairs (#57941). - -2004-05-01 Todd Berman - - * driver.cs: Remove '.' from path_chars, now System.* loads properly - from the GAC - -2004-04-30 Jackson Harper - - * codegen.cs: Open keys readonly. - -2004-04-30 Gonzalo Paniagua Javier - - * typemanager.cs: don't report cyclic struct layout when a struct - contains 2 or more fields of the same type. Failed for Pango.AttrShape - which has 2 Pango.Rectangle fields. - -2004-04-29 Ben Maurer - - * expression.cs: Handle IntPtr comparisons with IL code - rather than a method call. - -2004-04-29 Martin Baulig - - * ecore.cs (PropertyExpr.FindAccessor): New private method. Walk - the list of PropertyInfo's in class hierarchy and find the - accessor. Fixes #56013. - -2004-04-29 Martin Baulig - - * typemanager.cs (TypeManager.CheckStructCycles): Fixed. - -2004-04-29 Martin Baulig - - Applying a patch from Benjamin Jemlich . - - * ecore.cs (FieldExpr.AddressOf): Make this work for valuetypes. - -2004-04-29 Martin Baulig - - * class.cs (ConstructorInitializer.Resolve): Check whether the - parent .ctor is accessible. Fixes #52146. - -2004-04-29 Martin Baulig - - Applying a patch from Benjamin Jemlich . - - * statement.cs (Using.EmitLocalVariableDecls): Use - TypeManager.idisposable_type, not typeof (IDisposable). - (Foreach.EmitCollectionForeach): Added support for valuetypes. - -2004-04-29 Martin Baulig - - * class.cs (Event.Define): Don't emit the field and don't set - RTSpecialName and SpecialName for events on interfaces. Fixes - #57703. - -2004-04-29 Raja R Harinath - - Refactor Attribute.ApplyAttributes. - * attribute.cs (Attributable): New base class for objects that can - have Attributes applied on them. - (Attribute): Make AttributeUsage fields public. - (Attribute.GetFieldValue, Attribute.GetMarshal): Make non-static. - (Attribute.IsInternalCall): New property. - (Attribute.UsageAttr): Convert to a public read-only property. - (Attribute.CheckAttributeType): Use a DeclSpace, not an EmitContext. - (Attribute.ResolveType, Attribute.Resolve) - (Attribute.ScanForIndexerName): Update to reflect changes. - (Attribute.CheckAttributeTarget): Re-format. - (Attribute.ApplyAttributes): Refactor, to various - Attributable.ApplyAttributeBuilder methods. - * decl.cs (MemberCore): Make Attributable. - * class.cs (Accessor): Make Attributable. - (MethodData.ApplyAttributes): Use proper attribute types, not - attribute names. - (TypeContainer.LabelParameters): Pass Parameter to ApplyAttributes. - (TypeContainer.ApplyAttributeBuilder) - (Method.ApplyAttributeBuilder, Constructor.ApplyAttributeBuilder) - (Field.ApplyAttributeBuilder, Accessor.ApplyAttributeBuilder) - (PropertyBase.ApplyAttributeBuilder, Event.ApplyAttributeBuilder) - (Operator.ApplyAttributeBuilder): New factored-out methods. - * const.cs (Const.ApplyAttributeBuilder): Likewise. - * delegate.cs (Delegate.ApplyAttributeBuilder): Likewise. - * enum.cs (Enum.ApplyAttributeBuilder): Likewise. - * parameter.cs (ParameterBase): New Attributable base class - that can also represent Return types. - (Parameter): Update to the changes. - -2004-04-29 Jackson Harper - - * driver.cs: Prefer the corlib system version when looking for - assemblies in the GAC. This is still a hack, but its a better hack - now. - -2004-04-29 Marek Safar - - * decl.cs, enum.cs: Improved error 3005 reporting. - - * report.cs (SymbolRelatedToPreviousError): New method for error reporting. - (related_symbols): New private member for list of symbols - related to reported error/warning. - - * tree.cs: Do not use now obsolete Report.LocationOfPreviousError. - -2004-04-29 Martin Baulig - - * ecore.cs (Expression.Constantify): If we're an enum and - TypeManager.TypeToCoreType() doesn't give us another type, use - t.UnderlyingSystemType. Fixes #56178. - -2004-04-29 Martin Baulig - - * decl.cs (MemberCache.SetupCacheForInterface): Look over all our - interfaces and for each interface, only add members directly - declared in that interface. Fixes #53255. - -2004-04-28 Martin Baulig - - * expression.cs (ConditionalLogicalOperator): Use a temporary - variable for `left' to avoid that we evaluate it more than once; - bug #52588. - -2004-04-28 Martin Baulig - - * expression.cs (ComposedCast.DoResolveAsTypeStep): Don't allow - `void[]' (CS1547). - -2004-04-28 Martin Baulig - - * statement.cs (LocalInfo.Resolve): Check whether the type is not - void (CS1547). - - * class.cs (MemberBase.CheckParameters, FieldBase.DoDefine): Check - whether the type is not void (CS1547). - -2004-04-28 Martin Baulig - - * expression.cs (Unary.DoResolveLValue): Override this and report - CS0131 for anything but Operator.Indirection. - -2004-04-28 Martin Baulig - - Committing a patch from Ben Maurer; see bug #50820. - - * typemanager.cs (TypeManager.FilterWithClosure): Added CS1540 - check for classes. - - * ecore.cs (Expression.MemberLookupFailed): Added CS1540 check for - classes. - -2004-04-28 Martin Baulig - - Committing a patch from Ben Maurer; see bug #50820. - - * typemanager.cs (TypeManager.FilterWithClosure): Added CS1540 - check for classes. - - * ecore.cs (Expression.MemberLookupFailed): Added CS1540 check for - classes. - -2004-04-28 Martin Baulig - - * statement.cs (Block.LookupLabel): Also lookup in implicit child blocks. - (Block.AddLabel): Call DoLookupLabel() to only search in the - current block. - -2004-04-28 Martin Baulig - - * cfold.cs (ConstantFold.BinaryFold): Added special support for - comparing StringConstants and NullLiterals in Equality and Inequality. - -2004-04-28 Jackson Harper - - * driver.cs: Attempt to load referenced assemblies from the - GAC. This is the quick and dirty version of this method that - doesnt take into account versions and just takes the first - canidate found. Will be good enough for now as we will not have more - then one version installed into the GAC until I update this method. - -2004-04-28 Martin Baulig - - * typemanager.cs (TypeManager.CheckStructCycles): New public - static method to check for cycles in the struct layout. - - * rootcontext.cs (RootContext.PopulateTypes): Call - TypeManager.CheckStructCycles() for each TypeContainer. - [Note: We only need to visit each type once.] - -2004-04-28 Martin Baulig - - * constant.cs (StringConstant.Emit): Emit Ldnull if we're null. - - * const.cs (Const.LookupConstantValue): Return a `bool' signalling - success and added `out object value'. Use a `bool resolved' field - to check whether we've already been called rather than - `ConstantValue != null' since this breaks for NullLiterals. - -2004-04-28 Raja R Harinath - - * driver.cs (Driver.MainDriver) [IsModuleOnly]: Open code the - setting of this flag, since the 'set' method may be non-public. - -2004-04-28 Raja R Harinath - - * flowanalysis.cs (FlowBranchingException.LookupLabel): Add a null - check on current_vector.Block. - -2004-04-27 Martin Baulig - - * expression.cs (BaseAccess.CommonResolve): Don't allow `base' in - a field initializer. Fixes #56459. - -2004-04-27 Martin Baulig - - * ecore.cs (PropertyExpr.DoResolve/DoResolveLValue): Check whether - we're not attempting to use an indexer. Fixes #52154. - -2004-04-27 Martin Baulig - - * statement.cs (Return): Don't create a return label if we don't - need it; reverts my change from January 20th. Thanks to Ben - Maurer for this. - -2004-04-27 Martin Baulig - - According to the spec, `goto' can only leave a nested scope, but - never enter it. - - * statement.cs (Block.LookupLabel): Only lookup in the current - block, don't recurse into parent or child blocks. - (Block.AddLabel): Check in parent and child blocks, report - CS0140/CS0158 if we find a duplicate. - (Block): Removed this indexer for label lookups. - (Goto.Resolve): Call LookupLabel() on our current FlowBranching; - this already does the error reporting for us. - - * flowanalysis.cs - (FlowBranching.UsageVector.Block): New public variable; may be null. - (FlowBranching.CreateSibling): Added `Block' argument. - (FlowBranching.LookupLabel): New public virtual method. Lookup a - label for the target of a `goto' and check whether we're not - leaving a `finally'. - -2004-04-27 Martin Baulig - - * flowanalysis.cs (FlowBranching.UsageVector.MergeChild): If we're - a finite loop block, also do the ALWAYS->SOMETIMES for throws (not - just for returns). - -2004-04-27 Martin Baulig - - * statement.cs (Block.AddLabel): Also check for implicit blocks - and added a CS0158 check. - -2004-04-27 Martin Baulig - - * flowanalysis.cs (FlowBranchingLoop): New class. - (FlowBranching.UsageVector.MergeJumpOrigins): Take a list of - UsageVector's instead of an ArrayList. - (FlowBranching.Label): Likewise. - (FlowBranching.UsageVector.MergeBreakOrigins): New method. - (FlowBranching.AddBreakVector): New method. - -2004-04-27 Miguel de Icaza - - * attribute.cs: Small regression fix: only convert the type if we - the type is different, fixes System.Drawing build. - -2004-04-27 Martin Baulig - - * attribute.cs (Attribute.Resolve): If we have a constant value - for a named field or property, implicity convert it to the correct - type. - -2004-04-27 Raja R Harinath - - * statement.cs (Block.Block): Implicit blocks share - 'child_variable_names' fields with parent blocks. - (Block.AddChildVariableNames): Remove. - (Block.AddVariable): Mark variable as "used by a child block" in - every surrounding block. - * ecore.cs (SimpleName.SimpleNameResolve): If the name has already - been used in a child block, complain about violation of "Invariant - meaning in blocks" rule. - * cs-parser.jay (declare_local_variables): Don't use - AddChildVariableNames. - (foreach_statement): Don't create an implicit block: 'foreach' - introduces a scope. - -2004-04-23 Miguel de Icaza - - * convert.cs (ImplicitNumericConversion): 0 is also positive when - converting from 0L to ulong. Fixes 57522. - -2004-04-22 Marek Safar - - * decl.cs (FindMemberToOverride): Fix wrong warning for case when - derived class hides via 'new' keyword field from base class (test-242.cs). - TODO: Handle this in the more general way. - - * class.cs (CheckBase): Ditto. - -2004-04-22 Marek Safar - - * decl.cs (caching_flags): New member for storing cached values - as bit flags. - (MemberCore.Flags): New enum where bit flags for caching_flags - are defined. - (MemberCore.cls_compliance): Moved to caching_flags. - (DeclSpace.Created): Moved to caching_flags. - - * class.cs: Use caching_flags instead of DeclSpace.Created - -2004-04-21 Miguel de Icaza - - * ecore.cs (PropertyExpr.GetAccesor): Only perform the 1540 check - if we are only a derived class, not a nested class. - - * typemanager.cs: Same as above, but do this at the MemberLookup - level (used by field and methods, properties are handled in - PropertyExpr). Allow for the qualified access if we are a nested - method. - -2004-04-21 Marek Safar - - * class.cs: Refactoring. - (IMethodData): New inteface; Holds links to parent members - to avoid member duplication (reduced memory allocation). - (Method): Implemented IMethodData interface. - (PropertyBase): New inner classes for get/set methods. - (PropertyBase.PropertyMethod): Implemented IMethodData interface - (Event): New inner classes for add/remove methods. - (Event.DelegateMethod): Implemented IMethodData interface. - - * cs-parser.jay: Pass DeclSpace to Event class for creation of valid - EmitContext (related to class.cs refactoring). - -2004-04-21 Raja R Harinath - - * delegate.cs (Delegate.VerifyApplicability): If the number of - arguments are the same as the number of parameters, first try to - verify applicability ignoring any 'params' modifier on the last - parameter. - Fixes #56442. - -2004-04-16 Raja R Harinath - - * class.cs (TypeContainer.AddIndexer): Use - 'ExplicitInterfaceName' to determine if interface name was - explicitly specified. 'InterfaceType' is not initialized at this time. - (TypeContainer.DefineIndexers): Remove use of temporary list. The - Indexers array is already in the required order. Initialize - 'IndexerName' only if there are normal indexers. - (TypeContainer.DoDefineMembers): Don't initialize IndexerName. - (TypeContainer.Emit): Emit DefaultMember attribute only if - IndexerName is initialized. - Fixes #56300. - -2004-04-15 Benjamin Jemlich - - * enum.cs (Enum.DefineType): Don't allow char as type for enum. - Fixes #57007 - -2004-04-15 Raja R Harinath - - * attribute.cs (Attribute.CheckAttributeType): Check for ambiguous - attributes. - Fix for #56456. - - * attribute.cs (Attribute.Resolve): Check for duplicate named - attributes. - Fix for #56463. - -2004-04-15 Miguel de Icaza - - * iterators.cs (MarkYield): track whether we are in an exception, - and generate code accordingly. Use a temporary value to store the - result for our state. - - I had ignored a bit the interaction of try/catch with iterators - since their behavior was not entirely obvious, but now it is - possible to verify that our behavior is the same as MS .NET 2.0 - - Fixes 54814 - -2004-04-14 Miguel de Icaza - - * iterators.cs: Avoid creating temporaries if there is no work to - do. - - * expression.cs (ArrayAccess.EmitLoadOpcode): If dealing with - Enumerations, use TypeManager.EnumToUnderlying and call - recursively. - - Based on the patch from Benjamin Jemlich (pcgod@gmx.net), fixes - bug #57013 - - (This.Emit): Use EmitContext.EmitThis to emit our - instance variable. - - (This.EmitAssign): Ditto. - - * ecore.cs (FieldExpr.Emit): Remove RemapToProxy special - codepaths, we will move all the functionality into - Mono.CSharp.This - - (FieldExpr.EmitAssign): Ditto. - - This fixes several hidden bugs that I uncovered while doing a code - review of this today. - - * codegen.cs (EmitThis): reworked so the semantics are more clear - and also support value types "this" instances. - - * iterators.cs: Changed so that for iterators in value types, we - do not pass the value type as a parameter. - - Initialization of the enumerator helpers is now done in the caller - instead of passing the parameters to the constructors and having - the constructor set the fields. - - The fields have now `assembly' visibility instead of private. - -2004-04-11 Miguel de Icaza - - * expression.cs (Argument.Resolve): Check if fields passed as ref - or out are contained in a MarshalByRefObject. - - * typemanager.cs, rootcontext.cs: Add System.Marshalbyrefobject as - another compiler type. - -2004-04-06 Ben Maurer - - * class.cs (Indexer.Define): use the new name checking method. - Also, return false on an error. - * cs-tokenizer.cs (IsValidIdentifier): Checks for a valid identifier. - (is_identifier_[start/part]_character): make static. - -2004-04-10 Miguel de Icaza - - * expression.cs (Binary.ResolveOperator): Do no append strings - twice: since we can be invoked more than once (array evaluation) - on the same concatenation, take care of this here. Based on a fix - from Ben (bug #56454) - -2004-04-08 Sebastien Pouliot - - * codegen.cs: Fix another case where CS1548 must be reported (when - delay-sign isn't specified and no private is available #56564). Fix - loading the ECMA "key" to delay-sign an assembly. Report a CS1548 - error when MCS is used on the MS runtime and we need to delay-sign - (which seems unsupported by AssemblyBuilder - see #56621). - -2004-04-08 Marek Safar - - * typemanager.cs (TypeManager.TypeToCoreType): Handle IntPtr too. - (TypeManager.ComputeNamespaces): Faster implementation for - Microsoft runtime. - - * compiler.csproj: Updated AssemblyName to mcs. - -2004-04-07 Miguel de Icaza - - * rootcontext.cs: Add new types to the boot resolution. - - * ecore.cs (TypeExpr.CanInheritFrom): Inheriting from - MulticastDelegate is not allowed. - - * typemanager.cs: Add new types to lookup: System.TypedReference - and ArgIterator. - - * paramter.cs (Parameter.Resolve): if we are an out/ref parameter, - check for TypedReference or ArgIterator, they are not allowed. - - * ecore.cs (BoxedCast): Set the eclass to ExprClass.Value, this - makes us properly catch 1510 in some conditions (see bug 56016 for - details). - -2004-04-06 Bernie Solomon - - * CryptoConvert.cs: update from corlib version - with endian fixes. - -2004-04-05 Miguel de Icaza - - * class.cs (Indexer.Define): Check indexername declaration - -2004-04-05 Marek Safar - - * attribute.cs (IsClsCompliant): Fixed problem with handling - all three states (compliant, not-compliant, undetected). - -2004-03-30 Marek Safar - - * attribute.cs (Attribute): Location is now public. - (Resolve): Store resolved arguments (pos_values) in attribute class. - Attribute extractors (now GetClsCompliantAttributeValue) can reuse them. - (GetClsCompliantAttributeValue): New method that gets - CLSCompliantAttribute value. - (GetClsCompliantAttribute): Returns CLSCompliantAttribute for DeclSpace - if exists else null. - (AttributeTester): New class for CLS-Compliant verification routines. - - * class.cs (Emit): Add CLS-Compliant verification. - (Method.GetSignatureForError): Implemented. - (Constructor.GetSignatureForError): Implemented - (Constructor.HasCompliantArgs): Returns if constructor has - CLS-Compliant arguments. - (Constructor.Emit): Override. - (Construcor.IsIdentifierClsCompliant): New method; For constructors - is needed to test only parameters. - (FieldBase.GetSignatureForError): Implemented. - (TypeContainer): New member for storing base interfaces. - (TypeContainer.FindMembers): Search in base interfaces too. - - * codegen.cs (GetClsComplianceAttribute): New method that gets - assembly or module CLSCompliantAttribute value. - (ResolveClsCompliance): New method that resolve CLSCompliantAttribute - for assembly. - (ModuleClass.Emit): Add error 3012 test. - - * const.cs (Emit): Override and call base for CLS-Compliant tests. - - * decl.cs (ClsComplianceValue): New enum that holds CLS-Compliant - state for all decl types. - (MemberCore.Emit): Emit is now virtual and call VerifyClsCompliance - if CLS-Compliant tests are required. - (IsClsCompliaceRequired): New method. Analyze whether code - must be CLS-Compliant. - (IsExposedFromAssembly): New method. Returns true when MemberCore - is exposed from assembly. - (GetClsCompliantAttributeValue): New method. Resolve CLSCompliantAttribute - value or gets cached value. - (HasClsCompliantAttribute): New method. Returns true if MemberCore - is explicitly marked with CLSCompliantAttribute. - (IsIdentifierClsCompliant): New abstract method. This method is - used to testing error 3005. - (IsIdentifierAndParamClsCompliant): New method. Common helper method - for identifier and parameters CLS-Compliant testing. - (VerifyClsCompliance): New method. The main virtual method for - CLS-Compliant verifications. - (CheckAccessLevel): In one special case (System.Drawing) was TypeBuilder - null. I don't know why is null (too many public members !). - (GetClsCompliantAttributeValue). New method. Goes through class hierarchy - and get value of first CLSCompliantAttribute that found. - - * delegate.cs (Emit): Override and call base for CLS-Compliant tests. - (VerifyClsCompliance): Override and add extra tests. - - * driver.cs (CSCParseOption): New command line options (clscheck[+|-]). - clscheck- disable CLS-Compliant verification event if assembly is has - CLSCompliantAttribute(true). - - * enum.cs (Emit): Override and call base for CLS-Compliant tests. - ApllyAttribute is now called in emit section as in the other cases. - Possible future Emit integration. - (IsIdentifierClsCompliant): New override. - (VerifyClsCompliance): New override. - (GetEnumeratorName): Returns full enum name. - - * parameter.cs (GetSignatureForError): Implemented. - - * report.cs (WarningData): New struct for Warning message information. - (LocationOfPreviousError): New method. - (Warning): New method. Reports warning based on the warning table. - (Error_T): New method. Reports error based on the error table. - - * rootcontext.cs (EmitCode): Added new Emit(s) because CLS-Compliant - verifications are done here. - - * tree.cs (RecordDecl): Used new LocationOfPreviousError method. - - * typemanager.cs (cls_compliant_attribute_type): New member thath holds - CLSCompliantAttribute. - (all_imported_types): New member holds all imported types from other - assemblies. - (LoadAllImportedTypes): New method fills static table with exported types - from all referenced assemblies. - (Modules): New property returns all assembly modules. - -2004-03-30 Miguel de Icaza - - * cs-parser.jay: Add a rule to catch wrong event syntax instead of - throwing a parser error. - - * ecore.cs (PropertyExpr.GetAccessor): Apply patch from Patrik Reali - which removes the hardcoded get_/set_ prefixes for properties, as - IL allows for the properties to be named something else. - - Bug #56013 - - * expression.cs: Do not override operand before we know if it is - non-null. Fix 56207 - -2004-03-29 Ben Maurer - - * typemanager.cs: support for pinned variables. - -2004-03-29 Ben Maurer - - * decl.cs, typemanager.cs: Avoid using an arraylist - as a buffer if there is only one result set. - -2004-03-29 Ben Maurer - - * expression.cs: Make sure you cant call a static method - with an instance expression, bug #56174. - -2004-03-29 Miguel de Icaza - - * class.cs (IsDuplicateImplementation): Improve error reporting to - flag 663 (method only differs in parameter modifier). - - * cs-tokenizer.cs: Do not require whitespace when a ( or " will do - in preprocessor directives. - - * location.cs (LookupFile): Allow for the empty path. - - * attribute.cs (DefinePInvokeMethod): Fix 56148; I would like a - better approach for some of that patch, but its failing with the - CharSet enumeration. For now try/catch will do. - - * typemanager.cs: Do not crash if a struct does not have fields. - Fixes 56150. - -2004-03-28 Ben Maurer - - * expression.cs: cs0213, cant fix a fixed expression. - fixes 50231. - -2004-03-28 Ben Maurer - - * cs-parser.jay: detect invalid embeded statements gracefully. - bug #51113. - -2004-03-28 Ben Maurer - - * ecore.cs, typemanager.cs: Correct impl of cs1540 check. - As a regex: - s/ - the invocation type may not be a subclass of the tye of the item/ - The type of the item must be a subclass of the invocation item. - /g - - Fixes bug #50820. - -2004-03-25 Sebastien Pouliot - - * attribute.cs: Added methods to get a string and a bool from an - attribute. Required to information from AssemblyKeyFileAttribute, - AttributeKeyNameAttribute (string) and AssemblyDelaySign (bool). - * codegen.cs: Modified AssemblyName creation to include support for - strongnames. Catch additional exceptions to report them as CS1548. - * compiler.csproj: Updated include CryptoConvert.cs. - * compiler.csproj.user: Removed file - user specific configuration. - * CryptoConvert.cs: New. A COPY of the class CryptoConvert from - Mono.Security assembly. The original class is maintained and tested in - /mcs/class/Mono.Security/Mono.Security.Cryptography/CryptoConvert.cs. - * drivers.cs: Added support for /keyfile, /keycontainer and /delaysign - like CSC 8.0 (C# v2) supports. - * Makefile: Added CryptoConvert.cs to mcs sources. - * rootcontext.cs: Added new options for strongnames. - -2004-03-24 Ben Maurer - - * driver.cs: For --expect-error, report error code `2' - if the program compiled with no errors, error code `1' if - it compiled with an error other than the one expected. - -2004-03-24 Sebastien Pouliot - - * compiler.csproj: Updated for Visual Studio .NET 2003. - * compiler.csproj.user: Updated for Visual Studio .NET 2003. - * compiler.sln: Updated for Visual Studio .NET 2003. - -2004-03-24 Ravi Pratap M - - * expression.cs: Fix bug #47234. We basically need to apply the - rule that we prefer the conversion of null to a reference type - when faced with a conversion to 'object' (csc behaviour). - -2004-03-23 Ben Maurer - - * statement.cs: Shorter form for foreach, eliminates - a local variable. r=Martin. - -2004-03-23 Ben Maurer - - * constant.cs, ecore.cs, literal.cs: New prop IsZeroInteger that - checks if we can use brtrue/brfalse to test for 0. - * expression.cs: use the above in the test for using brtrue/brfalse. - cleanup code a bit. - -2004-03-23 Ben Maurer - - * expression.cs: Rewrite string concat stuff. Benefits: - - - "a" + foo + "b" + "c" becomes "a" + foo + "bc" - - "a" + foo + "b" + bar + "c" + baz ... uses concat (string []). - rather than a concat chain. - - * typemanager.cs: Add lookups for more concat overloads. - -2004-03-23 Ben Maurer - - * expression.cs: Emit shorter il code for array init. - - newarr - dup - // set 1 - - // set 2 - - newarr - stloc.x - - ldloc.x - // set 1 - - ldloc.x - // set 2 - -2004-03-22 Ben Maurer - - * statement.cs: Before, two switch blocks would be merged if the - total size of the blocks (end_item - begin_item + 1) was less than - two times the combined sizes of the blocks. - - Now, it will only merge if after the merge at least half of the - slots are filled. - - fixes 55885. - -2004-03-20 Atsushi Enomoto - - * class.cs : csc build fix for GetMethods(). See bug #52503. - -2004-03-20 Ben Maurer - - * expression.cs: Make sure fp comparisons work with NaN. - This fixes bug #54303. Mig approved this patch a long - time ago, but we were not able to test b/c the runtime - had a related bug. - -2004-03-19 Miguel de Icaza - - * ecore.cs (TypExpr.GetHashCode): implement this overload. - -2004-03-19 Martin Baulig - - * class.cs (MemberCore.IsDuplicateImplementation): Report the - error here and not in our caller. - -2004-03-19 Martin Baulig - - * interface.cs: Completely killed this file. - (Interface): We're now a TypeContainer and live in class.cs. - - * class.cs (TypeContainer.GetClassBases): Added `bool is_iface' - argument; we're now also called for interfaces. - (TypeContainer.DefineMembers): Allow this method being called - multiple times. - (TypeContainer.GetMethods): New public method; formerly known as - Interface.GetMethod(). This is used by PendingImplementation. - (TypeContainer.EmitDefaultMemberAttr): Moved here from Interface; - it's now private and non-static. - (Interface): Moved this here; it's now implemented similar to - Class and Struct. - (Method, Property, Event, Indexer): Added `bool is_interface' - argument to their .ctor's. - (MemberBase.IsInterface): New public field. - - * cs-parser.jay: Create normal Method, Property, Event, Indexer - instances instead of InterfaceMethod, InterfaceProperty, etc. - (opt_interface_base): Removed; we now use `opt_class_base' instead. - (InterfaceAccessorInfo): Create `Get' and `Set' Accessor's. - -2004-03-19 Martin Baulig - - * class.cs (MethodCore.IsDuplicateImplementation): New private - method which does the CS0111 checking. - (Method.CheckBase, Constructor.CheckBase, PropertyBase.CheckBase): - Use IsDuplicateImplementation(). - -2004-03-17 Ben Maurer - - * decl.cs (FindMemberToOverride): New method to find the correct - method or property to override in the base class. - * class.cs - - Make Method/Property use the above method to find the - version in the base class. - - Remove the InheritableMemberSignatureCompare as it is now - dead code. - - This patch makes large code bases much faster to compile, as it is - O(n) rather than O(n^2) to do this validation. - - Also, it fixes bug 52458 which is that nested classes are not - taken into account when finding the base class member. - - Reviewed/Approved by Martin. - -2004-03-17 Marek Safar - - * interface.cs: In all interface classes removed redundant - member initialization. - -2004-03-16 Martin Baulig - - * class.cs (TypeContainer.GetClassBases): Fix the CS0528 check. - -2004-03-15 Miguel de Icaza - - * decl.cs (DefineTypeAndParents): New helper method to define a - type's containers before the type itself is defined; This is a - bug exposed by the recent changes to Windows.Forms when an - implemented interface was defined inside a class that had not been - built yet. - - * modifiers.cs (MethodAttr): All methods in C# are HideBySig. - - (Check): Loop correctly to report errors modifiers - (UNSAFE was not in the loop, since it was the same as TOP). - - * interface.cs: Every interface member now takes a ModFlags, - instead of a "is_new" bool, which we set on the base MemberCore. - - Every place where we called "UnsafeOk" in the interface, now we - call the proper member (InterfaceMethod.UnsafeOK) instead to get - the unsafe settings from the member declaration instead of the - container interface. - - * cs-parser.jay (opt_new): Allow unsafe here per the spec. - - * pending.cs (TypeAndMethods): Add `get_indexer_name' and - `set_indexer_name' to the pending bits (one per type). - - We fixed a bug today that was picking the wrong method to - override, since for properties the existing InterfaceMethod code - basically ignored the method name. Now we make sure that the - method name is one of the valid indexer names. - -2004-03-14 Gustavo Giráldez - - * support.cs (SeekableStreamReader): Keep track of stream byte - positions and don't mix them with character offsets to the buffer. - - Patch from Gustavo Giráldez - -2004-03-15 Marek Safar - - * interface.cs (InterfaceSetGetBase): Removed double member - initialization, base class does it as well. - -2004-03-13 Martin Baulig - - * class.cs: Reverted Miguel's latest commit; it makes mcs crash - when compiling corlib. - -2004-03-13 Miguel de Icaza - - * convert.cs (ExplicitConversion): We were reporting an error on - certain conversions (object_type source to a value type, when the - expression was `null') before we had a chance to pass it through - the user defined conversions. - - * driver.cs: Replace / and \ in resource specifications to dots. - Fixes 50752 - - * class.cs: Add check for duplicate operators. Fixes 52477 - -2004-03-11 Miguel de Icaza - - * statement.cs (Switch.SimpleSwitchEmit): Deal with default labels - that are in the middle of the statements, not only at the end. - Fixes #54987 - - * class.cs (TypeContainer.AddField): No longer set the - `HaveStaticConstructor' flag, now we call it - `UserDefineStaticConstructor' to diferentiate the slightly - semantic difference. - - The situation is that we were not adding BeforeFieldInit (from - Modifiers.TypeAttr) to classes that could have it. - BeforeFieldInit should be set to classes that have no static - constructor. - - See: - - http://www.yoda.arachsys.com/csharp/beforefieldinit.html - - And most importantly Zoltan's comment: - - http://bugzilla.ximian.com/show_bug.cgi?id=44229 - - "I think beforefieldinit means 'it's ok to initialize the type sometime - before its static fields are used', i.e. initialization does not need - to be triggered by the first access to the type. Setting this flag - helps the JIT to compile better code, since it can run the static - constructor at JIT time, and does not need to generate code to call it - (possibly lots of times) at runtime. Unfortunately, mcs does not set - this flag for lots of classes like String. - - csc sets this flag if the type does not have an explicit static - constructor. The reasoning seems to be that if there are only static - initalizers for a type, and no static constructor, then the programmer - does not care when this initialization happens, so beforefieldinit - can be used. - - This bug prevents the AOT compiler from being usable, since it - generates so many calls to mono_runtime_class_init that the AOT code - is much slower than the JITted code. The JITted code is faster, - because it does not generate these calls if the vtable is type is - already initialized, which is true in the majority of cases. But the - AOT compiler can't do this." - -2004-03-10 Miguel de Icaza - - * class.cs (MethodData.Emit): Refactor the code so symbolic - information is generated for destructors; For some reasons we - were taking a code path that did not generate symbolic information - before. - -2004-03-11 Ben Maurer - - * class.cs: Create a Constructor.CheckBase method that - takes care of all validation type code. The method - contains some code that was moved from Define. - - It also includes new code that checks for duplicate ctors. - This fixes bug #55148. - -2004-03-09 Joshua Tauberer - - * expression.cs (ArrayCreation): Fix: More than 6 nulls in - a { ... }-style array creation invokes EmitStaticInitializers - which is not good for reference-type arrays. String, decimal - and now null constants (NullCast) are not counted toward - static initializers. - -2004-03-05 Martin Baulig - - * location.cs (SourceFile.HasLineDirective): New public field; - specifies whether the file contains or is referenced by a "#line" - directive. - (Location.DefineSymbolDocuments): Ignore source files which - either contain or are referenced by a "#line" directive. - -2004-02-29 Ben Maurer - - * class.cs (Method.CheckBase): Avoid using FindMembers, we have - direct access to our parent, so check the method inline there. - -2004-02-27 Ben Maurer - - * expression.cs (Invocation.EmitCall): Miguel's last commit - caused a regression. If you had: - - T t = null; - t.Foo (); - - In Foo the implict this would be null. - -2004-02-27 Miguel de Icaza - - * expression.cs (Invocation.EmitCall): If the method is not - virtual, do not emit a CallVirt to it, use Call. - - * typemanager.cs (GetFullNameSignature): Improve the method to - cope with ".ctor" and replace it with the type name. - - * class.cs (ConstructorInitializer.Resolve): Now the method takes - as an argument the ConstructorBuilder where it is being defined, - to catch the recursive constructor invocations. - -2004-02-26 Miguel de Icaza - - * iterators.cs (IteratorHandler.IsIEnumerator, IsIEnumerable): New - routines to check if a type is an enumerable/enumerator allow - classes that implement the IEnumerable or IEnumerator interfaces. - - * class.cs (Property, Operator): Implement IIteratorContainer, and - implement SetYields. - - (Property.Define): Do the block swapping for get_methods in the - context of iterators. We need to check if Properties also - include indexers or not. - - (Operator): Assign the Block before invoking the - OperatorMethod.Define, so we can trigger the Iterator code - replacement. - - * cs-parser.jay (SimpleIteratorContainer): new helper class. Both - Property and Operator classes are not created when we parse the - declarator but until we have the block completed, so we use a - singleton SimpleIteratorContainer.Simple to flag whether the - SetYields has been invoked. - - We propagate this setting then to the Property or the Operator to - allow the `yield' to function. - -2004-02-25 Marek Safar - - * codegen.cs: Implemented attribute support for modules. - New AssemblyClass, ModuleClass and CommonAssemblyModulClass for - Assembly/Module functionality. - - * attribute.cs, class.cs, cs-parser.jay, delegate.cs, driver.cs, enum.cs - interface.cs, rootcontext.cs, statement.cs, typemanager.cs: - Updated dependencies on CodeGen.ModuleBuilder and CodeGen.AssemblyBuilder. - -2004-02-16 Marek Safar - - * interface.cs (FindMembers): The operation is performed on all base - interfaces and not only on the first. It is required for future CLS Compliance patch. - -2004-02-12 Ben Maurer - - * statement.cs, codegen.cs: - This patch deals with patterns such as: - - public class List : IEnumerable { - - public MyEnumerator GetEnumerator () { - return new MyEnumerator(this); - } - - IEnumerator IEnumerable.GetEnumerator () { - ... - } - - public struct MyEnumerator : IEnumerator { - ... - } - } - - Before, there were a few things we did wrong: - 1) we would emit callvirt on a struct, which is illegal - 2) we emited ldarg when we needed to emit ldarga - 3) we would mistakenly call the interface methods on an enumerator - type that derived from IEnumerator and was in another assembly. For example: - - public class MyEnumerator : IEnumerator - - Would have the interface methods called, even if there were public impls of the - method. In a struct, this lead to invalid IL code. - -2004-02-11 Marek Safar - - * const.cs: Const is now derived from FieldBase. Method EmitConstant name - renamed to Emit. - - * delegate.cs (Define): Fixed crash when delegate type is undefined. - -2004-02-11 Miguel de Icaza - - * cs-parser.jay: Fix small regression: we were not testing V2 - compiler features correctly. - - * interface.cs: If the emit context is null, then create one - -2004-02-09 Marek Safar - - * decl.cs (GetSignatureForError): New virtual method to get full name - for error messages. - - * attribute.cs (IAttributeSupport): New interface for attribute setting. - Now it is possible to rewrite ApplyAttributes method to be less if/else. - - * interface.cs : All InterfaceXXX classes are now derived from MemberCore. - Duplicated members and code in these classes has been removed. - Better encapsulation in these classes. - -2004-02-07 Miguel de Icaza - - * assign.cs (Assign.DoResolve): When dealing with compound - assignments, there is a new rule in ECMA C# 2.4 (might have been - there before, but it is documented here) that states that in: - - a op= b; - - If b is of type int, and the `op' is a shift-operator, then the - above is evaluated as: - - a = (int) a op b - - * expression.cs (Binary.ResolveOperator): Instead of testing for - int/uint/long/ulong, try to implicitly convert to any of those - types and use that in pointer arithmetic. - - * delegate.cs (Error_NoMatchingMethodForDelegate): Compute the - method to print information for from the type, not from the - null-method we were given. - -2004-02-01 Duncan Mak - - * cs-tokenizer.cs (get_cmd_arg): Skip over whitespace before - parsing for cmd, fixes bug #53694. - -2004-02-04 Marek Safar - - * class.cs, decl.cs: Fixed problem where IndexerName attribute was ignored - in the member name duplication tests. Property and operator name duplication - was missing too (error tests cs0102-{2,3,4,5}.cs, cs0111-{3,4}.cs). - -2004-02-03 Marek Safar - - * interface.cs (PopulateMethod): Fixed crash when interface method - returns not existing type (error test cs0246-3.cs). - -2004-02-02 Ravi Pratap M - - * cs-parser.jay (interface_accessors): Re-write actions to also - store attributes attached to get and set methods. Fix spelling - while at it. - - (inteface_property_declaration): Modify accordingly. - - (InterfaceAccessorInfo): New helper class to store information to pass - around between rules that use interface_accessors. - - * interface.cs (Emit): Apply attributes on the get and set - accessors of properties and indexers too. - - * attribute.cs (ApplyAttributes): Modify accordingly to use the - right MethodBuilder when applying attributes to the get and set accessors. - -2004-01-31 Miguel de Icaza - - * cs-tokenizer.cs: Applied patch from Marek Safar to fix bug 53386 - -2004-01-26 Miguel de Icaza - - * cs-tokenizer.cs: Handle #line hidden from PDC bits. - -2004-01-25 Miguel de Icaza - - * cs-parser.jay: Remove YIELD token, instead use the new grammar - changes that treat `yield' specially when present before `break' - or `return' tokens. - - * cs-tokenizer.cs: yield is no longer a keyword. - -2004-01-23 Marek Safar - - * cs-parser.jay, class.cs (DefineDefaultConstructor): Fixed ModFlags - setting for default constructors. - For default constructors are almost every time set wrong Modifier. The - generated IL code has been alright. But inside mcs this values was - wrong and this was reason why several of my CLS Compliance tests - failed. - -2004-01-22 Martin Baulig - - * cs-parser.jay (namespace_or_type_name): Return an Expression, - not a QualifiedIdentifier. This is what `type_name_expression' - was previously doing. - (type_name_expression): Removed; the code is now in - `namespace_or_type_name'. - (qualified_identifier): Removed, use `namespace_or_type_name' - instead. - (QualifiedIdentifier): Removed this class. - -2004-01-22 Martin Baulig - - * namespace.cs (NamespaceEntry.UsingAlias): Take an Expression, - not a string as alias name. - -2004-01-21 Miguel de Icaza - - * ecore.cs (FieldInfo.AddressOf): Revert patch from previous - #52730 bug, and instead compute correctly the need to use a - temporary variable when requesting an address based on the - static/instace modified of the field and the constructor. - -2004-01-21 Martin Baulig - - * ecore.cs (SimpleName.ResolveAsTypeStep): Lookup in the current - class and namespace before looking up aliases. Fixes #52517. - -2004-01-21 Martin Baulig - - * flowanalysis.cs (UsageVector.Merge): Allow variables being - assinged in a 'try'; fixes exception4.cs. - -2004-01-21 Marek Safar - * class.cs : Implemented parameter-less constructor for TypeContainer - - * decl.cs: Attributes are now stored here. New property OptAttributes - - * delegate.cs, enum.cs, interface.cs: Removed attribute member. - - * rootcontext.cs, tree.cs: Now use parameter-less constructor of TypeContainer - -2004-01-21 Marek Safar - - * typemanager.cs (CSharpSignature): Now reports also inner class name. - (CSharpSignature): New method for indexer and property signature. - -2004-01-21 Marek Safar - - * pending.cs (IsVirtualFilter): Faster implementation. - -2004-01-21 Marek Safar - - * typemanager.cs: Avoid inclusion of same assembly more than once. - -2004-01-21 Marek Safar - - * cs-parser.jay: Fixed problem where the last assembly attribute - has been applied also to following declaration (class, struct, etc.) - -2004-01-21 Marek Safar - - * class.cs: Added error CS0538, CS0539 reporting. - Fixed crash on Microsoft runtime when field type is void. - - * cs-parser.jay: Added error CS0537 reporting. - - * pending.cs: Added error CS0535 reporting. - Improved error report for errors CS0536, CS0534. - -2004-01-20 Miguel de Icaza - - Merge a few bits from the Anonymous Method MCS tree. - - * statement.cs (ToplevelBlock): New class for toplevel methods, - will hold anonymous methods, lifted variables. - - * cs-parser.jay: Create toplevel blocks for delegates and for - regular blocks of code. - -2004-01-20 Martin Baulig - - * codegen.cs (EmitContext): Removed `InTry', `InCatch', - `InFinally', `InLoop', `TryCatchLevel', `LoopBeginTryCatchLevel' - and `NeedExplicitReturn'; added `IsLastStatement'. - (EmitContext.EmitTopBlock): Emit the explicit "ret" if we either - have a `ReturnLabel' or we're not unreachable. - - * flowanalysis.cs (FlowBranching.MergeChild): Actually merge the - child's reachability; don't just override ours with it. Fixes - #58058 (lluis's example). - (FlowBranching): Added public InTryOrCatch(), InCatch(), - InFinally(), InLoop(), InSwitch() and - BreakCrossesTryCatchBoundary() methods. - - * statement.cs (Return): Do all error checking in Resolve(). - Unless we are the last statement in a top-level block, always - create a return label and jump to it. - (Break, Continue): Do all error checking in Resolve(); also make - sure we aren't leaving a `finally'. - (Block.DoEmit): Set `ec.IsLastStatement' when emitting the last - statement in a top-level block. - (Block.Flags): Added `IsDestructor'. - (Block.IsDestructor): New public property. - -2004-01-20 Martin Baulig - - * statement.cs (Break.DoEmit): Set ec.NeedExplicitReturn; fixes #52427. - -2004-01-20 Martin Baulig - - * statement.cs (Statement.ResolveUnreachable): New public method. - (If, While): Do the dead-code elimination in Resolve(), not in Emit(). - (Block.Resolve): Resolve unreachable statements. - -2004-01-19 Ben Maurer - - * expression.cs: We need to fix the case where we do - not have a temp variable here. - - * assign.cs: Only expression compound assignments need - temporary variables. - -2004-01-19 Ben Maurer - - * flowanalysis.cs: Reduce memory allocation in a few ways: - - A block with no variables should not allocate a bit - vector for itself. - - A method with no out parameters does not need any tracking - for assignment of the parameters, so we need not allocate - any data for it. - - The arrays: - public readonly Type[] VariableTypes; - public readonly string[] VariableNames; - Are redundant. The data is already stored in the variable - map, so we need not allocate another array for it. - - We need to add alot of checks for if (params | locals) == null - due to the first two changes. - -2004-01-18 Miguel de Icaza - - * ecore.cs (FieldExpr.AddressOf): For ValueTypes that do not - implement IMemoryLocation, we store a copy on a local variable and - take the address of it. Patch from Benjamin Jemlich - - * cs-parser.jay: Applied patch from Ben Maurer to the "type" rule - to use a special "type_name_expression" rule which reduces the - number of "QualifiedIdentifier" classes created, and instead - directly creates MemberAccess expressions. - -2004-01-17 Miguel de Icaza - - * convert.cs: Applied patch from Benjamin Jemlich (pcgod@gmx.net) - that fixes #52853. Null literal assignment to ValueType - - * class.cs (MethodData.Emit): Instead of checking the name of the - method to determine if its a destructor, create a new derived - class from Method called Destructor, and test for that. - - * cs-parser.jay: Create a Destructor object instead of a Method. - - Based on a fix from Benjamin Jemlich (pcgod@gmx.net) - - Fixes: 52933 - -2004-01-16 Miguel de Icaza - - * expression.cs (Binary.ResolveOperator): Perform an implicit - conversion from MethodGroups to their delegate types on the - Addition operation. - - * delegate.cs: Introduce a new class DelegateCreation that is the - base class for `NewDelegate' and `ImplicitDelegateCreation', - factor some code in here. - - * convert.cs (Convert.ImplicitConversionStandard): Add an implicit - conversion from MethodGroups to compatible delegate types. - - * ecore.cs (Expression.Resolve): Do not flag error 654 - (Methodgroupd needs parenthesis) if running on the V2 compiler, as - we allow conversions from MethodGroups to delegate types now. - - * assign.cs (Assign.DoResolve): Do not flag errors on methodgroup - assignments in v2 either. - -2004-01-10 Miguel de Icaza - - * ecore.cs (FieldExpr.AddressOf): Fix generated IL for accessing - static read-only fields in ctors. - - Applied patch from Benjamin Jemlich - - * expression.cs (UnaryMutator): Avoid leaking local variables. - -2004-01-09 Miguel de Icaza - - * cs-tokenizer.cs (IsCastToken): Allow the various native types - here to return true, as they can be used like this: - - (XXX) int.MEMBER () - - Fixed 49836 and all the other dups - -2004-01-09 Zoltan Varga - - * driver.cs: Implement /win32res and /win32icon. - -2004-01-08 Miguel de Icaza - - * cs-parser.jay: Add a rule to improve error handling for the - common mistake of placing modifiers after the type. - -2004-01-07 Miguel de Icaza - - * cs-parser.jay (interface_event_declaration): Catch - initialization of events on interfaces, and report cs0068 - - * cs-parser.jay (interface_event_declaration): Catch - initialization of events. - - * ecore.cs: Better report missing constructors. - - * expression.cs (Binary.ResolveOperator): My previous bug fix had - the error reporting done in the wrong place. Fix. - - * expression.cs (Binary.ResolveOperator): Catch the - operator + (E x, E y) error earlier, and later allow for implicit - conversions in operator +/- (E e, U x) from U to the underlying - type of E. - - * class.cs (TypeContainer.DefineDefaultConstructor): Fix bug - 52596, if the container class is abstract, the default constructor - is protected otherwise its public (before, we were always public). - - * statement.cs (Fixed.Resolve): Catch a couple more errors in the - fixed statement. - - (Using.EmitLocalVariableDecls): Applied patch from Benjamin - Jemlich that fixes bug #52597, MCS was generating invalid code for - idisposable structs. Thanks to Ben for following up with this - bug as well. - -2004-01-06 Miguel de Icaza - - * driver.cs: Allow assemblies without code to be generated, fixes - 52230. - -2004-01-07 Nick Drochak - - * attribute.cs: Remove unneeded catch variables. Eliminates a warning. - -2004-01-05 Miguel de Icaza - - * cs-parser.jay: Add rules to improve error reporting if fields or - methods are declared at the namespace level (error 116) - - * Add rules to catch event add/remove - -2004-01-04 David Sheldon - - * expression.cs: Added matching ")" to error message for - CS0077 - -2004-01-03 Todd Berman - - * ecore.cs, attribute.cs: - Applying fix from #52429. - -2004-01-03 Ben Maurer - - * ecore.cs, expression.cs, statement.cs: - Total rewrite of how we handle branching. We - now handle complex boolean expressions with fewer - jumps. As well if (x == 0) no longer emits a ceq. - - if (x is Foo) is much faster now, because we generate - better code. - - Overall, we get a pretty big improvement on our benchmark - tests. The code we generate is smaller and more readable. - - I did a full two-stage bootstrap. The patch was reviewed - by Martin and Miguel. - -2004-01-03 Ben Maurer - - * cs-parser.jay: Make primary_expression not take a QI. - we dont need this because the member_access rule covers - us here. So we replace the rule with just IDENTIFIER. - - This has two good effects. First, we remove a s/r conflict. - Second, we allocate many fewer QualifiedIdentifier objects. - -2004-01-03 Ben Maurer - - * attribute.cs: Handle MarshalAs attributes as pseudo, and - set the correct information via SRE. This prevents - hanging on the MS runtime. Fixes #29374. - -2004-01-03 Ben Maurer - - * convert.cs: correctly handle conversions to value types - from Enum and ValueType as unboxing conversions. - - Fixes bug #52569. Patch by Benjamin Jemlich. - -2004-01-02 Ravi Pratap - - * expression.cs (BetterConversion): Prefer int -> uint - over int -> ulong (csc's behaviour). This fixed bug #52046. - -2004-01-02 Ben Maurer - - * decl.cs (MemberCache.FindMembers): now returns a - MemberInfo []. - - * typemanager.cs: In general, go with with ^^. - (CopyNewMethods): take an IList. - (RealMemberLookup): Only allocate an arraylist - if we copy from two sets of methods. - - This change basically does two things: - 1) Fewer array lists allocated due to CopyNewMethods. - 2) the explicit cast in MemberList costed ALOT. - -2004-01-02 Zoltan Varga - - * cs-tokenizer.cs (consume_identifier) driver.cs: Cache identifiers in - a hashtable to avoid needless string allocations when an identifier is - used more than once (the common case). - -2004-01-01 Ben Maurer - - * pending.cs: MS's TypeBuilder.GetInterfaces () - is broken, it will not return anything. So, we - have to use the information we have in mcs to - do the task. - - * typemanager.cs: Add a cache for GetInterfaces, - since this will now be used more often (due to ^^) - - (GetExplicitInterfaces) New method that gets the - declared, not effective, interfaces on a type - builder (eg, if you have interface IFoo, interface - IBar, Foo : IFoo, Bar : Foo, IBar, GetExplInt (Bar) == - { IBar }. - - This patch makes MCS able to bootstrap itself on - Windows again. - -2004-01-01 Ben Maurer - - * expression.cs: Remove the Nop's that Miguel put - in by mistake. - -2003-12-31 Ben Maurer - - * report.cs, codegen.cs: Give the real stack trace to - the error when an exception is thrown. - -2003-12-31 Ben Maurer - - * decl.cs: only allocate hashtables for ifaces if - it is an iface! - -2003-12-31 Ben Maurer - - * expression.cs: fix the error from cs0121-2.cs - (a parent interface has two child interfaces that - have a function with the same name and 0 params - and the function is called through the parent). - -2003-12-30 Ben Maurer - - * class.cs, rootcontext.cs, typmanager.cs: do not - leak pointers. - -2003-12-28 Ben Maurer - - * codegen.cs: remove stack for the ec flow branching. - It is already a linked list, so no need. - -2003-12-27 Ben Maurer - - * Makefile: Allow custom profiler here. - -2003-12-26 Ben Maurer - - * typemanager.cs (LookupType): - - Use a static char [], because split takes - a param array for args, so it was allocating - every time. - - Do not store true in a hashtable, it boxes. - -2003-12-26 Ben Maurer - - * flowanalysis.cs: bytify common enums. - -2003-12-25 Ben Maurer - - * modifiers.cs: Add a new set of flags for the - flags allowed on explicit interface impls. - * cs-parser.jay: catch the use of modifiers in - interfaces correctly. - * class.cs: catch private void IFoo.Blah (). - - All related to bug #50572. - -2003-12-25 Ben Maurer - - * decl.cs: Rewrite the consistant accessability checking. - Accessability is not linear, it must be implemented in - a tableish way. Fixes #49704. - -2003-12-25 Ben Maurer - - * expression.cs: Handle negation in a checked context. - We must use subtraction from zero. Fixes #38674. - -2003-12-23 Ben Maurer - - * class.cs: Ignore static void main in DLLs. - * rootcontext.cs: Handle the target type here, - since we are have to access it from class.cs - * driver.cs: account for the above. - -2003-12-23 Ben Maurer - - * report.cs: Give line numbers and files if available. - -2003-12-20 Zoltan Varga - - * driver.cs: Implement /addmodule. - - * typemanager.cs: Change 'modules' field so it now contains Modules not - ModuleBuilders. - -2003-12-20 Martin Baulig - - * class.cs (TypeContainer.DefineMembers): Don't do the CS0649 check here. - (FieldBase.IsAssigned): Removed this field. - (FieldBase.SetAssigned): New public method. - (TypeContainer.Emit): Make the CS0169/CS0649 checks actually work. - -2003-12-20 Martin Baulig - - * expression.cs (LocalVariableReference.DoResolve): Don't set - `vi.Used' if we're called from DoResolveLValue(). - - * statement.cs (Block.DoResolve): `ec.DoEndFlowBranching()' now - returns the usage vector it just merged into the current one - - pass this one to UsageWarning(). - (Block.UsageWarning): Take the `FlowBranching.UsageVector' instead - of the `EmitContext', don't call this recursively on our children. - -2003-12-19 Zoltan Varga - - * driver.cs: Implement /target:module. - -2003-12-18 Zoltan Varga - - * support.cs (CharArrayHashtable): New helper class. - - * cs-tokenizer.cs: Store keywords in a hashtable indexed by - char arrays, not strings, so we can avoid creating a string in - consume_identifier if the identifier is a keyword. - -2003-12-16 Martin Baulig - - * statement.cs (LocalInfo.Assigned): Removed this property. - (LocalInfo.Flags): Removed `Assigned'. - (LocalInfo.IsAssigned): New public method; takes the EmitContext - and uses flow analysis. - (Block.UsageWarning): Made this method private. - (Block.Resolve): Call UsageWarning() if appropriate. - - * expression.cs (LocalVariableReference.DoResolve): Always set - LocalInfo.Used here. - -2003-12-13 Martin Baulig - - * statement.cs (Statement.DoEmit, Statement.Emit): Don't return - any value here; we're now using flow analysis to figure out - whether a statement/block returns a value. - -2003-12-13 Martin Baulig - - * flowanalysis.cs (UsageVector.MergeFinallyOrigins): Made this - working again. - (FlowBranching.MergeFinally): Don't call - `branching.CheckOutParameters()' here, this is called in - MergeTopBlock(). - (FlowBranchingException.AddSibling): Call MergeFinallyOrigins() - when adding the `finally' vector. - -2003-12-13 Martin Baulig - - * flowanalysis.cs - (UsageVector.MergeJumpOrigins, FlowBranching.Label): Make this - actually work and also fix #48962. - -2003-12-12 Ben Maurer - - * decl.cs: Do not check System.Object for nested types, - since we know it does not have any. Big bang for buck: - - BEFORE: - Run 1: 8.35 seconds - Run 2: 8.32 seconds - corlib: 17.99 seconds - AFTER: - Run 1: 8.17 seconds - Run 2: 8.17 seconds - corlib: 17.39 seconds - -2003-12-11 Ben Maurer - - * class.cs (FindMembers): Allocate arraylists on demand. Most of the - time we are returning 0 members, so we save alot here. - -2003-12-11 Martin Baulig - - * flowanalysis.cs (UsageVector.MergeResult): Renamed this back to - `MergeChild()', also just take the `FlowBranching' as argument; - call Merge() on it and return the result. - (FlowBranching.Merge): We don't need to do anything if we just - have one sibling. - -2003-12-11 Martin Baulig - - * flowanalysis.cs: Use a list of `UsageVector's instead of storing - them in an `ArrayList' to reduce memory usage. Thanks to Ben - Maurer for this idea. - -2003-12-11 Martin Baulig - - * flowanalysis.cs (MergeResult): This class is now gone; we now - use the `UsageVector' for this. The reason for this is that if a - branching just has one sibling, we don't need to "merge" them at - all - that's the next step to do. - (FlowBranching.Merge): We now return a `UsageVector' instead of a - `MergeResult'. - -2003-12-11 Martin Baulig - - Reworked flow analyis and made it more precise and bug-free. The - most important change is that we're now using a special `Reachability' - class instead of having "magic" meanings of `FlowReturns'. I'll - do some more cleanups and optimizations and also add some more - documentation this week. - - * flowanalysis.cs (Reachability): Added `Throws' and `Barrier'; - largely reworked this class. - (FlowReturns): Removed `Unreachable' and `Exception'; we now use - the new `Reachability' class instead of having "magic" values here. - (FlowBranching): We're now using an instance of `Reachability' - instead of having separate `Returns', `Breaks' etc. fields. - - * codegen.cs (EmitContext.EmitTopBlock): Set `has_ret' solely - based on flow analysis; ignore the return value of block.Emit (). - -2003-12-10 Zoltan Varga - - * driver.cs typemanager.cs: Find the mono extensions to corlib even - if they are private. - -2003-12-09 Martin Baulig - - * flowanalyis.cs (FlowBranching.Return, Goto, Throw): Removed; - call them directly on the UsageVector. - -2003-12-09 Martin Baulig - - * flowanalysis.cs (FlowBranching.MergeChild, MergeTopBlock): - Changed return type from `FlowReturns' to `Reachability'. - -2003-12-09 Martin Baulig - - * flowanalysis.cs (FlowBranching.Reachability): New sealed class. - (FlowBranching.MergeResult): Replaced the `Returns', `Breaks' and - `Reachable' fields with a single `Reachability' one. - -2003-12-08 Ben Maurer - - * class.cs (FindMembers): Remove foreach's. - - Bootstrap times: - - BEFORE - Run 1: 8.74 seconds - Run 2: 8.71 seconds - - AFTER - Run 1: 8.64 seconds - Run 2: 8.58 seconds - - -2003-12-08 Ben Maurer - - * cs-parser.jay: - * gen-treedump.cs: - * statement.cs: - This patch does a few things: - 1. EmptyStatement is now a singleton, so it is never reallocated. - 2. All blah is EmptyStatement constructs have been changed to - blah == EmptyStatement.Value, which is much faster and valid - now that EmptyStatement is a singleton. - 3. When resolving a block, rather than allocating a new array for - the non-empty statements, empty statements are replaced with - EmptyStatement.Value - 4. Some recursive functions have been made non-recursive. - Mainly the performance impact is from (3), however (1) and (2) are needed for - this to work. (4) does not make a big difference in normal situations, however - it makes the profile look saner. - - Bootstrap times: - - BEFORE - 9.25user 0.23system 0:10.28elapsed 92%CPU (0avgtext+0avgdata 0maxresident)k - 9.34user 0.13system 0:10.23elapsed 92%CPU (0avgtext+0avgdata 0maxresident)k - Total memory allocated: 56397 KB - - AFTER - 9.13user 0.09system 0:09.64elapsed 95%CPU (0avgtext+0avgdata 0maxresident)k - 8.96user 0.24system 0:10.13elapsed 90%CPU (0avgtext+0avgdata 0maxresident)k - Total memory allocated: 55666 KB - -2003-12-08 Ben Maurer - - * support.cs: Rewrite DoubleHash to use its own impl. Is faster - than the hashtable in a hashtable version - - * decl.cs: Right now, whenever we try to lookup a type inside a namespace, - we always end up concating a string. This results in a huge perf - loss, because many strings have to be tracked by the GC. In this - patch, we first use a hashtable that works with two keys, so that - the strings do not need to be concat'ed. - - Bootstrap times: - BEFORE - Run 1: 8.74 seconds - Run 2: 8.71 seconds - - AFTER - Run 1: 8.65 seconds - Run 2: 8.56 seconds - -2003-12-08 Ben Maurer - - * Makefile: Add a new target `do-time' that does a quick and simple - profile, leaving easy to parse output. - -2003-12-08 Zoltan Varga - - * codegen.cs (Init): Create the dynamic assembly with - AssemblyBuilderAccess.Save, to enable some optimizations in the runtime. - -2003-12-02 Ben Maurer - - * support.cs: Make the PtrHashtable use only one - instance of its comparer. - -2003-11-30 Zoltan Varga - - * typemanager.cs: Fix lookup of GetNamespaces. - -2003-11-29 Miguel de Icaza - - * expression.cs: Removed redundant line. - - * statement.cs (Block.Resolve, Block.Emit): Avoid foreach on - ArrayLists, use for loops with bounds. - - * flowanalysis.cs (FlowBranching.Merge): Avoid foreach on - arraylist. - - * expression.cs (Invocation.OverloadResolve): Avoid foreach on - arraylists, use for loop with bounds. - - The above three changes give us a 0.071 second performance - improvement out of 3.294 seconds down to 3.223. On my machine - the above changes reduced the memory usage by 1,387 KB during - compiler bootstrap. - - * cs-parser.jay (QualifiedIdentifier): New class used to represent - QualifiedIdentifiers. Before we created a new string through - concatenation, and mostly later on, the result would be - manipulated by DecomposeQI through string manipulation. - - This reduced the compiler memory usage for bootstrapping from - 59380 KB to 59007 KB on my machine, 373 KB, and also reduced the - compile times in 0.05 seconds. - -2003-11-28 Dick Porter - - * support.cs: Do string compares with the Invariant culture. - - * rootcontext.cs: - * gen-treedump.cs: - * expression.cs: - * driver.cs: - * decl.cs: - * codegen.cs: - * class.cs: Use the char forms of IndexOf and LastIndexOf, so that - the comparison is done with the Invariant culture. - -2003-11-27 Miguel de Icaza - - * statement.cs (Foreach.TryType): Use DeclaredOnly to find the - GetEnumerator method. - - (ProbeCollectionType): Iterate starting at the most specific type - upwards looking for a GetEnumerator - - * expression.cs: Shift count can be up to 31 for int/uint and 63 - for long/ulong. - -2003-11-26 Miguel de Icaza - - * statement.cs (Block.LookupLabel): Also look for the label on the - children blocks. Use a hash table to keep track of visited - nodes. - - * cfold.cs (IntConstant to UIntConstant mapping): Only return if - we actually did transform the other operand, otherwise fall back - to the common codepath that casts to long. - - * cs-tokenizer.cs: Use the same code pattern as the int case. - Maybe I should do the parsing myself, and avoid depending on the - Parse routines to get this done. - -2003-11-25 Miguel de Icaza - - * expression.cs: Apply fix from l_m@pacbell.net (Laurent Morichetti), - which fixes bug 51347. This time test it. - - * expression.cs: Make TypeOfVoid derive from TypeOf, so code in - attributes for example can not tell the difference between these. - The difference was only a syntax feature of the language. - - * attribute.cs: Apply attributes to delegates. - - * delegate.cs: Call the apply attributes method. - -2003-11-24 Miguel de Icaza - - * convert.cs (TryImplicitIntConversion): One line bug fix: we were - comparing 0 vs Byte.MinValue, not the value - - (ImplicitConversionRequired): When reporting a conversion error, - use error 31 to print out the constant error instead of the - simpler 29. - - * expression.cs: Apply fix from l_m@pacbell.net (Laurent Morichetti), - which fixes bug 51347. - -2003-11-22 Miguel de Icaza - - * driver.cs: Applied patch from gert.driesen@pandora.be (Gert Driesen) - which fixes the -warnaserror command line option. - -2003-11-21 Miguel de Icaza - - * cfold.cs (DoNumericPromotions): During constant folding of - additions on UIntConstant, special case intconstants with - IntConstants like we do on the expression binary operator. - -2003-11-12 Miguel de Icaza - - * convert.cs (ImplicitReferenceConversion): We were missing a case - (System.Enum are not value types or class types, so we need to - classify them separatedly). - - * driver.cs: We do not support error 2007. - -2003-11-12 Jackson Harper - - * driver.cs: Use corlib.dll or mscorlib.dll when looking up the - system directory. Also use the full file name so users can - libraries names mscorlib-o-tron.dll in a non system dir. - -2003-11-10 Martin Baulig - - * typemanager.cs (TypeManager.ResolveExpressionTypes): Removed. - (TypeManager.InitCoreTypes): Initialize them here, but instead of - calling `ResolveType()' on them, directly assign their `Type'. - -2003-11-08 Martin Baulig - - * class.cs (TypeContainer.GetClassBases): Use TypeExpr's for the - return value and the `out parent' parameter. - (TypeContainer.DefineType): Moved the CS0644 check into - GetClassBases(). Don't pass the interface types to the - `builder.DefineType()'/`builder.DefineNestedType()', but resolve - them later and then call `TypeBuilder.AddInterfaceImplementation()'. - - * ecore.cs (TypeExpr.IsAttribute): New property. - (TypeExpr.GetInterfaces): New method. - - * interface.cs (Interface.GetInterfaceTypeByName): Return a - TypeExpr instead of a Type. - (Interface.GetInterfaceBases): Return TypeExpr's instead of Type's. - (Interface.DefineType): Don't pass the interface types to the - `builder.Definetype()'/`builder.DefineNestedType()', but resolve - them later and then call `TypeBulider.AddInterfaceImplementation()'. - - * typemanager.cs (TypeManager.AddUserType): Take a `TypeExpr[]' - instead of a `Type[]'. - (TypeManager.RegisterBuilder): Likewise. - (TypeManager.AddUserInterface): Likewise. - (TypeManager.ExpandInterfaces): Take a `Type[]' instead of a - `Type[]' and also return a `TypeExpr[]'. - (TypeManager.GetInterfaces): Return a `TypeExpr[]'. - -2003-11-08 Martin Baulig - - * decl.cs (DeclSpace.ResolveTypeExpr): Return a TypeExpr, not an - Expression. - -2003-11-08 Martin Baulig - - * decl.cs (DeclSpace.GetTypeResolveEmitContext): Call - TypeManager.ResolveExpressionTypes(). - - * ecore.cs (Expression.ResolveAsTypeTerminal): Return a TypeExpr - instead of an Expression. - (TypeExpr): This is now an abstract base class for `TypeExpression'. - (TypeExpression): New public class; formerly known as `TypeExpr'. - - * expression.cs (ComposedCast): Derive from TypeExpr. - - * typemanager.cs (TypeManager.system_*_expr): These are now - TypExpr's instead of Expression's. - (TypeManager.ResolveExpressionTypes): New public static function; - called from DeclSpace.GetTypeResolveEmitContext() to resolve all - of them. - -2003-11-06 Miguel de Icaza - - * expression.cs (New.DoResolve): Do not dereference value that - might be a null return. - - * statement.cs (Block.EmitMeta): Use the Const.ChangeType to make - sure that the constant value has the right type. Fixes an - unreported bug, similar to 50425. - - * const.cs (Const.LookupConstantValue): Call - ImplicitStandardConversionExists before doing a conversion to - avoid havng the TypeManager.ChangeType do conversions. - - Reduced the number of casts used - - (Const.ChangeType): New routine to enable reuse of the constant - type changing code from statement. - - * typemanager.cs (ChangeType): Move common initialization to - static global variables. - - Fixes #50425. - - * convert.cs (ImplicitReferenceConversion): Somehow we allowed - every value type to go through, even if it was void. Fix that. - - * cs-tokenizer.cs: Use is_identifier_start_character on the start - character of the define, and the is_identifier_part_character for - the rest of the string. - -2003-11-05 Miguel de Icaza - - * expression.cs (UnaryMutator.EmitCode): When I updated - LocalVariableReference.DoResolve, I overdid it, and dropped an - optimization done on local variable references. - -2003-11-04 Miguel de Icaza - - * ecore.cs: Convert the return from Ldlen into an int. - -2003-10-20 Miguel de Icaza - - * decl.cs (DeclSpace.GetAccessLevel): Handle NotPublic case for - the accessibility, this is a special case for toplevel non-public - classes (internal for instance). - -2003-10-20 Nick Drochak - - * ecore.cs: Fix typo and build. Needed another right paren. - -2003-10-19 Miguel de Icaza - - * ecore.cs: Applied fix from Ben Maurer. We were handling in the - `internal' case regular and protected, but not allowing protected - to be evaluated later. Bug 49840 - -2003-10-15 Miguel de Icaza - - * statement.cs (Switch.TableSwitchEmit): Compare the upper bound - to kb.Nlast, and not the kb.nFirst to isolate the switch - statement. - - Extract the underlying type, so enumerations of long/ulong are - treated like long/ulong. - -2003-10-14 Miguel de Icaza - - * expression.cs (New): Overload the meaning of RequestedType to - track the possible creation of the NewDelegate type, since - DoResolve is invoked more than once for new constructors on field - initialization. - - See bugs: #48800 and #37014 - - * cs-parser.jay (declare_local_constants): Take an arraylist - instead of a single constant. - - (local_constant_declaration): It should take a - constant_declarators, not a constant_declarator. Fixes 49487 - - * convert.cs: Fix error report. - -2003-10-13 Jackson Harper - - * typemanager.cs (TypeToCoreType): Add float and double this fixes - bug #49611 - -2003-10-09 Martin Baulig - - * class.cs (MethodCore): Added additional `DeclSpace ds' argument - to the .ctor. - (MethodCore.DoDefineParameters): Removed the TypeContainer - argument; use the DeclSpace which was passed to the .ctor instead. - (MethodCore.CheckParameter): Take a DeclSpace instead of a - TypeContainer; we only need a DeclSpace here. - -2003-10-09 Martin Baulig - - * class.cs (MethodData): Added additional `DeclSpace ds' argument - to the .ctor. - (MethodData.Define, MethodData.Emit): Pass the `ds' to the - EmitContext's .ctor. - -2003-10-09 Martin Baulig - - * decl.cs (DeclSpace.AsAccessible): Moved here from TypeContainer. - (AccessLevel, CheckAccessLevel, GetAccessLevel): They're used by - AsAccessible(), moved them as well. - - * class.cs (TypeContainer.AsAccessible): Moved to DeclSpace. - -2003-10-08 Atsushi Enomoto - - * cs-parser.jay : Renamed yyName to yyNames related to jay. - -2003-10-07 Miguel de Icaza - - * expression.cs (Binary.Emit.GreatherThanOrEqual): Fix the code - generation for >=, as spotted by Paolo, bug 48679. - Patch from David Waite. - - * cs-tokenizer.cs: Add handling for #pragma. - - * cs-parser.jay: Allow for both yield and yield return in the - syntax. The anti-cobolization of C# fight will go on! - - * class.cs (TypeBuilder.DefineType): Catch error condition here - (Parent.DefineType erroring out and returning null). - - * expression.cs (ArrayCreation.EmitDynamicInitializers): When - coping with enumerations variables, we were mistakenly processing - them as a regular value type instead of built-in types. Fixes the - bug #48063 - - * typemanager.cs (IsBuiltinOrEnum): New method. - -2003-09-30 Miguel de Icaza - - * cs-parser.jay: Upgrade: yield now needs the return clause. - -2003-09-19 Martin Baulig - - * decl.cs (MemberCache.SetupCacheForInterface): Take a - `MemberCache parent' argument. Normally, an interface doesn't - have a parent type except System.Object, but we use this in gmcs - for generic type parameters. - -2003-09-18 Martin Baulig - - * typemanager.cs (TypeHandle.ctor): Set `IsInterface' solely based - on `type.IsInterface'; don't check whether the type has a parent - to determine whether it's an interface. - -2003-09-15 Martin Baulig - - * class.cs (TypeContainer.DefineType): Added an error flag to - avoid reporting duplicate CS0146's ("class definition is - circular."). - - * driver.cs (Driver.MainDriver): Abort if - RootContext.ResolveTree() reported any errors. - -2003-09-07 Martin Baulig - - * report.cs (Error, Warning): Added overloaded versions which take - a `params object[] args' and call String.Format(). - -2003-09-07 Martin Baulig - - * decl.cs (DeclSpace..ctor): Don't call - NamespaceEntry.DefineName() here; do it in RecordDecl() which is - called from Tree.RecordDecl(). Fixes the CS0101 reporting. - (DeclSpace.RecordDecl): New method. - - * tree.cs (Tree.RecordDecl): Call ds.RecordDecl(). - -2003-09-02 Ravi Pratap - - * attribute.cs (CheckAttributeTarget): Ensure that we allow return - value attributes to be applied to ParameterBuilders. - - * class.cs (MethodCore.LabelParameters): Make static and more - generic so that it can be used from other places - like interface - methods, for instance. - - * interface.cs (Interface.Emit): Call LabelParameters before - emitting attributes on the InterfaceMethod. - -2003-08-26 Martin Baulig - - * ecore.cs (SimpleName.SimpleNameResolve): Look for members before - resolving aliases; fixes #47927. - -2003-08-26 Martin Baulig - - * statement.cs (Using.DoResolve): This is internally emitting a - try/finally clause, so we need to set ec.NeedExplicitReturn if we - do not always return. Fixes #47681. - -2003-08-26 Martin Baulig - - * decl.cs (MemberCore): Moved WarningNotHiding(), - Error_CannotChangeAccessModifiers() and CheckMethodAgainstBase() - into MemberBase. - (AdditionResult): Make this nested in DeclSpace. - (DeclSpace.ctor): The .ctor now takes an additional NamespaceEntry - argument; call NamespaceEntry.Define() unless we're nested in a - class or struct. - - * namespace.cs (Namespace.DefineName): New public function. This - is called from DeclSpace's .ctor to add - (Namespace.Lookup): Include DeclSpaces in the lookup. - - * class.cs (Operator): Derive from MemberBase, not MemberCore. - - * const.cs (Const): Derive from MemberBase, not MemberCore. - -2003-08-25 Martin Baulig - - * convert.cs (Convert.ExplicitReferenceConversion): When - converting from an interface type to a class, unbox if the target - type is a struct type. Fixes #47822. - -2003-08-24 Gonzalo Paniagua Javier - - * typemanager.cs: fixed the values of MethodFlags. Closes #47855 and - #47854. - -2003-08-22 Martin Baulig - - * class.cs (TypeManager.DefineType): When defining a nested type, - call DefineType() on our parent; fixes #47801. - -2003-08-22 Martin Baulig - - * class.cs (MethodData.Define): While checking if a method is an - interface implementation, improve the test a bit more to fix #47654. - -2003-08-22 Martin Baulig - - * expression.cs (Probe.DoResolve): Check whether `expr' resolved - correctly; fixes #47722. - -2003-08-22 Martin Baulig - - * expression.cs (UnaryMutator.ResolveVariable): If the target is a - LocalVariableReference, ensure it's not read-only. Fixes #47536. - - * statement.cs (Fixed.DoResolve): Make all variables read-only. - -2003-08-22 Martin Baulig - - * ecore.cs (FieldExpr.DoResolveLValue): Static read-only fields - can only be assigned in static constructors. Fixes #47161. - -2003-08-22 Martin Baulig - - Rewrote and improved the flow analysis code. - - * flowbranching.cs (FlowBranching): Make this class abstract. - (FlowBranching.CreateBranching): New static function to create a - new flow branching. - (FlowBranchingBlock, FlowBranchingException): New classes. - (FlowBranching.UsageVector.Type): New public readonly field. - (FlowBranching.UsageVector.Breaks): Removed the setter. - (FlowBranching.UsageVector.Returns): Removed the setter. - (FlowBranching.UsageVector): Added Break(), Return(), - NeverReachable() and Throw() methods to modify the reachability. - (FlowBranching.UsageVector.MergeChildren): Removed, this is now - done by FlowBranching.Merge(). - (FlowBranching.UsageVector.MergeChild): New method; merges the - merge result into the current vector. - (FlowBranching.Merge): New abstract method to merge a branching. - -2003-08-12 Martin Baulig - - * expression.cs (Indirection.CacheTemporaries): Create the - LocalTemporary with the pointer type, not its element type. - -2003-08-10 Miguel de Icaza - - * cs-parser.jay: FIRST_KEYWORD, LAST_KEYWORD: used to know if a - token was a keyword or not. - - Add `error' options where an IDENTIFIER was expected; Provide - CheckToken and CheckIdentifierToken convenience error reporting - functions. - - Do not use `DeclSpace.Namespace', use `DeclSpace.NamespaceEntry'. - - * decl.cs: Rename `NamespaceEntry Namespace' public field into - NameSpaceEntry NameSpaceEntry. - - (LookupInterfaceOrClass): Avoid creating a full qualified name - from namespace and name: avoid doing lookups when we know the - namespace is non-existant. Use new Tree.LookupByNamespace which - looks up DeclSpaces based on their namespace, name pair. - - * driver.cs: Provide a new `parser verbose' to display the - exception thrown during parsing. This is turned off by default - now, so the output of a failure from mcs is more graceful. - - * namespace.cs: Track all the namespaces defined in a hashtable - for quick lookup. - - (IsNamespace): New method - -2003-08-09 Miguel de Icaza - - * namespace.cs: Remove redundant call; Avoid using MakeFQN when - we know that we need to concatenate (full typename can never be - null). - - * class.cs: ditto. - - * statement.cs: Use a bitfield; Do not initialize to null things - which are done by the constructor by default. - - * cs-parser.jay: bug fix, parameter was 4, not 3. - - * expression.cs: Just use the property; - - * statement.cs: No need for GetVariableInfo method. - -2003-08-08 Martin Baulig - - * flowanalysis.cs (FlowReturns): This is now nested in the - `FlowBranching' class. - (MyBitVector): Moved this here from statement.cs. - (FlowBranching.SiblingType): New enum type. - (FlowBranching.CreateSibling): Added `SiblingType' argument. - -2003-08-07 Martin Baulig - - * flowanalysis.cs (FlowBranchingType): This is now nested in the - `FlowBranching' class and called `BranchingType'. - -2003-08-07 Martin Baulig - - * flowanalysis.cs: Moved all the control flow analysis code into - its own file. - -2003-08-07 Martin Baulig - - * assign.cs (Assign.DoResolve): `target' must either be an - IAssignMethod or an EventAccess; report a CS0131 otherwise. Fixes - #37319. - -2003-08-07 Miguel de Icaza - - * expression.cs (BinaryMethod): This kind of expression is created by the - Binary class if it determines that the operator has to be handled - by a method. - - (BinaryDelegate): This kind of expression is created if we are - dealing with a + or - operator on delegates. - - (Binary): remove method, argumetns, and DelegateOperator: when - dealing with methods, - - * ecore.cs (EventExpr.EmitAddOrRemove): Update to new layout. - - * statement.cs (Block): use bitfields for the three extra booleans - we had in use. Remove unused topblock parameter. - - * codegen.cs: Remove unecessary argument to Block.EmitTopBlock - - * assign.cs: Drop extra unneeded tests. - -2003-08-06 Miguel de Icaza - - * iterators.cs (Mapvariable): provide a mechanism to use prefixes. - - * statement.cs (Foreach): Use VariableStorage instead of - LocalBuilders. - - * codegen.cs (VariableStorage): New class used by clients that - require a variable stored: locals or fields for variables that - need to live across yield. - - Maybe provide a convenience api for EmitThis+EmitLoad? - - (GetTemporaryLocal, FreeTemporaryLocal): Recycle - these bad boys. - -2003-08-05 Miguel de Icaza - - * codegen.cs (RemapLocal, RemapLocalLValue, RemapParameter, - RemapParameterLValue): New methods that are used to turn a - precomputed FieldInfo into an expression like this: - - instance.FieldInfo - - The idea is to use this instead of making LocalVariableReference - have more than one meaning. - - * cs-parser.jay: Add error production to BASE. - - * ecore.cs: Deal with TypeManager.GetField returning null, which - is now a valid return value. - - (FieldExprNoAddress): New expression for Fields whose address can - not be taken. - - * expression.cs (LocalVariableReference): During the resolve - phases, create new expressions if we are in a remapping context. - Remove code that dealt with remapping here. - - (ParameterReference): same. - - (ProxyInstance): New expression, like the `This' expression, but - it is born fully resolved. We know what we are doing, so remove - the errors that are targeted to user-provided uses of `this'. - - * statement.cs (Foreach): our variable is now stored as an - Expression; During resolution, follow the protocol, dont just - assume it will return this. - -2003-08-06 Martin Baulig - - * support.cs (SeekableStreamReader.cs): New public class. - - * cs-tokenizer.cs, cs-parser.jay, driver.cs: Use the new - SeekableStreamReader instead of the normal StreamReader. - -2003-08-04 Martin Baulig - - * cs-parser.jay (CLOSE_PARENS_CAST, CLOSE_PARENS_NO_CAST, - CLOSE_PARENS_OPEN_PARENS, CLOSE_PARENS_MINUS): New tokens to - deambiguate casts and delegate invocations. - (parenthesized_expression): Use the new tokens to ensure this is - not a cast of method invocation. - - * cs-tokenizer.cs (is_punct): Return one of the new special tokens - when reading a `)' and Deambiguate_CloseParens () was previously - called. - - * expression.cs (ParenthesizedExpression): New class. This is - just used for the CS0075 test. - (Binary.DoResolve): Check for CS0075. - -2003-07-29 Ravi Pratap - - * expression.cs (Invocation.MakeUnionSet): Patch from Lluis - Sanchez : use TypeManager.ArrayContainsMethod instead of a direct - reference comparison. - - (TypeManager.ArrayContainsMethod): When we have a MethodInfo, also - examine the ReturnType for equality - this is necessary in the - cases of implicit and explicit operators whose signature also - includes the return type. - -2003-07-26 Miguel de Icaza - - * namespace.cs: Cache the result of the namespace computation, - instead of computing it every time. - -2003-07-24 Miguel de Icaza - - * decl.cs: Use a global arraylist that we reuse over invocations - to avoid excesive memory consumption. Reduces memory usage on an - mcs compile by one meg (45 average). - - * typemanager.cs (LookupTypeReflection): In .NET pointers are - private, work around that. - -2003-07-23 Miguel de Icaza - - * literal.cs (IntLiteral): Define Zero and One static literals. - - * cs-parser.jay (integer_literal): use static literals to reduce - memory usage for the most used literals (0, 1 and -1). 211kb - reduced in memory usage. - - Replace all calls to `new ArrayList' with `new - ArrayList(4)' which is a good average number for most allocations, - and also requires only 16 bytes of memory for its buffer by - default. - - This reduced MCS memory usage in seven megabytes for the RSS after - bootstrapping. - -2003-07-28 Ravi Pratap - - * expression.cs (Invocation.OverloadResolve): Fix the algorithm to - handle params methods the correct way by forming only one - applicable set with params and normal methods in them. Earlier we - were looking at params methods only if we found no normal methods - which was not the correct thing to do. - - (Invocation.BetterFunction): Take separate arguments indicating - when candidate and the best method are params methods in their - expanded form. - - This fixes bugs #43367 and #46199. - - * attribute.cs: Documentation updates. - - (CheckAttribute): Rename to CheckAttributeTarget. - (GetValidPlaces): Rename to GetValidTargets. - - * expression.cs (Invocation.IsParamsMethodApplicable): Fix trivial - bug - use Convert.ImplicitConversion, not ImplicitUserConversion! - - Fixes bug #44468. - -2003-07-28 Martin Baulig - - * class.cs (TypeContainer.DefineMembers): Use the base type's full - name when looking up the base class of a nested class. Fixes #46977. - -2003-07-26 Martin Baulig - - * expression.cs (Indexers.Indexer): New nested struct; contains - getter, setter and the indexer's type. - (Indexers.Properties): This is now an ArrayList of - Indexers.Indexer's. - (IndexerAccess.DoResolveLValue): Correctly set the type if the - indexer doesn't have any getters. - - * assign.cs (Assign.DoResolve): Also do the implicit conversions - for embedded property and indexer assignments. - -2003-07-26 Martin Baulig - - * cs-tokenizer.cs (Tokenizer.xtoken): Report a CS1040 if a - preprocessor directive is not the first non-whitespace character - on a line. - -2003-07-26 Martin Baulig - - * namespace.cs (NamespaceEntry.Lookup): New method; rewrote the - namespace parsing, follow the spec more closely. - - * rootcontext.cs (RootContext.NamespaceLookup): Use the new - NamespaceEntry.Lookup(). - -2003-07-25 Martin Baulig - - * MethodCore.cs (OverridesSomething): New public field; it's set - from TypeContainer.DefineMembers if this method overrides - something (which doesn't need to be a method). Fix #39462. - -2003-07-25 Ravi Pratap - - * typemanager.cs (GetMembers): Ensure that the list of members is - reversed. This keeps things in sync. - - * attribute.cs (Attribute.CheckAttribute): Break as soon as we - find an AttributeUsage attribute. - - * expression.cs (Invocation.OverloadResolve): Perform the check - which disallows Invoke to be directly called on a Delegate. - - (Error_InvokeOnDelegate): Report error cs1533. - -2003-07-25 Martin Baulig - - * expression.cs (Indexers.GetIndexersForType): Only look in the - interface hierarchy if the requested type is already an - interface. Fixes #46788 while keeping #46502 fixed. - -2003-07-25 Martin Baulig - - * class.cs (TypeContainer.DefineMembers): Check whether all - readonly fields have been assigned and report warning CS0649 if - not. - - * statement.cs (LocalInfo.IsFixed): Always return true if this is - a valuetype. - -2003-07-24 Ravi Pratap - - * decl.cs (MemberCache.AddMethods): Reverse the order of the array - returned from GetMethods to make things consistent with the - assumptions MCS makes about ordering of methods. - - This should comprehensively fix bug #45127 and it does :-) - - * ecore.cs (MethodGroupExpr.DeclaringType): Correct bug - the - ordering is actually reverse. - - * Clean up some debug messages I left lying around. - - * interface.cs (Populate*): Get rid of code which emits attributes - since the stage in which we emit attributes is the 'Emit' stage, - not the define stage. - - (Emit): Move attribute emission for interface members here. - -2003-07-22 Ravi Pratap - - * expression.cs (Invocation.OverloadResolve): Follow the spec more - closely: we eliminate methods in base types when we have an - applicable method in a top-level type. - - Please see section 14.5.5.1 for an exact description of what goes - on. - - This fixes bug #45127 and a host of other related to corlib compilation. - - * ecore.cs (MethodGroupExpr.DeclaringType): The element in the - array is the method corresponding to the top-level type (this is - because of the changes made to icall.c) so we change this - accordingly. - - (MethodGroupExpr.Name): This too. - - * typemanager.cs (GetElementType): New method which does the right - thing when compiling corlib. - - * everywhere: Make use of the above in the relevant places. - -2003-07-22 Martin Baulig - - * cs-parser.jay (invocation_expression): Moved - `OPEN_PARENS expression CLOSE_PARENS unary_expression' here from - `cast_expression', but create a InvocationOrCast which later - resolves to either an Invocation or a Cast. - - * ecore.cs (ExpressionStatement.ResolveStatement): New virtual - method; call this before EmitStatement() to make sure that this - expression can be used as a statement. - - * expression.cs (InvocationOrCast): New class; resolves to either - an Invocation or a Cast. - - * statement.cs (StatementExpression): Call ResolveStatement() on - the ExpressionStatement before emitting it. - -2003-07-21 Martin Baulig - - * expression.cs (Invocation.VerifyArgumentsCompat): Check whether - `ref' and `out' attributes match; fixes #46220. - (MemberAccess.ResolveMemberAccess): You can't reference a type - through an expression; fixes #33180. - (Indexers.GetIndexersForType): Don't return the indexers from - interfaces the class implements; fixes #46502. - -2003-07-21 Martin Baulig - - * class.cs (TypeContainer.CheckPairedOperators): Added CS0660 and - CS0661 checks; fixes bug #30442. - -2003-07-21 Martin Baulig - - * decl.cs (AdditionResult): Added `Error'. - - * enum.cs (AddEnumMember): Report a CS0076 if name is `value__'. - - * typemanager.cs (TypeManager.ChangeType): Catch exceptions; - makes cs0031.cs actually work. - -2003-07-20 Martin Baulig - - * namespace.cs: Fixed that bug which caused a crash when compiling - the debugger's GUI. - -2003-07-20 Miguel de Icaza - - * typemanager.cs (LookupTypeReflection): Never expose types which - are NotPublic, NestedPrivate, NestedAssembly, or - NestedFamANDAssem. We used to return these, and later do a check - that would report a meaningful error, but the problem is that we - would not get the real match, if there was a name override. - -2003-07-18 Miguel de Icaza - - * namespace.cs (Namespace, Name): Do not compute the namespace - name dynamically, compute it in the constructor. This reduced - memory usage by 1697 KB. - - * driver.cs: Use --pause to pause at the end. - -2003-07-17 Peter Williams - - * Makefile: Change the name of the test target so that it doesn't - conflict with the recursive test target. - -2003-07-17 Miguel de Icaza - - * expression.cs (LocalVariableReference.Emit, EmitAssign, - AddressOf): Do not use EmitThis, that was wrong, use the actual - this pointer. - -2003-07-15 Miguel de Icaza - - * class.cs (MethodData.Define): While checking if a method is an - interface implementation, improve the test: If we are not public - (use new test here: use the computed MethodAttributes directly, - instead of the parsed modifier flags) check if the `implementing' - method comes from an interface or not. - - * pending.cs (VerifyPendingMethods): Slightly better error - message. - - * makefile: add test target that does the mcs bootstrap. - -2003-07-16 Ravi Pratap - - * interface.cs (Define): Do nothing here since there are no - members to populate etc. Move the attribute emission out of here - since this was just totally the wrong place to put it. Attribute - application happens during the 'Emit' phase, not in the 'Define' - phase. - - (Emit): Add this method and move the attribute emission here - - * rootcontext.cs (EmitCode): Call the Emit method on interface - types too. - -2003-07-14 Ravi Pratap M - - * expression.cs (OverloadResolve): Report error only if Location - is not 'Null' which means that there was a probe going on. - -2003-07-14 Martin Baulig - - * expression.cs (ConditionalLogicalOperator): New public class to - implement user defined conditional logical operators. - This is section 14.11.2 in the spec and bug #40505. - -2003-07-14 Martin Baulig - - * ecore.cs (FieldExpr.DoResolveLValue): Fixed bug #46198. - -2003-07-14 Martin Baulig - - * codegen.cs (EmitContext.InFixedInitializer): New public field. - - * ecore.cs (IVariable.VerifyFixed): New interface method. - - * expression.cs (Unary.ResolveOperator): When resolving the `&' - operator, check whether the variable is actually fixed. Fixes bug - #36055. Set a variable definitely assigned when taking its - address as required by the spec. - - * statement.cs (LocalInfo.IsFixed): New field. - (LocalInfo.MakePinned): Set `IsFixed' to true. - -2003-07-14 Ravi Pratap M - - * attribute.cs (Attribute.Resolve): While doing a Member lookup - for .ctors, ensure that we only ask for members declared in the - attribute type (BindingFlags.DeclaredOnly). - - Fixes bug #43632. - - * expression.cs (Error_WrongNumArguments): Report error 1501 - correctly the way CSC does. - -2003-07-13 Martin Baulig - - * expression.cs (MemberAccess.ResolveAsTypeStep): Try to do a type - lookup on the fully qualified name, to make things like "X.X" work - where "X.X" is a fully qualified type name, but we also have a - namespace "X" in the using list. Fixes #41975. - -2003-07-13 Martin Baulig - - * assign.cs (Assign.GetEmbeddedAssign): New protected virtual - function. If we're a CompoundAssign, we need to create an embedded - CompoundAssign, not an embedded Assign. - (Assign.DoResolve): Make this work for embedded CompoundAssign's. - Fixes #45854. - -2003-07-13 Martin Baulig - - * typemanager.cs (TypeManager.IsNestedChildOf): Make this actually - work to fix bug #46088. - -2003-07-13 Ravi Pratap - - * class.cs (Operator.Emit): Do not emit attributes here - it is - taken care of by the Method class that we delegate too. This takes - care of bug #45876. - -2003-07-10 Martin Baulig - - * expression.cs (TypeOfVoid): New class. - (TypeOf): Report a CS0673 if it's System.Void. Fixes #42264. - -2003-07-10 Martin Baulig - - * class.cs (MethodCore.DoDefineParameters): Added CS0225 check; - bug #35957. - -2003-07-10 Martin Baulig - - * rootcontext.cs (RootContext.NamespaceLookup): Take a DeclSpace, - not a NamespaceEntry, so we can use DeclSpace.CheckAccessLevel(). - - * decl.cs (DeclSpace.FindType): Use DeclSpace.CheckAccessLevel(). - - * typemanager.cs (TypeManager.IsAccessibleFrom): Removed. - -2003-07-10 Martin Baulig - - * expression.cs (ArrayCreation): Don't use a byte blob for arrays - of decimal. Fixes #42850. - - NOTE: I also fixed the created byte blob, but this doesn't work on - the MS runtime and csc never produces any byte blobs for decimal - arrays. - -2003-07-10 Martin Baulig - - * statement.cs (StructInfo.GetStructInfo): Catch deep cycles in - structs; fixes #32068. - (Block.AddChildVariableNames): Fixed #44302. - -2003-07-07 Gonzalo Paniagua Javier - - * namespace.cs: fixed compilation with csc. It's bugzilla #44302. - -2003-07-07 Miguel de Icaza - - * attribute.cs: And this test is onger needed. - -2003-07-08 Martin Baulig - - * rootcontext.cs (RootContext.NamespaceLookup): Ignore - inaccessible types. Fixes #36313. - - * decl.cs (DeclSpace.FindType): Ignore inaccessible types. - - * namespace.cs (NamespaceEntry): Create implicit entries for all - namespaces; ie. if we have `namespace N1.N2.N3 { ... }', we create - implicit entries for N1.N2 and N1. - -2003-07-08 Martin Baulig - - Rewrote the handling of namespaces to fix a lot of the issues - wrt. `using' aliases etc. - - * namespace.cs (Namespace): Splitted this class into a - per-assembly `Namespace' and a per-file `NamespaceEntry'. - - * typemanager.cs (TypeManager.IsNamespace): Removed. - (TypeManager.ComputeNamespaces): Only compute namespaces from - loaded assemblies here, not the namespaces from the assembly we're - currently compiling. - -2003-07-08 Martin Baulig - - * rootcontext.cs, class.cs: Fixed the CS1530 reporting. - -2003-07-07 Miguel de Icaza - - * typemanager.cs: Reverted patch from Gonzalo, my previous patch - already fixed it. - - I thought about the memory savings here, but LookupTypeReflection - is used under already very constrained scenarios. Compiling - corlib or mcs only exposes one hit, so it would not really reduce - any memory consumption. - -2003-07-07 Gonzalo Paniagua Javier - - * typemanager.cs: fixes bug #45889 by only adding public types from - other assemblies to the list of known types. - -2003-07-07 Miguel de Icaza - - * attribute.cs (Attribute.Resolve): Add call to CheckAccessLevel - on the type we resolved. - -2003-07-05 Martin Baulig - - * pending.cs (PendingImplementation.ParentImplements): Don't - create the proxy if the parent is abstract. - - * class.cs (TypeContainer.DefineIndexers): Process explicit - interface implementations first. Fixes #37714. - -2003-07-04 Miguel de Icaza - - * expression.cs (MemberAccess.ResolveMemberAccess): Events are - defined recursively; but since we modify the input parameters - (left is set to `this' temporarily), we reset this value if the - left_is_explicit is false, which gives the original semantics to - the code. - - * literal.cs (NullPointer): new class used to represent a null - literal in a pointer context. - - * convert.cs (Convert.ImplicitReferenceConversion): Is the target - type is a pointer, use a NullPointer object instead of a - NullLiteral. Closes 43687 - - (ExplicitConversion): Convert pointer values using - the conv opcode to the proper type. - - * ecore.cs (New): change ValueTypeVariable property into a method, - that returns whether the valuetype is suitable for being used. - - * expression.cs (Binary.DoNumericPromotions): Only return if we - the int constant was a valid uint, and we can return both left and - right as uints. If not, we continue processing, to trigger the - type conversion. This fixes 39018. - - * statement.cs (Block.EmitMeta): During constant resolution, set - the CurrentBlock property on the emitcontext, so that we resolve - constants propertly. - -2003-07-02 Martin Baulig - - * codegen.cs (EmitContext.NeedExplicitReturn): New public variable. - (EmitContext.EmitTopBlock): Emit an explicit return if it's set. - - * statement.cs (Try.Resolve): Set ec.NeedExplicitReturn rather - than emitting it here. - - * statement.cs: Fixed some more flow analysis bugs. - -2003-07-02 Martin Baulig - - * class.cs (MethodData.Define): When implementing interface - methods, set Final unless we're Virtual. - - * decl.cs (MemberCore.CheckMethodAgainstBase): Make the CS0506 - check work for interface methods. - -2003-07-01 Martin Baulig - - * ecore.cs (EmitContext.This): Replaced this property with a - GetThis() method which takes a Location argument. This ensures - that we get the correct error location for a CS0188. - -2003-07-01 Miguel de Icaza - - * ecore.cs: (Convert.ConvertIntLiteral): Add test for - ImplicitStandardConversion. - - * class.cs (TypeContainer.GetClassBases): Small bug fix for 45649. - -2003-07-01 Zoltan Varga - - * expression.cs (ResolveOperator): Fix Concat (string, string, string) - optimization. - -2003-06-30 Miguel de Icaza - - * class.cs (Constructor.Define): Turn off initlocals for unsafe - constructors. - - (MethodData.Define): Turn off initlocals for unsafe methods. - -2003-06-29 Miguel de Icaza - - * decl.cs (DeclSpace.CheckAccessLevel): Make this routine - complete; Fixes #37521. - - * delegate.cs: Use Modifiers.TypeAttr to compute the - TypeAttributes, instead of rolling our own. This makes the flags - correct for the delegates. - -2003-06-28 Miguel de Icaza - - * class.cs (Constructor.Define): Set the private flag for static - constructors as well. - - * cs-parser.jay (statement_expression): Set the return value to - null, to avoid a crash when we catch an error. - -2003-06-24 Miguel de Icaza - - * cs-parser.jay: Applied patch from Jackson that adds support for - extern and unsafe modifiers to destructor declarations. - - * expression.cs: Report error 21 if the user is trying to index a - System.Array. - - * driver.cs: Add an error message, suggested by the bug report. - - * class.cs (TypeContainer.Emit): Only call EmitFieldInitializers - if we do not have a ": this ()" constructor initializer. Fixes 45149 - -2003-06-14 Miguel de Icaza - - * namespace.cs: Add some information to reduce FAQs. - -2003-06-13 Miguel de Icaza - - * cfold.cs (BinaryFold): BitwiseAnd, BitwiseOr: handle other - underlying enumeration types. Fixes #43915. - - * expression.cs: Treat ushort/short as legal values to be used in - bitwise operations. - -Wed Jun 4 13:19:04 CEST 2003 Paolo Molaro - - * delegate.cs: transfer custom attributes for paramenters from - the delegate declaration to Invoke and BeginInvoke. - -Tue Jun 3 11:11:08 CEST 2003 Paolo Molaro - - * attribute.cs: handle custom marshalers and emit marshal info - for fields, too. - -2003-05-28 Hector E. Gomez Morales - - * makefile.gnu: Added anonymous.cs to the compiler sources. - -2003-05-28 Miguel de Icaza - - * iterators.cs: Change the name of the proxy class to include two - underscores. - - * cs-parser.jay: Update grammar to include anonymous methods. - - * anonymous.cs: new file. - -2003-05-27 Miguel de Icaza - - * class.cs (Field.Define): Add missing test for pointers and - safety. - -2003-05-27 Ravi Pratap - - * expression.cs (ArrayAccess.GetStoreOpCode): For System.IntPtr, - we use the stobj opcode. - - (ArrayCreation.EmitDynamicInitializers): Revert Miguel's patch - since it wasn't the correct fix. - - It still is puzzling that we are required to use stobj for IntPtr - which seems to be a ValueType. - -2003-05-26 Miguel de Icaza - - * ecore.cs (SimpleName.SimpleNameResolve): Consider using aliases - during regular simple name resolution. Now, the trick is that - instead of returning for processing the simplename, we do a - TypeManager.LookupType (ie, a rooted lookup as opposed to a - contextual lookup type). If a match is found, return that, if - not, return for further composition. - - This fixes long-standing 30485. - - * expression.cs (ArrayCreation.EmitDynamicInitializers): When - using the address to initialize an object, do an Stobj instead of - using the regular Stelem. - - (IndexerAccess.Emit, IndexerAccess.EmitAssign): - Pass `is_base_indexer' to Invocation.EmitCall instead of false. - Because if we are a BaseIndexerAccess that value will be true. - Fixes 43643. - - * statement.cs (GotoCase.Resolve): Return after reporting an - error, do not attempt to continue. - - * expression.cs (PointerArithmetic.Emit): If our operand is a - long, convert our constants to match the operand before - multiplying. Convert to I type before adding. Fixes 43670. - -2003-05-14 Ravi Pratap - - * enum.cs (ImplicitConversionExists) : Rename to - ImplicitEnumConversionExists to remove ambiguity. - - * ecore.cs (NullCast): New type of cast expression class which - basically is very similar to EmptyCast with the difference being - it still is a constant since it is used only to cast a null to - something else - (eg. (string) null) - - * convert.cs (ImplicitReferenceConversion): When casting a null - literal, we return a NullCast. - - * literal.cs (NullLiteralTyped): Remove - I don't see why this - should be around anymore. - - The renaming (reported was slightly wrong). Corrections: - - ConvertImplicitStandard -> ImplicitConversionStandard - ConvertExplicitStandard -> ExplicitConversionStandard - - * expression.cs (StaticCallExpr.MakeSimpleCall): Resolve arguments - before passing them in ! - - * convert.cs (ImplicitConversionStandard): When comparing for - equal expr and target types, ensure that expr is not a - NullLiteral. - - In general, we must not be checking (expr_type == - target_type) in the top level conversion methods - (ImplicitConversion, ExplicitConversion etc). This checking is - done in the methods that they delegate to. - -2003-05-20 Miguel de Icaza - - * convert.cs: Move Error_CannotConvertType, - ImplicitReferenceConversion, ImplicitReferenceConversionExists, - ImplicitNumericConversion, ImplicitConversionExists, - ImplicitUserConversionExists, StandardConversionExists, - FindMostEncompassedType, FindMostSpecificSource, - FindMostSpecificTarget, ImplicitUserConversion, - ExplicitUserConversion, GetConversionOperators, - UserDefinedConversion, ConvertImplicit, ConvertImplicitStandard, - TryImplicitIntConversion, Error_CannotConvertImplicit, - ConvertImplicitRequired, ConvertNumericExplicit, - ExplicitReferenceConversionExists, ConvertReferenceExplicit, - ConvertExplicit, ConvertExplicitStandard from the ecore.cs into - its own file. - - Perform the following renames: - - StandardConversionExists -> ImplicitStandardConversionExists - ConvertImplicit -> ImplicitConversion - ConvertImplicitStandard -> ImplicitStandardConversion - TryImplicitIntConversion -> ImplicitIntConversion - ConvertImplicitRequired -> ImplicitConversionRequired - ConvertNumericExplicit -> ExplicitNumericConversion - ConvertReferenceExplicit -> ExplicitReferenceConversion - ConvertExplicit -> ExplicitConversion - ConvertExplicitStandard -> ExplicitStandardConversion - -2003-05-19 Martin Baulig - - * statement.cs (TypeInfo.StructInfo): Made this type protected. - (TypeInfo): Added support for structs having structs as fields. - - * ecore.cs (FieldExpr): Implement IVariable. - (FieldExpr.DoResolve): Call VariableInfo.GetSubStruct() to get the - VariableInfo for the field. - -2003-05-18 Martin Baulig - - * expression.cs (This.DoResolve): Report a CS0027 if we're - emitting a field initializer. - -2003-05-18 Martin Baulig - - * expression.cs (This.ResolveBase): New public function. - (This.DoResolve): Check for CS0188. - - * codegen.cs (EmitContext.This): Just call This.ResolveBase(), not - This.Resolve(). - - * ecore.cs (MethodGroupExpr.DoResolve): Set the - `instance_expression' to null if we don't have any non-static - methods. - -2003-05-18 Martin Baulig - - Reworked the way how local variables and parameters are handled by - the flow analysis code. - - * statement.cs (TypeInfo, VariableMap): New public classes. - (VariableInfo): New public class. This is now responsible for - checking whether a variable has been assigned. It is used for - parameters and local variables. - (Block.EmitMeta): Take the InternalParameters as argument; compute - the layout of the flow vectors here. - (Block.LocalMap, Block.ParameterMap): New public properties. - (FlowBranching): The .ctor doesn't get the InternalParameters - anymore since Block.EmitMeta() now computes the layout of the flow - vector. - (MyStructInfo): This class is now known as `StructInfo' and nested - in `TypeInfo'; we don't access this directly anymore. - - * ecore.cs (IVariable): Added `VariableInfo VariableInfo' - property and removed IsAssigned(), IsFieldAssigned(), - SetAssigned() and SetFieldAssigned(); we now call them on the - VariableInfo so we don't need to duplicate this code everywhere. - - * expression.cs (ParameterReference): Added `Block block' argument - to the .ctor. - (LocalVariableReference, ParameterReference, This): The new - VariableInfo class is now responsible for all the definite - assignment stuff. - - * codegen.cs (EmitContext.IsVariableAssigned, SetVariableAssigned, - IsParameterAssigned, SetParameterAssigned): Removed. - -2003-05-18 Martin Baulig - - * typemanager.cs (InitCoreTypes): Try calling - SetCorlibTypeBuilders() with 4 args; if that fails, fall back to - the 3-args-version. Corlib now also needs our `void_type'. - (GetMethod): Added overloaded version which takes an optional - `bool report_errors' to allow lookups of optional methods. - -2003-05-12 Martin Baulig - - * statement.cs (VariableInfo): Renamed to LocalInfo since it's - only used for locals and not for parameters. - -2003-05-12 Miguel de Icaza - - * support.cs (InternalParameters.ParameterType): Return the - ExternalType of the parameter. - - * parameter.cs (Parameter.ExternalType): drop the two arguments, - they were unused. - -2003-05-11 Miguel de Icaza - - * class.cs (MethodData.Define): Do not set the `newslot' on - interface members, if they are also flagged as "override". - - * expression.cs (UnaryMutator.EmitCode): Simple workaround to emit - better code for ++i and i++. This only works for static fields - and local variables. - - * typemanager.cs (LookupDeclSpace): Add new method, sometimes we - want to pull the DeclSpace out of the builder_to_declspace instead - of the TypeBuilder (like in TypeContainer.FindMembers). - - * class.cs (TypeContainer.FindMembers): Use LookupDeclSpace - instead of LookupTypeContainer. Fixes the crash on .NET for - looking up interface members. - - * const.cs: Create our own emit context during the Definition - stage, so that constants are evaluated in the proper context, when - a recursive definition happens. - -2003-05-11 Martin Baulig - - * statement.cs (Block.CreateSwitchBlock): New method. Creates a - new block for a switch section. - (Block.AddLabel, Block.LookupLabel): If we're a switch section, do - the adding/lookup in the switch block. Fixes #39828. - -2003-05-09 Miguel de Icaza - - * expression.cs (UnaryMutator.LoadOneAndEmitOp): Missing - functionality: I needed to convert the data after I had performed - the add/sub operation into the operands type size. - - * ecore.cs (ImplicitReferenceConversion): When boxing an interface - pass the type for the box operation, otherwise the resulting - object would have been of type object. - - (BoxedCast): Add constructor to specify the type to box as. - -2003-05-07 Miguel de Icaza - - * iterators.cs: I was reusing the `count' variable inadvertently, - take steps to not allow this to happen. - -2003-05-06 Miguel de Icaza - - * attribute.cs (Attribute.Resolve): Params attributes are encoded - by creating an array at the point where the params starts and - putting all those arguments there, then adjusting the size of the - array. - -2003-05-05 Miguel de Icaza - - * expression.cs (New.AddressOf): Implement interface - IMemoryLocation. This is used when the `new' operator is used in - the context of an invocation to a method on a value type. - - See http://bugzilla.ximian.com/show_bug.cgi?id=#42390 for an - example. - - * namespace.cs: Also check the using aliases here. - - * driver.cs: Move the test for using validity after the types have - been entered, so we do a single pass that also includes the using - aliases. - - * statement.cs (Try.Resolve): Avoid crashing if there is a failure - in the regular case. CreateSiblingForFinally is doing extra - error checking. - - * attribute.cs (GetAttributeArgumentExpression): Store the result - on an out value, and use the return value to indicate failure - instead of using null (which is a valid return for Constant.GetValue). - - * statement.cs: Perform the analysis flow for the increment - portion after the statement, because this will be the real flow of - execution. Fixes #42385 - - * codegen.cs (EmitContext.EmitArgument, - EmitContext.EmitStoreArgument): New helper functions when the - RemapToProxy flag is set. - - * expression.cs (ParameterReference.EmitLdarg): Expose this useful - function. - - Add support for remapping parameters. - - * iterators.cs: Propagate parameter values; Store parameter - values in the proxy classes. - -2003-05-04 Miguel de Icaza - - * ecore.cs (FieldExpr): Fix an obvious bug. static fields do not - need a proxy reference; I do not know what I was thinking - - * cs-parser.jay (constructor_initializer): catch another error, - and display nice message. - - (field_declaration): catch void field declaration - to flag a better error. - - * class.cs (MemberBase.CheckBase): Report an error instead of a - warning if a new protected member is declared in a struct. - (Field.Define): catch the error of readonly/volatile. - - * ecore.cs (FieldExpr.EmitAssign): reuse the field lookup. - - (FieldExpr.AddressOf): ditto. Catch error where the address of a - volatile variable is taken - -2003-05-02 Miguel de Icaza - - * statement.cs (Fixed.Resolve): Report an error if we are not in - an unsafe context. - -2003-05-01 Miguel de Icaza - - * typemanager.cs: reuse the code that handles type clashes for - delegates and enumerations. - - * class.cs (Report28): Always report. - - * expression.cs (EncodeAsAttribute): Allow nulls here. - -2003-04-28 Miguel de Icaza - - * attribute.cs (Attribute.GetAttributeArgumentExpression): Moved - the functionality for testing whether an expression is valid for - an attribute here. Also handle the case of arrays of elements - being stored. - - * expression.cs (ArrayCreation.EncodeAsAttribute): Add support for - encoding a linear array into an array of objects that are suitable - to be passed to an CustomAttributeBuilder. - - * delegate.cs: Check unsafe types being used outside of an Unsafe context. - - * ecore.cs: (FieldExpr): Handle field remapping here. - - * iteratators.cs: Pass the instance variable (if the method is an - instance method) to the constructors, so we can access the field - variables on the class. - - TODO: Test this with structs. I think the THIS variable on - structs might have to be a pointer, and not a refenrece - -2003-04-27 Miguel de Icaza - - * codegen.cs (EmitContext.Mapvariable): Adds a mechanism to map - local variables to fields in a proxy class. - - * iterators.cs (PopulateProxy): Rename our internal fields to - . - Create a field if we are an instance method, so we can - reference our parent container variables. - (MapVariable): Called back from the EmitContext code to enter a - new variable to field mapping into the proxy class (we just create - a FieldBuilder). - - * expression.cs - (LocalVariableReference.{Emit,EmitAssign,AddressOf}): Add support - for using the remapped locals to fields. - - I placed the code here, because that gives the same semantics to - local variables, and only changes the Emit code. - - * statement.cs (Fixed.Resolve): it is not allowed to have fixed - statements inside iterators. - (VariableInfo): Add a FieldBuilder for the cases when we are - remapping local variables to fields in a proxy class - - * ecore.cs (SimpleNameResolve): Avoid testing two times for - current_block != null. - - * statement.cs (Swithc.SimpleSwitchEmit): Removed code that did - not cope with strings, as it has been moved to the - TableSwitchEmit. Fixed bug in switch generation. - - * expression.cs (New.DoResolve): Provide more context for the user - when reporting an error. - - * ecore.cs (Expression.LoadFromPtr): Use ldind_i when loading - pointers. - - * expression.cs (MemberAccess.DoResolve): When we get a type back, - check the permissions for it. Note than in a type-resolution - context the check was already present in DeclSpace.ResolveType, - but was missing from the MemberAccess. - - (ArrayCreation.CheckIndices): warn if the user has - more nested levels of expressions, but there are no more - dimensions specified. Avoids crash on bug 41906. - -2003-04-26 Miguel de Icaza - - * statement.cs (Block): replace Implicit bool, for a generic - flags. - New flag: `Unchecked'. This is used during the EmitMeta phase - (which is out-of-line with the regular Resolve/Emit process for a - statement, as this is done ahead of time, but still gets a chance - to call constant resolve). - - (Block.Flags): new enum for adding a new flag. - - (Block.EmitMeta): track the state of unchecked. - - (Unchecked): Set the "UnChecked" flags on any blocks we enclose, - to enable constant resolution to work there as well. - -2003-04-22 Miguel de Icaza - - * typemanager.cs (ienumerable_type): Also look up - System.Collections.IEnumerable. - -2003-04-21 Miguel de Icaza - - TODO: Test more than one conditional per method. - - * class.cs (Indexer.Define): Report the location where the user is - referencing the unsupported feature. - - (MethodData): Overload the use of `conditionals' to - minimize the creation of needless ArrayLists. This saves roughly - 212kb on my machine. - - (Method): Implement the new IIteratorContainer interface. - (Method.SetYields): Implement the method by setting the ModFlags - to contain METHOD_YIELDS. - - * expression.cs (Unary.ResolveOperator): Use expr_type, not Expr, - which just got set to null. - - * iterators.cs: New file. - - (Yield, YieldBreak): New statements. - - * statement.cs (Return.Resolve): Flag an error if we are used in - an iterator method. - - * codegen.cs (InIterator): New flag set if the code is being - compiled in an iterator method. - - * modifiers.cs: New flag METHOD_YIELDS. This modifier is an - internal modifier, and we just use it to avoid adding extra - fields, as this is seldom used. - - * cs-parser.jay: Add yield_statement (yield and yield break). - - * driver.cs: New flag -v2 to turn on version 2 features. - - * cs-tokenizer.cs (Tokenizer): Add yield and __yield to the - hashtable when v2 is enabled. - -2003-04-20 Miguel de Icaza - - * typemanager.cs (TypeManager.NamespaceClash): Use to check if - there is already a namespace defined with this name. - - (TypeManager.InitCoreTypes): Remove the temporary workaround, as - people upgraded their corlibs. - - (TypeManager.CoreLookupType): Use LookupTypeDirect, as we - always use fully qualified types, no need to use the compiler - front end. - - (TypeManager.IsNamespace): Use binarysearch. - - * class.cs (AddClass, AddStruct, AddInterface, AddEvent, - AddDelegate): I did not quite use the new IsValid API properly: I - have to pass the short-name and the fullname. I was passing only - the basename instead of the fullname sometimes. - - (TypeContainer.DefineType): call NamespaceClash. - - * interface.cs (Interface.DefineType): use NamespaceClash before - defining the type. - - * delegate.cs (Delegate.DefineType): use NamespaceClash before - defining the type. - - * enum.cs: (Enum.DefineType): use NamespaceClash before - defining the type. - - * typemanager.cs (: 3-line patch that gives us some tasty 11% - speed increase. First, use the negative_hits cache when we get a - negative. Second, add the type with its full original name - instead of the new . and + encoded name (reflection uses + to - separate type from a nested type). Use LookupTypeReflection - directly which bypasses the type->name hashtable (that we already - know does not contain the type. - - * decl.cs (DeclSpace.ResolveTypeExpr): track the - location/container type. - - * driver.cs: When passing utf8, use directly the UTF8Encoding. - -2003-04-19 Miguel de Icaza - - * decl.cs (ResolveTypeExpr): Mirror check acess here too. - - * delegate.cs (NewDelegate.Resolve): Test whether an instance - method is being referenced in the method group from a static - context, and report error 120 if so. - - * expression.cs, ecore.cs (Error_UnexpectedKind): New name for - Error118. - - * typemanager.cs: Add intermediate namespaces (if a namespace A.B - is created, we create the A namespace). - - * cs-parser.jay: A namespace also introduces a DeclarationFound. - Fixes #41591 - -2003-04-18 Miguel de Icaza - - * typemanager.cs (GetReferenceType, GetPointerType): In .NET each - invocation to ModuleBuilder.GetType with the same values will - return a new type instance, so we need to cache its return - values. - - * expression.cs (Binary.ResolveOperator): Only allow the compare - operators on enums if they are of the same type. - - * ecore.cs (Expression.ImplicitReferenceConversion): handle target - types of ValueType on their own case. Before we were giving them - the same treatment as objects. - - * decl.cs (DeclSpace.IsValid): IsValid takes the short name and - fullname. Short name is used to compare against container name. - Fullname is used to check against defined namespace names. - - * class.cs (AddProperty, AddField, AddClass, AddStruct, AddEnum, - AddDelegate, AddEvent): Pass new parameter to DeclSpace.IsValid - - (Method.CheckBase): Call parent. - (MemberBase.CheckBase): Check for protected members on sealed - classes. - (PropertyBase.CheckBase): Call parent. - (Field.Define): Call parent. - - * report.cs: Negative error codes are now mapped to 8000 - code, - so that the display is render more nicely. - - * typemanager.cs: Do not use try/catch, instead report a regular - error. - - (GetPointerType, GetReferenceType): These methods provide - mechanisms to obtain the T* and T& from a T. We had the code - previously scattered around the code base, and it also used - TypeManager.LookupType that would go through plenty of caches. - This one goes directly to the type source. - - In some places we did the Type.GetType followed by - ModuleBuilder.GetType, but not in others, so this unifies the - processing as well. - - * namespace.cs (VerifyUsing): Perform a non-lazy approach to using - statements now that we have namespace information. - - * typemanager.cs (IsNamespace): New method, returns whether the - string presented is a namespace or not. - - (ComputeNamespaces): New public entry point, computes the list of - available namespaces, using the GetNamespaces API call in Mono, or - the slower version in MS.NET. - - Now before we start the semantic analysis phase, we have a - complete list of namespaces including everything that the user has - provided. - - Deleted old code to cache namespaces in .nsc files. - -2003-04-17 Miguel de Icaza - - * class.cs: (TypeContainer.DefineDefaultConstructor): Use the - class/struct location definition Location for the implicit - constructor location. - - (Operator.Define): Use the location of the operator for the - implicit Method definition. - - (Constructor.Emit): use the constructor location for the implicit - base initializer constructor. - - * ecore.cs: Remove ITypeExpression. This interface is now gone, - and the Expression class now contains two new methods: - - ResolveAsTypeStep and ResolveAsTypeTerminal. This is used to - isolate type lookup from the rest of the resolution process. - - Since we use Expressions to hold type definitions due to the way - we parse the input we have historically overloaded Resolve to - perform the Type lookups if a special flag is passed. Now this is - eliminated and two methods take their place. - - The differences in the two methods between xStep and xTerminal is - that xStep is involved in our current lookup system that uses - SimpleNames to compose a name, while xTerminal is used just to - catch the case where the simplename lookup failed. - -2003-04-16 Miguel de Icaza - - * expression.cs (ResolveMemberAccess): Remove redundant code. - TypeExpr expressions are always born fully resolved. - - * interface.cs (PopulateMethod): Do not lookup the types twice. - We were doing it once during SemanticAnalysis and once during - PopulateMethod. - - * cs-parser.jay: Due to our hack in the grammar, things like A.B[] - in local variable type definitions, were being returned as a - SimpleName (we decomposed everything into a string), that is - because primary_expression was being used instead of a type in the - grammar (reduce/reduce conflicts). - - The part that was wrong is that we converted the expression into a - string (an oversimplification in one hand, compounded with primary - expressions doing string concatenation). - - So things like: - - A.B.C [] x; - - Would return "A.B.C[]" as a SimpleName. This stopped things like - using clauses from working on this particular context. And a type - was being matched directly against "A.B.C[]". - - We now use the correct approach, and allow for ComposedCast to be - part of the unary expression. So the "A.B.C []" become a composed - cast of "A.B.C" (as a nested group of MemberAccess with a - SimpleName at the end) plus the rank composition "[]". - - Also fixes 35567 - -2003-04-10 Miguel de Icaza - - * decl.cs (CheckAccessLevel): Implement the NestedPrivate rules - for the access level checking. - - * class.cs: Cosmetic changes. Renamed `TypeContainer parent' to - `TypeContainer container', because I kept getting confused when I - was debugging this code. - - * expression.cs (Indexers): Instead of tracking getters/setters, - we now track them in parallel. We create one arraylist less, but - most importantly it is possible now for the LValue code to find a - matching get for a set. - - (IndexerAccess.DoResolveLValue): Update the code. - GetIndexersForType has been modified already to extract all the - indexers from a type. The code assumed it did not. - - Also make the code set the correct return type for the indexer. - This was fixed a long time ago for properties, but was missing for - indexers. It used to be void_type. - - (Binary.Emit): Test first for doubles instead of - floats, as they are more common. - - (Binary.EmitBranchable): Use the .un version of the branch opcodes - when dealing with floats and the <=, >= operators. This fixes bug - #39314 - - * statement.cs (Foreach.EmitArrayForeach): bug fix: The code used - to load the array value by emitting a load on the foreach variable - type. This was incorrect. - - We now emit the code to load an element using the the array - variable type, and then we emit the conversion operator. - - Fixed #40176 - -2003-04-10 Zoltan Varga - - * attribute.cs: Avoid allocation of ArrayLists in the common case. - -2003-04-09 Miguel de Icaza - - * class.cs (MethodSignature.InheritableMemberSignatureCompare): - test for protection before we test for signatures. - - (MethodSignature.ToString): implement. - - * expression.cs (Unary.TryReduceNegative): Add missing minus sign - to the case where we reduced into a LongConstant. - - * decl.cs (CheckAccessLevel): If the type is an array, we can not - depend on whether the information is acurrate, because the - Microsoft runtime will always claim that the array type is public, - regardless of the real state. - - If the type is a pointer, another problem happens: the type is - reported as non-public in Microsoft. - - In both cases we have to call CheckAccessLevel recursively with - the underlying type as the argument to be tested. - -2003-04-08 Miguel de Icaza - - * assign.cs (Assign.Emit): If we are dealing with a compound - assignment expression, we should use the code path that stores the - intermediate result in a temporary value. This fixes #40903. - - *expression.cs (Indirection.ToString): Provide ToString method for - debugging. - -2003-04-08 Zoltan Varga - - * class.cs: Null out fields holding references to Block objects so - they can be garbage collected. - - * expression.cs (OverloadResolve): Remove unused local. - -2003-04-07 Martin Baulig - - * codegen.cs (EmitContext.CurrentFile): New public field. - (EmitContext.Mark): Use the CurrentFile to check whether the - location is in the correct file. - (EmitContext.EmitTopBlock): Initialize CurrentFile here. - -2003-04-07 Martin Baulig - - * ecore.cs (Expression.ResolveBoolean): Don't call ec.Mark(). - - * codegen.cs (EmitContext.EmitTopBlock): Don't call Mark() on the - location. [FIXME: The location argument which gets passed to this - method is sometimes wrong!] - -2003-04-07 Nick Drochak - - * codegen.cs: Be more verbose when we can't find the symbol writer dll. - -2003-04-07 Miguel de Icaza - - * expression.cs (Indirection.EmitAssign): We were using the - temporary, but returning immediately instead of continuing the - EmitAssing flow. - -2003-04-06 Martin Baulig - - * ecore.cs (SimpleName.SimpleNameResolve): Don't report an error - if it's a nested child, but also deriving from the outer class. - See test 190.cs. - - * typemanager.cs (IsNestedChildOf): Make this work if it's a - nested child, but also deriving from the outer class. See - test-190.cs. - (FilterWithClosure): We may access private members of the outer - class if we're a nested child and deriving from the outer class. - (RealMemberLookup): Only set `closure_private_ok' if the - `original_bf' contained BindingFlags.NonPublic. - -2003-04-05 Martin Baulig - - * statement.cs (FlowBranching.UsageVector.MergeChildren): Fix bug #40670. - -2003-04-02 Miguel de Icaza - - * class.cs (Event.Define): Do not allow abstract events to have - initializers. - -2003-04-01 Miguel de Icaza - - * cs-parser.jay: Add error productions for ADD/REMOVE missing a - block in event declarations. - - * ecore.cs (FieldExpr.AddressOf): If our instance expression is a - value type, get its address. - - * expression.cs (Is.Emit): For action `LeaveOnStack' we were - leaving a class on the stack instead of a boolean value (int - 0/1). Change the code so we compare against null, and then the - result against zero. - - * class.cs (TypeContainer.GetClassBases): We were checking for the - parent class being sealed too late. - - * expression.cs (Binary.Emit): For <= and >= when dealing with - floating point values, use cgt.un and clt.un instead of cgt and - clt alone. - -2003-04-01 Zoltan Varga - - * statement.cs: Apply the same optimization as MS: skip the - GetEnumerator returning an IEnumerator, and use the one returning a - CharEnumerator instead. This allows us to avoid the try-finally block - and the boxing. - -2003-03-31 Gaurav Vaish - - * cs-parser.jay: Attributes cannot be applied to - namespaces. Fixes #40473 - -2003-03-31 Gonzalo Paniagua Javier - - * class.cs: - (Add*): check if the name is valid using the full name for constants, - fields, properties and events. - -2003-03-28 Miguel de Icaza - - * enum.cs (Enum.DefineType, Enum.IsValidEnumConstant): Also allow - char constants to be part of the enumeration. - - * expression.cs (Conditional.DoResolve): Add support for operator - true. Implements the missing functionality from 14.12 - - * class.cs (TypeContainer.CheckPairedOperators): Report error for missmatch on - operator true/false as required by the spec. - - * expression.cs (Unary.ResolveOperator): In LogicalNot, do an - implicit conversion to boolean. - - * statement.cs (Statement.ResolveBoolean): A boolean expression is - also one where the type implements `operator true'. - - * ecore.cs (Expression.GetOperatorTrue): New helper routine to - get an expression that will invoke operator true based on an - expression. - - (GetConversionOperators): Removed the hack that called op_True - here. - - (Expression.ResolveBoolean): Move this from Statement. - -2003-03-17 Miguel de Icaza - - * ecore.cs (FieldExpr): do not allow initialization of initonly - fields on derived classes - -2003-03-13 Martin Baulig - - * statement.cs (Block.Emit): Call ig.BeginScope() and - ig.EndScope() when compiling with debugging info; call - LocalBuilder.SetLocalSymInfo _after_ opening the scope. - -2003-03-08 Miguel de Icaza - - * expression.cs (Indexers): Do not construct immediately, allow - for new members to be appended as we go. Fixes 38143 - -2003-03-07 Gonzalo Paniagua Javier - - * expression.cs: save/restore context when resolving an unchecked - expression. - -2003-03-05 Miguel de Icaza - - * cfold.cs: Catch division by zero in modulus operator during - constant folding. - -2003-03-03 Miguel de Icaza - - * interface.cs (Interface.DefineMembers): Avoid defining members - twice. - -2003-02-27 Miguel de Icaza - - * driver.cs: handle the +/- options for -noconfig - - * statement.cs (Unckeched.Resolve): Also track the state of - unchecked in the Resolve phase. - -2003-02-27 Martin Baulig - - * ecore.cs (Expression.MemberLookup): Don't create a - MethodGroupExpr for something which is not a method. Fixes #38291. - -2003-02-25 Miguel de Icaza - - * class.cs (MemberBase.CheckParameters): Also check that the type - is unmanaged if it is a pointer. - - * expression.cs (SizeOf.Resolve): Add location information. - - * statement.cs (Block.EmitMeta): Flag error (208) if a pointer to - a managed type is declared. - - * expression.cs (Invocation.VerifyArgumentsCompat): Check for the - parameter modifiers as well. Fixes bug 38606 - - * class.cs: Very sad. Am backing out the speed up changes - introduced by the ArrayList -> Array in the TypeContainer, as they - were not actually that much faster, and introduced a bug (no error - reports on duplicated methods). - - * assign.cs (CompoundAssign.DoLResolve): Resolve the original - source first, this will guarantee that we have a valid expression - before calling in lower levels functions that will require a - resolved object. Then use this original_source in the - target.ResolveLValue instead of the original source that was - passed to us. - - Another change. Use target.Resolve instead of LValueResolve. - Although we are resolving for LValues, we will let the Assign code - take care of that (it will be called again from Resolve). This - basically allows code like this: - - class X { X operator + (X x, object o) {} X this [int idx] { get; set; } } - class Y { void A (X x) { x [0] += o; } - - The problem was that the indexer was trying to resolve for - set_Item (idx, object o) and never finding one. The real set_Item - was set_Item (idx, X). By delaying the process we get the right - semantics. - - Fixes bug 36505 - -2003-02-23 Martin Baulig - - * statement.cs (Block.Emit): Override this and set ec.CurrentBlock - while calling DoEmit (). - - * codegen.cs (EmitContext.Mark): Don't mark locations in other - source files; if you use the #line directive inside a method, the - compiler stops emitting line numbers for the debugger until it - reaches the end of the method or another #line directive which - restores the original file. - -2003-02-23 Martin Baulig - - * statement.cs (FlowBranching.UsageVector.MergeChildren): Fix bug #37708. - -2003-02-23 Martin Baulig - - * statement.cs (Block.AddChildVariableNames): We need to call this - recursively, not just for our immediate children. - -2003-02-23 Martin Baulig - - * class.cs (Event.Define): Always make the field private, like csc does. - - * typemanager.cs (TypeManager.RealMemberLookup): Make events - actually work, fixes bug #37521. - -2003-02-23 Miguel de Icaza - - * delegate.cs: When creating the various temporary "Parameters" - classes, make sure that we call the ComputeAndDefineParameterTypes - on those new parameters (just like we do with the formal ones), to - allow them to be resolved in the context of the DeclSpace. - - This fixes the bug that Dick observed in Bugzilla #38530. - -2003-02-22 Miguel de Icaza - - * expression.cs (ResolveMemberAccess): When resolving a constant, - do not attempt to pull a constant if the value was not able to - generate a valid constant. - - * const.cs (LookupConstantValue): Do not report more errors than required. - -2003-02-19 Gonzalo Paniagua Javier - - * expression.cs: fixes bug #38328. - -2003-02-18 Miguel de Icaza - - * class.cs: Changed all the various members that can be part of a - class from being an ArrayList to be an Array of the right type. - During the DefineType type_list, interface_list, delegate_list and - enum_list are turned into types, interfaces, delegates and enums - arrays. - - And during the member population, indexer_list, event_list, - constant_list, field_list, instance_constructor_list, method_list, - operator_list and property_list are turned into their real arrays. - - Although we could probably perform this operation earlier, for - good error reporting we need to keep the lists and remove the - lists for longer than required. - - This optimization was triggered by Paolo profiling the compiler - speed on the output of `gen-sample-program.pl' perl script. - - * decl.cs (DeclSpace.ResolveType): Set the ContainerType, so we do - not crash in methods like MemberLookupFailed that use this field. - - This problem arises when the compiler fails to resolve a type - during interface type definition for example. - -2003-02-18 Miguel de Icaza - - * expression.cs (Indexers.GetIndexersForType): Interfaces do not - inherit from System.Object, so we have to stop at null, not only - when reaching System.Object. - -2003-02-17 Miguel de Icaza - - * expression.cs: (Indexers.GetIndexersForType): Martin's fix used - DeclaredOnly because the parent indexer might have had a different - name, but did not loop until the top of the hierarchy was reached. - - The problem this one fixes is 35492: when a class implemented an - indexer from an interface, we were getting the interface method - (which was abstract) and we were flagging an error (can not invoke - abstract method). - - This also keeps bug 33089 functioning, and test-148 functioning. - - * typemanager.cs (IsSpecialMethod): The correct way of figuring - out if a method is special is to see if it is declared in a - property or event, or whether it is one of the predefined operator - names. This should fix correctly #36804. - -2003-02-15 Miguel de Icaza - - The goal here is to remove the dependency on EmptyCast.Peel (). - Killing it completely. - - The problem is that currently in a number of places where - constants are expected, we have to "probe" for an EmptyCast, and - Peel, which is not the correct thing to do, as this will be - repetitive and will likely lead to errors. - - The idea is to remove any EmptyCasts that are used in casts that - can be reduced to constants, so we only have to cope with - constants. - - This bug hunt was triggered by Bug 37363 and the desire to remove - the duplicate pattern where we were "peeling" emptycasts to check - whether they were constants. Now constants will always be - constants. - - * ecore.cs: Use an enumconstant here instead of wrapping with - EmptyCast. - - * expression.cs (Cast.TryReduce): Ah, the tricky EnumConstant was - throwing me off. By handling this we can get rid of a few hacks. - - * statement.cs (Switch): Removed Peel() code. - -2003-02-14 Miguel de Icaza - - * class.cs: Location information for error 508 - - * expression.cs (New.DoResolve): Add a guard against double - resolution of an expression. - - The New DoResolve might be called twice when initializing field - expressions (see EmitFieldInitializers, the call to - GetInitializerExpression will perform a resolve on the expression, - and later the assign will trigger another resolution - - This leads to bugs (#37014) - - * delegate.cs: The signature for EndInvoke should contain any ref - or out parameters as well. We were not doing this in the past. - - * class.cs (Field.Define): Do not overwrite the type definition - inside the `volatile' group. Turns out that volatile enumerations - were changing the type here to perform a validity test, which - broke conversions. - -2003-02-12 Miguel de Icaza - - * ecore.cs (FieldExpr.AddressOf): In the particular case of This - and structs, we do not want to load the instance variable - - (ImplicitReferenceConversion, ImplicitReferenceConversionExists): - enum_type has to be handled like an object reference (implicit - conversions exists from this to object), but the regular IsClass - and IsValueType tests will never return true for this one. - - Also we use TypeManager.IsValueType instead of type.IsValueType, - just for consistency with the rest of the code (this is only - needed if we ever use the construct exposed by test-180.cs inside - corlib, which we dont today). - -2003-02-12 Zoltan Varga - - * attribute.cs (ApplyAttributes): apply all MethodImplAttributes, not - just InternalCall. - -2003-02-09 Martin Baulig - - * namespace.cs (Namespace..ctor): Added SourceFile argument. - (Namespace.DefineNamespaces): New static public method; this is - called when we're compiling with debugging to add all namespaces - to the symbol file. - - * tree.cs (Tree.RecordNamespace): Added SourceFile argument and - pass it to the Namespace's .ctor. - - * symbolwriter.cs (SymbolWriter.OpenMethod): Added TypeContainer - and MethodBase arguments; pass the namespace ID to the symwriter; - pass the MethodBase instead of the token to the symwriter. - (SymbolWriter.DefineNamespace): New method to add a namespace to - the symbol file. - -2003-02-09 Martin Baulig - - * symbolwriter.cs: New file. This is a wrapper around - ISymbolWriter with a cleaner API. We'll dynamically Invoke() - methods here in near future. - -2003-02-09 Martin Baulig - - * codegen.cs (EmitContext.Mark): Just pass the arguments to - ILGenerator.MarkSequencePoint() which are actually used by the - symbol writer. - -2003-02-09 Martin Baulig - - * location.cs (SourceFile): New public sealed class. This - contains the name and an index which is used in the location's token. - (Location): Reserve an appropriate number of bits in the token for - the source file instead of walking over that list, this gives us a - really huge performance improvement when compiling with debugging. - - * driver.cs (Driver.parse, Driver.tokenize_file): Take a - `SourceFile' argument instead of a string. - (Driver.ProcessFile): Add all the files via Location.AddFile(), - but don't parse/tokenize here, we need to generate the list of all - source files before we do that. - (Driver.ProcessFiles): New static function. Parses/tokenizes all - the files. - - * cs-parser.jay (CSharpParser): Take a `SourceFile' argument - instead of a string. - - * cs-tokenizer.cs (Tokenizer): Take `SourceFile' argument instead - of a string. - -2003-02-09 Martin Baulig - - * cs-tokenizer.cs (Tokenizer.PreProcessLine): Also reset the - filename on `#line default'. - -Sat Feb 8 17:03:16 CET 2003 Paolo Molaro - - * statement.cs: don't clear the pinned var when the fixed statement - returns from the method (fixes bug#37752). - -Sat Feb 8 12:58:06 CET 2003 Paolo Molaro - - * typemanager.cs: fix from mathpup@mylinuxisp.com (Marcus Urban) - to IsValueType. - -2003-02-07 Martin Baulig - - * driver.cs: Removed the `--debug-args' command line argument. - - * codegen.cs (CodeGen.SaveSymbols): Removed, this is now done - automatically by the AsssemblyBuilder. - (CodeGen.InitializeSymbolWriter): We don't need to call any - initialization function on the symbol writer anymore. This method - doesn't take any arguments. - -2003-02-03 Miguel de Icaza - - * driver.cs: (AddAssemblyAndDeps, LoadAssembly): Enter the types - from referenced assemblies as well. - -2003-02-02 Martin Baulig - - * class.cs (MethodData.Emit): Generate debugging info for external methods. - -2003-02-02 Martin Baulig - - * class.cs (Constructor.Emit): Open the symbol writer before - emitting the constructor initializer. - (ConstructorInitializer.Emit): Call ec.Mark() to allow - single-stepping through constructor initializers. - -2003-01-30 Miguel de Icaza - - * class.cs: Handle error 549: do not allow virtual methods in - sealed classes. - -2003-02-01 Jackson Harper - - * decl.cs: Check access levels when resolving types - -2003-01-31 Jackson Harper - - * statement.cs: Add parameters and locals set in catch blocks that might - return to set vector - -2003-01-29 Miguel de Icaza - - * class.cs (Operator): Set the SpecialName flags for operators. - - * expression.cs (Invocation.DoResolve): Only block calls to - accessors and operators on SpecialName methods. - - (Cast.TryReduce): Handle conversions from char constants. - - -Tue Jan 28 17:30:57 CET 2003 Paolo Molaro - - * statement.cs: small memory and time optimization in FlowBranching. - -2003-01-28 Pedro Mart - - * expression.cs (IndexerAccess.DoResolveLValue): Resolve the same - problem that the last fix but in the other sid (Set). - - * expression.cs (IndexerAccess.DoResolve): Fix a problem with a null - access when there is no indexer in the hierarchy. - -2003-01-27 Jackson Harper - - * class.cs: Combine some if statements. - -2003-01-27 Gonzalo Paniagua Javier - - * driver.cs: fixed bug #37187. - -2003-01-27 Pedro Martinez Juliá - - * expression.cs (IndexerAccess.DoResolve): Before trying to resolve - any indexer, it's needed to build a list with all the indexers in the - hierarchy (AllGetters), else we have problems. Fixes #35653. - -2003-01-23 Miguel de Icaza - - * class.cs (MethodData.Define): It is wrong for an interface - implementation to be static in both cases: explicit and implicit. - We were only handling this in one case. - - Improve the if situation there to not have negations. - - * class.cs (Field.Define): Turns out that we do not need to check - the unsafe bit on field definition, only on usage. Remove the test. - -2003-01-22 Gonzalo Paniagua Javier - - * driver.cs: use assembly.Location instead of Codebase (the latest - patch made mcs fail when using MS assemblies). - -2003-01-21 Tim Haynes - - * driver.cs: use DirectorySeparatorChar instead of a hardcoded "/" to - get the path to *corlib.dll. - -2003-01-21 Nick Drochak - - * cs-tokenizer.cs: - * pending.cs: - * typemanager.cs: Remove compiler warnings - -2003-01-20 Duncan Mak - - * AssemblyInfo.cs: Bump the version number to 0.19. - -2003-01-20 Gonzalo Paniagua Javier - - * cs-tokenizer.cs: little fixes to line numbering when #line is used. - -2003-01-18 Zoltan Varga - - * class.cs (Constructor::Emit): Emit debugging info for constructors. - -2003-01-17 Miguel de Icaza - - * cs-parser.jay: Small fix: we were not comparing the constructor - name correctly. Thanks to Zoltan for the initial pointer. - -2003-01-16 Jackson Harper - - * cs-tokenizer.cs: Set file name when specified with #line - -2003-01-15 Miguel de Icaza - - * cs-parser.jay: Only perform the constructor checks here if we - are named like the class; This will help provider a better - error. The constructor path is taken when a type definition is - not found, but most likely the user forgot to add the type, so - report that rather than the constructor error. - -Tue Jan 14 10:36:49 CET 2003 Paolo Molaro - - * class.cs, rootcontext.cs: small changes to avoid unnecessary memory - allocations. - -2003-01-13 Jackson Harper - - * cs-parser.jay: Add cleanup call. - -2003-01-13 Duncan Mak - - * cs-tokenizer.cs (Cleanup): Rename to 'cleanup' to make it more - consistent with other methods. - -2003-01-13 Jackson Harper - - * cs-tokenizer.cs: Add Cleanup method, also fix #region error messages. - -Sun Jan 12 19:58:42 CET 2003 Paolo Molaro - - * attribute.cs: only set GuidAttr to true when we have a - GuidAttribute. - -2003-01-09 Gonzalo Paniagua Javier - - * ecore.cs: - * expression.cs: - * typemanager.cs: fixes to allow mcs compile corlib with the new - Type.IsSubclassOf fix. - -2003-01-08 Miguel de Icaza - - * expression.cs (LocalVariableReference.DoResolve): Classify a - constant as a value, not as a variable. Also, set the type for - the variable. - - * cs-parser.jay (fixed_statement): take a type instead of a - pointer_type, so we can produce a better error message later. - - * statement.cs (Fixed.Resolve): Flag types that are not pointers - as an error. - - (For.DoEmit): Make inifinite loops have a - non-conditional branch back. - - (Fixed.DoEmit): First populate the pinned variables, then emit the - statement, then clear the variables. Before I was emitting the - code once for each fixed piece. - - -2003-01-08 Martin Baulig - - * statement.cs (FlowBranching.MergeChild): A break in a - SWITCH_SECTION does not leave a loop. Fixes #36155. - -2003-01-08 Martin Baulig - - * statement.cs (FlowBranching.CheckOutParameters): `struct_params' - lives in the same number space than `param_map'. Fixes #36154. - -2003-01-07 Miguel de Icaza - - * cs-parser.jay (constructor_declaration): Set the - Constructor.ModFlags before probing for it. This makes the - compiler report 514, 515 and 132 (the code was there, but got - broken). - - * statement.cs (Goto.Resolve): Set `Returns' to ALWAYS. - (GotoDefault.Resolve): Set `Returns' to ALWAYS. - (GotoCase.Resolve): Set `Returns' to ALWAYS. - -Tue Jan 7 18:32:24 CET 2003 Paolo Molaro - - * enum.cs: create the enum static fields using the enum type. - -Tue Jan 7 18:23:44 CET 2003 Paolo Molaro - - * class.cs: don't try to create the ParamBuilder for the return - type if it's not needed (and handle it breaking for the ms runtime - anyway). - -2003-01-06 Jackson Harper - - * cs-tokenizer.cs: Add REGION flag to #region directives, and add checks to make sure that regions are being poped correctly - -2002-12-29 Miguel de Icaza - - * cs-tokenizer.cs (get_cmd_arg): Fixups to allow \r to terminate - the command. This showed up while compiling the JANET source - code, which used \r as its only newline separator. - -2002-12-28 Miguel de Icaza - - * class.cs (Method.Define): If we are an operator (because it - reuses our code), then set the SpecialName and HideBySig. #36128 - -2002-12-22 Miguel de Icaza - - * ecore.cs (FieldExpr.DoResolve): Instead of throwing an - exception, report error 120 `object reference required'. - - * driver.cs: Add --pause option, used during to measure the size - of the process as it goes with --timestamp. - - * expression.cs (Invocation.DoResolve): Do not allow methods with - SpecialName to be invoked. - -2002-12-21 Miguel de Icaza - - * cs-tokenizer.cs: Small fix to the parser: compute the ascii - number before adding it. - -2002-12-21 Ravi Pratap - - * ecore.cs (StandardImplicitConversion): When in an unsafe - context, we allow conversion between void * to any other pointer - type. This fixes bug #35973. - -2002-12-20 Jackson Harper - - * codegen.cs: Use Path.GetFileNameWithoutExtension so an exception - is not thrown when extensionless outputs are used - -2002-12-20 Gonzalo Paniagua Javier - - * rootcontext.cs: fixed compilation of corlib. - -2002-12-19 Miguel de Icaza - - * attribute.cs (Attributes.Contains): Add new method. - - * class.cs (MethodCore.LabelParameters): if the parameter is an - `out' parameter, check that no attribute `[In]' has been passed. - - * enum.cs: Handle the `value__' name in an enumeration. - -2002-12-14 Jaroslaw Kowalski - - * decl.cs: Added special case to allow overrides on "protected - internal" methods - -2002-12-18 Ravi Pratap - - * attribute.cs (Attributes.AddAttributeSection): Rename to this - since it makes much more sense. - - (Attributes.ctor): Don't require a Location parameter. - - * rootcontext.cs (AddGlobalAttributeSection): Rename again. - - * attribute.cs (ApplyAttributes): Remove extra Location parameters - since we already have that information per attribute. - - * everywhere : make appropriate changes. - - * class.cs (LabelParameters): Write the code which actually - applies attributes to the return type. We can't do this on the MS - .NET runtime so we flag a warning in the case an exception is - thrown. - -2002-12-18 Miguel de Icaza - - * const.cs: Handle implicit null conversions here too. - -2002-12-17 Ravi Pratap - - * class.cs (MethodCore.LabelParameters): Remove the extra - Type [] parameter since it is completely unnecessary. Instead - pass in the method's attributes so that we can extract - the "return" attribute. - -2002-12-17 Miguel de Icaza - - * cs-parser.jay (parse): Use Report.Error to flag errors instead - of ignoring it and letting the compile continue. - - * typemanager.cs (ChangeType): use an extra argument to return an - error condition instead of throwing an exception. - -2002-12-15 Miguel de Icaza - - * expression.cs (Unary.TryReduce): mimic the code for the regular - code path. Perform an implicit cast in the cases where we can - implicitly convert to one of the integral types, and then reduce - based on that constant. This fixes bug #35483. - -2002-12-14 Gonzalo Paniagua Javier - - * typemanager.cs: fixed cut & paste error in GetRemoveMethod. - -2002-12-13 Gonzalo Paniagua Javier - - * namespace.cs: fixed bug #35489. - -2002-12-12 Miguel de Icaza - - * class.cs: Remove some dead code. - - * cs-parser.jay: Estimate the number of methods needed - (RootContext.MethodCount); - - * cs-tokenizer.cs: Use char arrays for parsing identifiers and - numbers instead of StringBuilders. - - * support.cs (PtrHashtable): Add constructor with initial size; - We can now reduce reallocations of the method table. - -2002-12-10 Ravi Pratap - - * attribute.cs (ApplyAttributes): Keep track of the emitted - attributes on a per-target basis. This fixes bug #35413. - -2002-12-10 Miguel de Icaza - - * driver.cs (MainDriver): On rotor encoding 28591 does not exist, - default to the Windows 1252 encoding. - - (UnixParseOption): Support version, thanks to Alp for the missing - pointer. - - * AssemblyInfo.cs: Add nice assembly information. - - * cs-tokenizer.cs: Add fix from Felix to the #if/#else handler - (bug 35169). - - * cs-parser.jay: Allow a trailing comma before the close bracked - in the attribute_section production. - - * ecore.cs (FieldExpr.AddressOf): Until I figure out why the - address of the instance was being taken, I will take this out, - because we take the address of the object immediately here. - -2002-12-09 Ravi Pratap - - * typemanager.cs (AreMultipleAllowed): Take care of the most - obvious case where attribute type is not in the current assembly - - stupid me ;-) - -2002-12-08 Miguel de Icaza - - * ecore.cs (SimpleName.DoResolve): First perform lookups on using - definitions, instead of doing that afterwards. - - Also we use a nice little hack, depending on the constructor, we - know if we are a "composed" name or a simple name. Hence, we - avoid the IndexOf test, and we avoid - - * codegen.cs: Add code to assist in a bug reporter to track down - the source of a compiler crash. - -2002-12-07 Ravi Pratap - - * attribute.cs (Attribute.ApplyAttributes) : Keep track of which attribute - types have been emitted for a given element and flag an error - if something which does not have AllowMultiple set is used more - than once. - - * typemanager.cs (RegisterAttributeAllowMultiple): Keep track of - attribute types and their corresponding AllowMultiple properties - - (AreMultipleAllowed): Check the property for a given type. - - * attribute.cs (Attribute.ApplyAttributes): Register the AllowMultiple - property in the case we have a TypeContainer. - - (Attributes.AddAttribute): Detect duplicates and just skip on - adding them. This trivial fix catches a pretty gross error in our - attribute emission - global attributes were being emitted twice! - - Bugzilla bug #33187 is now fixed. - -2002-12-06 Miguel de Icaza - - * cs-tokenizer.cs (pp_expr): Properly recurse here (use pp_expr - instead of pp_and). - - * expression.cs (Binary.ResolveOperator): I can only use the - Concat (string, string, string) and Concat (string, string, - string, string) if the child is actually a concatenation of - strings. - -2002-12-04 Miguel de Icaza - - * cs-tokenizer.cs: Small fix, because decimal_digits is used in a - context where we need a 2-character lookahead. - - * pending.cs (PendingImplementation): Rework so we can keep track - of interface types all the time, and flag those which were - implemented by parents as optional. - -2002-12-03 Miguel de Icaza - - * expression.cs (Binary.ResolveOperator): Use - String.Concat(string,string,string) or - String.Concat(string,string,string,string) when possible. - - * typemanager: More helper methods. - - -Tue Dec 3 19:32:04 CET 2002 Paolo Molaro - - * pending.cs: remove the bogus return from GetMissingInterfaces() - (see the 2002-11-06 entry: the mono runtime is now fixed in cvs). - -2002-12-02 Gonzalo Paniagua Javier - - * namespace.cs: avoid duplicated 'using xxx' being added to - using_clauses. This prevents mcs from issuing and 'ambiguous type' error - when we get more than one 'using' statement for the same namespace. - Report a CS0105 warning for it. - -2002-11-30 Miguel de Icaza - - * cs-tokenizer.cs (consume_identifier): use read directly, instead - of calling getChar/putback, uses internal knowledge of it. - - (xtoken): Reorder tokenizer so most common patterns are checked - first. This reduces the compilation time in another 5% (from 8.11s - average to 7.73s for bootstrapping mcs on my Mobile p4/1.8ghz). - - The parsing time is 22% of the compilation in mcs, and from that - 64% is spent on the tokenization process. - - I tried using a binary search for keywords, but this is slower - than the hashtable. Another option would be to do a couple of - things: - - * Not use a StringBuilder, instead use an array of chars, - with a set value. Notice that this way we could catch - the 645 error without having to do it *afterwards*. - - * We could write a hand-parser to avoid the hashtable - compares altogether. - - The identifier consumption process takes 37% of the tokenization - time. Another 15% is spent on is_number. 56% of the time spent - on is_number is spent on Int64.Parse: - - * We could probably choose based on the string length to - use Int32.Parse or Int64.Parse and avoid all the 64-bit - computations. - - Another 3% is spend on wrapping `xtoken' in the `token' function. - - Handle 0xa0 as whitespace (#34752) - -2002-11-26 Miguel de Icaza - - * typemanager.cs (IsCLRType): New routine to tell whether a type - is one of the builtin types. - - Maybe it needs to use TypeCodes to be faster. Maybe we could use - typecode in more places instead of doing pointer comparissions. - We could leverage some knowledge about the way the typecodes are - laid out. - - New code to cache namespaces in assemblies, it is currently not - invoked, to be used soon. - - * decl.cs (DeclSpace.MakeFQN): Simple optimization. - - * expression.cs (Binary.ResolveOperator): specially handle - strings, and do not perform user-defined operator overloading for - built-in types. - -2002-11-24 Miguel de Icaza - - * cs-tokenizer.cs: Avoid calling Char.IsDigit which is an - internalcall as it is a pretty simple operation; Avoid whenever - possible to call Char.IsLetter. - - (consume_identifier): Cut by half the number of - hashtable calls by merging the is_keyword and GetKeyword behavior. - - Do not short-circuit, because if we do, we - report errors (ie, #if false && true would produce an invalid - directive error); - - -2002-11-24 Martin Baulig - - * expression.cs (Cast.TryReduce): If we're in checked syntax, - check constant ranges and report a CS0221. Fixes #33186. - -2002-11-24 Martin Baulig - - * cs-parser.jay: Make this work for uninitialized variable - declarations in the `for' initializer. Fixes #32416. - -2002-11-24 Martin Baulig - - * ecore.cs (Expression.ConvertExplicit): Make casting from/to - System.Enum actually work. Fixes bug #32269, added verify-6.cs. - -2002-11-24 Martin Baulig - - * expression.cs (Binary.DoNumericPromotions): Added `check_user_conv' - argument; if true, we also check for user-defined conversions. - This is only needed if both arguments are of a user-defined type. - Fixes #30443, added test-175.cs. - (Binary.ForceConversion): Pass the location argument to ConvertImplicit. - - * ecore.cs (Expression.ImplicitUserConversionExists): New method. - -2002-11-24 Martin Baulig - - * expression.cs (ArrayAccess.GetStoreOpcode): New public static - function to get the store opcode. - (Invocation.EmitParams): Call ArrayAccess.GetStoreOpcode() and - only emit the Ldelema if the store opcode is Stobj. You must run - both test-34 and test-167 to test this. Fixes #34529. - -2002-11-23 Martin Baulig - - * ecore.cs (Expression.MemberLookup): Added additional - `qualifier_type' argument which is used when we're being called - from MemberAccess.DoResolve() and null if we're called from a - SimpleName lookup. - (Expression.MemberLookupFailed): New method to report errors; this - does the CS1540 check and reports the correct error message. - - * typemanager.cs (MemberLookup): Added additional `qualifier_type' - argument for the CS1540 check and redone the way how we're dealing - with private members. See the comment in the source code for details. - (FilterWithClosure): Reverted this back to revision 1.197; renamed - `closure_start_type' to `closure_qualifier_type' and check whether - it's not null. It was not this filter being broken, it was just - being called with the wrong arguments. - - * expression.cs (MemberAccess.DoResolve): use MemberLookupFinal() - and pass it the correct `qualifier_type'; this also does the error - handling for us. - -2002-11-22 Miguel de Icaza - - * expression.cs (Invocation.EmitParams): If the we are dealing - with a non-built-in value type, load its address as well. - - (ArrayCreation): Use a a pretty constant instead - of the hardcoded value 2. Use 6 instead of 2 for the number of - static initializers. - - (ArrayCreation.EmitDynamicInitializers): Peel enumerations, - because they are not really value types, just glorified integers. - - * driver.cs: Do not append .exe, the CSC compiler does not do it. - - * ecore.cs: Remove redundant code for enumerations, make them use - the same code path as everything else, fixes the casting issue - with enumerations in Windows.Forms. - - * attribute.cs: Do only cast to string if it is a string, the - validation happens later. - - * typemanager.cs: Temproary hack to avoid a bootstrap issue until - people upgrade their corlibs. - - * ecore.cs: Oops, enumerations were not following the entire code path - -2002-11-21 Miguel de Icaza - - * typemanager.cs (FilterWithClosure): Commented out the test for - 1540 in typemanager.cs, as it has problems when accessing - protected methods from a parent class (see test-174.cs). - - * attribute.cs (Attribute.ValidateGuid): new method. - (Attribute.Resolve): Use above. - -2002-11-19 Miguel de Icaza - - * enum.cs: In FindMembers, perform a recursive lookup for values. (34308) - - * ecore.cs (SimpleName.SimpleNameResolve): Remove the special - handling for enumerations, as we only needed the TypeContainer - functionality to begin with (this is required for the fix below to - work for enums that reference constants in a container class for - example). - - * codegen.cs (EmitContext): Make TypeContainer a DeclSpace. - - * enum.cs (Enum.Define): Use `this' instead of parent, so we have - a valid TypeBuilder to perform lookups on.o - - * class.cs (InheritableMemberSignatureCompare): Use true in the - call to GetGetMethod and GetSetMethod, because we are comparing - the signature, and we need to get the methods *even* if they are - private. - - (PropertyBase.CheckBase): ditto. - - * statement.cs (Switch.ResolveAndReduce, Block.EmitMeta, - GotoCase.Resolve): Use Peel on EmpytCasts. - - * ecore.cs (EmptyCast): drop child, add Peel method. - -2002-11-17 Martin Baulig - - * ecore.cs (EmptyCast.Child): New public property. - - * statement.cs (SwitchLabel.ResolveAndReduce): Check whether the - label resolved to an EmptyCast. Fixes #34162. - (GotoCase.Resolve): Likewise. - (Block.EmitMeta): Likewise. - -2002-11-17 Martin Baulig - - * expression.cs (Invocation.BetterConversion): Prefer int over - uint; short over ushort; long over ulong for integer literals. - Use ImplicitConversionExists instead of StandardConversionExists - since we also need to check for user-defined implicit conversions. - Fixes #34165. Added test-173.cs. - -2002-11-16 Martin Baulig - - * expression.cs (Binary.EmitBranchable): Eliminate comparisions - with the `true' and `false' literals. Fixes #33151. - -2002-11-16 Martin Baulig - - * typemanager.cs (RealMemberLookup): Reverted Miguel's patch from - October 22nd; don't do the cs1540 check for static members. - - * ecore.cs (PropertyExpr.ResolveAccessors): Rewrote this; we're - now using our own filter here and doing the cs1540 check again. - -2002-11-16 Martin Baulig - - * support.cs (InternalParameters): Don't crash if we don't have - any fixed parameters. Fixes #33532. - -2002-11-16 Martin Baulig - - * decl.cs (MemberCache.AddMethods): Use BindingFlags.FlattenHierarchy - when looking up static methods to make this work on Windows. - Fixes #33773. - -2002-11-16 Martin Baulig - - * ecore.cs (PropertyExpr.VerifyAssignable): Check whether we have - a setter rather than using PropertyInfo.CanWrite. - -2002-11-15 Nick Drochak - - * class.cs: Allow acces to block member by subclasses. Fixes build - breaker. - -2002-11-14 Martin Baulig - - * class.cs (Constructor.Emit): Added the extern/block check. - Fixes bug #33678. - -2002-11-14 Martin Baulig - - * expression.cs (IndexerAccess.DoResolve): Do a DeclaredOnly - iteration while looking for indexers, this is needed because the - indexer may have a different name in our base classes. Fixed the - error reporting (no indexers at all, not get accessor, no - overloaded match). Fixes bug #33089. - (IndexerAccess.DoResolveLValue): Likewise. - -2002-11-14 Martin Baulig - - * class.cs (PropertyBase.CheckBase): Make this work for multiple - indexers. Fixes the first part of bug #33089. - (MethodSignature.InheritableMemberSignatureCompare): Added support - for properties. - -2002-11-13 Ravi Pratap - - * attribute.cs (Attribute.Resolve): Catch the - NullReferenceException and report it since it isn't supposed to - happen. - -2002-11-12 Miguel de Icaza - - * expression.cs (Binary.EmitBranchable): Also handle the cases for - LogicalOr and LogicalAnd that can benefit from recursively - handling EmitBranchable. The code now should be nice for Paolo. - -2002-11-08 Miguel de Icaza - - * typemanager.cs (LookupType): Added a negative-hit hashtable for - the Type lookups, as we perform quite a number of lookups on - non-Types. This can be removed once we can deterministically tell - whether we have a type or a namespace in advance. - - But this might require special hacks from our corlib. - - * TODO: updated. - - * ecore.cs (TryImplicitIntConversion): Handle conversions to float - and double which avoids a conversion from an integer to a double. - - * expression.cs: tiny optimization, avoid calling IsConstant, - because it effectively performs the lookup twice. - -2002-11-06 Miguel de Icaza - - But a bogus return here to keep the semantics of the old code - until the Mono runtime is fixed. - - * pending.cs (GetMissingInterfaces): New method used to remove all - the interfaces that are already implemented by our parent - classes from the list of pending methods. - - * interface.cs: Add checks for calls after ResolveTypeExpr. - -2002-11-05 Miguel de Icaza - - * class.cs (Class.Emit): Report warning 67: event not used if the - warning level is beyond 3. - - * ecore.cs (Expression.ConvertExplicit): Missed a check for expr - being a NullLiteral. - - * cs-parser.jay: Fix, Gonzalo reverted the order of the rank - specifiers. - - * class.cs (TypeContainer.GetClassBases): Cover a missing code - path that might fail if a type can not be resolved. - - * expression.cs (Binary.Emit): Emit unsigned versions of the - operators. - - * driver.cs: use error 5. - -2002-11-02 Gonzalo Paniagua Javier - - * cs-parser.jay: simplified a rule and 5 SR conflicts dissapeared. - -2002-11-01 Miguel de Icaza - - * cs-parser.jay (switch_section): A beautiful patch from Martin - Baulig that fixed 33094. - -2002-10-31 Miguel de Icaza - - * ecore.cs (PropertyExpr.DoResolveLValue, PropertyExpr.DoResolve): - Check whether the base is abstract and report an error if so. - - * expression.cs (IndexerAccess.DoResolveLValue, - IndexerAccess.DoResolve): ditto. - - (Invocation.DoResolve): ditto. - - (Invocation.FullMethodDesc): Improve the report string. - - * statement.cs (Block): Eliminate IsVariableDefined as it is - basically just a wrapper for GetVariableInfo. - - * ecore.cs (SimpleName): Use new - - * support.cs (ReflectionParamter.ParameterType): We unwrap the - type, as we return the actual parameter ref/unref state on a - different call. - -2002-10-30 Miguel de Icaza - - * support.cs: Return proper flags REF/OUT fixing the previous - commit. - - * expression.cs: Reverted last patch, that was wrong. Is_ref is - not used to mean `ref' but `ref or out' in ParameterReference - - * delegate.cs (FullDelegateDesc): use ParameterDesc to get the - full type signature instead of calling TypeManger.CSharpName - ourselves. - - * support.cs (InternalParameters.ParameterDesc): Do not compare - directly to the modflags, because REF/OUT will actually be bitsets - if set. - - * delegate.cs (VerifyMethod): Check also the modifiers. - - * cs-tokenizer.cs: Fix bug where floating point values with an - exponent where a sign was missing was ignored. - - * driver.cs: Allow multiple assemblies to be specified in a single - /r: argument - -2002-10-28 Miguel de Icaza - - * cs-parser.jay: Ugly. We had to add a multiplicative_expression, - because identifiers after a parenthesis would end up in this kind - of production, and we needed to desamiguate it for having casts - like: - - (UserDefinedType *) xxx - -2002-10-24 Miguel de Icaza - - * typemanager.cs (RealMemberLookup): when we deal with a subclass, - we should set on the Bindingflags.NonPublic, but not turn on - private_ok. private_ok controls whether a Private member is - returned (this is chekced on the filter routine), while the - BindingFlags.NonPublic just controls whether private/protected - will be allowed. This fixes the problem part of the problem of - private properties being allowed to be used in derived classes. - - * expression.cs (BaseAccess): Provide an DoResolveLValue method, - so we can call the children DoResolveLValue method (this will - properly signal errors on lvalue assignments to base properties) - - * ecore.cs (PropertyExpr.ResolveAccessors): If both setter and - getter are null, and we have a property info, we know that this - happened because the lookup failed, so we report an error 122 for - protection level violation. - - We also silently return if setter and getter are null in the - resolve functions, this condition only happens if we have flagged - the error before. This is the other half of the problem. - - (PropertyExpr.ResolveAccessors): Turns out that PropertyInfo does - not have accessibility information, that is why we were returning - true in the filter function in typemanager.cs. - - To properly report 122 (property is inaccessible because of its - protection level) correctly, we report this error in ResolveAccess - by failing if both the setter and the getter are lacking (ie, the - lookup failed). - - DoResolve and DoLResolve have been modified to check for both - setter/getter being null and returning silently, the reason being - that I did not want to put the knowledge about this error in upper - layers, like: - - int old = Report.Errors; - x = new PropertyExpr (...); - if (old != Report.Errors) - return null; - else - return x; - - So the property expr is returned, but it is invalid, so the error - will be flagged during the resolve process. - - * class.cs: Remove InheritablePropertySignatureCompare from the - class, as we no longer depend on the property signature to compute - whether it is possible to implement a method or not. - - The reason is that calling PropertyInfo.GetGetMethod will return - null (in .NET, in Mono it works, and we should change this), in - cases where the Get Method does not exist in that particular - class. - - So this code: - - class X { public virtual int A { get { return 1; } } } - class Y : X { } - class Z : Y { public override int A { get { return 2; } } } - - Would fail in Z because the parent (Y) would not have the property - defined. So we avoid this completely now (because the alternative - fix was ugly and slow), and we now depend exclusively on the - method names. - - (PropertyBase.CheckBase): Use a method-base mechanism to find our - reference method, instead of using the property. - - * typemanager.cs (GetPropertyGetter, GetPropertySetter): These - routines are gone now. - - * typemanager.cs (GetPropertyGetter, GetPropertySetter): swap the - names, they were incorrectly named. - - * cs-tokenizer.cs: Return are more gentle token on failure. - - * pending.cs (PendingImplementation.InterfaceMethod): This routine - had an out-of-sync index variable, which caused it to remove from - the list of pending methods the wrong method sometimes. - -2002-10-22 Miguel de Icaza - - * ecore.cs (PropertyExpr): Do not use PropertyInfo.CanRead, - CanWrite, because those refer to this particular instance of the - property, and do not take into account the fact that we can - override single members of a property. - - Constructor requires an EmitContext. The resolution process does - not happen here, but we need to compute the accessors before, - because the resolution does not always happen for properties. - - * typemanager.cs (RealMemberLookup): Set private_ok if we are a - subclass, before we did not update this flag, but we did update - bindingflags. - - (GetAccessors): Drop this routine, as it did not work in the - presence of partially overwritten set/get methods. - - Notice that this broke the cs1540 detection, but that will require - more thinking. - -2002-10-22 Gonzalo Paniagua Javier - - * class.cs: - * codegen.cs: - * driver.cs: issue a warning instead of an error if we don't support - debugging for the platform. Also ignore a couple of errors that may - arise when trying to write the symbols. Undo my previous patch. - -2002-10-22 Gonzalo Paniagua Javier - - * driver.cs: ignore /debug switch except for Unix platforms. - -2002-10-23 Nick Drochak - - * makefile: Remove mcs2.exe and mcs3.exe on 'make clean' - -2002-10-21 Miguel de Icaza - - * driver.cs: Do not make mcs-debug conditional, so we do not break - builds that use it. - - * statement.cs (UsageVector.MergeChildren): I would like Martin to - review this patch. But basically after all the children variables - have been merged, the value of "Breaks" was not being set to - new_breaks for Switch blocks. I think that it should be set after - it has executed. Currently I set this to the value of new_breaks, - but only if new_breaks is FlowReturn.ALWAYS, which is a bit - conservative, but I do not understand this code very well. - - I did not break anything in the build, so that is good ;-) - - * cs-tokenizer.cs: Also allow \r in comments as a line separator. - -2002-10-20 Mark Crichton - - * cfold.cs: Fixed compile blocker. Really fixed it this time. - -2002-10-20 Nick Drochak - - * cfold.cs: Fixed compile blocker. - -2002-10-20 Miguel de Icaza - - * driver.cs: I was chekcing the key, not the file. - -2002-10-19 Ravi Pratap - - * ecore.cs (UserDefinedConversion): Get rid of the bogus error - message that we were generating - we just need to silently return - a null. - -2002-10-19 Miguel de Icaza - - * class.cs (Event.Define): Change my previous commit, as this - breaks the debugger. This is a temporary hack, as it seems like - the compiler is generating events incorrectly to begin with. - - * expression.cs (Binary.ResolveOperator): Added support for - "U operator - (E x, E y)" - - * cfold.cs (BinaryFold): Added support for "U operator - (E x, E - y)". - - * ecore.cs (FieldExpr.AddressOf): We had a special code path for - init-only variables, but this path did not take into account that - there might be also instance readonly variables. Correct this - problem. - - This fixes bug 32253 - - * delegate.cs (NewDelegate.DoResolve): Catch creation of unsafe - delegates as well. - - * driver.cs: Change the extension for modules to `netmodule' - - * cs-parser.jay: Improved slightly the location tracking for - the debugger symbols. - - * class.cs (Event.Define): Use Modifiers.FieldAttr on the - modifiers that were specified instead of the hardcoded value - (FamAndAssem). This was basically ignoring the static modifier, - and others. Fixes 32429. - - * statement.cs (Switch.SimpleSwitchEmit): Simplified the code, and - fixed a bug in the process (32476) - - * expression.cs (ArrayAccess.EmitAssign): Patch from - hwang_rob@yahoo.ca that fixes bug 31834.3 - -2002-10-18 Miguel de Icaza - - * driver.cs: Make the module extension .netmodule. - -2002-10-16 Miguel de Icaza - - * driver.cs: Report an error if the resource file is not found - instead of crashing. - - * ecore.cs (PropertyExpr.EmitAssign): Pass IsBase instead of - false, like Emit does. - -2002-10-16 Nick Drochak - - * typemanager.cs: Remove unused private member. Also reported mcs - bug to report this as a warning like csc. - -2002-10-15 Martin Baulig - - * statement.cs (Statement.Emit): Made this a virtual method; emits - the line number info and calls DoEmit(). - (Statement.DoEmit): New protected abstract method, formerly knows - as Statement.Emit(). - - * codegen.cs (EmitContext.Mark): Check whether we have a symbol writer. - -2002-10-11 Miguel de Icaza - - * class.cs: Following the comment from 2002-09-26 to AddMethod, I - have fixed a remaining problem: not every AddXXXX was adding a - fully qualified name. - - Now everyone registers a fully qualified name in the DeclSpace as - being defined instead of the partial name. - - Downsides: we are slower than we need to be due to the excess - copies and the names being registered this way. - - The reason for this is that we currently depend (on the corlib - bootstrap for instance) that types are fully qualified, because - we dump all the types in the namespace, and we should really have - types inserted into the proper namespace, so we can only store the - basenames in the defined_names array. - -2002-10-10 Martin Baulig - - * expression.cs (ArrayAccess.EmitStoreOpcode): Reverted the patch - from bug #31834, see the bug report for a testcase which is - miscompiled. - -2002-10-10 Martin Baulig - - * codegen.cs (EmitContext.Breaks): Removed, we're now using the - flow analysis code for this. - - * statement.cs (Do, While, For): Tell the flow analysis code about - infinite loops. - (FlowBranching.UsageVector): Added support for infinite loops. - (Block.Resolve): Moved the dead code elimination here and use flow - analysis to do it. - -2002-10-09 Miguel de Icaza - - * class.cs (Field.Define): Catch cycles on struct type - definitions. - - * typemanager.cs (IsUnmanagedtype): Do not recursively check - fields if the fields are static. We only need to check instance - fields. - - * expression.cs (As.DoResolve): Test for reference type. - - * statement.cs (Using.ResolveExpression): Use - ConvertImplicitRequired, not ConvertImplicit which reports an - error on failture - (Using.ResolveLocalVariableDecls): ditto. - - * expression.cs (Binary.ResolveOperator): Report errors in a few - places where we had to. - - * typemanager.cs (IsUnmanagedtype): Finish implementation. - -2002-10-08 Miguel de Icaza - - * expression.cs: Use StoreFromPtr instead of extracting the type - and then trying to use Stelem. Patch is from hwang_rob@yahoo.ca - - * ecore.cs (ImplicitReferenceConversion): It is possible to assign - an enumeration value to a System.Enum, but System.Enum is not a - value type, but an class type, so we need to box. - - (Expression.ConvertExplicit): One codepath could return - errors but not flag them. Fix this. Fixes #31853 - - * parameter.cs (Resolve): Do not allow void as a parameter type. - -2002-10-06 Martin Baulig - - * statemenc.cs (FlowBranching.SetParameterAssigned): Don't crash - if it's a class type and not a struct. Fixes #31815. - -2002-10-06 Martin Baulig - - * statement.cs: Reworked the flow analysis code a bit to make it - usable for dead code elimination. - -2002-10-06 Gonzalo Paniagua Javier - - * cs-parser.jay: allow empty source files. Fixes bug #31781. - -2002-10-04 Miguel de Icaza - - * expression.cs (ComposedCast.DoResolveType): A quick workaround - to fix the test 165, will investigate deeper. - -2002-10-04 Martin Baulig - - * statement.cs (FlowBranching.UsageVector.MergeChildren): Make - finally blocks actually work. - (Try.Resolve): We don't need to create a sibling for `finally' if - there is no finally block. - -2002-10-04 Martin Baulig - - * class.cs (Constructor.Define): The default accessibility for a - non-default constructor is private, not public. - -2002-10-04 Miguel de Icaza - - * class.cs (Constructor): Make AllowedModifiers public, add - EXTERN. - - * cs-parser.jay: Perform the modifiers test here, as the - constructor for the Constructor class usually receives a zero - because of the way we create it (first we create, later we - customize, and we were never checking the modifiers). - - * typemanager.cs (Typemanager.LookupTypeDirect): This new function - is a version of LookupTypeReflection that includes the type-name - cache. This can be used as a fast path for functions that know - the fully qualified name and are only calling into *.GetType() to - obtain a composed type. - - This is also used by TypeManager.LookupType during its type - composition. - - (LookupType): We now also track the real type name, as sometimes - we can get a quey for the real type name from things like - ComposedCast. This fixes bug 31422. - - * expression.cs (ComposedCast.Resolve): Since we are obtaining a - complete type fullname, it does not have to go through the type - resolution system to obtain the composed version of the type (for - obtaining arrays or pointers). - - (Conditional.Emit): Use the EmitBoolExpression to - generate nicer code, as requested by Paolo. - - (ArrayCreation.CheckIndices): Use the patch from - hwang_rob@yahoo.ca to validate the array initializers. - -2002-10-03 Miguel de Icaza - - * class.cs (ConstructorInitializer.Emit): simplify code by using - Invocation.EmitCall, and at the same time, fix the bugs in calling - parent constructors that took variable arguments. - - * ecore.cs (Expression.ConvertNumericExplicit, - Expression.ImplicitNumericConversion): Remove the code that - manually wrapped decimal (InternalTypeConstructor call is now gone - as well). - - * expression.cs (Cast.TryReduce): Also handle decimal types when - trying to perform a constant fold on the type. - - * typemanager.cs (IsUnmanagedtype): Partially implemented. - - * parameter.cs: Removed ResolveAndDefine, as it was not needed, as - that only turned off an error report, and did nothing else. - -2002-10-02 Miguel de Icaza - - * driver.cs: Handle and ignore /fullpaths - -2002-10-01 Miguel de Icaza - - * expression.cs (Binary.ResolveOperator): Catch the case where - DoNumericPromotions returns true, - - (Binary.DoNumericPromotions): Simplify the code, and the tests. - -2002-09-27 Miguel de Icaza - - * ecore.cs (EventExpr.Emit): Instead of emitting an exception, - report error 70. - -2002-09-26 Miguel de Icaza - - * ecore.cs (ConvertNumericExplicit): It is not enough that the - conversion exists, but it is also required that the conversion be - performed. This manifested in "(Type64Enum) 2". - - * class.cs (TypeManager.AddMethod): The fix is not to change - AddEnum, because that one was using a fully qualified name (every - DeclSpace derivative does), but to change the AddMethod routine - that was using an un-namespaced name. This now correctly reports - the duplicated name. - - Revert patch until I can properly fix it. The issue - is that we have a shared Type space across all namespaces - currently, which is wrong. - - Options include making the Namespace a DeclSpace, and merge - current_namespace/current_container in the parser. - -2002-09-25 Miguel de Icaza - - * cs-parser.jay: Improve error reporting when we get a different - kind of expression in local_variable_type and - local_variable_pointer_type. - - Propagate this to avoid missleading errors being reported. - - * ecore.cs (ImplicitReferenceConversion): treat - TypeManager.value_type as a target just like object_type. As - code like this: - - ValueType v = 1; - - Is valid, and needs to result in the int 1 being boxed before it - is assigned to the value type v. - - * class.cs (TypeContainer.AddEnum): Use the basename, not the name - to validate the enumeration name. - - * expression.cs (ArrayAccess.EmitAssign): Mimic the same test from - EmitDynamicInitializers for the criteria to use Ldelema. Thanks - to hwang_rob@yahoo.ca for finding the bug and providing a patch. - - * ecore.cs (TryImplicitIntConversion): When doing an - implicit-enumeration-conversion, check if the type is 64-bits and - perform a conversion before passing to EnumConstant. - -2002-09-23 Miguel de Icaza - - * decl.cs (Error_AmbiguousTypeReference); New routine used to - report ambiguous type references. Unlike the MS version, we - report what the ambiguity is. Innovation at work ;-) - - (DeclSpace.FindType): Require a location argument to - display when we display an ambiguous error. - - * ecore.cs: (SimpleName.DoResolveType): Pass location to FindType. - - * interface.cs (GetInterfaceTypeByName): Pass location to FindType. - - * expression.cs (EmitDynamicInitializers): Apply patch from - hwang_rob@yahoo.ca that fixes the order in which we emit our - initializers. - -2002-09-21 Martin Baulig - - * delegate.cs (Delegate.VerifyApplicability): Make this work if the - delegate takes no arguments. - -2002-09-20 Miguel de Icaza - - * constant.cs: Use Conv_U8 instead of Conv_I8 when loading longs - from integers. - - * expression.cs: Extract the underlying type. - - * ecore.cs (StoreFromPtr): Use TypeManager.IsEnumType instad of IsEnum - - * decl.cs (FindType): Sorry about this, fixed the type lookup bug. - -2002-09-19 Miguel de Icaza - - * class.cs (TypeContainer.DefineType): We can not use the nice - PackingSize with the size set to 1 DefineType method, because it - will not allow us to define the interfaces that the struct - implements. - - This completes the fixing of bug 27287 - - * ecore.cs (Expresion.ImplicitReferenceConversion): `class-type S' - means also structs. This fixes part of the problem. - (Expresion.ImplicitReferenceConversionExists): ditto. - - * decl.cs (DeclSparce.ResolveType): Only report the type-not-found - error if there were no errors reported during the type lookup - process, to avoid duplicates or redundant errors. Without this - you would get an ambiguous errors plus a type not found. We have - beaten the user enough with the first error. - - (DeclSparce.FindType): Emit a warning if we have an ambiguous - reference. - - * ecore.cs (SimpleName.DoResolveType): If an error is emitted - during the resolution process, stop the lookup, this avoids - repeated error reports (same error twice). - - * rootcontext.cs: Emit a warning if we have an ambiguous reference. - - * typemanager.cs (LookupType): Redo the type lookup code to match - the needs of System.Reflection. - - The issue is that System.Reflection requires references to nested - types to begin with a "+" sign instead of a dot. So toplevel - types look like: "NameSpace.TopLevelClass", and nested ones look - like "Namespace.TopLevelClass+Nested", with arbitrary nesting - levels. - -2002-09-19 Martin Baulig - - * codegen.cs (EmitContext.EmitTopBlock): If control flow analysis - says that a method always returns or always throws an exception, - don't report the CS0161. - - * statement.cs (FlowBranching.UsageVector.MergeChildren): Always - set `Returns = new_returns'. - -2002-09-19 Martin Baulig - - * expression.cs (MemberAccess.ResolveMemberAccess): When resolving - to an enum constant, check for a CS0176. - -2002-09-18 Miguel de Icaza - - * class.cs (TypeContainer.CheckPairedOperators): Now we check - for operators that must be in pairs and report errors. - - * ecore.cs (SimpleName.DoResolveType): During the initial type - resolution process, when we define types recursively, we must - check first for types in our current scope before we perform - lookups in the enclosing scopes. - - * expression.cs (MakeByteBlob): Handle Decimal blobs. - - (Invocation.VerifyArgumentsCompat): Call - TypeManager.TypeToCoreType on the parameter_type.GetElementType. - I thought we were supposed to always call this, but there are a - few places in the code where we dont do it. - -2002-09-17 Miguel de Icaza - - * driver.cs: Add support in -linkres and -resource to specify the - name of the identifier. - -2002-09-16 Miguel de Icaza - - * ecore.cs (StandardConversionExists): Sync with the conversion - code: allow anything-* to void* conversions. - - (FindMostSpecificSource): Use an Expression argument - instead of a Type, because we might be handed over a Literal which - gets a few more implicit conversions that plain types do not. So - this information was being lost. - - Also, we drop the temporary type-holder expression when not - required. - -2002-09-17 Martin Baulig - - * class.cs (PropertyBase.CheckBase): Don't check the base class if - this is an explicit interface implementation. - -2002-09-17 Martin Baulig - - * class.cs (PropertyBase.CheckBase): Make this work for indexers with - different `IndexerName' attributes. - - * expression.cs (BaseIndexerAccess): Rewrote this class to use IndexerAccess. - (IndexerAccess): Added special protected ctor for BaseIndexerAccess and - virtual CommonResolve(). - -2002-09-16 Miguel de Icaza - - * enum.cs (LookupEnumValue): Use the EnumConstant declared type, - and convert that to the UnderlyingType. - - * statement.cs (Foreach.Resolve): Indexers are just like variables - or PropertyAccesses. - - * cs-tokenizer.cs (consume_string): Track line numbers and columns - inside quoted strings, we were not doing this before. - -2002-09-16 Martin Baulig - - * ecore.cs (MethodGroupExpr.DoResolve): If we have an instance expression, - resolve it. This is needed for the definite assignment check of the - instance expression, fixes bug #29846. - (PropertyExpr.DoResolve, EventExpr.DoResolve): Likewise. - -2002-09-16 Nick Drochak - - * parameter.cs: Fix compile error. Cannot reference static member - from an instance object. Is this an mcs bug? - -2002-09-14 Martin Baulig - - * decl.cs (MemberCache.SetupCacheForInterface): Don't add an interface - multiple times. Fixes bug #30295, added test-166.cs. - -2002-09-14 Martin Baulig - - * statement.cs (Block.Emit): Don't emit unreachable code. - (Switch.SimpleSwitchEmit, Switch.TableSwitchEmit): Check for missing - `break' statements. - (Goto.Emit, Continue.Emit): Set ec.Breaks = true. - -2002-09-14 Martin Baulig - - * parameter.cs (Parameter.Attributes): Make this work if Modifier.ISBYREF - is set. - -2002-09-14 Martin Baulig - - * typemanager.cs (TypeManager.IsNestedChildOf): This must return false - if `type == parent' since in this case `type.IsSubclassOf (parent)' will - be false on the ms runtime. - -2002-09-13 Martin Baulig - - * ecore.cs (SimpleName.SimpleNameResolve): Include the member name in - the CS0038 error message. - -2002-09-12 Miguel de Icaza - - * expression.cs (CheckedExpr, UnCheckedExpr): If we have a - constant inside, return it. - -2002-09-12 Martin Baulig - - * cfold.cs (ConstantFold.DoConstantNumericPromotions): Check whether an - implicit conversion can be done between enum types. - - * enum.cs (Enum.LookupEnumValue): If the value is an EnumConstant, - check whether an implicit conversion to the current enum's UnderlyingType - exists and report an error if not. - - * codegen.cs (CodeGen.Init): Delete the symbol file when compiling - without debugging support. - - * delegate.cs (Delegate.CloseDelegate): Removed, use CloseType instead. - Fixes bug #30235. Thanks to Ricardo Fernández Pascual. - -2002-09-12 Martin Baulig - - * typemanager.cs (TypeManager.IsNestedChildOf): New method. - - * ecore.cs (IMemberExpr.DeclaringType): New property. - (SimpleName.SimpleNameResolve): Check whether we're accessing a - nonstatic member of an outer type (CS0038). - -2002-09-11 Miguel de Icaza - - * driver.cs: Activate the using-error detector at warning level - 4 (at least for MS-compatible APIs). - - * namespace.cs (VerifyUsing): Small buglett fix. - - * pending.cs (PendingImplementation): pass the container pointer. - - * interface.cs (GetMethods): Allow for recursive definition. Long - term, I would like to move every type to support recursive - definitions, not the current ordering mechanism that we have right - now. - - The situation is this: Attributes are handled before interfaces, - so we can apply attributes to interfaces. But some attributes - implement interfaces, we will now handle the simple cases - (recursive definitions will just get an error). - - * parameter.cs: Only invalidate types at the end if we fail to - lookup all types. - -2002-09-09 Martin Baulig - - * ecore.cs (PropertyExpr.Emit): Also check for - TypeManager.system_int_array_get_length so this'll also work when - compiling corlib. Fixes #30003. - -2002-09-09 Martin Baulig - - * expression.cs (ArrayCreation.MakeByteBlob): Added support for enums - and throw an exception if we can't get the type's size. Fixed #30040, - added test-165.cs. - -2002-09-09 Martin Baulig - - * ecore.cs (PropertyExpr.DoResolve): Added check for static properies. - - * expression.cs (SizeOf.DoResolve): Sizeof is only allowed in unsafe - context. Fixes bug #30027. - - * delegate.cs (NewDelegate.Emit): Use OpCodes.Ldvirtftn for - virtual functions. Fixes bug #30043, added test-164.cs. - -2002-09-08 Ravi Pratap - - * attribute.cs : Fix a small NullRef crash thanks to my stupidity. - -2002-09-08 Nick Drochak - - * driver.cs: Use an object to get the windows codepage since it's not a - static property. - -2002-09-08 Miguel de Icaza - - * statement.cs (For.Emit): for infinite loops (test == null) - return whether there is a break inside, not always "true". - - * namespace.cs (UsingEntry): New struct to hold the name of the - using definition, the location where it is defined, and whether it - has been used in a successful type lookup. - - * rootcontext.cs (NamespaceLookup): Use UsingEntries instead of - strings. - - * decl.cs: ditto. - -2002-09-06 Ravi Pratap - - * attribute.cs : Fix incorrect code which relied on catching - a NullReferenceException to detect a null being passed in - where an object was expected. - -2002-09-06 Miguel de Icaza - - * statement.cs (Try): flag the catch variable as assigned - - * expression.cs (Cast): Simplified by using ResolveType instead of - manually resolving. - - * statement.cs (Catch): Fix bug by using ResolveType. - -2002-09-06 Ravi Pratap - - * expression.cs (BetterConversion): Special case for when we have - a NullLiteral as the argument and we have to choose between string - and object types - we choose string the way csc does. - - * attribute.cs (Attribute.Resolve): Catch the - NullReferenceException and report error #182 since the Mono - runtime no more has the bug and having this exception raised means - we tried to select a constructor which takes an object and is - passed a null. - -2002-09-05 Ravi Pratap - - * expression.cs (Invocation.OverloadResolve): Flag a nicer error - message (1502, 1503) when we can't locate a method after overload - resolution. This is much more informative and closes the bug - Miguel reported. - - * interface.cs (PopulateMethod): Return if there are no argument - types. Fixes a NullReferenceException bug. - - * attribute.cs (Attribute.Resolve): Ensure we allow TypeOf - expressions too. Previously we were checking only in one place for - positional arguments leaving out named arguments. - - * ecore.cs (ImplicitNumericConversion): Conversion from underlying - type to the enum type is not allowed. Remove code corresponding to - that. - - (ConvertNumericExplicit): Allow explicit conversions from - the underlying type to enum type. This precisely follows the spec - and closes a bug filed by Gonzalo. - -2002-09-04 Gonzalo Paniagua Javier - - * compiler.csproj: - * compiler.csproj.user: patch from Adam Chester (achester@bigpond.com). - -2002-09-03 Miguel de Icaza - - * statement.cs (SwitchLabel.ResolveAndReduce): In the string case, - it was important that we stored the right value after the - reduction in `converted'. - -2002-09-04 Martin Baulig - - * location.cs (Location.SymbolDocument): Use full pathnames for the - source files. - -2002-08-30 Miguel de Icaza - - * expression.cs (ComposedCast): Use DeclSparce.ResolveType instead - of the expression resolve mechanism, because that will catch the - SimpleName error failures. - - (Conditional): If we can not resolve the - expression, return, do not crash. - -2002-08-29 Gonzalo Paniagua Javier - - * cs-tokenizer.cs: - (location): display token name instead of its number. - -2002-08-28 Martin Baulig - - * expression.cs (Binary.ResolveOperator): Don't silently return - but return an error if an operator cannot be applied between two - enum types. - -2002-08-28 Martin Baulig - - * class.cs (Constructor.Define): Set the permission attributes - correctly instead of making all constructors public. - -2002-08-28 Martin Baulig - - * ecore.cs (Expression.DoResolve): Do a TypeManager.MemberLook - for private members before reporting a CS0103; if we find anything, - it's a CS0122. - -2002-08-28 Martin Baulig - - * typemanager.cs (TypeManager.FilterWithClosure): It's not enough - to check whether `closure_start_type == closure_invocation_type', - we also need to check whether `m.DeclaringType == closure_invocation_type' - before bypassing the permission checks. We might be accessing - protected/private members from the base class. - (TypeManager.RealMemberLookup): Only set private_ok if private - members were requested via BindingFlags.NonPublic. - - * ecore.cs (MethodGroupExpr.IsExplicitImpl): New property. - - * expression.cs (MemberAccess.ResolveMemberAccess): Set - MethodGroupExpr.IsExplicitImpl if appropriate. - (Invocation.DoResolve): Don't report the CS0120 for explicit - interface implementations. - -2002-08-27 Martin Baulig - - * expression.cs (Invocation.DoResolve): If this is a static - method and we don't have an InstanceExpression, we must report - a CS0120. - -2002-08-25 Martin Baulig - - * expression.cs (Binary.ResolveOperator): Don't allow `!=' and - `==' between a valuetype and an object. - -2002-08-25 Miguel de Icaza - - * ecore.cs (TypeExpr): Provide a ToString method. - -2002-08-24 Martin Baulig - - * codegen.cs (CodeGen.InitMonoSymbolWriter): The symbol file is - now called proggie.dbg and it's a binary file. - -2002-08-23 Martin Baulig - - * decl.cs (MemberCache.AddMethods): Ignore varargs methods. - -2002-08-23 Martin Baulig - - * struct.cs (MyStructInfo.ctor): Make this work with empty - structs; it's not allowed to use foreach() on null. - -2002-08-23 Martin Baulig - - * codegen.cs (CodeGen.InitMonoSymbolWriter): Tell the symbol - writer the full pathname of the generated assembly. - -2002-08-23 Martin Baulig - - * statements.cs (FlowBranching.UsageVector.MergeChildren): - A `finally' block never returns or breaks; improved handling of - unreachable code. - -2002-08-23 Martin Baulig - - * statement.cs (Throw.Resolve): Allow `throw null'. - -2002-08-23 Martin Baulig - - * expression.cs (MemberAccess.ResolveMemberAccess): If this is an - EventExpr, don't do a DeclaredOnly MemberLookup, but check whether - `ee.EventInfo.DeclaringType == ec.ContainerType'. The - MemberLookup would return a wrong event if this is an explicit - interface implementation and the class has an event with the same - name. - -2002-08-23 Martin Baulig - - * statement.cs (Block.AddChildVariableNames): New public method. - (Block.AddChildVariableName): Likewise. - (Block.IsVariableNameUsedInChildBlock): Likewise. - (Block.AddVariable): Check whether a variable name has already - been used in a child block. - - * cs-parser.jay (declare_local_variables): Mark all variable names - from the current block as being used in a child block in the - implicit block. - -2002-08-23 Martin Baulig - - * codegen.cs (CodeGen.InitializeSymbolWriter): Abort if we can't - find the symbol writer. - - * driver.cs: csc also allows the arguments to /define being - separated by commas, not only by semicolons. - -2002-08-23 Martin Baulig - - * interface.cs (Interface.GetMembers): Added static check for events. - -2002-08-15 Martin Baulig - - * class.cs (MethodData.EmitDestructor): In the Expression.MemberLookup - call, use ec.ContainerType.BaseType as queried_type and invocation_type. - - * ecore.cs (Expression.MemberLookup): Added documentation and explained - why the MethodData.EmitDestructor() change was necessary. - -2002-08-20 Martin Baulig - - * class.cs (TypeContainer.FindMembers): Added static check for events. - - * decl.cs (MemberCache.AddMembers): Handle events like normal members. - - * typemanager.cs (TypeHandle.GetMembers): When queried for events only, - use Type.GetEvents(), not Type.FindMembers(). - -2002-08-20 Martin Baulig - - * decl.cs (MemberCache): Added a special method cache which will - be used for method-only searched. This ensures that a method - search will return a MethodInfo with the correct ReflectedType for - inherited methods. - -2002-08-20 Martin Baulig - - * decl.cs (DeclSpace.FindMembers): Made this public. - -2002-08-20 Gonzalo Paniagua Javier - - * delegate.cs: fixed build on windows. - [FIXME: Filed as bug #29150: MCS must report these errors.] - -2002-08-19 Ravi Pratap - - * ecore.cs (StandardConversionExists): Return a false - if we are trying to convert the void type to anything else - since that is not allowed. - - * delegate.cs (DelegateInvocation.DoResolve): Ensure that - we flag error 70 in the event an event is trying to be accessed - directly from outside the declaring type. - -2002-08-20 Martin Baulig - - * typemanager.cs, decl.cs: Moved MemberList, IMemberContainer and - MemberCache from typemanager.cs to decl.cs. - -2002-08-19 Martin Baulig - - * class.cs (TypeContainer): Implement IMemberContainer. - (TypeContainer.DefineMembers): Create the MemberCache. - (TypeContainer.FindMembers): Do better BindingFlags checking; only - return public members if BindingFlags.Public was given, check - whether members are static. - -2002-08-16 Martin Baulig - - * decl.cs (DeclSpace.Define): Splitted this in Define and - DefineMembers. DefineMembers is called first and initializes the - MemberCache. - - * rootcontext.cs (RootContext.DefineMembers): New function. Calls - DefineMembers() on all our DeclSpaces. - - * class.cs (TypeContainer.Define): Moved all code to DefineMembers(), - but call DefineMembers() on all nested interfaces. We call their - Define() in our new Define() function. - - * interface.cs (Interface): Implement IMemberContainer. - (Interface.Define): Moved all code except the attribute stuf to - DefineMembers(). - (Interface.DefineMembers): Initialize the member cache. - - * typemanager.cs (IMemberFinder): Removed this interface, we don't - need this anymore since we can use MemberCache.FindMembers directly. - -2002-08-19 Martin Baulig - - * typemanager.cs (MemberCache): When creating the cache for an - interface type, add all inherited members. - (TypeManager.MemberLookup_FindMembers): Changed `ref bool searching' - to `out bool used_cache' and documented it. - (TypeManager.MemberLookup): If we already used the cache in the first - iteration, we don't need to do the interfaces check. - -2002-08-19 Martin Baulig - - * decl.cs (DeclSpace.FindMembers): New abstract method. Moved this - here from IMemberFinder and don't implement this interface anymore. - (DeclSpace.MemberCache): Moved here from IMemberFinder. - - * typemanager.cs (IMemberFinder): This interface is now only used by - classes which actually support the member cache. - (TypeManager.builder_to_member_finder): Renamed to builder_to_declspace - since we only put DeclSpaces into this Hashtable. - (MemberLookup_FindMembers): Use `builder_to_declspace' if the type is - a dynamic type and TypeHandle.GetTypeHandle() otherwise. - -2002-08-16 Martin Baulig - - * typemanager.cs (ICachingMemberFinder): Removed. - (IMemberFinder.MemberCache): New property. - (TypeManager.FindMembers): Merged this with RealFindMembers(). - This function will never be called from TypeManager.MemberLookup() - so we can't use the cache here, just the IMemberFinder. - (TypeManager.MemberLookup_FindMembers): Check whether the - IMemberFinder has a MemberCache and call the cache's FindMembers - function. - (MemberCache): Rewrote larger parts of this yet another time and - cleaned it up a bit. - -2002-08-15 Miguel de Icaza - - * driver.cs (LoadArgs): Support quoting. - - (Usage): Show the CSC-like command line arguments. - - Improved a few error messages. - -2002-08-15 Martin Baulig - - * typemanager.cs (IMemberContainer.Type): New property. - (IMemberContainer.IsInterface): New property. - - The following changes are conditional to BROKEN_RUNTIME, which is - defined at the top of the file. - - * typemanager.cs (MemberCache.MemberCache): Don't add the base - class'es members, but add all members from TypeHandle.ObjectType - if we're an interface. - (MemberCache.AddMembers): Set the Declared flag if member.DeclaringType - is the current type. - (MemberCache.CacheEntry.Container): Removed this field. - (TypeHandle.GetMembers): Include inherited members. - -2002-08-14 Gonzalo Paniagua Javier - - * typemanager.cs: fixed compilation and added a comment on a field that - is never used. - -2002-08-15 Martin Baulig - - * class.cs (ConstructorInitializer.Resolve): In the - Expression.MemberLookup call, use the queried_type as - invocation_type. - - * typemanager.cs (IMemberContainer.GetMembers): Removed the `bool - declared' attribute, it's always true. - (IMemberContainer.Parent, IMemberContainer.Name): New properties. - (TypeManager.MemberLookup_FindMembers): [FIXME FIXME FIXME] Added - temporary wrapper for FindMembers which tells MemberLookup whether - members from the base classes are included in the return value. - This will go away soon. - (TypeManager.MemberLookup): Use this temporary hack here; once the - new MemberCache is completed, we don't need to do the DeclaredOnly - looping here anymore since the MemberCache will take care of this. - (TypeManager.IsSubclassOrNestedChildOf): Allow `type == parent'. - (MemberCache): When creating the MemberCache for a class, get - members from the current class and all its base classes. - (MemberCache.CacheEntry.Container): New field. This is a - temporary hack until the Mono runtime is fixed to distinguish - between ReflectedType and DeclaringType. It allows us to use MCS - with both the MS runtime and the unfixed Mono runtime without - problems and without accecting performance. - (MemberCache.SearchMembers): The DeclaredOnly looping from - TypeManager.MemberLookup is now done here. - -2002-08-14 Martin Baulig - - * statement.cs (MyStructInfo.MyStructInfo): Don't call - Type.GetFields on dynamic types but get the fields from the - corresponding TypeContainer. - (MyStructInfo.GetStructInfo): Added check for enum types. - - * typemanager.cs (MemberList.IsSynchronized): Implemented. - (MemberList.SyncRoot): Implemented. - (TypeManager.FilterWithClosure): No need to check permissions if - closure_start_type == closure_invocation_type, don't crash if - closure_invocation_type is null. - -2002-08-13 Martin Baulig - - Rewrote TypeContainer.FindMembers to use a member cache. This - gives us a speed increase of about 35% for the self-hosting MCS - build and of about 15-20% for the class libs (both on GNU/Linux). - - * report.cs (Timer): New class to get enhanced profiling. This - whole class is "TIMER" conditional since it remarkably slows down - compilation speed. - - * class.cs (MemberList): New class. This is an IList wrapper - which we're now using instead of passing MemberInfo[]'s around to - avoid copying this array unnecessarily. - (IMemberFinder.FindMember): Return a MemberList, not a MemberInfo []. - (ICachingMemberFinder, IMemberContainer): New interface. - (TypeManager.FilterWithClosure): If `criteria' is null, the name - has already been checked, otherwise use it for the name comparision. - (TypeManager.FindMembers): Renamed to RealMemberFinder and - provided wrapper which tries to use ICachingMemberFinder.FindMembers - if possible. Returns a MemberList, not a MemberInfo []. - (TypeHandle): New class, implements IMemberContainer. We create - one instance of this class per type, it contains a MemberCache - which is used to do the member lookups. - (MemberCache): New class. Each instance of this class contains - all members of a type and a name-based hash table. - (MemberCache.FindMembers): This is our new member lookup - function. First, it looks up all members of the requested name in - the hash table. Then, it walks this list and sorts out all - applicable members and returns them. - -2002-08-13 Martin Baulig - - In addition to a nice code cleanup, this gives us a performance - increase of about 1.4% on GNU/Linux - not much, but it's already - half a second for the self-hosting MCS compilation. - - * typemanager.cs (IMemberFinder): New interface. It is used by - TypeManager.FindMembers to call FindMembers on a TypeContainer, - Enum, Delegate or Interface. - (TypeManager.finder_to_member_finder): New PtrHashtable. - (TypeManager.finder_to_container): Removed. - (TypeManager.finder_to_delegate): Removed. - (TypeManager.finder_to_interface): Removed. - (TypeManager.finder_to_enum): Removed. - - * interface.cs (Interface): Implement IMemberFinder. - - * delegate.cs (Delegate): Implement IMemberFinder. - - * enum.cs (Enum): Implement IMemberFinder. - - * class.cs (TypeContainer): Implement IMemberFinder. - -2002-08-12 Martin Baulig - - * ecore.cs (TypeExpr.DoResolveType): Mark this as virtual. - -2002-08-12 Martin Baulig - - * ecore.cs (ITypeExpression): New interface for expressions which - resolve to a type. - (TypeExpression): Renamed to TypeLookupExpression. - (Expression.DoResolve): If we're doing a types-only lookup, the - expression must implement the ITypeExpression interface and we - call DoResolveType() on it. - (SimpleName): Implement the new ITypeExpression interface. - (SimpleName.SimpleNameResolve): Removed the ec.OnlyLookupTypes - hack, the situation that we're only looking up types can't happen - anymore when this method is called. Moved the type lookup code to - DoResolveType() and call it. - (SimpleName.DoResolveType): This ITypeExpression interface method - is now doing the types-only lookup. - (TypeExpr, TypeLookupExpression): Implement ITypeExpression. - (ResolveFlags): Added MaskExprClass. - - * expression.cs (MemberAccess): Implement the ITypeExpression - interface. - (MemberAccess.DoResolve): Added support for a types-only lookup - when we're called via ITypeExpression.DoResolveType(). - (ComposedCast): Implement the ITypeExpression interface. - - * codegen.cs (EmitContext.OnlyLookupTypes): Removed. Call - Expression.Resolve() with ResolveFlags.Type instead. - -2002-08-12 Martin Baulig - - * interface.cs (Interface.Define): Apply attributes. - - * attribute.cs (Attribute.ApplyAttributes): Added support for - interface attributes. - -2002-08-11 Martin Baulig - - * statement.cs (Block.Emit): Only check the "this" variable if we - do not always throw an exception. - - * ecore.cs (PropertyExpr.DoResolveLValue): Implemented, check - whether the property has a set accessor. - -2002-08-11 Martin Baulig - - Added control flow analysis support for structs. - - * ecore.cs (ResolveFlags): Added `DisableFlowAnalysis' to resolve - with control flow analysis turned off. - (IVariable): New interface. - (SimpleName.SimpleNameResolve): If MemberAccess.ResolveMemberAccess - returns an IMemberExpr, call DoResolve/DoResolveLValue on it. - (FieldExpr.DoResolve): Resolve the instance expression with flow - analysis turned off and do the definite assignment check after the - resolving when we know what the expression will resolve to. - - * expression.cs (LocalVariableReference, ParameterReference): - Implement the new IVariable interface, only call the flow analysis - code if ec.DoFlowAnalysis is true. - (This): Added constructor which takes a Block argument. Implement - the new IVariable interface. - (MemberAccess.DoResolve, MemberAccess.DoResolveLValue): Call - DoResolve/DoResolveLValue on the result of ResolveMemberLookup(). - This does the definite assignment checks for struct members. - - * class.cs (Constructor.Emit): If this is a non-static `struct' - constructor which doesn't have any initializer, call - Block.AddThisVariable() to tell the flow analysis code that all - struct elements must be initialized before control returns from - the constructor. - - * statement.cs (MyStructInfo): New public class. - (UsageVector.this [VariableInfo vi]): Added `int field_idx' - argument to this indexer. If non-zero, check an individual struct - member, not the whole struct. - (FlowBranching.CheckOutParameters): Check struct members. - (FlowBranching.IsVariableAssigned, SetVariableAssigned): Added - overloaded versions of these methods which take an additional - `int field_idx' argument to check struct members. - (FlowBranching.IsParameterAssigned, SetParameterAssigned): Added - overloaded versions of these methods which take an additional - `string field_name' argument to check struct member.s - (VariableInfo): Implement the IVariable interface. - (VariableInfo.StructInfo): New public property. Returns the - MyStructInfo instance of the variable if it's a struct or null. - (Block.AddThisVariable): New public method. This is called from - Constructor.Emit() for non-static `struct' constructor which do - not have any initializer. It creates a special variable for the - "this" instance variable which will be checked by the flow - analysis code to ensure that all of the struct's fields are - initialized before control returns from the constructor. - (UsageVector): Added support for struct members. If a - variable/parameter is a struct with N members, we reserve a slot - in the usage vector for each member. A struct is considered fully - initialized if either the struct itself (slot 0) or all its - members are initialized. - -2002-08-08 Martin Baulig - - * driver.cs (Driver.MainDriver): Only report an error CS5001 - if there were no compilation errors. - - * codegen.cs (EmitContext.EmitContext): Use the DeclSpace's - `UnsafeContext' property to determine whether the parent is in - unsafe context rather than checking the parent's ModFlags: - classes nested in an unsafe class are unsafe as well. - -2002-08-08 Martin Baulig - - * statement.cs (UsageVector.MergeChildren): Distinguish between - `Breaks' and `Returns' everywhere, don't set `Breaks' anymore if - we return. Added test17() and test18() to test-154.cs. - -2002-08-08 Martin Baulig - - * typemanager.cs (TypeManager.FilterWithClosure): If we have - Family access, make sure the invoking type isn't a subclass of the - queried type (that'd be a CS1540). - - * ecore.cs (Expression.MemberLookup): Added overloaded version of - this method which takes an additional `Type invocation_type'. - - * expression.cs (BaseAccess.DoResolve): Use the base type as - invocation and query type. - (MemberAccess.DoResolve): If the lookup failed and we're about to - report a CS0122, try a lookup with the ec.ContainerType - if this - succeeds, we must report a CS1540. - -2002-08-08 Martin Baulig - - * ecore.cs (IMemberExpr): Added `bool IsInstance' property. - (MethodGroupExpr): Implement the IMemberExpr interface. - - * expression (MemberAccess.ResolveMemberAccess): No need to have - any special code for MethodGroupExprs anymore, they're now - IMemberExprs. - -2002-08-08 Martin Baulig - - * typemanager.cs (TypeManager.FilterWithClosure): Check Assembly, - Family, FamANDAssem and FamORAssem permissions. - (TypeManager.IsSubclassOrNestedChildOf): New public method. - -2002-08-08 Martin Baulig - - * statement.cs (FlowBranchingType): Added LOOP_BLOCK. - (UsageVector.MergeChildren): `break' breaks unless we're in a switch - or loop block. - -Thu Aug 8 10:28:07 CEST 2002 Paolo Molaro - - * driver.cs: implemented /resource option to embed managed resources. - -2002-08-07 Martin Baulig - - * class.cs (FieldBase.Initializer): Renamed to `init' and made private. - (FieldBase.HasFieldInitializer): New public property. - (FieldBase.GetInitializerExpression): New public method. Resolves and - returns the field initializer and makes sure it is only resolved once. - (TypeContainer.EmitFieldInitializers): Call - FieldBase.GetInitializerExpression to get the initializer, this ensures - that it isn't resolved multiple times. - - * codegen.cs (EmitContext): Added `bool IsFieldInitialier'. This tells - the resolving process (SimpleName/MemberLookup) that we're currently - emitting a field initializer (which must not access any instance members, - this is an error CS0236). - - * ecore.cs (SimpleName.Error_ObjectRefRequired): Added EmitContext - argument, if the `IsFieldInitializer' flag is set, we must report and - error CS0236 and not an error CS0120. - -2002-08-07 Martin Baulig - - * ecore.cs (IMemberExpr): New public interface. - (FieldExpr, PropertyExpr, EventExpr): Implement IMemberExpr. - (SimpleName.SimpleNameResolve): Call MemberAccess.ResolveMemberAccess - if the expression is an IMemberExpr. - - * expression.cs (MemberAccess.ResolveMemberAccess): Allow `left' - to be null, implicitly default to `this' if we're non-static in - this case. Simplified the code a lot by using the new IMemberExpr - interface. Also fixed bug #28176 here. - -2002-08-06 Martin Baulig - - * cs-parser.jay (SimpleLookup): Removed. We need to create - ParameterReferences during semantic analysis so that we can do a - type-only search when resolving Cast, TypeOf and SizeOf. - (block): Pass the `current_local_parameters' to the Block's - constructor. - - * class.cs (ConstructorInitializer): Added `Parameters parameters' - argument to the constructor. - (ConstructorInitializer.Resolve): Create a temporary implicit - block with the parameters. - - * ecore.cs (SimpleName.SimpleNameResolve): Resolve parameter - references here if we aren't doing a type-only search. - - * statement.cs (Block): Added constructor which takes a - `Parameters parameters' argument. - (Block.Parameters): New public property. - - * support.cs (InternalParameters.Parameters): Renamed `parameters' - to `Parameters' and made it public readonly. - -2002-08-06 Martin Baulig - - * ecore.cs (Expression.Warning): Made this public as well. - - * report.cs (Report.Debug): Print the contents of collections. - -2002-08-06 Martin Baulig - - * ecore.cs (Expression.ResolveFlags): New [Flags] enum. This is - used to tell Resolve() which kinds of expressions it may return. - (Expression.Resolve): Added overloaded version of this method which - takes a `ResolveFlags flags' argument. This can be used to tell - Resolve() which kinds of expressions it may return. Reports a - CS0118 on error. - (Expression.ResolveWithSimpleName): Removed, use Resolve() with - ResolveFlags.SimpleName. - (Expression.Error118): Added overloaded version of this method which - takes a `ResolveFlags flags' argument. It uses the flags to determine - which kinds of expressions are allowed. - - * expression.cs (Argument.ResolveMethodGroup): New public method. - Resolves an argument, but allows a MethodGroup to be returned. - This is used when invoking a delegate. - - * TODO: Updated a bit. - -2002-08-06 Gonzalo Paniagua Javier - - Fixed compilation with csc. - - * ecore.cs: Expression.Error made public. Is this correct? Should - Warning be made public too? - - * expression.cs: use ea.Location instead of ea.loc. - [FIXME: Filed as bug #28607: MCS must report these errors.] - -2002-08-06 Martin Baulig - - * ecore.cs (Expression.loc): Moved the location here instead of - duplicating it in all derived classes. - (Expression.Location): New public property. - (Expression.Error, Expression.Warning): Made them non-static and - removed the location argument. - (Expression.Warning): Added overloaded version which takes an - `int level' argument. - (Expression.Error118): Make this non-static and removed the - expression and location arguments. - (TypeExpr): Added location argument to the constructor. - - * expression.cs (StaticCallExpr): Added location argument to - the constructor. - (Indirection, PointerArithmetic): Likewise. - (CheckedExpr, UnCheckedExpr): Likewise. - (ArrayAccess, IndexerAccess, UserCast, ArrayPtr): Likewise. - (StringPtr): Likewise. - - -2002-08-05 Martin Baulig - - * expression.cs (BaseAccess.DoResolve): Actually report errors. - - * assign.cs (Assign.DoResolve): Check whether the source - expression is a value or variable. - - * statement.cs (Try.Resolve): Set ec.InTry/InCatch/InFinally - while resolving the corresponding blocks. - - * interface.cs (Interface.GetInterfaceTypeByName): Actually report - an error, don't silently return null. - - * statement.cs (Block.AddVariable): Do the error reporting here - and distinguish between CS0128 and CS0136. - (Block.DoResolve): Report all unused labels (warning CS0164). - (LabeledStatement): Pass the location to the constructor. - (LabeledStatement.HasBeenReferenced): New property. - (LabeledStatement.Resolve): Set it to true here. - - * statement.cs (Return.Emit): Return success even after reporting - a type mismatch error (CS0126 or CS0127), this is what csc does and - it avoids confusing the users with any consecutive errors. - -2002-08-05 Martin Baulig - - * enum.cs (Enum.LookupEnumValue): Catch circular definitions. - - * const.cs (Const.LookupConstantValue): Catch circular definitions. - - * expression.cs (MemberAccess.DoResolve): Silently return if an - error has already been reported. - - * ecore.cs (Expression.MemberLookupFinal): Silently return if an - error has already been reported. - -2002-08-05 Martin Baulig - - * statement.cs (UsageVector): Only initialize the `parameters' - vector if we actually have any "out" parameters. - -2002-08-05 Martin Baulig - - * expression.cs (Binary.ResolveOperator): When combining delegates, - they must have the same type. - -2002-08-05 Martin Baulig - - * typemanager.cs (TypeManager.GetArgumentTypes): Don't call - PropertyInfo.GetIndexParameters() on dynamic types, this doesn't - work with the ms runtime and we also don't need it: if we're a - PropertyBuilder and not in the `indexer_arguments' hash, then we - are a property and not an indexer. - - * class.cs (TypeContainer.AsAccessible): Use Type.IsArray, - Type.IsPointer and Type.IsByRef instead of Type.HasElementType - since the latter one doesn't work with the ms runtime. - -2002-08-03 Martin Baulig - - Fixed bugs #27998 and #22735. - - * class.cs (Method.IsOperator): New public field. - (Method.CheckBase): Report CS0111 if there's already a method - with the same parameters in the current class. Report CS0508 when - attempting to change the return type of an inherited method. - (MethodData.Emit): Report CS0179 if a method doesn't have a body - and it's not marked abstract or extern. - (PropertyBase): New abstract base class for Property and Indexer. - (PropertyBase.CheckBase): Moved here from Property and made it work - for indexers. - (PropertyBase.Emit): Moved here from Property.Emit, Indexer.Emit is - the same so we can reuse it there. - (Property, Indexer): Derive from PropertyBase. - (MethodSignature.inheritable_property_signature_filter): New delegate - to find properties and indexers. - - * decl.cs (MemberCore.CheckMethodAgainstBase): Added `string name' - argument and improved error reporting. - - * parameter.cs (Parameters.GetEmptyReadOnlyParameters): Renamed to - EmptyReadOnlyParameters and made it a property. - - * typemanager.cs (TypeManager.GetArgumentTypes): Added overloaded - version of this method which takes a `PropertyInfo indexer'. - (TypeManager.RegisterIndexer): New method. - - * class.cs: Added myself as author of this file :-) - -2002-08-03 Gonzalo Paniagua Javier - - * class.cs: fixed compilation on windoze. - -2002-08-03 Martin Baulig - - * interface.cs (Interface.GetInterfaceBases): Check whether all - base interfaces are at least as accessible than the current one. - - * class.cs (TypeContainer.GetClassBases): Check whether base types - are at least as accessible than the current type. - (TypeContainer.AsAccessible): Implemented and made non-static. - (MemberBase.CheckParameters): Report errors if the accessibility - checks fail. - - * delegate.cs (Delegate.Delegate): The default visibility is - internal for top-level types and private for nested types. - (Delegate.Define): Report errors if the accessibility checks fail. - - * enum.cs (Enum.Enum): The default visibility is internal for - top-level types and private for nested types. - (Enum.DefineType): Compute the correct visibility. - - * modifiers.cs (Modifiers.TypeAttr): Added a version of this - function which takes a `bool is_toplevel' instead of a TypeContainer. - - * typemanager.cs (TypeManager.IsBuiltinType): `void' is also a - builtin type. - -2002-08-02 Martin Baulig - - * expression.cs (LocalVariableReferenc): Added constructor which - takes additional `VariableInfo vi' and `bool is_readonly' arguments. - (LocalVariableReference.IsReadOnly): New property. - (LocalVariableReference.DoResolveLValue): Report a CS1604 if the - variable is readonly, use our own readonly flag to do this; you can - use the new constructor to get a writable reference to a read-only - variable. - - * cs-parser.jay (foreach_statement, using_statement): Get a writable - reference to the local variable. - -2002-08-01 Miguel de Icaza - - * rootcontext.cs (ResolveCore): Also include System.Exception - - * statement.cs (Block.Emit): Do not emit the dead-code warnings if - we reach an EmptyStatement. - - (Catch.DoResolve, Throw.DoResolve): Throwing the System.Exception - is also fine. - - * expression.cs (Binary.ResolveOperator): Check error result in - two places. - - use brtrue/brfalse directly and avoid compares to null. - -2002-08-02 Martin Baulig - - * class.cs (TypeContainer.Define): Define all nested interfaces here. - Fixes bug #28407, added test-155.cs. - -2002-08-01 Martin Baulig - - * class.cs (Event.EmitDefaultMethod): Make this work with static - events. Fixes #28311, added verify-3.cs. - -2002-08-01 Martin Baulig - - * statement.cs (ForeachHelperMethods): Added `enumerator_type' and - `is_disposable' fields. - (Foreach.GetEnumeratorFilter): Set `hm.enumerator_type' and - `hm.is_disposable' if we're using the collection pattern. - (Foreach.EmitCollectionForeach): Use the correct type for the - enumerator's local variable, only emit the try/finally block if - necessary (fixes #27713). - -2002-08-01 Martin Baulig - - * ecore.cs (Expression.report118): Renamed to Error118 and made - it public static. - - * statement.cs (Throw.Resolve): Check whether the expression is of - the correct type (CS0118) and whether the type derives from - System.Exception (CS0155). - (Catch.Resolve): New method. Do the type lookup here and check - whether it derives from System.Exception (CS0155). - (Catch.CatchType, Catch.IsGeneral): New public properties. - - * typemanager.cs (TypeManager.exception_type): Added. - -2002-07-31 Miguel de Icaza - - * driver.cs: Updated About function. - -2002-07-31 Martin Baulig - - Implemented Control Flow Analysis. - - * codegen.cs (EmitContext.DoFlowAnalysis): New public variable. - (EmitContext.CurrentBranching): Added. - (EmitContext.StartFlowBranching): Added. - (EmitContext.EndFlowBranching): Added. - (EmitContext.KillFlowBranching): Added. - (EmitContext.IsVariableAssigned): Added. - (EmitContext.SetVariableAssigned): Added. - (EmitContext.IsParameterAssigned): Added. - (EmitContext.SetParameterAssigned): Added. - (EmitContext.EmitTopBlock): Added `InternalParameters ip' argument. - Added control flow analysis stuff here. - - * expression.cs (Unary.DoResolve): If the operator is Oper.AddressOf, - resolve the expression as lvalue. - (LocalVariableReference.DoResolve): Check whether the variable has - already been assigned. - (ParameterReference.DoResolveLValue): Override lvalue resolve to mark - the parameter as assigned here. - (ParameterReference.DoResolve): Check whether the parameter has already - been assigned. - (Argument.Resolve): If it's a `ref' or `out' argument, resolve the - expression as lvalue. - - * statement.cs (FlowBranching): New class for the flow analysis code. - (Goto): Resolve the label in Resolve, not in Emit; added flow analysis. - (LabeledStatement.IsDefined): New public property. - (LabeledStatement.AddUsageVector): New public method to tell flow - analyis that the label may be reached via a forward jump. - (GotoCase): Lookup and resolve the label in Resolve, not in Emit; added - flow analysis. - (VariableInfo.Number): New public field. This is used by flow analysis - to number all locals of a block. - (Block.CountVariables): New public property. This is the number of - local variables in this block (including the locals from all parent - blocks). - (Block.EmitMeta): Number all the variables. - - * statement.cs: Added flow analysis support to all classes. - -2002-07-31 Martin Baulig - - * driver.cs: Added "--mcs-debug" argument if MCS_DEBUG is defined. - To get debugging messages, compile mcs with /define:MCS_DEBUG and - then use this argument. - - * report.cs (Report.Debug): Renamed to conditional to "MCS_DEBUG". - - * makefile.gnu (MCS_FLAGS): Include $(MCS_DEFINES), the user may - use this to specify /define options. - -2002-07-29 Martin Baulig - - * statement.cs (Fixed): Moved all code that does variable lookups - and resolvings from Emit to Resolve. - - * statement.cs (For): Moved all code that does variable lookups - and resolvings from Emit to Resolve. - - * statement.cs (Using): Moved all code that does variable lookups - and resolvings from Emit to Resolve. - -2002-07-29 Martin Baulig - - * attribute.cs (Attribute.Resolve): Explicitly catch a - System.NullReferenceException when creating the - CustromAttributeBuilder and report a different warning message. - -2002-07-29 Martin Baulig - - * support.cs (ParameterData.ParameterName): Added method to - get the name of a parameter. - - * typemanager.cs (TypeManager.IsValueType): New public method. - -2002-07-29 Martin Baulig - - * parameter.cs (Parameter.Modifier): Added `ISBYREF = 8'. This - is a flag which specifies that it's either ref or out. - (Parameter.GetParameterInfo (DeclSpace, int, out bool)): Changed - the out parameter to `out Parameter.Modifier mod', also set the - Parameter.Modifier.ISBYREF flag on it if it's either ref or out. - - * support.cs (InternalParameters.ParameterModifier): Distinguish - between Parameter.Modifier.OUT and Parameter.Modifier.REF, set the - Parameter.Modifier.ISBYREF flag if it's either ref or out. - - * expression.cs (Argument.GetParameterModifier): Distinguish - between Parameter.Modifier.OUT and Parameter.Modifier.REF, set the - Parameter.Modifier.ISBYREF flag if it's either ref or out. - -2002-07-29 Martin Baulig - - * expression.cs (ParameterReference.ParameterReference): Added - `Location loc' argument to the constructor. - - * cs-parser.jay: Pass location to ParameterReference. - -2002-07-28 Miguel de Icaza - - * statement.cs (Try): Initialize the location. - - * cs-parser.jay: pass location to Try. - - * expression.cs (Unary.Reduce): Change the prototype to return - whether a constant fold could be performed or not. The result is - returned in an out parameters. In the case of Indirection and - AddressOf, we want to perform the full tests. - -2002-07-26 Miguel de Icaza - - * statement.cs (Statement.Emit): Flag dead code. - -2002-07-27 Andrew Birkett - - * expression.cs (Unary.Reduce): Handle AddressOf and Indirection. - -2002-07-27 Martin Baulig - - * class.cs (MethodData.Define): Put back call to - TypeManager.AddMethod(), accidentally commented this out. - - * report.cs (Debug): New public method to print debugging information, - this is `[Conditional ("DEBUG")]'. - -2002-07-26 Martin Baulig - - * cs-parser.jay (CSharpParser): Added `Stack switch_stack'. - (switch_statement): Push the current_block to the switch_stack and - pop it again when we're done with the switch. - (switch_section): The new block is a child of the current_block. - Fixes bug #24007, added test-152.cs. - -2002-07-27 Martin Baulig - - * expression.cs (Invocation.EmitArguments): When calling a varargs - function with only its fixed arguments, we need to pass an empty - array. - -2002-07-27 Martin Baulig - - Mono 0.13 has been released. - -2002-07-25 Miguel de Icaza - - * driver.cs: Rename --resource to --linkres, because that is what - we do currently, we dont support --resource yet. - - * cs-tokenizer.cs: Fix test for reporting endif mismatches. - -2002-07-25 Martin Baulig - - * class.cs (MethodData): New public class. This is a `method builder' - class for a method or one accessor of a Property/Indexer/Event. - (MethodData.GetMethodFlags): Moved here from MemberBase. - (MethodData.ApplyAttributes): Likewise. - (MethodData.ApplyObsoleteAttribute): Likewise. - (MethodData.ApplyConditionalAttribute): Likewise. - (MethodData.ApplyDllImportAttribute): Likewise. - (MethodData.CheckAbstractAndExternal): Likewise. - (MethodData.Define): Formerly knows as MemberBase.DefineMethod(). - (MethodData.Emit): Formerly known as Method.Emit(). - (MemberBase): Moved everything which was specific to a single - accessor/method to MethodData. - (Method): Create a new MethodData and call Define() and Emit() on it. - (Property, Indexer, Event): Create a new MethodData objects for each - accessor and call Define() and Emit() on them. - -2002-07-25 Martin Baulig - - Made MethodCore derive from MemberBase to reuse the code from there. - MemberBase now also checks for attributes. - - * class.cs (MethodCore): Derive from MemberBase, not MemberCore. - (MemberBase.GetMethodFlags): Moved here from class Method and marked - as virtual. - (MemberBase.DefineAccessor): Renamed to DefineMethod(), added - `CallingConventions cc' and `Attributes opt_attrs' arguments. - (MemberBase.ApplyAttributes): New virtual method; applies the - attributes to a method or accessor. - (MemberBase.ApplyObsoleteAttribute): New protected virtual method. - (MemberBase.ApplyConditionalAttribute): Likewise. - (MemberBase.ApplyDllImportAttribute): Likewise. - (MemberBase.CheckAbstractAndExternal): Likewise. - (MethodCore.ParameterTypes): This is now a property instead of a - method, it's initialized from DoDefineParameters(). - (MethodCore.ParameterInfo): Removed the set accessor. - (MethodCore.DoDefineParameters): New protected virtual method to - initialize ParameterTypes and ParameterInfo. - (Method.GetReturnType): We can now simply return the MemberType. - (Method.GetMethodFlags): Override the MemberBase version and add - the conditional flags. - (Method.CheckBase): Moved some code from Define() here, call - DoDefineParameters() here. - (Method.Define): Use DoDefine() and DefineMethod() from MemberBase - here to avoid some larger code duplication. - (Property.Emit, Indexer.Emit): Call CheckAbstractAndExternal() to - ensure that abstract and external accessors don't declare a body. - - * attribute.cs (Attribute.GetValidPieces): Make this actually work: - `System.Attribute.GetCustomAttributes (attr.Type)' does a recursive - lookup in the attribute's parent classes, so we need to abort as soon - as we found the first match. - (Attribute.Obsolete_GetObsoleteMessage): Return the empty string if - the attribute has no arguments. - - * typemanager.cs (TypeManager.AddMethod): Now takes a MemberBase instead - of a Method. - -2002-07-24 Gonzalo Paniagua Javier - - * cs-parser.jay: reverted previous patch. - -2002-07-24 Gonzalo Paniagua Javier - - * cs-parser.jay: fixed bug #22119. - -2002-07-24 Gonzalo Paniagua Javier - - * attribute.cs: fixed compilation. The error was: - "attribute.cs(571,17): error CS0177: The out parameter 'is_error' must - be assigned to before control leaves the current method." - [FIXME: Filed as bug #28186: MCS must report this error.] - -2002-07-25 Martin Baulig - - * attribute.cs (Attribute.Conditional_GetConditionName): New static - method to pull the condition name ouf of a Conditional attribute. - (Attribute.Obsolete_GetObsoleteMessage): New static method to pull - the obsolete message and error flag out of an Obsolete attribute. - - * class.cs (Method.GetMethodFlags): New public method to get the - TypeManager.MethodFlags for this method. - (Method.ApplyConditionalAttribute, Method.ApplyObsoleteAttribute): New - private methods. - (Method.Define): Get and apply the Obsolete and Conditional attributes; - if we're overriding a virtual function, set the new private variable - `parent_method'; call the new TypeManager.AddMethod(). - - * typemanager.cs (TypeManager.AddMethod): New static method. Stores - the MethodBuilder and the Method in a PtrHashtable. - (TypeManager.builder_to_method): Added for this purpose. - (TypeManager.MethodFlags): Added IsObsoleteError. - (TypeManager.GetMethodFlags): Added `Location loc' argument. Lookup - Obsolete and Conditional arguments in MethodBuilders. If we discover - an Obsolete attribute, emit an appropriate warning 618 / error 619 with - the message from the attribute. - -2002-07-24 Martin Baulig - - * cs-tokenizer.cs: Eat up trailing whitespaces and one-line comments in - preprocessor directives, ensure that the argument to #define/#undef is - exactly one identifier and that it's actually an identifier. - - Some weeks ago I did a `#define DEBUG 1' myself and wondered why this - did not work .... - -2002-07-24 Martin Baulig - - * statement.cs (Foreach.ForeachHelperMethods): Added `Type element_type', - initialize it to TypeManager.object_type in the constructor. - (Foreach.GetEnumeratorFilter): Set `hm.element_type' to the return type - of the `hm.get_current' method if we're using the collection pattern. - (Foreach.EmitCollectionForeach): Use `hm.element_type' as the source type - for the explicit conversion to make it work when we're using the collection - pattern and the `Current' property has a different return type than `object'. - Fixes #27713. - -2002-07-24 Martin Baulig - - * delegate.cs (Delegate.VerifyMethod): Simply return null if the method - does not match, but don't report any errors. This method is called in - order for all methods in a MethodGroupExpr until a matching method is - found, so we don't want to bail out if the first method doesn't match. - (NewDelegate.DoResolve): If none of the methods in the MethodGroupExpr - matches, report the 123. Fixes #28070. - -2002-07-24 Martin Baulig - - * expression.cs (ArrayAccess.EmitStoreOpcode): Moved the - TypeManager.TypeToCoreType() to the top of the method so the - following equality checks will work. Fixes #28107. - -2002-07-24 Martin Baulig - - * cfold.cs (ConstantFold.DoConstantNumericPromotions): "If either - operand is of type uint, and the other operand is of type sbyte, - short or int, the operands are converted to type long." - - Actually do what this comment already told us. Fixes bug #28106, - added test-150.cs. - -2002-07-24 Martin Baulig - - * class.cs (MethodBase): New abstract class. This is now a base - class for Property, Indexer and Event to avoid some code duplication - in their Define() and DefineMethods() methods. - (MethodBase.DoDefine, MethodBase.DefineAccessor): Provide virtual - generic methods for Define() and DefineMethods(). - (FieldBase): Derive from MemberBase, not MemberCore. - (Property): Derive from MemberBase, not MemberCore. - (Property.DefineMethod): Moved all the code from this method to the - new MethodBase.DefineAccessor(), just call it with appropriate - argumetnts. - (Property.Define): Call the new Property.DoDefine(), this does some - sanity checks and we don't need to duplicate the code everywhere. - (Event): Derive from MemberBase, not MemberCore. - (Event.Define): Use the new MethodBase.DefineAccessor() to define the - accessors, this will also make them work with interface events. - (Indexer): Derive from MemberBase, not MemberCore. - (Indexer.DefineMethod): Removed, call MethodBase.DefineAccessor() insstead. - (Indexer.Define): Use the new MethodBase functions. - - * interface.cs (InterfaceEvent.InterfaceEvent): Added `Location loc' - argument to the constructor. - (Interface.FindMembers): Added support for interface events. - (Interface.PopluateEvent): Implemented. - - Added test-149.cs for this. This also fixes bugs #26067 and #24256. - -2002-07-22 Miguel de Icaza - - * class.cs (TypeContainer.AddMethod): Adding methods do not use IsValid, - but this is required to check for a method name being the same as - the containing class. - - Handle this now. - -2002-07-22 Gonzalo Paniagua Javier - - * interface.cs: initialize variable. - -2002-07-23 Martin Baulig - - Implemented the IndexerName attribute in interfaces. - - * class.cs (TypeContainer.DefineIndexers): Don't set the indexer - name if this is an explicit interface implementation. - (Indexer.InterfaceIndexerName): New public variable. If we're - implementing an interface indexer, this is the IndexerName in that - interface. Otherwise, it's the IndexerName. - (Indexer.DefineMethod): If we're implementing interface indexer, - set InterfaceIndexerName. Use the new Pending.IsInterfaceIndexer - and Pending.ImplementIndexer methods. - (Indexer.Define): Also define the PropertyBuilder if we're - implementing an interface indexer and this is neither an explicit - interface implementation nor do the IndexerName match the one in - the interface. - - * pending.cs (TypeAndMethods): Added `MethodInfo [] need_proxy'. - If a method is defined here, then we always need to create a proxy - for it. This is used when implementing interface indexers. - (Pending.IsInterfaceIndexer): New public method. - (Pending.ImplementIndexer): New public method. - (Pending.InterfaceMethod): Added `MethodInfo need_proxy' argument. - This is used when implementing interface indexers to define a proxy - if necessary. - (Pending.VerifyPendingMethods): Look in the `need_proxy' array and - define a proxy if necessary. - - * interface.cs (Interface.IndexerName): New public variable. - (Interface.PopulateIndexer): Set the IndexerName. - (Interface.DefineIndexers): New private method. Populate all the - indexers and make sure their IndexerNames match. - - * typemanager.cs (IndexerPropertyName): Added support for interface - indexers. - -2002-07-22 Martin Baulig - - * codegen.cs (EmitContext.HasReturnLabel): New public variable. - (EmitContext.EmitTopBlock): Always mark the ReturnLabel and emit a - ret if HasReturnLabel. - (EmitContext.TryCatchLevel, LoopBeginTryCatchLevel): New public - variables. - - * statement.cs (Do.Emit, While.Emit, For.Emit, Foreach.Emit): Save - and set the ec.LoopBeginTryCatchLevel. - (Try.Emit): Increment the ec.TryCatchLevel while emitting the block. - (Continue.Emit): If the ec.LoopBeginTryCatchLevel is smaller than - the current ec.TryCatchLevel, the branch goes out of an exception - block. In this case, we need to use Leave and not Br. - -2002-07-22 Martin Baulig - - * statement.cs (Try.Emit): Emit an explicit ret after the end of the - block unless the block does not always return or it is contained in - another try { ... } catch { ... } block. Fixes bug #26506. - Added verify-1.cs to the test suite. - -2002-07-22 Martin Baulig - - * statement.cs (Switch.TableSwitchEmit): If we don't have a default, - then we do not always return. Fixes bug #24985. - -2002-07-22 Martin Baulig - - * expression.cs (Invocation.OverloadedResolve): Do the BetterFunction() - lookup on a per-class level; ie. walk up the class hierarchy until we - found at least one applicable method, then choose the best among them. - Fixes bug #24463 and test-29.cs. - -2002-07-22 Martin Baulig - - * typemanager.cs (TypeManager.ArrayContainsMethod): Don't check the - return types of the methods. The return type is not part of the - signature and we must not check it to make the `new' modifier work. - Fixes bug #27999, also added test-147.cs. - (TypeManager.TypeToCoreType): Added TypeManager.type_type. - - * expression.cs (Invocation.DoResolve): Call TypeManager.TypeToCoreType() - on the method's return type. - -2002-07-21 Martin Baulig - - * assign.cs: Make this work if the rightmost source is a constant and - we need to do an implicit type conversion. Also adding a few more tests - to test-38.cs which should have caught this. - - * makefile.gnu: Disable debugging, there's already the mcs-mono2.exe - target in the makefile for this. The makefile.gnu is primarily intended - for end-users who don't want to debug the compiler. - -2002-07-21 Martin Baulig - - * assign.cs: Improved the Assign class so it can now handle embedded - assignments (X = Y = Z = something). As a side-effect this'll now also - consume less local variables. test-38.cs now passes with MCS, added - a few new test cases to that test. - -2002-07-20 Martin Baulig - - * expression.cs (Binary.EmitBranchable): Emit correct unsigned branch - instructions. Fixes bug #27977, also added test-146.cs. - -2002-07-19 Gonzalo Paniagua Javier - - * cs-tokenizer.cs: fixed getHex (). - -2002-07-19 Martin Baulig - - * expression.cs (Invocation.EmitParams): Use TypeManager.LookupType(), - not Type.GetType() to lookup the array type. This is needed when - we're constructing an array of a user-defined type. - (ArrayAccess.EmitDynamicInitializers): Only emit the Ldelema for - single-dimensional arrays, but also for single-dimensial arrays of - type decimal. - -2002-07-19 Martin Baulig - - * expression.cs (New.DoEmit): Create a new LocalTemporary each time - this function is called, it's not allowed to share LocalBuilders - among ILGenerators. - -2002-07-19 Martin Baulig - - * expression.cs (Argument.Resolve): Report an error 118 when trying - to pass a type as argument. - -2002-07-18 Martin Baulig - - * ecore.cs (Expression.ImplicitNumericConversion): Don't emit a - Conv_R_Un for the signed `long' type. - -2002-07-15 Miguel de Icaza - - * expression.cs (MemberAccess.DoResolve): Do not reuse the field - `expr' for the temporary result, as that will fail if we do - multiple resolves on the same expression. - -2002-07-05 Miguel de Icaza - - * ecore.cs (SimpleNameResolve): Use ec.DeclSpace instead of - ec.TypeContainer for looking up aliases. - - * class.cs (TypeContainer): Remove LookupAlias from here. - - * decl.cs (DeclSpace); Move here. - -2002-07-01 Miguel de Icaza - - * class.cs (FindMembers): Only call filter if the constructor - bulider is not null. - - Also handle delegates in `NestedTypes' now. Now we will perform - type lookups using the standard resolution process. This also - fixes a bug. - - * decl.cs (DeclSpace.ResolveType): New type resolution routine. - This uses Expressions (the limited kind that can be parsed by the - tree) instead of strings. - - * expression.cs (ComposedCast.ToString): Implement, used to flag - errors since now we have to render expressions. - - (ArrayCreation): Kill FormElementType. Use ComposedCasts in - FormArrayType. - - * ecore.cs (SimpleName.ToString): ditto. - - * cs-parser.jay: Instead of using strings to assemble types, use - Expressions to assemble the type (using SimpleName, ComposedCast, - MemberAccess). This should fix the type lookups in declarations, - because we were using a different code path for this. - - * statement.cs (Block.Resolve): Continue processing statements - even when there is an error. - -2002-07-17 Miguel de Icaza - - * class.cs (Event.Define): Also remove the `remove' method from - the list of pending items. - - * expression.cs (ParameterReference): Use ldarg.N (0..3) to - generate more compact code. - -2002-07-17 Martin Baulig - - * const.cs (Const.LookupConstantValue): Add support for constant - `unchecked' and `checked' expressions. - Also adding test case test-140.cs for this. - -2002-07-17 Martin Baulig - - * statement.cs (Foreach.GetEnumeratorFilter): When compiling corlib, - check whether mi.ReturnType implements the IEnumerator interface; the - `==' and the IsAssignableFrom() will fail in this situation. - -2002-07-16 Ravi Pratap - - * ecore.cs (SimpleName.SimpleNameResolve) : Apply Gonzalo's fix - here too. - -2002-07-16 Gonzalo Paniagua Javier - - * expression.cs: fixed bug #27811. - -2002-07-14 Miguel de Icaza - - * expression.cs (ParameterReference.AddressOf): Patch from Paolo - Molaro: when we are a ref, the value already contains a pointer - value, do not take the address of it. - -2002-07-14 Rafael Teixeira - * removed mb-parser.jay and mb-tokenizer.cs - -Sat Jul 13 19:38:03 CEST 2002 Paolo Molaro - - * expression.cs: check against the building corlib void type. - -Sat Jul 13 19:35:58 CEST 2002 Paolo Molaro - - * ecore.cs: fix for valuetype static readonly fields: when - initializing them, we need their address, not the address of a copy. - -Sat Jul 13 17:32:53 CEST 2002 Paolo Molaro - - * typemanager.cs: register also enum_type in corlib. - -Sat Jul 13 15:59:47 CEST 2002 Paolo Molaro - - * class.cs: allow calling this (but not base) initializers in structs. - -Sat Jul 13 15:12:06 CEST 2002 Paolo Molaro - - * ecore.cs: make sure we compare against the building base types - in GetTypeSize (). - -Sat Jul 13 15:10:32 CEST 2002 Paolo Molaro - - * typemanager.cs: fix TypeToCoreType() to handle void and object - (corlib gets no more typerefs after this change). - -2002-07-12 Miguel de Icaza - - * expression.cs (ArrayCreation.EmitArrayArguments): use - Conv.Ovf.U4 for unsigned and Conv.Ovf.I4 for signed. - - (ArrayAccess.LoadArrayAndArguments): Use Conv_Ovf_I and - Conv_Ovf_I_Un for the array arguments. Even if C# allows longs as - array indexes, the runtime actually forbids them. - - * ecore.cs (ExpressionToArrayArgument): Move the conversion code - for array arguments here. - - * expression.cs (EmitLoadOpcode): System.Char is a U2, use that - instead of the default for ValueTypes. - - (New.DoEmit): Use IsValueType instead of - IsSubclassOf (value_type) - (New.DoResolve): ditto. - (Invocation.EmitCall): ditto. - - * assign.cs (Assign): ditto. - - * statement.cs (Unsafe): Ok, so I got the semantics wrong. - Statements *are* currently doing part of their resolution during - Emit. - - Expressions do always resolve during resolve, but statements are - only required to propagate resolution to their children. - -2002-07-11 Miguel de Icaza - - * driver.cs (CSCParseOption): Finish the /r: and /lib: support. - - (LoadAssembly): Do not add the dll if it is already specified - - (MainDriver): Add the System directory to the link path at the end, - after all the other -L arguments. - - * expression.cs (ArrayAccess.EmitLoadOpcode): I was using the - wrong opcode for loading bytes and bools (ldelem.i1 instead of - ldelem.u1) and using the opposite for sbytes. - - This fixes Digger, and we can finally run it. - - * driver.cs (UnixParseOption): Move the option parsing here. - (CSCParseOption): Implement CSC-like parsing of options. - - We now support both modes of operation, the old Unix way, and the - new CSC-like way. This should help those who wanted to make cross - platform makefiles. - - The only thing broken is that /r:, /reference: and /lib: are not - implemented, because I want to make those have the same semantics - as the CSC compiler has, and kill once and for all the confussion - around this. Will be doing this tomorrow. - - * statement.cs (Unsafe.Resolve): The state is checked during - resolve, not emit, so we have to set the flags for IsUnsfe here. - -2002-07-10 Miguel de Icaza - - * expression.cs (MemberAccess.ResolveMemberAccess): Since we can - not catch the Error_ObjectRefRequired in SimpleName (as it is - possible to have a class/instance variable name that later gets - deambiguated), we have to check this here. - -2002-07-10 Ravi Pratap - - * class.cs (TypeContainer.GetFieldFromEvent): Move away from here, - make static and put into Expression. - - (Event.Define): Register the private field of the event with the - TypeManager so that GetFieldFromEvent can get at it. - - (TypeManager.RegisterPrivateFieldOfEvent): Implement to - keep track of the private field associated with an event which - has no accessors. - - (TypeManager.GetPrivateFieldOfEvent): Implement to get at the - private field. - - * ecore.cs (GetFieldFromEvent): RE-write to use the above methods. - -2002-07-10 Miguel de Icaza - - * expression.cs (Binary.EmitBranchable): this routine emits the - Binary expression in a branchable context. This basically means: - we need to branch somewhere, not just get the value on the stack. - - This works together with Statement.EmitBoolExpression. - - * statement.cs (Statement.EmitBoolExpression): Use - EmitBranchable. - -2002-07-09 Miguel de Icaza - - * statement.cs (For): Reduce the number of jumps in loops. - - (For): Implement loop inversion for the For statement. - - (Break): We can be breaking out of a Try/Catch controlled section - (foreach might have an implicit try/catch clause), so we need to - use Leave instead of Br. - - * ecore.cs (FieldExpr.AddressOf): Fix for test-139 (augmented - now). If the instace expression supports IMemoryLocation, we use - the AddressOf method from the IMemoryLocation to extract the - address instead of emitting the instance. - - This showed up with `This', as we were emitting the instance - always (Emit) instead of the Address of This. Particularly - interesting when This is a value type, as we dont want the Emit - effect (which was to load the object). - -2002-07-08 Miguel de Icaza - - * attribute.cs: Pass the entry point to the DefinePInvokeMethod - - * statement.cs (Checked): Set the CheckedState during the resolve - process too, as the ConvCast operations track the checked state on - the resolve process, and not emit. - - * cs-parser.jay (namespace_member_declaration): Flag that we have - found a declaration when we do. This is used to flag error 1529 - - * driver.cs: Report ok when we display the help only. - -2002-07-06 Andrew Birkett - - * cs-tokenizer.cs (xtoken): Improve handling of string literals. - -2002-07-04 Miguel de Icaza - - * cs-tokenizer.cs (define): We also have to track locally the - defines. AllDefines is just used for the Conditional Attribute, - but we also need the local defines for the current source code. - -2002-07-03 Miguel de Icaza - - * statement.cs (While, For, Do): These loops can exit through a - Break statement, use this information to tell whether the - statement is the last piece of code. - - (Break): Flag that we break. - - * codegen.cs (EmitContexts): New `Breaks' state variable. - -2002-07-03 Martin Baulig - - * class.cs (TypeContainer.MethodModifiersValid): Allow override - modifiers in method declarations in structs. Otherwise, you won't - be able to override things like Object.Equals(). - -2002-07-02 Miguel de Icaza - - * class.cs (Method, Property, Indexer): Do not allow the public - modifier to be used in explicit interface implementations. - - (TypeContainer.MethodModifiersValid): Catch virtual, abstract and - override modifiers in method declarations in structs - -2002-07-02 Andrew Birkett - - * cs-tokenizer.cs (adjust_int, adjust_real): Do not abort on - integer or real overflow, report an error - -2002-07-02 Martin Baulig - - * typemanager.cs (TypeManager.InitCoreTypes): When compiling - corlib, dynamically call AssemblyBuilder.SetCorlibTypeBuilders() - to tell the runtime about our newly created System.Object and - System.ValueType types. - -2002-07-02 Miguel de Icaza - - * expression.cs (This): Use Stobj/Ldobj when we are a member of a - struct instead of Ldarg/Starg. - -2002-07-02 Martin Baulig - - * expression.cs (Indirection.Indirection): Call - TypeManager.TypeToCoreType() on `expr.Type.GetElementType ()'. - -2002-07-02 Martin Baulig - - * expression.cs (ArrayAccess.EmitStoreOpcode): If the type is a - ValueType, call TypeManager.TypeToCoreType() on it. - (Invocations.EmitParams): Call TypeManager.TypeToCoreType() on - the OpCodes.Newarr argument. - -2002-07-02 Martin Baulig - - * expression.cs (Invocation.EmitCall): When compiling corlib, - replace all calls to the system's System.Array type to calls to - the newly created one. - - * typemanager.cs (TypeManager.InitCodeHelpers): Added a few more - System.Array methods. - (TypeManager.InitCoreTypes): When compiling corlib, get the methods - from the system's System.Array type which must be replaced. - -Tue Jul 2 19:05:05 CEST 2002 Paolo Molaro - - * typemanager.cs: load unverifiable_code_ctor so we can build - corlib using the correct type. Avoid using GetTypeCode() with - TypeBuilders. - * rootcontext.cs: uses TypeManager.unverifiable_code_ctor and - TypeManager.object_type to allow building corlib. - -Tue Jul 2 19:03:19 CEST 2002 Paolo Molaro - - * ecore.cs: handle System.Enum separately in LoadFromPtr(). - -2002-07-01 Martin Baulig - - * class.cs: Make the last change actually work, we need to check - whether `ifaces != null' to avoid a crash. - -Mon Jul 1 16:15:03 CEST 2002 Paolo Molaro - - * class.cs: when we build structs without fields that implement - interfaces, we need to add the interfaces separately, since there is - no API to both set the size and add the interfaces at type creation - time. - -Mon Jul 1 14:50:47 CEST 2002 Paolo Molaro - - * expression.cs: the dimension arguments to the array constructors - need to be converted if they are a long. - -Mon Jul 1 12:26:12 CEST 2002 Paolo Molaro - - * class.cs: don't emit ldarg.0 if there is no parent constructor - (fixes showstopper for corlib). - -2002-06-29 Martin Baulig - - MCS now compiles corlib on GNU/Linux :-) - - * attribute.cs (Attribute.ApplyAttributes): Treat Accessors like Method, - ie. check for MethodImplOptions.InternalCall. - - * class.cs (TypeContainer.DefineType): When compiling corlib, both parent - and TypeManager.attribute_type are null, so we must explicitly check - whether parent is not null to find out whether it's an attribute type. - (Property.Emit): Always call Attribute.ApplyAttributes() on the GetBuilder - and SetBuilder, not only if the property is neither abstract nor external. - This is necessary to set the MethodImplOptions on the accessor methods. - (Indexer.Emit): Call Attribute.ApplyAttributes() on the GetBuilder and - SetBuilder, see Property.Emit(). - - * rootcontext.cs (RootContext.PopulateTypes): When compiling corlib, don't - populate "System.Object", "System.ValueType" and "System.Attribute" since - they've already been populated from BootCorlib_PopulateCoreTypes(). - -2002-06-29 Martin Baulig - - * ecore.cs (Expression.ImplicitReferenceConversionExists): If expr - is the NullLiteral, we also need to make sure that target_type is not - an enum type. - -2002-06-29 Martin Baulig - - * rootcontext.cs (RootContext.ResolveCore): We must initialize - `TypeManager.multicast_delegate_type' and `TypeManager.delegate_type' - before calling BootstrapCorlib_ResolveDelegate (). - -2002-06-27 Gonzalo Paniagua Javier - - * statement.cs: fixed build-breaker. All tests passed ok. - -2002-06-27 Martin Baulig - - * typemanager.cs (TypeManager.VerifyUnManaged): Added explicit check - for System.Decimal when compiling corlib. - -2002-06-27 Martin Baulig - - * statement.cs (Switch.TableSwitchEmit): Make this work with empty - switch blocks which contain nothing but a default clause. - -2002-06-26 Andrew - - * ../errors/cs1501-3.cs: Added new test for struct ctr typechecks. - -2002-06-27 Martin Baulig - - * ecore.cs (PropertyExpr.PropertyExpr): Call - TypeManager.TypeToCoreType() on the `pi.PropertyType'. - - * typemanager.cs (TypeManager.TypeToCoreType): Return if the type - is already a TypeBuilder. - -2002-06-27 Martin Baulig - - * ecore.cs (Expression.ImplicitReferenceConversionExists): Use - `target_type == TypeManager.array_type', not IsAssignableFrom() in - the "from an array-type to System.Array" case. This makes it work - when compiling corlib. - -2002-06-27 Martin Baulig - - * ecore.cs (Expression.SimpleNameResolve): If the expression is a - non-static PropertyExpr, set its InstanceExpression. This makes - the `ICollection.Count' property work in System/Array.cs. - -2002-06-25 Andrew Birkett - - * driver.cs: Made error handling more consistent. Errors now - tracked by Report class, so many methods which used to return int - now return void. Main() now prints success/failure and - errors/warnings message. - - Renamed '--probe' compiler argument to '--expect-error'. Removed - the magic number return values (123 and 124). Now, if the - expected error occurs, the compiler exits with success (exit value - 0). If the compilation completes without seeing that particular - error, the compiler exits with failure (exit value 1). The - makefile in mcs/errors has been changed to handle the new behaviour. - - * report.cs: Made 'expected error' number a property and renamed - it from 'Probe' to 'ExpectedError'. - - * genericparser.cs: Removed error handling support, since it is - now all done by Report class. - - * cs-parser.jay, mb-parser.jay: Errors are tracked by Report - class, so parse() no longer returns an int. - - * namespace.cs: Use Report.Error instead of GenericParser.error - -2002-06-22 Miguel de Icaza - - * class.cs (TypeContainer.AddMethod, TypeContainer.AddIndexer, - TypeContainer.AddOperator): At the front of the list put the - explicit implementations, so they get resolved/defined first. - -2002-06-21 Miguel de Icaza - - * class.cs (TypeContainer.VerifyImplements): Verifies that a given - interface type is implemented by this TypeContainer. Used during - explicit interface implementation. - - (Property.Define, Indexer.Define, Method.Define): Validate that - the given interface in the explicit implementation is one of the - base classes for the containing type. - - Also if we are explicitly implementing an interface, but there is - no match in the pending implementation table, report an error. - - (Property.Define): Only define the property if we are - not explicitly implementing a property from an interface. Use the - correct name also for those properties (the same CSC uses, - although that is really not needed). - - (Property.Emit): Do not emit attributes for explicitly implemented - properties, as there is no TypeBuilder. - - (Indexer.Emit): ditto. - - Hiding then means that we do not really *implement* a pending - implementation, which makes code fail. - -2002-06-22 Martin Baulig - - * ecore.cs (Expression.Constantify): Call TypeManager.TypeToCoreType() on - the return value of Object.GetType(). [FIXME: we need to do this whenever - we get a type back from the reflection library]. - -Fri Jun 21 13:37:57 CEST 2002 Paolo Molaro - - * typemanager.cs: make ExpandInterfaces() slip duplicated interfaces. - -2002-06-20 Miguel de Icaza - - * attribute.cs: Return null if we can not look up the type. - - * class.cs (TypeContainer.GetClassBases): Use ExpandInterfaces on - the interface types found. - - * interface.cs (Interface.GetInterfaceBases): Use ExpandInterfaces on the - interface types found. - - * typemanager.cs (GetInterfaces): Make this routine returns alll - the interfaces and work around the lame differences between - System.Type and System.Reflection.Emit.TypeBuilder in the results - result for GetInterfaces. - - (ExpandInterfaces): Given an array of interface types, expand and - eliminate repeated ocurrences of an interface. This expands in - context like: IA; IB : IA; IC : IA, IB; the interface "IC" to - be IA, IB, IC. - -2002-06-21 Martin Baulig - - * typemanager.cs (TypeManager.EnumToUnderlying): It's now safe to call this function - on System.Enum. - -2002-06-21 Martin Baulig - - * typemanager.cs (TypeManager.TypeToCoreType): New function. When compiling corlib - and called with one of the core types, return the corresponding typebuilder for - that type. - - * expression.cs (ArrayAccess.DoResolve): Call TypeManager.TypeToCoreType() on the - element type. - -2002-06-21 Martin Baulig - - * ecore.cs (Expression.ExplicitReferenceConversionExists): Use - `target_type.IsArray' instead of `target_type.IsSubclassOf (TypeManager.array_type)'. - (Expression.ConvertReferenceExplicit): Likewise. - - * expression.cs (ElementAccess.DoResolve): Likewise. - (ElementAccess.DoResolveLValue): Likewise. - -2002-06-10 Martin Baulig - - * interface.cs (Interface.PopulateIndexer): When creating the setter, we need to - add the "value" parameter to the parameter list. - - * statement.cs (Fixed.Emit): Pass the return value of the child block's Emit() - to our caller. - -2002-06-19 Miguel de Icaza - - * expression.cs (ArrayCreation.ExpressionToArrayArgument): Convert - the argument to an int, uint, long or ulong, per the spec. Also - catch negative constants in array creation. - -Thu Jun 20 17:56:48 CEST 2002 Paolo Molaro - - * class.cs: do not allow the same interface to appear twice in - the definition list. - -Wed Jun 19 22:33:37 CEST 2002 Paolo Molaro - - * ecore.cs: don't use ldlen with System.Array. - -Wed Jun 19 20:57:40 CEST 2002 Paolo Molaro - - * ecore.cs: stobj requires a type argument. Handle indirect stores on enums. - -Wed Jun 19 20:17:59 CEST 2002 Paolo Molaro - - * modifiers.cs: produce correct field attributes for protected - internal. Easy fix so miguel can work on ther harder stuff:-) - -2002-06-18 Miguel de Icaza - - * pending.cs: New file. Move the code from class.cs here. - Support clearning the pending flag for all methods (when not doing - explicit interface implementation). - -Tue Jun 18 10:36:22 CEST 2002 Paolo Molaro - - * rootcontext.cs: added a couple more types needed to bootstrap. - -2002-06-17 Miguel de Icaza - - * typemanager.cs (GetConstructor): Use DeclaredOnly to look the - constructor in the type, instead of any constructor in the type - hierarchy. Thanks to Paolo for finding this bug (it showed up as - a bug in the Mono runtime when applying the params attribute). - -2002-06-16 Rafael Teixeira - * changed namespace.cs to use "GenericParser.error(...)" instead of "CSharpParser.error(...)" - -2002-06-14 Rachel Hestilow - - * expression.cs (Unary.ResolveOperator): Use TypeManager - to resolve the type. - -2002-06-13 Ravi Pratap - - * cs-parser.jay (enum_member_declaration): Pass in the attributes - attached. - - * enum.cs (AddEnumMember): Add support to store the attributes associated - with each member too. - - * attribute.cs (CheckAttribute, ApplyAttributes): Update to handle - field builders too - this takes care of the enum member case. - -2002-06-10 Rachel Hestilow - - * typemanager.cs (TypeManager.VerifyUnManaged): Allow - address-of operator on both value types and pointers. - -2002-06-10 Martin Baulig - - * interface.cs (Interface.PopulateIndexer): Add the indexer's - PropertyBuilder to the `property_builders' list. - - * expression.cs (Indexers.GetIndexersForTypeOrInterface): New private method. - (Indexers.GetIndexersForType): Call GetIndexersForTypeOrInterface() on the - `lookup_type' and all its interfaces. Unfortunately, Type.FindMembers() won't - find any indexers which are inherited from an interface. - -2002-06-09 Martin Baulig - - * const.cs (Const.LookupConstantValue): Convert `Expr' to a literal of - the same type as the constant if necessary. There's also a test-130.cs - for this. - - * enum.cs (Enum.ChangeEnumType): Moved to typemanager.cs and made public. - - * typemanager.cs (TypeManager.ChangeType): Previously known as - Enum.ChangeEnumType(). - -2002-06-09 Martin Baulig - - * expression.cs (Cast.TryReduce): Added support for consts. - -2002-06-08 Ravi Pratap - - * class.cs (Accessor): Hold attributes information so we can pass - it along. - - * cs-parser.jay (get_accessor_declaration, set_accessor_declaration): - Modify to pass in attributes attached to the methods. - - (add_accessor_declaration, remove_accessor_declaration): Ditto. - - * attribute.cs (ApplyAttributes, CheckAttribute): Update accordingly - to handle the Accessor kind :-) - - * class.cs (Property.Emit, Event.Emit): Apply attributes to the accessors - -2002-06-08 Martin Baulig - - * expression.cs (Unary.TryReduceNegative): Added support for - ULongConstants. - -2002-06-08 Martin Baulig - - * enum.cs (Enum.LookupEnumValue): Don't report an error if the - name can't be found in the `defined_names' - the caller will do a - MemberLookup in this case and thus find methods in System.Enum - such as Enum.IsDefined(). - -2002-06-08 Martin Baulig - - * enum.cs (Enum.ChangeEnumType): This is a custom version of - Convert.ChangeType() which works with TypeBuilder created types. - (Enum.LookupEnumValue, Enum.Define): Use it here. - - * class.cs (TypeContainer.RegisterRequiredImplementations): Added - `TypeBuilder.BaseType != null' check. - (TypeContainer.FindMembers): Only lookup parent members if we - actually have a parent. - (Method.EmitDestructor): Added `ec.ContainerType.BaseType != null' check. - (ConstructorInitializer.Resolve): Likewise. - - * interface.cs (Interface.FindMembers): Added - `TypeBuilder.BaseType != null' check. - - * rootcontext.cs (RootContext.ResolveCore): Added - "System.Runtime.CompilerServices.IndexerNameAttribute" to - classes_second_stage. - - * typemanager.cs (TypeManager.InitCoreTypes): Don't initialize - debug_type and trace_type when compiling with --nostdlib. - -2002-06-07 Martin Baulig - - * class.cs (TypeContainer): Added `have_nonstatic_fields' field. - (AddField): Set it to true when adding a non-static field. - (DefineType): Use `have_nonstatic_fields' to find out whether we - have non-static fields, not `Fields != null'. - -2002-06-02 Miguel de Icaza - - * ecore.cs (SimpleNameResolve): Removed simple bug (we were - dereferencing a null on the static-field code path) - -2002-05-30 Martin Baulig - - * codegen.cs (InitMonoSymbolWriter): Added `string[] args' argument - to take command line arguments. Use reflection to call the new - custom `Initialize' function on the symbol writer and pass it the - command line arguments. - - * driver.cs (--debug-args): New command line argument to pass command - line arguments to the symbol writer. - -2002-05-28 Miguel de Icaza - - * assign.cs (DoResolve): Forgot to do the implicit conversion to - the target type for indexers and properties. Thanks to Joe for - catching this. - -2002-05-27 Miguel de Icaza - - * typemanager.cs (MethodFlags): returns the method flags - (Obsolete/ShouldIgnore) that control warning emission and whether - the invocation should be made, or ignored. - - * expression.cs (Invocation.Emit): Remove previous hack, we should - not do this on matching a base type, we should do this based on an attribute - - Only emit calls to System.Diagnostics.Debug and - System.Diagnostics.Trace if the TRACE and DEBUG defines are passed - on the command line. - - * rootcontext.cs: Global settings for tracing and debugging. - - * cs-tokenizer.cs (define): New utility function to track - defines. Set the global settings for TRACE and DEBUG if found. - -2002-05-25 Ravi Pratap - - * interface.cs (Populate*): Pass in the TypeContainer as well as - the DeclSpace as parameters so that we can create EmitContexts and - then use that to apply attributes etc. - - (PopulateMethod, PopulateEvent, PopulateProperty) - (PopulateIndexer): Apply attributes everywhere. - - * attribute.cs (CheckAttribute): Include InterfaceMethod, InterfaceEvent - etc. - - (ApplyAttributes): Update accordingly. - - We now apply interface attributes for all members too. - -2002-05-26 Miguel de Icaza - - * class.cs (Indexer.Define); Correctly check if we are explicit - implementation (instead of checking the Name for a ".", we - directly look up if the InterfaceType was specified). - - Delay the creation of the PropertyBuilder. - - Only create the PropertyBuilder if we are not an explicit - interface implementation. This means that explicit interface - implementation members do not participate in regular function - lookups, and hence fixes another major ambiguity problem in - overload resolution (that was the visible effect). - - (DefineMethod): Return whether we are doing an interface - implementation. - - * typemanager.cs: Temporary hack until we get attributes in - interfaces (Ravi is working on that) and we get IndexerName - support in interfaces. - - * interface.cs: Register the indexers as properties. - - * attribute.cs (Attribute.Resolve): Catch the error, and emit a - warning, I have verified that this is a bug in the .NET runtime - (JavaScript suffers of the same problem). - - * typemanager.cs (MemberLookup): When looking up members for - interfaces, the parent of an interface is the implicit - System.Object (so we succeed in searches of Object methods in an - interface method invocation. Example: IEnumerable x; x.ToString - ()) - -2002-05-25 Miguel de Icaza - - * class.cs (Event): Events should also register if they do - implement the methods that an interface requires. - - * typemanager.cs (MemberLookup); use the new GetInterfaces - method. - - (GetInterfaces): The code used to lookup interfaces for a type is - used in more than one place, factor it here. - - * driver.cs: Track the errors at the bottom of the file, we kept - on going. - - * delegate.cs (NewDelegate.Emit): We have to emit a null as the - instance if the method we are calling is static! - -2002-05-24 Miguel de Icaza - - * attribute.cs (ApplyAttributes): Make this function filter out - the IndexerName attribute (as that attribute in reality is never - applied) and return the string constant for the IndexerName - attribute. - - * class.cs (TypeContainer.Emit): Validate that all the indexers - have the same IndexerName attribute, and if so, set the - DefaultName attribute on the class. - - * typemanager.cs: The return value might contain other stuff (not - only methods). For instance, consider a method with an "Item" - property and an Item method. - - * class.cs: If there is a problem with the parameter types, - return. - -2002-05-24 Ravi Pratap - - * ecore.cs (ImplicitConversionExists): Wrapper function which also - looks at user defined conversion after making a call to - StandardConversionExists - we need this for overload resolution. - - * expression.cs : Update accordingly the various method calls. - - This fixes 2 bugs filed against implicit user defined conversions - -2002-05-22 Miguel de Icaza - - * statement.cs: Track the result of the assignment. - -2002-05-21 Miguel de Icaza - - * expression.cs (MemberAccess): Improved error reporting for - inaccessible members. - -2002-05-22 Martin Baulig - - * makefile (mcs-mono2.exe): New target. This is mcs compiled with - itself with debugging support. - -2002-05-22 Martin Baulig - - * typemanager.cs ("System.Runtime.InteropServices.StructLayoutAttribute"): - Removed, this isn't needed anymore. - -2002-05-20 Martin Baulig - - * typemanager.cs (InitEnumUnderlyingTypes): "System.Char" can't - be underlying type for an enum. - -2002-05-20 Miguel de Icaza - - * typemanager.cs (InitEnumUnderlyingTypes): New helper function - that splits out the loading of just the core types. - - * rootcontext.cs (ResolveCore): Split the struct resolution in - two, so we can load the enumeration underlying types before any - enums are used. - - * expression.cs (Is): Bandaid until we fix properly Switch (see - bug #24985 for details). - - * typemanager.cs (ImplementsInterface): The hashtable will contain - a null if there are no interfaces implemented. - -2002-05-18 Miguel de Icaza - - * cs-parser.jay (indexer_declarator): It is fine to have array - parameters - -2002-05-17 Miguel de Icaza - - * typemanager.cs: (RegisterBuilder): New function used to register - TypeBuilders that implement interfaces. Since - TypeBuilder.GetInterfaces (as usual) does not work with lame - Reflection.Emit. - (AddUserType): register interfaces. - - (ImplementsInterface): Use the builder_to_ifaces hash if we are - dealing with TypeBuilder. Also, arrays are showing up as - SymbolTypes, which are not TypeBuilders, but whose GetInterfaces - methods can not be invoked on them! - - * ecore.cs (ExplicitReferenceConversionExists): Made public. - (ImplicitReferenceConversionExists): Split out from - StandardConversionExists. - - * expression.cs (As): We were only implementing one of the three - cases for the as operator. We now implement them all. - (Is): Implement the various other cases for Is as well. - - * typemanager.cs (CACHE): New define used to control if we want or - not the FindMembers cache. Seems to have a negative impact on - performance currently - - (MemberLookup): Nested types have full acess to - enclosing type members - - Remove code that coped with instance/static returns for events, we - now catch this in RealFindMembers. - - (RealFindMembers): only perform static lookup if the instance - lookup did not return a type or an event. - -2002-05-17 Miguel de Icaza - - * assign.cs (CompoundAssign): We pass more semantic information - now to Compound Assignments than we did before: now we have all - the information at hand, and now we resolve the target *before* we - do the expression expansion, which allows the "CacheValue" method - to have the effect we intended (before, a [x] += 1 would generate - two differen ArrayAccess expressions from the ElementAccess, - during the resolution process). - - (CompoundAssign.DoResolve): Resolve target and original_source here. - -2002-05-16 Miguel de Icaza - - * expression.cs (ArrayAccess): dropped debugging information. - - * typemanager.cs: Small bug fix: I was always returning i_members, - instead of one of i_members or s_members (depending on which had - the content). - - * assign.cs (IAssignMethod.CacheTemporaries): New method. This - method is invoked before any code generation takes place, and it - is a mechanism to inform that the expression will be invoked more - than once, and that the method should use temporary values to - avoid having side effects - - (Assign.Emit): Call CacheTemporaries in the IAssignMethod. - - * ecore.cs (Expression.CacheTemporaries): Provide empty default - implementation. - - * expression.cs (Indirection, ArrayAccess): Add support for - CacheTemporaries in these two bad boys. - - * ecore.cs (LoadFromPtr): figure out on our own if we need to use - ldobj or ldind_ref. - (StoreFromPtr): Handle stobj as well. - - * expression.cs (UnaryMutator): Share more code. - - * typemanager.cs (FindMembers): Thanks to Paolo for tracking this - down: I was not tracking the Filter function as well, which - was affecting the results of the cache. - -2002-05-15 Miguel de Icaza - - * attribute.cs: Remove the hack to handle the CharSet property on - StructLayouts. - -2002-05-14 Miguel de Icaza - - * attribute.cs (DoResolve): More uglyness, we now only try to - resolve the attribute partially, to extract the CharSet - information (only if we are a StructLayout attribute). Otherwise - - (GetExtraTypeInfo): Add some code to conditionally kill in the - future this. I am more and more convinced that the .NET - framework has special code to handle the attribute setting on - certain elements. - - * expression.cs (IsParamsMethodApplicable): Revert my previous - foreach change here, it was wrong. - -2002-05-13 Miguel de Icaza - - * cs-tokenizer.cs: (pp_primary): Eat the ')' at the end. - (pp_expr): do not abort on unknown input, just return. - (eval): abort if there are pending chars. - - * attribute.cs (Attribute.Resolve): Positional parameters are - optional. Deal with that case. - - * class.cs (DefineType): Call Attribute.GetExtraTypeInfo to fetch - the Ansi/Unicode/Auto information for the type. - - (TypeContainer.DefineType): instantiate the EmitContext here, as - we will be using it during the type definition (to resolve - attributes) and during the emit phase. - - * attribute.cs (Attribute.GetExtraTypeInfo): This routine is used - to pull type information out of the attributes - - (Attribute.Resolve): track the constructor builder, and allow for - multiple invocations (structs and classes will use this). - - * ecore.cs (MemberLookupFinal): new version with all the - parameters customizable. - - * expression.cs (New.DoResolve): Use MemberLookupFinal to locate - constructors. Return if the result value is null (as the error - would have been flagged already by MemberLookupFinal) - - Do not allow instances of abstract classes or interfaces to be - created. - - * class.cs: (MethodSignature.InheritableMemberSignatureCompare): - We have to compare the assembly property here when dealing with - FamANDAssem and Assembly access modifiers, because we might be - creating an assembly from *modules* (that means that we are not - getting TypeBuilders for types defined in other modules that are - part of this assembly). - - (Method.Emit): If the method is marked abstract and has a body, - emit an error. - - (TypeContainer.DefineMembers): If both the defined member and the - parent name match are methods, then do not emit any warnings: let - the Method.Define routine take care of flagging warnings. But if - there is a mismatch (method overrides something else, or method is - overriwritten by something, then emit warning). - - (MethodSignature.MemberSignatureCompare): If the sig.ret_type is - set to null, this means `do not check for the return type on the - signature'. - - (Method.Define): set the return type for the method signature to - null, so that we get methods with the same name and parameters and - different return types. This is used to flag warning 114 (you are - hiding a method, and you probably want to use the new/override - keywords instead). - - * typemanager.cs (MemberLookup): Implemented proper access - control, closing a long standing set of bug reports. The problem - was that the Framework only has two bits: Public and NonPublic, - and NonPublic includes private and protected methods, but we need - to enforce the FamANDAssem, FamOrAssem and Family. - -2002-05-11 Miguel de Icaza - - * statement.cs (GotoCase): Return true: Ammounts to giving up - knowledge on whether we return or not, and letting the other case - be responsible for it. - -2002-05-10 Miguel de Icaza - - * driver.cs: Do not load directories for each file processed, only - do it if there is a pattern. - - * ecore.cs: Report readonly assigns here as well, as we might have - been resolved only by MemberAccess. - - (SimpleName.SimpleNameResolve): Also be useful for LValue - resolution. We need this to propagate assign to local readonly variables - - * typemanager.cs: Use a ptrhashtable for the criteria, because we - do not want to reuse potential criteria memory. - - * class.cs (MyEventBuilder): Set reflected_type; - - * ecore.cs (Constantify): Added support for constifying bools. - - (RootContext.LookupType): Added a cache for values looked up in - the declaration space. - - * typemanager.cs (FindMembers): Now is a front-end to - RealFindMembers, and provides a two-level hashtable-based cache to - the request. - - 15% performance improvement: from 22.5 to 19.2 seconds. - - * expression.cs (IsParamsMethodApplicable): use foreach. - (Invocation.DoResolve): ditto. - (New.DoResolve): ditto. - (ArrayCreation.DoResolve): ditto. - - * ecore.cs (FindMostEncompassingType): use foreach. - - * delegate.cs (NewDelegate.DoResolve): Use foreach - - * ecore.cs (Expression.FindMostSpecificSource): Use foreach. - (RemoveMethods): use foreach. - - * expression.cs (Invocation.MakeUnionSet): Optimization: Use two - nested foreach statements instead of for, and also break out of - the inner loop once a match is found. - - (Invocation.OverloadResolve): Use foreach, simplify the code. - -2002-05-08 Miguel de Icaza - - * cfold.cs (BinaryFold): During an enumeration evaluation context, - we actually unwrap the expression to allow for extra information - to be extracted. - - * expression.cs: Use Shr_Un on unsigned operations. - -2002-05-08 Ravi Pratap - - * ecore.cs (FindMostEncompass*): Fix trivial bug where the set of - applicable operators was not being considered correctly. This closes - the bug Miguel reported. - -Wed May 8 16:40:50 CEST 2002 Paolo Molaro - - * attribute.cs: check that the type derives from System.Attribute - and report the correct error in that case (moved the duplicate code to - its own method, too). - -Wed May 8 11:50:31 CEST 2002 Paolo Molaro - - * attribute.cs: lookup attribute type name as the spec says: first the - bare attribute name and then name + "Attribute" (nant compiles with - mcs after this fix). - -2002-05-07 Miguel de Icaza - - * expression.cs (Unary.TryReduceNegative): Ah! Tricky! Tricky! - Because of the way we parse things, we should try to see if a - UIntConstant can fit in an integer. - -2002-05-07 Ravi Pratap - - * ecore.cs (GetConversionOperators): Do not pick up op_True operators - when we are in an explicit context. - - (ConvertReferenceExplicit): When converting from Iface type S to Class - T make sure the rules are implemented as an OR. - - * parameter.cs (ParameterType): Make it a property for now although the - purpose really isn't anything immediate. - - * expression.cs (Is*Applicable): Do better checking on the parameter type - of a ref/out parameter. The ones from the system assemblies are already - marked with the correct type so we don't need to do any correction. - - * ecore.cs (StandardConversionExists): Conversion from Interface types to - the object type is standard too so include that. - -2002-05-06 Miguel de Icaza - - * ecore.cs (StandardConversionExists): Augment with missing code: - deal with IntConstant, LongConstants and Enumerations. - - * assign.cs: Report the error, instead of failing silently - - * rootcontext.cs (AddGlobalAttributes): Track attributes on the - typecontainer that they are declared, because the - typecontainer/namespace will have the list of using clauses that - need to be applied. - - Assembly Attributes were escaping the normal registration - mechanism. - - (EmitCode): Apply attributes within an EmitContext that represents - the container they were declared on. - - * cs-parser.jay: Track bases for structs. How did I get this wrong? - -2002-05-06 Ravi Pratap - - * ecore.cs (FindMostEncompassingType, FindMostEncompassedType): - Revamp completely - make much cleaner as we now operate only - on a set of Types. - - (FindMostSpecificSource, FindMostSpecificTarget): New methods - to implement the logic detailed in the spec more correctly. - - (UserDefinedConversion): Update accordingly. - -2002-05-06 Miguel de Icaza - - * statement.cs: Return flow analysis information up. - - * cs-tokenizer.cs (adjust_real): Share code between LITERAL_DOUBLE - and the default. - - (token): Do not consume an extra character before calling - decimal_digits. - -2002-05-06 Piers Haken - - * cs-parser.jay: add 'override' attribute to System.Object.Finalize - -2002-05-06 Miguel de Icaza - - * class.cs (Constructor.Emit): Set the IsStatic flag in the - EmitContext during the instance constructor initializer - resolution, to stop access to instance variables. - - This is mandated by the spec, last paragraph of the `constructor - initializers' section. - -2002-05-05 Miguel de Icaza - - * cs-parser.jay, class.cs (Accessor): new class used to represent - an accessor (get or set). In the past we used `null' to represent - a missing accessor. But this is ambiguous because there was no - way to tell in abstract indexers/properties if one of them was - specified. - - Now there is a way of addressing that. - - * expression.cs (Indexers.GetIndexersForType): Use TypeManager.MemberLookup - instead of FindMembers. - - * class.cs (TypeContainer.EmitFieldInitializer): Do not typecast - the result of Assign.Resolve as Assign, but rather as ExpressionStatement. - - * attribute.cs: Treat indexers and properties as the same in terms - of applying attributes - - * ecore.cs (FindMostEncompassedType): Use statically initialized - EmptyExpressions()s like we do elsewhere to avoid creating useless - objects (and we take this out of the tight loop). - - (GetConversionOperators): Move the code to extract the actual - operators to a separate routine to clean things up. - -2002-05-04 Miguel de Icaza - - * ecore.cs (FieldExpr): Remove un-needed tests for null, since now - events are always registered FieldBuilders. - - * class.cs (FieldBase): New class shared by Fields - - * delegate.cs: If we are a toplevel delegate, use our full name. - If we are a nested delegate, then only use our tail name. - -2002-05-02 Ravi Pratap - - * expression.cs (IsApplicable): Ensure that we add the "&" to - ref/out types before comparing it with the type of the argument. - - (IsParamsMethodApplicable): Ditto. - - (Argument.Type): Use TypeManager.LookupType instead of Type.GetType - - silly me ;-) - - * delegate.cs : Handle the case when we have more than one applicable - method. Flag an error only when we finish checking all. - -2002-05-02 Miguel de Icaza - - * expression.cs: Add support for boolean static initializers. - -2002-05-01 Miguel de Icaza - - * attribute.cs: Use proper cast for Events, since we use a MyEventBuilder. - - * parameter.cs (ComputeParameterTypes, - ComputeAndDefineParameterTypes): Better error handling: now we - clear the `types' cache if we fail during any of the type lookups. - We also return the status code correctly to our caller - - * delegate.cs: If we fail to define a delegate, abort the extra - steps. - - * expression.cs (Binary.ResolveOperator): for - operator==(object,object) and operator !=(object, object) we also - have to verify that there is an implicit conversion from one to - the other. - - (ArrayAccess.DoResolve): Array Access can operate on - non-variables. - -2002-04-30 Miguel de Icaza - - * assign.cs (CompoundAssign): A new class used as a "flag" that - the assignment actually is happening as part of a compound - assignment operator. - - During compound assignment, a few new rules exist to enable things - like: - - byte b |= 1 + 2 - - From the spec: - - x op= y can be evaluated as x = (T) (x op y) (ie, an explicit cast - to the type of x) if y is implicitly convertible to the type of x, - and the operator is a builtin operator and the return type of the - operator is explicitly convertible to the type of x. - - * rootcontext.cs: Reset warning level to 2. 4 catches various - "interesting" features in mcs, we must clean this up at some - point, but currently am trying to kill other bugs ;-) - - * ecore.cs (SimpleName.SimpleNameResolve): Perform member lookups - in container classes as well. - - * expression.cs (Binary.ResolveOperator): Handle string case - before anything else (as operator overloading does emit an error - before doing anything else). - - This code could go away when we move to a table driven model, but - i could not come up with a good plan last night. - -2002-04-30 Lawrence Pit - - * typemanager.cs (CSharpName): reimplementation using regex. - * class.cs: added null check for fields in Emit - * rootcontext.cs: set warninglevel to 4 - -2002-04-29 Miguel de Icaza - - * typemanager.cs (CSharpName): reimplemented with Lupus - suggestion. - -2002-04-28 Miguel de Icaza - - * statement.cs (If): correclty implement Resolve, because we were - not catching sem errors in there. The same process is needed - everywhere else. - (Return, StatementExpression, For, While, Do, Throw, Lock): Implement Resolve - - - (Statement.Warning_DeadCodeFound): Factorize code. - (While): Report dead code here too. - - (Statement): Added Resolve virtual method to allow - for resolution split from the emit code. - -2002-04-26 Miguel de Icaza - - * statement.cs (EmitBoolExpression): No longer try to resolve the - expression here. - (MakeBoolean): New utility function that resolve, implicitly - converts to boolean and tags the expression. - - - (If, Do): Implement dead code elimination. - (While): Implement loop inversion - - (Do, While, For, If): Resolve the expression prior to calling our - code generation. - -2002-04-22 Lawrence Pit - - * class.cs: - - added method Report28 (warning: program has more than one entry point) - - added method IsEntryPoint, implements paragraph 10.1 of the spec - - modified method Method.Define, the part at the end of the method - - * rootcontext.cs: added static public Location EntryPointLocation; - - * ../errors/cs0028.cs : Add test case for the above warning. - - * typemanager.cs: - - modified method CSharpName to allow arrays of primitive type to - be printed nicely (e.g. instead of System.Int32[][] it now prints - int[][]) - - added method CSharpSignature: returns the signature of a method - in string format to be used in reporting errors, warnings, etc. - - * support.cs: InternalParameters.ParameterDesc variable tmp initialized - with String.Empty. - -2002-04-26 Ravi Pratap - - * delegate.cs (Define): Fix extremely silly bug where I was - setting the type of the 'object' parameter of the BeginInvoke - method to System.IAsyncResult instead of System.Object ;-) - -2002-04-26 Miguel de Icaza - - * class.cs (ConstructorInitializer.Resolve): Also use DeclaredOnly - here. - - (Constructor.Emit): return if we fail to initialize the - constructor. Another door closed! - - * expression.cs (New.DoResolve): Improve error message (from -6 to - 1501). Use DeclaredOnly lookup to find the exact constructor. - - * typemanager.cs (MemberLookup): If DeclaredOnly is set, do not - loop. This is useful. - - * cs-parser.jay: Adjust the default parameters so that destructors - have the proper signature. - -2002-04-26 Martin Baulig - - * driver.cs (LoadAssembly): If `assembly' contains any characters - which are only valid in path names and not in assembly names - (currently slash, backslash and point), use Assembly.LoadFrom () - instead of Assembly.Load () on the `assembly' (before iteration - over the link_paths). - -2002-04-26 Martin Baulig - - * cs-tokenizer.cs (is_hex): Correctly handle lowercase chars. - -2002-04-25 Miguel de Icaza - - * class.cs (Property): use the new typemanager.MemberLookup - - (TypeContainer.MemberLookup): Implement using the - TypeManager.MemberLookup now. - - * typemanager.cs: Make MemberLookup a function of the TypeManager, - and return MemberInfos, so that these can be used without an - EmitContext (what we had before). - -2002-04-24 Miguel de Icaza - - * expression.cs: Fix the case where the argument to params if the - type of the params. I omitted handling this before. Fixed - -2002-04-22 Miguel de Icaza - - * driver.cs: Call BootCorlib_PopulateCoreType - - * class.cs (Property.CheckBase): Check for properties only, not - for all members. - - * interface.cs: Temporary hack: try/catch around the - CustomAttributeBuilder, because I am getting an exception that I - do not understand. - - * rootcontext.cs (BootCorlib_PopulateCoreType): Populate some - types whose definitions are required to be there (attributes are - defined before standard types). - - Compute definitions as we boot the various types, as they are used - immediately (value_type class will need object_type, but if we do - not initialize object_type, we will pass a null, which will let - the runtime pick the System.Object from the existing corlib, which - is not what we want). - -2002-04-22 Patrik Torstensson - - * cs-tokenizer.cs: fixed a number of trim() issues. - -2002-04-22 Ravi Pratap - - * expression.cs (Argument.Type): Ensure that we return the correct - type when we have out or ref parameters [in which case we - append a "&"]. - -2002-04-22 Miguel de Icaza - - * class.cs (Property, Indexer): Allow extern modifier in there. - - * typemanager.cs (InitBaseTypes): Initializes object_type and - value_type, since those will be used early on during the bootstrap - process to compile corlib. - - (InitCoreTypes): Move code from here to InitBaseTypes. - -2002-04-21 Miguel de Icaza - - * ecore.cs (PropertyExpr): Optimize calls to Array::get_Length on - single-dimension arrays as using the ldlen opcode. - - Daniel Lewis discovered this optimization. - - * typemanager.cs: Add signature for System.Array::get_Length - -2002-04-20 Gonzalo Paniagua Javier - - * statement.cs: report the error when the foreach does not apply to an - array nor a collection. - -2002-04-19 Miguel de Icaza - - * expression.cs: Add implicit conversions to the operator ~. - - * constant.cs (DecimalConstant.Emit): Emit decimal value. - - * typemanager.cs: Locate the decimal constructor. - -2002-04-17 Gonzalo Paniagua Javier - - * attribute.cs: use the new property of TypeOf. - * expression.cs: added 'get' property around typearg. - - These changes fix a build breaker reported by NickD. Is this the - correct way to fix? If not, please, revert my changes and make it - work :-). - -2002-04-17 Miguel de Icaza - - * attribute.cs: Add support for typeof in attribute invocations. - I am not sure that this is right though. - -2002-04-14 Duncan Mak - - * cfold.cs (BinaryFold): Catch DivideByZeroException in the - Binary.Operator.Division case. - -2002-04-13 Ravi Pratap - - * class.cs (DefineType): Ensure that we do a proper check on - attribute types and also register it with the TypeManager. - - (TypeContainer.Targets): The default for attribute types is - AttributeTargets.All. - - * attribute.cs (ApplyAttributes): Registering the attribute type - is done elsewhere, not when we discover we have a Usage attribute. - -2002-04-12 Ravi Pratap - - * expression.cs (VerifyArgumentsCompat): Implement Miguel's suggestion - and get rid of is_delegate parameter. - - * everywhere : update. - -2002-04-12 Ravi Pratap - - * cs-parser.jay (compilation_unit): Revamp completely to use - some new ideas that I got from Rhys' grammar to solve the problems - with assembly level attributes. - - (outer_declaration): New grammar production. - - (attribute_sections): Add. - - (opt_attributes): Base on attribute_sections - - (namespace_declaration): Allow opt_attributes to tackle the case - when we have assembly level attributes - we are clever in this - regard now ;-) - - * attribute.cs (ApplyAttributes): Do not worry about assembly - attributes in the non-global context. - - * rootcontext.cs (AddGlobalAttributes): Go back to using this - instead of SetGlobalAttributes. - - * class.cs, rootcontext.cs : Ensure we define and generate - attribute types before anything else. - - * attribute.cs (CheckAttribute and GetValidPlaces): Handle the exception - and flag the new error -20 for the case when the attribute type - does not have valid targets specified. csc does not catch this. - - * ../errors/errors.txt : update for error # -20 - -2002-04-11 Ravi Pratap - - * support.cs (InternalParameters.ParameterModifier): Do some null - checking and return sane values. - - * class.cs (Method.Define): If we are a PInvoke method, ensure - that we are static and extern. Report error # 601 - - * ../errors/cs0601.cs : Add test case for the above error. - -2002-04-07 Ravi Pratap - - * rootcontext.cs (attribute_types): We need to keep type of - all attribute types separately and emit code for them first. - - (RegisterAttribute) : Implement. - - * class.cs (DefineType): Check if the current Type is a custom - attribute type and register it accordingly. - - * rootcontext.cs (AddGlobalAttributes): Fix silly bug where we were - adding the first attribute twice and rename to - - (SetGlobalAttributes): this. - - * rootcontext.cs (NamespaceLookup): Run through the aliases too and perform - lookups. - - * attribute.cs (ApplyAttributes): Take an additional argument telling us - if we are processing global arguments. Hmm, I am unsure of this. - -2002-04-12 Gonzalo Paniagua Javier - - * expression.cs: added static array of strings to avoid calling - Enum.ToString () for Operator in Binary. Significant recover of - performance. - -2002-04-10 Miguel de Icaza - - * class.cs (FindMembers): Allow the Builders of the various - members to be null. If they are skip them. This only happens - during the PInvoke declaration. - -2002-04-09 Miguel de Icaza - - * parameter.cs (Parameters.ComputeParameterTypes): Flag the - failure, so we do not keep going afterwards. - - * expression.cs: (Invocation.OverloadResolve): I believe Ravi - wanted to pass `false' as the `is_delegate' argument. If this is - the case, why not use delegate_type == null to mean `is_delegate = - false' and anything else as is_delegate = true. - -Tue Apr 9 05:40:12 2002 Piers Haken - - * statement.cs: fixed SimpleSwitchEmit to make 'goto case' goto the - code for the section, not the beginning of the tests. - -2002-04-08 Miguel de Icaza - - * cfold.cs: Handle operator + (Enum x, Underlying x) - - * expression.cs (Binary): same. Warn about errors where we have - Enum/Enum in operator + as well. - -Mon Apr 8 06:29:03 2002 Piers Haken - - * statement.cs: - - added support for switch(bool) - - optimize loading of I8/U8 constants (ldc.i4, iconv_i8) - - add TableSwitchEmit() to handle table-based switch statements - -2002-04-05 Ravi Pratap - - * expression.cs (Invocation.OverloadResolve): Factor out code which - does parameter compatibility checking with arguments so that we can - re-use the code even from Delegate.VerifyApplicability - - (VerifyArgumentsCompat): Move above code here. - - * delegate.cs (VerifyApplicability): Get rid of duplicate code - and instead make a call to the above method. - -2002-03-31 Ravi Pratap - - * typemanager.cs (attribute_type): Corresponds to System.Attribute. - We use it to keep track of classes which are attribute types. - -2002-04-02 Miguel de Icaza - - * delegate.cs (Delegate.Define): Correctly define the types in the - presence of fixed and array parameters. - - * class.cs (TypeContainers.FindMembers): Use NonPublic flag while - doing FindMembers. - - * ecore.cs (Expression.MemberLookup): Reset binding flags to not - include NonPublic after the first iteration. - - * class.cs (Indexer.CheckBase): Only check if both parents are - non-null. - - * cs-parser.jay (accessor_body): If empty, set to null. - - * ecore.cs (SimpleName.SimpleNameResolve): We did not have the - same code path here to resolve constants names that we did have in - MemberAccess.DoResolve. There is too much code duplicated here. - -2002-04-01 Miguel de Icaza - - * statement.cs, makefile: Drop Statementcollection and just use ArrayLists - - * ecore.cs: Optimize UserDefinedConversion by minimizing the calls - to MakeUnionSet. - - * cs-tokenizer.cs: Reuse a single StringBuilder for assembling - tokens, numbers and strings. - - * ecore.cs (MethodGroupExpr): Make Emit warn about missing - parenthesis. - - * delegate.cs: Use ComputeAndDefineParameterTypes for both the - asyncronous parameters and the regular parameters. - - * codegen.cs (CodeGen.Init): Use the constructor that allows us to - specify the target directory. - - * expression.cs: (This.DoResolve): Simplify - (As.Emit): Optimize, do not generate IsInst if the expression is - always of the given type. - - (Is.DoResolve): Bug fix, we were reporting both always/never for - the is expression. - - * (Invocation.MakeUnionSet): Simplify vastly and optimize, we were - creating too many unnecessary arrays. - -2002-03-31 Miguel de Icaza - - * class.cs (EmitFieldInitializer): Use Assign expression to assign - fields instead of rolling our own initializer. Takes care of all - implicit conversions, and drops unnecessary static checks/argument. - -2002-03-31 Dick Porter - - * driver.cs: use the GetDirectories() return values properly, and - use "/" as path separator. - -2002-03-30 Miguel de Icaza - - * expression.cs (Unary): Optimize - - expr into expr. - (Binary): Optimize a + (-b) into a -b. - - * codegen.cs (CodeGen): Made all methods static. - -2002-03-29 Miguel de Icaza - - * rootcontext.cs: - - * decl.cs: Rename `definition' into `TypeBuilder' and drop the - TypeBuilder property. - - * cs-parser.jay: Drop the use of RecordXXX and use RecordDecl - instead. - - * tree.cs: Removed the various RecordXXXX, and replaced with a - single RecordDecl. Removed all the accessor methods, and just - left a single access point Type - - * enum.cs: Rename DefineEnum to DefineType. - - * decl.cs: New abstract method `DefineType' used to unify the - Defines for Enumerations, Interfaces, TypeContainers and - Delegates. - - (FindType): Moved LookupInterfaceOrClass here. Moved the - LookupBaseClasses method that used to live in class.cs and - interface.cs here, and renamed to FindType. - - * delegate.cs: Implement DefineType. Take advantage of the - refactored pattern for locating the parent builder without taking - the parent_builder argument (which we know does not work if we are - nested, and triggering a toplevel definition). - -2002-03-28 Miguel de Icaza - - * decl.cs (MemberCore.CheckMethodAgainstBase): Test if the - accessibility of a member has changed during override and report - an error if so. - - * class.cs (Method.Define, Property.Define): Only complain on - overrides if the method is private, any other accessibility is - fine (and since we just checked the permission is the same, we are - good to go). - - * cs-tokenizer.cs: only line, region, endregion, if, endif, else - and elif are processed always. The other pre-processing - directives are only processed if we are "taking" the path - -2002-03-29 Martin Baulig - - * class.cs (Method.Emit): Only emit symbolic debugging info if the - current location is not Null. - - * codegen.cs (CodeGen.SaveSymbols): Split out symbol writing code into - a separate method so we can profile it. - - * driver.cs (ShowTime): We need to use `(int) span.TotalSeconds' since - `span.Seconds' are just seconds, but no minutes or hours. - (MainDriver): Profile the CodeGen.SaveSymbols calls. - -2002-03-28 Miguel de Icaza - - * class.cs (Method.Define), (Property.Define), (Indexer.Define): - Remove the gratuitous set of Final: - - // If an interface implementation, then we can set Final. - if (((flags & MethodAttributes.Abstract) == 0) && - implementing.DeclaringType.IsInterface) - flags |= MethodAttributes.Final; - - I do not know what I was smoking when I used that. - - - * cs-parser.jay, delegate.cs: Make Delegate be a DeclSpace, first - step into fixing the name resolution issues for delegates and - unifying the toplevel name resolution. - -2002-03-28 Martin Baulig - - * class.cs (Method.Emit): If we have a symbol writer, call its - OpenMethod(), CloseMethod() and SetMethodSourceRange() methods to - tell it about the current method. - - * codegen.cs (EmitContext.Mark): New public method. Tell the symbol - writer that we're going to emit the first byte of IL code for a new - statement (a new source line). - (EmitContext.EmitTopBlock): If we have a symbol writer, call - EmitContext.Mark() before emitting any code. - - * location.cs (SymbolDocument): Return null when we're Null. - - * statement.cs (Statement): Moved the `Location loc' variable here. - (Statement.EmitBoolExpression): If we have a symbol writer, call - ec.Mark() before emitting any code to tell it that we're at the - beginning of a new statement. - (StatementExpression): Added `Location' argument to the constructor. - (Block): Added public readonly variable `StartLocation' and public - variable `EndLocation'. The latter is to be set using SetEndLocation(). - (Block): Added constructor which takes a start and end location. - (Block.SetEndLocation): New method. This sets the end location. - (Block.EmitMeta): If we have a symbol writer, tell it the names of the - local variables we create. - (Block.Emit): If we have a symbol writer, call ec.Mark() before emitting - each statement and do also mark the begin and end of the block. - - * cs-parser.jay (block : OPEN_BRACE): Use the new `Block' constructor to - tell it the current lexer.Location, use Location.Null for the end of the - block. - (block : OPEN_BRACE opt_statement_list CLOSE_BRACE): When closing the - current block, set its end location using SetEndLocation(). - (statement_expression): StatementExpression constructor now takes the - lexer.Location as additional argument. - (for_statement, declare_local_variables): Likewise. - (declare_local_variables): When creating a new implicit block, use the - new Block constructor and pass it the lexer.Location. - -2002-03-28 Miguel de Icaza - - * ecore.cs (Expression.MemberLookup): On interfaces, lookup - members also on the parent interfaces recursively. - -2002-03-27 Miguel de Icaza - - * report.cs: Use new formats, since Gonzalo finished the missing - bits. - - * expression.cs (Binary.ResolveOperator): added missing operator| - operator& and operator^ for bool/bool. - - * cs-parser.jay: CheckDef now takes a Location argument that is - used to report errors more precisly (instead of reporting the end - of a definition, we try to track something which is a lot closer - to the source of the problem). - - * cs-tokenizer.cs: Track global token use, so we can properly flag - the use of #define/#undef after the first token has been seen. - - Also, rename the reportXXXX to Error_DescriptiveName - - * decl.cs (DeclSpace.IsTopLevel): Move property here from - TypeContainer, so that Enum and Interface can use this too. - - * class.cs (TypeContainer.LookupInterfaceOrClass, - GetInterfaceOrClass, GetClassBases, DefineType): Drop the - `builder' argument. Typically this was used to pass the parent - builder (a ModuleBuilder or a TypeBuilder from whoever triggered - the definition). - - The problem is that a nested class could trigger the definition of - a toplevel class, and the builder would be obviously wrong in that - case. - - So we drop this argument, and we compute dynamically the - TypeBuilder/ModuleBuilder (the correct information was available - to us anyways from DeclSpace.Parent) - - * interface.cs (Interface.DefineInterface): Drop builder - parameter cleanup like class.cs - - * enum.cs (Enum.DefineEnum): Drop builder parameter. Clean up - like class.cs - - * statement.cs (Switch.EmitObjectInteger): Emit short/ushort - values. - - (Try.Emit): Propagate the returns value from the statement. - - (Return.Emit): Even if we are leavning - - * driver.cs: Catch IOExpcetion for Directory.GetFiles as well. - - * modifiers.cs: Fix the computation of MethodAttributes flags. - -Tue Mar 26 21:14:36 CET 2002 Paolo Molaro - - * driver.cs: allow compilation of files that start with '/'. - Add a default case when checking the argument of --target. - -2002-03-25 Miguel de Icaza - - * interface.cs: Implement the same search algorithm for types in - the interface code. - - * delegate.cs: Do not allow multiple definition. - - * Recovered ChangeLog that got accidentally amputated - - * interface.cs (Interface.DefineInterface): Prevent from double definitions. - - * rootcontext.cs: Load manually enum to allow core classes to - contain enumerations. - - * enum.cs, ecore.cs, driver.cs, attribute.cs, class.cs, expression.cs: - Update to new static methods in TypeManager. - - * typemanager.cs (GetMethod, GetConstructor): Use our - implementation of FindMembers to find the members, since during - corlib compilation, the types are TypeBuilders and GetMethod and - GetConstructor do not work. - - Make all methods in TypeManager static. - - (InitCodeHelpers): Split the functionality from - the InitCodeTypes function. - - * driver.cs: Call InitCodeHelpers after we have populated the - types. - - * cs-parser.jay (delegate_declaration): we did not used to compute - the delegate name correctly for void delegates. - -2002-03-24 Miguel de Icaza - - * rootcontext.cs (RootContext): Init the interface_resolve_order - and type_container_resolve_order always. - - (ResolveCore, BootstrapCorlib_ResolveClass, - BootstrapCorlib_ResolveStruct): New functions to bootstrap the - compiler when compiling with --nostdlib - - * class.cs (TypeContainer.DefineType): Check that our parent is - not null. This test is most important when we are bootstraping - the core types. - - * codegen.cs: Split out the symbol writing code. - -2002-03-25 Martin Baulig - - * driver.cs (-g): Made -g an alias for --debug. - -2002-03-24 Martin Baulig - - * codegen.cs (SymbolWriter): New public variable. Returns the - current symbol writer. - (CodeGen): Added `bool want_debugging_support' argument to the - constructor. If true, tell the ModuleBuild that we want debugging - support and ask it for the ISymbolWriter. - (Save): If we have a symbol writer, call it's Close() method after - saving the assembly. - - * driver.c (--debug): New command line argument to create a - debugger information file. - - * location.cs (SymbolDocument): New public property. Returns an - ISymbolDocumentWriter object for the current source file or null - if we don't have a symbol writer. - -2002-03-21 Miguel de Icaza - - * driver.cs (LoadAssembly): Correctly return when all the paths - have been tried and not before. - - * statement.cs (Switch.Emit): return the actual coverage for this - statement (returns/not-returns) - - (Switch.SimpleSwitchEmit): Do not generate jumps to the end of the - switch of the statement if we are the last switch section. That - kills two problems: try/catch problems (we used to emit an empty - nop at the end) and switch statements where all branches would - return. - -2002-03-19 Miguel de Icaza - - * driver.cs: Add default assemblies (the equivalent to the - Microsoft CSC.RSP file) - - * cs-tokenizer.cs: When updating `cols and setting it to zero, - also update tokens_seen and set it to false. - - * driver.cs: Implement --recurse for Mike. - - * driver.cs (SplitPathAndPattern): Small bug fix, I was not - correctly splitting out the paths. - -2002-03-18 Miguel de Icaza - - * interface.cs (Interface.PopulateProperty): Instead of using - `parent' as the declaration space for the set parameters, use - `this' - - * support.cs (InternalParameters): InternalParameters constructor - takes a DeclSpace instead of a TypeContainer. - - * expression.cs (ArrayCreation.EmitDynamicInitializers): If value - types are being initialized, load the address of it before calling - the function. - - (New): Provide a mechanism to disable the generation of local - value type temporaries when the caller will be providing us with - an address to store it. - - (ArrayCreation.EmitDynamicInitializers): Use it. - -2002-03-17 Miguel de Icaza - - * expression.cs (Invocation.EmitArguments): Only probe for array - property if there is more than one argument. Sorry about that. - - * class.cs (Invocation.EmitArguments): Fix to emit arguments for - empty param arrays. - - * class.cs (Method.LabelParameters): Fix incorrect code path that - prevented the `ParamArrayAttribute' from being applied to the - params attribute. - -2002-03-16 Miguel de Icaza - - * support.cs (ReflectionParameters): Correctly compute whether the - last argument is a params array. Fixes the problem with - string.Split ('a') - - * typemanager.cs: Make the assemblies array always be non-null - (empty, but non-null) - - * tree.cs (RecordDecl): New function that abstracts the recording - of names. This reports error 101, and provides a pointer to the - previous declaration. Fixes a crash in the compiler. - - * cs-parser.jay (constructor_declaration): Update to new grammar, - and provide a constructor_body that can be empty. - -2002-03-15 Miguel de Icaza - - * driver.cs: Add support for --resources. - - * expression.cs: (FetchGetMethod, FetchAddressMethod, EmitAssign): - Make all types for the various array helper methods be integer. - - * ecore.cs (Expression.ConvertNumericExplicit): Pass the - CheckState to ConvCast. - - (ConvCast): Now it takes a `checked' state argument, to avoid - depending on the emit context for the conversion, and just using - the resolve time setting. - - * expression.cs (ArrayCreation.EmitArrayArguments): New function, - instead of Invocation.EmitArguments. We do not emit the original - arguments, instead we emit those which have been converted to - unsigned int expressions. - - * statement.cs (Block.EmitMeta): Drop tracking of indexes. - - * codegen.cs: ditto. - - * expression.cs (LocalVariableReference): Drop the use of the - Store function that depended on the variable index. - - * statement.cs (VariableInfo): Drop the `Idx' property from this - class, as this is not taking into account the indexes for - temporaries tat we generate during the execution, getting the - indexes wrong. - - * class.cs: First emit class initializers, then call the parent - constructor. - - * expression.cs (Binary): Fix opcode emision. - (UnaryMutator.EmitCode): Support checked code generation - - * ecore.cs (MemberLookup): TypeManager.FindMembers will return - matches for events for both the Static and Instance scans, - pointing to the same element. Fix that. - -2002-03-14 Miguel de Icaza - - * rootcontext.cs (ResolveTree): Always set the - interface_resolve_order, because nested interfaces will be calling - into us. - - * class.cs (GetInterfaceOrClass): Track the same resolution - process used by TypeManager.LookupType. This fixes the nested - type lookups in class declarations (separate path from - LookupType). - - (TypeContainer.DefineType): Also define nested interfaces. - (TypeContainer.RegisterOrder): New public function used to - register the order in which child interfaces need to be closed. - - Nested interfaces need to be closed after their parents have been - created. - - * interface.cs (InterfaceAttr): Put all the logic for computing - the interface attribute here. - - (DefineInterface): Register our interface order with the - RootContext or with the TypeContainer depending on the case. - -2002-03-12 Miguel de Icaza - - * cs-parser.jay: rework foreach statement to work with the new - changes to the policy on SimpleNames. - - * report.cs: support Stacktrace on warnings as well. - - * makefile: drop --unsafe and /unsafe from the compile. - -2002-03-13 Ravi Pratap - - * ecore.cs (StandardConversionExists): Modify to take an Expression - as the first parameter. Ensure we do null -> reference type conversion - checking. - - * Everywhere : update calls accordingly, making use of MyEmptyExpr to store - temporary Expression objects. - -Wed Mar 13 12:32:40 CET 2002 Paolo Molaro - - * interface.cs: workaround bug in method overloading resolution - (there is already a bugzilla bug for it). - -2002-03-12 Miguel de Icaza - - We could also solve this problem by having a separate path for - performing type lookups, instead of DoResolve, we could have a - ResolveType entry point, and only participating pieces of the - production (simplename, deref, array) would implement this. - - * codegen.cs (EmitContext): New field OnlyLookupTypes used to - signal SimpleName to only resolve type names and not attempt to - resolve anything else. - - * expression.cs (Cast): Set the flag. - - * ecore.cs (SimpleName): Use the OnlyLookupTypes flag - - * class.cs: Only report 108 if there is no `new' modifier. - - * cs-parser.jay: rework foreach statement to work with the new - changes to the policy on SimpleNames. - - * report.cs: support Stacktrace on warnings as well. - - * makefile: drop --unsafe and /unsafe from the compile. - -2002-03-11 Miguel de Icaza - - * ecore.cs (SimpleName.SimpleNameResolve): Perform local variable - lookups here, instead of doing that at parse time. This means - that our grammar will not introduce `LocalVariableReferences' as - expressions at this point. That solves the problem of code like - this: - - class X { - static void Main () - { int X = 1; - { X x = null }}} - - This is only half the fix. The full fix requires parameters to - also be handled in this way. - - * Everywhere: Use ec.DeclSpace on calls to LookupType, as this - makes the use more obvious of the DeclSpace. The - ec.TypeContainer.TypeBuilder is now only used to pull the - TypeBuilder for it. - - My theory is that I can get rid of the TypeBuilder completely from - the EmitContext, and have typecasts where it is used (from - DeclSpace to where it matters). - - The only pending problem is that the code that implements Aliases - is on TypeContainer, and probably should go in DeclSpace. - - * ecore.cs (SimpleName.SimpleNameResolve): Perform local variable - lookups here, instead of doing that at parse time. This means - that our grammar will not introduce `LocalVariableReferences' as - expressions at this point. That solves the problem of code like - this: - - class X { - static void Main () - { int X = 1; - { X x = null }}} - - This is only half the fix. The full fix requires parameters to - also be handled in this way. - - * class.cs (Property.DefineMethod): When implementing an interface - method, set newslot, when implementing an abstract method, do not - set the flag (before we tried never setting it, or always setting - it, which is the difference). - (Indexer.DefineMethod): same. - (Method.DefineMethod): same. - - * ecore.cs: Only set the status used flag if we get back a Field. - - * attribute.cs: Temporary hack, so Paolo can keep working. - -2002-03-08 Ravi Pratap - - * attribute.cs (Attribute.UnmanagedType): This is to keep track of - the unmanaged type in the case we have a MarshalAs attribute. - - (Resolve): Handle the case when we are parsing the special MarshalAs - attribute [we need to store the unmanaged type to use later] - - * typemanager.cs (marshal_as_attr_type): Built in type for the - MarshalAs Attribute. - - * attribute.cs (ApplyAttributes): Recognize the MarshalAs attribute - on parameters and accordingly set the marshalling info. - -2002-03-09 Miguel de Icaza - - * class.cs: Optimizing slightly by removing redundant code after - we switched to the `NoTypes' return value. - (Property.DefineMethod): use NoTypes here too. - - This fixes the bug I introduced in my last batch of changes. - -2002-03-05 Ravi Pratap - - * tree.cs (RecordEnum): Add. We now keep track of enums too. - - * class.cs (LookupInterfaceOrClass): Check against the list of recorded - Enums since those are types too. - - * cs-parser.jay (enum_declaration): Record enums as we parse them. - - * enum.cs (DefineEnum): Return if the TypeBuilder has already been defined - thanks to a call during the lookup process. - -2002-03-07 Miguel de Icaza - - * statement.cs (Foreach): Lots of work to accomodate a particular - kind of foreach statement that I had not kept in mind. It is - possible to have foreachs on classes that provide a GetEnumerator - method that return objects that implement the "pattern" for using - a foreach, there is no need to support GetEnumerator - specifically. - - This is needed to compile nant. - - * decl.cs: Only report 114 if the member is not `Finalize' and if - the warning level is at least 2. - - * class.cs: Moved the compare function from Method to - MethodSignature. - - (MethodSignature.InheritableMemberSignatureCompare): Add new - filter function that is used to extract inheritable methods from a - class. - - (Method.Define): Use the new `inheritable_method_signature_filter' - delegate - - * cs-tokenizer.cs (get_cmd_arg): Do not add white space to the - command. - -2002-03-06 Miguel de Icaza - - * ecore.cs (Expression.ConvertReferenceExplicit): Removed dead code. - - * cs-parser.jay: Add opt_semicolon to the interface declaration. - - * expression.cs: Pass location information to - ConvertImplicitStandard. - - * class.cs: Added debugging code to track return values from - interfaces. - -2002-03-05 Miguel de Icaza - - * expression.cs (Is.DoResolve): If either side of the `is' is an - interface, do not flag the warning. - - * ecore.cs (ImplicitReferenceConversion): We need a separate test - for interfaces - - * report.cs: Allow for --fatal to be used with --probe. - - * typemanager.cs (NoTypes): Move the definition for the empty Type - array here. - - * class.cs (TypeContainer.FindMembers): Also look for methods defined by - properties. - (TypeContainer.DefineProxy): New function used to proxy to parent - implementations when implementing interfaces. - (TypeContainer.ParentImplements): used to lookup if our parent - implements a public function that is required by an interface. - (TypeContainer.VerifyPendingMethods): Hook this up. - - * typemanager.cs (TypeManager, AddModule, AddAssembly): Make the - `modules' and `assemblies' arraylists into arrays. We only grow - these are the very early start up of the program, so this improves - the speedof LookupType (nicely measured). - - * expression.cs (MakeByteBlob): Replaced unsafe code with - BitConverter, as suggested by Paolo. - - * cfold.cs (ConstantFold.Binary): Special case: perform constant - folding of string concatenation, but if either side is a string, - and the other is not, then return null, and let the runtime use - the concatenation on the string plus the object (using - `Object.ToString'). - -2002-03-04 Miguel de Icaza - - Constant Folding has been implemented now. - - * expression.cs (Unary.Reduce): Do not throw an exception, catch - the error instead on types that are not supported in one's - complement. - - * constant.cs (Constant and all children): New set of functions to - perform implict and explicit conversions. - - * ecore.cs (EnumConstant): Implement the new functions to perform - conversion by proxying to the child expression. - - * codegen.cs: (ConstantCheckState): Constant evaluation has its - own separate setting that can not be turned off from the command - line using --unchecked or --checked and is only controlled using - the checked/unchecked statements and expressions. This setting is - used by the constant folder to flag errors. - - * expression.cs (CheckedExpr, UncheckedExpr): Set the - ConstantCheckState as well. - - During Resolve, they also have to flag the state, because the - constant folder runs completely in the Resolve phase. - - * statement.cs (Checked, Unchecked): Set the ConstantCheckState as - well. - -2002-03-01 Miguel de Icaza - - * cfold.cs: New file, this file contains the constant folder. - - * ecore.cs (IMemoryLocation.AddressOf): Now takes an extra - argument to track whether we are using the resulting address to - load or store a value and provide better error messages. - - (FieldExpr.Emit, FieldExpr.EmitAssign, FieldExpr.AddressOf): Use - new AddressOf arguments. - - * statement.cs (Foreach.EmitCollectionForeach): Update - - * expression.cs (Argument.Emit): Call AddressOf with proper - arguments to track usage. - - (New.DoEmit): Call AddressOf with new arguments. - - (Unary.Emit): Adjust AddressOf call. - -2002-03-01 Ravi Pratap - - * cs-parser.jay (member_access): Change the case for pre-defined types - to use a MemberAccess instead of a SimpleName. Thanks to Felix again for - this suggestion. - - * class.cs (Operator::Emit): If we are abstract or extern, we don't have - a method body. - - * attribute.cs (CheckAttribute, ApplyAttribute): Ensure that we treat operators - essentially like methods and apply attributes like MethodImplOptions to them too. - - * ecore.cs (SimpleName.SimpleNameResolve): Perform a check on ec.TypeContainer.TypeBuilder - not being null. - - * codegen.cs (EmitContext): The constructor now takes in an extra argument specifying the - DeclSpace as the distinction is important. We provide sane defaults as usually the TypeContainer - is the DeclSpace. - - * Update code everywhere accordingly. - - * ecore.cs : Change references to ec.TypeContainer to ec.DeclSpace where appropriate. - - * cs-parser.jay (enum_declaration): Set the current namespace of the enum. - -2002-02-28 Ravi Pratap - - * rootcontext.cs (LookupType): As we cycle through the chain of namespaces - try performing lookups against those instead of jumping straight into using - the 'using' clauses. - - (ImplicitParent): Add. Thanks to Felix Arrese-Igor for this idea. - - (LookupType): Perform lookups in implicit parents too. - - * class.cs (GetInterfaceOrClass): Modify to perform the exact same lookup - sequence as RootContext.LookupType. - - * rootcontext.cs (NamespaceLookup): Split out code from LookupType which tries - the various cases of namespace lookups into this method. - -2002-03-01 Miguel de Icaza - - * cs-parser.jay: Add support for [Attribute ()] (empty arguments - in positional arguments) - - * class.cs (Operator): Update the AllowedModifiers to contain - extern. - - * cs-parser.jay: Update operator declaration to allow for the - operator body to be empty. - - * cs-tokenizer.cs: Added '\u' unicode support in strings and hex - values. - -2002-02-27 Miguel de Icaza - - * class.cs (Method.Emit): Label parameters. - - * driver.cs: Return 1 or 0 as the program exit code. - -2002-02-26 Miguel de Icaza - - * expression.cs: Special case the `null' object when trying to - auto-compute the type, as anything can be explicitly converted to - that. - - * ecore.cs (Expression.ConvertExplicit): Bug fix, thanks for - spotting this Paolo. - - (Expression.ImplicitNumericConversion): Perform comparissions of - the type using the underlying type in the case of an enumeration - rather than using the enumeration type for the compare. - - Cope with the underlying == type case, which is not possible to - catch before. - - (Expression.ConvertNumericExplicit): Perform comparissions of - the type using the underlying type in the case of an enumeration - rather than using the enumeration type for the compare. - - * driver.cs: If the user does not supply an extension, assume .exe - - * cs-parser.jay (if_statement): Rewrote so that we can track the - location for the if statement. - - * expression.cs (Binary.ConstantFold): Only concat strings when - the operation is "+", not everything ;-) - - * statement.cs (Statement.EmitBoolExpression): Take a location - argument. - (If, While, Do): Track location. - - * expression.cs (Binary.ResolveOperator): In the object + string - case, I was missing a call to ConvertImplicit - -2002-02-25 Ravi Pratap - - * parameter.cs (Parameter.ExternalType): Take in extra DeclSpace and - Location arguments. Ensure we use RootContext.LookupType to do our work - and not try to do a direct Type.GetType and ModuleBuilder.GetType - - * interface.cs (PopulateMethod): Handle the type of the parameter being - null gracefully. - - * expression.cs (Invocation.BetterFunction): Handle the case when we - have a params method with no fixed arguments and a call is made with no - arguments. - -2002-02-25 Miguel de Icaza - - * cs-tokenizer.cs: Add support for the quote-escape-sequence in - the verbatim-string-literal - - * support.cs (InternalParameters.ParameterModifier): handle null - fixed parameters. - (InternalParameters.ParameterType): ditto. - - * parameter.cs (VerifyArgs): Also check if the fixed parameter is - duplicating the name of the variable parameter. - (GetParameterByName): Fix bug where we were not looking up array - paramters if they were the only present (thanks Paolo!). - (GetParameterInfo): We only have an empty set of types if both - fixed and array are set to null. - (GetParameterInfo-idx): Handle FixedParameter == null - - * cs-parser.jay: Handle the case where there is no catch - statements (missing null test). - -2002-02-22 Miguel de Icaza - - * driver.cs (MainDriver): Be conservative on our command line - handling. - - Catch DirectoryNotFoundException when calling GetFiles. - - (SplitPathAndPattern): Used to split the input specification into - a path and a pattern that we can feed to Directory.GetFiles. - -2002-02-21 Miguel de Icaza - - * statement.cs (Fixed): Implement the last case of the Fixed - statement (string handling). - - * expression.cs (StringPtr): New class used to return a char * to - a string; Used by the Fixed statement. - - * typemanager.cs: Add char_ptr_type. Add get_OffsetToStringData method. - - * expression.cs (Binary.ResolveOperator): Remove redundant - MemberLookup pn parent type. - Optimize union call, we do not need a union if the types are the same. - (Unary.ResolveOperator): REmove redundant MemberLookup on parent - type. - - Specialize the use of MemberLookup everywhere, instead of using - the default settings. - - (StackAlloc): Implement stackalloc keyword. - - * cs-parser.jay: Add rule to parse stackalloc. - - * driver.cs: Handle /h, /help, /? - - * expression.cs (MakeByteBlob): Removed the hacks we had in place - before we supported unsafe code. - - * makefile: add --unsafe to the self compilation of mcs. - -2002-02-20 Miguel de Icaza - - * expression.cs (PointerArithmetic): New class that is used to - perform pointer arithmetic. - (Binary.Resolve): Handle pointer arithmetic - Handle pointer comparission. - (ArrayPtr): Utility expression class that is used to take the - address of an array. - - (ElementAccess): Implement array access for pointers - - * statement.cs (Fixed): Implement fixed statement for arrays, we - are missing one more case before we are done. - - * expression.cs (Indirection): Implement EmitAssign and set the - ExprClass to Variable. This allows pointer dereferences to be - treated as variables, and to have values assigned to them. - - * ecore.cs (Expression.StoreFromPtr): New utility function to - store values dereferencing. - -2002-02-20 Ravi Pratap - - * expression.cs (Binary.ResolveOperator): Ensure that we are - not trying to operate on a void type - this fixes the reported - bug. - - * decl.cs (CheckMethodAgainstBase): Do not allow overriding if - the parent implementation is sealed. - - * ../errors/cs0239.cs : Add. - - * attribute.cs (ApplyAttributes): Handle Modulebuilders too. - - * typemanager.cs (unverifiable_code_type): Corresponds to - System.Security.UnverifiableCodeAttribute. We need to emit this for modules - which have unsafe code in them. - - * rootcontext.cs (EmitCode): Emit the above attribute when we are in an - unsafe context. - -2002-02-19 Miguel de Icaza - - * cs-tokenizer.cs: Add support for @"litreal strings" - - Make tokenizer accept pre-processor directives - on any column (remove the old C-like limitation). - - * rootcontext.cs (EmitCode): Emit any global attributes. - (AddGlobalAttributes): Used to keep track of assembly attributes. - - * attribute.cs (ApplyAttributes): Support AssemblyAttributes. - - * cs-parser.jay: Add support for global attributes. - -2002-02-17 Miguel de Icaza - - * expression.cs (Indirection): New helper class. Unary will - create Indirection classes to be able to implement the - IMemoryLocation interface on it. - -2002-02-16 Miguel de Icaza - - * cs-parser.jay (fixed_statement): reference the right statement. - - * statement.cs (Fixed.Emit): Finish implementing the fixed - statement for the &x case. - -2002-02-14 Miguel de Icaza - - * class.cs (Property.Define, Method.Define): Remove newslot when - `implementing'. - - * modifiers.cs: My use of NewSlot when `Abstract' was set was - wrong. NewSlot should only be used if the `new' keyword is present. - - * driver.cs (GetSystemDir): Use CodeBase instead of FullName for - locating our system dir. Sorry about this. - -2002-02-13 Miguel de Icaza - - * driver.cs (GetSystemDir): Compute correctly the location of our - system assemblies. I was using the compiler directory instead of - the library directory. - -2002-02-13 Ravi Pratap - - * expression.cs (BetterFunction): Put back in what Miguel commented out - since it is the correct fix. The problem is elsewhere ;-) - - (IsParamsMethodApplicable): Fix bug where we were not checking that the fixed - parameters of the parms method are themselves compatible or not ! - - (StandardConversionExists): Fix very dangerous bug where we were forgetting - to check that a class implements an interface before saying that an implicit - conversion was allowed. Use ImplementsInterface to do the checking. - -2002-02-13 Miguel de Icaza - - * class.cs (Method.Define): Track whether we are an explicit - implementation or not. And only call DefineMethodOverride if we - are an explicit implementation. - - (Property.DefineMethod): Ditto. - -2002-02-11 Ravi Pratap - - * expression.cs (BetterFunction): Catch hideous bug which was - preventing us from detecting ambiguous calls due to implicit casts i.e - cs0121. - -2002-01-29 Miguel de Icaza - - * support.cs (Pair): Remove un-needed method. I figured why I was - getting the error in cs-parser.jay, the variable in a foreach loop - is readonly, and the compiler does not really treat this as a variable. - - * cs-parser.jay (fixed_statement): Fix grammar. Use ASSIGN - instead of EQUALS in grammar. - - * typemanager.cs (VerifyUnmanaged): Report correct error (208) - - * expression.cs (Unary.DoResolve): Check whether the argument is - managed or not. - -2002-01-28 Miguel de Icaza - - * support.cs: Api for Pair to set a value. Despite the fact that - the variables are public the MS C# compiler refuses to compile - code that accesses the field if the variable is part of a foreach - statement. - - * statement.cs (Fixed): Begin implementation of the fixed - statement. - - (Block.AddVariable): Return the VariableInfo on success and null - on failure instead of true/false. - - * cs-parser.jay (foreach): Catch errors on variables already - defined (we were ignoring this value before) and properly unwind - the block hierarchy - - (fixed_statement): grammar for the fixed statement. - -2002-01-25 Miguel de Icaza - - * expression.cs (UnaryMutator.IsIncrementableNumber): Allow also - pointer types to be incretemented. - - (SizeOf): Implement. - - * cs-parser.jay (pointer_member_access): Implement - expr->IDENTIFIER production. - - * expression.cs (IndexerAccess.DoResolve, ArrayAccess.DoResolve, - MemberAccess.DoResolve, Invocation.DoResolve): Check for pointers - on safe contexts. - - (Unary): Implement indirection. - - * ecore.cs (Expression.UnsafeError): Reports error 214 (pointer - use in non-unsafe context). - - (SimpleName.DoResolve): Check for pointers in field access on safe - contexts. - - (Expression.LoadFromPtr): Factor the load-indirect code in this - function. This was duplicated in UnboxCast and ParameterReference - -2002-01-24 Miguel de Icaza - - * expression.cs (ComposedCast): report an error if a pointer cast - is used in a safe region. - - * ecore.cs (Expression.ConvertExplicit): Add rules for implicit - pointer type casts in unsafe context. - - * codegen.cs (EmitContext): Set up IsUnsafe. - - * cs-parser.jay (non_expression_type): Add productions for pointer - casts. - - * expression.cs (Invocation.EmitCall): Remove chunk of buggy - code. We should not use force into static mode if the method is - not virtual. Fixes bug in MIS - - * statement.cs (Do.Emit, While.Emit, For.Emit, - Statement.EmitBoolExpression): Add support to Do and While to - propagate infinite loop as `I do return' semantics. - - Improve the For case to also test for boolean constants. - - * attribute.cs (Attribute.ApplyAttributes): Add ParameterBuilder - to the list of attributes we can add. - - Remove `EmitContext' argument. - - * class.cs (Method.Define): Apply parameter attributes. - (Constructor.Define): Apply parameter attributes. - (MethodCore.LabelParameters): Move here the core of labeling - parameters. - - * support.cs (ReflectionParameters.ParameterModifier, - InternalParameters.ParameterModifier): Use IsByRef on the type and - only return the OUT bit for these parameters instead of in/out/ref - flags. - - This is because I miss-understood things. The ParameterInfo.IsIn - and IsOut represent whether the parameter has the [In] and [Out] - attributes set. - -2002-01-22 Miguel de Icaza - - * ecore.cs (FieldExpr.Emit): Release temporaries. - - * assign.cs (LocalTemporary.Release): new function. - - * codegen.cs (EmitContext.GetTemporaryStorage, - EmitContext.FreeTemporaryStorage): Rework the way we deal with - temporary storage. Now we can "put back" localbuilders when we - are done with them - -2002-01-21 Miguel de Icaza - - * ecore.cs (FieldExpr.Emit): Handle initonly fields specially: we - need to make a copy of the variable to generate verifiable code. - -2002-01-19 Miguel de Icaza - - * driver.cs: Compute dynamically the system directory. - - * ecore.cs (CopyNewMethods): reworked, exposed, made public. - Slower, but more generally useful. Used by the abstract - registering implementation. - - * expression.cs (ResolveMemberAccess): Reorder the way we evaluate - the rules for the special rule on Type/instances. First check if - we have the same name, and if so, try that special static path - rather than the instance path. - -2002-01-18 Miguel de Icaza - - * cs-parser.jay: Emit 642 (warning: possible empty statement) for - for, while and if. - - * class.cs (TypeBuilder.DefineType): Do not allow inheritance from - Enum, ValueType, Delegate or Array for non-corlib compiles. - - * cs-tokenizer.cs: Catch long identifiers (645) - - * typemanager.cs (IndexerPropetyName): Ravi never tested this - piece of code. - - * class.cs (TypeContainer.RegisterRequiredImplementations): Bug - fix, we were returning too early, so we were not registering - pending methods from abstract classes. - - Do not register pending methods if the class is abstract. - - * expression.cs (Conditional.DoResolve): Report circular implicit - conversions when we neecd to compute it for conditional - expressions. - - (Is.DoResolve): If the expression is always of the provided type, - flag warning 183. If the expression can not ever be of the - provided type flag warning 184. - - * class.cs: Catch 169 as well. - - * ecore.cs (FieldExpr): For now in AddressOf mark as assigned and - read. - -2002-01-18 Nick Drochak - - * makefile: remove path to beta2 csc.exe. path to csc.exe must be in PATH instead. - -2002-01-17 Miguel de Icaza - - * interface.cs: (PopulateMethod): Check for pointers being defined - only if the unsafe context is active. - (PopulateProperty): ditto. - (PopulateIndexer): ditto. - - * class.cs (Method, Method.Define): Allow `unsafe' modifier to be - specified. If pointers are present, make sure that they are - present in an unsafe context. - (Constructor, Constructor.Define): ditto. - (Field, Field.Define): ditto. - (Property, Property.Define): ditto. - (Event, Event.Define): ditto. - - * interface.cs (Interface.GetInterfaceTypeByName): Only lookup the - hashtable if there are classes or structs defined. - - * expression.cs (LocalVariableReference.DoResolve): Simplify this - code, as the constant resolution moved. - - * statement.cs (Block.EmitMeta): Resolve all constants as we emit - the metadata, so we can flag error 133. - - * decl.cs (MemberCore.UnsafeOK): New function to test that a - pointer is being declared in an unsafe context. - -2002-01-16 Miguel de Icaza - - * modifiers.cs (Modifiers.Check): Require a Location argument. - Report error 227 for Unsafe use. - - * typemanager.cs: Remove IsPointerType, we should be using Type.IsPointer - - * statement.cs (For.Emit): If the test is null, then report that - we do `return', as we wont reach anything afterwards. - - (Switch.SwitchGoverningType): Track the expression that matched - the conversion. - - * driver.cs: Allow negative numbers as an error code to flag. - - * cs-parser.jay: Handle 1551. - - * namespace.cs: Add 1537 checking (repeated using alias namespaces). - -2002-01-15 Miguel de Icaza - - * cs-parser.jay: Report 1518 (type declaration can only contain - class, struct, interface, enum or delegate) - - (switch_label): Report 1523 (keywords `case' or `default' must - preced code) - - (opt_switch_sections): Report 1522 (empty switch) - - * driver.cs: Report 1515 (response file specified multiple times) - Report 1516 (Source file specified multiple times). - - * expression.cs (Argument.Resolve): Signal 1510 - - (BaseAccess.Resolve, BaseIndexer.Resolve): Signal 1511 (base - access not allowed in static code) - -2002-01-11 Ravi Pratap - - * typemanager.cs (IsPointerType): Utility method which we are going - to need a lot. - - * ecore.cs (ImplicitReferenceConversion): A pointer type cannot be cast to - the object type, so we take care of that. - - * expression.cs (FullMethodDesc): Also include the return type in descriptions. - - * support.cs (ParameterDesc): Fix minor bug which was causing params tags to be - added to non-params parameters :-) - - * typemanager.cs (CSharpName): Include 'void' type too. - - (void_ptr_type): Include in the set of core types. - - * ecore.cs (ConvertImplicit): Make use of ConvertImplicitStandard instead of - duplicating code. - - (ConvertImplicitStandard): Handle standard implicit pointer conversions when we have - an unsafe context. - - * cs-parser.jay (local_variable_pointer_type): Add support for 'void *' as I had - completely forgotten about it. - -2002-01-10 Ravi Pratap - - * cs-parser.jay (pointer_type): Add. This begins our implementation - of parsing rules for unsafe code. - - (unsafe_statement): Implement. - - (embedded_statement): Modify to include the above. - - * statement.cs (Unsafe): Implement new class for unsafe blocks. - - * codegen.cs (EmitContext.InUnsafe): Add. This determines - if the current context is an unsafe one. - - * cs-parser.jay (local_variable_pointer_type): Since local variable types - are handled differently, we need separate rules for them. - - (local_variable_declaration): Update to use local_variable_pointer_type - to allow variable declarations of unmanaged pointer types. - - * expression.cs (Unary.ResolveOperator): Ensure that the '&' operator is used only - in unsafe contexts. - - * ../errors/cs0214.cs : Add. - -2002-01-16 Nick Drochak - - * makefile: remove 'response' file when cleaning. - -2002-01-15 Miguel de Icaza - - * cs-parser.jay: Report 1524. - -2002-01-14 Miguel de Icaza - - * typemanager.cs (RegisterMethod): drop checking if we have - registered this from here - -2002-01-12 Miguel de Icaza - - * class.cs (Method.EmitDestructor): Implement calling our base - destructor. - - * statement.cs (Try.Emit): Fix to reset the InFinally to the old - value of InFinally. - - * codegen.cs (EmitContext.EmitTopBlock): Destructors will call - this routine and will wrap the call in a try/catch block. Deal - with the case. - -2002-01-11 Miguel de Icaza - - * ecore.cs (Expression.MemberLookup): instead of taking a - parameter `same_type' that was used to tell whether we could - access private members we compute our containing type from the - EmitContext. - - (FieldExpr): Added partial support for volatile fields. This does - not work for volatile fields exposed from assemblies, as I can not - figure out how to extract the modreq from it. - - Updated all the source files to use this. - - * codegen.cs (EmitContext): Compute ContainerType ahead of time, - because it is referenced by MemberLookup very often. - -2002-01-09 Ravi Pratap - - * typemanager.cs (IndexerPropertyName): If we have a TypeBuilder, use - TypeBuilder.GetCustomAttributes to retrieve what we need. - - Get rid of redundant default_member_attr_type as this is the same as - default_member_type which already exists. - - * interface.cs, attribute.cs : Update accordingly. - -2002-01-08 Miguel de Icaza - - * typemanager.cs: Enable IndexerPropertyName again. It does not - work for TYpeBuilders though. Ravi, can you please fix this? - - * cs-tokenizer.cs: Accept _ as a name in pp-expressions. - - * expression.cs (Argument.Emit): Handle the case of ref objects - being passed to ref functions; - - (ParameterReference.EmitLoad): Loads the content of the pointer - without dereferencing. - -2002-01-07 Miguel de Icaza - - * cs-tokenizer.cs: Implemented the pre-processing expressions. - -2002-01-08 Ravi Pratap - - * class.cs (Indexer.DefineMethod): Incorporate the interface - type in the name of the method if we are doing explicit interface - implementation. - - * expression.cs (ConversionExists): Remove as it is completely obsolete. - - (BetterConversion): Fix extremely trivial bug where we were referring to - ConversionExists instead of StandardConversionExists ! Hooray, things are fine - again ! - - * ../errors/bug16.cs : Add although we have fixed it. - -2002-01-07 Miguel de Icaza - - * expression.cs (BaseIndexer): Begin implementation. - - * class.cs (TypeContainer.IsInterfaceMethod): Bug fix. - - * cs-parser.jay (indexer_declarator): Use qualified_identifier - production directly to remove a shift/reduce, and implement - explicit interface implementation. - - * cs-tokenizer.cs: Fix tokenizer, it was consuming one extra char - after a floating point suffix. - - * expression.cs (DoNumericPromotions): Improved the conversion for - uint/uint. If we have a constant, we avoid doing a typecast to a - larger type. - - * class.cs (Indexer): Implement explicit interface implementation - for indexers. - -Sat Jan 5 16:08:23 CET 2002 Paolo Molaro - - * class.cs: make the default instance constructor public and hidebysig. - -2001-01-03 Ravi Pratap - - * interface.cs (EmitDefaultMemberAttr): Make this helper method static - so we can call it from elsewhere. - - * class.cs (TypeContainer.Emit): Emit the attribute here too. The rule is that - we emit it internally if the class has a defined indexer; otherwise the user - emits it by decorating the class definition with the DefaultMemberAttribute. - - * attribute.cs (ApplyAttributes): Perform checks to see that the DefaultMember - attribute is not used on a type which defines an indexer. - - * cs-tokenizer.cs (get_cmd_arg): Ensure we trim whitespace and also include the tab - character when we skip whitespace. - - * ../errors/cs0646.cs : Add. - -2002-01-03 Miguel de Icaza - - * ecore.cs (SimpleName.ResolveSimpleName): Report error 120 - again. - - * makefile: Add practical target `mcs3.exe' which builds the third - generation compiler. - - * expression.cs (New): Fix structures constructor calling. - - * class.cs (Property, Method, Indexer): Emit Final flag on the - method if we are an interface implementation and we are not - abstract. - - * ecore.cs (PropertyExpr): New public field `IsBase', tells - whether this property is referencing a `base' method. - - * expression.cs (Invocation.EmitCall): take an extra argument: - is_base, this is used to determine whether the `call' or - `callvirt' opcode should be used. - - - * delegate.cs: update EmitCall. - - * class.cs (Method.Define): Set NewSlot for the cases where we are - not implementing an interface method. - - (Property.Define): ditto. - -2002-01-02 Miguel de Icaza - - * cs-tokenizer.cs: (Tokenizer.escape): Escape '\r' as '\r' not as - 'r'. Allows mcs to parse itself fully. - -2002-01-02 Ravi Pratap - - * expression.cs (ArrayCreation.num_automatic_initializers): Keep track - of the number of initializers that require the InitializeArray method. - - (CheckIndices): Store the Expression in all cases - not the plain value. Also - update the above field where necessary. - - (MakeByteBlob): Update accordingly. - - (DoEmit): Call EmitStaticInitializers only if the number of initializers is - greater than 2. - - (EmitDynamicInitializers): Update in accordance with the new optimization. - - (ArrayAccess.EmitStoreOpcode): Include char type along with short and ushort - the - same OpCode applies. - - * cs-parser.jay : Fix some glaring errors I introduced. - -2002-01-01 Ravi Pratap - - * parameters.cs (AddVariable, AddConstant): Pass in current_local_parameters - so that we can check for name clashes there too. - - * typemanager.cs (default_member_attr_type): The attribute that we need to emit - for interface indexers. - - * interfaces.cs (Define): Emit the default member attribute. - - * expression.cs (MakeByteBlob): Fix extremely trivial bug where the wrong - variable was being referred to while setting the value ;-) - -2002-01-01 Miguel de Icaza - - * expression.cs (MakeByteBlob): Optimize: we do not need to fill - byte-by-byte information when we know the data is zero. - - Make the block always a multiple of 4, because - DefineInitializedData has a bug. - - * assign.cs: Fix, we should assign from the temporary, not from - the source. - - * expression.cs (MakeByteBlob): Fix my incorrect code. - -2001-12-31 Miguel de Icaza - - * typemanager.cs (EnumToUnderlying): This function is used to get - the underlying type from an enumeration, because it does not - always work. - - * constant.cs: Use the I4_S form for values between -128 and 127. - - * statement.cs (Block.LookupLabel): Looks up a label. - (Block): Drop support for labeled blocks. - - (LabeledStatement): New kind of statement that represents a label - only. - - (Goto): Finally implement this bad boy. - - * cs-parser.jay: Update to reflect new mechanism to implement - labels. - -2001-12-30 Miguel de Icaza - - * codegen.cs (EmitContext.This): a codegen property that keeps the - a single instance of this instead of creating many different this - instances. - - * delegate.cs (Delegate.DoResolve): Update to use the property; - - * ecore.cs (SimpleName.SimpleNameResolve): Ditto - - * expression.cs (BaseAccess.DoResolve): Ditto. - -2001-12-29 Ravi Pratap - - * typemanager.cs (methodimpl_attr_type): Add to hold the type - corresponding to System.Runtime.CompilerServices.MethodImplAttribute. - - (InitCoreTypes): Update accordingly. - - * attribute.cs (Resolve): Remember if the attribute is a MethodImplAttribute - so we can quickly store the state. - - (ApplyAttributes): Set the correct implementation flags - for InternalCall methods. - -2001-12-29 Miguel de Icaza - - * expression.cs (EmitCall): if a method is not virtual, then do - not use callvirt on it. - - (ArrayAccess.EmitAssign): storing non-builtin value types (ie, - user defined stuff) requires the use of stobj, which takes an - address on the stack instead of an array and an index. So emit - the Ldelema operation for it. - - (EmitStoreOpcode): Use stobj for valuetypes. - - (UnaryMutator.EmitCode): Use the right 1 value depending on - whether we are dealing with int64/uint64, float or doubles. - - * class.cs (TypeContainer.AddConstructor): Fix the logic to define - constructors that I implemented last night. - - (Constructor.IsDefault): Fix to work properly for static - constructors. - - * cs-parser.jay (CheckDef): report method signature errors. - Update error number 103 to be 132. - - * decl.cs: New AdditionResult enumeration value: MethodExists. - Although we do this check for methods later on in the semantic - analysis, catching repeated default constructors is so easy that - we catch these here. - - * expression.cs (Binary.DoNumericPromotions): Fix the uint64 type - promotions code. - - (ParameterReference.EmitAssign, Emit): handle - bools as bytes. - - (ArrayAccess.EmitLoadOpcode): Handle bool type here. - (ArrayAccess.EmitStoreOpcode): ditto. - - * cs-tokenizer.cs (is_punct): Eliminated empty computation. - - * expression.cs (MakeByteBlob): Complete all the missing types - (uint, short, ushort, byte, sbyte) - - * class.cs: Only init instance field initializers on instance - constructors. - - Rename `constructors' to instance_constructors. - - (TypeContainer.AddConstructor): Only add constructors to the list - if it is not static. - - Make sure that we handle default_static_constructor independently - everywhere where we handle instance_constructors - -2001-12-28 Miguel de Icaza - - * class.cs: Do not lookup or create a base initializer for a - static constructor. - - (ConstructorInitializer.Resolve): use the proper type to lookup - for constructors. - - * cs-parser.jay: Report error 1585 (modifiers between type and name). - - * enum.cs, interface.cs: Remove CloseType, this is taken care by - in DeclSpace. - - * decl.cs: CloseType is now an virtual method, the default - implementation just closes this type. - -2001-12-28 Ravi Pratap - - * attribute.cs (DefinePInvokeMethod): Set the implementation flags - to PreserveSig by default. Also emit HideBySig on such methods. - - Basically, set the defaults to standard values. - - * expression.cs (Invocation.BetterFunction): We need to make sure that for each - argument, if candidate is better, it can't be worse than the best ! - - (Invocation): Re-write bits to differentiate between methods being - applicable in their expanded form and their normal form - for params - methods of course. - - Get rid of use_standard everywhere as only standard conversions are allowed - in overload resolution. - - More spec conformance. - -2001-12-27 Miguel de Icaza - - * driver.cs: Add --timestamp, to see where the compiler spends - most of its time. - - * ecore.cs (SimpleName.DoResolve): Do not create an implicit - `this' in static code. - - (SimpleName.DoResolve): Implement in terms of a helper function - that allows static-references to be passed upstream to - MemberAccess. - - (Expression.ResolveWithSimpleName): Resolve specially simple - names when called by MemberAccess to implement the special - semantics. - - (Expression.ImplicitReferenceConversion): Handle conversions from - Null to reference types before others, as Null's type is - System.Object. - - * expression.cs (Invocation.EmitCall): Handle the special case of - calling methods declared on a reference type from a ValueType - (Base classes System.Object and System.Enum) - - (MemberAccess.Resolve): Only perform lookups on Enumerations if - the left hand side is a TypeExpr, not on every enumeration. - - (Binary.Resolve): If types are reference types, then do a cast to - object on operators != and == of both arguments. - - * typemanager.cs (FindMembers): Extract instance and static - members if requested. - - * interface.cs (PopulateProperty): Use void_type instead of null - as the return type for the setter method. - - (PopulateIndexer): ditto. - -2001-12-27 Ravi Pratap - - * support.cs (ReflectionParameters): Fix minor bug where we - were examining the wrong parameter for the ParamArray attribute. - - Cope with requests for the type of the parameter at position - greater than the params parameter's. We now return the element - type of the params array as that makes more sense. - - * expression.cs (Invocation.IsParamsMethodApplicable): Update - accordingly as we no longer have to extract the element type - ourselves. - - (Invocation.OverloadResolve): Update. - -2001-12-27 Miguel de Icaza - - * statement.cs (Foreach.GetEnumeratorFilter): Do not compare - against IEnumerator, test whether the return value is a descendant - of the IEnumerator interface. - - * class.cs (Indexer.Define): Use an auxiliary method to implement - the other bits of the method definition. Begin support for - explicit interface implementation. - - (Property.DefineMethod): Use TypeManager.void_type instead of null - for an empty return value. - -2001-12-26 Miguel de Icaza - - * expression.cs (MemberAccess.ResolveMemberAccess): if we are - dealing with a FieldExpr which is composed of a FieldBuilder, in - the code path we did extract the constant, but we should have - obtained the underlying value to be able to cast it (otherwise we - end up in an infinite loop, this is what Ravi was running into). - - (ArrayCreation.UpdateIndices): Arrays might be empty. - - (MemberAccess.ResolveMemberAccess): Add support for section - 14.5.4.1 that deals with the special case of E.I when E is a type - and something else, that I can be a reference to a static member. - - (ArrayCreation.MakeByteBlob): It is not an error to not be able to - handle a particular array type to create byte blobs, it is just - something we dont generate byteblobs for. - - * cs-tokenizer.cs (get_cmd_arg): Ignore \r in commands and - arguments. - - * location.cs (Push): remove the key from the hashtable that we - are about to add. This happens for empty files. - - * driver.cs: Dispose files after we have parsed them. - - (tokenize): new function that only runs the tokenizer on its - input, for speed testing. - -2001-12-26 Ravi Pratap - - * class.cs (Event.Define): Define the private field only if there - are no accessors defined. - - * expression.cs (ResolveMemberAccess): If there is no associated - field with the event, that means we have an event defined with its - own accessors and we should flag error cs0070 since transforming - ourselves into a field is not valid in that case. - - * ecore.cs (SimpleName.DoResolve): Same as above. - - * attribute.cs (DefinePInvokeMethod): Set the default calling convention - and charset to sane values. - -2001-12-25 Ravi Pratap - - * assign.cs (DoResolve): Perform check on events only if they - are being accessed outside the declaring type. - - * cs-parser.jay (event_declarations): Update rules to correctly - set the type of the implicit parameter etc. - - (add_accessor, remove_accessor): Set current local parameters. - - * expression.cs (Binary): For delegate addition and subtraction, - cast the return value from the method into the appropriate delegate - type. - -2001-12-24 Ravi Pratap - - * typemanager.cs (RegisterDelegateData, GetDelegateData): Get rid - of these as the workaround is unnecessary. - - * delegate.cs (NewDelegate.DoResolve): Get rid of bits which registered - delegate data - none of that is needed at all. - - Re-write bits to extract the instance expression and the delegate method - correctly. - - * expression.cs (Binary.ResolveOperator): Handle the '-' binary operator - on delegates too. - - * attribute.cs (ApplyAttributes): New method to take care of common tasks - of attaching attributes instead of duplicating code everywhere. - - * everywhere : Update code to do attribute emission using the above method. - -2001-12-23 Miguel de Icaza - - * expression.cs (IsParamsMethodApplicable): if there are not - parameters, return immediately. - - * ecore.cs: The 0 literal can be implicity converted to an enum - type. - - (SimpleName.DoResolve): First lookup the type, then lookup the - members. - - (FieldExpr.Emit): If the InstanceExpression is a ValueType, we - want to get its address. If the InstanceExpression is not - addressable, store the result in a temporary variable, then get - the address of it. - - * codegen.cs: Only display 219 errors on warning level or above. - - * expression.cs (ArrayAccess): Make it implement the - IMemoryLocation interface. - - (Binary.DoResolve): handle the operator == (object a, object b) - and operator != (object a, object b) without incurring into a - BoxedCast (because 5 != o should never be performed). - - Handle binary enumerator operators. - - (EmitLoadOpcode): Use Ldelema if the object we are loading is a - value type, otherwise use Ldelem_ref. - - Use precomputed names; - - (AddressOf): Implement address of - - * cs-parser.jay (labeled_statement): Fix recursive block - addition by reworking the production. - - * expression.cs (New.DoEmit): New has a special case: - - If we are dealing with a ValueType, we have a few - situations to deal with: - - * The target of New is a ValueType variable, that is - easy, we just pass this as the variable reference - - * The target of New is being passed as an argument, - to a boxing operation or a function that takes a - ValueType. - - In this case, we need to create a temporary variable - that is the argument of New. - - -2001-12-23 Ravi Pratap - - * rootcontext.cs (LookupType): Check that current_type is not null before - going about looking at nested types. - - * ecore.cs (EventExpr.EmitAddOrRemove): Rename from EmitAssign as we do - not implement the IAssignMethod interface any more. - - * expression.cs (MemberAccess.ResolveMemberAccess): Handle EventExprs specially - where we tranform them into FieldExprs if they are being resolved from within - the declaring type. - - * ecore.cs (SimpleName.DoResolve): Do the same here. - - * assign.cs (DoResolve, Emit): Clean up code considerably. - - * ../errors/bug10.cs : Add. - - * ../errors/cs0070.cs : Add. - - * typemanager.cs : Use PtrHashtable for Delegate data hashtable etc. - - * assign.cs : Get rid of EventIsLocal everywhere. - -2001-12-23 Miguel de Icaza - - * ecore.cs (ConvertIntLiteral): finished the implementation. - - * statement.cs (SwitchLabel): Convert the value we are using as a - key before looking up the table. - -2001-12-22 Miguel de Icaza - - * codegen.cs (EmitTopBlock): Require a Location argument now. - - * cs-parser.jay (constructor_declarator): We need to setup - current_local_parameters before we parse the - opt_constructor_initializer, to allow the variables to be bound - to the constructor arguments. - - * rootcontext.cs (LookupType): First lookup nested classes in our - class and our parents before we go looking outside our class. - - * expression.cs (ConstantFold): Extract/debox the values at the - beginnning. - - * rootcontext.cs (EmitCode): Resolve the constants first before we - resolve the types. This is not really needed, but it helps debugging. - - * statement.cs: report location. - - * cs-parser.jay: pass location to throw statement. - - * driver.cs: Small bug fix. - - * report.cs: Updated format to be 4-zero filled digits. - -2001-12-22 Ravi Pratap - - * expression.cs (CheckIndices): Fix minor bug where the wrong - variable was being referred to ;-) - - (DoEmit): Do not call EmitStaticInitializers when the - underlying type is System.Object. - -2001-12-21 Ravi Pratap - - * ecore.cs (EventExpr.Resolve): Implement to correctly set the type - and do the usual workaround for SRE. - - * class.cs (MyEventBuilder.EventType): New member to get at the type - of the event, quickly. - - * expression.cs (Binary.ResolveOperator): Handle delegate addition. - - * assign.cs (Assign.DoResolve): Handle the case when the target - is an EventExpr and perform the necessary checks. - - * ecore.cs (EventExpr.EmitAssign): Implement the IAssignMethod - interface. - - (SimpleName.MemberStaticCheck): Include check for EventExpr. - - (EventExpr): Set the type in the constructor itself since we - are meant to be born fully resolved. - - (EventExpr.Define): Revert code I wrote earlier. - - * delegate.cs (NewDelegate.Resolve): Handle the case when the MethodGroup's - instance expression is null. The instance expression is a This in that case - or a null, depending on whether it is a static method or not. - - Also flag an error if the reference to a method is ambiguous i.e the MethodGroupExpr - refers to more than one method. - - * assign.cs (DoResolve): Check whether the event belongs to the same Type container - and accordingly flag errors. - -2001-12-21 Miguel de Icaza - - * statement.cs (Throw.Emit): Add support for re-throwing exceptions. - -2001-12-22 Miguel de Icaza - - * location.cs (ToString): Provide useful rutine. - -2001-12-21 Miguel de Icaza - - * ecore.cs (Expression.ConvertIntLiteral): Do not return Constant - objects, return the actual integral boxed. - - * statement.cs (SwitchLabel): define an ILLabel for each - SwitchLabel. - - (Switch.CheckSwitch): If the value is a Literal, extract - the underlying literal. - - Also in the unused hashtable we had, add the SwitchLabel so we can - quickly look this value up. - - * constant.cs: Implement a bunch of new constants. Rewrite - Literal based on this. Made changes everywhere to adapt to this. - - * expression.cs (Expression.MakeByteBlob): Optimize routine by - dereferencing array only once, and also copes with enumrations. - - bytes are two bytes wide, not one. - - (Cast): Perform constant conversions. - - * ecore.cs (TryImplicitIntConversion): Return literals instead of - wrappers to the literals here. - - * expression.cs (DoNumericPromotions): long literals can converted - to ulong implicity (this is taken care of elsewhere, but I was - missing this spot). - - * ecore.cs (Expression.Literalize): Make the return type Literal, - to improve type checking. - - * rootcontext.cs: Lookup for nested classes in our class hierarchy. - -2001-12-20 Miguel de Icaza - - * literal.cs: Revert code from ravi that checked the bounds. The - bounds are sane by the definition of the type itself. - - * typemanager.cs: Fix implementation of ImplementsInterface. We - need to actually look up in our parent hierarchy for interfaces - implemented. - - * const.cs: Use the underlying type for enumerations - - * delegate.cs: Compute the basename for the delegate creation, - that should fix the delegate test case, and restore the correct - Type Lookup semantics in rootcontext - - * rootcontext.cs: Revert Ravi's last patch. The correct way of - referencing a nested type with the Reflection API is using the "+" - sign. - - * cs-parser.jay: Do not require EOF token at the end. - -2001-12-20 Ravi Pratap - - * rootcontext.cs (LookupType): Concatenate type names with - a '.' instead of a '+' The test suite passes again. - - * enum.cs (Enum.DefineEnum): Set RTSpecialName on the 'value__' - field of the enumeration. - - * expression.cs (MemberAccess.ResolveMemberAccess): Add support for - the case when the member is an EventExpr. - - * ecore.cs (EventExpr.InstanceExpression): Every event which is not - static has an associated instance expression. - - * typemanager.cs (RegisterEvent): The usual workaround, now for events. - - (GetAddMethod, GetRemoveMethod): Workarounds, as usual. - - * class.cs (Event.Define): Register event and perform appropriate checks - for error #111. - - We define the Add and Remove methods even if the use provides none because - in that case, we provide default implementations ourselves. - - Define a private field of the type of the event. This is done by the CSC compiler - and we should be doing it too ;-) - - * typemanager.cs (delegate_combine_delegate_delegate, delegate_remove_delegate_delegate): - More methods we use in code we generate. - - (multicast_delegate_type, delegate_type): Two separate types since the distinction - is important. - - (InitCoreTypes): Update accordingly for the above. - - * class.cs (Event.Emit): Generate code for default accessors that we provide - - (EmitDefaultMethod): Do the job in the above. - - * delegate.cs (DefineDelegate): Use TypeManager.multicast_delegate_type in the - appropriate place. - -2001-12-20 Miguel de Icaza - - * class.cs (Indexer.Define): Fix bug, we were setting both Get/Set - builders even if we were missing one. - - * interface.cs, class.cs, enum.cs: When calling DefineNestedType - pass the Basename as our class name instead of the Name. The - basename will be correctly composed for us. - - * parameter.cs (Paramters): Now takes a Location argument. - - * decl.cs (DeclSpace.LookupType): Removed convenience function and - make all the code call directly LookupType in RootContext and take - this chance to pass the Location information everywhere. - - * Everywhere: pass Location information. - -2001-12-19 Miguel de Icaza - - * class.cs (Constructor.Define): Updated way of detecting the - length of the parameters. - - (TypeContainer.DefineType): Use basename as the type name for - nested types. - - (TypeContainer.Define): Do not recursively define types here, as - definition is taken care in order by the RootContext. - - * tree.cs: Keep track of namespaces in a per-file basis. - - * parameter.cs (Parameter.ComputeSignature): Update to use - DeclSpace. - - (Parameters.GetSignature): ditto. - - * interface.cs (InterfaceMethod.GetSignature): Take a DeclSpace - instead of a TypeContainer. - - (Interface.SemanticAnalysis): Use `this' instead of our parent to - resolve names. Because we need to be resolve in our context, not - our parents. - - * driver.cs: Implement response files. - - * class.cs (TypeContainer.DefineType): If we are defined, do not - redefine ourselves. - - (Event.Emit): Emit the code for add/remove handlers. - (Event.Define): Save the MethodBuilders for add/remove. - - * typemanager.cs: Use pair here too. - - * cs-parser.jay: Replaced use of DictionaryEntry for Pair because - DictionaryEntry requires the first argument to be non-null. - - (enum_declaration): Compute full name for registering the - enumeration. - - (delegate_declaration): Instead of using - formal_parameter_list, use opt_formal_parameter_list as the list - can be empty. - - * cs-tokenizer.cs (PropertyParsing): renamed from `properties' - (EventParsing): New property that controls whether `add' and - `remove' are returned as tokens or identifiers (for events); - -2001-12-19 Ravi Pratap - - * class.cs (Event.Define): Revamp use of EventBuilder completely. We now - use MyEventBuilder only and let it wrap the real builder for us. - - (MyEventBuilder): Revamp constructor etc. - - Implement all operations that we perform on EventBuilder in precisely the same - way here too. - - (FindMembers): Update to use the EventBuilder member. - - (Event.Emit): Update accordingly. - -2001-12-18 Ravi Pratap - - * class.cs (MyEventBuilder.Set*): Chain to the underlying builder - by calling the appropriate methods. - - (GetCustomAttributes): Make stubs as they cannot possibly do anything - useful. - - (Event.Emit): Use MyEventBuilder everywhere - even to set attributes. - -2001-12-17 Ravi Pratap - - * delegate.cs (Delegate.Populate): Check that the return type - and various parameters types are indeed accessible. - - * class.cs (Constructor.Define): Same here. - - (Field.Define): Ditto. - - (Event.Define): Ditto. - - (Operator.Define): Check that the underlying Method defined itself - correctly - so it's MethodBuilder should not be null. - - * delegate.cs (DelegateInvocation.DoResolve): Bale out if the type of the Instance - expression happens to be null. - - * class.cs (MyEventBuilder): Workaround for SRE lameness. Implement various abstract - members but as of now we don't seem to be able to do anything really useful with it. - - (FindMembers): Handle events separately by returning the MyEventBuilder of the event, - not the EventBuilder. - -2001-12-18 Miguel de Icaza - - * cs-tokenizer.cs: Add support for defines. - Add support for #if, #elif, #else, #endif - - (eval_var): evaluates a variable. - (eval): stubbed for evaluating functions. - - * cs-parser.jay: Pass the defines information - - * driver.cs: Add --define command line option. - - * decl.cs: Move MemberCore here. - - Make it the base class for DeclSpace. This allows us to catch and - report 108 and 109 for everything now. - - * class.cs (TypeContainer.Define): Extract all the members - before populating and emit the warning 108 (new keyword required - to override) instead of having each member implement this. - - (MemberCore.Define): New abstract method, we will be using this in - the warning reporting engine in Populate. - - (Operator.Define): Adjust to new MemberCore protocol. - - * const.cs (Const): This does not derive from Expression, it is a - temporary object we use to create fields, it is a MemberCore. - - * class.cs (Method.Define): Allow the entry point to be in a - specific class. - - * driver.cs: Rewrite the argument handler to clean it up a bit. - - * rootcontext.cs: Made it just an auxiliary namespace feature by - making everything static. - - * driver.cs: Adapt code to use RootContext type name instead of - instance variable. - - * delegate.cs: Remove RootContext argument. - - * class.cs: (Struct, TypeContainer, Class): Remove RootContext - argument. - - * class.cs (Event.Define): The lookup can fail. - - * cs-tokenizer.cs: Begin implementation of pre-procesor. - - * expression.cs: Resolve the this instance before invoking the code. - -2001-12-17 Miguel de Icaza - - * cs-parser.jay: Add a production in element_access that allows - the thing to become a "type" reference. This way we can parse - things like "(string [])" as a type. - - Note that this still does not handle the more complex rules of - casts. - - - * delegate.cs (Delegate.Populate): Register the delegage constructor builder here. - - * ecore.cs: (CopyNewMethods): new utility function used to - assemble the list of methods from running FindMembers. - - (MemberLookup): Rework FindMembers so that - -2001-12-16 Miguel de Icaza - - * class.cs (TypeContainer): Remove Delegates who fail to be - defined. - - * delegate.cs (Populate): Verify that we dont get null return - values. TODO: Check for AsAccessible. - - * cs-parser.jay: Use basename to emit error 574 (destructor should - have the same name as container class), not the full name. - - * cs-tokenizer.cs (adjust_int): Fit the integer in the best - possible representation. - - Also implements integer type suffixes U and L. - -2001-12-15 Miguel de Icaza - - * expression.cs (ArrayCreation.DoResolve): We need to do the - argument resolution *always*. - - * decl.cs: Make this hold the namespace. Hold the root context as - well. - (LookupType): Move here. - - * enum.cs, class.cs, interface.cs: Adapt to new hierarchy. - - * location.cs (Row, Name): Fixed the code, it was always returning - references to the first file. - - * interface.cs: Register properties defined through interfaces. - - * driver.cs: Add support for globbing on the command line - - * class.cs (Field): Make it derive from MemberCore as well. - (Event): ditto. - -2001-12-15 Ravi Pratap - - * class.cs (Event::Define): Check that the type of the event is a delegate - type else flag error #66. - - Also, re-use TypeContainer.MethodModifiersValid here too as the rules are the - same. - - * attribute.cs (DefinePInvokeMethod): Handle named arguments and process - values of EntryPoint, CharSet etc etc. - - Pass in the values to TypeBuilder.DefinePInvokeMethod; determine Type etc neatly. - - * class.cs (FindMembers): If a method is in transit, its MethodBuilder will - be null and we should ignore this. I am not sure if this is really clean. Apparently, - there's no way of avoiding hitting this because the call is coming from SimpleName.DoResolve, - which needs this to do its work. - - * ../errors/cs0066.cs : Add. - -2001-12-14 Miguel de Icaza - - * typemanager.cs: (GetPropertyGetter, GetPropertyGetter): New - helper functions. - - * class.cs: (MethodSignature.MethodSignature): Removed hack that - clears out the parameters field. - (MemberSignatureCompare): Cleanup - - (MemberCore): New base class used to share code between MethodCore - and Property. - - (RegisterRequiredImplementations) BindingFlags.Public requires - either BindingFlags.Instace or Static. Use instance here. - - (Property): Refactored code to cope better with the full spec. - - * parameter.cs (GetParameterInfo): Return an empty array instead - of null on error. - - * class.cs (Property): Abstract or extern properties have no bodies. - - * parameter.cs (GetParameterInfo): return a zero-sized array. - - * class.cs (TypeContainer.MethodModifiersValid): Move all the - method modifier validation to the typecontainer so we can reuse - this on properties. - - (MethodCore.ParameterTypes): return an empty sized array of types. - - (Property.Define): Test property modifier validity. - - Add tests for sealed/override too. - - (Method.Emit): abstract or extern methods have no bodies. - -2001-12-14 Ravi Pratap - - * class.cs (Method.IsPInvoke): Get rid of it as it is an expensive - thing. - - (Method::Define, ::Emit): Modify accordingly. - - * expression.cs (Invocation::OverloadResolve): Handle error # 121. - - (ArrayCreation::MakeByteBlob): Handle floats and doubles. - - * makefile: Pass in /unsafe. - -2001-12-13 Miguel de Icaza - - * class.cs (MakeKey): Kill routine. - - * class.cs (TypeContainer.Define): Correctly define explicit - method implementations (they require the full interface name plus - the method name). - - * typemanager.cs: Deply the PtrHashtable here and stop using the - lame keys. Things work so much better. - - This of course broke everyone who depended on `RegisterMethod' to - do the `test for existance' test. This has to be done elsewhere. - - * support.cs (PtrHashtable): A hashtable that avoid comparing with - the object stupid Equals method (because, that like fails all over - the place). We still do not use it. - - * class.cs (TypeContainer.SetRequiredInterface, - TypeContainer.RequireMethods): Killed these two routines and moved - all the functionality to RegisterRequiredImplementations. - - (TypeContainer.RegisterRequiredImplementations): This routine now - registers all the implementations required in an array for the - interfaces and abstract methods. We use an array of structures - which can be computed ahead of time to reduce memory usage and we - also assume that lookups are cheap as most classes will not - implement too many interfaces. - - We also avoid creating too many MethodSignatures. - - (TypeContainer.IsInterfaceMethod): Update and optionally does not - clear the "pending" bit if we find that there are problems with - the declaration. - - (TypeContainer.VerifyPendingMethods): Update to report errors of - methods that look like implementations but are not. - - (TypeContainer.Define): Add support for explicit interface method - implementation. - -2001-12-12 Miguel de Icaza - - * typemanager.cs: Keep track of the parameters here instead of - being a feature of the TypeContainer. - - * class.cs: Drop the registration of parameters here, as - InterfaceMethods are also interface declarations. - - * delegate.cs: Register methods with the TypeManager not only with - the TypeContainer. This code was buggy. - - * interface.cs: Full registation here. - -2001-12-11 Miguel de Icaza - - * expression.cs: Remove reducer for binary expressions, it can not - be done this way. - - * const.cs: Put here the code that used to go into constant.cs - - * constant.cs: Put here the code for constants, this is a new base - class for Literals. - - * literal.cs: Make Literal derive from Constant. - -2001-12-09 Miguel de Icaza - - * statement.cs (Return.Emit): Report error 157 if the user - attempts to return from a finally block. - - (Return.Emit): Instead of emitting a return, jump to the end of - the function. - - * codegen.cs (EmitContext): ReturnValue, ReturnLabel: new - LocalBuilder to store the result of the function. ReturnLabel is - the target where we jump. - - -2001-12-09 Radek Doulik - - * cs-parser.jay: remember alias in current namespace - - * ecore.cs (SimpleName::DoResolve): use aliases for types or - namespaces - - * class.cs (LookupAlias): lookup alias in my_namespace - - * namespace.cs (UsingAlias): add alias, namespace_or_type pair to - aliases hashtable - (LookupAlias): lookup alias in this and if needed in parent - namespaces - -2001-12-08 Miguel de Icaza - - * support.cs: - - * rootcontext.cs: (ModuleBuilder) Made static, first step into - making things static. I need this to avoid passing the - TypeContainer when calling ParameterType. - - * support.cs (InternalParameters.ParameterType): Remove ugly hack - that did string manipulation to compute the type and then call - GetType. Use Parameter.ParameterType instead. - - * cs-tokenizer.cs: Consume the suffix for floating values. - - * expression.cs (ParameterReference): figure out whether this is a - reference parameter or not. Kill an extra variable by computing - the arg_idx during emission. - - * parameter.cs (Parameters.GetParameterInfo): New overloaded - function that returns whether a parameter is an out/ref value or not. - - (Parameter.ParameterType): The type of the parameter (base, - without ref/out applied). - - (Parameter.Resolve): Perform resolution here. - (Parameter.ExternalType): The full type (with ref/out applied). - - * statement.cs (Using.Emit, Using.EmitExpression): Implement - support for expressions on the using statement. - -2001-12-07 Miguel de Icaza - - * statement.cs (Using.EmitLocalVariableDecls): Split the - localvariable handling of the using statement. - - (Block.EmitMeta): Keep track of variable count across blocks. We - were reusing slots on separate branches of blocks. - - (Try.Emit): Emit the general code block, we were not emitting it. - - Check the type of the declaration to be an IDisposable or - something that can be implicity converted to it. - - Emit conversions if required. - - * ecore.cs (EmptyExpression): New utility class. - (Expression.ImplicitConversionExists): New utility function. - -2001-12-06 Miguel de Icaza - - * statement.cs (Using): Implement. - - * expression.cs (LocalVariableReference): Support read only variables. - - * statement.cs: Remove the explicit emit for the Leave opcode. - (VariableInfo): Add a readonly field. - -2001-12-05 Miguel de Icaza - - * ecore.cs (ConvCast): new class used to encapsulate the various - explicit integer conversions that works in both checked and - unchecked contexts. - - (Expression.ConvertNumericExplicit): Use new ConvCast class to - properly generate the overflow opcodes. - -2001-12-04 Miguel de Icaza - - * statement.cs: The correct type for the EmptyExpression is the - element_type, not the variable type. Ravi pointed this out. - -2001-12-04 Ravi Pratap - - * class.cs (Method::Define): Handle PInvoke methods specially - by using DefinePInvokeMethod instead of the usual one. - - * attribute.cs (DefinePInvokeMethod): Implement as this is what is called - above to do the task of extracting information and defining the method. - -2001-12-04 Ravi Pratap - - * expression.cs (ArrayCreation::EmitStaticInitializers): Get rid - of the condition for string type. - - (Emit): Move that here. - - (ArrayCreation::CheckIndices): Keep string literals in their expression - form. - - (EmitDynamicInitializers): Handle strings appropriately. - -2001-12-04 Miguel de Icaza - - * codegen.cs (EmitContext): Replace multiple variables with a - single pointer to the current Switch statement. - - * statement.cs (GotoDefault, Switch): Adjust to cleaned up - EmitContext. - -2001-12-03 Miguel de Icaza - - * statement.cs - - * statement.cs (GotoDefault), cs-parser.jay: Implement `goto - default'. - - (Foreach.Emit): Foreach on arrays was not setting - up the loop variables (for break/continue). - - (GotoCase): Semi-implented. - -2001-12-03 Ravi Pratap - - * attribute.cs (CheckAttribute): Handle system attributes by using - Attribute.GetAttributes to examine information we need. - - (GetValidPlaces): Same here. - - * class.cs (Method::Define): Catch invalid use of extern and abstract together. - - * typemanager.cs (dllimport_type): Core type for System.DllImportAttribute. - - * class.cs (Method.IsPinvoke): Used to determine if we are a PInvoke method. - - (Method::Define): Set appropriate flags if we have a DllImport attribute. - - (Method::Emit): Handle the case when we are a PInvoke method. - -2001-12-03 Miguel de Icaza - - * expression.cs: Use ResolveWithSimpleName on compound names. - -2001-12-02 Ravi Pratap - - * constant.cs (EmitConstant): Make sure we resolve the associated expression - before trying to reduce it. - - * typemanager.cs (RegisterConstant, LookupConstant): Implement. - - * constant.cs (LookupConstantValue): Implement. - - (EmitConstant): Use the above in emitting the constant. - - * expression.cs (MemberAccess::ResolveMemberAccess): Handle constants - that are user-defined by doing a LookupConstantValue on them. - - (SimpleName::DoResolve): When we have a FieldExpr, cope with constants - too, like above. - -2001-11-29 Miguel de Icaza - - * expression.cs (BaseAccess, BaseIndexer): Also split this out. - - (BaseAccess.DoResolve): Implement. - - (MemberAccess.DoResolve): Split this routine into a - ResolveMemberAccess routine that can be used independently - -2001-11-28 Miguel de Icaza - - * expression.cs (Probe, Is, As): Split Probe in two classes Is and - As that share bits of the implementation. Is returns a boolean, - while As returns the Type that is being probed. - -2001-12-01 Ravi Pratap - - * enum.cs (LookupEnumValue): Re-write various bits, return an object value - instead of a Literal - much easier. - - (EnumInTransit): Remove - utterly useless :-) - - (Populate): Re-write bits - remove duplicate code etc. The code is much neater now. - - * expression.cs (MemberLookup): Cope with user-defined enums when they are in transit. - - * enum.cs (LookupEnumValue): Auto-compute next values by going down the dependency - chain when we have no associated expression. - -2001-11-30 Ravi Pratap - - * constant.cs (Define): Use Location while reporting the errror. - - Also emit a warning when 'new' is used and there is no inherited - member to hide. - - * enum.cs (EnumInTransit): Used to tell if an enum type is in the process of being - populated. - - (LookupEnumValue): Implement to lookup an enum member's value and define it - if necessary. - - (Populate): Re-write accordingly to use the above routine. - -2001-11-27 Miguel de Icaza - - * expression.cs (This): Fix prototype for DoResolveLValue to - override the base class DoResolveLValue. - - * cs-parser.cs: Report errors cs574 and cs575 (destructor - declarations) - - * ecore.cs (FieldExpr.EmitAssign): Handle value types specially - (we need to load the address of the field here). This fixes - test-22. - - (FieldExpr.DoResolveLValue): Call the DoResolve - function to initialize the Instance expression. - - * statement.cs (Foreach.Emit): Fix the bug where we did not invoke - correctly the GetEnumerator operation on a value type. - - * cs-parser.jay: Add more simple parsing error catches. - - * statement.cs (Switch): Add support for string switches. - Handle null specially. - - * literal.cs (NullLiteral): Make NullLiteral objects singletons. - -2001-11-28 Ravi Pratap - - * cs-parser.jay (local_constant_declaration): Use declare_local_constant. - - (declare_local_constant): New helper function. - - * statement.cs (AddConstant): Keep a separate record of constants - - (IsConstant): Implement to determine if a variable is a constant. - - (GetConstantExpression): Implement. - - * expression.cs (LocalVariableReference): Handle the case when it is a constant. - - * statement.cs (IsVariableDefined): Re-write. - -2001-11-27 Ravi Pratap - - * class.cs (TypeContainer::FindMembers): Look for constants - in the case when we are looking for MemberTypes.Field - - * expression.cs (MemberAccess::DoResolve): Check that in the - case we are a FieldExpr and a Literal, we are not being accessed - by an instance reference. - - * cs-parser.jay (local_constant_declaration): Implement. - - (declaration_statement): Implement for constant declarations. - -2001-11-26 Miguel de Icaza - - * statement.cs (Switch): Catch double defaults. - - (Switch): More work on the switch() statement - implementation. It works for integral values now, need to finish - string support. - - -2001-11-24 Miguel de Icaza - - * ecore.cs (Expression.ConvertIntLiteral): New function to convert - integer literals into other integer literals. To be used by - switch. - -2001-11-24 Ravi Pratap - - * expression.cs (ArrayCreation): Get rid of ArrayExprs : we save - some memory. - - (EmitDynamicInitializers): Cope with the above since we extract data - directly from ArrayData now. - - (ExpectInitializers): Keep track of whether initializers are mandatory - or not. - - (Bounds): Make it a hashtable to prevent the same dimension being - recorded for every element in that dimension. - - (EmitDynamicInitializers): Fix bug which prevented the Set array method - from being found. - - Also fix bug which was causing the indices to be emitted in the reverse - order. - -2001-11-24 Miguel de Icaza - - * expression.cs (ArrayCreation): Implement the bits that Ravi left - unfinished. They do not work, because the underlying code is - sloppy. - -2001-11-22 Miguel de Icaza - - * cs-parser.jay: Remove bogus fixme. - - * statement.cs (Switch, SwitchSection, SwithLabel): Started work - on Switch statement. - -2001-11-23 Ravi Pratap - - * typemanager.cs (IsDelegateType, IsEnumType): Fix logic to determine - the same. - - * expression.cs (ArrayCreation::CheckIndices): Get rid of the require_constant - parameter. Apparently, any expression is allowed. - - (ValidateInitializers): Update accordingly. - - (CheckIndices): Fix some tricky bugs thanks to recursion. - - * delegate.cs (NewDelegate::DoResolve): Re-write large portions as - I was being completely brain-dead. - - (VerifyMethod, VerifyApplicability, VerifyDelegate): Make static - and re-write acordingly. - - (DelegateInvocation): Re-write accordingly. - - * expression.cs (ArrayCreation::Emit): Handle string initialization separately. - - (MakeByteBlob): Handle types more correctly. - - * expression.cs (ArrayCreation:Emit): Write preliminary code to do - initialization from expressions but it is incomplete because I am a complete - Dodo :-| - -2001-11-22 Miguel de Icaza - - * statement.cs (If.Emit): Fix a bug that generated incorrect code - on If. Basically, we have to return `true' (ie, we do return to - our caller) only if both branches of the if return. - - * expression.cs (Binary.Emit): LogicalOr and LogicalAnd are - short-circuit operators, handle them as short circuit operators. - - (Cast.DoResolve): Resolve type. - (Cast.Cast): Take an expression as the target type. - - * cs-parser.jay (cast_expression): Remove old hack that only - allowed a limited set of types to be handled. Now we take a - unary_expression and we resolve to a type during semantic - analysis. - - Use the grammar productions from Rhys to handle casts (this is - not complete like Rhys syntax yet, we fail to handle that corner - case that C# has regarding (-x), but we will get there. - -2001-11-22 Ravi Pratap - - * class.cs (EmitFieldInitializer): Take care of the case when we have a - field which is an array type. - - * cs-parser.jay (declare_local_variables): Support array initialization too. - - * typemanager.cs (MakeKey): Implement. - - (everywhere): Use the above appropriately. - - * cs-parser.jay (for_statement): Update for array initialization while - declaring variables. - - * ecore.cs : The error message was correct, it's the variable's names that - were misleading ;-) Make the code more readable. - - (MemberAccess::DoResolve): Fix the code which handles Enum literals to set - the correct type etc. - - (ConvertExplicit): Handle Enum types by examining the underlying type. - -2001-11-21 Ravi Pratap - - * parameter.cs (GetCallingConvention): Always return - CallingConventions.Standard for now. - -2001-11-22 Miguel de Icaza - - * expression.cs (Binary.ResolveOperator): Update the values of `l' - and `r' after calling DoNumericPromotions. - - * ecore.cs: Fix error message (the types were in the wrong order). - - * statement.cs (Foreach.ProbeCollectionType): Need to pass - BindingFlags.Instance as well - - * ecore.cs (Expression.TryImplicitIntConversion): Wrap the result - implicit int literal conversion in an empty cast so that we - propagate the right type upstream. - - (UnboxCast): new class used to unbox value types. - (Expression.ConvertExplicit): Add explicit type conversions done - by unboxing. - - (Expression.ImplicitNumericConversion): Oops, forgot to test for - the target type before applying the implicit LongLiterals to ULong - literal cast. - -2001-11-21 Miguel de Icaza - - * cs-parser.jay (for_statement): Reworked the way For works: now - we declare manually any variables that are introduced in - for_initializer to solve the problem of having out-of-band code - emition (that is what got for broken). - - (declaration_statement): Perform the actual variable declaration - that used to be done in local_variable_declaration here. - - (local_variable_declaration): Do not declare anything, just pass - the information on a DictionaryEntry - -2001-11-20 Ravi Pratap - - * expression.cs (ArrayCreation::CheckIndices): The story continues :-) Complete - re-write of the logic to now make it recursive. - - (UpdateIndices): Re-write accordingly. - - Store element data in a separate ArrayData list in the above methods. - - (MakeByteBlob): Implement to dump the array data into a byte array. - -2001-11-19 Ravi Pratap - - * expression.cs (ArrayCreation): Factor out some code from ValidateInitializers - into CheckIndices. - - * constant.cs (Define): Implement. - - (EmitConstant): Re-write fully. - - Pass in location info. - - * class.cs (Populate, Emit): Call Constant::Define and Constant::EmitConstant - respectively. - - * cs-parser.jay (constant_declarator): Use VariableDeclaration instead of - DictionaryEntry since we need location info too. - - (constant_declaration): Update accordingly. - - * expression.cs (ArrayCreation): Make ValidateInitializers simpler by factoring - code into another method : UpdateIndices. - -2001-11-18 Ravi Pratap - - * expression.cs (ArrayCreation::ValidateInitializers): Update to perform - some type checking etc. - -2001-11-17 Ravi Pratap - - * expression.cs (ArrayCreation::ValidateInitializers): Implement - bits to provide dimension info if the user skips doing that. - - Update second constructor to store the rank correctly. - -2001-11-16 Ravi Pratap - - * expression.cs (ArrayCreation::ValidateInitializers): Poke around - and try to implement. - - * ../errors/cs0150.cs : Add. - - * ../errors/cs0178.cs : Add. - -2001-11-16 Miguel de Icaza - - * statement.cs: Implement foreach on multi-dimensional arrays. - - * parameter.cs (Parameters.GetParameterByName): Also lookup the - name of the params argument. - - * expression.cs: Use EmitStoreOpcode to get the right opcode while - initializing the array. - - (ArrayAccess.EmitStoreOpcode): move the opcode generation here, so - we can use this elsewhere. - - * statement.cs: Finish implementation of foreach for single - dimension arrays. - - * cs-parser.jay: Use an out-of-band stack to pass information - around, I wonder why I need this. - - foreach_block: Make the new foreach_block the current_block. - - * parameter.cs (Parameters.GetEmptyReadOnlyParameters): New - function used to return a static Parameters structure. Used for - empty parameters, as those are created very frequently. - - * cs-parser.jay, class.cs: Use GetEmptyReadOnlyParameters - -2001-11-15 Ravi Pratap - - * interface.cs : Default modifier is private, not public. The - make verify test passes again. - -2001-11-15 Ravi Pratap - - * support.cs (ReflectionParameters): Fix logic to determine - whether the last parameter is a params one. Test 9 passes again. - - * delegate.cs (Populate): Register the builders we define with - RegisterParameterForBuilder. Test 19 passes again. - - * cs-parser.jay (property_declaration): Reference $6 instead - of $$ to get at the location. - - (indexer_declaration): Similar stuff. - - (attribute): Ditto. - - * class.cs (Property): Register parameters for the Get and Set methods - if they exist. Test 23 passes again. - - * expression.cs (ArrayCreation::Emit): Pass null for the method in the - call to EmitArguments as we are sure there aren't any params arguments. - Test 32 passes again. - - * suppor.cs (ParameterDesc, ParameterModifier): Fix trivial bug causing - IndexOutOfRangeException. - - * class.cs (Property::Define): Register property using TypeManager.RegisterProperty - Test 33 now passes again. - -2001-11-15 Miguel de Icaza - - * cs-parser.jay: Kill horrendous hack ($??? = lexer.Location) that - broke a bunch of things. Will have to come up with a better way - of tracking locations. - - * statement.cs: Implemented foreach for single dimension arrays. - -2001-11-09 Miguel de Icaza - - * enum.cs (Enum.Emit): Delay the lookup of loc until we run into - an error. This removes the lookup from the critical path. - - * cs-parser.jay: Removed use of temporary_loc, which is completely - broken. - -2001-11-14 Miguel de Icaza - - * support.cs (ReflectionParameters.ParameterModifier): Report - whether the argument is a PARAMS argument or not. - - * class.cs: Set the attribute `ParamArrayAttribute' on the - parameter argument. - - * typemanager.cs: Define param_array_type (ParamArrayAttribute) - and cons_param_array_attribute (ConstructorInfo for - ParamArrayAttribute)., - - * codegen.cs: Emit the return using the `Return' statement, that - way we can report the error correctly for missing return values. - - * class.cs (Method.Emit): Clean up. - - * expression.cs (Argument.Resolve): Take another argument: the - location where this argument is used. Notice that this is not - part of the "Argument" class as to reduce the size of the - structure (we know the approximate location anyways). - - Test if the argument is a variable-reference, if not, then - complain with a 206. - - (Argument.Emit): Emit addresses of variables. - - (Argument.FullDesc): Simplify. - - (Invocation.DoResolve): Update for Argument.Resolve. - - (ElementAccess.DoResolve): ditto. - - * delegate.cs (DelegateInvocation.Emit): Invocation of Invoke - method should be virtual, as this method is always virtual. - - (NewDelegate.DoResolve): Update for Argument.Resolve. - - * class.cs (ConstructorInitializer.DoResolve): ditto. - - * attribute.cs (Attribute.Resolve): ditto. - -2001-11-13 Miguel de Icaza - - * statement.cs (Foreach.Emit): Use EmitAssign instead of Store. - - * expression.cs (ParameterReference): Drop IStackStorage and implement - IAssignMethod instead. - - (LocalVariableReference): ditto. - - * ecore.cs (FieldExpr): Drop IStackStorage and implement - IAssignMethod instead. - -2001-11-13 Miguel de Icaza - - * parameter.cs, expression.cs, class.cs, ecore.cs: Made all - enumerations that are used in heavily used structures derive from - byte in a laughable and pathetic attempt to reduce memory usage. - This is the kind of pre-optimzations that you should not do at - home without adult supervision. - - * expression.cs (UnaryMutator): New class, used to handle ++ and - -- separatedly from the other unary operators. Cleans up the - code, and kills the ExpressionStatement dependency in Unary. - - (Unary): Removed `method' and `Arguments' from this class, making - it smaller, and moving it all to SimpleCall, so I can reuse this - code in other locations and avoid creating a lot of transient data - strucutres when not required. - - * cs-parser.jay: Adjust for new changes. - -2001-11-11 Miguel de Icaza - - * enum.cs (Enum.Populate): If there is a failure during - definition, return - - * cs-parser.jay (opt_enum_base): we used to catch type errors - here, but this is really incorrect. The type error should be - catched during semantic analysis. - -2001-12-11 Ravi Pratap - - * cs-parser.jay (operator_declarator, conversion_operator_declarator): Set - current_local_parameters as expected since I, in my stupidity, had forgotten - to do this :-) - - * attribute.cs (GetValidPlaces): Fix stupid bug. - - * class.cs (Method::Emit): Perform check on applicability of attributes. - - (Constructor::Emit): Ditto. - - (Field::Emit): Ditto. - - (Field.Location): Store location information. - - (Property, Event, Indexer, Operator): Ditto. - - * cs-parser.jay (field_declaration): Pass in location for each field. - - * ../errors/cs0592.cs : Add. - -2001-11-12 Ravi Pratap - - * typemanager.cs (attribute_usage_type): New static member for System.AttributeUsage. - - (InitCoreTypes): Update accordingly. - - (RegisterAttrType, LookupAttr): Implement. - - * attribute.cs (Attribute.Targets, AllowMultiple, Inherited): New fields to hold - info about the same. - - (Resolve): Update to populate the above as necessary. - - (Error592): Helper. - - (GetValidPlaces): Helper to the above. - - (CheckAttribute): Implement to perform validity of attributes on declarative elements. - - * class.cs (TypeContainer::Emit): Update attribute emission code to perform checking etc. - -2001-11-12 Ravi Pratap - - * attribute.cs (Attribute::Resolve): Expand to handle named arguments too. - - * ../errors/cs0617.cs : Add. - -2001-11-11 Ravi Pratap - - * enum.cs (Emit): Rename to Populate to be more consistent with what - we expect it to do and when exactly it is called. - - * class.cs, rootcontext.cs : Update accordingly. - - * typemanager.cs (RegisterField, GetValue): Workarounds for the fact that - FieldInfo.GetValue does not work on dynamic types ! S.R.E lameness strikes again ! - - * enum.cs (Populate): Register fields with TypeManager.RegisterField. - - * expression.cs (MemberAccess.DoResolve): Adjust code to obtain the value - of a fieldinfo using the above, when dealing with a FieldBuilder. - -2001-11-10 Ravi Pratap - - * ../errors/cs0031.cs : Add. - - * ../errors/cs1008.cs : Add. - - * ../errrors/cs0543.cs : Add. - - * enum.cs (DefineEnum): Check the underlying type and report an error if not a valid - enum type. - - (FindMembers): Implement. - - * typemanager.cs (FindMembers): Re-write to call the appropriate methods for - enums and delegates too. - - (enum_types): Rename to builder_to_enum. - - (delegate_types): Rename to builder_to_delegate. - - * delegate.cs (FindMembers): Implement. - -2001-11-09 Ravi Pratap - - * typemanager.cs (IsEnumType): Implement. - - * enum.cs (Emit): Re-write parts to account for the underlying type - better and perform checking etc. - - (GetNextDefaultValue): Helper to ensure we don't overshoot max value - of the underlying type. - - * literal.cs (GetValue methods everywhere): Perform bounds checking and return - value - - * enum.cs (error31): Helper to report error #31. - - * cs-parser.jay (enum_declaration): Store location of each member too. - - * enum.cs (member_to_location): New hashtable. - - (AddEnumMember): Update location hashtable. - - (Emit): Use the location of each member while reporting errors. - -2001-11-09 Miguel de Icaza - - * cs-parser.jay: A for_initializer if is a - local_variable_declaration really ammount to have an implicit - block with the variable declaration and no initializer for for. - - * statement.cs (For.Emit): Cope with null initializers. - - This fixes the infinite loop on for initializers. - -2001-11-08 Miguel de Icaza - - * enum.cs: More cleanup. - - * ecore.cs: Remove dead code. - - * class.cs (Property.Emit): More simplification. - (Event.Emit): ditto. - - Reworked to have less levels of indentation. - -2001-11-08 Ravi Pratap - - * class.cs (Property): Emit attributes. - - (Field): Ditto. - - (Event): Ditto. - - (Indexer): Ditto. - - (Operator): Ditto. - - * enum.cs (Emit): Ditto. - - * rootcontext.cs (ResolveTree, EmitCode, CloseTypes): Do the same for - Enums too. - - * class.cs (Field, Event, etc.): Move attribute generation into the - Emit method everywhere. - - * enum.cs (Enum): Revamp to use the same definition semantics as delegates so - we have a DefineEnum, CloseEnum etc. The previous way of doing things was not right - as we had no way of defining nested enums ! - - * rootcontext.cs : Adjust code accordingly. - - * typemanager.cs (AddEnumType): To keep track of enum types separately. - -2001-11-07 Ravi Pratap - - * expression.cs (EvalConstantExpression): Move into ecore.cs - - * enum.cs (Enum): Rename some members and make them public and readonly - according to our convention. - - * modifiers.cs (EnumAttr): Implement as we need to set only visibility flags, - nothing else. - - * enum.cs (Enum::Define): Use the above instead of TypeAttr. - - (Enum::Emit): Write a simple version for now which doesn't try to compute - expressions. I shall modify this to be more robust in just a while. - - * class.cs (TypeContainer::Emit): Make sure we include Enums too. - - (TypeContainer::CloseType): Create the Enum types too. - - * attribute.cs (Resolve): Use the new Reduce method instead of EvalConstantExpression. - - * expression.cs (EvalConstantExpression): Get rid of completely. - - * enum.cs (Enum::Emit): Use the new expression reducer. Implement assigning - user-defined values and other cases. - - (IsValidEnumLiteral): Helper function. - - * expression.cs (ExprClassfromMemberInfo): Modify to not do any literalizing - out there in the case we had a literal FieldExpr. - - (MemberAccess:DoResolve): Do the literalizing of the FieldExpr here. - - (Literalize): Revamp a bit to take two arguments. - - (EnumLiteral): New class which derives from Literal to wrap enum literals. - -2001-11-06 Ravi Pratap - - * cs-parser.jay (compilation_unit): Remove extra opt_attributes for now. - - * expression.cs (ArrayCreation::ValidateInitializers): Implement. - - (Resolve): Use the above to ensure we have proper initializers. - -2001-11-05 Ravi Pratap - - * expression.cs (Expression::EvalConstantExpression): New method to - evaluate constant expressions. - - * attribute.cs (Attribute::Resolve): Modify bits to use the above function. - -2001-11-07 Miguel de Icaza - - * expression.cs (ArrayCreation.Emit): Some bits to initialize data - in an array. - - (Binary.ResolveOperator): Handle operator != (object a, object b) - and operator == (object a, object b); - - (Binary.DoNumericPromotions): Indicate whether the numeric - promotion was possible. - - (ArrayAccess.DoResolve, ArrayAccess.Emit, ArrayAccess.EmitAssign): - Implement. - - Made the ArrayAccess implement interface IAssignMethod instead of - IStackStore as the order in which arguments are passed reflects - this. - - * assign.cs: Instead of using expr.ExprClass to select the way of - assinging, probe for the IStackStore/IAssignMethod interfaces. - - * typemanager.cs: Load InitializeArray definition. - - * rootcontext.cs (RootContext.MakeStaticData): Used to define - static data that can be used to initialize arrays. - -2001-11-05 Miguel de Icaza - - * expression.cs: Handle operator== and operator!= for booleans. - - (Conditioal.Reduce): Implement reducer for the ?: operator. - - (Conditional.Resolve): Implement dead code elimination. - - (Binary.Resolve): Catch string literals and return a new - concatenated string. - - (Unary.Reduce): Implement reduction of unary expressions. - - * ecore.cs: Split out the expression core handling here. - - (Expression.Reduce): New method used to perform constant folding - and CSE. This is needed to support constant-expressions. - - * statement.cs (Statement.EmitBoolExpression): Pass true and false - targets, and optimize for !x. - -2001-11-04 Ravi Pratap - - * attribute.cs (Attribute::Resolve): Implement guts. Note that resolution - of an attribute gives us a CustomAttributeBuilder which we use accordingly to - set custom atttributes. - - * literal.cs (Literal::GetValue): New abstract method to return the actual - value of the literal, cast as an object. - - (*Literal): Implement GetValue method. - - * cs-parser.jay (positional_argument_list, named_argument_list): Add not just plain - expressions to the arraylist but objects of type Argument. - - * class.cs (TypeContainer::Emit): Emit our attributes too. - - (Method::Emit, Constructor::Emit): Ditto. - - * cs-parser.jay (constructor_declaration): Set attributes too, which we seemed - to be ignoring earlier. - -2001-11-03 Ravi Pratap - - * attribute.cs (AttributeSection::Define): Implement to do the business - of constructing a CustomAttributeBuilder. - - (Attribute): New trivial class. Increases readability of code. - - * cs-parser.jay : Update accordingly. - - (positional_argument_list, named_argument_list, named_argument): New rules - - (attribute_arguments): Use the above so that we are more correct. - -2001-11-02 Ravi Pratap - - * expression.cs (Invocation::IsParamsMethodApplicable): Implement - to perform all checks for a method with a params parameter. - - (Invocation::OverloadResolve): Update to use the above method and therefore - cope correctly with params method invocations. - - * support.cs (InternalParameters::ParameterDesc): Provide a desc for - params too. - - * class.cs (ConstructorInitializer::Resolve): Make sure we look for Non-public - constructors in our parent too because we can't afford to miss out on - protected ones ;-) - - * attribute.cs (AttributeSection): New name for the class Attribute - - Other trivial changes to improve readability. - - * cs-parser.jay (opt_attributes, attribute_section etc.): Modify to - use the new class names. - -2001-11-01 Ravi Pratap - - * class.cs (Method::Define): Complete definition for params types too - - (Indexer::Define): Ditto. - - * support.cs (InternalParameters::ParameterType, ParameterDesc, ParameterModifier): - Cope everywhere with a request for info about the array parameter. - -2001-11-01 Ravi Pratap - - * tree.cs (RecordNamespace): Fix up to check for the correct key. - - * cs-parser.jay (GetQualifiedIdentifier): New Helper method used in - local_variable_type to extract the string corresponding to the type. - - (local_variable_type): Fixup the action to use the new helper method. - - * codegen.cs : Get rid of RefOrOutParameter, it's not the right way to - go. - - * expression.cs : Clean out code which uses the above. - -2001-10-31 Ravi Pratap - - * typemanager.cs (RegisterMethod): Check if we already have an existing key - and bale out if necessary by returning a false. - - (RegisterProperty): Ditto. - - * class.cs (everywhere): Check the return value from TypeManager.RegisterMethod - and print out appropriate error messages. - - * interface.cs (everywhere): Ditto. - - * cs-parser.jay (property_declaration, event_declaration, indexer_declaration): Pass - location to constructor. - - * class.cs (Property, Event, Indexer): Update accordingly. - - * ../errors/cs111.cs : Added. - - * expression.cs (Invocation::IsApplicable): New static method to determine applicability - of a method, as laid down by the spec. - - (Invocation::OverloadResolve): Use the above method. - -2001-10-31 Ravi Pratap - - * support.cs (InternalParameters): Get rid of crap taking in duplicate info. We - now take a TypeContainer and a Parameters object. - - (ParameterData): Modify return type of ParameterModifier method to be - Parameter.Modifier and not a string. - - (ReflectionParameters, InternalParameters): Update accordingly. - - * expression.cs (Argument::GetParameterModifier): Same here. - - * support.cs (InternalParameters::ParameterType): Find a better way of determining - if we are a ref/out parameter. Actually, the type shouldn't be holding the '&' - symbol in it at all so maybe this is only for now. - -2001-10-30 Ravi Pratap - - * support.cs (InternalParameters): Constructor now takes an extra argument - which is the actual Parameters class. - - (ParameterDesc): Update to provide info on ref/out modifiers. - - * class.cs (everywhere): Update call to InternalParameters to pass in - the second argument too. - - * support.cs (ParameterData): Add ParameterModifier, which is a method - to return the modifier info [ref/out etc] - - (InternalParameters, ReflectionParameters): Implement the above. - - * expression.cs (Argument::ParameterModifier): Similar function to return - info about the argument's modifiers. - - (Invocation::OverloadResolve): Update to take into account matching modifiers - too. - - * class.cs (Indexer::Define): Actually define a Parameter object and put it onto - a new SetFormalParameters object which we pass to InternalParameters. - -2001-10-30 Ravi Pratap - - * expression.cs (NewArray): Merge into the ArrayCreation class. - -2001-10-29 Ravi Pratap - - * expression.cs (NewArray): Merge classes NewBuiltinArray and - NewUserdefinedArray into one as there wasn't much of a use in having - two separate ones. - - * expression.cs (Argument): Change field's name to ArgType from Type. - - (Type): New readonly property which returns the proper type, taking into - account ref/out modifiers. - - (everywhere): Adjust code accordingly for the above. - - * codegen.cs (EmitContext.RefOrOutParameter): New field to determine - whether we are emitting for a ref or out parameter. - - * expression.cs (Argument::Emit): Use the above field to set the state. - - (LocalVariableReference::Emit): Update to honour the flag and emit the - right stuff. - - * parameter.cs (Attributes): Set the correct flags for ref parameters. - - * expression.cs (Argument::FullDesc): New function to provide a full desc. - - * support.cs (ParameterData): Add method ParameterDesc to the interface. - - (ReflectionParameters, InternalParameters): Implement the above method. - - * expression.cs (Invocation::OverloadResolve): Use the new desc methods in - reporting errors. - - (Invocation::FullMethodDesc): Ditto. - -2001-10-29 Miguel de Icaza - - * cs-parser.jay: Add extra production for the second form of array - creation. - - * expression.cs (ArrayCreation): Update to reflect the above - change. - - * Small changes to prepare for Array initialization. - -2001-10-28 Miguel de Icaza - - * typemanager.cs (ImplementsInterface): interface might be null; - Deal with this problem; - - Also, we do store negative hits on the cache (null values), so use - this instead of calling t.GetInterfaces on the type everytime. - -2001-10-28 Ravi Pratap - - * typemanager.cs (IsBuiltinType): New method to help determine the same. - - * expression.cs (New::DoResolve): Get rid of array creation code and instead - split functionality out into different classes. - - (New::FormArrayType): Move into NewBuiltinArray. - - (Invocation::EmitArguments): Get rid of the MethodBase argument. Appears - quite useless. - - (NewBuiltinArray): New class to handle creation of built-in arrays. - - (NewBuiltinArray::DoResolve): Implement guts of array creation. Also take into - account creation of one-dimensional arrays. - - (::Emit): Implement to use Newarr and Newobj opcodes accordingly. - - (NewUserdefinedArray::DoResolve): Implement. - - * cs-parser.jay (local_variable_type): Fix up to add the rank to the variable too. - - * typemanager.cs (AddModule): Used to add a ModuleBuilder to the list of modules - we maintain inside the TypeManager. This is necessary to perform lookups on the - module builder. - - (LookupType): Update to perform GetType on the module builders too. - - * driver.cs (Driver): Add the ModuleBuilder to the list maintained by the TypeManager. - - * exprssion.cs (NewUserdefinedArray::Emit): Implement. - -2001-10-23 Ravi Pratap - - * expression.cs (New::DoResolve): Implement guts of array creation. - - (New::FormLookupType): Rename to FormArrayType and modify ever so slightly. - -2001-10-27 Miguel de Icaza - - * expression.cs: Fix bug I introduced lsat night that broke - Delegates. - - (Expression.Resolve): Report a 246 error (can not resolve name) - if we find a SimpleName in the stream. - - (Expression.ResolveLValue): Ditto. - - (Expression.ResolveWithSimpleName): This function is a variant of - ResolveName, this one allows SimpleNames to be returned without a - warning. The only consumer of SimpleNames is MemberAccess - -2001-10-26 Miguel de Icaza - - * expression.cs (Invocation::DoResolve): Catch SimpleNames that - might arrive here. I have my doubts that this is correct. - - * statement.cs (Lock): Implement lock statement. - - * cs-parser.jay: Small fixes to support `lock' and `using' - - * cs-tokenizer.cs: Remove extra space - - * driver.cs: New flag --checked, allows to turn on integer math - checking. - - * typemanger.cs: Load methodinfos for Threading.Monitor.Enter and - Threading.Monitor.Exit - -2001-10-23 Miguel de Icaza - - * expression.cs (IndexerAccess::DoResolveLValue): Set the - Expression Class to be IndexerAccess. - - Notice that Indexer::DoResolve sets the eclass to Value. - -2001-10-22 Miguel de Icaza - - * class.cs (TypeContainer::Emit): Emit code for indexers. - - * assign.cs (IAssignMethod): New interface implemented by Indexers - and Properties for handling assignment. - - (Assign::Emit): Simplify and reuse code. - - * expression.cs (IndexerAccess, PropertyExpr): Implement - IAssignMethod, clean up old code. - -2001-10-22 Ravi Pratap - - * typemanager.cs (ImplementsInterface): New method to determine if a type - implements a given interface. Provides a nice cache too. - - * expression.cs (ImplicitReferenceConversion): Update checks to use the above - method. - - (ConvertReferenceExplicit): Ditto. - - * delegate.cs (Delegate::Populate): Update to define the parameters on the - various methods, with correct names etc. - - * class.cs (Operator::OpType): New members Operator.UnaryPlus and - Operator.UnaryNegation. - - * cs-parser.jay (operator_declarator): Be a little clever in the case where - we have a unary plus or minus operator. - - * expression.cs (Unary): Rename memebers of Operator enum to UnaryPlus and - UnaryMinus. - - * everywhere : update accordingly. - - * everywhere : Change Negate and BitComplement to LogicalNot and OnesComplement - respectively. - - * class.cs (Method::Define): For the case where we are implementing a method - inherited from an interface, we need to set the MethodAttributes.Final flag too. - Also set MethodAttributes.NewSlot and MethodAttributes.HideBySig. - -2001-10-21 Ravi Pratap - - * interface.cs (FindMembers): Implement to work around S.R.E - lameness. - - * typemanager.cs (IsInterfaceType): Implement. - - (FindMembers): Update to handle interface types too. - - * expression.cs (ImplicitReferenceConversion): Re-write bits which - use IsAssignableFrom as that is not correct - it doesn't work. - - * delegate.cs (DelegateInvocation): Derive from ExpressionStatement - and accordingly override EmitStatement. - - * expression.cs (ConvertReferenceExplicit): Re-write similary, this time - using the correct logic :-) - -2001-10-19 Ravi Pratap - - * ../errors/cs-11.cs : Add to demonstrate error -11 - -2001-10-17 Miguel de Icaza - - * assign.cs (Assign::Resolve): Resolve right hand side first, and - then pass this as a hint to ResolveLValue. - - * expression.cs (FieldExpr): Add Location information - - (FieldExpr::LValueResolve): Report assignment to readonly - variable. - - (Expression::ExprClassFromMemberInfo): Pass location information. - - (Expression::ResolveLValue): Add new method that resolves an - LValue. - - (Expression::DoResolveLValue): Default invocation calls - DoResolve. - - (Indexers): New class used to keep track of indexers in a given - Type. - - (IStackStore): Renamed from LValue, as it did not really describe - what this did. Also ResolveLValue is gone from this interface and - now is part of Expression. - - (ElementAccess): Depending on the element access type - - * typemanager.cs: Add `indexer_name_type' as a Core type - (System.Runtime.CompilerServices.IndexerNameAttribute) - - * statement.cs (Goto): Take a location. - -2001-10-18 Ravi Pratap - - * delegate.cs (Delegate::VerifyDelegate): New method to verify - if two delegates are compatible. - - (NewDelegate::DoResolve): Update to take care of the case when - we instantiate a delegate from another delegate. - - * typemanager.cs (FindMembers): Don't even try to look up members - of Delegate types for now. - -2001-10-18 Ravi Pratap - - * delegate.cs (NewDelegate): New class to take care of delegate - instantiation. - - * expression.cs (New): Split the delegate related code out into - the NewDelegate class. - - * delegate.cs (DelegateInvocation): New class to handle delegate - invocation. - - * expression.cs (Invocation): Split out delegate related code into - the DelegateInvocation class. - -2001-10-17 Ravi Pratap - - * expression.cs (New::DoResolve): Implement delegate creation fully - and according to the spec. - - (New::DoEmit): Update to handle delegates differently. - - (Invocation::FullMethodDesc): Fix major stupid bug thanks to me - because of which we were printing out arguments in reverse order ! - - * delegate.cs (VerifyMethod): Implement to check if the given method - matches the delegate. - - (FullDelegateDesc): Implement. - - (VerifyApplicability): Implement. - - * expression.cs (Invocation::DoResolve): Update to accordingly handle - delegate invocations too. - - (Invocation::Emit): Ditto. - - * ../errors/cs1593.cs : Added. - - * ../errors/cs1594.cs : Added. - - * delegate.cs (InstanceExpression, TargetMethod): New properties. - -2001-10-16 Ravi Pratap - - * typemanager.cs (intptr_type): Core type for System.IntPtr - - (InitCoreTypes): Update for the same. - - (iasyncresult_type, asynccallback_type): Ditto. - - * delegate.cs (Populate): Fix to use System.Intptr as it is indeed - correct. - - * typemanager.cs (AddDelegateType): Store a pointer to the Delegate class - too. - - * delegate.cs (ConstructorBuilder, InvokeBuilder, ...): New members to hold - the builders for the 4 members of a delegate type :-) - - (Populate): Define the BeginInvoke and EndInvoke methods on the delegate - type. - - * expression.cs (New::DoResolve): Implement guts for delegate creation. - - * ../errors/errors.txt : Update for an error (-11) which only we catch :-) - -2001-10-15 Miguel de Icaza - - * statement.cs (Break::Emit): Implement. - (Continue::Emit): Implement. - - (For::Emit): Track old being/end loops; Set Begin loop, ack end loop - (While::Emit): Track old being/end loops; Set Begin loop, ack end loop - (Do::Emit): Track old being/end loops; Set Begin loop, ack end loop - (Foreach::Emit): Track old being/end loops; Set Begin loop, ack - end loop - - * codegen.cs (EmitContext::LoopEnd, EmitContext::LoopBegin): New - properties that track the label for the current loop (begin of the - loop and end of the loop). - -2001-10-15 Ravi Pratap - - * delegate.cs (Emit): Get rid of it as there doesn't seem to be any ostensible - use of emitting anything at all. - - * class.cs, rootcontext.cs : Get rid of calls to the same. - - * delegate.cs (DefineDelegate): Make sure the class we define is also sealed. - - (Populate): Define the constructor correctly and set the implementation - attributes. - - * typemanager.cs (delegate_types): New hashtable to hold delegates that - have been defined. - - (AddDelegateType): Implement. - - (IsDelegateType): Implement helper method. - - * delegate.cs (DefineDelegate): Use AddDelegateType instead of AddUserType. - - * expression.cs (New::DoResolve): Check if we are trying to instantiate a delegate type - and accordingly handle it. - - * delegate.cs (Populate): Take TypeContainer argument. - Implement bits to define the Invoke method. However, I still haven't figured out - how to take care of the native int bit :-( - - * cs-parser.jay (delegate_declaration): Fixed the bug that I had introduced :-) - Qualify the name of the delegate, not its return type ! - - * expression.cs (ImplicitReferenceConversion): Implement guts of implicit array - conversion. - - (StandardConversionExists): Checking for array types turns out to be recursive. - - (ConvertReferenceExplicit): Implement array conversion. - - (ExplicitReferenceConversionExists): New method to determine precisely that :-) - -2001-10-12 Ravi Pratap - - * cs-parser.jay (delegate_declaration): Store the fully qualified - name as it is a type declaration. - - * delegate.cs (ReturnType, Name): Rename members to these. Make them - readonly. - - (DefineDelegate): Renamed from Define. Does the same thing essentially, - as TypeContainer::DefineType. - - (Populate): Method in which all the definition of the various methods (Invoke) - etc is done. - - (Emit): Emit any code, if necessary. I am not sure about this really, but let's - see. - - (CloseDelegate): Finally creates the delegate. - - * class.cs (TypeContainer::DefineType): Update to define delegates. - (Populate, Emit and CloseType): Do the same thing here too. - - * rootcontext.cs (ResolveTree, PopulateTypes, EmitCode, CloseTypes): Include - delegates in all these operations. - -2001-10-14 Miguel de Icaza - - * expression.cs: LocalTemporary: a new expression used to - reference a temporary that has been created. - - * assign.cs: Handle PropertyAccess back here, so that we can - provide the proper semantic access to properties. - - * expression.cs (Expression::ConvertReferenceExplicit): Implement - a few more explicit conversions. - - * modifiers.cs: `NEW' modifier maps to HideBySig. - - * expression.cs (PropertyExpr): Make this into an - ExpressionStatement, and support the EmitStatement code path. - - Perform get/set error checking, clean up the interface. - - * assign.cs: recognize PropertyExprs as targets, and if so, turn - them into toplevel access objects. - -2001-10-12 Miguel de Icaza - - * expression.cs: PropertyExpr::PropertyExpr: use work around the - SRE. - - * typemanager.cs: Keep track here of our PropertyBuilders again to - work around lameness in SRE. - -2001-10-11 Miguel de Icaza - - * expression.cs (LValue::LValueResolve): New method in the - interface, used to perform a second resolution pass for LValues. - - (This::DoResolve): Catch the use of this in static methods. - - (This::LValueResolve): Implement. - - (This::Store): Remove warning, assigning to `this' in structures - is - - (Invocation::Emit): Deal with invocation of - methods on value types. We need to pass the address to structure - methods rather than the object itself. (The equivalent code to - emit "this" for structures leaves the entire structure on the - stack instead of a pointer to it). - - (ParameterReference::DoResolve): Compute the real index for the - argument based on whether the method takes or not a `this' pointer - (ie, the method is static). - - * codegen.cs (EmitContext::GetTemporaryStorage): Used to store - value types returned from functions when we need to invoke a - method on the sturcture. - - -2001-10-11 Ravi Pratap - - * class.cs (TypeContainer::DefineType): Method to actually do the business of - defining the type in the Modulebuilder or Typebuilder. This is to take - care of nested types which need to be defined on the TypeBuilder using - DefineNestedMethod. - - (TypeContainer::GetClassBases): Implement. Essentially the code from the - methods in RootContext, only ported to be part of TypeContainer. - - (TypeContainer::GetInterfaceOrClass): Ditto. - - (TypeContainer::LookupInterfaceOrClass, ::MakeFQN): Ditto. - - * interface.cs (Interface::DefineInterface): New method. Does exactly - what RootContext.CreateInterface did earlier, only it takes care of nested types - too. - - (Interface::GetInterfaces): Move from RootContext here and port. - - (Interface::GetInterfaceByName): Same here. - - * rootcontext.cs (ResolveTree): Re-write. - - (PopulateTypes): Re-write. - - * class.cs (TypeContainer::Populate): Populate nested types too. - (TypeContainer::Emit): Emit nested members too. - - * typemanager.cs (AddUserType): Do not make use of the FullName property, - instead just use the name argument passed in as it is already fully - qualified. - - (FindMembers): Check in the Builders to TypeContainer mapping instead of the name - to TypeContainer mapping to see if a type is user-defined. - - * class.cs (TypeContainer::CloseType): Implement. - - (TypeContainer::DefineDefaultConstructor): Use Basename, not Name while creating - the default constructor. - - (TypeContainer::Populate): Fix minor bug which led to creating default constructors - twice. - - (Constructor::IsDefault): Fix up logic to determine if it is the default constructor - - * interface.cs (CloseType): Create the type here. - - * rootcontext.cs (CloseTypes): Re-write to recursively close types by running through - the hierarchy. - - Remove all the methods which are now in TypeContainer. - -2001-10-10 Ravi Pratap - - * delegate.cs (Define): Re-write bits to define the delegate - correctly. - -2001-10-10 Miguel de Icaza - - * makefile: Renamed the compiler to `mcs.exe' instead of compiler.exe - - * expression.cs (ImplicitReferenceConversion): handle null as well - as a source to convert to any reference type. - - * statement.cs (Return): Perform any implicit conversions to - expected return type. - - Validate use of return statement. - - * codegen.cs (EmitContext): Pass the expected return type here. - - * class.cs (Method, Constructor, Property): Pass expected return - type to EmitContext. - -2001-10-09 Miguel de Icaza - - * expression.cs: Make DoResolve take an EmitContext instead of a - TypeContainer. - - Replaced `l' and `location' for `loc', for consistency. - - (Error, Warning): Remove unneeded Tc argument. - - * assign.cs, literal.cs, constant.cs: Update to new calling - convention. - - * codegen.cs: EmitContext now contains a flag indicating whether - code is being generated in a static method or not. - - * cs-parser.jay: DecomposeQI, new function that replaces the old - QualifiedIdentifier. Now we always decompose the assembled - strings from qualified_identifier productions into a group of - memberaccesses. - -2001-10-08 Miguel de Icaza - - * rootcontext.cs: Deal with field-less struct types correctly now - by passing the size option to Define Type. - - * class.cs: Removed hack that created one static field. - -2001-10-07 Miguel de Icaza - - * statement.cs: Moved most of the code generation here. - -2001-10-09 Ravi Pratap - - * expression.cs (New::DoResolve): Revert changes for array creation, doesn't - seem very right. - - (ElementAccess): Remove useless bits for now - keep checks as the spec - says. - -2001-10-08 Ravi Pratap - - * expression.cs (ElementAccess::DoResolve): Remove my crap code - and start performing checks according to the spec. - -2001-10-07 Ravi Pratap - - * cs-parser.jay (type_suffix*): Remove - they are redundant. Use - rank_specifiers instead. - - (rank_specifiers): Change the order in which the rank specifiers are stored - - (local_variable_declaration): Use opt_rank_specifier instead of type_suffixes. - - * expression.cs (ElementAccess): Implement the LValue interface too. - -2001-10-06 Ravi Pratap - - * expression.cs (ConvertExplicitStandard): Add. Same as ConvertExplicit - except that user defined conversions are not included. - - (UserDefinedConversion): Update to use the ConvertExplicitStandard to - perform the conversion of the return type, if necessary. - - (New::DoResolve): Check whether we are creating an array or an object - and accordingly do the needful. - - (New::Emit): Same here. - - (New::DoResolve): Implement guts of array creation. - - (New::FormLookupType): Helper function. - -2001-10-07 Miguel de Icaza - - * codegen.cs: Removed most of the code generation here, and move the - corresponding code generation bits to the statement classes. - - Added support for try/catch/finalize and throw. - - * cs-parser.jay: Added support for try/catch/finalize. - - * class.cs: Catch static methods having the flags override, - virtual or abstract. - - * expression.cs (UserCast): This user cast was not really doing - what it was supposed to do. Which is to be born in fully resolved - state. Parts of the resolution were being performed at Emit time! - - Fixed this code. - -2001-10-05 Miguel de Icaza - - * expression.cs: Implicity convert the result from UserCast. - -2001-10-05 Ravi Pratap - - * expression.cs (Expression::FindMostEncompassingType): Fix bug which - prevented it from working correctly. - - (ConvertExplicit): Make the first try, a call to ConvertImplicitStandard, not - merely ConvertImplicit. - -2001-10-05 Miguel de Icaza - - * typemanager.cs: Make the LookupTypeContainer function static, - and not per-instance. - - * class.cs: Make static FindMembers (the one that takes a Type - argument). - - * codegen.cs: Add EmitForeach here. - - * cs-parser.jay: Make foreach a toplevel object instead of the - inline expansion, as we need to perform semantic analysis on it. - -2001-10-05 Ravi Pratap - - * expression.cs (Expression::ImplicitUserConversion): Rename to - UserDefinedConversion. - - (Expression::UserDefinedConversion): Take an extra argument specifying - whether we look for explicit user conversions too. - - (Expression::ImplicitUserConversion): Make it a call to UserDefinedConversion. - - (UserDefinedConversion): Incorporate support for user defined explicit conversions. - - (ExplicitUserConversion): Make it a call to UserDefinedConversion - with the appropriate arguments. - - * cs-parser.jay (cast_expression): Record location too. - - * expression.cs (Cast): Record location info. - - (Expression::ConvertExplicit): Take location argument. - - (UserImplicitCast): Change name to UserCast. Take an extra constructor argument - to determine if we are doing explicit conversions. - - (UserCast::Emit): Update accordingly. - - (Expression::ConvertExplicit): Report an error if everything fails. - - * ../errors/cs0030.cs : Add. - -2001-10-04 Miguel de Icaza - - * modifiers.cs: If the ABSTRACT keyword is present, also set the - virtual and newslot bits. - - * class.cs (TypeContainer::RegisterRequiredImplementations): - Record methods we need. - - (TypeContainer::MakeKey): Helper function to make keys for - MethodBases, since the Methodbase key is useless. - - (TypeContainer::Populate): Call RegisterRequiredImplementations - before defining the methods. - - Create a mapping for method_builders_to_methods ahead of time - instead of inside a tight loop. - - (::RequireMethods): Accept an object as the data to set into the - hashtable so we can report interface vs abstract method mismatch. - -2001-10-03 Miguel de Icaza - - * report.cs: Make all of it static. - - * rootcontext.cs: Drop object_type and value_type computations, as - we have those in the TypeManager anyways. - - Drop report instance variable too, now it is a global. - - * driver.cs: Use try/catch on command line handling. - - Add --probe option to debug the error reporting system with a test - suite. - - * report.cs: Add support for exiting program when a probe - condition is reached. - -2001-10-03 Ravi Pratap - - * expression.cs (Binary::DoNumericPromotions): Fix the case when - we do a forcible conversion regardless of type, to check if - ForceConversion returns a null. - - (Binary::error19): Use location to report error. - - (Unary::error23): Use location here too. - - * ../errors/cs0019.cs : Check in. - - * ../errors/cs0023.cs : Check in. - - * expression.cs (Expression.MemberLookup): Return null for a rather esoteric - case of a non-null MethodInfo object with a length of 0 ! - - (Binary::ResolveOperator): Flag error if overload resolution fails to find - an applicable member - according to the spec :-) - Also fix logic to find members in base types. - - (Unary::ResolveOperator): Same here. - - (Unary::report23): Change name to error23 and make first argument a TypeContainer - as I was getting thoroughly confused between this and error19 :-) - - * expression.cs (Expression::ImplicitUserConversion): Re-write fully - (::FindMostEncompassedType): Implement. - (::FindMostEncompassingType): Implement. - (::StandardConversionExists): Implement. - - (UserImplicitCast): Re-vamp. We now need info about most specific - source and target types so that we can do the necessary conversions. - - (Invocation::MakeUnionSet): Completely re-write to make sure we form a proper - mathematical union with no duplicates. - -2001-10-03 Miguel de Icaza - - * rootcontext.cs (RootContext::PopulateTypes): Populate containers - in order from base classes to child classes, so that we can in - child classes look up in our parent for method names and - attributes (required for handling abstract, virtual, new, override - constructs: we need to instrospect our base class, and if we dont - populate the classes in order, the introspection might be - incorrect. For example, a method could query its parent before - the parent has any methods and would determine that the parent has - no abstract methods (while it could have had them)). - - (RootContext::CreateType): Record the order in which we define the - classes. - -2001-10-02 Miguel de Icaza - - * class.cs (TypeContainer::Populate): Also method definitions can - fail now, keep track of this. - - (TypeContainer::FindMembers): Implement support for - DeclaredOnly/noDeclaredOnly flag. - - (Constructor::Emit) Return the ConstructorBuilder. - - (Method::Emit) Return the MethodBuilder. - Check for abstract or virtual methods to be public. - - * rootcontext.cs (RootContext::CreateType): Register all the - abstract methods required for the class to be complete and the - interface methods that must be implemented. - - * cs-parser.jay: Report error 501 (method requires body if it is - not marked abstract or extern). - - * expression.cs (TypeOf::Emit): Implement. - - * typemanager.cs: runtime_handle_type, new global type. - - * class.cs (Property::Emit): Generate code for properties. - -2001-10-02 Ravi Pratap - - * expression.cs (Unary::ResolveOperator): Find operators on base type - too - we now conform exactly to the spec. - - (Binary::ResolveOperator): Same here. - - * class.cs (Operator::Define): Fix minor quirk in the tests. - - * ../errors/cs0215.cs : Added. - - * ../errors/cs0556.cs : Added. - - * ../errors/cs0555.cs : Added. - -2001-10-01 Miguel de Icaza - - * cs-tokenizer.cs: Reimplemented Location to be a struct with a - single integer which is really efficient - -2001-10-01 Ravi Pratap - - * expression.cs (Expression::ImplicitUserConversion): Use location - even in the case when we are examining True operators. - - * class.cs (Operator::Define): Perform extensive checks to conform - with the rules for operator overloading in the spec. - - * expression.cs (Expression::ImplicitReferenceConversion): Implement - some of the other conversions mentioned in the spec. - - * typemanager.cs (array_type): New static member for the System.Array built-in - type. - - (cloneable_interface): For System.ICloneable interface. - - * driver.cs (Driver::Driver): Initialize TypeManager's core types even before - we start resolving the tree and populating types. - - * ../errors/errors.txt : Update for error numbers -7, -8, -9, -10 - -2001-10-01 Miguel de Icaza - - * expression.cs (Expression::ExprClassFromMemberInfo, - Expression::Literalize): Create literal expressions from - FieldInfos which are literals. - - (ConvertNumericExplicit, ImplicitNumericConversion): Fix a few - type casts, because they were wrong. The test suite in tests - caught these ones. - - (ImplicitNumericConversion): ushort to ulong requires a widening - cast. - - Int32 constant to long requires widening cast as well. - - * literal.cs (LongLiteral::EmitLong): Do not generate i4 constants - for integers because the type on the stack is not i4. - -2001-09-30 Miguel de Icaza - - * expression.cs (report118): require location argument. - - * parameter.cs: Do not dereference potential null value. - - * class.cs: Catch methods that lack the `new' keyword when - overriding a name. Report warnings when `new' is used without - anything being there to override. - - * modifiers.cs: Handle `NEW' as MethodAttributes.NewSlot. - - * class.cs: Only add constructor to hashtable if it is non-null - (as now constructors can fail on define). - - (TypeManager, Class, Struct): Take location arguments. - - Catch field instance initialization in structs as errors. - - accepting_filter: a new filter for FindMembers that is static so - that we dont create an instance per invocation. - - (Constructor::Define): Catch errors where a struct constructor is - parameterless - - * cs-parser.jay: Pass location information for various new - constructs. - - * delegate.cs (Delegate): take a location argument. - - * driver.cs: Do not call EmitCode if there were problesm in the - Definition of the types, as many Builders wont be there. - - * decl.cs (Decl::Decl): Require a location argument. - - * cs-tokenizer.cs: Handle properly hex constants that can not fit - into integers, and find the most appropiate integer for it. - - * literal.cs: Implement ULongLiteral. - - * rootcontext.cs: Provide better information about the location of - failure when CreateType fails. - -2001-09-29 Miguel de Icaza - - * rootcontext.cs (RootContext::PopulateTypes): Populates structs - as well. - - * expression.cs (Binary::CheckShiftArguments): Add missing type - computation. - (Binary::ResolveOperator): Add type to the logical and and logical - or, Bitwise And/Or and Exclusive Or code paths, it was missing - before. - - (Binary::DoNumericPromotions): In the case where either argument - is ulong (and most signed types combined with ulong cause an - error) perform implicit integer constant conversions as well. - -2001-09-28 Miguel de Icaza - - * expression.cs (UserImplicitCast): Method should always be - non-null. - (Invocation::BetterConversion): Simplified test for IntLiteral. - - (Expression::ImplicitNumericConversion): Split this routine out. - Put the code that performs implicit constant integer conversions - here. - - (Expression::Resolve): Become a wrapper around DoResolve so we can - check eclass and type being set after resolve. - - (Invocation::Badness): Remove this dead function - - (Binary::ResolveOperator): Do not compute the expensive argumnets - unless we have a union for it. - - (Probe::Emit): Is needs to do an isinst and then - compare against null. - - (::CanConvert): Added Location argument. If the Location argument - is null (Location.Null), then we do not report errors. This is - used by the `probe' mechanism of the Explicit conversion. We do - not want to generate an error for something that the user - explicitly requested to be casted. But the pipeline for an - explicit cast first tests for potential implicit casts. - - So for now, if the Location is null, it means `Probe only' to - avoid adding another argument. Might have to revise this - strategy later. - - (ClassCast): New class used to type cast objects into arbitrary - classes (used in Explicit Reference Conversions). - - Implement `as' as well. - - Reverted all the patches from Ravi below: they were broken: - - * The use of `level' as a mechanism to stop recursive - invocations is wrong. That was there just to catch the - bug with a strack trace but not as a way of addressing - the problem. - - To fix the problem we have to *understand* what is going - on and the interactions and come up with a plan, not - just get things going. - - * The use of the type conversion cache that I proposed - last night had an open topic: How does this work across - protection domains. A user defined conversion might not - be public in the location where we are applying the - conversion, a different conversion might be selected - (ie, private A->B (better) but public B->A (worse), - inside A, A->B applies, but outside it, B->A will - apply). - - * On top of that (ie, even if the above is solved), - conversions in a cache need to be abstract. Ie, `To - convert from an Int to a Short use an OpcodeCast', not - `To convert from an Int to a Short use the OpcodeCast on - the variable 5' (which is what this patch was doing). - -2001-09-28 Ravi Pratap - - * expression.cs (Invocation::ConversionExists): Re-write to use - the conversion cache - - (Expression::ConvertImplicit): Automatic bailing out if level != 0. Also - cache all conversions done, not just user-defined ones. - - (Invocation::BetterConversion): The real culprit. Use ConversionExists - to determine if a conversion exists instead of acutually trying to - perform the conversion. It's faster too. - - (Expression::ConvertExplicit): Modify to use ConversionExists to check - and only then attempt the implicit conversion. - -2001-09-28 Ravi Pratap - - * expression.cs (ConvertImplicit): Use a cache for conversions - already found. Check level of recursion and bail out if necessary. - -2001-09-28 Miguel de Icaza - - * typemanager.cs (string_concat_string_string, string_concat_object_object): - Export standard methods that we expect for string operations. - - * statement.cs (Block::UsageWarning): Track usage of variables and - report the errors for not used variables. - - * expression.cs (Conditional::Resolve, ::Emit): Implement ?: - operator. - -2001-09-27 Miguel de Icaza - - * codegen.cs: remove unnneded code - - * expression.cs: Removed BuiltinTypeAccess class - - Fix the order in which implicit conversions are - done. - - The previous fixed dropped support for boxed conversions (adding a - test to the test suite now) - - (UserImplicitCast::CanConvert): Remove test for source being null, - that code is broken. We should not feed a null to begin with, if - we do, then we should track the bug where the problem originates - and not try to cover it up here. - - Return a resolved expression of type UserImplicitCast on success - rather than true/false. Ravi: this is what I was talking about, - the pattern is to use a static method as a "constructor" for - objects. - - Also, do not create arguments until the very last minute, - otherwise we always create the arguments even for lookups that - will never be performed. - - (UserImplicitCast::Resolve): Eliminate, objects of type - UserImplicitCast are born in a fully resolved state. - - * typemanager.cs (InitCoreTypes): Init also value_type - (System.ValueType). - - * expression.cs (Cast::Resolve): First resolve the child expression. - - (LValue): Add new method AddressOf to be used by - the `&' operator. - - Change the argument of Store to take an EmitContext instead of an - ILGenerator, because things like FieldExpr need to be able to call - their children expression to generate the instance code. - - (Expression::Error, Expression::Warning): Sugar functions for - reporting errors. - - (Expression::MemberLookup): Accept a TypeContainer instead of a - Report as the first argument. - - (Expression::ResolvePrimary): Killed. I still want to improve - this as currently the code is just not right. - - (Expression::ResolveMemberAccess): Simplify, but it is still - wrong. - - (Unary::Resolve): Catch errors in AddressOf operators. - - (LocalVariableReference::Emit, ::Store, ::AddressOf): typecast - index to a byte for the short-version, or the compiler will choose - the wrong Emit call, which generates the wrong data. - - (ParameterReference::Emit, ::Store): same. - - (FieldExpr::AddressOf): Implement. - - * typemanager.cs: TypeManager: made public variable instead of - property. - - * driver.cs: document --fatal. - - * report.cs (ErrorMessage, WarningMessage): new names for the old - Error and Warning classes. - - * cs-parser.jay (member_access): Turn built-in access to types - into a normal simplename - -2001-09-27 Ravi Pratap - - * expression.cs (Invocation::BetterConversion): Fix to cope - with q being null, since this was introducing a bug. - - * expression.cs (ConvertImplicit): Do built-in conversions first. - -2001-09-27 Ravi Pratap - - * expression.cs (UserImplicitCast::Resolve): Fix bug. - -2001-09-27 Ravi Pratap - - * class.cs (TypeContainer::AddConstructor): Fix a stupid bug - I had introduced long ago (what's new ?). - - * expression.cs (UserImplicitCast::CanConvert): Static method to do - the work of all the checking. - (ConvertImplicit): Call CanConvert and only then create object if necessary. - (UserImplicitCast::CanConvert, ::Resolve): Re-write. - - (Unary::Operator): Rename Add and Subtract to Addition and Subtraction because - that is the right way. - - (Invocation::MakeUnionSet): Convenience function to make unions of sets for - overloading resolution. Use everywhere instead of cutting and pasting code. - - (Binary::ResolveOperator): Use MakeUnionSet. - - (UserImplicitCast::CanConvert, ::Resolve): Update to take care of the case when - we have to convert to bool types. Not complete yet. - -2001-09-27 Miguel de Icaza - - * typemanager.cs (TypeManager::CSharpName): support ushort. - - * expression.cs (Expression::TryImplicitIntConversion): Attempts - to provide an expression that performsn an implicit constant int - conversion (section 6.1.6). - (Expression::ConvertImplicitRequired): Reworked to include - implicit constant expression conversions. - - (Expression::ConvertNumericExplicit): Finished. - - (Invocation::Emit): If InstanceExpression is null, then it means - that we perform a call on this. - -2001-09-26 Miguel de Icaza - - * expression.cs (Unary::Emit): Remove some dead code. - (Probe): Implement Resolve and Emit for `is'. - (Expression::ConvertImplicitRequired): Attempt to do constant - expression conversions here. Maybe should be moved to - ConvertImplicit, but I am not sure. - (Expression::ImplicitLongConstantConversionPossible, - Expression::ImplicitIntConstantConversionPossible): New functions - that tell whether is it possible to apply an implicit constant - expression conversion. - - (ConvertNumericExplicit): Started work on explicit numeric - conversions. - - * cs-parser.jay: Update operator constants. - - * parameter.cs (Parameters::GetParameterInfo): Hook up VerifyArgs - (Parameters::GetSignature): Hook up VerifyArgs here. - (Parameters::VerifyArgs): Verifies that no two arguments have the - same name. - - * class.cs (Operator): Update the operator names to reflect the - ones that the spec expects (as we are just stringizing the - operator names). - - * expression.cs (Unary::ResolveOperator): Fix bug: Use - MethodInfo's ReturnType instead of LookupMethodByBuilder as the - previous usage did only work for our methods. - (Expression::ConvertImplicit): Handle decimal implicit numeric - conversions as well. - (Expression::InternalTypeConstructor): Used to invoke constructors - on internal types for default promotions. - - (Unary::Emit): Implement special handling for the pre/post - increment/decrement for overloaded operators, as they need to have - the same semantics as the other operators. - - (Binary::ResolveOperator): ditto. - (Invocation::ConversionExists): ditto. - (UserImplicitCast::Resolve): ditto. - -2001-09-26 Ravi Pratap - - * expression.cs (Unary::Emit and Binary::Emit): If we have an overloaded - operator, return after emitting body. Regression tests pass again ! - - * expression.cs (ConvertImplicit): Take TypeContainer as first argument - (Unary::ForceConversion, Binary::ForceConversion): Ditto. - (Invocation::OverloadResolve): Ditto. - (Invocation::BetterFunction, BetterConversion, ConversionExists): Ditto. - - * everywhere : update calls to the above methods accordingly. - -2001-09-26 Miguel de Icaza - - * assign.cs (Assign): Make it inherit from ExpressionStatement. - - * expression.cs (ExpressionStatement): New base class used for - expressions that can appear in statements, so that we can provide - an alternate path to generate expression that do not leave a value - on the stack. - - (Expression::Emit, and all the derivatives): We no longer return - whether a value is left on the stack or not. Every expression - after being emitted leaves a single value on the stack. - - * codegen.cs (EmitContext::EmitStatementExpression): Use the - facilties of ExpressionStatement if possible. - - * cs-parser.jay: Update statement_expression. - -2001-09-25 Miguel de Icaza - - * driver.cs: Change the wording of message - -2001-09-25 Ravi Pratap - - * expression.cs (Binary::ResolveOperator): Had forgottten to set - the type of the expression to the return type of the method if - we have an overloaded operator match ! The regression tests pass again ! - (Unary::ResolveOperator): Ditto. - - * expression.cs (Invocation::ConversionExists): Correct the member lookup - to find "op_Implicit", not "implicit" ;-) - (UserImplicitCast): New class to take care of user-defined implicit conversions. - (ConvertImplicit, ForceConversion): Take TypeContainer argument - - * everywhere : Correct calls to the above accordingly. - - * expression.cs (UserImplicitCast::Resolve, ::Emit): Implement. - (ConvertImplicit): Do user-defined conversion if it exists. - -2001-09-24 Miguel de Icaza - - * assign.cs: track location. - (Resolve): Use implicit conversions on assignment. - - * literal.cs: Oops. Not good, Emit of short access values should - pass (Bytes) or the wrong argument will be selected. - - * expression.cs (Unary::Emit): Emit code for -expr. - - (Unary::ResolveOperator): Handle `Substract' for non-constants - (substract from zero from the non-constants). - Deal with Doubles as well. - - (Expression::ConvertImplicitRequired): New routine that reports an - error if no implicit conversion exists. - - (Invocation::OverloadResolve): Store the converted implicit - expressions if we make them - -2001-09-24 Ravi Pratap - - * class.cs (ConstructorInitializer): Take a Location argument. - (ConstructorBaseInitializer): Same here. - (ConstructorThisInitializer): Same here. - - * cs-parser.jay : Update all calls accordingly. - - * expression.cs (Unary, Binary, New): Take location argument. - Update accordingly everywhere. - - * cs-parser.jay : Update all calls to the above to take a location - argument. - - * class.cs : Ditto. - -2001-09-24 Ravi Pratap - - * expression.cs (Invocation::BetterFunction): Take TypeContainer argument - (Invocation::BetterConversion): Same here - (Invocation::ConversionExists): Ditto. - - (Invocation::ConversionExists): Implement. - -2001-09-22 Ravi Pratap - - * expression.cs (OverloadResolve): Improve some more to catch errors 1502 and 1503 - Also take an additional TypeContainer argument. - - * All over : Pass in TypeContainer as argument to OverloadResolve. - - * typemanager.cs (CSharpName): Update to check for the string type and return - that too. - - * expression.cs (Invocation::FullMethodDesc): New static method to return a string fully describing - a given method. - -2001-09-21 Ravi Pratap - - * expression.cs (Invocation::OverloadResolve): Re-write to conform more to the spec. - (Invocation::BetterFunction): Implement. - (Invocation::BetterConversion): Implement. - (Invocation::ConversionExists): Skeleton, no implementation yet. - - Okay, things work fine ! - -2001-09-21 Miguel de Icaza - - * typemanager.cs: declare and load enum_type, delegate_type and - void_type. - - * expression.cs (Expression::Emit): Now emit returns a value that - tells whether a value is left on the stack or not. This strategy - might be reveted tomorrow with a mechanism that would address - multiple assignments. - (Expression::report118): Utility routine to report mismatches on - the ExprClass. - - (Unary::Report23): Report impossible type/operator combination - utility function. - - (Unary::IsIncrementableNumber): Whether the type can be - incremented or decremented with add. - (Unary::ResolveOperator): Also allow enumerations to be bitwise - complemented. - (Unary::ResolveOperator): Implement ++, !, ~, - - (Invocation::Emit): Deal with new Emit convetion. - - * All Expression derivatives: Updated their Emit method to return - whether they leave values on the stack or not. - - * codegen.cs (CodeGen::EmitStatement): Pop values left on the - stack for expressions that are statements. - -2001-09-20 Miguel de Icaza - - * expression.cs (LValue): New interface. Must be implemented by - LValue objects. - (LocalVariableReference, ParameterReference, FieldExpr): Implement - LValue interface. - - * assign.cs (Assign::Emit, Assign::Resolve): Use new LValue - interface for generating code, simplifies the code. - -2001-09-20 Ravi Pratap - - * expression.cs (everywhere): Comment out return statements in ::Resolve - methods to avoid the warnings. - -2001-09-20 Miguel de Icaza - - * driver.cs (parse): Report error 2001 if we can not open the - source file. - - * expression.cs (SimpleName::ResolveSimpleName): Error if we can - not resolve it. - - * cs-parser.jay (QualifierIdentifier): Pass location to SimpleName - object. - - * statement.cs (Block::EmitMeta): Reuse the count across all the variables, - otherwise nested blocks end up with the same index. - - * codegen.cs (CodeGen::EmitTopBlock): Pass initial sequence - - * expression.cs: Instead of having FIXMEs in the Resolve - functions, throw exceptions so it is obvious that we are facing a - bug. - - * cs-parser.jay (invocation_expression): Pass Location information. - - * codegen.cs (CodeGen::Save, CodeGen::CodeGen, CodeGen::Basename): - Use a basename for those routines because .NET does not like paths - on them. - - * class.cs (TypeContainer::AddMethod): Do not call DefineName if the name was - already defined. - -2001-09-19 Miguel de Icaza - - * typemanager.cs (TypeManager::CoreLookupType): A function to make sure that we - are loading the correct data types (throws an exception if not). - (TypeManager::InitCoreTypes): Use CoreLookupType - - * expression.cs (Unary::ResolveOperator): return the child - expression for expressions which are just +expr. - (Unary::ResolveOperator): Return negative literals for -LITERAL - expressions (otherwise they are Unary {Literal}). - (Invocation::Badness): Take into account `Implicit constant - expression conversions'. - - * literal.cs (LongLiteral): Implement long literal class. - (IntLiteral): export the `Value' of the intliteral. - -2001-09-19 Ravi Pratap - - * expression.cs (Binary::Emit): Finally get the emission right ! Woo! - - * class.cs (Operator::Define): Change the methodname prefix to 'op_' - instead of 'Operator' - - * expression.cs (Binary::ResolveOperator): Update accordingly. - (Unary::Operator): Change names to 'Add' and 'Subtract' instead 'Plus' - and 'Minus' - - * cs-parser.jay (unary_expression): Update to use the new names. - - * gen-treedump.cs (GetUnary): Same here. - - * expression.cs (Unary::Resolve): Implement. - (Binary::ResolveOperator): Re-write bits to quietly continue if no overloaded - operators are found instead of making noise ;-) - (Unary::ResolveOperator): New method to do precisely the same thing which - Binary::ResolveOperator does for Binary expressions. - (Unary.method, .Arguments): Add. - (Unary::OperName): Implement. - (Unary::ForceConversion): Copy and Paste ! - - * class.cs (Operator::Define): Fix a small bug for the case when we have - a unary operator. - - * expression.cs (Unary::Emit): Implement. Need to find the right Opcodes - for the inbuilt operators. Only overloading works for now ;-) - -2001-09-18 Miguel de Icaza - - * expression.cs (CheckedExpr::Resolve, CheckedExpr::Emit, - UnCheckedExpr::Resolve, UnCheckedExpr::Emit): Implement. - - * expression.cs (This::Emit): Implement. - (This::Resolve): Implement. - (TypeOf:Resolve): Implement. - (Expression::ResolveSimpleName): Add an implicit this to instance - field references. - (MemberAccess::Resolve): Deal with Parameters and Fields. - Bind instance variable to Field expressions. - (FieldExpr::Instance): New field used to track the expression that - represents the object instance. - (FieldExpr::Resolve): Track potential errors from MemberLookup not - binding - (FieldExpr::Emit): Implement. - - * codegen.cs (EmitIf, EmitStatement, EmitBlock): Propagate whether - the last instruction contains a return opcode to avoid generating - the last `ret' instruction (this generates correct code, and it is - nice to pass the peverify output). - - * class.cs (TypeContainer::EmitFieldInitializers): Implement field - initializer for static and instance variables. - (Constructor::Emit): Allow initializer to be null in the case of - static constructors. Only emit initializer for instance - constructors. - - (TypeContainer::FindMembers): Return a null array if there are no - matches. - - Also fix the code for the MemberTypes.Method branch, as it was not - scanning that for operators (or tried to access null variables before). - - * assign.cs (Assign::Emit): Handle instance and static fields. - - * TODO: Updated. - - * driver.cs: Stop compilation if there are parse errors. - - * cs-parser.jay (constructor_declaration): Provide default base - initializer for non-static constructors. - (constructor_declarator): Do not provide a default base - initializers if none was specified. - Catch the fact that constructors should not have parameters. - - * class.cs: Do not emit parent class initializers for static - constructors, that should be flagged as an error. - -2001-09-18 Ravi Pratap - - * class.cs (RegisterMethodBuilder): Remove : it's unnecessary. - Move back code into TypeContainer::Populate. - -2001-09-18 Ravi Pratap - - * class.cs (TypeContainer::AddConstructor): Fix the check to - compare against Name, not Basename. - (Operator::OpType): Change Plus and Minus to Add and Subtract. - - * cs-parser.jay : Update accordingly. - - * class.cs (TypeContainer::FindMembers): For the case where we are searching - for methods, don't forget to look into the operators too. - (RegisterMethodBuilder): Helper method to take care of this for - methods, constructors and operators. - (Operator::Define): Completely revamp. - (Operator.OperatorMethod, MethodName): New fields. - (TypeContainer::Populate): Move the registering of builders into - RegisterMethodBuilder. - (Operator::Emit): Re-write. - - * expression.cs (Binary::Emit): Comment out code path to emit method - invocation stuff for the case when we have a user defined operator. I am - just not able to get it right ! - -2001-09-17 Miguel de Icaza - - * expression.cs (Expression::OverloadResolve): Drop TypeContainer - argument. - - (Expression::MemberLookup): Provide a version that allows to - specify the MemberTypes and BindingFlags. - - * statement.cs (Block::GetVariableInfo): Forgot to recurse here, - so it was not fetching variable information from outer blocks. - - * modifiers.cs: (Modifiers::TypeAttr): Invert condition on - Beforefieldinit as it was buggy. - - * rootcontext.cs (::LookupInterfaceOrClass): Removed an Error -200 - that Ravi put here. - - * class.cs (Constructor::Emit): Only emit if block is not null. - (TypeContainer::EmitDefaultConstructor): Removed routine, now we - deal with this by semantically definining it as if the user had - done it. - - (TypeContainer::FindMembers): Removed ad-hoc hack to deal with - constructors as we now "emit" them at a higher level. - - (TypeContainer::DefineDefaultConstructor): Used to define the - default constructors if none was provided. - - (ConstructorInitializer): Add methods Resolve and Emit. - - * expression.cs: Cast to ConstructorInfo instead of MethodInfo - -2001-09-17 Ravi Pratap - - * class.cs (TypeContainer::EmitDefaultConstructor): Register - the default constructor builder with our hashtable for methodbuilders - to methodcores. - - * expression.cs (Invocation::OverloadResolve): Add a check for pd == null - and argument_count is 0 in which case we have a match. - (Binary::ResolveOperator): More null checking and miscellaneous coding - style cleanup. - -2001-09-17 Ravi Pratap - - * rootcontext.cs (IsNameSpace): Compare against null. - - * everywhere : Correct spelling to 'Greater' and to 'Subtract' - - * class.cs (Operator::OpType): Change names to match the ones in Binary::Operator - and Unary::Operator. - - * cs-parser.jay (operator_declaration, CheckBinaryOperator, CheckUnaryOperator): Update - accordingly. - - * expression.cs (Binary::method): New member to hold the MethodBase for the case when - we have overloaded operators. - (Binary::ResolveOperator): Implement the part which does the operator overload - resolution. - - * class.cs (Operator::Emit): Implement. - (TypeContainer::Emit): Emit the operators we have too. - - * expression.cs (Binary::Emit): Update to emit the appropriate code for - the case when we have a user-defined operator. - -2001-09-17 Miguel de Icaza - - * rootcontext.cs: Fix bug: tree.Namespaces might be null. - -2001-09-16 Ravi Pratap - - * class.cs (EmitStaticFieldInitializers, EmitFieldInitializers): Make public. - (TypeContainer::EmitConstructor): Remove and move code into Contructor::Emit. - (Constructor::Emit): Implement. - (EmitStaticFieldInitializers, EmitFieldInitializers): Ensure we return immediately - if we have no work to do. - (TypeContainer::Emit): Pass in TypeContainer as argument to the constructor's - Emit method. - - * interface.cs (Interface::InterfaceAttr): Re-write to be more correct and complete. - (Interface::IsTopLevel): Add. Same as TypeContainer::IsTopLevel. - - * class.cs (TypeContainer::IsTopLevel): Modify to use parent.Parent instead - of parent.parent. - -2001-09-15 Ravi Pratap - - * tree.cs (Tree::namespaces): New hashtable to keep track of namespaces - in the source. - (Tree::RecordNamespace): Method to do what the name says ;-) - (Tree::Namespaces): Property to get at the namespaces hashtable. - - * cs-parser.jay (namespace_declaration): Call RecordNamespace to - keep track. - - * rootcontext.cs (IsNamespace): Fixed it :-) - -2001-09-14 Miguel de Icaza - - * class.cs (TypeContainer::FindMembers): Add support for - constructors. - (MethodCore): New class that encapsulates both the shared aspects - of a Constructor and a Method. - (Method, Constructor): Factored pieces into MethodCore. - - * driver.cs: Added --fatal which makes errors throw exceptions. - Load System assembly as well as part of the standard library. - - * report.cs: Allow throwing exceptions on errors for debugging. - - * modifiers.cs: Do not use `parent', instead use the real type - container to evaluate permission settings. - - * class.cs: Put Ravi's patch back in. He is right, and we will - have to cope with the - -2001-09-14 Ravi Pratap - - * modifiers.cs (TypeAttr, MethodAttr, FieldAttr): Map protected internal to - FamORAssem, not FamANDAssem. - -2001-09-14 Miguel de Icaza - - * driver.cs: Added --parse option that only parses its input files - and terminates. - - * class.cs: Reverted last change from Ravi to IsTopLevel. That is - incorrect. IsTopLevel is not used to tell whether an object is - root_types or not (that can be achieved by testing this == - root_types). But to see if this is a top-level *class* (not - necessarly our "toplevel" container). - -2001-09-14 Ravi Pratap - - * enum.cs (Enum::Define): Modify to call the Lookup method on the - parent instead of a direct call to GetType. - -2001-09-14 Ravi Pratap - - * class.cs (TypeContainer::TypeAttr): Remove property code and move it into - Modifiers.TypeAttr. This should just be a call to that method. - - * modifiers.cs (TypeAttr): Re-write and take an extra argument, the TypeContainer - object so that we can determine if we are top-level or not. - - * delegate.cs (Delegate::Define): Update call to TypeAttr method to pass in the - TypeContainer too. - - * enum.cs (Enum::Define): Ditto. - - * modifiers.cs (FieldAttr): Re-write. - - * class.cs (TypeContainer::IsTopLevel): Change accessibility to public. - (TypeContainer::HaveStaticConstructor): New property to provide access - to precisely that info. - - * modifiers.cs (MethodAttr): Re-write. - (EventAttr): Remove altogether as there seems to be no ostensible use for it. - - * class.cs (TypeContainer::IsTopLevel): Re-write. root_types doesn't seem to be the parent - of top-level types as claimed. - -2001-09-13 Miguel de Icaza - - * expression.cs (MemberLookup): Fruitless attempt to lookup - constructors. Maybe I need to emit default constructors? That - might be it (currently .NET emits this for me automatically). - (Invocation::OverloadResolve): Cope with Arguments == null. - (Invocation::EmitArguments): new function, shared by the new - constructor and us. - (Invocation::Emit): Handle static and instance methods. Emit - proper call instruction for virtual or non-virtual invocations. - (New::Emit): Implement. - (New::Resolve): Implement. - (MemberAccess:Resolve): Implement. - (MethodGroupExpr::InstanceExpression): used conforming to the spec - to track instances. - (FieldExpr::Resolve): Set type. - - * support.cs: Handle empty arguments. - - * cs-parser.jay (CompositeLookup, QualifierIdentifier, - SimpleLookup): Auxiliary routines to help parse a qualifier - identifier. - - Update qualifier_identifier rule. - - * codegen.cs: Removed debugging messages. - - * class.cs: Make this a global thing, this acts just as a "key" to - objects that we might have around. - - (Populate): Only initialize method_builders_to_methods once. - - * expression.cs (PropertyExpr): Initialize type from the - PropertyType. - - * codegen.cs (EmitContext::EmitBoolExpression): Use propper - Resolve pattern. Attempt to implicitly convert value to boolean. - Emit code. - - * expression.cs: Set the type for the int32/int32 argument case. - (Binary::ResolveOperator): Set the return type to boolean for - comparission operators - - * typemanager.cs: Remove debugging print code. - - (Invocation::Resolve): resolve type. - - * class.cs: Allocate a MemberInfo of the correct size, as the code - elsewhere depends on the test to reflect the correct contents. - - (Method::) Keep track of parameters, due to System.Reflection holes - - (TypeContainer::Populate): Keep track of MethodBuilders to Method - mapping here. - - (TypeContainer::FindMembers): Use ArrayList and then copy an array - of the exact size and return that. - - (Class::LookupMethodByBuilder): New function that maps - MethodBuilders to its methods. Required to locate the information - on methods because System.Reflection bit us again. - - * support.cs: New file, contains an interface ParameterData and - two implementations: ReflectionParameters and InternalParameters - used to access Parameter information. We will need to grow this - as required. - - * expression.cs (Invocation::GetParameterData): implement a cache - and a wrapper around the ParameterData creation for methods. - (Invocation::OverloadResolve): Use new code. - -2001-09-13 Ravi Pratap - - * class.cs (TypeContainer::EmitField): Remove and move into - (Field::Define): here and modify accordingly. - (Field.FieldBuilder): New member. - (TypeContainer::Populate): Update accordingly. - (TypeContainer::FindMembers): Implement. - -2001-09-13 Miguel de Icaza - - * statement.cs: (VariableInfo::VariableType): New field to be - initialized with the full type once it is resolved. - -2001-09-12 Miguel de Icaza - - * parameter.cs (GetParameterInfo): Use a type cache to compute - things only once, and to reuse this information - - * expression.cs (LocalVariableReference::Emit): Implement. - (OpcodeCast::Emit): fix. - - (ParameterReference::Resolve): Implement. - (ParameterReference::Emit): Implement. - - * cs-parser.jay: Fix bug introduced by Ravi, variable initializers - that are expressions need to stay as Expressions. - - * typemanager.cs (CSharpName): Returns the C# name of a type if - possible. - - * expression.cs (Expression::ConvertImplicit): New function that - implements implicit type conversions. - - (Expression::ImplicitReferenceConversion): Implements implicit - reference conversions. - - (EmptyCast): New type for transparent casts. - - (OpcodeCast): New type for casts of types that are performed with - a sequence of bytecodes. - - (BoxedCast): New type used for casting value types into reference - types. Emits a box opcode. - - (Binary::DoNumericPromotions): Implements numeric promotions of - and computation of the Binary::Type. - - (Binary::EmitBranchable): Optimization. - - (Binary::Emit): Implement code emission for expressions. - - * typemanager.cs (TypeManager): Added two new core types: sbyte - and byte. - -2001-09-12 Ravi Pratap - - * class.cs (TypeContainer::FindMembers): Method which does exactly - what Type.FindMembers does, only we don't have to use reflection. No - implementation yet. - - * typemanager.cs (typecontainers): New hashtable to hold the corresponding - typecontainer objects as we need to get at them. - (TypeManager::AddUserType): Overload to take an extra argument, the TypeContainer. - - * rootcontext.cs : Correspondingly modify called to AddUserType to pass the - typecontainer object. - - * expression.cs (MemberLookup): Modify signature to take a RootContext object instead - of just a Report object. - -2001-09-11 Ravi Pratap - - * class.cs (Event::Define): Go back to using the prefixes "add_" and - "remove_" - (TypeContainer::Populate): Now define the delegates of the type too. - (TypeContainer.Delegates): Property to access the list of delegates defined - in the type. - - * delegates.cs (Delegate::Define): Implement partially. - - * modifiers.cs (TypeAttr): Handle more flags. - -2001-09-11 Ravi Pratap - - * class.cs (Indexer::Define): Fix for loop iteration condition to be just < - and not <= - (Operator::Define): Re-write logic to get types by using the LookupType method - instead of blindly doing a Type.GetType ! How stupid can I get ;-) ? - (Indexer::Define): Ditto. - (Event::Define): Ditto. - (Property::Define): Ditto. - -2001-09-10 Ravi Pratap - - * class.cs (TypeContainer::Populate): Now define operators too. - (TypeContainer.Operators): New property to access the list of operators - in a type. - (Operator.OperatorMethodBuilder): New member to hold the method builder - for the operator we are defining. - (Operator::Define): Implement. - -2001-09-10 Ravi Pratap - - * class.cs (Event::Define): Make the prefixes of the accessor methods - addOn_ and removeOn_ - - * genericparser.cs (GenericParser::error): Overloaded method to handle the case - of the location being passed in too. Ideally, this should go later since all - error reporting should be done through the Report object. - - * class.cs (TypeContainer.Indexers): New property to access the list of indexers. - (Populate): Iterate thru the indexers we have and define them too. - (Indexer.GetMethodBuilder, .SetMethodBuilder): New members to hold the method builders - for the get and set accessors. - (Indexer::Define): Implement. - -2001-09-09 Miguel de Icaza - - * expression.cs (Binary::Resolve): Beginning of it. I scratched - my previous implementation, did not work. - - * typemanager.cs: Add a couple of missing types (the longs). - - * literal.cs: Use TypeManager.bool_type instead of getting it. - - * expression.cs (EventExpr): New kind of expressions. - (Expressio::ExprClassFromMemberInfo): finish - -2001-09-08 Miguel de Icaza - - * assign.cs: Emit stores to static fields differently. - -2001-09-08 Ravi Pratap - - * Merge in changes and adjust code to tackle conflicts. Backed out my - code in Assign::Resolve ;-) - -2001-09-08 Ravi Pratap - - * cs-parser.jay (CheckAttributeTarget): Modify call to error to use - instead Report.Error and also pass in the location. - (CSharpParser::Lexer): New readonly property to return the reference - to the Tokenizer object. - (declare_local_variables): Use Report.Error with location instead of plain - old error. - (CheckDef): Ditto. - - * class.cs (Operator::CheckUnaryOperator): Move into cs-parser.jay. - (Operator.CheckBinaryOperator): Ditto. - - * cs-parser.jay (operator_declarator): Update accordingly. - - * cs-parser.jay (CheckUnaryOperator): Modify to use Report.Error - (CheckBinaryOperator): Same here. - - * rootcontext.cs (LookupType): Add an extra lookup which simply does a lookup - on the name without any prefixes of namespace names etc. This is because we - already might have something already fully qualified like - 'System.Console.WriteLine' - - * assign.cs (Resolve): Begin implementation. Stuck ;-) - -2001-09-07 Ravi Pratap - - * cs-tokenizer.cs (location): Return a string which also contains - the file name. - - * expression.cs (ElementAccess): New class for expressions of the - type 'element access.' - (BaseAccess): New class for expressions of the type 'base access.' - (CheckedExpr, UnCheckedExpr): New classes for Checked and Unchecked expressions - respectively. - - * cs-parser.jay (element_access): Implement action. - (base_access): Implement actions. - (checked_expression, unchecked_expression): Implement. - - * cs-parser.jay (local_variable_type): Correct and implement. - (type_suffixes, type_suffix_list, type_suffix): Implement actions. - - * cs-tokenizer.cs (real_type_suffix): Comment out the extra getchar. - - * cs-parser.jay (rank_specifiers): Remove space while concatenating the type's - name and the specifiers. - - * interface.cs (InterfaceAttr): New property to return the corresponding TypeAttributes - - * rootcontext.cs (CreateInterface): Use the InterfaceAttr property instead of - making them all public ;-) - - * cs-parser.jay (error): Remove entirely as we have an implementation in the base - class anyways. - -2001-09-07 Miguel de Icaza - - * expression.cs (ExprClassFromMemberInfo): Return FieldExpr and - PropertyExprs. - (FieldExpr, PropertyExprs): New resolved expressions. - (SimpleName::MemberStaticCheck): Perform static checks for access - to non-static fields on static methods. Maybe this should be - generalized for MemberAccesses. - (SimpleName::ResolveSimpleName): More work on simple name - resolution. - - * cs-parser.jay (primary_expression/qualified_identifier): track - the parameter index. - - * codegen.cs (CodeGen::Save): Catch save exception, report error. - (EmitContext::EmitBoolExpression): Chain to expression generation - instead of temporary hack. - (::EmitStatementExpression): Put generic expression code generation. - - * assign.cs (Assign::Emit): Implement variable assignments to - local variables, parameters and fields. - -2001-09-06 Miguel de Icaza - - * statement.cs (Block::GetVariableInfo): New method, returns the - VariableInfo for a variable name in a block. - (Block::GetVariableType): Implement in terms of GetVariableInfo - - * literal.cs (IntLiteral::Emit, FloatLiteral::Emit, - DoubleLiteral::Emit, CharLiteral::Emit, BoolLiteral::Emit): Implement - -2001-09-06 Ravi Pratap - - * cs-parser.jay (operator_declaration): Continue on my quest : update - to take attributes argument. - (event_declaration): Ditto. - (enum_declaration): Ditto. - (indexer_declaration): Ditto. - - * class.cs (Operator::Operator): Update constructor accordingly. - (Event::Event): Ditto. - - * delegate.cs (Delegate::Delegate): Same here. - - * enum.cs (Enum::Enum): Same here. - -2001-09-05 Ravi Pratap - - * cs-parser.jay (CheckAttributeTarget): Update to use the right error number. - - * ../tests/cs0658.cs : New file to demonstrate error 0658. - - * attribute.cs (Attributes): New class to encapsulate all attributes which were - being passed around as an arraylist. - (Attributes::AddAttribute): Method to add attribute sections. - - * cs-parser.jay (opt_attributes): Modify actions to use the new Attributes class. - (struct_declaration): Update accordingly. - (constant_declaration): Update. - (field_declaration): Update. - (method_header): Update. - (fixed_parameter): Update. - (parameter_array): Ditto. - (property_declaration): Ditto. - (destructor_declaration): Ditto. - - * class.cs (Struct::Struct): Update constructors accordingly. - (Class::Class): Ditto. - (Field::Field): Ditto. - (Method::Method): Ditto. - (Property::Property): Ditto. - (TypeContainer::OptAttribute): update property's return type. - - * interface.cs (Interface.opt_attributes): New member. - (Interface::Interface): Update to take the extra Attributes argument. - - * parameter.cs (Parameter::Parameter): Ditto. - - * constant.cs (Constant::Constant): Ditto. - - * interface.cs (InterfaceMemberBase): New OptAttributes field. - (InterfaceMemberBase::InterfaceMemberBase): Update constructor to take - the attributes as a parameter. - (InterfaceProperty): Update constructor call. - (InterfaceEvent): Ditto. - (InterfaceMethod): Ditto. - (InterfaceIndexer): Ditto. - - * cs-parser.jay (interface_indexer_declaration): Update call to constructor to - pass the attributes too. - (interface_event_declaration): Ditto. - (interface_property_declaration): Ditto. - (interface_method_declaration): Ditto. - (interface_declaration): Ditto. - -2001-09-05 Miguel de Icaza - - * class.cs (Method::Define): Track the "static Main" definition to - create an entry point. - - * rootcontext.cs (RootContext::EntryPoint): MethodInfo that holds the - EntryPoint if we find it. - - * codegen.cs (EmitContext::EmitInvocation): Emit invocations. - (EmitContext::ig): Make this variable public. - - * driver.cs: Make the default output file be the first file name - with the .exe extension. - - Detect empty compilations - - Handle various kinds of output targets. Handle --target and - rename -t to --dumper. - - * expression.cs, literal.cs, assign.cs, constant.cs: All `Resolve' - methods inherited from Expression return now an Expression. This - will is used during the tree rewriting as we resolve them during - semantic analysis. - - (Expression::MemberLookup): Implements the MemberLookup (7.3) from - the spec. Missing entirely is the information about - accessability of elements of it. - - (Expression::ExprClassFromMemberInfo): New constructor for - Expressions that creates a fully initialized Expression based on - a MemberInfo that is one of Eventinfo, FieldINfo, PropertyInfo or - a Type. - - (Invocation::Resolve): Begin implementing resolution of invocations. - - * literal.cs (StringLiteral): Implement Emit. - -2001-09-05 Ravi Pratap - - * cs-parser.jay (error): Add new modifier because we are hiding an inherited - member. - -2001-09-04 Ravi Pratap - - * cs-parser.jay (attribute_arguments): Implement actions. - (attribute): Fix bug in production. Implement action. - (attribute_list): Implement. - (attribute_target): Implement. - (attribute_target_specifier, opt_target_specifier): Implement - (CheckAttributeTarget): New method to check if the attribute target - is valid. - (attribute_section): Implement. - (opt_attributes): Implement. - - * attribute.cs : New file to handle attributes. - (Attribute): Class to hold attribute info. - - * cs-parser.jay (opt_attribute_target_specifier): Remove production - (attribute_section): Modify production to use 2 different rules to - achieve the same thing. 1 s/r conflict down ! - Clean out commented, useless, non-reducing dimension_separator rules. - - * class.cs (TypeContainer.attributes): New member to hold list - of attributes for a type. - (Struct::Struct): Modify to take one more argument, the attribute list. - (Class::Class): Ditto. - (Field::Field): Ditto. - (Method::Method): Ditto. - (Property::Property): Ditto. - - * cs-parser.jay (struct_declaration): Update constructor call to - pass in the attributes too. - (class_declaration): Ditto. - (constant_declaration): Ditto. - (field_declaration): Ditto. - (method_header): Ditto. - (fixed_parameter): Ditto. - (parameter_array): Ditto. - (property_declaration): Ditto. - - * constant.cs (Constant::Constant): Update constructor similarly. - Use System.Collections. - - * parameter.cs (Parameter::Parameter): Update as above. - -2001-09-02 Ravi Pratap - - * class.cs (TypeContainer::AddDelegate): New method to add a delegate. - (TypeContainer.delegates): New member to hold list of delegates. - - * cs-parser.jay (delegate_declaration): Implement the action correctly - this time as I seem to be on crack ;-) - -2001-09-02 Miguel de Icaza - - * rootcontext.cs (RootContext::IsNamespace): new function, used to - tell whether an identifier represents a namespace. - - * expression.cs (NamespaceExpr): A namespace expression, used only - temporarly during expression resolution. - (Expression::ResolveSimpleName, ::ResolvePrimary, ::ResolveName): - utility functions to resolve names on expressions. - -2001-09-01 Miguel de Icaza - - * codegen.cs: Add hook for StatementExpressions. - - * class.cs: Fix inverted test for static flag in methods. - -2001-09-02 Ravi Pratap - - * class.cs (Operator::CheckUnaryOperator): Correct error number used - to make it coincide with MS' number. - (Operator::CheckBinaryOperator): Ditto. - - * ../errors/errors.txt : Remove error numbers added earlier. - - * ../errors/cs1019.cs : Test case for error # 1019 - - * ../errros/cs1020.cs : Test case for error # 1020 - - * cs-parser.jay : Clean out commented cruft. - (dimension_separators, dimension_separator): Comment out. Ostensibly not - used anywhere - non-reducing rule. - (namespace_declarations): Non-reducing rule - comment out. - - * enum.cs (Enum::AddEnum): Rename to AddEnumMember as I was getting confused - with TypeContainer::AddEnum. - - * delegate.cs : New file for delegate handling classes. - (Delegate): Class for declaring delegates. - - * makefile : Update. - - * cs-parser.jay (delegate_declaration): Implement. - -2001-09-01 Ravi Pratap - - * class.cs (Event::Define): Implement. - (Event.EventBuilder): New member. - - * class.cs (TypeContainer::Populate): Update to define all enums and events - we have. - (Events): New property for the events arraylist we hold. Shouldn't we move to using - readonly fields for all these cases ? - -2001-08-31 Ravi Pratap - - * class.cs (Property): Revamp to use the convention of making fields readonly. - Accordingly modify code elsewhere. - - * class.cs : Apply patch from Mr. Mandar for implementing - the Define method of the Property class. - - * class.cs : Clean up applied patch and update references to variables etc. Fix - trivial bug. - (TypeContainer::Populate): Update to define all the properties we have. Also - define all enumerations. - - * enum.cs (Define): Implement. - -2001-08-31 Ravi Pratap - - * cs-parser.jay (overloadable_operator): The semantic value is an - enum of the Operator class. - (operator_declarator): Implement actions. - (operator_declaration): Implement. - - * class.cs (Operator::CheckUnaryOperator): New static method to help in checking - validity of definitions. - (Operator::CheckBinaryOperator): Static method to check for binary operators - (TypeContainer::AddOperator): New method to add an operator to a type. - - * cs-parser.jay (indexer_declaration): Added line to actually call the - AddIndexer method so it gets added ;-) - - * ../errors/errors.txt : Update to include new error numbers. Are these numbers - already taken care of by the MS compiler ? - -2001-08-29 Ravi Pratap - - * class.cs (Operator): New class for operator declarations. - (Operator::OpType): Enum for the various operators. - -2001-08-29 Ravi Pratap - - * class.cs (TypeContainer::AddIndexer): Remove FIXME comment. We - ostensibly handle this in semantic analysis. - - * cs-parser.jay (general_catch_clause): Comment out - (specific_catch_clauses, specific_catch_clause): Ditto. - (opt_general_catch_clause, opt_specific_catch_clauses): Ditto - (catch_args, opt_catch_args): New productions. - (catch_clause): Rewrite to use the new productions above - (catch_clauses): Modify accordingly. - (opt_catch_clauses): New production to use in try_statement - (try_statement): Revamp. Basically, we get rid of one unnecessary rule - and re-write the code in the actions to extract the specific and - general catch clauses by being a little smart ;-) - - * ../tests/try.cs : Fix. It's not 'finalize' my friend, it's 'finally' ! - Hooray, try and catch statements parse fine ! - -2001-08-28 Ravi Pratap - - * statement.cs (Block::GetVariableType): Fix logic to extract the type - string from the hashtable of variables. - - * cs-parser.jay (event_accessor_declarations): Trivial fix. Man, how did - I end up making that mistake ;-) - (catch_clauses): Fixed gross error which made Key and Value of the - DictionaryEntry the same : $1 !! - -2001-08-28 Ravi Pratap - - * cs-tokenizer.cs (initTokens): Add keywords 'add' and 'remove' - - * cs-parser.jay (event_declaration): Correct to remove the semicolon - when the add and remove accessors are specified. - -2001-08-28 Ravi Pratap - - * cs-parser.jay (IndexerDeclaration): New helper class to hold - information about indexer_declarator. - (indexer_declarator): Implement actions. - (parsing_indexer): New local boolean used to keep track of whether - we are parsing indexers or properties. This is necessary because - implicit_parameters come into picture even for the get accessor in the - case of an indexer. - (get_accessor_declaration, set_accessor_declaration): Correspondingly modified. - - * class.cs (Indexer): New class for indexer declarations. - (TypeContainer::AddIndexer): New method to add an indexer to a type. - (TypeContainer::indexers): New member to hold list of indexers for the - type. - -2001-08-27 Ravi Pratap - - * cs-parser.jay (add_accessor_declaration): Implement action. - (remove_accessor_declaration): Implement action. - (event_accessors_declaration): Implement - (variable_declarators): swap statements for first rule - trivial. - - * class.cs (Event): New class to hold information about event - declarations. - (TypeContainer::AddEvent): New method to add an event to a type - (TypeContainer::events): New member to hold list of events. - - * cs-parser.jay (event_declaration): Implement actions. - -2001-08-27 Ravi Pratap - - * cs-parser.jay (dim_separators): Implement. Make it a string - concatenating all the commas together, just as they appear. - (opt_dim_separators): Modify accordingly - (rank_specifiers): Update accordingly. Basically do the same - thing - instead, collect the brackets here. - (opt_rank_sepcifiers): Modify accordingly. - (array_type): Modify to actually return the complete type string - instead of ignoring the rank_specifiers. - (expression_list): Implement to collect the expressions - (variable_initializer): Implement. We make it a list of expressions - essentially so that we can handle the array_initializer case neatly too. - (variable_initializer_list): Implement. - (array_initializer): Make it a list of variable_initializers - (opt_array_initializer): Modify accordingly. - - * expression.cs (New::NType): Add enumeration to help us - keep track of whether we have an object/delegate creation - or an array creation. - (New:NewType, New::Rank, New::Indices, New::Initializers): New - members to hold data about array creation. - (New:New): Modify to update NewType - (New:New): New Overloaded contructor for the array creation - case. - - * cs-parser.jay (array_creation_expression): Implement to call - the overloaded New constructor. - -2001-08-26 Ravi Pratap - - * class.cs (TypeContainer::Constructors): Return member - constructors instead of returning null. - -2001-08-26 Miguel de Icaza - - * typemanager.cs (InitCoreTypes): Initialize the various core - types after we have populated the type manager with the user - defined types (this distinction will be important later while - compiling corlib.dll) - - * expression.cs, literal.cs, assign.cs, constant.cs: Started work - on Expression Classification. Now all expressions have a method - `Resolve' and a method `Emit'. - - * codegen.cs, cs-parser.jay: Fixed the bug that stopped code - generation from working. Also add some temporary debugging - code. - -2001-08-24 Miguel de Icaza - - * codegen.cs: Lots of code generation pieces. This is only the - beginning, will continue tomorrow with more touches of polish. We - handle the fundamentals of if, while, do, for, return. Others are - trickier and I need to start working on invocations soon. - - * gen-treedump.cs: Bug fix, use s.Increment here instead of - s.InitStatement. - - * codegen.cs (EmitContext): New struct, used during code - emission to keep a context. Most of the code generation will be - here. - - * cs-parser.jay: Add embedded blocks to the list of statements of - this block. So code generation proceeds in a top down fashion. - -2001-08-23 Miguel de Icaza - - * statement.cs: Add support for multiple child blocks. - -2001-08-22 Miguel de Icaza - - * codegen.cs (EmitCode): New function, will emit the code for a - Block of code given a TypeContainer and its ILGenerator. - - * statement.cs (Block): Standard public readonly optimization. - (Block::Block constructors): Link children. - (Block::Child): Child Linker. - (Block::EmitVariables): Emits IL variable declarations. - - * class.cs: Drop support for MethodGroups here, delay until - Semantic Analysis. - (Method::): Applied the same simplification that I did before, and - move from Properties to public readonly fields. - (Method::ParameterTypes): Returns the parameter types for the - function, and implements a cache that will be useful later when I - do error checking and the semantic analysis on the methods is - performed. - (Constructor::GetCallingConvention): Renamed from CallingConvetion - and made a method, optional argument tells whether this is a class - or a structure to apply the `has-this' bit. - (Method::GetCallingConvention): Implement, returns the calling - convention. - (Method::Define): Defines the type, a second pass is performed - later to populate the methods. - - (Constructor::ParameterTypes): implement a cache similar to the - one on Method::ParameterTypes, useful later when we do semantic - analysis. - - (TypeContainer::EmitMethod): New method. Emits methods. - - * expression.cs: Removed MethodGroup class from here. - - * parameter.cs (Parameters::GetCallingConvention): new method. - -2001-08-21 Miguel de Icaza - - * class.cs (TypeContainer::Populate): Drop RootContext from the - argument. - - (Constructor::CallingConvention): Returns the calling convention. - (Constructor::ParameterTypes): Returns the constructor parameter - types. - - (TypeContainer::AddConstructor): Keep track of default constructor - and the default static constructor. - - (Constructor::) Another class that starts using `public readonly' - instead of properties. - - (Constructor::IsDefault): Whether this is a default constructor. - - (Field::) use readonly public fields instead of properties also. - - (TypeContainer::TypeAttr, TypeContainer::AddConstructor): Keep - track of static constructors; If none is used, turn on - BeforeFieldInit in the TypeAttributes. - - * cs-parser.jay (opt_argument_list): now the return can be null - for the cases where there are no arguments. - - (constructor_declarator): If there is no implicit `base' or - `this', then invoke the default parent constructor. - - * modifiers.cs (MethodAttr): New static function maps a set of - modifiers flags into a MethodAttributes enum - (FieldAttr): renamed from `Map'. So now we have FieldAttr, - MethodAttr, TypeAttr to represent the various mappings where the - modifiers are used. - (FieldAttr): Map also `readonly' to `FieldAttributes.InitOnly' - -2001-08-19 Miguel de Icaza - - * parameter.cs (GetParameterInfo): Fix bug where there would be no - method arguments. - - * interface.cs (PopulateIndexer): Implemented the code generator - for interface indexers. - -2001-08-17 Miguel de Icaza - - * interface.cs (InterfaceMemberBase): Now we track the new status - here. - - (PopulateProperty): Implement property population. Woohoo! Got - Methods and Properties going today. - - Removed all the properties for interfaces, and replaced them with - `public readonly' fields. - -2001-08-16 Miguel de Icaza - - * interface.cs (AddEvent, AddMethod, AddIndexer, AddProperty): - initialize their hashtables/arraylists only when they are needed - instead of doing this always. - - * parameter.cs: Handle refs and out parameters. - - * cs-parser.jay: Use an ArrayList to construct the arguments - instead of the ParameterCollection, and then cast that to a - Parameter[] array. - - * parameter.cs: Drop the use of ParameterCollection and use - instead arrays of Parameters. - - (GetParameterInfo): Use the Type, not the Name when resolving - types. - -2001-08-13 Miguel de Icaza - - * parameter.cs: Eliminate the properties Name, Type and ModFlags, - and instead use public readonly fields. - - * class.cs: Put back walking code for type containers. - -2001-08-11 Miguel de Icaza - - * class.cs (MakeConstant): Code to define constants. - - * rootcontext.cs (LookupType): New function. Used to locate types - - -2001-08-08 Miguel de Icaza - - * rootcontext.cs: OH MY! My trick works! It is amazing how nice - this System.Reflection code is. Kudos to Microsoft - - * typemanager.cs: Implement a type cache and avoid loading all - types at boot time. Wrap in LookupType the internals. This made - the compiler so much faster. Wow. I rule! - - * driver.cs: Make sure we always load mscorlib first (for - debugging purposes, nothing really important). - - * Renamespaced things that were on `CSC' to `CIR'. Maybe I should - have moved to `CSC' rather than `CIR'. Oh man! The confussion! - - * rootcontext.cs: Lookup types on their namespace; Lookup types - on namespaces that have been imported using the `using' keyword. - - * class.cs (TypeContainer::TypeAttr): Virtualize. - (Class::TypeAttr): Return attributes suitable for this bad boy. - (Struct::TypeAttr): ditto. - Handle nested classes. - (TypeContainer::) Remove all the type visiting code, it is now - replaced with the rootcontext.cs code - - * rootcontext.cs (GetClassBases): Added support for structs. - -2001-08-06 Miguel de Icaza - - * interface.cs, statement.cs, class.cs, parameter.cs, - rootcontext.cs, gen-treedump.cs, enum.cs, cs-parse.jay: - Drop use of TypeRefs, and use strings instead. - -2001-08-04 Miguel de Icaza - - * rootcontext.cs: - - * class.cs (Struct::Struct): set the SEALED flags after - checking the modifiers. - (TypeContainer::TypeAttr): new property, returns the - TypeAttributes for a class. - - * cs-parser.jay (type_list): Oops, list production was creating a - new list of base types. - - * rootcontext.cs (StdLib): New property. - (GetInterfaceTypeByName): returns an interface by type name, and - encapsulates error handling here. - (GetInterfaces): simplified. - (ResolveTree): Encapsulated all the tree resolution here. - (CreateClass, GetClassBases, GetInterfaceOrClass): Create class - types. - - * driver.cs: Add support for --nostdlib, to avoid loading the - default assemblies. - (Main): Do not put tree resolution here. - - * rootcontext.cs: Beginning of the class resolution. - -2001-08-03 Miguel de Icaza - - * rootcontext.cs: Provide better error reporting. - - * cs-parser.jay (interface_base): set our $$ to be interfaces. - - * rootcontext.cs (CreateInterface): Handle the case where there - are no parent interfaces. - - (CloseTypes): Routine to flush types at the end. - (CreateInterface): Track types. - (GetInterfaces): Returns an array of Types from the list of - defined interfaces. - - * typemanager.c (AddUserType): Mechanism to track user types (puts - the type on the global type hash, and allows us to close it at the - end). - -2001-08-02 Miguel de Icaza - - * tree.cs: Removed RecordType, added RecordClass, RecordStruct and - RecordInterface instead. - - * cs-parser.jay: Updated to reflect changes above. - - * decl.cs (Definition): Keep track of the TypeBuilder type that - represents this type here. Not sure we will use it in the long - run, but wont hurt for now. - - * driver.cs: Smaller changes to accomodate the new code. - - Call ResolveInterfaceBases, Call ResolveClassBases, Save assembly - when done. - - * rootcontext.cs (CreateInterface): New method, used to create - the System.TypeBuilder type for interfaces. - (ResolveInterfaces): new entry point to resolve the interface - hierarchy. - (CodeGen): Property, used to keep track of the code generator. - -2001-07-26 Miguel de Icaza - - * cs-parser.jay: Add a second production for delegate_declaration - with `VOID'. - - (enum_body): Put an opt_comma here instead of putting it on - enum_body or enum_member_declarations so we can handle trailing - commas on enumeration members. Gets rid of a shift/reduce. - - (type_list): Need a COMMA in the middle. - - (indexer_declaration): Tell tokenizer to recognize get/set - - * Remove old targets. - - * Re-add the parser target. - -2001-07-13 Simon Cozens - - * cs-parser.jay: Add precendence rules for a number of operators - ot reduce the number of shift/reduce conflicts in the grammar. - -2001-07-17 Miguel de Icaza - - * tree.cs: moved IGenerator interface and renamed it to ITreeDump - and put it here. - - Get rid of old crufty code. - - * rootcontext.cs: Use this to keep track of the parsed - representation and the defined types available to the program. - - * gen-treedump.cs: adjust for new convention. - - * type.cs: Split out the type manager, and the assembly builder - from here. - - * typemanager.cs: the type manager will live here now. - - * cil-codegen.cs: And the code generator here. - -2001-07-14 Sean MacIsaac - - * makefile: Fixed up for easy making. - -2001-07-13 Simon Cozens - - * cs-parser.jay (rank_specifier): Remove a conflict by reordering - the - - (unary_expression): Expand pre_increment_expression and - post_decrement_expression to reduce a shift/reduce. - -2001-07-11 Simon Cozens - - * cs-tokenizer.cs: Hex numbers should begin with a 0. - - Improve allow_keyword_as_indent name. - -2001-06-19 Miguel de Icaza - - * Adjustments for Beta2. - -2001-06-13 Miguel de Icaza - - * decl.cs: Added `Define' abstract method. - (InTransit): new property, used to catch recursive definitions. - - * interface.cs: Implement `Define'. - - * modifiers.cs: Map Modifiers.constants to - System.Reflection.TypeAttribute flags. - - * class.cs: Keep track of types and user-defined types. - (BuilderInit): New method for creating an assembly - (ResolveType): New function to launch the resolution process, only - used by interfaces for now. - - * cs-parser.jay: Keep track of Classes, Structs and Interfaces - that are inserted into the name space. - -2001-06-08 Miguel de Icaza - - * ARGH. I have screwed up my tree so many times due to the use of - rsync rather than using CVS. Going to fix this at once. - - * driver.cs: Objetify driver. Load assemblies, use assemblies to - load types. - -2001-06-07 Miguel de Icaza - - * Experiment successful: Use System.Type rather that our own - version of Type. - -2001-05-25 Miguel de Icaza - - * cs-parser.jay: Removed nsAliases from here. - - Use new namespaces, handle `using XXX;' - - * namespace.cs: Reimplemented namespace handling, use a recursive - definition of the class. Now we can keep track of using clauses - and catch invalid using clauses. - -2001-05-24 Miguel de Icaza - - * gen-treedump.cs: Adapted for all the renaming. - - * expression.cs (Expression): this class now has a Type property - which returns an expression Type. - - (Probe::, New::, TypeOf::, SizeOf::, Constant::): renamed from - `Type', as this has a different meaning now in the base - -2001-05-22 Miguel de Icaza - - * interface.cs, class.cs: Removed from all the sources the - references to signature computation, as we can not do method - signature computation during the parsing time, as we are not - trying to solve at that point distinguishing: - - class X { - void a (Blah x) {} - void a (NS.Blah x) {} - } - - Which depending on the context might be valid or not, as we do not - know if Blah is the same thing as NS.Blah at that point. - - * Redid everything so the code uses TypeRefs now instead of - Types. TypeRefs are just temporary type placeholders, that need - to be resolved. They initially have a pointer to a string and the - current scope in which they are used. This is used later by the - compiler to resolve the reference to an actual Type. - - * DeclSpace is no longer a CIR.Type, and neither are - TypeContainers (Class and Struct) nor Interfaces nor Enums. They - are all DeclSpaces, but no Types. - - * type.cs (TypeRefManager): This implements the TypeRef manager, - which keeps track of all the types that need to be resolved after - the parsing has finished. - -2001-05-13 Miguel de Icaza - - * ARGH. We are going to have to store `foreach' as a class rather - than resolving it, as we need to verify error 1579 after name - resolution. *OR* we could keep a flag that says `This request to - IEnumerator comes from a foreach statement' which we can then use - to generate the error. - -2001-05-10 Miguel de Icaza - - * class.cs (TypeContainer.AddMethod): we now add methods to the - MethodGroup instead of the method hashtable. - - * expression.cs: Add MethodGroup abstraction, which gets us one - step closer to the specification in the way we handle method - declarations. - - * cs-parser.jay (primary_expression): qualified_identifier now - tried to match up an identifier to a local variable reference or - to a parameter reference. - - current_local_parameters is now a parser global variable that - points to the current parameters for the block, used during name - lookup. - - (property_declaration): Now creates an implicit `value' argument to - the set accessor. - -2001-05-09 Miguel de Icaza - - * parameter.cs: Do not use `param' arguments as part of the - signature, per the spec. - -2001-05-08 Miguel de Icaza - - * decl.cs: Base class for classes, structs and interfaces. This - is the "Declaration Space" - - * cs-parser.jay: Use CheckDef for checking declaration errors - instead of having one on each function. - - * class.cs: Factor out some code for handling error handling in - accordance to the "Declarations" section in the "Basic Concepts" - chapter in the ECMA C# spec. - - * interface.cs: Make all interface member classes derive from - InterfaceMemberBase. - -2001-05-07 Miguel de Icaza - - * Many things: all interfaces are parsed and generated in - gen-treedump. Support for member variables, constructors, - destructors, properties, constants is there. - - Beginning of the IL backend, but very little done, just there for - testing purposes. - -2001-04-29 Miguel de Icaza - - * cs-parser.jay: Fix labeled statement. - - * cs-tokenizer.cs (escape): Escape " and ' always. - ref_line, ref_name: keep track of the line/filename as instructed - by #line by the compiler. - Parse #line. - -2001-04-27 Miguel de Icaza - - * System.CodeDOM/CodeBinaryOperatorExpression.cs: Rearrange enum - to match the values in System.CodeDOM. - - Divid renamed to Divide. - - * System.CodeDOM/CodeForLoopStatement.cs: Always have valid - statements. - (Statements.set): remove. - - * System.CodeDOM/CodeCatchClause.cs: always have a valid - statements. - - * System.CodeDOM/CodeIfStatement.cs: trueStatements and - falseStatements always have valid values. - - * cs-parser.jay: Use System.CodeDOM now. - diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/Makefile b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/Makefile deleted file mode 100644 index 43a2780851..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/Makefile +++ /dev/null @@ -1,126 +0,0 @@ -thisdir := mcs -SUBDIRS := -include ../build/rules.make - -EXTRA_DISTFILES = \ - *mcs.csproj \ - compiler.doc \ - *mcs.sln \ - *cs-parser.jay \ - *.sources \ - NOTES \ - TODO \ - *mcs.exe.config - -COMPILER_NAME = gmcs - -ifeq (net_2_0, $(PROFILE)) -INTERNAL_GMCS = $(RUNTIME) $(RUNTIME_FLAGS) $(topdir)/class/lib/$(BOOTSTRAP_PROFILE)/gmcs.exe -endif - -ifeq (moonlight_bootstrap, $(PROFILE)) -INTERNAL_GMCS = $(RUNTIME) $(RUNTIME_FLAGS) $(topdir)/class/lib/$(BOOTSTRAP_PROFILE)/gmcs.exe -endif - -ifeq (2.1, $(FRAMEWORK_VERSION)) -LOCAL_MCS_FLAGS += -d:SMCS_SOURCE -COMPILER_NAME = smcs -endif - -ifeq (4.0, $(FRAMEWORK_VERSION)) -COMPILER_NAME = dmcs -endif - -PROGRAM = $(topdir)/class/lib/$(PROFILE)/$(COMPILER_NAME).exe - -BUILT_SOURCES = cs-parser.cs - -PROGRAM_COMPILE = $(BOOT_COMPILE) - -CLEAN_FILES += y.output - -%-parser.cs: %-parser.jay $(topdir)/jay/skeleton.cs - $(topdir)/jay/jay -cvt < $(topdir)/jay/skeleton.cs $< > jay-tmp.out && mv jay-tmp.out $@ - - -KEEP_OUTPUT_FILE_COPY = yes - -include ../build/executable.make - -csproj-local: - config_file=`basename $(PROGRAM) .exe`-$(PROFILE).input; \ - echo $(thisdir):$$config_file >> $(topdir)/../mono/msvc/scripts/order; \ - (echo $(is_boot); \ - echo $(BOOTSTRAP_MCS); \ - echo $(USE_MCS_FLAGS) $(LIBRARY_FLAGS) $(LIB_MCS_FLAGS); \ - echo $(PROGRAM); \ - echo $(BUILT_SOURCES); \ - echo $(PROGRAM); \ - echo $(response)) > $(topdir)/../mono/msvc/scripts/inputs/$$config_file - -# -# Below this line we have local targets used for testing and development -# - -# Testing targets - -TIME = time - -# This used to be called test, but that conflicts with the global -# recursive target. - -btest: mcs2.exe mcs3.exe - ls -l mcs2.exe mcs3.exe - -mcs2.exe: $(PROGRAM) - $(TIME) $(RUNTIME) $(RUNTIME_FLAGS) $(PROGRAM) $(USE_MCS_FLAGS) -target:exe -out:$@ $(BUILT_SOURCES) @$(response) - -mcs3.exe: mcs2.exe - $(TIME) $(RUNTIME) $(RUNTIME_FLAGS) ./mcs2.exe $(USE_MCS_FLAGS) -target:exe -out:$@ $(BUILT_SOURCES) @$(response) - -wc: - wc -l $(BUILT_SOURCES) `cat $(sourcefile)` - -ctest: - rm -f mcs2.exe mcs3.exe - $(MAKE) USE_MCS_FLAGS="-d:NET_1_1 -d:ONLY_1_1" btest - -# we need this because bash tries to use its own crappy timer -FRIENDLY_TIME = $(shell which time) -f'%U seconds' - -do-time : $(PROGRAM) - @ echo -n "Run 1: " - @ rm -f mcs2.exe - @ $(MAKE) TIME="$(FRIENDLY_TIME)" mcs2.exe > /dev/null || (echo FAILED; exit 1) - @ echo -n "Run 2: " - @ rm -f mcs3.exe - @ $(MAKE) TIME="$(FRIENDLY_TIME)" mcs3.exe > /dev/null || (echo FAILED; exit 1) - @ $(MAKE) do-corlib - -do-corlib: - @ echo -n "corlib: " - @ rm -f ../class/lib/mscorlib.dll - @ cd ../class/corlib ; $(MAKE) BOOTSTRAP_MCS='$(FRIENDLY_TIME) mono $$(topdir)/class/lib/$(PROFILE)/mcs.exe' > /dev/null || (echo FAILED; exit 1) - -PROFILER=default - -do-gettext: - xgettext --keyword='Report.Error:3' --keyword='Report.Error:2' --keyword='Report.Warning:3' --keyword='Report.Warning:2' -o mcs.po --language='C#' `cat gmcs.exe.sources | grep -v /` - -profile : $(PROGRAM) - $(RUNTIME) $(RUNTIME_FLAGS) --profile=$(PROFILER) $(PROGRAM) $(USE_MCS_FLAGS) -target:exe -out:mcs2.exe $(BUILT_SOURCES) @$(response) - -# -# quick hack target, to quickly develop the gmcs compiler -# Update manually. - -q: cs-parser.cs qh - echo 'System.Console.WriteLine ("Hello");' | mono csharp.exe - echo -e 'using System;\nConsole.WriteLine ("hello");' | mono csharp.exe - echo -e '"foo" == "bar";' | mono csharp.exe - echo -e 'var a = 1;\na + 2;' | mono csharp.exe - echo -e 'int j;\nj = 1;' | mono csharp.exe - echo -e 'var a = new int[]{1,2,3};\nfrom x in a select x;' | mono csharp.exe - echo -e 'var a = from f in System.IO.Directory.GetFiles ("/tmp") where f == "passwd" select f;' | mono csharp.exe - - diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/MonoSymbolFile.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/MonoSymbolFile.cs index 465f4c7cbe..664cdf0cf8 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/MonoSymbolFile.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/MonoSymbolFile.cs @@ -1,12 +1,13 @@ // -// Mono.CSharp.Debugger/MonoSymbolFile.cs +// MonoSymbolFile.cs // -// Author: +// Authors: // Martin Baulig (martin@ximian.com) +// Marek Safar (marek.safar@gmail.com) // // (C) 2003 Ximian, Inc. http://www.ximian.com +// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com) // - // // Permission is hereby granted, free of charge, to any person obtaining // a copy of this software and associated documentation files (the @@ -30,10 +31,7 @@ using System; using System.Reflection; -using SRE = System.Reflection.Emit; using System.Collections.Generic; -using System.Text; -using System.Threading; using System.IO; namespace Mono.CompilerServices.SymbolWriter @@ -46,7 +44,13 @@ namespace Mono.CompilerServices.SymbolWriter public MonoSymbolFileException (string message, params object[] args) : base (String.Format (message, args)) - { } + { + } + + public MonoSymbolFileException (string message, Exception innerException) + : base (message, innerException) + { + } } internal class MyBinaryWriter : BinaryWriter @@ -109,54 +113,11 @@ namespace Mono.CompilerServices.SymbolWriter } } -#if !CECIL - // TODO: Obsolete under .net 4 - internal class MonoDebuggerSupport - { - static GetMethodTokenFunc get_method_token; - static GetGuidFunc get_guid; - - delegate int GetMethodTokenFunc (MethodBase method); - delegate Guid GetGuidFunc (Module module); - - static Delegate create_delegate (Type type, Type delegate_type, string name) - { - MethodInfo mi = type.GetMethod (name, BindingFlags.Static | - BindingFlags.NonPublic); - if (mi == null) - throw new Exception ("Can't find " + name); - - return Delegate.CreateDelegate (delegate_type, mi); - } - - static MonoDebuggerSupport () - { - get_method_token = (GetMethodTokenFunc) create_delegate ( - typeof (Assembly), typeof (GetMethodTokenFunc), - "MonoDebugger_GetMethodToken"); - - get_guid = (GetGuidFunc) create_delegate ( - typeof (Module), typeof (GetGuidFunc), "Mono_GetGuid"); - } - - public static int GetMethodToken (MethodBase method) - { - return get_method_token (method); - } - - public static Guid GetGuid (Module module) - { - return get_guid (module); - } - } -#endif - public class MonoSymbolFile : IDisposable { List methods = new List (); List sources = new List (); List comp_units = new List (); - Dictionary type_hash = new Dictionary (); Dictionary anonymous_scopes; OffsetTable ot; @@ -164,7 +125,6 @@ namespace Mono.CompilerServices.SymbolWriter int last_method_index; int last_namespace_index; - public readonly string FileName = ""; public readonly int MajorVersion = OffsetTable.MajorVersion; public readonly int MinorVersion = OffsetTable.MinorVersion; @@ -187,17 +147,6 @@ namespace Mono.CompilerServices.SymbolWriter return comp_units.Count; } - internal int DefineType (Type type) - { - int index; - if (type_hash.TryGetValue (type, out index)) - return index; - - index = ++last_type_index; - type_hash.Add (type, index); - return index; - } - internal void AddMethod (MethodEntry entry) { methods.Add (entry); @@ -285,7 +234,7 @@ namespace Mono.CompilerServices.SymbolWriter // methods.Sort (); for (int i = 0; i < methods.Count; i++) - ((MethodEntry) methods [i]).Index = i + 1; + methods [i].Index = i + 1; // // Write data sections. @@ -304,7 +253,7 @@ namespace Mono.CompilerServices.SymbolWriter // ot.MethodTableOffset = (int) bw.BaseStream.Position; for (int i = 0; i < methods.Count; i++) { - MethodEntry entry = (MethodEntry) methods [i]; + MethodEntry entry = methods [i]; entry.Write (bw); } ot.MethodTableSize = (int) bw.BaseStream.Position - ot.MethodTableOffset; @@ -314,7 +263,7 @@ namespace Mono.CompilerServices.SymbolWriter // ot.SourceTableOffset = (int) bw.BaseStream.Position; for (int i = 0; i < sources.Count; i++) { - SourceFileEntry source = (SourceFileEntry) sources [i]; + SourceFileEntry source = sources [i]; source.Write (bw); } ot.SourceTableSize = (int) bw.BaseStream.Position - ot.SourceTableOffset; @@ -324,7 +273,7 @@ namespace Mono.CompilerServices.SymbolWriter // ot.CompileUnitTableOffset = (int) bw.BaseStream.Position; for (int i = 0; i < comp_units.Count; i++) { - CompileUnitEntry unit = (CompileUnitEntry) comp_units [i]; + CompileUnitEntry unit = comp_units [i]; unit.Write (bw); } ot.CompileUnitTableSize = (int) bw.BaseStream.Position - ot.CompileUnitTableOffset; @@ -381,10 +330,8 @@ namespace Mono.CompilerServices.SymbolWriter Guid guid; - MonoSymbolFile (string filename) + MonoSymbolFile (Stream stream) { - this.FileName = filename; - FileStream stream = new FileStream (filename, FileMode.Open, FileAccess.Read); reader = new MyBinaryReader (stream); try { @@ -393,89 +340,56 @@ namespace Mono.CompilerServices.SymbolWriter int minor_version = reader.ReadInt32 (); if (magic != OffsetTable.Magic) - throw new MonoSymbolFileException ( - "Symbol file `{0}' is not a valid " + - "Mono symbol file", filename); + throw new MonoSymbolFileException ("Symbol file is not a valid"); if (major_version != OffsetTable.MajorVersion) throw new MonoSymbolFileException ( - "Symbol file `{0}' has version {1}, " + - "but expected {2}", filename, major_version, - OffsetTable.MajorVersion); + "Symbol file has version {0} but expected {1}", major_version, OffsetTable.MajorVersion); if (minor_version != OffsetTable.MinorVersion) - throw new MonoSymbolFileException ( - "Symbol file `{0}' has version {1}.{2}, " + - "but expected {3}.{4}", filename, major_version, - minor_version, OffsetTable.MajorVersion, - OffsetTable.MinorVersion); + throw new MonoSymbolFileException ("Symbol file has version {0}.{1} but expected {2}.{3}", + major_version, minor_version, + OffsetTable.MajorVersion, OffsetTable.MinorVersion); MajorVersion = major_version; MinorVersion = minor_version; guid = new Guid (reader.ReadBytes (16)); ot = new OffsetTable (reader, major_version, minor_version); - } catch { - throw new MonoSymbolFileException ( - "Cannot read symbol file `{0}'", filename); + } catch (Exception e) { + throw new MonoSymbolFileException ("Cannot read symbol file", e); } source_file_hash = new Dictionary (); compile_unit_hash = new Dictionary (); } - void CheckGuidMatch (Guid other, string filename, string assembly) + public static MonoSymbolFile ReadSymbolFile (Assembly assembly) { - if (other == guid) - return; - - throw new MonoSymbolFileException ( - "Symbol file `{0}' does not match assembly `{1}'", - filename, assembly); - } + string filename = assembly.Location; + string name = filename + ".mdb"; -#if CECIL - protected MonoSymbolFile (string filename, Mono.Cecil.ModuleDefinition module) - : this (filename) - { - CheckGuidMatch (module.Mvid, filename, module.FullyQualifiedName); - } + Module[] modules = assembly.GetModules (); + Guid assembly_guid = modules[0].ModuleVersionId; - public static MonoSymbolFile ReadSymbolFile (Mono.Cecil.ModuleDefinition module) - { - return ReadSymbolFile (module, module.FullyQualifiedName); + return ReadSymbolFile (name, assembly_guid); } - public static MonoSymbolFile ReadSymbolFile (Mono.Cecil.ModuleDefinition module, string filename) + public static MonoSymbolFile ReadSymbolFile (string mdbFilename) { - string name = filename + ".mdb"; - - return new MonoSymbolFile (name, module); + return ReadSymbolFile (new FileStream (mdbFilename, FileMode.Open, FileAccess.Read)); } -#else - protected MonoSymbolFile (string filename, Assembly assembly) : this (filename) - { - // Check that the MDB file matches the assembly, if we have been - // passed an assembly. - if (assembly == null) - return; - - Module[] modules = assembly.GetModules (); - Guid assembly_guid = MonoDebuggerSupport.GetGuid (modules [0]); - CheckGuidMatch (assembly_guid, filename, assembly.Location); - } - - public static MonoSymbolFile ReadSymbolFile (Assembly assembly) + public static MonoSymbolFile ReadSymbolFile (string mdbFilename, Guid assemblyGuid) { - string filename = assembly.Location; - string name = filename + ".mdb"; + var sf = ReadSymbolFile (mdbFilename); + if (assemblyGuid != sf.guid) + throw new MonoSymbolFileException ("Symbol file `{0}' does not match assembly", mdbFilename); - return new MonoSymbolFile (name, assembly); + return sf; } -#endif - public static MonoSymbolFile ReadSymbolFile (string mdbFilename) + public static MonoSymbolFile ReadSymbolFile (Stream stream) { - return new MonoSymbolFile (mdbFilename, null); + return new MonoSymbolFile (stream); } public int CompileUnitCount { @@ -633,7 +547,7 @@ namespace Mono.CompilerServices.SymbolWriter lock (this) { read_methods (); - return (MethodEntry) method_list [index - 1]; + return method_list [index - 1]; } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/MonoSymbolTable.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/MonoSymbolTable.cs index 5f30818ff6..c9beaa0d43 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/MonoSymbolTable.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/MonoSymbolTable.cs @@ -185,9 +185,23 @@ namespace Mono.CompilerServices.SymbolWriter public readonly int Row; public readonly int File; public readonly int Offset; - public readonly bool IsHidden; + public readonly bool IsHidden; // Obsolete is never used #endregion + public sealed class LocationComparer : IComparer + { + public static readonly LocationComparer Default = new LocationComparer (); + + public int Compare (LineNumberEntry l1, LineNumberEntry l2) + { + return l1.Row == l2.Row ? + l1.Offset.CompareTo (l2.Offset) : + l1.Row.CompareTo (l2.Row); + } + } + + public static readonly LineNumberEntry Null = new LineNumberEntry (0, 0, 0); + public LineNumberEntry (int file, int row, int offset) : this (file, row, offset, false) { } @@ -200,37 +214,6 @@ namespace Mono.CompilerServices.SymbolWriter this.IsHidden = is_hidden; } - public static LineNumberEntry Null = new LineNumberEntry (0, 0, 0); - - private class OffsetComparerClass : IComparer - { - public int Compare (LineNumberEntry l1, LineNumberEntry l2) - { - if (l1.Offset < l2.Offset) - return -1; - else if (l1.Offset > l2.Offset) - return 1; - else - return 0; - } - } - - private class RowComparerClass : IComparer - { - public int Compare (LineNumberEntry l1, LineNumberEntry l2) - { - if (l1.Row < l2.Row) - return -1; - else if (l1.Row > l2.Row) - return 1; - else - return 0; - } - } - - public static readonly IComparer OffsetComparer = new OffsetComparerClass (); - public static readonly IComparer RowComparer = new RowComparerClass (); - public override string ToString () { return String.Format ("[Line {0}:{1}:{2}]", File, Row, Offset); @@ -700,6 +683,12 @@ namespace Mono.CompilerServices.SymbolWriter this.hash = checksum; } + public byte[] Checksum { + get { + return hash; + } + } + internal void WriteData (MyBinaryWriter bw) { DataOffset = (int) bw.BaseStream.Position; @@ -931,9 +920,7 @@ namespace Mono.CompilerServices.SymbolWriter (opcode <= DW_LNE_MONO__extensions_end)) { ; // reserved for future extensions } else { - throw new MonoSymbolFileException ( - "Unknown extended opcode {0:x} in LNT ({1})", - opcode, file.FileName); + throw new MonoSymbolFileException ("Unknown extended opcode {0:x}", opcode); } br.BaseStream.Position = end_pos; @@ -1123,7 +1110,7 @@ namespace Mono.CompilerServices.SymbolWriter } } - void CheckLineNumberTable (LineNumberEntry[] line_numbers) + static void CheckLineNumberTable (LineNumberEntry[] line_numbers) { int last_offset = -1; int last_row = -1; diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/MonoSymbolWriter.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/MonoSymbolWriter.cs index 4d6d1f3d2d..199ef41d50 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/MonoSymbolWriter.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/MonoSymbolWriter.cs @@ -239,165 +239,4 @@ namespace Mono.CompilerServices.SymbolWriter } } } - - public class SourceMethodBuilder - { - List _locals; - List _blocks; - List _scope_vars; -#if NET_2_1 - System.Collections.Stack _block_stack; -#else - Stack _block_stack; -#endif - string _real_name; - IMethodDef _method; - ICompileUnit _comp_unit; -// MethodEntry.Flags _method_flags; - int _ns_id; - - public SourceMethodBuilder (ICompileUnit comp_unit, int ns_id, IMethodDef method) - { - this._comp_unit = comp_unit; - this._method = method; - this._ns_id = ns_id; - - method_lines = new LineNumberEntry [32]; - } - - private LineNumberEntry [] method_lines; - private int method_lines_pos = 0; - - public void MarkSequencePoint (int offset, SourceFileEntry file, int line, int column, - bool is_hidden) - { - if (method_lines_pos == method_lines.Length) { - LineNumberEntry [] tmp = method_lines; - method_lines = new LineNumberEntry [method_lines.Length * 2]; - Array.Copy (tmp, method_lines, method_lines_pos); - } - - int file_idx = file != null ? file.Index : 0; - method_lines [method_lines_pos++] = new LineNumberEntry ( - file_idx, line, offset, is_hidden); - } - - public void StartBlock (CodeBlockEntry.Type type, int start_offset) - { - if (_block_stack == null) { -#if NET_2_1 - _block_stack = new System.Collections.Stack (); -#else - _block_stack = new Stack (); -#endif - } - - if (_blocks == null) - _blocks = new List (); - - int parent = CurrentBlock != null ? CurrentBlock.Index : -1; - - CodeBlockEntry block = new CodeBlockEntry ( - _blocks.Count + 1, parent, type, start_offset); - - _block_stack.Push (block); - _blocks.Add (block); - } - - public void EndBlock (int end_offset) - { - CodeBlockEntry block = (CodeBlockEntry) _block_stack.Pop (); - block.Close (end_offset); - } - - public CodeBlockEntry[] Blocks { - get { - if (_blocks == null) - return new CodeBlockEntry [0]; - - CodeBlockEntry[] retval = new CodeBlockEntry [_blocks.Count]; - _blocks.CopyTo (retval, 0); - return retval; - } - } - - public CodeBlockEntry CurrentBlock { - get { - if ((_block_stack != null) && (_block_stack.Count > 0)) - return (CodeBlockEntry) _block_stack.Peek (); - else - return null; - } - } - - public LocalVariableEntry[] Locals { - get { - if (_locals == null) - return new LocalVariableEntry [0]; - else { - LocalVariableEntry[] retval = - new LocalVariableEntry [_locals.Count]; - _locals.CopyTo (retval, 0); - return retval; - } - } - } - - public void AddLocal (int index, string name) - { - if (_locals == null) - _locals = new List (); - int block_idx = CurrentBlock != null ? CurrentBlock.Index : 0; - _locals.Add (new LocalVariableEntry (index, name, block_idx)); - } - - public ScopeVariable[] ScopeVariables { - get { - if (_scope_vars == null) - return new ScopeVariable [0]; - - ScopeVariable[] retval = new ScopeVariable [_scope_vars.Count]; - _scope_vars.CopyTo (retval); - return retval; - } - } - - public void AddScopeVariable (int scope, int index) - { - if (_scope_vars == null) - _scope_vars = new List (); - _scope_vars.Add ( - new ScopeVariable (scope, index)); - } - - public string RealMethodName { - get { return _real_name; } - } - - public void SetRealMethodName (string name) - { - _real_name = name; - } - - public ICompileUnit SourceFile { - get { return _comp_unit; } - } - - public IMethodDef Method { - get { return _method; } - } - - public void DefineMethod (MonoSymbolFile file) - { - LineNumberEntry[] lines = new LineNumberEntry [method_lines_pos]; - Array.Copy (method_lines, lines, method_lines_pos); - - MethodEntry entry = new MethodEntry ( - file, _comp_unit.Entry, _method.Token, ScopeVariables, - Locals, lines, Blocks, RealMethodName, 0, //_method_flags, - _ns_id); - - file.AddMethod (entry); - } - } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/NOTES b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/NOTES deleted file mode 100644 index ccae274939..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/NOTES +++ /dev/null @@ -1,38 +0,0 @@ -* Notes on improving error handling in MCS - (from Axel Schreiner ) - - -I included the 'recover' example with C# as well. Currently the package -is at . I did change some -names and the embedding that the user does somewhat, i.e., it is not -directly compatible with what you did. - -Here is the important part about error recovery. To make the typical -iterations bullet-proof, code them as follows: - -opt : // null - | opt WORD { yyErrorFlag = 0; } - | opt error - -seq : WORD - | seq WORD { yyErrorFlag = 0; } - | error - | seq error - -list : WORD - | list ',' WORD { yyErrorFlag = 0; } - | error - | list error - | list error WORD { yyErrorFlag = 0; } - | list ',' error - -i.e., throw in 'error' wherever a token can be. 'yyErrorFlag' need not -be set to zero, but if it is done this way, second errors are caught -earlier. This may introduce s/r conflicts, but they tend to be harmless. - -In your case -- the comment concerning error recovery at the beginning -of your compiler jay file -- just adding 'error' to the different -global things won't work. Your example will already have started to -advance in one of the rules and 'error' is then not in the lookahead of -wherever the parse then is. You need to put 'error' into the iteration -above those global things. \ No newline at end of file diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/OPTIMIZE b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/OPTIMIZE deleted file mode 100644 index 6fa1e31e94..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/OPTIMIZE +++ /dev/null @@ -1,26 +0,0 @@ -This document describes all code optimalizations performed by Mono C# compiler -when optimalizations are enabled via /optimize+ option. - -Optimalizations: - -* Instance field initializer to default value ---------------------------------------------- - -Code to optimize: - -class C -{ - enum E - { - Test - } - - int i = 0; // Field will not be redundantly assigned - int i2 = new int (); // This will be also completely optimized out - - E e = E.Test; // Even this will go out. - -} - - - diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/OTODO b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/OTODO deleted file mode 100644 index ee2cc56f83..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/OTODO +++ /dev/null @@ -1,239 +0,0 @@ ----- This is a list of old tasks, just here for historical value ---- - -Open question: - Create a toplevel block for anonymous methods? - -Anonymous Methods ------------------ - - Plan: - - * Resolve anonymous methods before. - * Each time a Local matches, if the mode is `InAnonymous', flag - the VariableInfo for `proxying'. - * During Resolve track the depth required for local variables. - * Before Emit, create proxy classes with proper depth. - * Emit. - -Notes on memory allocation --------------------------- - - Outdated: - - A run of the AllocationProfile shows that the compiler allocates roughly - 30 megabytes of strings. From those, 20 megabytes come from - LookupType. - - See the notes on current_container problems below on memory usage. - -LookupTypeReflection: ---------------------- - - With something like `System.Object', LookupTypeReflection will be called - twice: once to find out that `System' is not a type and once - for System.Object. - - This is required because System.Reflection requires that the type/nested types are - not separated by a dot but by a plus sign. - - A nested class would be My+Class (My being the toplevel, Class the nested one). - - It is interesting to look at the most called lookups when bootstrapping MCS: - - 647 LTR: ArrayList - 713 LTR: System.Globalization - 822 LTR: System.Object+Expression - 904 LTR: Mono.CSharp.ArrayList - 976 LTR: System.Runtime.CompilerServices - 999 LTR: Type - 1118 LTR: System.Runtime - 1208 LTR: Mono.CSharp.Type - 1373 LTR: Mono.Languages - 1599 LTR: System.Diagnostics - 2036 LTR: System.Text - 2302 LTR: System.Reflection.Emit - 2515 LTR: System.Collections - 4527 LTR: System.Reflection - 22273 LTR: Mono.CSharp - 24245 LTR: System - 27005 LTR: Mono - - Analysis: - The top 9 lookups are done for things which are not types. - - Mono.CSharp.Type happens to be a common lookup: the class Type - used heavily in the compiler in the default namespace. - - RED FLAG: - - Then `Type' is looked up alone a lot of the time, this happens - in parameter declarations and am not entirely sure that this is - correct (FindType will pass to LookupInterfaceOrClass a the current_type.FullName, - which for some reason is null!). This seems to be a problem with a lost - piece of context during FindType. - - System.Object is also used a lot as a toplevel class, and we assume it will - have children, we should just shortcut this. - - A cache: - - Adding a cache and adding a catch for `System.Object' to flag that it wont be the - root of a hierarchy reduced the MCS bootstrap time from 10.22 seconds to 8.90 seconds. - - This cache is currently enabled with SIMPLE_SPEEDUP in typemanager.cs. Memory consumption - went down from 74 megs to 65 megs with this change. - -Major tasks: ------------- - - Pinned and volatile require type modifiers that can not be encoded - with Reflection.Emit. - -* Revisit - - Primary-expression, as it has now been split into - non-array-creation-expression and array-creation-expression. - -* Emit `pinned' for pinned local variables. - - Both `modreq' and pinned will require special hacks in the compiler. - -* Make sure that we are pinning the right variable - -* local_variable_declaration - - Not sure that this grammar is correct, we might have to - resolve this during semantic analysis. - -* Optimizations - - In Indexers and Properties, probably support an EmitWithDup - That emits the code to call Get and then leaves a this pointer - in the stack, so that later a Store can be emitted using that - this pointer (consider Property++ or Indexer++) - -* Use of local temporary in UnaryMutator - - We should get rid of the Localtemporary there for some cases - - This turns out to be very complex, at least for the post-version, - because this case: - - a = i++ - - To produce optimal code, it is necessary for UnaryMutator to know - that it is being assigned to a variable (the way the stack is laid - out using dup requires the store to happen inside UnaryMutator). - -* Interface indexers - - I have not figured out why the Microsoft version puts an - `instance' attribute, and I am not generating this `instance' attribute. - - Explanation: The reason for the `instance' attribute on - indexers is that indexers only apply to instances - -* Check for Final when overriding, if the parent is Final, then we cant - allow an override. - - Implement base indexer access. - -current_container/current_namespace and the DeclSpace ------------------------------------------------------ - - We are storing fully qualified names in the DeclSpace instead of the node, - this is because `current_namespace' (Namepsace) is not a DeclSpace like - `current_container'. - - The reason for storing the full names today is this: - - namespace X { - class Y { - } - } - - namespace A { - class Y { - } - } - - The problem is that we only use the namespace stack to track the "prefix" - for typecontainers, but they are not typecontainers themselves, so we have - to use fully qualified names, because both A.X and A.Y would be entered - in the toplevel type container. If we use the short names, there would be - a name clash. - - To fix this problem, we have to make namespaces DeclSpaces. - - The full size, contrasted with the size that could be stored is: - corlib: - Size of strings held: 368901 - Size of strings short: 147863 - - System: - Size of strings held: 212677 - Size of strings short: 97521 - - System.XML: - Size of strings held: 128055 - Size of strings short: 35782 - - System.Data: - Size of strings held: 117896 - Size of strings short: 36153 - - System.Web: - Size of strings held: 194527 - Size of strings short: 58064 - - System.Windows.Forms: - Size of strings held: 220495 - Size of strings short: 64923 - - -The use of DottedName ---------------------- - - We could probably use a different system to represent names, like this: - - class Name { - string simplename; - Name parent; - } - - So `System.ComponentModel' becomes: - - x: (System, null) - y: (ComponentModel, x) - - The problem is that we would still need to construct the name to pass to - GetType. - - This has been now implemented, its called "QualifiedIdentifier" - -TODO: - - 1. Create a "partial" emit context for each TypeContainer.. - - 2. EmitContext should be partially constructed. No IL Generator. - - interface_type review. - - parameter_array, line 952: `note: must be a single dimension array type'. Validate this - -Instance idea -------------- - - It would be nice to have things that can be "instances" to have an - EmitInstance method (this would default to nothing). - - The idea is to be able to use efficiently the instance data on stack - manipulations, as opposed to the current scheme, where we basically have - a few special cases. - - * `yield' is no longer a keyword, it only has special - meaning before a return or break keywords. - - * Study side effects with assign - * Study TemporaryStorage/LocalStorage -> Merge/rename - diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/PLAN b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/PLAN deleted file mode 100644 index dc8324c3d5..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/PLAN +++ /dev/null @@ -1,66 +0,0 @@ -Clean Up --------- - - Move MapVariable from CodeGen into Block? - -Improve test: - - Necesitamos que a-capture8.cs pruebe si la asignacion funciona o no. - -Audit: - - Al emitir instancias de variables - (EmitCaptureVariableInstance) parece ser que el loop de iteracion: - - while (si.ScopeBlock.ID != li.Block.ID) - - está mas actulizado que el codigo similar para parámetros, es posible - que sea bitrot de parámetros o que en los parámetros usamos otra estrategia - (lo segundo es más razonable). - -Iteradores: - - En algún lugar no pongo el `FieldBuilder' a un valor con los - iteradores, ver expression.cs: 3616, local_info.FieldBuilder es nulo. - -Parameters: - - a-parameter4.cs falla por que no se liga el método anónimo - anidado con el padre. - -Cleanup: - - CaptureContext cc = ContextForParameter (ec.CurrentBlock.Toplevel, name); - if (cc != this){ - cc.EmitParameter (ec, name); - return; - } - - That should be a static method, and call the instance method - in the right CaptureContext, instead of having the CaptureContext - compute that itself. - -MakePinned is gone: - - Need to audit the code now that use DeclareLocal, and that this uses - a differnent code path than the main mcs. - -Need to fix the order in which types are closed: currently we are not -compatible with the MS requirement that the parent has to be created -before the children are. - -Tests and pending features: - - Switch statement is broken (because it uses ILGenerator during - the Resolve phase, which with the `anonymous' branch is no longer - the case: so we have to delay the creation of labels until they - are needed, during the Emit phase). - -Validation: - - For testing, set ec.IG == null during resolve, restore value - for emit. - - Currently it is commented out: there is a bug in the - statement.cs changes (see the old-statement.cs, the compiler - fails during bootstrap) diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/README b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/README deleted file mode 100644 index f7023e675c..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/README +++ /dev/null @@ -1,72 +0,0 @@ -Completion support -================== - - Supported: - - a. to complete members of type `a' - a for types and namespaces - a.W - a for local variables - - Unsupported: - - delegate { FOO. - using statement autocompletion - -These are the sources to the Mono C# compiler ---------------------------------------------- - - Read the mcs/docs/compiler.txt for an overview of the compiler. - -Testing the Compiler --------------------- - - You might want to use the `make btest' in this directory to - have the compiler bootstrap itself, this is the basic regression - test. - - Before commiting changes to MCS, make sure that all the tests - in `mcs/tests' pass, and all the tests in 'mcs/errors' have the - expected result, type: - - cd mcs # The top-level 'mcs' directory - make compiler-tests - - If you want to test the installed compiler, you can run: - - cd mcs # The top-level 'mcs' directory - make test-installed-compiler - -Full Bootstrap -============== - - To finally ensure the state of the compiler, it is ideal to do - a full bootstrap, to do this, do: - - cd mcs - make clean; - make - make install - - That installs the compiler and assemblies compiled by the new compiler. - - Then, repeat that step again: - - make clean - make - - If things work, the compiler has not added a new regression - while building the mscorlib and the compiler itself. - -Tests -===== - - When bugs are fixed, new tests must be added to the - `mcs/tests' directory to excercise the problem and to guarantee - that we keep the compiler in a good state. - - When an error is reported, it should be added to mcs/errors. - - We try to make the errors numbers be the same as the ones in - Microsoft C#, if this is not possible, allocate a negative error - number, and list it in mcs/errors/errors.txt diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/SourceMethodBuilder.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/SourceMethodBuilder.cs new file mode 100644 index 0000000000..1ff399cdcd --- /dev/null +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/SourceMethodBuilder.cs @@ -0,0 +1,193 @@ +// +// SourceMethodBuilder.cs +// +// Authors: +// Martin Baulig (martin@ximian.com) +// Marek Safar (marek.safar@gmail.com) +// +// (C) 2002 Ximian, Inc. http://www.ximian.com +// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com) +// +// Permission is hereby granted, free of charge, to any person obtaining +// a copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to +// permit persons to whom the Software is furnished to do so, subject to +// the following conditions: +// +// The above copyright notice and this permission notice shall be +// included in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +// + +using System.Collections.Generic; + +namespace Mono.CompilerServices.SymbolWriter +{ + public class SourceMethodBuilder + { + List _locals; + List _blocks; + List _scope_vars; +#if NET_2_1 + System.Collections.Stack _block_stack; +#else + Stack _block_stack; +#endif + readonly List method_lines; + + readonly ICompileUnit _comp_unit; + readonly int ns_id; + readonly IMethodDef method; + + public SourceMethodBuilder (ICompileUnit comp_unit) + { + this._comp_unit = comp_unit; + method_lines = new List (); + } + + public SourceMethodBuilder (ICompileUnit comp_unit, int ns_id, IMethodDef method) + : this (comp_unit) + { + this.ns_id = ns_id; + this.method = method; + } + + public void MarkSequencePoint (int offset, SourceFileEntry file, int line, int column, bool is_hidden) + { + int file_idx = file != null ? file.Index : 0; + var lne = new LineNumberEntry (file_idx, line, offset, is_hidden); + + if (method_lines.Count > 0) { + var prev = method_lines[method_lines.Count - 1]; + + // + // Same offset cannot be used for multiple lines + // + if (prev.Offset == offset) { + // + // Use the new location because debugger will adjust + // the breakpoint to next line with sequence point + // + if (LineNumberEntry.LocationComparer.Default.Compare (lne, prev) > 0) + method_lines[method_lines.Count - 1] = lne; + + return; + } + } + + method_lines.Add (lne); + } + + public void StartBlock (CodeBlockEntry.Type type, int start_offset) + { + if (_block_stack == null) { +#if NET_2_1 + _block_stack = new System.Collections.Stack (); +#else + _block_stack = new Stack (); +#endif + } + + if (_blocks == null) + _blocks = new List (); + + int parent = CurrentBlock != null ? CurrentBlock.Index : -1; + + CodeBlockEntry block = new CodeBlockEntry ( + _blocks.Count + 1, parent, type, start_offset); + + _block_stack.Push (block); + _blocks.Add (block); + } + + public void EndBlock (int end_offset) + { + CodeBlockEntry block = (CodeBlockEntry) _block_stack.Pop (); + block.Close (end_offset); + } + + public CodeBlockEntry[] Blocks { + get { + if (_blocks == null) + return new CodeBlockEntry [0]; + + CodeBlockEntry[] retval = new CodeBlockEntry [_blocks.Count]; + _blocks.CopyTo (retval, 0); + return retval; + } + } + + public CodeBlockEntry CurrentBlock { + get { + if ((_block_stack != null) && (_block_stack.Count > 0)) + return (CodeBlockEntry) _block_stack.Peek (); + else + return null; + } + } + + public LocalVariableEntry[] Locals { + get { + if (_locals == null) + return new LocalVariableEntry [0]; + else { + return _locals.ToArray (); + } + } + } + + public ICompileUnit SourceFile { + get { + return _comp_unit; + } + } + + public void AddLocal (int index, string name) + { + if (_locals == null) + _locals = new List (); + int block_idx = CurrentBlock != null ? CurrentBlock.Index : 0; + _locals.Add (new LocalVariableEntry (index, name, block_idx)); + } + + public ScopeVariable[] ScopeVariables { + get { + if (_scope_vars == null) + return new ScopeVariable [0]; + + return _scope_vars.ToArray (); + } + } + + public void AddScopeVariable (int scope, int index) + { + if (_scope_vars == null) + _scope_vars = new List (); + _scope_vars.Add ( + new ScopeVariable (scope, index)); + } + + public void DefineMethod (MonoSymbolFile file) + { + DefineMethod (file, method.Token); + } + + public void DefineMethod (MonoSymbolFile file, int token) + { + MethodEntry entry = new MethodEntry ( + file, _comp_unit.Entry, token, ScopeVariables, + Locals, method_lines.ToArray (), Blocks, null, 0, ns_id); + + file.AddMethod (entry); + } + } +} diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/TODO b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/TODO deleted file mode 100644 index 1abb0382b7..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/TODO +++ /dev/null @@ -1,223 +0,0 @@ -=========================================== - -* Value Parameter - - I believe that `Value Parameter' might have been introduced - after C# 1.0, also notice than in the treatment of Value Parameter - the parameters are defined in four categories: - - Section 9.3 in the latest spec. - - -Large project: --------------- - -New ---- - - It would be nice to optimize the case of: - - Method (new ValueType ()) - - So that no temporary is created, and we only use a newobj call - that remains on the stack, as opposed to ldloca, initobj, ldloc - call. - -NEW NOTES: ----------- - - ImplicitStandardConversionExists and ImplicitStandardConversion - should always be the same, but there are a few diverging lines that - must be studied: - - if (expr_type == target_type && !(expr is NullLiteral)) - return expr; - - vs: - - if (expr_type == target_type) - return true; - -**************************************************************************************** -* -* The information on the rest of this file is mostly outdated, and its kept here for -* historical reasons -* -**************************************************************************************** - -Error Reporting: ----------------- - - * Make yyerror show a nice syntax error, instead of the current mess. - -Optimization ideas ------------------- - - Currently when we build a type cache, it contains private members, - internal members, and internal protected members; We should trim - these out, as it shows up on the profile. - - We create too many Arraylists; When we know the size, we should create - an array; - - During parsing we use arraylists to accumulate data, like this: - - thing: - - thing_list - : thing { $$ =new ArrayList (); $$.Add ($1); } - | thing_list thing { ArrayList a = $1; a.Add ($2); $$ = a; } - - We probably could start using "Pairs" there: - - thing_list - : thing { $$ = new Pair ($1, null); } - | thing_list thing { Pair p = $1; $$ = new Pair ($2, $1); } - - -EmitContext.ResolveTypeTree ---------------------------- - - We should investigate its usage. The problem is that by default - this will be set when calling FindType, that triggers a more expensive - lookup. - - I believe we should pass the current EmitContext (which has this turned off - by default) to ResolveType/REsolveTypeExpr and then have the routines that - need ResolveType to pass null as the emit context. - -DeclareLocal audit ------------------- - - DeclareLocal is used in various statements. The audit should be done - in two steps: - - * Identify all the declare locals. - - * Identify its uses. - - * Find if we can make wrapper functions for all of them. - - Then we can move DeclareLocal into a helper class. - - This is required to fix foreach in iterators. - -Ideas: ------- - - Instead of the hack that *knows* about System.Object not having any children classes, - we should just make it simple for a probe to know that there is no need for it. - -Dead Code Elimination bugs: ---------------------------- - - I should also resolve all the children expressions in Switch, Fixed, Using. - -Major tasks: ------------- - Properties and 17.6.3: Finish it. - -readonly variables and ref/out - -BUGS ----- - -* Break/Continue statements - - A finally block should reset the InLoop/LoopBegin/LoopEnd, as - they are logically outside the scope of the loop. - -* Break/continue part 2. - - They should transfer control to the finally block if inside a try/catch - block. - -* -> // CSC sets beforefieldinit -> class X { -> // .cctor will be generated by compiler -> public static readonly object O = new System.Object (); -> public static void Main () {} -> } -> - -PENDING TASKS -------------- - -* Merge test 89 and test-34 - -* Code cleanup - - The information when registering a method in InternalParameters - is duplicated, you can always get the types from the InternalParameters - -* Emit modreq for volatiles - - Handle modreq from public apis. - -* Merge tree.cs, rootcontext.cs - -OPTIMIZATIONS -------------- - -* User Defined Conversions is doing way too many calls to do union sets that are not needed - -* Add test case for destructors - -* Places that use `Ldelema' are basically places where I will be - initializing a value type. I could apply an optimization to - disable the implicit local temporary from being created (by using - the method in New). - -* Dropping TypeContainer as an argument to EmitContext - - My theory is that I can get rid of the TypeBuilder completely from - the EmitContext, and have typecasts where it is used (from - DeclSpace to where it matters). - - The only pending problem is that the code that implements Aliases - is on TypeContainer, and probably should go in DeclSpace. - -* Tests - - Write tests for the various reference conversions. We have - test for all the numeric conversions. - -* Optimizations: variable allocation. - - When local variables of a type are required, we should request - the variable and later release it when we are done, so that - the same local variable slot can be reused later on. - -* Add a cache for the various GetArrayMethod operations. - -* MakeUnionSet Callers - - If the types are the same, there is no need to compute the unionset, - we can just use the list from one of the types. - -* Factor the lookup code for class declarations an interfaces - (interface.cs:GetInterfaceByName) - -RECOMMENDATIONS ---------------- - -* Use of lexer.Location in the parser - - Currently we do: - - TOKEN nt TERMINAL nt TERMINAL nt3 { - $$ = new Blah ($2, $4, $6, lexer.Location); - } - - This is bad, because the lexer.Location is for the last item in `nt3' - - We need to change that to use this pattern: - - TOKEN { oob_stack.Push (lexer.Location) } nt TERMINAL nt TERMINAL nt3 { - $$ = new Blah ($3, $5, $7, (Location) oob_stack.Pop ()); - } - - Notice how numbering of the arguments changes as the - { oob_stack.Push (lexer.Location) } takes a "slot" in the productions. - diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/anonymous.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/anonymous.cs index a5843ef6ec..7ef97558f8 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/anonymous.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/anonymous.cs @@ -12,6 +12,8 @@ using System; using System.Collections.Generic; +using Mono.CompilerServices.SymbolWriter; +using System.Diagnostics; #if STATIC using IKVM.Reflection; @@ -24,19 +26,37 @@ using System.Reflection.Emit; namespace Mono.CSharp { - public abstract class CompilerGeneratedClass : Class + public abstract class CompilerGeneratedContainer : ClassOrStruct { - protected CompilerGeneratedClass (TypeContainer parent, MemberName name, Modifiers mod) - : base (parent.NamespaceEntry, parent, name, mod | Modifiers.COMPILER_GENERATED, null) + protected CompilerGeneratedContainer (TypeContainer parent, MemberName name, Modifiers mod) + : this (parent, name, mod, MemberKind.Class) { } + protected CompilerGeneratedContainer (TypeContainer parent, MemberName name, Modifiers mod, MemberKind kind) + : base (parent, name, null, kind) + { + Debug.Assert ((mod & Modifiers.AccessibilityMask) != 0); + + ModFlags = mod | Modifiers.COMPILER_GENERATED | Modifiers.SEALED; + spec = new TypeSpec (Kind, null, this, null, ModFlags); + } + protected void CheckMembersDefined () { if (HasMembersDefined) throw new InternalErrorException ("Helper class already defined!"); } + protected override bool DoDefineMembers () + { + if (Kind == MemberKind.Class && !IsStatic && !PartialContainer.HasInstanceConstructor) { + DefineDefaultConstructor (false); + } + + return base.DoDefineMembers (); + } + protected static MemberName MakeMemberName (MemberBase host, string name, int unique_id, TypeParameters tparams, Location loc) { string host_name = host == null ? null : host is InterfaceMemberBase ? ((InterfaceMemberBase)host).GetFullName (host.MemberName) : host.MemberName.Name; @@ -58,9 +78,17 @@ namespace Mono.CSharp { { return "<" + host + ">" + typePrefix + "__" + name + id.ToString ("X"); } + + protected override TypeSpec[] ResolveBaseTypes (out FullNamedExpression base_class) + { + base_type = Compiler.BuiltinTypes.Object; + + base_class = null; + return null; + } } - public class HoistedStoreyClass : CompilerGeneratedClass + public class HoistedStoreyClass : CompilerGeneratedContainer { public sealed class HoistedField : Field { @@ -85,8 +113,8 @@ namespace Mono.CSharp { protected TypeParameterMutator mutator; - public HoistedStoreyClass (TypeContainer parent, MemberName name, TypeParameters tparams, Modifiers mod) - : base (parent, name, mod | Modifiers.PRIVATE) + public HoistedStoreyClass (TypeDefinition parent, MemberName name, TypeParameters tparams, Modifiers mods, MemberKind kind) + : base (parent, name, mods | Modifiers.PRIVATE, kind) { if (tparams != null) { @@ -172,7 +200,7 @@ namespace Mono.CSharp { protected override void DoEmit (EmitContext ec) { - hoisted_this.EmitHoistingAssignment (ec); + hoisted_this.EmitAssign (ec, new CompilerGeneratedThis (ec.CurrentType, loc), false, false); } protected override void CloneTo (CloneContext clonectx, Statement target) @@ -183,9 +211,8 @@ namespace Mono.CSharp { // Unique storey ID public readonly int ID; - static int unique_id; - public readonly Block OriginalSourceBlock; + public readonly ExplicitBlock OriginalSourceBlock; // A list of StoreyFieldPair with local field keeping parent storey instance List used_parent_storeys; @@ -193,6 +220,7 @@ namespace Mono.CSharp { // A list of hoisted parameters protected List hoisted_params; + List hoisted_local_params; protected List hoisted_locals; // Hoisted this @@ -201,29 +229,23 @@ namespace Mono.CSharp { // Local variable which holds this storey instance public Expression Instance; - public AnonymousMethodStorey (Block block, TypeContainer parent, MemberBase host, TypeParameters tparams, string name) - : base (parent, MakeMemberName (host, name, unique_id, tparams, block.StartLocation), - tparams, Modifiers.SEALED) + bool initialize_hoisted_this; + + public AnonymousMethodStorey (ExplicitBlock block, TypeDefinition parent, MemberBase host, TypeParameters tparams, string name, MemberKind kind) + : base (parent, MakeMemberName (host, name, parent.Module.CounterAnonymousContainers, tparams, block.StartLocation), + tparams, 0, kind) { OriginalSourceBlock = block; - ID = unique_id++; + ID = parent.Module.CounterAnonymousContainers++; } public void AddCapturedThisField (EmitContext ec) { TypeExpr type_expr = new TypeExpression (ec.CurrentType, Location); - Field f = AddCompilerGeneratedField ("<>f__this", type_expr); - f.Define (); + Field f = AddCompilerGeneratedField ("$this", type_expr); hoisted_this = new HoistedThis (this, f); - // Inflated type instance has to be updated manually - if (Instance.Type is InflatedTypeSpec) { - var inflator = new TypeParameterInflator (this, Instance.Type, TypeParameterSpec.EmptyTypes, TypeSpec.EmptyTypes); - Instance.Type.MemberCache.AddMember (f.Spec.InflateMember (inflator)); - - inflator = new TypeParameterInflator (this, f.Parent.CurrentType, TypeParameterSpec.EmptyTypes, TypeSpec.EmptyTypes); - f.Parent.CurrentType.MemberCache.AddMember (f.Spec.InflateMember (inflator)); - } + initialize_hoisted_this = true; } public Field AddCapturedVariable (string name, TypeSpec type) @@ -283,38 +305,93 @@ namespace Mono.CSharp { used_parent_storeys.Add (new StoreyFieldPair (storey, f)); } - public void CaptureLocalVariable (ResolveContext ec, LocalVariable local_info) + public void CaptureLocalVariable (ResolveContext ec, LocalVariable localVariable) { - ec.CurrentBlock.Explicit.HasCapturedVariable = true; - if (ec.CurrentBlock.Explicit != local_info.Block.Explicit) - AddReferenceFromChildrenBlock (ec.CurrentBlock.Explicit); + if (this is StateMachine) { + if (ec.CurrentBlock.ParametersBlock != localVariable.Block.ParametersBlock) + ec.CurrentBlock.Explicit.HasCapturedVariable = true; + } else { + ec.CurrentBlock.Explicit.HasCapturedVariable = true; + } - if (local_info.HoistedVariant != null) - return; + var hoisted = localVariable.HoistedVariant; + if (hoisted != null && hoisted.Storey != this && hoisted.Storey.Kind == MemberKind.Struct) { + // TODO: It's too late the field is defined in HoistedLocalVariable ctor + hoisted.Storey.hoisted_locals.Remove (hoisted); + hoisted = null; + } - HoistedVariable var = new HoistedLocalVariable (this, local_info, GetVariableMangledName (local_info)); - local_info.HoistedVariant = var; + if (hoisted == null) { + hoisted = new HoistedLocalVariable (this, localVariable, GetVariableMangledName (localVariable)); + localVariable.HoistedVariant = hoisted; - if (hoisted_locals == null) - hoisted_locals = new List (); + if (hoisted_locals == null) + hoisted_locals = new List (); - hoisted_locals.Add (var); + hoisted_locals.Add (hoisted); + } + + if (ec.CurrentBlock.Explicit != localVariable.Block.Explicit) + hoisted.Storey.AddReferenceFromChildrenBlock (ec.CurrentBlock.Explicit); } - public void CaptureParameter (ResolveContext ec, ParameterReference param_ref) + public void CaptureParameter (ResolveContext ec, ParametersBlock.ParameterInfo parameterInfo, ParameterReference parameterReference) { - ec.CurrentBlock.Explicit.HasCapturedVariable = true; - AddReferenceFromChildrenBlock (ec.CurrentBlock.Explicit); + if (!(this is StateMachine)) { + ec.CurrentBlock.Explicit.HasCapturedVariable = true; + } - if (param_ref.GetHoistedVariable (ec) != null) - return; + var hoisted = parameterInfo.Parameter.HoistedVariant; + + if (parameterInfo.Block.StateMachine is AsyncTaskStorey) { + // + // Another storey in same block exists but state machine does not + // have parameter captured. We need to add it there as well to + // proxy parameter value correctly. + // + if (hoisted == null && parameterInfo.Block.StateMachine != this) { + var storey = parameterInfo.Block.StateMachine; + + hoisted = new HoistedParameter (storey, parameterReference); + parameterInfo.Parameter.HoistedVariant = hoisted; + + if (storey.hoisted_params == null) + storey.hoisted_params = new List (); + + storey.hoisted_params.Add (hoisted); + } + + // + // Lift captured parameter from value type storey to reference type one. Otherwise + // any side effects would be done on a copy + // + if (hoisted != null && hoisted.Storey != this && hoisted.Storey.Kind == MemberKind.Struct) { + if (hoisted_local_params == null) + hoisted_local_params = new List (); + + hoisted_local_params.Add (hoisted); + hoisted = null; + } + } + + if (hoisted == null) { + hoisted = new HoistedParameter (this, parameterReference); + parameterInfo.Parameter.HoistedVariant = hoisted; - if (hoisted_params == null) - hoisted_params = new List (2); + if (hoisted_params == null) + hoisted_params = new List (); + + hoisted_params.Add (hoisted); + } - var expr = new HoistedParameter (this, param_ref); - param_ref.Parameter.HoistedVariant = expr; - hoisted_params.Add (expr); + // + // Register link between current block and parameter storey. It will + // be used when setting up storey definition to deploy storey reference + // when parameters are used from multiple blocks + // + if (ec.CurrentBlock.Explicit != parameterInfo.Block) { + hoisted.Storey.AddReferenceFromChildrenBlock (ec.CurrentBlock.Explicit); + } } TypeExpr CreateStoreyTypeExpression (EmitContext ec) @@ -398,8 +475,6 @@ namespace Mono.CSharp { if (Instance != null) throw new InternalErrorException (); - SymbolWriter.OpenCompilerGeneratedBlock (ec); - // // Create an instance of this storey // @@ -428,11 +503,14 @@ namespace Mono.CSharp { var fexpr = new FieldExpr (field, Location); fexpr.InstanceExpression = new CompilerGeneratedThis (ec.CurrentType, Location); fexpr.EmitAssign (ec, source, false, false); - Instance = fexpr; } else { var local = TemporaryVariableReference.Create (source.Type, block, Location); - local.EmitAssign (ec, source); + if (source.Type.IsStruct) { + local.LocalInfo.CreateBuilder (ec); + } else { + local.EmitAssign (ec, source); + } Instance = local; } @@ -441,8 +519,6 @@ namespace Mono.CSharp { // TODO: Implement properly //SymbolWriter.DefineScopeVariable (ID, Instance.Builder); - - SymbolWriter.CloseCompilerGeneratedBlock (ec); } void EmitHoistedFieldsInitialization (ResolveContext rc, EmitContext ec) @@ -463,6 +539,7 @@ namespace Mono.CSharp { FieldExpr f_set_expr = new FieldExpr (fs, Location); f_set_expr.InstanceExpression = instace_expr; + // TODO: CompilerAssign expression SimpleAssign a = new SimpleAssign (f_set_expr, sf.Storey.GetStoreyInstanceExpression (ec)); if (a.Resolve (rc) != null) a.EmitStatement (ec); @@ -470,10 +547,10 @@ namespace Mono.CSharp { } // - // Define hoisted `this' in top-level storey only + // Initialize hoisted `this' only once, everywhere else will be + // referenced indirectly // - if (OriginalSourceBlock.Explicit.HasCapturedThis && !(Parent is AnonymousMethodStorey)) { - AddCapturedThisField (ec); + if (initialize_hoisted_this) { rc.CurrentBlock.AddScopeStatement (new ThisInitializer (hoisted_this)); } @@ -490,37 +567,22 @@ namespace Mono.CSharp { ec.CurrentAnonymousMethod = ae; } - protected virtual void EmitHoistedParameters (EmitContext ec, IList hoisted) + protected virtual void EmitHoistedParameters (EmitContext ec, List hoisted) { foreach (HoistedParameter hp in hoisted) { - hp.EmitHoistingAssignment (ec); - } - } - - public override void EmitType () - { - SymbolWriter.DefineAnonymousScope (ID); - - if (hoisted_this != null) - hoisted_this.EmitSymbolInfo (); - - if (hoisted_locals != null) { - foreach (HoistedVariable local in hoisted_locals) - local.EmitSymbolInfo (); - } - - if (hoisted_params != null) { - foreach (HoistedParameter param in hoisted_params) - param.EmitSymbolInfo (); - } - - if (used_parent_storeys != null) { - foreach (StoreyFieldPair sf in used_parent_storeys) { - SymbolWriter.DefineCapturedScope (ID, sf.Storey.ID, sf.Field.Name); + // + // Parameters could be proxied via local fields for value type storey + // + if (hoisted_local_params != null) { + var local_param = hoisted_local_params.Find (l => l.Parameter.Parameter == hp.Parameter.Parameter); + var source = new FieldExpr (local_param.Field, Location); + source.InstanceExpression = new CompilerGeneratedThis (CurrentType, Location); + hp.EmitAssign (ec, source, false, false); + continue; } - } - base.EmitType (); + hp.EmitHoistingAssignment (ec); + } } // @@ -591,17 +653,17 @@ namespace Mono.CSharp { } public HoistedThis HoistedThis { - get { return hoisted_this; } + get { + return hoisted_this; + } + set { + hoisted_this = value; + } } public IList ReferencesFromChildrenBlock { get { return children_references; } } - - public static void Reset () - { - unique_id = 0; - } } public abstract class HoistedVariable @@ -664,6 +726,12 @@ namespace Mono.CSharp { this.field = field; } + public AnonymousMethodStorey Storey { + get { + return storey; + } + } + public void AddressOf (EmitContext ec, AddressOp mode) { GetFieldExpression (ec).AddressOf (ec, mode); @@ -732,8 +800,6 @@ namespace Mono.CSharp { return inner_access; } - public abstract void EmitSymbolInfo (); - public void Emit (EmitContext ec, bool leave_copy) { GetFieldExpression (ec).Emit (ec, leave_copy); @@ -747,7 +813,7 @@ namespace Mono.CSharp { public class HoistedParameter : HoistedVariable { - sealed class HoistedFieldAssign : Assign + sealed class HoistedFieldAssign : CompilerAssign { public HoistedFieldAssign (Expression target, Expression source) : base (target, source, source.Location) @@ -778,52 +844,42 @@ namespace Mono.CSharp { this.parameter = hp.parameter; } + #region Properties + + public Field Field { + get { + return field; + } + } + + public ParameterReference Parameter { + get { + return parameter; + } + } + + #endregion + public void EmitHoistingAssignment (EmitContext ec) { // // Remove hoisted redirection to emit assignment from original parameter // - HoistedVariable temp = parameter.Parameter.HoistedVariant; + var temp = parameter.Parameter.HoistedVariant; parameter.Parameter.HoistedVariant = null; - Assign a = new HoistedFieldAssign (GetFieldExpression (ec), parameter); - if (a.Resolve (new ResolveContext (ec.MemberContext)) != null) - a.EmitStatement (ec); + var a = new HoistedFieldAssign (GetFieldExpression (ec), parameter); + a.EmitStatement (ec); parameter.Parameter.HoistedVariant = temp; } - - public override void EmitSymbolInfo () - { - SymbolWriter.DefineCapturedParameter (storey.ID, field.Name, field.Name); - } - - public Field Field { - get { return field; } - } } class HoistedLocalVariable : HoistedVariable { - readonly string name; - public HoistedLocalVariable (AnonymousMethodStorey storey, LocalVariable local, string name) : base (storey, name, local.Type) { - this.name = local.Name; - } - - // - // For compiler generated local variables - // - public HoistedLocalVariable (AnonymousMethodStorey storey, Field field) - : base (storey, field) - { - } - - public override void EmitSymbolInfo () - { - SymbolWriter.DefineCapturedLocal (storey.ID, name, field.Name); } } @@ -834,20 +890,10 @@ namespace Mono.CSharp { { } - public void EmitHoistingAssignment (EmitContext ec) - { - SimpleAssign a = new SimpleAssign (GetFieldExpression (ec), new CompilerGeneratedThis (ec.CurrentType, field.Location)); - if (a.Resolve (new ResolveContext (ec.MemberContext)) != null) - a.EmitStatement (ec); - } - - public override void EmitSymbolInfo () - { - SymbolWriter.DefineCapturedThis (storey.ID, field.Name); - } - public Field Field { - get { return field; } + get { + return field; + } } } @@ -1045,16 +1091,10 @@ namespace Mono.CSharp { return false; for (int i = 0; i < Parameters.Count; ++i) { - TypeSpec itype = d_params.Types [i]; - if (!TypeManager.IsGenericParameter (itype)) { - if (!TypeManager.HasElementType (itype)) - continue; - - if (!TypeManager.IsGenericParameter (TypeManager.GetElementType (itype))) - continue; - } - type_inference.ExactInference (Parameters.Types [i], itype); + if (type_inference.ExactInference (Parameters.Types[i], d_params.Types[i]) == 0) + return false; } + return true; } @@ -1069,12 +1109,8 @@ namespace Mono.CSharp { } using (ec.Set (ResolveContext.Options.ProbingMode | ResolveContext.Options.InferReturnType)) { - var body = CompatibleMethodBody (ec, tic, InternalType.Arglist, delegate_type); + var body = CompatibleMethodBody (ec, tic, null, delegate_type); if (body != null) { - if (Block.IsAsync) { - AsyncInitializer.Create (ec, body.Block, body.Parameters, ec.CurrentMemberDefinition.Parent, null, loc); - } - am = body.Compatible (ec, body); } else { am = null; @@ -1146,6 +1182,10 @@ namespace Mono.CSharp { } else { int errors = ec.Report.Errors; + if (Block.IsAsync) { + ec.Report.Error (1989, loc, "Async lambda expressions cannot be converted to expression trees"); + } + using (ec.Set (ResolveContext.Options.ExpressionTreeConversion)) { am = body.Compatible (ec); } @@ -1157,22 +1197,12 @@ namespace Mono.CSharp { am = CreateExpressionTree (ec, delegate_type); } } else { - if (Block.IsAsync) { - var rt = body.ReturnType; - if (rt.Kind != MemberKind.Void && - rt != ec.Module.PredefinedTypes.Task.TypeSpec && - !rt.IsGenericTask) { - ec.Report.Error (4010, loc, "Cannot convert async {0} to delegate type `{1}'", - GetSignatureForError (), type.GetSignatureForError ()); - } - - AsyncInitializer.Create (ec, body.Block, body.Parameters, ec.CurrentMemberDefinition.Parent, rt, loc); - } - am = body.Compatible (ec); } } catch (CompletionResult) { throw; + } catch (FatalException) { + throw; } catch (Exception e) { throw new InternalErrorException (e, loc); } @@ -1207,7 +1237,7 @@ namespace Mono.CSharp { for (int i = 0; i < delegate_parameters.Count; i++) { Parameter.Modifier i_mod = delegate_parameters.FixedParameters [i].ModFlags; - if (i_mod == Parameter.Modifier.OUT) { + if ((i_mod & Parameter.Modifier.OUT) != 0) { if (!ec.IsInProbingMode) { ec.Report.Error (1688, loc, "Cannot convert anonymous method block without a parameter list to delegate type `{0}' because it has one or more `out' parameters", @@ -1294,7 +1324,19 @@ namespace Mono.CSharp { ParametersBlock b = ec.IsInProbingMode ? (ParametersBlock) Block.PerformClone () : Block; - return CompatibleMethodFactory (return_type, delegate_type, p, b); + if (b.IsAsync) { + var rt = return_type; + if (rt != null && rt.Kind != MemberKind.Void && rt != ec.Module.PredefinedTypes.Task.TypeSpec && !rt.IsGenericTask) { + ec.Report.Error (4010, loc, "Cannot convert async {0} to delegate type `{1}'", + GetSignatureForError (), delegate_type.GetSignatureForError ()); + + return null; + } + + b = b.ConvertToAsyncTask (ec, ec.CurrentMemberDefinition.Parent.PartialContainer, p, return_type, loc); + } + + return CompatibleMethodFactory (return_type ?? InternalType.Arglist, delegate_type, p, b); } protected virtual AnonymousMethodBody CompatibleMethodFactory (TypeSpec return_type, TypeSpec delegate_type, ParametersCompiled p, ParametersBlock b) @@ -1324,26 +1366,24 @@ namespace Mono.CSharp { { public readonly AnonymousExpression AnonymousMethod; public readonly AnonymousMethodStorey Storey; - readonly string RealName; - public AnonymousMethodMethod (TypeContainer parent, AnonymousExpression am, AnonymousMethodStorey storey, + public AnonymousMethodMethod (TypeDefinition parent, AnonymousExpression am, AnonymousMethodStorey storey, TypeExpr return_type, - Modifiers mod, string real_name, MemberName name, + Modifiers mod, MemberName name, ParametersCompiled parameters) : base (parent, return_type, mod | Modifiers.COMPILER_GENERATED, name, parameters, null) { this.AnonymousMethod = am; this.Storey = storey; - this.RealName = real_name; - Parent.PartialContainer.AddMethod (this); + Parent.PartialContainer.Members.Add (this); Block = new ToplevelBlock (am.block, parameters); } - public override EmitContext CreateEmitContext (ILGenerator ig) + public override EmitContext CreateEmitContext (ILGenerator ig, SourceMethodBuilder sourceMethod) { - EmitContext ec = new EmitContext (this, ig, ReturnType); + EmitContext ec = new EmitContext (this, ig, ReturnType, sourceMethod); ec.CurrentAnonymousMethod = AnonymousMethod; return ec; } @@ -1379,11 +1419,6 @@ namespace Mono.CSharp { base.Emit (); } - - public override void EmitExtraSymbolInfo (SourceMethod source) - { - source.SetRealMethodName (RealName); - } } protected ParametersBlock block; @@ -1401,6 +1436,15 @@ namespace Mono.CSharp { public abstract bool IsIterator { get; } public abstract AnonymousMethodStorey Storey { get; } + // + // The block that makes up the body for the anonymous method + // + public ParametersBlock Block { + get { + return block; + } + } + public AnonymousExpression Compatible (ResolveContext ec) { return Compatible (ec, this); @@ -1474,16 +1518,6 @@ namespace Mono.CSharp { b = b.Parent == null ? null : b.Parent.Explicit; } while (b != null); } - - // - // The block that makes up the body for the anonymous method - // - public ParametersBlock Block { - get { - return block; - } - } - } public class AnonymousMethodBody : AnonymousExpression @@ -1496,8 +1530,6 @@ namespace Mono.CSharp { string block_name; TypeInferenceContext return_inference; - static int unique_id; - public AnonymousMethodBody (ParametersCompiled parameters, ParametersBlock block, TypeSpec return_type, TypeSpec delegate_type, Location loc) @@ -1573,21 +1605,50 @@ namespace Mono.CSharp { // Modifiers modifiers; - if (Block.HasCapturedVariable || Block.HasCapturedThis) { - storey = FindBestMethodStorey (); + TypeDefinition parent = null; + + var src_block = Block.Original.Explicit; + if (src_block.HasCapturedVariable || src_block.HasCapturedThis) { + parent = storey = FindBestMethodStorey (); + + if (storey == null) { + var sm = src_block.ParametersBlock.TopBlock.StateMachine; + + // + // Remove hoisted this demand when simple instance method is enough + // + if (src_block.HasCapturedThis) { + src_block.ParametersBlock.TopBlock.RemoveThisReferenceFromChildrenBlock (src_block); + + // + // Special case where parent class is used to emit instance method + // because currect storey is of value type (async host) and we don't + // want to create another childer storey to host this reference only + // + if (sm != null && sm.Kind == MemberKind.Struct) + parent = sm.Parent.PartialContainer; + } + + // + // For iterators we can host everything in one class + // + if (sm is IteratorStorey) + parent = storey = sm; + } + modifiers = storey != null ? Modifiers.INTERNAL : Modifiers.PRIVATE; } else { if (ec.CurrentAnonymousMethod != null) - storey = ec.CurrentAnonymousMethod.Storey; + parent = storey = ec.CurrentAnonymousMethod.Storey; modifiers = Modifiers.STATIC | Modifiers.PRIVATE; } - TypeContainer parent = storey != null ? storey : ec.CurrentTypeDefinition.Parent.PartialContainer; + if (parent == null) + parent = ec.CurrentTypeDefinition.Parent.PartialContainer; - MemberCore mc = ec.MemberContext as MemberCore; - string name = CompilerGeneratedClass.MakeName (parent != storey ? block_name : null, - "m", null, unique_id++); + string name = CompilerGeneratedContainer.MakeName (parent != storey ? block_name : null, + "m", null, ec.Module.CounterAnonymousMethods++); MemberName member_name; if (storey == null && ec.CurrentTypeParameters != null) { @@ -1603,13 +1664,9 @@ namespace Mono.CSharp { member_name = new MemberName (name, Location); } - string real_name = String.Format ( - "{0}~{1}{2}", mc.GetSignatureForError (), GetSignatureForError (), - parameters.GetSignatureForError ()); - return new AnonymousMethodMethod (parent, this, storey, new TypeExpression (ReturnType, Location), modifiers, - real_name, member_name, parameters); + member_name, parameters); } protected override Expression DoResolve (ResolveContext ec) @@ -1642,13 +1699,13 @@ namespace Mono.CSharp { // Creates a field cache to store delegate instance if it's not generic // if (!method.MemberName.IsGeneric) { - TypeContainer parent = method.Parent.PartialContainer; - int id = parent.Fields == null ? 0 : parent.Fields.Count; + var parent = method.Parent.PartialContainer; + int id = parent.AnonymousMethodsCounter++; var cache_type = storey != null && storey.Mutator != null ? storey.Mutator.Mutate (type) : type; am_cache = new Field (parent, new TypeExpression (cache_type, loc), Modifiers.STATIC | Modifiers.PRIVATE | Modifiers.COMPILER_GENERATED, - new MemberName (CompilerGeneratedClass.MakeName (null, "f", "am$cache", id), loc), null); + new MemberName (CompilerGeneratedContainer.MakeName (null, "f", "am$cache", id), loc), null); am_cache.Define (); parent.AddField (am_cache); } else { @@ -1688,10 +1745,22 @@ namespace Mono.CSharp { ec.EmitNull (); } else if (storey != null) { Expression e = storey.GetStoreyInstanceExpression (ec).Resolve (new ResolveContext (ec.MemberContext)); - if (e != null) + if (e != null) { e.Emit (ec); + } } else { ec.EmitThis (); + + // + // Special case for value type storey where this is not lifted but + // droped off to parent class + // + for (var b = Block.Parent; b != null; b = b.Parent) { + if (b.ParametersBlock.StateMachine != null) { + ec.Emit (OpCodes.Ldfld, b.ParametersBlock.StateMachine.HoistedThis.Field.Spec); + break; + } + } } var delegate_method = method.Spec; @@ -1702,9 +1771,7 @@ namespace Mono.CSharp { // Mutate anonymous method instance type if we are in nested // hoisted generic anonymous method storey // - if (ec.CurrentAnonymousMethod != null && - ec.CurrentAnonymousMethod.Storey != null && - ec.CurrentAnonymousMethod.Storey.Mutator != null) { + if (ec.IsAnonymousStoreyMutateRequired) { t = storey.Mutator.Mutate (t); } @@ -1752,33 +1819,27 @@ namespace Mono.CSharp { { return TypeManager.CSharpName (type); } - - public static void Reset () - { - unique_id = 0; - } } // // Anonymous type container // - public class AnonymousTypeClass : CompilerGeneratedClass + public class AnonymousTypeClass : CompilerGeneratedContainer { - static int types_counter; public const string ClassNamePrefix = "<>__AnonType"; public const string SignatureForError = "anonymous type"; readonly IList parameters; - private AnonymousTypeClass (TypeContainer parent, MemberName name, IList parameters, Location loc) - : base (parent, name, (parent.Module.Evaluator != null ? Modifiers.PUBLIC : 0) | Modifiers.SEALED) + private AnonymousTypeClass (ModuleContainer parent, MemberName name, IList parameters, Location loc) + : base (parent, name, parent.Evaluator != null ? Modifiers.PUBLIC : Modifiers.INTERNAL) { this.parameters = parameters; } public static AnonymousTypeClass Create (TypeContainer parent, IList parameters, Location loc) { - string name = ClassNamePrefix + types_counter++; + string name = ClassNamePrefix + parent.Module.CounterAnonymousTypes++; ParametersCompiled all_parameters; TypeParameters tparams = null; @@ -1817,21 +1878,20 @@ namespace Mono.CSharp { // Create generic anonymous type host with generic arguments // named upon properties names // - AnonymousTypeClass a_type = new AnonymousTypeClass (parent.NamespaceEntry.SlaveDeclSpace, - new MemberName (name, tparams, loc), parameters, loc); + AnonymousTypeClass a_type = new AnonymousTypeClass (parent.Module, new MemberName (name, tparams, loc), parameters, loc); Constructor c = new Constructor (a_type, name, Modifiers.PUBLIC | Modifiers.DEBUGGER_HIDDEN, null, all_parameters, loc); c.Block = new ToplevelBlock (parent.Module.Compiler, c.ParameterInfo, loc); // - // Create fields and contructor body with field initialization + // Create fields and constructor body with field initialization // bool error = false; for (int i = 0; i < parameters.Count; ++i) { AnonymousTypeParameter p = parameters [i]; - Field f = new Field (a_type, t_args [i], Modifiers.PRIVATE | Modifiers.READONLY, + Field f = new Field (a_type, t_args [i], Modifiers.PRIVATE | Modifiers.READONLY | Modifiers.DEBUGGER_HIDDEN, new MemberName ("<" + p.Name + ">", p.Location), null); if (!a_type.AddField (f)) { @@ -1851,7 +1911,7 @@ namespace Mono.CSharp { new MemberName (p.Name, p.Location), null); prop.Get = new Property.GetMethod (prop, 0, null, p.Location); prop.Get.Block = get_block; - a_type.AddProperty (prop); + a_type.AddMember (prop); } if (error) @@ -1861,30 +1921,6 @@ namespace Mono.CSharp { return a_type; } - public static void Reset () - { - types_counter = 0; - } - - protected override bool AddToContainer (MemberCore symbol, string name) - { - MemberCore mc = GetDefinition (name); - - if (mc == null) { - defined_names.Add (name, symbol); - return true; - } - - // A conflict between anonymous type members will be reported - if (symbol is TypeParameter) { - Report.SymbolRelatedToPreviousError (symbol); - return false; - } - - // Ignore other conflicts - return true; - } - protected override bool DoDefineMembers () { if (!base.DoDefineMembers ()) @@ -1931,7 +1967,7 @@ namespace Mono.CSharp { Expression rs_hashcode = new IntConstant (Compiler.BuiltinTypes, -2128831035, loc); for (int i = 0; i < parameters.Count; ++i) { var p = parameters [i]; - var f = Fields [i]; + var f = (Field) Members [i * 2]; MemberAccess equality_comparer = new MemberAccess (new MemberAccess ( system_collections_generic, "EqualityComparer", @@ -2008,7 +2044,7 @@ namespace Mono.CSharp { equals.Block = equals_block; equals.Define (); - AddMethod (equals); + Members.Add (equals); // // GetHashCode () override @@ -2062,7 +2098,7 @@ namespace Mono.CSharp { hashcode_block.AddStatement (new Return (hash_variable, loc)); hashcode.Block = hashcode_top; hashcode.Define (); - AddMethod (hashcode); + Members.Add (hashcode); // // ToString () override @@ -2072,7 +2108,7 @@ namespace Mono.CSharp { tostring_block.AddStatement (new Return (string_concat, loc)); tostring.Block = tostring_block; tostring.Define (); - AddMethod (tostring); + Members.Add (tostring); return true; } @@ -2082,6 +2118,11 @@ namespace Mono.CSharp { return SignatureForError; } + public override CompilationSourceFile GetCompilationSourceFile () + { + return null; + } + public IList Parameters { get { return parameters; diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/argument.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/argument.cs index a6fa8bd843..9da98b8a80 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/argument.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/argument.cs @@ -120,10 +120,14 @@ namespace Mono.CSharp ml.AddressOf (ec, mode); } - public Argument EmitToField (EmitContext ec) + public Argument EmitToField (EmitContext ec, bool cloneResult) { var res = Expr.EmitToField (ec); - return res == Expr ? this : new Argument (res, ArgType); + if (cloneResult && res != Expr) + return new Argument (res, ArgType); + + Expr = res; + return this; } public string GetSignatureForError () @@ -258,7 +262,7 @@ namespace Mono.CSharp { foreach (var a in ordered) { if (prepareAwait) - a.EmitToField (ec); + a.EmitToField (ec, false); else a.EmitToVariable (ec); } @@ -440,7 +444,7 @@ namespace Mono.CSharp LocalTemporary lt; foreach (Argument a in args) { if (prepareAwait) { - dups.Add (a.EmitToField (ec)); + dups.Add (a.EmitToField (ec, true)); continue; } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/assembly.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/assembly.cs index 2e25ab7ca4..1cdbf45187 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/assembly.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/assembly.cs @@ -50,7 +50,7 @@ namespace Mono.CSharp // TODO: make it private and move all builder based methods here public AssemblyBuilder Builder; protected AssemblyBuilderExtension builder_extra; - MonoSymbolWriter symbol_writer; + MonoSymbolFile symbol_writer; bool is_cls_compliant; bool wrap_non_exception_throws; @@ -179,6 +179,12 @@ namespace Mono.CSharp } } + public MonoSymbolFile SymbolWriter { + get { + return symbol_writer; + } + } + #endregion public void AddModule (ImportedModuleDefinition module) @@ -437,8 +443,8 @@ namespace Mono.CSharp { if (Compiler.Settings.Target == Target.Module) { module_target_attrs = new AssemblyAttributesPlaceholder (module, name); - module_target_attrs.CreateType (); - module_target_attrs.DefineType (); + module_target_attrs.CreateContainer (); + module_target_attrs.DefineContainer (); module_target_attrs.Define (); module.AddCompilerGeneratedClass (module_target_attrs); } else if (added_modules != null) { @@ -446,18 +452,10 @@ namespace Mono.CSharp } if (Compiler.Settings.GenerateDebugInfo) { - symbol_writer = new MonoSymbolWriter (file_name); - - // Register all source files with symbol writer - foreach (var source in Compiler.SourceFiles) { - source.DefineSymbolInfo (symbol_writer); - } - - // TODO: global variables - SymbolWriter.symwriter = symbol_writer; + symbol_writer = new MonoSymbolFile (); } - module.Emit (); + module.EmitContainer (); if (module.HasExtensionMethod) { var pa = module.PredefinedAttributes.Extension; @@ -484,12 +482,7 @@ namespace Mono.CSharp Builder.__AddDeclarativeSecurity (entry); } #else - var args = new PermissionSet[3]; -#pragma warning disable 618 - declarative_security.TryGetValue (SecurityAction.RequestMinimum, out args[0]); - declarative_security.TryGetValue (SecurityAction.RequestOptional, out args[1]); - declarative_security.TryGetValue (SecurityAction.RequestRefuse, out args[2]); - builder_extra.AddPermissionRequests (args); + throw new NotSupportedException ("Assembly-level security"); #endif } @@ -791,25 +784,38 @@ namespace Mono.CSharp public void Save () { - PortableExecutableKinds pekind; + PortableExecutableKinds pekind = PortableExecutableKinds.ILOnly; ImageFileMachine machine; switch (Compiler.Settings.Platform) { case Platform.X86: - pekind = PortableExecutableKinds.Required32Bit | PortableExecutableKinds.ILOnly; + pekind |= PortableExecutableKinds.Required32Bit; machine = ImageFileMachine.I386; break; case Platform.X64: - pekind = PortableExecutableKinds.ILOnly; + pekind |= PortableExecutableKinds.PE32Plus; machine = ImageFileMachine.AMD64; break; case Platform.IA64: - pekind = PortableExecutableKinds.ILOnly; machine = ImageFileMachine.IA64; break; + case Platform.AnyCPU32Preferred: +#if STATIC + pekind |= PortableExecutableKinds.Preferred32Bit; + machine = ImageFileMachine.I386; + break; +#else + throw new NotSupportedException (); +#endif + case Platform.Arm: +#if STATIC + machine = ImageFileMachine.ARM; + break; +#else + throw new NotSupportedException (); +#endif case Platform.AnyCPU: default: - pekind = PortableExecutableKinds.ILOnly; machine = ImageFileMachine.I386; break; } @@ -830,7 +836,21 @@ namespace Mono.CSharp if (symbol_writer != null && Compiler.Report.Errors == 0) { // TODO: it should run in parallel Compiler.TimeReporter.Start (TimeReporter.TimerType.DebugSave); - symbol_writer.WriteSymbolFile (SymbolWriter.GetGuid (module.Builder)); + + var filename = file_name + ".mdb"; + try { + // We mmap the file, so unlink the previous version since it may be in use + File.Delete (filename); + } catch { + // We can safely ignore + } + + module.WriteDebugSymbol (symbol_writer); + + using (FileStream fs = new FileStream (filename, FileMode.Create, FileAccess.Write)) { + symbol_writer.CreateSymbolFile (module.Builder.ModuleVersionId, fs); + } + Compiler.TimeReporter.Stop (TimeReporter.TimerType.DebugSave); } } @@ -990,7 +1010,7 @@ namespace Mono.CSharp // // A placeholder class for assembly attributes when emitting module // - class AssemblyAttributesPlaceholder : CompilerGeneratedClass + class AssemblyAttributesPlaceholder : CompilerGeneratedContainer { static readonly string TypeNamePrefix = "<$AssemblyAttributes${0}>"; public static readonly string AssemblyFieldName = "attributes"; @@ -998,7 +1018,7 @@ namespace Mono.CSharp Field assembly; public AssemblyAttributesPlaceholder (ModuleContainer parent, string outputName) - : base (parent, new MemberName (GetGeneratedName (outputName)), Modifiers.STATIC) + : base (parent, new MemberName (GetGeneratedName (outputName)), Modifiers.STATIC | Modifiers.INTERNAL) { assembly = new Field (this, new TypeExpression (parent.Compiler.BuiltinTypes.Object, Location), Modifiers.PUBLIC | Modifiers.STATIC, new MemberName (AssemblyFieldName), null); diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/assign.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/assign.cs index 4fc2e6e9a4..673d586d10 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/assign.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/assign.cs @@ -343,7 +343,7 @@ namespace Mono.CSharp { type = target_type; if (!(target is IAssignMethod)) { - Error_ValueAssignment (ec, source); + target.Error_ValueAssignment (ec, source); return null; } @@ -357,7 +357,7 @@ namespace Mono.CSharp { return this; } -#if NET_4_0 +#if NET_4_0 || MONODROID public override System.Linq.Expressions.Expression MakeExpression (BuilderContext ctx) { var tassign = target as IDynamicAssign; @@ -488,6 +488,10 @@ namespace Mono.CSharp { public CompilerAssign (Expression target, Expression source, Location loc) : base (target, source, loc) { + if (target.Type != null) { + type = target.Type; + eclass = ExprClass.Value; + } } protected override Expression DoResolve (ResolveContext ec) @@ -565,7 +569,18 @@ namespace Mono.CSharp { { if (resolved == null) return; - + + // + // Emit sequence symbol info even if we are in compiler generated + // block to allow debugging field initializers when constructor is + // compiler generated + // + if (ec.HasSet (BuilderContext.Options.OmitDebugInfo) && ec.HasMethodSymbolBuilder) { + using (ec.With (BuilderContext.Options.OmitDebugInfo, false)) { + ec.Mark (loc); + } + } + if (resolved != this) resolved.EmitStatement (ec); else @@ -811,7 +826,7 @@ namespace Mono.CSharp { return new SimpleAssign (target, new DynamicConversion (target_type, CSharpBinderFlags.ConvertExplicit, arg, loc), loc).Resolve (ec); } - right.Error_ValueCannotBeConverted (ec, loc, target_type, false); + right.Error_ValueCannotBeConverted (ec, target_type, false); return null; } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/async.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/async.cs index 032a47f709..4c0cce6127 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/async.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/async.cs @@ -46,6 +46,12 @@ namespace Mono.CSharp } } + public AwaitStatement Statement { + get { + return stmt; + } + } + protected override void CloneTo (CloneContext clonectx, Expression target) { var t = (Await) target; @@ -70,11 +76,6 @@ namespace Mono.CSharp "The `await' operator cannot be used in the body of a lock statement"); } - if (rc.HasSet (ResolveContext.Options.ExpressionTreeConversion)) { - rc.Report.Error (1989, loc, "An expression tree cannot contain an await operator"); - return null; - } - if (rc.IsUnsafe) { rc.Report.Error (4004, loc, "The `await' operator cannot be used in an unsafe context"); @@ -94,7 +95,10 @@ namespace Mono.CSharp public override void Emit (EmitContext ec) { stmt.EmitPrologue (ec); - stmt.Emit (ec); + + using (ec.With (BuilderContext.Options.OmitDebugInfo, true)) { + stmt.Emit (ec); + } } public override Expression EmitToField (EmitContext ec) @@ -121,7 +125,7 @@ namespace Mono.CSharp } } - class AwaitStatement : YieldStatement + public class AwaitStatement : YieldStatement { sealed class AwaitableMemberAccess : MemberAccess { @@ -137,7 +141,13 @@ namespace Mono.CSharp protected override void Error_OperatorCannotBeApplied (ResolveContext rc, TypeSpec type) { - rc.Report.Error (4001, loc, "Cannot await `{0}' expression", type.GetSignatureForError ()); + var invocation = LeftExpression as Invocation; + if (invocation != null && invocation.MethodGroup != null && (invocation.MethodGroup.BestCandidate.Modifiers & Modifiers.ASYNC) != 0) { + rc.Report.Error (4008, loc, "Cannot await void method `{0}'. Consider changing method return type to `Task'", + invocation.GetSignatureForError ()); + } else { + rc.Report.Error (4001, loc, "Cannot await `{0}' expression", type.GetSignatureForError ()); + } } } @@ -158,7 +168,6 @@ namespace Mono.CSharp Field awaiter; PropertySpec is_completed; - MethodSpec on_completed; MethodSpec get_result; TypeSpec type; TypeSpec result_type; @@ -176,12 +185,6 @@ namespace Mono.CSharp } } - public TypeSpec Type { - get { - return type; - } - } - public TypeSpec ResultType { get { return result_type; @@ -216,6 +219,8 @@ namespace Mono.CSharp public void EmitPrologue (EmitContext ec) { + awaiter = ((AsyncTaskStorey) machine_initializer.Storey).AddAwaiter (expr.Type, loc); + var fe_awaiter = new FieldExpr (awaiter, loc); fe_awaiter.InstanceExpression = new CompilerGeneratedThis (ec.CurrentType, loc); @@ -233,6 +238,10 @@ namespace Mono.CSharp Arguments dargs = new Arguments (1); dargs.Add (new Argument (fe_awaiter)); completed_expr = new DynamicMemberBinder ("IsCompleted", dargs, loc).Resolve (rc); + + dargs = new Arguments (1); + dargs.Add (new Argument (completed_expr)); + completed_expr = new DynamicConversion (ec.Module.Compiler.BuiltinTypes.Bool, 0, dargs, loc).Resolve (rc); } else { var pe = PropertyExpr.CreatePredefined (is_completed, loc); pe.InstanceExpression = fe_awaiter; @@ -255,25 +264,10 @@ namespace Mono.CSharp ec.AssertEmptyStack (); var storey = (AsyncTaskStorey) machine_initializer.Storey; - var cont_field = storey.EmitContinuationInitialization (ec); - - var args = new Arguments (1); - args.Add (new Argument (cont_field)); - if (IsDynamic) { - var rc = new ResolveContext (ec.MemberContext); - var mg_expr = new Invocation (new MemberAccess (fe_awaiter, "OnCompleted"), args).Resolve (rc); - - ExpressionStatement es = (ExpressionStatement) mg_expr; - es.EmitStatement (ec); + storey.EmitAwaitOnCompletedDynamic (ec, fe_awaiter); } else { - var mg_completed = MethodGroupExpr.CreatePredefined (on_completed, fe_awaiter.Type, loc); - mg_completed.InstanceExpression = fe_awaiter; - - // - // awaiter.OnCompleted (continuation); - // - mg_completed.EmitCall (ec, args); + storey.EmitAwaitOnCompleted (ec, fe_awaiter); } // Return ok @@ -286,7 +280,9 @@ namespace Mono.CSharp public void EmitStatement (EmitContext ec) { EmitPrologue (ec); - Emit (ec); + DoEmit (ec); + + awaiter.IsAvailableForReuse = true; if (ResultType.Kind != MemberKind.Void) { var storey = (AsyncTaskStorey) machine_initializer.Storey; @@ -300,12 +296,18 @@ namespace Mono.CSharp void Error_WrongAwaiterPattern (ResolveContext rc, TypeSpec awaiter) { - rc.Report.Error (4011, loc, "The awaiter type `{0}' must have suitable IsCompleted, OnCompleted, and GetResult members", + rc.Report.Error (4011, loc, "The awaiter type `{0}' must have suitable IsCompleted and GetResult members", awaiter.GetSignatureForError ()); } public override bool Resolve (BlockContext bc) { + if (bc.CurrentBlock is Linq.QueryBlock) { + bc.Report.Error (1995, loc, + "The `await' operator may only be used in a query expression within the first collection expression of the initial `from' clause or within the collection expression of a `join' clause"); + return false; + } + if (!base.Resolve (bc)) return false; @@ -318,9 +320,6 @@ namespace Mono.CSharp // if (type.BuiltinType == BuiltinTypeSpec.Type.Dynamic) { result_type = type; - - awaiter = ((AsyncTaskStorey) machine_initializer.Storey).AddAwaiter (type, loc); - expr = new Invocation (new MemberAccess (expr, "GetAwaiter"), args).Resolve (bc); return true; } @@ -346,8 +345,6 @@ namespace Mono.CSharp } var awaiter_type = ama.Type; - awaiter = ((AsyncTaskStorey) machine_initializer.Storey).AddAwaiter (awaiter_type, loc); - expr = ama; // @@ -361,20 +358,6 @@ namespace Mono.CSharp return false; } - // - // Predefined: OnCompleted (Action) - // - if (bc.Module.PredefinedTypes.Action.Define ()) { - on_completed = MemberCache.FindMember (awaiter_type, MemberFilter.Method ("OnCompleted", 0, - ParametersCompiled.CreateFullyResolved (bc.Module.PredefinedTypes.Action.TypeSpec), bc.Module.Compiler.BuiltinTypes.Void), - BindingRestriction.InstanceOnly) as MethodSpec; - - if (on_completed == null) { - Error_WrongAwaiterPattern (bc, awaiter_type); - return false; - } - } - // // Predefined: GetResult () // @@ -389,6 +372,16 @@ namespace Mono.CSharp return false; } + // + // Predefined: INotifyCompletion.OnCompleted (System.Action) + // + var nc = bc.Module.PredefinedTypes.INotifyCompletion; + if (nc.Define () && !awaiter_type.ImplementsInterface (nc.TypeSpec, false)) { + bc.Report.Error (4027, loc, "The awaiter type `{0}' must implement interface `{1}'", + awaiter_type.GetSignatureForError (), nc.GetSignatureForError ()); + return false; + } + result_type = get_result.ReturnType; return true; @@ -399,7 +392,7 @@ namespace Mono.CSharp { TypeInferenceContext return_inference; - public AsyncInitializer (ParametersBlock block, TypeContainer host, TypeSpec returnType) + public AsyncInitializer (ParametersBlock block, TypeDefinition host, TypeSpec returnType) : base (block, host, returnType) { } @@ -418,12 +411,6 @@ namespace Mono.CSharp } } - public Block OriginalBlock { - get { - return block.Parent; - } - } - public TypeInferenceContext ReturnTypeInference { get { return return_inference; @@ -432,38 +419,6 @@ namespace Mono.CSharp #endregion - public static void Create (IMemberContext context, ParametersBlock block, ParametersCompiled parameters, TypeContainer host, TypeSpec returnType, Location loc) - { - for (int i = 0; i < parameters.Count; i++) { - Parameter p = parameters[i]; - Parameter.Modifier mod = p.ModFlags; - if ((mod & Parameter.Modifier.ISBYREF) != 0) { - host.Compiler.Report.Error (1988, p.Location, - "Async methods cannot have ref or out parameters"); - return; - } - - if (p is ArglistParameter) { - host.Compiler.Report.Error (4006, p.Location, - "__arglist is not allowed in parameter list of async methods"); - return; - } - - if (parameters.Types[i].IsPointer) { - host.Compiler.Report.Error (4005, p.Location, - "Async methods cannot have unsafe parameters"); - return; - } - } - - if (!block.HasAwait) { - host.Compiler.Report.Warning (1998, 1, loc, - "Async block lacks `await' operator and will run synchronously"); - } - - block.WrapIntoAsyncTask (context, host, returnType); - } - protected override BlockContext CreateBlockContext (ResolveContext rc) { var ctx = base.CreateBlockContext (rc); @@ -494,37 +449,7 @@ namespace Mono.CSharp public override void EmitStatement (EmitContext ec) { var storey = (AsyncTaskStorey) Storey; - storey.Instance.Emit (ec); - - var move_next_entry = storey.StateMachineMethod.Spec; - if (storey.MemberName.Arity > 0) { - move_next_entry = MemberCache.GetMember (storey.Instance.Type, move_next_entry); - } - - ec.Emit (OpCodes.Call, move_next_entry); - - // - // Emits return .$builder.Task; - // - if (storey.Task != null) { - var builder_field = storey.Builder.Spec; - var task_get = storey.Task.Get; - - if (storey.MemberName.Arity > 0) { - builder_field = MemberCache.GetMember (storey.Instance.Type, builder_field); - task_get = MemberCache.GetMember (builder_field.MemberType, task_get); - } - - var pe_task = new PropertyExpr (storey.Task, loc) { - InstanceExpression = new FieldExpr (builder_field, loc) { - InstanceExpression = storey.Instance - }, - Getter = task_get - }; - - pe_task.Emit (ec); - } - + storey.EmitInitializer (ec); ec.Emit (OpCodes.Ret); } } @@ -532,30 +457,27 @@ namespace Mono.CSharp class AsyncTaskStorey : StateMachine { int awaiters; - Field builder, continuation; + Field builder; readonly TypeSpec return_type; MethodSpec set_result; MethodSpec set_exception; + MethodSpec builder_factory; + MethodSpec builder_start; PropertySpec task; LocalVariable hoisted_return; int locals_captured; - Dictionary> stack_fields; - TypeSpec action; + Dictionary> stack_fields; + Dictionary> awaiter_fields; - public AsyncTaskStorey (IMemberContext context, AsyncInitializer initializer, TypeSpec type) - : base (initializer.OriginalBlock, initializer.Host,context.CurrentMemberDefinition as MemberBase, context.CurrentTypeParameters, "async") + public AsyncTaskStorey (ParametersBlock block, IMemberContext context, AsyncInitializer initializer, TypeSpec type) + : base (block, initializer.Host, context.CurrentMemberDefinition as MemberBase, context.CurrentTypeParameters, "async", MemberKind.Struct) { return_type = type; + awaiter_fields = new Dictionary> (); } #region Properties - public Field Builder { - get { - return builder; - } - } - public LocalVariable HoistedReturn { get { return hoisted_return; @@ -578,34 +500,53 @@ namespace Mono.CSharp public Field AddAwaiter (TypeSpec type, Location loc) { - return AddCapturedVariable ("$awaiter" + awaiters++.ToString ("X"), type); + if (mutator != null) + type = mutator.Mutate (type); + + List existing_fields = null; + if (awaiter_fields.TryGetValue (type, out existing_fields)) { + foreach (var f in existing_fields) { + if (f.IsAvailableForReuse) { + f.IsAvailableForReuse = false; + return f; + } + } + } + + var field = AddCompilerGeneratedField ("$awaiter" + awaiters++.ToString ("X"), new TypeExpression (type, Location), true); + field.Define (); + + if (existing_fields == null) { + existing_fields = new List (); + awaiter_fields.Add (type, existing_fields); + } + + existing_fields.Add (field); + return field; } - public StackField AddCapturedLocalVariable (TypeSpec type) + public Field AddCapturedLocalVariable (TypeSpec type) { if (mutator != null) type = mutator.Mutate (type); - List existing_fields = null; + List existing_fields = null; if (stack_fields == null) { - stack_fields = new Dictionary> (); + stack_fields = new Dictionary> (); } else if (stack_fields.TryGetValue (type, out existing_fields)) { foreach (var f in existing_fields) { - if (f.CanBeReused) { - f.CanBeReused = false; + if (f.IsAvailableForReuse) { + f.IsAvailableForReuse = false; return f; } } } - const Modifiers mod = Modifiers.COMPILER_GENERATED | Modifiers.PRIVATE; - var field = new StackField (this, new TypeExpression (type, Location), mod, new MemberName ("$" + locals_captured++.ToString ("X"), Location)); - AddField (field); - + var field = AddCompilerGeneratedField ("$stack" + locals_captured++.ToString ("X"), new TypeExpression (type, Location), true); field.Define (); if (existing_fields == null) { - existing_fields = new List (); + existing_fields = new List (); stack_fields.Add (type, existing_fields); } @@ -616,39 +557,52 @@ namespace Mono.CSharp protected override bool DoDefineMembers () { - action = Module.PredefinedTypes.Action.Resolve (); - PredefinedType builder_type; PredefinedMember bf; + PredefinedMember bs; PredefinedMember sr; PredefinedMember se; + PredefinedMember sm; bool has_task_return_type = false; var pred_members = Module.PredefinedMembers; if (return_type.Kind == MemberKind.Void) { builder_type = Module.PredefinedTypes.AsyncVoidMethodBuilder; bf = pred_members.AsyncVoidMethodBuilderCreate; + bs = pred_members.AsyncVoidMethodBuilderStart; sr = pred_members.AsyncVoidMethodBuilderSetResult; se = pred_members.AsyncVoidMethodBuilderSetException; + sm = pred_members.AsyncVoidMethodBuilderSetStateMachine; } else if (return_type == Module.PredefinedTypes.Task.TypeSpec) { builder_type = Module.PredefinedTypes.AsyncTaskMethodBuilder; bf = pred_members.AsyncTaskMethodBuilderCreate; + bs = pred_members.AsyncTaskMethodBuilderStart; sr = pred_members.AsyncTaskMethodBuilderSetResult; se = pred_members.AsyncTaskMethodBuilderSetException; + sm = pred_members.AsyncTaskMethodBuilderSetStateMachine; task = pred_members.AsyncTaskMethodBuilderTask.Get (); } else { builder_type = Module.PredefinedTypes.AsyncTaskMethodBuilderGeneric; bf = pred_members.AsyncTaskMethodBuilderGenericCreate; + bs = pred_members.AsyncTaskMethodBuilderGenericStart; sr = pred_members.AsyncTaskMethodBuilderGenericSetResult; se = pred_members.AsyncTaskMethodBuilderGenericSetException; + sm = pred_members.AsyncTaskMethodBuilderGenericSetStateMachine; task = pred_members.AsyncTaskMethodBuilderGenericTask.Get (); has_task_return_type = true; } set_result = sr.Get (); set_exception = se.Get (); - var builder_factory = bf.Get (); - if (!builder_type.Define () || set_result == null || builder_factory == null || set_exception == null) { + builder_factory = bf.Get (); + builder_start = bs.Get (); + + var istate_machine = Module.PredefinedTypes.IAsyncStateMachine; + var set_statemachine = sm.Get (); + + if (!builder_type.Define () || !istate_machine.Define () || set_result == null || builder_factory == null || + set_exception == null || set_statemachine == null || builder_start == null || + !Module.PredefinedTypes.INotifyCompletion.Define ()) { Report.Error (1993, Location, "Cannot find compiler required types for asynchronous functions support. Are you targeting the wrong framework version?"); return base.DoDefineMembers (); @@ -665,81 +619,206 @@ namespace Mono.CSharp task_return_type = mutator.Mutate (task_return_type); bt = bt.MakeGenericType (Module, task_return_type); - builder_factory = MemberCache.GetMember (bt, builder_factory); - set_result = MemberCache.GetMember (bt, set_result); - set_exception = MemberCache.GetMember (bt, set_exception); + set_result = MemberCache.GetMember (bt, set_result); + set_exception = MemberCache.GetMember (bt, set_exception); + set_statemachine = MemberCache.GetMember (bt, set_statemachine); if (task != null) - task = MemberCache.GetMember (bt, task); + task = MemberCache.GetMember (bt, task); } builder = AddCompilerGeneratedField ("$builder", new TypeExpression (bt, Location)); + var set_state_machine = new Method (this, new TypeExpression (Compiler.BuiltinTypes.Void, Location), + Modifiers.COMPILER_GENERATED | Modifiers.DEBUGGER_HIDDEN | Modifiers.PUBLIC, + new MemberName ("SetStateMachine"), + ParametersCompiled.CreateFullyResolved ( + new Parameter (new TypeExpression (istate_machine.TypeSpec, Location), "stateMachine", Parameter.Modifier.NONE, null, Location), + istate_machine.TypeSpec), + null); + + ToplevelBlock block = new ToplevelBlock (Compiler, set_state_machine.ParameterInfo, Location); + block.IsCompilerGenerated = true; + set_state_machine.Block = block; + + Members.Add (set_state_machine); + if (!base.DoDefineMembers ()) return false; - var block = instance_constructors[0].Block; + // + // Fabricates SetStateMachine method + // + // public void SetStateMachine (IAsyncStateMachine stateMachine) + // { + // $builder.SetStateMachine (stateMachine); + // } + // + var mg = MethodGroupExpr.CreatePredefined (set_statemachine, bt, Location); + mg.InstanceExpression = new FieldExpr (builder, Location); - var mg = MethodGroupExpr.CreatePredefined (builder_factory, bt, Location); - block.AddStatement ( - new StatementExpression (new SimpleAssign ( - new FieldExpr (builder, Location), - new Invocation (mg, new Arguments (0)), - Location))); + var param_reference = block.GetParameterReference (0, Location); + param_reference.Type = istate_machine.TypeSpec; + param_reference.eclass = ExprClass.Variable; + + var args = new Arguments (1); + args.Add (new Argument (param_reference)); + set_state_machine.Block.AddStatement (new StatementExpression (new Invocation (mg, args))); if (has_task_return_type) { - hoisted_return = LocalVariable.CreateCompilerGenerated (bt.TypeArguments[0], block, Location); + hoisted_return = LocalVariable.CreateCompilerGenerated (bt.TypeArguments[0], StateMachineMethod.Block, Location); } return true; } - public Expression EmitContinuationInitialization (EmitContext ec) + public void EmitAwaitOnCompletedDynamic (EmitContext ec, FieldExpr awaiter) { + var critical = Module.PredefinedTypes.ICriticalNotifyCompletion; + if (!critical.Define ()) { + throw new NotImplementedException (); + } + + var temp_critical = new LocalTemporary (critical.TypeSpec); + var label_critical = ec.DefineLabel (); + var label_end = ec.DefineLabel (); + // - // When more than 1 awaiter has been used in the block we - // introduce class scope field to cache continuation delegate + // Special path for dynamic awaiters // - if (awaiters > 1) { - if (continuation == null) { - continuation = AddCompilerGeneratedField ("$continuation", new TypeExpression (action, Location), true); - continuation.Define (); - } + // var awaiter = this.$awaiter as ICriticalNotifyCompletion; + // if (awaiter == null) { + // var completion = (INotifyCompletion) this.$awaiter; + // this.$builder.AwaitOnCompleted (ref completion, ref this); + // } else { + // this.$builder.AwaitUnsafeOnCompleted (ref awaiter, ref this); + // } + // + awaiter.Emit (ec); + ec.Emit (OpCodes.Isinst, critical.TypeSpec); + temp_critical.Store (ec); + temp_critical.Emit (ec); + ec.Emit (OpCodes.Brtrue_S, label_critical); + + var temp = new LocalTemporary (Module.PredefinedTypes.INotifyCompletion.TypeSpec); + awaiter.Emit (ec); + ec.Emit (OpCodes.Castclass, temp.Type); + temp.Store (ec); + EmitOnCompleted (ec, temp, false); + temp.Release (ec); + ec.Emit (OpCodes.Br_S, label_end); - var fexpr = new FieldExpr (continuation, Location); - fexpr.InstanceExpression = new CompilerGeneratedThis (CurrentType, Location); + ec.MarkLabel (label_critical); - // - // if ($continuation == null) - // $continuation = new Action (MoveNext); - // - fexpr.Emit (ec); + EmitOnCompleted (ec, temp_critical, true); - var skip_cont_init = ec.DefineLabel (); - ec.Emit (OpCodes.Brtrue_S, skip_cont_init); + ec.MarkLabel (label_end); - ec.EmitThis (); - EmitActionLoad (ec); - ec.Emit (OpCodes.Stfld, continuation.Spec); - ec.MarkLabel (skip_cont_init); + temp_critical.Release (ec); + } - return fexpr; + public void EmitAwaitOnCompleted (EmitContext ec, FieldExpr awaiter) + { + bool unsafe_version = false; + if (Module.PredefinedTypes.ICriticalNotifyCompletion.Define ()) { + unsafe_version = awaiter.Type.ImplementsInterface (Module.PredefinedTypes.ICriticalNotifyCompletion.TypeSpec, false); } - // - // Otherwise simply use temporary local variable - // - var field = LocalVariable.CreateCompilerGenerated (action, OriginalSourceBlock, Location); - EmitActionLoad (ec); - field.EmitAssign (ec); - return new LocalVariableReference (field, Location); + EmitOnCompleted (ec, awaiter, unsafe_version); + } + + void EmitOnCompleted (EmitContext ec, Expression awaiter, bool unsafeVersion) + { + var pm = Module.PredefinedMembers; + PredefinedMember predefined; + bool has_task_return_type = false; + if (return_type.Kind == MemberKind.Void) { + predefined = unsafeVersion ? pm.AsyncVoidMethodBuilderOnCompletedUnsafe : pm.AsyncVoidMethodBuilderOnCompleted; + } else if (return_type == Module.PredefinedTypes.Task.TypeSpec) { + predefined = unsafeVersion ? pm.AsyncTaskMethodBuilderOnCompletedUnsafe : pm.AsyncTaskMethodBuilderOnCompleted; + } else { + predefined = unsafeVersion ? pm.AsyncTaskMethodBuilderGenericOnCompletedUnsafe : pm.AsyncTaskMethodBuilderGenericOnCompleted; + has_task_return_type = true; + } + + var on_completed = predefined.Resolve (Location); + if (on_completed == null) + return; + + if (has_task_return_type) + on_completed = MemberCache.GetMember (set_result.DeclaringType, on_completed); + + on_completed = on_completed.MakeGenericMethod (this, awaiter.Type, ec.CurrentType); + + var mg = MethodGroupExpr.CreatePredefined (on_completed, on_completed.DeclaringType, Location); + mg.InstanceExpression = new FieldExpr (builder, Location) { + InstanceExpression = new CompilerGeneratedThis (ec.CurrentType, Location) + }; + + var args = new Arguments (2); + args.Add (new Argument (awaiter, Argument.AType.Ref)); + args.Add (new Argument (new CompilerGeneratedThis (CurrentType, Location), Argument.AType.Ref)); + mg.EmitCall (ec, args); } - void EmitActionLoad (EmitContext ec) + public void EmitInitializer (EmitContext ec) { - ec.EmitThis (); - ec.Emit (OpCodes.Ldftn, StateMachineMethod.Spec); - ec.Emit (OpCodes.Newobj, (MethodSpec) MemberCache.FindMember (action, MemberFilter.Constructor (null), BindingRestriction.DeclaredOnly)); + // + // Some predefined types are missing + // + if (builder == null) + return; + + var instance = (TemporaryVariableReference) Instance; + var builder_field = builder.Spec; + if (MemberName.Arity > 0) { + builder_field = MemberCache.GetMember (instance.Type, builder_field); + } + + // + // Inflated factory method when task is of generic type + // + if (builder_factory.DeclaringType.IsGeneric) { + var task_return_type = return_type.TypeArguments; + var bt = builder_factory.DeclaringType.MakeGenericType (Module, task_return_type); + builder_factory = MemberCache.GetMember (bt, builder_factory); + builder_start = MemberCache.GetMember (bt, builder_start); + } + + // + // stateMachine.$builder = AsyncTaskMethodBuilder<{task-type}>.Create(); + // + instance.AddressOf (ec, AddressOp.Store); + ec.Emit (OpCodes.Call, builder_factory); + ec.Emit (OpCodes.Stfld, builder_field); + + // + // stateMachine.$builder.Start<{storey-type}>(ref stateMachine); + // + instance.AddressOf (ec, AddressOp.Store); + ec.Emit (OpCodes.Ldflda, builder_field); + if (Task != null) + ec.Emit (OpCodes.Dup); + instance.AddressOf (ec, AddressOp.Store); + ec.Emit (OpCodes.Call, builder_start.MakeGenericMethod (Module, instance.Type)); + + // + // Emits return stateMachine.$builder.Task; + // + if (Task != null) { + var task_get = Task.Get; + + if (MemberName.Arity > 0) { + task_get = MemberCache.GetMember (builder_field.MemberType, task_get); + } + + var pe_task = new PropertyExpr (Task, Location) { + InstanceExpression = EmptyExpression.Null, // Comes from the dup above + Getter = task_get + }; + + pe_task.Emit (ec); + } } public void EmitSetException (EmitContext ec, LocalVariableReference exceptionVariable) @@ -748,7 +827,7 @@ namespace Mono.CSharp // $builder.SetException (Exception) // var mg = MethodGroupExpr.CreatePredefined (set_exception, set_exception.DeclaringType, Location); - mg.InstanceExpression = new FieldExpr (Builder, Location) { + mg.InstanceExpression = new FieldExpr (builder, Location) { InstanceExpression = new CompilerGeneratedThis (ec.CurrentType, Location) }; @@ -765,7 +844,7 @@ namespace Mono.CSharp // $builder.SetResult (value); // var mg = MethodGroupExpr.CreatePredefined (set_result, set_result.DeclaringType, Location); - mg.InstanceExpression = new FieldExpr (Builder, Location) { + mg.InstanceExpression = new FieldExpr (builder, Location) { InstanceExpression = new CompilerGeneratedThis (ec.CurrentType, Location) }; @@ -779,31 +858,57 @@ namespace Mono.CSharp mg.EmitCall (ec, args); } - } - class StackField : Field - { - public StackField (TypeContainer parent, FullNamedExpression type, Modifiers mod, MemberName name) - : base (parent, type, mod, name, null) + protected override TypeSpec[] ResolveBaseTypes (out FullNamedExpression base_class) { - } + base_type = Compiler.BuiltinTypes.ValueType; + base_class = null; + + var istate_machine = Module.PredefinedTypes.IAsyncStateMachine; + if (istate_machine.Define ()) { + return new[] { istate_machine.TypeSpec }; + } - public bool CanBeReused { get; set; } + return null; + } } - class StackFieldExpr : FieldExpr + class StackFieldExpr : FieldExpr, IExpressionCleanup { public StackFieldExpr (Field field) : base (field, Location.Null) { } + public override void AddressOf (EmitContext ec, AddressOp mode) + { + base.AddressOf (ec, mode); + + if (mode == AddressOp.Load) { + var field = (Field) spec.MemberDefinition; + field.IsAvailableForReuse = true; + } + } + public override void Emit (EmitContext ec) { base.Emit (ec); - var field = (StackField) spec.MemberDefinition; - field.CanBeReused = true; + var field = (Field) spec.MemberDefinition; + field.IsAvailableForReuse = true; + + // + // Release any captured reference type stack variables + // to imitate real stack behavour and help GC stuff early + // + if (TypeSpec.IsReferenceType (type)) { + ec.AddStatementEpilog (this); + } + } + + void IExpressionCleanup.EmitCleanup (EmitContext ec) + { + EmitAssign (ec, new NullConstant (type, loc), false, false); } } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/attribute.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/attribute.cs index a9decc3ba4..47eaad62e0 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/attribute.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/attribute.cs @@ -278,7 +278,7 @@ namespace Mono.CSharp { void ResolveAttributeType () { SessionReportPrinter resolve_printer = new SessionReportPrinter (); - ReportPrinter prev_recorder = context.Module.Compiler.Report.SetPrinter (resolve_printer); + ReportPrinter prev_recorder = Report.SetPrinter (resolve_printer); bool t1_is_attr = false; bool t2_is_attr = false; @@ -902,6 +902,11 @@ namespace Mono.CSharp { // Returns true for MethodImplAttribute with MethodImplOptions.InternalCall value // public bool IsInternalCall () + { + return (GetMethodImplOptions () & MethodImplOptions.InternalCall) != 0; + } + + public MethodImplOptions GetMethodImplOptions () { MethodImplOptions options = 0; if (pos_args.Count == 1) { @@ -911,7 +916,7 @@ namespace Mono.CSharp { options = (MethodImplOptions) System.Enum.Parse (typeof (MethodImplOptions), named.GetValue ().ToString ()); } - return (options & MethodImplOptions.InternalCall) != 0; + return options; } // @@ -1557,56 +1562,6 @@ namespace Mono.CSharp { /// static class AttributeTester { - public enum Result { - Ok, - RefOutArrayError, - ArrayArrayError - } - - /// - /// Returns true if parameters of two compared methods are CLS-Compliant. - /// It tests differing only in ref or out, or in array rank. - /// - public static Result AreOverloadedMethodParamsClsCompliant (AParametersCollection pa, AParametersCollection pb) - { - TypeSpec [] types_a = pa.Types; - TypeSpec [] types_b = pb.Types; - if (types_a == null || types_b == null) - return Result.Ok; - - if (types_a.Length != types_b.Length) - return Result.Ok; - - Result result = Result.Ok; - for (int i = 0; i < types_b.Length; ++i) { - TypeSpec aType = types_a [i]; - TypeSpec bType = types_b [i]; - - var ac_a = aType as ArrayContainer; - var ac_b = aType as ArrayContainer; - - if (ac_a != null && ac_b != null) { - if (ac_a.Rank != ac_b.Rank && ac_a.Element == ac_b.Element) { - result = Result.RefOutArrayError; - continue; - } - - if (ac_a.Element.IsArray || ac_b.Element.IsArray) { - result = Result.ArrayArrayError; - continue; - } - } - - if (aType != bType) - return Result.Ok; - - const Parameter.Modifier out_ref_mod = (Parameter.Modifier.OUTMASK | Parameter.Modifier.REFMASK); - if ((pa.FixedParameters[i].ModFlags & out_ref_mod) != (pb.FixedParameters[i].ModFlags & out_ref_mod)) - result = Result.RefOutArrayError; - } - return result; - } - /// /// Common method for Obsolete error/warning reporting. /// @@ -1666,6 +1621,7 @@ namespace Mono.CSharp { public readonly PredefinedAttribute DebuggerHidden; public readonly PredefinedAttribute UnsafeValueType; public readonly PredefinedAttribute UnmanagedFunctionPointer; + public readonly PredefinedDebuggerBrowsableAttribute DebuggerBrowsable; // New in .NET 3.5 public readonly PredefinedAttribute Extension; @@ -1680,6 +1636,9 @@ namespace Mono.CSharp { public readonly PredefinedDecimalAttribute DecimalConstant; public readonly PredefinedAttribute StructLayout; public readonly PredefinedAttribute FieldOffset; + public readonly PredefinedAttribute CallerMemberNameAttribute; + public readonly PredefinedAttribute CallerLineNumberAttribute; + public readonly PredefinedAttribute CallerFilePathAttribute; public PredefinedAttributes (ModuleContainer module) { @@ -1720,6 +1679,7 @@ namespace Mono.CSharp { DebuggerHidden = new PredefinedAttribute (module, "System.Diagnostics", "DebuggerHiddenAttribute"); UnsafeValueType = new PredefinedAttribute (module, "System.Runtime.CompilerServices", "UnsafeValueTypeAttribute"); UnmanagedFunctionPointer = new PredefinedAttribute (module, "System.Runtime.InteropServices", "UnmanagedFunctionPointerAttribute"); + DebuggerBrowsable = new PredefinedDebuggerBrowsableAttribute (module, "System.Diagnostics", "DebuggerBrowsableAttribute"); Extension = new PredefinedAttribute (module, "System.Runtime.CompilerServices", "ExtensionAttribute"); @@ -1730,6 +1690,10 @@ namespace Mono.CSharp { StructLayout = new PredefinedAttribute (module, "System.Runtime.InteropServices", "StructLayoutAttribute"); FieldOffset = new PredefinedAttribute (module, "System.Runtime.InteropServices", "FieldOffsetAttribute"); + CallerMemberNameAttribute = new PredefinedAttribute (module, "System.Runtime.CompilerServices", "CallerMemberNameAttribute"); + CallerLineNumberAttribute = new PredefinedAttribute (module, "System.Runtime.CompilerServices", "CallerLineNumberAttribute"); + CallerFilePathAttribute = new PredefinedAttribute (module, "System.Runtime.CompilerServices", "CallerFilePathAttribute"); + // TODO: Should define only attributes which are used for comparison const System.Reflection.BindingFlags all_fields = System.Reflection.BindingFlags.Public | System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.DeclaredOnly; @@ -1803,22 +1767,12 @@ namespace Mono.CSharp { builder.SetCustomAttribute (GetCtorMetaInfo (), AttributeEncoder.Empty); } - public void EmitAttribute (FieldBuilder builder, AttributeEncoder argsEncoded) - { - builder.SetCustomAttribute (GetCtorMetaInfo (), argsEncoded.ToArray ()); - } - public void EmitAttribute (TypeBuilder builder) { if (ResolveBuilder ()) builder.SetCustomAttribute (GetCtorMetaInfo (), AttributeEncoder.Empty); } - public void EmitAttribute (TypeBuilder builder, AttributeEncoder argsEncoded) - { - builder.SetCustomAttribute (GetCtorMetaInfo (), argsEncoded.ToArray ()); - } - public void EmitAttribute (AssemblyBuilder builder) { if (ResolveBuilder ()) @@ -1837,11 +1791,6 @@ namespace Mono.CSharp { builder.SetCustomAttribute (GetCtorMetaInfo (), AttributeEncoder.Empty); } - public void EmitAttribute (ParameterBuilder builder, AttributeEncoder argsEncoded) - { - builder.SetCustomAttribute (GetCtorMetaInfo (), argsEncoded.ToArray ()); - } - ConstructorInfo GetCtorMetaInfo () { return (ConstructorInfo) ctor.GetMetaInfo (); @@ -1863,6 +1812,27 @@ namespace Mono.CSharp { } } + public class PredefinedDebuggerBrowsableAttribute : PredefinedAttribute + { + public PredefinedDebuggerBrowsableAttribute (ModuleContainer module, string ns, string name) + : base (module, ns, name) + { + } + + public void EmitAttribute (FieldBuilder builder, System.Diagnostics.DebuggerBrowsableState state) + { + var ctor = module.PredefinedMembers.DebuggerBrowsableAttributeCtor.Get (); + if (ctor == null) + return; + + AttributeEncoder encoder = new AttributeEncoder (); + encoder.Encode ((int) state); + encoder.EncodeEmptyNamedArguments (); + + builder.SetCustomAttribute ((ConstructorInfo) ctor.GetMetaInfo (), encoder.ToArray ()); + } + } + public class PredefinedDecimalAttribute : PredefinedAttribute { public PredefinedDecimalAttribute (ModuleContainer module, string ns, string name) diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/cfold.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/cfold.cs index 7580124cee..9e2cfc8b96 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/cfold.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/cfold.cs @@ -149,7 +149,7 @@ namespace Mono.CSharp { case Binary.Operator.ExclusiveOr: result = BinaryFold (ec, oper, ((EnumConstant)left).Child, ((EnumConstant)right).Child, loc); if (result != null) - result = result.TryReduce (ec, lt, loc); + result = result.TryReduce (ec, lt); return result; /// @@ -158,7 +158,7 @@ namespace Mono.CSharp { case Binary.Operator.Subtraction: result = BinaryFold (ec, oper, ((EnumConstant)left).Child, ((EnumConstant)right).Child, loc); if (result != null) - result = result.TryReduce (ec, EnumSpec.GetUnderlyingType (lt), loc); + result = result.TryReduce (ec, EnumSpec.GetUnderlyingType (lt)); return result; /// @@ -340,7 +340,7 @@ namespace Mono.CSharp { if (result == null) return null; - result = result.TryReduce (ec, lt, loc); + result = result.TryReduce (ec, lt); if (result == null) return null; @@ -459,7 +459,7 @@ namespace Mono.CSharp { if (result == null) return null; - result = result.TryReduce (ec, lt, loc); + result = result.TryReduce (ec, lt); if (result == null) return null; diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/class.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/class.cs index 84cb9ed673..de601e1451 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/class.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/class.cs @@ -18,6 +18,9 @@ using System.Runtime.InteropServices; using System.Security; using System.Security.Permissions; using System.Linq; +using System.Text; +using System.Diagnostics; +using Mono.CompilerServices.SymbolWriter; #if NET_2_1 using XmlElement = System.Object; @@ -35,17 +38,335 @@ using System.Reflection.Emit; namespace Mono.CSharp { - - public interface ITypesContainer + // + // General types container, used as a base class for all constructs which can hold types + // + public abstract class TypeContainer : MemberCore { - Location Location { get; } - MemberName MemberName { get; } + public readonly MemberKind Kind; + public readonly string Basename; + + protected List containers; + + TypeDefinition main_container; + + protected Dictionary defined_names; + + protected bool is_defined; + + public TypeContainer (TypeContainer parent, MemberName name, Attributes attrs, MemberKind kind) + : base (parent, name, attrs) + { + this.Kind = kind; + if (name != null) + this.Basename = name.Basename; + + defined_names = new Dictionary (); + } + + public override TypeSpec CurrentType { + get { + return null; + } + } + + public TypeDefinition PartialContainer { + get { + return main_container; + } + protected set { + main_container = value; + } + } + + public IList Containers { + get { + return containers; + } + } + + // + // Any unattached attributes during parsing get added here. User + // by FULL_AST mode + // + public Attributes UnattachedAttributes { + get; set; + } + + public virtual void AddCompilerGeneratedClass (CompilerGeneratedContainer c) + { + containers.Add (c); + } + + public virtual void AddPartial (TypeDefinition next_part) + { + MemberCore mc; + (PartialContainer ?? this).defined_names.TryGetValue (next_part.Basename, out mc); + + AddPartial (next_part, mc as TypeDefinition); + } + + protected void AddPartial (TypeDefinition next_part, TypeDefinition existing) + { + next_part.ModFlags |= Modifiers.PARTIAL; + + if (existing == null) { + AddTypeContainer (next_part); + return; + } + + if ((existing.ModFlags & Modifiers.PARTIAL) == 0) { + if (existing.Kind != next_part.Kind) { + AddTypeContainer (next_part); + } else { + Report.SymbolRelatedToPreviousError (next_part); + Error_MissingPartialModifier (existing); + } + + return; + } + + if (existing.Kind != next_part.Kind) { + Report.SymbolRelatedToPreviousError (existing); + Report.Error (261, next_part.Location, + "Partial declarations of `{0}' must be all classes, all structs or all interfaces", + next_part.GetSignatureForError ()); + } + + if ((existing.ModFlags & Modifiers.AccessibilityMask) != (next_part.ModFlags & Modifiers.AccessibilityMask) && + ((existing.ModFlags & Modifiers.DEFAULT_ACCESS_MODIFER) == 0 && + (next_part.ModFlags & Modifiers.DEFAULT_ACCESS_MODIFER) == 0)) { + Report.SymbolRelatedToPreviousError (existing); + Report.Error (262, next_part.Location, + "Partial declarations of `{0}' have conflicting accessibility modifiers", + next_part.GetSignatureForError ()); + } + + var tc_names = existing.CurrentTypeParameters; + if (tc_names != null) { + for (int i = 0; i < tc_names.Count; ++i) { + var tp = next_part.MemberName.TypeParameters[i]; + if (tc_names[i].MemberName.Name != tp.MemberName.Name) { + Report.SymbolRelatedToPreviousError (existing.Location, ""); + Report.Error (264, next_part.Location, "Partial declarations of `{0}' must have the same type parameter names in the same order", + next_part.GetSignatureForError ()); + break; + } + + if (tc_names[i].Variance != tp.Variance) { + Report.SymbolRelatedToPreviousError (existing.Location, ""); + Report.Error (1067, next_part.Location, "Partial declarations of `{0}' must have the same type parameter variance modifiers", + next_part.GetSignatureForError ()); + break; + } + } + } + + if ((next_part.ModFlags & Modifiers.DEFAULT_ACCESS_MODIFER) != 0) { + existing.ModFlags |= next_part.ModFlags & ~(Modifiers.DEFAULT_ACCESS_MODIFER | Modifiers.AccessibilityMask); + } else if ((existing.ModFlags & Modifiers.DEFAULT_ACCESS_MODIFER) != 0) { + existing.ModFlags &= ~(Modifiers.DEFAULT_ACCESS_MODIFER | Modifiers.AccessibilityMask); + existing.ModFlags |= next_part.ModFlags; + } else { + existing.ModFlags |= next_part.ModFlags; + } + + existing.Definition.Modifiers = existing.ModFlags; + + if (next_part.attributes != null) { + if (existing.attributes == null) + existing.attributes = next_part.attributes; + else + existing.attributes.AddAttributes (next_part.attributes.Attrs); + } + + next_part.PartialContainer = existing; + + if (containers == null) + containers = new List (); + + containers.Add (next_part); + } + + public virtual void AddTypeContainer (TypeContainer tc) + { + containers.Add (tc); + + var tparams = tc.MemberName.TypeParameters; + if (tparams != null && tc.PartialContainer != null) { + var td = (TypeDefinition) tc; + for (int i = 0; i < tparams.Count; ++i) { + var tp = tparams[i]; + if (tp.MemberName == null) + continue; + + td.AddNameToContainer (tp, tp.Name); + } + } + } + + public virtual void CloseContainer () + { + if (containers != null) { + foreach (TypeContainer tc in containers) { + tc.CloseContainer (); + } + } + } + + public virtual void CreateMetadataName (StringBuilder sb) + { + if (Parent != null && Parent.MemberName != null) + Parent.CreateMetadataName (sb); + + MemberName.CreateMetadataName (sb); + } + + public virtual bool CreateContainer () + { + if (containers != null) { + foreach (TypeContainer tc in containers) { + tc.CreateContainer (); + } + } + + return true; + } + + public override bool Define () + { + if (containers != null) { + foreach (TypeContainer tc in containers) { + tc.Define (); + } + } + + // Release cache used by parser only + if (Module.Evaluator == null) { + defined_names = null; + } else { + defined_names.Clear (); + } + + return true; + } + + public virtual void PrepareEmit () + { + if (containers != null) { + foreach (var t in containers) { + try { + t.PrepareEmit (); + } catch (Exception e) { + if (MemberName == MemberName.Null) + throw; + + throw new InternalErrorException (t, e); + } + } + } + } + + public virtual bool DefineContainer () + { + if (is_defined) + return true; + + is_defined = true; + + DoDefineContainer (); + + if (containers != null) { + foreach (TypeContainer tc in containers) { + try { + tc.DefineContainer (); + } catch (Exception e) { + if (MemberName == MemberName.Null) + throw; + + throw new InternalErrorException (tc, e); + } + } + } + + return true; + } + + protected virtual void DefineNamespace () + { + if (containers != null) { + foreach (var tc in containers) { + try { + tc.DefineNamespace (); + } catch (Exception e) { + throw new InternalErrorException (tc, e); + } + } + } + } + + protected virtual void DoDefineContainer () + { + } + + public virtual void EmitContainer () + { + if (containers != null) { + for (int i = 0; i < containers.Count; ++i) + containers[i].EmitContainer (); + } + } + + protected void Error_MissingPartialModifier (MemberCore type) + { + Report.Error (260, type.Location, + "Missing partial modifier on declaration of type `{0}'. Another partial declaration of this type exists", + type.GetSignatureForError ()); + } + + public override string GetSignatureForDocumentation () + { + if (Parent != null && Parent.MemberName != null) + return Parent.GetSignatureForDocumentation () + "." + MemberName.GetSignatureForDocumentation (); + + return MemberName.GetSignatureForDocumentation (); + } + + public override string GetSignatureForError () + { + if (Parent != null && Parent.MemberName != null) + return Parent.GetSignatureForError () + "." + MemberName.GetSignatureForError (); + + return MemberName.GetSignatureForError (); + } + + public virtual void RemoveContainer (TypeContainer cont) + { + if (containers != null) + containers.Remove (cont); + + defined_names.Remove (cont.Basename); + } + + public virtual void VerifyMembers () + { + if (containers != null) { + foreach (TypeContainer tc in containers) + tc.VerifyMembers (); + } + } + + public override void WriteDebugSymbol (MonoSymbolFile file) + { + if (containers != null) { + foreach (TypeContainer tc in containers) { + tc.WriteDebugSymbol (file); + } + } + } } - /// - /// This is the base class for structs and classes. - /// - public abstract class TypeContainer : MemberCore, ITypeDefinition, ITypesContainer + public abstract class TypeDefinition : TypeContainer, ITypeDefinition { // // Different context is needed when resolving type container base @@ -135,24 +456,7 @@ namespace Mono.CSharp HasStaticFieldInitializer = 1 << 2 } - - // Whether this is a struct, class or interface - public readonly MemberKind Kind; - - // Holds a list of classes and structures - protected List types; - - List ordered_explicit_member_list; - List ordered_member_list; - - // Holds the list of properties - List properties; - - // Holds the list of constructors - protected List instance_constructors; - - // Holds the list of fields - protected List fields; + readonly List members; // Holds a list of fields that have initializers protected List initialized_fields; @@ -160,42 +464,17 @@ namespace Mono.CSharp // Holds a list of static fields that have initializers protected List initialized_static_fields; - // Holds the list of constants - protected List constants; - - // Holds the methods. - List methods; - - // Holds the events - protected List events; - - // Holds the indexers - List indexers; - - // Holds the operators - List operators; - - // Holds the compiler generated classes - protected List compiler_generated; - Dictionary hoisted_base_call_proxies; - protected Dictionary defined_names; Dictionary Cache = new Dictionary (); - // - // Pointers to the default constructor and the default static constructor - // - protected Constructor default_constructor; - protected Constructor default_static_constructor; - // // Points to the first non-static field added to the container. // // This is an arbitrary choice. We are interested in looking at _some_ non-static field, // and the first one's as good as any. // - FieldBase first_nonstatic_field; + protected FieldBase first_nonstatic_field; // // This one is computed after we can distinguish interfaces @@ -207,12 +486,7 @@ namespace Mono.CSharp protected List type_bases; - bool members_defined; - bool members_defined_ok; - bool type_defined; - - TypeContainer InTransit; - public TypeContainer PartialContainer; + TypeDefinition InTransit; public TypeBuilder TypeBuilder; GenericTypeParameterBuilder[] all_tp_builders; @@ -222,28 +496,23 @@ namespace Mono.CSharp // TypeParameters all_type_parameters; - // - // This is the namespace in which this typecontainer - // was declared. We use this to resolve names. - // - public NamespaceContainer NamespaceEntry; - - public readonly string Basename; public const string DefaultIndexerName = "Item"; - private bool seen_normal_indexers = false; - private string indexer_name = DefaultIndexerName; + bool has_normal_indexers; + string indexer_name; protected bool requires_delayed_unmanagedtype_check; bool error; + bool members_defined; + bool members_defined_ok; + protected bool has_static_constructor; private CachedMethods cached_method; protected TypeSpec spec; TypeSpec current_type; - List partial_parts; - public int DynamicSitesCounter; + public int AnonymousMethodsCounter; static readonly string[] attribute_targets = new string[] { "type" }; @@ -253,25 +522,11 @@ namespace Mono.CSharp /// PendingImplementation pending; - public TypeContainer (NamespaceContainer ns, TypeContainer parent, MemberName name, Attributes attrs, MemberKind kind) - : base (parent, name, attrs) + public TypeDefinition (TypeContainer parent, MemberName name, Attributes attrs, MemberKind kind) + : base (parent, name, attrs, kind) { - if (parent != null && parent.NamespaceEntry != ns) - throw new InternalErrorException ("A nested type should be in the same NamespaceEntry as its enclosing class"); - - this.Kind = kind; - this.PartialContainer = this; - this.Basename = name.Basename; - this.NamespaceEntry = ns; - - defined_names = new Dictionary (); - } - - List orderedAllMembers = new List (); - public List OrderedAllMembers { - get { - return this.orderedAllMembers; - } + PartialContainer = this; + members = new List (); } #region Properties @@ -346,6 +601,35 @@ namespace Mono.CSharp } } + public bool HasInstanceConstructor { + get { + return (caching_flags & Flags.HasInstanceConstructor) != 0; + } + set { + caching_flags |= Flags.HasInstanceConstructor; + } + } + + // Indicated whether container has StructLayout attribute set Explicit + public bool HasExplicitLayout { + get { return (caching_flags & Flags.HasExplicitLayout) != 0; } + set { caching_flags |= Flags.HasExplicitLayout; } + } + + public bool HasOperators { + get { + return (caching_flags & Flags.HasUserOperators) != 0; + } + set { + caching_flags |= Flags.HasUserOperators; + } + } + + public bool HasStructLayout { + get { return (caching_flags & Flags.HasStructLayout) != 0; } + set { caching_flags |= Flags.HasStructLayout; } + } + public TypeSpec[] Interfaces { get { return iface_exprs; @@ -358,20 +642,46 @@ namespace Mono.CSharp } } - // - // root_types contains all the types. All TopLevel types - // hence have a parent that points to `root_types', that is - // why there is a non-obvious test down here. - // public bool IsTopLevel { get { - return Parent != null && Parent.Parent == null; + return !(Parent is TypeDefinition); + } + } + + public bool IsPartial { + get { + return (ModFlags & Modifiers.PARTIAL) != 0; + } + } + + // + // Returns true for secondary partial containers + // + bool IsPartialPart { + get { + return PartialContainer != this; + } + } + + public MemberCache MemberCache { + get { + return spec.MemberCache; + } + } + + public List Members { + get { + return members; } } string ITypeDefinition.Namespace { get { - return NamespaceEntry.NS.MemberName.GetSignatureForError (); + var p = Parent; + while (p.Kind != MemberKind.Namespace) + p = p.Parent; + + return p.MemberName == null ? null : p.GetSignatureForError (); } } @@ -411,62 +721,66 @@ namespace Mono.CSharp visitor.Visit (this); } - public bool AddMember (MemberCore symbol) + public void AddMember (MemberCore symbol) { - return AddToContainer (symbol, symbol.MemberName.Basename); - } + if (symbol.MemberName.ExplicitInterface != null) { + if (!(Kind == MemberKind.Class || Kind == MemberKind.Struct)) { + Report.Error (541, symbol.Location, + "`{0}': explicit interface declaration can only be declared in a class or struct", + symbol.GetSignatureForError ()); + } + } - public bool AddMember (MemberCore symbol, string name) - { - return AddToContainer (symbol, name); + AddNameToContainer (symbol, symbol.MemberName.Basename); + members.Add (symbol); } - protected virtual bool AddMemberType (TypeContainer ds) + public override void AddTypeContainer (TypeContainer tc) { - return AddToContainer (ds, ds.Basename); - } + AddNameToContainer (tc, tc.Basename); - protected virtual void RemoveMemberType (TypeContainer ds) - { - defined_names.Remove (ds.Basename); + if (containers == null) + containers = new List (); + + members.Add (tc); + base.AddTypeContainer (tc); } - public void AddConstant (Const constant) + public override void AddCompilerGeneratedClass (CompilerGeneratedContainer c) { - orderedAllMembers.Add (constant); - if (!AddMember (constant)) - return; - - if (constants == null) - constants = new List (); - constants.Add (constant); + members.Add (c); + + if (containers == null) + containers = new List (); + + base.AddCompilerGeneratedClass (c); } // // Adds the member to defined_names table. It tests for duplications and enclosing name conflicts // - protected virtual bool AddToContainer (MemberCore symbol, string name) + public virtual void AddNameToContainer (MemberCore symbol, string name) { + if (((ModFlags | symbol.ModFlags) & Modifiers.COMPILER_GENERATED) != 0) + return; + MemberCore mc; - if (!defined_names.TryGetValue (name, out mc)) { - defined_names.Add (name, symbol); - return true; + if (!PartialContainer.defined_names.TryGetValue (name, out mc)) { + PartialContainer.defined_names.Add (name, symbol); + return; } - if (((mc.ModFlags | symbol.ModFlags) & Modifiers.COMPILER_GENERATED) != 0) - return true; - if (symbol.EnableOverloadChecks (mc)) - return true; + return; InterfaceMemberBase im = mc as InterfaceMemberBase; if (im != null && im.IsExplicitImpl) - return true; + return; Report.SymbolRelatedToPreviousError (mc); if ((mc.ModFlags & Modifiers.PARTIAL) != 0 && (symbol is ClassOrStruct || symbol is Interface)) { Error_MissingPartialModifier (symbol); - return false; + return; } if (symbol is TypeParameter) { @@ -478,348 +792,89 @@ namespace Mono.CSharp GetSignatureForError (), name); } - return false; + return; } - public TypeContainer AddTypeContainer (TypeContainer tc) - { - orderedAllMembers.Add (tc); - if (!AddMemberType (tc)) - return tc; - - var tparams = tc.MemberName.TypeParameters; - if (tparams != null) { - for (int i = 0; i < tparams.Count; ++i) { - var tp = tparams[i]; - if (tp.MemberName == null) - continue; - - tc.AddMember (tp, tp.Name); - } - } - - if (types == null) - types = new List (); - - types.Add (tc); - return tc; - } - - public virtual TypeContainer AddPartial (TypeContainer next_part) - { - return AddPartial (next_part, next_part.Basename); - } - - protected TypeContainer AddPartial (TypeContainer next_part, string name) - { - next_part.ModFlags |= Modifiers.PARTIAL; - TypeContainer tc = GetDefinition (name) as TypeContainer; - if (tc == null) - return AddTypeContainer (next_part); - - if ((tc.ModFlags & Modifiers.PARTIAL) == 0) { - Report.SymbolRelatedToPreviousError (next_part); - Error_MissingPartialModifier (tc); - } - - if (tc.Kind != next_part.Kind) { - Report.SymbolRelatedToPreviousError (tc); - Report.Error (261, next_part.Location, - "Partial declarations of `{0}' must be all classes, all structs or all interfaces", - next_part.GetSignatureForError ()); - } - - if ((tc.ModFlags & Modifiers.AccessibilityMask) != (next_part.ModFlags & Modifiers.AccessibilityMask) && - ((tc.ModFlags & Modifiers.DEFAULT_ACCESS_MODIFER) == 0 && - (next_part.ModFlags & Modifiers.DEFAULT_ACCESS_MODIFER) == 0)) { - Report.SymbolRelatedToPreviousError (tc); - Report.Error (262, next_part.Location, - "Partial declarations of `{0}' have conflicting accessibility modifiers", - next_part.GetSignatureForError ()); - } - - var tc_names = tc.CurrentTypeParameters; - if (tc_names != null) { - for (int i = 0; i < tc_names.Count; ++i) { - var tp = next_part.MemberName.TypeParameters[i]; - if (tc_names[i].MemberName.Name != tp.MemberName.Name) { - Report.SymbolRelatedToPreviousError (tc.Location, ""); - Report.Error (264, next_part.Location, "Partial declarations of `{0}' must have the same type parameter names in the same order", - next_part.GetSignatureForError ()); - break; - } - - if (tc_names[i].Variance != tp.Variance) { - Report.SymbolRelatedToPreviousError (tc.Location, ""); - Report.Error (1067, next_part.Location, "Partial declarations of `{0}' must have the same type parameter variance modifiers", - next_part.GetSignatureForError ()); - break; - } - } - } - - if (tc.partial_parts == null) - tc.partial_parts = new List (1); - - if ((next_part.ModFlags & Modifiers.DEFAULT_ACCESS_MODIFER) != 0) { - tc.ModFlags |= next_part.ModFlags & ~(Modifiers.DEFAULT_ACCESS_MODIFER | Modifiers.AccessibilityMask); - } else if ((tc.ModFlags & Modifiers.DEFAULT_ACCESS_MODIFER) != 0) { - tc.ModFlags &= ~(Modifiers.DEFAULT_ACCESS_MODIFER | Modifiers.AccessibilityMask); - tc.ModFlags |= next_part.ModFlags; - } else { - tc.ModFlags |= next_part.ModFlags; - } - - tc.spec.Modifiers = tc.ModFlags; - - if (next_part.attributes != null) { - if (tc.attributes == null) - tc.attributes = next_part.attributes; - else - tc.attributes.AddAttributes (next_part.attributes.Attrs); - } - - next_part.PartialContainer = tc; - tc.partial_parts.Add (next_part); - return tc; - } - - public virtual void RemoveTypeContainer (TypeContainer next_part) - { - if (types != null) - types.Remove (next_part); - - Cache.Remove (next_part.Basename); - RemoveMemberType (next_part); - } - - public void AddDelegate (Delegate d) - { - AddTypeContainer (d); - } - - private void AddMemberToList (InterfaceMemberBase mc, List alist) - { - if (ordered_explicit_member_list == null) { - ordered_explicit_member_list = new List (); - ordered_member_list = new List (); - } - - if (mc.IsExplicitImpl) { - if (Kind == MemberKind.Interface) { - Report.Error (541, mc.Location, - "`{0}': explicit interface declaration can only be declared in a class or struct", - mc.GetSignatureForError ()); - } - - ordered_explicit_member_list.Add (mc); - alist.Insert (0, mc); - } else { - ordered_member_list.Add (mc); - alist.Add (mc); - } - - } - - public void AddMethod (MethodOrOperator method) + public void AddConstructor (Constructor c) { - orderedAllMembers.Add (method); - if (!AddToContainer (method, method.MemberName.Basename)) - return; - - if (methods == null) - methods = new List (); - - AddMemberToList (method, methods); + AddConstructor (c, false); } - public void AddConstructor (Constructor c) + public void AddConstructor (Constructor c, bool isDefault) { - orderedAllMembers.Add (c); bool is_static = (c.ModFlags & Modifiers.STATIC) != 0; - if (!AddToContainer (c, is_static ? Constructor.ConstructorName : Constructor.TypeConstructorName)) - return; - - if (is_static && c.ParameterInfo.IsEmpty){ - if (default_static_constructor != null) { - Report.SymbolRelatedToPreviousError (default_static_constructor); - Report.Error (111, c.Location, - "A member `{0}' is already defined. Rename this member or use different parameter types", - c.GetSignatureForError ()); - return; - } + if (!isDefault) + AddNameToContainer (c, is_static ? Constructor.TypeConstructorName : Constructor.ConstructorName); - default_static_constructor = c; + if (is_static && c.ParameterInfo.IsEmpty) { + PartialContainer.has_static_constructor = true; } else { - if (c.ParameterInfo.IsEmpty) - default_constructor = c; - if (instance_constructors == null) - instance_constructors = new List (); - - instance_constructors.Add (c); + PartialContainer.HasInstanceConstructor = true; } + + members.Add (c); } public bool AddField (FieldBase field) { - orderedAllMembers.Add (field); - if (!AddMember (field)) - return false; - if (fields == null) - fields = new List (); - - fields.Add (field); + AddMember (field); if ((field.ModFlags & Modifiers.STATIC) != 0) return true; - if (first_nonstatic_field == null) { - first_nonstatic_field = field; + var first_field = PartialContainer.first_nonstatic_field; + if (first_field == null) { + PartialContainer.first_nonstatic_field = field; return true; } - if (Kind == MemberKind.Struct && first_nonstatic_field.Parent != field.Parent) { - Report.SymbolRelatedToPreviousError (first_nonstatic_field.Parent); + if (Kind == MemberKind.Struct && first_field.Parent != field.Parent) { + Report.SymbolRelatedToPreviousError (first_field.Parent); Report.Warning (282, 3, field.Location, "struct instance field `{0}' found in different declaration from instance field `{1}'", - field.GetSignatureForError (), first_nonstatic_field.GetSignatureForError ()); + field.GetSignatureForError (), first_field.GetSignatureForError ()); } return true; } - public void AddProperty (Property prop) - { - orderedAllMembers.Add (prop); - if (!AddMember (prop)) - return; - if (properties == null) - properties = new List (); - - AddMemberToList (prop, properties); - } - - public void AddEvent (Event e) - { - orderedAllMembers.Add (e); - if (!AddMember (e)) - return; - if (events == null) - events = new List (); - - events.Add (e); - } - /// /// Indexer has special handling in constrast to other AddXXX because the name can be driven by IndexerNameAttribute /// public void AddIndexer (Indexer i) { - orderedAllMembers.Add (i); - if (indexers == null) - indexers = new List (); - - AddMemberToList (i, indexers); + members.Add (i); } public void AddOperator (Operator op) - { - orderedAllMembers.Add (op); - if (!AddMember (op)) - return; - if (operators == null) - operators = new List (); - - operators.Add (op); - } - - public void AddCompilerGeneratedClass (CompilerGeneratedClass c) - { - if (compiler_generated == null) - compiler_generated = new List (); - - compiler_generated.Add (c); - } - - public override void ApplyAttributeBuilder (Attribute a, MethodSpec ctor, byte[] cdata, PredefinedAttributes pa) - { - if (a.Type == pa.DefaultMember) { - if (Indexers != null) { - Report.Error (646, a.Location, "Cannot specify the `DefaultMember' attribute on type containing an indexer"); - return; - } - } - - if (a.Type == pa.Required) { - Report.Error (1608, a.Location, "The RequiredAttribute attribute is not permitted on C# types"); - return; - } - - TypeBuilder.SetCustomAttribute ((ConstructorInfo) ctor.GetMetaInfo (), cdata); - } - - public override AttributeTargets AttributeTargets { - get { - throw new NotSupportedException (); - } - } - - public IList Types { - get { - return types; - } - } - - public IList Methods { - get { - return methods; - } - } - - public IList Constants { - get { - return constants; - } - } - - public TypeSpec BaseType { - get { - return spec.BaseType; - } - } - - public IList Fields { - get { - return fields; - } - } - - public IList InstanceConstructors { - get { - return instance_constructors; - } + { + PartialContainer.HasOperators = true; + AddMember (op); } - public IList Properties { - get { - return properties; + public override void ApplyAttributeBuilder (Attribute a, MethodSpec ctor, byte[] cdata, PredefinedAttributes pa) + { + if (has_normal_indexers && a.Type == pa.DefaultMember) { + Report.Error (646, a.Location, "Cannot specify the `DefaultMember' attribute on type containing an indexer"); + return; } - } - public IList Events { - get { - return events; + if (a.Type == pa.Required) { + Report.Error (1608, a.Location, "The RequiredAttribute attribute is not permitted on C# types"); + return; } - } - - public IList Indexers { + + TypeBuilder.SetCustomAttribute ((ConstructorInfo) ctor.GetMetaInfo (), cdata); + } + + public override AttributeTargets AttributeTargets { get { - return indexers; + throw new NotSupportedException (); } } - public IList Operators { + public TypeSpec BaseType { get { - return operators; + return spec.BaseType; } } @@ -843,7 +898,7 @@ namespace Mono.CSharp public string GetAttributeDefaultMember () { - return indexers == null ? DefaultIndexerName : indexer_name; + return indexer_name ?? DefaultIndexerName; } public bool IsComImport { @@ -857,9 +912,12 @@ namespace Mono.CSharp public virtual void RegisterFieldForInitialization (MemberCore field, FieldInitializer expression) { + if (IsPartialPart) + PartialContainer.RegisterFieldForInitialization (field, expression); + if ((field.ModFlags & Modifiers.STATIC) != 0){ if (initialized_static_fields == null) { - PartialContainer.HasStaticFieldInitializer = true; + HasStaticFieldInitializer = true; initialized_static_fields = new List (4); } @@ -874,16 +932,8 @@ namespace Mono.CSharp public void ResolveFieldInitializers (BlockContext ec) { - if (partial_parts != null) { - foreach (TypeContainer part in partial_parts) { - part.DoResolveFieldInitializers (ec); - } - } - DoResolveFieldInitializers (ec); - } + Debug.Assert (!IsPartialPart); - void DoResolveFieldInitializers (BlockContext ec) - { if (ec.IsStatic) { if (initialized_static_fields == null) return; @@ -958,44 +1008,8 @@ namespace Mono.CSharp { base.GenerateDocComment (builder); - if (DefaultStaticConstructor != null) - DefaultStaticConstructor.GenerateDocComment (builder); - - if (InstanceConstructors != null) - foreach (Constructor c in InstanceConstructors) - c.GenerateDocComment (builder); - - if (Types != null) - foreach (TypeContainer tc in Types) - tc.GenerateDocComment (builder); - - if (Constants != null) - foreach (Const c in Constants) - c.GenerateDocComment (builder); - - if (Fields != null) - foreach (FieldBase f in Fields) - f.GenerateDocComment (builder); - - if (Events != null) - foreach (Event e in Events) - e.GenerateDocComment (builder); - - if (Indexers != null) - foreach (Indexer ix in Indexers) - ix.GenerateDocComment (builder); - - if (Properties != null) - foreach (Property p in Properties) - p.GenerateDocComment (builder); - - if (Methods != null) - foreach (MethodOrOperator m in Methods) - m.GenerateDocComment (builder); - - if (Operators != null) - foreach (Operator o in Operators) - o.GenerateDocComment (builder); + foreach (var member in members) + member.GenerateDocComment (builder); } public TypeSpec GetAttributeCoClass () @@ -1023,9 +1037,21 @@ namespace Mono.CSharp return a.GetAttributeUsageAttribute (); } - public virtual void AddBasesForPart (TypeContainer part, List bases) + public virtual CompilationSourceFile GetCompilationSourceFile () + { + TypeContainer ns = Parent; + while (true) { + var sf = ns as CompilationSourceFile; + if (sf != null) + return sf; + + ns = ns.Parent; + } + } + + public virtual void AddBasesForPart (List bases) { - part.type_bases = bases; + type_bases = bases; } /// @@ -1103,67 +1129,6 @@ namespace Mono.CSharp return ifaces; } - // - // Returns the MemberCore associated with a given name in the declaration - // space. It doesn't return method based symbols !! - // - // TODO: protected or private - // - public MemberCore GetDefinition (string name) - { - MemberCore mc = null; - defined_names.TryGetValue (name, out mc); - return mc; - } - - TypeSpec[] GetNormalPartialBases () - { - var ifaces = new List (0); - if (iface_exprs != null) - ifaces.AddRange (iface_exprs); - - foreach (TypeContainer part in partial_parts) { - FullNamedExpression new_base_class; - var new_ifaces = part.ResolveBaseTypes (out new_base_class); - if (new_base_class != null) { - if (base_type_expr != null && part.base_type != base_type) { - Report.SymbolRelatedToPreviousError (new_base_class.Location, ""); - Report.Error (263, part.Location, - "Partial declarations of `{0}' must not specify different base classes", - part.GetSignatureForError ()); - } else { - base_type_expr = new_base_class; - base_type = part.base_type; - } - } - - if (new_ifaces == null) - continue; - - foreach (var iface in new_ifaces) { - if (ifaces.Contains (iface)) - continue; - - ifaces.Add (iface); - } - } - - if (ifaces.Count == 0) - return null; - - return ifaces.ToArray (); - } - - public override string GetSignatureForDocumentation () - { - return MemberName.GetName (true); - } - - public override string GetSignatureForError () - { - return MemberName.GetSignatureForError (); - } - // // Checks that some operators come in pairs: // == and != @@ -1176,26 +1141,28 @@ namespace Mono.CSharp void CheckPairedOperators () { bool has_equality_or_inequality = false; - var operators = this.operators.ToArray (); - bool[] has_pair = new bool[operators.Length]; + List found_matched = new List (); - for (int i = 0; i < operators.Length; ++i) { - if (operators[i] == null) + for (int i = 0; i < members.Count; ++i) { + var o_a = members[i] as Operator; + if (o_a == null) continue; - Operator o_a = (Operator) operators[i]; - Operator.OpType o_type = o_a.OperatorType; + var o_type = o_a.OperatorType; if (o_type == Operator.OpType.Equality || o_type == Operator.OpType.Inequality) has_equality_or_inequality = true; - Operator.OpType matching_type = o_a.GetMatchingOperator (); + if (found_matched.Contains (o_type)) + continue; + + var matching_type = o_a.GetMatchingOperator (); if (matching_type == Operator.OpType.TOP) { - operators[i] = null; continue; } - for (int ii = 0; ii < operators.Length; ++ii) { - Operator o_b = (Operator) operators[ii]; + bool pair_found = false; + for (int ii = i + 1; ii < members.Count; ++ii) { + var o_b = members[ii] as Operator; if (o_b == null || o_b.OperatorType != matching_type) continue; @@ -1205,35 +1172,41 @@ namespace Mono.CSharp if (!TypeSpecComparer.Equals (o_a.ParameterTypes, o_b.ParameterTypes)) continue; - operators[i] = null; - - // - // Used to ignore duplicate user conversions - // - has_pair[ii] = true; + found_matched.Add (matching_type); + pair_found = true; + break; } - } - - for (int i = 0; i < operators.Length; ++i) { - if (operators[i] == null || has_pair[i]) - continue; - Operator o = (Operator) operators [i]; - Report.Error (216, o.Location, - "The operator `{0}' requires a matching operator `{1}' to also be defined", - o.GetSignatureForError (), Operator.GetName (o.GetMatchingOperator ())); + if (!pair_found) { + Report.Error (216, o_a.Location, + "The operator `{0}' requires a matching operator `{1}' to also be defined", + o_a.GetSignatureForError (), Operator.GetName (matching_type)); + } } if (has_equality_or_inequality) { - if (Methods == null || !HasEquals) + if (!HasEquals) Report.Warning (660, 2, Location, "`{0}' defines operator == or operator != but does not override Object.Equals(object o)", GetSignatureForError ()); - if (Methods == null || !HasGetHashCode) + if (!HasGetHashCode) Report.Warning (661, 2, Location, "`{0}' defines operator == or operator != but does not override Object.GetHashCode()", GetSignatureForError ()); } } + + public override void CreateMetadataName (StringBuilder sb) + { + if (Parent.MemberName != null) { + Parent.CreateMetadataName (sb); + + if (sb.Length != 0) { + sb.Append ("."); + } + } + + sb.Append (MemberName.Basename); + } bool CreateTypeBuilder () { @@ -1242,10 +1215,13 @@ namespace Mono.CSharp // int type_size = Kind == MemberKind.Struct && first_nonstatic_field == null ? 1 : 0; - if (IsTopLevel) { - TypeBuilder = Module.CreateBuilder (MemberName.GetName (true), TypeAttr, type_size); + var parent_def = Parent as TypeDefinition; + if (parent_def == null) { + var sb = new StringBuilder (); + CreateMetadataName (sb); + TypeBuilder = Module.CreateBuilder (sb.ToString (), TypeAttr, type_size); } else { - TypeBuilder = Parent.TypeBuilder.DefineNestedType (Basename, TypeAttr, null, type_size); + TypeBuilder = parent_def.TypeBuilder.DefineNestedType (Basename, TypeAttr, null, type_size); } if (DeclaringAssembly.Importer != null) @@ -1253,13 +1229,16 @@ namespace Mono.CSharp spec.SetMetaInfo (TypeBuilder); spec.MemberCache = new MemberCache (this); - spec.DeclaringType = Parent.CurrentType; - if (!IsTopLevel) - Parent.MemberCache.AddMember (spec); + TypeParameters parentAllTypeParameters = null; + if (parent_def != null) { + spec.DeclaringType = Parent.CurrentType; + parent_def.MemberCache.AddMember (spec); + parentAllTypeParameters = parent_def.all_type_parameters; + } - if (MemberName.TypeParameters != null || Parent.IsGenericOrParentIsGeneric) { - var tparam_names = CreateTypeParameters (); + if (MemberName.TypeParameters != null || parentAllTypeParameters != null) { + var tparam_names = CreateTypeParameters (parentAllTypeParameters); all_tp_builders = TypeBuilder.DefineGenericParameters (tparam_names); @@ -1270,20 +1249,19 @@ namespace Mono.CSharp return true; } - string[] CreateTypeParameters () + string[] CreateTypeParameters (TypeParameters parentAllTypeParameters) { string[] names; int parent_offset = 0; - var parent_all = Parent.all_type_parameters; - if (parent_all != null) { + if (parentAllTypeParameters != null) { if (CurrentTypeParameters == null) { - all_type_parameters = Parent.all_type_parameters; - return Parent.all_tp_builders.Select (l => l.Name).ToArray (); + all_type_parameters = parentAllTypeParameters; + return parentAllTypeParameters.GetAllNames (); } - names = new string[parent_all.Count + CurrentTypeParameters.Count]; + names = new string[parentAllTypeParameters.Count + CurrentTypeParameters.Count]; all_type_parameters = new TypeParameters (names.Length); - all_type_parameters.Add (Parent.all_type_parameters); + all_type_parameters.Add (parentAllTypeParameters); parent_offset = all_type_parameters.Count; for (int i = 0; i < parent_offset; ++i) @@ -1317,6 +1295,18 @@ namespace Mono.CSharp } + public SourceMethodBuilder CreateMethodSymbolEntry () + { + if (Module.DeclaringAssembly.SymbolWriter == null) + return null; + + var source_file = GetCompilationSourceFile (); + if (source_file == null) + return null; + + return new SourceMethodBuilder (source_file.SymbolUnitEntry); + } + // // Creates a proxy base method call inside this container for hoisted base member calls // @@ -1335,7 +1325,7 @@ namespace Mono.CSharp } if (proxy_method == null) { - string name = CompilerGeneratedClass.MakeName (method.Name, null, "BaseCallProxy", hoisted_base_call_proxies.Count); + string name = CompilerGeneratedContainer.MakeName (method.Name, null, "BaseCallProxy", hoisted_base_call_proxies.Count); var base_parameters = new Parameter[method.Parameters.Count]; for (int i = 0; i < base_parameters.Length; ++i) { var base_param = method.Parameters.FixedParameters[i]; @@ -1379,7 +1369,9 @@ namespace Mono.CSharp Modifiers.PRIVATE | Modifiers.COMPILER_GENERATED | Modifiers.DEBUGGER_HIDDEN, member_name, cloned_params, null); - var block = new ToplevelBlock (Compiler, proxy_method.ParameterInfo, Location); + var block = new ToplevelBlock (Compiler, proxy_method.ParameterInfo, Location) { + IsCompilerGenerated = true + }; var mg = MethodGroupExpr.CreatePredefined (method, method.DeclaringType, Location); mg.InstanceExpression = new BaseThis (method.DeclaringType, Location); @@ -1397,7 +1389,7 @@ namespace Mono.CSharp block.AddStatement (statement); proxy_method.Block = block; - methods.Add (proxy_method); + members.Add (proxy_method); proxy_method.Define (); hoisted_base_call_proxies.Add (method, proxy_method); @@ -1406,11 +1398,55 @@ namespace Mono.CSharp return proxy_method.Spec; } - bool DefineBaseTypes () + protected bool DefineBaseTypes () { iface_exprs = ResolveBaseTypes (out base_type_expr); - if (partial_parts != null) { - iface_exprs = GetNormalPartialBases (); + bool set_base_type; + + if (IsPartialPart) { + set_base_type = false; + + if (base_type_expr != null) { + if (PartialContainer.base_type_expr != null && PartialContainer.base_type != base_type) { + Report.SymbolRelatedToPreviousError (base_type_expr.Location, ""); + Report.Error (263, Location, + "Partial declarations of `{0}' must not specify different base classes", + GetSignatureForError ()); + } else { + PartialContainer.base_type_expr = base_type_expr; + PartialContainer.base_type = base_type; + set_base_type = true; + } + } + + if (iface_exprs != null) { + if (PartialContainer.iface_exprs == null) + PartialContainer.iface_exprs = iface_exprs; + else { + var ifaces = new List (PartialContainer.iface_exprs); + foreach (var iface_partial in iface_exprs) { + if (ifaces.Contains (iface_partial)) + continue; + + ifaces.Add (iface_partial); + } + + PartialContainer.iface_exprs = ifaces.ToArray (); + } + } + + PartialContainer.members.AddRange (members); + if (containers != null) { + if (PartialContainer.containers == null) + PartialContainer.containers = new List (); + + PartialContainer.containers.AddRange (containers); + } + + members_defined = members_defined_ok = true; + caching_flags |= Flags.CloseTypeCreated; + } else { + set_base_type = true; } var cycle = CheckRecursiveDefinition (this); @@ -1446,7 +1482,7 @@ namespace Mono.CSharp var compiled_iface = iface_type.MemberDefinition as Interface; if (compiled_iface != null) { // TODO: Need DefineBaseType only - compiled_iface.DefineType (); + compiled_iface.DefineContainer (); } if (iface_type.Interfaces != null) { @@ -1469,60 +1505,48 @@ namespace Mono.CSharp return true; } - if (base_type != null) { - spec.BaseType = base_type; + if (set_base_type) { + if (base_type != null) { + spec.BaseType = base_type; - // Set base type after type creation - TypeBuilder.SetParent (base_type.GetMetaInfo ()); - } else { - TypeBuilder.SetParent (null); + // Set base type after type creation + TypeBuilder.SetParent (base_type.GetMetaInfo ()); + } else { + TypeBuilder.SetParent (null); + } } return true; } - public virtual void DefineConstants () + public override void PrepareEmit () { - if (constants != null) { - foreach (Const c in constants) { - c.DefineValue (); - } - } + if ((caching_flags & Flags.CloseTypeCreated) != 0) + return; - if (instance_constructors != null) { - foreach (MethodCore m in instance_constructors) { - var p = m.ParameterInfo; - if (!p.IsEmpty) { - p.ResolveDefaultValues (m); - } - } - } + foreach (var member in members) { + var pm = member as IParametersMember; + if (pm != null) { - if (methods != null) { - foreach (MethodCore m in methods) { - var p = m.ParameterInfo; - if (!p.IsEmpty) { - p.ResolveDefaultValues (m); - } - } - } + var p = pm.Parameters; + if (p.IsEmpty) + continue; - if (indexers != null) { - foreach (Indexer i in indexers) { - i.ParameterInfo.ResolveDefaultValues (i); + ((ParametersCompiled) p).ResolveDefaultValues (member); } - } - if (types != null) { - foreach (var t in types) - t.DefineConstants (); + var c = member as Const; + if (c != null) + c.DefineValue (); } + + base.PrepareEmit (); } // // Defines the type in the appropriate ModuleBuilder or TypeBuilder. // - public bool CreateType () + public override bool CreateContainer () { if (TypeBuilder != null) return !error; @@ -1530,57 +1554,26 @@ namespace Mono.CSharp if (error) return false; - if (!CreateTypeBuilder ()) { - error = true; - return false; - } - - if (partial_parts != null) { - foreach (TypeContainer part in partial_parts) { - part.spec = spec; - part.current_type = current_type; - part.TypeBuilder = TypeBuilder; - part.all_type_parameters = all_type_parameters; - part.all_tp_builders = all_tp_builders; - } - } - - if (Types != null) { - foreach (TypeContainer tc in Types) { - tc.CreateType (); + if (IsPartialPart) { + spec = PartialContainer.spec; + TypeBuilder = PartialContainer.TypeBuilder; + all_tp_builders = PartialContainer.all_tp_builders; + all_type_parameters = PartialContainer.all_type_parameters; + } else { + if (!CreateTypeBuilder ()) { + error = true; + return false; } } - return true; + return base.CreateContainer (); } - public void DefineType () + protected override void DoDefineContainer () { - if (error) - return; - if (type_defined) - return; - - type_defined = true; - - // Nested type share same namespace - if (IsTopLevel && !IsCompilerGenerated) { - NamespaceEntry.Define (); - if (partial_parts != null) { - foreach (var part in partial_parts) - part.NamespaceEntry.Define (); - } - } - - if (!DefineBaseTypes ()) { - error = true; - return; - } + DefineBaseTypes (); - if (!DefineNestedTypes ()) { - error = true; - return; - } + DoResolveTypeParameters (); } // @@ -1605,7 +1598,7 @@ namespace Mono.CSharp current_type = null; } - void UpdateTypeParameterConstraints (TypeContainer part) + void UpdateTypeParameterConstraints (TypeDefinition part) { for (int i = 0; i < CurrentTypeParameters.Count; i++) { if (CurrentTypeParameters[i].AddPartialConstraints (part, part.MemberName.TypeParameters[i])) @@ -1618,24 +1611,11 @@ namespace Mono.CSharp } } - public bool ResolveTypeParameters () + public override void RemoveContainer (TypeContainer cont) { - if (!DoResolveTypeParameters ()) - return false; - - if (types != null) { - foreach (var type in types) - if (!type.ResolveTypeParameters ()) - return false; - } - - if (compiler_generated != null) { - foreach (CompilerGeneratedClass c in compiler_generated) - if (!c.ResolveTypeParameters ()) - return false; - } - - return true; + base.RemoveContainer (cont); + Members.Remove (cont); + Cache.Remove (cont.Basename); } protected virtual bool DoResolveTypeParameters () @@ -1644,9 +1624,6 @@ namespace Mono.CSharp if (tparams == null) return true; - if (PartialContainer != this) - throw new InternalErrorException (); - var base_context = new BaseContext (this); for (int i = 0; i < tparams.Count; ++i) { var tp = tparams[i]; @@ -1657,25 +1634,14 @@ namespace Mono.CSharp } } - if (partial_parts != null) { - foreach (TypeContainer part in partial_parts) - UpdateTypeParameterConstraints (part); - } - - return true; - } - - protected virtual bool DefineNestedTypes () - { - if (Types != null) { - foreach (TypeContainer tc in Types) - tc.DefineType (); + if (IsPartialPart) { + PartialContainer.UpdateTypeParameterConstraints (this); } return true; } - TypeSpec CheckRecursiveDefinition (TypeContainer tc) + TypeSpec CheckRecursiveDefinition (TypeDefinition tc) { if (InTransit != null) return spec; @@ -1683,7 +1649,7 @@ namespace Mono.CSharp InTransit = tc; if (base_type != null) { - var ptc = base_type.MemberDefinition as TypeContainer; + var ptc = base_type.MemberDefinition as TypeDefinition; if (ptc != null && ptc.CheckRecursiveDefinition (this) != null) return base_type; } @@ -1717,16 +1683,15 @@ namespace Mono.CSharp members_defined_ok = DoDefineMembers (); members_defined = true; - if (types != null) { - foreach (var nested in types) - nested.Define (); - } + base.Define (); return members_defined_ok; } protected virtual bool DoDefineMembers () { + Debug.Assert (!IsPartialPart); + if (iface_exprs != null) { foreach (var iface_type in iface_exprs) { if (iface_type == null) @@ -1807,251 +1772,213 @@ namespace Mono.CSharp } } - DefineContainerMembers (constants); - DefineContainerMembers (fields); - if (Kind == MemberKind.Struct || Kind == MemberKind.Class) { pending = PendingImplementation.GetPendingImplementations (this); - - if (requires_delayed_unmanagedtype_check) { - requires_delayed_unmanagedtype_check = false; - foreach (FieldBase f in fields) { - if (f.MemberType != null && f.MemberType.IsPointer) - TypeManager.VerifyUnmanaged (Module, f.MemberType, f.Location); - } - } - } - - // - // Constructors are not in the defined_names array - // - DefineContainerMembers (instance_constructors); - - DefineContainerMembers (events); - DefineContainerMembers (ordered_explicit_member_list); - DefineContainerMembers (ordered_member_list); - - if (operators != null) { - DefineContainerMembers (operators); - CheckPairedOperators (); - } - - ComputeIndexerName(); - CheckEqualsAndGetHashCode(); - - if (Kind == MemberKind.Interface && iface_exprs != null) { - MemberCache.RemoveHiddenMembers (spec); } - return true; - } + var count = members.Count; + for (int i = 0; i < count; ++i) { + var mc = members[i] as InterfaceMemberBase; + if (mc == null || !mc.IsExplicitImpl) + continue; - protected virtual void DefineContainerMembers (System.Collections.IList mcal) // IList - { - if (mcal != null) { - for (int i = 0; i < mcal.Count; ++i) { - MemberCore mc = (MemberCore) mcal[i]; - try { - mc.Define (); - } catch (Exception e) { - throw new InternalErrorException (mc, e); - } + try { + mc.Define (); + } catch (Exception e) { + throw new InternalErrorException (mc, e); } } - } - - protected virtual void ComputeIndexerName () - { - if (indexers == null) - return; - - string class_indexer_name = null; - - // - // If there's both an explicit and an implicit interface implementation, the - // explicit one actually implements the interface while the other one is just - // a normal indexer. See bug #37714. - // - // Invariant maintained by AddIndexer(): All explicit interface indexers precede normal indexers - foreach (Indexer i in indexers) { - if (i.InterfaceType != null) { - if (seen_normal_indexers) - throw new Exception ("Internal Error: 'Indexers' array not sorted properly."); + for (int i = 0; i < count; ++i) { + var mc = members[i] as InterfaceMemberBase; + if (mc != null && mc.IsExplicitImpl) continue; - } - - seen_normal_indexers = true; - if (class_indexer_name == null) { - class_indexer_name = i.ShortName; + if (members[i] is TypeContainer) continue; - } - if (i.ShortName != class_indexer_name) - Report.Error (668, i.Location, "Two indexers have different names; the IndexerName attribute must be used with the same name on every indexer within a type"); + try { + members[i].Define (); + } catch (Exception e) { + throw new InternalErrorException (members[i], e); + } } - if (class_indexer_name != null) - indexer_name = class_indexer_name; - } - - void EmitIndexerName () - { - if (!seen_normal_indexers) - return; - - var ctor = Module.PredefinedMembers.DefaultMemberAttributeCtor.Get (); - if (ctor == null) - return; - - var encoder = new AttributeEncoder (); - encoder.Encode (GetAttributeDefaultMember ()); - encoder.EncodeEmptyNamedArguments (); + if (HasOperators) { + CheckPairedOperators (); + } - TypeBuilder.SetCustomAttribute ((ConstructorInfo) ctor.GetMetaInfo (), encoder.ToArray ()); - } + if (requires_delayed_unmanagedtype_check) { + requires_delayed_unmanagedtype_check = false; + foreach (var member in members) { + var f = member as Field; + if (f != null && f.MemberType != null && f.MemberType.IsPointer) + TypeManager.VerifyUnmanaged (Module, f.MemberType, f.Location); + } + } - protected virtual void CheckEqualsAndGetHashCode () - { - if (methods == null) - return; + ComputeIndexerName(); if (HasEquals && !HasGetHashCode) { - Report.Warning (659, 3, this.Location, "`{0}' overrides Object.Equals(object) but does not override Object.GetHashCode()", this.GetSignatureForError ()); + Report.Warning (659, 3, Location, + "`{0}' overrides Object.Equals(object) but does not override Object.GetHashCode()", GetSignatureForError ()); } - } - - // Indicated whether container has StructLayout attribute set Explicit - public bool HasExplicitLayout { - get { return (caching_flags & Flags.HasExplicitLayout) != 0; } - set { caching_flags |= Flags.HasExplicitLayout; } - } - public bool HasStructLayout { - get { return (caching_flags & Flags.HasStructLayout) != 0; } - set { caching_flags |= Flags.HasStructLayout; } - } - - public MemberCache MemberCache { - get { - return spec.MemberCache; + if (Kind == MemberKind.Interface && iface_exprs != null) { + MemberCache.RemoveHiddenMembers (spec); } + + return true; } - void CheckMemberUsage (List al, string member_type) + void ComputeIndexerName () { - if (al == null) + var indexers = MemberCache.FindMembers (spec, MemberCache.IndexerNameAlias, true); + if (indexers == null) return; - foreach (MemberCore mc in al) { - if ((mc.ModFlags & Modifiers.AccessibilityMask) != Modifiers.PRIVATE) - continue; + string class_indexer_name = null; + has_normal_indexers = true; - if ((mc.ModFlags & Modifiers.PARTIAL) != 0) + // + // Check normal indexers for consistent name, explicit interface implementation + // indexers are ignored + // + foreach (var indexer in indexers) { + if (class_indexer_name == null) { + indexer_name = class_indexer_name = indexer.Name; continue; - - if (!mc.IsUsed && (mc.caching_flags & Flags.Excluded) == 0) { - Report.Warning (169, 3, mc.Location, "The private {0} `{1}' is never used", member_type, mc.GetSignatureForError ()); } + + if (indexer.Name != class_indexer_name) + Report.Error (668, ((Indexer)indexer.MemberDefinition).Location, + "Two indexers have different names; the IndexerName attribute must be used with the same name on every indexer within a type"); } } - public virtual void VerifyMembers () + void EmitIndexerName () + { + if (!has_normal_indexers) + return; + + var ctor = Module.PredefinedMembers.DefaultMemberAttributeCtor.Get (); + if (ctor == null) + return; + + var encoder = new AttributeEncoder (); + encoder.Encode (GetAttributeDefaultMember ()); + encoder.EncodeEmptyNamedArguments (); + + TypeBuilder.SetCustomAttribute ((ConstructorInfo) ctor.GetMetaInfo (), encoder.ToArray ()); + } + + public override void VerifyMembers () { // // Check for internal or private fields that were never assigned // - if (Report.WarningLevel >= 3) { - if (Compiler.Settings.EnhancedWarnings) { - CheckMemberUsage (properties, "property"); - CheckMemberUsage (methods, "method"); - CheckMemberUsage (constants, "constant"); - } - - if (fields != null){ - bool is_type_exposed = Kind == MemberKind.Struct || IsExposedFromAssembly (); - foreach (FieldBase f in fields) { - if ((f.ModFlags & Modifiers.AccessibilityMask) != Modifiers.PRIVATE) { - if (is_type_exposed) - continue; - - f.SetIsUsed (); - } - - if (!f.IsUsed){ - if ((f.caching_flags & Flags.IsAssigned) == 0) - Report.Warning (169, 3, f.Location, "The private field `{0}' is never used", f.GetSignatureForError ()); - else { - Report.Warning (414, 3, f.Location, "The private field `{0}' is assigned but its value is never used", - f.GetSignatureForError ()); - } - continue; - } - - if ((f.caching_flags & Flags.IsAssigned) != 0) - continue; - + if (!IsCompilerGenerated && Compiler.Settings.WarningLevel >= 3 && this == PartialContainer) { + bool is_type_exposed = Kind == MemberKind.Struct || IsExposedFromAssembly (); + foreach (var member in members) { + if (member is Event) { // - // Only report 649 on level 4 + // An event can be assigned from same class only, so we can report + // this warning for all accessibility modes // - if (Report.WarningLevel < 4) - continue; + if (!member.IsUsed) + Report.Warning (67, 3, member.Location, "The event `{0}' is never used", member.GetSignatureForError ()); - // - // Don't be pendatic over serializable attributes - // - if (f.OptAttributes != null || PartialContainer.HasStructLayout) + continue; + } + + if ((member.ModFlags & Modifiers.AccessibilityMask) != Modifiers.PRIVATE) { + if (is_type_exposed) continue; - - Constant c = New.Constantify (f.MemberType, f.Location); - string value; - if (c != null) { - value = c.GetValueAsLiteral (); - } else if (TypeSpec.IsReferenceType (f.MemberType)) { - value = "null"; - } else { - // Ignore this warning for struct value fields (they are always initialized) - if (f.MemberType.IsStruct) - continue; - value = null; + member.SetIsUsed (); + } + + var f = member as Field; + if (f == null) + continue; + + if (!member.IsUsed) { + if ((member.caching_flags & Flags.IsAssigned) == 0) { + Report.Warning (169, 3, member.Location, "The private field `{0}' is never used", member.GetSignatureForError ()); + } else { + Report.Warning (414, 3, member.Location, "The private field `{0}' is assigned but its value is never used", + member.GetSignatureForError ()); } + continue; + } + + if ((f.caching_flags & Flags.IsAssigned) != 0) + continue; + + // + // Only report 649 on level 4 + // + if (Compiler.Settings.WarningLevel < 4) + continue; + + // + // Don't be pendatic over serializable attributes + // + if (f.OptAttributes != null || PartialContainer.HasStructLayout) + continue; - if (value != null) - value = " `" + value + "'"; + Constant c = New.Constantify (f.MemberType, f.Location); + string value; + if (c != null) { + value = c.GetValueAsLiteral (); + } else if (TypeSpec.IsReferenceType (f.MemberType)) { + value = "null"; + } else { + // Ignore this warning for struct value fields (they are always initialized) + if (f.MemberType.IsStruct) + continue; - Report.Warning (649, 4, f.Location, "Field `{0}' is never assigned to, and will always have its default value{1}", - f.GetSignatureForError (), value); + value = null; } + + if (value != null) + value = " `" + value + "'"; + + Report.Warning (649, 4, f.Location, "Field `{0}' is never assigned to, and will always have its default value{1}", + f.GetSignatureForError (), value); } } + + base.VerifyMembers (); } public override void Emit () { - if (!IsTopLevel) { - MemberSpec candidate; - bool overrides = false; - var conflict_symbol = MemberCache.FindBaseMember (this, out candidate, ref overrides); - if (conflict_symbol == null && candidate == null) { - if ((ModFlags & Modifiers.NEW) != 0) - Report.Warning (109, 4, Location, "The member `{0}' does not hide an inherited member. The new keyword is not required", - GetSignatureForError ()); - } else { - if ((ModFlags & Modifiers.NEW) == 0) { - if (candidate == null) - candidate = conflict_symbol; + if (OptAttributes != null) + OptAttributes.Emit (); - Report.SymbolRelatedToPreviousError (candidate); - Report.Warning (108, 2, Location, "`{0}' hides inherited member `{1}'. Use the new keyword if hiding was intended", - GetSignatureForError (), candidate.GetSignatureForError ()); + if (!IsCompilerGenerated) { + if (!IsTopLevel) { + MemberSpec candidate; + bool overrides = false; + var conflict_symbol = MemberCache.FindBaseMember (this, out candidate, ref overrides); + if (conflict_symbol == null && candidate == null) { + if ((ModFlags & Modifiers.NEW) != 0) + Report.Warning (109, 4, Location, "The member `{0}' does not hide an inherited member. The new keyword is not required", + GetSignatureForError ()); + } else { + if ((ModFlags & Modifiers.NEW) == 0) { + if (candidate == null) + candidate = conflict_symbol; + + Report.SymbolRelatedToPreviousError (candidate); + Report.Warning (108, 2, Location, "`{0}' hides inherited member `{1}'. Use the new keyword if hiding was intended", + GetSignatureForError (), candidate.GetSignatureForError ()); + } } } - } - // Run constraints check on all possible generic types - if ((ModFlags & Modifiers.COMPILER_GENERATED) == 0) { + // Run constraints check on all possible generic types if (base_type != null && base_type_expr != null) { ConstraintChecker.Check (this, base_type, base_type_expr.Location); } @@ -2088,120 +2015,44 @@ namespace Mono.CSharp #endif base.Emit (); - } - - // TODO: move to ClassOrStruct - void EmitConstructors () - { - if (instance_constructors == null) - return; - if (spec.IsAttribute && IsExposedFromAssembly () && Compiler.Settings.VerifyClsCompliance && IsClsComplianceRequired ()) { - bool has_compliant_args = false; - - foreach (Constructor c in instance_constructors) { - try { - c.Emit (); - } - catch (Exception e) { - throw new InternalErrorException (c, e); - } + for (int i = 0; i < members.Count; i++) + members[i].Emit (); - if (has_compliant_args) - continue; + EmitIndexerName (); + CheckAttributeClsCompliance (); - has_compliant_args = c.HasCompliantArgs; - } - if (!has_compliant_args) - Report.Warning (3015, 1, Location, "`{0}' has no accessible constructors which use only CLS-compliant types", GetSignatureForError ()); - } else { - foreach (Constructor c in instance_constructors) { - try { - c.Emit (); - } - catch (Exception e) { - throw new InternalErrorException (c, e); - } - } - } + if (pending != null) + pending.VerifyPendingMethods (); } - /// - /// Emits the code, this step is performed after all - /// the types, enumerations, constructors - /// - public virtual void EmitType () + + void CheckAttributeClsCompliance () { - if ((caching_flags & Flags.CloseTypeCreated) != 0) + if (!spec.IsAttribute || !IsExposedFromAssembly () || !Compiler.Settings.VerifyClsCompliance || !IsClsComplianceRequired ()) return; - if (OptAttributes != null) - OptAttributes.Emit (); - - Emit (); - - EmitConstructors (); - - if (constants != null) - foreach (Const con in constants) - con.Emit (); - - if (default_static_constructor != null) - default_static_constructor.Emit (); - - if (operators != null) - foreach (Operator o in operators) - o.Emit (); - - if (properties != null) - foreach (Property p in properties) - p.Emit (); - - if (indexers != null) { - foreach (Indexer indx in indexers) - indx.Emit (); - EmitIndexerName (); - } - - if (events != null){ - foreach (Event e in Events) - e.Emit (); - } - - if (methods != null) { - for (int i = 0; i < methods.Count; ++i) - ((MethodOrOperator) methods [i]).Emit (); - } - - if (fields != null) - foreach (FieldBase f in fields) - f.Emit (); + foreach (var m in members) { + var c = m as Constructor; + if (c == null) + continue; - if (types != null) { - foreach (TypeContainer t in types) - t.EmitType (); + if (c.HasCompliantArgs) + return; } - if (pending != null) - pending.VerifyPendingMethods (); - - if (Report.Errors > 0) - return; - - if (compiler_generated != null) { - for (int i = 0; i < compiler_generated.Count; ++i) - compiler_generated [i].EmitType (); - } + Report.Warning (3015, 1, Location, "`{0}' has no accessible constructors which use only CLS-compliant types", GetSignatureForError ()); } - protected void Error_MissingPartialModifier (MemberCore type) + public sealed override void EmitContainer () { - Report.Error (260, type.Location, - "Missing partial modifier on declaration of type `{0}'. Another partial declaration of this type exists", - type.GetSignatureForError ()); + if ((caching_flags & Flags.CloseTypeCreated) != 0) + return; + + Emit (); } - public virtual void CloseType () + public override void CloseContainer () { if ((caching_flags & Flags.CloseTypeCreated) != 0) return; @@ -2210,7 +2061,7 @@ namespace Mono.CSharp if (spec.BaseType != null) { var btype = spec.BaseType.MemberDefinition as TypeContainer; if (btype != null) { - btype.CloseType (); + btype.CloseContainer (); if ((caching_flags & Flags.CloseTypeCreated) != 0) return; @@ -2220,38 +2071,19 @@ namespace Mono.CSharp try { caching_flags |= Flags.CloseTypeCreated; TypeBuilder.CreateType (); - } catch (TypeLoadException){ + } catch (TypeLoadException) { // // This is fine, the code still created the type // -// Report.Warning (-20, "Exception while creating class: " + TypeBuilder.Name); -// Console.WriteLine (e.Message); } catch (Exception e) { throw new InternalErrorException (this, e); } - - if (Types != null){ - foreach (TypeContainer tc in Types) - tc.CloseType (); - } - if (compiler_generated != null) - foreach (CompilerGeneratedClass c in compiler_generated) - c.CloseType (); + base.CloseContainer (); - types = null; + containers = null; initialized_fields = null; initialized_static_fields = null; - constants = null; - ordered_explicit_member_list = null; - ordered_member_list = null; - methods = null; - events = null; - indexers = null; - operators = null; - compiler_generated = null; - default_constructor = null; - default_static_constructor = null; type_bases = null; OptAttributes = null; } @@ -2332,18 +2164,11 @@ namespace Mono.CSharp return ok; } - public Constructor DefaultStaticConstructor { - get { return default_static_constructor; } - } - protected override bool VerifyClsCompliance () { if (!base.VerifyClsCompliance ()) return false; - // Check this name against other containers - NamespaceEntry.NS.VerifyClsCompliance (); - // Check all container names for user classes if (Kind != MemberKind.Delegate) MemberCache.VerifyClsCompliance (Definition, Report); @@ -2397,6 +2222,14 @@ namespace Mono.CSharp return false; } + public override bool IsClsComplianceRequired () + { + if (IsPartialPart) + return PartialContainer.IsClsComplianceRequired (); + + return base.IsClsComplianceRequired (); + } + bool ITypeDefinition.IsInternalAsPublic (IAssemblyDefinition assembly) { return Module.DeclaringAssembly == assembly; @@ -2441,15 +2274,8 @@ namespace Mono.CSharp if (t != null && (t.IsAccessible (this) || mode == LookupMode.IgnoreAccessibility)) e = new TypeExpression (t, Location.Null); - else if (Parent != null) { + else { e = Parent.LookupNamespaceOrType (name, arity, mode, loc); - } else { - int errors = Report.Errors; - - e = NamespaceEntry.LookupNamespaceOrType (name, arity, mode, loc); - - if (errors != Report.Errors) - return e; } } @@ -2462,21 +2288,12 @@ namespace Mono.CSharp TypeSpec LookupNestedTypeInHierarchy (string name, int arity) { - // TODO: GenericMethod only - if (PartialContainer == null) - return null; - // Has any nested type // Does not work, because base type can have //if (PartialContainer.Types == null) // return null; var container = PartialContainer.CurrentType; - - // Is not Root container - if (container == null) - return null; - return MemberCache.FindNestedType (container, name, arity); } @@ -2490,6 +2307,16 @@ namespace Mono.CSharp cached_method |= CachedMethods.GetHashCode; } + public override void WriteDebugSymbol (MonoSymbolFile file) + { + if (IsPartialPart) + return; + + foreach (var m in members) { + m.WriteDebugSymbol (file); + } + } + /// /// Method container contains Equals method /// @@ -2525,23 +2352,43 @@ namespace Mono.CSharp } } - public abstract class ClassOrStruct : TypeContainer + public abstract class ClassOrStruct : TypeDefinition { + public const TypeAttributes StaticClassAttribute = TypeAttributes.Abstract | TypeAttributes.Sealed; + SecurityType declarative_security; - public ClassOrStruct (NamespaceContainer ns, TypeContainer parent, MemberName name, Attributes attrs, MemberKind kind) - : base (ns, parent, name, attrs, kind) + public ClassOrStruct (TypeContainer parent, MemberName name, Attributes attrs, MemberKind kind) + : base (parent, name, attrs, kind) { } - protected override bool AddToContainer (MemberCore symbol, string name) + protected override TypeAttributes TypeAttr { + get { + TypeAttributes ta = base.TypeAttr; + if (!has_static_constructor) + ta |= TypeAttributes.BeforeFieldInit; + + if (Kind == MemberKind.Class) { + ta |= TypeAttributes.AutoLayout | TypeAttributes.Class; + if (IsStatic) + ta |= StaticClassAttribute; + } else { + ta |= TypeAttributes.SequentialLayout; + } + + return ta; + } + } + + public override void AddNameToContainer (MemberCore symbol, string name) { if (!(symbol is Constructor) && symbol.MemberName.Name == MemberName.Name) { if (symbol is TypeParameter) { Report.Error (694, symbol.Location, "Type parameter `{0}' has same name as containing type, or method", symbol.GetSignatureForError ()); - return false; + return; } InterfaceMemberBase imb = symbol as InterfaceMemberBase; @@ -2549,28 +2396,19 @@ namespace Mono.CSharp Report.SymbolRelatedToPreviousError (this); Report.Error (542, symbol.Location, "`{0}': member names cannot be the same as their enclosing type", symbol.GetSignatureForError ()); - return false; + return; } } - return base.AddToContainer (symbol, name); + base.AddNameToContainer (symbol, name); } public override void VerifyMembers () { base.VerifyMembers (); - if ((events != null) && Report.WarningLevel >= 3) { - foreach (Event e in events){ - // Note: The event can be assigned from same class only, so we can report - // this warning for all accessibility modes - if ((e.caching_flags & Flags.IsUsed) == 0) - Report.Warning (67, 3, e.Location, "The event `{0}' is never used", e.GetSignatureForError ()); - } - } - - if (types != null) { - foreach (var t in types) + if (containers != null) { + foreach (var t in containers) t.VerifyMembers (); } } @@ -2599,7 +2437,7 @@ namespace Mono.CSharp /// /// Defines the default constructors /// - protected void DefineDefaultConstructor (bool is_static) + protected Constructor DefineDefaultConstructor (bool is_static) { // The default instance constructor is public // If the class is abstract, the default constructor is protected @@ -2612,12 +2450,15 @@ namespace Mono.CSharp mods = ((ModFlags & Modifiers.ABSTRACT) != 0) ? Modifiers.PROTECTED : Modifiers.PUBLIC; } - Constructor c = new Constructor (this, MemberName.Name, mods, - null, ParametersCompiled.EmptyReadOnlyParameters, Location); + var c = new Constructor (this, MemberName.Name, mods, null, ParametersCompiled.EmptyReadOnlyParameters, Location); c.Initializer = new GeneratedBaseInitializer (Location); - AddConstructor (c); - c.Block = new ToplevelBlock (Compiler, ParametersCompiled.EmptyReadOnlyParameters, Location); + AddConstructor (c, true); + c.Block = new ToplevelBlock (Compiler, ParametersCompiled.EmptyReadOnlyParameters, Location) { + IsCompilerGenerated = true + }; + + return c; } protected override bool DoDefineMembers () @@ -2626,17 +2467,14 @@ namespace Mono.CSharp base.DoDefineMembers (); - if (default_static_constructor != null) - default_static_constructor.Define (); - return true; } public override void Emit () { - if (default_static_constructor == null && PartialContainer.HasStaticFieldInitializer) { - DefineDefaultConstructor (true); - default_static_constructor.Define (); + if (!has_static_constructor && HasStaticFieldInitializer) { + var c = DefineDefaultConstructor (true); + c.Define (); } base.Emit (); @@ -2651,34 +2489,11 @@ namespace Mono.CSharp } } } - - public override ExtensionMethodCandidates LookupExtensionMethod (TypeSpec extensionType, string name, int arity) - { - if (Parent != null) { - var methods = NamespaceEntry.NS.LookupExtensionMethod (this, extensionType, name, arity); - if (methods != null) { - return new ExtensionMethodCandidates (methods, NamespaceEntry, NamespaceEntry.NS) { - HasUninspectedMembers = true - }; - } - } - - return NamespaceEntry.LookupExtensionMethod (extensionType, name, arity); - } - - protected override TypeAttributes TypeAttr { - get { - if (default_static_constructor == null) - return base.TypeAttr | TypeAttributes.BeforeFieldInit; - - return base.TypeAttr; - } - } } - // TODO: should be sealed - public class Class : ClassOrStruct { + public sealed class Class : ClassOrStruct + { const Modifiers AllowedModifiers = Modifiers.NEW | Modifiers.PUBLIC | @@ -2690,12 +2505,10 @@ namespace Mono.CSharp Modifiers.STATIC | Modifiers.UNSAFE; - public const TypeAttributes StaticClassAttribute = TypeAttributes.Abstract | TypeAttributes.Sealed; - - public Class (NamespaceContainer ns, TypeContainer parent, MemberName name, Modifiers mod, Attributes attrs) - : base (ns, parent, name, attrs, MemberKind.Class) + public Class (TypeContainer parent, MemberName name, Modifiers mod, Attributes attrs) + : base (parent, name, attrs, MemberKind.Class) { - var accmods = (Parent == null || Parent.Parent == null) ? Modifiers.INTERNAL : Modifiers.PRIVATE; + var accmods = IsTopLevel ? Modifiers.INTERNAL : Modifiers.PRIVATE; this.ModFlags = ModifiersExtensions.Check (AllowedModifiers, mod, accmods, Location, Report); spec = new TypeSpec (Kind, null, this, null, ModFlags); } @@ -2705,13 +2518,14 @@ namespace Mono.CSharp visitor.Visit (this); } - public override void AddBasesForPart (TypeContainer part, List bases) + public override void AddBasesForPart (List bases) { - var pmn = part.MemberName; - if (pmn.Name == "Object" && pmn.Left != null && pmn.Left.Name == "System" && pmn.TypeParameters == null) - Report.Error (537, part.Location, + var pmn = MemberName; + if (pmn.Name == "Object" && !pmn.IsGeneric && Parent.MemberName.Name == "System" && Parent.MemberName.Left == null) + Report.Error (537, Location, "The class System.Object cannot have a base class or implement an interface."); - base.AddBasesForPart (part, bases); + + base.AddBasesForPart (bases); } public override void ApplyAttributeBuilder (Attribute a, MethodSpec ctor, byte[] cdata, PredefinedAttributes pa) @@ -2737,7 +2551,7 @@ namespace Mono.CSharp return; } - if (a.Type.IsConditionallyExcluded (Compiler, Location)) + if (a.Type.IsConditionallyExcluded (this, Location)) return; base.ApplyAttributeBuilder (a, ctor, cdata, pa); @@ -2749,46 +2563,6 @@ namespace Mono.CSharp } } - protected override void DefineContainerMembers (System.Collections.IList list) - { - if (list == null) - return; - - if (!IsStatic) { - base.DefineContainerMembers (list); - return; - } - - foreach (MemberCore m in list) { - if (m is Operator) { - Report.Error (715, m.Location, "`{0}': Static classes cannot contain user-defined operators", m.GetSignatureForError ()); - continue; - } - - if (m is Destructor) { - Report.Error (711, m.Location, "`{0}': Static classes cannot contain destructor", GetSignatureForError ()); - continue; - } - - if (m is Indexer) { - Report.Error (720, m.Location, "`{0}': cannot declare indexers in a static class", m.GetSignatureForError ()); - continue; - } - - if ((m.ModFlags & Modifiers.STATIC) != 0 || m is Enum || m is Delegate) - continue; - - if (m is Constructor) { - Report.Error (710, m.Location, "`{0}': Static classes cannot have instance constructors", GetSignatureForError ()); - continue; - } - - Report.Error (708, m.Location, "`{0}': cannot declare instance members in a static class", m.GetSignatureForError ()); - } - - base.DefineContainerMembers (list); - } - protected override bool DoDefineMembers () { if ((ModFlags & Modifiers.ABSTRACT) == Modifiers.ABSTRACT && (ModFlags & (Modifiers.SEALED | Modifiers.STATIC)) != 0) { @@ -2799,8 +2573,37 @@ namespace Mono.CSharp Report.Error (441, Location, "`{0}': a class cannot be both static and sealed", GetSignatureForError ()); } - if (InstanceConstructors == null && !IsStatic) - DefineDefaultConstructor (false); + if (IsStatic) { + foreach (var m in Members) { + if (m is Operator) { + Report.Error (715, m.Location, "`{0}': Static classes cannot contain user-defined operators", m.GetSignatureForError ()); + continue; + } + + if (m is Destructor) { + Report.Error (711, m.Location, "`{0}': Static classes cannot contain destructor", GetSignatureForError ()); + continue; + } + + if (m is Indexer) { + Report.Error (720, m.Location, "`{0}': cannot declare indexers in a static class", m.GetSignatureForError ()); + continue; + } + + if ((m.ModFlags & Modifiers.STATIC) != 0 || m is TypeContainer) + continue; + + if (m is Constructor) { + Report.Error (710, m.Location, "`{0}': Static classes cannot have instance constructors", GetSignatureForError ()); + continue; + } + + Report.Error (708, m.Location, "`{0}': cannot declare instance members in a static class", m.GetSignatureForError ()); + } + } else { + if (!PartialContainer.HasInstanceConstructor) + DefineDefaultConstructor (false); + } return base.DoDefineMembers (); } @@ -2895,23 +2698,10 @@ namespace Mono.CSharp caching_flags |= Flags.Excluded; return conditions; } - - // - // FIXME: How do we deal with the user specifying a different - // layout? - // - protected override TypeAttributes TypeAttr { - get { - TypeAttributes ta = base.TypeAttr | TypeAttributes.AutoLayout | TypeAttributes.Class; - if (IsStatic) - ta |= StaticClassAttribute; - return ta; - } - } } - public sealed class Struct : ClassOrStruct { - + public sealed class Struct : ClassOrStruct + { bool is_unmanaged, has_unmanaged_check_done; bool InTransit; @@ -2926,10 +2716,10 @@ namespace Mono.CSharp Modifiers.UNSAFE | Modifiers.PRIVATE; - public Struct (NamespaceContainer ns, TypeContainer parent, MemberName name, Modifiers mod, Attributes attrs) - : base (ns, parent, name, attrs, MemberKind.Struct) + public Struct (TypeContainer parent, MemberName name, Modifiers mod, Attributes attrs) + : base (parent, name, attrs, MemberKind.Struct) { - var accmods = parent.Parent == null ? Modifiers.INTERNAL : Modifiers.PRIVATE; + var accmods = IsTopLevel ? Modifiers.INTERNAL : Modifiers.PRIVATE; this.ModFlags = ModifiersExtensions.Check (AllowedModifiers, mod, accmods, Location, Report) | Modifiers.SEALED ; spec = new TypeSpec (Kind, null, this, null, ModFlags); } @@ -2954,13 +2744,13 @@ namespace Mono.CSharp // set CharSet, its value has to be propagated to compiler generated // fixed types // - if (a.Type == pa.StructLayout && Fields != null) { + if (a.Type == pa.StructLayout) { var value = a.GetNamedValue ("CharSet"); if (value == null) return; - for (int i = 0; i < Fields.Count; ++i) { - FixedField ff = Fields [i] as FixedField; + for (int i = 0; i < Members.Count; ++i) { + FixedField ff = Members [i] as FixedField; if (ff == null) continue; @@ -2969,16 +2759,17 @@ namespace Mono.CSharp } } - bool CheckStructCycles (Struct s) + bool CheckStructCycles () { - if (s.Fields == null) - return true; - - if (s.InTransit) + if (InTransit) return false; - s.InTransit = true; - foreach (FieldBase field in s.Fields) { + InTransit = true; + foreach (var member in Members) { + var field = member as Field; + if (field == null) + continue; + TypeSpec ftype = field.Spec.MemberType; if (!ftype.IsStruct) continue; @@ -2998,7 +2789,7 @@ namespace Mono.CSharp // // Static fields of exactly same type are allowed // - if (field.IsStatic && ftype == s.CurrentType) + if (field.IsStatic && ftype == CurrentType) continue; if (!CheckFieldTypeCycle (ftype)) { @@ -3009,22 +2800,22 @@ namespace Mono.CSharp } } - s.InTransit = false; + InTransit = false; return true; } - bool CheckFieldTypeCycle (TypeSpec ts) + static bool CheckFieldTypeCycle (TypeSpec ts) { var fts = ts.MemberDefinition as Struct; if (fts == null) return true; - return CheckStructCycles (fts); + return fts.CheckStructCycles (); } public override void Emit () { - CheckStructCycles (this); + CheckStructCycles (); base.Emit (); } @@ -3037,15 +2828,20 @@ namespace Mono.CSharp if (requires_delayed_unmanagedtype_check) return true; - if (Parent != null && Parent.IsGenericOrParentIsGeneric) { + var parent_def = Parent.PartialContainer; + if (parent_def != null && parent_def.IsGenericOrParentIsGeneric) { has_unmanaged_check_done = true; return false; } - if (fields != null) { + if (first_nonstatic_field != null) { requires_delayed_unmanagedtype_check = true; - foreach (FieldBase f in fields) { + foreach (var member in Members) { + var f = member as Field; + if (f == null) + continue; + if (f.IsStatic) continue; @@ -3077,17 +2873,6 @@ namespace Mono.CSharp return ifaces; } - protected override TypeAttributes TypeAttr { - get { - const - TypeAttributes DefaultTypeAttributes = - TypeAttributes.SequentialLayout | - TypeAttributes.Sealed ; - - return base.TypeAttr | DefaultTypeAttributes; - } - } - public override void RegisterFieldForInitialization (MemberCore field, FieldInitializer expression) { if ((field.ModFlags & Modifiers.STATIC) == 0) { @@ -3103,7 +2888,7 @@ namespace Mono.CSharp /// /// Interfaces /// - public sealed class Interface : TypeContainer { + public sealed class Interface : TypeDefinition { /// /// Modifiers allowed in a class declaration @@ -3116,10 +2901,10 @@ namespace Mono.CSharp Modifiers.UNSAFE | Modifiers.PRIVATE; - public Interface (NamespaceContainer ns, TypeContainer parent, MemberName name, Modifiers mod, Attributes attrs) - : base (ns, parent, name, attrs, MemberKind.Interface) + public Interface (TypeContainer parent, MemberName name, Modifiers mod, Attributes attrs) + : base (parent, name, attrs, MemberKind.Interface) { - var accmods = parent.Parent == null ? Modifiers.INTERNAL : Modifiers.PRIVATE; + var accmods = IsTopLevel ? Modifiers.INTERNAL : Modifiers.PRIVATE; this.ModFlags = ModifiersExtensions.Check (AllowedModifiers, mod, accmods, name.Location, Report); spec = new TypeSpec (Kind, null, this, null, ModFlags); @@ -3229,7 +3014,7 @@ namespace Mono.CSharp // // If true, this is an explicit interface implementation // - public bool IsExplicitImpl; + public readonly bool IsExplicitImpl; protected bool is_external_implementation; @@ -3246,10 +3031,10 @@ namespace Mono.CSharp readonly Modifiers explicit_mod_flags; public MethodAttributes flags; - public InterfaceMemberBase (TypeContainer parent, FullNamedExpression type, Modifiers mod, Modifiers allowed_mod, MemberName name, Attributes attrs) + public InterfaceMemberBase (TypeDefinition parent, FullNamedExpression type, Modifiers mod, Modifiers allowed_mod, MemberName name, Attributes attrs) : base (parent, type, mod, allowed_mod, Modifiers.PRIVATE, name, attrs) { - IsInterface = parent.PartialContainer.Kind == MemberKind.Interface; + IsInterface = parent.Kind == MemberKind.Interface; IsExplicitImpl = (MemberName.ExplicitInterface != null); explicit_mod_flags = mod; } @@ -3655,10 +3440,12 @@ namespace Mono.CSharp { protected FullNamedExpression type_expr; protected TypeSpec member_type; + public new TypeDefinition Parent; - protected MemberBase (TypeContainer parent, FullNamedExpression type, Modifiers mod, Modifiers allowed_mod, Modifiers def_mod, MemberName name, Attributes attrs) + protected MemberBase (TypeDefinition parent, FullNamedExpression type, Modifiers mod, Modifiers allowed_mod, Modifiers def_mod, MemberName name, Attributes attrs) : base (parent, name, attrs) { + this.Parent = parent; this.type_expr = type; ModFlags = ModifiersExtensions.Check (allowed_mod, mod, def_mod, Location, Report); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/codegen.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/codegen.cs index 99eae23a82..026d410698 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/codegen.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/codegen.cs @@ -12,6 +12,7 @@ using System; using System.Collections.Generic; +using Mono.CompilerServices.SymbolWriter; #if STATIC using MetaType = IKVM.Reflection.Type; @@ -76,11 +77,15 @@ namespace Mono.CSharp readonly IMemberContext member_context; + readonly SourceMethodBuilder methodSymbols; + DynamicSiteClass dynamic_site_container; Label? return_label; - public EmitContext (IMemberContext rc, ILGenerator ig, TypeSpec return_type) + List epilogue_expressions; + + public EmitContext (IMemberContext rc, ILGenerator ig, TypeSpec return_type, SourceMethodBuilder methodSymbols) { this.member_context = rc; this.ig = ig; @@ -89,6 +94,14 @@ namespace Mono.CSharp if (rc.Module.Compiler.Settings.Checked) flags |= Options.CheckedScope; + if (methodSymbols != null) { + this.methodSymbols = methodSymbols; + if (!rc.Module.Compiler.Settings.Optimize) + flags |= Options.AccurateDebugInfo; + } else { + flags |= Options.OmitDebugInfo; + } + #if STATIC ig.__CleverExceptionBlockAssistance (); #endif @@ -120,6 +133,18 @@ namespace Mono.CSharp get { return member_context.CurrentMemberDefinition; } } + public bool EmitAccurateDebugInfo { + get { + return (flags & Options.AccurateDebugInfo) != 0; + } + } + + public bool HasMethodSymbolBuilder { + get { + return methodSymbols != null; + } + } + public bool HasReturnLabel { get { return return_label.HasValue; @@ -173,8 +198,25 @@ namespace Mono.CSharp } } + public List StatementEpilogue { + get { + return epilogue_expressions; + } + } + #endregion + public void AddStatementEpilog (IExpressionCleanup cleanupExpression) + { + if (epilogue_expressions == null) { + epilogue_expressions = new List (); + } else if (epilogue_expressions.Contains (cleanupExpression)) { + return; + } + + epilogue_expressions.Add (cleanupExpression); + } + public void AssertEmptyStack () { #if STATIC @@ -188,17 +230,30 @@ namespace Mono.CSharp /// This is called immediately before emitting an IL opcode to tell the symbol /// writer to which source line this opcode belongs. /// - public void Mark (Location loc) + public bool Mark (Location loc) { - if (!SymbolWriter.HasSymbolWriter || HasSet (Options.OmitDebugInfo) || loc.IsNull) - return; + if ((flags & Options.OmitDebugInfo) != 0) + return false; + + if (loc.IsNull || methodSymbols == null) + return false; + + var sf = loc.SourceFile; + if (sf.IsHiddenLocation (loc)) + return false; - SymbolWriter.MarkSequencePoint (ig, loc); +#if NET_4_0 + methodSymbols.MarkSequencePoint (ig.ILOffset, sf.SourceFileEntry, loc.Row, loc.Column, false); +#endif + return true; } public void DefineLocalVariable (string name, LocalBuilder builder) { - SymbolWriter.DefineLocalVariable (name, builder); + if ((flags & Options.OmitDebugInfo) != 0) + return; + + methodSymbols.AddLocal (builder.LocalIndex, name); } public void BeginCatchBlock (TypeSpec type) @@ -218,7 +273,12 @@ namespace Mono.CSharp public void BeginScope () { - SymbolWriter.OpenScope(ig); + if ((flags & Options.OmitDebugInfo) != 0) + return; + +#if NET_4_0 + methodSymbols.StartBlock (CodeBlockEntry.Type.Lexical, ig.ILOffset); +#endif } public void EndExceptionBlock () @@ -228,7 +288,12 @@ namespace Mono.CSharp public void EndScope () { - SymbolWriter.CloseScope(ig); + if ((flags & Options.OmitDebugInfo) != 0) + return; + +#if NET_4_0 + methodSymbols.EndBlock (ig.ILOffset); +#endif } // @@ -241,9 +306,8 @@ namespace Mono.CSharp dynamic_site_container = new DynamicSiteClass (CurrentTypeDefinition.Parent.PartialContainer, mc, member_context.CurrentTypeParameters); CurrentTypeDefinition.Module.AddCompilerGeneratedClass (dynamic_site_container); - dynamic_site_container.CreateType (); - dynamic_site_container.DefineType (); - dynamic_site_container.ResolveTypeParameters (); + dynamic_site_container.CreateContainer (); + dynamic_site_container.DefineContainer (); dynamic_site_container.Define (); var inflator = new TypeParameterInflator (Module, CurrentType, TypeParameterSpec.EmptyTypes, TypeSpec.EmptyTypes); @@ -771,6 +835,17 @@ namespace Mono.CSharp ig.Emit (OpCodes.Ldarg_0); } + public void EmitEpilogue () + { + if (epilogue_expressions == null) + return; + + foreach (var e in epilogue_expressions) + e.EmitCleanup (this); + + epilogue_expressions = null; + } + /// /// Returns a temporary storage for a variable of type t as /// a local variable in the current body. @@ -866,7 +941,7 @@ namespace Mono.CSharp public void Emit (EmitContext ec, MethodSpec method, Arguments Arguments, Location loc) { // Speed up the check by not doing it on not allowed targets - if (method.ReturnType.Kind == MemberKind.Void && method.IsConditionallyExcluded (ec.Module.Compiler, loc)) + if (method.ReturnType.Kind == MemberKind.Void && method.IsConditionallyExcluded (ec.MemberContext, loc)) return; EmitPredefined (ec, method, Arguments); @@ -1021,9 +1096,11 @@ namespace Mono.CSharp return false; // - // It's non-virtual and will never be null + // It's non-virtual and will never be null and it can be determined + // whether it's known value or reference type by verifier // - if (!method.IsVirtual && (instance is This || instance is New || instance is ArrayCreation || instance is DelegateCreation)) + if (!method.IsVirtual && (instance is This || instance is New || instance is ArrayCreation || instance is DelegateCreation) && + !instance.Type.IsGenericParameter) return false; return true; diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/compiler.doc b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/compiler.doc deleted file mode 100644 index 952437601c..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/compiler.doc +++ /dev/null @@ -1,116 +0,0 @@ -Compiler operation - -The compiler has a number of phases: - -* Parsing. - - Initially the compiler parses all the source files and keeps a - parsed representation in memory. Very syntax error checking - is performed at this point. - - The compiler stores the information in classes whose names - represent the language construct, for example, the "if" - construct is stored in an `If' class. A class is stored in a - `Class'. - -* The TypeManager - - The TypeManager loads all the assemblies that were referenced - by the programmer. The CLR type system is used as our - repository for types defined as well. - - So the same interface that is used to query the types, - properties and flags about system types is the same interface - that we use for our types. - - As we work our way through the code generation and semantic - analysis, new types are entered into the Type system through - the use of System.Reflection.Emit. The TypeManager will - lookup types on both the user defined types and on the system - defined ones. - - So special care has to be used. The order in which we - proceeed from here is important. - -* Base class resolution and type definition. - - Once the parsing has happened, the compiler resolves the - inheritance tree for interfaces. This is done recursively - and we catch recursive interface definitions here. - - After this is done, we continue on with classes. Classes have - can have an optional "parent" inherit from or the implicit - System.Object class (for normal builds, builds with /nostdlib - will allow you to compile class System.Object with no parent). - - At this point we do some error checking and verify that the - inherits/implements section of a class is correct (since we - have previously built the interface inheritance). - - By the time we are done, all classes, structs and interfaces - have been created using System.Reflection.Emit and registered - with the Type Manager. - - This allows us to define fields and resolve argument names for - methods, properties, indexers and events. - -* Field generation - - Fields are generated next, we go through all the type - containers (classes and structs) and enter the fields into - their types. - -* Method, Properties, Indexers and events definitions - - Now all the methods, constructors, properties, indexers and - events are entered. They are only `defined' using - System.Reflection.Emit. No code generation will happen until - everything has been entered into System.Reflection.Emit. - - This is important because to actually generate code we need to - know everything about the environment in which the code is - being generated. - -* Code Generation - - At this point all the definitions have been entered into the - type manager through System.Reflection.Emit. We can now use - System.Reflection to query all the information about the - types. - - Your normal semantic analysis and code generation phase lives - here. - -* Statements - - Most of the statements are handled in the codegen.cs file. - -* Expressions - -* Error reporting - - Always use `Report::Error' or `Report::Warning' methods of Report - class. The actual Report instance is available via local context. - An expression error reporting has to be done during Resolve phase, - except when it's Emit specific (very rare). - - Error reporting should try to use the same codes that the - Microsoft compiler uses (if only so we can track which errors - we handle and which ones we dont). - - If there is an error which is specific to MSC, use negative - numbers, and register the number in mcs/errors/errors.txt - - Try to write a test case for any error that you run into the - code of the compiler if there is none already. - - Put your test case in a file called csNNNN.cs in the - mcs/errors directory, and have the first two lines be: - - // csNNNN.cs: This is the error message - // Line: XXX - // Compiler options: an optional compiler options - - Where `XXX' is the line where the error ocurrs. We will later - use this as a regression test suite for catching errors in the - compiler. diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/complete.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/complete.cs index 08b420592a..a1bb8ec00f 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/complete.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/complete.cs @@ -78,11 +78,9 @@ namespace Mono.CSharp { { var results = new List (); - AppendResults (results, Prefix, ec.Module.Evaluator.GetVarNames ()); - AppendResults (results, Prefix, ec.CurrentMemberDefinition.Parent.NamespaceEntry.CompletionGetTypesStartingWith (Prefix)); - AppendResults (results, Prefix, ec.Module.Evaluator.GetUsingList ()); - - throw new CompletionResult (Prefix, results.ToArray ()); + ec.CurrentMemberDefinition.GetCompletionStartingWith (Prefix, results); + + throw new CompletionResult (Prefix, results.Distinct ().Select (l => l.Substring (Prefix.Length)).ToArray ()); } protected override void CloneTo (CloneContext clonectx, Expression t) @@ -140,17 +138,9 @@ namespace Mono.CSharp { else namespaced_partial = nexpr.Name + "." + partial_name; -#if false - Console.WriteLine ("Workign with: namespaced partial {0}", namespaced_partial); - foreach (var x in ec.TypeContainer.NamespaceEntry.CompletionGetTypesStartingWith (ec.TypeContainer, namespaced_partial)){ - Console.WriteLine (" {0}", x); - } -#endif - - CompletionSimpleName.AppendResults ( - results, - partial_name, - ec.CurrentMemberDefinition.Parent.NamespaceEntry.CompletionGetTypesStartingWith (namespaced_partial)); + ec.CurrentMemberDefinition.GetCompletionStartingWith (namespaced_partial, results); + if (partial_name != null) + results = results.Select (l => l.Substring (partial_name.Length)).ToList (); } else { var r = MemberCache.GetCompletitionMembers (ec, expr_type, partial_name).Select (l => l.Name); AppendResults (results, partial_name, r); diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/const.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/const.cs index 9789bd9ad0..5eb93d129a 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/const.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/const.cs @@ -26,7 +26,7 @@ namespace Mono.CSharp { Modifiers.INTERNAL | Modifiers.PRIVATE; - public Const (TypeContainer parent, FullNamedExpression type, Modifiers mod_flags, MemberName name, Attributes attrs) + public Const (TypeDefinition parent, FullNamedExpression type, Modifiers mod_flags, MemberName name, Attributes attrs) : base (parent, type, mod_flags, AllowedModifiers, name, attrs) { ModFlags |= Modifiers.STATIC; @@ -63,12 +63,12 @@ namespace Mono.CSharp { if (declarators != null) { var t = new TypeExpression (MemberType, TypeExpression.Location); - int index = Parent.PartialContainer.Constants.IndexOf (this); foreach (var d in declarators) { var c = new Const (Parent, t, ModFlags & ~Modifiers.STATIC, new MemberName (d.Name.Value, d.Name.Location), OptAttributes); c.initializer = d.Initializer; ((ConstInitializer) c.initializer).Name = d.Name.Value; - Parent.PartialContainer.Constants.Insert (++index, c); + c.Define (); + Parent.PartialContainer.Members.Add (c); } } @@ -205,7 +205,7 @@ namespace Mono.CSharp { else if (!(expr is Constant)) Error_ExpressionMustBeConstant (rc, expr.Location, GetSignatureForError ()); else - expr.Error_ValueCannotBeConverted (rc, expr.Location, field.MemberType, false); + expr.Error_ValueCannotBeConverted (rc, field.MemberType, false); } expr = c; diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/constant.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/constant.cs index 3869f1e805..4297c521d1 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/constant.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/constant.cs @@ -58,7 +58,7 @@ namespace Mono.CSharp { } #endif - public override void Error_ValueCannotBeConverted (ResolveContext ec, Location loc, TypeSpec target, bool expl) + public override void Error_ValueCannotBeConverted (ResolveContext ec, TypeSpec target, bool expl) { if (!expl && IsLiteral && BuiltinTypeSpec.IsPrimitiveTypeOrDecimal (target) && @@ -66,7 +66,7 @@ namespace Mono.CSharp { ec.Report.Error (31, loc, "Constant value `{0}' cannot be converted to a `{1}'", GetValueAsLiteral (), TypeManager.CSharpName (target)); } else { - base.Error_ValueCannotBeConverted (ec, loc, target, expl); + base.Error_ValueCannotBeConverted (ec, target, expl); } } @@ -74,7 +74,7 @@ namespace Mono.CSharp { { Constant c = ConvertImplicitly (type); if (c == null) - Error_ValueCannotBeConverted (ec, loc, type, false); + Error_ValueCannotBeConverted (ec, type, false); return c; } @@ -160,8 +160,11 @@ namespace Mono.CSharp { return new NullConstant (t, loc); } - throw new InternalErrorException ("Constant value `{0}' has unexpected underlying type `{1}'", - v, TypeManager.CSharpName (t)); +#if STATIC + throw new InternalErrorException ("Constant value `{0}' has unexpected underlying type `{1}'", v, t.GetSignatureForError ()); +#else + return null; +#endif } public override Expression CreateExpressionTree (ResolveContext ec) @@ -251,32 +254,38 @@ namespace Mono.CSharp { /// /// Attempts to do a compile-time folding of a constant cast. /// - public Constant TryReduce (ResolveContext ec, TypeSpec target_type, Location loc) + public Constant TryReduce (ResolveContext ec, TypeSpec target_type) { try { - return TryReduce (ec, target_type); - } - catch (OverflowException) { + return TryReduceConstant (ec, target_type); + } catch (OverflowException) { if (ec.ConstantCheckState && Type.BuiltinType != BuiltinTypeSpec.Type.Decimal) { ec.Report.Error (221, loc, "Constant value `{0}' cannot be converted to a `{1}' (use `unchecked' syntax to override)", GetValueAsLiteral (), target_type.GetSignatureForError ()); } else { - Error_ValueCannotBeConverted (ec, loc, target_type, false); + Error_ValueCannotBeConverted (ec, target_type, false); } return New.Constantify (target_type, loc); } } - Constant TryReduce (ResolveContext ec, TypeSpec target_type) + Constant TryReduceConstant (ResolveContext ec, TypeSpec target_type) { - if (Type == target_type) + if (Type == target_type) { + // + // Reducing literal value produces a new constant. Syntactically 10 is not same as (int)10 + // + if (IsLiteral) + return CreateConstantFromValue (target_type, GetValue (), loc); + return this; + } Constant c; if (target_type.IsEnum) { - c = TryReduce (ec, EnumSpec.GetUnderlyingType (target_type)); + c = TryReduceConstant (ec, EnumSpec.GetUnderlyingType (target_type)); if (c == null) return null; @@ -378,11 +387,11 @@ namespace Mono.CSharp { eclass = ExprClass.Value; } - public override void Error_ValueCannotBeConverted (ResolveContext ec, Location loc, TypeSpec target, bool expl) + public override void Error_ValueCannotBeConverted (ResolveContext ec, TypeSpec target, bool expl) { try { ConvertExplicitly (true, target); - base.Error_ValueCannotBeConverted (ec, loc, target, expl); + base.Error_ValueCannotBeConverted (ec, target, expl); } catch { diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/context.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/context.cs index 24fedc69d5..5f309854bd 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/context.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/context.cs @@ -481,7 +481,7 @@ namespace Mono.CSharp // or it's a parameter // if (CurrentAnonymousMethod is AsyncInitializer) - return CurrentBlock.Explicit.HasAwait; + return local.IsParameter || CurrentBlock.Explicit.HasAwait; return local.Block.ParametersBlock != CurrentBlock.ParametersBlock.Original; } @@ -586,10 +586,10 @@ namespace Mono.CSharp Dictionary all_source_files; - public CompilerContext (CompilerSettings settings, Report report) + public CompilerContext (CompilerSettings settings, ReportPrinter reportPrinter) { this.settings = settings; - this.report = report; + this.report = new Report (this, reportPrinter); this.builtin_types = new BuiltinTypes (); this.TimeReporter = DisabledTimeReporter; } @@ -620,7 +620,7 @@ namespace Mono.CSharp } } - public List SourceFiles { + public List SourceFiles { get { return settings.SourceFiles; } @@ -646,7 +646,7 @@ namespace Mono.CSharp string path; if (!Path.IsPathRooted (name)) { - string root = Path.GetDirectoryName (comp_unit.FullPathName); + string root = Path.GetDirectoryName (comp_unit.SourceFile.FullPathName); path = Path.Combine (root, name); } else path = name; @@ -655,7 +655,8 @@ namespace Mono.CSharp if (all_source_files.TryGetValue (path, out retval)) return retval; - retval = Location.AddFile (name, path); + retval = new SourceFile (name, path, all_source_files.Count + 1); + Location.AddFile (retval); all_source_files.Add (path, retval); return retval; } @@ -681,6 +682,8 @@ namespace Mono.CSharp /// CheckedScope = 1 << 0, + AccurateDebugInfo = 1 << 1, + OmitDebugInfo = 1 << 2, ConstructorScope = 1 << 3, diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/convert.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/convert.cs index f1dfc2d8bd..a9a304dfc9 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/convert.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/convert.cs @@ -330,17 +330,40 @@ namespace Mono.CSharp { return TypeSpecComparer.Variant.IsEqual (expr_type, target_type) || expr_type.ImplementsInterface (target_type, true); return target_type.BuiltinType == BuiltinTypeSpec.Type.Object || target_type.BuiltinType == BuiltinTypeSpec.Type.Dynamic; - } - // - // from the null literal to any reference-type. - // - if (expr_type == InternalType.NullLiteral) { - // Exlude internal compiler types - if (target_type.Kind == MemberKind.InternalCompilerType) - return target_type.BuiltinType == BuiltinTypeSpec.Type.Dynamic; + case MemberKind.InternalCompilerType: + // + // from the null literal to any reference-type. + // + if (expr_type == InternalType.NullLiteral) { + // Exlude internal compiler types + if (target_type.Kind == MemberKind.InternalCompilerType) + return target_type.BuiltinType == BuiltinTypeSpec.Type.Dynamic; + + return TypeSpec.IsReferenceType (target_type); + } + + // + // Implicit dynamic conversion + // + if (expr_type.BuiltinType == BuiltinTypeSpec.Type.Dynamic) { + switch (target_type.Kind) { + case MemberKind.ArrayType: + case MemberKind.Class: + case MemberKind.Delegate: + case MemberKind.Interface: + case MemberKind.TypeParameter: + return true; + } + + // dynamic to __arglist + if (target_type == InternalType.Arglist) + return true; + + return false; + } - return TypeSpec.IsReferenceType (target_type); + break; } return false; @@ -472,6 +495,11 @@ namespace Mono.CSharp { return ImplicitNumericConversion (expr, expr.Type, target_type); } + public static bool ImplicitNumericConversionExists (TypeSpec expr_type, TypeSpec target_type) + { + return ImplicitNumericConversion (null, expr_type, target_type) != null; + } + static Expression ImplicitNumericConversion (Expression expr, TypeSpec expr_type, TypeSpec target_type) { switch (expr_type.BuiltinType) { @@ -773,23 +801,17 @@ namespace Mono.CSharp { return i.IsZeroInteger; } - // Implicit dynamic conversion + // + // Implicit dynamic conversion for remaining value types. It should probably + // go somewhere else + // if (expr_type.BuiltinType == BuiltinTypeSpec.Type.Dynamic) { switch (target_type.Kind) { - case MemberKind.ArrayType: - case MemberKind.Class: case MemberKind.Struct: - case MemberKind.Delegate: case MemberKind.Enum: - case MemberKind.Interface: - case MemberKind.TypeParameter: return true; } - // dynamic to __arglist - if (target_type == InternalType.Arglist) - return true; - return false; } @@ -1173,7 +1195,7 @@ namespace Mono.CSharp { if (s_x != source_type) { var c = source as Constant; if (c != null) { - source = c.TryReduce (ec, s_x, loc); + source = c.TryReduce (ec, s_x); } else { source = implicitOnly ? ImplicitConversionStandard (ec, source_type_expr, s_x, loc) : @@ -1401,7 +1423,7 @@ namespace Mono.CSharp { if (e != null) return e; - source.Error_ValueCannotBeConverted (ec, loc, target_type, false); + source.Error_ValueCannotBeConverted (ec, target_type, false); return null; } @@ -2081,7 +2103,7 @@ namespace Mono.CSharp { if (ec.IsUnsafe && expr.Type.IsPointer && target_type.IsPointer && ((PointerContainer)expr.Type).Element.Kind == MemberKind.Void) return EmptyCast.Create (expr, target_type); - expr.Error_ValueCannotBeConverted (ec, l, target_type, true); + expr.Error_ValueCannotBeConverted (ec, target_type, true); return null; } @@ -2144,7 +2166,7 @@ namespace Mono.CSharp { if (e != null) return e; - expr.Error_ValueCannotBeConverted (ec, loc, target_type, true); + expr.Error_ValueCannotBeConverted (ec, target_type, true); return null; } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/cs-parser.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/cs-parser.cs index c42ac2e228..77893426d1 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/cs-parser.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/cs-parser.cs @@ -47,9 +47,9 @@ namespace Mono.CSharp static readonly object ModifierNone = 0; - NamespaceContainer current_namespace; - TypeContainer current_container; - TypeContainer current_class; + NamespaceContainer current_namespace; + TypeContainer current_container; + TypeDefinition current_type; PropertyBase current_property; EventProperty current_event; EventField current_event_field; @@ -88,7 +88,7 @@ namespace Mono.CSharp /// /// Controls the verbosity of the errors produced by the parser /// - static public int yacc_verbose_flag; + int yacc_verbose_flag; /// /// Used by the interactive shell, flags whether EOF was reached @@ -145,11 +145,13 @@ namespace Mono.CSharp // Full AST support members // LocationsBag lbag; - UsingsBag ubag; List> mod_locations; Location parameterModifierLocation, savedLocation, savedOpenLocation, savedCloseLocation; Location savedAttrParenOpenLocation, savedAttrParenCloseLocation, savedOperatorLocation; Stack> locationListStack = new Stack> (); // used for type parameters + Stack opt_intoStack = new Stack (); + + bool HadAttributeParens; List attributeCommas = new List (); List attributeArgumentCommas = new List (); List parameterListCommas = new List (); @@ -236,6 +238,7 @@ namespace Mono.CSharp //t "namespace_or_type_declarations : namespace_or_type_declarations namespace_or_type_declaration", //t "namespace_or_type_declaration : type_declaration", //t "namespace_or_type_declaration : namespace_declaration", +//t "namespace_or_type_declaration : attribute_sections CLOSE_BRACE", //t "type_declaration : class_declaration", //t "type_declaration : struct_declaration", //t "type_declaration : interface_declaration", @@ -288,6 +291,7 @@ namespace Mono.CSharp //t "class_member_declaration : constructor_declaration", //t "class_member_declaration : destructor_declaration", //t "class_member_declaration : type_declaration", +//t "class_member_declaration : attributes_without_members", //t "class_member_declaration : error", //t "$$8 :", //t "$$9 :", @@ -344,6 +348,7 @@ namespace Mono.CSharp //t "$$25 :", //t "method_header : opt_attributes opt_modifiers PARTIAL VOID $$23 method_declaration_name OPEN_PARENS $$24 opt_formal_parameter_list CLOSE_PARENS $$25 opt_type_parameter_constraints_clauses", //t "method_header : opt_attributes opt_modifiers member_type modifiers method_declaration_name OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS", +//t "method_header : opt_attributes opt_modifiers member_type method_declaration_name error", //t "method_body : block", //t "method_body : SEMICOLON", //t "opt_formal_parameter_list :", @@ -362,6 +367,7 @@ namespace Mono.CSharp //t "fixed_parameters : fixed_parameters COMMA fixed_parameter", //t "fixed_parameter : opt_attributes opt_parameter_modifier parameter_type IDENTIFIER", //t "fixed_parameter : opt_attributes opt_parameter_modifier parameter_type IDENTIFIER OPEN_BRACKET CLOSE_BRACKET", +//t "fixed_parameter : attribute_sections error", //t "fixed_parameter : opt_attributes opt_parameter_modifier parameter_type error", //t "$$26 :", //t "fixed_parameter : opt_attributes opt_parameter_modifier parameter_type IDENTIFIER ASSIGN $$26 constant_expression", @@ -499,6 +505,7 @@ namespace Mono.CSharp //t "remove_accessor_declaration : opt_attributes opt_modifiers REMOVE $$55 event_accessor_block", //t "event_accessor_block : opt_semicolon", //t "event_accessor_block : block", +//t "attributes_without_members : attribute_sections CLOSE_BRACE", //t "$$56 :", //t "$$57 :", //t "$$58 :", @@ -565,7 +572,6 @@ namespace Mono.CSharp //t "type_list : base_type_name", //t "type_list : type_list COMMA base_type_name", //t "base_type_name : type", -//t "base_type_name : error", //t "builtin_types : OBJECT", //t "builtin_types : STRING", //t "builtin_types : BOOL", @@ -646,7 +652,7 @@ namespace Mono.CSharp //t "argument_list : argument_or_named_argument", //t "argument_list : argument_list COMMA argument", //t "argument_list : argument_list COMMA named_argument", -//t "argument_list : argument_list COMMA", +//t "argument_list : argument_list COMMA error", //t "argument_list : COMMA error", //t "argument : expression", //t "argument : non_simple_argument", @@ -777,7 +783,8 @@ namespace Mono.CSharp //t "null_coalescing_expression : conditional_or_expression", //t "null_coalescing_expression : conditional_or_expression OP_COALESCING null_coalescing_expression", //t "conditional_expression : null_coalescing_expression", -//t "conditional_expression : null_coalescing_expression INTERR expression COLON expression", +//t "conditional_expression : null_coalescing_expression INTERR expression COLON expression_or_error", +//t "conditional_expression : null_coalescing_expression INTERR expression error", //t "assignment_expression : prefixed_unary_expression ASSIGN expression", //t "assignment_expression : prefixed_unary_expression OP_MULT_ASSIGN expression", //t "assignment_expression : prefixed_unary_expression OP_DIV_ASSIGN expression", @@ -851,12 +858,13 @@ namespace Mono.CSharp //t "modifier : ASYNC", //t "opt_class_base :", //t "opt_class_base : COLON type_list", +//t "opt_class_base : COLON type_list error", //t "opt_type_parameter_constraints_clauses :", //t "opt_type_parameter_constraints_clauses : type_parameter_constraints_clauses", -//t "opt_type_parameter_constraints_clauses : error", //t "type_parameter_constraints_clauses : type_parameter_constraints_clause", //t "type_parameter_constraints_clauses : type_parameter_constraints_clauses type_parameter_constraints_clause", //t "type_parameter_constraints_clause : WHERE IDENTIFIER COLON type_parameter_constraints", +//t "type_parameter_constraints_clause : WHERE IDENTIFIER error", //t "type_parameter_constraints : type_parameter_constraint", //t "type_parameter_constraints : type_parameter_constraints COMMA type_parameter_constraint", //t "type_parameter_constraint : type", @@ -873,6 +881,7 @@ namespace Mono.CSharp //t "block_end : COMPLETE_COMPLETION", //t "$$81 :", //t "block_prepared : OPEN_BRACE $$81 opt_statement_list CLOSE_BRACE", +//t "block_prepared : CLOSE_BRACE", //t "opt_statement_list :", //t "opt_statement_list : statement_list", //t "statement_list : statement", @@ -934,9 +943,11 @@ namespace Mono.CSharp //t "identifier_inside_body : IDENTIFIER", //t "identifier_inside_body : AWAIT", //t "$$83 :", -//t "block_variable_declaration : variable_type identifier_inside_body $$83 opt_local_variable_initializer opt_variable_declarators SEMICOLON", +//t "block_variable_declaration : variable_type identifier_inside_body $$83 opt_local_variable_initializer opt_variable_declarators semicolon_or_handle_error_close_brace", //t "$$84 :", //t "block_variable_declaration : CONST variable_type identifier_inside_body $$84 const_variable_initializer opt_const_declarators SEMICOLON", +//t "semicolon_or_handle_error_close_brace : SEMICOLON", +//t "semicolon_or_handle_error_close_brace : CLOSE_BRACE", //t "opt_local_variable_initializer :", //t "opt_local_variable_initializer : ASSIGN block_variable_initializer", //t "opt_local_variable_initializer : ASSIGN error", @@ -961,6 +972,7 @@ namespace Mono.CSharp //t "block_variable_initializer : STACKALLOC simple_type", //t "expression_statement : statement_expression SEMICOLON", //t "expression_statement : statement_expression COMPLETE_COMPLETION", +//t "expression_statement : statement_expression CLOSE_BRACE", //t "interactive_expression_statement : interactive_statement_expression SEMICOLON", //t "interactive_expression_statement : interactive_statement_expression COMPLETE_COMPLETION", //t "statement_expression : expression", @@ -984,6 +996,7 @@ namespace Mono.CSharp //t "switch_labels : switch_label", //t "switch_labels : switch_labels switch_label", //t "switch_label : CASE constant_expression COLON", +//t "switch_label : CASE constant_expression error", //t "switch_label : DEFAULT_COLON", //t "iteration_statement : while_statement", //t "iteration_statement : do_statement", @@ -997,14 +1010,17 @@ namespace Mono.CSharp //t "$$87 :", //t "for_statement : FOR open_parens_any $$87 for_statement_cont", //t "$$88 :", +//t "for_statement_cont : opt_for_initializer SEMICOLON $$88 for_statement_condition", +//t "for_statement_cont : opt_for_initializer CLOSE_PARENS", //t "$$89 :", -//t "$$90 :", -//t "for_statement_cont : opt_for_initializer SEMICOLON $$88 opt_for_condition SEMICOLON $$89 opt_for_iterator CLOSE_PARENS $$90 embedded_statement", -//t "for_statement_cont : error", +//t "for_statement_condition : opt_for_condition SEMICOLON $$89 for_statement_end", +//t "for_statement_condition : boolean_expression CLOSE_PARENS", +//t "for_statement_end : opt_for_iterator CLOSE_PARENS embedded_statement", +//t "for_statement_end : error", //t "opt_for_initializer :", //t "opt_for_initializer : for_initializer", -//t "$$91 :", -//t "for_initializer : variable_type identifier_inside_body $$91 opt_local_variable_initializer opt_variable_declarators", +//t "$$90 :", +//t "for_initializer : variable_type identifier_inside_body $$90 opt_local_variable_initializer opt_variable_declarators", //t "for_initializer : statement_expression_list", //t "opt_for_condition :", //t "opt_for_condition : boolean_expression", @@ -1015,8 +1031,8 @@ namespace Mono.CSharp //t "statement_expression_list : statement_expression_list COMMA statement_expression", //t "foreach_statement : FOREACH open_parens_any type error", //t "foreach_statement : FOREACH open_parens_any type identifier_inside_body error", -//t "$$92 :", -//t "foreach_statement : FOREACH open_parens_any type identifier_inside_body IN expression CLOSE_PARENS $$92 embedded_statement", +//t "$$91 :", +//t "foreach_statement : FOREACH open_parens_any type identifier_inside_body IN expression CLOSE_PARENS $$91 embedded_statement", //t "foreach_statement : FOREACH open_parens_any type identifier_inside_body error", //t "foreach_statement : FOREACH open_parens_any type error", //t "jump_statement : break_statement", @@ -1027,11 +1043,14 @@ namespace Mono.CSharp //t "jump_statement : yield_statement", //t "break_statement : BREAK SEMICOLON", //t "continue_statement : CONTINUE SEMICOLON", +//t "continue_statement : CONTINUE error", //t "goto_statement : GOTO identifier_inside_body SEMICOLON", //t "goto_statement : GOTO CASE constant_expression SEMICOLON", //t "goto_statement : GOTO DEFAULT SEMICOLON", //t "return_statement : RETURN opt_expression SEMICOLON", +//t "return_statement : RETURN error", //t "throw_statement : THROW opt_expression SEMICOLON", +//t "throw_statement : THROW error", //t "yield_statement : identifier_inside_body RETURN opt_expression SEMICOLON", //t "yield_statement : identifier_inside_body BREAK SEMICOLON", //t "opt_expression :", @@ -1045,21 +1064,21 @@ namespace Mono.CSharp //t "opt_identifier :", //t "opt_identifier : identifier_inside_body", //t "catch_clause : CATCH block", -//t "$$93 :", -//t "catch_clause : CATCH open_parens_any type opt_identifier CLOSE_PARENS $$93 block_prepared", +//t "$$92 :", +//t "catch_clause : CATCH open_parens_any type opt_identifier CLOSE_PARENS $$92 block_prepared", //t "catch_clause : CATCH open_parens_any error", //t "checked_statement : CHECKED block", //t "unchecked_statement : UNCHECKED block", -//t "$$94 :", -//t "unsafe_statement : UNSAFE $$94 block", +//t "$$93 :", +//t "unsafe_statement : UNSAFE $$93 block", //t "lock_statement : LOCK open_parens_any expression CLOSE_PARENS embedded_statement", //t "lock_statement : LOCK open_parens_any expression error", +//t "$$94 :", //t "$$95 :", +//t "fixed_statement : FIXED open_parens_any variable_type identifier_inside_body $$94 using_or_fixed_variable_initializer opt_using_or_fixed_variable_declarators CLOSE_PARENS $$95 embedded_statement", //t "$$96 :", -//t "fixed_statement : FIXED open_parens_any variable_type identifier_inside_body $$95 using_or_fixed_variable_initializer opt_using_or_fixed_variable_declarators CLOSE_PARENS $$96 embedded_statement", //t "$$97 :", -//t "$$98 :", -//t "using_statement : USING open_parens_any variable_type identifier_inside_body $$97 using_initialization CLOSE_PARENS $$98 embedded_statement", +//t "using_statement : USING open_parens_any variable_type identifier_inside_body $$96 using_initialization CLOSE_PARENS $$97 embedded_statement", //t "using_statement : USING open_parens_any expression CLOSE_PARENS embedded_statement", //t "using_statement : USING open_parens_any expression error", //t "using_initialization : using_or_fixed_variable_initializer opt_using_or_fixed_variable_declarators", @@ -1074,20 +1093,20 @@ namespace Mono.CSharp //t "first_from_clause : FROM_FIRST type identifier_inside_body IN expression", //t "nested_from_clause : FROM identifier_inside_body IN expression", //t "nested_from_clause : FROM type identifier_inside_body IN expression", +//t "$$98 :", +//t "from_clause : FROM identifier_inside_body IN $$98 expression_or_error", //t "$$99 :", -//t "from_clause : FROM identifier_inside_body IN $$99 expression", -//t "$$100 :", -//t "from_clause : FROM type identifier_inside_body IN $$100 expression", -//t "query_body : opt_query_body_clauses select_or_group_clause opt_query_continuation", -//t "query_body : opt_query_body_clauses COMPLETE_COMPLETION", +//t "from_clause : FROM type identifier_inside_body IN $$99 expression_or_error", +//t "query_body : query_body_clauses select_or_group_clause opt_query_continuation", +//t "query_body : select_or_group_clause opt_query_continuation", +//t "query_body : query_body_clauses COMPLETE_COMPLETION", +//t "query_body : query_body_clauses error", //t "query_body : error", +//t "$$100 :", +//t "select_or_group_clause : SELECT $$100 expression_or_error", //t "$$101 :", -//t "select_or_group_clause : SELECT $$101 expression", //t "$$102 :", -//t "$$103 :", -//t "select_or_group_clause : GROUP $$102 expression $$103 BY expression", -//t "opt_query_body_clauses :", -//t "opt_query_body_clauses : query_body_clauses", +//t "select_or_group_clause : GROUP $$101 expression_or_error $$102 BY expression_or_error", //t "query_body_clauses : query_body_clause", //t "query_body_clauses : query_body_clauses query_body_clause", //t "query_body_clause : from_clause", @@ -1095,28 +1114,28 @@ namespace Mono.CSharp //t "query_body_clause : where_clause", //t "query_body_clause : join_clause", //t "query_body_clause : orderby_clause", +//t "$$103 :", +//t "let_clause : LET identifier_inside_body ASSIGN $$103 expression_or_error", //t "$$104 :", -//t "let_clause : LET identifier_inside_body ASSIGN $$104 expression", +//t "where_clause : WHERE $$104 expression_or_error", //t "$$105 :", -//t "where_clause : WHERE $$105 expression", //t "$$106 :", //t "$$107 :", +//t "join_clause : JOIN identifier_inside_body IN $$105 expression_or_error ON $$106 expression_or_error EQUALS $$107 expression_or_error opt_join_into", //t "$$108 :", -//t "join_clause : JOIN identifier_inside_body IN $$106 expression ON $$107 expression EQUALS $$108 expression opt_join_into", //t "$$109 :", //t "$$110 :", -//t "$$111 :", -//t "join_clause : JOIN type identifier_inside_body IN $$109 expression ON $$110 expression EQUALS $$111 expression opt_join_into", +//t "join_clause : JOIN type identifier_inside_body IN $$108 expression_or_error ON $$109 expression_or_error EQUALS $$110 expression_or_error opt_join_into", //t "opt_join_into :", //t "opt_join_into : INTO identifier_inside_body", -//t "$$112 :", -//t "orderby_clause : ORDERBY $$112 orderings", +//t "$$111 :", +//t "orderby_clause : ORDERBY $$111 orderings", //t "orderings : order_by", -//t "$$113 :", -//t "orderings : order_by COMMA $$113 orderings_then_by", +//t "$$112 :", +//t "orderings : order_by COMMA $$112 orderings_then_by", //t "orderings_then_by : then_by", -//t "$$114 :", -//t "orderings_then_by : orderings_then_by COMMA $$114 then_by", +//t "$$113 :", +//t "orderings_then_by : orderings_then_by COMMA $$113 then_by", //t "order_by : expression", //t "order_by : expression ASCENDING", //t "order_by : expression DESCENDING", @@ -1124,12 +1143,12 @@ namespace Mono.CSharp //t "then_by : expression ASCENDING", //t "then_by : expression DESCENDING", //t "opt_query_continuation :", -//t "$$115 :", -//t "opt_query_continuation : INTO identifier_inside_body $$115 query_body", +//t "$$114 :", +//t "opt_query_continuation : INTO identifier_inside_body $$114 query_body", //t "interactive_parsing : EVAL_STATEMENT_PARSER EOF", //t "interactive_parsing : EVAL_USING_DECLARATIONS_UNIT_PARSER using_directives opt_COMPLETE_COMPLETION", -//t "$$116 :", -//t "interactive_parsing : EVAL_STATEMENT_PARSER $$116 interactive_statement_list opt_COMPLETE_COMPLETION", +//t "$$115 :", +//t "interactive_parsing : EVAL_STATEMENT_PARSER $$115 interactive_statement_list opt_COMPLETE_COMPLETION", //t "interactive_parsing : EVAL_COMPILATION_UNIT_PARSER interactive_compilation_unit", //t "interactive_compilation_unit : opt_extern_alias_directives opt_using_directives", //t "interactive_compilation_unit : opt_extern_alias_directives opt_using_directives namespace_or_type_declarations", @@ -1142,16 +1161,16 @@ namespace Mono.CSharp //t "doc_cref : builtin_types opt_doc_method_sig", //t "doc_cref : builtin_types DOT IDENTIFIER opt_doc_method_sig", //t "doc_cref : doc_type_declaration_name DOT THIS", -//t "$$117 :", -//t "doc_cref : doc_type_declaration_name DOT THIS OPEN_BRACKET $$117 opt_doc_parameters CLOSE_BRACKET", +//t "$$116 :", +//t "doc_cref : doc_type_declaration_name DOT THIS OPEN_BRACKET $$116 opt_doc_parameters CLOSE_BRACKET", //t "doc_cref : EXPLICIT OPERATOR type opt_doc_method_sig", //t "doc_cref : IMPLICIT OPERATOR type opt_doc_method_sig", //t "doc_cref : OPERATOR overloadable_operator opt_doc_method_sig", //t "doc_type_declaration_name : type_declaration_name", //t "doc_type_declaration_name : doc_type_declaration_name DOT type_declaration_name", //t "opt_doc_method_sig :", -//t "$$118 :", -//t "opt_doc_method_sig : OPEN_PARENS $$118 opt_doc_parameters CLOSE_PARENS", +//t "$$117 :", +//t "opt_doc_method_sig : OPEN_PARENS $$117 opt_doc_parameters CLOSE_PARENS", //t "opt_doc_parameters :", //t "opt_doc_parameters : doc_parameters", //t "doc_parameters : doc_parameter", @@ -1396,20 +1415,20 @@ namespace Mono.CSharp yyVal = yyV > yyTop ? null : yyVals[yyV]; // yyVal = yyDefault(yyV > yyTop ? null : yyVals[yyV]); switch (yyN) { case 1: -#line 388 "cs-parser.jay" +#line 390 "cs-parser.jay" { Lexer.check_incorrect_doc_comment (); } break; case 2: -#line 389 "cs-parser.jay" +#line 391 "cs-parser.jay" { Lexer.CompleteOnEOF = false; } break; case 6: case_6(); break; case 7: -#line 406 "cs-parser.jay" +#line 410 "cs-parser.jay" { module.AddAttributes ((Attributes) yyVals[0+yyTop], current_namespace); } @@ -1421,7 +1440,7 @@ case 13: case_13(); break; case 14: -#line 451 "cs-parser.jay" +#line 455 "cs-parser.jay" { Error_SyntaxError (yyToken); } @@ -1460,13 +1479,13 @@ case 39: case_39(); break; case 40: -#line 626 "cs-parser.jay" +#line 621 "cs-parser.jay" { current_namespace.DeclarationFound = true; } break; -case 48: - case_48(); +case 41: + case_41(); break; case 49: case_49(); @@ -1490,47 +1509,47 @@ case 55: case_55(); break; case 56: + case_56(); + break; +case 57: #line 735 "cs-parser.jay" { yyVal = "event"; savedCloseLocation = GetLocation (yyVals[0+yyTop]); } break; -case 57: +case 58: #line 736 "cs-parser.jay" { yyVal = "return"; savedCloseLocation = GetLocation (yyVals[0+yyTop]); } break; -case 58: - case_58(); - break; case 59: + case_59(); + break; +case 60: #line 753 "cs-parser.jay" { yyVal = new List (4) { (Attribute) yyVals[0+yyTop] }; } break; -case 60: - case_60(); - break; case 61: + case_61(); + break; +case 62: #line 768 "cs-parser.jay" { ++lexer.parsing_block; } break; -case 62: - case_62(); - break; -case 64: -#line 794 "cs-parser.jay" - { yyVal = null; } +case 63: + case_63(); break; case 65: - case_65(); +#line 796 "cs-parser.jay" + { yyVal = null; HadAttributeParens = false; } break; case 66: -#line 805 "cs-parser.jay" - { yyVal = null; } + case_66(); break; case 67: - case_67(); +#line 808 "cs-parser.jay" + { yyVal = null; } break; case 68: case_68(); @@ -1542,65 +1561,62 @@ case 70: case_70(); break; case 71: -#line 849 "cs-parser.jay" + case_71(); + break; +case 72: +#line 852 "cs-parser.jay" { yyVal = new Argument ((Expression) yyVals[0+yyTop]); } break; -case 73: -#line 857 "cs-parser.jay" +case 74: +#line 860 "cs-parser.jay" { ++lexer.parsing_block; } break; -case 74: - case_74(); - break; case 75: case_75(); break; case 76: -#line 883 "cs-parser.jay" - { yyVal = null; } + case_76(); break; case 77: -#line 887 "cs-parser.jay" +#line 886 "cs-parser.jay" + { yyVal = null; } + break; +case 78: +#line 890 "cs-parser.jay" { yyVal = Argument.AType.Ref; } break; -case 78: -#line 891 "cs-parser.jay" +case 79: +#line 894 "cs-parser.jay" { yyVal = Argument.AType.Out; } break; -case 81: -#line 903 "cs-parser.jay" - { - lexer.parsing_modifiers = true; - } - break; case 82: -#line 907 "cs-parser.jay" +#line 906 "cs-parser.jay" { lexer.parsing_modifiers = true; } break; -case 93: - case_93(); - break; -case 94: -#line 937 "cs-parser.jay" +case 83: +#line 910 "cs-parser.jay" { - lexer.ConstraintsParsing = true; + lexer.parsing_modifiers = true; } break; case 95: case_95(); break; case 96: - case_96(); +#line 941 "cs-parser.jay" + { + lexer.ConstraintsParsing = true; + } break; case 97: case_97(); @@ -1612,49 +1628,49 @@ case 99: case_99(); break; case 100: -#line 979 "cs-parser.jay" - { - Error_SyntaxError (yyToken); - } + case_100(); break; case 101: case_101(); break; case 102: - case_102(); - break; -case 105: -#line 1020 "cs-parser.jay" +#line 984 "cs-parser.jay" { - current_field.AddDeclarator ((FieldDeclarator) yyVals[0+yyTop]); + Error_SyntaxError (yyToken); } break; -case 106: -#line 1024 "cs-parser.jay" +case 103: + case_103(); + break; +case 104: + case_104(); + break; +case 107: +#line 1025 "cs-parser.jay" { current_field.AddDeclarator ((FieldDeclarator) yyVals[0+yyTop]); } break; -case 107: - case_107(); - break; case 108: -#line 1040 "cs-parser.jay" +#line 1029 "cs-parser.jay" { - ++lexer.parsing_block; + current_field.AddDeclarator ((FieldDeclarator) yyVals[0+yyTop]); } break; case 109: case_109(); break; case 110: - case_110(); +#line 1045 "cs-parser.jay" + { + ++lexer.parsing_block; + } break; -case 113: - case_113(); +case 111: + case_111(); break; -case 114: - case_114(); +case 112: + case_112(); break; case 115: case_115(); @@ -1663,129 +1679,129 @@ case 116: case_116(); break; case 117: -#line 1119 "cs-parser.jay" + case_117(); + break; +case 118: + case_118(); + break; +case 119: +#line 1124 "cs-parser.jay" { report.Error (1641, GetLocation (yyVals[-1+yyTop]), "A fixed size buffer field must have the array size specifier after the field name"); } break; -case 119: - case_119(); - break; -case 120: - case_120(); +case 121: + case_121(); break; -case 123: -#line 1149 "cs-parser.jay" - { - current_field.AddDeclarator ((FieldDeclarator) yyVals[0+yyTop]); - } +case 122: + case_122(); break; -case 124: -#line 1153 "cs-parser.jay" +case 125: +#line 1154 "cs-parser.jay" { current_field.AddDeclarator ((FieldDeclarator) yyVals[0+yyTop]); } break; -case 125: - case_125(); - break; case 126: -#line 1166 "cs-parser.jay" +#line 1158 "cs-parser.jay" { - ++lexer.parsing_block; + current_field.AddDeclarator ((FieldDeclarator) yyVals[0+yyTop]); } break; case 127: case_127(); break; -case 130: -#line 1185 "cs-parser.jay" +case 128: +#line 1171 "cs-parser.jay" { - current_field.AddDeclarator ((FieldDeclarator) yyVals[0+yyTop]); + ++lexer.parsing_block; } break; -case 131: -#line 1189 "cs-parser.jay" +case 129: + case_129(); + break; +case 132: +#line 1190 "cs-parser.jay" { current_field.AddDeclarator ((FieldDeclarator) yyVals[0+yyTop]); } break; -case 132: - case_132(); - break; case 133: -#line 1205 "cs-parser.jay" +#line 1194 "cs-parser.jay" { - ++lexer.parsing_block; + current_field.AddDeclarator ((FieldDeclarator) yyVals[0+yyTop]); } break; case 134: case_134(); break; case 135: - case_135(); +#line 1210 "cs-parser.jay" + { + ++lexer.parsing_block; + } break; -case 138: - case_138(); +case 136: + case_136(); break; -case 139: - case_139(); +case 137: + case_137(); break; case 140: case_140(); break; case 141: -#line 1276 "cs-parser.jay" - { - valid_param_mod = ParameterModifierType.All; - } + case_141(); break; case 142: -#line 1280 "cs-parser.jay" - { - lexer.ConstraintsParsing = true; - } + case_142(); break; case 143: - case_143(); +#line 1281 "cs-parser.jay" + { + valid_param_mod = ParameterModifierType.All; + } break; case 144: -#line 1306 "cs-parser.jay" +#line 1285 "cs-parser.jay" { - lexer.parsing_generic_declaration = true; + lexer.ConstraintsParsing = true; } break; case 145: case_145(); break; case 146: -#line 1316 "cs-parser.jay" +#line 1311 "cs-parser.jay" { - lexer.ConstraintsParsing = true; + lexer.parsing_generic_declaration = true; } break; case 147: case_147(); break; case 148: - case_148(); +#line 1321 "cs-parser.jay" + { + lexer.ConstraintsParsing = true; + } + break; +case 149: + case_149(); break; case 150: -#line 1364 "cs-parser.jay" - { savedLocation = GetLocation (yyVals[0+yyTop]); yyVal = null; } + case_150(); break; case 151: -#line 1368 "cs-parser.jay" - { yyVal = ParametersCompiled.EmptyReadOnlyParameters; } + case_151(); break; case 153: - case_153(); +#line 1386 "cs-parser.jay" + { savedLocation = GetLocation (yyVals[0+yyTop]); yyVal = null; } break; case 154: - case_154(); - break; -case 155: - case_155(); +#line 1390 "cs-parser.jay" + { yyVal = ParametersCompiled.EmptyReadOnlyParameters; } break; case 156: case_156(); @@ -1800,25 +1816,25 @@ case 159: case_159(); break; case 160: -#line 1440 "cs-parser.jay" - { - yyVal = new ParametersCompiled (new Parameter[] { (Parameter) yyVals[0+yyTop] } ); - } + case_160(); break; case 161: -#line 1444 "cs-parser.jay" - { - yyVal = new ParametersCompiled (new Parameter [] { new ArglistParameter (GetLocation (yyVals[0+yyTop])) }, true); - } + case_161(); break; case 162: case_162(); break; case 163: - case_163(); +#line 1462 "cs-parser.jay" + { + yyVal = new ParametersCompiled (new Parameter[] { (Parameter) yyVals[0+yyTop] } ); + } break; case 164: - case_164(); +#line 1466 "cs-parser.jay" + { + yyVal = new ParametersCompiled (new Parameter [] { new ArglistParameter (GetLocation (yyVals[0+yyTop])) }, true); + } break; case 165: case_165(); @@ -1830,35 +1846,35 @@ case 167: case_167(); break; case 168: -#line 1519 "cs-parser.jay" - { - ++lexer.parsing_block; - } + case_168(); break; case 169: case_169(); break; case 170: -#line 1560 "cs-parser.jay" - { yyVal = Parameter.Modifier.NONE; } + case_170(); + break; +case 171: + case_171(); break; case 172: -#line 1568 "cs-parser.jay" +#line 1547 "cs-parser.jay" { - yyVal = yyVals[0+yyTop]; + ++lexer.parsing_block; } break; case 173: case_173(); break; case 174: - case_174(); - break; -case 175: - case_175(); +#line 1588 "cs-parser.jay" + { yyVal = Parameter.Modifier.NONE; } break; case 176: - case_176(); +#line 1596 "cs-parser.jay" + { + yyVal = yyVals[0+yyTop]; + } break; case 177: case_177(); @@ -1876,10 +1892,7 @@ case 181: case_181(); break; case 182: -#line 1661 "cs-parser.jay" - { - Error_DuplicateParameterModifier (GetLocation (yyVals[-1+yyTop]), Parameter.Modifier.PARAMS); - } + case_182(); break; case 183: case_183(); @@ -1891,44 +1904,50 @@ case 185: case_185(); break; case 186: - case_186(); +#line 1689 "cs-parser.jay" + { + Error_DuplicateParameterModifier (GetLocation (yyVals[-1+yyTop]), Parameter.Modifier.PARAMS); + } break; case 187: case_187(); break; case 188: -#line 1715 "cs-parser.jay" - { - valid_param_mod = ParameterModifierType.Params | ParameterModifierType.DefaultValue; - } + case_188(); break; case 189: case_189(); break; case 190: -#line 1744 "cs-parser.jay" - { - lexer.PropertyParsing = false; - } + case_190(); break; case 191: case_191(); break; -case 196: - case_196(); +case 192: +#line 1743 "cs-parser.jay" + { + valid_param_mod = ParameterModifierType.Params | ParameterModifierType.DefaultValue; + } break; -case 197: - case_197(); +case 193: + case_193(); break; -case 198: - case_198(); +case 194: +#line 1772 "cs-parser.jay" + { + lexer.PropertyParsing = false; + } break; -case 199: - case_199(); +case 195: + case_195(); break; case 200: case_200(); break; +case 201: + case_201(); + break; case 202: case_202(); break; @@ -1936,13 +1955,7 @@ case 203: case_203(); break; case 204: -#line 1893 "cs-parser.jay" - { - lexer.ConstraintsParsing = true; - } - break; -case 205: - case_205(); + case_204(); break; case 206: case_206(); @@ -1951,194 +1964,197 @@ case 207: case_207(); break; case 208: - case_208(); +#line 1921 "cs-parser.jay" + { + lexer.ConstraintsParsing = true; + } break; case 209: -#line 1931 "cs-parser.jay" + case_209(); + break; +case 210: + case_210(); + break; +case 211: + case_211(); + break; +case 212: + case_212(); + break; +case 213: +#line 1960 "cs-parser.jay" { Error_SyntaxError (yyToken); } break; -case 212: -#line 1943 "cs-parser.jay" +case 216: +#line 1972 "cs-parser.jay" { lexer.parsing_modifiers = true; } break; -case 213: -#line 1947 "cs-parser.jay" +case 217: +#line 1976 "cs-parser.jay" { lexer.parsing_modifiers = true; } break; -case 214: -#line 1954 "cs-parser.jay" +case 218: +#line 1983 "cs-parser.jay" { report.Error (525, GetLocation (yyVals[0+yyTop]), "Interfaces cannot contain fields or constants"); } break; -case 215: -#line 1958 "cs-parser.jay" +case 219: +#line 1987 "cs-parser.jay" { report.Error (525, GetLocation (yyVals[0+yyTop]), "Interfaces cannot contain fields or constants"); } break; -case 220: -#line 1966 "cs-parser.jay" +case 224: +#line 1995 "cs-parser.jay" { report.Error (567, GetLocation (yyVals[0+yyTop]), "Interfaces cannot contain operators"); } break; -case 221: -#line 1970 "cs-parser.jay" +case 225: +#line 1999 "cs-parser.jay" { report.Error (526, GetLocation (yyVals[0+yyTop]), "Interfaces cannot contain contructors"); } break; -case 222: -#line 1974 "cs-parser.jay" +case 226: +#line 2003 "cs-parser.jay" { report.Error (524, GetLocation (yyVals[0+yyTop]), "Interfaces cannot declare classes, structs, interfaces, delegates, or enumerations"); } break; -case 223: -#line 1980 "cs-parser.jay" +case 227: +#line 2009 "cs-parser.jay" { } break; -case 224: - case_224(); +case 228: + case_228(); break; -case 226: -#line 2013 "cs-parser.jay" +case 230: +#line 2042 "cs-parser.jay" { savedLocation = GetLocation (yyVals[0+yyTop]); yyVal = null; } break; -case 228: - case_228(); +case 232: + case_232(); break; -case 229: -#line 2029 "cs-parser.jay" +case 233: +#line 2058 "cs-parser.jay" { valid_param_mod = ParameterModifierType.DefaultValue; } break; -case 230: - case_230(); +case 234: + case_234(); break; -case 232: -#line 2075 "cs-parser.jay" +case 236: +#line 2104 "cs-parser.jay" { yyVal = Operator.OpType.LogicalNot; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 233: -#line 2076 "cs-parser.jay" +case 237: +#line 2105 "cs-parser.jay" { yyVal = Operator.OpType.OnesComplement; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 234: -#line 2077 "cs-parser.jay" +case 238: +#line 2106 "cs-parser.jay" { yyVal = Operator.OpType.Increment; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 235: -#line 2078 "cs-parser.jay" +case 239: +#line 2107 "cs-parser.jay" { yyVal = Operator.OpType.Decrement; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 236: -#line 2079 "cs-parser.jay" +case 240: +#line 2108 "cs-parser.jay" { yyVal = Operator.OpType.True; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 237: -#line 2080 "cs-parser.jay" +case 241: +#line 2109 "cs-parser.jay" { yyVal = Operator.OpType.False; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 238: -#line 2082 "cs-parser.jay" +case 242: +#line 2111 "cs-parser.jay" { yyVal = Operator.OpType.Addition; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 239: -#line 2083 "cs-parser.jay" +case 243: +#line 2112 "cs-parser.jay" { yyVal = Operator.OpType.Subtraction; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 240: -#line 2085 "cs-parser.jay" +case 244: +#line 2114 "cs-parser.jay" { yyVal = Operator.OpType.Multiply; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 241: -#line 2086 "cs-parser.jay" +case 245: +#line 2115 "cs-parser.jay" { yyVal = Operator.OpType.Division; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 242: -#line 2087 "cs-parser.jay" +case 246: +#line 2116 "cs-parser.jay" { yyVal = Operator.OpType.Modulus; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 243: -#line 2088 "cs-parser.jay" +case 247: +#line 2117 "cs-parser.jay" { yyVal = Operator.OpType.BitwiseAnd; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 244: -#line 2089 "cs-parser.jay" +case 248: +#line 2118 "cs-parser.jay" { yyVal = Operator.OpType.BitwiseOr; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 245: -#line 2090 "cs-parser.jay" +case 249: +#line 2119 "cs-parser.jay" { yyVal = Operator.OpType.ExclusiveOr; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 246: -#line 2091 "cs-parser.jay" +case 250: +#line 2120 "cs-parser.jay" { yyVal = Operator.OpType.LeftShift; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 247: -#line 2092 "cs-parser.jay" +case 251: +#line 2121 "cs-parser.jay" { yyVal = Operator.OpType.RightShift; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 248: -#line 2093 "cs-parser.jay" +case 252: +#line 2122 "cs-parser.jay" { yyVal = Operator.OpType.Equality; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 249: -#line 2094 "cs-parser.jay" +case 253: +#line 2123 "cs-parser.jay" { yyVal = Operator.OpType.Inequality; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 250: -#line 2095 "cs-parser.jay" +case 254: +#line 2124 "cs-parser.jay" { yyVal = Operator.OpType.GreaterThan; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 251: -#line 2096 "cs-parser.jay" +case 255: +#line 2125 "cs-parser.jay" { yyVal = Operator.OpType.LessThan; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 252: -#line 2097 "cs-parser.jay" +case 256: +#line 2126 "cs-parser.jay" { yyVal = Operator.OpType.GreaterThanOrEqual; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 253: -#line 2098 "cs-parser.jay" +case 257: +#line 2127 "cs-parser.jay" { yyVal = Operator.OpType.LessThanOrEqual; savedOperatorLocation = GetLocation (yyVals[0+yyTop]); } break; -case 254: -#line 2105 "cs-parser.jay" +case 258: +#line 2134 "cs-parser.jay" { valid_param_mod = ParameterModifierType.DefaultValue; } break; -case 255: - case_255(); - break; -case 256: -#line 2124 "cs-parser.jay" - { - valid_param_mod = ParameterModifierType.DefaultValue; - } - break; -case 257: - case_257(); - break; -case 258: - case_258(); - break; case 259: case_259(); break; case 260: - case_260(); +#line 2153 "cs-parser.jay" + { + valid_param_mod = ParameterModifierType.DefaultValue; + } break; case 261: case_261(); @@ -2149,36 +2165,36 @@ case 262: case 263: case_263(); break; +case 264: + case_264(); + break; case 265: -#line 2230 "cs-parser.jay" - { current_block = null; yyVal = null; } + case_265(); break; -case 268: -#line 2242 "cs-parser.jay" - { - ++lexer.parsing_block; - } +case 266: + case_266(); + break; +case 267: + case_267(); break; case 269: - case_269(); +#line 2259 "cs-parser.jay" + { current_block = null; yyVal = null; } break; -case 270: -#line 2252 "cs-parser.jay" +case 272: +#line 2271 "cs-parser.jay" { ++lexer.parsing_block; } break; -case 271: - case_271(); - break; -case 272: - case_272(); - break; case 273: case_273(); break; case 274: - case_274(); +#line 2281 "cs-parser.jay" + { + ++lexer.parsing_block; + } break; case 275: case_275(); @@ -2198,59 +2214,59 @@ case 279: case 280: case_280(); break; +case 281: + case_281(); + break; case 282: -#line 2367 "cs-parser.jay" - { - ++lexer.parsing_block; - } + case_282(); break; case 283: case_283(); break; +case 284: + case_284(); + break; case 286: -#line 2384 "cs-parser.jay" +#line 2397 "cs-parser.jay" { - current_event_field.AddDeclarator ((FieldDeclarator) yyVals[0+yyTop]); + ++lexer.parsing_block; } break; case 287: -#line 2388 "cs-parser.jay" + case_287(); + break; +case 290: +#line 2414 "cs-parser.jay" { current_event_field.AddDeclarator ((FieldDeclarator) yyVals[0+yyTop]); } break; -case 288: - case_288(); - break; -case 289: -#line 2401 "cs-parser.jay" +case 291: +#line 2418 "cs-parser.jay" { - ++lexer.parsing_block; + current_event_field.AddDeclarator ((FieldDeclarator) yyVals[0+yyTop]); } break; -case 290: - case_290(); - break; -case 291: - case_291(); - break; case 292: -#line 2426 "cs-parser.jay" + case_292(); + break; +case 293: +#line 2431 "cs-parser.jay" { - yyVal = yyVals[0+yyTop]; + ++lexer.parsing_block; } break; +case 294: + case_294(); + break; case 295: case_295(); break; case 296: - case_296(); - break; -case 297: - case_297(); - break; -case 298: - case_298(); +#line 2456 "cs-parser.jay" + { + yyVal = yyVals[0+yyTop]; + } break; case 299: case_299(); @@ -2264,6 +2280,9 @@ case 301: case 302: case_302(); break; +case 303: + case_303(); + break; case 304: case_304(); break; @@ -2273,8 +2292,8 @@ case 305: case 306: case_306(); break; -case 307: - case_307(); +case 308: + case_308(); break; case 309: case_309(); @@ -2282,50 +2301,53 @@ case 309: case 310: case_310(); break; -case 313: -#line 2589 "cs-parser.jay" - { - lbag.AppendToMember (current_class, GetLocation (yyVals[0+yyTop])); - } +case 311: + case_311(); break; -case 315: - case_315(); +case 312: + case_312(); break; -case 316: - case_316(); +case 314: + case_314(); break; -case 317: - case_317(); +case 315: + case_315(); break; case 318: - case_318(); - break; -case 319: -#line 2647 "cs-parser.jay" +#line 2624 "cs-parser.jay" { - valid_param_mod = ParameterModifierType.Ref | ParameterModifierType.Out | ParameterModifierType.Params | ParameterModifierType.DefaultValue; + lbag.AppendToMember (current_container, GetLocation (yyVals[0+yyTop])); } break; case 320: case_320(); break; case 321: -#line 2669 "cs-parser.jay" - { - lexer.ConstraintsParsing = false; - } + case_321(); break; case 322: case_322(); break; +case 323: + case_323(); + break; case 324: - case_324(); +#line 2682 "cs-parser.jay" + { + valid_param_mod = ParameterModifierType.Ref | ParameterModifierType.Out | ParameterModifierType.Params | ParameterModifierType.DefaultValue; + } + break; +case 325: + case_325(); break; case 326: - case_326(); +#line 2701 "cs-parser.jay" + { + lexer.ConstraintsParsing = false; + } break; -case 328: - case_328(); +case 327: + case_327(); break; case 329: case_329(); @@ -2333,32 +2355,29 @@ case 329: case 331: case_331(); break; -case 332: - case_332(); - break; case 333: case_333(); break; case 334: case_334(); break; -case 335: -#line 2775 "cs-parser.jay" - { - lexer.parsing_generic_declaration = true; - } - break; case 336: case_336(); break; case 337: case_337(); break; +case 338: + case_338(); + break; case 339: case_339(); break; case 340: - case_340(); +#line 2807 "cs-parser.jay" + { + lexer.parsing_generic_declaration = true; + } break; case 341: case_341(); @@ -2366,12 +2385,12 @@ case 341: case 342: case_342(); break; -case 343: - case_343(); - break; case 344: case_344(); break; +case 345: + case_345(); + break; case 346: case_346(); break; @@ -2384,195 +2403,194 @@ case 348: case 349: case_349(); break; -case 350: - case_350(); +case 351: + case_351(); break; case 352: -#line 2893 "cs-parser.jay" - { - yyVal = new TypeExpression (compiler.BuiltinTypes.Void, GetLocation (yyVals[0+yyTop])); - } + case_352(); break; case 353: -#line 2900 "cs-parser.jay" - { - lexer.parsing_generic_declaration = true; - } + case_353(); + break; +case 354: + case_354(); break; case 355: case_355(); break; case 357: - case_357(); - break; -case 359: - case_359(); +#line 2929 "cs-parser.jay" + { + yyVal = new TypeExpression (compiler.BuiltinTypes.Void, GetLocation (yyVals[0+yyTop])); + } break; -case 361: -#line 2938 "cs-parser.jay" +case 358: +#line 2936 "cs-parser.jay" { - yyVal = new ComposedCast ((FullNamedExpression) yyVals[-1+yyTop], (ComposedTypeSpecifier) yyVals[0+yyTop]); + lexer.parsing_generic_declaration = true; } break; +case 360: + case_360(); + break; case 362: case_362(); break; -case 363: -#line 2957 "cs-parser.jay" - { - yyVal = new ComposedCast ((ATypeNameExpression) yyVals[-1+yyTop], (ComposedTypeSpecifier) yyVals[0+yyTop]); - } - break; case 364: case_364(); break; -case 365: -#line 2966 "cs-parser.jay" - { - yyVal = new ComposedCast ((FullNamedExpression) yyVals[-1+yyTop], (ComposedTypeSpecifier) yyVals[0+yyTop]); - } - break; case 366: -#line 2970 "cs-parser.jay" +#line 2974 "cs-parser.jay" { - yyVal = new ComposedCast (new TypeExpression (compiler.BuiltinTypes.Void, GetLocation (yyVals[-1+yyTop])), (ComposedTypeSpecifier) yyVals[0+yyTop]); + yyVal = new ComposedCast ((FullNamedExpression) yyVals[-1+yyTop], (ComposedTypeSpecifier) yyVals[0+yyTop]); } break; case 367: case_367(); break; case 368: - case_368(); +#line 2993 "cs-parser.jay" + { + yyVal = new ComposedCast ((ATypeNameExpression) yyVals[-1+yyTop], (ComposedTypeSpecifier) yyVals[0+yyTop]); + } break; case 369: case_369(); break; case 370: - case_370(); +#line 3002 "cs-parser.jay" + { + yyVal = new ComposedCast ((FullNamedExpression) yyVals[-1+yyTop], (ComposedTypeSpecifier) yyVals[0+yyTop]); + } break; case 371: -#line 3009 "cs-parser.jay" - { yyVal = new TypeExpression (compiler.BuiltinTypes.Object, GetLocation (yyVals[0+yyTop])); } +#line 3006 "cs-parser.jay" + { + yyVal = new ComposedCast (new TypeExpression (compiler.BuiltinTypes.Void, GetLocation (yyVals[-1+yyTop])), (ComposedTypeSpecifier) yyVals[0+yyTop]); + } break; case 372: -#line 3010 "cs-parser.jay" - { yyVal = new TypeExpression (compiler.BuiltinTypes.String, GetLocation (yyVals[0+yyTop])); } + case_372(); break; case 373: -#line 3011 "cs-parser.jay" - { yyVal = new TypeExpression (compiler.BuiltinTypes.Bool, GetLocation (yyVals[0+yyTop])); } + case_373(); break; case 374: -#line 3012 "cs-parser.jay" - { yyVal = new TypeExpression (compiler.BuiltinTypes.Decimal, GetLocation (yyVals[0+yyTop])); } + case_374(); break; case 375: -#line 3013 "cs-parser.jay" - { yyVal = new TypeExpression (compiler.BuiltinTypes.Float, GetLocation (yyVals[0+yyTop])); } +#line 3040 "cs-parser.jay" + { yyVal = new TypeExpression (compiler.BuiltinTypes.Object, GetLocation (yyVals[0+yyTop])); } break; case 376: -#line 3014 "cs-parser.jay" - { yyVal = new TypeExpression (compiler.BuiltinTypes.Double, GetLocation (yyVals[0+yyTop])); } +#line 3041 "cs-parser.jay" + { yyVal = new TypeExpression (compiler.BuiltinTypes.String, GetLocation (yyVals[0+yyTop])); } + break; +case 377: +#line 3042 "cs-parser.jay" + { yyVal = new TypeExpression (compiler.BuiltinTypes.Bool, GetLocation (yyVals[0+yyTop])); } break; case 378: -#line 3019 "cs-parser.jay" - { yyVal = new TypeExpression (compiler.BuiltinTypes.SByte, GetLocation (yyVals[0+yyTop])); } +#line 3043 "cs-parser.jay" + { yyVal = new TypeExpression (compiler.BuiltinTypes.Decimal, GetLocation (yyVals[0+yyTop])); } break; case 379: -#line 3020 "cs-parser.jay" - { yyVal = new TypeExpression (compiler.BuiltinTypes.Byte, GetLocation (yyVals[0+yyTop])); } +#line 3044 "cs-parser.jay" + { yyVal = new TypeExpression (compiler.BuiltinTypes.Float, GetLocation (yyVals[0+yyTop])); } break; case 380: -#line 3021 "cs-parser.jay" +#line 3045 "cs-parser.jay" + { yyVal = new TypeExpression (compiler.BuiltinTypes.Double, GetLocation (yyVals[0+yyTop])); } + break; +case 382: +#line 3050 "cs-parser.jay" + { yyVal = new TypeExpression (compiler.BuiltinTypes.SByte, GetLocation (yyVals[0+yyTop])); } + break; +case 383: +#line 3051 "cs-parser.jay" + { yyVal = new TypeExpression (compiler.BuiltinTypes.Byte, GetLocation (yyVals[0+yyTop])); } + break; +case 384: +#line 3052 "cs-parser.jay" { yyVal = new TypeExpression (compiler.BuiltinTypes.Short, GetLocation (yyVals[0+yyTop])); } break; -case 381: -#line 3022 "cs-parser.jay" +case 385: +#line 3053 "cs-parser.jay" { yyVal = new TypeExpression (compiler.BuiltinTypes.UShort, GetLocation (yyVals[0+yyTop])); } break; -case 382: -#line 3023 "cs-parser.jay" +case 386: +#line 3054 "cs-parser.jay" { yyVal = new TypeExpression (compiler.BuiltinTypes.Int, GetLocation (yyVals[0+yyTop])); } break; -case 383: -#line 3024 "cs-parser.jay" +case 387: +#line 3055 "cs-parser.jay" { yyVal = new TypeExpression (compiler.BuiltinTypes.UInt, GetLocation (yyVals[0+yyTop])); } break; -case 384: -#line 3025 "cs-parser.jay" +case 388: +#line 3056 "cs-parser.jay" { yyVal = new TypeExpression (compiler.BuiltinTypes.Long, GetLocation (yyVals[0+yyTop])); } break; -case 385: -#line 3026 "cs-parser.jay" +case 389: +#line 3057 "cs-parser.jay" { yyVal = new TypeExpression (compiler.BuiltinTypes.ULong, GetLocation (yyVals[0+yyTop])); } break; -case 386: -#line 3027 "cs-parser.jay" +case 390: +#line 3058 "cs-parser.jay" { yyVal = new TypeExpression (compiler.BuiltinTypes.Char, GetLocation (yyVals[0+yyTop])); } break; -case 407: - case_407(); - break; -case 408: - case_408(); +case 411: + case_411(); break; case 412: -#line 3074 "cs-parser.jay" + case_412(); + break; +case 416: +#line 3105 "cs-parser.jay" { yyVal = new NullLiteral (GetLocation (yyVals[0+yyTop])); } break; -case 413: -#line 3078 "cs-parser.jay" +case 417: +#line 3109 "cs-parser.jay" { yyVal = new BoolLiteral (compiler.BuiltinTypes, true, GetLocation (yyVals[0+yyTop])); } break; -case 414: -#line 3079 "cs-parser.jay" +case 418: +#line 3110 "cs-parser.jay" { yyVal = new BoolLiteral (compiler.BuiltinTypes, false, GetLocation (yyVals[0+yyTop])); } break; -case 419: - case_419(); - break; -case 420: -#line 3112 "cs-parser.jay" - { - yyVal = new ParenthesizedExpression ((Expression) yyVals[-1+yyTop]); - } - break; -case 421: - case_421(); - break; -case 422: - case_422(); - break; case 423: case_423(); break; case 424: - case_424(); - break; -case 425: -#line 3147 "cs-parser.jay" +#line 3143 "cs-parser.jay" { - yyVal = new CompletionMemberAccess ((Expression) yyVals[-2+yyTop], null,GetLocation (yyVals[0+yyTop])); + yyVal = new ParenthesizedExpression ((Expression) yyVals[-1+yyTop]); } break; +case 425: + case_425(); + break; case 426: case_426(); break; case 427: -#line 3155 "cs-parser.jay" - { - yyVal = new CompletionMemberAccess ((Expression) yyVals[-2+yyTop], null, lexer.Location); - } + case_427(); break; case 428: case_428(); break; case 429: - case_429(); +#line 3178 "cs-parser.jay" + { + yyVal = new CompletionMemberAccess ((Expression) yyVals[-2+yyTop], null,GetLocation (yyVals[0+yyTop])); + } break; case 430: -#line 3171 "cs-parser.jay" - { yyVal = null; } + case_430(); + break; +case 431: +#line 3186 "cs-parser.jay" + { + yyVal = new CompletionMemberAccess ((Expression) yyVals[-2+yyTop], null, lexer.Location); + } break; case 432: case_432(); @@ -2581,15 +2599,9 @@ case 433: case_433(); break; case 434: -#line 3194 "cs-parser.jay" +#line 3202 "cs-parser.jay" { yyVal = null; } break; -case 435: -#line 3198 "cs-parser.jay" - { - yyVal = yyVals[0+yyTop]; - } - break; case 436: case_436(); break; @@ -2597,16 +2609,17 @@ case 437: case_437(); break; case 438: - case_438(); +#line 3225 "cs-parser.jay" + { yyVal = null; } break; case 439: - case_439(); +#line 3229 "cs-parser.jay" + { + yyVal = yyVals[0+yyTop]; + } break; case 440: -#line 3231 "cs-parser.jay" - { - yyVal = new CompletionElementInitializer (null, GetLocation (yyVals[0+yyTop])); - } + case_440(); break; case 441: case_441(); @@ -2617,60 +2630,57 @@ case 442: case 443: case_443(); break; -case 446: -#line 3259 "cs-parser.jay" - { yyVal = null; } +case 444: +#line 3262 "cs-parser.jay" + { + yyVal = new CompletionElementInitializer (null, GetLocation (yyVals[0+yyTop])); + } break; -case 448: - case_448(); +case 445: + case_445(); break; -case 449: - case_449(); +case 446: + case_446(); break; -case 450: - case_450(); +case 447: + case_447(); break; -case 451: - case_451(); +case 450: +#line 3292 "cs-parser.jay" + { yyVal = null; } break; case 452: case_452(); break; case 453: -#line 3311 "cs-parser.jay" - { - yyVal = new Argument ((Expression) yyVals[0+yyTop]); - } + case_453(); break; -case 457: - case_457(); +case 454: + case_454(); break; -case 458: - case_458(); +case 455: + case_455(); break; -case 459: - case_459(); +case 456: + case_456(); + break; +case 457: +#line 3344 "cs-parser.jay" + { + yyVal = new Argument ((Expression) yyVals[0+yyTop]); + } break; -case 460: - case_460(); +case 461: + case_461(); break; case 462: case_462(); break; case 463: -#line 3356 "cs-parser.jay" - { - yyVal = new ElementAccess ((Expression) yyVals[-3+yyTop], (Arguments) yyVals[-1+yyTop], GetLocation (yyVals[-2+yyTop])); - } + case_463(); break; case 464: -#line 3360 "cs-parser.jay" - { - yyVal = new ElementAccess ((Expression) yyVals[-2+yyTop], null, GetLocation (yyVals[-1+yyTop])); - } - break; -case 465: - case_465(); + case_464(); break; case 466: case_466(); @@ -2685,33 +2695,27 @@ case 469: case_469(); break; case 470: -#line 3406 "cs-parser.jay" - { - yyVal = new Argument ((Expression) yyVals[0+yyTop]); - } + case_470(); + break; +case 471: + case_471(); break; case 472: -#line 3414 "cs-parser.jay" - { - yyVal = new This (GetLocation (yyVals[0+yyTop])); - } + case_472(); break; case 473: case_473(); break; case 474: - case_474(); - break; -case 475: -#line 3434 "cs-parser.jay" +#line 3441 "cs-parser.jay" { - yyVal = new UnaryMutator (UnaryMutator.Mode.PostIncrement, (Expression) yyVals[-1+yyTop], GetLocation (yyVals[0+yyTop])); + yyVal = new Argument ((Expression) yyVals[0+yyTop]); } break; case 476: -#line 3441 "cs-parser.jay" +#line 3449 "cs-parser.jay" { - yyVal = new UnaryMutator (UnaryMutator.Mode.PostDecrement, (Expression) yyVals[-1+yyTop], GetLocation (yyVals[0+yyTop])); + yyVal = new This (GetLocation (yyVals[0+yyTop])); } break; case 477: @@ -2721,10 +2725,16 @@ case 478: case_478(); break; case 479: - case_479(); +#line 3469 "cs-parser.jay" + { + yyVal = new UnaryMutator (UnaryMutator.Mode.PostIncrement, (Expression) yyVals[-1+yyTop], GetLocation (yyVals[0+yyTop])); + } break; case 480: - case_480(); +#line 3476 "cs-parser.jay" + { + yyVal = new UnaryMutator (UnaryMutator.Mode.PostDecrement, (Expression) yyVals[-1+yyTop], GetLocation (yyVals[0+yyTop])); + } break; case 481: case_481(); @@ -2736,10 +2746,7 @@ case 483: case_483(); break; case 484: -#line 3507 "cs-parser.jay" - { - ++lexer.parsing_type; - } + case_484(); break; case 485: case_485(); @@ -2747,21 +2754,24 @@ case 485: case 486: case_486(); break; -case 489: -#line 3534 "cs-parser.jay" - { yyVal = null; } +case 487: + case_487(); break; -case 491: - case_491(); +case 488: +#line 3543 "cs-parser.jay" + { + ++lexer.parsing_type; + } break; -case 492: - case_492(); +case 489: + case_489(); break; -case 493: - case_493(); +case 490: + case_490(); break; -case 494: - case_494(); +case 493: +#line 3570 "cs-parser.jay" + { yyVal = null; } break; case 495: case_495(); @@ -2769,72 +2779,72 @@ case 495: case 496: case_496(); break; +case 497: + case_497(); + break; +case 498: + case_498(); + break; +case 499: + case_499(); + break; case 500: case_500(); break; -case 501: - case_501(); +case 504: + case_504(); break; -case 502: - case_502(); +case 505: + case_505(); break; -case 503: -#line 3612 "cs-parser.jay" - { +case 506: + case_506(); + break; +case 507: +#line 3648 "cs-parser.jay" + { yyVal = 2; } break; -case 504: -#line 3616 "cs-parser.jay" +case 508: +#line 3652 "cs-parser.jay" { yyVal = ((int) yyVals[-1+yyTop]) + 1; } break; -case 505: -#line 3623 "cs-parser.jay" +case 509: +#line 3659 "cs-parser.jay" { yyVal = null; } break; -case 506: -#line 3627 "cs-parser.jay" +case 510: +#line 3663 "cs-parser.jay" { yyVal = yyVals[0+yyTop]; } break; -case 507: - case_507(); +case 511: + case_511(); break; -case 508: - case_508(); +case 512: + case_512(); break; -case 509: - case_509(); +case 513: + case_513(); break; -case 510: - case_510(); +case 514: + case_514(); break; -case 511: -#line 3671 "cs-parser.jay" +case 515: +#line 3707 "cs-parser.jay" { lexer.TypeOfParsing = true; } break; -case 512: - case_512(); - break; -case 515: - case_515(); - break; case 516: case_516(); break; -case 517: - case_517(); - break; -case 518: - case_518(); - break; case 519: case_519(); break; @@ -2860,136 +2870,139 @@ case 526: case_526(); break; case 527: -#line 3791 "cs-parser.jay" - { - start_anonymous (false, (ParametersCompiled) yyVals[0+yyTop], false, GetLocation (yyVals[-1+yyTop])); - } + case_527(); break; case 528: case_528(); break; case 529: -#line 3804 "cs-parser.jay" - { - start_anonymous (false, (ParametersCompiled) yyVals[0+yyTop], true, GetLocation (yyVals[-2+yyTop])); - } + case_529(); break; case 530: case_530(); break; case 531: -#line 3821 "cs-parser.jay" +#line 3827 "cs-parser.jay" { - yyVal = ParametersCompiled.Undefined; + start_anonymous (false, (ParametersCompiled) yyVals[0+yyTop], false, GetLocation (yyVals[-1+yyTop])); } break; +case 532: + case_532(); + break; case 533: -#line 3829 "cs-parser.jay" +#line 3840 "cs-parser.jay" { - valid_param_mod = ParameterModifierType.Ref | ParameterModifierType.Out; + start_anonymous (false, (ParametersCompiled) yyVals[0+yyTop], true, GetLocation (yyVals[-2+yyTop])); } break; case 534: case_534(); break; case 535: - case_535(); +#line 3857 "cs-parser.jay" + { + yyVal = ParametersCompiled.Undefined; + } break; case 537: -#line 3855 "cs-parser.jay" +#line 3865 "cs-parser.jay" { - yyVal = new Unary (Unary.Operator.LogicalNot, (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); + valid_param_mod = ParameterModifierType.Ref | ParameterModifierType.Out; } break; case 538: -#line 3859 "cs-parser.jay" - { - yyVal = new Unary (Unary.Operator.OnesComplement, (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); - } + case_538(); break; case 539: case_539(); break; -case 540: - case_540(); +case 541: +#line 3891 "cs-parser.jay" + { + yyVal = new Unary (Unary.Operator.LogicalNot, (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); + } break; case 542: -#line 3887 "cs-parser.jay" +#line 3895 "cs-parser.jay" + { + yyVal = new Unary (Unary.Operator.OnesComplement, (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); + } + break; +case 543: + case_543(); + break; +case 544: + case_544(); + break; +case 546: +#line 3931 "cs-parser.jay" { yyVal = new Unary (Unary.Operator.UnaryPlus, (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } break; -case 543: -#line 3891 "cs-parser.jay" +case 547: +#line 3935 "cs-parser.jay" { yyVal = new Unary (Unary.Operator.UnaryNegation, (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } break; -case 544: -#line 3895 "cs-parser.jay" +case 548: +#line 3939 "cs-parser.jay" { yyVal = new UnaryMutator (UnaryMutator.Mode.PreIncrement, (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } break; -case 545: -#line 3899 "cs-parser.jay" +case 549: +#line 3943 "cs-parser.jay" { yyVal = new UnaryMutator (UnaryMutator.Mode.PreDecrement, (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } break; -case 546: -#line 3903 "cs-parser.jay" +case 550: +#line 3947 "cs-parser.jay" { yyVal = new Indirection ((Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } break; -case 547: -#line 3907 "cs-parser.jay" +case 551: +#line 3951 "cs-parser.jay" { yyVal = new Unary (Unary.Operator.AddressOf, (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } break; -case 549: - case_549(); - break; -case 550: - case_550(); - break; -case 551: - case_551(); - break; case 553: case_553(); break; case 554: -#line 3939 "cs-parser.jay" - { - yyVal = new Binary (Binary.Operator.Subtraction, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); - } + case_554(); break; case 555: case_555(); break; -case 556: -#line 3948 "cs-parser.jay" - { - yyVal = new As ((Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); - } - break; case 557: -#line 3952 "cs-parser.jay" + case_557(); + break; +case 558: +#line 3983 "cs-parser.jay" { - yyVal = new Is ((Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); + yyVal = new Binary (Binary.Operator.Subtraction, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } break; case 559: case_559(); break; case 560: - case_560(); +#line 3992 "cs-parser.jay" + { + yyVal = new As ((Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); + } break; -case 562: - case_562(); +case 561: +#line 3996 "cs-parser.jay" + { + yyVal = new Is ((Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); + } break; case 563: case_563(); @@ -2997,8 +3010,8 @@ case 563: case 564: case_564(); break; -case 565: - case_565(); +case 566: + case_566(); break; case 567: case_567(); @@ -3006,8 +3019,11 @@ case 567: case 568: case_568(); break; -case 570: - case_570(); +case 569: + case_569(); + break; +case 571: + case_571(); break; case 572: case_572(); @@ -3027,18 +3043,9 @@ case 580: case 582: case_582(); break; -case 583: -#line 4076 "cs-parser.jay" - { - yyVal = new SimpleAssign ((Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); - } - break; case 584: case_584(); break; -case 585: - case_585(); - break; case 586: case_586(); break; @@ -3046,7 +3053,10 @@ case 587: case_587(); break; case 588: - case_588(); +#line 4125 "cs-parser.jay" + { + yyVal = new SimpleAssign ((Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); + } break; case 589: case_589(); @@ -3079,41 +3089,38 @@ case 598: case_598(); break; case 599: -#line 4173 "cs-parser.jay" - { yyVal = ParametersCompiled.EmptyReadOnlyParameters; } + case_599(); break; case 600: case_600(); break; +case 601: + case_601(); + break; +case 602: + case_602(); + break; case 603: -#line 4189 "cs-parser.jay" - { - start_block (lexer.Location); - } + case_603(); break; case 604: - case_604(); - break; -case 606: - case_606(); +#line 4222 "cs-parser.jay" + { yyVal = ParametersCompiled.EmptyReadOnlyParameters; } break; -case 607: - case_607(); +case 605: + case_605(); break; case 608: - case_608(); +#line 4238 "cs-parser.jay" + { + start_block (Location.Null); + } break; case 609: case_609(); break; -case 610: - case_610(); - break; case 611: -#line 4234 "cs-parser.jay" - { - valid_param_mod = ParameterModifierType.Ref | ParameterModifierType.Out; - } + case_611(); break; case 612: case_612(); @@ -3122,43 +3129,43 @@ case 613: case_613(); break; case 614: -#line 4248 "cs-parser.jay" - { - valid_param_mod = ParameterModifierType.Ref | ParameterModifierType.Out; - } + case_614(); break; case 615: case_615(); break; case 616: - case_616(); - break; -case 622: -#line 4273 "cs-parser.jay" +#line 4283 "cs-parser.jay" { - yyVal = new ArglistAccess (GetLocation (yyVals[0+yyTop])); + valid_param_mod = ParameterModifierType.Ref | ParameterModifierType.Out; } break; -case 623: - case_623(); +case 617: + case_617(); + break; +case 618: + case_618(); + break; +case 619: +#line 4297 "cs-parser.jay" + { + valid_param_mod = ParameterModifierType.Ref | ParameterModifierType.Out; + } break; -case 624: - case_624(); +case 620: + case_620(); break; -case 625: - case_625(); +case 621: + case_621(); break; case 627: -#line 4302 "cs-parser.jay" +#line 4322 "cs-parser.jay" { - yyVal = new BooleanExpression ((Expression) yyVals[0+yyTop]); + yyVal = new ArglistAccess (GetLocation (yyVals[0+yyTop])); } break; case 628: -#line 4315 "cs-parser.jay" - { - lexer.ConstraintsParsing = true; - } + case_628(); break; case 629: case_629(); @@ -3166,43 +3173,46 @@ case 629: case 630: case_630(); break; -case 631: - case_631(); - break; case 632: - case_632(); +#line 4351 "cs-parser.jay" + { + yyVal = new BooleanExpression ((Expression) yyVals[0+yyTop]); + } break; case 633: -#line 4359 "cs-parser.jay" - { yyVal = null; } +#line 4364 "cs-parser.jay" + { + lexer.ConstraintsParsing = true; + } break; case 634: -#line 4361 "cs-parser.jay" - { yyVal = yyVals[0+yyTop]; StoreModifierLocation (Modifiers.PARTIAL, GetLocation (yyVals[0+yyTop])); } + case_634(); break; case 635: case_635(); break; case 636: -#line 4374 "cs-parser.jay" - { - lexer.parsing_modifiers = false; - } + case_636(); + break; +case 637: + case_637(); break; case 638: - case_638(); +#line 4409 "cs-parser.jay" + { yyVal = null; } break; case 639: - case_639(); +#line 4411 "cs-parser.jay" + { yyVal = yyVals[0+yyTop]; StoreModifierLocation (Modifiers.PARTIAL, GetLocation (yyVals[0+yyTop])); } break; case 640: case_640(); break; case 641: - case_641(); - break; -case 642: - case_642(); +#line 4424 "cs-parser.jay" + { + lexer.parsing_modifiers = false; + } break; case 643: case_643(); @@ -3237,32 +3247,32 @@ case 652: case 653: case_653(); break; +case 654: + case_654(); + break; case 655: case_655(); break; +case 656: + case_656(); + break; case 657: -#line 4494 "cs-parser.jay" - { - yyVal = yyVals[0+yyTop]; - } + case_657(); break; case 658: case_658(); break; -case 659: - case_659(); - break; case 660: case_660(); break; case 661: case_661(); break; -case 662: - case_662(); - break; case 663: - case_663(); +#line 4550 "cs-parser.jay" + { + yyVal = yyVals[0+yyTop]; + } break; case 664: case_664(); @@ -3271,22 +3281,13 @@ case 665: case_665(); break; case 666: -#line 4585 "cs-parser.jay" - { - yyVal = new SpecialContraintExpr (SpecialConstraint.Class, GetLocation (yyVals[0+yyTop])); - } + case_666(); break; case 667: -#line 4589 "cs-parser.jay" - { - yyVal = new SpecialContraintExpr (SpecialConstraint.Struct, GetLocation (yyVals[0+yyTop])); - } + case_667(); break; case 668: -#line 4596 "cs-parser.jay" - { - yyVal = Variance.None; - } + case_668(); break; case 669: case_669(); @@ -3298,16 +3299,22 @@ case 671: case_671(); break; case 672: - case_672(); +#line 4643 "cs-parser.jay" + { + yyVal = new SpecialContraintExpr (SpecialConstraint.Class, GetLocation (yyVals[0+yyTop])); + } break; case 673: -#line 4641 "cs-parser.jay" +#line 4647 "cs-parser.jay" { - yyVal = yyVals[0+yyTop]; + yyVal = new SpecialContraintExpr (SpecialConstraint.Struct, GetLocation (yyVals[0+yyTop])); } break; case 674: - case_674(); +#line 4654 "cs-parser.jay" + { + yyVal = Variance.None; + } break; case 675: case_675(); @@ -3318,50 +3325,59 @@ case 676: case 677: case_677(); break; -case 682: -#line 4685 "cs-parser.jay" - { - current_block.AddStatement ((Statement) yyVals[0+yyTop]); - } +case 678: + case_678(); break; -case 683: -#line 4689 "cs-parser.jay" +case 679: +#line 4699 "cs-parser.jay" { - current_block.AddStatement ((Statement) yyVals[0+yyTop]); + yyVal = yyVals[0+yyTop]; } break; -case 685: - case_685(); +case 680: + case_680(); + break; +case 681: + case_681(); + break; +case 682: + case_682(); + break; +case 683: + case_683(); break; -case 686: - case_686(); +case 684: + case_684(); break; case 689: -#line 4723 "cs-parser.jay" +#line 4748 "cs-parser.jay" { current_block.AddStatement ((Statement) yyVals[0+yyTop]); } break; case 690: -#line 4727 "cs-parser.jay" +#line 4752 "cs-parser.jay" { current_block.AddStatement ((Statement) yyVals[0+yyTop]); } break; -case 719: - case_719(); - break; -case 720: - case_720(); +case 692: + case_692(); break; -case 721: - case_721(); +case 693: + case_693(); break; -case 722: - case_722(); +case 696: +#line 4786 "cs-parser.jay" + { + current_block.AddStatement ((Statement) yyVals[0+yyTop]); + } break; -case 723: - case_723(); +case 697: +#line 4790 "cs-parser.jay" + { + current_block.AddStatement ((Statement) yyVals[0+yyTop]); + } break; case 726: case_726(); @@ -3376,46 +3392,43 @@ case 729: case_729(); break; case 730: -#line 4871 "cs-parser.jay" - { - yyVal = new ComposedCast ((FullNamedExpression) yyVals[-1+yyTop], (ComposedTypeSpecifier) yyVals[0+yyTop]); - } - break; -case 731: -#line 4875 "cs-parser.jay" - { - yyVal = new ComposedCast (new TypeExpression (compiler.BuiltinTypes.Void, GetLocation (yyVals[-1+yyTop])), (ComposedTypeSpecifier) yyVals[0+yyTop]); - } + case_730(); break; -case 732: - case_732(); +case 733: + case_733(); break; case 734: case_734(); break; case 735: -#line 4896 "cs-parser.jay" - { - yyVal = ComposedTypeSpecifier.CreatePointer (GetLocation (yyVals[0+yyTop])); - } + case_735(); + break; +case 736: + case_736(); break; case 737: - case_737(); +#line 4934 "cs-parser.jay" + { + yyVal = new ComposedCast ((FullNamedExpression) yyVals[-1+yyTop], (ComposedTypeSpecifier) yyVals[0+yyTop]); + } break; case 738: - case_738(); +#line 4938 "cs-parser.jay" + { + yyVal = new ComposedCast (new TypeExpression (compiler.BuiltinTypes.Void, GetLocation (yyVals[-1+yyTop])), (ComposedTypeSpecifier) yyVals[0+yyTop]); + } break; case 739: case_739(); break; -case 740: - case_740(); - break; case 741: case_741(); break; -case 743: - case_743(); +case 742: +#line 4959 "cs-parser.jay" + { + yyVal = ComposedTypeSpecifier.CreatePointer (GetLocation (yyVals[0+yyTop])); + } break; case 744: case_744(); @@ -3423,8 +3436,17 @@ case 744: case 745: case_745(); break; -case 749: - case_749(); +case 746: + case_746(); + break; +case 747: + case_747(); + break; +case 748: + case_748(); + break; +case 750: + case_750(); break; case 752: case_752(); @@ -3433,64 +3455,52 @@ case 753: case_753(); break; case 754: -#line 5021 "cs-parser.jay" - { - report.Error (145, lexer.Location, "A const field requires a value to be provided"); - } + case_754(); break; -case 755: - case_755(); +case 758: + case_758(); break; -case 760: - case_760(); +case 761: + case_761(); break; case 762: case_762(); break; case 763: - case_763(); +#line 5094 "cs-parser.jay" + { + report.Error (145, lexer.Location, "A const field requires a value to be provided"); + } break; case 764: case_764(); break; -case 765: -#line 5071 "cs-parser.jay" - { yyVal = yyVals[-1+yyTop]; } - break; -case 766: -#line 5075 "cs-parser.jay" - { yyVal = yyVals[-1+yyTop]; } - break; -case 767: -#line 5076 "cs-parser.jay" - { yyVal = yyVals[-1+yyTop]; } - break; -case 768: - case_768(); - break; case 769: case_769(); break; -case 770: - case_770(); +case 771: + case_771(); + break; +case 772: + case_772(); break; case 773: case_773(); break; case 774: - case_774(); +#line 5144 "cs-parser.jay" + { yyVal = yyVals[-1+yyTop]; } break; case 775: case_775(); break; case 776: -#line 5151 "cs-parser.jay" - { - start_block (GetLocation (yyVals[0+yyTop])); - } +#line 5154 "cs-parser.jay" + { yyVal = yyVals[-1+yyTop]; } break; case 777: - case_777(); +#line 5155 "cs-parser.jay" + { yyVal = yyVals[-1+yyTop]; } break; case 778: case_778(); @@ -3498,29 +3508,23 @@ case 778: case 779: case_779(); break; -case 781: - case_781(); - break; -case 782: - case_782(); +case 780: + case_780(); break; case 783: case_783(); break; case 784: -#line 5202 "cs-parser.jay" - { - current_block = current_block.CreateSwitchBlock (lexer.Location); - } + case_784(); break; case 785: -#line 5206 "cs-parser.jay" - { - yyVal = new SwitchSection ((List) yyVals[-2+yyTop], current_block); - } + case_785(); break; case 786: - case_786(); +#line 5230 "cs-parser.jay" + { + start_block (GetLocation (yyVals[0+yyTop])); + } break; case 787: case_787(); @@ -3529,16 +3533,28 @@ case 788: case_788(); break; case 789: -#line 5235 "cs-parser.jay" - { - yyVal = new SwitchLabel (null, GetLocation (yyVals[0+yyTop])); - } + case_789(); + break; +case 791: + case_791(); + break; +case 792: + case_792(); + break; +case 793: + case_793(); break; case 794: - case_794(); +#line 5281 "cs-parser.jay" + { + current_block = current_block.CreateSwitchBlock (lexer.Location); + } break; case 795: - case_795(); +#line 5285 "cs-parser.jay" + { + yyVal = new SwitchSection ((List) yyVals[-2+yyTop], current_block); + } break; case 796: case_796(); @@ -3553,38 +3569,19 @@ case 799: case_799(); break; case 800: -#line 5295 "cs-parser.jay" +#line 5319 "cs-parser.jay" { - yyVal = yyVals[0+yyTop]; - } - break; -case 801: -#line 5303 "cs-parser.jay" - { - ((For) yyVals[-2+yyTop]).Initializer = (Statement) yyVals[-1+yyTop]; - } - break; -case 802: -#line 5307 "cs-parser.jay" - { - ((For) yyVals[-5+yyTop]).Condition = (BooleanExpression) yyVals[-1+yyTop]; - } - break; -case 803: -#line 5311 "cs-parser.jay" - { - ((For) yyVals[-8+yyTop]).Iterator = (Statement) yyVals[-1+yyTop]; + yyVal = new SwitchLabel (null, GetLocation (yyVals[0+yyTop])); } break; -case 804: - case_804(); - break; case 805: case_805(); break; case 806: -#line 5331 "cs-parser.jay" - { yyVal = new EmptyStatement (lexer.Location); } + case_806(); + break; +case 807: + case_807(); break; case 808: case_808(); @@ -3592,13 +3589,35 @@ case 808: case 809: case_809(); break; +case 810: + case_810(); + break; case 811: -#line 5352 "cs-parser.jay" - { yyVal = null; } +#line 5380 "cs-parser.jay" + { + yyVal = yyVals[0+yyTop]; + } + break; +case 812: + case_812(); break; case 813: -#line 5357 "cs-parser.jay" - { yyVal = new EmptyStatement (lexer.Location); } +#line 5395 "cs-parser.jay" + { + yyVal = yyVals[0+yyTop]; + } + break; +case 814: + case_814(); + break; +case 815: + case_815(); + break; +case 816: +#line 5416 "cs-parser.jay" + { + yyVal = yyVals[0+yyTop]; + } break; case 817: case_817(); @@ -3610,10 +3629,8 @@ case 819: case_819(); break; case 820: - case_820(); - break; -case 821: - case_821(); +#line 5449 "cs-parser.jay" + { yyVal = new EmptyStatement (lexer.Location); } break; case 822: case_822(); @@ -3621,8 +3638,13 @@ case 822: case 823: case_823(); break; -case 830: - case_830(); +case 825: +#line 5470 "cs-parser.jay" + { yyVal = null; } + break; +case 827: +#line 5475 "cs-parser.jay" + { yyVal = new EmptyStatement (lexer.Location); } break; case 831: case_831(); @@ -3645,21 +3667,6 @@ case 836: case 837: case_837(); break; -case 838: - case_838(); - break; -case 841: -#line 5558 "cs-parser.jay" - { - yyVal = new TryCatch ((Block) yyVals[-1+yyTop], (List) yyVals[0+yyTop], GetLocation (yyVals[-2+yyTop]), false); - } - break; -case 842: - case_842(); - break; -case 843: - case_843(); - break; case 844: case_844(); break; @@ -3669,51 +3676,39 @@ case 845: case 846: case_846(); break; +case 847: + case_847(); + break; +case 848: + case_848(); + break; case 849: -#line 5607 "cs-parser.jay" - { - yyVal = new Catch ((Block) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); - } + case_849(); break; case 850: case_850(); break; case 851: -#line 5626 "cs-parser.jay" - { - yyVal = yyVals[-1+yyTop]; - } + case_851(); break; case 852: case_852(); break; case 853: -#line 5644 "cs-parser.jay" - { - yyVal = new Checked ((Block) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); - } + case_853(); break; case 854: -#line 5651 "cs-parser.jay" - { - yyVal = new Unchecked ((Block) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); - } + case_854(); break; case 855: case_855(); break; -case 856: -#line 5661 "cs-parser.jay" +case 858: +#line 5692 "cs-parser.jay" { - yyVal = new Unsafe ((Block) yyVals[0+yyTop], GetLocation (yyVals[-2+yyTop])); + yyVal = new TryCatch ((Block) yyVals[-1+yyTop], (List) yyVals[0+yyTop], GetLocation (yyVals[-2+yyTop]), false); } break; -case 857: - case_857(); - break; -case 858: - case_858(); - break; case 859: case_859(); break; @@ -3729,35 +3724,44 @@ case 862: case 863: case_863(); break; -case 864: - case_864(); - break; -case 865: - case_865(); - break; case 866: - case_866(); +#line 5742 "cs-parser.jay" + { + yyVal = new Catch ((Block) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); + } break; -case 868: - case_868(); +case 867: + case_867(); break; -case 869: -#line 5766 "cs-parser.jay" +case 868: +#line 5761 "cs-parser.jay" { - Error_MissingInitializer (lexer.Location); + yyVal = yyVals[-1+yyTop]; } break; +case 869: + case_869(); + break; case 870: - case_870(); +#line 5779 "cs-parser.jay" + { + yyVal = new Checked ((Block) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); + } break; case 871: - case_871(); +#line 5786 "cs-parser.jay" + { + yyVal = new Unchecked ((Block) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); + } break; case 872: case_872(); break; case 873: - case_873(); +#line 5796 "cs-parser.jay" + { + yyVal = new Unsafe ((Block) yyVals[0+yyTop], GetLocation (yyVals[-2+yyTop])); + } break; case 874: case_874(); @@ -3775,19 +3779,13 @@ case 878: case_878(); break; case 879: -#line 5867 "cs-parser.jay" - { - current_block = new Linq.QueryBlock (current_block, lexer.Location); - } + case_879(); break; case 880: case_880(); break; case 881: -#line 5882 "cs-parser.jay" - { - current_block = new Linq.QueryBlock (current_block, lexer.Location); - } + case_881(); break; case 882: case_882(); @@ -3799,9 +3797,9 @@ case 885: case_885(); break; case 886: -#line 5927 "cs-parser.jay" +#line 5901 "cs-parser.jay" { - current_block = new Linq.QueryBlock (current_block, lexer.Location); + Error_MissingInitializer (lexer.Location); } break; case 887: @@ -3816,24 +3814,45 @@ case 889: case 890: case_890(); break; +case 891: + case_891(); + break; +case 892: + case_892(); + break; +case 893: + case_893(); + break; case 894: case_894(); break; -case 900: -#line 5986 "cs-parser.jay" +case 895: + case_895(); + break; +case 896: +#line 6006 "cs-parser.jay" { - current_block = new Linq.QueryBlock (current_block, lexer.Location); + current_block = new Linq.QueryBlock (current_block, lexer.Location); } break; -case 901: - case_901(); +case 897: + case_897(); break; -case 902: -#line 6005 "cs-parser.jay" +case 898: +#line 6022 "cs-parser.jay" { - current_block = new Linq.QueryBlock (current_block, lexer.Location); + current_block = new Linq.QueryBlock (current_block, lexer.Location); } break; +case 899: + case_899(); + break; +case 900: + case_900(); + break; +case 901: + case_901(); + break; case 903: case_903(); break; @@ -3841,7 +3860,10 @@ case 904: case_904(); break; case 905: - case_905(); +#line 6086 "cs-parser.jay" + { + current_block = new Linq.QueryBlock (current_block, lexer.Location); + } break; case 906: case_906(); @@ -3855,33 +3877,24 @@ case 908: case 909: case_909(); break; -case 910: - case_910(); - break; case 911: case_911(); break; -case 913: -#line 6149 "cs-parser.jay" - { - yyVal = yyVals[0+yyTop]; - } - break; -case 914: -#line 6156 "cs-parser.jay" +case 917: +#line 6140 "cs-parser.jay" { - current_block = new Linq.QueryBlock (current_block, lexer.Location); + current_block = new Linq.QueryBlock (current_block, lexer.Location); } break; -case 915: - case_915(); - break; -case 917: - case_917(); - break; case 918: case_918(); break; +case 919: +#line 6159 "cs-parser.jay" + { + current_block = new Linq.QueryBlock (current_block, lexer.Location); + } + break; case 920: case_920(); break; @@ -3889,10 +3902,7 @@ case 921: case_921(); break; case 922: -#line 6202 "cs-parser.jay" - { - yyVal = new Linq.OrderByAscending ((Linq.QueryBlock) current_block, (Expression)yyVals[0+yyTop]); - } + case_922(); break; case 923: case_923(); @@ -3901,10 +3911,7 @@ case 924: case_924(); break; case 925: -#line 6219 "cs-parser.jay" - { - yyVal = new Linq.ThenByAscending ((Linq.QueryBlock) current_block, (Expression)yyVals[0+yyTop]); - } + case_925(); break; case 926: case_926(); @@ -3912,92 +3919,143 @@ case 926: case 927: case_927(); break; -case 929: - case_929(); +case 928: + case_928(); break; case 930: case_930(); break; -case 933: - case_933(); +case 931: +#line 6313 "cs-parser.jay" + { + current_block = new Linq.QueryBlock (current_block, lexer.Location); + } + break; +case 932: + case_932(); break; case 934: case_934(); break; +case 935: + case_935(); + break; +case 937: + case_937(); + break; +case 938: + case_938(); + break; +case 939: +#line 6359 "cs-parser.jay" + { + yyVal = new Linq.OrderByAscending ((Linq.QueryBlock) current_block, (Expression)yyVals[0+yyTop]); + } + break; +case 940: + case_940(); + break; +case 941: + case_941(); + break; case 942: -#line 6342 "cs-parser.jay" +#line 6376 "cs-parser.jay" { - module.DocumentationBuilder.ParsedName = (MemberName) yyVals[0+yyTop]; + yyVal = new Linq.ThenByAscending ((Linq.QueryBlock) current_block, (Expression)yyVals[0+yyTop]); } break; case 943: -#line 6349 "cs-parser.jay" + case_943(); + break; +case 944: + case_944(); + break; +case 946: + case_946(); + break; +case 947: + case_947(); + break; +case 950: + case_950(); + break; +case 951: + case_951(); + break; +case 959: +#line 6498 "cs-parser.jay" + { + module.DocumentationBuilder.ParsedName = (MemberName) yyVals[0+yyTop]; + } + break; +case 960: +#line 6505 "cs-parser.jay" { module.DocumentationBuilder.ParsedParameters = (List)yyVals[0+yyTop]; } break; -case 944: - case_944(); +case 961: + case_961(); break; -case 945: - case_945(); +case 962: + case_962(); break; -case 946: -#line 6366 "cs-parser.jay" +case 963: +#line 6522 "cs-parser.jay" { yyVal = new MemberName ((MemberName) yyVals[-2+yyTop], MemberCache.IndexerNameAlias, Location.Null); } break; -case 947: -#line 6370 "cs-parser.jay" +case 964: +#line 6526 "cs-parser.jay" { valid_param_mod = ParameterModifierType.Ref | ParameterModifierType.Out; } break; -case 948: - case_948(); +case 965: + case_965(); break; -case 949: - case_949(); +case 966: + case_966(); break; -case 950: - case_950(); +case 967: + case_967(); break; -case 951: - case_951(); +case 968: + case_968(); break; -case 953: -#line 6406 "cs-parser.jay" +case 970: +#line 6562 "cs-parser.jay" { yyVal = new MemberName (((MemberName) yyVals[-2+yyTop]), (MemberName) yyVals[0+yyTop]); } break; -case 955: -#line 6414 "cs-parser.jay" +case 972: +#line 6570 "cs-parser.jay" { valid_param_mod = ParameterModifierType.Ref | ParameterModifierType.Out; } break; -case 956: -#line 6418 "cs-parser.jay" +case 973: +#line 6574 "cs-parser.jay" { yyVal = yyVals[-1+yyTop]; } break; -case 957: -#line 6425 "cs-parser.jay" +case 974: +#line 6581 "cs-parser.jay" { yyVal = new List (0); } break; -case 959: - case_959(); +case 976: + case_976(); break; -case 960: - case_960(); +case 977: + case_977(); break; -case 961: - case_961(); +case 978: + case_978(); break; #line default } @@ -4035,17 +4093,19 @@ case 961: All more than 3 lines long rules are wrapped into a method */ void case_6() -#line 396 "cs-parser.jay" +#line 398 "cs-parser.jay" { if (yyVals[0+yyTop] != null) { Attributes attrs = (Attributes) yyVals[0+yyTop]; report.Error (1730, attrs.Attrs [0].Location, "Assembly and module attributes must precede all other elements except using clauses and extern alias declarations"); + + current_namespace.UnattachedAttributes = attrs; } } void case_8() -#line 408 "cs-parser.jay" +#line 412 "cs-parser.jay" { if (yyToken == Token.EXTERN_ALIAS) report.Error (439, lexer.Location, "An extern alias declaration must precede all other elements"); @@ -4054,7 +4114,7 @@ void case_8() } void case_13() -#line 428 "cs-parser.jay" +#line 432 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; string s = lt.Value; @@ -4077,24 +4137,23 @@ void case_13() } void case_17() -#line 461 "cs-parser.jay" +#line 465 "cs-parser.jay" { if (doc_support) Lexer.doc_state = XmlCommentState.Allowed; } void case_18() -#line 469 "cs-parser.jay" +#line 473 "cs-parser.jay" { var un = new UsingNamespace ((ATypeNameExpression) yyVals[-1+yyTop], GetLocation (yyVals[-2+yyTop])); current_namespace.AddUsing (un); - ubag.AddUsing (GetLocation (yyVals[-2+yyTop]), (ATypeNameExpression) yyVals[-1+yyTop], GetLocation (yyVals[0+yyTop])); lbag.AddLocation (un, GetLocation (yyVals[0+yyTop])); } void case_19() -#line 477 "cs-parser.jay" +#line 480 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-3+yyTop]; if (lang_version != LanguageVersion.ISO_1 && lt.Value == "global") { @@ -4104,26 +4163,24 @@ void case_19() var un = new UsingAliasNamespace (new SimpleMemberName (lt.Value, lt.Location), (ATypeNameExpression) yyVals[-1+yyTop], GetLocation (yyVals[-4+yyTop])); current_namespace.AddUsing (un); - ubag.AddUsingAlias (GetLocation (yyVals[-4+yyTop]), lt, GetLocation (yyVals[-2+yyTop]), (ATypeNameExpression) yyVals[-1+yyTop], GetLocation (yyVals[0+yyTop])); - lbag.AddLocation (un, GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); } void case_20() -#line 491 "cs-parser.jay" +#line 492 "cs-parser.jay" { Error_SyntaxError (yyToken); yyVal = null; } void case_21() -#line 504 "cs-parser.jay" +#line 505 "cs-parser.jay" { Attributes attrs = (Attributes) yyVals[-2+yyTop]; var name = (MemberName) yyVals[0+yyTop]; if (attrs != null) { bool valid_global_attrs = true; - if ((current_namespace.DeclarationFound || current_namespace != file.NamespaceContainer)) { + if ((current_namespace.DeclarationFound || current_namespace != file)) { valid_global_attrs = false; } else { foreach (var a in attrs.Attrs) { @@ -4141,44 +4198,38 @@ void case_21() module.AddAttributes (attrs, current_namespace); - current_namespace = new NamespaceContainer (name, module, current_namespace, file); - module.AddTypesContainer (current_namespace); - current_class = current_namespace.SlaveDeclSpace; - current_container = current_class.PartialContainer; - - ubag.DeclareNamespace (GetLocation (yyVals[-1+yyTop]), name); + var ns = new NamespaceContainer (name, current_namespace); + current_namespace.AddTypeContainer (ns); + current_container = current_namespace = ns; } void case_22() -#line 535 "cs-parser.jay" +#line 533 "cs-parser.jay" { if (doc_support) Lexer.doc_state = XmlCommentState.Allowed; - ubag.OpenNamespace (GetLocation (yyVals[0+yyTop])); } void case_23() -#line 541 "cs-parser.jay" +#line 538 "cs-parser.jay" { - current_namespace = current_namespace.Parent; - current_class = current_namespace.SlaveDeclSpace; - current_container = current_class.PartialContainer; - ubag.CloseNamespace (GetLocation (yyVals[-1+yyTop])); if (yyVals[0+yyTop] != null) - ubag.EndNamespace (GetLocation (yyVals[0+yyTop])); + lbag.AddLocation (current_container, GetLocation (yyVals[-9+yyTop]), GetLocation (yyVals[-6+yyTop]), GetLocation (yyVals[-1+yyTop]), GetLocation (yyVals[0+yyTop])); else - ubag.EndNamespace (); + lbag.AddLocation (current_container, GetLocation (yyVals[-9+yyTop]), GetLocation (yyVals[-6+yyTop]), GetLocation (yyVals[-1+yyTop])); + + current_container = current_namespace = current_namespace.Parent; } void case_24() -#line 555 "cs-parser.jay" +#line 550 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; yyVal = new MemberName (lt.Value, lt.Location); } void case_25() -#line 560 "cs-parser.jay" +#line 555 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; yyVal = new MemberName ((MemberName) yyVals[-2+yyTop], lt.Value, lt.Location) { @@ -4187,14 +4238,14 @@ void case_25() } void case_26() -#line 567 "cs-parser.jay" +#line 562 "cs-parser.jay" { Error_SyntaxError (yyToken); yyVal = new MemberName ("", lexer.Location); } void case_39() -#line 605 "cs-parser.jay" +#line 600 "cs-parser.jay" { if (yyVals[0+yyTop] != null) { TypeContainer ds = (TypeContainer)yyVals[0+yyTop]; @@ -4208,13 +4259,21 @@ void case_39() /* we parse succeeding declaration hence we parse them as normal and re-attach them*/ /* when we know whether they are global (assembly:, module:) or local (type:).*/ if (ds.OptAttributes != null) { - ds.OptAttributes.ConvertGlobalAttributes (ds, current_namespace, !current_namespace.DeclarationFound && current_namespace == file.NamespaceContainer); + ds.OptAttributes.ConvertGlobalAttributes (ds, current_namespace, !current_namespace.DeclarationFound && current_namespace == file); } } current_namespace.DeclarationFound = true; } -void case_48() +void case_41() +#line 622 "cs-parser.jay" +{ + current_namespace.UnattachedAttributes = (Attributes) yyVals[-1+yyTop]; + report.Error (1518, lexer.Location, "Attributes must be attached to class, delegate, enum, interface or struct"); + lexer.putback ('}'); + } + +void case_49() #line 655 "cs-parser.jay" { var sect = (List) yyVals[0+yyTop]; @@ -4227,7 +4286,7 @@ void case_48() } } -void case_49() +void case_50() #line 666 "cs-parser.jay" { Attributes attrs = yyVals[-1+yyTop] as Attributes; @@ -4242,21 +4301,21 @@ void case_49() yyVal = attrs; } -void case_50() +void case_51() #line 682 "cs-parser.jay" { lexer.parsing_attribute_section = true; savedOpenLocation = GetLocation (yyVals[0+yyTop]); } -void case_51() +void case_52() #line 687 "cs-parser.jay" { lexer.parsing_attribute_section = false; yyVal = yyVals[0+yyTop]; } -void case_52() +void case_53() #line 695 "cs-parser.jay" { current_attr_target = (string) yyVals[-1+yyTop]; @@ -4265,7 +4324,7 @@ void case_52() } } -void case_53() +void case_54() #line 702 "cs-parser.jay" { /* when attribute target is invalid*/ @@ -4283,7 +4342,7 @@ void case_53() } } -void case_54() +void case_55() #line 718 "cs-parser.jay" { yyVal = yyVals[-2+yyTop]; @@ -4294,7 +4353,7 @@ void case_54() } } -void case_55() +void case_56() #line 730 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; @@ -4302,7 +4361,7 @@ void case_55() savedCloseLocation = GetLocation (yyVals[0+yyTop]); } -void case_58() +void case_59() #line 738 "cs-parser.jay" { if (yyToken == Token.IDENTIFIER) { @@ -4314,7 +4373,7 @@ void case_58() } } -void case_60() +void case_61() #line 755 "cs-parser.jay" { var attrs = (List) yyVals[-2+yyTop]; @@ -4324,7 +4383,7 @@ void case_60() yyVal = attrs; } -void case_62() +void case_63() #line 770 "cs-parser.jay" { --lexer.parsing_block; @@ -4341,35 +4400,38 @@ void case_62() attributeArgumentCommas.Add (savedAttrParenCloseLocation); lbag.AddLocation (yyVal, attributeArgumentCommas); attributeArgumentCommas.Clear (); + } else if (HadAttributeParens) { + lbag.AddLocation (yyVal, savedAttrParenOpenLocation, savedAttrParenCloseLocation); } } -void case_65() -#line 796 "cs-parser.jay" +void case_66() +#line 798 "cs-parser.jay" { savedAttrParenOpenLocation = GetLocation (yyVals[-2+yyTop]); savedAttrParenCloseLocation = GetLocation (yyVals[0+yyTop]); yyVal = yyVals[-1+yyTop]; + HadAttributeParens = true; } -void case_67() -#line 807 "cs-parser.jay" +void case_68() +#line 810 "cs-parser.jay" { Arguments a = new Arguments (4); a.Add ((Argument) yyVals[0+yyTop]); yyVal = new Arguments [] { a, null }; } -void case_68() -#line 813 "cs-parser.jay" +void case_69() +#line 816 "cs-parser.jay" { Arguments a = new Arguments (4); a.Add ((Argument) yyVals[0+yyTop]); yyVal = new Arguments [] { null, a }; } -void case_69() -#line 819 "cs-parser.jay" +void case_70() +#line 822 "cs-parser.jay" { Arguments[] o = (Arguments[]) yyVals[-2+yyTop]; if (o [1] != null) { @@ -4385,8 +4447,8 @@ void case_69() attributeArgumentCommas.Add (GetLocation (yyVals[-1+yyTop])); } -void case_70() -#line 834 "cs-parser.jay" +void case_71() +#line 837 "cs-parser.jay" { Arguments[] o = (Arguments[]) yyVals[-2+yyTop]; if (o [1] == null) { @@ -4397,8 +4459,8 @@ void case_70() attributeArgumentCommas.Add (GetLocation (yyVals[-1+yyTop])); } -void case_74() -#line 859 "cs-parser.jay" +void case_75() +#line 862 "cs-parser.jay" { --lexer.parsing_block; var lt = (Tokenizer.LocatedToken) yyVals[-3+yyTop]; @@ -4406,8 +4468,8 @@ void case_74() lbag.AddLocation (yyVal, GetLocation(yyVals[-2+yyTop])); } -void case_75() -#line 869 "cs-parser.jay" +void case_76() +#line 872 "cs-parser.jay" { if (lang_version <= LanguageVersion.V_3) FeatureIsNotAvailable (GetLocation (yyVals[-3+yyTop]), "named argument"); @@ -4420,8 +4482,8 @@ void case_75() lbag.AddLocation (yyVal, GetLocation(yyVals[-2+yyTop])); } -void case_93() -#line 922 "cs-parser.jay" +void case_95() +#line 926 "cs-parser.jay" { report.Error (1519, lexer.Location, "Unexpected symbol `{0}' in class, struct, or interface member declaration", GetSymbolName (yyToken)); @@ -4429,60 +4491,61 @@ void case_93() lexer.parsing_generic_declaration = false; } -void case_95() -#line 939 "cs-parser.jay" +void case_97() +#line 943 "cs-parser.jay" { - MemberName name = MakeName ((MemberName) yyVals[0+yyTop]); - push_current_class (new Struct (current_namespace, current_class, name, (Modifiers) yyVals[-4+yyTop], (Attributes) yyVals[-5+yyTop]), yyVals[-3+yyTop]); - lbag.AddMember (current_class, GetModifierLocations (), GetLocation (yyVals[-2+yyTop])); + push_current_container (new Struct (current_container, (MemberName) yyVals[0+yyTop], (Modifiers) yyVals[-4+yyTop], (Attributes) yyVals[-5+yyTop]), yyVals[-3+yyTop]); + lbag.AddMember (current_container, GetModifierLocations (), GetLocation (yyVals[-2+yyTop])); } -void case_96() -#line 946 "cs-parser.jay" +void case_98() +#line 949 "cs-parser.jay" { lexer.ConstraintsParsing = false; if (yyVals[0+yyTop] != null) - current_class.SetConstraints ((List) yyVals[0+yyTop]); + current_container.SetConstraints ((List) yyVals[0+yyTop]); if (doc_support) - current_container.DocComment = Lexer.consume_doc_comment (); + current_container.PartialContainer.DocComment = Lexer.consume_doc_comment (); lexer.parsing_modifiers = true; } -void case_97() -#line 959 "cs-parser.jay" +void case_99() +#line 962 "cs-parser.jay" { if (doc_support) Lexer.doc_state = XmlCommentState.Allowed; } -void case_98() -#line 964 "cs-parser.jay" +void case_100() +#line 967 "cs-parser.jay" { - lbag.AppendToMember (current_class, GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[-1+yyTop])); --lexer.parsing_declaration; if (doc_support) Lexer.doc_state = XmlCommentState.Allowed; } -void case_99() -#line 971 "cs-parser.jay" +void case_101() +#line 973 "cs-parser.jay" { - if (yyVals[-1+yyTop] != null) - current_class.OptionalSemicolon = GetLocation (yyVals[-1+yyTop]); + if (yyVals[0+yyTop] == null) { + lbag.AppendToMember (current_container, GetLocation (yyVals[-5+yyTop]), GetLocation (yyVals[-2+yyTop])); + } else { + lbag.AppendToMember (current_container, GetLocation (yyVals[-5+yyTop]), GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); + } yyVal = pop_current_class (); } -void case_101() -#line 986 "cs-parser.jay" +void case_103() +#line 991 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; var mod = (Modifiers) yyVals[-3+yyTop]; - current_field = new Const (current_class, (FullNamedExpression) yyVals[-1+yyTop], mod, new MemberName (lt.Value, lt.Location), (Attributes) yyVals[-4+yyTop]); - current_container.AddConstant ((Const) current_field); + current_field = new Const (current_type, (FullNamedExpression) yyVals[-1+yyTop], mod, new MemberName (lt.Value, lt.Location), (Attributes) yyVals[-4+yyTop]); + current_type.AddMember (current_field); if ((mod & Modifiers.STATIC) != 0) { report.Error (504, current_field.Location, "The constant `{0}' cannot be marked static", current_field.GetSignatureForError ()); @@ -4491,8 +4554,8 @@ void case_101() yyVal = current_field; } -void case_102() -#line 999 "cs-parser.jay" +void case_104() +#line 1004 "cs-parser.jay" { if (doc_support) { current_field.DocComment = Lexer.consume_doc_comment (); @@ -4504,31 +4567,31 @@ void case_102() current_field = null; } -void case_107() -#line 1029 "cs-parser.jay" +void case_109() +#line 1034 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; yyVal = new FieldDeclarator (new SimpleMemberName (lt.Value, lt.Location), (ConstInitializer) yyVals[0+yyTop]); lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop])); } -void case_109() -#line 1042 "cs-parser.jay" +void case_111() +#line 1047 "cs-parser.jay" { --lexer.parsing_block; yyVal = new ConstInitializer (current_field, (Expression) yyVals[0+yyTop], GetLocation (yyVals[-2+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop])); } -void case_110() -#line 1048 "cs-parser.jay" +void case_112() +#line 1053 "cs-parser.jay" { report.Error (145, lexer.Location, "A const field requires a value to be provided"); yyVal = null; } -void case_113() -#line 1063 "cs-parser.jay" +void case_115() +#line 1068 "cs-parser.jay" { lexer.parsing_generic_declaration = false; @@ -4537,13 +4600,13 @@ void case_113() report.Error (670, GetLocation (yyVals[-1+yyTop]), "Fields cannot have void type"); var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; - current_field = new Field (current_class, type, (Modifiers) yyVals[-2+yyTop], new MemberName (lt.Value, lt.Location), (Attributes) yyVals[-3+yyTop]); - current_container.AddField (current_field); + current_field = new Field (current_type, type, (Modifiers) yyVals[-2+yyTop], new MemberName (lt.Value, lt.Location), (Attributes) yyVals[-3+yyTop]); + current_type.AddField (current_field); yyVal = current_field; } -void case_114() -#line 1078 "cs-parser.jay" +void case_116() +#line 1083 "cs-parser.jay" { if (doc_support) { current_field.DocComment = Lexer.consume_doc_comment (); @@ -4555,21 +4618,21 @@ void case_114() current_field = null; } -void case_115() -#line 1091 "cs-parser.jay" +void case_117() +#line 1096 "cs-parser.jay" { if (lang_version < LanguageVersion.ISO_2) FeatureIsNotAvailable (GetLocation (yyVals[-2+yyTop]), "fixed size buffers"); var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; - current_field = new FixedField (current_class, (FullNamedExpression) yyVals[-1+yyTop], (Modifiers) yyVals[-3+yyTop], + current_field = new FixedField (current_type, (FullNamedExpression) yyVals[-1+yyTop], (Modifiers) yyVals[-3+yyTop], new MemberName (lt.Value, lt.Location), (Attributes) yyVals[-4+yyTop]); - current_container.AddField (current_field); + current_type.AddField (current_field); } -void case_116() -#line 1102 "cs-parser.jay" +void case_118() +#line 1107 "cs-parser.jay" { if (doc_support) { current_field.DocComment = Lexer.consume_doc_comment (); @@ -4582,16 +4645,16 @@ void case_116() current_field = null; } -void case_119() -#line 1125 "cs-parser.jay" +void case_121() +#line 1130 "cs-parser.jay" { ++lexer.parsing_block; current_local_parameters = ParametersCompiled.EmptyReadOnlyParameters; start_block (GetLocation (yyVals[0+yyTop])); } -void case_120() -#line 1131 "cs-parser.jay" +void case_122() +#line 1136 "cs-parser.jay" { --lexer.parsing_block; current_field.Initializer = (Expression) yyVals[0+yyTop]; @@ -4600,16 +4663,16 @@ void case_120() current_local_parameters = null; } -void case_125() -#line 1158 "cs-parser.jay" +void case_127() +#line 1163 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; yyVal = new FieldDeclarator (new SimpleMemberName (lt.Value, lt.Location), null); lbag.AddLocation (yyVal, GetLocation (yyVals[-1+yyTop])); } -void case_127() -#line 1168 "cs-parser.jay" +void case_129() +#line 1173 "cs-parser.jay" { --lexer.parsing_block; var lt = (Tokenizer.LocatedToken) yyVals[-3+yyTop]; @@ -4617,39 +4680,39 @@ void case_127() lbag.AddLocation (yyVal, GetLocation (yyVals[-4+yyTop]), GetLocation (yyVals[-2+yyTop])); } -void case_132() -#line 1194 "cs-parser.jay" +void case_134() +#line 1199 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; yyVal = new FieldDeclarator (new SimpleMemberName (lt.Value, lt.Location), (ConstInitializer) yyVals[0+yyTop]); lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop])); } -void case_134() -#line 1207 "cs-parser.jay" +void case_136() +#line 1212 "cs-parser.jay" { --lexer.parsing_block; yyVal = new ConstInitializer (current_field, (Expression) yyVals[-1+yyTop], GetLocation (yyVals[-3+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_135() -#line 1213 "cs-parser.jay" +void case_137() +#line 1218 "cs-parser.jay" { report.Error (443, lexer.Location, "Value or constant expected"); yyVal = null; } -void case_138() -#line 1223 "cs-parser.jay" +void case_140() +#line 1228 "cs-parser.jay" { /* It has to be here for the parent to safely restore artificial block*/ Error_SyntaxError (yyToken); yyVal = null; } -void case_139() -#line 1232 "cs-parser.jay" +void case_141() +#line 1237 "cs-parser.jay" { if (doc_support) Lexer.doc_state = XmlCommentState.NotAllowed; @@ -4657,11 +4720,11 @@ void case_139() /* Add it early in the case of body being eof for full ast*/ Method m = (Method) yyVals[0+yyTop]; async_block = (m.ModFlags & Modifiers.ASYNC) != 0; - current_container.AddMethod (m); + current_type.AddMember (m); } -void case_140() -#line 1242 "cs-parser.jay" +void case_142() +#line 1247 "cs-parser.jay" { Method method = (Method) yyVals[-2+yyTop]; method.Block = (ToplevelBlock) yyVals[0+yyTop]; @@ -4688,15 +4751,15 @@ void case_140() Lexer.doc_state = XmlCommentState.Allowed; } -void case_143() -#line 1282 "cs-parser.jay" +void case_145() +#line 1287 "cs-parser.jay" { lexer.ConstraintsParsing = false; valid_param_mod = 0; MemberName name = (MemberName) yyVals[-6+yyTop]; current_local_parameters = (ParametersCompiled) yyVals[-3+yyTop]; - var method = Method.Create (current_class, (FullNamedExpression) yyVals[-7+yyTop], (Modifiers) yyVals[-8+yyTop], + var method = Method.Create (current_type, (FullNamedExpression) yyVals[-7+yyTop], (Modifiers) yyVals[-8+yyTop], name, current_local_parameters, (Attributes) yyVals[-9+yyTop], yyVals[0+yyTop] != null); if (yyVals[0+yyTop] != null) @@ -4709,15 +4772,15 @@ void case_143() yyVal = method; } -void case_145() -#line 1309 "cs-parser.jay" +void case_147() +#line 1314 "cs-parser.jay" { lexer.parsing_generic_declaration = false; valid_param_mod = ParameterModifierType.All; } -void case_147() -#line 1318 "cs-parser.jay" +void case_149() +#line 1323 "cs-parser.jay" { lexer.ConstraintsParsing = false; valid_param_mod = 0; @@ -4728,7 +4791,7 @@ void case_147() var modifiers = (Modifiers) yyVals[-10+yyTop]; modifiers |= Modifiers.PARTIAL; - var method = Method.Create (current_class, new TypeExpression (compiler.BuiltinTypes.Void, GetLocation (yyVals[-8+yyTop])), + var method = Method.Create (current_type, new TypeExpression (compiler.BuiltinTypes.Void, GetLocation (yyVals[-8+yyTop])), modifiers, name, current_local_parameters, (Attributes) yyVals[-11+yyTop], yyVals[-1+yyTop] != null); if (yyVals[-1+yyTop] != null) @@ -4742,14 +4805,14 @@ void case_147() yyVal = method; } -void case_148() -#line 1345 "cs-parser.jay" +void case_150() +#line 1350 "cs-parser.jay" { MemberName name = (MemberName) yyVals[-3+yyTop]; report.Error (1585, name.Location, "Member modifier `{0}' must precede the member type and name", ModifiersExtensions.Name ((Modifiers) yyVals[-4+yyTop])); - var method = Method.Create (current_class, (FullNamedExpression) yyVals[-5+yyTop], + var method = Method.Create (current_type, (FullNamedExpression) yyVals[-5+yyTop], 0, name, (ParametersCompiled) yyVals[-1+yyTop], (Attributes) yyVals[-7+yyTop], false); current_local_parameters = (ParametersCompiled) yyVals[-1+yyTop]; @@ -4760,16 +4823,32 @@ void case_148() yyVal = method; } -void case_153() -#line 1374 "cs-parser.jay" +void case_151() +#line 1369 "cs-parser.jay" +{ + Error_SyntaxError (yyToken); + current_local_parameters = ParametersCompiled.Undefined; + + MemberName name = (MemberName) yyVals[-1+yyTop]; + var method = Method.Create (current_type, (FullNamedExpression) yyVals[-2+yyTop], (Modifiers) yyVals[-3+yyTop], + name, current_local_parameters, (Attributes) yyVals[-4+yyTop], false); + + if (doc_support) + method.DocComment = Lexer.consume_doc_comment (); + + yyVal = method; + } + +void case_156() +#line 1396 "cs-parser.jay" { var pars_list = (List) yyVals[0+yyTop]; yyVal = new ParametersCompiled (pars_list.ToArray ()); lbag.AddLocation (yyVal, parameterListCommas); } -void case_154() -#line 1380 "cs-parser.jay" +void case_157() +#line 1402 "cs-parser.jay" { var pars_list = (List) yyVals[-2+yyTop]; pars_list.Add ((Parameter) yyVals[0+yyTop]); @@ -4779,8 +4858,8 @@ void case_154() lbag.AddLocation (yyVal, parameterListCommas); } -void case_155() -#line 1389 "cs-parser.jay" +void case_158() +#line 1411 "cs-parser.jay" { var pars_list = (List) yyVals[-2+yyTop]; pars_list.Add (new ArglistParameter (GetLocation (yyVals[0+yyTop]))); @@ -4790,8 +4869,8 @@ void case_155() lbag.AddLocation (yyVal, parameterListCommas); } -void case_156() -#line 1398 "cs-parser.jay" +void case_159() +#line 1420 "cs-parser.jay" { if (yyVals[-2+yyTop] != null) report.Error (231, ((Parameter) yyVals[-2+yyTop]).Location, "A params parameter must be the last parameter in a formal parameter list"); @@ -4800,8 +4879,8 @@ void case_156() lbag.AddLocation (yyVal, parameterListCommas); } -void case_157() -#line 1406 "cs-parser.jay" +void case_160() +#line 1428 "cs-parser.jay" { if (yyVals[-2+yyTop] != null) report.Error (231, ((Parameter) yyVals[-2+yyTop]).Location, "A params parameter must be the last parameter in a formal parameter list"); @@ -4815,8 +4894,8 @@ void case_157() lbag.AddLocation (yyVal, parameterListCommas); } -void case_158() -#line 1419 "cs-parser.jay" +void case_161() +#line 1441 "cs-parser.jay" { report.Error (257, GetLocation (yyVals[-2+yyTop]), "An __arglist parameter must be the last parameter in a formal parameter list"); @@ -4824,8 +4903,8 @@ void case_158() lbag.AddLocation (yyVal, parameterListCommas); } -void case_159() -#line 1426 "cs-parser.jay" +void case_162() +#line 1448 "cs-parser.jay" { report.Error (257, GetLocation (yyVals[-2+yyTop]), "An __arglist parameter must be the last parameter in a formal parameter list"); @@ -4838,15 +4917,15 @@ void case_159() lbag.AddLocation (yyVal, parameterListCommas); } -void case_162() -#line 1446 "cs-parser.jay" +void case_165() +#line 1468 "cs-parser.jay" { Error_SyntaxError (yyToken); yyVal = ParametersCompiled.EmptyReadOnlyParameters; } -void case_163() -#line 1454 "cs-parser.jay" +void case_166() +#line 1476 "cs-parser.jay" { parameters_bucket.Clear (); Parameter p = (Parameter) yyVals[0+yyTop]; @@ -4856,8 +4935,8 @@ void case_163() yyVal = parameters_bucket; } -void case_164() -#line 1463 "cs-parser.jay" +void case_167() +#line 1485 "cs-parser.jay" { var pars = (List) yyVals[-2+yyTop]; Parameter p = (Parameter) yyVals[0+yyTop]; @@ -4876,16 +4955,16 @@ void case_164() yyVal = yyVals[-2+yyTop]; } -void case_165() -#line 1487 "cs-parser.jay" +void case_168() +#line 1509 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; yyVal = new Parameter ((FullNamedExpression) yyVals[-1+yyTop], lt.Value, (Parameter.Modifier) yyVals[-2+yyTop], (Attributes) yyVals[-3+yyTop], lt.Location); lbag.AddLocation (yyVal, parameterModifierLocation); } -void case_166() -#line 1496 "cs-parser.jay" +void case_169() +#line 1518 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; report.Error (1552, lt.Location, "Array type specifier, [], must appear before parameter name"); @@ -4893,17 +4972,25 @@ void case_166() lbag.AddLocation (yyVal, parameterModifierLocation); } -void case_167() -#line 1506 "cs-parser.jay" +void case_170() +#line 1525 "cs-parser.jay" { - Error_SyntaxError (yyToken); + Error_SyntaxError (yyToken); + Location l = GetLocation (yyVals[0+yyTop]); + yyVal = new Parameter (null, null, Parameter.Modifier.NONE, (Attributes) yyVals[-1+yyTop], l); + } + +void case_171() +#line 1534 "cs-parser.jay" +{ + Error_SyntaxError (yyToken); Location l = GetLocation (yyVals[0+yyTop]); yyVal = new Parameter ((FullNamedExpression) yyVals[-1+yyTop], null, (Parameter.Modifier) yyVals[-2+yyTop], (Attributes) yyVals[-3+yyTop], l); lbag.AddLocation (yyVal, parameterModifierLocation); } -void case_169() -#line 1521 "cs-parser.jay" +void case_173() +#line 1549 "cs-parser.jay" { --lexer.parsing_block; if (lang_version <= LanguageVersion.V_3) { @@ -4941,8 +5028,8 @@ void case_169() ((Parameter) yyVal).DefaultValue = new DefaultParameterValueExpression ((Expression) yyVals[0+yyTop]); } -void case_173() -#line 1570 "cs-parser.jay" +void case_177() +#line 1598 "cs-parser.jay" { Parameter.Modifier p2 = (Parameter.Modifier)yyVals[0+yyTop]; Parameter.Modifier mod = (Parameter.Modifier)yyVals[-1+yyTop] | p2; @@ -4964,8 +5051,8 @@ void case_173() yyVal = mod; } -void case_174() -#line 1594 "cs-parser.jay" +void case_178() +#line 1622 "cs-parser.jay" { if ((valid_param_mod & ParameterModifierType.Ref) == 0) Error_ParameterModifierNotValid ("ref", GetLocation (yyVals[0+yyTop])); @@ -4973,8 +5060,8 @@ void case_174() yyVal = Parameter.Modifier.REF; } -void case_175() -#line 1601 "cs-parser.jay" +void case_179() +#line 1629 "cs-parser.jay" { if ((valid_param_mod & ParameterModifierType.Out) == 0) Error_ParameterModifierNotValid ("out", GetLocation (yyVals[0+yyTop])); @@ -4982,8 +5069,8 @@ void case_175() yyVal = Parameter.Modifier.OUT; } -void case_176() -#line 1608 "cs-parser.jay" +void case_180() +#line 1636 "cs-parser.jay" { if ((valid_param_mod & ParameterModifierType.This) == 0) Error_ParameterModifierNotValid ("this", GetLocation (yyVals[0+yyTop])); @@ -4994,16 +5081,16 @@ void case_176() yyVal = Parameter.Modifier.This; } -void case_177() -#line 1621 "cs-parser.jay" +void case_181() +#line 1649 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; yyVal = new ParamsParameter ((FullNamedExpression) yyVals[-1+yyTop], lt.Value, (Attributes) yyVals[-3+yyTop], lt.Location); lbag.AddLocation (yyVal, savedLocation); } -void case_178() -#line 1627 "cs-parser.jay" +void case_182() +#line 1655 "cs-parser.jay" { report.Error (1751, GetLocation (yyVals[-4+yyTop]), "Cannot specify a default value for a parameter array"); @@ -5012,23 +5099,23 @@ void case_178() lbag.AddLocation (yyVal, savedLocation); } -void case_179() -#line 1635 "cs-parser.jay" +void case_183() +#line 1663 "cs-parser.jay" { Error_SyntaxError (yyToken); yyVal = null; } -void case_180() -#line 1643 "cs-parser.jay" +void case_184() +#line 1671 "cs-parser.jay" { if ((valid_param_mod & ParameterModifierType.Params) == 0) report.Error (1670, (GetLocation (yyVals[0+yyTop])), "The `params' modifier is not allowed in current context"); savedLocation = GetLocation (yyVals[0+yyTop]); } -void case_181() -#line 1649 "cs-parser.jay" +void case_185() +#line 1677 "cs-parser.jay" { Parameter.Modifier mod = (Parameter.Modifier)yyVals[0+yyTop]; if ((mod & Parameter.Modifier.This) != 0) { @@ -5039,38 +5126,38 @@ void case_181() savedLocation = GetLocation (yyVals[-1+yyTop]); } -void case_183() -#line 1666 "cs-parser.jay" +void case_187() +#line 1694 "cs-parser.jay" { if ((valid_param_mod & ParameterModifierType.Arglist) == 0) report.Error (1669, GetLocation (yyVals[0+yyTop]), "__arglist is not valid in this context"); } -void case_184() -#line 1677 "cs-parser.jay" +void case_188() +#line 1705 "cs-parser.jay" { if (doc_support) tmpComment = Lexer.consume_doc_comment (); } -void case_185() -#line 1682 "cs-parser.jay" +void case_189() +#line 1710 "cs-parser.jay" { var type = (FullNamedExpression) yyVals[-3+yyTop]; - current_property = new Property (current_class, type, (Modifiers) yyVals[-4+yyTop], + current_property = new Property (current_type, type, (Modifiers) yyVals[-4+yyTop], (MemberName) yyVals[-2+yyTop], (Attributes) yyVals[-5+yyTop]); if (type.Type != null && type.Type.Kind == MemberKind.Void) report.Error (547, GetLocation (yyVals[-3+yyTop]), "`{0}': property or indexer cannot have void type", current_property.GetSignatureForError ()); - current_container.AddProperty ((Property)current_property); + current_type.AddMember (current_property); lbag.AddMember (current_property, GetModifierLocations (), GetLocation (yyVals[0+yyTop])); lexer.PropertyParsing = true; } -void case_186() -#line 1696 "cs-parser.jay" +void case_190() +#line 1724 "cs-parser.jay" { lexer.PropertyParsing = false; @@ -5078,23 +5165,23 @@ void case_186() current_property.DocComment = ConsumeStoredComment (); } -void case_187() -#line 1703 "cs-parser.jay" +void case_191() +#line 1731 "cs-parser.jay" { lbag.AppendToMember (current_property, GetLocation (yyVals[0+yyTop])); current_property = null; } -void case_189() -#line 1717 "cs-parser.jay" +void case_193() +#line 1745 "cs-parser.jay" { valid_param_mod = 0; var type = (FullNamedExpression) yyVals[-6+yyTop]; - Indexer indexer = new Indexer (current_class, type, (MemberName) yyVals[-5+yyTop], (Modifiers) yyVals[-7+yyTop], (ParametersCompiled) yyVals[-2+yyTop], (Attributes) yyVals[-8+yyTop]); + Indexer indexer = new Indexer (current_type, type, (MemberName) yyVals[-5+yyTop], (Modifiers) yyVals[-7+yyTop], (ParametersCompiled) yyVals[-2+yyTop], (Attributes) yyVals[-8+yyTop]); current_property = indexer; - current_container.AddIndexer (indexer); + current_type.AddIndexer (indexer); lbag.AddMember (current_property, GetModifierLocations (), GetLocation (yyVals[-4+yyTop]), GetLocation (yyVals[-1+yyTop]), GetLocation (yyVals[0+yyTop])); if (type.Type != null && type.Type.Kind == MemberKind.Void) @@ -5112,8 +5199,8 @@ void case_189() lexer.PropertyParsing = true; } -void case_191() -#line 1746 "cs-parser.jay" +void case_195() +#line 1774 "cs-parser.jay" { if (current_property.AccessorFirst != null && current_property.AccessorFirst.Block == null) ((Indexer) current_property).ParameterInfo.CheckParameters (current_property); @@ -5125,8 +5212,8 @@ void case_191() current_property = null; } -void case_196() -#line 1765 "cs-parser.jay" +void case_200() +#line 1793 "cs-parser.jay" { if (yyToken == Token.CLOSE_BRACE) { report.Error (548, lexer.Location, "`{0}': property or indexer must have at least one accessor", current_property.GetSignatureForError ()); @@ -5138,8 +5225,8 @@ void case_196() } } -void case_197() -#line 1779 "cs-parser.jay" +void case_201() +#line 1807 "cs-parser.jay" { if (yyVals[-1+yyTop] != ModifierNone && lang_version == LanguageVersion.ISO_1) { FeatureIsNotAvailable (GetLocation (yyVals[-1+yyTop]), "access modifiers on properties"); @@ -5161,8 +5248,8 @@ void case_197() lexer.PropertyParsing = false; } -void case_198() -#line 1800 "cs-parser.jay" +void case_202() +#line 1828 "cs-parser.jay" { if (yyVals[0+yyTop] != null) { current_property.Get.Block = (ToplevelBlock) yyVals[0+yyTop]; @@ -5184,8 +5271,8 @@ void case_198() Lexer.doc_state = XmlCommentState.NotAllowed; } -void case_199() -#line 1824 "cs-parser.jay" +void case_203() +#line 1852 "cs-parser.jay" { if (yyVals[-1+yyTop] != ModifierNone && lang_version == LanguageVersion.ISO_1) { FeatureIsNotAvailable (GetLocation (yyVals[-1+yyTop]), "access modifiers on properties"); @@ -5212,8 +5299,8 @@ void case_199() lexer.PropertyParsing = false; } -void case_200() -#line 1850 "cs-parser.jay" +void case_204() +#line 1878 "cs-parser.jay" { if (yyVals[0+yyTop] != null) { current_property.Set.Block = (ToplevelBlock) yyVals[0+yyTop]; @@ -5235,68 +5322,69 @@ void case_200() Lexer.doc_state = XmlCommentState.NotAllowed; } -void case_202() -#line 1875 "cs-parser.jay" +void case_206() +#line 1903 "cs-parser.jay" { savedLocation = GetLocation (yyVals[0+yyTop]); yyVal = null; } -void case_203() -#line 1880 "cs-parser.jay" +void case_207() +#line 1908 "cs-parser.jay" { Error_SyntaxError (1043, yyToken, "Invalid accessor body"); yyVal = null; } -void case_205() -#line 1895 "cs-parser.jay" +void case_209() +#line 1923 "cs-parser.jay" { - MemberName name = MakeName ((MemberName) yyVals[0+yyTop]); - push_current_class (new Interface (current_namespace, current_class, name, (Modifiers) yyVals[-4+yyTop], (Attributes) yyVals[-5+yyTop]), yyVals[-3+yyTop]); - lbag.AddMember (current_class, GetModifierLocations (), GetLocation (yyVals[-2+yyTop])); + push_current_container (new Interface (current_container, (MemberName) yyVals[0+yyTop], (Modifiers) yyVals[-4+yyTop], (Attributes) yyVals[-5+yyTop]), yyVals[-3+yyTop]); + lbag.AddMember (current_container, GetModifierLocations (), GetLocation (yyVals[-2+yyTop])); } -void case_206() -#line 1902 "cs-parser.jay" +void case_210() +#line 1929 "cs-parser.jay" { lexer.ConstraintsParsing = false; if (yyVals[0+yyTop] != null) - current_class.SetConstraints ((List) yyVals[0+yyTop]); + current_container.SetConstraints ((List) yyVals[0+yyTop]); if (doc_support) { - current_container.DocComment = Lexer.consume_doc_comment (); + current_container.PartialContainer.DocComment = Lexer.consume_doc_comment (); Lexer.doc_state = XmlCommentState.Allowed; } lexer.parsing_modifiers = true; } -void case_207() -#line 1916 "cs-parser.jay" +void case_211() +#line 1943 "cs-parser.jay" { --lexer.parsing_declaration; if (doc_support) Lexer.doc_state = XmlCommentState.Allowed; } -void case_208() -#line 1922 "cs-parser.jay" +void case_212() +#line 1949 "cs-parser.jay" { - if (yyVals[0+yyTop] != null) - current_class.OptionalSemicolon = GetLocation (yyVals[0+yyTop]); - lbag.AppendToMember (current_class, GetLocation (yyVals[-4+yyTop]), GetLocation (yyVals[-2+yyTop])); + if (yyVals[0+yyTop] == null) { + lbag.AppendToMember (current_container, GetLocation (yyVals[-4+yyTop]), GetLocation (yyVals[-2+yyTop])); + } else { + lbag.AppendToMember (current_container, GetLocation (yyVals[-4+yyTop]), GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); + } yyVal = pop_current_class (); } -void case_224() -#line 1982 "cs-parser.jay" +void case_228() +#line 2011 "cs-parser.jay" { OperatorDeclaration decl = (OperatorDeclaration) yyVals[-2+yyTop]; if (decl != null) { Operator op = new Operator ( - current_class, decl.optype, decl.ret_type, (Modifiers) yyVals[-3+yyTop], + current_type, decl.optype, decl.ret_type, (Modifiers) yyVals[-3+yyTop], current_local_parameters, (ToplevelBlock) yyVals[0+yyTop], (Attributes) yyVals[-4+yyTop], decl.location); @@ -5309,7 +5397,7 @@ void case_224() } /* Note again, checking is done in semantic analysis*/ - current_container.AddOperator (op); + current_type.AddOperator (op); lbag.AddMember (op, GetModifierLocations (), lbag.GetLocations (decl)); if (yyVals[0+yyTop] == null) { /* Semicolon*/ @@ -5320,15 +5408,15 @@ void case_224() current_local_parameters = null; } -void case_228() -#line 2019 "cs-parser.jay" +void case_232() +#line 2048 "cs-parser.jay" { report.Error (590, GetLocation (yyVals[0+yyTop]), "User-defined operators cannot return void"); yyVal = new TypeExpression (compiler.BuiltinTypes.Void, GetLocation (yyVals[0+yyTop])); } -void case_230() -#line 2031 "cs-parser.jay" +void case_234() +#line 2060 "cs-parser.jay" { valid_param_mod = 0; @@ -5369,8 +5457,8 @@ void case_230() lbag.AddLocation (yyVal, GetLocation (yyVals[-5+yyTop]), savedOperatorLocation, GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_255() -#line 2107 "cs-parser.jay" +void case_259() +#line 2136 "cs-parser.jay" { valid_param_mod = 0; @@ -5386,8 +5474,8 @@ void case_255() lbag.AddLocation (yyVal, GetLocation (yyVals[-6+yyTop]), GetLocation (yyVals[-5+yyTop]), GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_257() -#line 2126 "cs-parser.jay" +void case_261() +#line 2155 "cs-parser.jay" { valid_param_mod = 0; @@ -5403,24 +5491,24 @@ void case_257() lbag.AddLocation (yyVal, GetLocation (yyVals[-6+yyTop]), GetLocation (yyVals[-5+yyTop]), GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_258() -#line 2141 "cs-parser.jay" +void case_262() +#line 2170 "cs-parser.jay" { Error_SyntaxError (yyToken); current_local_parameters = ParametersCompiled.EmptyReadOnlyParameters; yyVal = new OperatorDeclaration (Operator.OpType.Implicit, null, GetLocation (yyVals[-1+yyTop])); } -void case_259() -#line 2147 "cs-parser.jay" +void case_263() +#line 2176 "cs-parser.jay" { Error_SyntaxError (yyToken); current_local_parameters = ParametersCompiled.EmptyReadOnlyParameters; yyVal = new OperatorDeclaration (Operator.OpType.Explicit, null, GetLocation (yyVals[-1+yyTop])); } -void case_260() -#line 2157 "cs-parser.jay" +void case_264() +#line 2186 "cs-parser.jay" { Constructor c = (Constructor) yyVals[-1+yyTop]; c.Block = (ToplevelBlock) yyVals[0+yyTop]; @@ -5433,8 +5521,8 @@ void case_260() Lexer.doc_state = XmlCommentState.Allowed; } -void case_261() -#line 2174 "cs-parser.jay" +void case_265() +#line 2203 "cs-parser.jay" { if (doc_support) { tmpComment = Lexer.consume_doc_comment (); @@ -5444,15 +5532,15 @@ void case_261() valid_param_mod = ParameterModifierType.All; } -void case_262() -#line 2183 "cs-parser.jay" +void case_266() +#line 2212 "cs-parser.jay" { valid_param_mod = 0; current_local_parameters = (ParametersCompiled) yyVals[-1+yyTop]; var lt = (Tokenizer.LocatedToken) yyVals[-4+yyTop]; var mods = (Modifiers) yyVals[-5+yyTop]; - var c = new Constructor (current_class, lt.Value, mods, (Attributes) yyVals[-6+yyTop], current_local_parameters, lt.Location); + var c = new Constructor (current_type, lt.Value, mods, (Attributes) yyVals[-6+yyTop], current_local_parameters, lt.Location); if (lt.Value != current_container.MemberName.Name) { report.Error (1520, c.Location, "Class, struct, or interface method must have a return type"); @@ -5464,7 +5552,7 @@ void case_262() } } - current_container.AddConstructor (c); + current_type.AddConstructor (c); lbag.AddMember (c, GetModifierLocations (), GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); yyVal = c; @@ -5475,8 +5563,8 @@ void case_262() start_block (lexer.Location); } -void case_263() -#line 2212 "cs-parser.jay" +void case_267() +#line 2241 "cs-parser.jay" { if (yyVals[0+yyTop] != null) { var c = (Constructor) yyVals[-1+yyTop]; @@ -5492,39 +5580,39 @@ void case_263() yyVal = yyVals[-1+yyTop]; } -void case_269() -#line 2244 "cs-parser.jay" +void case_273() +#line 2273 "cs-parser.jay" { --lexer.parsing_block; yyVal = new ConstructorBaseInitializer ((Arguments) yyVals[-1+yyTop], GetLocation (yyVals[-4+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[-5+yyTop]), GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_271() -#line 2254 "cs-parser.jay" +void case_275() +#line 2283 "cs-parser.jay" { --lexer.parsing_block; yyVal = new ConstructorThisInitializer ((Arguments) yyVals[-1+yyTop], GetLocation (yyVals[-4+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[-5+yyTop]), GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_272() -#line 2260 "cs-parser.jay" +void case_276() +#line 2289 "cs-parser.jay" { - Error_SyntaxError (yyToken); - yyVal = new ConstructorThisInitializer (null, GetLocation (yyVals[-1+yyTop])); + Error_SyntaxError (yyToken); + yyVal = new ConstructorThisInitializer (null, GetLocation (yyVals[0+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[-1+yyTop])); } -void case_273() -#line 2266 "cs-parser.jay" +void case_277() +#line 2295 "cs-parser.jay" { Error_SyntaxError (yyToken); yyVal = null; } -void case_274() -#line 2274 "cs-parser.jay" +void case_278() +#line 2303 "cs-parser.jay" { if (doc_support) { tmpComment = Lexer.consume_doc_comment (); @@ -5534,8 +5622,8 @@ void case_274() current_local_parameters = ParametersCompiled.EmptyReadOnlyParameters; } -void case_275() -#line 2283 "cs-parser.jay" +void case_279() +#line 2312 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-3+yyTop]; if (lt.Value != current_container.MemberName.Name){ @@ -5544,23 +5632,24 @@ void case_275() report.Error (575, lt.Location, "Only class types can contain destructor"); } - Destructor d = new Destructor (current_class, (Modifiers) yyVals[-6+yyTop], + Destructor d = new Destructor (current_type, (Modifiers) yyVals[-6+yyTop], ParametersCompiled.EmptyReadOnlyParameters, (Attributes) yyVals[-7+yyTop], lt.Location); + d.Identifier = lt.Value; if (doc_support) d.DocComment = ConsumeStoredComment (); d.Block = (ToplevelBlock) yyVals[0+yyTop]; - current_container.AddMethod (d); + current_type.AddMember (d); lbag.AddMember (d, GetModifierLocations (), GetLocation (yyVals[-5+yyTop]), GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[-1+yyTop])); current_local_parameters = null; } -void case_276() -#line 2308 "cs-parser.jay" +void case_280() +#line 2338 "cs-parser.jay" { - current_event_field = new EventField (current_class, (FullNamedExpression) yyVals[-1+yyTop], (Modifiers) yyVals[-3+yyTop], (MemberName) yyVals[0+yyTop], (Attributes) yyVals[-4+yyTop]); - current_container.AddEvent (current_event_field); + current_event_field = new EventField (current_type, (FullNamedExpression) yyVals[-1+yyTop], (Modifiers) yyVals[-3+yyTop], (MemberName) yyVals[0+yyTop], (Attributes) yyVals[-4+yyTop]); + current_type.AddMember (current_event_field); if (current_event_field.MemberName.ExplicitInterface != null) { report.Error (71, current_event_field.Location, "`{0}': An explicit interface implementation of an event must use property syntax", @@ -5570,8 +5659,8 @@ void case_276() yyVal = current_event_field; } -void case_277() -#line 2322 "cs-parser.jay" +void case_281() +#line 2352 "cs-parser.jay" { if (doc_support) { current_event_field.DocComment = Lexer.consume_doc_comment (); @@ -5582,18 +5671,18 @@ void case_277() current_event_field = null; } -void case_278() -#line 2335 "cs-parser.jay" +void case_282() +#line 2365 "cs-parser.jay" { - current_event = new EventProperty (current_class, (FullNamedExpression) yyVals[-2+yyTop], (Modifiers) yyVals[-4+yyTop], (MemberName) yyVals[-1+yyTop], (Attributes) yyVals[-5+yyTop]); - current_container.AddEvent (current_event); + current_event = new EventProperty (current_type, (FullNamedExpression) yyVals[-2+yyTop], (Modifiers) yyVals[-4+yyTop], (MemberName) yyVals[-1+yyTop], (Attributes) yyVals[-5+yyTop]); + current_type.AddMember (current_event); lbag.AddMember (current_event, GetModifierLocations (), GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[0+yyTop])); lexer.EventParsing = true; } -void case_279() -#line 2343 "cs-parser.jay" +void case_283() +#line 2373 "cs-parser.jay" { if (current_container.Kind == MemberKind.Interface) report.Error (69, GetLocation (yyVals[-2+yyTop]), "Event in interface cannot have add or remove accessors"); @@ -5601,8 +5690,8 @@ void case_279() lexer.EventParsing = false; } -void case_280() -#line 2350 "cs-parser.jay" +void case_284() +#line 2380 "cs-parser.jay" { if (doc_support) { current_event.DocComment = Lexer.consume_doc_comment (); @@ -5614,23 +5703,23 @@ void case_280() current_local_parameters = null; } -void case_283() -#line 2369 "cs-parser.jay" +void case_287() +#line 2399 "cs-parser.jay" { --lexer.parsing_block; current_event_field.Initializer = (Expression) yyVals[0+yyTop]; } -void case_288() -#line 2393 "cs-parser.jay" +void case_292() +#line 2423 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; yyVal = new FieldDeclarator (new SimpleMemberName (lt.Value, lt.Location), null); lbag.AddLocation (yyVal, GetLocation (yyVals[-1+yyTop])); } -void case_290() -#line 2403 "cs-parser.jay" +void case_294() +#line 2433 "cs-parser.jay" { --lexer.parsing_block; var lt = (Tokenizer.LocatedToken) yyVals[-3+yyTop]; @@ -5638,8 +5727,8 @@ void case_290() lbag.AddLocation (yyVal, GetLocation (yyVals[-4+yyTop]), GetLocation (yyVals[-2+yyTop])); } -void case_291() -#line 2412 "cs-parser.jay" +void case_295() +#line 2442 "cs-parser.jay" { if (current_container.Kind == MemberKind.Interface) { report.Error (68, lexer.Location, "`{0}': event in interface cannot have an initializer", @@ -5652,29 +5741,29 @@ void case_291() } } -void case_295() -#line 2433 "cs-parser.jay" +void case_299() +#line 2463 "cs-parser.jay" { report.Error (65, lexer.Location, "`{0}': event property must have both add and remove accessors", current_event.GetSignatureForError ()); } -void case_296() -#line 2438 "cs-parser.jay" +void case_300() +#line 2468 "cs-parser.jay" { report.Error (65, lexer.Location, "`{0}': event property must have both add and remove accessors", current_event.GetSignatureForError ()); } -void case_297() -#line 2443 "cs-parser.jay" +void case_301() +#line 2473 "cs-parser.jay" { report.Error (1055, GetLocation (yyVals[0+yyTop]), "An add or remove accessor expected"); yyVal = null; } -void case_298() -#line 2451 "cs-parser.jay" +void case_302() +#line 2481 "cs-parser.jay" { if (yyVals[-1+yyTop] != ModifierNone) { report.Error (1609, GetLocation (yyVals[-1+yyTop]), "Modifiers cannot be placed on event accessor declarations"); @@ -5687,8 +5776,8 @@ void case_298() lexer.EventParsing = false; } -void case_299() -#line 2463 "cs-parser.jay" +void case_303() +#line 2493 "cs-parser.jay" { lexer.EventParsing = true; @@ -5702,8 +5791,8 @@ void case_299() current_local_parameters = null; } -void case_300() -#line 2479 "cs-parser.jay" +void case_304() +#line 2509 "cs-parser.jay" { if (yyVals[-1+yyTop] != ModifierNone) { report.Error (1609, GetLocation (yyVals[-1+yyTop]), "Modifiers cannot be placed on event accessor declarations"); @@ -5716,8 +5805,8 @@ void case_300() lexer.EventParsing = false; } -void case_301() -#line 2491 "cs-parser.jay" +void case_305() +#line 2521 "cs-parser.jay" { lexer.EventParsing = true; @@ -5731,22 +5820,30 @@ void case_301() current_local_parameters = null; } -void case_302() -#line 2507 "cs-parser.jay" +void case_306() +#line 2537 "cs-parser.jay" { report.Error (73, lexer.Location, "An add or remove accessor must have a body"); yyVal = null; } -void case_304() -#line 2520 "cs-parser.jay" +void case_308() +#line 2546 "cs-parser.jay" +{ + current_type.UnattachedAttributes = (Attributes) yyVals[-1+yyTop]; + report.Error (1519, GetLocation (yyVals[-1+yyTop]), "An attribute is missing member declaration"); + lexer.putback ('}'); + } + +void case_309() +#line 2559 "cs-parser.jay" { if (doc_support) enumTypeComment = Lexer.consume_doc_comment (); } -void case_305() -#line 2525 "cs-parser.jay" +void case_310() +#line 2564 "cs-parser.jay" { if (doc_support) Lexer.doc_state = XmlCommentState.Allowed; @@ -5756,71 +5853,67 @@ void case_305() report.Error (1675, name.Location, "Enums cannot have type parameters"); } - push_current_class (new Enum (current_namespace, current_class, (TypeExpression) yyVals[-2+yyTop], (Modifiers) yyVals[-5+yyTop], MakeName (name), (Attributes) yyVals[-6+yyTop]), null); + push_current_container (new Enum (current_container, (FullNamedExpression) yyVals[-2+yyTop], (Modifiers) yyVals[-5+yyTop], name, (Attributes) yyVals[-6+yyTop]), null); if (yyVals[-2+yyTop] != null) { - lbag.AddMember (current_class, GetModifierLocations (), GetLocation (yyVals[-4+yyTop]), savedLocation, GetLocation (yyVals[0+yyTop])); + lbag.AddMember (current_container, GetModifierLocations (), GetLocation (yyVals[-4+yyTop]), savedLocation, GetLocation (yyVals[0+yyTop])); } else { - lbag.AddMember (current_class, GetModifierLocations (), GetLocation (yyVals[-4+yyTop]), GetLocation (yyVals[0+yyTop])); + lbag.AddMember (current_container, GetModifierLocations (), GetLocation (yyVals[-4+yyTop]), GetLocation (yyVals[0+yyTop])); } } -void case_306() -#line 2542 "cs-parser.jay" +void case_311() +#line 2581 "cs-parser.jay" { /* here will be evaluated after CLOSE_BLACE is consumed.*/ if (doc_support) Lexer.doc_state = XmlCommentState.Allowed; } -void case_307() -#line 2548 "cs-parser.jay" +void case_312() +#line 2587 "cs-parser.jay" { - lbag.AppendToMember (current_class, GetLocation (yyVals[-1+yyTop])); + lbag.AppendToMember (current_container, GetLocation (yyVals[-1+yyTop])); if (yyVals[0+yyTop] != null) { - current_class.OptionalSemicolon = GetLocation (yyVals[0+yyTop]); - lbag.AppendToMember (current_class, GetLocation (yyVals[0+yyTop])); + lbag.AppendToMember (current_container, GetLocation (yyVals[0+yyTop])); } if (doc_support) - current_class.DocComment = enumTypeComment; + current_container.DocComment = enumTypeComment; --lexer.parsing_declaration; +/* if (doc_support)*/ +/* em.DocComment = ev.DocComment;*/ + yyVal = pop_current_class (); } -void case_309() -#line 2566 "cs-parser.jay" +void case_314() +#line 2607 "cs-parser.jay" { - var te = yyVals[0+yyTop] as TypeExpression; - if (te == null || !EnumSpec.IsValidUnderlyingType (te.Type)) { - Enum.Error_1008 (GetLocation (yyVals[0+yyTop]), report); - yyVal = null; - } else { - savedLocation = GetLocation (yyVals[-1+yyTop]); - yyVal = yyVals[0+yyTop]; - } + savedLocation = GetLocation (yyVals[-1+yyTop]); + yyVal = yyVals[0+yyTop]; } -void case_310() -#line 2577 "cs-parser.jay" +void case_315() +#line 2612 "cs-parser.jay" { Error_TypeExpected (GetLocation (yyVals[-1+yyTop])); yyVal = null; } -void case_315() -#line 2595 "cs-parser.jay" +void case_320() +#line 2630 "cs-parser.jay" { - lbag.AppendToMember (current_class, GetLocation (yyVals[-1+yyTop])); + lbag.AppendToMember (current_container, GetLocation (yyVals[-1+yyTop])); yyVal = yyVals[0+yyTop]; } -void case_316() -#line 2603 "cs-parser.jay" +void case_321() +#line 2638 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; - var em = new EnumMember ((Enum) current_class, new MemberName (lt.Value, lt.Location), (Attributes) yyVals[-1+yyTop]); - ((Enum) current_class).AddEnumMember (em); + var em = new EnumMember ((Enum) current_type, new MemberName (lt.Value, lt.Location), (Attributes) yyVals[-1+yyTop]); + ((Enum) current_type).AddEnumMember (em); if (doc_support) { em.DocComment = Lexer.consume_doc_comment (); @@ -5830,8 +5923,8 @@ void case_316() yyVal = em; } -void case_317() -#line 2616 "cs-parser.jay" +void case_322() +#line 2651 "cs-parser.jay" { ++lexer.parsing_block; if (doc_support) { @@ -5840,15 +5933,15 @@ void case_317() } } -void case_318() -#line 2624 "cs-parser.jay" +void case_323() +#line 2659 "cs-parser.jay" { --lexer.parsing_block; var lt = (Tokenizer.LocatedToken) yyVals[-3+yyTop]; - var em = new EnumMember ((Enum) current_class, new MemberName (lt.Value, lt.Location), (Attributes) yyVals[-4+yyTop]); + var em = new EnumMember ((Enum) current_type, new MemberName (lt.Value, lt.Location), (Attributes) yyVals[-4+yyTop]); em.Initializer = new ConstInitializer (em, (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); - ((Enum) current_class).AddEnumMember (em); + ((Enum) current_type).AddEnumMember (em); if (doc_support) em.DocComment = ConsumeStoredComment (); @@ -5856,28 +5949,25 @@ void case_318() yyVal = em; } -void case_320() -#line 2649 "cs-parser.jay" +void case_325() +#line 2684 "cs-parser.jay" { valid_param_mod = 0; - MemberName name = MakeName ((MemberName) yyVals[-4+yyTop]); ParametersCompiled p = (ParametersCompiled) yyVals[-1+yyTop]; - Delegate del = new Delegate (current_namespace, current_class, (FullNamedExpression) yyVals[-5+yyTop], - (Modifiers) yyVals[-7+yyTop], name, p, (Attributes) yyVals[-8+yyTop]); + Delegate del = new Delegate (current_container, (FullNamedExpression) yyVals[-5+yyTop], (Modifiers) yyVals[-7+yyTop], (MemberName) yyVals[-4+yyTop], p, (Attributes) yyVals[-8+yyTop]); + p.CheckParameters (del); - ubag.PushTypeDeclaration (del); - ubag.PopTypeDeclaration (); + current_container.AddTypeContainer (del); - current_container.AddDelegate (del); current_delegate = del; lexer.ConstraintsParsing = true; } -void case_322() -#line 2671 "cs-parser.jay" +void case_327() +#line 2703 "cs-parser.jay" { if (doc_support) { current_delegate.DocComment = Lexer.consume_doc_comment (); @@ -5893,8 +5983,8 @@ void case_322() current_delegate = null; } -void case_324() -#line 2690 "cs-parser.jay" +void case_329() +#line 2722 "cs-parser.jay" { if (lang_version < LanguageVersion.ISO_2) FeatureIsNotAvailable (GetLocation (yyVals[0+yyTop]), "nullable types"); @@ -5902,8 +5992,8 @@ void case_324() yyVal = ComposedTypeSpecifier.CreateNullable (GetLocation (yyVals[0+yyTop])); } -void case_326() -#line 2701 "cs-parser.jay" +void case_331() +#line 2733 "cs-parser.jay" { var lt1 = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; var lt2 = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; @@ -5912,23 +6002,23 @@ void case_326() lbag.AddLocation (yyVal, GetLocation (yyVals[-1+yyTop])); } -void case_328() -#line 2713 "cs-parser.jay" +void case_333() +#line 2745 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; yyVal = new MemberAccess ((Expression) yyVals[-3+yyTop], lt.Value, (TypeArguments) yyVals[0+yyTop], lt.Location); lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop])); } -void case_329() -#line 2722 "cs-parser.jay" +void case_334() +#line 2754 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; yyVal = new SimpleName (lt.Value, (TypeArguments)yyVals[0+yyTop], lt.Location); } -void case_331() -#line 2734 "cs-parser.jay" +void case_336() +#line 2766 "cs-parser.jay" { if (lang_version < LanguageVersion.ISO_2) FeatureIsNotAvailable (GetLocation (yyVals[-2+yyTop]), "generics"); @@ -5940,15 +6030,15 @@ void case_331() yyVal = yyVals[-1+yyTop];; } -void case_332() -#line 2745 "cs-parser.jay" +void case_337() +#line 2777 "cs-parser.jay" { Error_TypeExpected (lexer.Location); yyVal = new TypeArguments (); } -void case_333() -#line 2753 "cs-parser.jay" +void case_338() +#line 2785 "cs-parser.jay" { TypeArguments type_args = new TypeArguments (); type_args.Add ((FullNamedExpression) yyVals[0+yyTop]); @@ -5956,8 +6046,8 @@ void case_333() locationListStack.Push (new List ()); } -void case_334() -#line 2760 "cs-parser.jay" +void case_339() +#line 2792 "cs-parser.jay" { TypeArguments type_args = (TypeArguments) yyVals[-2+yyTop]; type_args.Add ((FullNamedExpression) yyVals[0+yyTop]); @@ -5965,16 +6055,16 @@ void case_334() locationListStack.Peek ().Add (GetLocation (yyVals[-1+yyTop])); } -void case_336() -#line 2777 "cs-parser.jay" +void case_341() +#line 2809 "cs-parser.jay" { lexer.parsing_generic_declaration = false; var lt = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; yyVal = new MemberName (lt.Value, (TypeParameters)yyVals[0+yyTop], lt.Location); } -void case_337() -#line 2786 "cs-parser.jay" +void case_342() +#line 2818 "cs-parser.jay" { MemberName mn = (MemberName)yyVals[0+yyTop]; if (mn.TypeParameters != null) @@ -5982,38 +6072,38 @@ void case_337() mn.GetSignatureForError ())); } -void case_339() -#line 2797 "cs-parser.jay" +void case_344() +#line 2829 "cs-parser.jay" { lexer.parsing_generic_declaration = false; var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; yyVal = new MemberName (lt.Value, (TypeParameters) yyVals[0+yyTop], (ATypeNameExpression) yyVals[-2+yyTop], lt.Location); } -void case_340() -#line 2806 "cs-parser.jay" +void case_345() +#line 2838 "cs-parser.jay" { lexer.parsing_generic_declaration = false; - yyVal = new MemberName (TypeContainer.DefaultIndexerName, GetLocation (yyVals[0+yyTop])); + yyVal = new MemberName (TypeDefinition.DefaultIndexerName, GetLocation (yyVals[0+yyTop])); } -void case_341() -#line 2811 "cs-parser.jay" +void case_346() +#line 2843 "cs-parser.jay" { lexer.parsing_generic_declaration = false; - yyVal = new MemberName (TypeContainer.DefaultIndexerName, null, (ATypeNameExpression) yyVals[-1+yyTop], GetLocation (yyVals[0+yyTop])); + yyVal = new MemberName (TypeDefinition.DefaultIndexerName, null, (ATypeNameExpression) yyVals[-1+yyTop], GetLocation (yyVals[0+yyTop])); } -void case_342() -#line 2819 "cs-parser.jay" +void case_347() +#line 2851 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; yyVal = new SimpleName (lt.Value, (TypeArguments) yyVals[-1+yyTop], lt.Location); lbag.AddLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_343() -#line 2825 "cs-parser.jay" +void case_348() +#line 2857 "cs-parser.jay" { var lt1 = (Tokenizer.LocatedToken) yyVals[-3+yyTop]; var lt2 = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; @@ -6022,50 +6112,54 @@ void case_343() lbag.AddLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_344() -#line 2833 "cs-parser.jay" +void case_349() +#line 2865 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; yyVal = new MemberAccess ((ATypeNameExpression) yyVals[-3+yyTop], lt.Value, (TypeArguments) yyVals[-1+yyTop], lt.Location); lbag.AddLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_346() -#line 2843 "cs-parser.jay" +void case_351() +#line 2875 "cs-parser.jay" { if (lang_version < LanguageVersion.ISO_2) FeatureIsNotAvailable (GetLocation (yyVals[-2+yyTop]), "generics"); yyVal = yyVals[-1+yyTop]; - lbag.AppendTo (yyVal, GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); + var list = locationListStack.Pop (); + list.Add (GetLocation (yyVals[-2+yyTop])); + list.Add (GetLocation (yyVals[-1+yyTop])); + lbag.AddLocation (yyVals[-1+yyTop], list); } -void case_347() -#line 2854 "cs-parser.jay" +void case_352() +#line 2889 "cs-parser.jay" { var tparams = new TypeParameters (); tparams.Add ((TypeParameter)yyVals[0+yyTop]); yyVal = tparams; + locationListStack.Push (new List ()); } -void case_348() -#line 2860 "cs-parser.jay" +void case_353() +#line 2896 "cs-parser.jay" { var tparams = (TypeParameters) yyVals[-2+yyTop]; tparams.Add ((TypeParameter)yyVals[0+yyTop]); yyVal = tparams; - lbag.AddLocation (yyVals[0+yyTop], GetLocation (yyVals[0+yyTop])); + locationListStack.Peek ().Add (GetLocation (yyVals[-1+yyTop])); } -void case_349() -#line 2870 "cs-parser.jay" +void case_354() +#line 2906 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken)yyVals[0+yyTop]; yyVal = new TypeParameter (new MemberName (lt.Value, lt.Location), (Attributes)yyVals[-2+yyTop], (Variance) yyVals[-1+yyTop]); } -void case_350() -#line 2875 "cs-parser.jay" +void case_355() +#line 2911 "cs-parser.jay" { if (GetTokenName (yyToken) == "type") report.Error (81, GetLocation (yyVals[0+yyTop]), "Type parameter declaration must be an identifier not a type"); @@ -6075,29 +6169,29 @@ void case_350() yyVal = new TypeParameter (MemberName.Null, null, Variance.None); } -void case_355() -#line 2909 "cs-parser.jay" +void case_360() +#line 2945 "cs-parser.jay" { Expression.Error_VoidInvalidInTheContext (GetLocation (yyVals[0+yyTop]), report); yyVal = new TypeExpression (compiler.BuiltinTypes.Void, GetLocation (yyVals[0+yyTop])); } -void case_357() -#line 2918 "cs-parser.jay" +void case_362() +#line 2954 "cs-parser.jay" { Expression.Error_VoidInvalidInTheContext (GetLocation (yyVals[0+yyTop]), report); yyVal = new TypeExpression (compiler.BuiltinTypes.Void, GetLocation (yyVals[0+yyTop])); } -void case_359() -#line 2927 "cs-parser.jay" +void case_364() +#line 2963 "cs-parser.jay" { report.Error (1536, GetLocation (yyVals[0+yyTop]), "Invalid parameter type `void'"); yyVal = new TypeExpression (compiler.BuiltinTypes.Void, GetLocation (yyVals[0+yyTop])); } -void case_362() -#line 2943 "cs-parser.jay" +void case_367() +#line 2979 "cs-parser.jay" { if (yyVals[0+yyTop] != null) { yyVal = new ComposedCast ((ATypeNameExpression) yyVals[-1+yyTop], (ComposedTypeSpecifier) yyVals[0+yyTop]); @@ -6110,23 +6204,23 @@ void case_362() } } -void case_364() -#line 2959 "cs-parser.jay" +void case_369() +#line 2995 "cs-parser.jay" { if (yyVals[0+yyTop] != null) yyVal = new ComposedCast ((FullNamedExpression) yyVals[-1+yyTop], (ComposedTypeSpecifier) yyVals[0+yyTop]); } -void case_367() -#line 2975 "cs-parser.jay" +void case_372() +#line 3011 "cs-parser.jay" { var types = new List (2); types.Add ((FullNamedExpression) yyVals[0+yyTop]); yyVal = types; } -void case_368() -#line 2981 "cs-parser.jay" +void case_373() +#line 3017 "cs-parser.jay" { var types = (List) yyVals[-2+yyTop]; types.Add ((FullNamedExpression) yyVals[0+yyTop]); @@ -6134,8 +6228,8 @@ void case_368() yyVal = types; } -void case_369() -#line 2991 "cs-parser.jay" +void case_374() +#line 3027 "cs-parser.jay" { if (yyVals[0+yyTop] is ComposedCast) { report.Error (1521, GetLocation (yyVals[0+yyTop]), "Invalid base type `{0}'", ((ComposedCast)yyVals[0+yyTop]).GetSignatureForError ()); @@ -6143,36 +6237,29 @@ void case_369() yyVal = yyVals[0+yyTop]; } -void case_370() -#line 2998 "cs-parser.jay" -{ - Error_TypeExpected (lexer.Location); - yyVal = null; - } - -void case_407() -#line 3060 "cs-parser.jay" +void case_411() +#line 3091 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; yyVal = new SimpleName (lt.Value, (TypeArguments)yyVals[0+yyTop], lt.Location); } -void case_408() -#line 3064 "cs-parser.jay" +void case_412() +#line 3095 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; yyVal = new CompletionSimpleName (MemberName.MakeName (lt.Value, null), lt.Location); } -void case_419() -#line 3105 "cs-parser.jay" +void case_423() +#line 3136 "cs-parser.jay" { yyVal = new ParenthesizedExpression ((Expression) yyVals[-1+yyTop]); lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_421() -#line 3117 "cs-parser.jay" +void case_425() +#line 3148 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; yyVal = new MemberAccess ((Expression) yyVals[-3+yyTop], lt.Value, (TypeArguments) yyVals[0+yyTop], lt.Location) { @@ -6180,8 +6267,8 @@ void case_421() }; } -void case_422() -#line 3124 "cs-parser.jay" +void case_426() +#line 3155 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; yyVal = new MemberAccess ((Expression) yyVals[-3+yyTop], lt.Value, (TypeArguments) yyVals[0+yyTop], lt.Location) { @@ -6189,8 +6276,8 @@ void case_422() }; } -void case_423() -#line 3131 "cs-parser.jay" +void case_427() +#line 3162 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; yyVal = new MemberAccess (new BaseThis (GetLocation (yyVals[-3+yyTop])), lt.Value, (TypeArguments) yyVals[0+yyTop], lt.Location) { @@ -6198,8 +6285,8 @@ void case_423() }; } -void case_424() -#line 3138 "cs-parser.jay" +void case_428() +#line 3169 "cs-parser.jay" { var lt1 = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; var lt2 = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; @@ -6208,29 +6295,29 @@ void case_424() lbag.AddLocation (yyVal, GetLocation (yyVals[-1+yyTop])); } -void case_426() -#line 3148 "cs-parser.jay" +void case_430() +#line 3179 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; yyVal = new CompletionMemberAccess ((Expression) yyVals[-3+yyTop], lt.Value, lt.Location); } -void case_428() -#line 3156 "cs-parser.jay" +void case_432() +#line 3187 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; yyVal = new CompletionMemberAccess ((Expression) yyVals[-3+yyTop], lt.Value, lt.Location); } -void case_429() -#line 3164 "cs-parser.jay" +void case_433() +#line 3195 "cs-parser.jay" { yyVal = new Invocation ((Expression) yyVals[-3+yyTop], (Arguments) yyVals[-1+yyTop]); lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_432() -#line 3177 "cs-parser.jay" +void case_436() +#line 3208 "cs-parser.jay" { if (yyVals[-1+yyTop] == null) { yyVal = CollectionOrObjectInitializers.Empty; @@ -6241,23 +6328,23 @@ void case_432() } } -void case_433() -#line 3187 "cs-parser.jay" +void case_437() +#line 3218 "cs-parser.jay" { yyVal = new CollectionOrObjectInitializers ((List) yyVals[-2+yyTop], GetLocation (yyVals[-3+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[-1+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_436() -#line 3203 "cs-parser.jay" +void case_440() +#line 3234 "cs-parser.jay" { var a = new List (); a.Add ((Expression) yyVals[0+yyTop]); yyVal = a; } -void case_437() -#line 3209 "cs-parser.jay" +void case_441() +#line 3240 "cs-parser.jay" { var a = (List)yyVals[-2+yyTop]; a.Add ((Expression) yyVals[0+yyTop]); @@ -6265,23 +6352,23 @@ void case_437() yyVal = a; } -void case_438() -#line 3215 "cs-parser.jay" +void case_442() +#line 3246 "cs-parser.jay" { Error_SyntaxError (yyToken); yyVal = yyVals[-1+yyTop]; } -void case_439() -#line 3223 "cs-parser.jay" +void case_443() +#line 3254 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; yyVal = new ElementInitializer (lt.Value, (Expression)yyVals[0+yyTop], lt.Location); lbag.AddLocation (yyVal, GetLocation (yyVals[-1+yyTop])); } -void case_441() -#line 3232 "cs-parser.jay" +void case_445() +#line 3263 "cs-parser.jay" { CompletionSimpleName csn = yyVals[-1+yyTop] as CompletionSimpleName; if (csn == null) @@ -6290,32 +6377,34 @@ void case_441() yyVal = new CompletionElementInitializer (csn.Prefix, csn.Location); } -void case_442() -#line 3240 "cs-parser.jay" +void case_446() +#line 3271 "cs-parser.jay" { if (yyVals[-1+yyTop] == null) yyVal = null; - else + else { yyVal = new CollectionElementInitializer ((List)yyVals[-1+yyTop], GetLocation (yyVals[-2+yyTop])); + lbag.AddLocation (yyVal, GetLocation (yyVals[-1+yyTop])); + } } -void case_443() -#line 3247 "cs-parser.jay" +void case_447() +#line 3280 "cs-parser.jay" { report.Error (1920, GetLocation (yyVals[-1+yyTop]), "An element initializer cannot be empty"); yyVal = null; } -void case_448() -#line 3265 "cs-parser.jay" +void case_452() +#line 3298 "cs-parser.jay" { Arguments list = new Arguments (4); list.Add ((Argument) yyVals[0+yyTop]); yyVal = list; } -void case_449() -#line 3271 "cs-parser.jay" +void case_453() +#line 3304 "cs-parser.jay" { Arguments list = (Arguments) yyVals[-2+yyTop]; if (list [list.Count - 1] is NamedArgument) @@ -6326,8 +6415,8 @@ void case_449() yyVal = list; } -void case_450() -#line 3281 "cs-parser.jay" +void case_454() +#line 3314 "cs-parser.jay" { Arguments list = (Arguments) yyVals[-2+yyTop]; NamedArgument a = (NamedArgument) yyVals[0+yyTop]; @@ -6343,65 +6432,79 @@ void case_450() yyVal = list; } -void case_451() -#line 3296 "cs-parser.jay" +void case_455() +#line 3329 "cs-parser.jay" { - report.Error (839, GetLocation (yyVals[0+yyTop]), "An argument is missing"); - yyVal = yyVals[-1+yyTop]; + Error_SyntaxError (yyToken); + yyVal = yyVals[-2+yyTop]; } -void case_452() -#line 3301 "cs-parser.jay" +void case_456() +#line 3334 "cs-parser.jay" { report.Error (839, GetLocation (yyVals[-1+yyTop]), "An argument is missing"); yyVal = null; } -void case_457() -#line 3322 "cs-parser.jay" +void case_461() +#line 3355 "cs-parser.jay" { yyVal = new Argument ((Expression) yyVals[0+yyTop], Argument.AType.Ref); lbag.AddLocation (yyVal, GetLocation (yyVals[-1+yyTop])); } -void case_458() -#line 3327 "cs-parser.jay" +void case_462() +#line 3360 "cs-parser.jay" { yyVal = new Argument ((Expression) yyVals[0+yyTop], Argument.AType.Out); lbag.AddLocation (yyVal, GetLocation (yyVals[-1+yyTop])); } -void case_459() -#line 3332 "cs-parser.jay" +void case_463() +#line 3365 "cs-parser.jay" { yyVal = new Argument (new Arglist ((Arguments) yyVals[-1+yyTop], GetLocation (yyVals[-3+yyTop]))); lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_460() -#line 3337 "cs-parser.jay" +void case_464() +#line 3370 "cs-parser.jay" { yyVal = new Argument (new Arglist (GetLocation (yyVals[-2+yyTop]))); lbag.AddLocation (yyVal, GetLocation (yyVals[-1+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_462() -#line 3349 "cs-parser.jay" +void case_466() +#line 3382 "cs-parser.jay" { yyVal = new ElementAccess ((Expression) yyVals[-3+yyTop], (Arguments) yyVals[-1+yyTop], GetLocation (yyVals[-2+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_465() -#line 3365 "cs-parser.jay" +void case_467() +#line 3387 "cs-parser.jay" +{ + Error_SyntaxError (yyToken); + yyVal = new ElementAccess ((Expression) yyVals[-3+yyTop], (Arguments) yyVals[-1+yyTop], GetLocation (yyVals[-2+yyTop])); + } + +void case_468() +#line 3392 "cs-parser.jay" +{ + Error_SyntaxError (yyToken); + yyVal = new ElementAccess ((Expression) yyVals[-2+yyTop], null, GetLocation (yyVals[-1+yyTop])); + } + +void case_469() +#line 3400 "cs-parser.jay" { var list = new List (4); list.Add ((Expression) yyVals[0+yyTop]); yyVal = list; } -void case_466() -#line 3371 "cs-parser.jay" +void case_470() +#line 3406 "cs-parser.jay" { var list = (List) yyVals[-2+yyTop]; list.Add ((Expression) yyVals[0+yyTop]); @@ -6409,23 +6512,23 @@ void case_466() yyVal = list; } -void case_467() -#line 3377 "cs-parser.jay" +void case_471() +#line 3412 "cs-parser.jay" { Error_SyntaxError (yyToken); yyVal = yyVals[-1+yyTop]; } -void case_468() -#line 3385 "cs-parser.jay" +void case_472() +#line 3420 "cs-parser.jay" { Arguments args = new Arguments (4); args.Add ((Argument) yyVals[0+yyTop]); yyVal = args; } -void case_469() -#line 3391 "cs-parser.jay" +void case_473() +#line 3426 "cs-parser.jay" { Arguments args = (Arguments) yyVals[-2+yyTop]; if (args [args.Count - 1] is NamedArgument && !(yyVals[0+yyTop] is NamedArgument)) @@ -6436,22 +6539,22 @@ void case_469() yyVal = args; } -void case_473() -#line 3419 "cs-parser.jay" +void case_477() +#line 3454 "cs-parser.jay" { yyVal = new ElementAccess (new BaseThis (GetLocation (yyVals[-3+yyTop])), (Arguments) yyVals[-1+yyTop], GetLocation (yyVals[-2+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_474() -#line 3424 "cs-parser.jay" +void case_478() +#line 3459 "cs-parser.jay" { Error_SyntaxError (yyToken); yyVal = new ElementAccess (null, null, GetLocation (yyVals[-1+yyTop])); } -void case_477() -#line 3446 "cs-parser.jay" +void case_481() +#line 3481 "cs-parser.jay" { if (yyVals[0+yyTop] != null) { if (lang_version <= LanguageVersion.ISO_2) @@ -6465,8 +6568,8 @@ void case_477() lbag.AddLocation (yyVal, GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[-1+yyTop])); } -void case_478() -#line 3459 "cs-parser.jay" +void case_482() +#line 3494 "cs-parser.jay" { if (lang_version <= LanguageVersion.ISO_2) FeatureIsNotAvailable (GetLocation (yyVals[-2+yyTop]), "collection initializers"); @@ -6474,8 +6577,8 @@ void case_478() yyVal = new NewInitialize ((FullNamedExpression) yyVals[-1+yyTop], null, (CollectionOrObjectInitializers) yyVals[0+yyTop], GetLocation (yyVals[-2+yyTop])); } -void case_479() -#line 3471 "cs-parser.jay" +void case_483() +#line 3506 "cs-parser.jay" { yyVal = new ArrayCreation ((FullNamedExpression) yyVals[-5+yyTop], (List) yyVals[-3+yyTop], new ComposedTypeSpecifier (((List) yyVals[-3+yyTop]).Count, GetLocation (yyVals[-4+yyTop])) { @@ -6484,8 +6587,8 @@ void case_479() lbag.AddLocation (yyVal, GetLocation (yyVals[-4+yyTop]), GetLocation (yyVals[-2+yyTop])); } -void case_480() -#line 3479 "cs-parser.jay" +void case_484() +#line 3514 "cs-parser.jay" { if (yyVals[0+yyTop] == null) report.Error (1586, GetLocation (yyVals[-3+yyTop]), "Array creation must have array size or array initializer"); @@ -6493,8 +6596,8 @@ void case_480() yyVal = new ArrayCreation ((FullNamedExpression) yyVals[-2+yyTop], (ComposedTypeSpecifier) yyVals[-1+yyTop], (ArrayInitializer) yyVals[0+yyTop], GetLocation (yyVals[-3+yyTop])); } -void case_481() -#line 3486 "cs-parser.jay" +void case_485() +#line 3521 "cs-parser.jay" { if (lang_version <= LanguageVersion.ISO_2) FeatureIsNotAvailable (GetLocation (yyVals[-2+yyTop]), "implicitly typed arrays"); @@ -6502,29 +6605,30 @@ void case_481() yyVal = new ImplicitlyTypedArrayCreation ((ComposedTypeSpecifier) yyVals[-1+yyTop], (ArrayInitializer) yyVals[0+yyTop], GetLocation (yyVals[-2+yyTop])); } -void case_482() -#line 3493 "cs-parser.jay" +void case_486() +#line 3528 "cs-parser.jay" { report.Error (178, GetLocation (yyVals[-1+yyTop]), "Invalid rank specifier, expecting `,' or `]'"); yyVal = new ArrayCreation ((FullNamedExpression) yyVals[-5+yyTop], null, GetLocation (yyVals[-6+yyTop])); } -void case_483() -#line 3498 "cs-parser.jay" +void case_487() +#line 3533 "cs-parser.jay" { - Error_SyntaxError (1526, yyToken, "Unexpected symbol"); - yyVal = new ArrayCreation ((FullNamedExpression) yyVals[-1+yyTop], null, GetLocation (yyVals[-2+yyTop])); + Error_SyntaxError (yyToken); + /* It can be any of new expression, create the most common one*/ + yyVal = new New ((FullNamedExpression) yyVals[-1+yyTop], null, GetLocation (yyVals[-2+yyTop])); } -void case_485() -#line 3509 "cs-parser.jay" +void case_489() +#line 3545 "cs-parser.jay" { --lexer.parsing_type; yyVal = yyVals[0+yyTop]; } -void case_486() -#line 3517 "cs-parser.jay" +void case_490() +#line 3553 "cs-parser.jay" { if (lang_version <= LanguageVersion.ISO_2) FeatureIsNotAvailable (GetLocation (yyVals[-3+yyTop]), "anonymous types"); @@ -6535,16 +6639,16 @@ void case_486() lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_491() -#line 3540 "cs-parser.jay" +void case_495() +#line 3576 "cs-parser.jay" { var a = new List (4); a.Add ((AnonymousTypeParameter) yyVals[0+yyTop]); yyVal = a; } -void case_492() -#line 3546 "cs-parser.jay" +void case_496() +#line 3582 "cs-parser.jay" { var a = (List) yyVals[-2+yyTop]; a.Add ((AnonymousTypeParameter) yyVals[0+yyTop]); @@ -6553,60 +6657,60 @@ void case_492() yyVal = a; } -void case_493() -#line 3557 "cs-parser.jay" +void case_497() +#line 3593 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken)yyVals[-2+yyTop]; yyVal = new AnonymousTypeParameter ((Expression)yyVals[0+yyTop], lt.Value, lt.Location); lbag.AddLocation (yyVal, GetLocation (yyVals[-1+yyTop])); } -void case_494() -#line 3563 "cs-parser.jay" +void case_498() +#line 3599 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken)yyVals[0+yyTop]; yyVal = new AnonymousTypeParameter (new SimpleName (lt.Value, lt.Location), lt.Value, lt.Location); } -void case_495() -#line 3569 "cs-parser.jay" +void case_499() +#line 3605 "cs-parser.jay" { MemberAccess ma = (MemberAccess) yyVals[0+yyTop]; yyVal = new AnonymousTypeParameter (ma, ma.Name, ma.Location); } -void case_496() -#line 3574 "cs-parser.jay" +void case_500() +#line 3610 "cs-parser.jay" { report.Error (746, lexer.Location, "Invalid anonymous type member declarator. Anonymous type members must be a member assignment, simple name or member access expression"); yyVal = null; } -void case_500() -#line 3589 "cs-parser.jay" +void case_504() +#line 3625 "cs-parser.jay" { ((ComposedTypeSpecifier) yyVals[-1+yyTop]).Next = (ComposedTypeSpecifier) yyVals[0+yyTop]; yyVal = yyVals[-1+yyTop]; } -void case_501() -#line 3597 "cs-parser.jay" +void case_505() +#line 3633 "cs-parser.jay" { yyVal = ComposedTypeSpecifier.CreateArrayDimension (1, GetLocation (yyVals[-1+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_502() -#line 3602 "cs-parser.jay" +void case_506() +#line 3638 "cs-parser.jay" { yyVal = ComposedTypeSpecifier.CreateArrayDimension ((int)yyVals[-1+yyTop], GetLocation (yyVals[-2+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_507() -#line 3632 "cs-parser.jay" +void case_511() +#line 3668 "cs-parser.jay" { var ai = new ArrayInitializer (0, GetLocation (yyVals[-1+yyTop])); ai.VariableDeclaration = current_variable; @@ -6614,8 +6718,8 @@ void case_507() yyVal = ai; } -void case_508() -#line 3639 "cs-parser.jay" +void case_512() +#line 3675 "cs-parser.jay" { var ai = new ArrayInitializer ((List) yyVals[-2+yyTop], GetLocation (yyVals[-3+yyTop])); ai.VariableDeclaration = current_variable; @@ -6627,16 +6731,16 @@ void case_508() yyVal = ai; } -void case_509() -#line 3653 "cs-parser.jay" +void case_513() +#line 3689 "cs-parser.jay" { var list = new List (4); list.Add ((Expression) yyVals[0+yyTop]); yyVal = list; } -void case_510() -#line 3659 "cs-parser.jay" +void case_514() +#line 3695 "cs-parser.jay" { var list = (List) yyVals[-2+yyTop]; list.Add ((Expression) yyVals[0+yyTop]); @@ -6644,31 +6748,31 @@ void case_510() yyVal = list; } -void case_512() -#line 3673 "cs-parser.jay" +void case_516() +#line 3709 "cs-parser.jay" { lexer.TypeOfParsing = false; yyVal = new TypeOf ((FullNamedExpression) yyVals[-1+yyTop], GetLocation (yyVals[-4+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_515() -#line 3684 "cs-parser.jay" +void case_519() +#line 3720 "cs-parser.jay" { Error_TypeExpected (lexer.Location); yyVal = null; } -void case_516() -#line 3692 "cs-parser.jay" +void case_520() +#line 3728 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; yyVal = new SimpleName (lt.Value, (int) yyVals[0+yyTop], lt.Location); } -void case_517() -#line 3698 "cs-parser.jay" +void case_521() +#line 3734 "cs-parser.jay" { var lt1 = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; var lt2 = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; @@ -6677,8 +6781,8 @@ void case_517() lbag.AddLocation (yyVal, GetLocation (yyVals[-1+yyTop])); } -void case_518() -#line 3706 "cs-parser.jay" +void case_522() +#line 3742 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; @@ -6687,8 +6791,8 @@ void case_518() }; } -void case_519() -#line 3714 "cs-parser.jay" +void case_523() +#line 3750 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; @@ -6697,8 +6801,8 @@ void case_519() }; } -void case_520() -#line 3722 "cs-parser.jay" +void case_524() +#line 3758 "cs-parser.jay" { var tne = (ATypeNameExpression) yyVals[-3+yyTop]; if (tne.HasTypeArguments) @@ -6710,8 +6814,8 @@ void case_520() }; } -void case_521() -#line 3736 "cs-parser.jay" +void case_525() +#line 3772 "cs-parser.jay" { if (lang_version < LanguageVersion.ISO_2) FeatureIsNotAvailable (GetLocation (yyVals[0+yyTop]), "generics"); @@ -6719,8 +6823,8 @@ void case_521() yyVal = yyVals[0+yyTop]; } -void case_522() -#line 3746 "cs-parser.jay" +void case_526() +#line 3782 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; if (lang_version == LanguageVersion.ISO_1) @@ -6729,36 +6833,36 @@ void case_522() yyVal = lt; } -void case_523() -#line 3757 "cs-parser.jay" +void case_527() +#line 3793 "cs-parser.jay" { yyVal = new SizeOf ((Expression) yyVals[-1+yyTop], GetLocation (yyVals[-3+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_524() -#line 3765 "cs-parser.jay" +void case_528() +#line 3801 "cs-parser.jay" { yyVal = new CheckedExpr ((Expression) yyVals[-1+yyTop], GetLocation (yyVals[-3+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_525() -#line 3773 "cs-parser.jay" +void case_529() +#line 3809 "cs-parser.jay" { yyVal = new UnCheckedExpr ((Expression) yyVals[-1+yyTop], GetLocation (yyVals[-3+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_526() -#line 3781 "cs-parser.jay" +void case_530() +#line 3817 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; yyVal = new MemberAccess (new Indirection ((Expression) yyVals[-3+yyTop], GetLocation (yyVals[-2+yyTop])), lt.Value, (TypeArguments) yyVals[0+yyTop], lt.Location); } -void case_528() -#line 3793 "cs-parser.jay" +void case_532() +#line 3829 "cs-parser.jay" { yyVal = end_anonymous ((ParametersBlock) yyVals[0+yyTop]); if ((ParametersCompiled) yyVals[-2+yyTop] != ParametersCompiled.Undefined) { @@ -6768,8 +6872,8 @@ void case_528() } } -void case_530() -#line 3806 "cs-parser.jay" +void case_534() +#line 3842 "cs-parser.jay" { yyVal = end_anonymous ((ParametersBlock) yyVals[0+yyTop]); @@ -6780,8 +6884,8 @@ void case_530() } } -void case_534() -#line 3831 "cs-parser.jay" +void case_538() +#line 3867 "cs-parser.jay" { valid_param_mod = 0; yyVal = yyVals[-1+yyTop]; @@ -6789,8 +6893,8 @@ void case_534() savedCloseLocation = GetLocation (yyVals[-2+yyTop]); } -void case_535() -#line 3841 "cs-parser.jay" +void case_539() +#line 3877 "cs-parser.jay" { if (lang_version < LanguageVersion.ISO_2) FeatureIsNotAvailable (GetLocation (yyVals[-3+yyTop]), "default value expression"); @@ -6799,19 +6903,27 @@ void case_535() lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_539() -#line 3861 "cs-parser.jay" +void case_543() +#line 3897 "cs-parser.jay" { yyVal = new Cast ((FullNamedExpression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-3+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[-1+yyTop])); } -void case_540() -#line 3866 "cs-parser.jay" +void case_544() +#line 3902 "cs-parser.jay" { if (!async_block) { - report.Error (1992, GetLocation (yyVals[-1+yyTop]), - "The `await' operator can only be used when its containing method or lambda expression is marked with the `async' modifier"); + if (current_anonymous_method is LambdaExpression) { + report.Error (4034, GetLocation (yyVals[-1+yyTop]), + "The `await' operator can only be used when its containing lambda expression is marked with the `async' modifier"); + } else if (current_anonymous_method is AnonymousMethodExpression) { + report.Error (4035, GetLocation (yyVals[-1+yyTop]), + "The `await' operator can only be used when its containing anonymous method is marked with the `async' modifier"); + } else { + report.Error (4033, GetLocation (yyVals[-1+yyTop]), + "The `await' operator can only be used when its containing method is marked with the `async' modifier"); + } } else { current_block.Explicit.RegisterAsyncAwait (); } @@ -6819,134 +6931,134 @@ void case_540() yyVal = new Await ((Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_549() -#line 3913 "cs-parser.jay" +void case_553() +#line 3957 "cs-parser.jay" { yyVal = new Binary (Binary.Operator.Multiply, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_550() -#line 3918 "cs-parser.jay" +void case_554() +#line 3962 "cs-parser.jay" { yyVal = new Binary (Binary.Operator.Division, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_551() -#line 3923 "cs-parser.jay" +void case_555() +#line 3967 "cs-parser.jay" { yyVal = new Binary (Binary.Operator.Modulus, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_553() -#line 3932 "cs-parser.jay" +void case_557() +#line 3976 "cs-parser.jay" { yyVal = new Binary (Binary.Operator.Addition, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_555() -#line 3941 "cs-parser.jay" +void case_559() +#line 3985 "cs-parser.jay" { /* Shift/Reduce conflict*/ yyVal = new Binary (Binary.Operator.Subtraction, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_559() -#line 3958 "cs-parser.jay" +void case_563() +#line 4002 "cs-parser.jay" { yyVal = new Binary (Binary.Operator.LeftShift, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_560() -#line 3963 "cs-parser.jay" +void case_564() +#line 4007 "cs-parser.jay" { yyVal = new Binary (Binary.Operator.RightShift, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_562() -#line 3972 "cs-parser.jay" +void case_566() +#line 4016 "cs-parser.jay" { yyVal = new Binary (Binary.Operator.LessThan, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_563() -#line 3977 "cs-parser.jay" +void case_567() +#line 4021 "cs-parser.jay" { yyVal = new Binary (Binary.Operator.GreaterThan, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_564() -#line 3982 "cs-parser.jay" +void case_568() +#line 4026 "cs-parser.jay" { yyVal = new Binary (Binary.Operator.LessThanOrEqual, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_565() -#line 3987 "cs-parser.jay" +void case_569() +#line 4031 "cs-parser.jay" { yyVal = new Binary (Binary.Operator.GreaterThanOrEqual, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_567() -#line 3996 "cs-parser.jay" +void case_571() +#line 4040 "cs-parser.jay" { yyVal = new Binary (Binary.Operator.Equality, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_568() -#line 4001 "cs-parser.jay" +void case_572() +#line 4045 "cs-parser.jay" { yyVal = new Binary (Binary.Operator.Inequality, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_570() -#line 4010 "cs-parser.jay" +void case_574() +#line 4054 "cs-parser.jay" { yyVal = new Binary (Binary.Operator.BitwiseAnd, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_572() -#line 4019 "cs-parser.jay" +void case_576() +#line 4063 "cs-parser.jay" { yyVal = new Binary (Binary.Operator.ExclusiveOr, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_574() -#line 4028 "cs-parser.jay" +void case_578() +#line 4072 "cs-parser.jay" { yyVal = new Binary (Binary.Operator.BitwiseOr, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_576() -#line 4037 "cs-parser.jay" +void case_580() +#line 4081 "cs-parser.jay" { yyVal = new Binary (Binary.Operator.LogicalAnd, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_578() -#line 4046 "cs-parser.jay" +void case_582() +#line 4090 "cs-parser.jay" { yyVal = new Binary (Binary.Operator.LogicalOr, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_580() -#line 4055 "cs-parser.jay" +void case_584() +#line 4099 "cs-parser.jay" { if (lang_version < LanguageVersion.ISO_2) FeatureIsNotAvailable (GetLocation (yyVals[-1+yyTop]), "null coalescing operator"); @@ -6954,85 +7066,92 @@ void case_580() yyVal = new Nullable.NullCoalescingOperator ((Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_582() -#line 4066 "cs-parser.jay" +void case_586() +#line 4110 "cs-parser.jay" { yyVal = new Conditional (new BooleanExpression ((Expression) yyVals[-4+yyTop]), (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-3+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[-1+yyTop])); } -void case_584() -#line 4078 "cs-parser.jay" +void case_587() +#line 4115 "cs-parser.jay" +{ + Error_SyntaxError (yyToken); + yyVal = new Conditional (new BooleanExpression ((Expression) yyVals[-3+yyTop]), (Expression) yyVals[-1+yyTop], null, GetLocation (yyVals[-2+yyTop])); + } + +void case_589() +#line 4127 "cs-parser.jay" { yyVal = new CompoundAssign ( Binary.Operator.Multiply, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_585() -#line 4083 "cs-parser.jay" +void case_590() +#line 4132 "cs-parser.jay" { yyVal = new CompoundAssign ( Binary.Operator.Division, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_586() -#line 4088 "cs-parser.jay" +void case_591() +#line 4137 "cs-parser.jay" { yyVal = new CompoundAssign ( Binary.Operator.Modulus, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_587() -#line 4093 "cs-parser.jay" +void case_592() +#line 4142 "cs-parser.jay" { yyVal = new CompoundAssign ( Binary.Operator.Addition, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_588() -#line 4098 "cs-parser.jay" +void case_593() +#line 4147 "cs-parser.jay" { yyVal = new CompoundAssign ( Binary.Operator.Subtraction, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_589() -#line 4103 "cs-parser.jay" +void case_594() +#line 4152 "cs-parser.jay" { yyVal = new CompoundAssign ( Binary.Operator.LeftShift, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_590() -#line 4108 "cs-parser.jay" +void case_595() +#line 4157 "cs-parser.jay" { yyVal = new CompoundAssign ( Binary.Operator.RightShift, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_591() -#line 4113 "cs-parser.jay" +void case_596() +#line 4162 "cs-parser.jay" { yyVal = new CompoundAssign ( Binary.Operator.BitwiseAnd, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_592() -#line 4118 "cs-parser.jay" +void case_597() +#line 4167 "cs-parser.jay" { yyVal = new CompoundAssign ( Binary.Operator.BitwiseOr, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_593() -#line 4123 "cs-parser.jay" +void case_598() +#line 4172 "cs-parser.jay" { yyVal = new CompoundAssign ( Binary.Operator.ExclusiveOr, (Expression) yyVals[-2+yyTop], (Expression) yyVals[0+yyTop], GetLocation (yyVals[-1+yyTop])); } -void case_594() -#line 4131 "cs-parser.jay" +void case_599() +#line 4180 "cs-parser.jay" { var pars = new List (4); pars.Add ((Parameter) yyVals[0+yyTop]); @@ -7040,8 +7159,8 @@ void case_594() yyVal = pars; } -void case_595() -#line 4138 "cs-parser.jay" +void case_600() +#line 4187 "cs-parser.jay" { var pars = (List) yyVals[-2+yyTop]; Parameter p = (Parameter)yyVals[0+yyTop]; @@ -7055,188 +7174,189 @@ void case_595() yyVal = pars; } -void case_596() -#line 4154 "cs-parser.jay" +void case_601() +#line 4203 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; yyVal = new Parameter ((FullNamedExpression) yyVals[-1+yyTop], lt.Value, (Parameter.Modifier) yyVals[-2+yyTop], null, lt.Location); } -void case_597() -#line 4160 "cs-parser.jay" +void case_602() +#line 4209 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; yyVal = new Parameter ((FullNamedExpression) yyVals[-1+yyTop], lt.Value, Parameter.Modifier.NONE, null, lt.Location); } -void case_598() -#line 4166 "cs-parser.jay" +void case_603() +#line 4215 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; yyVal = new ImplicitLambdaParameter (lt.Value, lt.Location); } -void case_600() -#line 4174 "cs-parser.jay" +void case_605() +#line 4223 "cs-parser.jay" { var pars_list = (List) yyVals[0+yyTop]; yyVal = new ParametersCompiled (pars_list.ToArray ()); lbag.AddLocation (yyVal, parameterListCommas); } -void case_604() -#line 4191 "cs-parser.jay" +void case_609() +#line 4240 "cs-parser.jay" { - Block b = end_block (lexer.Location); + Block b = end_block (Location.Null); b.IsCompilerGenerated = true; b.AddStatement (new ContextualReturn ((Expression) yyVals[0+yyTop])); yyVal = b; } -void case_606() -#line 4202 "cs-parser.jay" +void case_611() +#line 4251 "cs-parser.jay" { Error_SyntaxError (yyToken); yyVal = EmptyExpression.Null; } -void case_607() -#line 4210 "cs-parser.jay" +void case_612() +#line 4259 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; Parameter p = new ImplicitLambdaParameter (lt.Value, lt.Location); start_anonymous (true, new ParametersCompiled (p), false, lt.Location); } -void case_608() -#line 4216 "cs-parser.jay" +void case_613() +#line 4265 "cs-parser.jay" { yyVal = end_anonymous ((ParametersBlock) yyVals[0+yyTop]); lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop])); } -void case_609() -#line 4221 "cs-parser.jay" +void case_614() +#line 4270 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; Parameter p = new ImplicitLambdaParameter (lt.Value, lt.Location); start_anonymous (true, new ParametersCompiled (p), true, lt.Location); } -void case_610() -#line 4227 "cs-parser.jay" +void case_615() +#line 4276 "cs-parser.jay" { yyVal = end_anonymous ((ParametersBlock) yyVals[0+yyTop]); lbag.AddLocation (yyVal, GetLocation (yyVals[-4+yyTop]), GetLocation (yyVals[-2+yyTop])); } -void case_612() -#line 4236 "cs-parser.jay" +void case_617() +#line 4285 "cs-parser.jay" { valid_param_mod = 0; start_anonymous (true, (ParametersCompiled) yyVals[-2+yyTop], false, GetLocation (yyVals[-4+yyTop])); } -void case_613() -#line 4241 "cs-parser.jay" +void case_618() +#line 4290 "cs-parser.jay" { yyVal = end_anonymous ((ParametersBlock) yyVals[0+yyTop]); lbag.AddLocation (yyVal, GetLocation (yyVals[-6+yyTop]), GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[-2+yyTop])); } -void case_615() -#line 4250 "cs-parser.jay" +void case_620() +#line 4299 "cs-parser.jay" { valid_param_mod = 0; start_anonymous (true, (ParametersCompiled) yyVals[-2+yyTop], true, GetLocation (yyVals[-5+yyTop])); } -void case_616() -#line 4255 "cs-parser.jay" +void case_621() +#line 4304 "cs-parser.jay" { yyVal = end_anonymous ((ParametersBlock) yyVals[0+yyTop]); lbag.AddLocation (yyVal, GetLocation (yyVals[-7+yyTop]), GetLocation (yyVals[-6+yyTop]), GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[-2+yyTop])); } -void case_623() -#line 4278 "cs-parser.jay" +void case_628() +#line 4327 "cs-parser.jay" { yyVal = new RefValueExpr ((Expression) yyVals[-3+yyTop], (FullNamedExpression) yyVals[-1+yyTop], GetLocation (yyVals[-5+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[-4+yyTop]), GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_624() -#line 4283 "cs-parser.jay" +void case_629() +#line 4332 "cs-parser.jay" { yyVal = new RefTypeExpr ((Expression) yyVals[-1+yyTop], GetLocation (yyVals[-3+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_625() -#line 4288 "cs-parser.jay" +void case_630() +#line 4337 "cs-parser.jay" { yyVal = new MakeRefExpr ((Expression) yyVals[-1+yyTop], GetLocation (yyVals[-3+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_629() -#line 4317 "cs-parser.jay" +void case_634() +#line 4366 "cs-parser.jay" { - MemberName name = MakeName ((MemberName) yyVals[0+yyTop]); - Class c = new Class (current_namespace, current_class, name, (Modifiers) yyVals[-4+yyTop], (Attributes) yyVals[-5+yyTop]); + Class c = new Class (current_container, (MemberName) yyVals[0+yyTop], (Modifiers) yyVals[-4+yyTop], (Attributes) yyVals[-5+yyTop]); if (((c.ModFlags & Modifiers.STATIC) != 0) && lang_version == LanguageVersion.ISO_1) { FeatureIsNotAvailable (c.Location, "static classes"); } - - push_current_class (c, yyVals[-3+yyTop]); + + push_current_container (c, yyVals[-3+yyTop]); + lbag.AddMember (current_container, GetModifierLocations (), GetLocation (yyVals[-2+yyTop])); } -void case_630() -#line 4328 "cs-parser.jay" +void case_635() +#line 4377 "cs-parser.jay" { lexer.ConstraintsParsing = false; if (yyVals[0+yyTop] != null) - current_class.SetConstraints ((List) yyVals[0+yyTop]); - lbag.AddMember (current_class, GetModifierLocations (), GetLocation (yyVals[-5+yyTop])); + current_container.SetConstraints ((List) yyVals[0+yyTop]); if (doc_support) { - current_container.DocComment = Lexer.consume_doc_comment (); + current_container.PartialContainer.DocComment = Lexer.consume_doc_comment (); Lexer.doc_state = XmlCommentState.Allowed; } lexer.parsing_modifiers = true; } -void case_631() -#line 4343 "cs-parser.jay" +void case_636() +#line 4391 "cs-parser.jay" { --lexer.parsing_declaration; if (doc_support) Lexer.doc_state = XmlCommentState.Allowed; } -void case_632() -#line 4349 "cs-parser.jay" +void case_637() +#line 4397 "cs-parser.jay" { - lbag.AppendToMember (current_class, GetLocation (yyVals[-4+yyTop]), GetLocation (yyVals[-2+yyTop])); - if (yyVals[0+yyTop] != null) - current_class.OptionalSemicolon = GetLocation (yyVals[0+yyTop]); + if (yyVals[0+yyTop] == null) { + lbag.AppendToMember (current_container, GetLocation (yyVals[-4+yyTop]), GetLocation (yyVals[-2+yyTop])); + } else { + lbag.AppendToMember (current_container, GetLocation (yyVals[-4+yyTop]), GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); + } yyVal = pop_current_class (); } -void case_635() -#line 4366 "cs-parser.jay" +void case_640() +#line 4416 "cs-parser.jay" { mod_locations = null; yyVal = ModifierNone; lexer.parsing_modifiers = false; } -void case_638() -#line 4380 "cs-parser.jay" +void case_643() +#line 4430 "cs-parser.jay" { var m1 = (Modifiers) yyVals[-1+yyTop]; var m2 = (Modifiers) yyVals[0+yyTop]; @@ -7253,102 +7373,102 @@ void case_638() yyVal = m1 | m2; } -void case_639() -#line 4399 "cs-parser.jay" +void case_644() +#line 4449 "cs-parser.jay" { yyVal = Modifiers.NEW; StoreModifierLocation (yyVal, GetLocation (yyVals[0+yyTop])); - if (current_container == module) + if (current_container.Kind == MemberKind.Namespace) report.Error (1530, GetLocation (yyVals[0+yyTop]), "Keyword `new' is not allowed on namespace elements"); } -void case_640() -#line 4407 "cs-parser.jay" +void case_645() +#line 4457 "cs-parser.jay" { yyVal = Modifiers.PUBLIC; StoreModifierLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_641() -#line 4412 "cs-parser.jay" +void case_646() +#line 4462 "cs-parser.jay" { yyVal = Modifiers.PROTECTED; StoreModifierLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_642() -#line 4417 "cs-parser.jay" +void case_647() +#line 4467 "cs-parser.jay" { yyVal = Modifiers.INTERNAL; StoreModifierLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_643() -#line 4422 "cs-parser.jay" +void case_648() +#line 4472 "cs-parser.jay" { yyVal = Modifiers.PRIVATE; StoreModifierLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_644() -#line 4427 "cs-parser.jay" +void case_649() +#line 4477 "cs-parser.jay" { yyVal = Modifiers.ABSTRACT; StoreModifierLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_645() -#line 4432 "cs-parser.jay" +void case_650() +#line 4482 "cs-parser.jay" { yyVal = Modifiers.SEALED; StoreModifierLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_646() -#line 4437 "cs-parser.jay" +void case_651() +#line 4487 "cs-parser.jay" { yyVal = Modifiers.STATIC; StoreModifierLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_647() -#line 4442 "cs-parser.jay" +void case_652() +#line 4492 "cs-parser.jay" { yyVal = Modifiers.READONLY; StoreModifierLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_648() -#line 4447 "cs-parser.jay" +void case_653() +#line 4497 "cs-parser.jay" { yyVal = Modifiers.VIRTUAL; StoreModifierLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_649() -#line 4452 "cs-parser.jay" +void case_654() +#line 4502 "cs-parser.jay" { yyVal = Modifiers.OVERRIDE; StoreModifierLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_650() -#line 4457 "cs-parser.jay" +void case_655() +#line 4507 "cs-parser.jay" { yyVal = Modifiers.EXTERN; StoreModifierLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_651() -#line 4462 "cs-parser.jay" +void case_656() +#line 4512 "cs-parser.jay" { yyVal = Modifiers.VOLATILE; StoreModifierLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_652() -#line 4467 "cs-parser.jay" +void case_657() +#line 4517 "cs-parser.jay" { yyVal = Modifiers.UNSAFE; StoreModifierLocation (yyVal, GetLocation (yyVals[0+yyTop])); @@ -7356,37 +7476,38 @@ void case_652() Error_UnsafeCodeNotAllowed (GetLocation (yyVals[0+yyTop])); } -void case_653() -#line 4474 "cs-parser.jay" +void case_658() +#line 4524 "cs-parser.jay" { yyVal = Modifiers.ASYNC; StoreModifierLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_655() -#line 4483 "cs-parser.jay" +void case_660() +#line 4533 "cs-parser.jay" { - lbag.AppendToMember (current_class, GetLocation (yyVals[-1+yyTop])); - current_container.AddBasesForPart (current_class, (List) yyVals[0+yyTop]); + current_type.AddBasesForPart ((List) yyVals[0+yyTop]); + lbag.AppendToMember (current_type, GetLocation (yyVals[-1+yyTop])); } -void case_658() -#line 4496 "cs-parser.jay" +void case_661() +#line 4538 "cs-parser.jay" { Error_SyntaxError (yyToken); - yyVal = null; - } -void case_659() -#line 4504 "cs-parser.jay" + current_type.AddBasesForPart ((List) yyVals[-1+yyTop]); + } + +void case_664() +#line 4555 "cs-parser.jay" { var constraints = new List (1); constraints.Add ((Constraints) yyVals[0+yyTop]); yyVal = constraints; } -void case_660() -#line 4510 "cs-parser.jay" +void case_665() +#line 4561 "cs-parser.jay" { var constraints = (List) yyVals[-1+yyTop]; Constraints new_constraint = (Constraints)yyVals[0+yyTop]; @@ -7403,24 +7524,33 @@ void case_660() yyVal = constraints; } -void case_661() -#line 4529 "cs-parser.jay" +void case_666() +#line 4580 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; yyVal = new Constraints (new SimpleMemberName (lt.Value, lt.Location), (List) yyVals[0+yyTop], GetLocation (yyVals[-3+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[-1+yyTop])); } -void case_662() -#line 4538 "cs-parser.jay" +void case_667() +#line 4586 "cs-parser.jay" +{ + Error_SyntaxError (yyToken); + + var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; + yyVal = new Constraints (new SimpleMemberName (lt.Value, lt.Location), null, GetLocation (yyVals[-2+yyTop])); + } + +void case_668() +#line 4596 "cs-parser.jay" { var constraints = new List (1); constraints.Add ((FullNamedExpression) yyVals[0+yyTop]); yyVal = constraints; } -void case_663() -#line 4544 "cs-parser.jay" +void case_669() +#line 4602 "cs-parser.jay" { var constraints = (List) yyVals[-2+yyTop]; var prev = constraints [constraints.Count - 1] as SpecialContraintExpr; @@ -7445,8 +7575,8 @@ void case_663() yyVal = constraints; } -void case_664() -#line 4571 "cs-parser.jay" +void case_670() +#line 4629 "cs-parser.jay" { if (yyVals[0+yyTop] is ComposedCast) report.Error (706, GetLocation (yyVals[0+yyTop]), "Invalid constraint type `{0}'", ((ComposedCast)yyVals[0+yyTop]).GetSignatureForError ()); @@ -7454,15 +7584,15 @@ void case_664() yyVal = yyVals[0+yyTop]; } -void case_665() -#line 4578 "cs-parser.jay" +void case_671() +#line 4636 "cs-parser.jay" { yyVal = new SpecialContraintExpr (SpecialConstraint.Constructor, GetLocation (yyVals[-2+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[-1+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_669() -#line 4598 "cs-parser.jay" +void case_675() +#line 4656 "cs-parser.jay" { if (lang_version <= LanguageVersion.V_3) FeatureIsNotAvailable (lexer.Location, "generic type variance"); @@ -7470,57 +7600,65 @@ void case_669() yyVal = yyVals[0+yyTop]; } -void case_670() -#line 4608 "cs-parser.jay" +void case_676() +#line 4666 "cs-parser.jay" { yyVal = Variance.Covariant; savedLocation = GetLocation (yyVals[0+yyTop]); } -void case_671() -#line 4613 "cs-parser.jay" +void case_677() +#line 4671 "cs-parser.jay" { yyVal = Variance.Contravariant; savedLocation = GetLocation (yyVals[0+yyTop]); } -void case_672() -#line 4634 "cs-parser.jay" +void case_678() +#line 4692 "cs-parser.jay" { ++lexer.parsing_block; start_block (GetLocation (yyVals[0+yyTop])); } -void case_674() -#line 4646 "cs-parser.jay" +void case_680() +#line 4704 "cs-parser.jay" { --lexer.parsing_block; yyVal = end_block (GetLocation (yyVals[0+yyTop])); } -void case_675() -#line 4651 "cs-parser.jay" +void case_681() +#line 4709 "cs-parser.jay" { --lexer.parsing_block; yyVal = end_block (lexer.Location); } -void case_676() -#line 4660 "cs-parser.jay" +void case_682() +#line 4718 "cs-parser.jay" { ++lexer.parsing_block; current_block.StartLocation = GetLocation (yyVals[0+yyTop]); } -void case_677() -#line 4665 "cs-parser.jay" +void case_683() +#line 4723 "cs-parser.jay" { --lexer.parsing_block; yyVal = end_block (GetLocation (yyVals[0+yyTop])); } -void case_685() -#line 4693 "cs-parser.jay" +void case_684() +#line 4727 "cs-parser.jay" +{ + report.Error (1525, GetLocation (yyVals[0+yyTop]), "Unexpected symbol '}', expected '{'"); + lexer.putback ('}'); + yyVal = end_block (GetLocation (yyVals[0+yyTop])); + } + +void case_692() +#line 4756 "cs-parser.jay" { Error_SyntaxError (yyToken); var lt =(Tokenizer.LocatedToken) yyVals[-1+yyTop]; @@ -7529,43 +7667,43 @@ void case_685() yyVal = null; } -void case_686() -#line 4702 "cs-parser.jay" +void case_693() +#line 4765 "cs-parser.jay" { Error_SyntaxError (yyToken); yyVal = null; } -void case_719() -#line 4766 "cs-parser.jay" +void case_726() +#line 4829 "cs-parser.jay" { report.Error (1023, GetLocation (yyVals[0+yyTop]), "An embedded statement may not be a declaration or labeled statement"); yyVal = null; } -void case_720() -#line 4771 "cs-parser.jay" +void case_727() +#line 4834 "cs-parser.jay" { report.Error (1023, GetLocation (yyVals[0+yyTop]), "An embedded statement may not be a declaration or labeled statement"); yyVal = null; } -void case_721() -#line 4776 "cs-parser.jay" +void case_728() +#line 4839 "cs-parser.jay" { Error_SyntaxError (yyToken); yyVal = new EmptyStatement (GetLocation (yyVals[0+yyTop])); } -void case_722() -#line 4784 "cs-parser.jay" +void case_729() +#line 4847 "cs-parser.jay" { /* Uses lexer.Location because semicolon location is not kept in quick mode*/ yyVal = new EmptyStatement (lexer.Location); } -void case_723() -#line 4792 "cs-parser.jay" +void case_730() +#line 4855 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; LabeledStatement labeled = new LabeledStatement (lt.Value, current_block, lt.Location); @@ -7574,8 +7712,8 @@ void case_723() current_block.AddStatement (labeled); } -void case_726() -#line 4805 "cs-parser.jay" +void case_733() +#line 4868 "cs-parser.jay" { if (yyVals[-1+yyTop] is VarExpr) yyVals[-1+yyTop] = new SimpleName ("var", ((VarExpr) yyVals[-1+yyTop]).Location); @@ -7583,8 +7721,8 @@ void case_726() yyVal = new ComposedCast ((FullNamedExpression) yyVals[-1+yyTop], (ComposedTypeSpecifier) yyVals[0+yyTop]); } -void case_727() -#line 4821 "cs-parser.jay" +void case_734() +#line 4884 "cs-parser.jay" { /* Ok, the above "primary_expression" is there to get rid of*/ /* both reduce/reduce and shift/reduces in the grammar, it should*/ @@ -7615,8 +7753,8 @@ void case_727() } } -void case_728() -#line 4851 "cs-parser.jay" +void case_735() +#line 4914 "cs-parser.jay" { ATypeNameExpression expr = yyVals[-1+yyTop] as ATypeNameExpression; @@ -7628,8 +7766,8 @@ void case_728() } } -void case_729() -#line 4862 "cs-parser.jay" +void case_736() +#line 4925 "cs-parser.jay" { if (yyVals[0+yyTop] == null) yyVal = yyVals[-1+yyTop]; @@ -7637,22 +7775,22 @@ void case_729() yyVal = new ComposedCast ((FullNamedExpression) yyVals[-1+yyTop], (ComposedTypeSpecifier) yyVals[0+yyTop]); } -void case_732() -#line 4877 "cs-parser.jay" +void case_739() +#line 4940 "cs-parser.jay" { Expression.Error_VoidInvalidInTheContext (GetLocation (yyVals[0+yyTop]), report); yyVal = new TypeExpression (compiler.BuiltinTypes.Void, GetLocation (yyVals[0+yyTop])); } -void case_734() -#line 4886 "cs-parser.jay" +void case_741() +#line 4949 "cs-parser.jay" { ((ComposedTypeSpecifier) yyVals[-1+yyTop]).Next = (ComposedTypeSpecifier) yyVals[0+yyTop]; yyVal = yyVals[-1+yyTop]; } -void case_737() -#line 4902 "cs-parser.jay" +void case_744() +#line 4965 "cs-parser.jay" { if (async_block) { report.Error (4003, GetLocation (yyVals[0+yyTop]), "`await' cannot be used as an identifier within an async method or lambda expression"); @@ -7660,8 +7798,8 @@ void case_737() } } -void case_738() -#line 4912 "cs-parser.jay" +void case_745() +#line 4975 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; var li = new LocalVariable (current_block, lt.Value, lt.Location); @@ -7669,16 +7807,16 @@ void case_738() current_variable = new BlockVariableDeclaration ((FullNamedExpression) yyVals[-1+yyTop], li); } -void case_739() -#line 4919 "cs-parser.jay" +void case_746() +#line 4982 "cs-parser.jay" { yyVal = current_variable; current_variable = null; lbag.AppendTo (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_740() -#line 4925 "cs-parser.jay" +void case_747() +#line 4988 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; var li = new LocalVariable (current_block, lt.Value, LocalVariable.Flags.Constant, lt.Location); @@ -7686,8 +7824,8 @@ void case_740() current_variable = new BlockConstantDeclaration ((FullNamedExpression) yyVals[-1+yyTop], li); } -void case_741() -#line 4932 "cs-parser.jay" +void case_748() +#line 4995 "cs-parser.jay" { if (current_variable.Initializer != null) { lbag.AddLocation (current_variable, GetLocation (yyVals[-6+yyTop]), savedLocation, GetLocation (yyVals[0+yyTop])); @@ -7698,15 +7836,24 @@ void case_741() current_variable = null; } -void case_743() -#line 4946 "cs-parser.jay" +void case_750() +#line 5008 "cs-parser.jay" +{ + /* Redundant, but wont regress*/ + report.Error (1525, lexer.Location, "Unexpected symbol }"); + lexer.putback ('}'); + yyVal = yyVals[0+yyTop]; + } + +void case_752() +#line 5019 "cs-parser.jay" { current_variable.Initializer = (Expression) yyVals[0+yyTop]; lbag.AppendTo (current_variable, GetLocation (yyVals[-1+yyTop])); } -void case_744() -#line 4951 "cs-parser.jay" +void case_753() +#line 5024 "cs-parser.jay" { if (yyToken == Token.OPEN_BRACKET_EXPR) { report.Error (650, lexer.Location, @@ -7721,8 +7868,8 @@ void case_744() lbag.AppendTo (current_variable, GetLocation (yyVals[-1+yyTop])); } -void case_745() -#line 4965 "cs-parser.jay" +void case_754() +#line 5038 "cs-parser.jay" { if (yyToken == Token.OPEN_BRACKET_EXPR) { report.Error (650, lexer.Location, @@ -7732,8 +7879,8 @@ void case_745() } } -void case_749() -#line 4983 "cs-parser.jay" +void case_758() +#line 5056 "cs-parser.jay" { foreach (var d in current_variable.Declarators) { if (d.Initializer == null) @@ -7741,8 +7888,8 @@ void case_749() } } -void case_752() -#line 4998 "cs-parser.jay" +void case_761() +#line 5071 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; var li = new LocalVariable (current_variable.Variable, lt.Value, lt.Location); @@ -7752,8 +7899,8 @@ void case_752() lbag.AddLocation (d, GetLocation (yyVals[-1+yyTop])); } -void case_753() -#line 5007 "cs-parser.jay" +void case_762() +#line 5080 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; var li = new LocalVariable (current_variable.Variable, lt.Value, lt.Location); @@ -7763,15 +7910,15 @@ void case_753() lbag.AddLocation (d, GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[-1+yyTop])); } -void case_755() -#line 5023 "cs-parser.jay" +void case_764() +#line 5096 "cs-parser.jay" { savedLocation = GetLocation (yyVals[-1+yyTop]); current_variable.Initializer = (Expression) yyVals[0+yyTop]; } -void case_760() -#line 5041 "cs-parser.jay" +void case_769() +#line 5114 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; var li = new LocalVariable (current_block, lt.Value, LocalVariable.Flags.Constant, lt.Location); @@ -7781,29 +7928,37 @@ void case_760() lbag.AddLocation (d, GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[-1+yyTop])); } -void case_762() -#line 5054 "cs-parser.jay" +void case_771() +#line 5127 "cs-parser.jay" { yyVal = new StackAlloc ((Expression) yyVals[-3+yyTop], (Expression) yyVals[-1+yyTop], GetLocation (yyVals[-4+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_763() -#line 5059 "cs-parser.jay" +void case_772() +#line 5132 "cs-parser.jay" { report.Error (1575, GetLocation (yyVals[-1+yyTop]), "A stackalloc expression requires [] after type"); yyVal = new StackAlloc ((Expression) yyVals[0+yyTop], null, GetLocation (yyVals[-1+yyTop])); } -void case_764() -#line 5067 "cs-parser.jay" +void case_773() +#line 5140 "cs-parser.jay" { yyVal = yyVals[-1+yyTop]; lbag.AddStatement (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_768() -#line 5085 "cs-parser.jay" +void case_775() +#line 5146 "cs-parser.jay" +{ + yyVal = yyVals[-1+yyTop]; + report.Error (1002, GetLocation (yyVals[0+yyTop]), "; expected"); + lexer.putback ('}'); + } + +void case_778() +#line 5164 "cs-parser.jay" { ExpressionStatement s = yyVals[0+yyTop] as ExpressionStatement; if (s == null) { @@ -7814,8 +7969,8 @@ void case_768() } } -void case_769() -#line 5098 "cs-parser.jay" +void case_779() +#line 5177 "cs-parser.jay" { Expression expr = (Expression) yyVals[0+yyTop]; ExpressionStatement s; @@ -7824,15 +7979,15 @@ void case_769() yyVal = new StatementExpression (s); } -void case_770() -#line 5106 "cs-parser.jay" +void case_780() +#line 5185 "cs-parser.jay" { Error_SyntaxError (yyToken); yyVal = new EmptyStatement (GetLocation (yyVals[0+yyTop])); } -void case_773() -#line 5120 "cs-parser.jay" +void case_783() +#line 5199 "cs-parser.jay" { if (yyVals[0+yyTop] is EmptyStatement) Warning_EmptyStatement (GetLocation (yyVals[0+yyTop])); @@ -7841,8 +7996,8 @@ void case_773() lbag.AddStatement (yyVal, GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[-1+yyTop])); } -void case_774() -#line 5129 "cs-parser.jay" +void case_784() +#line 5208 "cs-parser.jay" { yyVal = new If ((BooleanExpression) yyVals[-4+yyTop], (Statement) yyVals[-2+yyTop], (Statement) yyVals[0+yyTop], GetLocation (yyVals[-6+yyTop])); lbag.AddStatement (yyVal, GetLocation (yyVals[-5+yyTop]), GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[-1+yyTop])); @@ -7853,8 +8008,8 @@ void case_774() Warning_EmptyStatement (GetLocation (yyVals[0+yyTop])); } -void case_775() -#line 5139 "cs-parser.jay" +void case_785() +#line 5218 "cs-parser.jay" { Error_SyntaxError (yyToken); @@ -7862,16 +8017,16 @@ void case_775() lbag.AddStatement (yyVal, GetLocation (yyVals[-2+yyTop])); } -void case_777() -#line 5153 "cs-parser.jay" +void case_787() +#line 5232 "cs-parser.jay" { yyVal = new Switch ((Expression) yyVals[-5+yyTop], (ExplicitBlock) current_block.Explicit, (List) yyVals[-1+yyTop], GetLocation (yyVals[-7+yyTop])); end_block (GetLocation (yyVals[0+yyTop])); lbag.AddStatement (yyVal, GetLocation (yyVals[-6+yyTop]), GetLocation (yyVals[-4+yyTop]), GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_778() -#line 5159 "cs-parser.jay" +void case_788() +#line 5238 "cs-parser.jay" { Error_SyntaxError (yyToken); @@ -7879,15 +8034,15 @@ void case_778() lbag.AddStatement (yyVal, GetLocation (yyVals[-2+yyTop])); } -void case_779() -#line 5169 "cs-parser.jay" +void case_789() +#line 5248 "cs-parser.jay" { report.Warning (1522, 1, current_block.StartLocation, "Empty switch block"); yyVal = new List (); } -void case_781() -#line 5178 "cs-parser.jay" +void case_791() +#line 5257 "cs-parser.jay" { var sections = new List (4); @@ -7895,8 +8050,8 @@ void case_781() yyVal = sections; } -void case_782() -#line 5185 "cs-parser.jay" +void case_792() +#line 5264 "cs-parser.jay" { var sections = (List) yyVals[-1+yyTop]; @@ -7904,15 +8059,15 @@ void case_782() yyVal = sections; } -void case_783() -#line 5192 "cs-parser.jay" +void case_793() +#line 5271 "cs-parser.jay" { Error_SyntaxError (yyToken); yyVal = new List (); } -void case_786() -#line 5211 "cs-parser.jay" +void case_796() +#line 5290 "cs-parser.jay" { var labels = new List (2); @@ -7920,8 +8075,8 @@ void case_786() yyVal = labels; } -void case_787() -#line 5218 "cs-parser.jay" +void case_797() +#line 5297 "cs-parser.jay" { var labels = (List) (yyVals[-1+yyTop]); labels.Add ((SwitchLabel) yyVals[0+yyTop]); @@ -7929,15 +8084,22 @@ void case_787() yyVal = labels; } -void case_788() -#line 5228 "cs-parser.jay" +void case_798() +#line 5307 "cs-parser.jay" { yyVal = new SwitchLabel ((Expression) yyVals[-1+yyTop], GetLocation (yyVals[-2+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_794() -#line 5247 "cs-parser.jay" +void case_799() +#line 5312 "cs-parser.jay" +{ + Error_SyntaxError (yyToken); + yyVal = new SwitchLabel ((Expression) yyVals[-1+yyTop], GetLocation (yyVals[-2+yyTop])); + } + +void case_805() +#line 5331 "cs-parser.jay" { if (yyVals[0+yyTop] is EmptyStatement && lexer.peek_token () == Token.OPEN_BRACE) Warning_EmptyStatement (GetLocation (yyVals[0+yyTop])); @@ -7946,8 +8108,8 @@ void case_794() lbag.AddStatement (yyVal, GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[-1+yyTop])); } -void case_795() -#line 5255 "cs-parser.jay" +void case_806() +#line 5339 "cs-parser.jay" { Error_SyntaxError (yyToken); @@ -7955,22 +8117,22 @@ void case_795() lbag.AddStatement (yyVal, GetLocation (yyVals[-2+yyTop])); } -void case_796() -#line 5265 "cs-parser.jay" +void case_807() +#line 5349 "cs-parser.jay" { yyVal = new Do ((Statement) yyVals[-5+yyTop], (BooleanExpression) yyVals[-2+yyTop], GetLocation (yyVals[-6+yyTop])); lbag.AddStatement (yyVal, GetLocation (yyVals[-4+yyTop]), GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[-1+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_797() -#line 5270 "cs-parser.jay" +void case_808() +#line 5354 "cs-parser.jay" { Error_SyntaxError (yyToken); yyVal = new Do ((Statement) yyVals[-1+yyTop], null, GetLocation (yyVals[-2+yyTop])); } -void case_798() -#line 5275 "cs-parser.jay" +void case_809() +#line 5359 "cs-parser.jay" { Error_SyntaxError (yyToken); @@ -7978,38 +8140,79 @@ void case_798() lbag.AddStatement (yyVal, GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[-2+yyTop])); } -void case_799() -#line 5285 "cs-parser.jay" +void case_810() +#line 5369 "cs-parser.jay" { start_block (GetLocation (yyVals[0+yyTop])); current_block.IsCompilerGenerated = true; For f = new For (GetLocation (yyVals[-1+yyTop])); current_block.AddStatement (f); + lbag.AddStatement (f, current_block.StartLocation); + yyVal = f; + } + +void case_812() +#line 5386 "cs-parser.jay" +{ + For f = (For) yyVals[-2+yyTop]; + f.Initializer = (Statement) yyVals[-1+yyTop]; + lbag.AppendTo (f, GetLocation (yyVals[0+yyTop])); + yyVal = f; + } + +void case_814() +#line 5396 "cs-parser.jay" +{ + report.Error (1525, GetLocation (yyVals[0+yyTop]), "Unexpected symbol ')', expected ';'"); + For f = (For) yyVals[-2+yyTop]; + f.Initializer = (Statement) yyVals[-1+yyTop]; + lbag.AppendTo (f, GetLocation (yyVals[0+yyTop])); + yyVal = end_block (GetLocation (yyVals[0+yyTop])); + } + +void case_815() +#line 5407 "cs-parser.jay" +{ + For f = (For) yyVals[-2+yyTop]; + f.Condition = (BooleanExpression) yyVals[-1+yyTop]; + lbag.AppendTo (f, GetLocation (yyVals[0+yyTop])); yyVal = f; } -void case_804() -#line 5313 "cs-parser.jay" +void case_817() +#line 5417 "cs-parser.jay" +{ + report.Error (1525, GetLocation (yyVals[0+yyTop]), "Unexpected symbol ')', expected ';'"); + For f = (For) yyVals[-2+yyTop]; + f.Condition = (BooleanExpression) yyVals[-1+yyTop]; + lbag.AppendTo (f, GetLocation (yyVals[0+yyTop])); + yyVal = end_block (GetLocation (yyVals[0+yyTop])); + } + +void case_818() +#line 5429 "cs-parser.jay" { + For f = (For) yyVals[-3+yyTop]; + f.Iterator = (Statement) yyVals[-2+yyTop]; + if (yyVals[0+yyTop] is EmptyStatement && lexer.peek_token () == Token.OPEN_BRACE) Warning_EmptyStatement (GetLocation (yyVals[0+yyTop])); - For f = ((For) yyVals[-10+yyTop]); f.Statement = (Statement) yyVals[0+yyTop]; - lbag.AddStatement (f, current_block.StartLocation, GetLocation (yyVals[-8+yyTop]), GetLocation (yyVals[-5+yyTop]), GetLocation (yyVals[-2+yyTop])); + lbag.AppendTo (f, GetLocation (yyVals[-1+yyTop])); - yyVal = end_block (GetLocation (yyVals[-8+yyTop])); + yyVal = end_block (GetLocation (yyVals[-1+yyTop])); } -void case_805() -#line 5324 "cs-parser.jay" +void case_819() +#line 5442 "cs-parser.jay" { Error_SyntaxError (yyToken); yyVal = end_block (current_block.StartLocation); } -void case_808() -#line 5337 "cs-parser.jay" +void case_822() +#line 5455 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[0+yyTop]; var li = new LocalVariable (current_block, lt.Value, lt.Location); @@ -8017,15 +8220,15 @@ void case_808() current_variable = new BlockVariableDeclaration ((FullNamedExpression) yyVals[-1+yyTop], li); } -void case_809() -#line 5344 "cs-parser.jay" +void case_823() +#line 5462 "cs-parser.jay" { yyVal = current_variable; current_variable = null; } -void case_817() -#line 5368 "cs-parser.jay" +void case_831() +#line 5486 "cs-parser.jay" { var sl = yyVals[-2+yyTop] as StatementList; if (sl == null) { @@ -8034,31 +8237,32 @@ void case_817() } else { sl.Add ((Statement) yyVals[0+yyTop]); lbag.AppendTo (sl, GetLocation (yyVals[-1+yyTop])); + } yyVal = sl; } -void case_818() -#line 5384 "cs-parser.jay" +void case_832() +#line 5503 "cs-parser.jay" { report.Error (230, GetLocation (yyVals[-3+yyTop]), "Type and identifier are both required in a foreach statement"); start_block (GetLocation (yyVals[-2+yyTop])); current_block.IsCompilerGenerated = true; - Foreach f = new Foreach ((Expression) yyVals[-1+yyTop], null, null, null, GetLocation (yyVals[-3+yyTop])); + Foreach f = new Foreach ((Expression) yyVals[-1+yyTop], null, null, null, null, GetLocation (yyVals[-3+yyTop])); current_block.AddStatement (f); lbag.AddStatement (f, GetLocation (yyVals[-2+yyTop])); yyVal = end_block (GetLocation (yyVals[0+yyTop])); } -void case_819() -#line 5397 "cs-parser.jay" +void case_833() +#line 5516 "cs-parser.jay" { Error_SyntaxError (yyToken); - + start_block (GetLocation (yyVals[-3+yyTop])); current_block.IsCompilerGenerated = true; @@ -8066,15 +8270,15 @@ void case_819() var li = new LocalVariable (current_block, lt.Value, LocalVariable.Flags.ForeachVariable | LocalVariable.Flags.Used, lt.Location); current_block.AddLocalName (li); - Foreach f = new Foreach ((Expression) yyVals[-2+yyTop], li, null, null, GetLocation (yyVals[-4+yyTop])); + Foreach f = new Foreach ((Expression) yyVals[-2+yyTop], li, null, null, null, GetLocation (yyVals[-4+yyTop])); current_block.AddStatement (f); lbag.AddStatement (f, GetLocation (yyVals[-3+yyTop])); yyVal = end_block (GetLocation (yyVals[0+yyTop])); } -void case_820() -#line 5414 "cs-parser.jay" +void case_834() +#line 5533 "cs-parser.jay" { start_block (GetLocation (yyVals[-5+yyTop])); current_block.IsCompilerGenerated = true; @@ -8084,96 +8288,117 @@ void case_820() yyVal = li; } -void case_821() -#line 5423 "cs-parser.jay" +void case_835() +#line 5542 "cs-parser.jay" { if (yyVals[0+yyTop] is EmptyStatement && lexer.peek_token () == Token.OPEN_BRACE) Warning_EmptyStatement (GetLocation (yyVals[0+yyTop])); - - Foreach f = new Foreach ((Expression) yyVals[-6+yyTop], (LocalVariable) yyVals[-1+yyTop], (Expression) yyVals[-3+yyTop], (Statement) yyVals[0+yyTop], GetLocation (yyVals[-8+yyTop])); - current_block.AddStatement (f); + Foreach f = new Foreach ((Expression) yyVals[-6+yyTop], (LocalVariable) yyVals[-1+yyTop], (Expression) yyVals[-3+yyTop], (Statement) yyVals[0+yyTop], current_block, GetLocation (yyVals[-8+yyTop])); lbag.AddStatement (f, GetLocation (yyVals[-7+yyTop]), GetLocation (yyVals[-4+yyTop]), GetLocation (yyVals[-2+yyTop])); - yyVal = end_block (GetLocation (yyVals[-2+yyTop])); + end_block (GetLocation (yyVals[-2+yyTop])); + + yyVal = f; } -void case_822() -#line 5434 "cs-parser.jay" +void case_836() +#line 5553 "cs-parser.jay" { start_block (GetLocation (yyVals[-3+yyTop])); current_block.IsCompilerGenerated = true; var lt = yyVals[-1+yyTop] as Tokenizer.LocatedToken; var li = lt != null ? new LocalVariable (current_block, lt.Value, LocalVariable.Flags.ForeachVariable | LocalVariable.Flags.Used, lt.Location) : null; - Foreach f = new Foreach ((Expression) yyVals[-2+yyTop], li, null, null, GetLocation (yyVals[-4+yyTop])); + Foreach f = new Foreach ((Expression) yyVals[-2+yyTop], li, null, null, null, GetLocation (yyVals[-4+yyTop])); current_block.AddStatement (f); lbag.AddStatement (f, GetLocation (yyVals[-3+yyTop])); yyVal = end_block (GetLocation (yyVals[0+yyTop])); } -void case_823() -#line 5447 "cs-parser.jay" +void case_837() +#line 5566 "cs-parser.jay" { - Foreach f = new Foreach ((Expression) yyVals[-1+yyTop], null, null, null, GetLocation (yyVals[-3+yyTop])); + Foreach f = new Foreach ((Expression) yyVals[-1+yyTop], null, null, null, null, GetLocation (yyVals[-3+yyTop])); current_block.AddStatement (f); lbag.AddStatement (f, GetLocation (yyVals[-2+yyTop])); yyVal = f; } -void case_830() -#line 5467 "cs-parser.jay" +void case_844() +#line 5586 "cs-parser.jay" { yyVal = new Break (GetLocation (yyVals[-1+yyTop])); lbag.AddStatement (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_831() -#line 5475 "cs-parser.jay" +void case_845() +#line 5594 "cs-parser.jay" { yyVal = new Continue (GetLocation (yyVals[-1+yyTop])); lbag.AddStatement (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_832() -#line 5483 "cs-parser.jay" +void case_846() +#line 5599 "cs-parser.jay" +{ + Error_SyntaxError (yyToken); + yyVal = new Continue (GetLocation (yyVals[-1+yyTop])); + } + +void case_847() +#line 5607 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-1+yyTop]; yyVal = new Goto (lt.Value, GetLocation (yyVals[-2+yyTop])); lbag.AddStatement (yyVal, GetLocation (yyVals[-1+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_833() -#line 5489 "cs-parser.jay" +void case_848() +#line 5613 "cs-parser.jay" { yyVal = new GotoCase ((Expression) yyVals[-1+yyTop], GetLocation (yyVals[-3+yyTop])); lbag.AddStatement (yyVal, GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_834() -#line 5494 "cs-parser.jay" +void case_849() +#line 5618 "cs-parser.jay" { yyVal = new GotoDefault (GetLocation (yyVals[-2+yyTop])); lbag.AddStatement (yyVal, GetLocation (yyVals[-1+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_835() -#line 5502 "cs-parser.jay" +void case_850() +#line 5626 "cs-parser.jay" { yyVal = new Return ((Expression) yyVals[-1+yyTop], GetLocation (yyVals[-2+yyTop])); lbag.AddStatement (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_836() -#line 5510 "cs-parser.jay" +void case_851() +#line 5631 "cs-parser.jay" +{ + Error_SyntaxError (yyToken); + yyVal = new Return (null, GetLocation (yyVals[-1+yyTop])); + } + +void case_852() +#line 5639 "cs-parser.jay" { yyVal = new Throw ((Expression) yyVals[-1+yyTop], GetLocation (yyVals[-2+yyTop])); lbag.AddStatement (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_837() -#line 5518 "cs-parser.jay" +void case_853() +#line 5644 "cs-parser.jay" +{ + Error_SyntaxError (yyToken); + yyVal = new Throw (null, GetLocation (yyVals[-1+yyTop])); + } + +void case_854() +#line 5652 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-3+yyTop]; string s = lt.Value; @@ -8190,8 +8415,8 @@ void case_837() lbag.AddStatement (yyVal, GetLocation (yyVals[-2+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_838() -#line 5534 "cs-parser.jay" +void case_855() +#line 5668 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; string s = lt.Value; @@ -8206,29 +8431,30 @@ void case_838() lbag.AddStatement (yyVal, GetLocation (yyVals[-1+yyTop]), GetLocation (yyVals[0+yyTop])); } -void case_842() -#line 5560 "cs-parser.jay" +void case_859() +#line 5694 "cs-parser.jay" { yyVal = new TryFinally ((Statement) yyVals[-2+yyTop], (Block) yyVals[0+yyTop], GetLocation (yyVals[-3+yyTop])); lbag.AddStatement (yyVal, GetLocation (yyVals[-1+yyTop])); } -void case_843() -#line 5565 "cs-parser.jay" +void case_860() +#line 5699 "cs-parser.jay" { - yyVal = new TryFinally (new TryCatch ((Block) yyVals[-3+yyTop], (List) yyVals[-2+yyTop], GetLocation (yyVals[-4+yyTop]), true), (Block) yyVals[0+yyTop], GetLocation (yyVals[-4+yyTop])); + var loc = GetLocation (yyVals[-4+yyTop]); + yyVal = new TryFinally (new TryCatch ((Block) yyVals[-3+yyTop], (List) yyVals[-2+yyTop], loc, true), (Block) yyVals[0+yyTop], loc); lbag.AddStatement (yyVal, GetLocation (yyVals[-1+yyTop])); } -void case_844() -#line 5570 "cs-parser.jay" +void case_861() +#line 5705 "cs-parser.jay" { Error_SyntaxError (1524, yyToken); yyVal = new TryCatch ((Block) yyVals[-1+yyTop], null, GetLocation (yyVals[-2+yyTop]), false); } -void case_845() -#line 5578 "cs-parser.jay" +void case_862() +#line 5713 "cs-parser.jay" { var l = new List (2); @@ -8236,8 +8462,8 @@ void case_845() yyVal = l; } -void case_846() -#line 5585 "cs-parser.jay" +void case_863() +#line 5720 "cs-parser.jay" { var l = (List) yyVals[-1+yyTop]; @@ -8250,8 +8476,8 @@ void case_846() yyVal = l; } -void case_850() -#line 5609 "cs-parser.jay" +void case_867() +#line 5744 "cs-parser.jay" { start_block (GetLocation (yyVals[-3+yyTop])); var c = new Catch (current_block, GetLocation (yyVals[-4+yyTop])); @@ -8267,8 +8493,8 @@ void case_850() yyVal = c; } -void case_852() -#line 5628 "cs-parser.jay" +void case_869() +#line 5763 "cs-parser.jay" { if (yyToken == Token.CLOSE_PARENS) { report.Error (1015, lexer.Location, @@ -8280,15 +8506,15 @@ void case_852() yyVal = new Catch (null, GetLocation (yyVals[-2+yyTop])); } -void case_855() -#line 5656 "cs-parser.jay" +void case_872() +#line 5791 "cs-parser.jay" { if (!settings.Unsafe) Error_UnsafeCodeNotAllowed (GetLocation (yyVals[0+yyTop])); } -void case_857() -#line 5666 "cs-parser.jay" +void case_874() +#line 5801 "cs-parser.jay" { if (yyVals[0+yyTop] is EmptyStatement && lexer.peek_token () == Token.OPEN_BRACE) Warning_EmptyStatement (GetLocation (yyVals[0+yyTop])); @@ -8297,8 +8523,8 @@ void case_857() lbag.AddStatement (yyVal, GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[-1+yyTop])); } -void case_858() -#line 5674 "cs-parser.jay" +void case_875() +#line 5809 "cs-parser.jay" { Error_SyntaxError (yyToken); @@ -8306,8 +8532,8 @@ void case_858() lbag.AddStatement (yyVal, GetLocation (yyVals[-2+yyTop])); } -void case_859() -#line 5684 "cs-parser.jay" +void case_876() +#line 5819 "cs-parser.jay" { start_block (GetLocation (yyVals[-2+yyTop])); @@ -8318,15 +8544,15 @@ void case_859() current_variable = new Fixed.VariableDeclaration ((FullNamedExpression) yyVals[-1+yyTop], li); } -void case_860() -#line 5694 "cs-parser.jay" +void case_877() +#line 5829 "cs-parser.jay" { yyVal = current_variable; current_variable = null; } -void case_861() -#line 5699 "cs-parser.jay" +void case_878() +#line 5834 "cs-parser.jay" { if (yyVals[0+yyTop] is EmptyStatement && lexer.peek_token () == Token.OPEN_BRACE) Warning_EmptyStatement (GetLocation (yyVals[0+yyTop])); @@ -8337,8 +8563,8 @@ void case_861() yyVal = end_block (GetLocation (yyVals[-2+yyTop])); } -void case_862() -#line 5712 "cs-parser.jay" +void case_879() +#line 5847 "cs-parser.jay" { start_block (GetLocation (yyVals[-2+yyTop])); @@ -8349,15 +8575,15 @@ void case_862() current_variable = new Using.VariableDeclaration ((FullNamedExpression) yyVals[-1+yyTop], li); } -void case_863() -#line 5722 "cs-parser.jay" +void case_880() +#line 5857 "cs-parser.jay" { yyVal = current_variable; current_variable = null; } -void case_864() -#line 5727 "cs-parser.jay" +void case_881() +#line 5862 "cs-parser.jay" { if (yyVals[0+yyTop] is EmptyStatement && lexer.peek_token () == Token.OPEN_BRACE) Warning_EmptyStatement (GetLocation (yyVals[0+yyTop])); @@ -8368,8 +8594,8 @@ void case_864() yyVal = end_block (GetLocation (yyVals[-2+yyTop])); } -void case_865() -#line 5737 "cs-parser.jay" +void case_882() +#line 5872 "cs-parser.jay" { if (yyVals[0+yyTop] is EmptyStatement && lexer.peek_token () == Token.OPEN_BRACE) Warning_EmptyStatement (GetLocation (yyVals[0+yyTop])); @@ -8378,8 +8604,8 @@ void case_865() lbag.AddStatement (yyVal, GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[-1+yyTop])); } -void case_866() -#line 5745 "cs-parser.jay" +void case_883() +#line 5880 "cs-parser.jay" { Error_SyntaxError (yyToken); @@ -8387,23 +8613,23 @@ void case_866() lbag.AddStatement (yyVal, GetLocation (yyVals[-2+yyTop])); } -void case_868() -#line 5756 "cs-parser.jay" +void case_885() +#line 5891 "cs-parser.jay" { /* It has to be here for the parent to safely restore artificial block*/ Error_SyntaxError (yyToken); } -void case_870() -#line 5768 "cs-parser.jay" +void case_887() +#line 5903 "cs-parser.jay" { current_variable.Initializer = (Expression) yyVals[0+yyTop]; lbag.AppendTo (current_variable, GetLocation (yyVals[-1+yyTop])); yyVal = current_variable; } -void case_871() -#line 5780 "cs-parser.jay" +void case_888() +#line 5915 "cs-parser.jay" { lexer.query_parsing = false; @@ -8416,8 +8642,8 @@ void case_871() current_block = current_block.Parent; } -void case_872() -#line 5792 "cs-parser.jay" +void case_889() +#line 5927 "cs-parser.jay" { Linq.AQueryClause from = yyVals[-1+yyTop] as Linq.AQueryClause; @@ -8428,8 +8654,8 @@ void case_872() current_block = current_block.Parent; } -void case_873() -#line 5803 "cs-parser.jay" +void case_890() +#line 5938 "cs-parser.jay" { lexer.query_parsing = false; yyVal = yyVals[-1+yyTop]; @@ -8438,64 +8664,68 @@ void case_873() current_block = current_block.Parent; } -void case_874() -#line 5810 "cs-parser.jay" +void case_891() +#line 5945 "cs-parser.jay" { yyVal = yyVals[-1+yyTop]; current_block.SetEndLocation (lexer.Location); current_block = current_block.Parent; } -void case_875() -#line 5819 "cs-parser.jay" +void case_892() +#line 5954 "cs-parser.jay" { current_block = new Linq.QueryBlock (current_block, lexer.Location); var lt = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; var rv = new Linq.RangeVariable (lt.Value, lt.Location); - yyVal = new Linq.QueryExpression (new Linq.QueryStartClause ((Linq.QueryBlock)current_block, (Expression)yyVals[0+yyTop], rv, GetLocation (yyVals[-3+yyTop]))); + var start = new Linq.QueryStartClause ((Linq.QueryBlock)current_block, (Expression)yyVals[0+yyTop], rv, GetLocation (yyVals[-3+yyTop])); + lbag.AddLocation (start, GetLocation (yyVals[-1+yyTop])); + yyVal = new Linq.QueryExpression (start); } -void case_876() -#line 5827 "cs-parser.jay" +void case_893() +#line 5964 "cs-parser.jay" { current_block = new Linq.QueryBlock (current_block, lexer.Location); var lt = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; var rv = new Linq.RangeVariable (lt.Value, lt.Location); - yyVal = new Linq.QueryExpression ( - new Linq.QueryStartClause ((Linq.QueryBlock)current_block, (Expression)yyVals[0+yyTop], rv, GetLocation (yyVals[-4+yyTop])) { - IdentifierType = (FullNamedExpression)yyVals[-3+yyTop] - } - ); + var start = new Linq.QueryStartClause ((Linq.QueryBlock)current_block, (Expression)yyVals[0+yyTop], rv, GetLocation (yyVals[-4+yyTop])) { + IdentifierType = (FullNamedExpression)yyVals[-3+yyTop] + }; + lbag.AddLocation (start, GetLocation (yyVals[-1+yyTop])); + yyVal = new Linq.QueryExpression (start); } -void case_877() -#line 5842 "cs-parser.jay" +void case_894() +#line 5979 "cs-parser.jay" { current_block = new Linq.QueryBlock (current_block, lexer.Location); var lt = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; var rv = new Linq.RangeVariable (lt.Value, lt.Location); - yyVal = new Linq.QueryExpression (new Linq.QueryStartClause ((Linq.QueryBlock)current_block, (Expression)yyVals[0+yyTop], rv, GetLocation (yyVals[-3+yyTop]))); + var start = new Linq.QueryStartClause ((Linq.QueryBlock)current_block, (Expression)yyVals[0+yyTop], rv, GetLocation (yyVals[-3+yyTop])); + lbag.AddLocation (start, GetLocation (yyVals[-1+yyTop])); + yyVal = new Linq.QueryExpression (start); } -void case_878() -#line 5850 "cs-parser.jay" +void case_895() +#line 5989 "cs-parser.jay" { current_block = new Linq.QueryBlock (current_block, lexer.Location); var lt = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; var rv = new Linq.RangeVariable (lt.Value, lt.Location); - yyVal = new Linq.QueryExpression ( - new Linq.QueryStartClause ((Linq.QueryBlock)current_block, (Expression)yyVals[0+yyTop], rv, GetLocation (yyVals[-4+yyTop])) { - IdentifierType = (FullNamedExpression)yyVals[-3+yyTop] - } - ); + var start = new Linq.QueryStartClause ((Linq.QueryBlock)current_block, (Expression)yyVals[0+yyTop], rv, GetLocation (yyVals[-4+yyTop])) { + IdentifierType = (FullNamedExpression)yyVals[-3+yyTop] + }; + lbag.AddLocation (start, GetLocation (yyVals[-1+yyTop])); + yyVal = new Linq.QueryExpression (start); } -void case_880() -#line 5869 "cs-parser.jay" +void case_897() +#line 6008 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-3+yyTop]; var sn = new Linq.RangeVariable (lt.Value, lt.Location); @@ -8503,12 +8733,13 @@ void case_880() current_block.SetEndLocation (lexer.Location); current_block = current_block.Parent; - ((Linq.QueryBlock)current_block).AddRangeVariable (sn); + + lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop])); } -void case_882() -#line 5884 "cs-parser.jay" +void case_899() +#line 6024 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-3+yyTop]; var sn = new Linq.RangeVariable (lt.Value, lt.Location); @@ -8521,10 +8752,12 @@ void case_882() current_block = current_block.Parent; ((Linq.QueryBlock)current_block).AddRangeVariable (sn); + + lbag.AddLocation (yyVal, GetLocation (yyVals[-2+yyTop])); } -void case_883() -#line 5901 "cs-parser.jay" +void case_900() +#line 6043 "cs-parser.jay" { Linq.AQueryClause head = (Linq.AQueryClause)yyVals[-1+yyTop]; @@ -8540,15 +8773,36 @@ void case_883() yyVal = head; } -void case_885() -#line 5917 "cs-parser.jay" +void case_901() +#line 6058 "cs-parser.jay" +{ + Linq.AQueryClause head = (Linq.AQueryClause)yyVals[0+yyTop]; + + if (yyVals[-1+yyTop] != null) { + Linq.AQueryClause clause = (Linq.AQueryClause)yyVals[-1+yyTop]; + clause.Tail.Next = head; + head = clause; + } + + yyVal = head; + } + +void case_903() +#line 6071 "cs-parser.jay" +{ + report.Error (742, GetLocation (yyVals[0+yyTop]), "Unexpected symbol `{0}'. A query body must end with select or group clause", GetSymbolName (yyToken)); + yyVal = yyVals[-1+yyTop]; + } + +void case_904() +#line 6076 "cs-parser.jay" { Error_SyntaxError (yyToken); yyVal = null; } -void case_887() -#line 5929 "cs-parser.jay" +void case_906() +#line 6088 "cs-parser.jay" { yyVal = new Linq.Select ((Linq.QueryBlock)current_block, (Expression)yyVals[0+yyTop], GetLocation (yyVals[-2+yyTop])); @@ -8556,8 +8810,8 @@ void case_887() current_block = current_block.Parent; } -void case_888() -#line 5936 "cs-parser.jay" +void case_907() +#line 6095 "cs-parser.jay" { if (linq_clause_blocks == null) linq_clause_blocks = new Stack (); @@ -8566,8 +8820,8 @@ void case_888() linq_clause_blocks.Push ((Linq.QueryBlock)current_block); } -void case_889() -#line 5944 "cs-parser.jay" +void case_908() +#line 6103 "cs-parser.jay" { current_block.SetEndLocation (lexer.Location); current_block = current_block.Parent; @@ -8575,8 +8829,8 @@ void case_889() current_block = new Linq.QueryBlock (current_block, lexer.Location); } -void case_890() -#line 5951 "cs-parser.jay" +void case_909() +#line 6110 "cs-parser.jay" { yyVal = new Linq.GroupBy ((Linq.QueryBlock)current_block, (Expression)yyVals[-3+yyTop], linq_clause_blocks.Pop (), (Expression)yyVals[0+yyTop], GetLocation (yyVals[-5+yyTop])); lbag.AddLocation (yyVal, GetLocation (yyVals[-1+yyTop])); @@ -8585,15 +8839,15 @@ void case_890() current_block = current_block.Parent; } -void case_894() -#line 5968 "cs-parser.jay" +void case_911() +#line 6122 "cs-parser.jay" { ((Linq.AQueryClause)yyVals[-1+yyTop]).Tail.Next = (Linq.AQueryClause)yyVals[0+yyTop]; yyVal = yyVals[-1+yyTop]; } -void case_901() -#line 5988 "cs-parser.jay" +void case_918() +#line 6142 "cs-parser.jay" { var lt = (Tokenizer.LocatedToken) yyVals[-3+yyTop]; var sn = new Linq.RangeVariable (lt.Value, lt.Location); @@ -8606,8 +8860,8 @@ void case_901() ((Linq.QueryBlock)current_block).AddRangeVariable (sn); } -void case_903() -#line 6007 "cs-parser.jay" +void case_920() +#line 6161 "cs-parser.jay" { yyVal = new Linq.Where ((Linq.QueryBlock)current_block, (Expression)yyVals[0+yyTop], GetLocation (yyVals[-2+yyTop])); @@ -8615,8 +8869,8 @@ void case_903() current_block = current_block.Parent; } -void case_904() -#line 6017 "cs-parser.jay" +void case_921() +#line 6171 "cs-parser.jay" { if (linq_clause_blocks == null) linq_clause_blocks = new Stack (); @@ -8625,8 +8879,8 @@ void case_904() linq_clause_blocks.Push ((Linq.QueryBlock) current_block); } -void case_905() -#line 6025 "cs-parser.jay" +void case_922() +#line 6179 "cs-parser.jay" { current_block.SetEndLocation (lexer.Location); current_block = current_block.Parent; @@ -8635,8 +8889,8 @@ void case_905() linq_clause_blocks.Push ((Linq.QueryBlock) current_block); } -void case_906() -#line 6033 "cs-parser.jay" +void case_923() +#line 6187 "cs-parser.jay" { current_block.AddStatement (new ContextualReturn ((Expression) yyVals[-1+yyTop])); current_block.SetEndLocation (lexer.Location); @@ -8645,8 +8899,8 @@ void case_906() current_block = new Linq.QueryBlock (current_block, lexer.Location); } -void case_907() -#line 6041 "cs-parser.jay" +void case_924() +#line 6195 "cs-parser.jay" { current_block.AddStatement (new ContextualReturn ((Expression) yyVals[-1+yyTop])); current_block.SetEndLocation (lexer.Location); @@ -8678,15 +8932,15 @@ void case_907() into = new Linq.RangeVariable (lt.Value, lt.Location); yyVal = new Linq.GroupJoin (block, sn, (Expression)yyVals[-7+yyTop], outer_selector, (Linq.QueryBlock) current_block, into, GetLocation (yyVals[-11+yyTop])); - lbag.AddLocation (yyVal, GetLocation (yyVals[-9+yyTop]), GetLocation (yyVals[-6+yyTop]), GetLocation (yyVals[-3+yyTop]), GetLocation (yyVals[0+yyTop])); + lbag.AddLocation (yyVal, GetLocation (yyVals[-9+yyTop]), GetLocation (yyVals[-6+yyTop]), GetLocation (yyVals[-3+yyTop]), opt_intoStack.Pop ()); } current_block = block.Parent; ((Linq.QueryBlock)current_block).AddRangeVariable (into); } -void case_908() -#line 6079 "cs-parser.jay" +void case_925() +#line 6233 "cs-parser.jay" { if (linq_clause_blocks == null) linq_clause_blocks = new Stack (); @@ -8695,8 +8949,8 @@ void case_908() linq_clause_blocks.Push ((Linq.QueryBlock) current_block); } -void case_909() -#line 6087 "cs-parser.jay" +void case_926() +#line 6241 "cs-parser.jay" { current_block.SetEndLocation (lexer.Location); current_block = current_block.Parent; @@ -8705,8 +8959,8 @@ void case_909() linq_clause_blocks.Push ((Linq.QueryBlock) current_block); } -void case_910() -#line 6095 "cs-parser.jay" +void case_927() +#line 6249 "cs-parser.jay" { current_block.AddStatement (new ContextualReturn ((Expression) yyVals[-1+yyTop])); current_block.SetEndLocation (lexer.Location); @@ -8715,8 +8969,8 @@ void case_910() current_block = new Linq.QueryBlock (current_block, lexer.Location); } -void case_911() -#line 6103 "cs-parser.jay" +void case_928() +#line 6257 "cs-parser.jay" { current_block.AddStatement (new ContextualReturn ((Expression) yyVals[-1+yyTop])); current_block.SetEndLocation (lexer.Location); @@ -8733,6 +8987,7 @@ void case_911() yyVal = new Linq.Join (block, sn, (Expression)yyVals[-7+yyTop], outer_selector, (Linq.QueryBlock) current_block, GetLocation (yyVals[-12+yyTop])) { IdentifierType = (FullNamedExpression)yyVals[-11+yyTop] }; + lbag.AddLocation (yyVal, GetLocation (yyVals[-10+yyTop]), GetLocation (yyVals[-7+yyTop]), GetLocation (yyVals[-4+yyTop])); } else { /**/ /* Set equals right side parent to beginning of linq query, it is not accessible therefore cannot cause name collisions*/ @@ -8751,14 +9006,22 @@ void case_911() yyVal = new Linq.GroupJoin (block, sn, (Expression)yyVals[-7+yyTop], outer_selector, (Linq.QueryBlock) current_block, into, GetLocation (yyVals[-12+yyTop])) { IdentifierType = (FullNamedExpression)yyVals[-11+yyTop] }; + lbag.AddLocation (yyVal, GetLocation (yyVals[-10+yyTop]), GetLocation (yyVals[-7+yyTop]), GetLocation (yyVals[-4+yyTop]), opt_intoStack.Pop ()); } current_block = block.Parent; ((Linq.QueryBlock)current_block).AddRangeVariable (into); } -void case_915() -#line 6158 "cs-parser.jay" +void case_930() +#line 6303 "cs-parser.jay" +{ + opt_intoStack.Push (GetLocation (yyVals[-1+yyTop])); + yyVal = yyVals[0+yyTop]; + } + +void case_932() +#line 6315 "cs-parser.jay" { current_block.SetEndLocation (lexer.Location); current_block = current_block.Parent; @@ -8766,8 +9029,8 @@ void case_915() yyVal = yyVals[0+yyTop]; } -void case_917() -#line 6169 "cs-parser.jay" +void case_934() +#line 6326 "cs-parser.jay" { current_block.SetEndLocation (lexer.Location); current_block = current_block.Parent; @@ -8775,15 +9038,15 @@ void case_917() current_block = new Linq.QueryBlock (current_block, lexer.Location); } -void case_918() -#line 6176 "cs-parser.jay" +void case_935() +#line 6333 "cs-parser.jay" { ((Linq.AQueryClause)yyVals[-3+yyTop]).Next = (Linq.AQueryClause)yyVals[0+yyTop]; yyVal = yyVals[-3+yyTop]; } -void case_920() -#line 6185 "cs-parser.jay" +void case_937() +#line 6342 "cs-parser.jay" { current_block.SetEndLocation (lexer.Location); current_block = current_block.Parent; @@ -8791,43 +9054,43 @@ void case_920() current_block = new Linq.QueryBlock ((Linq.QueryBlock) current_block, lexer.Location); } -void case_921() -#line 6192 "cs-parser.jay" +void case_938() +#line 6349 "cs-parser.jay" { ((Linq.AQueryClause)yyVals[-3+yyTop]).Tail.Next = (Linq.AQueryClause)yyVals[0+yyTop]; yyVal = yyVals[-3+yyTop]; } -void case_923() -#line 6204 "cs-parser.jay" +void case_940() +#line 6361 "cs-parser.jay" { yyVal = new Linq.OrderByAscending ((Linq.QueryBlock) current_block, (Expression)yyVals[-1+yyTop]); lbag.AddLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_924() -#line 6209 "cs-parser.jay" +void case_941() +#line 6366 "cs-parser.jay" { yyVal = new Linq.OrderByDescending ((Linq.QueryBlock) current_block, (Expression)yyVals[-1+yyTop]); lbag.AddLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_926() -#line 6221 "cs-parser.jay" +void case_943() +#line 6378 "cs-parser.jay" { yyVal = new Linq.ThenByAscending ((Linq.QueryBlock) current_block, (Expression)yyVals[-1+yyTop]); lbag.AddLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_927() -#line 6226 "cs-parser.jay" +void case_944() +#line 6383 "cs-parser.jay" { yyVal = new Linq.ThenByDescending ((Linq.QueryBlock) current_block, (Expression)yyVals[-1+yyTop]); lbag.AddLocation (yyVal, GetLocation (yyVals[0+yyTop])); } -void case_929() -#line 6236 "cs-parser.jay" +void case_946() +#line 6393 "cs-parser.jay" { /* query continuation block is not linked with query block but with block*/ /* before. This means each query can use same range variable names for*/ @@ -8844,8 +9107,8 @@ void case_929() linq_clause_blocks.Push ((Linq.QueryBlock) current_block); } -void case_930() -#line 6252 "cs-parser.jay" +void case_947() +#line 6409 "cs-parser.jay" { var current_block = linq_clause_blocks.Pop (); var lt = (Tokenizer.LocatedToken) yyVals[-2+yyTop]; @@ -8855,11 +9118,10 @@ void case_930() }; } -void case_933() -#line 6279 "cs-parser.jay" +void case_950() +#line 6436 "cs-parser.jay" { - current_container = new Class (current_namespace, current_class, new MemberName (""), Modifiers.PUBLIC, null); - current_class = current_container; + current_container = current_type = new Class (current_container, new MemberName (""), Modifiers.PUBLIC, null); /* (ref object retval)*/ Parameter [] mpar = new Parameter [1]; @@ -8872,22 +9134,22 @@ void case_933() current_local_parameters = pars; Method method = new Method ( - current_class, + current_type, new TypeExpression (compiler.BuiltinTypes.Void, Location.Null), mods, new MemberName ("Host"), pars, null /* attributes */); - current_container.AddMethod (method); + current_type.AddMember (method); oob_stack.Push (method); ++lexer.parsing_block; start_block (lexer.Location); } -void case_934() -#line 6308 "cs-parser.jay" +void case_951() +#line 6464 "cs-parser.jay" { --lexer.parsing_block; Method method = (Method) oob_stack.Pop (); @@ -8898,16 +9160,16 @@ void case_934() current_local_parameters = null; } -void case_944() -#line 6351 "cs-parser.jay" +void case_961() +#line 6507 "cs-parser.jay" { module.DocumentationBuilder.ParsedBuiltinType = (TypeExpression)yyVals[-1+yyTop]; module.DocumentationBuilder.ParsedParameters = (List)yyVals[0+yyTop]; yyVal = null; } -void case_945() -#line 6357 "cs-parser.jay" +void case_962() +#line 6513 "cs-parser.jay" { module.DocumentationBuilder.ParsedBuiltinType = (TypeExpression)yyVals[-3+yyTop]; module.DocumentationBuilder.ParsedParameters = (List)yyVals[0+yyTop]; @@ -8915,15 +9177,15 @@ void case_945() yyVal = new MemberName (lt.Value); } -void case_948() -#line 6372 "cs-parser.jay" +void case_965() +#line 6528 "cs-parser.jay" { module.DocumentationBuilder.ParsedParameters = (List)yyVals[-1+yyTop]; yyVal = new MemberName ((MemberName) yyVals[-6+yyTop], MemberCache.IndexerNameAlias, Location.Null); } -void case_949() -#line 6377 "cs-parser.jay" +void case_966() +#line 6533 "cs-parser.jay" { var p = (List)yyVals[0+yyTop] ?? new List (1); p.Add (new DocumentationParameter ((FullNamedExpression) yyVals[-1+yyTop])); @@ -8932,8 +9194,8 @@ void case_949() yyVal = null; } -void case_950() -#line 6385 "cs-parser.jay" +void case_967() +#line 6541 "cs-parser.jay" { var p = (List)yyVals[0+yyTop] ?? new List (1); p.Add (new DocumentationParameter ((FullNamedExpression) yyVals[-1+yyTop])); @@ -8942,8 +9204,8 @@ void case_950() yyVal = null; } -void case_951() -#line 6393 "cs-parser.jay" +void case_968() +#line 6549 "cs-parser.jay" { var p = (List)yyVals[0+yyTop] ?? new List (1); module.DocumentationBuilder.ParsedParameters = p; @@ -8951,24 +9213,24 @@ void case_951() yyVal = null; } -void case_959() -#line 6431 "cs-parser.jay" +void case_976() +#line 6587 "cs-parser.jay" { var parameters = new List (); parameters.Add ((DocumentationParameter) yyVals[0+yyTop]); yyVal = parameters; } -void case_960() -#line 6437 "cs-parser.jay" +void case_977() +#line 6593 "cs-parser.jay" { var parameters = yyVals[-2+yyTop] as List; parameters.Add ((DocumentationParameter) yyVals[0+yyTop]); yyVal = parameters; } -void case_961() -#line 6446 "cs-parser.jay" +void case_978() +#line 6602 "cs-parser.jay" { if (yyVals[-1+yyTop] != null) yyVal = new DocumentationParameter ((Parameter.Modifier) yyVals[-1+yyTop], (FullNamedExpression) yyVals[0+yyTop]); @@ -8982,1638 +9244,1556 @@ void case_961() 11, 11, 12, 12, 13, 13, 14, 15, 15, 15, 19, 20, 17, 18, 18, 18, 22, 22, 23, 23, 7, 7, 6, 6, 21, 21, 8, 8, 24, 24, - 25, 25, 25, 25, 25, 9, 9, 10, 10, 33, - 31, 36, 32, 32, 34, 34, 34, 34, 35, 35, - 40, 37, 38, 39, 39, 41, 41, 41, 41, 41, - 42, 42, 46, 43, 45, 48, 48, 48, 49, 49, - 50, 50, 51, 51, 51, 51, 51, 51, 51, 51, - 51, 51, 51, 64, 66, 68, 69, 70, 27, 27, - 73, 52, 74, 74, 75, 75, 76, 78, 72, 72, - 77, 77, 83, 53, 87, 53, 53, 82, 90, 82, - 84, 84, 91, 91, 92, 93, 92, 88, 88, 94, - 94, 95, 96, 86, 86, 89, 89, 89, 99, 54, - 102, 103, 97, 104, 105, 106, 97, 97, 98, 98, - 101, 101, 109, 109, 109, 109, 109, 109, 109, 109, - 109, 109, 110, 110, 113, 113, 113, 116, 113, 114, - 114, 117, 117, 118, 118, 118, 111, 111, 111, 119, - 119, 119, 112, 121, 123, 124, 55, 126, 127, 128, - 57, 122, 122, 122, 122, 122, 132, 129, 133, 130, - 131, 131, 131, 134, 135, 136, 138, 28, 28, 137, - 137, 139, 139, 140, 140, 140, 140, 140, 140, 140, - 140, 140, 143, 58, 142, 142, 144, 144, 147, 141, - 141, 146, 146, 146, 146, 146, 146, 146, 146, 146, - 146, 146, 146, 146, 146, 146, 146, 146, 146, 146, - 146, 146, 146, 149, 148, 150, 148, 148, 148, 59, - 153, 155, 151, 152, 152, 154, 154, 159, 157, 160, - 157, 157, 157, 161, 60, 163, 56, 166, 167, 56, - 162, 169, 162, 164, 164, 170, 170, 171, 172, 171, - 173, 168, 165, 165, 165, 165, 165, 177, 174, 178, - 175, 176, 176, 180, 182, 183, 29, 179, 179, 179, - 181, 181, 181, 184, 184, 185, 186, 185, 187, 188, - 189, 30, 190, 190, 16, 16, 191, 191, 194, 193, - 193, 193, 195, 195, 197, 63, 120, 100, 100, 125, - 125, 198, 198, 198, 196, 196, 199, 199, 200, 200, - 202, 202, 81, 71, 71, 85, 85, 115, 115, 145, - 145, 203, 203, 203, 203, 203, 207, 207, 208, 208, - 206, 206, 206, 206, 206, 206, 206, 209, 209, 209, - 209, 209, 209, 209, 209, 209, 210, 210, 210, 210, - 210, 210, 210, 210, 210, 210, 210, 210, 210, 210, - 210, 210, 210, 210, 210, 210, 211, 211, 211, 212, - 212, 212, 232, 232, 233, 233, 234, 234, 214, 214, - 231, 231, 231, 231, 231, 231, 231, 231, 216, 235, - 235, 236, 236, 237, 237, 239, 239, 239, 240, 240, - 240, 240, 240, 241, 241, 158, 158, 245, 245, 245, - 245, 245, 247, 247, 246, 246, 248, 248, 248, 248, - 249, 217, 217, 217, 244, 244, 244, 250, 250, 251, - 251, 218, 219, 219, 220, 221, 222, 222, 213, 213, - 213, 213, 213, 256, 252, 223, 257, 257, 258, 258, - 259, 259, 260, 260, 260, 260, 253, 253, 204, 204, - 255, 255, 261, 261, 254, 254, 80, 80, 262, 262, - 263, 224, 264, 264, 264, 265, 265, 265, 265, 265, - 266, 192, 225, 226, 227, 228, 268, 229, 269, 229, - 267, 267, 271, 270, 215, 272, 272, 272, 272, 272, - 273, 273, 273, 273, 273, 273, 273, 274, 274, 274, - 274, 275, 275, 275, 275, 275, 275, 276, 276, 276, - 277, 277, 277, 277, 277, 278, 278, 278, 279, 279, - 280, 280, 281, 281, 282, 282, 283, 283, 284, 284, - 285, 285, 286, 286, 286, 286, 286, 286, 286, 286, - 286, 286, 286, 287, 287, 288, 288, 288, 289, 289, - 290, 290, 293, 291, 292, 292, 295, 294, 296, 294, - 297, 298, 294, 299, 300, 294, 44, 44, 242, 242, - 242, 242, 230, 230, 230, 79, 302, 303, 304, 305, - 306, 26, 62, 62, 61, 61, 107, 107, 307, 307, - 307, 307, 307, 307, 307, 307, 307, 307, 307, 307, - 307, 307, 307, 65, 65, 67, 67, 67, 308, 308, - 309, 310, 310, 311, 311, 311, 311, 201, 201, 312, - 312, 314, 108, 315, 315, 316, 156, 313, 313, 317, - 317, 318, 318, 318, 318, 318, 322, 322, 323, 323, - 323, 320, 320, 320, 320, 320, 320, 320, 320, 320, - 320, 320, 320, 320, 324, 324, 324, 324, 324, 324, - 324, 324, 324, 324, 324, 324, 324, 338, 338, 338, - 338, 325, 339, 321, 340, 340, 341, 341, 341, 341, - 341, 341, 205, 205, 342, 47, 47, 344, 319, 347, - 319, 343, 343, 343, 343, 345, 345, 351, 351, 350, - 350, 352, 352, 346, 346, 348, 348, 353, 353, 354, - 349, 349, 349, 326, 326, 337, 337, 355, 356, 356, - 327, 327, 357, 357, 357, 360, 358, 358, 359, 359, - 361, 361, 361, 364, 362, 363, 363, 365, 365, 328, - 328, 328, 328, 366, 366, 367, 367, 367, 371, 368, - 374, 376, 377, 370, 370, 372, 372, 379, 378, 378, - 373, 373, 375, 375, 381, 380, 380, 369, 369, 382, - 369, 369, 369, 329, 329, 329, 329, 329, 329, 383, - 384, 385, 385, 385, 386, 387, 388, 388, 389, 389, - 330, 330, 330, 330, 390, 390, 392, 392, 391, 393, - 391, 391, 331, 332, 394, 335, 333, 333, 396, 397, - 336, 399, 400, 334, 334, 334, 398, 398, 395, 395, - 301, 301, 301, 301, 401, 401, 403, 403, 405, 404, - 406, 404, 402, 402, 402, 410, 408, 411, 412, 408, - 407, 407, 413, 413, 414, 414, 414, 414, 414, 419, - 415, 420, 416, 421, 422, 423, 417, 425, 426, 427, - 417, 424, 424, 429, 418, 428, 432, 428, 431, 434, - 431, 430, 430, 430, 433, 433, 433, 409, 435, 409, - 3, 3, 436, 3, 3, 437, 437, 243, 243, 238, - 238, 5, 438, 438, 438, 438, 442, 438, 438, 438, - 438, 439, 439, 440, 443, 440, 441, 441, 444, 444, - 445, + 24, 25, 25, 25, 25, 25, 9, 9, 10, 10, + 33, 31, 36, 32, 32, 34, 34, 34, 34, 35, + 35, 40, 37, 38, 39, 39, 41, 41, 41, 41, + 41, 42, 42, 46, 43, 45, 48, 48, 48, 49, + 49, 50, 50, 51, 51, 51, 51, 51, 51, 51, + 51, 51, 51, 51, 51, 65, 67, 69, 70, 71, + 27, 27, 74, 52, 75, 75, 76, 76, 77, 79, + 73, 73, 78, 78, 84, 53, 88, 53, 53, 83, + 91, 83, 85, 85, 92, 92, 93, 94, 93, 89, + 89, 95, 95, 96, 97, 87, 87, 90, 90, 90, + 100, 54, 103, 104, 98, 105, 106, 107, 98, 98, + 98, 99, 99, 102, 102, 110, 110, 110, 110, 110, + 110, 110, 110, 110, 110, 111, 111, 114, 114, 114, + 114, 117, 114, 115, 115, 118, 118, 119, 119, 119, + 112, 112, 112, 120, 120, 120, 113, 122, 124, 125, + 55, 127, 128, 129, 57, 123, 123, 123, 123, 123, + 133, 130, 134, 131, 132, 132, 132, 135, 136, 137, + 139, 28, 28, 138, 138, 140, 140, 141, 141, 141, + 141, 141, 141, 141, 141, 141, 144, 58, 143, 143, + 145, 145, 148, 142, 142, 147, 147, 147, 147, 147, + 147, 147, 147, 147, 147, 147, 147, 147, 147, 147, + 147, 147, 147, 147, 147, 147, 147, 150, 149, 151, + 149, 149, 149, 59, 154, 156, 152, 153, 153, 155, + 155, 160, 158, 161, 158, 158, 158, 162, 60, 164, + 56, 167, 168, 56, 163, 170, 163, 165, 165, 171, + 171, 172, 173, 172, 174, 169, 166, 166, 166, 166, + 166, 178, 175, 179, 176, 177, 177, 61, 181, 183, + 184, 29, 180, 180, 180, 182, 182, 182, 185, 185, + 186, 187, 186, 188, 189, 190, 30, 191, 191, 16, + 16, 192, 192, 195, 194, 194, 194, 196, 196, 198, + 64, 121, 101, 101, 126, 126, 199, 199, 199, 197, + 197, 200, 200, 201, 201, 203, 203, 82, 72, 72, + 86, 86, 116, 116, 146, 146, 204, 204, 204, 204, + 204, 208, 208, 209, 207, 207, 207, 207, 207, 207, + 207, 210, 210, 210, 210, 210, 210, 210, 210, 210, + 211, 211, 211, 211, 211, 211, 211, 211, 211, 211, + 211, 211, 211, 211, 211, 211, 211, 211, 211, 211, + 212, 212, 212, 213, 213, 213, 233, 233, 234, 234, + 235, 235, 215, 215, 232, 232, 232, 232, 232, 232, + 232, 232, 217, 236, 236, 237, 237, 238, 238, 240, + 240, 240, 241, 241, 241, 241, 241, 242, 242, 159, + 159, 246, 246, 246, 246, 246, 248, 248, 247, 247, + 249, 249, 249, 249, 250, 218, 218, 218, 245, 245, + 245, 251, 251, 252, 252, 219, 220, 220, 221, 222, + 223, 223, 214, 214, 214, 214, 214, 257, 253, 224, + 258, 258, 259, 259, 260, 260, 261, 261, 261, 261, + 254, 254, 205, 205, 256, 256, 262, 262, 255, 255, + 81, 81, 263, 263, 264, 225, 265, 265, 265, 266, + 266, 266, 266, 266, 267, 193, 226, 227, 228, 229, + 269, 230, 270, 230, 268, 268, 272, 271, 216, 273, + 273, 273, 273, 273, 274, 274, 274, 274, 274, 274, + 274, 275, 275, 275, 275, 276, 276, 276, 276, 276, + 276, 277, 277, 277, 278, 278, 278, 278, 278, 279, + 279, 279, 280, 280, 281, 281, 282, 282, 283, 283, + 284, 284, 285, 285, 286, 286, 286, 288, 288, 288, + 288, 288, 288, 288, 288, 288, 288, 288, 289, 289, + 290, 290, 290, 291, 291, 292, 292, 294, 293, 287, + 287, 296, 295, 297, 295, 298, 299, 295, 300, 301, + 295, 44, 44, 243, 243, 243, 243, 231, 231, 231, + 80, 303, 304, 305, 306, 307, 26, 63, 63, 62, + 62, 108, 108, 308, 308, 308, 308, 308, 308, 308, + 308, 308, 308, 308, 308, 308, 308, 308, 66, 66, + 66, 68, 68, 309, 309, 310, 310, 311, 311, 312, + 312, 312, 312, 202, 202, 313, 313, 315, 109, 316, + 316, 317, 157, 157, 314, 314, 318, 318, 319, 319, + 319, 319, 319, 323, 323, 324, 324, 324, 321, 321, + 321, 321, 321, 321, 321, 321, 321, 321, 321, 321, + 321, 325, 325, 325, 325, 325, 325, 325, 325, 325, + 325, 325, 325, 325, 339, 339, 339, 339, 326, 340, + 322, 341, 341, 342, 342, 342, 342, 342, 342, 206, + 206, 343, 47, 47, 345, 320, 349, 320, 347, 347, + 344, 344, 344, 344, 346, 346, 353, 353, 352, 352, + 354, 354, 348, 348, 350, 350, 355, 355, 356, 351, + 351, 351, 327, 327, 327, 338, 338, 357, 358, 358, + 328, 328, 359, 359, 359, 362, 360, 360, 361, 361, + 363, 363, 363, 366, 364, 365, 365, 367, 367, 367, + 329, 329, 329, 329, 368, 368, 369, 369, 369, 373, + 370, 376, 372, 372, 379, 375, 375, 378, 378, 374, + 374, 382, 381, 381, 377, 377, 380, 380, 384, 383, + 383, 371, 371, 385, 371, 371, 371, 330, 330, 330, + 330, 330, 330, 386, 387, 387, 388, 388, 388, 389, + 389, 390, 390, 391, 391, 392, 392, 331, 331, 331, + 331, 393, 393, 395, 395, 394, 396, 394, 394, 332, + 333, 397, 336, 334, 334, 399, 400, 337, 402, 403, + 335, 335, 335, 401, 401, 398, 398, 302, 302, 302, + 302, 404, 404, 406, 406, 408, 407, 409, 407, 405, + 405, 405, 405, 405, 413, 411, 414, 415, 411, 410, + 410, 416, 416, 416, 416, 416, 421, 417, 422, 418, + 423, 424, 425, 419, 427, 428, 429, 419, 426, 426, + 431, 420, 430, 434, 430, 433, 436, 433, 432, 432, + 432, 435, 435, 435, 412, 437, 412, 3, 3, 438, + 3, 3, 439, 439, 244, 244, 239, 239, 5, 440, + 440, 440, 440, 444, 440, 440, 440, 440, 441, 441, + 442, 445, 442, 443, 443, 446, 446, 447, }; static readonly short [] yyLen = { 2, 2, 0, 3, 1, 2, 4, 3, 1, 0, 1, 1, 2, 4, 2, 1, 2, 1, 3, 5, 2, 0, 0, 11, 1, 3, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 1, 2, 1, 1, - 1, 1, 1, 1, 1, 0, 1, 1, 2, 0, - 3, 0, 6, 3, 1, 1, 1, 1, 1, 3, - 0, 3, 1, 0, 3, 0, 1, 1, 3, 3, - 1, 1, 0, 4, 4, 0, 1, 1, 0, 1, - 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 0, 0, 0, 0, 0, 16, 5, - 0, 9, 0, 1, 1, 2, 3, 0, 3, 1, - 1, 1, 0, 8, 0, 9, 6, 0, 0, 3, - 0, 1, 1, 2, 2, 0, 5, 0, 1, 1, - 2, 3, 0, 4, 2, 1, 1, 1, 0, 3, - 0, 0, 10, 0, 0, 0, 12, 8, 1, 1, - 0, 1, 1, 3, 3, 3, 5, 3, 5, 1, - 1, 1, 1, 3, 4, 6, 4, 0, 7, 0, - 1, 1, 2, 1, 1, 1, 4, 6, 4, 1, - 2, 2, 1, 0, 0, 0, 10, 0, 0, 0, - 13, 1, 2, 1, 2, 1, 0, 5, 0, 5, - 1, 1, 1, 0, 0, 0, 0, 15, 5, 0, + 2, 1, 1, 1, 1, 1, 0, 1, 1, 2, + 0, 3, 0, 6, 3, 1, 1, 1, 1, 1, + 3, 0, 3, 1, 0, 3, 0, 1, 1, 3, + 3, 1, 1, 0, 4, 4, 0, 1, 1, 0, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 0, 5, 1, 1, 1, 1, 0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 2, 2, 1, 2, 2, 0, 0, 4, - 2, 3, 0, 4, 2, 2, 3, 0, 1, 1, - 1, 2, 2, 2, 4, 3, 0, 7, 4, 4, - 3, 1, 3, 0, 0, 4, 0, 1, 1, 3, - 2, + 1, 2, 1, 0, 3, 1, 2, 3, 3, 1, + 1, 1, 1, 1, 5, 4, 7, 3, 6, 0, + 4, 0, 4, 2, 0, 4, 2, 3, 1, 0, + 1, 0, 5, 1, 0, 1, 0, 1, 1, 1, + 3, 4, 5, 0, 9, 5, 4, 1, 1, 1, + 1, 1, 1, 2, 2, 2, 3, 4, 3, 3, + 2, 3, 2, 4, 3, 0, 1, 3, 4, 5, + 3, 1, 2, 0, 1, 2, 0, 7, 3, 2, + 2, 0, 3, 5, 4, 0, 0, 10, 0, 0, + 9, 5, 4, 2, 1, 0, 2, 2, 2, 2, + 2, 4, 5, 4, 5, 0, 5, 0, 6, 3, + 2, 2, 2, 1, 0, 3, 0, 0, 6, 1, + 2, 1, 1, 1, 1, 1, 0, 5, 0, 3, + 0, 0, 0, 12, 0, 0, 0, 13, 0, 2, + 0, 3, 1, 0, 4, 1, 0, 4, 1, 2, + 2, 1, 2, 2, 0, 0, 4, 2, 3, 0, + 4, 2, 2, 3, 0, 1, 1, 1, 2, 2, + 2, 4, 3, 0, 7, 4, 4, 3, 1, 3, + 0, 0, 4, 0, 1, 1, 3, 2, }; static readonly short [] yyDefRed = { 0, 8, 0, 0, 0, 0, 0, 0, 0, 2, 4, - 0, 0, 11, 14, 0, 931, 0, 0, 935, 0, - 0, 15, 17, 373, 379, 386, 374, 376, 0, 375, - 0, 382, 384, 371, 0, 378, 380, 372, 383, 385, - 381, 335, 952, 0, 377, 942, 0, 10, 1, 0, - 0, 0, 12, 0, 770, 0, 0, 0, 0, 0, - 0, 0, 0, 414, 0, 0, 0, 0, 0, 0, - 0, 412, 0, 0, 0, 472, 0, 413, 0, 511, - 0, 855, 0, 0, 0, 622, 0, 0, 0, 0, - 0, 0, 0, 672, 0, 722, 0, 0, 0, 0, - 0, 0, 0, 0, 411, 0, 611, 0, 769, 0, - 705, 0, 0, 0, 0, 388, 389, 0, 391, 392, - 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, - 403, 404, 405, 406, 409, 410, 618, 541, 0, 0, + 0, 0, 11, 14, 0, 948, 0, 0, 952, 0, + 0, 15, 17, 377, 383, 390, 378, 380, 0, 379, + 0, 386, 388, 375, 0, 382, 384, 376, 387, 389, + 385, 340, 969, 0, 381, 959, 0, 10, 1, 0, + 0, 0, 12, 0, 780, 0, 0, 0, 0, 0, + 0, 0, 0, 418, 0, 0, 0, 0, 0, 0, + 0, 416, 0, 0, 0, 476, 0, 417, 0, 515, + 0, 872, 0, 0, 0, 627, 0, 0, 0, 0, + 0, 0, 0, 678, 0, 729, 0, 0, 0, 0, + 0, 0, 0, 0, 415, 0, 616, 0, 779, 0, + 712, 0, 0, 0, 0, 392, 393, 0, 395, 396, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 407, 408, 409, 410, 413, 414, 623, 545, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 619, 617, 620, 621, 689, 691, 0, 687, 690, 706, - 708, 709, 710, 711, 712, 713, 714, 715, 716, 717, - 707, 0, 0, 0, 771, 772, 790, 791, 792, 793, - 824, 825, 826, 827, 828, 829, 0, 0, 0, 20, - 0, 0, 325, 0, 327, 939, 16, 932, 0, 0, - 237, 236, 233, 238, 239, 232, 251, 250, 243, 244, - 240, 242, 241, 245, 234, 235, 246, 247, 253, 252, - 248, 249, 0, 0, 955, 0, 944, 0, 943, 3, - 50, 0, 0, 0, 40, 37, 39, 41, 42, 43, - 44, 45, 48, 13, 0, 0, 0, 830, 415, 416, - 853, 0, 0, 0, 0, 0, 0, 390, 0, 831, - 0, 533, 527, 532, 721, 768, 692, 719, 718, 720, - 693, 694, 695, 696, 697, 698, 699, 700, 701, 702, - 703, 704, 0, 0, 0, 799, 0, 0, 0, 737, - 736, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 840, 0, 387, 0, 0, 0, 0, 0, 0, - 854, 0, 0, 0, 735, 731, 0, 0, 0, 0, - 0, 0, 0, 354, 0, 0, 0, 0, 0, 0, - 0, 0, 614, 0, 540, 0, 0, 538, 542, 543, - 537, 547, 546, 544, 545, 607, 522, 0, 408, 407, - 0, 0, 0, 0, 0, 723, 0, 324, 0, 729, - 730, 0, 475, 476, 0, 0, 0, 727, 728, 0, + 624, 622, 625, 626, 696, 698, 0, 694, 697, 713, + 715, 716, 717, 718, 719, 720, 721, 722, 723, 724, + 714, 0, 0, 0, 781, 782, 801, 802, 803, 804, + 838, 839, 840, 841, 842, 843, 0, 0, 0, 20, + 0, 0, 330, 0, 332, 956, 16, 949, 0, 0, + 241, 240, 237, 242, 243, 236, 255, 254, 247, 248, + 244, 246, 245, 249, 238, 239, 250, 251, 257, 256, + 252, 253, 0, 0, 972, 0, 961, 0, 960, 3, + 51, 0, 0, 0, 40, 37, 39, 42, 43, 44, + 45, 46, 49, 13, 0, 0, 0, 844, 419, 420, + 870, 0, 0, 0, 0, 0, 0, 394, 0, 846, + 845, 0, 537, 531, 536, 728, 778, 699, 726, 725, + 727, 700, 701, 702, 703, 704, 705, 706, 707, 708, + 709, 710, 711, 0, 0, 0, 810, 0, 0, 0, + 744, 743, 0, 0, 0, 0, 0, 0, 0, 0, + 851, 0, 0, 857, 0, 391, 0, 0, 0, 853, + 0, 0, 0, 871, 0, 0, 0, 742, 738, 0, + 0, 0, 0, 0, 0, 0, 359, 0, 0, 0, + 0, 0, 0, 0, 0, 619, 0, 544, 0, 0, + 542, 546, 547, 541, 551, 550, 548, 549, 612, 526, + 0, 412, 411, 0, 0, 0, 0, 0, 730, 0, + 329, 0, 736, 737, 0, 479, 480, 0, 0, 0, + 734, 735, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 951, 695, 745, 733, + 0, 776, 777, 904, 919, 0, 0, 905, 907, 0, + 931, 890, 888, 912, 0, 0, 910, 913, 914, 915, + 916, 891, 889, 0, 0, 0, 334, 0, 18, 0, + 0, 0, 968, 0, 341, 0, 0, 0, 970, 0, + 0, 38, 649, 655, 647, 0, 644, 654, 648, 646, + 645, 652, 650, 651, 657, 653, 656, 658, 0, 0, + 642, 41, 50, 478, 0, 474, 475, 0, 0, 472, + 0, 747, 0, 0, 0, 808, 0, 775, 773, 774, + 0, 0, 0, 631, 0, 849, 847, 632, 0, 0, + 500, 0, 0, 0, 491, 0, 495, 505, 507, 0, + 487, 0, 0, 0, 0, 0, 482, 0, 485, 0, + 489, 361, 850, 0, 0, 852, 861, 0, 0, 0, + 862, 0, 0, 873, 0, 0, 741, 0, 371, 367, + 368, 0, 0, 366, 369, 370, 0, 0, 0, 552, + 0, 0, 533, 0, 614, 693, 0, 0, 0, 687, + 689, 690, 691, 423, 424, 0, 337, 338, 0, 179, + 178, 180, 0, 0, 0, 0, 363, 0, 599, 0, + 0, 855, 0, 0, 428, 0, 431, 0, 429, 0, + 468, 0, 0, 0, 0, 0, 457, 460, 0, 0, + 452, 459, 458, 0, 588, 589, 590, 591, 592, 593, + 594, 595, 596, 598, 597, 553, 555, 554, 560, 561, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 934, 688, 738, 726, 0, 766, 767, - 885, 902, 0, 0, 0, 914, 873, 871, 895, 0, - 0, 893, 896, 897, 898, 899, 874, 872, 0, 0, - 0, 329, 0, 18, 0, 0, 0, 951, 0, 336, - 0, 0, 0, 953, 0, 0, 38, 644, 650, 642, - 0, 639, 649, 643, 641, 640, 647, 645, 646, 652, - 648, 651, 653, 0, 0, 637, 49, 474, 0, 470, - 471, 0, 0, 468, 0, 740, 0, 0, 0, 797, - 0, 764, 765, 0, 0, 0, 626, 0, 834, 832, - 627, 0, 0, 496, 0, 0, 0, 487, 0, 491, - 501, 503, 0, 483, 0, 0, 0, 0, 0, 478, - 0, 481, 0, 485, 356, 835, 0, 0, 836, 844, - 0, 0, 0, 845, 0, 0, 856, 0, 0, 734, - 0, 366, 362, 363, 0, 0, 361, 364, 365, 0, - 0, 0, 548, 0, 0, 529, 0, 609, 686, 0, - 0, 0, 680, 682, 683, 684, 419, 420, 0, 332, - 333, 0, 175, 174, 176, 0, 0, 0, 0, 358, - 0, 594, 0, 0, 838, 0, 0, 424, 0, 427, - 0, 425, 0, 464, 0, 0, 0, 0, 0, 453, - 456, 0, 0, 448, 455, 454, 0, 583, 584, 585, - 586, 587, 588, 589, 590, 591, 593, 592, 549, 551, - 550, 556, 557, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 580, 0, - 0, 500, 0, 0, 0, 0, 0, 0, 0, 886, - 888, 884, 0, 894, 0, 0, 326, 949, 950, 350, - 0, 0, 347, 0, 0, 172, 0, 0, 959, 945, - 947, 58, 56, 57, 0, 0, 51, 0, 0, 59, - 61, 26, 24, 0, 0, 0, 634, 0, 638, 423, - 0, 473, 0, 524, 0, 535, 162, 183, 0, 0, - 152, 0, 0, 0, 163, 528, 0, 859, 805, 0, - 816, 800, 0, 807, 0, 818, 0, 833, 775, 0, - 858, 0, 0, 486, 0, 502, 504, 0, 0, 440, - 0, 0, 436, 0, 0, 465, 0, 506, 480, 0, - 138, 507, 136, 137, 509, 0, 523, 778, 0, 849, - 0, 842, 0, 846, 515, 0, 0, 0, 351, 0, - 513, 0, 0, 525, 866, 0, 862, 795, 0, 877, - 0, 875, 0, 0, 624, 625, 0, 0, 0, 685, - 674, 675, 673, 681, 602, 608, 601, 0, 0, 331, - 597, 0, 0, 0, 539, 837, 724, 428, 422, 426, - 421, 526, 463, 462, 461, 458, 457, 0, 452, 417, - 418, 429, 0, 0, 745, 0, 0, 903, 879, 0, - 904, 0, 900, 0, 915, 0, 0, 0, 0, 883, - 19, 328, 671, 670, 0, 669, 0, 346, 961, 173, - 956, 0, 0, 52, 0, 0, 0, 0, 0, 0, - 353, 0, 628, 0, 0, 78, 77, 0, 469, 0, - 0, 0, 0, 0, 534, 0, 0, 0, 0, 0, - 808, 801, 0, 819, 0, 0, 857, 493, 492, 443, - 0, 0, 940, 941, 432, 438, 0, 441, 0, 467, - 0, 0, 0, 0, 0, 776, 852, 0, 843, 0, - 521, 516, 0, 0, 512, 0, 865, 0, 794, 878, - 876, 0, 530, 0, 610, 606, 605, 604, 334, 596, - 595, 612, 460, 0, 450, 449, 582, 138, 0, 761, - 743, 0, 0, 0, 750, 0, 881, 0, 908, 0, - 923, 924, 917, 887, 889, 929, 349, 348, 960, 0, - 0, 60, 54, 0, 62, 25, 22, 0, 0, 304, - 0, 209, 0, 100, 0, 75, 755, 111, 112, 0, - 0, 0, 758, 181, 182, 0, 0, 0, 0, 155, - 164, 156, 158, 798, 0, 0, 0, 0, 0, 817, - 0, 0, 442, 444, 445, 439, 433, 437, 0, 498, - 0, 466, 477, 431, 510, 508, 0, 848, 0, 0, - 0, 517, 0, 868, 0, 0, 623, 615, 0, 459, - 0, 0, 739, 751, 880, 0, 0, 0, 901, 0, - 0, 0, 948, 0, 0, 0, 67, 68, 71, 72, - 0, 319, 310, 309, 0, 629, 205, 95, 0, 741, - 759, 167, 0, 179, 0, 0, 0, 796, 870, 0, - 0, 0, 812, 0, 820, 774, 482, 479, 783, 0, - 789, 0, 0, 781, 0, 786, 850, 520, 519, 867, - 863, 0, 613, 0, 0, 882, 905, 0, 0, 0, - 919, 0, 930, 0, 73, 65, 0, 0, 0, 305, - 0, 0, 0, 0, 0, 168, 0, 159, 157, 860, - 809, 802, 0, 0, 777, 782, 0, 787, 0, 0, - 616, 0, 753, 0, 909, 926, 927, 920, 890, 53, - 0, 69, 70, 0, 0, 0, 0, 0, 0, 0, - 760, 166, 0, 178, 0, 0, 821, 788, 0, 676, - 851, 864, 762, 0, 0, 0, 74, 0, 0, 320, - 0, 306, 0, 314, 370, 369, 0, 367, 658, 0, - 630, 0, 659, 206, 96, 169, 861, 0, 0, 814, - 0, 906, 0, 921, 0, 0, 0, 0, 0, 0, - 0, 0, 660, 0, 0, 803, 0, 0, 910, 28, - 23, 321, 0, 0, 315, 368, 0, 0, 0, 97, - 0, 677, 0, 0, 0, 0, 307, 666, 0, 667, - 664, 0, 662, 93, 0, 92, 0, 0, 81, 83, - 84, 85, 86, 87, 88, 89, 90, 91, 139, 0, - 0, 222, 214, 215, 216, 217, 218, 219, 220, 221, - 0, 0, 212, 0, 804, 0, 907, 0, 322, 318, - 0, 0, 0, 631, 82, 0, 265, 260, 264, 0, - 207, 213, 0, 913, 911, 665, 663, 0, 0, 0, - 0, 0, 0, 0, 274, 0, 0, 223, 0, 0, - 231, 0, 150, 140, 149, 0, 98, 0, 0, 259, - 0, 0, 258, 0, 144, 0, 0, 340, 0, 338, - 0, 0, 184, 0, 0, 0, 0, 0, 632, 208, - 0, 101, 0, 337, 0, 0, 0, 0, 115, 0, - 0, 0, 0, 0, 0, 141, 0, 0, 188, 0, - 341, 0, 226, 225, 224, 0, 99, 0, 278, 0, - 256, 117, 0, 254, 0, 0, 0, 119, 0, 342, - 0, 0, 185, 0, 0, 0, 339, 229, 110, 108, - 0, 0, 282, 0, 0, 0, 0, 0, 145, 0, - 262, 0, 0, 0, 0, 123, 0, 0, 0, 0, - 343, 344, 0, 0, 0, 0, 0, 105, 297, 0, - 279, 0, 0, 291, 0, 0, 0, 286, 0, 135, - 0, 0, 0, 0, 130, 0, 0, 275, 0, 120, - 0, 114, 124, 142, 148, 196, 0, 186, 0, 0, - 0, 0, 109, 0, 102, 106, 0, 0, 0, 293, - 0, 294, 283, 0, 0, 277, 287, 257, 0, 0, - 116, 131, 255, 0, 273, 0, 263, 267, 126, 0, - 0, 0, 193, 195, 189, 230, 107, 298, 300, 280, - 0, 0, 292, 289, 134, 132, 146, 272, 0, 0, - 0, 143, 197, 199, 187, 0, 0, 0, 291, 0, - 268, 270, 127, 0, 0, 190, 302, 303, 299, 301, - 290, 147, 0, 0, 203, 202, 201, 198, 200, 0, - 0, 0, 191, 269, 271, + 0, 0, 0, 0, 0, 584, 0, 0, 504, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 903, 902, + 0, 911, 0, 901, 0, 0, 331, 966, 967, 355, + 0, 0, 0, 352, 0, 0, 176, 0, 0, 976, + 962, 964, 59, 57, 58, 0, 0, 52, 0, 0, + 60, 62, 26, 24, 0, 0, 0, 639, 0, 643, + 427, 0, 477, 0, 528, 0, 539, 165, 187, 0, + 0, 0, 155, 0, 0, 0, 166, 532, 0, 876, + 0, 830, 811, 0, 821, 0, 832, 0, 848, 785, + 0, 875, 0, 0, 490, 0, 506, 508, 0, 0, + 444, 0, 0, 440, 0, 0, 469, 0, 510, 484, + 0, 140, 511, 138, 139, 513, 0, 527, 788, 0, + 866, 0, 859, 0, 863, 519, 0, 0, 0, 356, + 0, 517, 0, 0, 529, 883, 0, 879, 806, 0, + 894, 0, 892, 0, 0, 629, 630, 0, 0, 0, + 692, 680, 681, 679, 688, 607, 613, 606, 0, 0, + 336, 602, 0, 0, 0, 543, 854, 731, 432, 426, + 430, 425, 530, 467, 466, 465, 462, 461, 0, 456, + 421, 422, 433, 0, 587, 0, 754, 0, 0, 611, + 610, 920, 896, 0, 921, 0, 906, 908, 917, 0, + 932, 0, 900, 946, 19, 333, 677, 676, 0, 675, + 0, 351, 978, 177, 973, 0, 0, 53, 0, 0, + 0, 0, 0, 0, 358, 0, 633, 0, 0, 79, + 78, 0, 473, 0, 0, 0, 0, 0, 170, 538, + 0, 0, 0, 0, 0, 822, 814, 812, 0, 833, + 0, 0, 874, 497, 496, 447, 0, 0, 957, 958, + 436, 442, 0, 445, 0, 471, 0, 0, 0, 0, + 0, 786, 869, 0, 860, 0, 525, 520, 0, 0, + 516, 0, 882, 0, 805, 895, 893, 0, 534, 0, + 615, 609, 339, 601, 600, 617, 464, 0, 455, 454, + 453, 586, 140, 0, 770, 752, 0, 0, 0, 759, + 0, 898, 0, 925, 0, 0, 940, 941, 934, 0, + 354, 353, 977, 0, 0, 61, 55, 0, 63, 25, + 22, 0, 0, 309, 0, 213, 0, 102, 0, 76, + 764, 113, 114, 0, 0, 0, 767, 185, 186, 0, + 0, 0, 0, 158, 167, 159, 161, 809, 0, 0, + 0, 0, 0, 831, 0, 0, 446, 448, 449, 443, + 437, 441, 0, 502, 0, 470, 481, 435, 514, 512, + 0, 865, 0, 0, 0, 521, 0, 885, 0, 0, + 628, 620, 0, 463, 0, 0, 750, 749, 746, 760, + 897, 0, 0, 0, 0, 918, 0, 947, 965, 0, + 0, 0, 68, 69, 72, 73, 0, 324, 315, 314, + 0, 634, 209, 97, 0, 748, 768, 171, 0, 183, + 0, 0, 0, 807, 887, 0, 0, 0, 0, 813, + 0, 834, 784, 486, 483, 793, 0, 800, 0, 0, + 791, 0, 796, 867, 524, 523, 884, 880, 0, 618, + 0, 0, 899, 922, 0, 909, 0, 0, 936, 0, + 74, 66, 0, 0, 0, 310, 0, 0, 0, 0, + 0, 172, 0, 162, 160, 877, 823, 817, 815, 0, + 0, 787, 792, 0, 797, 0, 0, 621, 0, 762, + 0, 926, 943, 944, 937, 54, 0, 70, 71, 0, + 0, 0, 0, 0, 0, 0, 769, 169, 0, 182, + 0, 0, 835, 799, 798, 0, 682, 684, 868, 881, + 771, 0, 0, 0, 75, 0, 0, 325, 0, 311, + 0, 319, 374, 0, 372, 0, 635, 0, 664, 210, + 98, 173, 878, 819, 816, 0, 0, 828, 0, 923, + 0, 938, 0, 0, 0, 0, 0, 661, 0, 0, + 0, 665, 0, 0, 0, 0, 0, 927, 28, 23, + 326, 0, 0, 320, 373, 667, 0, 0, 0, 99, + 818, 683, 0, 0, 0, 0, 312, 672, 0, 673, + 670, 0, 668, 95, 0, 0, 93, 0, 0, 82, + 84, 85, 86, 87, 88, 89, 90, 91, 92, 94, + 141, 0, 0, 226, 218, 219, 220, 221, 222, 223, + 224, 225, 0, 0, 216, 0, 0, 924, 0, 327, + 323, 0, 0, 0, 308, 636, 83, 0, 269, 264, + 268, 0, 211, 217, 0, 930, 928, 671, 669, 0, + 0, 0, 0, 0, 0, 0, 278, 0, 0, 227, + 0, 0, 235, 0, 153, 142, 152, 0, 100, 0, + 0, 263, 0, 0, 262, 0, 146, 0, 0, 345, + 0, 343, 0, 0, 188, 0, 0, 0, 0, 0, + 637, 212, 0, 103, 0, 342, 0, 0, 0, 0, + 117, 0, 0, 0, 0, 0, 0, 151, 143, 0, + 0, 192, 0, 346, 0, 230, 229, 228, 0, 101, + 0, 282, 0, 260, 119, 0, 258, 0, 0, 0, + 121, 0, 347, 0, 0, 189, 0, 0, 0, 344, + 233, 112, 110, 0, 0, 286, 0, 0, 0, 0, + 0, 147, 0, 266, 0, 0, 0, 0, 125, 0, + 0, 0, 0, 348, 349, 0, 0, 0, 0, 0, + 107, 301, 0, 283, 0, 0, 295, 0, 0, 0, + 290, 0, 137, 0, 0, 0, 0, 132, 0, 0, + 279, 0, 122, 0, 116, 126, 144, 150, 200, 0, + 190, 0, 0, 0, 0, 111, 0, 104, 108, 0, + 0, 0, 297, 0, 298, 287, 0, 0, 281, 291, + 261, 0, 0, 118, 133, 259, 0, 277, 0, 267, + 271, 128, 0, 0, 0, 197, 199, 193, 234, 109, + 302, 304, 284, 0, 0, 296, 293, 136, 134, 148, + 276, 0, 0, 0, 145, 201, 203, 191, 0, 0, + 0, 295, 0, 272, 274, 129, 0, 0, 194, 306, + 307, 303, 305, 294, 149, 0, 0, 207, 206, 205, + 202, 204, 0, 0, 0, 195, 273, 275, }; protected static readonly short [] yyDgoto = { 7, - 8, 49, 9, 50, 10, 11, 51, 232, 689, 430, - 12, 13, 52, 22, 23, 321, 235, 674, 839, 1031, - 1149, 1487, 836, 236, 237, 238, 239, 240, 241, 242, - 243, 667, 445, 668, 669, 941, 670, 671, 945, 837, - 1026, 1027, 1028, 266, 591, 1121, 110, 848, 1217, 1218, - 1219, 1220, 1221, 1222, 1223, 1224, 1225, 1226, 1227, 1228, - 464, 678, 1300, 955, 1128, 1093, 1161, 1185, 1244, 1311, - 1156, 1361, 1338, 1386, 1387, 1388, 957, 1384, 958, 734, - 1277, 1349, 1324, 1374, 514, 1367, 1343, 1403, 920, 1372, - 1375, 1376, 1471, 1404, 1405, 1401, 1229, 1284, 1256, 1301, - 690, 1351, 1450, 1321, 1407, 1480, 465, 267, 691, 692, - 693, 694, 695, 654, 568, 1133, 655, 656, 854, 1303, - 1328, 1418, 1379, 1452, 1304, 1354, 1476, 1500, 1419, 1420, - 1498, 1484, 1485, 953, 1092, 1184, 1241, 1286, 1242, 1243, - 1278, 1335, 1307, 1279, 324, 223, 1383, 1281, 1368, 1365, - 1230, 1258, 1297, 1447, 1409, 1141, 1448, 592, 1493, 1494, - 1296, 1364, 1340, 1396, 1391, 1362, 1428, 1433, 1394, 1397, - 1398, 1479, 1434, 1392, 1393, 1489, 1477, 1478, 950, 1035, - 1152, 1126, 1178, 1153, 1154, 1193, 1089, 1176, 1205, 533, - 193, 112, 350, 195, 562, 440, 224, 1316, 652, 653, - 825, 841, 325, 407, 532, 303, 1157, 1158, 45, 114, - 304, 116, 117, 118, 119, 120, 121, 122, 123, 124, - 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, - 135, 136, 252, 802, 993, 510, 721, 875, 722, 723, - 986, 137, 198, 727, 593, 594, 595, 596, 796, 473, - 474, 297, 991, 729, 408, 299, 497, 498, 499, 500, - 503, 736, 310, 752, 753, 892, 263, 479, 767, 264, - 478, 138, 139, 140, 141, 142, 143, 144, 145, 146, - 147, 148, 149, 150, 151, 152, 571, 572, 573, 776, - 777, 908, 778, 153, 559, 769, 351, 1009, 547, 1072, - 154, 492, 951, 1091, 1182, 1282, 466, 1162, 1163, 1212, - 1213, 826, 551, 336, 773, 1171, 552, 553, 268, 269, - 270, 157, 158, 159, 271, 272, 273, 274, 275, 276, - 277, 278, 279, 280, 281, 282, 171, 283, 577, 172, - 173, 317, 807, 631, 923, 851, 685, 961, 921, 924, - 1051, 925, 962, 963, 284, 174, 175, 176, 1062, 997, - 1063, 1064, 1065, 1107, 1066, 177, 178, 179, 180, 702, - 485, 703, 1054, 979, 1168, 1136, 1201, 704, 978, 705, - 1170, 1103, 181, 182, 183, 184, 185, 186, 305, 523, - 524, 999, 1109, 313, 977, 860, 1135, 1006, 898, 1110, - 187, 418, 188, 419, 926, 1016, 420, 643, 820, 817, - 818, 1021, 421, 422, 423, 424, 425, 426, 930, 633, - 928, 1114, 1188, 1247, 1018, 1145, 1204, 815, 639, 816, - 1080, 1020, 1081, 1146, 1022, 17, 19, 46, 47, 227, - 657, 833, 441, 658, 659, + 8, 49, 9, 50, 10, 11, 51, 232, 700, 662, + 12, 13, 52, 22, 23, 324, 235, 685, 853, 1047, + 1167, 1510, 850, 236, 237, 238, 239, 240, 241, 242, + 243, 678, 450, 679, 680, 955, 681, 682, 959, 851, + 1042, 1043, 1044, 267, 598, 1137, 110, 862, 1238, 1239, + 1240, 1241, 1242, 1243, 1244, 1245, 1246, 1247, 1248, 1249, + 1250, 469, 689, 1322, 969, 1144, 1109, 1177, 1204, 1266, + 1333, 1173, 1384, 1361, 1409, 1410, 1411, 971, 1407, 972, + 745, 1299, 1372, 1346, 1397, 521, 1390, 1366, 1426, 935, + 1395, 1398, 1399, 1494, 1427, 1428, 1424, 1251, 1306, 1278, + 1323, 702, 1374, 1473, 1343, 1430, 1503, 470, 268, 703, + 704, 705, 706, 707, 665, 575, 1149, 666, 667, 868, + 1325, 1351, 1441, 1402, 1475, 1326, 1377, 1499, 1523, 1442, + 1443, 1521, 1507, 1508, 967, 1108, 1203, 1263, 1308, 1264, + 1265, 1300, 1358, 1329, 1301, 327, 223, 1406, 1303, 1391, + 1388, 1252, 1280, 1319, 1470, 1432, 1159, 1471, 599, 1516, + 1517, 1318, 1387, 1363, 1419, 1414, 1385, 1451, 1456, 1417, + 1420, 1421, 1502, 1457, 1415, 1416, 1512, 1500, 1501, 964, + 1051, 1170, 1142, 1196, 1171, 1172, 1212, 1105, 1194, 1225, + 540, 193, 112, 353, 195, 569, 445, 224, 1338, 663, + 664, 839, 855, 328, 410, 539, 305, 1174, 1175, 45, + 114, 306, 116, 117, 118, 119, 120, 121, 122, 123, + 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, + 134, 135, 136, 252, 813, 1007, 517, 732, 891, 733, + 734, 1000, 137, 198, 738, 600, 601, 602, 603, 807, + 479, 480, 298, 1005, 740, 411, 300, 504, 505, 506, + 507, 510, 747, 313, 763, 764, 908, 264, 485, 778, + 265, 484, 138, 139, 140, 141, 142, 143, 144, 145, + 146, 147, 148, 149, 150, 151, 822, 152, 578, 579, + 580, 787, 788, 789, 153, 566, 780, 354, 1023, 554, + 1089, 154, 499, 965, 1107, 1201, 1304, 471, 1178, 1179, + 1232, 1233, 840, 558, 339, 784, 1189, 559, 560, 269, + 270, 271, 157, 158, 159, 272, 273, 274, 275, 276, + 277, 278, 279, 280, 281, 282, 283, 171, 284, 584, + 172, 173, 320, 819, 638, 938, 1029, 865, 696, 975, + 936, 939, 1067, 940, 976, 977, 285, 174, 175, 176, + 1079, 1011, 1080, 1081, 1082, 1124, 1083, 177, 178, 179, + 180, 713, 492, 714, 1070, 993, 1071, 1185, 1152, 1186, + 715, 992, 716, 1188, 1120, 181, 182, 183, 184, 185, + 186, 307, 530, 531, 1013, 1126, 316, 991, 875, 1151, + 1020, 914, 1127, 187, 423, 188, 424, 941, 1032, 425, + 426, 654, 645, 646, 945, 427, 428, 429, 430, 431, + 946, 640, 943, 1131, 1207, 1268, 1034, 1163, 1224, 831, + 648, 832, 1098, 1037, 1099, 1164, 950, 17, 19, 46, + 47, 227, 668, 847, 446, 669, 670, }; - protected static readonly short [] yySindex = { -182, - 0, -212, 84, 146, 12,12046, 0, 180, 0, 0, - 12, 146, 0, 0, 99, 0, 6723, 12, 0, -172, - -20, 0, 0, 0, 0, 0, 0, 0, 233, 0, - 307, 0, 0, 0, 3619, 0, 0, 0, 0, 0, - 0, 0, 0, 409, 0, 0, 526, 0, 0, 180, - 264, 12, 0, 201, 0, 246, 219, 256,11546, 252, - -31, 306, 6880, 0, -31, -31, -31, -196, -31, -31, - -248, 0,10649, -31, -31, 0,10649, 0, 323, 0, - 256, 0, -31, 331, -31, 0,12065,12065, 351, -31, - -31, -224,11329, 0,10649, 0,11329,11329,11329,11329, -11329,11329,11329,11329, 0, 22, 0, 8429, 0, 63, - 0, 322, 346, 530, 279, 0, 0, 439, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 983, 643, - 21, -28, 491, 557, 456, 455, 476, 466, 216, 542, - 0, 0, 0, 0, 0, 0, 3320, 0, 0, 0, + protected static readonly short [] yySindex = { -175, + 0, -180, -100, -38, 249,12550, 0, 124, 0, 0, + 249, -38, 0, 0, 200, 0, 6884, 249, 0, -171, + -242, 0, 0, 0, 0, 0, 0, 0, 319, 0, + 397, 0, 0, 0, 3907, 0, 0, 0, 0, 0, + 0, 0, 0, 289, 0, 0, 712, 0, 0, 124, + 367, 249, 0, 374, 0, 214, 401, 244,12032, -83, + -255, 420, 7041, 0, -255, -255, -255, -90, -255, -255, + 720, 0, 8730, -255, -255, 0, 8887, 0, 429, 0, + 244, 0, -255, 458, -255, 0,12594,12594, 491, -255, + -255, -191,11815, 0,11135, 0,11815,11815,11815,11815, +11815,11815,11815,11815, 0, 258, 0, 8590, 0, 218, + 0, 468, 11, 522, 387, 0, 0, 527, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 94, 512, 113, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, -193, -189, 264, 0, - -266, 38, 0, 468, 0, 0, 0, 0, 8429, 8429, + 0, 0, 0, 0, 0, 0, 0, 0, 1299, 685, + 89, -273, -265, 413, 529, 561, 553, 557, 123, 588, + 0, 0, 0, 0, 0, 0, 3608, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, -8, 617, -261, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 306, 330, 367, 0, + 403, 344, 0, 577, 0, 0, 0, 0, 8590, 8590, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 573, 495, 0, 582, 0, 50, 0, 0, - 0, 264,12723, 264, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 784, 627,10785, 0, 0, 0, - 0,10649, -31, -31, 771, 317, 530, 0, 94, 0, - 8429, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, -157, 174,11546, 0, 8429,10649, 691, 0, - 0, 696,10649,10649, 9040, 445, -197, 708, 8586,11329, - 22, 0, 717, 0, 722, 8429,10649, 750, 441, -31, - 0,10649, 323,10105, 0, 0, 331,10649, 331, -277, - 376, 842, 94, 0, 512, 279, 845, 94,10649,10649, -10649, 306, 0, 806, 0, 7037, -293, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 1358, 0, 0, -11975, -277, 785, 783,10649, 0, 746, 0, 320, 0, - 0, 370, 0, 0, 744, 8569, 9833, 0, 0,11329, -10649,10649,10649,10649,10649,10649,10649,10649,10649,10649, -10649,11329,11329,11329, 8429, 8429,11329,11329,11329,11329, -11329,11329,11329,11329,11329,11329,11329,11329,11329,11329, -11329,11329,10649, 0, 0, 0, 0, 512, 0, 0, - 0, 0,12065,12065, 94, 0, 0, 0, 0, 43, - 493, 0, 0, 0, 0, 0, 0, 0, 264, 264, - 747, 0, 755, 0, 746, 573, 573, 0, -169, 0, - 496, 573, 795, 0, -148,12723, 0, 0, 0, 0, - -170, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, -177,12753, 0, 0, 0, 746, 0, - 0, 792, 488, 0, 802, 0, 803, -159, 323, 0, - -31, 0, 0, 94, 8117, -185, 0, 800, 0, 0, - 0, -143, -140, 0, 290, 0, 811, 0, 807, 0, - 0, 0, 506, 0, 8253, 569,10649, 708, 9833, 0, - 7508, 0, 331, 0, 0, 0, 808, -87, 0, 0, - 256, 323, -151, 0, 4203, 814, 0, -76, 94, 0, - -66, 0, 0, 0,10649, 889, 0, 0, 0,10649, - 894, 817, 0, 820, 825, 0,11975, 0, 0, -187, - 36, 7037, 0, 0, 0, 0, 0, 0, 323, 0, - 0, -262, 0, 0, 0, 331, -277, 94, 8743, 0, - 832, 0, 827,11329, 0, 831, 7037, 0, 309, 0, - 314, 0, 746, 0, -88,10649,10649, 837, 953, 0, - 0, -84, 838, 0, 0, 0, 643, 0, 0, 0, + 0, 0, 651, 612, 0, 616, 0, -248, 0, 0, + 0, 367,13162, 470, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 788, 661,11271, 0, 0, 0, + 0,11135, -255, -255, 781, 412, 522, 0, -8, 0, + 0, 8590, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 643, 643, 21, 21, -28, -28, -28, - -28, 491, 491, 557, 456, 455, 476, 466, 0, 846, - -195, 0,10649, 919, 94, 923, 94, 839,10649, 0, - 0, 0, 867, 0, 474, 746, 0, 0, 0, 0, - 471, 240, 0, 8743, 496, 0, 852, 851, 0, 0, - 0, 0, 0, 0, -277, 854, 0, 853, 856, 0, - 0, 0, 0, 859, 8900, 815, 0, 338, 0, 0, - 187, 0,10785, 0, 855, 0, 0, 0, 470, 862, - 0, 861, 863, 864, 0, 0,10649, 0, 0, 94, - 0, 0, 866, 0, 865, 0, 226, 0, 0, 6880, - 0, 6880, 8412, 0, 9040, 0, 0,10241, 88, 0, - 81, -183, 0, 816, 821, 0, 70, 0, 0, 874, - 0, 0, 0, 0, 0, 875, 0, 0, 883, 0, - 4362, 0, 323, 0, 0, 331, 382, 833, 0, 122, - 0, 886, 887, 0, 0, 6880, 0, 0, 6880, 0, -10649, 0,10649, 8429, 0, 0, 323, 890, 323, 0, - 0, 0, 0, 0, 0, 0, 0, 8726, 8429, 0, - 0, 94,11975, 918, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 9697, 0, 0, - 0, 0, 9969,10649, 0, 7665, 892, 0, 0, 969, - 0, 970, 0, 619, 0, 895,10649,10649, 94, 0, - 0, 0, 0, 0, 850, 0, -169, 0, 0, 0, - 0, 496, 496, 0, 747, 900, 903, 860, 917, 815, - 0, 910, 0, 1032, 1036, 0, 0,10649, 0,10377, - 921, 470, 8743, 8429, 0, 374, 1037, 1045, -38, 924, - 0, 0,10649, 0,10649, 1026, 0, 0, 0, 0, - 8,10513, 0, 0, 0, 0, 7801, 0, 1051, 0, - 512,10649, 943, 8412, 944, 0, 0, 94, 0, 168, - 0, 0, 746, 833, 0, 94, 0, -161, 0, 0, - 0, 945, 0, 972, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 546, 0, 0, 0, 0, 8586, 0, - 0, 94, 940, 892, 0,10649, 0,10649, 0,10649, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 949, - 747, 0, 0,10921, 0, 0, 0, 950, 7525, 0, - 815, 0, 815, 0, 815, 0, 0, 0, 0, 94, - 946, 921, 0, 0, 0, -168, -164, 952, 954, 0, - 0, 0, 0, 0, 947, 8412, 892, -195,10649, 0, - 955, 6880, 0, 0, 0, 0, 0, 0, 959, 0, - 708, 0, 0, 0, 0, 0, -198, 0, 958, 746, - 833, 0, 833, 0, 892, 960, 0, 0, 323, 0, - 901, 956, 0, 0, 0,10649, 986,10649, 0,10649, - 984, 215, 0, 856, 259, 592, 0, 0, 0, 0, - 146, 0, 0, 0, 967, 0, 0, 0, 957, 0, - 0, 0, 301, 0, 961, 1080, 1084, 0, 0, 892, - 971, 892, 0, 965, 0, 0, 0, 0, 0,10649, - 0, 978, -163, 0, -163, 0, 0, 0, 0, 0, - 0, 323, 0,10649, 7960, 0, 0, 1000, 624, 975, - 0,10649, 0, 980, 0, 0,10921, 12, -159, 0, - 976, 976, 976,10377, 982, 0,10649, 0, 0, 0, - 0, 0, 6880, 979, 0, 0, 7037, 0, 992, 6880, - 0, 990, 0,10649, 0, 0, 0, 0, 0, 0, -10649, 0, 0, 264, 981, 264, 7682, -150, -150, -150, - 0, 0,10649, 0, 6880,10649, 0, 0, 7037, 0, - 0, 0, 0, 1013,10649,10649, 0, 264, 994, 0, - 948, 0, 991, 0, 0, 0, 995, 0, 0, 964, - 0, 1029, 0, 0, 0, 0, 0, 998, 865, 0, - 7037, 0, 1025, 0, 999, -150, 0, 1006, 264, 7682, - 1001, 1010, 0, 1011, 1016, 0, 1027,10649, 0, 0, - 0, 0, 1015, 999, 0, 0,11625, -77, 264, 0, - 6880, 0, 1041,10649, 1022,10649, 0, 0, 1028, 0, - 0, 1030, 0, 0,12753, 0, 1033, -77, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 429, -12753, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 1035, 264, 0, -77, 0, 94, 0, 1041, 0, 0, - 1034,11625,11791, 0, 0, 432, 0, 0, 0,11823, - 0, 0, 1039, 0, 0, 0, 0, 8429, 8429, 228, - 8586, 258, 331, 1063, 0, -277, 9633, 0, 1103, 0, - 0, 999, 0, 0, 0, 999, 0, 993, 997, 0, - 8429, -162, 0, 8429, 0, 1008, 1038, 0, -277, 0, - 1042, 9076, 0, 1043, 1009, 65, 440, 3619, 0, 0, - 999, 0, -277, 0, 1049, 1012, 1058, 1057, 0, 1064, - 997, 1065, -159, 1053, 1066, 0, 1067, 1070, 0, 746, - 0, 607, 0, 0, 0, 1069, 0, -153, 0, 1060, - 0, 0, 1073, 0, 1072, 1074, 1075, 0, 1071, 0, - -159, -159, 0, -159, 1077, 1078, 0, 0, 0, 0, - 1079, 51, 0, 1082, -159, 1154, 1083, -159, 0, 432, - 0, 8412, 1040, 1068, 1071, 0, 1076, 1087, 52, 1091, - 0, 0, -159,10377, 1044, 1090, 1079, 0, 0,12753, - 0, 264, 264, 0, 1052, 1093, 1082, 0, 1095, 0, -10649, 1055, 1098, 1083, 0, 1106, -159, 0, -173, 0, - 1094, 0, 0, 0, 0, 0,12753, 0, 52, 52, - 1085, 1107, 0, -153, 0, 0, -154, 1112,12753, 0, -12753, 0, 0, 8412, 1100, 0, 0, 0, 1113, 1073, - 0, 0, 0, 1110, 0, 69, 0, 0, 0, -150, - 721, 1116, 0, 0, 0, 0, 0, 0, 0, 0, - 1170, 1223, 0, 0, 0, 0, 0, 0, 1117, 1118, - 8412, 0, 0, 0, 0, 52, 502, 502, 0, -150, - 0, 0, 0, 56, 56, 0, 0, 0, 0, 0, - 0, 0, 9833, 9833, 0, 0, 0, 0, 0, 1119, - 1120, 1121, 0, 0, 0, - }; - protected static readonly short [] yyRindex = { 2853, - 0, 0, 7194, 2853, 0, 0, 0, 1494, 0, 0, - 3006, 2784, 0, 0, 0, 0, 0, 3006, 0, 0, - 42, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, -146, 138,12032, 0, 8590,11135, 740, + 0, 0, 750,11135,11135, 4875, 157, -165, 764, 8747, + 0,11815, 258, 0, 762, 0, 789, 8590,11135, 0, + 826, 442, -255, 0,11135, 429,10591, 0, 0, 458, +11135, 458, 228, 443, 848, -8, 0, 617, 387, 851, + -8,11135,11135,11135, 420, 0, 818, 0, 7198, -50, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 1495, 0, 0, 1495, 0, 0, 1494, - 3049, 2900, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 1129, 0, 0, 0, 0, 0, 0, 0, 0, -12119, 0, 1122, 0, 0, 0, 1122, 0, 0, 0, - 0, 0, 0, -241, 0, 0, 0, 0, 0, 0, - 0, 0, 66, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 4583, 0, 0, 0, 0, - 0, 0, -237, 4520, 3796, 0, 0, 4361, 0, 0, + 4491, 0, 0,12505, 228, 804, 827,11135, 0, 791, + 0, -298, 0, 0, 441, 0, 0, 786, 9044,10455, + 0, 0,11815,11135,11135,11135,11135,11135,11135,11135, +11135,11135,11135,11135,11815,11815,11815, 8590, 8590,11815, +11815,11815,11815,11815,11815,11815,11815,11815,11815,11815, +11815,11815,11815,11815,11815,11135, 0, 0, 0, 0, + 617, 0, 0, 0, 0,12594,12594, 0, 0, -8, + 0, 0, 0, 0, 469, 850, 0, 0, 0, 0, + 0, 0, 0, 367, 470, 792, 0, 795, 0, 791, + 651, 651, 0, 71, 0, 559, 651, 839, 0, -195, +13162, 0, 0, 0, 0, -164, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 202,13194, + 0, 0, 0, 0, 791, 0, 0, 837, 586, 0, + 842, 0, 847, 59, 429, 0, -255, 0, 0, 0, + -8,10591, -184, 0, 844, 0, 0, 0, -174, 58, + 0, 423, 0, 858, 0, 853, 0, 0, 0, 607, + 0, 8414, 618,11135, 764,10455, 0, 7669, 0, 458, + 0, 0, 0, 856, 63, 0, 0, 244, 429, 516, + 0, 4332, 859, 0, 65, -8, 0, 94, 0, 0, + 0,11135, 936, 0, 0, 0,11135, 939, 860, 0, + 863, 865, 0,12505, 0, 0, -182, -28, 7198, 0, + 0, 0, 0, 0, 0, 429, 0, 0, 6, 0, + 0, 0, 458, 228, -8, 8904, 0, 864, 0, 870, +11815, 0, 867, 7198, 0, -289, 0, 304, 0, 791, + 0, -65,11135,11135, 873, 992, 0, 0, -47, 883, + 0, 0, 0, 685, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 4676, 4780, - 5088, 5292, 5632, 5836, 5972, 6108, 6244, 6380, 6504, 3687, - 0, 0, 0, 0, 0, 0, 42, 0, 0, 0, + 685, 685, 89, 89, -273, -273, -273, -273, -265, -265, + 413, 529, 561, 553, 557, 0, -149, -181, 0, 9201, + 964, -8, 965, -8, 9201, 9201, 879,11135, 0, 0, + 850, 0, -8, 0, 512, 791, 0, 0, 0, 0, + 240, 367, 16, 0, 8904, 559, 0, 889, 888, 0, + 0, 0, 0, 0, 0, 228, 891, 0, 892, 897, + 0, 0, 0, 0, 893, 9061, 855, 0, 398, 0, + 0, 220, 0,11271, 0, 896, 0, 0, 0, 555, + 90, 908, 0, 907, 911, 912, 0, 0,11135, 0, + -8, 0, 0, 624, 0, 914, 0, 266, 0, 0, + 7041, 0, 7041, 8573, 0, 4875, 0, 0,10727, 161, + 0, -12, -66, 0, 862, 866, 0, -64, 0, 0, + 910, 0, 0, 0, 0, 0, 919, 0, 0, 928, + 0, 7686, 0, 429, 0, 0, 458, 463, 875, 0, + 39, 0, 925, 930, 0, 0, 7041, 0, 0, 7041, + 0,11135, 0,11135, 8590, 0, 0, 429, 926, 429, + 0, 0, 0, 0, 0, 0, 0, 0, 9201, 8590, + 0, 0, -8,12505, 961, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0,10319, 0, + 0, 0, 0, 7826, 0, 9201, 0, 7983, 931, 0, + 0, 0, 0, 1012, 0, 1014, 0, 0, 0, 652, + 0, 935, 0, 0, 0, 0, 0, 0, 894, 0, + 71, 0, 0, 0, 0, 559, 559, 0, 792, 940, + 943, 900, 948, 855, 0, 944, 0, 1064, 1065, 0, + 0,11135, 0,10863, 950, 555, 8904, 8590, 0, 0, + 180, 1066, 1070, 122, 946, 0, 0, 0,11135, 0, +11135, 1049, 0, 0, 0, 0, 40,10999, 0, 0, + 0, 0, 8119, 0, 1074, 0, 617,11135, 968, 8573, + 970, 0, 0, -8, 0, 195, 0, 0, 791, 875, + 0, -8, 0, -161, 0, 0, 0, 967, 0, 997, + 0, 0, 0, 0, 0, 0, 0, 730, 0, 0, + 0, 0, 0, 8747, 0, 0, -8, 549, 931, 0, + 9201, 0, 9201, 0, 998, 9201, 0, 0, 0, 680, + 0, 0, 0, 980, 792, 0, 0,11407, 0, 0, + 0, 972, 7843, 0, 855, 0, 855, 0, 855, 0, + 0, 0, 0, -8, 975, 950, 0, 0, 0, -162, + -156, 978, 979, 0, 0, 0, 0, 0, 981, 8573, + 931, -181,11135, 0, 983, 7041, 0, 0, 0, 0, + 0, 0, 986, 0, 764, 0, 0, 0, 0, 0, + -189, 0, 987, 791, 875, 0, 875, 0, 931, 988, + 0, 0, 429, 0, 938, 977, 0, 0, 0, 0, + 0, 9201, 1015, 9201, 9201, 0,11135, 0, 0, 897, + 239, 731, 0, 0, 0, 0, -38, 0, 0, 0, + 1002, 0, 0, 0, 989, 0, 0, 0, 523, 0, + 990, 1116, 1117, 0, 0, 931, 1003, 931, 1005, 0, + 1006, 0, 0, 0, 0, 0,11135, 0, 1013, -154, + 0, -154, 0, 0, 0, 0, 0, 0, 429, 0, +11135, 8278, 0, 0, 1027, 0, 736, 1009, 0, 1016, + 0, 0,11407, 249, 59, 0, 1017, 1017, 1017,10863, + 1018, 0,11135, 0, 0, 0, 0, 0, 0, 7041, + -80, 0, 0, 7198, 0, 743, 7041, 0, 1019, 0, + 9201, 0, 0, 0, 0, 0,11135, 0, 0, 367, + 1026, 367, 8590, 1045, 1045, 1045, 0, 0,11135, 0, + 7041, 9358, 0, 0, 0, 7198, 0, 0, 0, 0, + 0, 1043, 9201,11135, 0, 367, 1029, 0, 982, 0, + 1028, 0, 0, 38, 0, 985, 0, 1045, 0, 0, + 0, 0, 0, 0, 0, 1032, 914, 0, 7198, 0, + 1051, 0, 1030, 1045, 0, 1033, 367, 0, 8590, -76, + 1038, 0, 1041, 1044, 7041, 1042, 9201, 0, 0, 0, + 0, 1031, 1030, 0, 0, 0,12111, 120, 367, 0, + 0, 0, 1059, 9201, 1040,11135, 0, 0, 1046, 0, + 0, 1047, 0, 0,13194, 800, 0, 1050, 120, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 208, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 764, 764, 3092, 0, - 539, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 540,13194, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1054, 367, 0, 120, -8, 0, 1059, 0, + 0, 1061,12111,12277, 0, 0, 0, 27, 0, 0, + 0,12309, 0, 0, 1055, 0, 0, 0, 0, 8590, + 8590, 309, 8747, 312, 458, 1082, 0, 228, 4646, 0, + 1129, 0, 0, 1030, 0, 0, 0, 1030, 0, 1021, + 1034, 0, 8590, -147, 0, 8590, 0, 1056, 1072, 0, + 228, 0, 62, 5003, 0, 1067, 1057, 24, 511, 3907, + 0, 0, 1030, 0, 228, 0, 1068, 1058, 1073, 1071, + 0, 1075, 1034, 1078, 59, 1080, 1083, 0, 0, 1091, + 1097, 0, 791, 0, 766, 0, 0, 0, 1096, 0, + -97, 0, 1087, 0, 0, 1103, 0, 1107, 1108, 1110, + 0, 1063, 0, 59, 59, 0, 59, 1106, 1112, 0, + 0, 0, 0, 1109, 127, 0, 1115, 59, 1234, 1118, + 59, 0, 27, 0, 8573, 1079, 1120, 1063, 0, 1119, + 1121, 129, 1128, 0, 0, 59,10863, 1084, 1125, 1109, + 0, 0,13194, 0, 367, 367, 0, 1085, 1130, 1115, + 0, 1132, 0,11135, 1090, 1133, 1118, 0, 1139, 59, + 0, -74, 0, 1124, 0, 0, 0, 0, 0,13194, + 0, 129, 129, 1145, 1141, 0, -97, 0, 0, 106, + 1146,13194, 0,13194, 0, 0, 8573, 1134, 0, 0, + 0, 1149, 1103, 0, 0, 0, 1151, 0, 445, 0, + 0, 0, 1045, 794, 1150, 0, 0, 0, 0, 0, + 0, 0, 0, 1206, 1261, 0, 0, 0, 0, 0, + 0, 1155, 1157, 8573, 0, 0, 0, 0, 129, 542, + 542, 0, 1045, 0, 0, 0, -79, -79, 0, 0, + 0, 0, 0, 0, 0,10455,10455, 0, 0, 0, + 0, 0, 1161, 1158, 1159, 0, 0, 0, + }; + protected static readonly short [] yyRindex = { 1916, + 0, 0, 7355, 1916, 0, 0, 0, 1532, 0, 0, + 3243, 1827, 0, 0, 0, 0, 0, 3243, 0, 0, + 55, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1533, 0, 0, 1533, 0, 0, 1532, + 3286, 3157, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1167, 0, 0, 0, 0, 0, 0, 0, 0, + 9218, 0, 1160, 0, 0, 0, 1160, 0, 0, 0, + 0, 0, 0, -280, 0, 0, 0, 0, 0, 0, + 0, 0, 234, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 4714, 0, 0, 0, 0, + 0, 0, 182, 4873, 4084, 0, 0, 4649, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 1495, 272, 0, 0, 0, 0, 0, 0, - 0, 3135, 283, 3178, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 5029, 5097, + 5441, 5645, 5985, 6189, 6325, 6461, 6597, 1264, 1413, 2967, + 0, 0, 0, 0, 0, 0, 55, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 3407, 0, 0, 0, 0, + 0, 0, 207, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 3329, 0, + 599, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1533, 136, 0, 0, 0, 0, 0, 0, + 0, 3372, 355, 3415, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 1131, 0, 0, 0, 0, 0, - 3407, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 2075, 0, 1193, 520, - 2205, 0, 0, 0, 2335, 2205, 0, 0, 0, 0, - 0, 1129, 0, 0, 0, 120, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 3695, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 1125, 2439, 0, 0, 1122, 0, 3407, 0, 0, 0, - 0, 0, 0, 0, 0, 0, -42, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1172, 0, 0, 0, 0, + 0, 0, 3695, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 2517, + 0, 3027, 119, 2647, 0, 0, 0, 2777, 2647, 0, + 0, 0, 0, 0, 1167, 0, 0, 0, 51, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 1468, 0, 0, + 0, 0, 0, 1163, 2881, 0, 0, 1160, 0, 3695, + 0, 0, 0, 0, 0, 0, 0, 0, 0, -41, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 46, 0, 0, 0, 0, 0, 0, 0, 3241, 2608, - 0, 0, 0, 0, 1929, 1495, 1495, 0, -204, 0, - 7977, 1495, 1500, 0, 0, 131, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 403,11478, 0, 0, 0, 3407, 0, - 0, 0, 0, 0, 0, 0, 0,11867, 0, 0, - 0, 0, 0, 0, 1128, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 676, 749, 0, 0, 1133, 0, - 0, 0, 0, 0, 137, 0, 0, 3884, 1135, 0, - 0, 0, 340, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 1636, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 1125, 0, 0, 6563, - 0, 147, 0, 0, 0, 0, 0, 0, 8883, 0, - 0, 0, 0, 0, 0, -167, 522, 0, 0, 0, - 1136, 0, 0, 0, 0, 0, 0, 0, 3407, 0, - 3407, 0, 4043, 0, 0, 0, 0, 129, 0, 0, - 0, 0, 35, 0, 0, 0, 4848, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 4952, 5020, 5156, 5224, 5360, 5428, 5496, - 5564, 5700, 5768, 5904, 6040, 6176, 6312, 6436, 0, 0, - 614, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 4005, 0, 0, 1929, 0, 0, 0, 0, - 1092, 0, 0, 0,12136, 0, 0, 664, 0, 0, - 0, 0, 0, 0, 681, 653, 0, 0, 1141, 0, - 0, 0, 0, 1138, 0, 0, 0, 0, 0, 0, -11057, 0, 0, 0, 687, 0, 0, 0,12190, 0, - 0, 701, 719, 723, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 1137, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 1144, 0, 0, 0, 3473, 0, - 0, 158, 0, 60, 3566, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 1146, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 202, 561, 0, 0, 0, - 0, 0, 1143, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 8883, 0, + 1656, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 3975, 0, 0, 0, 0, + 0, 0, 0, 3482, 3529, 0, 0, 0, 0, 2371, + 1533, 1533, 0, -132, 0, 8000, 1533, 1541, 0, 0, + 197, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 417,11964, + 0, 0, 0, 0, 3695, 0, 0, 0, 0, 0, + 0, 0, 0,12353, 0, 0, 0, 0, 0, 0, + 0, 637, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 591, 973, 0, 0, 1176, 0, 0, 0, 0, + 0, 140, 0, 0, 4172, 1173, 0, 0, 0, 407, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 2078, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1163, 0, 0, 6724, 0, 145, 0, + 0, 0, 0, 0, 0, 9515, 0, 0, 0, 0, + 0, 0, -158, 380, 0, 0, 0, 1174, 0, 0, + 0, 0, 0, 0, 0, 3695, 0, 3695, 0, 4331, + 0, 0, 0, 0, -284, 0, 0, 0, 0, 130, + 0, 0, 0, 5201, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 155, 0, 0, 0, 1142, 0, 0, 0, - 0, 0, 0, 239, 0, 305, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, -204, 0, 0, 0, - 0,12190, 8134, 0, 1147, 0, 575, 0, 0, 0, - 0, 1152, 0, 1102, 1104, 0, 0, 0, 0, 0, - 1145,12214, 0, 0, 0,11943, 0, 0, 0, 729, - 0, 0, 0, 0, 0, 1803, 0, 0, 0, 0, + 5269, 5373, 5509, 5577, 5713, 5781, 5849, 5917, 6053, 6121, + 6257, 6393, 6529, 6665, 1918, 0, 0, 563, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 3725, 0, 4202, 1155, 0, 0, 0, 1153, 0, 0, - 0, 0, 179, 0, 0, 0, 0, 729, 0, 0, + 3975, 0, 0, 0, 0, 2371, 0, 0, 0, 0, + 1131, 9719, 0, 0, 0, 9375, 0, 0, 737, 0, + 0, 0, 0, 0, 0, 693, -247, 0, 0, 1177, + 0, 0, 0, 0, 1181, 0, 0, 0, 0, 0, + 0,11543, 0, 0, 0, 741, 0, 0, 0,12618, +12429, 0, 0, 752, 757, 768, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 640, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1183, 0, 0, 0, 3761, + 0, 0, 151, 0, 57, 3854, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1184, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 236, 709, 0, 0, + 0, 0, 0, 1182, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 9515, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 1148, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 733, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 606, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, -186, + 0, 504, 0, 0, 0, 0, 0, 0, 0, 0, + -132, 0, 0, 0, 0,12618, 8295, 0, 1185, 0, + 666, 0, 0, 0, 0, 1189, 0, 1140, 1142, 0, + 0, 0, 0, 0, 1186,12672, 0, 0, 0, 0, +12461, 0, 0, 0, 769, 0, 0, 0, 0, 0, + 0, 2245, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 4013, 0, 4490, 1191, + 0, 0, 0, 1192, 0, 0, 0, 0, 318, 0, + 0, 0, 0, 769, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 1151, 0, 0, 0, 0, 0, 736, 740, 0, - 0, 0, 0, 0, 0, 0, 1156, 614, 1157, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 579, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 3884, 0, 0, 0, 0, 0, 1161, 0, 0, 179, - 0, 0, 765, 0, 1156, 0, 0, 0, 8883, 0, - 528, 621, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 93, 0, 1141, 9077, 0, 0, 0, 0, 0, -12262, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 636, 0, 692, 0, 0, 0, 0, 1158, - 0, 1142, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 1163, 0, 7351, 0, 0, 0, 0, 0, - 0, 8883, 0, 0, 0, 0, 0, 0, 420, 608, - 0, 0, 0, 0, 0, 0, 0,12305,11867, 0, - 79, 79, 79, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 778, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1193, 0, 0, 0, 0, + 0, 784, 785, 0, 0, 0, 0, 0, 0, 0, + 1195, 649, 1194, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 4172, 0, 0, 0, 0, 0, + 1197, 0, 0, 318, 0, 0, 816, 0, 1195, 0, + 0, 0, 9515, 0, 572, 595, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1177, + 9565, 0, 0, 0, 0, 0,12714, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 665, 0, + 678, 0, 0, 0, 0, 1199, 0, 671, 1198, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1212, + 0, 7512, 0, 0, 0, 0, 0, 0, 9515, 0, + 0, 0, 0, 0, 0, 0, 294, 550, 0, 0, + 0, 0, 0,12790,12353, 0, 371, 371, 371, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0,12416, 0, -50, 0, 1168, 1168, 1168, - 0, 0, 0, 0, 0, 1164, 0, 0, -221, 0, - 0, 0, 0, 0, 0, 0, 0,12459, 0, 0, - 0, 0, 1182, 0, 0, 0, 114, 0, 0, 0, - 0, 538, 0, 0, 0, 0, 0, 0, 1179, 0, - 1184, 0, 0, 0, 2963, 1177, -251, 0, 164, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 2721, 0, 0, 0, 9231, 9429, 0, - 0, 0, 689, 0, 0, 0, 0, 0, 0, 0, - 0, 265, 0, 0,11649, 0, 0, 9330, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0,12895, + 0, -271, 0, 1214, 1214, 1214, 0, 0, 0, 0, + 0, 1210, 0, 0, 0, -157, 0, 0, 0, 0, + 0, 0, 0, 0, 0,12938, 0, 0, 0, 0, + 1217, 0, 0, 375, 0, 0, 0, 544, 0, 0, + 0, 0, 0, 0, 0, 0, 1216, 0, 1218, 0, + 0, 0, 3200, 1213, 414, 0, -14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -11717, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 9523, 0, 9231, 0, 0, 0, 689, 0, 0, - 0, 0, 403, 0, 0, 0, 0, 0, 0, 403, + 0, 0, 1553, 0, 0, 0, 0, 9824,10022, 0, + 0, 0, 641, 0, 0, 0, 0, 0, 0, 0, + 0, 534, 0, 0,12135,10116, 0, 0, 9923, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 893, 428, 0, 9565, 0, 0, 0, 4517, - 0, 2721, 0, 0, 0, 2721, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 596, 0, - 1187, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 2721, 0, 631, 0, 462, 0, 0, 0, 0, 0, - 0, 0,11867, 745, 0, 0, 0, 0, 0, 1185, - 0, 613, 0, 0, 0, 0, 0, 0, 0, 751, - 0, 0, 0, 0, 0, 0, 0, 0, 1181, 0, -11867,11867, 0,11899, 0, 0, 0, 0, 0, 0, - 1183,12683, 0, 1186,11867,11193, 1190,11867, 0, 0, - 0, 0, 0, 0, 1197, 0, 0, 0,12653, 0, - 0, 0,11867, 0, 0, 0, 1198, 0, 0, 54, - 0,12577,12615, 0, 0, 0, 1204, 0, 0, 0, - 0, 0, 0, 1205, 0, 0,11867, 0, 549, 0, - 756, 0, 0, 0, 0, 0, 779, 0,12501,12539, - 0, 0, 0, 0, 0, 0, 0, 0, 1240, 0, - 1322, 0, 0, 0, 759, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 550, + 0, 0,12203, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0,10202, 0, 9824, 0, 0, 641, 0, + 0, 0, 0, 417, 0, 0, 0, 0, 0, 0, + 0, 417, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 744, 433, 0,10244, 0, 0, + 0, 1148, 0, 1553, 0, 0, 0, 1553, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 190, 0, 1224, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1553, 0, 763, 0, 623, 0, 0, 0, + 0, 0, 0, 0,12353, 790, 0, 0, 0, 0, + 0, 0, 1188, 0, 221, 0, 0, 0, 0, 0, + 0, 0, 798, 0, 0, 0, 0, 0, 0, 0, + 0, 1219, 0,12353,12353, 0,12385, 0, 0, 0, + 0, 0, 0, 1220,13132, 0, 1221,12353,11679, 1222, +12353, 0, 0, 0, 0, 0, 0, 1229, 0, 0, + 0, 1266, 0, 0, 0,12353, 0, 0, 0, 1230, + 0, 0, 232, 0,13056,13094, 0, 0, 0, 1231, + 0, 0, 0, 0, 0, 0, 1245, 0, 0,12353, + 0, 554, 0, 803, 0, 0, 0, 0, 0, 828, + 0,12980,13018, 0, 0, 0, 0, 0, 0, 0, + 0, 1277, 0, 1330, 0, 0, 0, 811, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0,12653,11365,12373, 0, 550, + 0, 0, 556, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 1135, 1135, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1266,11851, +12832, 0, 556, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1173, 1173, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, }; protected static readonly short [] yyGindex = { 0, - 0, 1534, 0, 0, 0, 1, -9, -176, -48, 1535, - 0, 1583, 1592, 641, 0, -6, 0, 0, 0, 0, - 0,-1002, -704, -217, -388, 0, 0, 0, 0, 0, - -191, 0, 0, 0, 657, 0, 766, 0, 0, 0, - 0, 515, 516, -17, -223, 0, -62, 0, 355, 0, - 386, -743, -708, -605, -575, -568, -564, -547, -540, 0, --1138, 0, 30, 0, 53, 0,-1065, 0, 0, 0, - 111, 181, 0, 0, 0, 220,-1057, 0, -270, -297, - 933, 0, 0, 0, -892, 170, 0, 0, -500, 0, - 0, 237, 0, 0, 209, 0, 0, 245, 0, -791, - -548, 0, 0, 0, 0, 0, 339, -13, 0, 0, - 761, 762, 763, 931, -530, 0, 0, -313, 772, 337, - 0, -875, 0, 0, 0, 0, 0, 0, 0, 0, - 142, 0, 0, 0, 0, 0, 0, 0, 0, 387, - 0, 0, 0, 0, -332, 324, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 400, 0, -502, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 156, 0, 0, - 241, 0, 0, 247, 242, 161, 0, 0, 0, 0, - 0, 0, 0, 0, 463, 0, 0, 0, 0, -58, - 0, -12, 26, 0, 0, 311, 0, 364, 0, 818, - 0, 1123, -289, -263, -64, 399, 0, 464, 0, -30, - 112, 0, 0, 916, 0, 0, 0, 0, 0, 0, + 0, 1544, 0, 0, 0, -2, -9, -179, -48, -43, + 0, 1588, 1617, 589, 0, 3, 0, 0, 0, 0, + 0,-1109, -711, -213, -432, 0, 0, 0, 0, 0, + -228, 0, 0, 0, 668, 0, 775, 0, 0, 0, + 0, 524, 530, -17, -236, 0, -46, 0, 359, 0, + 396,-1114, -607, -598, -534, -519, -516, -513, -500, 0, + 0,-1173, 0, 1, 0, 86, 0,-1098, 0, 0, + 0, -44, 179, 0, 0, 0, 227,-1059, 0, -272, + -279, 955, 0, 0, 0, -894, 181, 0, 0, -505, + 0, 0, 245, 0, 0, 215, 0, 0, 252, 0, + -721, -968, 0, 0, 0, 0, 0, 349, -13, 0, + 0, 779, 780, 782, 949, -537, 0, 0, -323, 796, + 341, 0,-1330, 0, 0, 0, 0, 0, 0, 0, + 0, 149, 0, 0, 0, 0, 0, 0, 0, 0, + 394, 0, 0, 0, 0, -339, 331, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 408, 0, -515, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 165, 0, + 0, 248, 0, 0, 254, 256, 172, 0, 0, 0, + 0, 0, 0, 0, 0, 477, 0, 0, 0, 0, + -42, 0, 373, -138, 0, 0, 320, 0, 377, 0, + 838, 0, 1153, -295, -263, -63, 1025, 0, 479, 0, + -33, 112, 0, 0, 1152, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - -260, 0, 1206, 0, 0, -535, 0, 0, 0, 770, - 0, -296, -134, 936, 857, 0, 858, 0, 1062, 1290, - 974, 0, 0, 669, 1593, 0, 0, 0, 0, 951, - 0, 0, 0, 0, 0, -523, 1331, 0, 0, 0, - 0, 0, 1321, 404, 758, 690, 757, 1268, 1271, 1272, - 1273, 1274, 0, 1270, 0, 0, 0, 896, 1130, -728, + 0, -262, 0, 1209, 0, 0, -130, 0, 0, 0, + 799, 0, -302, -129, 952, 874, 0, 868, 0, 1093, + 1319, 1000, 0, 0, 686, 1624, 0, 0, 0, 0, + 1008, 0, 0, 0, 0, 0, -599, 1363, 0, 0, + 0, 0, 0, 1327, 343, 806, 704, 802, 1315, 1298, + 1333, 1335, 1332, 0, 1334, 0, -608, 0, 0, 947, + 1190, -747, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, -294, 0, 0, 0, 0, -454, 0, 562, + 0, 472, 0, 558, 0, 0, 0, 619, -530, -5, + -314, -3, 0, 1585, 0, 46, 0, 82, 84, 85, + 91, 117, 118, 125, 126, 132, 134, 0, -664, 0, + -27, 0, 0, 758, 0, 681, 0, 0, 0, 0, + 659, -145, 734, -870, 0, 797, -468, 0, 0, 0, + 0, 0, 0, 674, 0, 0, 673, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, -287, 0, 0, 0, 0, -449, 0, 519, 0, - 426, 0, 511, 0, 0, 0, 576, -531, -15, -314, - -5, 0, 1527, 0, 64, 0, 68, 74, 90, 103, - 110, 116, 121, 132, 141, 145, 0, -658, 0, -11, - 0, 0, 707, 0, 634, 0, 0, 0, 622, -252, - 693, -842, 0, 732, -457, 0, 0, 0, 0, 0, - 0, 633, 0, 0, 635, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 563, - 0, 0, 0, 0, 0, 0, 0, 0, -27, 0, - 1178, 0, 0, 0, 804, 0, 0, 0, 0, 0, - 0, -171, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 1285, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 459, 0, 0, 0, 0, 0, 0, - 0, 0, 579, 0, 0, 0, 0, 0, 0, -7, - 898, 0, 0, 0, 902, + 0, 0, 604, 0, 0, 0, 0, 0, 0, 0, + 0, -19, 0, 1228, 0, 0, 0, 857, 0, 0, + 0, 0, 0, 0, -170, 0, 0, 0, 0, 0, + 1345, 1123, 0, 0, 0, 1347, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 506, 0, 0, 0, 0, + 0, 0, 0, 0, 614, 0, 0, 0, 0, 0, + 0, 2, 929, 0, 0, 0, 933, }; protected static readonly short [] yyTable = { 109, - 512, 155, 233, 111, 18, 292, 730, 194, 189, 515, - 735, 156, 429, 192, 447, 679, 428, 488, 570, 316, - 774, 555, 404, 471, 322, 327, 1011, 701, 257, 334, - 531, 885, 542, 508, 496, 43, 1131, 569, 782, 229, - 905, 938, 467, 14, 251, 787, 785, 259, 361, 308, - 369, 866, 332, 867, 360, 302, 368, 1059, 504, 302, - 805, 537, 411, 1164, 1165, 309, 411, 311, 770, 1060, - 706, 288, 876, 1, 194, 194, 1253, 337, 557, 289, - 160, 1014, 1445, 190, 161, 672, 650, 1042, 359, 46, - 162, 1044, 1260, 1318, 1004, 194, 687, 897, 480, 675, - 899, 46, 1359, 676, 1060, 1159, 163, 662, 1458, 406, - 1192, 779, 709, 347, 431, 711, 316, 521, 295, 164, - 296, 732, 316, 829, 347, 323, 165, 732, 115, 317, - 6, 323, 166, 663, 743, 558, 348, 167, 290, 109, - 233, 155, 471, 111, 632, 412, 785, 348, 168, 412, - 413, 156, 414, 780, 413, 346, 414, 169, 415, 416, - 1459, 170, 415, 416, 677, 664, 290, 793, 738, 505, - 115, 506, 1191, 249, 115, 2, 732, 290, 1214, 755, - 323, 688, 481, 446, 472, 806, 194, 194, 1160, 758, - 877, 1207, 749, 291, 333, 359, 476, 323, 328, 231, - 785, 1446, 359, 347, 359, 15, 359, 1014, 724, 231, - 728, 447, 868, 46, 570, 438, 432, 974, 353, 976, - 160, 291, 250, 1061, 161, 507, 348, 1360, 710, 470, - 162, 712, 291, 569, 475, 417, 570, 555, 467, 427, - 349, 3, 4, 5, 6, 191, 163, 673, 194, 1043, - 359, 1427, 530, 1045, 257, 1319, 534, 444, 1061, 164, - 536, 539, 555, 880, 257, 541, 165, 538, 115, 665, - 487, 345, 166, 484, 194, 491, 493, 167, 1451, 1309, - 1073, 794, 385, 1310, 739, 683, 194, 800, 168, 518, - 1461, 231, 1462, 194, 526, 756, 528, 169, 938, 527, - 491, 170, 529, 472, 472, 759, 1389, 1416, 1337, 436, - 437, 1495, 544, 545, 20, 938, 635, 311, 386, 1084, - 554, 570, 966, 1056, 1468, 880, 1423, 576, 354, 446, - 556, 737, 1469, 975, 654, 194, 985, 302, 194, 249, - 16, 830, 749, 1111, 801, 432, 20, 994, 470, 590, - 634, 636, 638, 598, 599, 600, 601, 602, 603, 604, - 605, 606, 607, 608, 346, 389, 390, 46, 635, 655, - 1002, 477, 194, 194, 443, 983, 355, 432, 1292, 737, - 233, 882, 578, 995, 1472, 630, 446, 6, 250, 1331, - 651, 640, 641, 1470, 892, 892, 115, 486, 387, 388, - 194, 194, 635, 771, 44, 980, 447, 635, 196, 859, - 433, 635, 347, 434, 1492, 113, 517, 654, 194, 231, - 231, 698, 94, 707, 645, 115, 635, 938, 648, 649, - 346, 1496, 194, 938, 660, 348, 48, 356, 666, 881, - 737, 891, 891, 882, 1137, 654, 472, 115, 873, 349, - 570, 1142, 655, 635, 496, 1233, 290, 113, 561, 471, - 647, 113, 748, 447, 772, 696, 757, 42, 872, 569, - 411, 642, 635, 700, 892, 1049, 1167, 1068, 347, 1069, - 655, 864, 1332, 1290, 290, 326, 326, 678, 409, 726, - 1234, 590, 846, 733, 680, 612, 613, 1314, 1233, 847, - 622, 348, 622, 2, 434, 781, 326, 740, 742, 874, - 1327, 291, 750, 1293, 679, 349, 54, 760, 747, 865, - 570, 891, 762, 635, 637, 435, 451, 345, 451, 1345, - 290, 313, 1291, 1234, 194, 330, 554, 199, 964, 893, - 1125, 410, 1245, 1453, 1454, 775, 556, 330, 678, 482, - 330, 330, 959, 412, 635, 113, 194, 622, 413, 635, - 414, 554, 1294, 635, 330, 434, 415, 416, 795, 795, - 725, 556, 810, 352, 812, 679, 244, 922, 635, 915, - 724, 46, 922, 451, 922, 1000, 435, 922, 922, 878, - 922, 922, 432, 1235, 248, 357, 115, 326, 326, 736, - 1486, 346, 483, 661, 789, 635, 791, 774, 792, 843, - 345, 200, 922, 827, 245, 808, 401, 990, 246, 352, - 472, 814, 94, 1236, 635, 725, 249, 260, 402, 515, - 1237, 661, 231, 844, 1238, 358, 1235, 861, 345, 1085, - 661, 194, 345, 916, 345, 345, 345, 345, 916, 347, - 916, 1239, 345, 916, 916, 828, 916, 916, 1240, 326, - 845, 197, 194, 115, 315, 470, 1236, 922, 247, 1095, - 713, 822, 348, 1237, 633, 250, 262, 1238, 701, 491, - 347, 1096, 534, 113, 257, 326, 349, 894, 115, 94, - 432, 1053, 197, 728, 1239, 733, 520, 326, 633, 634, - 726, 1240, 358, 348, 326, 842, 357, 347, 357, 521, - 357, 357, 113, 357, 968, 357, 315, 349, 359, 910, - 1030, 329, 348, 634, 1050, 633, 522, 348, 194, 889, - 348, 315, 358, 916, 113, 472, 788, 579, 358, 357, - 472, 790, 231, 900, 349, 901, 326, 580, 433, 326, - 634, 194, 1050, 903, 890, 775, 936, 357, 925, 357, - 907, 315, 357, 925, 823, 925, 194, 315, 925, 925, - 194, 925, 925, 597, 1347, 563, 824, 852, 651, 225, - 590, 226, 564, 326, 326, 590, 917, 581, 733, 1104, - 614, 615, 555, 925, 565, 1140, 959, 582, 94, 934, - 935, 563, 1377, 1378, 1257, 1380, 94, 1283, 564, 1216, - 1232, 326, 326, 736, 501, 1333, 1399, 370, 502, 1406, - 565, 115, 194, 115, 555, 998, 1134, 1001, 666, 1216, - 956, 412, 487, 1003, 1422, 276, 413, 276, 414, 397, - 194, 194, 276, 398, 415, 416, 433, 981, 925, 821, - 1083, 888, 679, 1232, 984, 1216, 555, 682, 1444, 1012, - 399, 683, 1166, 1030, 992, 400, 733, 115, 94, 948, - 115, 1410, 391, 392, 902, 716, 330, 1190, 330, 717, - 296, 472, 330, 113, 330, 435, 393, 394, 330, 909, - 330, 330, 330, 598, 330, 598, 225, 1039, 228, 763, - 249, 763, 362, 763, 657, 330, 194, 330, 1015, 439, - 1017, 330, 1019, 657, 330, 266, 656, 1010, 647, 803, - 1280, 363, 364, 326, 266, 656, 1029, 1280, 194, 323, - 447, 403, 323, 1463, 666, 1250, 194, 330, 725, 330, - 736, 365, 502, 225, 64, 326, 918, 1148, 64, 250, - 113, 918, 366, 918, 395, 396, 918, 918, 733, 918, - 918, 491, 335, 1086, 967, 1087, 335, 326, 330, 113, - 1483, 113, 931, 932, 258, 113, 113, 1116, 1117, 345, - 1036, 515, 1037, 345, 1038, 330, 345, 742, 345, 742, - 1501, 1502, 752, 345, 752, 775, 752, 335, 1076, 442, - 1078, 335, 1079, 330, 335, 165, 335, 165, 258, 165, - 335, 335, 258, 258, 258, 258, 258, 258, 258, 258, - 348, 439, 63, 63, 472, 822, 63, 912, 382, 383, - 384, 1088, 912, 958, 912, 958, 918, 912, 912, 468, - 912, 912, 487, 494, 469, 335, 330, 332, 330, 494, - 330, 330, 326, 330, 330, 55, 1112, 733, 775, 1034, - 754, 177, 754, 177, 1119, 177, 489, 330, 330, 1029, - 153, 490, 153, 326, 511, 233, 487, 1151, 1124, 487, - 618, 619, 620, 621, 1473, 1474, 959, 330, 160, 359, - 160, 554, 161, 115, 161, 330, 1144, 516, 330, 233, - 869, 556, 869, 1147, 66, 183, 66, 183, 113, 154, - 113, 154, 891, 891, 194, 487, 495, 912, 118, 409, - 118, 409, 495, 554, 281, 519, 281, 1173, 1079, 125, - 1151, 125, 288, 556, 288, 535, 518, 518, 540, 326, - 409, 409, 635, 635, 1129, 1130, 616, 617, 548, 1215, - 1231, 622, 623, 352, 113, 554, 574, 113, 575, 348, - 409, 583, 326, 661, 352, 556, 681, 194, 409, 1215, - 1203, 409, 646, 684, 686, 708, 352, 326, 714, 737, - 715, 326, 761, 1264, 194, 754, 1248, 763, 487, 352, - 764, 765, 355, 1231, 352, 1215, 766, 228, 784, 352, - 258, 352, 352, 352, 352, 783, 786, 798, 799, 352, - 258, 803, 809, 352, 115, 258, 811, 352, 115, 813, - 804, 115, 819, 831, 832, 352, 433, 834, 352, 835, - 352, 838, 42, 855, 856, 850, 857, 858, 863, 194, - 194, 862, 1285, 879, 196, 883, 115, 194, 884, 886, - 115, 326, 326, 891, 352, 194, 194, 895, 194, 896, - 912, 904, 927, 929, 1305, 922, 261, 937, 933, 943, - 285, 286, 287, 944, 293, 294, 1305, 946, 194, 306, - 307, 194, 115, 947, 949, 258, 312, 952, 314, 1305, - 318, 954, 972, 1334, 960, 330, 331, 258, 258, 258, - 973, 432, 258, 258, 976, 982, 989, 1211, 1305, 505, - 352, 996, 115, 1390, 1008, 1013, 1007, 326, 1023, 367, - 1032, 1040, 1048, 1074, 1325, 1046, 1055, 1047, 1057, 1067, - 1417, 1071, 1077, 1090, 1082, 1098, 1075, 1094, 1325, 1099, - 1102, 1097, 1100, 1429, 1431, 1105, 1115, 326, 1118, 1120, - 1127, 1132, 1150, 1138, 733, 1355, 1285, 1356, 1140, 1143, - 1172, 1175, 1211, 371, 1179, 1177, 487, 1160, 1180, 1186, - 1417, 1417, 1189, 1194, 1190, 1197, 1198, 1199, 1288, 1289, - 113, 1181, 1200, 1439, 372, 373, 374, 375, 376, 377, - 378, 379, 380, 381, 1202, 1206, 1246, 1249, 1251, 1295, - 1254, 1317, 1261, 1252, 1320, 1266, 1287, 1308, 1323, 1400, - 1312, 1329, 1326, 335, 1313, 1339, 733, 338, 339, 340, - 341, 342, 343, 344, 345, 1322, 1330, 1417, 1341, 1332, - 472, 472, 1342, 1348, 1344, 1346, 1353, 1352, 1350, 1358, - 1363, 1366, 1369, 1412, 1373, 1370, 1371, 1414, 355, 1381, - 1382, 1455, 1385, 733, 355, 1395, 1402, 1411, 1415, 312, - 1421, 1424, 367, 1488, 1488, 1425, 1438, 499, 1436, 1435, - 1497, 1497, 1440, 1441, 1449, 590, 590, 1443, 1456, 1460, - 1464, 1467, 1465, 1475, 1459, 1458, 1503, 1481, 1482, 258, - 355, 1504, 1505, 9, 954, 531, 599, 839, 489, 946, - 490, 113, 509, 806, 21, 113, 446, 600, 113, 668, - 29, 488, 810, 29, 514, 525, 30, 746, 308, 204, - 756, 94, 30, 747, 847, 326, 757, 748, 779, 749, - 780, 355, 811, 113, 656, 813, 355, 113, 355, 355, - 355, 355, 355, 355, 355, 355, 355, 355, 355, 312, - 815, 678, 656, 337, 635, 355, 121, 330, 103, 355, - 355, 284, 355, 355, 355, 128, 355, 355, 355, 113, - 355, 355, 122, 104, 355, 355, 355, 355, 326, 285, - 129, 355, 355, 230, 635, 234, 355, 355, 355, 355, - 355, 355, 355, 355, 53, 326, 21, 1024, 1263, 113, - 942, 1122, 1123, 1255, 1457, 355, 1426, 840, 355, 1466, - 355, 1413, 1442, 560, 1408, 1302, 969, 970, 971, 853, - 335, 355, 24, 965, 25, 1315, 1499, 26, 1262, 1259, - 258, 1336, 27, 1430, 1491, 841, 28, 1437, 1490, 1432, - 1306, 1195, 1357, 1196, 938, 30, 988, 751, 797, 543, - 326, 326, 32, 871, 914, 585, 849, 33, 326, 1058, - 916, 34, 546, 298, 624, 869, 326, 326, 625, 326, - 626, 629, 627, 36, 628, 37, 768, 1267, 911, 38, - 1183, 1187, 1139, 405, 1052, 1101, 697, 39, 40, 326, - 543, 41, 326, 1041, 319, 1106, 1113, 1070, 1169, 1108, - 744, 1005, 609, 610, 611, 644, 1265, 543, 543, 543, - 543, 543, 543, 543, 543, 543, 543, 543, 543, 543, - 543, 543, 543, 499, 1174, 0, 741, 0, 499, 499, - 940, 0, 0, 939, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 499, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 499, 499, 0, 0, 0, 499, - 0, 0, 499, 0, 499, 352, 499, 499, 499, 499, - 0, 0, 0, 0, 499, 0, 0, 0, 499, 0, - 0, 0, 499, 0, 0, 0, 0, 0, 0, 0, - 499, 0, 773, 499, 0, 499, 499, 0, 0, 0, - 0, 499, 0, 499, 499, 499, 499, 499, 499, 499, - 499, 499, 499, 499, 0, 543, 0, 0, 0, 499, - 499, 0, 0, 0, 499, 499, 0, 499, 499, 499, - 499, 499, 499, 499, 0, 499, 499, 0, 499, 499, - 499, 499, 499, 499, 499, 499, 499, 499, 0, 499, - 499, 499, 499, 499, 499, 499, 499, 499, 499, 499, - 499, 499, 499, 499, 499, 499, 499, 499, 499, 499, - 499, 0, 0, 499, 0, 499, 0, 499, 0, 0, - 499, 841, 841, 0, 785, 0, 499, 0, 0, 841, - 841, 841, 841, 841, 0, 841, 841, 0, 841, 841, - 841, 841, 841, 841, 841, 841, 0, 0, 0, 0, - 841, 0, 841, 841, 841, 841, 841, 841, 330, 0, - 841, 0, 0, 0, 841, 841, 0, 841, 841, 841, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 841, - 0, 841, 0, 841, 841, 0, 0, 841, 0, 841, - 841, 841, 841, 841, 841, 841, 841, 841, 841, 841, - 841, 0, 841, 0, 0, 841, 841, 0, 0, 841, - 841, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 841, 841, 841, 841, 841, 0, - 0, 0, 841, 841, 0, 0, 841, 0, 0, 0, - 0, 841, 841, 841, 841, 841, 0, 0, 0, 841, - 0, 841, 0, 0, 0, 0, 0, 841, 841, 0, + 741, 18, 233, 111, 522, 473, 43, 234, 189, 434, + 477, 155, 746, 156, 577, 690, 495, 433, 452, 519, + 319, 293, 192, 712, 562, 257, 538, 407, 785, 549, + 576, 259, 921, 503, 515, 901, 827, 828, 793, 1025, + 325, 330, 326, 331, 251, 337, 1180, 1181, 229, 364, + 1147, 372, 437, 798, 955, 304, 882, 311, 883, 304, + 673, 1274, 160, 356, 544, 312, 1076, 314, 1030, 939, + 363, 717, 371, 781, 817, 14, 448, 340, 1077, 1282, + 1, 720, 739, 1210, 190, 335, 674, 627, 739, 627, + 511, 683, 20, 1058, 1018, 1211, 316, 364, 161, 1060, + 162, 163, 913, 1227, 1255, 915, 815, 164, 1340, 486, + 795, 1476, 1477, 1077, 412, 249, 394, 395, 675, 586, + 392, 393, 64, 64, 351, 409, 64, 843, 115, 587, + 396, 397, 477, 165, 166, 350, 1141, 739, 799, 109, + 233, 167, 168, 111, 627, 435, 47, 639, 169, 1255, + 170, 155, 939, 156, 441, 442, 16, 939, 1382, 939, + 349, 47, 939, 939, 250, 939, 939, 413, 1509, 42, + 115, 291, 260, 47, 115, 1154, 1518, 289, 291, 1216, + 922, 1468, 2, 451, 437, 290, 196, 939, 435, 892, + 804, 896, 760, 487, 1331, 1030, 6, 721, 1332, 818, + 478, 512, 160, 513, 364, 249, 473, 932, 350, 735, + 795, 364, 482, 364, 577, 364, 437, 483, 884, 990, + 452, 585, 676, 1360, 443, 816, 292, 336, 449, 476, + 576, 351, 1078, 292, 481, 739, 577, 15, 161, 1450, + 162, 163, 939, 493, 562, 352, 191, 164, 3, 4, + 5, 6, 257, 684, 250, 1059, 537, 514, 491, 364, + 541, 1061, 257, 524, 795, 546, 1474, 1078, 115, 562, + 1341, 494, 291, 165, 166, 1090, 498, 500, 1484, 543, + 1485, 167, 168, 1383, 548, 47, 545, 94, 169, 536, + 170, 525, 261, 1198, 1155, 896, 1519, 533, 1217, 535, + 1469, 657, 534, 498, 805, 897, 568, 893, 694, 898, + 1016, 955, 955, 722, 698, 551, 552, 1348, 749, 2, + 766, 564, 478, 478, 811, 577, 660, 292, 1100, 980, + 450, 1073, 1031, 561, 1033, 563, 691, 1036, 583, 782, + 304, 1128, 844, 619, 620, 869, 760, 1446, 1354, 769, + 388, 476, 597, 318, 291, 889, 605, 606, 607, 608, + 609, 610, 611, 612, 613, 614, 615, 361, 1481, 641, + 643, 642, 644, 647, 1495, 1234, 1370, 988, 565, 790, + 48, 812, 1412, 362, 1439, 233, 389, 450, 637, 841, + 435, 350, 194, 94, 1009, 661, 318, 115, 1314, 699, + 783, 291, 1305, 47, 1515, 1400, 1401, 997, 1403, 292, + 994, 1199, 743, 898, 874, 1085, 890, 1086, 685, 1422, + 1482, 791, 1429, 1093, 955, 1095, 1096, 231, 115, 723, + 955, 842, 1349, 473, 750, 437, 767, 1445, 655, 231, + 701, 1355, 658, 659, 710, 340, 718, 800, 671, 802, + 115, 803, 677, 6, 577, 1153, 909, 477, 231, 194, + 194, 1467, 1160, 503, 711, 770, 390, 391, 640, 478, + 576, 708, 473, 640, 350, 335, 350, 640, 686, 685, + 194, 335, 687, 357, 1065, 759, 1183, 335, 231, 768, + 335, 335, 640, 989, 640, 231, 737, 231, 597, 744, + 744, 451, 350, 349, 335, 488, 350, 438, 350, 350, + 350, 350, 686, 489, 751, 753, 350, 836, 439, 640, + 982, 880, 1162, 404, 771, 860, 508, 577, 792, 773, + 509, 358, 861, 837, 758, 405, 335, 437, 640, 743, + 1221, 888, 978, 688, 328, 838, 640, 744, 231, 942, + 328, 350, 786, 561, 1191, 563, 340, 291, 451, 881, + 340, 414, 335, 115, 1312, 115, 490, 1315, 438, 732, + 115, 194, 194, 686, 351, 806, 806, 930, 561, 439, + 563, 349, 245, 20, 973, 414, 246, 350, 352, 1336, + 735, 350, 359, 335, 350, 824, 350, 826, 1223, 328, + 349, 350, 1350, 115, 340, 894, 834, 357, 744, 197, + 94, 1256, 1014, 1313, 249, 1269, 1316, 54, 350, 1101, + 1257, 1368, 821, 199, 732, 785, 640, 821, 821, 350, + 830, 640, 942, 1004, 194, 640, 247, 942, 522, 942, + 197, 351, 942, 942, 415, 942, 942, 478, 350, 416, + 640, 417, 351, 357, 418, 419, 1256, 420, 421, 225, + 194, 226, 362, 250, 876, 1257, 352, 942, 415, 857, + 115, 351, 194, 416, 335, 417, 476, 640, 418, 419, + 194, 420, 421, 712, 1258, 352, 335, 856, 638, 335, + 335, 498, 257, 858, 541, 115, 640, 527, 1069, 1259, + 1491, 200, 1260, 335, 639, 1261, 744, 904, 1492, 659, + 528, 737, 638, 660, 910, 604, 438, 351, 1262, 439, + 859, 1046, 942, 194, 649, 739, 194, 529, 639, 1258, + 918, 801, 621, 622, 422, 231, 335, 659, 743, 638, + 905, 660, 335, 361, 1259, 923, 924, 1260, 335, 244, + 1261, 603, 335, 603, 916, 639, 917, 999, 432, 933, + 194, 194, 478, 1262, 919, 335, 786, 478, 1008, 1493, + 657, 821, 318, 362, 362, 362, 248, 362, 362, 1038, + 362, 321, 362, 436, 528, 1237, 1254, 321, 194, 194, + 263, 597, 661, 350, 322, 94, 597, 335, 821, 361, + 744, 754, 350, 724, 1121, 935, 1237, 415, 194, 562, + 398, 399, 416, 350, 417, 438, 351, 418, 419, 361, + 420, 421, 194, 981, 362, 351, 362, 701, 318, 362, + 973, 1254, 115, 1237, 115, 906, 351, 472, 231, 352, + 1150, 562, 933, 318, 970, 1066, 494, 933, 318, 933, + 352, 677, 933, 933, 962, 933, 933, 1012, 588, 1015, + 570, 332, 866, 995, 570, 1017, 1046, 571, 589, 690, + 998, 571, 666, 1066, 562, 836, 1182, 94, 115, 572, + 1006, 115, 744, 572, 438, 360, 1356, 835, 935, 1433, + 1026, 1111, 249, 935, 365, 935, 929, 650, 935, 935, + 666, 935, 935, 1112, 761, 373, 1157, 1158, 94, 666, + 663, 478, 400, 366, 367, 1279, 1027, 1209, 1050, 663, + 270, 270, 662, 821, 1028, 821, 194, 1055, 821, 270, + 751, 662, 933, 368, 1302, 414, 751, 402, 751, 772, + 1045, 250, 1302, 772, 369, 772, 756, 772, 194, 401, + 756, 1486, 452, 1271, 756, 693, 403, 677, 498, 694, + 1166, 335, 761, 335, 498, 1052, 761, 1053, 761, 1054, + 761, 335, 744, 755, 335, 498, 727, 406, 935, 929, + 728, 755, 335, 335, 929, 297, 929, 736, 1506, 929, + 929, 509, 929, 929, 440, 877, 280, 522, 280, 878, + 1524, 1525, 335, 280, 357, 947, 948, 473, 820, 786, + 335, 824, 820, 335, 821, 824, 821, 821, 415, 1097, + 751, 225, 751, 416, 751, 417, 444, 357, 418, 419, + 44, 420, 421, 447, 168, 65, 168, 194, 168, 65, + 357, 113, 755, 474, 1104, 357, 755, 181, 232, 181, + 357, 181, 357, 357, 357, 357, 478, 335, 194, 494, + 357, 701, 335, 335, 357, 335, 335, 56, 357, 929, + 385, 386, 387, 1129, 744, 786, 357, 328, 475, 357, + 328, 357, 225, 113, 228, 1045, 296, 113, 297, 1133, + 1134, 233, 494, 1169, 1140, 494, 435, 625, 626, 627, + 628, 1024, 1102, 814, 1103, 357, 975, 115, 975, 1157, + 1158, 329, 329, 821, 763, 496, 763, 233, 561, 1165, + 563, 156, 435, 156, 194, 497, 163, 973, 163, 340, + 518, 494, 329, 340, 362, 335, 340, 164, 340, 164, + 886, 542, 886, 340, 547, 821, 1097, 194, 1169, 67, + 561, 67, 563, 187, 157, 187, 157, 1496, 1497, 437, + 555, 357, 194, 120, 523, 120, 194, 1275, 231, 1235, + 1253, 285, 1231, 285, 1236, 581, 127, 340, 127, 351, + 444, 113, 1347, 561, 292, 563, 292, 522, 522, 821, + 1235, 640, 640, 1145, 1146, 1236, 1347, 623, 624, 629, + 630, 526, 582, 590, 351, 653, 821, 672, 494, 355, + 258, 692, 656, 695, 1378, 1253, 1379, 1235, 697, 719, + 1286, 194, 1236, 329, 329, 725, 726, 748, 1231, 772, + 765, 115, 774, 775, 776, 115, 777, 794, 115, 194, + 194, 795, 797, 809, 258, 1310, 1311, 810, 258, 258, + 258, 258, 258, 258, 258, 258, 814, 823, 825, 829, + 845, 846, 115, 438, 1307, 852, 848, 115, 1339, 262, + 849, 1342, 42, 286, 287, 288, 864, 294, 295, 870, + 871, 899, 308, 309, 872, 873, 329, 879, 895, 315, + 196, 317, 900, 321, 902, 907, 911, 920, 333, 334, + 115, 701, 912, 926, 937, 942, 194, 944, 949, 957, + 113, 951, 329, 958, 961, 1357, 115, 960, 963, 966, + 968, 986, 370, 974, 329, 987, 990, 194, 996, 1003, + 701, 701, 329, 701, 512, 194, 1413, 1010, 1021, 1022, + 499, 113, 1048, 413, 701, 413, 499, 701, 1035, 1039, + 1056, 1062, 1063, 1440, 1072, 1074, 1064, 1092, 1084, 1088, + 1091, 1094, 701, 113, 413, 413, 1452, 1454, 1106, 1110, + 1113, 1114, 1115, 1132, 1116, 329, 1118, 744, 329, 1307, + 1122, 1119, 1135, 1176, 413, 1136, 701, 1148, 1161, 494, + 1190, 1143, 413, 1440, 1440, 413, 1193, 1168, 1208, 1195, + 1213, 1197, 1200, 1205, 1218, 1209, 1462, 1219, 356, 1222, + 1220, 1226, 329, 329, 1267, 1270, 1272, 1276, 1317, 338, + 1273, 1283, 1309, 341, 342, 343, 344, 345, 346, 347, + 348, 356, 1288, 1330, 1362, 1352, 1396, 258, 1334, 744, + 329, 329, 1345, 1364, 356, 1367, 1365, 258, 1369, 356, + 1440, 1335, 231, 258, 356, 1373, 356, 356, 356, 356, + 1371, 1375, 315, 1376, 356, 370, 1381, 1386, 356, 478, + 478, 1389, 356, 1344, 1353, 1355, 744, 1392, 1404, 1393, + 356, 1394, 1408, 356, 1405, 356, 1511, 1511, 1418, 1423, + 1437, 1425, 1438, 1520, 1520, 1435, 1434, 1444, 597, 597, + 1448, 1447, 1458, 1461, 1472, 1459, 516, 1463, 1464, 356, + 1466, 1478, 1479, 1483, 1487, 194, 113, 1498, 1488, 581, + 1482, 532, 1490, 1481, 258, 1504, 47, 1505, 1526, 1527, + 1528, 9, 971, 535, 604, 856, 258, 258, 258, 493, + 963, 258, 258, 494, 450, 605, 29, 21, 674, 47, + 492, 29, 27, 518, 30, 313, 329, 208, 30, 96, + 335, 765, 47, 864, 789, 356, 757, 47, 766, 825, + 758, 194, 47, 826, 47, 47, 47, 47, 329, 790, + 662, 827, 47, 113, 317, 685, 47, 829, 662, 194, + 342, 640, 640, 230, 123, 105, 288, 130, 47, 53, + 329, 47, 581, 47, 124, 106, 289, 581, 113, 581, + 581, 581, 581, 581, 581, 581, 581, 581, 581, 581, + 131, 21, 1040, 956, 1285, 1480, 1138, 47, 338, 47, + 47, 581, 1139, 581, 1277, 581, 1449, 581, 581, 581, + 854, 1465, 1436, 1489, 1431, 194, 194, 1324, 867, 983, + 984, 1337, 985, 581, 194, 503, 1522, 1284, 550, 1281, + 1359, 979, 194, 194, 581, 194, 1514, 1460, 583, 1455, + 1453, 1327, 1513, 1214, 1380, 1328, 581, 1215, 952, 374, + 887, 931, 928, 1327, 762, 194, 808, 592, 194, 329, + 1075, 1002, 581, 863, 299, 709, 1327, 553, 632, 550, + 375, 376, 377, 378, 379, 380, 381, 382, 383, 384, + 329, 616, 617, 618, 631, 1327, 550, 550, 550, 550, + 550, 550, 550, 550, 550, 550, 550, 550, 550, 550, + 550, 550, 258, 885, 633, 635, 752, 634, 636, 1202, + 925, 408, 1156, 779, 1289, 113, 1206, 113, 1117, 1068, + 1130, 583, 1087, 1123, 1125, 1187, 583, 755, 583, 583, + 583, 583, 583, 583, 583, 583, 583, 583, 583, 651, + 1019, 652, 1057, 833, 1287, 954, 329, 1192, 953, 0, + 583, 0, 583, 0, 583, 0, 583, 583, 583, 0, + 0, 113, 0, 0, 113, 0, 0, 0, 0, 329, + 0, 0, 583, 0, 0, 0, 0, 0, 27, 27, + 0, 0, 0, 27, 329, 0, 0, 27, 329, 27, + 0, 0, 27, 0, 27, 27, 34, 27, 0, 27, + 0, 27, 0, 27, 27, 27, 27, 0, 550, 27, + 27, 583, 0, 0, 0, 27, 0, 27, 27, 27, + 0, 0, 27, 27, 27, 0, 27, 0, 0, 27, + 0, 27, 27, 27, 27, 0, 0, 0, 27, 27, + 27, 0, 0, 27, 27, 27, 0, 258, 0, 0, + 0, 0, 27, 27, 0, 27, 27, 0, 27, 27, + 27, 329, 329, 0, 27, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 796, 0, 0, + 0, 503, 0, 0, 27, 33, 503, 503, 0, 0, + 27, 27, 0, 0, 0, 0, 0, 0, 0, 27, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 503, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 503, 503, 0, 0, 0, 503, 329, 0, + 503, 0, 503, 0, 503, 503, 503, 503, 0, 0, + 27, 0, 503, 0, 0, 0, 503, 0, 0, 0, + 503, 0, 0, 0, 0, 0, 0, 329, 503, 0, + 0, 503, 0, 503, 503, 0, 0, 0, 0, 503, + 0, 503, 503, 503, 503, 503, 503, 503, 503, 503, + 503, 503, 0, 0, 0, 0, 0, 503, 503, 0, + 113, 0, 503, 503, 0, 503, 503, 503, 503, 503, + 503, 503, 0, 503, 503, 0, 503, 503, 503, 503, + 503, 503, 503, 503, 503, 503, 0, 503, 503, 503, + 503, 503, 503, 503, 503, 503, 503, 503, 503, 503, + 503, 503, 503, 503, 503, 503, 503, 503, 503, 0, + 0, 503, 0, 503, 0, 503, 0, 858, 503, 0, + 0, 0, 0, 34, 503, 0, 0, 34, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 34, 0, + 0, 0, 0, 34, 0, 0, 0, 34, 0, 0, + 34, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 34, 34, 0, 0, 0, 34, 34, 0, + 0, 0, 0, 34, 0, 34, 34, 34, 34, 0, + 0, 0, 0, 34, 113, 0, 0, 34, 113, 34, + 0, 113, 0, 0, 0, 0, 0, 0, 0, 34, + 0, 34, 34, 0, 34, 0, 0, 329, 34, 0, + 0, 0, 33, 582, 0, 113, 33, 0, 0, 0, + 113, 0, 0, 0, 0, 0, 0, 33, 34, 0, + 0, 0, 33, 0, 34, 34, 33, 0, 0, 33, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 841, 841, 841, 841, 0, 841, 773, 773, - 0, 0, 0, 0, 841, 0, 773, 773, 773, 773, - 773, 0, 773, 773, 733, 773, 773, 773, 773, 773, - 773, 773, 0, 0, 0, 0, 0, 773, 0, 773, - 773, 773, 773, 773, 773, 0, 0, 773, 0, 0, - 0, 773, 773, 0, 773, 773, 773, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 773, 0, 773, 0, - 773, 773, 0, 0, 773, 0, 773, 773, 773, 773, - 773, 773, 773, 773, 773, 773, 773, 773, 0, 773, - 0, 0, 773, 773, 0, 0, 773, 773, 0, 0, + 0, 33, 33, 113, 0, 0, 33, 33, 0, 550, + 0, 0, 33, 329, 33, 33, 33, 33, 0, 113, + 0, 0, 33, 0, 0, 0, 33, 0, 33, 0, + 0, 329, 0, 0, 783, 0, 0, 0, 33, 0, + 33, 33, 0, 33, 0, 0, 582, 33, 0, 0, + 0, 582, 0, 582, 582, 582, 582, 582, 582, 582, + 582, 582, 582, 582, 0, 0, 0, 33, 0, 0, + 0, 0, 0, 0, 33, 582, 0, 582, 0, 582, + 0, 582, 582, 582, 0, 0, 0, 329, 329, 0, + 0, 0, 0, 0, 0, 0, 329, 582, 0, 0, + 0, 0, 0, 0, 329, 329, 0, 329, 582, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 773, 773, 773, 773, 773, 0, 0, 0, 773, - 773, 0, 0, 773, 0, 0, 0, 0, 773, 773, - 773, 773, 773, 0, 330, 0, 773, 0, 773, 330, - 330, 0, 0, 0, 773, 773, 0, 543, 0, 0, - 0, 0, 0, 0, 323, 0, 0, 0, 0, 0, - 0, 0, 330, 0, 0, 0, 0, 0, 0, 773, - 773, 773, 773, 0, 773, 330, 330, 0, 0, 0, - 330, 773, 0, 330, 0, 330, 0, 330, 330, 330, - 330, 0, 0, 0, 0, 330, 0, 0, 0, 330, - 0, 0, 0, 330, 0, 0, 0, 0, 0, 0, - 0, 330, 0, 0, 330, 0, 330, 330, 0, 0, - 0, 0, 330, 0, 330, 330, 330, 330, 330, 330, - 330, 330, 330, 330, 330, 330, 0, 0, 0, 0, - 330, 330, 0, 0, 0, 330, 330, 330, 330, 330, - 330, 330, 330, 330, 330, 0, 330, 330, 0, 0, - 330, 330, 330, 330, 330, 0, 0, 330, 330, 0, - 0, 0, 330, 330, 330, 330, 330, 330, 330, 330, - 733, 0, 0, 0, 360, 733, 733, 0, 0, 0, - 0, 330, 0, 0, 330, 0, 330, 0, 330, 0, - 0, 330, 0, 0, 0, 0, 0, 330, 733, 0, + 582, 0, 0, 858, 858, 0, 0, 329, 0, 0, + 329, 858, 858, 858, 858, 858, 582, 858, 858, 0, + 858, 858, 858, 858, 858, 858, 858, 858, 0, 0, + 0, 0, 858, 0, 858, 858, 858, 858, 858, 858, + 335, 0, 858, 0, 0, 0, 858, 858, 0, 858, + 858, 858, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 858, 0, 858, 0, 858, 858, 0, 0, 858, + 0, 858, 858, 858, 858, 858, 858, 858, 858, 858, + 858, 858, 858, 0, 858, 0, 0, 858, 858, 0, + 0, 858, 858, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 858, 858, 858, 858, + 858, 0, 0, 0, 858, 858, 0, 0, 858, 0, + 0, 0, 0, 858, 858, 858, 858, 858, 0, 0, + 0, 858, 0, 858, 0, 0, 0, 0, 0, 858, + 858, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 733, 733, 0, 0, 0, 733, 0, 0, 733, - 0, 733, 0, 733, 733, 733, 733, 0, 0, 0, - 0, 733, 0, 0, 0, 733, 0, 0, 0, 733, - 0, 0, 0, 0, 0, 0, 0, 733, 0, 0, - 733, 0, 733, 733, 0, 0, 0, 0, 733, 0, - 733, 733, 733, 733, 733, 733, 733, 733, 733, 733, - 733, 0, 0, 0, 0, 0, 733, 733, 330, 0, - 0, 733, 733, 733, 733, 733, 733, 0, 733, 733, - 733, 0, 733, 733, 0, 0, 733, 733, 733, 733, - 323, 0, 0, 733, 733, 323, 323, 0, 733, 733, - 733, 733, 733, 733, 733, 733, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 733, 323, 0, - 733, 0, 733, 0, 733, 0, 0, 733, 0, 0, - 0, 323, 323, 733, 0, 0, 323, 0, 0, 323, - 0, 323, 0, 323, 323, 323, 323, 0, 0, 0, - 0, 323, 0, 0, 0, 323, 0, 0, 0, 323, - 0, 0, 0, 0, 0, 0, 0, 323, 0, 0, - 323, 0, 323, 323, 0, 0, 0, 0, 323, 0, - 323, 323, 323, 323, 323, 323, 323, 323, 323, 323, - 323, 0, 0, 0, 0, 0, 323, 323, 0, 0, - 0, 323, 323, 323, 323, 323, 323, 0, 323, 323, - 323, 0, 323, 323, 0, 0, 323, 323, 323, 323, - 360, 0, 0, 323, 323, 360, 360, 0, 323, 323, - 323, 323, 323, 323, 323, 323, 0, 47, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 323, 360, 0, - 323, 0, 323, 0, 323, 0, 0, 323, 0, 0, - 0, 360, 360, 323, 0, 0, 360, 0, 0, 360, - 0, 360, 0, 360, 360, 360, 360, 0, 0, 0, - 0, 360, 0, 0, 0, 360, 0, 0, 0, 360, - 0, 0, 0, 0, 0, 0, 0, 360, 0, 0, - 360, 0, 360, 360, 0, 0, 0, 0, 360, 0, - 360, 360, 360, 360, 360, 360, 360, 360, 360, 360, - 360, 0, 0, 0, 330, 0, 360, 360, 0, 0, - 330, 360, 360, 0, 360, 360, 360, 0, 360, 360, - 360, 0, 360, 360, 0, 0, 360, 360, 360, 360, - 27, 0, 0, 360, 360, 0, 0, 0, 360, 360, - 360, 360, 360, 360, 360, 360, 330, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 360, 0, 0, - 360, 0, 360, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 360, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 330, 0, 0, - 0, 0, 330, 34, 330, 330, 330, 330, 330, 330, - 330, 330, 330, 330, 330, 330, 0, 0, 0, 0, - 0, 330, 0, 0, 0, 330, 330, 330, 330, 330, - 330, 330, 330, 330, 330, 0, 330, 330, 0, 0, - 330, 330, 330, 330, 330, 0, 0, 330, 330, 0, - 0, 0, 330, 330, 330, 330, 330, 330, 330, 330, + 0, 0, 0, 0, 858, 858, 858, 858, 0, 858, + 783, 783, 0, 0, 0, 0, 858, 0, 783, 783, + 783, 783, 783, 0, 783, 783, 740, 783, 783, 783, + 783, 783, 783, 783, 0, 0, 0, 0, 0, 783, + 0, 783, 783, 783, 783, 783, 783, 0, 0, 783, + 0, 0, 0, 783, 783, 0, 783, 783, 783, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 783, 0, + 783, 0, 783, 783, 0, 0, 783, 0, 783, 783, + 783, 783, 783, 783, 783, 783, 783, 783, 783, 783, + 0, 783, 0, 0, 783, 783, 0, 0, 783, 783, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 330, 33, 0, 330, 0, 330, 0, 330, 0, - 0, 330, 0, 0, 47, 0, 0, 330, 47, 0, - 47, 0, 47, 0, 47, 0, 0, 47, 0, 47, - 47, 0, 47, 0, 47, 0, 47, 0, 47, 47, - 47, 47, 0, 0, 47, 47, 0, 0, 0, 32, - 47, 47, 47, 47, 47, 0, 0, 47, 47, 47, - 0, 47, 0, 47, 47, 47, 47, 47, 47, 47, - 47, 0, 47, 47, 47, 47, 0, 0, 47, 47, - 47, 0, 47, 0, 0, 0, 0, 47, 47, 0, - 47, 47, 0, 47, 47, 47, 0, 0, 0, 47, + 0, 0, 0, 783, 783, 783, 783, 783, 0, 0, + 0, 783, 783, 0, 0, 783, 0, 0, 0, 0, + 783, 783, 783, 783, 783, 0, 335, 0, 783, 0, + 783, 335, 335, 0, 0, 0, 783, 783, 0, 0, + 0, 0, 0, 0, 0, 0, 328, 0, 0, 0, + 0, 0, 0, 0, 335, 0, 0, 0, 0, 0, + 0, 783, 783, 783, 783, 0, 783, 335, 335, 0, + 0, 0, 335, 783, 0, 335, 0, 335, 0, 335, + 335, 335, 335, 0, 0, 0, 0, 335, 0, 0, + 0, 335, 0, 0, 0, 335, 0, 0, 0, 0, + 0, 0, 0, 335, 0, 0, 335, 0, 335, 335, + 0, 0, 0, 0, 335, 0, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 0, 0, + 0, 0, 335, 335, 0, 0, 0, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 0, 335, 335, + 0, 0, 335, 335, 335, 335, 335, 0, 0, 335, + 335, 0, 0, 0, 335, 335, 335, 335, 335, 335, + 335, 335, 740, 0, 0, 0, 365, 740, 740, 0, + 0, 0, 0, 335, 0, 0, 335, 0, 335, 0, + 335, 0, 0, 335, 0, 0, 0, 0, 0, 335, + 740, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 740, 740, 0, 0, 0, 740, 0, + 0, 740, 0, 740, 0, 740, 740, 740, 740, 0, + 0, 0, 0, 740, 0, 0, 0, 740, 0, 0, + 0, 740, 0, 0, 0, 0, 0, 0, 0, 740, + 0, 0, 740, 0, 740, 740, 0, 0, 0, 0, + 740, 0, 740, 740, 740, 740, 740, 740, 740, 740, + 740, 740, 740, 0, 0, 0, 0, 0, 740, 740, + 335, 0, 0, 740, 740, 740, 740, 740, 740, 0, + 740, 740, 740, 0, 740, 740, 0, 0, 740, 740, + 740, 740, 328, 0, 0, 740, 740, 328, 328, 0, + 740, 740, 740, 740, 740, 740, 740, 740, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 740, + 328, 0, 740, 0, 740, 0, 740, 0, 0, 740, + 0, 0, 0, 328, 328, 740, 0, 0, 328, 0, + 0, 328, 0, 328, 0, 328, 328, 328, 328, 0, + 0, 0, 0, 328, 0, 0, 0, 328, 0, 0, + 0, 328, 0, 0, 0, 0, 0, 0, 0, 328, + 0, 0, 328, 0, 328, 328, 0, 0, 0, 0, + 328, 0, 328, 328, 328, 328, 328, 328, 328, 328, + 328, 328, 328, 0, 0, 0, 0, 0, 328, 328, + 0, 0, 0, 328, 328, 328, 328, 328, 328, 0, + 328, 328, 328, 0, 328, 328, 360, 0, 328, 328, + 328, 328, 365, 0, 0, 328, 328, 365, 365, 0, + 328, 328, 328, 328, 328, 328, 328, 328, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 328, + 365, 0, 328, 0, 328, 0, 328, 0, 0, 328, + 0, 0, 0, 365, 365, 328, 0, 0, 365, 0, + 0, 365, 0, 365, 0, 365, 365, 365, 365, 0, + 0, 0, 0, 365, 0, 0, 0, 365, 0, 0, + 0, 365, 0, 0, 0, 0, 0, 0, 0, 365, + 0, 0, 365, 0, 365, 365, 0, 0, 0, 0, + 365, 0, 365, 365, 365, 365, 365, 365, 365, 365, + 365, 365, 365, 0, 0, 0, 335, 0, 365, 365, + 0, 0, 335, 365, 365, 0, 365, 365, 365, 0, + 365, 365, 365, 0, 365, 365, 32, 0, 365, 365, + 365, 365, 0, 0, 0, 365, 365, 0, 0, 0, + 365, 365, 365, 365, 365, 365, 365, 365, 335, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 365, + 0, 0, 365, 0, 365, 0, 0, 0, 0, 27, + 0, 0, 0, 0, 0, 365, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 335, + 0, 0, 585, 0, 335, 0, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 0, 0, + 0, 0, 31, 335, 0, 0, 0, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 0, 335, 335, + 0, 0, 335, 335, 335, 335, 335, 0, 0, 335, + 335, 0, 0, 0, 335, 335, 335, 335, 335, 335, + 335, 335, 360, 0, 0, 5, 0, 0, 360, 0, + 0, 0, 0, 335, 0, 0, 335, 0, 335, 0, + 335, 0, 0, 335, 0, 585, 0, 0, 0, 335, + 585, 0, 585, 585, 585, 585, 585, 585, 585, 585, + 585, 585, 585, 0, 360, 0, 0, 0, 953, 0, + 0, 0, 0, 0, 585, 0, 585, 0, 585, 0, + 585, 585, 585, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 27, 0, 0, 0, 0, 0, 0, 47, - 0, 47, 47, 0, 0, 0, 27, 27, 0, 0, - 0, 27, 0, 0, 47, 27, 0, 27, 0, 0, - 27, 0, 27, 27, 0, 27, 0, 27, 0, 27, - 0, 27, 27, 27, 27, 31, 0, 27, 27, 0, - 0, 0, 0, 27, 0, 27, 27, 27, 0, 0, - 27, 27, 27, 0, 27, 47, 0, 27, 0, 27, - 27, 27, 27, 0, 0, 0, 27, 27, 27, 0, - 34, 27, 27, 27, 34, 0, 0, 0, 5, 0, - 27, 27, 0, 27, 27, 34, 27, 27, 27, 0, - 34, 0, 27, 0, 34, 0, 0, 34, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 34, - 34, 0, 27, 0, 34, 34, 0, 0, 27, 27, - 34, 936, 34, 34, 34, 34, 0, 27, 0, 0, - 34, 0, 0, 0, 34, 0, 34, 0, 0, 33, - 0, 0, 0, 33, 0, 0, 34, 0, 34, 34, - 0, 34, 0, 0, 33, 34, 0, 0, 0, 33, - 0, 0, 0, 33, 46, 0, 33, 0, 27, 0, - 0, 0, 0, 0, 0, 34, 0, 0, 33, 33, - 0, 34, 34, 33, 33, 0, 32, 0, 0, 33, - 32, 33, 33, 33, 33, 0, 0, 0, 0, 33, - 0, 32, 0, 33, 0, 33, 32, 7, 0, 0, - 32, 0, 0, 32, 0, 33, 0, 33, 33, 0, - 33, 0, 0, 0, 33, 32, 32, 0, 0, 0, - 32, 32, 0, 0, 0, 0, 32, 0, 32, 32, - 32, 32, 0, 0, 33, 0, 32, 0, 0, 27, - 32, 33, 32, 27, 0, 0, 0, 0, 0, 0, - 0, 0, 32, 0, 27, 32, 0, 32, 0, 27, - 937, 32, 0, 27, 0, 0, 27, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 27, 27, - 0, 32, 31, 27, 27, 0, 31, 32, 32, 27, - 0, 27, 27, 27, 27, 0, 0, 31, 0, 27, - 0, 0, 31, 27, 0, 27, 31, 0, 0, 31, - 0, 0, 0, 0, 0, 27, 0, 0, 27, 0, - 27, 31, 31, 0, 27, 5, 31, 31, 0, 46, - 0, 0, 31, 0, 31, 31, 31, 31, 0, 0, - 46, 0, 31, 0, 27, 46, 31, 0, 31, 46, - 27, 27, 46, 0, 0, 0, 0, 0, 31, 0, - 0, 31, 0, 31, 46, 46, 0, 31, 936, 46, - 46, 0, 46, 0, 0, 46, 0, 46, 46, 46, - 46, 0, 0, 46, 0, 46, 0, 31, 46, 46, - 0, 46, 46, 0, 31, 46, 0, 0, 0, 0, - 0, 46, 0, 0, 46, 0, 46, 46, 46, 0, - 46, 46, 46, 46, 0, 46, 0, 0, 46, 0, - 46, 46, 46, 46, 0, 0, 46, 0, 46, 0, - 46, 46, 46, 0, 46, 46, 0, 0, 46, 0, - 0, 0, 0, 0, 46, 0, 0, 46, 0, 46, - 46, 46, 0, 46, 7, 46, 46, 0, 47, 0, - 0, 46, 0, 46, 46, 46, 46, 0, 0, 47, - 0, 46, 0, 46, 47, 46, 0, 46, 47, 0, - 0, 47, 0, 0, 0, 0, 0, 46, 0, 0, - 46, 0, 46, 47, 47, 0, 46, 0, 47, 47, - 0, 0, 0, 0, 47, 0, 47, 47, 47, 47, - 0, 0, 0, 0, 47, 0, 46, 937, 47, 0, - 47, 46, 0, 0, 0, 0, 0, 0, 0, 0, - 47, 0, 46, 47, 0, 47, 0, 46, 0, 47, - 0, 46, 0, 0, 46, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 46, 46, 0, 47, - 0, 46, 46, 0, 0, 0, 0, 46, 0, 46, - 46, 46, 46, 0, 0, 0, 0, 46, 0, 0, - 0, 46, 0, 46, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 46, 0, 55, 46, 0, 46, 0, - 0, 0, 46, 56, 24, 57, 25, 0, 0, 26, - 58, 0, 59, 60, 27, 61, 62, 63, 28, 0, - 0, 0, 46, 0, 64, 0, 65, 30, 66, 67, - 68, 69, 0, 0, 32, 0, 0, 0, 70, 33, - 0, 71, 72, 34, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 73, 0, 36, 0, 37, 74, 0, - 0, 38, 0, 75, 76, 77, 78, 79, 80, 39, - 40, 81, 82, 41, 83, 0, 84, 0, 0, 85, - 86, 0, 330, 87, 88, 0, 0, 0, 330, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 89, 90, - 91, 92, 93, 0, 0, 0, 94, 0, 0, 0, - 95, 0, 0, 0, 0, 96, 97, 98, 99, 100, - 0, 0, 0, 101, 330, 102, 0, 0, 0, 0, - 0, 103, 104, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 330, 0, - 0, 0, 0, 0, 330, 0, 105, 106, 107, 108, - 0, 0, 0, 0, 0, 330, 0, 0, 196, 0, - 330, 0, 330, 330, 330, 330, 330, 330, 330, 330, - 330, 330, 330, 330, 0, 0, 0, 0, 0, 330, - 330, 0, 0, 0, 330, 330, 330, 330, 330, 330, - 330, 330, 330, 0, 330, 330, 0, 330, 330, 330, - 330, 330, 330, 330, 330, 330, 330, 0, 330, 330, - 330, 330, 330, 330, 330, 330, 330, 330, 330, 330, - 330, 330, 330, 330, 330, 330, 330, 330, 330, 330, - 0, 501, 0, 0, 330, 0, 330, 501, 0, 330, - 0, 0, 0, 0, 0, 330, 0, 0, 0, 0, - 330, 0, 0, 330, 0, 330, 330, 0, 0, 0, - 330, 330, 0, 0, 330, 330, 330, 330, 330, 330, - 330, 330, 330, 501, 330, 330, 330, 330, 330, 330, - 330, 330, 330, 330, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 330, 330, 0, 0, 0, 0, - 0, 0, 330, 0, 0, 330, 0, 0, 0, 0, - 0, 330, 0, 201, 501, 0, 0, 0, 0, 501, - 0, 501, 501, 501, 501, 501, 501, 501, 501, 501, - 501, 501, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 501, 501, 501, 501, 501, 501, 501, 501, - 501, 501, 581, 501, 501, 202, 501, 501, 501, 501, - 501, 501, 501, 501, 501, 501, 0, 501, 501, 501, - 501, 501, 501, 501, 501, 501, 501, 501, 501, 501, - 501, 501, 501, 501, 501, 501, 501, 501, 501, 0, - 497, 0, 0, 0, 0, 501, 497, 0, 0, 0, - 0, 0, 0, 0, 501, 203, 204, 205, 206, 0, - 207, 208, 209, 210, 211, 212, 213, 214, 0, 0, - 215, 216, 217, 218, 219, 220, 221, 222, 0, 0, - 0, 0, 497, 0, 0, 581, 0, 0, 0, 0, - 581, 0, 581, 581, 581, 581, 581, 581, 581, 581, - 581, 581, 581, 0, 0, 0, 0, 0, 0, 0, - 0, 387, 0, 0, 581, 0, 581, 387, 581, 0, - 581, 581, 581, 497, 0, 0, 0, 0, 497, 0, - 497, 497, 497, 497, 497, 497, 497, 497, 497, 497, - 497, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 497, 497, 387, 497, 497, 497, 497, 497, 497, - 497, 0, 497, 497, 0, 497, 497, 497, 497, 497, - 497, 497, 497, 497, 497, 581, 497, 497, 497, 497, - 497, 497, 497, 497, 497, 497, 497, 497, 497, 497, - 497, 497, 497, 497, 497, 497, 497, 497, 0, 505, - 0, 0, 0, 0, 497, 505, 0, 497, 0, 0, - 0, 0, 0, 497, 0, 0, 0, 0, 323, 0, - 0, 0, 0, 0, 323, 0, 387, 387, 387, 387, - 0, 387, 0, 387, 387, 0, 387, 387, 387, 387, - 387, 505, 387, 387, 387, 387, 0, 387, 387, 387, - 387, 387, 387, 387, 387, 387, 387, 387, 387, 387, - 387, 387, 387, 387, 387, 387, 387, 387, 387, 0, - 0, 0, 0, 323, 0, 387, 0, 0, 387, 0, - 0, 0, 505, 0, 387, 0, 0, 505, 0, 505, + 0, 0, 0, 0, 0, 360, 0, 0, 0, 0, + 360, 47, 360, 360, 360, 360, 360, 360, 360, 360, + 360, 360, 360, 0, 0, 0, 0, 0, 0, 360, + 0, 0, 0, 360, 360, 585, 360, 360, 360, 0, + 360, 360, 360, 0, 360, 360, 0, 0, 360, 360, + 360, 360, 0, 32, 7, 360, 360, 32, 0, 0, + 360, 360, 360, 360, 360, 360, 360, 360, 32, 0, + 0, 0, 0, 32, 0, 0, 0, 32, 0, 360, + 32, 0, 360, 0, 360, 0, 0, 0, 0, 0, + 0, 0, 32, 32, 0, 360, 27, 32, 32, 0, + 27, 0, 0, 32, 0, 32, 32, 32, 32, 0, + 0, 27, 0, 32, 0, 0, 27, 32, 0, 32, + 27, 954, 0, 27, 0, 0, 0, 0, 0, 32, + 0, 0, 32, 0, 32, 27, 27, 0, 32, 31, + 27, 27, 0, 31, 0, 0, 27, 0, 27, 27, + 27, 27, 0, 0, 31, 0, 27, 0, 32, 31, + 27, 0, 27, 31, 32, 32, 31, 0, 48, 0, + 0, 0, 27, 0, 0, 27, 0, 27, 31, 31, + 0, 27, 5, 31, 31, 0, 47, 0, 0, 31, + 0, 31, 31, 31, 31, 0, 0, 47, 0, 31, + 0, 27, 47, 31, 0, 31, 47, 27, 27, 47, + 0, 0, 0, 0, 0, 31, 0, 0, 31, 0, + 31, 47, 47, 0, 31, 953, 47, 47, 0, 47, + 0, 0, 47, 0, 47, 47, 47, 47, 0, 0, + 47, 0, 47, 0, 31, 47, 47, 0, 47, 47, + 0, 31, 47, 0, 0, 0, 0, 0, 47, 0, + 0, 47, 0, 47, 47, 47, 0, 47, 47, 47, + 47, 0, 47, 0, 0, 47, 0, 47, 47, 47, + 47, 0, 0, 47, 0, 47, 0, 47, 47, 47, + 0, 47, 47, 0, 0, 47, 0, 0, 0, 0, + 0, 47, 0, 0, 47, 0, 47, 47, 47, 0, + 47, 7, 47, 47, 0, 48, 0, 0, 47, 0, + 47, 47, 47, 47, 0, 0, 48, 0, 47, 0, + 47, 48, 47, 0, 47, 48, 0, 0, 48, 0, + 0, 0, 0, 0, 47, 0, 0, 47, 0, 47, + 48, 48, 0, 47, 0, 48, 48, 0, 0, 0, + 0, 48, 0, 48, 48, 48, 48, 0, 0, 0, + 0, 48, 0, 47, 0, 48, 0, 48, 954, 0, + 0, 0, 47, 0, 0, 0, 0, 48, 0, 0, + 48, 0, 48, 47, 0, 0, 48, 0, 47, 0, + 0, 0, 47, 0, 0, 47, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 48, 47, 47, 0, + 0, 0, 47, 47, 0, 48, 0, 0, 47, 48, + 47, 47, 47, 47, 0, 0, 0, 0, 47, 0, + 48, 0, 47, 0, 47, 48, 0, 0, 0, 48, + 0, 0, 48, 0, 47, 0, 0, 47, 0, 47, + 0, 0, 0, 47, 48, 48, 0, 0, 0, 48, + 48, 0, 0, 0, 0, 48, 0, 48, 48, 48, + 48, 0, 0, 47, 0, 48, 0, 0, 0, 48, + 0, 48, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 48, 0, 55, 48, 0, 48, 0, 0, 0, + 48, 56, 24, 57, 25, 0, 0, 26, 58, 0, + 59, 60, 27, 61, 62, 63, 28, 0, 0, 0, + 48, 0, 64, 0, 65, 30, 66, 67, 68, 69, + 0, 0, 32, 0, 0, 0, 70, 33, 0, 71, + 72, 34, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 73, 0, 36, 0, 37, 74, 0, 0, 38, + 0, 75, 76, 77, 78, 79, 80, 39, 40, 81, + 82, 41, 83, 0, 84, 0, 0, 85, 86, 0, + 335, 87, 88, 0, 0, 0, 335, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 89, 90, 91, 92, + 93, 0, 0, 0, 94, 0, 0, 0, 95, 0, + 0, 0, 0, 96, 97, 98, 99, 100, 0, 0, + 0, 101, 335, 102, 0, 0, 0, 0, 0, 103, + 104, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 335, 0, 0, 0, + 0, 0, 335, 0, 105, 106, 107, 108, 0, 0, + 0, 0, 0, 335, 0, 0, 196, 0, 335, 0, + 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 0, 0, 0, 0, 0, 335, 335, 0, + 0, 0, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 0, 335, 335, 0, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 0, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 0, 505, + 0, 0, 335, 0, 335, 505, 0, 335, 0, 0, + 0, 0, 0, 335, 0, 0, 0, 0, 335, 0, + 0, 335, 0, 335, 335, 0, 0, 0, 335, 335, + 0, 0, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 505, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 335, 335, 0, 0, 0, 0, 0, 0, + 335, 0, 0, 335, 0, 0, 0, 0, 0, 335, + 0, 201, 505, 0, 0, 0, 0, 505, 0, 505, 505, 505, 505, 505, 505, 505, 505, 505, 505, 505, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 505, 0, 505, 505, 505, 505, 505, 505, 505, - 928, 505, 505, 0, 505, 505, 505, 505, 505, 505, + 505, 505, 505, 505, 505, 505, 505, 505, 505, 505, + 945, 505, 505, 202, 505, 505, 505, 505, 505, 505, 505, 505, 505, 505, 0, 505, 505, 505, 505, 505, 505, 505, 505, 505, 505, 505, 505, 505, 505, 505, - 505, 505, 505, 505, 505, 505, 505, 0, 330, 0, - 0, 0, 0, 505, 330, 0, 505, 0, 0, 0, - 0, 0, 505, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 330, 0, 0, 928, 0, 0, 0, 0, 928, 0, - 928, 928, 928, 928, 928, 928, 928, 928, 928, 928, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 928, 0, 928, 0, 928, 0, 928, 928, - 928, 330, 0, 0, 0, 0, 330, 0, 330, 330, - 330, 330, 330, 330, 330, 330, 330, 330, 330, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 330, 0, 330, 330, 330, 330, 330, 330, 330, 0, - 330, 330, 0, 330, 330, 330, 330, 330, 330, 330, - 330, 330, 330, 928, 330, 330, 330, 330, 330, 330, - 330, 330, 330, 330, 330, 330, 330, 330, 330, 330, - 330, 330, 330, 330, 330, 330, 0, 430, 745, 0, - 0, 0, 330, 430, 0, 330, 0, 24, 0, 25, - 0, 330, 26, 0, 0, 0, 0, 27, 0, 0, - 0, 28, 0, 0, 0, 0, 0, 0, 0, 0, - 30, 0, 0, 0, 0, 0, 0, 32, 0, 430, - 0, 0, 33, 0, 0, 0, 34, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 36, 0, - 37, 0, 0, 0, 38, 0, 0, 0, 0, 0, - 0, 0, 39, 40, 0, 0, 41, 0, 0, 746, - 430, 0, 0, 0, 0, 430, 0, 430, 430, 430, - 430, 430, 430, 430, 430, 430, 430, 430, 0, 0, - 0, 0, 0, 0, 0, 290, 0, 0, 0, 430, - 0, 430, 430, 430, 430, 430, 430, 430, 0, 430, - 430, 0, 430, 430, 430, 430, 430, 430, 430, 430, - 430, 430, 0, 430, 430, 430, 430, 430, 430, 430, - 430, 430, 430, 430, 430, 430, 430, 430, 430, 430, - 430, 430, 430, 430, 430, 0, 390, 887, 0, 0, - 320, 430, 390, 0, 430, 0, 24, 0, 25, 0, - 430, 26, 0, 0, 0, 0, 27, 0, 0, 0, + 505, 505, 505, 505, 505, 505, 505, 0, 501, 0, + 0, 0, 0, 505, 501, 0, 0, 0, 0, 0, + 0, 0, 505, 203, 204, 205, 206, 0, 207, 208, + 209, 210, 211, 212, 213, 214, 0, 0, 215, 216, + 217, 218, 219, 220, 221, 222, 0, 0, 0, 0, + 501, 0, 0, 945, 0, 0, 0, 0, 945, 0, + 945, 945, 945, 945, 945, 945, 945, 945, 945, 945, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 391, + 0, 0, 945, 0, 945, 391, 945, 0, 945, 945, + 945, 501, 0, 0, 0, 0, 501, 0, 501, 501, + 501, 501, 501, 501, 501, 501, 501, 501, 501, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 501, + 501, 391, 501, 501, 501, 501, 501, 501, 501, 0, + 501, 501, 0, 501, 501, 501, 501, 501, 501, 501, + 501, 501, 501, 945, 501, 501, 501, 501, 501, 501, + 501, 501, 501, 501, 501, 501, 501, 501, 501, 501, + 501, 501, 501, 501, 501, 501, 0, 509, 0, 0, + 0, 0, 501, 509, 0, 501, 0, 0, 0, 0, + 0, 501, 0, 0, 0, 0, 328, 0, 0, 0, + 0, 391, 328, 0, 391, 391, 391, 391, 0, 391, + 0, 391, 391, 0, 391, 391, 391, 391, 391, 509, + 391, 391, 391, 391, 0, 391, 391, 391, 391, 391, + 391, 391, 391, 391, 391, 391, 391, 391, 391, 391, + 391, 391, 391, 391, 391, 391, 391, 0, 0, 0, + 0, 328, 0, 391, 0, 0, 391, 0, 0, 0, + 509, 0, 391, 0, 0, 509, 0, 509, 509, 509, + 509, 509, 509, 509, 509, 509, 509, 509, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 509, + 0, 509, 509, 509, 509, 509, 509, 509, 0, 509, + 509, 0, 509, 509, 509, 509, 509, 509, 509, 509, + 509, 509, 0, 509, 509, 509, 509, 509, 509, 509, + 509, 509, 509, 509, 509, 509, 509, 509, 509, 509, + 509, 509, 509, 509, 509, 0, 335, 756, 0, 0, + 0, 509, 335, 0, 509, 0, 24, 0, 25, 0, + 509, 26, 0, 0, 0, 0, 27, 0, 0, 0, 28, 0, 0, 0, 0, 0, 0, 0, 0, 30, - 0, 0, 0, 0, 0, 0, 32, 0, 390, 0, + 0, 0, 0, 0, 0, 0, 32, 0, 335, 0, 0, 33, 0, 0, 0, 34, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 36, 0, 37, 0, 0, 0, 38, 0, 0, 0, 0, 0, 0, - 0, 39, 40, 0, 0, 41, 0, 0, 319, 390, - 0, 0, 0, 0, 390, 0, 390, 390, 390, 390, - 390, 390, 390, 390, 390, 390, 390, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 390, 0, - 390, 390, 390, 390, 390, 390, 390, 0, 390, 0, - 0, 390, 390, 390, 390, 390, 390, 390, 390, 390, - 390, 0, 390, 390, 390, 390, 390, 390, 390, 390, - 390, 390, 390, 390, 390, 390, 390, 390, 390, 390, - 390, 390, 390, 390, 0, 536, 0, 351, 0, 352, - 390, 536, 0, 390, 0, 0, 0, 0, 0, 390, + 0, 39, 40, 0, 0, 41, 0, 0, 757, 335, + 0, 0, 0, 0, 335, 0, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 0, 0, 0, + 0, 0, 0, 0, 291, 0, 0, 0, 335, 0, + 335, 335, 335, 335, 335, 335, 335, 0, 335, 335, + 0, 335, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 0, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 0, 434, 567, 0, 0, 323, + 335, 434, 0, 335, 0, 24, 0, 25, 0, 335, + 26, 0, 0, 0, 0, 27, 0, 0, 0, 28, + 0, 0, 0, 0, 0, 0, 0, 0, 30, 0, + 0, 0, 0, 0, 0, 32, 0, 434, 0, 0, + 33, 0, 0, 0, 34, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 36, 0, 37, 0, + 0, 0, 38, 0, 0, 0, 0, 0, 0, 0, + 39, 40, 0, 0, 41, 0, 0, 322, 434, 0, + 0, 0, 0, 434, 0, 434, 434, 434, 434, 434, + 434, 434, 434, 434, 434, 434, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 434, 0, 434, + 434, 434, 434, 434, 434, 434, 0, 434, 434, 0, + 434, 434, 434, 434, 434, 434, 434, 434, 434, 434, + 0, 434, 434, 434, 434, 434, 434, 434, 434, 434, + 434, 434, 434, 434, 434, 434, 434, 434, 434, 434, + 434, 434, 434, 0, 394, 0, 453, 0, 355, 434, + 394, 0, 434, 0, 0, 0, 0, 0, 434, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 454, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 351, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 351, 0, 0, 0, 536, 351, 0, - 0, 227, 0, 351, 0, 351, 351, 351, 351, 0, - 0, 0, 0, 351, 0, 0, 0, 351, 330, 0, - 0, 351, 0, 0, 330, 0, 0, 0, 736, 351, - 0, 0, 351, 0, 351, 0, 0, 0, 536, 0, - 0, 0, 0, 536, 0, 536, 536, 536, 536, 536, - 536, 536, 536, 536, 536, 536, 0, 0, 351, 0, - 330, 0, 0, 0, 0, 0, 0, 536, 0, 536, - 0, 536, 0, 536, 536, 536, 736, 536, 536, 0, - 536, 536, 536, 536, 536, 536, 536, 536, 536, 536, - 0, 0, 0, 536, 536, 536, 536, 536, 536, 536, - 536, 536, 536, 536, 536, 536, 536, 536, 536, 536, - 536, 548, 536, 0, 351, 0, 0, 548, 0, 330, - 0, 0, 0, 0, 0, 330, 0, 0, 536, 0, - 0, 330, 330, 330, 330, 330, 330, 736, 330, 0, - 330, 330, 0, 330, 330, 330, 330, 330, 330, 330, - 330, 330, 330, 548, 330, 330, 330, 330, 330, 330, - 330, 330, 330, 330, 330, 330, 330, 330, 330, 330, - 330, 330, 330, 330, 330, 330, 0, 0, 0, 0, - 330, 0, 330, 0, 0, 330, 0, 0, 0, 0, - 0, 330, 0, 0, 548, 0, 0, 0, 0, 548, - 0, 548, 548, 548, 548, 548, 548, 548, 548, 548, - 548, 548, 0, 0, 0, 552, 0, 0, 0, 0, - 0, 552, 0, 548, 0, 548, 0, 548, 0, 548, - 548, 548, 0, 548, 548, 0, 0, 548, 548, 548, - 548, 548, 548, 548, 548, 548, 0, 0, 0, 548, - 548, 548, 548, 548, 548, 548, 548, 552, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 548, 0, + 0, 0, 455, 0, 0, 0, 394, 457, 0, 0, + 0, 0, 458, 0, 459, 460, 461, 462, 0, 0, + 0, 0, 463, 0, 0, 0, 464, 0, 0, 335, + 1320, 0, 0, 0, 0, 335, 0, 0, 465, 743, + 0, 466, 0, 467, 0, 0, 0, 394, 0, 0, + 0, 0, 394, 0, 394, 394, 394, 394, 394, 394, + 394, 394, 394, 394, 394, 0, 0, 468, 0, 0, + 0, 335, 0, 0, 0, 0, 394, 0, 394, 394, + 394, 394, 394, 394, 394, 0, 394, 743, 0, 394, + 394, 394, 394, 394, 394, 394, 394, 394, 394, 0, + 394, 394, 394, 394, 394, 394, 394, 394, 394, 394, + 394, 394, 394, 394, 394, 394, 394, 394, 394, 394, + 394, 394, 0, 1321, 0, 0, 0, 0, 394, 0, + 335, 394, 0, 0, 0, 0, 335, 394, 0, 0, + 0, 335, 335, 335, 335, 335, 335, 335, 743, 335, + 0, 335, 335, 0, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 0, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 0, 540, 0, + 501, 335, 0, 335, 540, 0, 335, 0, 56, 24, + 0, 25, 335, 0, 26, 253, 0, 0, 0, 27, + 61, 62, 0, 28, 0, 0, 0, 0, 0, 64, + 0, 0, 30, 0, 0, 0, 0, 0, 0, 32, + 540, 0, 0, 0, 33, 0, 71, 72, 34, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 555, 548, 0, 0, 0, 0, 555, - 0, 0, 0, 0, 0, 0, 0, 0, 552, 0, - 0, 0, 0, 552, 0, 552, 552, 552, 552, 552, - 552, 552, 552, 552, 552, 552, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 555, 0, 552, 0, 552, - 0, 552, 0, 552, 552, 552, 0, 552, 552, 0, - 0, 552, 552, 552, 552, 0, 0, 0, 552, 552, - 0, 0, 0, 552, 552, 552, 552, 552, 552, 552, - 552, 0, 0, 0, 0, 0, 555, 0, 0, 0, - 0, 555, 552, 555, 555, 555, 555, 555, 555, 555, - 555, 555, 555, 555, 0, 0, 0, 553, 552, 0, - 0, 0, 0, 553, 0, 555, 0, 555, 0, 555, - 0, 555, 555, 555, 0, 555, 555, 0, 0, 555, - 555, 555, 555, 0, 0, 0, 555, 555, 0, 0, - 0, 555, 555, 555, 555, 555, 555, 555, 555, 553, + 36, 0, 37, 74, 0, 0, 38, 0, 0, 76, + 0, 78, 0, 80, 39, 40, 254, 0, 41, 0, + 0, 540, 0, 0, 0, 0, 540, 0, 540, 540, + 540, 540, 540, 540, 540, 540, 540, 540, 540, 0, + 0, 0, 0, 89, 90, 91, 255, 0, 0, 0, + 540, 0, 540, 0, 540, 95, 540, 540, 540, 0, + 540, 540, 0, 540, 540, 540, 540, 540, 540, 540, + 540, 540, 540, 453, 0, 0, 540, 540, 540, 540, + 540, 540, 540, 540, 540, 540, 540, 540, 540, 540, + 540, 540, 540, 540, 552, 540, 454, 0, 0, 0, + 552, 105, 502, 0, 0, 0, 0, 0, 0, 455, + 0, 540, 0, 0, 457, 0, 0, 0, 0, 458, + 0, 459, 460, 461, 462, 0, 0, 0, 0, 463, + 0, 0, 0, 464, 0, 0, 552, 0, 0, 0, + 0, 0, 0, 0, 0, 465, 0, 0, 466, 0, + 467, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 556, 0, 0, 0, 0, 0, 556, 0, + 0, 0, 0, 0, 468, 0, 0, 552, 0, 0, + 0, 0, 552, 0, 552, 552, 552, 552, 552, 552, + 552, 552, 552, 552, 552, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 556, 0, 552, 0, 552, 0, + 552, 0, 552, 552, 552, 0, 552, 552, 0, 0, + 552, 552, 552, 552, 552, 552, 552, 552, 552, 0, + 1335, 0, 552, 552, 552, 552, 552, 552, 552, 552, + 0, 0, 0, 0, 0, 556, 0, 0, 0, 0, + 556, 552, 556, 556, 556, 556, 556, 556, 556, 556, + 556, 556, 556, 0, 0, 0, 559, 552, 0, 0, + 0, 0, 559, 0, 556, 0, 556, 0, 556, 0, + 556, 556, 556, 0, 556, 556, 0, 0, 556, 556, + 556, 556, 0, 0, 0, 556, 556, 0, 0, 0, + 556, 556, 556, 556, 556, 556, 556, 556, 559, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 556, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 555, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 554, 555, 0, 0, 0, - 0, 554, 0, 0, 0, 0, 0, 0, 0, 0, - 553, 0, 0, 0, 0, 553, 0, 553, 553, 553, - 553, 553, 553, 553, 553, 553, 553, 553, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 554, 0, 553, - 0, 553, 0, 553, 0, 553, 553, 553, 0, 553, - 553, 0, 0, 553, 553, 553, 553, 0, 0, 0, - 553, 553, 0, 558, 0, 553, 553, 553, 553, 553, - 553, 553, 553, 0, 0, 0, 0, 0, 554, 0, - 0, 0, 0, 554, 553, 554, 554, 554, 554, 554, - 554, 554, 554, 554, 554, 554, 0, 0, 0, 0, - 553, 0, 0, 0, 0, 0, 0, 554, 0, 554, - 0, 554, 0, 554, 554, 554, 0, 554, 554, 0, - 0, 554, 554, 554, 554, 0, 0, 0, 554, 554, - 0, 559, 0, 554, 554, 554, 554, 554, 554, 554, - 554, 0, 0, 0, 0, 0, 558, 0, 0, 0, - 0, 558, 554, 558, 558, 558, 558, 558, 558, 558, - 558, 558, 558, 558, 0, 0, 0, 0, 554, 0, - 0, 0, 0, 0, 0, 558, 0, 558, 0, 558, - 0, 558, 558, 558, 0, 0, 0, 0, 0, 558, - 558, 558, 558, 0, 0, 0, 558, 558, 0, 560, - 0, 558, 558, 558, 558, 558, 558, 558, 558, 0, - 0, 0, 0, 0, 559, 0, 0, 0, 0, 559, - 558, 559, 559, 559, 559, 559, 559, 559, 559, 559, - 559, 559, 0, 0, 0, 0, 558, 0, 0, 0, - 0, 0, 0, 559, 0, 559, 0, 559, 0, 559, - 559, 559, 0, 0, 0, 0, 0, 559, 559, 559, - 559, 0, 0, 0, 559, 559, 0, 561, 0, 559, + 0, 0, 0, 0, 557, 556, 0, 0, 0, 0, + 557, 0, 0, 0, 0, 0, 0, 0, 0, 559, + 0, 0, 0, 0, 559, 0, 559, 559, 559, 559, 559, 559, 559, 559, 559, 559, 559, 0, 0, 0, - 0, 0, 560, 0, 0, 0, 0, 560, 559, 560, - 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, - 0, 0, 0, 0, 559, 0, 0, 0, 0, 0, - 0, 560, 0, 560, 0, 560, 0, 560, 560, 560, - 0, 0, 0, 0, 0, 560, 560, 560, 560, 0, - 0, 0, 560, 560, 0, 562, 0, 560, 560, 560, - 560, 560, 560, 560, 560, 0, 0, 0, 0, 0, - 561, 0, 0, 0, 0, 561, 560, 561, 561, 561, - 561, 561, 561, 561, 561, 561, 561, 561, 0, 0, - 0, 0, 560, 0, 0, 0, 0, 0, 0, 561, - 0, 561, 0, 561, 0, 561, 561, 561, 0, 0, - 0, 0, 0, 561, 561, 561, 561, 0, 0, 0, - 561, 561, 0, 563, 0, 0, 0, 561, 561, 561, - 561, 561, 561, 0, 0, 0, 0, 0, 562, 0, - 0, 0, 0, 562, 561, 562, 562, 562, 562, 562, - 562, 562, 562, 562, 562, 562, 0, 0, 0, 0, - 561, 0, 0, 0, 0, 0, 0, 562, 0, 562, - 0, 562, 0, 562, 562, 562, 0, 0, 0, 0, - 0, 562, 562, 562, 562, 0, 0, 0, 562, 562, - 0, 564, 0, 0, 0, 562, 562, 562, 562, 562, - 562, 0, 0, 0, 0, 0, 563, 0, 0, 0, - 0, 563, 562, 563, 563, 563, 563, 563, 563, 563, - 563, 563, 563, 563, 0, 0, 0, 0, 562, 0, - 0, 0, 0, 0, 0, 563, 0, 563, 0, 563, - 0, 563, 563, 563, 0, 0, 0, 0, 0, 563, - 563, 563, 563, 0, 0, 0, 563, 563, 0, 565, - 0, 0, 0, 563, 563, 563, 563, 563, 563, 0, - 0, 0, 0, 0, 564, 0, 0, 0, 0, 564, - 563, 564, 564, 564, 564, 564, 564, 564, 564, 564, - 564, 564, 0, 0, 0, 0, 563, 0, 0, 0, - 0, 0, 0, 564, 0, 564, 0, 564, 0, 564, - 564, 564, 0, 0, 0, 0, 0, 564, 564, 564, - 564, 0, 0, 0, 564, 564, 0, 566, 0, 0, - 0, 564, 564, 564, 564, 564, 564, 0, 0, 0, - 0, 0, 565, 0, 0, 0, 0, 565, 564, 565, + 0, 0, 0, 0, 0, 0, 557, 0, 559, 0, + 559, 0, 559, 0, 559, 559, 559, 0, 559, 559, + 0, 0, 559, 559, 559, 559, 0, 0, 0, 559, + 559, 0, 0, 0, 559, 559, 559, 559, 559, 559, + 559, 559, 0, 0, 0, 0, 0, 557, 0, 0, + 0, 0, 557, 559, 557, 557, 557, 557, 557, 557, + 557, 557, 557, 557, 557, 0, 0, 0, 558, 559, + 0, 0, 0, 0, 558, 0, 557, 0, 557, 0, + 557, 0, 557, 557, 557, 0, 557, 557, 0, 0, + 557, 557, 557, 557, 0, 0, 0, 557, 557, 0, + 0, 0, 557, 557, 557, 557, 557, 557, 557, 557, + 558, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 557, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 562, 557, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 558, 0, 0, 0, 0, 558, 0, 558, 558, + 558, 558, 558, 558, 558, 558, 558, 558, 558, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 558, 0, 558, 0, 558, 0, 558, 558, 558, 0, + 558, 558, 0, 0, 558, 558, 558, 558, 0, 0, + 0, 558, 558, 0, 563, 0, 558, 558, 558, 558, + 558, 558, 558, 558, 0, 0, 0, 0, 0, 562, + 0, 0, 0, 0, 562, 558, 562, 562, 562, 562, + 562, 562, 562, 562, 562, 562, 562, 0, 0, 0, + 0, 558, 0, 0, 0, 0, 0, 0, 562, 0, + 562, 0, 562, 0, 562, 562, 562, 0, 0, 0, + 0, 0, 562, 562, 562, 562, 0, 0, 0, 562, + 562, 0, 564, 0, 562, 562, 562, 562, 562, 562, + 562, 562, 0, 0, 0, 0, 0, 563, 0, 0, + 0, 0, 563, 562, 563, 563, 563, 563, 563, 563, + 563, 563, 563, 563, 563, 0, 0, 0, 0, 562, + 0, 0, 0, 0, 0, 0, 563, 0, 563, 0, + 563, 0, 563, 563, 563, 0, 0, 0, 0, 0, + 563, 563, 563, 563, 0, 0, 0, 563, 563, 0, + 565, 0, 563, 563, 563, 563, 563, 563, 563, 563, + 0, 0, 0, 0, 0, 564, 0, 0, 0, 0, + 564, 563, 564, 564, 564, 564, 564, 564, 564, 564, + 564, 564, 564, 0, 0, 0, 0, 563, 0, 0, + 0, 0, 0, 0, 564, 0, 564, 0, 564, 0, + 564, 564, 564, 0, 0, 0, 0, 0, 564, 564, + 564, 564, 0, 0, 0, 564, 564, 0, 566, 0, + 564, 564, 564, 564, 564, 564, 564, 564, 0, 0, + 0, 0, 0, 565, 0, 0, 0, 0, 565, 564, 565, 565, 565, 565, 565, 565, 565, 565, 565, 565, - 0, 0, 0, 0, 564, 0, 0, 0, 0, 0, - 0, 565, 0, 565, 0, 565, 0, 565, 565, 565, - 0, 0, 0, 0, 0, 565, 565, 565, 565, 0, - 0, 0, 565, 565, 0, 567, 0, 0, 0, 565, - 565, 565, 565, 565, 565, 0, 0, 0, 0, 0, - 566, 0, 0, 0, 0, 566, 565, 566, 566, 566, - 566, 566, 566, 566, 566, 566, 566, 566, 0, 0, - 0, 0, 565, 0, 0, 0, 0, 0, 0, 566, - 0, 566, 0, 566, 0, 566, 566, 566, 0, 0, - 0, 0, 0, 0, 0, 566, 566, 0, 0, 0, - 566, 566, 0, 568, 0, 0, 0, 0, 0, 566, - 566, 566, 566, 0, 0, 0, 0, 0, 567, 0, - 0, 0, 0, 567, 566, 567, 567, 567, 567, 567, - 567, 567, 567, 567, 567, 567, 0, 0, 0, 0, - 566, 0, 0, 0, 0, 0, 0, 567, 0, 567, - 0, 567, 0, 567, 567, 567, 0, 0, 0, 0, - 0, 0, 0, 567, 567, 0, 0, 0, 567, 567, - 0, 569, 0, 0, 0, 0, 0, 567, 567, 567, - 567, 0, 0, 0, 0, 0, 568, 0, 0, 0, - 0, 568, 567, 568, 568, 568, 568, 568, 568, 568, - 568, 568, 568, 568, 0, 0, 0, 0, 567, 0, - 0, 0, 0, 0, 0, 568, 0, 568, 0, 568, - 0, 568, 568, 568, 0, 0, 0, 0, 0, 0, - 0, 568, 568, 0, 0, 0, 568, 568, 0, 570, - 0, 0, 0, 0, 0, 568, 568, 568, 568, 0, - 0, 0, 0, 0, 569, 0, 0, 0, 0, 569, - 568, 569, 569, 569, 569, 569, 569, 569, 569, 569, - 569, 569, 0, 0, 0, 0, 568, 0, 0, 0, - 0, 0, 0, 569, 0, 569, 0, 569, 0, 569, - 569, 569, 0, 0, 0, 0, 0, 0, 0, 569, - 569, 0, 0, 0, 569, 569, 0, 571, 0, 0, - 0, 0, 0, 0, 0, 569, 569, 0, 0, 0, - 0, 0, 570, 0, 0, 0, 0, 570, 569, 570, + 565, 0, 0, 0, 0, 564, 0, 0, 0, 0, + 0, 0, 565, 0, 565, 0, 565, 0, 565, 565, + 565, 0, 0, 0, 0, 0, 565, 565, 565, 565, + 0, 0, 0, 565, 565, 0, 567, 0, 0, 0, + 565, 565, 565, 565, 565, 565, 0, 0, 0, 0, + 0, 566, 0, 0, 0, 0, 566, 565, 566, 566, + 566, 566, 566, 566, 566, 566, 566, 566, 566, 0, + 0, 0, 0, 565, 0, 0, 0, 0, 0, 0, + 566, 0, 566, 0, 566, 0, 566, 566, 566, 0, + 0, 0, 0, 0, 566, 566, 566, 566, 0, 0, + 0, 566, 566, 0, 568, 0, 0, 0, 566, 566, + 566, 566, 566, 566, 0, 0, 0, 0, 0, 567, + 0, 0, 0, 0, 567, 566, 567, 567, 567, 567, + 567, 567, 567, 567, 567, 567, 567, 0, 0, 0, + 0, 566, 0, 0, 0, 0, 0, 0, 567, 0, + 567, 0, 567, 0, 567, 567, 567, 0, 0, 0, + 0, 0, 567, 567, 567, 567, 0, 0, 0, 567, + 567, 0, 569, 0, 0, 0, 567, 567, 567, 567, + 567, 567, 0, 0, 0, 0, 0, 568, 0, 0, + 0, 0, 568, 567, 568, 568, 568, 568, 568, 568, + 568, 568, 568, 568, 568, 0, 0, 0, 0, 567, + 0, 0, 0, 0, 0, 0, 568, 0, 568, 0, + 568, 0, 568, 568, 568, 0, 0, 0, 0, 0, + 568, 568, 568, 568, 0, 0, 0, 568, 568, 0, + 570, 0, 0, 0, 568, 568, 568, 568, 568, 568, + 0, 0, 0, 0, 0, 569, 0, 0, 0, 0, + 569, 568, 569, 569, 569, 569, 569, 569, 569, 569, + 569, 569, 569, 0, 0, 0, 0, 568, 0, 0, + 0, 0, 0, 0, 569, 0, 569, 0, 569, 0, + 569, 569, 569, 0, 0, 0, 0, 0, 569, 569, + 569, 569, 0, 0, 0, 569, 569, 0, 571, 0, + 0, 0, 569, 569, 569, 569, 569, 569, 0, 0, + 0, 0, 0, 570, 0, 0, 0, 0, 570, 569, 570, 570, 570, 570, 570, 570, 570, 570, 570, 570, - 0, 0, 0, 0, 569, 0, 0, 0, 0, 0, - 0, 570, 0, 570, 0, 570, 0, 570, 570, 570, - 0, 0, 0, 0, 0, 0, 0, 570, 570, 0, - 0, 0, 570, 570, 0, 572, 0, 0, 0, 0, - 0, 0, 0, 570, 570, 0, 0, 0, 0, 0, - 571, 0, 0, 0, 0, 571, 570, 571, 571, 571, - 571, 571, 571, 571, 571, 571, 571, 571, 0, 0, - 0, 0, 570, 0, 0, 0, 0, 0, 0, 571, - 0, 571, 0, 571, 0, 571, 571, 571, 0, 0, - 0, 0, 0, 0, 0, 0, 571, 0, 0, 0, - 571, 571, 0, 573, 0, 0, 0, 0, 0, 0, - 0, 571, 571, 0, 0, 0, 0, 0, 572, 0, - 0, 0, 0, 572, 571, 572, 572, 572, 572, 572, - 572, 572, 572, 572, 572, 572, 0, 0, 0, 0, - 571, 0, 0, 0, 0, 0, 0, 572, 0, 572, - 0, 572, 0, 572, 572, 572, 0, 0, 0, 0, - 0, 0, 0, 0, 572, 0, 0, 0, 572, 572, - 0, 574, 0, 0, 0, 0, 0, 0, 0, 572, - 572, 0, 0, 0, 0, 0, 573, 0, 0, 0, - 0, 573, 572, 573, 573, 573, 573, 573, 573, 573, - 573, 573, 573, 573, 0, 0, 0, 0, 572, 0, - 0, 0, 0, 0, 0, 573, 0, 573, 0, 573, - 0, 573, 573, 573, 0, 0, 0, 0, 0, 0, - 0, 0, 573, 0, 0, 0, 0, 573, 0, 575, - 0, 0, 0, 0, 0, 0, 0, 573, 573, 0, - 0, 0, 0, 0, 574, 0, 0, 0, 0, 574, - 573, 574, 574, 574, 574, 574, 574, 574, 574, 574, - 574, 574, 0, 0, 0, 0, 573, 0, 0, 0, - 0, 0, 0, 574, 0, 574, 0, 574, 0, 574, - 574, 574, 0, 0, 0, 0, 0, 0, 0, 0, - 574, 0, 0, 0, 0, 574, 0, 576, 0, 0, - 0, 0, 0, 0, 0, 574, 574, 0, 0, 0, - 0, 0, 575, 0, 0, 0, 0, 575, 574, 575, + 570, 0, 0, 0, 0, 569, 0, 0, 0, 0, + 0, 0, 570, 0, 570, 0, 570, 0, 570, 570, + 570, 0, 0, 0, 0, 0, 0, 0, 570, 570, + 0, 0, 0, 570, 570, 0, 572, 0, 0, 0, + 0, 0, 570, 570, 570, 570, 0, 0, 0, 0, + 0, 571, 0, 0, 0, 0, 571, 570, 571, 571, + 571, 571, 571, 571, 571, 571, 571, 571, 571, 0, + 0, 0, 0, 570, 0, 0, 0, 0, 0, 0, + 571, 0, 571, 0, 571, 0, 571, 571, 571, 0, + 0, 0, 0, 0, 0, 0, 571, 571, 0, 0, + 0, 571, 571, 0, 573, 0, 0, 0, 0, 0, + 571, 571, 571, 571, 0, 0, 0, 0, 0, 572, + 0, 0, 0, 0, 572, 571, 572, 572, 572, 572, + 572, 572, 572, 572, 572, 572, 572, 0, 0, 0, + 0, 571, 0, 0, 0, 0, 0, 0, 572, 0, + 572, 0, 572, 0, 572, 572, 572, 0, 0, 0, + 0, 0, 0, 0, 572, 572, 0, 0, 0, 572, + 572, 0, 574, 0, 0, 0, 0, 0, 572, 572, + 572, 572, 0, 0, 0, 0, 0, 573, 0, 0, + 0, 0, 573, 572, 573, 573, 573, 573, 573, 573, + 573, 573, 573, 573, 573, 0, 0, 0, 0, 572, + 0, 0, 0, 0, 0, 0, 573, 0, 573, 0, + 573, 0, 573, 573, 573, 0, 0, 0, 0, 0, + 0, 0, 573, 573, 0, 0, 0, 573, 573, 0, + 575, 0, 0, 0, 0, 0, 0, 0, 573, 573, + 0, 0, 0, 0, 0, 574, 0, 0, 0, 0, + 574, 573, 574, 574, 574, 574, 574, 574, 574, 574, + 574, 574, 574, 0, 0, 0, 0, 573, 0, 0, + 0, 0, 0, 0, 574, 0, 574, 0, 574, 0, + 574, 574, 574, 0, 0, 0, 0, 0, 0, 0, + 574, 574, 0, 0, 0, 574, 574, 0, 576, 0, + 0, 0, 0, 0, 0, 0, 574, 574, 0, 0, + 0, 0, 0, 575, 0, 0, 0, 0, 575, 574, 575, 575, 575, 575, 575, 575, 575, 575, 575, 575, - 0, 0, 0, 0, 574, 0, 0, 0, 0, 0, - 0, 575, 0, 575, 0, 575, 0, 575, 575, 575, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 575, 0, 577, 0, 0, 0, 0, - 0, 0, 0, 575, 575, 0, 0, 0, 0, 0, - 576, 0, 0, 0, 0, 576, 575, 576, 576, 576, - 576, 576, 576, 576, 576, 576, 576, 576, 0, 0, - 0, 0, 575, 0, 0, 0, 0, 0, 0, 576, - 0, 576, 0, 576, 0, 576, 576, 576, 0, 0, - 0, 578, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 576, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 576, 576, 0, 0, 0, 0, 0, 577, 0, - 0, 0, 0, 577, 576, 577, 577, 577, 577, 577, - 577, 577, 577, 577, 577, 577, 0, 0, 0, 0, - 576, 0, 0, 0, 0, 0, 0, 577, 0, 577, - 0, 577, 0, 577, 577, 577, 0, 0, 0, 579, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 577, - 0, 0, 0, 0, 578, 0, 0, 0, 0, 578, - 577, 578, 578, 578, 578, 578, 578, 578, 578, 578, - 578, 578, 577, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 578, 0, 578, 0, 578, 577, 578, - 578, 578, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 330, 578, 0, 0, 736, 0, - 0, 0, 0, 0, 0, 0, 578, 0, 0, 0, - 0, 0, 579, 0, 0, 0, 0, 579, 578, 579, - 579, 579, 579, 579, 579, 579, 579, 579, 579, 579, - 330, 0, 0, 0, 578, 0, 0, 0, 0, 0, - 0, 579, 0, 579, 0, 579, 736, 579, 579, 579, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 579, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 330, - 0, 0, 0, 0, 0, 330, 0, 0, 0, 0, - 0, 330, 579, 330, 0, 330, 0, 736, 330, 0, - 330, 330, 0, 330, 330, 330, 330, 330, 330, 330, - 330, 330, 330, 0, 330, 330, 330, 330, 330, 330, - 330, 330, 330, 330, 330, 330, 330, 330, 330, 330, - 330, 330, 330, 330, 330, 330, 0, 0, 55, 0, - 330, 0, 330, 0, 0, 330, 56, 24, 57, 25, - 0, 330, 26, 58, 0, 59, 60, 27, 61, 62, - 63, 28, 0, 0, 0, 0, 0, 64, 0, 65, - 30, 66, 67, 68, 69, 0, 0, 32, 0, 0, - 0, 70, 33, 0, 71, 72, 34, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 73, 0, 36, 0, - 37, 74, 0, 0, 38, 0, 75, 76, 77, 78, - 79, 80, 39, 40, 81, 82, 41, 83, 0, 84, - 0, 0, 85, 86, 0, 0, 87, 88, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 89, 90, 91, 92, 93, 0, 0, 0, 94, - 0, 0, 0, 95, 0, 0, 0, 0, 96, 97, - 98, 99, 100, 0, 0, 0, 101, 0, 102, 0, - 0, 0, 0, 0, 103, 104, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 265, 0, 0, 0, 105, - 106, 107, 108, 56, 24, 57, 25, 0, 0, 26, - 58, 0, 59, 60, 27, 61, 62, 63, 28, 0, - 0, 0, 0, 0, 64, 0, 65, 30, 66, 67, - 68, 69, 0, 0, 32, 0, 0, 0, 70, 33, - 0, 71, 72, 34, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 73, 0, 36, 0, 37, 74, 0, - 0, 38, 0, 75, 76, 77, 78, 79, 80, 39, - 40, 81, 82, 41, 83, 0, 84, 0, 0, 85, - 86, 0, 0, 87, 88, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 89, 90, - 91, 92, 93, 0, 0, 0, 94, 0, 0, 0, - 95, 0, 0, 0, 0, 96, 97, 98, 99, 100, - 0, 0, 0, 101, 0, 102, 0, 0, 0, 0, - 0, 103, 104, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 549, 0, 0, 0, 105, 106, 107, 108, - 56, 24, 57, 25, 0, 0, 26, 58, 0, 59, - 60, 27, 61, 62, 63, 28, 0, 0, 0, 0, - 0, 64, 0, 65, 30, 66, 67, 68, 69, 0, - 0, 32, 0, 0, 0, 70, 33, 0, 71, 72, - 34, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 73, 0, 36, 0, 37, 74, 0, 0, 38, 0, - 75, 76, 77, 78, 79, 80, 39, 40, 81, 82, - 41, 83, 0, 84, 0, 0, 85, 86, 0, 0, - 87, 88, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 89, 90, 91, 92, 93, - 0, 0, 0, 94, 0, 0, 0, 95, 0, 0, - 0, 0, 96, 97, 98, 99, 100, 0, 0, 0, - 101, 0, 102, 0, 0, 0, 0, 0, 103, 104, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 933, - 0, 0, 0, 105, 550, 107, 108, 933, 933, 933, - 933, 0, 0, 933, 933, 0, 933, 933, 933, 933, - 933, 933, 933, 0, 0, 0, 0, 0, 933, 0, - 933, 933, 933, 933, 933, 933, 0, 0, 933, 0, - 0, 0, 933, 933, 0, 933, 933, 933, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 933, 0, 933, - 0, 933, 933, 0, 0, 933, 0, 933, 933, 933, - 933, 933, 933, 933, 933, 933, 933, 933, 933, 0, - 933, 0, 0, 933, 933, 0, 0, 933, 933, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 933, 933, 933, 933, 933, 0, 0, 0, - 933, 0, 0, 0, 933, 0, 0, 0, 0, 933, - 933, 933, 933, 933, 0, 0, 0, 933, 0, 933, - 0, 0, 0, 0, 0, 933, 933, 0, 0, 0, + 575, 0, 0, 0, 0, 574, 0, 0, 0, 0, + 0, 0, 575, 0, 575, 0, 575, 0, 575, 575, + 575, 0, 0, 0, 0, 0, 0, 0, 0, 575, + 0, 0, 0, 575, 575, 0, 577, 0, 0, 0, + 0, 0, 0, 0, 575, 575, 0, 0, 0, 0, + 0, 576, 0, 0, 0, 0, 576, 575, 576, 576, + 576, 576, 576, 576, 576, 576, 576, 576, 576, 0, + 0, 0, 0, 575, 0, 0, 0, 0, 0, 0, + 576, 0, 576, 0, 576, 0, 576, 576, 576, 0, + 0, 0, 0, 0, 0, 0, 0, 576, 0, 0, + 0, 576, 576, 0, 578, 0, 0, 0, 0, 0, + 0, 0, 576, 576, 0, 0, 0, 0, 0, 577, + 0, 0, 0, 0, 577, 576, 577, 577, 577, 577, + 577, 577, 577, 577, 577, 577, 577, 0, 0, 0, + 0, 576, 0, 0, 0, 0, 0, 0, 577, 0, + 577, 0, 577, 0, 577, 577, 577, 0, 0, 0, + 0, 0, 0, 0, 0, 577, 0, 0, 0, 0, + 577, 0, 579, 0, 0, 0, 0, 0, 0, 0, + 577, 577, 0, 0, 0, 0, 0, 578, 0, 0, + 0, 0, 578, 577, 578, 578, 578, 578, 578, 578, + 578, 578, 578, 578, 578, 0, 0, 0, 0, 577, + 0, 0, 0, 0, 0, 0, 578, 0, 578, 0, + 578, 0, 578, 578, 578, 0, 0, 0, 0, 0, + 0, 0, 0, 578, 0, 0, 0, 0, 578, 0, + 580, 0, 0, 0, 0, 0, 0, 0, 578, 578, + 0, 0, 0, 0, 0, 579, 0, 0, 0, 0, + 579, 578, 579, 579, 579, 579, 579, 579, 579, 579, + 579, 579, 579, 0, 0, 0, 0, 578, 0, 0, + 0, 0, 0, 0, 579, 0, 579, 0, 579, 0, + 579, 579, 579, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 335, 579, 0, 0, 743, + 0, 0, 0, 0, 0, 0, 579, 579, 0, 0, + 0, 0, 0, 580, 0, 0, 0, 0, 580, 579, + 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, + 580, 335, 0, 0, 0, 579, 0, 0, 0, 0, + 0, 0, 580, 0, 580, 0, 580, 743, 580, 580, + 580, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 580, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 580, 580, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 580, 0, 0, + 335, 0, 0, 0, 0, 0, 335, 0, 0, 0, + 0, 335, 335, 580, 335, 0, 335, 0, 743, 335, + 0, 335, 335, 0, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 0, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 0, 0, 55, + 0, 335, 0, 335, 0, 0, 335, 56, 24, 57, + 25, 0, 335, 26, 58, 0, 59, 60, 27, 61, + 62, 63, 28, 0, 0, 0, 0, 0, 64, 0, + 65, 30, 66, 67, 68, 69, 0, 0, 32, 0, + 0, 0, 70, 33, 0, 71, 72, 34, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 73, 0, 36, + 0, 37, 74, 0, 0, 38, 0, 75, 76, 77, + 78, 79, 80, 39, 40, 81, 82, 41, 83, 0, + 84, 0, 0, 85, 86, 0, 0, 87, 88, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 784, 0, 0, 0, - 933, 933, 933, 933, 784, 784, 784, 784, 0, 0, - 784, 784, 0, 784, 784, 784, 784, 784, 784, 784, - 0, 0, 0, 0, 0, 784, 0, 784, 784, 784, - 784, 784, 784, 0, 0, 784, 0, 0, 0, 784, - 784, 0, 784, 784, 784, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 784, 0, 784, 0, 784, 784, - 0, 0, 784, 0, 784, 784, 784, 784, 784, 784, - 784, 784, 784, 784, 784, 784, 0, 784, 0, 0, - 784, 784, 0, 0, 784, 784, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 784, - 784, 784, 784, 784, 0, 0, 0, 784, 0, 0, - 0, 784, 0, 0, 0, 0, 784, 784, 784, 784, - 784, 0, 0, 0, 784, 0, 784, 0, 0, 0, - 0, 0, 784, 784, 0, 0, 0, 0, 0, 0, + 0, 0, 89, 90, 91, 92, 93, 0, 0, 0, + 94, 0, 0, 0, 95, 0, 0, 0, 0, 96, + 97, 98, 99, 100, 0, 0, 0, 101, 0, 102, + 0, 0, 0, 0, 0, 103, 104, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 731, 0, 0, 0, 784, 784, 784, - 784, 56, 24, 0, 25, 0, 0, 26, 253, 0, - 1033, 0, 27, 61, 62, 0, 28, 0, 0, 24, - 0, 25, 64, 0, 26, 30, 0, 0, 0, 27, - 0, 0, 32, 28, 0, 0, 0, 33, 0, 71, - 72, 34, 30, 0, 0, 0, 0, 0, 0, 32, - 0, 0, 0, 36, 33, 37, 74, 0, 34, 38, - 0, 0, 76, 0, 78, 0, 80, 39, 40, 254, - 36, 41, 37, 0, 0, 0, 38, 0, 86, 0, - 0, 87, 88, 0, 39, 40, 0, 0, 41, 0, - 0, 319, 0, 0, 0, 0, 89, 90, 91, 92, - 300, 0, 0, 0, 511, 732, 0, 0, 95, 0, - 0, 0, 0, 0, 97, 98, 99, 100, 0, 0, - 0, 101, 0, 102, 0, 0, 0, 0, 0, 103, - 104, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 918, 0, 0, 0, 105, 301, 107, 108, 56, 24, - 0, 25, 0, 0, 26, 253, 0, 1155, 0, 27, - 61, 62, 352, 28, 0, 0, 24, 0, 25, 64, - 0, 26, 30, 0, 0, 0, 27, 0, 0, 32, - 28, 0, 0, 0, 33, 0, 71, 72, 34, 30, - 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, - 36, 33, 37, 74, 919, 34, 38, 0, 0, 76, - 0, 78, 0, 80, 39, 40, 254, 36, 41, 37, - 0, 0, 0, 38, 0, 86, 0, 0, 87, 88, - 0, 39, 40, 0, 0, 41, 0, 0, 319, 0, - 0, 0, 0, 89, 90, 91, 92, 300, 0, 0, - 0, 511, 0, 0, 0, 95, 0, 0, 0, 0, - 0, 97, 98, 99, 100, 0, 0, 0, 101, 0, - 102, 0, 0, 0, 0, 0, 103, 104, 0, 0, - 0, 0, 0, 0, 56, 24, 0, 25, 0, 0, - 26, 253, 0, 0, 0, 27, 61, 62, 0, 28, - 0, 105, 301, 107, 108, 64, 0, 0, 30, 0, - 0, 0, 0, 0, 0, 32, 0, 0, 0, 352, + 0, 0, 0, 0, 0, 0, 266, 0, 0, 0, + 105, 106, 107, 108, 56, 24, 57, 25, 0, 0, + 26, 58, 0, 59, 60, 27, 61, 62, 63, 28, + 0, 0, 0, 0, 0, 64, 0, 65, 30, 66, + 67, 68, 69, 0, 0, 32, 0, 0, 0, 70, 33, 0, 71, 72, 34, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 36, 0, 37, 74, - 0, 0, 38, 0, 0, 76, 0, 78, 0, 80, - 39, 40, 254, 0, 41, 0, 0, 0, 0, 0, - 0, 86, 0, 0, 87, 88, 0, 0, 0, 0, + 0, 0, 0, 0, 73, 0, 36, 0, 37, 74, + 0, 0, 38, 0, 75, 76, 77, 78, 79, 80, + 39, 40, 81, 82, 41, 83, 0, 84, 0, 0, + 85, 86, 0, 0, 87, 88, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 89, - 90, 91, 92, 300, 0, 0, 0, 718, 987, 0, - 0, 95, 0, 0, 0, 0, 0, 97, 98, 99, + 90, 91, 92, 93, 0, 0, 0, 94, 0, 0, + 0, 95, 0, 0, 0, 0, 96, 97, 98, 99, 100, 0, 0, 0, 101, 0, 102, 0, 0, 0, 0, 0, 103, 104, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 731, 0, 105, 719, 107, - 108, 0, 0, 56, 24, 0, 25, 0, 720, 26, - 253, 0, 0, 0, 27, 61, 62, 0, 28, 0, - 0, 170, 0, 170, 64, 0, 170, 30, 0, 0, - 0, 170, 0, 0, 32, 170, 0, 0, 0, 33, - 0, 71, 72, 34, 170, 0, 0, 0, 0, 0, - 0, 170, 0, 0, 0, 36, 170, 37, 74, 919, - 170, 38, 0, 0, 76, 0, 78, 0, 80, 39, - 40, 254, 170, 41, 170, 0, 0, 0, 170, 0, - 86, 0, 0, 87, 88, 0, 170, 170, 0, 0, - 170, 0, 0, 170, 0, 0, 0, 0, 89, 90, - 91, 92, 300, 0, 0, 0, 511, 0, 0, 0, - 95, 0, 0, 0, 0, 0, 97, 98, 99, 100, - 0, 0, 0, 101, 0, 102, 0, 0, 957, 0, - 0, 103, 104, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 556, 0, 0, 0, 105, 106, 107, + 108, 56, 24, 57, 25, 0, 0, 26, 58, 0, + 59, 60, 27, 61, 62, 63, 28, 0, 0, 0, + 0, 0, 64, 0, 65, 30, 66, 67, 68, 69, + 0, 0, 32, 0, 0, 0, 70, 33, 0, 71, + 72, 34, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 73, 0, 36, 0, 37, 74, 0, 0, 38, + 0, 75, 76, 77, 78, 79, 80, 39, 40, 81, + 82, 41, 83, 0, 84, 0, 0, 85, 86, 0, + 0, 87, 88, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 89, 90, 91, 92, + 93, 0, 0, 0, 94, 0, 0, 0, 95, 0, + 0, 0, 0, 96, 97, 98, 99, 100, 0, 0, + 0, 101, 0, 102, 0, 0, 0, 0, 0, 103, + 104, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 699, 0, 0, 0, 105, 301, 107, 108, - 56, 24, 0, 25, 0, 0, 26, 253, 0, 0, - 0, 27, 61, 62, 170, 28, 0, 0, 170, 0, - 170, 64, 0, 170, 30, 0, 0, 0, 170, 0, - 0, 32, 170, 0, 0, 0, 33, 0, 71, 72, - 34, 170, 0, 0, 0, 0, 0, 0, 170, 0, - 0, 0, 36, 170, 37, 74, 0, 170, 38, 0, - 0, 76, 0, 78, 0, 80, 39, 40, 254, 170, - 41, 170, 0, 84, 0, 170, 0, 86, 0, 0, - 87, 88, 0, 170, 170, 0, 0, 170, 0, 0, - 170, 0, 0, 0, 0, 89, 90, 91, 92, 300, - 0, 0, 0, 0, 0, 0, 0, 95, 0, 0, - 0, 0, 0, 97, 98, 99, 100, 0, 0, 0, - 101, 0, 102, 957, 0, 0, 0, 0, 103, 104, - 0, 0, 0, 0, 0, 0, 56, 24, 0, 25, - 0, 0, 26, 253, 0, 0, 0, 27, 61, 62, - 0, 28, 0, 105, 301, 107, 108, 64, 0, 0, - 30, 0, 0, 0, 0, 0, 0, 32, 0, 0, - 0, 170, 33, 0, 71, 72, 34, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 36, 0, - 37, 74, 0, 0, 38, 0, 0, 76, 0, 78, - 0, 80, 39, 40, 254, 0, 41, 0, 0, 0, - 0, 0, 0, 86, 0, 0, 87, 88, 0, 0, + 950, 0, 0, 0, 105, 557, 107, 108, 950, 950, + 950, 950, 0, 0, 950, 950, 0, 950, 950, 950, + 950, 950, 950, 950, 0, 0, 0, 0, 0, 950, + 0, 950, 950, 950, 950, 950, 950, 0, 0, 950, + 0, 0, 0, 950, 950, 0, 950, 950, 950, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 950, 0, + 950, 0, 950, 950, 0, 0, 950, 0, 950, 950, + 950, 950, 950, 950, 950, 950, 950, 950, 950, 950, + 0, 950, 0, 0, 950, 950, 0, 0, 950, 950, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 89, 90, 91, 92, 300, 0, 0, 0, 718, - 0, 0, 0, 95, 0, 0, 0, 0, 0, 97, - 98, 99, 100, 0, 0, 0, 101, 0, 102, 0, - 0, 0, 0, 0, 103, 104, 0, 0, 0, 0, + 0, 0, 0, 950, 950, 950, 950, 950, 0, 0, + 0, 950, 0, 0, 0, 950, 0, 0, 0, 0, + 950, 950, 950, 950, 950, 0, 0, 0, 950, 0, + 950, 0, 0, 0, 0, 0, 950, 950, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 794, 0, 0, + 0, 950, 950, 950, 950, 794, 794, 794, 794, 0, + 0, 794, 794, 0, 794, 794, 794, 794, 794, 794, + 794, 0, 0, 0, 0, 0, 794, 0, 794, 794, + 794, 794, 794, 794, 0, 0, 794, 0, 0, 0, + 794, 794, 0, 794, 794, 794, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 794, 0, 794, 0, 794, + 794, 0, 0, 794, 0, 794, 794, 794, 794, 794, + 794, 794, 794, 794, 794, 794, 794, 0, 794, 0, + 0, 794, 794, 0, 0, 794, 794, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 731, 0, 105, - 719, 107, 108, 0, 0, 56, 24, 0, 25, 0, - 720, 26, 253, 0, 0, 0, 27, 61, 62, 0, - 28, 0, 0, 24, 0, 25, 64, 0, 26, 30, - 0, 0, 0, 27, 0, 0, 32, 28, 0, 0, - 0, 33, 0, 71, 72, 34, 30, 0, 0, 0, - 0, 0, 0, 32, 0, 0, 0, 36, 33, 37, - 74, 0, 34, 38, 0, 0, 76, 0, 78, 0, - 80, 39, 40, 254, 36, 41, 37, 0, 0, 0, - 38, 0, 86, 0, 0, 87, 88, 0, 39, 40, - 0, 0, 41, 0, 0, 319, 0, 0, 0, 0, - 89, 90, 91, 92, 300, 0, 0, 0, 511, 0, - 0, 0, 95, 0, 0, 0, 0, 0, 97, 98, - 99, 100, 0, 0, 0, 101, 0, 102, 0, 0, - 0, 0, 0, 103, 104, 0, 0, 0, 0, 0, + 794, 794, 794, 794, 794, 0, 0, 0, 794, 0, + 0, 0, 794, 0, 0, 0, 0, 794, 794, 794, + 794, 794, 0, 0, 0, 794, 0, 794, 0, 0, + 0, 0, 0, 794, 794, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 584, 0, 0, 0, 105, 301, - 107, 108, 56, 24, 0, 25, 0, 0, 26, 253, - 0, 0, 0, 27, 61, 62, 352, 28, 0, 0, + 0, 0, 0, 0, 742, 0, 0, 0, 794, 794, + 794, 794, 56, 24, 0, 25, 0, 0, 26, 253, + 0, 903, 0, 27, 61, 62, 0, 28, 0, 0, 24, 0, 25, 64, 0, 26, 30, 0, 0, 0, 27, 0, 0, 32, 28, 0, 0, 0, 33, 0, 71, 72, 34, 30, 0, 0, 0, 0, 0, 0, @@ -10621,180 +10801,305 @@ void case_961() 38, 0, 0, 76, 0, 78, 0, 80, 39, 40, 254, 36, 41, 37, 0, 0, 0, 38, 0, 86, 0, 0, 87, 88, 0, 39, 40, 0, 0, 41, - 0, 0, 513, 0, 0, 0, 0, 89, 90, 91, - 92, 93, 0, 0, 0, 0, 0, 0, 0, 95, + 0, 0, 322, 0, 0, 0, 0, 89, 90, 91, + 92, 302, 0, 0, 0, 518, 743, 0, 0, 95, 0, 0, 0, 0, 0, 97, 98, 99, 100, 0, 0, 0, 101, 0, 102, 0, 0, 0, 0, 0, 103, 104, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 906, 0, 0, 0, 105, 106, 107, 108, 56, - 24, 0, 25, 0, 0, 26, 253, 0, 0, 0, - 27, 61, 62, 352, 28, 0, 0, 24, 0, 25, + 0, 929, 0, 0, 0, 105, 303, 107, 108, 56, + 24, 0, 25, 0, 0, 26, 253, 0, 1049, 0, + 27, 61, 62, 355, 28, 0, 0, 24, 0, 25, 64, 0, 26, 30, 0, 0, 0, 27, 0, 0, 32, 28, 0, 0, 0, 33, 0, 71, 72, 34, - 30, 0, 0, 0, 0, 0, 0, 32, 0, 0, + 30, 593, 0, 0, 0, 0, 0, 32, 594, 0, 0, 36, 33, 37, 74, 0, 34, 38, 0, 0, 76, 0, 78, 0, 80, 39, 40, 254, 36, 41, - 37, 0, 0, 0, 38, 0, 86, 0, 0, 87, - 88, 0, 39, 40, 0, 0, 41, 0, 0, 566, - 0, 0, 0, 0, 89, 90, 91, 92, 300, 0, + 37, 0, 0, 0, 38, 0, 595, 0, 0, 87, + 88, 0, 39, 40, 0, 0, 41, 0, 0, 322, + 0, 0, 0, 0, 89, 90, 91, 92, 93, 0, 0, 0, 0, 0, 0, 0, 95, 0, 0, 0, 0, 0, 97, 98, 99, 100, 0, 0, 0, 101, 0, 102, 0, 0, 0, 0, 0, 103, 104, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 603, 0, - 0, 0, 105, 301, 107, 108, 603, 603, 0, 603, - 0, 0, 603, 603, 0, 0, 0, 603, 603, 603, - 352, 603, 0, 0, 24, 0, 25, 603, 0, 26, - 603, 0, 0, 0, 27, 0, 0, 603, 28, 0, - 0, 0, 603, 0, 603, 603, 603, 30, 0, 0, - 0, 0, 0, 0, 32, 0, 0, 0, 603, 33, - 603, 603, 0, 34, 603, 0, 0, 603, 0, 603, - 0, 603, 603, 603, 603, 36, 603, 37, 0, 0, - 0, 38, 0, 603, 0, 0, 603, 603, 0, 39, - 40, 0, 0, 41, 0, 0, 746, 0, 0, 0, - 0, 603, 603, 603, 603, 603, 0, 0, 0, 0, - 0, 0, 0, 603, 0, 0, 0, 0, 0, 603, - 603, 603, 603, 0, 0, 0, 603, 0, 603, 0, - 0, 0, 0, 0, 603, 603, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 494, 0, 0, 0, 603, - 603, 603, 603, 56, 24, 0, 25, 0, 0, 26, - 253, 0, 0, 0, 27, 61, 62, 352, 28, 0, - 0, 0, 0, 0, 64, 0, 0, 30, 0, 0, - 0, 0, 0, 0, 32, 0, 448, 0, 330, 33, - 0, 71, 72, 34, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 36, 0, 37, 74, 449, - 0, 38, 0, 0, 76, 0, 78, 0, 80, 39, - 40, 254, 450, 41, 330, 0, 0, 452, 0, 0, - 0, 0, 453, 0, 454, 455, 456, 457, 0, 0, - 0, 0, 458, 0, 0, 0, 459, 0, 89, 90, - 91, 255, 0, 0, 0, 0, 0, 0, 460, 0, - 95, 461, 0, 462, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 463, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 330, 330, 330, - 330, 736, 0, 0, 330, 330, 105, 495, 330, 330, - 330, 330, 330, 330, 330, 330, 330, 0, 330, 330, - 330, 330, 330, 330, 330, 330, 330, 330, 330, 330, - 330, 330, 330, 330, 330, 330, 330, 330, 330, 330, - 0, 46, 0, 1313, 0, 46, 330, 46, 0, 330, - 46, 0, 46, 46, 0, 46, 0, 46, 0, 46, - 0, 46, 46, 46, 46, 0, 0, 46, 46, 0, - 0, 0, 0, 46, 0, 46, 46, 46, 0, 0, - 46, 0, 46, 0, 46, 0, 0, 46, 0, 46, - 46, 46, 46, 0, 0, 0, 46, 46, 46, 0, - 0, 46, 46, 46, 0, 0, 0, 0, 0, 0, - 46, 46, 0, 46, 46, 0, 46, 46, 46, 0, - 0, 0, 46, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 46, 0, 46, 0, 46, 0, 46, 0, 79, 46, - 0, 46, 46, 0, 46, 0, 46, 46, 46, 0, - 46, 46, 46, 46, 0, 0, 46, 46, 0, 0, - 0, 0, 46, 0, 46, 46, 46, 0, 0, 46, - 0, 46, 0, 46, 0, 0, 46, 0, 46, 46, - 46, 46, 0, 0, 0, 46, 46, 46, 46, 0, - 46, 46, 46, 0, 0, 0, 0, 0, 0, 46, - 46, 0, 46, 46, 0, 46, 46, 46, 0, 0, - 0, 46, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 46, - 0, 46, 0, 46, 0, 46, 0, 80, 46, 0, - 46, 46, 0, 46, 0, 46, 46, 46, 0, 46, - 46, 46, 46, 0, 0, 46, 46, 0, 0, 0, - 0, 46, 0, 46, 46, 46, 0, 0, 46, 0, - 46, 0, 46, 0, 0, 46, 0, 46, 46, 46, - 46, 0, 0, 0, 46, 46, 46, 46, 0, 46, - 46, 46, 0, 0, 0, 0, 0, 0, 46, 46, - 0, 46, 46, 0, 46, 46, 46, 0, 0, 0, - 46, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 46, 0, 0, 0, 46, 0, 46, - 46, 0, 46, 0, 46, 46, 210, 46, 0, 46, - 0, 46, 0, 46, 46, 46, 46, 0, 0, 46, - 46, 0, 0, 0, 0, 46, 0, 46, 46, 46, - 0, 0, 46, 0, 46, 330, 46, 0, 0, 46, - 0, 46, 46, 46, 46, 0, 0, 0, 46, 46, - 46, 0, 0, 46, 46, 46, 46, 0, 330, 0, - 0, 0, 46, 46, 0, 46, 46, 0, 46, 46, - 46, 330, 0, 0, 46, 0, 330, 0, 0, 330, - 0, 330, 0, 330, 330, 330, 330, 0, 0, 0, - 0, 330, 0, 0, 46, 330, 0, 0, 0, 330, - 211, 0, 0, 448, 0, 0, 0, 330, 0, 0, - 330, 0, 330, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 449, 0, 0, 0, - 0, 330, 0, 0, 0, 0, 330, 0, 0, 450, - 0, 0, 0, 330, 452, 261, 0, 330, 0, 453, - 46, 454, 455, 456, 457, 0, 0, 0, 0, 458, - 330, 0, 0, 459, 0, 0, 0, 1298, 0, 0, - 56, 24, 0, 25, 0, 460, 26, 253, 461, 0, - 462, 27, 61, 62, 0, 28, 0, 0, 0, 0, - 0, 64, 330, 0, 30, 0, 0, 0, 0, 0, - 0, 32, 0, 0, 463, 0, 33, 0, 71, 72, - 34, 0, 586, 0, 0, 0, 0, 0, 0, 587, - 0, 0, 36, 0, 37, 74, 0, 0, 38, 0, - 0, 76, 0, 78, 0, 80, 39, 40, 254, 0, - 41, 0, 0, 0, 0, 0, 0, 588, 0, 0, - 87, 88, 0, 0, 0, 0, 0, 0, 0, 0, - 1299, 0, 0, 0, 0, 89, 90, 91, 92, 93, - 0, 0, 0, 0, 0, 0, 0, 95, 913, 0, - 589, 0, 0, 97, 98, 99, 100, 0, 0, 0, - 101, 0, 102, 0, 0, 0, 0, 0, 103, 104, - 0, 0, 0, 0, 0, 0, 56, 24, 0, 25, + 0, 0, 0, 0, 0, 0, 0, 0, 933, 0, + 0, 0, 105, 106, 107, 108, 56, 24, 0, 25, 0, 0, 26, 253, 0, 0, 0, 27, 61, 62, - 0, 28, 0, 105, 106, 107, 108, 64, 0, 0, - 30, 0, 0, 0, 0, 0, 0, 32, 0, 0, - 0, 0, 33, 0, 71, 72, 34, 0, 586, 0, - 0, 0, 0, 0, 0, 587, 0, 0, 36, 0, - 37, 74, 0, 0, 38, 0, 0, 76, 0, 78, - 0, 80, 39, 40, 254, 0, 41, 0, 0, 0, - 0, 0, 0, 588, 0, 0, 87, 88, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 89, 90, 91, 92, 93, 0, 0, 0, 0, - 0, 0, 0, 95, 0, 0, 589, 0, 0, 97, + 355, 28, 0, 0, 174, 0, 174, 64, 0, 174, + 30, 0, 0, 0, 174, 0, 0, 32, 174, 0, + 0, 0, 33, 0, 71, 72, 34, 174, 0, 0, + 0, 0, 0, 0, 174, 0, 0, 0, 36, 174, + 37, 74, 934, 174, 38, 0, 0, 76, 0, 78, + 0, 80, 39, 40, 254, 174, 41, 174, 0, 0, + 0, 174, 0, 86, 0, 0, 87, 88, 0, 174, + 174, 0, 0, 174, 0, 0, 174, 0, 0, 0, + 0, 89, 90, 91, 92, 302, 0, 0, 0, 518, + 0, 0, 0, 95, 0, 0, 0, 0, 0, 97, 98, 99, 100, 0, 0, 0, 101, 0, 102, 0, - 0, 0, 0, 0, 103, 104, 0, 0, 0, 0, + 0, 974, 0, 0, 103, 104, 0, 0, 0, 0, 0, 0, 56, 24, 0, 25, 0, 0, 26, 253, 0, 0, 0, 27, 61, 62, 0, 28, 0, 105, - 106, 107, 108, 64, 0, 0, 30, 0, 0, 0, - 0, 0, 0, 32, 0, 0, 0, 0, 33, 0, - 71, 72, 34, 0, 586, 0, 0, 0, 0, 0, - 0, 587, 0, 0, 36, 0, 37, 74, 0, 0, + 303, 107, 108, 64, 0, 0, 30, 0, 0, 0, + 0, 0, 0, 32, 0, 0, 0, 174, 33, 0, + 71, 72, 34, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 36, 0, 37, 74, 0, 0, 38, 0, 0, 76, 0, 78, 0, 80, 39, 40, - 254, 0, 41, 0, 0, 0, 0, 0, 0, 588, + 254, 0, 41, 0, 0, 0, 0, 0, 0, 86, 0, 0, 87, 88, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 89, 90, 91, - 92, 93, 0, 0, 0, 0, 0, 0, 0, 95, + 92, 302, 0, 0, 0, 729, 1001, 0, 0, 95, 0, 0, 0, 0, 0, 97, 98, 99, 100, 0, 0, 0, 101, 0, 102, 0, 0, 0, 0, 0, + 103, 104, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 742, 0, 105, 730, 107, 108, 0, + 0, 56, 24, 0, 25, 0, 731, 26, 253, 0, + 0, 0, 27, 61, 62, 0, 28, 0, 0, 174, + 0, 174, 64, 0, 174, 30, 0, 0, 0, 174, + 0, 0, 32, 174, 0, 0, 0, 33, 0, 71, + 72, 34, 174, 0, 0, 0, 0, 0, 0, 174, + 0, 0, 0, 36, 174, 37, 74, 934, 174, 38, + 0, 0, 76, 0, 78, 0, 80, 39, 40, 254, + 174, 41, 174, 0, 0, 0, 174, 0, 86, 0, + 0, 87, 88, 0, 174, 174, 0, 0, 174, 0, + 0, 174, 0, 0, 0, 0, 89, 90, 91, 92, + 302, 0, 0, 0, 518, 0, 0, 0, 95, 0, + 0, 0, 0, 0, 97, 98, 99, 100, 0, 0, + 0, 101, 0, 102, 974, 0, 0, 0, 0, 103, + 104, 0, 0, 0, 0, 0, 0, 56, 24, 0, + 25, 0, 0, 26, 253, 0, 0, 0, 27, 61, + 62, 0, 28, 0, 105, 303, 107, 108, 64, 0, + 0, 30, 0, 0, 0, 0, 0, 0, 32, 0, + 0, 0, 174, 33, 0, 71, 72, 34, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 36, + 0, 37, 74, 0, 0, 38, 0, 0, 76, 0, + 78, 0, 80, 39, 40, 254, 0, 41, 0, 0, + 0, 0, 0, 0, 86, 0, 0, 87, 88, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 89, 90, 91, 92, 302, 0, 0, 0, + 729, 0, 0, 0, 95, 0, 0, 0, 0, 0, + 97, 98, 99, 100, 0, 0, 0, 101, 0, 102, + 0, 0, 0, 0, 0, 103, 104, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 742, 0, + 105, 730, 107, 108, 0, 0, 56, 24, 0, 25, + 0, 731, 26, 253, 0, 0, 0, 27, 61, 62, + 0, 28, 0, 0, 24, 0, 25, 64, 0, 26, + 30, 0, 0, 0, 27, 0, 0, 32, 28, 0, + 0, 0, 33, 0, 71, 72, 34, 30, 0, 0, + 0, 0, 0, 0, 32, 0, 0, 0, 36, 33, + 37, 74, 0, 34, 38, 0, 0, 76, 0, 78, + 0, 80, 39, 40, 254, 36, 41, 37, 0, 0, + 0, 38, 0, 86, 0, 0, 87, 88, 0, 39, + 40, 0, 0, 41, 0, 0, 322, 0, 0, 0, + 0, 89, 90, 91, 92, 302, 0, 0, 0, 518, + 0, 0, 0, 95, 0, 0, 0, 0, 0, 97, + 98, 99, 100, 0, 0, 0, 101, 0, 102, 0, + 0, 0, 0, 0, 103, 104, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 301, 0, 0, 0, 105, + 303, 107, 108, 56, 24, 0, 25, 0, 0, 26, + 253, 0, 0, 0, 27, 61, 62, 355, 28, 0, + 0, 24, 0, 25, 64, 0, 26, 30, 0, 0, + 0, 27, 0, 0, 32, 28, 0, 0, 0, 33, + 0, 71, 72, 34, 30, 0, 0, 0, 0, 0, + 0, 32, 0, 0, 0, 36, 33, 37, 74, 0, + 34, 38, 0, 0, 76, 0, 78, 0, 80, 39, + 40, 254, 36, 41, 37, 0, 0, 0, 38, 0, + 86, 0, 0, 87, 88, 0, 39, 40, 0, 0, + 41, 0, 0, 520, 0, 0, 0, 0, 89, 90, + 91, 92, 302, 0, 0, 0, 0, 0, 0, 0, + 95, 0, 0, 0, 0, 0, 97, 98, 99, 100, + 0, 0, 0, 101, 0, 102, 0, 0, 0, 0, + 0, 103, 104, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 310, 0, 0, 0, 105, 303, 107, 108, + 56, 24, 0, 25, 0, 0, 26, 253, 0, 0, + 0, 27, 61, 62, 355, 28, 0, 0, 24, 0, + 25, 64, 0, 26, 30, 0, 0, 0, 27, 0, + 0, 32, 28, 0, 0, 0, 33, 0, 71, 72, + 34, 30, 0, 0, 0, 0, 0, 0, 32, 0, + 0, 0, 36, 33, 37, 74, 0, 34, 38, 0, + 0, 76, 0, 78, 0, 80, 39, 40, 254, 36, + 41, 37, 0, 0, 0, 38, 0, 86, 0, 0, + 87, 88, 0, 39, 40, 0, 0, 41, 0, 0, + 573, 0, 0, 0, 0, 89, 90, 91, 92, 302, + 0, 0, 0, 0, 0, 0, 0, 95, 0, 0, + 0, 0, 0, 97, 98, 99, 100, 0, 0, 0, + 101, 0, 102, 0, 0, 0, 0, 0, 103, 104, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 591, + 0, 0, 0, 105, 303, 107, 108, 56, 24, 0, + 25, 0, 0, 26, 253, 0, 0, 0, 27, 61, + 62, 355, 28, 0, 0, 24, 0, 25, 64, 0, + 26, 30, 0, 0, 0, 27, 0, 0, 32, 28, + 0, 0, 0, 33, 0, 71, 72, 34, 30, 0, + 0, 0, 0, 0, 0, 32, 0, 0, 0, 36, + 33, 37, 74, 0, 34, 38, 0, 0, 76, 0, + 78, 0, 80, 39, 40, 254, 36, 41, 37, 0, + 0, 0, 38, 0, 86, 0, 0, 87, 88, 0, + 39, 40, 0, 0, 41, 0, 0, 757, 0, 0, + 0, 0, 89, 90, 91, 92, 93, 0, 0, 0, + 0, 0, 0, 0, 95, 0, 0, 0, 0, 0, + 97, 98, 99, 100, 0, 0, 0, 101, 0, 102, + 0, 0, 0, 0, 0, 103, 104, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 820, 0, 0, 0, + 105, 106, 107, 108, 56, 24, 0, 25, 0, 0, + 26, 253, 0, 0, 0, 27, 61, 62, 355, 28, + 0, 0, 488, 0, 488, 64, 0, 488, 30, 0, + 0, 0, 488, 0, 0, 32, 488, 0, 0, 0, + 33, 0, 71, 72, 34, 488, 0, 0, 0, 0, + 0, 0, 488, 0, 0, 0, 36, 488, 37, 74, + 0, 488, 38, 0, 0, 76, 0, 78, 0, 80, + 39, 40, 254, 488, 41, 488, 0, 0, 0, 488, + 0, 86, 0, 0, 87, 88, 0, 488, 488, 0, + 0, 488, 0, 0, 488, 0, 0, 0, 0, 89, + 90, 91, 92, 302, 0, 0, 0, 0, 0, 0, + 0, 95, 0, 0, 0, 0, 0, 97, 98, 99, + 100, 0, 0, 0, 101, 0, 102, 0, 0, 0, + 0, 0, 103, 104, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1184, 0, 0, 0, 105, 303, 107, + 108, 56, 24, 0, 25, 0, 0, 26, 253, 0, + 0, 0, 27, 61, 62, 488, 28, 0, 0, 175, + 0, 175, 64, 0, 175, 30, 0, 0, 0, 175, + 0, 0, 32, 175, 0, 0, 0, 33, 0, 71, + 72, 34, 175, 0, 0, 0, 0, 0, 0, 175, + 0, 0, 0, 36, 175, 37, 74, 0, 175, 38, + 0, 0, 76, 0, 78, 0, 80, 39, 40, 254, + 175, 41, 175, 0, 0, 0, 175, 0, 86, 0, + 0, 87, 88, 0, 175, 175, 0, 0, 175, 0, + 0, 175, 0, 0, 0, 0, 89, 90, 91, 92, + 302, 0, 0, 0, 0, 0, 0, 0, 95, 0, + 0, 0, 0, 0, 97, 98, 99, 100, 0, 0, + 0, 101, 0, 102, 0, 0, 0, 0, 0, 103, + 104, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 608, 0, 0, 0, 105, 303, 107, 108, 608, 608, + 0, 608, 0, 0, 608, 608, 0, 0, 0, 608, + 608, 608, 175, 608, 0, 0, 0, 0, 0, 608, + 0, 0, 608, 0, 0, 0, 0, 0, 0, 608, + 0, 0, 0, 0, 608, 0, 608, 608, 608, 0, + 0, 0, 0, 0, 0, 0, 335, 0, 0, 0, + 608, 0, 608, 608, 0, 0, 608, 0, 0, 608, + 0, 608, 0, 608, 608, 608, 608, 0, 608, 0, + 0, 0, 0, 0, 0, 608, 0, 0, 608, 608, + 0, 0, 335, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 608, 608, 608, 608, 608, 0, 0, + 0, 0, 0, 0, 0, 608, 0, 0, 0, 0, + 0, 608, 608, 608, 608, 0, 0, 0, 608, 0, + 608, 0, 0, 0, 0, 0, 608, 608, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 608, 608, 608, 608, 335, 335, 335, 335, 743, + 0, 0, 335, 335, 0, 0, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 0, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 0, 48, + 0, 48, 0, 48, 335, 48, 0, 335, 48, 0, + 48, 48, 0, 48, 0, 48, 0, 48, 0, 48, + 48, 48, 48, 0, 0, 48, 48, 0, 0, 0, + 0, 48, 48, 48, 48, 48, 0, 0, 48, 0, + 48, 0, 48, 0, 48, 48, 0, 48, 48, 48, + 48, 0, 0, 48, 48, 48, 48, 0, 0, 48, + 48, 48, 0, 0, 0, 0, 0, 0, 48, 48, + 0, 48, 48, 0, 48, 48, 48, 0, 0, 0, + 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 48, 0, 48, 48, 47, 0, 0, 0, 47, 0, + 47, 0, 0, 47, 0, 47, 47, 0, 47, 0, + 47, 0, 47, 0, 47, 47, 47, 47, 0, 0, + 47, 47, 0, 0, 0, 0, 47, 0, 47, 47, + 47, 0, 0, 47, 0, 47, 0, 47, 0, 0, + 47, 0, 47, 47, 47, 47, 48, 0, 0, 47, + 47, 47, 0, 0, 47, 47, 47, 0, 0, 0, + 0, 0, 0, 47, 47, 0, 47, 47, 0, 47, + 47, 47, 0, 0, 0, 47, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 47, 0, 47, 0, 47, 0, 47, + 0, 80, 47, 0, 47, 47, 0, 47, 0, 47, + 47, 47, 0, 47, 47, 47, 47, 0, 0, 47, + 47, 0, 0, 0, 0, 47, 0, 47, 47, 47, + 0, 0, 47, 0, 47, 0, 47, 0, 0, 47, + 0, 47, 47, 47, 47, 0, 0, 0, 47, 47, + 47, 47, 0, 47, 47, 47, 0, 0, 0, 0, + 0, 0, 47, 47, 0, 47, 47, 0, 47, 47, + 47, 0, 0, 0, 47, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 47, 0, 47, 0, 47, 0, 47, 0, + 81, 47, 0, 47, 47, 0, 47, 0, 47, 47, + 47, 0, 47, 47, 47, 47, 0, 0, 47, 47, + 0, 0, 0, 0, 47, 0, 47, 47, 47, 0, + 0, 47, 0, 47, 0, 47, 0, 0, 47, 0, + 47, 47, 47, 47, 0, 0, 0, 47, 47, 47, + 47, 0, 47, 47, 47, 0, 0, 0, 0, 0, + 0, 47, 47, 0, 47, 47, 0, 47, 47, 47, + 0, 0, 0, 47, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 48, 0, 0, 0, + 48, 0, 48, 47, 0, 48, 0, 48, 48, 214, + 48, 0, 48, 0, 48, 0, 48, 48, 48, 48, + 0, 0, 48, 48, 0, 0, 0, 0, 48, 0, + 48, 48, 48, 0, 0, 48, 0, 48, 0, 48, + 0, 0, 48, 0, 48, 48, 48, 48, 0, 0, + 0, 48, 48, 48, 0, 0, 48, 48, 48, 47, + 0, 0, 0, 0, 0, 48, 48, 0, 48, 48, + 0, 48, 48, 48, 0, 0, 0, 48, 0, 0, + 0, 0, 47, 0, 0, 0, 47, 0, 47, 0, + 0, 47, 0, 47, 47, 0, 47, 48, 47, 0, + 47, 0, 47, 47, 47, 47, 0, 0, 47, 47, + 0, 0, 48, 0, 47, 0, 47, 47, 47, 0, + 0, 47, 0, 47, 335, 47, 0, 0, 47, 0, + 47, 47, 47, 47, 0, 0, 0, 47, 47, 47, + 0, 0, 47, 47, 47, 0, 0, 335, 0, 0, + 0, 47, 47, 48, 47, 47, 0, 47, 47, 47, + 335, 0, 0, 47, 0, 335, 0, 0, 335, 0, + 335, 0, 335, 335, 335, 335, 0, 0, 0, 0, + 335, 0, 0, 47, 335, 0, 0, 0, 335, 215, + 0, 0, 0, 0, 0, 0, 335, 0, 0, 335, + 0, 335, 56, 24, 0, 25, 0, 0, 26, 253, + 0, 0, 0, 27, 61, 62, 0, 28, 0, 0, + 335, 0, 0, 64, 0, 335, 30, 0, 0, 0, + 0, 0, 335, 32, 265, 0, 335, 0, 33, 47, + 71, 72, 34, 0, 593, 0, 0, 0, 0, 335, + 0, 594, 0, 0, 36, 0, 37, 74, 0, 0, + 38, 0, 0, 76, 0, 78, 0, 80, 39, 40, + 254, 0, 41, 0, 0, 0, 0, 0, 0, 595, + 0, 335, 87, 88, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 89, 90, 91, + 92, 93, 0, 0, 0, 0, 0, 0, 0, 95, + 927, 0, 596, 0, 0, 97, 98, 99, 100, 0, + 0, 0, 101, 0, 102, 0, 0, 0, 0, 0, 103, 104, 0, 0, 0, 0, 0, 0, 56, 24, 0, 25, 0, 0, 26, 253, 0, 0, 0, 27, 61, 62, 0, 28, 0, 105, 106, 107, 108, 64, 0, 0, 30, 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, 0, 33, 0, 71, 72, 34, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 593, 0, 0, 0, 0, 0, 0, 594, 0, 0, 36, 0, 37, 74, 0, 0, 38, 0, 0, 76, 0, 78, 0, 80, 39, 40, 254, 0, 41, 0, - 0, 84, 0, 0, 0, 86, 0, 0, 87, 88, + 0, 0, 0, 0, 0, 595, 0, 0, 87, 88, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 89, 90, 91, 92, 300, 0, 0, - 0, 0, 0, 0, 0, 95, 0, 0, 0, 0, + 0, 0, 0, 89, 90, 91, 92, 93, 0, 0, + 0, 0, 0, 0, 0, 95, 0, 0, 596, 0, 0, 97, 98, 99, 100, 0, 0, 0, 101, 0, 102, 0, 0, 0, 0, 0, 103, 104, 0, 0, 0, 0, 0, 0, 56, 24, 0, 25, 0, 0, 26, 253, 0, 0, 0, 27, 61, 62, 0, 28, - 0, 105, 301, 107, 108, 64, 0, 0, 30, 0, + 0, 105, 106, 107, 108, 64, 0, 0, 30, 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, 0, 33, 0, 71, 72, 34, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 36, 0, 37, 74, 0, 0, 38, 0, 0, 76, 0, 78, 0, 80, - 39, 40, 254, 0, 41, 0, 0, 0, 0, 0, + 39, 40, 254, 0, 41, 0, 0, 84, 0, 0, 0, 86, 0, 0, 87, 88, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 89, - 90, 91, 92, 300, 0, 0, 0, 0, 870, 0, + 90, 91, 92, 302, 0, 0, 0, 0, 0, 0, 0, 95, 0, 0, 0, 0, 0, 97, 98, 99, 100, 0, 0, 0, 101, 0, 102, 0, 0, 0, 0, 0, 103, 104, 0, 0, 0, 0, 0, 0, 56, 24, 0, 25, 0, 0, 26, 253, 0, 0, - 0, 27, 61, 62, 0, 28, 0, 105, 301, 107, + 0, 27, 61, 62, 0, 28, 0, 105, 303, 107, 108, 64, 0, 0, 30, 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, 0, 33, 0, 71, 72, 34, 0, 0, 0, 0, 0, 0, 0, 0, 0, @@ -10802,13 +11107,13 @@ void case_961() 0, 76, 0, 78, 0, 80, 39, 40, 254, 0, 41, 0, 0, 0, 0, 0, 0, 86, 0, 0, 87, 88, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 89, 90, 91, 92, 300, - 0, 0, 0, 511, 0, 0, 0, 95, 0, 0, + 0, 0, 0, 0, 0, 89, 90, 91, 92, 302, + 0, 0, 0, 0, 886, 0, 0, 95, 0, 0, 0, 0, 0, 97, 98, 99, 100, 0, 0, 0, 101, 0, 102, 0, 0, 0, 0, 0, 103, 104, 0, 0, 0, 0, 0, 0, 56, 24, 0, 25, 0, 0, 26, 253, 0, 0, 0, 27, 61, 62, - 0, 28, 0, 105, 301, 107, 108, 64, 0, 0, + 0, 28, 0, 105, 303, 107, 108, 64, 0, 0, 30, 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, 0, 33, 0, 71, 72, 34, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 36, 0, @@ -10816,13 +11121,13 @@ void case_961() 0, 80, 39, 40, 254, 0, 41, 0, 0, 0, 0, 0, 0, 86, 0, 0, 87, 88, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 89, 90, 91, 92, 300, 0, 0, 0, 505, + 0, 89, 90, 91, 92, 302, 0, 0, 0, 518, 0, 0, 0, 95, 0, 0, 0, 0, 0, 97, 98, 99, 100, 0, 0, 0, 101, 0, 102, 0, 0, 0, 0, 0, 103, 104, 0, 0, 0, 0, 0, 0, 56, 24, 0, 25, 0, 0, 26, 253, 0, 0, 0, 27, 61, 62, 0, 28, 0, 105, - 301, 107, 108, 64, 0, 0, 30, 0, 0, 0, + 303, 107, 108, 64, 0, 0, 30, 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, 0, 33, 0, 71, 72, 34, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 36, 0, 37, 74, 0, 0, @@ -10830,12 +11135,12 @@ void case_961() 254, 0, 41, 0, 0, 0, 0, 0, 0, 86, 0, 0, 87, 88, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 89, 90, 91, - 92, 300, 0, 0, 0, 0, 0, 0, 0, 95, + 92, 302, 0, 0, 0, 512, 0, 0, 0, 95, 0, 0, 0, 0, 0, 97, 98, 99, 100, 0, 0, 0, 101, 0, 102, 0, 0, 0, 0, 0, 103, 104, 0, 0, 0, 0, 0, 0, 56, 24, 0, 25, 0, 0, 26, 253, 0, 0, 0, 27, - 61, 62, 0, 28, 0, 105, 301, 107, 108, 64, + 61, 62, 0, 28, 0, 105, 303, 107, 108, 64, 0, 0, 30, 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, 0, 33, 0, 71, 72, 34, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, @@ -10843,13 +11148,13 @@ void case_961() 0, 78, 0, 80, 39, 40, 254, 0, 41, 0, 0, 0, 0, 0, 0, 86, 0, 0, 87, 88, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 89, 90, 91, 92, 93, 0, 0, + 0, 0, 0, 89, 90, 91, 92, 302, 0, 0, 0, 0, 0, 0, 0, 95, 0, 0, 0, 0, 0, 97, 98, 99, 100, 0, 0, 0, 101, 0, 102, 0, 0, 0, 0, 0, 103, 104, 0, 0, 0, 0, 0, 0, 56, 24, 0, 25, 0, 0, 26, 253, 0, 0, 0, 27, 61, 62, 0, 28, - 0, 105, 106, 107, 108, 64, 0, 0, 30, 0, + 0, 105, 303, 107, 108, 64, 0, 0, 30, 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, 0, 33, 0, 71, 72, 34, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 36, 0, 37, 74, @@ -10861,651 +11166,657 @@ void case_961() 0, 95, 0, 0, 0, 0, 0, 97, 98, 99, 100, 0, 0, 0, 101, 0, 102, 0, 0, 0, 0, 0, 103, 104, 0, 0, 0, 0, 0, 0, - 76, 76, 0, 76, 0, 0, 76, 76, 0, 0, - 0, 76, 76, 76, 0, 76, 0, 105, 1025, 107, - 108, 76, 0, 0, 76, 0, 0, 0, 0, 0, - 0, 76, 0, 0, 0, 0, 76, 0, 76, 76, - 76, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 76, 0, 76, 76, 0, 0, 76, 0, - 0, 76, 0, 76, 0, 76, 76, 76, 76, 0, - 76, 0, 0, 0, 0, 0, 0, 76, 0, 0, - 76, 76, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 76, 76, 76, 76, 76, - 0, 0, 0, 0, 0, 0, 0, 76, 0, 0, - 0, 0, 0, 76, 76, 76, 76, 0, 0, 0, - 76, 0, 76, 0, 0, 0, 0, 0, 76, 76, - 0, 0, 0, 0, 0, 0, 133, 133, 0, 133, - 0, 0, 133, 133, 0, 0, 0, 133, 133, 133, - 0, 133, 0, 76, 76, 76, 76, 133, 0, 0, - 133, 0, 0, 0, 0, 0, 0, 133, 0, 0, - 0, 0, 133, 0, 133, 133, 133, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 133, 0, - 133, 133, 0, 0, 133, 0, 0, 133, 0, 133, - 0, 133, 133, 133, 133, 0, 133, 0, 0, 0, - 0, 0, 0, 133, 0, 0, 133, 133, 0, 0, + 56, 24, 0, 25, 0, 0, 26, 253, 0, 0, + 0, 27, 61, 62, 0, 28, 0, 105, 106, 107, + 108, 64, 0, 0, 30, 0, 0, 0, 0, 0, + 0, 32, 0, 0, 0, 0, 33, 0, 71, 72, + 34, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 36, 0, 37, 74, 0, 0, 38, 0, + 0, 76, 0, 78, 0, 80, 39, 40, 254, 0, + 41, 0, 0, 0, 0, 0, 0, 86, 0, 0, + 87, 88, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 89, 90, 91, 92, 93, + 0, 0, 0, 0, 0, 0, 0, 95, 0, 0, + 0, 0, 0, 97, 98, 99, 100, 0, 0, 0, + 101, 0, 102, 0, 0, 0, 0, 0, 103, 104, + 0, 0, 0, 0, 0, 0, 77, 77, 0, 77, + 0, 0, 77, 77, 0, 0, 0, 77, 77, 77, + 0, 77, 0, 105, 1041, 107, 108, 77, 0, 0, + 77, 0, 0, 0, 0, 0, 0, 77, 0, 0, + 0, 0, 77, 0, 77, 77, 77, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 77, 0, + 77, 77, 0, 0, 77, 0, 0, 77, 0, 77, + 0, 77, 77, 77, 77, 0, 77, 0, 0, 0, + 0, 0, 0, 77, 0, 0, 77, 77, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 133, 133, 133, 133, 133, 0, 0, 0, 0, - 0, 0, 0, 133, 0, 0, 0, 0, 0, 133, - 133, 133, 133, 0, 0, 0, 133, 0, 133, 0, - 0, 0, 0, 0, 133, 133, 0, 0, 0, 0, - 0, 0, 56, 24, 0, 25, 0, 0, 26, 253, - 0, 0, 0, 27, 61, 62, 0, 28, 0, 133, - 133, 133, 133, 64, 0, 0, 30, 0, 0, 0, - 0, 0, 0, 32, 0, 27, 0, 0, 33, 0, - 71, 72, 34, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 36, 0, 37, 74, 27, 0, - 38, 0, 0, 76, 0, 78, 0, 80, 39, 40, - 254, 27, 41, 0, 0, 0, 27, 0, 0, 0, - 0, 27, 0, 27, 27, 27, 27, 0, 0, 27, - 0, 27, 0, 0, 0, 27, 0, 89, 90, 91, - 255, 300, 0, 0, 0, 0, 0, 27, 0, 95, - 27, 0, 27, 0, 0, 97, 98, 99, 100, 0, - 0, 0, 101, 0, 102, 0, 0, 0, 0, 0, - 103, 104, 0, 0, 0, 0, 27, 0, 0, 0, - 0, 0, 27, 27, 0, 0, 0, 0, 0, 0, - 636, 0, 636, 0, 636, 105, 256, 636, 108, 636, - 636, 0, 636, 0, 636, 0, 636, 0, 636, 636, - 636, 0, 0, 0, 636, 636, 0, 0, 0, 0, - 636, 0, 636, 636, 0, 0, 0, 636, 0, 0, - 0, 636, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 636, 636, 0, 636, 0, 0, 0, 636, - 636, 0, 0, 0, 0, 0, 0, 636, 636, 56, - 24, 636, 25, 0, 636, 26, 253, 0, 0, 636, - 27, 61, 62, 0, 28, 0, 0, 0, 0, 0, - 64, 0, 0, 30, 0, 0, 0, 0, 0, 0, - 32, 636, 636, 0, 0, 33, 0, 71, 72, 34, - 0, 0, 0, 0, 636, 0, 0, 0, 0, 0, - 0, 36, 0, 37, 74, 0, 0, 38, 0, 0, - 76, 0, 78, 0, 80, 39, 40, 254, 0, 41, - 0, 0, 84, 0, 0, 0, 0, 0, 0, 24, - 0, 25, 0, 0, 26, 636, 1208, 0, 0, 27, - 0, 0, 0, 28, 89, 90, 91, 255, 0, 0, - 0, 0, 30, 635, 0, 635, 95, 0, 635, 32, - 635, 635, 0, 635, 33, 635, 1209, 635, 34, 635, - 635, 635, 0, 0, 0, 635, 635, 0, 0, 0, - 36, 635, 37, 635, 635, 0, 38, 1210, 635, 0, - 0, 0, 635, 0, 39, 40, 0, 0, 41, 0, - 0, 319, 105, 256, 635, 0, 635, 0, 0, 0, - 635, 635, 0, 0, 0, 0, 0, 0, 635, 635, - 0, 635, 635, 635, 0, 635, 635, 0, 635, 635, - 635, 635, 0, 635, 0, 635, 0, 635, 635, 635, - 0, 0, 0, 635, 635, 0, 0, 0, 0, 635, - 0, 635, 635, 0, 0, 0, 635, 0, 0, 0, - 635, 0, 0, 0, 0, 635, 0, 0, 0, 0, - 0, 0, 635, 0, 635, 0, 0, 0, 635, 635, - 0, 0, 352, 0, 0, 0, 635, 635, 0, 0, - 635, 0, 0, 635, 0, 24, 0, 25, 635, 0, - 26, 0, 0, 1268, 0, 27, 635, 675, 0, 28, - 0, 676, 1269, 1270, 0, 0, 0, 1271, 30, 0, - 0, 0, 0, 1272, 0, 32, 0, 24, 0, 25, - 33, 0, 26, 0, 34, 1268, 0, 27, 0, 675, - 0, 28, 0, 676, 1269, 1270, 36, 0, 37, 1271, - 30, 0, 38, 0, 0, 1272, 0, 32, 0, 0, - 39, 40, 33, 0, 41, 0, 34, 1273, 0, 0, - 0, 46, 1274, 46, 635, 0, 46, 0, 36, 0, - 37, 46, 0, 0, 38, 46, 0, 0, 0, 0, - 0, 0, 39, 40, 46, 0, 41, 0, 0, 1273, - 0, 46, 0, 46, 1274, 46, 46, 1275, 46, 0, - 46, 0, 46, 46, 46, 0, 0, 46, 0, 46, - 0, 0, 46, 0, 46, 0, 46, 0, 46, 0, - 0, 46, 0, 46, 0, 0, 46, 46, 46, 0, - 46, 0, 46, 46, 46, 0, 46, 46, 1276, 46, - 0, 46, 46, 0, 46, 0, 46, 46, 0, 0, - 46, 46, 0, 46, 0, 0, 0, 0, 46, 46, - 46, 0, 46, 0, 0, 46, 0, 46, 151, 24, - 1276, 25, 46, 0, 26, 0, 46, 0, 46, 27, - 46, 0, 0, 28, 0, 46, 0, 0, 46, 0, - 46, 0, 30, 0, 46, 0, 0, 46, 151, 32, - 0, 0, 46, 46, 33, 0, 46, 0, 34, 46, - 563, 0, 0, 0, 46, 0, 0, 564, 0, 0, - 36, 0, 37, 0, 0, 0, 38, 0, 0, 565, - 0, 0, 0, 0, 39, 40, 0, 0, 41, 0, - 24, 566, 25, 0, 0, 26, 46, 0, 0, 0, - 27, 0, 0, 0, 28, 0, 0, 0, 29, 24, - 0, 25, 0, 30, 26, 0, 0, 0, 31, 27, - 32, 0, 0, 28, 0, 33, 0, 0, 0, 34, - 35, 0, 30, 0, 0, 0, 0, 0, 0, 32, - 46, 36, 0, 37, 33, 0, 0, 38, 34, 0, - 0, 0, 0, 0, 0, 39, 40, 0, 0, 41, - 36, 0, 37, 484, 0, 484, 38, 0, 484, 0, - 0, 0, 567, 484, 39, 40, 0, 484, 41, 0, - 171, 319, 171, 0, 0, 171, 484, 0, 0, 0, - 171, 0, 0, 484, 171, 0, 0, 0, 484, 0, - 0, 0, 484, 171, 0, 0, 0, 290, 0, 0, - 171, 0, 0, 0, 484, 171, 484, 0, 0, 171, - 484, 0, 0, 0, 0, 0, 0, 0, 484, 484, - 0, 171, 484, 171, 170, 484, 170, 171, 0, 170, - 0, 0, 0, 42, 170, 171, 171, 0, 170, 171, - 0, 0, 171, 0, 0, 0, 0, 170, 180, 0, - 180, 0, 320, 180, 170, 0, 0, 0, 180, 170, - 0, 0, 180, 170, 0, 0, 0, 0, 0, 0, - 0, 180, 0, 0, 0, 170, 0, 170, 180, 0, - 0, 170, 0, 180, 0, 0, 0, 180, 0, 170, - 170, 0, 33, 170, 0, 0, 170, 0, 0, 180, - 0, 180, 0, 33, 0, 180, 484, 0, 33, 0, - 0, 0, 33, 180, 180, 33, 0, 180, 0, 0, - 180, 0, 0, 171, 0, 0, 0, 33, 33, 0, - 0, 0, 33, 33, 0, 31, 0, 0, 33, 0, - 33, 33, 33, 33, 0, 0, 31, 0, 33, 0, - 0, 31, 33, 0, 33, 31, 0, 0, 31, 0, - 0, 0, 0, 0, 33, 0, 33, 33, 0, 33, - 31, 31, 0, 33, 0, 31, 31, 170, 0, 0, - 0, 31, 0, 31, 31, 31, 31, 0, 0, 0, - 0, 31, 0, 33, 0, 31, 0, 31, 0, 33, - 33, 180, 0, 27, 0, 27, 0, 31, 0, 0, - 31, 0, 31, 0, 0, 0, 31, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 27, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 31, 0, 0, 27, - 0, 0, 31, 31, 27, 0, 46, 0, 0, 27, - 0, 27, 27, 27, 27, 0, 0, 46, 0, 27, - 0, 0, 46, 27, 0, 0, 46, 0, 0, 46, - 0, 0, 0, 0, 0, 27, 0, 0, 27, 0, - 27, 46, 46, 0, 0, 0, 46, 46, 0, 46, - 0, 0, 46, 0, 46, 46, 46, 46, 0, 0, - 46, 0, 46, 0, 27, 46, 46, 0, 46, 46, - 27, 27, 46, 0, 0, 0, 0, 0, 46, 0, - 0, 46, 0, 46, 46, 46, 0, 46, 0, 46, - 46, 46, 0, 0, 0, 46, 0, 46, 46, 46, - 46, 0, 0, 0, 0, 46, 0, 46, 0, 46, - 0, 46, 0, 35, 46, 0, 0, 0, 0, 0, - 0, 46, 0, 0, 46, 0, 46, 46, 0, 46, - 46, 0, 46, 0, 0, 0, 0, 46, 0, 46, - 46, 46, 46, 0, 0, 0, 0, 46, 0, 0, - 46, 46, 46, 0, 0, 0, 36, 0, 0, 0, - 0, 0, 0, 46, 0, 46, 46, 46, 46, 0, - 46, 0, 0, 0, 0, 46, 0, 46, 46, 46, - 46, 0, 0, 0, 0, 46, 0, 0, 0, 46, - 46, 0, 46, 0, 46, 46, 0, 0, 192, 0, - 0, 46, 0, 46, 46, 46, 46, 46, 46, 0, - 0, 0, 0, 46, 0, 46, 46, 46, 46, 0, - 0, 46, 0, 46, 0, 0, 0, 46, 46, 0, - 46, 0, 46, 46, 0, 0, 194, 0, 0, 46, - 0, 46, 46, 46, 46, 0, 46, 0, 0, 0, - 0, 46, 0, 46, 46, 46, 46, 0, 0, 0, - 0, 46, 0, 0, 0, 46, 46, 0, 46, 0, - 0, 0, 0, 46, 295, 46, 0, 46, 0, 46, - 46, 0, 46, 0, 46, 0, 0, 0, 0, 46, - 0, 46, 46, 46, 46, 0, 46, 0, 0, 46, - 0, 0, 0, 46, 0, 0, 46, 0, 0, 46, - 0, 0, 296, 448, 46, 46, 0, 0, 46, 46, - 46, 46, 46, 46, 46, 0, 0, 46, 0, 46, - 0, 0, 0, 46, 0, 0, 449, 0, 0, 0, - 0, 0, 0, 448, 46, 46, 46, 46, 46, 450, - 46, 0, 0, 451, 452, 0, 0, 0, 0, 453, - 0, 454, 455, 456, 457, 0, 449, 0, 0, 458, - 0, 0, 0, 459, 46, 0, 0, 0, 0, 450, - 0, 0, 0, 0, 452, 460, 0, 0, 461, 453, - 462, 454, 455, 456, 457, 0, 0, 0, 0, 458, - 0, 0, 0, 459, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 463, 460, 0, 0, 461, 0, - 462, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 77, 77, 77, 77, 77, 0, 0, 0, 0, + 0, 0, 0, 77, 0, 0, 0, 0, 0, 77, + 77, 77, 77, 0, 0, 0, 77, 0, 77, 0, + 0, 0, 0, 0, 77, 77, 0, 0, 0, 0, + 0, 0, 135, 135, 0, 135, 0, 0, 135, 135, + 0, 0, 0, 135, 135, 135, 0, 135, 0, 77, + 77, 77, 77, 135, 0, 0, 135, 0, 0, 0, + 0, 0, 0, 135, 0, 0, 0, 0, 135, 0, + 135, 135, 135, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 135, 0, 135, 135, 0, 0, + 135, 0, 0, 135, 0, 135, 0, 135, 135, 135, + 135, 0, 135, 0, 0, 0, 0, 0, 0, 135, + 0, 0, 135, 135, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 135, 135, 135, + 135, 135, 0, 0, 0, 0, 0, 0, 0, 135, + 0, 0, 0, 0, 0, 135, 135, 135, 135, 0, + 0, 0, 135, 0, 135, 0, 0, 0, 0, 0, + 135, 135, 0, 0, 0, 0, 0, 0, 56, 24, + 0, 25, 0, 0, 26, 253, 0, 0, 0, 27, + 61, 62, 0, 28, 0, 135, 135, 135, 135, 64, + 0, 0, 30, 0, 0, 0, 0, 0, 0, 32, + 0, 27, 0, 0, 33, 0, 71, 72, 34, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 36, 0, 37, 74, 27, 0, 38, 0, 0, 76, + 0, 78, 0, 80, 39, 40, 254, 27, 41, 0, + 0, 0, 27, 0, 0, 0, 0, 27, 0, 27, + 27, 27, 27, 0, 0, 27, 0, 27, 0, 0, + 0, 27, 0, 89, 90, 91, 255, 302, 0, 0, + 0, 0, 0, 27, 0, 95, 27, 0, 27, 0, + 0, 97, 98, 99, 100, 0, 0, 0, 101, 0, + 102, 0, 0, 0, 0, 0, 103, 104, 0, 0, + 0, 0, 27, 0, 0, 0, 0, 0, 27, 27, + 0, 0, 0, 0, 0, 0, 641, 0, 641, 0, + 641, 105, 256, 641, 108, 641, 641, 0, 641, 0, + 641, 0, 641, 0, 641, 641, 641, 0, 0, 0, + 641, 641, 0, 0, 0, 0, 641, 0, 641, 641, + 0, 0, 0, 641, 0, 0, 0, 641, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 641, 641, + 0, 641, 0, 0, 0, 641, 641, 0, 0, 0, + 0, 0, 0, 641, 641, 56, 24, 641, 25, 0, + 641, 26, 253, 0, 0, 641, 27, 61, 62, 0, + 28, 0, 0, 0, 0, 0, 64, 0, 0, 30, + 0, 0, 0, 0, 0, 0, 32, 641, 641, 0, + 0, 33, 0, 71, 72, 34, 0, 0, 0, 0, + 641, 0, 0, 0, 0, 0, 0, 36, 0, 37, + 74, 0, 0, 38, 0, 0, 76, 0, 78, 0, + 80, 39, 40, 254, 0, 41, 0, 0, 84, 0, + 0, 0, 0, 0, 0, 24, 0, 25, 0, 0, + 26, 641, 1228, 0, 0, 27, 0, 0, 0, 28, + 89, 90, 91, 255, 0, 0, 0, 0, 30, 640, + 0, 640, 95, 0, 640, 32, 640, 640, 0, 640, + 33, 640, 1229, 640, 34, 640, 640, 640, 0, 0, + 0, 640, 640, 0, 0, 0, 36, 640, 37, 640, + 640, 0, 38, 1230, 640, 0, 0, 0, 640, 0, + 39, 40, 0, 0, 41, 0, 0, 322, 105, 256, + 640, 0, 640, 0, 0, 0, 640, 640, 0, 0, + 0, 0, 0, 0, 640, 640, 0, 640, 640, 640, + 0, 640, 640, 0, 640, 640, 640, 640, 0, 640, + 0, 640, 0, 640, 640, 640, 0, 0, 0, 640, + 640, 0, 0, 0, 0, 640, 0, 640, 640, 0, + 0, 0, 640, 0, 0, 0, 640, 0, 0, 0, + 0, 640, 0, 0, 0, 0, 0, 0, 640, 0, + 640, 0, 0, 0, 640, 640, 0, 0, 355, 0, + 0, 0, 640, 640, 0, 0, 640, 0, 0, 640, + 0, 24, 0, 25, 640, 0, 26, 0, 0, 1290, + 0, 27, 640, 686, 0, 28, 0, 687, 1291, 1292, + 0, 0, 0, 1293, 30, 0, 0, 0, 0, 1294, + 0, 32, 0, 24, 0, 25, 33, 0, 26, 0, + 34, 1290, 0, 27, 0, 686, 0, 28, 0, 687, + 1291, 1292, 36, 0, 37, 1293, 30, 0, 38, 0, + 0, 1294, 0, 32, 0, 0, 39, 40, 33, 0, + 41, 0, 34, 1295, 0, 0, 0, 47, 1296, 47, + 640, 0, 47, 0, 36, 0, 37, 47, 0, 0, + 38, 47, 0, 0, 0, 0, 0, 0, 39, 40, + 47, 0, 41, 0, 0, 1295, 0, 47, 0, 47, + 1296, 47, 47, 1297, 47, 0, 47, 0, 47, 47, + 47, 0, 0, 47, 0, 47, 0, 0, 47, 0, + 47, 0, 47, 0, 47, 0, 0, 47, 0, 47, + 0, 0, 47, 47, 47, 0, 47, 0, 47, 47, + 47, 0, 47, 48, 1298, 48, 0, 47, 48, 0, + 47, 0, 47, 48, 0, 0, 47, 48, 0, 47, + 0, 0, 0, 0, 47, 47, 48, 0, 47, 0, + 0, 47, 0, 48, 154, 47, 1298, 47, 48, 0, + 47, 0, 48, 0, 48, 47, 48, 0, 0, 47, + 0, 48, 0, 0, 48, 0, 48, 0, 47, 0, + 48, 0, 0, 48, 154, 47, 0, 0, 48, 48, + 47, 0, 48, 0, 47, 48, 47, 0, 47, 24, + 47, 25, 0, 47, 26, 0, 47, 0, 47, 27, + 0, 0, 47, 28, 0, 47, 0, 0, 0, 0, + 47, 47, 30, 0, 47, 0, 0, 47, 0, 32, + 0, 0, 47, 0, 33, 0, 0, 0, 34, 0, + 570, 0, 0, 0, 24, 0, 25, 571, 0, 26, + 36, 0, 37, 0, 27, 0, 38, 0, 28, 572, + 0, 0, 29, 0, 39, 40, 0, 30, 41, 0, + 0, 573, 31, 0, 32, 0, 48, 0, 0, 33, + 0, 0, 0, 34, 35, 0, 0, 0, 24, 0, + 25, 0, 0, 26, 0, 36, 0, 37, 27, 0, + 0, 38, 28, 0, 0, 0, 0, 0, 47, 39, + 40, 30, 174, 41, 174, 0, 0, 174, 32, 0, + 0, 0, 174, 33, 0, 0, 174, 34, 0, 0, + 0, 0, 0, 0, 0, 174, 0, 0, 0, 36, + 0, 37, 174, 0, 0, 38, 0, 174, 0, 0, + 0, 174, 574, 39, 40, 0, 0, 41, 0, 0, + 322, 0, 0, 174, 0, 174, 184, 0, 184, 174, + 0, 184, 0, 0, 0, 0, 184, 174, 174, 0, + 184, 174, 0, 0, 174, 0, 291, 0, 0, 184, + 0, 0, 0, 0, 0, 0, 184, 42, 0, 0, + 0, 184, 0, 0, 33, 184, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 33, 0, 184, 0, 184, + 33, 0, 0, 184, 33, 0, 0, 33, 0, 0, + 0, 184, 184, 0, 0, 184, 0, 0, 184, 33, + 33, 323, 0, 0, 33, 33, 0, 0, 0, 0, + 33, 0, 33, 33, 33, 33, 0, 0, 0, 0, + 33, 0, 0, 0, 33, 174, 33, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 33, 0, 33, 33, + 31, 33, 0, 0, 0, 33, 0, 0, 0, 0, + 0, 31, 0, 0, 0, 0, 31, 0, 0, 0, + 31, 0, 0, 31, 0, 33, 0, 0, 0, 0, + 0, 33, 33, 0, 0, 31, 31, 0, 0, 184, + 31, 31, 27, 0, 27, 0, 31, 0, 31, 31, + 31, 31, 0, 0, 0, 0, 31, 0, 0, 0, + 31, 0, 31, 0, 0, 27, 0, 0, 0, 0, + 0, 0, 31, 0, 0, 31, 0, 31, 27, 0, + 0, 31, 0, 27, 0, 0, 0, 0, 27, 0, + 27, 27, 27, 27, 0, 0, 0, 0, 27, 0, + 0, 31, 27, 0, 0, 47, 0, 31, 31, 0, + 0, 0, 0, 0, 27, 0, 47, 27, 0, 27, + 0, 47, 0, 0, 0, 47, 0, 0, 47, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 463, + 47, 47, 0, 27, 0, 47, 47, 0, 47, 27, + 27, 47, 0, 47, 47, 47, 47, 0, 0, 47, + 0, 47, 0, 0, 47, 47, 0, 47, 47, 0, + 0, 47, 0, 0, 0, 0, 0, 47, 0, 0, + 47, 0, 47, 47, 47, 0, 47, 0, 47, 47, + 47, 0, 0, 0, 47, 0, 47, 47, 47, 47, + 0, 0, 0, 0, 47, 0, 47, 0, 47, 0, + 47, 0, 35, 47, 0, 0, 0, 0, 0, 0, + 47, 0, 0, 47, 0, 47, 47, 0, 47, 47, + 0, 47, 0, 0, 0, 0, 47, 0, 47, 47, + 47, 47, 0, 0, 0, 0, 47, 0, 0, 47, + 47, 47, 0, 0, 0, 36, 0, 0, 0, 0, + 0, 0, 47, 0, 47, 47, 47, 47, 0, 47, + 0, 0, 0, 0, 47, 0, 47, 47, 47, 47, + 0, 0, 0, 0, 47, 0, 0, 0, 47, 47, + 0, 47, 0, 47, 47, 0, 0, 196, 0, 0, + 47, 0, 47, 47, 47, 47, 47, 47, 0, 0, + 0, 0, 47, 0, 47, 47, 47, 47, 0, 0, + 47, 0, 47, 0, 0, 0, 47, 47, 0, 47, + 0, 47, 47, 0, 0, 198, 0, 0, 47, 0, + 47, 47, 47, 47, 47, 47, 0, 0, 0, 0, + 47, 0, 47, 47, 47, 47, 0, 0, 0, 0, + 47, 0, 0, 0, 47, 47, 0, 47, 0, 0, + 0, 0, 453, 299, 0, 0, 47, 0, 47, 47, + 0, 47, 0, 47, 0, 0, 0, 0, 47, 0, + 47, 47, 47, 47, 0, 454, 47, 0, 47, 0, + 0, 0, 47, 0, 453, 47, 0, 0, 455, 0, + 0, 300, 456, 457, 47, 0, 0, 47, 458, 47, + 459, 460, 461, 462, 0, 0, 0, 454, 463, 0, + 0, 0, 464, 0, 0, 0, 0, 0, 0, 0, + 455, 0, 0, 47, 465, 457, 0, 466, 0, 467, + 458, 0, 459, 460, 461, 462, 0, 0, 0, 0, + 463, 0, 0, 0, 464, 0, 0, 0, 0, 0, + 0, 0, 0, 468, 0, 0, 465, 0, 0, 466, + 0, 467, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 468, }; protected static readonly short [] yyCheck = { 17, - 298, 17, 51, 17, 4, 68, 509, 20, 18, 299, - 511, 17, 189, 20, 232, 465, 188, 288, 351, 84, - 552, 336, 157, 247, 87, 88, 919, 485, 59, 92, - 318, 736, 329, 297, 295, 6, 1094, 351, 569, 47, - 769, 0, 234, 256, 58, 577, 268, 59, 113, 77, - 115, 710, 277, 712, 113, 73, 115, 256, 256, 77, - 256, 325, 256, 1129, 1130, 79, 256, 81, 256, 268, - 256, 268, 256, 256, 87, 88, 1215, 95, 372, 276, - 17, 924, 256, 256, 17, 256, 256, 256, 256, 294, - 17, 256, 1231, 256, 256, 108, 256, 756, 256, 277, - 759, 306, 256, 281, 268, 256, 17, 256, 263, 172, - 1176, 374, 256, 391, 381, 256, 368, 269, 367, 17, - 369, 363, 374, 654, 391, 363, 17, 369, 17, 381, - 0, 369, 17, 282, 286, 429, 414, 17, 363, 157, - 189, 157, 366, 157, 408, 339, 368, 414, 17, 339, - 344, 157, 346, 416, 344, 343, 346, 17, 352, 353, - 315, 17, 352, 353, 342, 314, 363, 256, 256, 367, - 59, 369, 1175, 371, 63, 358, 418, 363, 256, 256, - 418, 341, 340, 232, 247, 381, 199, 200, 339, 256, - 374, 1194, 525, 418, 419, 363, 259, 87, 88, 369, - 422, 375, 370, 391, 372, 418, 374, 1050, 505, 369, - 508, 429, 713, 418, 547, 223, 191, 256, 108, 381, - 157, 418, 420, 422, 157, 423, 414, 381, 372, 247, - 157, 372, 418, 547, 252, 429, 569, 552, 430, 429, - 428, 424, 425, 426, 427, 418, 157, 418, 261, 418, - 418, 1390, 317, 418, 285, 418, 321, 228, 422, 157, - 323, 326, 577, 256, 295, 328, 157, 326, 157, 418, - 288, 0, 157, 285, 287, 293, 294, 157, 1417, 1282, - 1009, 370, 262, 1286, 372, 374, 299, 372, 157, 307, - 1429, 369, 1431, 306, 312, 372, 314, 157, 257, 313, - 318, 157, 314, 366, 367, 372, 256, 256, 1311, 199, - 200, 256, 330, 331, 335, 256, 263, 368, 298, 1024, - 336, 654, 853, 982, 256, 256, 1384, 355, 266, 372, - 336, 266, 264, 372, 256, 348, 872, 355, 351, 371, - 257, 655, 675, 1072, 429, 320, 335, 883, 366, 367, - 413, 414, 415, 371, 372, 373, 374, 375, 376, 377, - 378, 379, 380, 381, 343, 394, 395, 418, 315, 256, - 894, 261, 385, 386, 325, 368, 314, 352, 1271, 314, - 429, 374, 357, 884, 1450, 403, 429, 257, 420, 325, - 439, 349, 350, 325, 349, 350, 285, 287, 378, 379, - 413, 414, 272, 368, 6, 863, 372, 277, 429, 697, - 373, 281, 391, 376, 1480, 17, 306, 339, 431, 369, - 369, 484, 367, 486, 431, 314, 296, 368, 436, 437, - 343, 376, 445, 374, 442, 414, 257, 375, 445, 370, - 375, 349, 350, 374, 1103, 367, 509, 336, 368, 428, - 783, 1110, 339, 323, 715, 1199, 363, 59, 348, 683, - 435, 63, 525, 429, 429, 479, 529, 418, 381, 783, - 256, 429, 342, 485, 429, 976, 1135, 1001, 391, 1003, - 367, 256, 418, 256, 363, 87, 88, 368, 376, 507, - 1199, 509, 306, 511, 469, 385, 386, 1289, 1242, 313, - 372, 414, 374, 358, 368, 568, 108, 521, 522, 429, - 1302, 418, 525, 256, 368, 428, 418, 535, 525, 294, - 853, 429, 540, 413, 414, 368, 372, 256, 374, 1321, - 363, 368, 305, 1242, 547, 357, 552, 305, 852, 418, - 1089, 429, 1201, 1419, 1420, 559, 552, 369, 429, 376, - 372, 373, 850, 339, 272, 157, 569, 429, 344, 277, - 346, 577, 305, 281, 386, 429, 352, 353, 586, 587, - 363, 577, 635, 372, 637, 429, 376, 339, 296, 803, - 877, 418, 344, 429, 346, 418, 429, 349, 350, 724, - 352, 353, 567, 1199, 376, 256, 485, 199, 200, 421, - 1476, 343, 429, 339, 579, 323, 581, 1139, 583, 272, - 339, 305, 374, 374, 369, 633, 401, 881, 373, 418, - 683, 639, 367, 1199, 342, 418, 371, 376, 413, 919, - 1199, 367, 369, 296, 1199, 357, 1242, 700, 367, 381, - 376, 654, 371, 339, 373, 374, 375, 376, 344, 391, - 346, 1199, 381, 349, 350, 416, 352, 353, 1199, 261, - 323, 21, 675, 552, 386, 683, 1242, 429, 423, 369, - 381, 646, 414, 1242, 272, 420, 371, 1242, 1136, 697, - 391, 381, 747, 285, 715, 287, 428, 750, 577, 367, - 665, 979, 52, 991, 1242, 713, 256, 299, 296, 272, - 718, 1242, 357, 414, 306, 676, 367, 391, 369, 269, - 371, 372, 314, 374, 341, 376, 386, 428, 373, 782, - 944, 371, 414, 296, 977, 323, 286, 414, 741, 743, - 414, 386, 357, 429, 336, 798, 428, 418, 357, 418, - 803, 428, 369, 761, 428, 763, 348, 428, 373, 351, - 323, 764, 1005, 767, 373, 769, 819, 418, 339, 420, - 778, 386, 423, 344, 294, 346, 779, 386, 349, 350, - 783, 352, 353, 370, 1323, 306, 306, 308, 827, 371, - 798, 373, 313, 385, 386, 803, 804, 418, 806, 1060, - 387, 388, 1107, 374, 325, 367, 1094, 428, 367, 817, - 818, 306, 1351, 1352, 376, 1354, 367, 376, 313, 1198, - 1199, 413, 414, 294, 370, 376, 1365, 379, 374, 1368, - 325, 710, 835, 712, 1139, 888, 1097, 890, 835, 1218, - 848, 339, 850, 896, 1383, 374, 344, 376, 346, 384, - 853, 854, 381, 389, 352, 353, 373, 865, 429, 376, - 1022, 741, 1302, 1242, 872, 1244, 1171, 370, 1407, 922, - 385, 374, 1133, 1087, 882, 400, 884, 756, 367, 840, - 759, 1372, 382, 383, 764, 370, 357, 376, 357, 374, - 369, 944, 363, 485, 363, 418, 396, 397, 369, 779, - 369, 372, 373, 372, 373, 374, 371, 960, 373, 372, - 371, 374, 373, 376, 367, 386, 919, 386, 926, 415, - 928, 373, 930, 376, 376, 367, 367, 372, 893, 374, - 1253, 392, 393, 525, 376, 376, 944, 1260, 941, 369, - 1148, 390, 372, 1434, 941, 1206, 949, 418, 370, 418, - 421, 412, 374, 371, 370, 547, 339, 1124, 374, 420, - 552, 344, 423, 346, 398, 399, 349, 350, 976, 352, - 353, 979, 367, 372, 854, 374, 371, 569, 373, 374, - 1471, 376, 354, 355, 59, 577, 381, 354, 355, 367, - 951, 1271, 953, 371, 955, 373, 374, 374, 376, 376, - 1493, 1494, 372, 381, 374, 1009, 376, 367, 1016, 418, - 1018, 371, 1020, 373, 374, 370, 376, 372, 93, 374, - 415, 381, 97, 98, 99, 100, 101, 102, 103, 104, - 414, 415, 370, 371, 1087, 1000, 374, 339, 386, 387, - 388, 1031, 344, 370, 346, 372, 429, 349, 350, 256, - 352, 353, 1060, 368, 418, 415, 371, 277, 373, 374, - 370, 371, 654, 373, 374, 375, 1074, 1075, 1072, 949, - 374, 370, 376, 372, 1082, 374, 376, 392, 393, 1087, - 370, 376, 372, 675, 367, 1124, 1094, 1126, 1088, 1097, - 391, 392, 393, 394, 364, 365, 1384, 412, 370, 373, - 372, 1107, 370, 982, 372, 420, 1114, 376, 423, 1148, - 372, 1107, 374, 1121, 372, 370, 374, 372, 710, 370, - 712, 372, 349, 350, 1127, 1133, 368, 429, 374, 371, - 376, 373, 374, 1139, 374, 376, 376, 1145, 1146, 374, - 1179, 376, 374, 1139, 376, 294, 372, 373, 294, 741, - 392, 393, 364, 365, 1092, 1093, 389, 390, 343, 1198, - 1199, 395, 396, 261, 756, 1171, 372, 759, 376, 414, - 412, 418, 764, 369, 418, 1171, 375, 1180, 420, 1218, - 1188, 423, 418, 372, 372, 376, 284, 779, 368, 372, - 374, 783, 294, 1246, 1197, 372, 1204, 294, 1206, 297, - 374, 372, 0, 1242, 302, 1244, 372, 305, 372, 307, - 285, 309, 310, 311, 312, 374, 376, 371, 256, 317, - 295, 374, 294, 321, 1103, 300, 294, 325, 1107, 381, - 375, 1110, 356, 372, 374, 333, 373, 375, 336, 374, - 338, 373, 418, 372, 374, 381, 374, 374, 374, 1252, - 1253, 376, 1256, 423, 429, 372, 1135, 1260, 374, 367, - 1139, 853, 854, 421, 362, 1268, 1269, 372, 1271, 373, - 343, 372, 294, 294, 1277, 374, 61, 418, 374, 370, - 65, 66, 67, 371, 69, 70, 1289, 418, 1291, 74, - 75, 1294, 1171, 367, 375, 370, 81, 256, 83, 1302, - 85, 256, 256, 1307, 374, 90, 91, 382, 383, 384, - 256, 1276, 387, 388, 381, 280, 256, 1197, 1321, 367, - 418, 368, 1201, 1362, 343, 376, 372, 919, 370, 114, - 371, 376, 376, 423, 1299, 374, 372, 374, 370, 372, - 1379, 372, 347, 367, 351, 256, 381, 381, 1313, 256, - 376, 381, 372, 1392, 1393, 368, 347, 949, 374, 370, - 375, 370, 372, 375, 1372, 1330, 1370, 1332, 367, 370, - 348, 368, 1252, 381, 374, 418, 1384, 339, 374, 372, - 1419, 1420, 348, 368, 376, 375, 367, 367, 1268, 1269, - 982, 418, 367, 1401, 402, 403, 404, 405, 406, 407, - 408, 409, 410, 411, 368, 381, 356, 376, 371, 337, - 368, 1291, 368, 374, 1294, 372, 368, 305, 371, 256, - 418, 369, 371, 93, 418, 367, 1434, 97, 98, 99, - 100, 101, 102, 103, 104, 418, 418, 1476, 371, 418, - 1493, 1494, 376, 381, 371, 371, 367, 371, 373, 371, - 381, 369, 371, 376, 374, 372, 372, 372, 256, 373, - 373, 367, 374, 1471, 262, 374, 374, 418, 372, 254, - 370, 418, 257, 1477, 1478, 376, 372, 0, 376, 418, - 1484, 1485, 418, 376, 381, 1493, 1494, 372, 372, 368, - 381, 372, 370, 368, 315, 263, 368, 371, 371, 574, - 298, 372, 372, 0, 0, 367, 372, 376, 368, 0, - 368, 1103, 297, 376, 367, 1107, 372, 372, 1110, 418, - 370, 368, 376, 368, 372, 310, 370, 376, 367, 418, - 376, 418, 368, 376, 372, 1127, 376, 372, 368, 372, - 368, 339, 376, 1135, 367, 372, 344, 1139, 346, 347, - 348, 349, 350, 351, 352, 353, 354, 355, 356, 368, - 372, 368, 376, 367, 315, 363, 376, 373, 376, 367, - 368, 376, 370, 371, 372, 376, 374, 375, 376, 1171, - 378, 379, 376, 376, 382, 383, 384, 385, 1180, 376, - 376, 389, 390, 50, 263, 51, 394, 395, 396, 397, - 398, 399, 400, 401, 12, 1197, 5, 941, 1244, 1201, - 835, 1087, 1087, 1218, 1424, 413, 1387, 675, 416, 1440, - 418, 1375, 1404, 256, 1370, 1277, 856, 856, 856, 689, - 300, 429, 265, 852, 267, 1289, 1485, 270, 1242, 1230, - 715, 1308, 275, 1392, 1479, 0, 279, 1397, 1478, 1393, - 1277, 1179, 1332, 1180, 827, 288, 877, 525, 587, 329, - 1252, 1253, 295, 718, 798, 366, 683, 300, 1260, 991, - 803, 304, 332, 71, 397, 715, 1268, 1269, 398, 1271, - 399, 402, 400, 316, 401, 318, 547, 1252, 783, 322, - 1162, 1171, 1107, 157, 978, 1052, 481, 330, 331, 1291, - 370, 334, 1294, 962, 337, 1063, 1075, 1005, 1136, 1065, - 523, 898, 382, 383, 384, 421, 1248, 387, 388, 389, - 390, 391, 392, 393, 394, 395, 396, 397, 398, 399, - 400, 401, 402, 256, 1146, -1, 521, -1, 261, 262, - 833, -1, -1, 832, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 284, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 297, 298, -1, -1, -1, 302, - -1, -1, 305, -1, 307, 418, 309, 310, 311, 312, - -1, -1, -1, -1, 317, -1, -1, -1, 321, -1, - -1, -1, 325, -1, -1, -1, -1, -1, -1, -1, - 333, -1, 0, 336, -1, 338, 339, -1, -1, -1, - -1, 344, -1, 346, 347, 348, 349, 350, 351, 352, - 353, 354, 355, 356, -1, 505, -1, -1, -1, 362, - 363, -1, -1, -1, 367, 368, -1, 370, 371, 372, - 373, 374, 375, 376, -1, 378, 379, -1, 381, 382, - 383, 384, 385, 386, 387, 388, 389, 390, -1, 392, - 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, - 403, 404, 405, 406, 407, 408, 409, 410, 411, 412, - 413, -1, -1, 416, -1, 418, -1, 420, -1, -1, - 423, 256, 257, -1, 574, -1, 429, -1, -1, 264, - 265, 266, 267, 268, -1, 270, 271, -1, 273, 274, - 275, 276, 277, 278, 279, 280, -1, -1, -1, -1, - 285, -1, 287, 288, 289, 290, 291, 292, 0, -1, - 295, -1, -1, -1, 299, 300, -1, 302, 303, 304, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 314, - -1, 316, -1, 318, 319, -1, -1, 322, -1, 324, - 325, 326, 327, 328, 329, 330, 331, 332, 333, 334, - 335, -1, 337, -1, -1, 340, 341, -1, -1, 344, - 345, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 359, 360, 361, 362, 363, -1, - -1, -1, 367, 368, -1, -1, 371, -1, -1, -1, - -1, 376, 377, 378, 379, 380, -1, -1, -1, 384, - -1, 386, -1, -1, -1, -1, -1, 392, 393, -1, + 516, 4, 51, 17, 300, 234, 6, 51, 18, 189, + 247, 17, 518, 17, 354, 470, 289, 188, 232, 299, + 84, 68, 20, 492, 339, 59, 321, 157, 559, 332, + 354, 59, 780, 296, 298, 747, 645, 646, 576, 934, + 87, 88, 87, 88, 58, 92, 1145, 1146, 47, 113, + 1110, 115, 191, 584, 0, 73, 721, 77, 723, 77, + 256, 1235, 17, 108, 328, 79, 256, 81, 939, 256, + 113, 256, 115, 256, 256, 256, 325, 95, 268, 1253, + 256, 256, 363, 1193, 256, 277, 282, 372, 369, 374, + 256, 256, 335, 256, 256, 1194, 368, 256, 17, 256, + 17, 17, 767, 1213, 1219, 770, 256, 17, 256, 256, + 268, 1442, 1443, 268, 376, 371, 382, 383, 314, 418, + 394, 395, 370, 371, 414, 172, 374, 665, 17, 428, + 396, 397, 369, 17, 17, 0, 1105, 418, 428, 157, + 189, 17, 17, 157, 429, 189, 418, 411, 17, 1264, + 17, 157, 339, 157, 199, 200, 257, 344, 256, 346, + 343, 294, 349, 350, 420, 352, 353, 429, 1499, 418, + 59, 363, 256, 306, 63, 256, 256, 268, 363, 256, + 789, 256, 358, 232, 323, 276, 429, 374, 232, 256, + 256, 256, 532, 340, 1304, 1066, 0, 372, 1308, 381, + 247, 367, 157, 369, 363, 371, 435, 816, 391, 512, + 368, 370, 259, 372, 554, 374, 355, 262, 724, 381, + 434, 360, 418, 1333, 223, 375, 418, 419, 228, 247, + 554, 414, 422, 418, 252, 515, 576, 418, 157, 1413, + 157, 157, 429, 288, 559, 428, 418, 157, 424, 425, + 426, 427, 286, 418, 420, 418, 320, 423, 286, 418, + 324, 418, 296, 308, 422, 329, 1440, 422, 157, 584, + 418, 289, 363, 157, 157, 1023, 294, 295, 1452, 326, + 1454, 157, 157, 381, 331, 418, 329, 367, 157, 317, + 157, 309, 376, 256, 375, 256, 376, 315, 375, 317, + 375, 440, 316, 321, 370, 370, 351, 374, 374, 374, + 910, 257, 256, 256, 256, 333, 334, 256, 256, 358, + 256, 372, 369, 370, 372, 665, 256, 418, 1040, 867, + 372, 996, 941, 339, 943, 339, 475, 946, 358, 368, + 358, 1089, 666, 388, 389, 256, 686, 1407, 325, 256, + 262, 369, 370, 368, 363, 368, 374, 375, 376, 377, + 378, 379, 380, 381, 382, 383, 384, 357, 263, 416, + 417, 416, 417, 420, 1473, 256, 1345, 256, 429, 374, + 257, 429, 256, 373, 256, 434, 298, 429, 406, 374, + 434, 256, 20, 367, 900, 444, 386, 286, 1293, 341, + 429, 363, 376, 418, 1503, 1374, 1375, 368, 1377, 418, + 879, 374, 294, 374, 709, 1015, 429, 1017, 368, 1388, + 315, 416, 1391, 1032, 368, 1034, 1035, 369, 317, 372, + 374, 416, 371, 662, 372, 574, 372, 1406, 436, 369, + 484, 418, 441, 442, 491, 256, 493, 586, 447, 588, + 339, 590, 450, 257, 794, 1120, 418, 694, 369, 87, + 88, 1430, 1127, 726, 492, 372, 378, 379, 272, 516, + 794, 485, 701, 277, 339, 357, 256, 281, 277, 429, + 108, 363, 281, 266, 990, 532, 1151, 369, 369, 536, + 372, 373, 296, 372, 263, 369, 514, 369, 516, 266, + 518, 372, 367, 343, 386, 368, 371, 368, 373, 374, + 375, 376, 368, 376, 528, 529, 381, 656, 368, 323, + 341, 256, 1131, 401, 542, 306, 370, 867, 575, 547, + 374, 314, 313, 294, 532, 413, 418, 676, 342, 421, + 1205, 381, 866, 342, 363, 306, 315, 314, 369, 256, + 369, 391, 566, 559, 1163, 559, 367, 363, 429, 294, + 371, 256, 373, 374, 256, 376, 429, 256, 429, 363, + 381, 199, 200, 429, 414, 593, 594, 814, 584, 429, + 584, 343, 369, 335, 864, 256, 373, 367, 428, 1311, + 893, 371, 375, 373, 374, 642, 376, 644, 1207, 418, + 343, 381, 1324, 492, 415, 735, 653, 372, 375, 21, + 367, 1219, 418, 305, 371, 1224, 305, 418, 391, 381, + 1219, 1343, 640, 305, 418, 1156, 272, 645, 646, 391, + 648, 277, 339, 897, 262, 281, 423, 344, 934, 346, + 52, 414, 349, 350, 339, 352, 353, 694, 391, 344, + 296, 346, 414, 418, 349, 350, 1264, 352, 353, 371, + 288, 373, 256, 420, 711, 1264, 428, 374, 339, 272, + 559, 414, 300, 344, 357, 346, 694, 323, 349, 350, + 308, 352, 353, 1152, 1219, 428, 369, 687, 272, 372, + 373, 709, 726, 296, 758, 584, 342, 256, 993, 1219, + 256, 305, 1219, 386, 272, 1219, 724, 752, 264, 339, + 269, 729, 296, 339, 761, 373, 373, 414, 1219, 376, + 323, 958, 429, 351, 256, 1005, 354, 286, 296, 1264, + 775, 428, 390, 391, 429, 369, 357, 367, 421, 323, + 754, 367, 363, 357, 1264, 790, 793, 1264, 369, 376, + 1264, 372, 373, 374, 772, 323, 774, 888, 429, 256, + 388, 389, 809, 1264, 778, 386, 780, 814, 899, 325, + 909, 789, 386, 367, 368, 369, 376, 371, 372, 950, + 374, 368, 376, 381, 269, 1218, 1219, 374, 416, 417, + 371, 809, 841, 391, 381, 367, 814, 418, 816, 357, + 818, 286, 391, 381, 1077, 256, 1239, 339, 436, 1124, + 398, 399, 344, 391, 346, 373, 414, 349, 350, 357, + 352, 353, 450, 868, 418, 414, 420, 871, 386, 423, + 1110, 1264, 721, 1266, 723, 373, 414, 368, 369, 428, + 1113, 1156, 339, 386, 862, 991, 864, 344, 386, 346, + 428, 849, 349, 350, 854, 352, 353, 904, 418, 906, + 306, 371, 308, 881, 306, 912, 1103, 313, 428, 1324, + 888, 313, 339, 1019, 1189, 1014, 1149, 367, 767, 325, + 898, 770, 900, 325, 373, 418, 376, 376, 339, 1395, + 937, 369, 371, 344, 373, 346, 256, 429, 349, 350, + 367, 352, 353, 381, 532, 379, 367, 368, 367, 376, + 367, 958, 384, 392, 393, 376, 368, 376, 963, 376, + 367, 368, 367, 941, 376, 943, 554, 974, 946, 376, + 368, 376, 429, 412, 1274, 256, 374, 385, 376, 368, + 958, 420, 1282, 372, 423, 374, 368, 376, 576, 389, + 372, 1457, 1166, 1226, 376, 370, 400, 955, 368, 374, + 1140, 371, 368, 373, 374, 965, 372, 967, 374, 969, + 376, 373, 990, 368, 376, 993, 370, 390, 429, 339, + 374, 376, 392, 393, 344, 369, 346, 370, 1494, 349, + 350, 374, 352, 353, 418, 372, 374, 1293, 376, 376, + 1516, 1517, 412, 381, 261, 354, 355, 1236, 372, 1023, + 420, 372, 376, 423, 1032, 376, 1034, 1035, 339, 1037, + 372, 371, 374, 344, 376, 346, 415, 284, 349, 350, + 6, 352, 353, 418, 370, 370, 372, 665, 374, 374, + 297, 17, 372, 256, 1047, 302, 376, 370, 305, 372, + 307, 374, 309, 310, 311, 312, 1103, 277, 686, 1077, + 317, 1105, 370, 371, 321, 373, 374, 375, 325, 429, + 386, 387, 388, 1091, 1092, 1089, 333, 369, 418, 336, + 372, 338, 371, 59, 373, 1103, 367, 63, 369, 354, + 355, 1140, 1110, 1142, 1104, 1113, 1140, 394, 395, 396, + 397, 372, 372, 374, 374, 362, 370, 996, 372, 367, + 368, 87, 88, 1131, 374, 376, 376, 1166, 1124, 1137, + 1124, 370, 1166, 372, 752, 376, 370, 1407, 372, 367, + 367, 1149, 108, 371, 373, 373, 374, 370, 376, 372, + 372, 294, 374, 381, 294, 1163, 1164, 775, 1197, 372, + 1156, 374, 1156, 370, 370, 372, 372, 364, 365, 1298, + 343, 418, 790, 374, 376, 376, 794, 368, 369, 1218, + 1219, 374, 1217, 376, 1218, 372, 374, 415, 376, 414, + 415, 157, 1321, 1189, 374, 1189, 376, 372, 373, 1207, + 1239, 364, 365, 1108, 1109, 1239, 1335, 392, 393, 398, + 399, 376, 376, 418, 414, 356, 1224, 369, 1226, 418, + 59, 375, 418, 372, 1353, 1264, 1355, 1266, 372, 376, + 1267, 849, 1266, 199, 200, 368, 374, 372, 1273, 294, + 372, 1120, 294, 374, 372, 1124, 372, 374, 1127, 867, + 868, 372, 376, 371, 93, 1290, 1291, 256, 97, 98, + 99, 100, 101, 102, 103, 104, 374, 294, 294, 381, + 372, 374, 1151, 373, 1278, 373, 375, 1156, 1313, 61, + 374, 1316, 418, 65, 66, 67, 381, 69, 70, 372, + 374, 372, 74, 75, 374, 374, 262, 374, 423, 81, + 429, 83, 374, 85, 367, 421, 372, 372, 90, 91, + 1189, 1345, 373, 343, 374, 294, 934, 294, 374, 370, + 286, 418, 288, 371, 367, 1329, 1205, 418, 375, 256, + 256, 256, 114, 374, 300, 256, 381, 955, 280, 256, + 1374, 1375, 308, 1377, 367, 963, 1385, 368, 372, 343, + 368, 317, 371, 371, 1388, 373, 374, 1391, 351, 370, + 376, 374, 374, 1402, 372, 370, 376, 381, 372, 372, + 423, 347, 1406, 339, 392, 393, 1415, 1416, 367, 381, + 381, 256, 256, 347, 372, 351, 372, 1395, 354, 1393, + 368, 376, 374, 339, 412, 370, 1430, 370, 370, 1407, + 348, 375, 420, 1442, 1443, 423, 368, 372, 348, 418, + 368, 374, 418, 372, 367, 376, 1424, 367, 261, 368, + 367, 381, 388, 389, 356, 376, 371, 368, 337, 93, + 374, 368, 368, 97, 98, 99, 100, 101, 102, 103, + 104, 284, 372, 305, 367, 369, 374, 286, 418, 1457, + 416, 417, 371, 371, 297, 371, 376, 296, 371, 302, + 1499, 418, 305, 302, 307, 373, 309, 310, 311, 312, + 381, 371, 254, 367, 317, 257, 371, 381, 321, 1516, + 1517, 369, 325, 418, 418, 418, 1494, 371, 373, 372, + 333, 372, 374, 336, 373, 338, 1500, 1501, 374, 256, + 372, 374, 372, 1507, 1508, 376, 418, 370, 1516, 1517, + 376, 418, 418, 372, 381, 376, 298, 418, 376, 362, + 372, 367, 372, 368, 381, 1143, 492, 368, 370, 256, + 315, 313, 372, 263, 373, 371, 261, 371, 368, 372, + 372, 0, 0, 367, 372, 376, 385, 386, 387, 368, + 0, 390, 391, 368, 372, 372, 370, 367, 418, 284, + 368, 368, 0, 372, 370, 367, 532, 418, 368, 418, + 373, 376, 297, 372, 368, 418, 372, 302, 376, 376, + 372, 1199, 307, 376, 309, 310, 311, 312, 554, 368, + 367, 372, 317, 559, 368, 368, 321, 372, 376, 1217, + 367, 315, 263, 50, 376, 376, 376, 376, 333, 12, + 576, 336, 339, 338, 376, 376, 376, 344, 584, 346, + 347, 348, 349, 350, 351, 352, 353, 354, 355, 356, + 376, 5, 955, 849, 1266, 1447, 1103, 362, 302, 364, + 365, 368, 1103, 370, 1239, 372, 1410, 374, 375, 376, + 686, 1427, 1398, 1463, 1393, 1273, 1274, 1299, 700, 871, + 871, 1311, 871, 390, 1282, 0, 1508, 1264, 332, 1252, + 1330, 866, 1290, 1291, 401, 1293, 1502, 1420, 256, 1416, + 1415, 1299, 1501, 1197, 1355, 1299, 413, 1199, 841, 381, + 729, 814, 809, 1311, 532, 1313, 594, 369, 1316, 665, + 1005, 893, 429, 694, 71, 487, 1324, 335, 401, 373, + 402, 403, 404, 405, 406, 407, 408, 409, 410, 411, + 686, 385, 386, 387, 400, 1343, 390, 391, 392, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 581, 726, 402, 404, 528, 403, 405, 1178, + 794, 157, 1124, 554, 1273, 721, 1189, 723, 1068, 992, + 1092, 339, 1019, 1080, 1082, 1152, 344, 530, 346, 347, + 348, 349, 350, 351, 352, 353, 354, 355, 356, 425, + 914, 425, 976, 651, 1269, 847, 752, 1164, 846, -1, + 368, -1, 370, -1, 372, -1, 374, 375, 376, -1, + -1, 767, -1, -1, 770, -1, -1, -1, -1, 775, + -1, -1, 390, -1, -1, -1, -1, -1, 256, 257, + -1, -1, -1, 261, 790, -1, -1, 265, 794, 267, + -1, -1, 270, -1, 272, 273, 0, 275, -1, 277, + -1, 279, -1, 281, 282, 283, 284, -1, 512, 287, + 288, 429, -1, -1, -1, 293, -1, 295, 296, 297, + -1, -1, 300, 301, 302, -1, 304, -1, -1, 307, + -1, 309, 310, 311, 312, -1, -1, -1, 316, 317, + 318, -1, -1, 321, 322, 323, -1, 726, -1, -1, + -1, -1, 330, 331, -1, 333, 334, -1, 336, 337, + 338, 867, 868, -1, 342, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 581, -1, -1, + -1, 256, -1, -1, 362, 0, 261, 262, -1, -1, + 368, 369, -1, -1, -1, -1, -1, -1, -1, 377, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 284, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 297, 298, -1, -1, -1, 302, 934, -1, + 305, -1, 307, -1, 309, 310, 311, 312, -1, -1, + 418, -1, 317, -1, -1, -1, 321, -1, -1, -1, + 325, -1, -1, -1, -1, -1, -1, 963, 333, -1, + -1, 336, -1, 338, 339, -1, -1, -1, -1, 344, + -1, 346, 347, 348, 349, 350, 351, 352, 353, 354, + 355, 356, -1, -1, -1, -1, -1, 362, 363, -1, + 996, -1, 367, 368, -1, 370, 371, 372, 373, 374, + 375, 376, -1, 378, 379, -1, 381, 382, 383, 384, + 385, 386, 387, 388, 389, 390, -1, 392, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 407, 408, 409, 410, 411, 412, 413, -1, + -1, 416, -1, 418, -1, 420, -1, 0, 423, -1, + -1, -1, -1, 257, 429, -1, -1, 261, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 272, -1, + -1, -1, -1, 277, -1, -1, -1, 281, -1, -1, + 284, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 296, 297, -1, -1, -1, 301, 302, -1, + -1, -1, -1, 307, -1, 309, 310, 311, 312, -1, + -1, -1, -1, 317, 1120, -1, -1, 321, 1124, 323, + -1, 1127, -1, -1, -1, -1, -1, -1, -1, 333, + -1, 335, 336, -1, 338, -1, -1, 1143, 342, -1, + -1, -1, 257, 256, -1, 1151, 261, -1, -1, -1, + 1156, -1, -1, -1, -1, -1, -1, 272, 362, -1, + -1, -1, 277, -1, 368, 369, 281, -1, -1, 284, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 417, 418, 419, 420, -1, 422, 256, 257, - -1, -1, -1, -1, 429, -1, 264, 265, 266, 267, - 268, -1, 270, 271, 0, 273, 274, 275, 276, 277, - 278, 279, -1, -1, -1, -1, -1, 285, -1, 287, - 288, 289, 290, 291, 292, -1, -1, 295, -1, -1, - -1, 299, 300, -1, 302, 303, 304, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 314, -1, 316, -1, - 318, 319, -1, -1, 322, -1, 324, 325, 326, 327, - 328, 329, 330, 331, 332, 333, 334, 335, -1, 337, - -1, -1, 340, 341, -1, -1, 344, 345, -1, -1, + -1, 296, 297, 1189, -1, -1, 301, 302, -1, 893, + -1, -1, 307, 1199, 309, 310, 311, 312, -1, 1205, + -1, -1, 317, -1, -1, -1, 321, -1, 323, -1, + -1, 1217, -1, -1, 0, -1, -1, -1, 333, -1, + 335, 336, -1, 338, -1, -1, 339, 342, -1, -1, + -1, 344, -1, 346, 347, 348, 349, 350, 351, 352, + 353, 354, 355, 356, -1, -1, -1, 362, -1, -1, + -1, -1, -1, -1, 369, 368, -1, 370, -1, 372, + -1, 374, 375, 376, -1, -1, -1, 1273, 1274, -1, + -1, -1, -1, -1, -1, -1, 1282, 390, -1, -1, + -1, -1, -1, -1, 1290, 1291, -1, 1293, 401, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 359, 360, 361, 362, 363, -1, -1, -1, 367, - 368, -1, -1, 371, -1, -1, -1, -1, 376, 377, - 378, 379, 380, -1, 256, -1, 384, -1, 386, 261, - 262, -1, -1, -1, 392, 393, -1, 877, -1, -1, - -1, -1, -1, -1, 0, -1, -1, -1, -1, -1, - -1, -1, 284, -1, -1, -1, -1, -1, -1, 417, - 418, 419, 420, -1, 422, 297, 298, -1, -1, -1, - 302, 429, -1, 305, -1, 307, -1, 309, 310, 311, - 312, -1, -1, -1, -1, 317, -1, -1, -1, 321, - -1, -1, -1, 325, -1, -1, -1, -1, -1, -1, - -1, 333, -1, -1, 336, -1, 338, 339, -1, -1, - -1, -1, 344, -1, 346, 347, 348, 349, 350, 351, - 352, 353, 354, 355, 356, 357, -1, -1, -1, -1, - 362, 363, -1, -1, -1, 367, 368, 369, 370, 371, - 372, 373, 374, 375, 376, -1, 378, 379, -1, -1, - 382, 383, 384, 385, 386, -1, -1, 389, 390, -1, - -1, -1, 394, 395, 396, 397, 398, 399, 400, 401, - 256, -1, -1, -1, 0, 261, 262, -1, -1, -1, - -1, 413, -1, -1, 416, -1, 418, -1, 420, -1, - -1, 423, -1, -1, -1, -1, -1, 429, 284, -1, + 413, -1, -1, 256, 257, -1, -1, 1313, -1, -1, + 1316, 264, 265, 266, 267, 268, 429, 270, 271, -1, + 273, 274, 275, 276, 277, 278, 279, 280, -1, -1, + -1, -1, 285, -1, 287, 288, 289, 290, 291, 292, + 0, -1, 295, -1, -1, -1, 299, 300, -1, 302, + 303, 304, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 314, -1, 316, -1, 318, 319, -1, -1, 322, + -1, 324, 325, 326, 327, 328, 329, 330, 331, 332, + 333, 334, 335, -1, 337, -1, -1, 340, 341, -1, + -1, 344, 345, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 359, 360, 361, 362, + 363, -1, -1, -1, 367, 368, -1, -1, 371, -1, + -1, -1, -1, 376, 377, 378, 379, 380, -1, -1, + -1, 384, -1, 386, -1, -1, -1, -1, -1, 392, + 393, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 297, 298, -1, -1, -1, 302, -1, -1, 305, - -1, 307, -1, 309, 310, 311, 312, -1, -1, -1, - -1, 317, -1, -1, -1, 321, -1, -1, -1, 325, - -1, -1, -1, -1, -1, -1, -1, 333, -1, -1, - 336, -1, 338, 339, -1, -1, -1, -1, 344, -1, - 346, 347, 348, 349, 350, 351, 352, 353, 354, 355, - 356, -1, -1, -1, -1, -1, 362, 363, 0, -1, - -1, 367, 368, 369, 370, 371, 372, -1, 374, 375, - 376, -1, 378, 379, -1, -1, 382, 383, 384, 385, - 256, -1, -1, 389, 390, 261, 262, -1, 394, 395, - 396, 397, 398, 399, 400, 401, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 413, 284, -1, - 416, -1, 418, -1, 420, -1, -1, 423, -1, -1, - -1, 297, 298, 429, -1, -1, 302, -1, -1, 305, - -1, 307, -1, 309, 310, 311, 312, -1, -1, -1, - -1, 317, -1, -1, -1, 321, -1, -1, -1, 325, - -1, -1, -1, -1, -1, -1, -1, 333, -1, -1, - 336, -1, 338, 339, -1, -1, -1, -1, 344, -1, - 346, 347, 348, 349, 350, 351, 352, 353, 354, 355, - 356, -1, -1, -1, -1, -1, 362, 363, -1, -1, - -1, 367, 368, 369, 370, 371, 372, -1, 374, 375, - 376, -1, 378, 379, -1, -1, 382, 383, 384, 385, - 256, -1, -1, 389, 390, 261, 262, -1, 394, 395, - 396, 397, 398, 399, 400, 401, -1, 0, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 413, 284, -1, - 416, -1, 418, -1, 420, -1, -1, 423, -1, -1, - -1, 297, 298, 429, -1, -1, 302, -1, -1, 305, - -1, 307, -1, 309, 310, 311, 312, -1, -1, -1, - -1, 317, -1, -1, -1, 321, -1, -1, -1, 325, - -1, -1, -1, -1, -1, -1, -1, 333, -1, -1, - 336, -1, 338, 339, -1, -1, -1, -1, 344, -1, - 346, 347, 348, 349, 350, 351, 352, 353, 354, 355, - 356, -1, -1, -1, 256, -1, 362, 363, -1, -1, - 262, 367, 368, -1, 370, 371, 372, -1, 374, 375, - 376, -1, 378, 379, -1, -1, 382, 383, 384, 385, - 0, -1, -1, 389, 390, -1, -1, -1, 394, 395, - 396, 397, 398, 399, 400, 401, 298, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 413, -1, -1, - 416, -1, 418, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 429, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 339, -1, -1, - -1, -1, 344, 0, 346, 347, 348, 349, 350, 351, - 352, 353, 354, 355, 356, 357, -1, -1, -1, -1, - -1, 363, -1, -1, -1, 367, 368, 369, 370, 371, - 372, 373, 374, 375, 376, -1, 378, 379, -1, -1, - 382, 383, 384, 385, 386, -1, -1, 389, 390, -1, - -1, -1, 394, 395, 396, 397, 398, 399, 400, 401, + -1, -1, -1, -1, 417, 418, 419, 420, -1, 422, + 256, 257, -1, -1, -1, -1, 429, -1, 264, 265, + 266, 267, 268, -1, 270, 271, 0, 273, 274, 275, + 276, 277, 278, 279, -1, -1, -1, -1, -1, 285, + -1, 287, 288, 289, 290, 291, 292, -1, -1, 295, + -1, -1, -1, 299, 300, -1, 302, 303, 304, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 314, -1, + 316, -1, 318, 319, -1, -1, 322, -1, 324, 325, + 326, 327, 328, 329, 330, 331, 332, 333, 334, 335, + -1, 337, -1, -1, 340, 341, -1, -1, 344, 345, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 413, 0, -1, 416, -1, 418, -1, 420, -1, - -1, 423, -1, -1, 257, -1, -1, 429, 261, -1, - 263, -1, 265, -1, 267, -1, -1, 270, -1, 272, - 273, -1, 275, -1, 277, -1, 279, -1, 281, 282, - 283, 284, -1, -1, 287, 288, -1, -1, -1, 0, - 293, 294, 295, 296, 297, -1, -1, 300, 301, 302, - -1, 304, -1, 306, 307, 308, 309, 310, 311, 312, - 313, -1, 315, 316, 317, 318, -1, -1, 321, 322, - 323, -1, 325, -1, -1, -1, -1, 330, 331, -1, - 333, 334, -1, 336, 337, 338, -1, -1, -1, 342, + -1, -1, -1, 359, 360, 361, 362, 363, -1, -1, + -1, 367, 368, -1, -1, 371, -1, -1, -1, -1, + 376, 377, 378, 379, 380, -1, 256, -1, 384, -1, + 386, 261, 262, -1, -1, -1, 392, 393, -1, -1, + -1, -1, -1, -1, -1, -1, 0, -1, -1, -1, + -1, -1, -1, -1, 284, -1, -1, -1, -1, -1, + -1, 417, 418, 419, 420, -1, 422, 297, 298, -1, + -1, -1, 302, 429, -1, 305, -1, 307, -1, 309, + 310, 311, 312, -1, -1, -1, -1, 317, -1, -1, + -1, 321, -1, -1, -1, 325, -1, -1, -1, -1, + -1, -1, -1, 333, -1, -1, 336, -1, 338, 339, + -1, -1, -1, -1, 344, -1, 346, 347, 348, 349, + 350, 351, 352, 353, 354, 355, 356, 357, -1, -1, + -1, -1, 362, 363, -1, -1, -1, 367, 368, 369, + 370, 371, 372, 373, 374, 375, 376, -1, 378, 379, + -1, -1, 382, 383, 384, 385, 386, -1, -1, 389, + 390, -1, -1, -1, 394, 395, 396, 397, 398, 399, + 400, 401, 256, -1, -1, -1, 0, 261, 262, -1, + -1, -1, -1, 413, -1, -1, 416, -1, 418, -1, + 420, -1, -1, 423, -1, -1, -1, -1, -1, 429, + 284, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 297, 298, -1, -1, -1, 302, -1, + -1, 305, -1, 307, -1, 309, 310, 311, 312, -1, + -1, -1, -1, 317, -1, -1, -1, 321, -1, -1, + -1, 325, -1, -1, -1, -1, -1, -1, -1, 333, + -1, -1, 336, -1, 338, 339, -1, -1, -1, -1, + 344, -1, 346, 347, 348, 349, 350, 351, 352, 353, + 354, 355, 356, -1, -1, -1, -1, -1, 362, 363, + 0, -1, -1, 367, 368, 369, 370, 371, 372, -1, + 374, 375, 376, -1, 378, 379, -1, -1, 382, 383, + 384, 385, 256, -1, -1, 389, 390, 261, 262, -1, + 394, 395, 396, 397, 398, 399, 400, 401, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 413, + 284, -1, 416, -1, 418, -1, 420, -1, -1, 423, + -1, -1, -1, 297, 298, 429, -1, -1, 302, -1, + -1, 305, -1, 307, -1, 309, 310, 311, 312, -1, + -1, -1, -1, 317, -1, -1, -1, 321, -1, -1, + -1, 325, -1, -1, -1, -1, -1, -1, -1, 333, + -1, -1, 336, -1, 338, 339, -1, -1, -1, -1, + 344, -1, 346, 347, 348, 349, 350, 351, 352, 353, + 354, 355, 356, -1, -1, -1, -1, -1, 362, 363, + -1, -1, -1, 367, 368, 369, 370, 371, 372, -1, + 374, 375, 376, -1, 378, 379, 0, -1, 382, 383, + 384, 385, 256, -1, -1, 389, 390, 261, 262, -1, + 394, 395, 396, 397, 398, 399, 400, 401, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 413, + 284, -1, 416, -1, 418, -1, 420, -1, -1, 423, + -1, -1, -1, 297, 298, 429, -1, -1, 302, -1, + -1, 305, -1, 307, -1, 309, 310, 311, 312, -1, + -1, -1, -1, 317, -1, -1, -1, 321, -1, -1, + -1, 325, -1, -1, -1, -1, -1, -1, -1, 333, + -1, -1, 336, -1, 338, 339, -1, -1, -1, -1, + 344, -1, 346, 347, 348, 349, 350, 351, 352, 353, + 354, 355, 356, -1, -1, -1, 256, -1, 362, 363, + -1, -1, 262, 367, 368, -1, 370, 371, 372, -1, + 374, 375, 376, -1, 378, 379, 0, -1, 382, 383, + 384, 385, -1, -1, -1, 389, 390, -1, -1, -1, + 394, 395, 396, 397, 398, 399, 400, 401, 298, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 413, + -1, -1, 416, -1, 418, -1, -1, -1, -1, 0, + -1, -1, -1, -1, -1, 429, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 339, + -1, -1, 256, -1, 344, -1, 346, 347, 348, 349, + 350, 351, 352, 353, 354, 355, 356, 357, -1, -1, + -1, -1, 0, 363, -1, -1, -1, 367, 368, 369, + 370, 371, 372, 373, 374, 375, 376, -1, 378, 379, + -1, -1, 382, 383, 384, 385, 386, -1, -1, 389, + 390, -1, -1, -1, 394, 395, 396, 397, 398, 399, + 400, 401, 256, -1, -1, 0, -1, -1, 262, -1, + -1, -1, -1, 413, -1, -1, 416, -1, 418, -1, + 420, -1, -1, 423, -1, 339, -1, -1, -1, 429, + 344, -1, 346, 347, 348, 349, 350, 351, 352, 353, + 354, 355, 356, -1, 298, -1, -1, -1, 0, -1, + -1, -1, -1, -1, 368, -1, 370, -1, 372, -1, + 374, 375, 376, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 0, -1, -1, -1, -1, -1, -1, 362, - -1, 364, 365, -1, -1, -1, 256, 257, -1, -1, - -1, 261, -1, -1, 377, 265, -1, 267, -1, -1, - 270, -1, 272, 273, -1, 275, -1, 277, -1, 279, - -1, 281, 282, 283, 284, 0, -1, 287, 288, -1, - -1, -1, -1, 293, -1, 295, 296, 297, -1, -1, - 300, 301, 302, -1, 304, 418, -1, 307, -1, 309, - 310, 311, 312, -1, -1, -1, 316, 317, 318, -1, - 257, 321, 322, 323, 261, -1, -1, -1, 0, -1, - 330, 331, -1, 333, 334, 272, 336, 337, 338, -1, - 277, -1, 342, -1, 281, -1, -1, 284, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 296, - 297, -1, 362, -1, 301, 302, -1, -1, 368, 369, - 307, 0, 309, 310, 311, 312, -1, 377, -1, -1, - 317, -1, -1, -1, 321, -1, 323, -1, -1, 257, - -1, -1, -1, 261, -1, -1, 333, -1, 335, 336, - -1, 338, -1, -1, 272, 342, -1, -1, -1, 277, - -1, -1, -1, 281, 0, -1, 284, -1, 418, -1, - -1, -1, -1, -1, -1, 362, -1, -1, 296, 297, - -1, 368, 369, 301, 302, -1, 257, -1, -1, 307, - 261, 309, 310, 311, 312, -1, -1, -1, -1, 317, - -1, 272, -1, 321, -1, 323, 277, 0, -1, -1, - 281, -1, -1, 284, -1, 333, -1, 335, 336, -1, - 338, -1, -1, -1, 342, 296, 297, -1, -1, -1, - 301, 302, -1, -1, -1, -1, 307, -1, 309, 310, - 311, 312, -1, -1, 362, -1, 317, -1, -1, 257, - 321, 369, 323, 261, -1, -1, -1, -1, -1, -1, - -1, -1, 333, -1, 272, 336, -1, 338, -1, 277, - 0, 342, -1, 281, -1, -1, 284, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 296, 297, - -1, 362, 257, 301, 302, -1, 261, 368, 369, 307, + -1, -1, -1, -1, -1, 339, -1, -1, -1, -1, + 344, 0, 346, 347, 348, 349, 350, 351, 352, 353, + 354, 355, 356, -1, -1, -1, -1, -1, -1, 363, + -1, -1, -1, 367, 368, 429, 370, 371, 372, -1, + 374, 375, 376, -1, 378, 379, -1, -1, 382, 383, + 384, 385, -1, 257, 0, 389, 390, 261, -1, -1, + 394, 395, 396, 397, 398, 399, 400, 401, 272, -1, + -1, -1, -1, 277, -1, -1, -1, 281, -1, 413, + 284, -1, 416, -1, 418, -1, -1, -1, -1, -1, + -1, -1, 296, 297, -1, 429, 257, 301, 302, -1, + 261, -1, -1, 307, -1, 309, 310, 311, 312, -1, + -1, 272, -1, 317, -1, -1, 277, 321, -1, 323, + 281, 0, -1, 284, -1, -1, -1, -1, -1, 333, + -1, -1, 336, -1, 338, 296, 297, -1, 342, 257, + 301, 302, -1, 261, -1, -1, 307, -1, 309, 310, + 311, 312, -1, -1, 272, -1, 317, -1, 362, 277, + 321, -1, 323, 281, 368, 369, 284, -1, 0, -1, + -1, -1, 333, -1, -1, 336, -1, 338, 296, 297, + -1, 342, 257, 301, 302, -1, 261, -1, -1, 307, -1, 309, 310, 311, 312, -1, -1, 272, -1, 317, - -1, -1, 277, 321, -1, 323, 281, -1, -1, 284, + -1, 362, 277, 321, -1, 323, 281, 368, 369, 284, -1, -1, -1, -1, -1, 333, -1, -1, 336, -1, 338, 296, 297, -1, 342, 257, 301, 302, -1, 261, -1, -1, 307, -1, 309, 310, 311, 312, -1, -1, 272, -1, 317, -1, 362, 277, 321, -1, 323, 281, - 368, 369, 284, -1, -1, -1, -1, -1, 333, -1, + -1, 369, 284, -1, -1, -1, -1, -1, 333, -1, -1, 336, -1, 338, 296, 297, -1, 342, 257, 301, 302, -1, 261, -1, -1, 307, -1, 309, 310, 311, 312, -1, -1, 272, -1, 317, -1, 362, 277, 321, - -1, 323, 281, -1, 369, 284, -1, -1, -1, -1, + -1, 323, 281, -1, -1, 284, -1, -1, -1, -1, -1, 333, -1, -1, 336, -1, 338, 296, 297, -1, 342, 257, 301, 302, -1, 261, -1, -1, 307, -1, 309, 310, 311, 312, -1, -1, 272, -1, 317, -1, 362, 277, 321, -1, 323, 281, -1, -1, 284, -1, -1, -1, -1, -1, 333, -1, -1, 336, -1, 338, - 296, 297, -1, 342, 257, 301, 302, -1, 261, -1, - -1, 307, -1, 309, 310, 311, 312, -1, -1, 272, - -1, 317, -1, 362, 277, 321, -1, 323, 281, -1, - -1, 284, -1, -1, -1, -1, -1, 333, -1, -1, - 336, -1, 338, 296, 297, -1, 342, -1, 301, 302, - -1, -1, -1, -1, 307, -1, 309, 310, 311, 312, - -1, -1, -1, -1, 317, -1, 362, 257, 321, -1, - 323, 261, -1, -1, -1, -1, -1, -1, -1, -1, - 333, -1, 272, 336, -1, 338, -1, 277, -1, 342, - -1, 281, -1, -1, 284, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 296, 297, -1, 362, - -1, 301, 302, -1, -1, -1, -1, 307, -1, 309, - 310, 311, 312, -1, -1, -1, -1, 317, -1, -1, - -1, 321, -1, 323, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 333, -1, 256, 336, -1, 338, -1, - -1, -1, 342, 264, 265, 266, 267, -1, -1, 270, - 271, -1, 273, 274, 275, 276, 277, 278, 279, -1, - -1, -1, 362, -1, 285, -1, 287, 288, 289, 290, - 291, 292, -1, -1, 295, -1, -1, -1, 299, 300, - -1, 302, 303, 304, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 314, -1, 316, -1, 318, 319, -1, - -1, 322, -1, 324, 325, 326, 327, 328, 329, 330, - 331, 332, 333, 334, 335, -1, 337, -1, -1, 340, - 341, -1, 256, 344, 345, -1, -1, -1, 262, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 359, 360, - 361, 362, 363, -1, -1, -1, 367, -1, -1, -1, - 371, -1, -1, -1, -1, 376, 377, 378, 379, 380, - -1, -1, -1, 384, 298, 386, -1, -1, -1, -1, - -1, 392, 393, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 256, -1, - -1, -1, -1, -1, 262, -1, 417, 418, 419, 420, - -1, -1, -1, -1, -1, 339, -1, -1, 429, -1, - 344, -1, 346, 347, 348, 349, 350, 351, 352, 353, - 354, 355, 356, 357, -1, -1, -1, -1, -1, 363, - 298, -1, -1, -1, 368, 369, 370, 371, 372, 373, - 374, 375, 376, -1, 378, 379, -1, 381, 382, 383, - 384, 385, 386, 387, 388, 389, 390, -1, 392, 393, - 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, - 404, 405, 406, 407, 408, 409, 410, 411, 412, 413, - -1, 256, -1, -1, 418, -1, 420, 262, -1, 423, - -1, -1, -1, -1, -1, 429, -1, -1, -1, -1, - 368, -1, -1, 371, -1, 373, 374, -1, -1, -1, - 378, 379, -1, -1, 382, 383, 384, 385, 386, 387, - 388, 389, 390, 298, 392, 393, 394, 395, 396, 397, - 398, 399, 400, 401, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 412, 413, -1, -1, -1, -1, - -1, -1, 420, -1, -1, 423, -1, -1, -1, -1, - -1, 429, -1, 285, 339, -1, -1, -1, -1, 344, - -1, 346, 347, 348, 349, 350, 351, 352, 353, 354, - 355, 356, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 367, 368, 369, 370, 371, 372, 373, 374, - 375, 376, 256, 378, 379, 327, 381, 382, 383, 384, - 385, 386, 387, 388, 389, 390, -1, 392, 393, 394, - 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, - 405, 406, 407, 408, 409, 410, 411, 412, 413, -1, - 256, -1, -1, -1, -1, 420, 262, -1, -1, -1, - -1, -1, -1, -1, 429, 377, 378, 379, 380, -1, - 382, 383, 384, 385, 386, 387, 388, 389, -1, -1, - 392, 393, 394, 395, 396, 397, 398, 399, -1, -1, - -1, -1, 298, -1, -1, 339, -1, -1, -1, -1, - 344, -1, 346, 347, 348, 349, 350, 351, 352, 353, - 354, 355, 356, -1, -1, -1, -1, -1, -1, -1, - -1, 256, -1, -1, 368, -1, 370, 262, 372, -1, - 374, 375, 376, 339, -1, -1, -1, -1, 344, -1, + 296, 297, -1, 342, -1, 301, 302, -1, -1, -1, + -1, 307, -1, 309, 310, 311, 312, -1, -1, -1, + -1, 317, -1, 362, -1, 321, -1, 323, 257, -1, + -1, -1, 261, -1, -1, -1, -1, 333, -1, -1, + 336, -1, 338, 272, -1, -1, 342, -1, 277, -1, + -1, -1, 281, -1, -1, 284, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 362, 296, 297, -1, + -1, -1, 301, 302, -1, 257, -1, -1, 307, 261, + 309, 310, 311, 312, -1, -1, -1, -1, 317, -1, + 272, -1, 321, -1, 323, 277, -1, -1, -1, 281, + -1, -1, 284, -1, 333, -1, -1, 336, -1, 338, + -1, -1, -1, 342, 296, 297, -1, -1, -1, 301, + 302, -1, -1, -1, -1, 307, -1, 309, 310, 311, + 312, -1, -1, 362, -1, 317, -1, -1, -1, 321, + -1, 323, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 333, -1, 256, 336, -1, 338, -1, -1, -1, + 342, 264, 265, 266, 267, -1, -1, 270, 271, -1, + 273, 274, 275, 276, 277, 278, 279, -1, -1, -1, + 362, -1, 285, -1, 287, 288, 289, 290, 291, 292, + -1, -1, 295, -1, -1, -1, 299, 300, -1, 302, + 303, 304, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 314, -1, 316, -1, 318, 319, -1, -1, 322, + -1, 324, 325, 326, 327, 328, 329, 330, 331, 332, + 333, 334, 335, -1, 337, -1, -1, 340, 341, -1, + 256, 344, 345, -1, -1, -1, 262, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 359, 360, 361, 362, + 363, -1, -1, -1, 367, -1, -1, -1, 371, -1, + -1, -1, -1, 376, 377, 378, 379, 380, -1, -1, + -1, 384, 298, 386, -1, -1, -1, -1, -1, 392, + 393, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 256, -1, -1, -1, + -1, -1, 262, -1, 417, 418, 419, 420, -1, -1, + -1, -1, -1, 339, -1, -1, 429, -1, 344, -1, 346, 347, 348, 349, 350, 351, 352, 353, 354, 355, - 356, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 367, 368, 298, 370, 371, 372, 373, 374, 375, + 356, 357, -1, -1, -1, -1, -1, 363, 298, -1, + -1, -1, 368, 369, 370, 371, 372, 373, 374, 375, 376, -1, 378, 379, -1, 381, 382, 383, 384, 385, - 386, 387, 388, 389, 390, 429, 392, 393, 394, 395, + 386, 387, 388, 389, 390, -1, 392, 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, 410, 411, 412, 413, -1, 256, - -1, -1, -1, -1, 420, 262, -1, 423, -1, -1, - -1, -1, -1, 429, -1, -1, -1, -1, 363, -1, - -1, -1, -1, -1, 369, -1, 371, 372, 373, 374, - -1, 376, -1, 378, 379, -1, 381, 382, 383, 384, - 385, 298, 387, 388, 389, 390, -1, 392, 393, 394, - 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, - 405, 406, 407, 408, 409, 410, 411, 412, 413, -1, - -1, -1, -1, 418, -1, 420, -1, -1, 423, -1, - -1, -1, 339, -1, 429, -1, -1, 344, -1, 346, + -1, -1, 418, -1, 420, 262, -1, 423, -1, -1, + -1, -1, -1, 429, -1, -1, -1, -1, 368, -1, + -1, 371, -1, 373, 374, -1, -1, -1, 378, 379, + -1, -1, 382, 383, 384, 385, 386, 387, 388, 389, + 390, 298, 392, 393, 394, 395, 396, 397, 398, 399, + 400, 401, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 412, 413, -1, -1, -1, -1, -1, -1, + 420, -1, -1, 423, -1, -1, -1, -1, -1, 429, + -1, 285, 339, -1, -1, -1, -1, 344, -1, 346, 347, 348, 349, 350, 351, 352, 353, 354, 355, 356, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 368, -1, 370, 371, 372, 373, 374, 375, 376, - 256, 378, 379, -1, 381, 382, 383, 384, 385, 386, + 367, 368, 369, 370, 371, 372, 373, 374, 375, 376, + 256, 378, 379, 327, 381, 382, 383, 384, 385, 386, 387, 388, 389, 390, -1, 392, 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, 410, 411, 412, 413, -1, 256, -1, - -1, -1, -1, 420, 262, -1, 423, -1, -1, -1, - -1, -1, 429, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 420, 262, -1, -1, -1, -1, -1, + -1, -1, 429, 377, 378, 379, 380, -1, 382, 383, + 384, 385, 386, 387, 388, 389, -1, -1, 392, 393, + 394, 395, 396, 397, 398, 399, -1, -1, -1, -1, 298, -1, -1, 339, -1, -1, -1, -1, 344, -1, 346, 347, 348, 349, 350, 351, 352, 353, 354, 355, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 368, -1, 370, -1, 372, -1, 374, 375, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 256, + -1, -1, 368, -1, 370, 262, 372, -1, 374, 375, 376, 339, -1, -1, -1, -1, 344, -1, 346, 347, 348, 349, 350, 351, 352, 353, 354, 355, 356, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 368, -1, 370, 371, 372, 373, 374, 375, 376, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 367, + 368, 298, 370, 371, 372, 373, 374, 375, 376, -1, 378, 379, -1, 381, 382, 383, 384, 385, 386, 387, 388, 389, 390, 429, 392, 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, - 408, 409, 410, 411, 412, 413, -1, 256, 256, -1, - -1, -1, 420, 262, -1, 423, -1, 265, -1, 267, - -1, 429, 270, -1, -1, -1, -1, 275, -1, -1, - -1, 279, -1, -1, -1, -1, -1, -1, -1, -1, - 288, -1, -1, -1, -1, -1, -1, 295, -1, 298, - -1, -1, 300, -1, -1, -1, 304, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 316, -1, - 318, -1, -1, -1, 322, -1, -1, -1, -1, -1, - -1, -1, 330, 331, -1, -1, 334, -1, -1, 337, - 339, -1, -1, -1, -1, 344, -1, 346, 347, 348, + 408, 409, 410, 411, 412, 413, -1, 256, -1, -1, + -1, -1, 420, 262, -1, 423, -1, -1, -1, -1, + -1, 429, -1, -1, -1, -1, 363, -1, -1, -1, + -1, 368, 369, -1, 371, 372, 373, 374, -1, 376, + -1, 378, 379, -1, 381, 382, 383, 384, 385, 298, + 387, 388, 389, 390, -1, 392, 393, 394, 395, 396, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 407, 408, 409, 410, 411, 412, 413, -1, -1, -1, + -1, 418, -1, 420, -1, -1, 423, -1, -1, -1, + 339, -1, 429, -1, -1, 344, -1, 346, 347, 348, 349, 350, 351, 352, 353, 354, 355, 356, -1, -1, - -1, -1, -1, -1, -1, 363, -1, -1, -1, 368, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 368, -1, 370, 371, 372, 373, 374, 375, 376, -1, 378, 379, -1, 381, 382, 383, 384, 385, 386, 387, 388, 389, 390, -1, 392, 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, 410, 411, 412, 413, -1, 256, 256, -1, -1, - 418, 420, 262, -1, 423, -1, 265, -1, 267, -1, + -1, 420, 262, -1, 423, -1, 265, -1, 267, -1, 429, 270, -1, -1, -1, -1, 275, -1, -1, -1, 279, -1, -1, -1, -1, -1, -1, -1, -1, 288, -1, -1, -1, -1, -1, -1, 295, -1, 298, -1, @@ -11515,281 +11826,253 @@ void case_961() -1, 330, 331, -1, -1, 334, -1, -1, 337, 339, -1, -1, -1, -1, 344, -1, 346, 347, 348, 349, 350, 351, 352, 353, 354, 355, 356, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 368, -1, - 370, 371, 372, 373, 374, 375, 376, -1, 378, -1, + -1, -1, -1, -1, 363, -1, -1, -1, 368, -1, + 370, 371, 372, 373, 374, 375, 376, -1, 378, 379, -1, 381, 382, 383, 384, 385, 386, 387, 388, 389, 390, -1, 392, 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, - 410, 411, 412, 413, -1, 256, -1, 261, -1, 418, - 420, 262, -1, 423, -1, -1, -1, -1, -1, 429, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 284, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 297, -1, -1, -1, 298, 302, -1, - -1, 305, -1, 307, -1, 309, 310, 311, 312, -1, - -1, -1, -1, 317, -1, -1, -1, 321, 256, -1, - -1, 325, -1, -1, 262, -1, -1, -1, 266, 333, - -1, -1, 336, -1, 338, -1, -1, -1, 339, -1, + 410, 411, 412, 413, -1, 256, 256, -1, -1, 418, + 420, 262, -1, 423, -1, 265, -1, 267, -1, 429, + 270, -1, -1, -1, -1, 275, -1, -1, -1, 279, + -1, -1, -1, -1, -1, -1, -1, -1, 288, -1, + -1, -1, -1, -1, -1, 295, -1, 298, -1, -1, + 300, -1, -1, -1, 304, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 316, -1, 318, -1, + -1, -1, 322, -1, -1, -1, -1, -1, -1, -1, + 330, 331, -1, -1, 334, -1, -1, 337, 339, -1, -1, -1, -1, 344, -1, 346, 347, 348, 349, 350, - 351, 352, 353, 354, 355, 356, -1, -1, 362, -1, - 298, -1, -1, -1, -1, -1, -1, 368, -1, 370, - -1, 372, -1, 374, 375, 376, 314, 378, 379, -1, + 351, 352, 353, 354, 355, 356, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 368, -1, 370, + 371, 372, 373, 374, 375, 376, -1, 378, 379, -1, 381, 382, 383, 384, 385, 386, 387, 388, 389, 390, - -1, -1, -1, 394, 395, 396, 397, 398, 399, 400, + -1, 392, 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, 410, - 411, 256, 413, -1, 418, -1, -1, 262, -1, 357, - -1, -1, -1, -1, -1, 363, -1, -1, 429, -1, - -1, 369, 370, 371, 372, 373, 374, 375, 376, -1, - 378, 379, -1, 381, 382, 383, 384, 385, 386, 387, - 388, 389, 390, 298, 392, 393, 394, 395, 396, 397, - 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, - 408, 409, 410, 411, 412, 413, -1, -1, -1, -1, - 418, -1, 420, -1, -1, 423, -1, -1, -1, -1, - -1, 429, -1, -1, 339, -1, -1, -1, -1, 344, - -1, 346, 347, 348, 349, 350, 351, 352, 353, 354, - 355, 356, -1, -1, -1, 256, -1, -1, -1, -1, - -1, 262, -1, 368, -1, 370, -1, 372, -1, 374, - 375, 376, -1, 378, 379, -1, -1, 382, 383, 384, - 385, 386, 387, 388, 389, 390, -1, -1, -1, 394, - 395, 396, 397, 398, 399, 400, 401, 298, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 413, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 256, 429, -1, -1, -1, -1, 262, - -1, -1, -1, -1, -1, -1, -1, -1, 339, -1, - -1, -1, -1, 344, -1, 346, 347, 348, 349, 350, - 351, 352, 353, 354, 355, 356, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 298, -1, 368, -1, 370, - -1, 372, -1, 374, 375, 376, -1, 378, 379, -1, - -1, 382, 383, 384, 385, -1, -1, -1, 389, 390, - -1, -1, -1, 394, 395, 396, 397, 398, 399, 400, - 401, -1, -1, -1, -1, -1, 339, -1, -1, -1, - -1, 344, 413, 346, 347, 348, 349, 350, 351, 352, - 353, 354, 355, 356, -1, -1, -1, 256, 429, -1, - -1, -1, -1, 262, -1, 368, -1, 370, -1, 372, - -1, 374, 375, 376, -1, 378, 379, -1, -1, 382, - 383, 384, 385, -1, -1, -1, 389, 390, -1, -1, - -1, 394, 395, 396, 397, 398, 399, 400, 401, 298, + 411, 412, 413, -1, 256, -1, 261, -1, 418, 420, + 262, -1, 423, -1, -1, -1, -1, -1, 429, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 284, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 413, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 256, 429, -1, -1, -1, - -1, 262, -1, -1, -1, -1, -1, -1, -1, -1, - 339, -1, -1, -1, -1, 344, -1, 346, 347, 348, - 349, 350, 351, 352, 353, 354, 355, 356, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 298, -1, 368, - -1, 370, -1, 372, -1, 374, 375, 376, -1, 378, - 379, -1, -1, 382, 383, 384, 385, -1, -1, -1, - 389, 390, -1, 256, -1, 394, 395, 396, 397, 398, - 399, 400, 401, -1, -1, -1, -1, -1, 339, -1, - -1, -1, -1, 344, 413, 346, 347, 348, 349, 350, - 351, 352, 353, 354, 355, 356, -1, -1, -1, -1, - 429, -1, -1, -1, -1, -1, -1, 368, -1, 370, - -1, 372, -1, 374, 375, 376, -1, 378, 379, -1, - -1, 382, 383, 384, 385, -1, -1, -1, 389, 390, - -1, 256, -1, 394, 395, 396, 397, 398, 399, 400, - 401, -1, -1, -1, -1, -1, 339, -1, -1, -1, - -1, 344, 413, 346, 347, 348, 349, 350, 351, 352, - 353, 354, 355, 356, -1, -1, -1, -1, 429, -1, - -1, -1, -1, -1, -1, 368, -1, 370, -1, 372, - -1, 374, 375, 376, -1, -1, -1, -1, -1, 382, - 383, 384, 385, -1, -1, -1, 389, 390, -1, 256, - -1, 394, 395, 396, 397, 398, 399, 400, 401, -1, - -1, -1, -1, -1, 339, -1, -1, -1, -1, 344, - 413, 346, 347, 348, 349, 350, 351, 352, 353, 354, - 355, 356, -1, -1, -1, -1, 429, -1, -1, -1, - -1, -1, -1, 368, -1, 370, -1, 372, -1, 374, - 375, 376, -1, -1, -1, -1, -1, 382, 383, 384, - 385, -1, -1, -1, 389, 390, -1, 256, -1, 394, - 395, 396, 397, 398, 399, 400, 401, -1, -1, -1, - -1, -1, 339, -1, -1, -1, -1, 344, 413, 346, - 347, 348, 349, 350, 351, 352, 353, 354, 355, 356, - -1, -1, -1, -1, 429, -1, -1, -1, -1, -1, - -1, 368, -1, 370, -1, 372, -1, 374, 375, 376, - -1, -1, -1, -1, -1, 382, 383, 384, 385, -1, - -1, -1, 389, 390, -1, 256, -1, 394, 395, 396, - 397, 398, 399, 400, 401, -1, -1, -1, -1, -1, - 339, -1, -1, -1, -1, 344, 413, 346, 347, 348, - 349, 350, 351, 352, 353, 354, 355, 356, -1, -1, - -1, -1, 429, -1, -1, -1, -1, -1, -1, 368, - -1, 370, -1, 372, -1, 374, 375, 376, -1, -1, - -1, -1, -1, 382, 383, 384, 385, -1, -1, -1, - 389, 390, -1, 256, -1, -1, -1, 396, 397, 398, - 399, 400, 401, -1, -1, -1, -1, -1, 339, -1, - -1, -1, -1, 344, 413, 346, 347, 348, 349, 350, - 351, 352, 353, 354, 355, 356, -1, -1, -1, -1, - 429, -1, -1, -1, -1, -1, -1, 368, -1, 370, - -1, 372, -1, 374, 375, 376, -1, -1, -1, -1, - -1, 382, 383, 384, 385, -1, -1, -1, 389, 390, - -1, 256, -1, -1, -1, 396, 397, 398, 399, 400, - 401, -1, -1, -1, -1, -1, 339, -1, -1, -1, - -1, 344, 413, 346, 347, 348, 349, 350, 351, 352, - 353, 354, 355, 356, -1, -1, -1, -1, 429, -1, - -1, -1, -1, -1, -1, 368, -1, 370, -1, 372, - -1, 374, 375, 376, -1, -1, -1, -1, -1, 382, - 383, 384, 385, -1, -1, -1, 389, 390, -1, 256, - -1, -1, -1, 396, 397, 398, 399, 400, 401, -1, - -1, -1, -1, -1, 339, -1, -1, -1, -1, 344, - 413, 346, 347, 348, 349, 350, 351, 352, 353, 354, - 355, 356, -1, -1, -1, -1, 429, -1, -1, -1, - -1, -1, -1, 368, -1, 370, -1, 372, -1, 374, - 375, 376, -1, -1, -1, -1, -1, 382, 383, 384, - 385, -1, -1, -1, 389, 390, -1, 256, -1, -1, - -1, 396, 397, 398, 399, 400, 401, -1, -1, -1, - -1, -1, 339, -1, -1, -1, -1, 344, 413, 346, - 347, 348, 349, 350, 351, 352, 353, 354, 355, 356, - -1, -1, -1, -1, 429, -1, -1, -1, -1, -1, - -1, 368, -1, 370, -1, 372, -1, 374, 375, 376, - -1, -1, -1, -1, -1, 382, 383, 384, 385, -1, - -1, -1, 389, 390, -1, 256, -1, -1, -1, 396, - 397, 398, 399, 400, 401, -1, -1, -1, -1, -1, - 339, -1, -1, -1, -1, 344, 413, 346, 347, 348, - 349, 350, 351, 352, 353, 354, 355, 356, -1, -1, - -1, -1, 429, -1, -1, -1, -1, -1, -1, 368, - -1, 370, -1, 372, -1, 374, 375, 376, -1, -1, - -1, -1, -1, -1, -1, 384, 385, -1, -1, -1, - 389, 390, -1, 256, -1, -1, -1, -1, -1, 398, - 399, 400, 401, -1, -1, -1, -1, -1, 339, -1, - -1, -1, -1, 344, 413, 346, 347, 348, 349, 350, - 351, 352, 353, 354, 355, 356, -1, -1, -1, -1, - 429, -1, -1, -1, -1, -1, -1, 368, -1, 370, - -1, 372, -1, 374, 375, 376, -1, -1, -1, -1, - -1, -1, -1, 384, 385, -1, -1, -1, 389, 390, - -1, 256, -1, -1, -1, -1, -1, 398, 399, 400, - 401, -1, -1, -1, -1, -1, 339, -1, -1, -1, - -1, 344, 413, 346, 347, 348, 349, 350, 351, 352, - 353, 354, 355, 356, -1, -1, -1, -1, 429, -1, - -1, -1, -1, -1, -1, 368, -1, 370, -1, 372, - -1, 374, 375, 376, -1, -1, -1, -1, -1, -1, - -1, 384, 385, -1, -1, -1, 389, 390, -1, 256, - -1, -1, -1, -1, -1, 398, 399, 400, 401, -1, - -1, -1, -1, -1, 339, -1, -1, -1, -1, 344, - 413, 346, 347, 348, 349, 350, 351, 352, 353, 354, - 355, 356, -1, -1, -1, -1, 429, -1, -1, -1, - -1, -1, -1, 368, -1, 370, -1, 372, -1, 374, - 375, 376, -1, -1, -1, -1, -1, -1, -1, 384, - 385, -1, -1, -1, 389, 390, -1, 256, -1, -1, - -1, -1, -1, -1, -1, 400, 401, -1, -1, -1, - -1, -1, 339, -1, -1, -1, -1, 344, 413, 346, - 347, 348, 349, 350, 351, 352, 353, 354, 355, 356, - -1, -1, -1, -1, 429, -1, -1, -1, -1, -1, - -1, 368, -1, 370, -1, 372, -1, 374, 375, 376, - -1, -1, -1, -1, -1, -1, -1, 384, 385, -1, - -1, -1, 389, 390, -1, 256, -1, -1, -1, -1, - -1, -1, -1, 400, 401, -1, -1, -1, -1, -1, - 339, -1, -1, -1, -1, 344, 413, 346, 347, 348, - 349, 350, 351, 352, 353, 354, 355, 356, -1, -1, - -1, -1, 429, -1, -1, -1, -1, -1, -1, 368, - -1, 370, -1, 372, -1, 374, 375, 376, -1, -1, - -1, -1, -1, -1, -1, -1, 385, -1, -1, -1, - 389, 390, -1, 256, -1, -1, -1, -1, -1, -1, - -1, 400, 401, -1, -1, -1, -1, -1, 339, -1, - -1, -1, -1, 344, 413, 346, 347, 348, 349, 350, - 351, 352, 353, 354, 355, 356, -1, -1, -1, -1, - 429, -1, -1, -1, -1, -1, -1, 368, -1, 370, - -1, 372, -1, 374, 375, 376, -1, -1, -1, -1, - -1, -1, -1, -1, 385, -1, -1, -1, 389, 390, - -1, 256, -1, -1, -1, -1, -1, -1, -1, 400, - 401, -1, -1, -1, -1, -1, 339, -1, -1, -1, - -1, 344, 413, 346, 347, 348, 349, 350, 351, 352, - 353, 354, 355, 356, -1, -1, -1, -1, 429, -1, - -1, -1, -1, -1, -1, 368, -1, 370, -1, 372, - -1, 374, 375, 376, -1, -1, -1, -1, -1, -1, - -1, -1, 385, -1, -1, -1, -1, 390, -1, 256, - -1, -1, -1, -1, -1, -1, -1, 400, 401, -1, - -1, -1, -1, -1, 339, -1, -1, -1, -1, 344, - 413, 346, 347, 348, 349, 350, 351, 352, 353, 354, - 355, 356, -1, -1, -1, -1, 429, -1, -1, -1, - -1, -1, -1, 368, -1, 370, -1, 372, -1, 374, - 375, 376, -1, -1, -1, -1, -1, -1, -1, -1, - 385, -1, -1, -1, -1, 390, -1, 256, -1, -1, - -1, -1, -1, -1, -1, 400, 401, -1, -1, -1, - -1, -1, 339, -1, -1, -1, -1, 344, 413, 346, - 347, 348, 349, 350, 351, 352, 353, 354, 355, 356, - -1, -1, -1, -1, 429, -1, -1, -1, -1, -1, - -1, 368, -1, 370, -1, 372, -1, 374, 375, 376, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 390, -1, 256, -1, -1, -1, -1, - -1, -1, -1, 400, 401, -1, -1, -1, -1, -1, - 339, -1, -1, -1, -1, 344, 413, 346, 347, 348, - 349, 350, 351, 352, 353, 354, 355, 356, -1, -1, - -1, -1, 429, -1, -1, -1, -1, -1, -1, 368, - -1, 370, -1, 372, -1, 374, 375, 376, -1, -1, - -1, 256, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 390, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 400, 401, -1, -1, -1, -1, -1, 339, -1, - -1, -1, -1, 344, 413, 346, 347, 348, 349, 350, - 351, 352, 353, 354, 355, 356, -1, -1, -1, -1, - 429, -1, -1, -1, -1, -1, -1, 368, -1, 370, - -1, 372, -1, 374, 375, 376, -1, -1, -1, 256, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 390, - -1, -1, -1, -1, 339, -1, -1, -1, -1, 344, - 401, 346, 347, 348, 349, 350, 351, 352, 353, 354, - 355, 356, 413, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 368, -1, 370, -1, 372, 429, 374, - 375, 376, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 262, 390, -1, -1, 266, -1, - -1, -1, -1, -1, -1, -1, 401, -1, -1, -1, - -1, -1, 339, -1, -1, -1, -1, 344, 413, 346, - 347, 348, 349, 350, 351, 352, 353, 354, 355, 356, - 298, -1, -1, -1, 429, -1, -1, -1, -1, -1, - -1, 368, -1, 370, -1, 372, 314, 374, 375, 376, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 390, -1, -1, -1, -1, -1, -1, + -1, -1, 297, -1, -1, -1, 298, 302, -1, -1, + -1, -1, 307, -1, 309, 310, 311, 312, -1, -1, + -1, -1, 317, -1, -1, -1, 321, -1, -1, 256, + 325, -1, -1, -1, -1, 262, -1, -1, 333, 266, + -1, 336, -1, 338, -1, -1, -1, 339, -1, -1, + -1, -1, 344, -1, 346, 347, 348, 349, 350, 351, + 352, 353, 354, 355, 356, -1, -1, 362, -1, -1, + -1, 298, -1, -1, -1, -1, 368, -1, 370, 371, + 372, 373, 374, 375, 376, -1, 378, 314, -1, 381, + 382, 383, 384, 385, 386, 387, 388, 389, 390, -1, + 392, 393, 394, 395, 396, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 407, 408, 409, 410, 411, + 412, 413, -1, 418, -1, -1, -1, -1, 420, -1, + 357, 423, -1, -1, -1, -1, 363, 429, -1, -1, + -1, 368, 369, 370, 371, 372, 373, 374, 375, 376, + -1, 378, 379, -1, 381, 382, 383, 384, 385, 386, + 387, 388, 389, 390, -1, 392, 393, 394, 395, 396, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 407, 408, 409, 410, 411, 412, 413, -1, 256, -1, + 256, 418, -1, 420, 262, -1, 423, -1, 264, 265, + -1, 267, 429, -1, 270, 271, -1, -1, -1, 275, + 276, 277, -1, 279, -1, -1, -1, -1, -1, 285, + -1, -1, 288, -1, -1, -1, -1, -1, -1, 295, + 298, -1, -1, -1, 300, -1, 302, 303, 304, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 357, - -1, -1, -1, -1, -1, 363, -1, -1, -1, -1, - -1, 369, 429, 371, -1, 373, -1, 375, 376, -1, + 316, -1, 318, 319, -1, -1, 322, -1, -1, 325, + -1, 327, -1, 329, 330, 331, 332, -1, 334, -1, + -1, 339, -1, -1, -1, -1, 344, -1, 346, 347, + 348, 349, 350, 351, 352, 353, 354, 355, 356, -1, + -1, -1, -1, 359, 360, 361, 362, -1, -1, -1, + 368, -1, 370, -1, 372, 371, 374, 375, 376, -1, 378, 379, -1, 381, 382, 383, 384, 385, 386, 387, - 388, 389, 390, -1, 392, 393, 394, 395, 396, 397, + 388, 389, 390, 261, -1, -1, 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, - 408, 409, 410, 411, 412, 413, -1, -1, 256, -1, - 418, -1, 420, -1, -1, 423, 264, 265, 266, 267, - -1, 429, 270, 271, -1, 273, 274, 275, 276, 277, - 278, 279, -1, -1, -1, -1, -1, 285, -1, 287, - 288, 289, 290, 291, 292, -1, -1, 295, -1, -1, - -1, 299, 300, -1, 302, 303, 304, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 314, -1, 316, -1, - 318, 319, -1, -1, 322, -1, 324, 325, 326, 327, - 328, 329, 330, 331, 332, 333, 334, 335, -1, 337, - -1, -1, 340, 341, -1, -1, 344, 345, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 359, 360, 361, 362, 363, -1, -1, -1, 367, - -1, -1, -1, 371, -1, -1, -1, -1, 376, 377, - 378, 379, 380, -1, -1, -1, 384, -1, 386, -1, - -1, -1, -1, -1, 392, 393, -1, -1, -1, -1, + 408, 409, 410, 411, 256, 413, 284, -1, -1, -1, + 262, 417, 418, -1, -1, -1, -1, -1, -1, 297, + -1, 429, -1, -1, 302, -1, -1, -1, -1, 307, + -1, 309, 310, 311, 312, -1, -1, -1, -1, 317, + -1, -1, -1, 321, -1, -1, 298, -1, -1, -1, + -1, -1, -1, -1, -1, 333, -1, -1, 336, -1, + 338, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 256, -1, -1, -1, -1, -1, 262, -1, + -1, -1, -1, -1, 362, -1, -1, 339, -1, -1, + -1, -1, 344, -1, 346, 347, 348, 349, 350, 351, + 352, 353, 354, 355, 356, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 298, -1, 368, -1, 370, -1, + 372, -1, 374, 375, 376, -1, 378, 379, -1, -1, + 382, 383, 384, 385, 386, 387, 388, 389, 390, -1, + 418, -1, 394, 395, 396, 397, 398, 399, 400, 401, + -1, -1, -1, -1, -1, 339, -1, -1, -1, -1, + 344, 413, 346, 347, 348, 349, 350, 351, 352, 353, + 354, 355, 356, -1, -1, -1, 256, 429, -1, -1, + -1, -1, 262, -1, 368, -1, 370, -1, 372, -1, + 374, 375, 376, -1, 378, 379, -1, -1, 382, 383, + 384, 385, -1, -1, -1, 389, 390, -1, -1, -1, + 394, 395, 396, 397, 398, 399, 400, 401, 298, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 413, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 256, -1, -1, -1, 417, - 418, 419, 420, 264, 265, 266, 267, -1, -1, 270, - 271, -1, 273, 274, 275, 276, 277, 278, 279, -1, - -1, -1, -1, -1, 285, -1, 287, 288, 289, 290, - 291, 292, -1, -1, 295, -1, -1, -1, 299, 300, - -1, 302, 303, 304, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 314, -1, 316, -1, 318, 319, -1, - -1, 322, -1, 324, 325, 326, 327, 328, 329, 330, - 331, 332, 333, 334, 335, -1, 337, -1, -1, 340, - 341, -1, -1, 344, 345, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 359, 360, - 361, 362, 363, -1, -1, -1, 367, -1, -1, -1, - 371, -1, -1, -1, -1, 376, 377, 378, 379, 380, - -1, -1, -1, 384, -1, 386, -1, -1, -1, -1, - -1, 392, 393, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 256, 429, -1, -1, -1, -1, + 262, -1, -1, -1, -1, -1, -1, -1, -1, 339, + -1, -1, -1, -1, 344, -1, 346, 347, 348, 349, + 350, 351, 352, 353, 354, 355, 356, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 298, -1, 368, -1, + 370, -1, 372, -1, 374, 375, 376, -1, 378, 379, + -1, -1, 382, 383, 384, 385, -1, -1, -1, 389, + 390, -1, -1, -1, 394, 395, 396, 397, 398, 399, + 400, 401, -1, -1, -1, -1, -1, 339, -1, -1, + -1, -1, 344, 413, 346, 347, 348, 349, 350, 351, + 352, 353, 354, 355, 356, -1, -1, -1, 256, 429, + -1, -1, -1, -1, 262, -1, 368, -1, 370, -1, + 372, -1, 374, 375, 376, -1, 378, 379, -1, -1, + 382, 383, 384, 385, -1, -1, -1, 389, 390, -1, + -1, -1, 394, 395, 396, 397, 398, 399, 400, 401, + 298, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 413, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 256, 429, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 256, -1, -1, -1, 417, 418, 419, 420, - 264, 265, 266, 267, -1, -1, 270, 271, -1, 273, - 274, 275, 276, 277, 278, 279, -1, -1, -1, -1, - -1, 285, -1, 287, 288, 289, 290, 291, 292, -1, - -1, 295, -1, -1, -1, 299, 300, -1, 302, 303, - 304, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 314, -1, 316, -1, 318, 319, -1, -1, 322, -1, - 324, 325, 326, 327, 328, 329, 330, 331, 332, 333, - 334, 335, -1, 337, -1, -1, 340, 341, -1, -1, - 344, 345, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 359, 360, 361, 362, 363, - -1, -1, -1, 367, -1, -1, -1, 371, -1, -1, - -1, -1, 376, 377, 378, 379, 380, -1, -1, -1, - 384, -1, 386, -1, -1, -1, -1, -1, 392, 393, + -1, 339, -1, -1, -1, -1, 344, -1, 346, 347, + 348, 349, 350, 351, 352, 353, 354, 355, 356, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 256, - -1, -1, -1, 417, 418, 419, 420, 264, 265, 266, - 267, -1, -1, 270, 271, -1, 273, 274, 275, 276, + 368, -1, 370, -1, 372, -1, 374, 375, 376, -1, + 378, 379, -1, -1, 382, 383, 384, 385, -1, -1, + -1, 389, 390, -1, 256, -1, 394, 395, 396, 397, + 398, 399, 400, 401, -1, -1, -1, -1, -1, 339, + -1, -1, -1, -1, 344, 413, 346, 347, 348, 349, + 350, 351, 352, 353, 354, 355, 356, -1, -1, -1, + -1, 429, -1, -1, -1, -1, -1, -1, 368, -1, + 370, -1, 372, -1, 374, 375, 376, -1, -1, -1, + -1, -1, 382, 383, 384, 385, -1, -1, -1, 389, + 390, -1, 256, -1, 394, 395, 396, 397, 398, 399, + 400, 401, -1, -1, -1, -1, -1, 339, -1, -1, + -1, -1, 344, 413, 346, 347, 348, 349, 350, 351, + 352, 353, 354, 355, 356, -1, -1, -1, -1, 429, + -1, -1, -1, -1, -1, -1, 368, -1, 370, -1, + 372, -1, 374, 375, 376, -1, -1, -1, -1, -1, + 382, 383, 384, 385, -1, -1, -1, 389, 390, -1, + 256, -1, 394, 395, 396, 397, 398, 399, 400, 401, + -1, -1, -1, -1, -1, 339, -1, -1, -1, -1, + 344, 413, 346, 347, 348, 349, 350, 351, 352, 353, + 354, 355, 356, -1, -1, -1, -1, 429, -1, -1, + -1, -1, -1, -1, 368, -1, 370, -1, 372, -1, + 374, 375, 376, -1, -1, -1, -1, -1, 382, 383, + 384, 385, -1, -1, -1, 389, 390, -1, 256, -1, + 394, 395, 396, 397, 398, 399, 400, 401, -1, -1, + -1, -1, -1, 339, -1, -1, -1, -1, 344, 413, + 346, 347, 348, 349, 350, 351, 352, 353, 354, 355, + 356, -1, -1, -1, -1, 429, -1, -1, -1, -1, + -1, -1, 368, -1, 370, -1, 372, -1, 374, 375, + 376, -1, -1, -1, -1, -1, 382, 383, 384, 385, + -1, -1, -1, 389, 390, -1, 256, -1, -1, -1, + 396, 397, 398, 399, 400, 401, -1, -1, -1, -1, + -1, 339, -1, -1, -1, -1, 344, 413, 346, 347, + 348, 349, 350, 351, 352, 353, 354, 355, 356, -1, + -1, -1, -1, 429, -1, -1, -1, -1, -1, -1, + 368, -1, 370, -1, 372, -1, 374, 375, 376, -1, + -1, -1, -1, -1, 382, 383, 384, 385, -1, -1, + -1, 389, 390, -1, 256, -1, -1, -1, 396, 397, + 398, 399, 400, 401, -1, -1, -1, -1, -1, 339, + -1, -1, -1, -1, 344, 413, 346, 347, 348, 349, + 350, 351, 352, 353, 354, 355, 356, -1, -1, -1, + -1, 429, -1, -1, -1, -1, -1, -1, 368, -1, + 370, -1, 372, -1, 374, 375, 376, -1, -1, -1, + -1, -1, 382, 383, 384, 385, -1, -1, -1, 389, + 390, -1, 256, -1, -1, -1, 396, 397, 398, 399, + 400, 401, -1, -1, -1, -1, -1, 339, -1, -1, + -1, -1, 344, 413, 346, 347, 348, 349, 350, 351, + 352, 353, 354, 355, 356, -1, -1, -1, -1, 429, + -1, -1, -1, -1, -1, -1, 368, -1, 370, -1, + 372, -1, 374, 375, 376, -1, -1, -1, -1, -1, + 382, 383, 384, 385, -1, -1, -1, 389, 390, -1, + 256, -1, -1, -1, 396, 397, 398, 399, 400, 401, + -1, -1, -1, -1, -1, 339, -1, -1, -1, -1, + 344, 413, 346, 347, 348, 349, 350, 351, 352, 353, + 354, 355, 356, -1, -1, -1, -1, 429, -1, -1, + -1, -1, -1, -1, 368, -1, 370, -1, 372, -1, + 374, 375, 376, -1, -1, -1, -1, -1, 382, 383, + 384, 385, -1, -1, -1, 389, 390, -1, 256, -1, + -1, -1, 396, 397, 398, 399, 400, 401, -1, -1, + -1, -1, -1, 339, -1, -1, -1, -1, 344, 413, + 346, 347, 348, 349, 350, 351, 352, 353, 354, 355, + 356, -1, -1, -1, -1, 429, -1, -1, -1, -1, + -1, -1, 368, -1, 370, -1, 372, -1, 374, 375, + 376, -1, -1, -1, -1, -1, -1, -1, 384, 385, + -1, -1, -1, 389, 390, -1, 256, -1, -1, -1, + -1, -1, 398, 399, 400, 401, -1, -1, -1, -1, + -1, 339, -1, -1, -1, -1, 344, 413, 346, 347, + 348, 349, 350, 351, 352, 353, 354, 355, 356, -1, + -1, -1, -1, 429, -1, -1, -1, -1, -1, -1, + 368, -1, 370, -1, 372, -1, 374, 375, 376, -1, + -1, -1, -1, -1, -1, -1, 384, 385, -1, -1, + -1, 389, 390, -1, 256, -1, -1, -1, -1, -1, + 398, 399, 400, 401, -1, -1, -1, -1, -1, 339, + -1, -1, -1, -1, 344, 413, 346, 347, 348, 349, + 350, 351, 352, 353, 354, 355, 356, -1, -1, -1, + -1, 429, -1, -1, -1, -1, -1, -1, 368, -1, + 370, -1, 372, -1, 374, 375, 376, -1, -1, -1, + -1, -1, -1, -1, 384, 385, -1, -1, -1, 389, + 390, -1, 256, -1, -1, -1, -1, -1, 398, 399, + 400, 401, -1, -1, -1, -1, -1, 339, -1, -1, + -1, -1, 344, 413, 346, 347, 348, 349, 350, 351, + 352, 353, 354, 355, 356, -1, -1, -1, -1, 429, + -1, -1, -1, -1, -1, -1, 368, -1, 370, -1, + 372, -1, 374, 375, 376, -1, -1, -1, -1, -1, + -1, -1, 384, 385, -1, -1, -1, 389, 390, -1, + 256, -1, -1, -1, -1, -1, -1, -1, 400, 401, + -1, -1, -1, -1, -1, 339, -1, -1, -1, -1, + 344, 413, 346, 347, 348, 349, 350, 351, 352, 353, + 354, 355, 356, -1, -1, -1, -1, 429, -1, -1, + -1, -1, -1, -1, 368, -1, 370, -1, 372, -1, + 374, 375, 376, -1, -1, -1, -1, -1, -1, -1, + 384, 385, -1, -1, -1, 389, 390, -1, 256, -1, + -1, -1, -1, -1, -1, -1, 400, 401, -1, -1, + -1, -1, -1, 339, -1, -1, -1, -1, 344, 413, + 346, 347, 348, 349, 350, 351, 352, 353, 354, 355, + 356, -1, -1, -1, -1, 429, -1, -1, -1, -1, + -1, -1, 368, -1, 370, -1, 372, -1, 374, 375, + 376, -1, -1, -1, -1, -1, -1, -1, -1, 385, + -1, -1, -1, 389, 390, -1, 256, -1, -1, -1, + -1, -1, -1, -1, 400, 401, -1, -1, -1, -1, + -1, 339, -1, -1, -1, -1, 344, 413, 346, 347, + 348, 349, 350, 351, 352, 353, 354, 355, 356, -1, + -1, -1, -1, 429, -1, -1, -1, -1, -1, -1, + 368, -1, 370, -1, 372, -1, 374, 375, 376, -1, + -1, -1, -1, -1, -1, -1, -1, 385, -1, -1, + -1, 389, 390, -1, 256, -1, -1, -1, -1, -1, + -1, -1, 400, 401, -1, -1, -1, -1, -1, 339, + -1, -1, -1, -1, 344, 413, 346, 347, 348, 349, + 350, 351, 352, 353, 354, 355, 356, -1, -1, -1, + -1, 429, -1, -1, -1, -1, -1, -1, 368, -1, + 370, -1, 372, -1, 374, 375, 376, -1, -1, -1, + -1, -1, -1, -1, -1, 385, -1, -1, -1, -1, + 390, -1, 256, -1, -1, -1, -1, -1, -1, -1, + 400, 401, -1, -1, -1, -1, -1, 339, -1, -1, + -1, -1, 344, 413, 346, 347, 348, 349, 350, 351, + 352, 353, 354, 355, 356, -1, -1, -1, -1, 429, + -1, -1, -1, -1, -1, -1, 368, -1, 370, -1, + 372, -1, 374, 375, 376, -1, -1, -1, -1, -1, + -1, -1, -1, 385, -1, -1, -1, -1, 390, -1, + 256, -1, -1, -1, -1, -1, -1, -1, 400, 401, + -1, -1, -1, -1, -1, 339, -1, -1, -1, -1, + 344, 413, 346, 347, 348, 349, 350, 351, 352, 353, + 354, 355, 356, -1, -1, -1, -1, 429, -1, -1, + -1, -1, -1, -1, 368, -1, 370, -1, 372, -1, + 374, 375, 376, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 262, 390, -1, -1, 266, + -1, -1, -1, -1, -1, -1, 400, 401, -1, -1, + -1, -1, -1, 339, -1, -1, -1, -1, 344, 413, + 346, 347, 348, 349, 350, 351, 352, 353, 354, 355, + 356, 298, -1, -1, -1, 429, -1, -1, -1, -1, + -1, -1, 368, -1, 370, -1, 372, 314, 374, 375, + 376, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 390, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 400, 401, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 413, -1, -1, + 357, -1, -1, -1, -1, -1, 363, -1, -1, -1, + -1, 368, 369, 429, 371, -1, 373, -1, 375, 376, + -1, 378, 379, -1, 381, 382, 383, 384, 385, 386, + 387, 388, 389, 390, -1, 392, 393, 394, 395, 396, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 407, 408, 409, 410, 411, 412, 413, -1, -1, 256, + -1, 418, -1, 420, -1, -1, 423, 264, 265, 266, + 267, -1, 429, 270, 271, -1, 273, 274, 275, 276, 277, 278, 279, -1, -1, -1, -1, -1, 285, -1, 287, 288, 289, 290, 291, 292, -1, -1, 295, -1, -1, -1, 299, 300, -1, 302, 303, 304, -1, -1, @@ -11820,114 +12103,55 @@ void case_961() -1, -1, 392, 393, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 256, -1, -1, -1, 417, 418, 419, - 420, 264, 265, -1, 267, -1, -1, 270, 271, -1, - 256, -1, 275, 276, 277, -1, 279, -1, -1, 265, - -1, 267, 285, -1, 270, 288, -1, -1, -1, 275, - -1, -1, 295, 279, -1, -1, -1, 300, -1, 302, - 303, 304, 288, -1, -1, -1, -1, -1, -1, 295, - -1, -1, -1, 316, 300, 318, 319, -1, 304, 322, - -1, -1, 325, -1, 327, -1, 329, 330, 331, 332, - 316, 334, 318, -1, -1, -1, 322, -1, 341, -1, - -1, 344, 345, -1, 330, 331, -1, -1, 334, -1, - -1, 337, -1, -1, -1, -1, 359, 360, 361, 362, - 363, -1, -1, -1, 367, 368, -1, -1, 371, -1, - -1, -1, -1, -1, 377, 378, 379, 380, -1, -1, + 420, 264, 265, 266, 267, -1, -1, 270, 271, -1, + 273, 274, 275, 276, 277, 278, 279, -1, -1, -1, + -1, -1, 285, -1, 287, 288, 289, 290, 291, 292, + -1, -1, 295, -1, -1, -1, 299, 300, -1, 302, + 303, 304, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 314, -1, 316, -1, 318, 319, -1, -1, 322, + -1, 324, 325, 326, 327, 328, 329, 330, 331, 332, + 333, 334, 335, -1, 337, -1, -1, 340, 341, -1, + -1, 344, 345, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 359, 360, 361, 362, + 363, -1, -1, -1, 367, -1, -1, -1, 371, -1, + -1, -1, -1, 376, 377, 378, 379, 380, -1, -1, -1, 384, -1, 386, -1, -1, -1, -1, -1, 392, 393, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 256, -1, -1, -1, 417, 418, 419, 420, 264, 265, - -1, 267, -1, -1, 270, 271, -1, 256, -1, 275, - 276, 277, 418, 279, -1, -1, 265, -1, 267, 285, - -1, 270, 288, -1, -1, -1, 275, -1, -1, 295, - 279, -1, -1, -1, 300, -1, 302, 303, 304, 288, - -1, -1, -1, -1, -1, -1, 295, -1, -1, -1, - 316, 300, 318, 319, 320, 304, 322, -1, -1, 325, - -1, 327, -1, 329, 330, 331, 332, 316, 334, 318, - -1, -1, -1, 322, -1, 341, -1, -1, 344, 345, - -1, 330, 331, -1, -1, 334, -1, -1, 337, -1, + 266, 267, -1, -1, 270, 271, -1, 273, 274, 275, + 276, 277, 278, 279, -1, -1, -1, -1, -1, 285, + -1, 287, 288, 289, 290, 291, 292, -1, -1, 295, + -1, -1, -1, 299, 300, -1, 302, 303, 304, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 314, -1, + 316, -1, 318, 319, -1, -1, 322, -1, 324, 325, + 326, 327, 328, 329, 330, 331, 332, 333, 334, 335, + -1, 337, -1, -1, 340, 341, -1, -1, 344, 345, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 359, 360, 361, 362, 363, -1, -1, -1, 367, -1, -1, -1, 371, -1, -1, -1, -1, - -1, 377, 378, 379, 380, -1, -1, -1, 384, -1, + 376, 377, 378, 379, 380, -1, -1, -1, 384, -1, 386, -1, -1, -1, -1, -1, 392, 393, -1, -1, - -1, -1, -1, -1, 264, 265, -1, 267, -1, -1, - 270, 271, -1, -1, -1, 275, 276, 277, -1, 279, - -1, 417, 418, 419, 420, 285, -1, -1, 288, -1, - -1, -1, -1, -1, -1, 295, -1, -1, -1, 418, - 300, -1, 302, 303, 304, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 316, -1, 318, 319, - -1, -1, 322, -1, -1, 325, -1, 327, -1, 329, - 330, 331, 332, -1, 334, -1, -1, -1, -1, -1, - -1, 341, -1, -1, 344, 345, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 359, - 360, 361, 362, 363, -1, -1, -1, 367, 368, -1, - -1, 371, -1, -1, -1, -1, -1, 377, 378, 379, - 380, -1, -1, -1, 384, -1, 386, -1, -1, -1, - -1, -1, 392, 393, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 256, -1, 417, 418, 419, - 420, -1, -1, 264, 265, -1, 267, -1, 428, 270, - 271, -1, -1, -1, 275, 276, 277, -1, 279, -1, - -1, 265, -1, 267, 285, -1, 270, 288, -1, -1, - -1, 275, -1, -1, 295, 279, -1, -1, -1, 300, - -1, 302, 303, 304, 288, -1, -1, -1, -1, -1, - -1, 295, -1, -1, -1, 316, 300, 318, 319, 320, - 304, 322, -1, -1, 325, -1, 327, -1, 329, 330, - 331, 332, 316, 334, 318, -1, -1, -1, 322, -1, - 341, -1, -1, 344, 345, -1, 330, 331, -1, -1, - 334, -1, -1, 337, -1, -1, -1, -1, 359, 360, - 361, 362, 363, -1, -1, -1, 367, -1, -1, -1, - 371, -1, -1, -1, -1, -1, 377, 378, 379, 380, - -1, -1, -1, 384, -1, 386, -1, -1, 372, -1, - -1, 392, 393, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 256, -1, -1, -1, 417, 418, 419, 420, - 264, 265, -1, 267, -1, -1, 270, 271, -1, -1, - -1, 275, 276, 277, 418, 279, -1, -1, 265, -1, - 267, 285, -1, 270, 288, -1, -1, -1, 275, -1, - -1, 295, 279, -1, -1, -1, 300, -1, 302, 303, - 304, 288, -1, -1, -1, -1, -1, -1, 295, -1, - -1, -1, 316, 300, 318, 319, -1, 304, 322, -1, - -1, 325, -1, 327, -1, 329, 330, 331, 332, 316, - 334, 318, -1, 337, -1, 322, -1, 341, -1, -1, - 344, 345, -1, 330, 331, -1, -1, 334, -1, -1, - 337, -1, -1, -1, -1, 359, 360, 361, 362, 363, - -1, -1, -1, -1, -1, -1, -1, 371, -1, -1, - -1, -1, -1, 377, 378, 379, 380, -1, -1, -1, - 384, -1, 386, 370, -1, -1, -1, -1, 392, 393, - -1, -1, -1, -1, -1, -1, 264, 265, -1, 267, - -1, -1, 270, 271, -1, -1, -1, 275, 276, 277, - -1, 279, -1, 417, 418, 419, 420, 285, -1, -1, - 288, -1, -1, -1, -1, -1, -1, 295, -1, -1, - -1, 418, 300, -1, 302, 303, 304, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 316, -1, - 318, 319, -1, -1, 322, -1, -1, 325, -1, 327, - -1, 329, 330, 331, 332, -1, 334, -1, -1, -1, - -1, -1, -1, 341, -1, -1, 344, 345, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 359, 360, 361, 362, 363, -1, -1, -1, 367, - -1, -1, -1, 371, -1, -1, -1, -1, -1, 377, - 378, 379, 380, -1, -1, -1, 384, -1, 386, -1, - -1, -1, -1, -1, 392, 393, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 256, -1, -1, + -1, 417, 418, 419, 420, 264, 265, 266, 267, -1, + -1, 270, 271, -1, 273, 274, 275, 276, 277, 278, + 279, -1, -1, -1, -1, -1, 285, -1, 287, 288, + 289, 290, 291, 292, -1, -1, 295, -1, -1, -1, + 299, 300, -1, 302, 303, 304, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 314, -1, 316, -1, 318, + 319, -1, -1, 322, -1, 324, 325, 326, 327, 328, + 329, 330, 331, 332, 333, 334, 335, -1, 337, -1, + -1, 340, 341, -1, -1, 344, 345, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 256, -1, 417, - 418, 419, 420, -1, -1, 264, 265, -1, 267, -1, - 428, 270, 271, -1, -1, -1, 275, 276, 277, -1, - 279, -1, -1, 265, -1, 267, 285, -1, 270, 288, - -1, -1, -1, 275, -1, -1, 295, 279, -1, -1, - -1, 300, -1, 302, 303, 304, 288, -1, -1, -1, - -1, -1, -1, 295, -1, -1, -1, 316, 300, 318, - 319, -1, 304, 322, -1, -1, 325, -1, 327, -1, - 329, 330, 331, 332, 316, 334, 318, -1, -1, -1, - 322, -1, 341, -1, -1, 344, 345, -1, 330, 331, - -1, -1, 334, -1, -1, 337, -1, -1, -1, -1, 359, 360, 361, 362, 363, -1, -1, -1, 367, -1, - -1, -1, 371, -1, -1, -1, -1, -1, 377, 378, + -1, -1, 371, -1, -1, -1, -1, 376, 377, 378, 379, 380, -1, -1, -1, 384, -1, 386, -1, -1, -1, -1, -1, 392, 393, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 256, -1, -1, -1, 417, 418, 419, 420, 264, 265, -1, 267, -1, -1, 270, 271, - -1, -1, -1, 275, 276, 277, 418, 279, -1, -1, + -1, 256, -1, 275, 276, 277, -1, 279, -1, -1, 265, -1, 267, 285, -1, 270, 288, -1, -1, -1, 275, -1, -1, 295, 279, -1, -1, -1, 300, -1, 302, 303, 304, 288, -1, -1, -1, -1, -1, -1, @@ -11936,17 +12160,17 @@ void case_961() 332, 316, 334, 318, -1, -1, -1, 322, -1, 341, -1, -1, 344, 345, -1, 330, 331, -1, -1, 334, -1, -1, 337, -1, -1, -1, -1, 359, 360, 361, - 362, 363, -1, -1, -1, -1, -1, -1, -1, 371, + 362, 363, -1, -1, -1, 367, 368, -1, -1, 371, -1, -1, -1, -1, -1, 377, 378, 379, 380, -1, -1, -1, 384, -1, 386, -1, -1, -1, -1, -1, 392, 393, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 256, -1, -1, -1, 417, 418, 419, 420, 264, - 265, -1, 267, -1, -1, 270, 271, -1, -1, -1, + 265, -1, 267, -1, -1, 270, 271, -1, 256, -1, 275, 276, 277, 418, 279, -1, -1, 265, -1, 267, 285, -1, 270, 288, -1, -1, -1, 275, -1, -1, 295, 279, -1, -1, -1, 300, -1, 302, 303, 304, - 288, -1, -1, -1, -1, -1, -1, 295, -1, -1, + 288, 306, -1, -1, -1, -1, -1, 295, 313, -1, -1, 316, 300, 318, 319, -1, 304, 322, -1, -1, 325, -1, 327, -1, 329, 330, 331, 332, 316, 334, 318, -1, -1, -1, 322, -1, 341, -1, -1, 344, @@ -11960,6 +12184,65 @@ void case_961() -1, -1, 417, 418, 419, 420, 264, 265, -1, 267, -1, -1, 270, 271, -1, -1, -1, 275, 276, 277, 418, 279, -1, -1, 265, -1, 267, 285, -1, 270, + 288, -1, -1, -1, 275, -1, -1, 295, 279, -1, + -1, -1, 300, -1, 302, 303, 304, 288, -1, -1, + -1, -1, -1, -1, 295, -1, -1, -1, 316, 300, + 318, 319, 320, 304, 322, -1, -1, 325, -1, 327, + -1, 329, 330, 331, 332, 316, 334, 318, -1, -1, + -1, 322, -1, 341, -1, -1, 344, 345, -1, 330, + 331, -1, -1, 334, -1, -1, 337, -1, -1, -1, + -1, 359, 360, 361, 362, 363, -1, -1, -1, 367, + -1, -1, -1, 371, -1, -1, -1, -1, -1, 377, + 378, 379, 380, -1, -1, -1, 384, -1, 386, -1, + -1, 372, -1, -1, 392, 393, -1, -1, -1, -1, + -1, -1, 264, 265, -1, 267, -1, -1, 270, 271, + -1, -1, -1, 275, 276, 277, -1, 279, -1, 417, + 418, 419, 420, 285, -1, -1, 288, -1, -1, -1, + -1, -1, -1, 295, -1, -1, -1, 418, 300, -1, + 302, 303, 304, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 316, -1, 318, 319, -1, -1, + 322, -1, -1, 325, -1, 327, -1, 329, 330, 331, + 332, -1, 334, -1, -1, -1, -1, -1, -1, 341, + -1, -1, 344, 345, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 359, 360, 361, + 362, 363, -1, -1, -1, 367, 368, -1, -1, 371, + -1, -1, -1, -1, -1, 377, 378, 379, 380, -1, + -1, -1, 384, -1, 386, -1, -1, -1, -1, -1, + 392, 393, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 256, -1, 417, 418, 419, 420, -1, + -1, 264, 265, -1, 267, -1, 428, 270, 271, -1, + -1, -1, 275, 276, 277, -1, 279, -1, -1, 265, + -1, 267, 285, -1, 270, 288, -1, -1, -1, 275, + -1, -1, 295, 279, -1, -1, -1, 300, -1, 302, + 303, 304, 288, -1, -1, -1, -1, -1, -1, 295, + -1, -1, -1, 316, 300, 318, 319, 320, 304, 322, + -1, -1, 325, -1, 327, -1, 329, 330, 331, 332, + 316, 334, 318, -1, -1, -1, 322, -1, 341, -1, + -1, 344, 345, -1, 330, 331, -1, -1, 334, -1, + -1, 337, -1, -1, -1, -1, 359, 360, 361, 362, + 363, -1, -1, -1, 367, -1, -1, -1, 371, -1, + -1, -1, -1, -1, 377, 378, 379, 380, -1, -1, + -1, 384, -1, 386, 370, -1, -1, -1, -1, 392, + 393, -1, -1, -1, -1, -1, -1, 264, 265, -1, + 267, -1, -1, 270, 271, -1, -1, -1, 275, 276, + 277, -1, 279, -1, 417, 418, 419, 420, 285, -1, + -1, 288, -1, -1, -1, -1, -1, -1, 295, -1, + -1, -1, 418, 300, -1, 302, 303, 304, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 316, + -1, 318, 319, -1, -1, 322, -1, -1, 325, -1, + 327, -1, 329, 330, 331, 332, -1, 334, -1, -1, + -1, -1, -1, -1, 341, -1, -1, 344, 345, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 359, 360, 361, 362, 363, -1, -1, -1, + 367, -1, -1, -1, 371, -1, -1, -1, -1, -1, + 377, 378, 379, 380, -1, -1, -1, 384, -1, 386, + -1, -1, -1, -1, -1, 392, 393, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 256, -1, + 417, 418, 419, 420, -1, -1, 264, 265, -1, 267, + -1, 428, 270, 271, -1, -1, -1, 275, 276, 277, + -1, 279, -1, -1, 265, -1, 267, 285, -1, 270, 288, -1, -1, -1, 275, -1, -1, 295, 279, -1, -1, -1, 300, -1, 302, 303, 304, 288, -1, -1, -1, -1, -1, -1, 295, -1, -1, -1, 316, 300, @@ -11967,7 +12250,7 @@ void case_961() -1, 329, 330, 331, 332, 316, 334, 318, -1, -1, -1, 322, -1, 341, -1, -1, 344, 345, -1, 330, 331, -1, -1, 334, -1, -1, 337, -1, -1, -1, - -1, 359, 360, 361, 362, 363, -1, -1, -1, -1, + -1, 359, 360, 361, 362, 363, -1, -1, -1, 367, -1, -1, -1, 371, -1, -1, -1, -1, -1, 377, 378, 379, 380, -1, -1, -1, 384, -1, 386, -1, -1, -1, -1, -1, 392, 393, -1, -1, -1, -1, @@ -11975,122 +12258,188 @@ void case_961() -1, -1, -1, -1, -1, 256, -1, -1, -1, 417, 418, 419, 420, 264, 265, -1, 267, -1, -1, 270, 271, -1, -1, -1, 275, 276, 277, 418, 279, -1, - -1, -1, -1, -1, 285, -1, -1, 288, -1, -1, - -1, -1, -1, -1, 295, -1, 261, -1, 262, 300, - -1, 302, 303, 304, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 316, -1, 318, 319, 284, - -1, 322, -1, -1, 325, -1, 327, -1, 329, 330, - 331, 332, 297, 334, 298, -1, -1, 302, -1, -1, - -1, -1, 307, -1, 309, 310, 311, 312, -1, -1, - -1, -1, 317, -1, -1, -1, 321, -1, 359, 360, - 361, 362, -1, -1, -1, -1, -1, -1, 333, -1, - 371, 336, -1, 338, -1, -1, -1, -1, -1, -1, + -1, 265, -1, 267, 285, -1, 270, 288, -1, -1, + -1, 275, -1, -1, 295, 279, -1, -1, -1, 300, + -1, 302, 303, 304, 288, -1, -1, -1, -1, -1, + -1, 295, -1, -1, -1, 316, 300, 318, 319, -1, + 304, 322, -1, -1, 325, -1, 327, -1, 329, 330, + 331, 332, 316, 334, 318, -1, -1, -1, 322, -1, + 341, -1, -1, 344, 345, -1, 330, 331, -1, -1, + 334, -1, -1, 337, -1, -1, -1, -1, 359, 360, + 361, 362, 363, -1, -1, -1, -1, -1, -1, -1, + 371, -1, -1, -1, -1, -1, 377, 378, 379, 380, + -1, -1, -1, 384, -1, 386, -1, -1, -1, -1, + -1, 392, 393, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 256, -1, -1, -1, 417, 418, 419, 420, + 264, 265, -1, 267, -1, -1, 270, 271, -1, -1, + -1, 275, 276, 277, 418, 279, -1, -1, 265, -1, + 267, 285, -1, 270, 288, -1, -1, -1, 275, -1, + -1, 295, 279, -1, -1, -1, 300, -1, 302, 303, + 304, 288, -1, -1, -1, -1, -1, -1, 295, -1, + -1, -1, 316, 300, 318, 319, -1, 304, 322, -1, + -1, 325, -1, 327, -1, 329, 330, 331, 332, 316, + 334, 318, -1, -1, -1, 322, -1, 341, -1, -1, + 344, 345, -1, 330, 331, -1, -1, 334, -1, -1, + 337, -1, -1, -1, -1, 359, 360, 361, 362, 363, + -1, -1, -1, -1, -1, -1, -1, 371, -1, -1, + -1, -1, -1, 377, 378, 379, 380, -1, -1, -1, + 384, -1, 386, -1, -1, -1, -1, -1, 392, 393, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 256, + -1, -1, -1, 417, 418, 419, 420, 264, 265, -1, + 267, -1, -1, 270, 271, -1, -1, -1, 275, 276, + 277, 418, 279, -1, -1, 265, -1, 267, 285, -1, + 270, 288, -1, -1, -1, 275, -1, -1, 295, 279, + -1, -1, -1, 300, -1, 302, 303, 304, 288, -1, + -1, -1, -1, -1, -1, 295, -1, -1, -1, 316, + 300, 318, 319, -1, 304, 322, -1, -1, 325, -1, + 327, -1, 329, 330, 331, 332, 316, 334, 318, -1, + -1, -1, 322, -1, 341, -1, -1, 344, 345, -1, + 330, 331, -1, -1, 334, -1, -1, 337, -1, -1, + -1, -1, 359, 360, 361, 362, 363, -1, -1, -1, + -1, -1, -1, -1, 371, -1, -1, -1, -1, -1, + 377, 378, 379, 380, -1, -1, -1, 384, -1, 386, + -1, -1, -1, -1, -1, 392, 393, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 256, -1, -1, -1, + 417, 418, 419, 420, 264, 265, -1, 267, -1, -1, + 270, 271, -1, -1, -1, 275, 276, 277, 418, 279, + -1, -1, 265, -1, 267, 285, -1, 270, 288, -1, + -1, -1, 275, -1, -1, 295, 279, -1, -1, -1, + 300, -1, 302, 303, 304, 288, -1, -1, -1, -1, + -1, -1, 295, -1, -1, -1, 316, 300, 318, 319, + -1, 304, 322, -1, -1, 325, -1, 327, -1, 329, + 330, 331, 332, 316, 334, 318, -1, -1, -1, 322, + -1, 341, -1, -1, 344, 345, -1, 330, 331, -1, + -1, 334, -1, -1, 337, -1, -1, -1, -1, 359, + 360, 361, 362, 363, -1, -1, -1, -1, -1, -1, + -1, 371, -1, -1, -1, -1, -1, 377, 378, 379, + 380, -1, -1, -1, 384, -1, 386, -1, -1, -1, + -1, -1, 392, 393, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 256, -1, -1, -1, 417, 418, 419, + 420, 264, 265, -1, 267, -1, -1, 270, 271, -1, + -1, -1, 275, 276, 277, 418, 279, -1, -1, 265, + -1, 267, 285, -1, 270, 288, -1, -1, -1, 275, + -1, -1, 295, 279, -1, -1, -1, 300, -1, 302, + 303, 304, 288, -1, -1, -1, -1, -1, -1, 295, + -1, -1, -1, 316, 300, 318, 319, -1, 304, 322, + -1, -1, 325, -1, 327, -1, 329, 330, 331, 332, + 316, 334, 318, -1, -1, -1, 322, -1, 341, -1, + -1, 344, 345, -1, 330, 331, -1, -1, 334, -1, + -1, 337, -1, -1, -1, -1, 359, 360, 361, 362, + 363, -1, -1, -1, -1, -1, -1, -1, 371, -1, + -1, -1, -1, -1, 377, 378, 379, 380, -1, -1, + -1, 384, -1, 386, -1, -1, -1, -1, -1, 392, + 393, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 256, -1, -1, -1, 417, 418, 419, 420, 264, 265, + -1, 267, -1, -1, 270, 271, -1, -1, -1, 275, + 276, 277, 418, 279, -1, -1, -1, -1, -1, 285, + -1, -1, 288, -1, -1, -1, -1, -1, -1, 295, + -1, -1, -1, -1, 300, -1, 302, 303, 304, -1, + -1, -1, -1, -1, -1, -1, 262, -1, -1, -1, + 316, -1, 318, 319, -1, -1, 322, -1, -1, 325, + -1, 327, -1, 329, 330, 331, 332, -1, 334, -1, + -1, -1, -1, -1, -1, 341, -1, -1, 344, 345, + -1, -1, 298, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 359, 360, 361, 362, 363, -1, -1, + -1, -1, -1, -1, -1, 371, -1, -1, -1, -1, + -1, 377, 378, 379, 380, -1, -1, -1, 384, -1, + 386, -1, -1, -1, -1, -1, 392, 393, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 362, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 371, 372, 373, - 374, 375, -1, -1, 378, 379, 417, 418, 382, 383, - 384, 385, 386, 387, 388, 389, 390, -1, 392, 393, - 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, - 404, 405, 406, 407, 408, 409, 410, 411, 412, 413, - -1, 261, -1, 418, -1, 265, 420, 267, -1, 423, - 270, -1, 272, 273, -1, 275, -1, 277, -1, 279, - -1, 281, 282, 283, 284, -1, -1, 287, 288, -1, - -1, -1, -1, 293, -1, 295, 296, 297, -1, -1, - 300, -1, 302, -1, 304, -1, -1, 307, -1, 309, - 310, 311, 312, -1, -1, -1, 316, 317, 318, -1, - -1, 321, 322, 323, -1, -1, -1, -1, -1, -1, - 330, 331, -1, 333, 334, -1, 336, 337, 338, -1, - -1, -1, 342, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 261, -1, 362, -1, 265, -1, 267, -1, 368, 270, - -1, 272, 273, -1, 275, -1, 277, 377, 279, -1, - 281, 282, 283, 284, -1, -1, 287, 288, -1, -1, - -1, -1, 293, -1, 295, 296, 297, -1, -1, 300, - -1, 302, -1, 304, -1, -1, 307, -1, 309, 310, - 311, 312, -1, -1, -1, 316, 317, 318, 418, -1, - 321, 322, 323, -1, -1, -1, -1, -1, -1, 330, - 331, -1, 333, 334, -1, 336, 337, 338, -1, -1, - -1, 342, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 261, - -1, 362, -1, 265, -1, 267, -1, 368, 270, -1, - 272, 273, -1, 275, -1, 277, 377, 279, -1, 281, + -1, 417, 418, 419, 420, 371, 372, 373, 374, 375, + -1, -1, 378, 379, -1, -1, 382, 383, 384, 385, + 386, 387, 388, 389, 390, -1, 392, 393, 394, 395, + 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 407, 408, 409, 410, 411, 412, 413, -1, 261, + -1, 263, -1, 265, 420, 267, -1, 423, 270, -1, + 272, 273, -1, 275, -1, 277, -1, 279, -1, 281, 282, 283, 284, -1, -1, 287, 288, -1, -1, -1, - -1, 293, -1, 295, 296, 297, -1, -1, 300, -1, - 302, -1, 304, -1, -1, 307, -1, 309, 310, 311, - 312, -1, -1, -1, 316, 317, 318, 418, -1, 321, + -1, 293, 294, 295, 296, 297, -1, -1, 300, -1, + 302, -1, 304, -1, 306, 307, -1, 309, 310, 311, + 312, -1, -1, 315, 316, 317, 318, -1, -1, 321, 322, 323, -1, -1, -1, -1, -1, -1, 330, 331, -1, 333, 334, -1, 336, 337, 338, -1, -1, -1, 342, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 261, -1, -1, -1, 265, -1, 267, - 362, -1, 270, -1, 272, 273, 368, 275, -1, 277, - -1, 279, -1, 281, 282, 283, 284, -1, -1, 287, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 362, -1, 364, 365, 261, -1, -1, -1, 265, -1, + 267, -1, -1, 270, -1, 272, 273, -1, 275, -1, + 277, -1, 279, -1, 281, 282, 283, 284, -1, -1, + 287, 288, -1, -1, -1, -1, 293, -1, 295, 296, + 297, -1, -1, 300, -1, 302, -1, 304, -1, -1, + 307, -1, 309, 310, 311, 312, 418, -1, -1, 316, + 317, 318, -1, -1, 321, 322, 323, -1, -1, -1, + -1, -1, -1, 330, 331, -1, 333, 334, -1, 336, + 337, 338, -1, -1, -1, 342, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 261, -1, 362, -1, 265, -1, 267, + -1, 368, 270, -1, 272, 273, -1, 275, -1, 277, + 377, 279, -1, 281, 282, 283, 284, -1, -1, 287, 288, -1, -1, -1, -1, 293, -1, 295, 296, 297, - -1, -1, 300, -1, 302, 261, 304, -1, -1, 307, + -1, -1, 300, -1, 302, -1, 304, -1, -1, 307, -1, 309, 310, 311, 312, -1, -1, -1, 316, 317, - 318, -1, -1, 321, 322, 323, 418, -1, 284, -1, + 318, 418, -1, 321, 322, 323, -1, -1, -1, -1, -1, -1, 330, 331, -1, 333, 334, -1, 336, 337, - 338, 297, -1, -1, 342, -1, 302, -1, -1, 305, - -1, 307, -1, 309, 310, 311, 312, -1, -1, -1, - -1, 317, -1, -1, 362, 321, -1, -1, -1, 325, - 368, -1, -1, 261, -1, -1, -1, 333, -1, -1, - 336, -1, 338, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 284, -1, -1, -1, - -1, 357, -1, -1, -1, -1, 362, -1, -1, 297, - -1, -1, -1, 369, 302, 371, -1, 373, -1, 307, - 418, 309, 310, 311, 312, -1, -1, -1, -1, 317, - 386, -1, -1, 321, -1, -1, -1, 325, -1, -1, - 264, 265, -1, 267, -1, 333, 270, 271, 336, -1, - 338, 275, 276, 277, -1, 279, -1, -1, -1, -1, - -1, 285, 418, -1, 288, -1, -1, -1, -1, -1, - -1, 295, -1, -1, 362, -1, 300, -1, 302, 303, - 304, -1, 306, -1, -1, -1, -1, -1, -1, 313, - -1, -1, 316, -1, 318, 319, -1, -1, 322, -1, - -1, 325, -1, 327, -1, 329, 330, 331, 332, -1, - 334, -1, -1, -1, -1, -1, -1, 341, -1, -1, - 344, 345, -1, -1, -1, -1, -1, -1, -1, -1, - 418, -1, -1, -1, -1, 359, 360, 361, 362, 363, - -1, -1, -1, -1, -1, -1, -1, 371, 372, -1, - 374, -1, -1, 377, 378, 379, 380, -1, -1, -1, - 384, -1, 386, -1, -1, -1, -1, -1, 392, 393, - -1, -1, -1, -1, -1, -1, 264, 265, -1, 267, - -1, -1, 270, 271, -1, -1, -1, 275, 276, 277, - -1, 279, -1, 417, 418, 419, 420, 285, -1, -1, - 288, -1, -1, -1, -1, -1, -1, 295, -1, -1, - -1, -1, 300, -1, 302, 303, 304, -1, 306, -1, - -1, -1, -1, -1, -1, 313, -1, -1, 316, -1, - 318, 319, -1, -1, 322, -1, -1, 325, -1, 327, - -1, 329, 330, 331, 332, -1, 334, -1, -1, -1, - -1, -1, -1, 341, -1, -1, 344, 345, -1, -1, + 338, -1, -1, -1, 342, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 359, 360, 361, 362, 363, -1, -1, -1, -1, - -1, -1, -1, 371, -1, -1, 374, -1, -1, 377, - 378, 379, 380, -1, -1, -1, 384, -1, 386, -1, - -1, -1, -1, -1, 392, 393, -1, -1, -1, -1, - -1, -1, 264, 265, -1, 267, -1, -1, 270, 271, - -1, -1, -1, 275, 276, 277, -1, 279, -1, 417, - 418, 419, 420, 285, -1, -1, 288, -1, -1, -1, - -1, -1, -1, 295, -1, -1, -1, -1, 300, -1, - 302, 303, 304, -1, 306, -1, -1, -1, -1, -1, + -1, -1, 261, -1, 362, -1, 265, -1, 267, -1, + 368, 270, -1, 272, 273, -1, 275, -1, 277, 377, + 279, -1, 281, 282, 283, 284, -1, -1, 287, 288, + -1, -1, -1, -1, 293, -1, 295, 296, 297, -1, + -1, 300, -1, 302, -1, 304, -1, -1, 307, -1, + 309, 310, 311, 312, -1, -1, -1, 316, 317, 318, + 418, -1, 321, 322, 323, -1, -1, -1, -1, -1, + -1, 330, 331, -1, 333, 334, -1, 336, 337, 338, + -1, -1, -1, 342, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 261, -1, -1, -1, + 265, -1, 267, 362, -1, 270, -1, 272, 273, 368, + 275, -1, 277, -1, 279, -1, 281, 282, 283, 284, + -1, -1, 287, 288, -1, -1, -1, -1, 293, -1, + 295, 296, 297, -1, -1, 300, -1, 302, -1, 304, + -1, -1, 307, -1, 309, 310, 311, 312, -1, -1, + -1, 316, 317, 318, -1, -1, 321, 322, 323, 418, + -1, -1, -1, -1, -1, 330, 331, -1, 333, 334, + -1, 336, 337, 338, -1, -1, -1, 342, -1, -1, + -1, -1, 261, -1, -1, -1, 265, -1, 267, -1, + -1, 270, -1, 272, 273, -1, 275, 362, 277, -1, + 279, -1, 281, 282, 283, 284, -1, -1, 287, 288, + -1, -1, 377, -1, 293, -1, 295, 296, 297, -1, + -1, 300, -1, 302, 261, 304, -1, -1, 307, -1, + 309, 310, 311, 312, -1, -1, -1, 316, 317, 318, + -1, -1, 321, 322, 323, -1, -1, 284, -1, -1, + -1, 330, 331, 418, 333, 334, -1, 336, 337, 338, + 297, -1, -1, 342, -1, 302, -1, -1, 305, -1, + 307, -1, 309, 310, 311, 312, -1, -1, -1, -1, + 317, -1, -1, 362, 321, -1, -1, -1, 325, 368, + -1, -1, -1, -1, -1, -1, 333, -1, -1, 336, + -1, 338, 264, 265, -1, 267, -1, -1, 270, 271, + -1, -1, -1, 275, 276, 277, -1, 279, -1, -1, + 357, -1, -1, 285, -1, 362, 288, -1, -1, -1, + -1, -1, 369, 295, 371, -1, 373, -1, 300, 418, + 302, 303, 304, -1, 306, -1, -1, -1, -1, 386, -1, 313, -1, -1, 316, -1, 318, 319, -1, -1, 322, -1, -1, 325, -1, 327, -1, 329, 330, 331, 332, -1, 334, -1, -1, -1, -1, -1, -1, 341, - -1, -1, 344, 345, -1, -1, -1, -1, -1, -1, + -1, 418, 344, 345, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 359, 360, 361, 362, 363, -1, -1, -1, -1, -1, -1, -1, 371, - -1, -1, -1, -1, -1, 377, 378, 379, 380, -1, + 372, -1, 374, -1, -1, 377, 378, 379, 380, -1, -1, -1, 384, -1, 386, -1, -1, -1, -1, -1, 392, 393, -1, -1, -1, -1, -1, -1, 264, 265, -1, 267, -1, -1, 270, 271, -1, -1, -1, 275, 276, 277, -1, 279, -1, 417, 418, 419, 420, 285, -1, -1, 288, -1, -1, -1, -1, -1, -1, 295, -1, -1, -1, -1, 300, -1, 302, 303, 304, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 306, -1, -1, -1, -1, -1, -1, 313, -1, -1, 316, -1, 318, 319, -1, -1, 322, -1, -1, 325, -1, 327, -1, 329, 330, 331, 332, -1, 334, -1, - -1, 337, -1, -1, -1, 341, -1, -1, 344, 345, + -1, -1, -1, -1, -1, 341, -1, -1, 344, 345, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 359, 360, 361, 362, 363, -1, -1, - -1, -1, -1, -1, -1, 371, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 371, -1, -1, 374, -1, -1, 377, 378, 379, 380, -1, -1, -1, 384, -1, 386, -1, -1, -1, -1, -1, 392, 393, -1, -1, -1, -1, -1, -1, 264, 265, -1, 267, -1, -1, @@ -12100,10 +12449,10 @@ void case_961() 300, -1, 302, 303, 304, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 316, -1, 318, 319, -1, -1, 322, -1, -1, 325, -1, 327, -1, 329, - 330, 331, 332, -1, 334, -1, -1, -1, -1, -1, + 330, 331, 332, -1, 334, -1, -1, 337, -1, -1, -1, 341, -1, -1, 344, 345, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 359, - 360, 361, 362, 363, -1, -1, -1, -1, 368, -1, + 360, 361, 362, 363, -1, -1, -1, -1, -1, -1, -1, 371, -1, -1, -1, -1, -1, 377, 378, 379, 380, -1, -1, -1, 384, -1, 386, -1, -1, -1, -1, -1, 392, 393, -1, -1, -1, -1, -1, -1, @@ -12117,7 +12466,7 @@ void case_961() 334, -1, -1, -1, -1, -1, -1, 341, -1, -1, 344, 345, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 359, 360, 361, 362, 363, - -1, -1, -1, 367, -1, -1, -1, 371, -1, -1, + -1, -1, -1, -1, 368, -1, -1, 371, -1, -1, -1, -1, -1, 377, 378, 379, 380, -1, -1, -1, 384, -1, 386, -1, -1, -1, -1, -1, 392, 393, -1, -1, -1, -1, -1, -1, 264, 265, -1, 267, @@ -12144,7 +12493,7 @@ void case_961() 332, -1, 334, -1, -1, -1, -1, -1, -1, 341, -1, -1, 344, 345, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 359, 360, 361, - 362, 363, -1, -1, -1, -1, -1, -1, -1, 371, + 362, 363, -1, -1, -1, 367, -1, -1, -1, 371, -1, -1, -1, -1, -1, 377, 378, 379, 380, -1, -1, -1, 384, -1, 386, -1, -1, -1, -1, -1, 392, 393, -1, -1, -1, -1, -1, -1, 264, 265, @@ -12205,159 +12554,168 @@ void case_961() -1, -1, 264, 265, -1, 267, -1, -1, 270, 271, -1, -1, -1, 275, 276, 277, -1, 279, -1, 417, 418, 419, 420, 285, -1, -1, 288, -1, -1, -1, - -1, -1, -1, 295, -1, 261, -1, -1, 300, -1, + -1, -1, -1, 295, -1, -1, -1, -1, 300, -1, 302, 303, 304, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 316, -1, 318, 319, 284, -1, + -1, -1, -1, -1, 316, -1, 318, 319, -1, -1, 322, -1, -1, 325, -1, 327, -1, 329, 330, 331, - 332, 297, 334, -1, -1, -1, 302, -1, -1, -1, - -1, 307, -1, 309, 310, 311, 312, -1, -1, 315, - -1, 317, -1, -1, -1, 321, -1, 359, 360, 361, - 362, 363, -1, -1, -1, -1, -1, 333, -1, 371, - 336, -1, 338, -1, -1, 377, 378, 379, 380, -1, + 332, -1, 334, -1, -1, -1, -1, -1, -1, 341, + -1, -1, 344, 345, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 359, 360, 361, + 362, 363, -1, -1, -1, -1, -1, -1, -1, 371, + -1, -1, -1, -1, -1, 377, 378, 379, 380, -1, -1, -1, 384, -1, 386, -1, -1, -1, -1, -1, - 392, 393, -1, -1, -1, -1, 362, -1, -1, -1, - -1, -1, 368, 369, -1, -1, -1, -1, -1, -1, - 263, -1, 265, -1, 267, 417, 418, 270, 420, 272, - 273, -1, 275, -1, 277, -1, 279, -1, 281, 282, - 283, -1, -1, -1, 287, 288, -1, -1, -1, -1, - 293, -1, 295, 296, -1, -1, -1, 300, -1, -1, - -1, 304, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 315, 316, -1, 318, -1, -1, -1, 322, - 323, -1, -1, -1, -1, -1, -1, 330, 331, 264, - 265, 334, 267, -1, 337, 270, 271, -1, -1, 342, - 275, 276, 277, -1, 279, -1, -1, -1, -1, -1, - 285, -1, -1, 288, -1, -1, -1, -1, -1, -1, - 295, 364, 365, -1, -1, 300, -1, 302, 303, 304, - -1, -1, -1, -1, 377, -1, -1, -1, -1, -1, - -1, 316, -1, 318, 319, -1, -1, 322, -1, -1, - 325, -1, 327, -1, 329, 330, 331, 332, -1, 334, - -1, -1, 337, -1, -1, -1, -1, -1, -1, 265, - -1, 267, -1, -1, 270, 418, 272, -1, -1, 275, - -1, -1, -1, 279, 359, 360, 361, 362, -1, -1, - -1, -1, 288, 265, -1, 267, 371, -1, 270, 295, - 272, 273, -1, 275, 300, 277, 302, 279, 304, 281, - 282, 283, -1, -1, -1, 287, 288, -1, -1, -1, - 316, 293, 318, 295, 296, -1, 322, 323, 300, -1, - -1, -1, 304, -1, 330, 331, -1, -1, 334, -1, - -1, 337, 417, 418, 316, -1, 318, -1, -1, -1, - 322, 323, -1, -1, -1, -1, -1, -1, 330, 331, - -1, 265, 334, 267, -1, 337, 270, -1, 272, 273, - 342, 275, -1, 277, -1, 279, -1, 281, 282, 283, + 392, 393, -1, -1, -1, -1, -1, -1, 264, 265, + -1, 267, -1, -1, 270, 271, -1, -1, -1, 275, + 276, 277, -1, 279, -1, 417, 418, 419, 420, 285, + -1, -1, 288, -1, -1, -1, -1, -1, -1, 295, + -1, 261, -1, -1, 300, -1, 302, 303, 304, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 316, -1, 318, 319, 284, -1, 322, -1, -1, 325, + -1, 327, -1, 329, 330, 331, 332, 297, 334, -1, + -1, -1, 302, -1, -1, -1, -1, 307, -1, 309, + 310, 311, 312, -1, -1, 315, -1, 317, -1, -1, + -1, 321, -1, 359, 360, 361, 362, 363, -1, -1, + -1, -1, -1, 333, -1, 371, 336, -1, 338, -1, + -1, 377, 378, 379, 380, -1, -1, -1, 384, -1, + 386, -1, -1, -1, -1, -1, 392, 393, -1, -1, + -1, -1, 362, -1, -1, -1, -1, -1, 368, 369, + -1, -1, -1, -1, -1, -1, 263, -1, 265, -1, + 267, 417, 418, 270, 420, 272, 273, -1, 275, -1, + 277, -1, 279, -1, 281, 282, 283, -1, -1, -1, + 287, 288, -1, -1, -1, -1, 293, -1, 295, 296, + -1, -1, -1, 300, -1, -1, -1, 304, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 315, 316, + -1, 318, -1, -1, -1, 322, 323, -1, -1, -1, + -1, -1, -1, 330, 331, 264, 265, 334, 267, -1, + 337, 270, 271, -1, -1, 342, 275, 276, 277, -1, + 279, -1, -1, -1, -1, -1, 285, -1, -1, 288, + -1, -1, -1, -1, -1, -1, 295, 364, 365, -1, + -1, 300, -1, 302, 303, 304, -1, -1, -1, -1, + 377, -1, -1, -1, -1, -1, -1, 316, -1, 318, + 319, -1, -1, 322, -1, -1, 325, -1, 327, -1, + 329, 330, 331, 332, -1, 334, -1, -1, 337, -1, + -1, -1, -1, -1, -1, 265, -1, 267, -1, -1, + 270, 418, 272, -1, -1, 275, -1, -1, -1, 279, + 359, 360, 361, 362, -1, -1, -1, -1, 288, 265, + -1, 267, 371, -1, 270, 295, 272, 273, -1, 275, + 300, 277, 302, 279, 304, 281, 282, 283, -1, -1, + -1, 287, 288, -1, -1, -1, 316, 293, 318, 295, + 296, -1, 322, 323, 300, -1, -1, -1, 304, -1, + 330, 331, -1, -1, 334, -1, -1, 337, 417, 418, + 316, -1, 318, -1, -1, -1, 322, 323, -1, -1, + -1, -1, -1, -1, 330, 331, -1, 265, 334, 267, + -1, 337, 270, -1, 272, 273, 342, 275, -1, 277, + -1, 279, -1, 281, 282, 283, -1, -1, -1, 287, + 288, -1, -1, -1, -1, 293, -1, 295, 296, -1, + -1, -1, 300, -1, -1, -1, 304, -1, -1, -1, + -1, 377, -1, -1, -1, -1, -1, -1, 316, -1, + 318, -1, -1, -1, 322, 323, -1, -1, 418, -1, + -1, -1, 330, 331, -1, -1, 334, -1, -1, 337, + -1, 265, -1, 267, 342, -1, 270, -1, -1, 273, + -1, 275, 418, 277, -1, 279, -1, 281, 282, 283, -1, -1, -1, 287, 288, -1, -1, -1, -1, 293, - -1, 295, 296, -1, -1, -1, 300, -1, -1, -1, - 304, -1, -1, -1, -1, 377, -1, -1, -1, -1, - -1, -1, 316, -1, 318, -1, -1, -1, 322, 323, - -1, -1, 418, -1, -1, -1, 330, 331, -1, -1, - 334, -1, -1, 337, -1, 265, -1, 267, 342, -1, - 270, -1, -1, 273, -1, 275, 418, 277, -1, 279, - -1, 281, 282, 283, -1, -1, -1, 287, 288, -1, - -1, -1, -1, 293, -1, 295, -1, 265, -1, 267, - 300, -1, 270, -1, 304, 273, -1, 275, -1, 277, - -1, 279, -1, 281, 282, 283, 316, -1, 318, 287, - 288, -1, 322, -1, -1, 293, -1, 295, -1, -1, - 330, 331, 300, -1, 334, -1, 304, 337, -1, -1, - -1, 265, 342, 267, 418, -1, 270, -1, 316, -1, - 318, 275, -1, -1, 322, 279, -1, -1, -1, -1, - -1, -1, 330, 331, 288, -1, 334, -1, -1, 337, - -1, 295, -1, 265, 342, 267, 300, 377, 270, -1, - 304, -1, 306, 275, 308, -1, -1, 279, -1, 313, - -1, -1, 316, -1, 318, -1, 288, -1, 322, -1, - -1, 325, -1, 295, -1, -1, 330, 331, 300, -1, - 334, -1, 304, 337, 306, -1, 308, 265, 418, 267, - -1, 313, 270, -1, 316, -1, 318, 275, -1, -1, - 322, 279, -1, 325, -1, -1, -1, -1, 330, 331, - 288, -1, 334, -1, -1, 337, -1, 295, 372, 265, - 418, 267, 300, -1, 270, -1, 304, -1, 306, 275, + -1, 295, -1, 265, -1, 267, 300, -1, 270, -1, + 304, 273, -1, 275, -1, 277, -1, 279, -1, 281, + 282, 283, 316, -1, 318, 287, 288, -1, 322, -1, + -1, 293, -1, 295, -1, -1, 330, 331, 300, -1, + 334, -1, 304, 337, -1, -1, -1, 265, 342, 267, + 418, -1, 270, -1, 316, -1, 318, 275, -1, -1, + 322, 279, -1, -1, -1, -1, -1, -1, 330, 331, + 288, -1, 334, -1, -1, 337, -1, 295, -1, 265, + 342, 267, 300, 377, 270, -1, 304, -1, 306, 275, 308, -1, -1, 279, -1, 313, -1, -1, 316, -1, - 318, -1, 288, -1, 322, -1, -1, 325, 370, 295, + 318, -1, 288, -1, 322, -1, -1, 325, -1, 295, -1, -1, 330, 331, 300, -1, 334, -1, 304, 337, - 306, -1, -1, -1, 418, -1, -1, 313, -1, -1, - 316, -1, 318, -1, -1, -1, 322, -1, -1, 325, - -1, -1, -1, -1, 330, 331, -1, -1, 334, -1, - 265, 337, 267, -1, -1, 270, 418, -1, -1, -1, - 275, -1, -1, -1, 279, -1, -1, -1, 283, 265, - -1, 267, -1, 288, 270, -1, -1, -1, 293, 275, - 295, -1, -1, 279, -1, 300, -1, -1, -1, 304, - 305, -1, 288, -1, -1, -1, -1, -1, -1, 295, - 418, 316, -1, 318, 300, -1, -1, 322, 304, -1, - -1, -1, -1, -1, -1, 330, 331, -1, -1, 334, - 316, -1, 318, 265, -1, 267, 322, -1, 270, -1, - -1, -1, 418, 275, 330, 331, -1, 279, 334, -1, - 265, 337, 267, -1, -1, 270, 288, -1, -1, -1, - 275, -1, -1, 295, 279, -1, -1, -1, 300, -1, - -1, -1, 304, 288, -1, -1, -1, 363, -1, -1, - 295, -1, -1, -1, 316, 300, 318, -1, -1, 304, - 322, -1, -1, -1, -1, -1, -1, -1, 330, 331, - -1, 316, 334, 318, 265, 337, 267, 322, -1, 270, - -1, -1, -1, 418, 275, 330, 331, -1, 279, 334, - -1, -1, 337, -1, -1, -1, -1, 288, 265, -1, - 267, -1, 418, 270, 295, -1, -1, -1, 275, 300, - -1, -1, 279, 304, -1, -1, -1, -1, -1, -1, - -1, 288, -1, -1, -1, 316, -1, 318, 295, -1, - -1, 322, -1, 300, -1, -1, -1, 304, -1, 330, - 331, -1, 261, 334, -1, -1, 337, -1, -1, 316, - -1, 318, -1, 272, -1, 322, 418, -1, 277, -1, - -1, -1, 281, 330, 331, 284, -1, 334, -1, -1, - 337, -1, -1, 418, -1, -1, -1, 296, 297, -1, - -1, -1, 301, 302, -1, 261, -1, -1, 307, -1, - 309, 310, 311, 312, -1, -1, 272, -1, 317, -1, - -1, 277, 321, -1, 323, 281, -1, -1, 284, -1, - -1, -1, -1, -1, 333, -1, 335, 336, -1, 338, - 296, 297, -1, 342, -1, 301, 302, 418, -1, -1, - -1, 307, -1, 309, 310, 311, 312, -1, -1, -1, - -1, 317, -1, 362, -1, 321, -1, 323, -1, 368, - 369, 418, -1, 261, -1, 263, -1, 333, -1, -1, - 336, -1, 338, -1, -1, -1, 342, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 284, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 362, -1, -1, 297, - -1, -1, 368, 369, 302, -1, 261, -1, -1, 307, - -1, 309, 310, 311, 312, -1, -1, 272, -1, 317, - -1, -1, 277, 321, -1, -1, 281, -1, -1, 284, - -1, -1, -1, -1, -1, 333, -1, -1, 336, -1, - 338, 296, 297, -1, -1, -1, 301, 302, -1, 261, + 306, -1, 308, 265, 418, 267, -1, 313, 270, -1, + 316, -1, 318, 275, -1, -1, 322, 279, -1, 325, + -1, -1, -1, -1, 330, 331, 288, -1, 334, -1, + -1, 337, -1, 295, 372, 265, 418, 267, 300, -1, + 270, -1, 304, -1, 306, 275, 308, -1, -1, 279, + -1, 313, -1, -1, 316, -1, 318, -1, 288, -1, + 322, -1, -1, 325, 370, 295, -1, -1, 330, 331, + 300, -1, 334, -1, 304, 337, 306, -1, 308, 265, + 418, 267, -1, 313, 270, -1, 316, -1, 318, 275, + -1, -1, 322, 279, -1, 325, -1, -1, -1, -1, + 330, 331, 288, -1, 334, -1, -1, 337, -1, 295, + -1, -1, 418, -1, 300, -1, -1, -1, 304, -1, + 306, -1, -1, -1, 265, -1, 267, 313, -1, 270, + 316, -1, 318, -1, 275, -1, 322, -1, 279, 325, + -1, -1, 283, -1, 330, 331, -1, 288, 334, -1, + -1, 337, 293, -1, 295, -1, 418, -1, -1, 300, + -1, -1, -1, 304, 305, -1, -1, -1, 265, -1, + 267, -1, -1, 270, -1, 316, -1, 318, 275, -1, + -1, 322, 279, -1, -1, -1, -1, -1, 418, 330, + 331, 288, 265, 334, 267, -1, -1, 270, 295, -1, + -1, -1, 275, 300, -1, -1, 279, 304, -1, -1, + -1, -1, -1, -1, -1, 288, -1, -1, -1, 316, + -1, 318, 295, -1, -1, 322, -1, 300, -1, -1, + -1, 304, 418, 330, 331, -1, -1, 334, -1, -1, + 337, -1, -1, 316, -1, 318, 265, -1, 267, 322, + -1, 270, -1, -1, -1, -1, 275, 330, 331, -1, + 279, 334, -1, -1, 337, -1, 363, -1, -1, 288, + -1, -1, -1, -1, -1, -1, 295, 418, -1, -1, + -1, 300, -1, -1, 261, 304, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 272, -1, 316, -1, 318, + 277, -1, -1, 322, 281, -1, -1, 284, -1, -1, + -1, 330, 331, -1, -1, 334, -1, -1, 337, 296, + 297, 418, -1, -1, 301, 302, -1, -1, -1, -1, + 307, -1, 309, 310, 311, 312, -1, -1, -1, -1, + 317, -1, -1, -1, 321, 418, 323, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 333, -1, 335, 336, + 261, 338, -1, -1, -1, 342, -1, -1, -1, -1, + -1, 272, -1, -1, -1, -1, 277, -1, -1, -1, + 281, -1, -1, 284, -1, 362, -1, -1, -1, -1, + -1, 368, 369, -1, -1, 296, 297, -1, -1, 418, + 301, 302, 261, -1, 263, -1, 307, -1, 309, 310, + 311, 312, -1, -1, -1, -1, 317, -1, -1, -1, + 321, -1, 323, -1, -1, 284, -1, -1, -1, -1, + -1, -1, 333, -1, -1, 336, -1, 338, 297, -1, + -1, 342, -1, 302, -1, -1, -1, -1, 307, -1, + 309, 310, 311, 312, -1, -1, -1, -1, 317, -1, + -1, 362, 321, -1, -1, 261, -1, 368, 369, -1, + -1, -1, -1, -1, 333, -1, 272, 336, -1, 338, + -1, 277, -1, -1, -1, 281, -1, -1, 284, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 296, 297, -1, 362, -1, 301, 302, -1, 261, 368, + 369, 307, -1, 309, 310, 311, 312, -1, -1, 272, + -1, 317, -1, -1, 277, 321, -1, 323, 281, -1, + -1, 284, -1, -1, -1, -1, -1, 333, -1, -1, + 336, -1, 338, 296, 297, -1, 342, -1, 301, 302, + 261, -1, -1, -1, 307, -1, 309, 310, 311, 312, + -1, -1, -1, -1, 317, -1, 362, -1, 321, -1, + 323, -1, 368, 284, -1, -1, -1, -1, -1, -1, + 333, -1, -1, 336, -1, 338, 297, -1, 261, 342, + -1, 302, -1, -1, -1, -1, 307, -1, 309, 310, + 311, 312, -1, -1, -1, -1, 317, -1, -1, 362, + 321, 284, -1, -1, -1, 368, -1, -1, -1, -1, + -1, -1, 333, -1, 297, 336, 261, 338, -1, 302, + -1, -1, -1, -1, 307, -1, 309, 310, 311, 312, + -1, -1, -1, -1, 317, -1, -1, -1, 321, 284, + -1, 362, -1, 364, 365, -1, -1, 368, -1, -1, + 333, -1, 297, 336, 261, 338, 263, 302, -1, -1, -1, -1, 307, -1, 309, 310, 311, 312, -1, -1, - 272, -1, 317, -1, 362, 277, 321, -1, 323, 281, - 368, 369, 284, -1, -1, -1, -1, -1, 333, -1, - -1, 336, -1, 338, 296, 297, -1, 342, -1, 301, - 302, 261, -1, -1, -1, 307, -1, 309, 310, 311, - 312, -1, -1, -1, -1, 317, -1, 362, -1, 321, - -1, 323, -1, 368, 284, -1, -1, -1, -1, -1, - -1, 333, -1, -1, 336, -1, 338, 297, -1, 261, - 342, -1, 302, -1, -1, -1, -1, 307, -1, 309, - 310, 311, 312, -1, -1, -1, -1, 317, -1, -1, - 362, 321, 284, -1, -1, -1, 368, -1, -1, -1, - -1, -1, -1, 333, -1, 297, 336, 261, 338, -1, - 302, -1, -1, -1, -1, 307, -1, 309, 310, 311, - 312, -1, -1, -1, -1, 317, -1, -1, -1, 321, - 284, -1, 362, -1, 364, 365, -1, -1, 368, -1, - -1, 333, -1, 297, 336, 261, 338, 263, 302, -1, - -1, -1, -1, 307, -1, 309, 310, 311, 312, -1, - -1, 315, -1, 317, -1, -1, -1, 321, 284, -1, - 362, -1, 364, 365, -1, -1, 368, -1, -1, 333, - -1, 297, 336, 261, 338, -1, 302, -1, -1, -1, - -1, 307, -1, 309, 310, 311, 312, -1, -1, -1, - -1, 317, -1, -1, -1, 321, 284, -1, 362, -1, - -1, -1, -1, 261, 368, 263, -1, 333, -1, 297, - 336, -1, 338, -1, 302, -1, -1, -1, -1, 307, - -1, 309, 310, 311, 312, -1, 284, -1, -1, 317, - -1, -1, -1, 321, -1, -1, 362, -1, -1, 297, - -1, -1, 368, 261, 302, 333, -1, -1, 336, 307, - 338, 309, 310, 311, 312, -1, -1, 315, -1, 317, - -1, -1, -1, 321, -1, -1, 284, -1, -1, -1, - -1, -1, -1, 261, 362, 333, 364, 365, 336, 297, - 338, -1, -1, 301, 302, -1, -1, -1, -1, 307, - -1, 309, 310, 311, 312, -1, 284, -1, -1, 317, - -1, -1, -1, 321, 362, -1, -1, -1, -1, 297, - -1, -1, -1, -1, 302, 333, -1, -1, 336, 307, - 338, 309, 310, 311, 312, -1, -1, -1, -1, 317, - -1, -1, -1, 321, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 362, 333, -1, -1, 336, -1, - 338, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 315, -1, 317, -1, -1, -1, 321, 284, -1, 362, + -1, 364, 365, -1, -1, 368, -1, -1, 333, -1, + 297, 336, 261, 338, 263, 302, -1, -1, -1, -1, + 307, -1, 309, 310, 311, 312, -1, -1, -1, -1, + 317, -1, -1, -1, 321, 284, -1, 362, -1, -1, + -1, -1, 261, 368, -1, -1, 333, -1, 297, 336, + -1, 338, -1, 302, -1, -1, -1, -1, 307, -1, + 309, 310, 311, 312, -1, 284, 315, -1, 317, -1, + -1, -1, 321, -1, 261, 362, -1, -1, 297, -1, + -1, 368, 301, 302, 333, -1, -1, 336, 307, 338, + 309, 310, 311, 312, -1, -1, -1, 284, 317, -1, + -1, -1, 321, -1, -1, -1, -1, -1, -1, -1, + 297, -1, -1, 362, 333, 302, -1, 336, -1, 338, + 307, -1, 309, 310, 311, 312, -1, -1, -1, -1, + 317, -1, -1, -1, 321, -1, -1, -1, -1, -1, + -1, -1, -1, 362, -1, -1, 333, -1, -1, 336, + -1, 338, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 362, + -1, -1, -1, -1, -1, 362, }; -#line 6455 "cs-parser.jay" +#line 6611 "cs-parser.jay" // // A class used to hold info about an operator declarator @@ -12421,51 +12779,34 @@ void Error_MissingInitializer (Location loc) report.Error (210, loc, "You must provide an initializer in a fixed or using statement declaration"); } -void push_current_class (TypeContainer tc, object partial_token) +void push_current_container (TypeDefinition tc, object partial_token) { - if (module.Evaluator != null && current_container is ModuleContainer){ + if (module.Evaluator != null){ tc.Definition.Modifiers = tc.ModFlags = (tc.ModFlags & ~Modifiers.AccessibilityMask) | Modifiers.PUBLIC; if (undo == null) undo = new Undo (); + undo.AddTypeContainer (current_container, tc); } - + if (partial_token != null) - current_container = current_container.AddPartial (tc); + current_container.AddPartial (tc); else - current_container = current_container.AddTypeContainer (tc); - + current_container.AddTypeContainer (tc); + ++lexer.parsing_declaration; - current_class = tc; - ubag.PushTypeDeclaration (tc); + current_container = tc; + current_type = tc; } TypeContainer pop_current_class () { - var retval = current_class; + var retval = current_container; - current_class = current_class.Parent; - current_container = current_class.PartialContainer; - ubag.PopTypeDeclaration (); - - return retval; -} + current_container = current_container.Parent; + current_type = current_type.Parent as TypeDefinition; -// -// Given the @class_name name, it creates a fully qualified name -// based on the containing declaration space -// -MemberName -MakeName (MemberName class_name) -{ - if (current_container == module) { - if (current_namespace.MemberName != MemberName.Null) - return new MemberName (current_namespace.NS.MemberName, class_name); - else - return class_name; - } else { - return new MemberName (current_container.MemberName, class_name); - } + return retval; } [System.Diagnostics.Conditional ("FULL_AST")] @@ -12535,26 +12876,31 @@ static CSharpParser () } public CSharpParser (SeekableStreamReader reader, CompilationSourceFile file) - : this (reader, file, file.NamespaceContainer.Module.Compiler.Report) + : this (reader, file, file.Compiler.Report) { } public CSharpParser (SeekableStreamReader reader, CompilationSourceFile file, Report report) { this.file = file; - current_namespace = file.NamespaceContainer; + current_container = current_namespace = file; - this.module = current_namespace.Module; - this.compiler = module.Compiler; + this.module = file.Module; + this.compiler = file.Compiler; this.settings = compiler.Settings; this.report = report; lang_version = settings.Version; + yacc_verbose_flag = settings.VerboseParserFlag; doc_support = settings.DocumentationFile != null; - current_class = current_namespace.SlaveDeclSpace; - current_container = current_class.PartialContainer; // == RootContest.ToplevelTypes oob_stack.Clear (); - lexer = new Tokenizer (reader, file, compiler); + lexer = new Tokenizer (reader, file); + +#if FULL_AST + lbag = new LocationsBag (); +#else + lbag = null; +#endif use_global_stacks = true; } @@ -12583,10 +12929,10 @@ public void parse () report.Error (-25, lexer.Location, "Parsing error"); } else { // Used by compiler-tester to test internal errors - if (yacc_verbose_flag > 0) + if (yacc_verbose_flag > 0 || e is FatalException) throw; - report.Error (589, lexer.Location, "Internal compiler error during parsing"); + report.Error (589, lexer.Location, "Internal compiler error during parsing" + e); } } } @@ -12633,18 +12979,6 @@ public LocationsBag LocationsBag { get { return lbag; } - set { - lbag = value; - } -} - -public UsingsBag UsingsBag { - get { - return ubag; - } - set { - ubag = value; - } } void start_block (Location loc) diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/cs-parser.jay b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/cs-parser.jay index d7cf3dba5a..6e2e26750c 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/cs-parser.jay +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/cs-parser.jay @@ -45,9 +45,9 @@ namespace Mono.CSharp static readonly object ModifierNone = 0; - NamespaceContainer current_namespace; - TypeContainer current_container; - TypeContainer current_class; + NamespaceContainer current_namespace; + TypeContainer current_container; + TypeDefinition current_type; PropertyBase current_property; EventProperty current_event; EventField current_event_field; @@ -86,7 +86,7 @@ namespace Mono.CSharp /// /// Controls the verbosity of the errors produced by the parser /// - static public int yacc_verbose_flag; + int yacc_verbose_flag; /// /// Used by the interactive shell, flags whether EOF was reached @@ -143,11 +143,13 @@ namespace Mono.CSharp // Full AST support members // LocationsBag lbag; - UsingsBag ubag; List> mod_locations; Location parameterModifierLocation, savedLocation, savedOpenLocation, savedCloseLocation; Location savedAttrParenOpenLocation, savedAttrParenCloseLocation, savedOperatorLocation; Stack> locationListStack = new Stack> (); // used for type parameters + Stack opt_intoStack = new Stack (); + + bool HadAttributeParens; List attributeCommas = new List (); List attributeArgumentCommas = new List (); List parameterListCommas = new List (); @@ -398,6 +400,8 @@ outer_declaration Attributes attrs = (Attributes) $4; report.Error (1730, attrs.Attrs [0].Location, "Assembly and module attributes must precede all other elements except using clauses and extern alias declarations"); + + current_namespace.UnattachedAttributes = attrs; } } | opt_extern_alias_directives opt_using_directives attribute_sections @@ -470,7 +474,6 @@ using_namespace var un = new UsingNamespace ((ATypeNameExpression) $2, GetLocation ($1)); current_namespace.AddUsing (un); - ubag.AddUsing (GetLocation ($1), (ATypeNameExpression) $2, GetLocation ($3)); lbag.AddLocation (un, GetLocation ($3)); } | USING IDENTIFIER ASSIGN namespace_or_type_expr SEMICOLON @@ -483,8 +486,6 @@ using_namespace var un = new UsingAliasNamespace (new SimpleMemberName (lt.Value, lt.Location), (ATypeNameExpression) $4, GetLocation ($1)); current_namespace.AddUsing (un); - ubag.AddUsingAlias (GetLocation ($1), lt, GetLocation ($3), (ATypeNameExpression) $4, GetLocation ($5)); - lbag.AddLocation (un, GetLocation ($3), GetLocation ($5)); } | USING error @@ -506,7 +507,7 @@ namespace_declaration var name = (MemberName) $3; if (attrs != null) { bool valid_global_attrs = true; - if ((current_namespace.DeclarationFound || current_namespace != file.NamespaceContainer)) { + if ((current_namespace.DeclarationFound || current_namespace != file)) { valid_global_attrs = false; } else { foreach (var a in attrs.Attrs) { @@ -524,29 +525,23 @@ namespace_declaration module.AddAttributes (attrs, current_namespace); - current_namespace = new NamespaceContainer (name, module, current_namespace, file); - module.AddTypesContainer (current_namespace); - current_class = current_namespace.SlaveDeclSpace; - current_container = current_class.PartialContainer; - - ubag.DeclareNamespace (GetLocation ($2), name); + var ns = new NamespaceContainer (name, current_namespace); + current_namespace.AddTypeContainer (ns); + current_container = current_namespace = ns; } OPEN_BRACE { if (doc_support) Lexer.doc_state = XmlCommentState.Allowed; - ubag.OpenNamespace (GetLocation ($5)); } opt_extern_alias_directives opt_using_directives opt_namespace_or_type_declarations CLOSE_BRACE opt_semicolon { - current_namespace = current_namespace.Parent; - current_class = current_namespace.SlaveDeclSpace; - current_container = current_class.PartialContainer; - ubag.CloseNamespace (GetLocation ($10)); if ($11 != null) - ubag.EndNamespace (GetLocation ($11)); + lbag.AddLocation (current_container, GetLocation ($2), GetLocation ($5), GetLocation ($10), GetLocation ($11)); else - ubag.EndNamespace (); + lbag.AddLocation (current_container, GetLocation ($2), GetLocation ($5), GetLocation ($10)); + + current_container = current_namespace = current_namespace.Parent; } ; @@ -615,7 +610,7 @@ namespace_or_type_declaration // we parse succeeding declaration hence we parse them as normal and re-attach them // when we know whether they are global (assembly:, module:) or local (type:). if (ds.OptAttributes != null) { - ds.OptAttributes.ConvertGlobalAttributes (ds, current_namespace, !current_namespace.DeclarationFound && current_namespace == file.NamespaceContainer); + ds.OptAttributes.ConvertGlobalAttributes (ds, current_namespace, !current_namespace.DeclarationFound && current_namespace == file); } } current_namespace.DeclarationFound = true; @@ -624,6 +619,11 @@ namespace_or_type_declaration { current_namespace.DeclarationFound = true; } + | attribute_sections CLOSE_BRACE { + current_namespace.UnattachedAttributes = (Attributes) $1; + report.Error (1518, lexer.Location, "Attributes must be attached to class, delegate, enum, interface or struct"); + lexer.putback ('}'); + } ; type_declaration @@ -782,6 +782,8 @@ attribute attributeArgumentCommas.Add (savedAttrParenCloseLocation); lbag.AddLocation ($$, attributeArgumentCommas); attributeArgumentCommas.Clear (); + } else if (HadAttributeParens) { + lbag.AddLocation ($$, savedAttrParenOpenLocation, savedAttrParenCloseLocation); } } ; @@ -791,12 +793,13 @@ attribute_name ; opt_attribute_arguments - : /* empty */ { $$ = null; } + : /* empty */ { $$ = null; HadAttributeParens = false; } | OPEN_PARENS attribute_arguments CLOSE_PARENS { savedAttrParenOpenLocation = GetLocation ($1); savedAttrParenCloseLocation = GetLocation ($3); $$ = $2; + HadAttributeParens = true; } ; @@ -918,6 +921,7 @@ class_member_declaration | constructor_declaration | destructor_declaration | type_declaration + | attributes_without_members | error { report.Error (1519, lexer.Location, "Unexpected symbol `{0}' in class, struct, or interface member declaration", @@ -937,9 +941,8 @@ struct_declaration } type_declaration_name { - MemberName name = MakeName ((MemberName) $6); - push_current_class (new Struct (current_namespace, current_class, name, (Modifiers) $2, (Attributes) $1), $3); - lbag.AddMember (current_class, GetModifierLocations (), GetLocation ($4)); + push_current_container (new Struct (current_container, (MemberName) $6, (Modifiers) $2, (Attributes) $1), $3); + lbag.AddMember (current_container, GetModifierLocations (), GetLocation ($4)); } opt_class_base opt_type_parameter_constraints_clauses @@ -947,10 +950,10 @@ struct_declaration lexer.ConstraintsParsing = false; if ($9 != null) - current_class.SetConstraints ((List) $9); + current_container.SetConstraints ((List) $9); if (doc_support) - current_container.DocComment = Lexer.consume_doc_comment (); + current_container.PartialContainer.DocComment = Lexer.consume_doc_comment (); lexer.parsing_modifiers = true; @@ -962,15 +965,17 @@ struct_declaration } opt_class_member_declarations CLOSE_BRACE { - lbag.AppendToMember (current_class, GetLocation ($11), GetLocation ($13)); --lexer.parsing_declaration; if (doc_support) Lexer.doc_state = XmlCommentState.Allowed; } opt_semicolon { - if ($15 != null) - current_class.OptionalSemicolon = GetLocation ($15); + if ($16 == null) { + lbag.AppendToMember (current_container, GetLocation ($11), GetLocation ($14)); + } else { + lbag.AppendToMember (current_container, GetLocation ($11), GetLocation ($14), GetLocation ($16)); + } $$ = pop_current_class (); } | opt_attributes opt_modifiers opt_partial STRUCT error @@ -986,8 +991,8 @@ constant_declaration { var lt = (Tokenizer.LocatedToken) $5; var mod = (Modifiers) $2; - current_field = new Const (current_class, (FullNamedExpression) $4, mod, new MemberName (lt.Value, lt.Location), (Attributes) $1); - current_container.AddConstant ((Const) current_field); + current_field = new Const (current_type, (FullNamedExpression) $4, mod, new MemberName (lt.Value, lt.Location), (Attributes) $1); + current_type.AddMember (current_field); if ((mod & Modifiers.STATIC) != 0) { report.Error (504, current_field.Location, "The constant `{0}' cannot be marked static", current_field.GetSignatureForError ()); @@ -1068,8 +1073,8 @@ field_declaration report.Error (670, GetLocation ($3), "Fields cannot have void type"); var lt = (Tokenizer.LocatedToken) $4; - current_field = new Field (current_class, type, (Modifiers) $2, new MemberName (lt.Value, lt.Location), (Attributes) $1); - current_container.AddField (current_field); + current_field = new Field (current_type, type, (Modifiers) $2, new MemberName (lt.Value, lt.Location), (Attributes) $1); + current_type.AddField (current_field); $$ = current_field; } opt_field_initializer @@ -1093,10 +1098,10 @@ field_declaration FeatureIsNotAvailable (GetLocation ($3), "fixed size buffers"); var lt = (Tokenizer.LocatedToken) $5; - current_field = new FixedField (current_class, (FullNamedExpression) $4, (Modifiers) $2, + current_field = new FixedField (current_type, (FullNamedExpression) $4, (Modifiers) $2, new MemberName (lt.Value, lt.Location), (Attributes) $1); - current_container.AddField (current_field); + current_type.AddField (current_field); } fixed_field_size opt_fixed_field_declarators SEMICOLON { @@ -1236,7 +1241,7 @@ method_declaration // Add it early in the case of body being eof for full ast Method m = (Method) $1; async_block = (m.ModFlags & Modifiers.ASYNC) != 0; - current_container.AddMethod (m); + current_type.AddMember (m); } method_body { @@ -1285,7 +1290,7 @@ method_header MemberName name = (MemberName) $4; current_local_parameters = (ParametersCompiled) $7; - var method = Method.Create (current_class, (FullNamedExpression) $3, (Modifiers) $2, + var method = Method.Create (current_type, (FullNamedExpression) $3, (Modifiers) $2, name, current_local_parameters, (Attributes) $1, $10 != null); if ($10 != null) @@ -1325,7 +1330,7 @@ method_header var modifiers = (Modifiers) $2; modifiers |= Modifiers.PARTIAL; - var method = Method.Create (current_class, new TypeExpression (compiler.BuiltinTypes.Void, GetLocation ($4)), + var method = Method.Create (current_type, new TypeExpression (compiler.BuiltinTypes.Void, GetLocation ($4)), modifiers, name, current_local_parameters, (Attributes) $1, $11 != null); if ($11 != null) @@ -1347,11 +1352,28 @@ method_header report.Error (1585, name.Location, "Member modifier `{0}' must precede the member type and name", ModifiersExtensions.Name ((Modifiers) $4)); - var method = Method.Create (current_class, (FullNamedExpression) $3, + var method = Method.Create (current_type, (FullNamedExpression) $3, 0, name, (ParametersCompiled) $7, (Attributes) $1, false); current_local_parameters = (ParametersCompiled) $7; + if (doc_support) + method.DocComment = Lexer.consume_doc_comment (); + + $$ = method; + } + | opt_attributes + opt_modifiers + member_type + method_declaration_name error + { + Error_SyntaxError (yyToken); + current_local_parameters = ParametersCompiled.Undefined; + + MemberName name = (MemberName) $4; + var method = Method.Create (current_type, (FullNamedExpression) $3, (Modifiers) $2, + name, current_local_parameters, (Attributes) $1, false); + if (doc_support) method.DocComment = Lexer.consume_doc_comment (); @@ -1499,12 +1521,18 @@ fixed_parameter $$ = new Parameter ((FullNamedExpression) $3, lt.Value, (Parameter.Modifier) $2, (Attributes) $1, lt.Location); lbag.AddLocation ($$, parameterModifierLocation); } + | attribute_sections error + { + Error_SyntaxError (yyToken); + Location l = GetLocation ($2); + $$ = new Parameter (null, null, Parameter.Modifier.NONE, (Attributes) $1, l); + } | opt_attributes opt_parameter_modifier parameter_type error { - Error_SyntaxError (yyToken); + Error_SyntaxError (yyToken); Location l = GetLocation ($4); $$ = new Parameter ((FullNamedExpression) $3, null, (Parameter.Modifier) $2, (Attributes) $1, l); lbag.AddLocation ($$, parameterModifierLocation); @@ -1681,13 +1709,13 @@ property_declaration OPEN_BRACE { var type = (FullNamedExpression) $3; - current_property = new Property (current_class, type, (Modifiers) $2, + current_property = new Property (current_type, type, (Modifiers) $2, (MemberName) $4, (Attributes) $1); if (type.Type != null && type.Type.Kind == MemberKind.Void) report.Error (547, GetLocation ($3), "`{0}': property or indexer cannot have void type", current_property.GetSignatureForError ()); - current_container.AddProperty ((Property)current_property); + current_type.AddMember (current_property); lbag.AddMember (current_property, GetModifierLocations (), GetLocation ($6)); lexer.PropertyParsing = true; @@ -1717,11 +1745,11 @@ indexer_declaration { valid_param_mod = 0; var type = (FullNamedExpression) $3; - Indexer indexer = new Indexer (current_class, type, (MemberName) $4, (Modifiers) $2, (ParametersCompiled) $7, (Attributes) $1); + Indexer indexer = new Indexer (current_type, type, (MemberName) $4, (Modifiers) $2, (ParametersCompiled) $7, (Attributes) $1); current_property = indexer; - current_container.AddIndexer (indexer); + current_type.AddIndexer (indexer); lbag.AddMember (current_property, GetModifierLocations (), GetLocation ($5), GetLocation ($8), GetLocation ($9)); if (type.Type != null && type.Type.Kind == MemberKind.Void) @@ -1893,9 +1921,8 @@ interface_declaration } type_declaration_name { - MemberName name = MakeName ((MemberName) $6); - push_current_class (new Interface (current_namespace, current_class, name, (Modifiers) $2, (Attributes) $1), $3); - lbag.AddMember (current_class, GetModifierLocations (), GetLocation ($4)); + push_current_container (new Interface (current_container, (MemberName) $6, (Modifiers) $2, (Attributes) $1), $3); + lbag.AddMember (current_container, GetModifierLocations (), GetLocation ($4)); } opt_class_base opt_type_parameter_constraints_clauses @@ -1903,10 +1930,10 @@ interface_declaration lexer.ConstraintsParsing = false; if ($9 != null) - current_class.SetConstraints ((List) $9); + current_container.SetConstraints ((List) $9); if (doc_support) { - current_container.DocComment = Lexer.consume_doc_comment (); + current_container.PartialContainer.DocComment = Lexer.consume_doc_comment (); Lexer.doc_state = XmlCommentState.Allowed; } @@ -1920,9 +1947,11 @@ interface_declaration } opt_semicolon { - if ($15 != null) - current_class.OptionalSemicolon = GetLocation ($15); - lbag.AppendToMember (current_class, GetLocation ($11), GetLocation ($13)); + if ($15 == null) { + lbag.AppendToMember (current_container, GetLocation ($11), GetLocation ($13)); + } else { + lbag.AppendToMember (current_container, GetLocation ($11), GetLocation ($13), GetLocation ($15)); + } $$ = pop_current_class (); } | opt_attributes opt_modifiers opt_partial INTERFACE error @@ -1983,7 +2012,7 @@ operator_declaration OperatorDeclaration decl = (OperatorDeclaration) $3; if (decl != null) { Operator op = new Operator ( - current_class, decl.optype, decl.ret_type, (Modifiers) $2, + current_type, decl.optype, decl.ret_type, (Modifiers) $2, current_local_parameters, (ToplevelBlock) $5, (Attributes) $1, decl.location); @@ -1996,7 +2025,7 @@ operator_declaration } // Note again, checking is done in semantic analysis - current_container.AddOperator (op); + current_type.AddOperator (op); lbag.AddMember (op, GetModifierLocations (), lbag.GetLocations (decl)); if ($5 == null) { // Semicolon @@ -2186,7 +2215,7 @@ constructor_declarator var lt = (Tokenizer.LocatedToken) $3; var mods = (Modifiers) $2; - var c = new Constructor (current_class, lt.Value, mods, (Attributes) $1, current_local_parameters, lt.Location); + var c = new Constructor (current_type, lt.Value, mods, (Attributes) $1, current_local_parameters, lt.Location); if (lt.Value != current_container.MemberName.Name) { report.Error (1520, c.Location, "Class, struct, or interface method must have a return type"); @@ -2198,7 +2227,7 @@ constructor_declarator } } - current_container.AddConstructor (c); + current_type.AddConstructor (c); lbag.AddMember (c, GetModifierLocations (), GetLocation ($5), GetLocation ($7)); $$ = c; @@ -2258,8 +2287,8 @@ constructor_initializer } | COLON error { - Error_SyntaxError (yyToken); - $$ = new ConstructorThisInitializer (null, GetLocation ($1)); + Error_SyntaxError (yyToken); + $$ = new ConstructorThisInitializer (null, GetLocation ($2)); lbag.AddLocation ($$, GetLocation ($1)); } | error @@ -2288,13 +2317,14 @@ destructor_declaration report.Error (575, lt.Location, "Only class types can contain destructor"); } - Destructor d = new Destructor (current_class, (Modifiers) $2, + Destructor d = new Destructor (current_type, (Modifiers) $2, ParametersCompiled.EmptyReadOnlyParameters, (Attributes) $1, lt.Location); + d.Identifier = lt.Value; if (doc_support) d.DocComment = ConsumeStoredComment (); d.Block = (ToplevelBlock) $8; - current_container.AddMethod (d); + current_type.AddMember (d); lbag.AddMember (d, GetModifierLocations (), GetLocation ($3), GetLocation ($6), GetLocation ($7)); current_local_parameters = null; @@ -2306,8 +2336,8 @@ event_declaration opt_modifiers EVENT type member_declaration_name { - current_event_field = new EventField (current_class, (FullNamedExpression) $4, (Modifiers) $2, (MemberName) $5, (Attributes) $1); - current_container.AddEvent (current_event_field); + current_event_field = new EventField (current_type, (FullNamedExpression) $4, (Modifiers) $2, (MemberName) $5, (Attributes) $1); + current_type.AddMember (current_event_field); if (current_event_field.MemberName.ExplicitInterface != null) { report.Error (71, current_event_field.Location, "`{0}': An explicit interface implementation of an event must use property syntax", @@ -2333,8 +2363,8 @@ event_declaration EVENT type member_declaration_name OPEN_BRACE { - current_event = new EventProperty (current_class, (FullNamedExpression) $4, (Modifiers) $2, (MemberName) $5, (Attributes) $1); - current_container.AddEvent (current_event); + current_event = new EventProperty (current_type, (FullNamedExpression) $4, (Modifiers) $2, (MemberName) $5, (Attributes) $1); + current_type.AddMember (current_event); lbag.AddMember (current_event, GetModifierLocations (), GetLocation ($3), GetLocation ($6)); lexer.EventParsing = true; @@ -2511,6 +2541,15 @@ event_accessor_block | block; ; +attributes_without_members + : attribute_sections CLOSE_BRACE + { + current_type.UnattachedAttributes = (Attributes) $1; + report.Error (1519, GetLocation ($1), "An attribute is missing member declaration"); + lexer.putback ('}'); + } + ; + enum_declaration : opt_attributes opt_modifiers @@ -2531,11 +2570,11 @@ enum_declaration report.Error (1675, name.Location, "Enums cannot have type parameters"); } - push_current_class (new Enum (current_namespace, current_class, (TypeExpression) $5, (Modifiers) $2, MakeName (name), (Attributes) $1), null); + push_current_container (new Enum (current_container, (FullNamedExpression) $5, (Modifiers) $2, name, (Attributes) $1), null); if ($5 != null) { - lbag.AddMember (current_class, GetModifierLocations (), GetLocation ($3), savedLocation, GetLocation ($7)); + lbag.AddMember (current_container, GetModifierLocations (), GetLocation ($3), savedLocation, GetLocation ($7)); } else { - lbag.AddMember (current_class, GetModifierLocations (), GetLocation ($3), GetLocation ($7)); + lbag.AddMember (current_container, GetModifierLocations (), GetLocation ($3), GetLocation ($7)); } } opt_enum_member_declarations @@ -2546,16 +2585,18 @@ enum_declaration } CLOSE_BRACE opt_semicolon { - lbag.AppendToMember (current_class, GetLocation ($11)); + lbag.AppendToMember (current_container, GetLocation ($11)); if ($12 != null) { - current_class.OptionalSemicolon = GetLocation ($12); - lbag.AppendToMember (current_class, GetLocation ($12)); + lbag.AppendToMember (current_container, GetLocation ($12)); } if (doc_support) - current_class.DocComment = enumTypeComment; + current_container.DocComment = enumTypeComment; --lexer.parsing_declaration; +// if (doc_support) +// em.DocComment = ev.DocComment; + $$ = pop_current_class (); } ; @@ -2564,14 +2605,8 @@ opt_enum_base : /* empty */ | COLON type { - var te = $2 as TypeExpression; - if (te == null || !EnumSpec.IsValidUnderlyingType (te.Type)) { - Enum.Error_1008 (GetLocation ($2), report); - $$ = null; - } else { - savedLocation = GetLocation ($1); - $$ = $2; - } + savedLocation = GetLocation ($1); + $$ = $2; } | COLON error { @@ -2585,7 +2620,7 @@ opt_enum_member_declarations | enum_member_declarations | enum_member_declarations COMMA { - lbag.AppendToMember (current_class, GetLocation ($2)); + lbag.AppendToMember (current_container, GetLocation ($2)); } ; @@ -2593,7 +2628,7 @@ enum_member_declarations : enum_member_declaration | enum_member_declarations COMMA enum_member_declaration { - lbag.AppendToMember (current_class, GetLocation ($2)); + lbag.AppendToMember (current_container, GetLocation ($2)); $$ = $3; } ; @@ -2602,8 +2637,8 @@ enum_member_declaration : opt_attributes IDENTIFIER { var lt = (Tokenizer.LocatedToken) $2; - var em = new EnumMember ((Enum) current_class, new MemberName (lt.Value, lt.Location), (Attributes) $1); - ((Enum) current_class).AddEnumMember (em); + var em = new EnumMember ((Enum) current_type, new MemberName (lt.Value, lt.Location), (Attributes) $1); + ((Enum) current_type).AddEnumMember (em); if (doc_support) { em.DocComment = Lexer.consume_doc_comment (); @@ -2625,9 +2660,9 @@ enum_member_declaration --lexer.parsing_block; var lt = (Tokenizer.LocatedToken) $2; - var em = new EnumMember ((Enum) current_class, new MemberName (lt.Value, lt.Location), (Attributes) $1); + var em = new EnumMember ((Enum) current_type, new MemberName (lt.Value, lt.Location), (Attributes) $1); em.Initializer = new ConstInitializer (em, (Expression) $5, GetLocation ($4)); - ((Enum) current_class).AddEnumMember (em); + ((Enum) current_type).AddEnumMember (em); if (doc_support) em.DocComment = ConsumeStoredComment (); @@ -2649,17 +2684,14 @@ delegate_declaration { valid_param_mod = 0; - MemberName name = MakeName ((MemberName) $5); ParametersCompiled p = (ParametersCompiled) $8; - Delegate del = new Delegate (current_namespace, current_class, (FullNamedExpression) $4, - (Modifiers) $2, name, p, (Attributes) $1); + Delegate del = new Delegate (current_container, (FullNamedExpression) $4, (Modifiers) $2, (MemberName) $5, p, (Attributes) $1); + p.CheckParameters (del); - ubag.PushTypeDeclaration (del); - ubag.PopTypeDeclaration (); + current_container.AddTypeContainer (del); - current_container.AddDelegate (del); current_delegate = del; lexer.ConstraintsParsing = true; } @@ -2805,12 +2837,12 @@ indexer_declaration_name : THIS { lexer.parsing_generic_declaration = false; - $$ = new MemberName (TypeContainer.DefaultIndexerName, GetLocation ($1)); + $$ = new MemberName (TypeDefinition.DefaultIndexerName, GetLocation ($1)); } | explicit_interface THIS { lexer.parsing_generic_declaration = false; - $$ = new MemberName (TypeContainer.DefaultIndexerName, null, (ATypeNameExpression) $1, GetLocation ($2)); + $$ = new MemberName (TypeDefinition.DefaultIndexerName, null, (ATypeNameExpression) $1, GetLocation ($2)); } ; @@ -2845,7 +2877,10 @@ opt_type_parameter_list FeatureIsNotAvailable (GetLocation ($1), "generics"); $$ = $2; - lbag.AppendTo ($$, GetLocation ($1), GetLocation ($3)); + var list = locationListStack.Pop (); + list.Add (GetLocation ($1)); + list.Add (GetLocation ($2)); + lbag.AddLocation ($2, list); } ; @@ -2855,13 +2890,14 @@ type_parameters var tparams = new TypeParameters (); tparams.Add ((TypeParameter)$1); $$ = tparams; + locationListStack.Push (new List ()); } | type_parameters COMMA type_parameter { var tparams = (TypeParameters) $1; tparams.Add ((TypeParameter)$3); $$ = tparams; - lbag.AddLocation ($3, GetLocation ($3)); + locationListStack.Peek ().Add (GetLocation ($2)); } ; @@ -2994,11 +3030,6 @@ base_type_name } $$ = $1; } - | error - { - Error_TypeExpected (lexer.Location); - $$ = null; - } ; /* @@ -3240,8 +3271,10 @@ member_initializer { if ($2 == null) $$ = null; - else + else { $$ = new CollectionElementInitializer ((List)$2, GetLocation ($1)); + lbag.AddLocation ($$, GetLocation ($2)); + } } | OPEN_BRACE CLOSE_BRACE { @@ -3292,10 +3325,10 @@ argument_list lbag.AppendTo (list, GetLocation ($2)); $$ = list; } - | argument_list COMMA + | argument_list COMMA error { - report.Error (839, GetLocation ($2), "An argument is missing"); - $$ = $1; + Error_SyntaxError (yyToken); + $$ = $1; } | COMMA error { @@ -3352,10 +3385,12 @@ element_access } | primary_expression OPEN_BRACKET_EXPR expression_list_arguments error { + Error_SyntaxError (yyToken); $$ = new ElementAccess ((Expression) $1, (Arguments) $3, GetLocation ($2)); } | primary_expression OPEN_BRACKET_EXPR error { + Error_SyntaxError (yyToken); $$ = new ElementAccess ((Expression) $1, null, GetLocation ($2)); } ; @@ -3496,8 +3531,9 @@ array_creation_expression } | NEW new_expr_type error { - Error_SyntaxError (1526, yyToken, "Unexpected symbol"); - $$ = new ArrayCreation ((FullNamedExpression) $2, null, GetLocation ($1)); + Error_SyntaxError (yyToken); + // It can be any of new expression, create the most common one + $$ = new New ((FullNamedExpression) $2, null, GetLocation ($1)); } ; @@ -3865,8 +3901,16 @@ unary_expression | AWAIT prefixed_unary_expression { if (!async_block) { - report.Error (1992, GetLocation ($1), - "The `await' operator can only be used when its containing method or lambda expression is marked with the `async' modifier"); + if (current_anonymous_method is LambdaExpression) { + report.Error (4034, GetLocation ($1), + "The `await' operator can only be used when its containing lambda expression is marked with the `async' modifier"); + } else if (current_anonymous_method is AnonymousMethodExpression) { + report.Error (4035, GetLocation ($1), + "The `await' operator can only be used when its containing anonymous method is marked with the `async' modifier"); + } else { + report.Error (4033, GetLocation ($1), + "The `await' operator can only be used when its containing method is marked with the `async' modifier"); + } } else { current_block.Explicit.RegisterAsyncAwait (); } @@ -4062,11 +4106,16 @@ null_coalescing_expression conditional_expression : null_coalescing_expression - | null_coalescing_expression INTERR expression COLON expression + | null_coalescing_expression INTERR expression COLON expression_or_error { $$ = new Conditional (new BooleanExpression ((Expression) $1), (Expression) $3, (Expression) $5, GetLocation ($2)); lbag.AddLocation ($$, GetLocation ($4)); } + | null_coalescing_expression INTERR expression error + { + Error_SyntaxError (yyToken); + $$ = new Conditional (new BooleanExpression ((Expression) $1), (Expression) $3, null, GetLocation ($2)); + } ; assignment_expression @@ -4185,11 +4234,11 @@ lambda_expression_body lambda_expression_body_simple : { - start_block (lexer.Location); + start_block (Location.Null); } expression_or_error // Have to close block when error occurs { - Block b = end_block (lexer.Location); + Block b = end_block (Location.Null); b.IsCompilerGenerated = true; b.AddStatement (new ContextualReturn ((Expression) $2)); $$ = b; @@ -4315,13 +4364,13 @@ class_declaration } type_declaration_name { - MemberName name = MakeName ((MemberName) $6); - Class c = new Class (current_namespace, current_class, name, (Modifiers) $2, (Attributes) $1); + Class c = new Class (current_container, (MemberName) $6, (Modifiers) $2, (Attributes) $1); if (((c.ModFlags & Modifiers.STATIC) != 0) && lang_version == LanguageVersion.ISO_1) { FeatureIsNotAvailable (c.Location, "static classes"); } - - push_current_class (c, $3); + + push_current_container (c, $3); + lbag.AddMember (current_container, GetModifierLocations (), GetLocation ($4)); } opt_class_base opt_type_parameter_constraints_clauses @@ -4329,11 +4378,10 @@ class_declaration lexer.ConstraintsParsing = false; if ($9 != null) - current_class.SetConstraints ((List) $9); - lbag.AddMember (current_class, GetModifierLocations (), GetLocation ($4)); + current_container.SetConstraints ((List) $9); if (doc_support) { - current_container.DocComment = Lexer.consume_doc_comment (); + current_container.PartialContainer.DocComment = Lexer.consume_doc_comment (); Lexer.doc_state = XmlCommentState.Allowed; } @@ -4347,9 +4395,11 @@ class_declaration } opt_semicolon { - lbag.AppendToMember (current_class, GetLocation ($11), GetLocation ($13)); - if ($15 != null) - current_class.OptionalSemicolon = GetLocation ($15); + if ($15 == null) { + lbag.AppendToMember (current_container, GetLocation ($11), GetLocation ($13)); + } else { + lbag.AppendToMember (current_container, GetLocation ($11), GetLocation ($13), GetLocation ($15)); + } $$ = pop_current_class (); } ; @@ -4400,7 +4450,7 @@ modifier $$ = Modifiers.NEW; StoreModifierLocation ($$, GetLocation ($1)); - if (current_container == module) + if (current_container.Kind == MemberKind.Namespace) report.Error (1530, GetLocation ($1), "Keyword `new' is not allowed on namespace elements"); } | PUBLIC @@ -4481,9 +4531,15 @@ opt_class_base : /* empty */ | COLON type_list { - lbag.AppendToMember (current_class, GetLocation ($1)); - current_container.AddBasesForPart (current_class, (List) $2); + current_type.AddBasesForPart ((List) $2); + lbag.AppendToMember (current_type, GetLocation ($1)); } + | COLON type_list error + { + Error_SyntaxError (yyToken); + + current_type.AddBasesForPart ((List) $2); + } ; opt_type_parameter_constraints_clauses @@ -4492,11 +4548,6 @@ opt_type_parameter_constraints_clauses { $$ = $1; } - | error - { - Error_SyntaxError (yyToken); - $$ = null; - } ; type_parameter_constraints_clauses @@ -4531,6 +4582,13 @@ type_parameter_constraints_clause $$ = new Constraints (new SimpleMemberName (lt.Value, lt.Location), (List) $4, GetLocation ($1)); lbag.AddLocation ($$, GetLocation ($3)); } + | WHERE IDENTIFIER error + { + Error_SyntaxError (yyToken); + + var lt = (Tokenizer.LocatedToken) $2; + $$ = new Constraints (new SimpleMemberName (lt.Value, lt.Location), null, GetLocation ($1)); + } ; type_parameter_constraints @@ -4665,6 +4723,11 @@ block_prepared { --lexer.parsing_block; $$ = end_block (GetLocation ($4)); + } | CLOSE_BRACE + { + report.Error (1525, GetLocation ($1), "Unexpected symbol '}', expected '{'"); + lexer.putback ('}'); + $$ = end_block (GetLocation ($1)); } ; @@ -4915,7 +4978,7 @@ block_variable_declaration current_block.AddLocalName (li); current_variable = new BlockVariableDeclaration ((FullNamedExpression) $1, li); } - opt_local_variable_initializer opt_variable_declarators SEMICOLON + opt_local_variable_initializer opt_variable_declarators semicolon_or_handle_error_close_brace { $$ = current_variable; current_variable = null; @@ -4940,6 +5003,16 @@ block_variable_declaration } ; +semicolon_or_handle_error_close_brace + : SEMICOLON + | CLOSE_BRACE { + // Redundant, but wont regress + report.Error (1525, lexer.Location, "Unexpected symbol }"); + lexer.putback ('}'); + $$ = $1; + } + ; + opt_local_variable_initializer : /* empty */ | ASSIGN block_variable_initializer @@ -5069,6 +5142,12 @@ expression_statement lbag.AddStatement ($$, GetLocation ($2)); } | statement_expression COMPLETE_COMPLETION { $$ = $1; } + | statement_expression CLOSE_BRACE + { + $$ = $1; + report.Error (1002, GetLocation ($2), "; expected"); + lexer.putback ('}'); + } ; interactive_expression_statement @@ -5229,6 +5308,11 @@ switch_label $$ = new SwitchLabel ((Expression) $2, GetLocation ($1)); lbag.AddLocation ($$, GetLocation ($3)); } + | CASE constant_expression error + { + Error_SyntaxError (yyToken); + $$ = new SwitchLabel ((Expression) $2, GetLocation ($1)); + } | DEFAULT_COLON { $$ = new SwitchLabel (null, GetLocation ($1)); @@ -5287,6 +5371,7 @@ for_statement current_block.IsCompilerGenerated = true; For f = new For (GetLocation ($1)); current_block.AddStatement (f); + lbag.AddStatement (f, current_block.StartLocation); $$ = f; } for_statement_cont @@ -5299,24 +5384,57 @@ for_statement for_statement_cont : opt_for_initializer SEMICOLON { - ((For) $0).Initializer = (Statement) $1; + For f = (For) $0; + f.Initializer = (Statement) $1; + lbag.AppendTo (f, GetLocation ($2)); + $$ = f; + } + for_statement_condition + { + $$ = $4; } - opt_for_condition SEMICOLON + | opt_for_initializer CLOSE_PARENS { + report.Error (1525, GetLocation ($2), "Unexpected symbol ')', expected ';'"); + For f = (For) $0; + f.Initializer = (Statement) $1; + lbag.AppendTo (f, GetLocation ($2)); + $$ = end_block (GetLocation ($2)); + } + ; + +for_statement_condition + : opt_for_condition SEMICOLON { - ((For) $0).Condition = (BooleanExpression) $4; + For f = (For) $0; + f.Condition = (BooleanExpression) $1; + lbag.AppendTo (f, GetLocation ($2)); + $$ = f; } - opt_for_iterator CLOSE_PARENS + for_statement_end { - ((For) $0).Iterator = (Statement) $7; + $$ = $4; } + | boolean_expression CLOSE_PARENS { + report.Error (1525, GetLocation ($2), "Unexpected symbol ')', expected ';'"); + For f = (For) $0; + f.Condition = (BooleanExpression) $1; + lbag.AppendTo (f, GetLocation ($2)); + $$ = end_block (GetLocation ($2)); + } + ; + +for_statement_end + : opt_for_iterator CLOSE_PARENS embedded_statement { - if ($10 is EmptyStatement && lexer.peek_token () == Token.OPEN_BRACE) - Warning_EmptyStatement (GetLocation ($10)); + For f = (For) $0; + f.Iterator = (Statement) $1; + + if ($3 is EmptyStatement && lexer.peek_token () == Token.OPEN_BRACE) + Warning_EmptyStatement (GetLocation ($3)); - For f = ((For) $0); - f.Statement = (Statement) $10; - lbag.AddStatement (f, current_block.StartLocation, GetLocation ($2), GetLocation ($5), GetLocation ($8)); + f.Statement = (Statement) $3; + lbag.AppendTo (f, GetLocation ($2)); $$ = end_block (GetLocation ($2)); } @@ -5373,6 +5491,7 @@ statement_expression_list } else { sl.Add ((Statement) $3); lbag.AppendTo (sl, GetLocation ($2)); + } $$ = sl; @@ -5387,7 +5506,7 @@ foreach_statement start_block (GetLocation ($2)); current_block.IsCompilerGenerated = true; - Foreach f = new Foreach ((Expression) $3, null, null, null, GetLocation ($1)); + Foreach f = new Foreach ((Expression) $3, null, null, null, null, GetLocation ($1)); current_block.AddStatement (f); lbag.AddStatement (f, GetLocation ($2)); @@ -5396,7 +5515,7 @@ foreach_statement | FOREACH open_parens_any type identifier_inside_body error { Error_SyntaxError (yyToken); - + start_block (GetLocation ($2)); current_block.IsCompilerGenerated = true; @@ -5404,7 +5523,7 @@ foreach_statement var li = new LocalVariable (current_block, lt.Value, LocalVariable.Flags.ForeachVariable | LocalVariable.Flags.Used, lt.Location); current_block.AddLocalName (li); - Foreach f = new Foreach ((Expression) $3, li, null, null, GetLocation ($1)); + Foreach f = new Foreach ((Expression) $3, li, null, null, null, GetLocation ($1)); current_block.AddStatement (f); lbag.AddStatement (f, GetLocation ($2)); @@ -5423,12 +5542,12 @@ foreach_statement { if ($9 is EmptyStatement && lexer.peek_token () == Token.OPEN_BRACE) Warning_EmptyStatement (GetLocation ($9)); - - Foreach f = new Foreach ((Expression) $3, (LocalVariable) $8, (Expression) $6, (Statement) $9, GetLocation ($1)); - current_block.AddStatement (f); + Foreach f = new Foreach ((Expression) $3, (LocalVariable) $8, (Expression) $6, (Statement) $9, current_block, GetLocation ($1)); lbag.AddStatement (f, GetLocation ($2), GetLocation ($5), GetLocation ($7)); - $$ = end_block (GetLocation ($7)); + end_block (GetLocation ($7)); + + $$ = f; } | FOREACH open_parens_any type identifier_inside_body error { @@ -5437,7 +5556,7 @@ foreach_statement var lt = $4 as Tokenizer.LocatedToken; var li = lt != null ? new LocalVariable (current_block, lt.Value, LocalVariable.Flags.ForeachVariable | LocalVariable.Flags.Used, lt.Location) : null; - Foreach f = new Foreach ((Expression) $3, li, null, null, GetLocation ($1)); + Foreach f = new Foreach ((Expression) $3, li, null, null, null, GetLocation ($1)); current_block.AddStatement (f); lbag.AddStatement (f, GetLocation ($2)); @@ -5445,7 +5564,7 @@ foreach_statement } | FOREACH open_parens_any type error { - Foreach f = new Foreach ((Expression) $3, null, null, null, GetLocation ($1)); + Foreach f = new Foreach ((Expression) $3, null, null, null, null, GetLocation ($1)); current_block.AddStatement (f); lbag.AddStatement (f, GetLocation ($2)); @@ -5476,6 +5595,11 @@ continue_statement $$ = new Continue (GetLocation ($1)); lbag.AddStatement ($$, GetLocation ($2)); } + | CONTINUE error + { + Error_SyntaxError (yyToken); + $$ = new Continue (GetLocation ($1)); + } ; goto_statement @@ -5503,6 +5627,11 @@ return_statement $$ = new Return ((Expression) $2, GetLocation ($1)); lbag.AddStatement ($$, GetLocation ($3)); } + | RETURN error + { + Error_SyntaxError (yyToken); + $$ = new Return (null, GetLocation ($1)); + } ; throw_statement @@ -5511,6 +5640,11 @@ throw_statement $$ = new Throw ((Expression) $2, GetLocation ($1)); lbag.AddStatement ($$, GetLocation ($3)); } + | THROW error + { + Error_SyntaxError (yyToken); + $$ = new Throw (null, GetLocation ($1)); + } ; yield_statement @@ -5563,7 +5697,8 @@ try_statement } | TRY block catch_clauses FINALLY block { - $$ = new TryFinally (new TryCatch ((Block) $2, (List) $3, GetLocation ($1), true), (Block) $5, GetLocation ($1)); + var loc = GetLocation ($1); + $$ = new TryFinally (new TryCatch ((Block) $2, (List) $3, loc, true), (Block) $5, loc); lbag.AddStatement ($$, GetLocation ($4)); } | TRY block error @@ -5821,7 +5956,9 @@ first_from_clause var lt = (Tokenizer.LocatedToken) $2; var rv = new Linq.RangeVariable (lt.Value, lt.Location); - $$ = new Linq.QueryExpression (new Linq.QueryStartClause ((Linq.QueryBlock)current_block, (Expression)$4, rv, GetLocation ($1))); + var start = new Linq.QueryStartClause ((Linq.QueryBlock)current_block, (Expression)$4, rv, GetLocation ($1)); + lbag.AddLocation (start, GetLocation ($3)); + $$ = new Linq.QueryExpression (start); } | FROM_FIRST type identifier_inside_body IN expression { @@ -5829,11 +5966,11 @@ first_from_clause var lt = (Tokenizer.LocatedToken) $3; var rv = new Linq.RangeVariable (lt.Value, lt.Location); - $$ = new Linq.QueryExpression ( - new Linq.QueryStartClause ((Linq.QueryBlock)current_block, (Expression)$5, rv, GetLocation ($1)) { - IdentifierType = (FullNamedExpression)$2 - } - ); + var start = new Linq.QueryStartClause ((Linq.QueryBlock)current_block, (Expression)$5, rv, GetLocation ($1)) { + IdentifierType = (FullNamedExpression)$2 + }; + lbag.AddLocation (start, GetLocation ($4)); + $$ = new Linq.QueryExpression (start); } ; @@ -5844,7 +5981,9 @@ nested_from_clause var lt = (Tokenizer.LocatedToken) $2; var rv = new Linq.RangeVariable (lt.Value, lt.Location); - $$ = new Linq.QueryExpression (new Linq.QueryStartClause ((Linq.QueryBlock)current_block, (Expression)$4, rv, GetLocation ($1))); + var start = new Linq.QueryStartClause ((Linq.QueryBlock)current_block, (Expression)$4, rv, GetLocation ($1)); + lbag.AddLocation (start, GetLocation ($3)); + $$ = new Linq.QueryExpression (start); } | FROM type identifier_inside_body IN expression { @@ -5852,11 +5991,11 @@ nested_from_clause var lt = (Tokenizer.LocatedToken) $3; var rv = new Linq.RangeVariable (lt.Value, lt.Location); - $$ = new Linq.QueryExpression ( - new Linq.QueryStartClause ((Linq.QueryBlock)current_block, (Expression)$5, rv, GetLocation ($1)) { - IdentifierType = (FullNamedExpression)$2 - } - ); + var start = new Linq.QueryStartClause ((Linq.QueryBlock)current_block, (Expression)$5, rv, GetLocation ($1)) { + IdentifierType = (FullNamedExpression)$2 + }; + lbag.AddLocation (start, GetLocation ($4)); + $$ = new Linq.QueryExpression (start); } ; @@ -5865,7 +6004,7 @@ from_clause { current_block = new Linq.QueryBlock (current_block, lexer.Location); } - expression + expression_or_error { var lt = (Tokenizer.LocatedToken) $2; var sn = new Linq.RangeVariable (lt.Value, lt.Location); @@ -5873,14 +6012,15 @@ from_clause current_block.SetEndLocation (lexer.Location); current_block = current_block.Parent; - ((Linq.QueryBlock)current_block).AddRangeVariable (sn); + + lbag.AddLocation ($$, GetLocation ($3)); } | FROM type identifier_inside_body IN { current_block = new Linq.QueryBlock (current_block, lexer.Location); } - expression + expression_or_error { var lt = (Tokenizer.LocatedToken) $3; var sn = new Linq.RangeVariable (lt.Value, lt.Location); @@ -5893,11 +6033,13 @@ from_clause current_block = current_block.Parent; ((Linq.QueryBlock)current_block).AddRangeVariable (sn); + + lbag.AddLocation ($$, GetLocation ($4)); } ; query_body - : opt_query_body_clauses select_or_group_clause opt_query_continuation + : query_body_clauses select_or_group_clause opt_query_continuation { Linq.AQueryClause head = (Linq.AQueryClause)$2; @@ -5912,7 +6054,24 @@ query_body $$ = head; } - | opt_query_body_clauses COMPLETE_COMPLETION + | select_or_group_clause opt_query_continuation + { + Linq.AQueryClause head = (Linq.AQueryClause)$2; + + if ($1 != null) { + Linq.AQueryClause clause = (Linq.AQueryClause)$1; + clause.Tail.Next = head; + head = clause; + } + + $$ = head; + } + | query_body_clauses COMPLETE_COMPLETION + | query_body_clauses error + { + report.Error (742, GetLocation ($2), "Unexpected symbol `{0}'. A query body must end with select or group clause", GetSymbolName (yyToken)); + $$ = $1; + } | error { Error_SyntaxError (yyToken); @@ -5925,7 +6084,7 @@ select_or_group_clause { current_block = new Linq.QueryBlock (current_block, lexer.Location); } - expression + expression_or_error { $$ = new Linq.Select ((Linq.QueryBlock)current_block, (Expression)$3, GetLocation ($1)); @@ -5940,14 +6099,14 @@ select_or_group_clause current_block = new Linq.QueryBlock (current_block, lexer.Location); linq_clause_blocks.Push ((Linq.QueryBlock)current_block); } - expression + expression_or_error { current_block.SetEndLocation (lexer.Location); current_block = current_block.Parent; current_block = new Linq.QueryBlock (current_block, lexer.Location); } - BY expression + BY expression_or_error { $$ = new Linq.GroupBy ((Linq.QueryBlock)current_block, (Expression)$3, linq_clause_blocks.Pop (), (Expression)$6, GetLocation ($1)); lbag.AddLocation ($$, GetLocation ($5)); @@ -5957,11 +6116,6 @@ select_or_group_clause } ; -opt_query_body_clauses - : /* empty */ - | query_body_clauses - ; - query_body_clauses : query_body_clause | query_body_clauses query_body_clause @@ -5984,7 +6138,7 @@ let_clause { current_block = new Linq.QueryBlock (current_block, lexer.Location); } - expression + expression_or_error { var lt = (Tokenizer.LocatedToken) $2; var sn = new Linq.RangeVariable (lt.Value, lt.Location); @@ -6003,7 +6157,7 @@ where_clause { current_block = new Linq.QueryBlock (current_block, lexer.Location); } - expression + expression_or_error { $$ = new Linq.Where ((Linq.QueryBlock)current_block, (Expression)$3, GetLocation ($1)); @@ -6021,7 +6175,7 @@ join_clause current_block = new Linq.QueryBlock (current_block, lexer.Location); linq_clause_blocks.Push ((Linq.QueryBlock) current_block); } - expression ON + expression_or_error ON { current_block.SetEndLocation (lexer.Location); current_block = current_block.Parent; @@ -6029,7 +6183,7 @@ join_clause current_block = new Linq.QueryBlock (current_block, lexer.Location); linq_clause_blocks.Push ((Linq.QueryBlock) current_block); } - expression EQUALS + expression_or_error EQUALS { current_block.AddStatement (new ContextualReturn ((Expression) $8)); current_block.SetEndLocation (lexer.Location); @@ -6037,7 +6191,7 @@ join_clause current_block = new Linq.QueryBlock (current_block, lexer.Location); } - expression opt_join_into + expression_or_error opt_join_into { current_block.AddStatement (new ContextualReturn ((Expression) $11)); current_block.SetEndLocation (lexer.Location); @@ -6069,7 +6223,7 @@ join_clause into = new Linq.RangeVariable (lt.Value, lt.Location); $$ = new Linq.GroupJoin (block, sn, (Expression)$5, outer_selector, (Linq.QueryBlock) current_block, into, GetLocation ($1)); - lbag.AddLocation ($$, GetLocation ($3), GetLocation ($6), GetLocation ($9), GetLocation ($12)); + lbag.AddLocation ($$, GetLocation ($3), GetLocation ($6), GetLocation ($9), opt_intoStack.Pop ()); } current_block = block.Parent; @@ -6083,7 +6237,7 @@ join_clause current_block = new Linq.QueryBlock (current_block, lexer.Location); linq_clause_blocks.Push ((Linq.QueryBlock) current_block); } - expression ON + expression_or_error ON { current_block.SetEndLocation (lexer.Location); current_block = current_block.Parent; @@ -6091,7 +6245,7 @@ join_clause current_block = new Linq.QueryBlock (current_block, lexer.Location); linq_clause_blocks.Push ((Linq.QueryBlock) current_block); } - expression EQUALS + expression_or_error EQUALS { current_block.AddStatement (new ContextualReturn ((Expression) $9)); current_block.SetEndLocation (lexer.Location); @@ -6099,7 +6253,7 @@ join_clause current_block = new Linq.QueryBlock (current_block, lexer.Location); } - expression opt_join_into + expression_or_error opt_join_into { current_block.AddStatement (new ContextualReturn ((Expression) $12)); current_block.SetEndLocation (lexer.Location); @@ -6116,6 +6270,7 @@ join_clause $$ = new Linq.Join (block, sn, (Expression)$6, outer_selector, (Linq.QueryBlock) current_block, GetLocation ($1)) { IdentifierType = (FullNamedExpression)$2 }; + lbag.AddLocation ($$, GetLocation ($3), GetLocation ($6), GetLocation ($9)); } else { // // Set equals right side parent to beginning of linq query, it is not accessible therefore cannot cause name collisions @@ -6134,6 +6289,7 @@ join_clause $$ = new Linq.GroupJoin (block, sn, (Expression)$6, outer_selector, (Linq.QueryBlock) current_block, into, GetLocation ($1)) { IdentifierType = (FullNamedExpression)$2 }; + lbag.AddLocation ($$, GetLocation ($3), GetLocation ($6), GetLocation ($9), opt_intoStack.Pop ()); } current_block = block.Parent; @@ -6145,6 +6301,7 @@ opt_join_into : /* empty */ | INTO identifier_inside_body { + opt_intoStack.Push (GetLocation ($1)); $$ = $2; } ; @@ -6277,8 +6434,7 @@ interactive_parsing | EVAL_USING_DECLARATIONS_UNIT_PARSER using_directives opt_COMPLETE_COMPLETION | EVAL_STATEMENT_PARSER { - current_container = new Class (current_namespace, current_class, new MemberName (""), Modifiers.PUBLIC, null); - current_class = current_container; + current_container = current_type = new Class (current_container, new MemberName (""), Modifiers.PUBLIC, null); // (ref object retval) Parameter [] mpar = new Parameter [1]; @@ -6291,14 +6447,14 @@ interactive_parsing current_local_parameters = pars; Method method = new Method ( - current_class, + current_type, new TypeExpression (compiler.BuiltinTypes.Void, Location.Null), mods, new MemberName ("Host"), pars, null /* attributes */); - current_container.AddMethod (method); + current_type.AddMember (method); oob_stack.Push (method); ++lexer.parsing_block; @@ -6515,51 +6671,34 @@ void Error_MissingInitializer (Location loc) report.Error (210, loc, "You must provide an initializer in a fixed or using statement declaration"); } -void push_current_class (TypeContainer tc, object partial_token) +void push_current_container (TypeDefinition tc, object partial_token) { - if (module.Evaluator != null && current_container is ModuleContainer){ + if (module.Evaluator != null){ tc.Definition.Modifiers = tc.ModFlags = (tc.ModFlags & ~Modifiers.AccessibilityMask) | Modifiers.PUBLIC; if (undo == null) undo = new Undo (); + undo.AddTypeContainer (current_container, tc); } - + if (partial_token != null) - current_container = current_container.AddPartial (tc); + current_container.AddPartial (tc); else - current_container = current_container.AddTypeContainer (tc); - + current_container.AddTypeContainer (tc); + ++lexer.parsing_declaration; - current_class = tc; - ubag.PushTypeDeclaration (tc); + current_container = tc; + current_type = tc; } TypeContainer pop_current_class () { - var retval = current_class; + var retval = current_container; - current_class = current_class.Parent; - current_container = current_class.PartialContainer; - ubag.PopTypeDeclaration (); - - return retval; -} + current_container = current_container.Parent; + current_type = current_type.Parent as TypeDefinition; -// -// Given the @class_name name, it creates a fully qualified name -// based on the containing declaration space -// -MemberName -MakeName (MemberName class_name) -{ - if (current_container == module) { - if (current_namespace.MemberName != MemberName.Null) - return new MemberName (current_namespace.NS.MemberName, class_name); - else - return class_name; - } else { - return new MemberName (current_container.MemberName, class_name); - } + return retval; } [System.Diagnostics.Conditional ("FULL_AST")] @@ -6629,26 +6768,31 @@ static CSharpParser () } public CSharpParser (SeekableStreamReader reader, CompilationSourceFile file) - : this (reader, file, file.NamespaceContainer.Module.Compiler.Report) + : this (reader, file, file.Compiler.Report) { } public CSharpParser (SeekableStreamReader reader, CompilationSourceFile file, Report report) { this.file = file; - current_namespace = file.NamespaceContainer; + current_container = current_namespace = file; - this.module = current_namespace.Module; - this.compiler = module.Compiler; + this.module = file.Module; + this.compiler = file.Compiler; this.settings = compiler.Settings; this.report = report; lang_version = settings.Version; + yacc_verbose_flag = settings.VerboseParserFlag; doc_support = settings.DocumentationFile != null; - current_class = current_namespace.SlaveDeclSpace; - current_container = current_class.PartialContainer; // == RootContest.ToplevelTypes oob_stack.Clear (); - lexer = new Tokenizer (reader, file, compiler); + lexer = new Tokenizer (reader, file); + +#if FULL_AST + lbag = new LocationsBag (); +#else + lbag = null; +#endif use_global_stacks = true; } @@ -6677,10 +6821,10 @@ public void parse () report.Error (-25, lexer.Location, "Parsing error"); } else { // Used by compiler-tester to test internal errors - if (yacc_verbose_flag > 0) + if (yacc_verbose_flag > 0 || e is FatalException) throw; - report.Error (589, lexer.Location, "Internal compiler error during parsing"); + report.Error (589, lexer.Location, "Internal compiler error during parsing" + e); } } } @@ -6727,18 +6871,6 @@ public LocationsBag LocationsBag { get { return lbag; } - set { - lbag = value; - } -} - -public UsingsBag UsingsBag { - get { - return ubag; - } - set { - ubag = value; - } } void start_block (Location loc) diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/cs-tokenizer.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/cs-tokenizer.cs index d9c679406b..35705d56e1 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/cs-tokenizer.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/cs-tokenizer.cs @@ -73,7 +73,8 @@ namespace Mono.CSharp { int row, column; string value; - static LocatedToken[] buffer; + + static LocatedToken[] buffer = new LocatedToken[0]; static int pos; private LocatedToken () @@ -129,11 +130,18 @@ namespace Mono.CSharp public static void Initialize () { - if (buffer == null) - buffer = new LocatedToken [10000]; +#if !FULL_AST + if (buffer.Length == 0) + buffer = new LocatedToken [15000]; +#endif pos = 0; } + public override string ToString () + { + return string.Format ("Token '{0}' at {1},{2}", Value, row, column); + } + public Location Location { get { return new Location (row, column); } } @@ -158,23 +166,24 @@ namespace Mono.CSharp Error = 9, Warning = 10, Pragma = 11 | CustomArgumentsParsing, - Line = 12, + Line = 12 | CustomArgumentsParsing, CustomArgumentsParsing = 1 << 10, RequiresArgument = 1 << 11 } - SeekableStreamReader reader; - SourceFile ref_name; - CompilationSourceFile file_name; - CompilerContext context; - bool hidden = false; + readonly SeekableStreamReader reader; + readonly CompilationSourceFile source_file; + readonly CompilerContext context; + + SourceFile current_source; + Location hidden_block_start; int ref_line = 1; int line = 1; int col = 0; int previous_col; int current_token; - int tab_size; + readonly int tab_size; bool handle_get_set = false; bool handle_remove_add = false; bool handle_where = false; @@ -263,7 +272,7 @@ namespace Mono.CSharp // static readonly KeywordEntry[][] keywords; static readonly KeywordEntry[][] keywords_preprocessor; - static readonly Dictionary keyword_strings; // TODO: HashSet + static readonly HashSet keyword_strings; static readonly NumberStyles styles; static readonly NumberFormatInfo csharp_format_info; @@ -272,6 +281,9 @@ namespace Mono.CSharp static readonly char[] pragma_warning_disable = "disable".ToCharArray (); static readonly char[] pragma_warning_restore = "restore".ToCharArray (); static readonly char[] pragma_checksum = "checksum".ToCharArray (); + static readonly char[] line_hidden = "hidden".ToCharArray (); + static readonly char[] line_default = "default".ToCharArray (); + static readonly char[] simple_whitespaces = new char[] { ' ', '\t' }; bool startsLine = true; internal SpecialsBag sbag; @@ -295,12 +307,7 @@ namespace Mono.CSharp get { return handle_typeof; } set { handle_typeof = value; } } - - public int TabSize { - get { return tab_size; } - set { tab_size = value; } - } - + public XmlCommentState doc_state { get { return xml_doc_state; } set { @@ -348,19 +355,35 @@ namespace Mono.CSharp // Stack ifstack; - static System.Text.StringBuilder string_builder; const int max_id_size = 512; - static readonly char[] id_builder = new char [max_id_size]; - public static Dictionary[] identifiers = new Dictionary[max_id_size + 1]; const int max_number_size = 512; - static char[] number_builder = new char [max_number_size]; + +#if FULL_AST + readonly char [] id_builder = new char [max_id_size]; + + Dictionary[] identifiers = new Dictionary[max_id_size + 1]; + + char [] number_builder = new char [max_number_size]; + int number_pos; + + char[] value_builder = new char[256]; +#else + static readonly char [] id_builder = new char [max_id_size]; + + static Dictionary[] identifiers = new Dictionary[max_id_size + 1]; + + static char [] number_builder = new char [max_number_size]; static int number_pos; static char[] value_builder = new char[256]; +#endif public int Line { get { return ref_line; } + set { + ref_line = value; + } } // @@ -377,7 +400,7 @@ namespace Mono.CSharp public int line; public int ref_line; public int col; - public bool hidden; + public Location hidden; public int putback_char; public int previous_col; public Stack ifstack; @@ -391,7 +414,7 @@ namespace Mono.CSharp line = t.line; ref_line = t.ref_line; col = t.col; - hidden = t.hidden; + hidden = t.hidden_block_start; putback_char = t.putback_char; previous_col = t.previous_col; if (t.ifstack != null && t.ifstack.Count != 0) { @@ -407,24 +430,22 @@ namespace Mono.CSharp } } - public Tokenizer (SeekableStreamReader input, CompilationSourceFile file, CompilerContext ctx) + public Tokenizer (SeekableStreamReader input, CompilationSourceFile file) { - this.ref_name = file; - this.file_name = file; - this.context = ctx; + this.source_file = file; + this.context = file.Compiler; + this.current_source = file.SourceFile; + reader = input; putback_char = -1; xml_comment_buffer = new StringBuilder (); - doc_processing = ctx.Settings.DocumentationFile != null; + doc_processing = context.Settings.DocumentationFile != null; - if (Environment.OSVersion.Platform == PlatformID.Win32NT) - tab_size = 4; - else - tab_size = 8; + tab_size = context.Settings.TabSize; - Mono.CSharp.Location.Push (file, file); + Mono.CSharp.Location.Push (current_source); } public void PushPosition () @@ -440,7 +461,7 @@ namespace Mono.CSharp ref_line = p.ref_line; line = p.line; col = p.col; - hidden = p.hidden; + hidden_block_start = p.hidden; putback_char = p.putback_char; previous_col = p.previous_col; ifstack = p.ifstack; @@ -457,7 +478,7 @@ namespace Mono.CSharp static void AddKeyword (string kw, int token) { - keyword_strings.Add (kw, null); + keyword_strings.Add (kw); AddKeyword (keywords, kw, token); } @@ -493,7 +514,7 @@ namespace Mono.CSharp // static Tokenizer () { - keyword_strings = new Dictionary (); + keyword_strings = new HashSet (); // 11 is the length of the longest keyword for now keywords = new KeywordEntry[11][]; @@ -621,8 +642,6 @@ namespace Mono.CSharp csharp_format_info = NumberFormatInfo.InvariantInfo; styles = NumberStyles.Float; - - string_builder = new System.Text.StringBuilder (); } int GetKeyword (char[] id, int id_len) @@ -872,7 +891,7 @@ namespace Mono.CSharp public Location Location { get { - return new Location (ref_line, hidden ? -1 : col); + return new Location (ref_line, col); } } @@ -900,7 +919,7 @@ namespace Mono.CSharp public static bool IsKeyword (string s) { - return keyword_strings.ContainsKey (s); + return keyword_strings.Contains (s); } // @@ -960,6 +979,7 @@ namespace Mono.CSharp case Token.UNCHECKED: case Token.UNSAFE: case Token.DEFAULT: + case Token.AWAIT: // // These can be part of a member access @@ -1251,10 +1271,24 @@ namespace Mono.CSharp int ntoken; int interrs = 1; int colons = 0; + int braces = 0; // // All shorcuts failed, do it hard way // while ((ntoken = xtoken ()) != Token.EOF) { + if (ntoken == Token.OPEN_BRACE) { + ++braces; + continue; + } + + if (ntoken == Token.CLOSE_BRACE) { + --braces; + continue; + } + + if (braces != 0) + continue; + if (ntoken == Token.SEMICOLON) break; @@ -1270,7 +1304,7 @@ namespace Mono.CSharp } } - next_token = colons != interrs ? Token.INTERR_NULLABLE : Token.INTERR; + next_token = colons != interrs && braces == 0 ? Token.INTERR_NULLABLE : Token.INTERR; break; } } @@ -1511,6 +1545,12 @@ namespace Mono.CSharp #if FULL_AST int read_start = reader.Position - 1; + if (c == '.') { + // + // Caller did peek_char + // + --read_start; + } #endif number_pos = 0; var loc = Location; @@ -1596,10 +1636,10 @@ namespace Mono.CSharp val = res; #if FULL_AST - var endPos = reader.Position - (type == TypeCode.Empty ? 1 : 0); - if (reader.GetChar (endPos - 1) == '\r') - endPos--; - res.ParsedValue = reader.ReadChars (hasLeadingDot ? read_start - 1 : read_start, endPos); + var chars = reader.ReadChars (read_start, reader.Position - (type == TypeCode.Empty && c > 0 ? 1 : 0)); + if (chars[chars.Length - 1] == '\r') + Array.Resize (ref chars, chars.Length - 1); + res.ParsedValue = chars; #endif return Token.LITERAL; @@ -1774,12 +1814,12 @@ namespace Mono.CSharp return reader.Peek (); } - void putback (int c) + public void putback (int c) { if (putback_char != -1){ Console.WriteLine ("Col: " + col); Console.WriteLine ("Row: " + line); - Console.WriteLine ("Name: " + ref_name.Name); + Console.WriteLine ("Name: " + current_source.Name); Console.WriteLine ("Current [{0}] putting back [{1}] ", putback_char, c); throw new Exception ("This should not happen putback on putback"); } @@ -1940,44 +1980,120 @@ namespace Mono.CSharp // // Handles the #line directive // - bool PreProcessLine (string arg) + bool PreProcessLine () { - if (arg.Length == 0) - return false; + Location loc = Location; - if (arg == "default"){ - ref_line = line; - ref_name = file_name; - hidden = false; - Location.Push (file_name, ref_name); + int c; + + int length = TokenizePreprocessorIdentifier (out c); + if (length == line_default.Length) { + if (!IsTokenIdentifierEqual (line_default)) + return false; + + current_source = source_file.SourceFile; + if (!hidden_block_start.IsNull) { + current_source.RegisterHiddenScope (hidden_block_start, loc); + hidden_block_start = Location.Null; + } + + //ref_line = line; + Location.Push (current_source); return true; - } else if (arg == "hidden"){ - hidden = true; + } + + if (length == line_hidden.Length) { + if (!IsTokenIdentifierEqual (line_hidden)) + return false; + + if (hidden_block_start.IsNull) + hidden_block_start = loc; + return true; } - - try { - int pos; - if ((pos = arg.IndexOf (' ')) != -1 && pos != 0){ - ref_line = System.Int32.Parse (arg.Substring (0, pos)); - pos++; - - char [] quotes = { '\"' }; - - string name = arg.Substring (pos). Trim (quotes); - ref_name = context.LookupFile (file_name, name); - file_name.AddIncludeFile (ref_name); - hidden = false; - Location.Push (file_name, ref_name); - } else { - ref_line = System.Int32.Parse (arg); - hidden = false; + if (length != 0 || c < '0' || c > '9') { + // + // Eat any remaining characters to continue parsing on next line + // + while (c != -1 && c != '\n') { + c = get_char (); } - } catch { + return false; } - + + int new_line = TokenizeNumber (c); + if (new_line < 1) { + // + // Eat any remaining characters to continue parsing on next line + // + while (c != -1 && c != '\n') { + c = get_char (); + } + + return new_line != 0; + } + + c = get_char (); + if (c == ' ') { + // skip over white space + do { + c = get_char (); + } while (c == ' ' || c == '\t'); + } else if (c == '"') { + c = 0; + } + + if (c != '\n' && c != '/' && c != '"') { + // + // Eat any remaining characters to continue parsing on next line + // + while (c != -1 && c != '\n') { + c = get_char (); + } + + Report.Error (1578, loc, "Filename, single-line comment or end-of-line expected"); + return true; + } + + string new_file_name = null; + if (c == '"') { + new_file_name = TokenizeFileName (ref c); + + // skip over white space + while (c == ' ' || c == '\t') { + c = get_char (); + } + } + + if (c == '\n') { + } else if (c == '/') { + ReadSingleLineComment (); + } else { + // + // Eat any remaining characters to continue parsing on next line + // + while (c != -1 && c != '\n') { + c = get_char (); + } + + Error_EndLineExpected (); + return true; + } + + if (new_file_name != null) { + current_source = context.LookupFile (source_file, new_file_name); + source_file.AddIncludeFile (current_source); + Location.Push (current_source); + } + + if (!hidden_block_start.IsNull) { + current_source.RegisterHiddenScope (hidden_block_start, loc); + hidden_block_start = Location.Null; + } + + //ref_line = new_line; return true; } @@ -2016,12 +2132,12 @@ namespace Mono.CSharp if (context.Settings.IsConditionalSymbolDefined (ident)) return; - file_name.AddDefine (ident); + source_file.AddDefine (ident); } else { // // #undef ident // - file_name.AddUndefine (ident); + source_file.AddUndefine (ident); } } @@ -2072,26 +2188,13 @@ namespace Mono.CSharp if (c != '"') return false; - string_builder.Length = 0; - while (c != -1 && c != '\n') { - c = get_char (); - if (c == '"') { - c = get_char (); - break; - } - - string_builder.Append ((char) c); - } - - if (string_builder.Length == 0) { - Report.Warning (1709, 1, Location, "Filename specified for preprocessor directive is empty"); - } + string file_name = TokenizeFileName (ref c); // TODO: Any white-spaces count if (c != ' ') return false; - SourceFile file = context.LookupFile (file_name, string_builder.ToString ()); + SourceFile file = context.LookupFile (source_file, file_name); if (get_char () != '"' || get_char () != '{') return false; @@ -2158,10 +2261,13 @@ namespace Mono.CSharp } file.SetChecksum (guid_bytes, checksum_bytes.ToArray ()); - ref_name.AutoGenerated = true; + current_source.AutoGenerated = true; return true; } +#if !FULL_AST + static +#endif bool IsTokenIdentifierEqual (char[] identifier) { for (int i = 0; i < identifier.Length; ++i) { @@ -2172,27 +2278,54 @@ namespace Mono.CSharp return true; } - int TokenizePragmaNumber (ref int c) + int TokenizeNumber (int value) { number_pos = 0; - int number; + decimal_digits (value); + uint ui = (uint) (number_builder[0] - '0'); - if (c >= '0' && c <= '9') { - decimal_digits (c); - uint ui = (uint) (number_builder[0] - '0'); + try { + for (int i = 1; i < number_pos; i++) { + ui = checked ((ui * 10) + ((uint) (number_builder[i] - '0'))); + } - try { - for (int i = 1; i < number_pos; i++) { - ui = checked ((ui * 10) + ((uint) (number_builder[i] - '0'))); - } + return (int) ui; + } catch (OverflowException) { + Error_NumericConstantTooLong (); + return -1; + } + } - number = (int) ui; - } catch (OverflowException) { - Error_NumericConstantTooLong (); - number = -1; + string TokenizeFileName (ref int c) + { + var string_builder = new StringBuilder (); + while (c != -1 && c != '\n') { + c = get_char (); + if (c == '"') { + c = get_char (); + break; } + string_builder.Append ((char) c); + } + + if (string_builder.Length == 0) { + Report.Warning (1709, 1, Location, "Filename specified for preprocessor directive is empty"); + } + + + return string_builder.ToString (); + } + + int TokenizePragmaNumber (ref int c) + { + number_pos = 0; + + int number; + + if (c >= '0' && c <= '9') { + number = TokenizeNumber (c); c = get_char (); @@ -2287,9 +2420,9 @@ namespace Mono.CSharp code = TokenizePragmaNumber (ref c); if (code > 0) { if (disable) { - Report.RegisterWarningRegion (loc).WarningDisable (loc, code, Report); + Report.RegisterWarningRegion (loc).WarningDisable (loc, code, context.Report); } else { - Report.RegisterWarningRegion (loc).WarningEnable (loc, code, Report); + Report.RegisterWarningRegion (loc).WarningEnable (loc, code, context); } } } while (code >= 0 && c != '\n' && c != -1); @@ -2325,7 +2458,7 @@ namespace Mono.CSharp if (s == "false") return false; - return file_name.IsConditionalDefined (context, s); + return source_file.IsConditionalDefined (s); } bool pp_primary (ref string s) @@ -2715,10 +2848,10 @@ namespace Mono.CSharp return true; case PreprocessorDirective.Line: - if (!PreProcessLine (arg)) - Report.Error ( - 1576, Location, - "The line number specified for #line directive is missing or invalid"); + Location loc = Location; + if (!PreProcessLine ()) + Report.Error (1576, loc, "The line number specified for #line directive is missing or invalid"); + return caller_is_taking; } @@ -2897,7 +3030,10 @@ namespace Mono.CSharp return Token.IDENTIFIER; } - static string InternIdentifier (char[] charBuffer, int length) +#if !FULL_AST + static +#endif + string InternIdentifier (char[] charBuffer, int length) { // // Keep identifiers in an array of hashtables to avoid needless diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/decl.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/decl.cs index 6e2c2d081c..2d2dcf8ff2 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/decl.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/decl.cs @@ -15,6 +15,8 @@ using System; using System.Collections.Generic; using System.Diagnostics; +using System.Text; +using Mono.CompilerServices.SymbolWriter; #if NET_2_1 using XmlElement = System.Object; @@ -96,12 +98,6 @@ namespace Mono.CSharp { this.Left = left; } - // TODO: Remove - public string GetName () - { - return GetName (false); - } - public int Arity { get { return TypeParameters == null ? 0 : TypeParameters.Count; @@ -110,24 +106,10 @@ namespace Mono.CSharp { public bool IsGeneric { get { - if (TypeParameters != null) - return true; - else if (Left != null) - return Left.IsGeneric; - else - return false; + return TypeParameters != null; } } - public string GetName (bool is_generic) - { - string name = is_generic ? Basename : Name; - if (Left != null) - return Left.GetName (is_generic) + "." + name; - - return name; - } - public string Basename { get { if (TypeParameters != null) @@ -136,6 +118,31 @@ namespace Mono.CSharp { } } + public void CreateMetadataName (StringBuilder sb) + { + if (Left != null) + Left.CreateMetadataName (sb); + + if (sb.Length != 0) { + sb.Append ("."); + } + + sb.Append (Basename); + } + + public string GetSignatureForDocumentation () + { + var s = Basename; + + if (ExplicitInterface != null) + s = ExplicitInterface.GetSignatureForError () + "." + s; + + if (Left == null) + return s; + + return Left.GetSignatureForDocumentation () + "." + s; + } + public string GetSignatureForError () { string s = TypeParameters == null ? null : "<" + TypeParameters.GetSignatureForError () + ">"; @@ -290,7 +297,10 @@ namespace Mono.CSharp { IsAssigned = 1 << 12, // Field is assigned HasExplicitLayout = 1 << 13, PartialDefinitionExists = 1 << 14, // Set when corresponding partial method definition exists - HasStructLayout = 1 << 15 // Has StructLayoutAttribute + HasStructLayout = 1 << 15, // Has StructLayoutAttribute + HasInstanceConstructor = 1 << 16, + HasUserOperators = 1 << 17, + CanBeReused = 1 << 18 } /// @@ -398,10 +408,11 @@ namespace Mono.CSharp { // public virtual string GetSignatureForError () { - if (Parent == null || Parent.Parent == null) + var parent = Parent.GetSignatureForError (); + if (parent == null) return member_name.GetSignatureForError (); - return Parent.GetSignatureForError () + "." + member_name.GetSignatureForError (); + return parent + "." + member_name.GetSignatureForError (); } /// @@ -415,6 +426,15 @@ namespace Mono.CSharp { VerifyClsCompliance (); } + public bool IsAvailableForReuse { + get { + return (caching_flags & Flags.CanBeReused) != 0; + } + set { + caching_flags = value ? (caching_flags | Flags.CanBeReused) : (caching_flags & ~Flags.CanBeReused); + } + } + public bool IsCompilerGenerated { get { if ((mod_flags & Modifiers.COMPILER_GENERATED) != 0) @@ -553,7 +573,7 @@ namespace Mono.CSharp { case Modifiers.PROTECTED: if (al == Modifiers.PROTECTED) { - same_access_restrictions = mc.Parent.IsBaseTypeDefinition (p_parent); + same_access_restrictions = mc.Parent.PartialContainer.IsBaseTypeDefinition (p_parent); break; } @@ -562,8 +582,8 @@ namespace Mono.CSharp { // When type is private and any of its parents derives from // protected type then the type is accessible // - while (mc.Parent != null) { - if (mc.Parent.IsBaseTypeDefinition (p_parent)) + while (mc.Parent != null && mc.Parent.PartialContainer != null) { + if (mc.Parent.PartialContainer.IsBaseTypeDefinition (p_parent)) same_access_restrictions = true; mc = mc.Parent; } @@ -575,7 +595,7 @@ namespace Mono.CSharp { if (al == Modifiers.INTERNAL) same_access_restrictions = p.MemberDefinition.IsInternalAsPublic (mc.Module.DeclaringAssembly); else if (al == (Modifiers.PROTECTED | Modifiers.INTERNAL)) - same_access_restrictions = mc.Parent.IsBaseTypeDefinition (p_parent) && p.MemberDefinition.IsInternalAsPublic (mc.Module.DeclaringAssembly); + same_access_restrictions = mc.Parent.PartialContainer.IsBaseTypeDefinition (p_parent) && p.MemberDefinition.IsInternalAsPublic (mc.Module.DeclaringAssembly); else goto case Modifiers.PROTECTED; @@ -589,7 +609,7 @@ namespace Mono.CSharp { var decl = mc.Parent; do { same_access_restrictions = decl.CurrentType == p_parent; - } while (!same_access_restrictions && !decl.IsTopLevel && (decl = decl.Parent) != null); + } while (!same_access_restrictions && !decl.PartialContainer.IsTopLevel && (decl = decl.Parent) != null); } break; @@ -624,7 +644,7 @@ namespace Mono.CSharp { return true; } - if (Parent.PartialContainer.IsClsComplianceRequired ()) { + if (Parent.IsClsComplianceRequired ()) { caching_flags |= Flags.ClsCompliant; return true; } @@ -643,25 +663,40 @@ namespace Mono.CSharp { public bool IsExposedFromAssembly () { if ((ModFlags & (Modifiers.PUBLIC | Modifiers.PROTECTED)) == 0) - return false; + return this is NamespaceContainer; var parentContainer = Parent.PartialContainer; - while (parentContainer != null && parentContainer.ModFlags != 0) { + while (parentContainer != null) { if ((parentContainer.ModFlags & (Modifiers.PUBLIC | Modifiers.PROTECTED)) == 0) return false; - parentContainer = parentContainer.Parent; + + parentContainer = parentContainer.Parent.PartialContainer; } + return true; } - public virtual ExtensionMethodCandidates LookupExtensionMethod (TypeSpec extensionType, string name, int arity) + // + // Does extension methods look up to find a method which matches name and extensionType. + // Search starts from this namespace and continues hierarchically up to top level. + // + public ExtensionMethodCandidates LookupExtensionMethod (TypeSpec extensionType, string name, int arity) { - return Parent.LookupExtensionMethod (extensionType, name, arity); + var m = Parent; + do { + var ns = m as NamespaceContainer; + if (ns != null) + return ns.LookupExtensionMethod (this, extensionType, name, arity, 0); + + m = m.Parent; + } while (m != null); + + return null; } public virtual FullNamedExpression LookupNamespaceAlias (string name) { - return Parent.NamespaceEntry.LookupNamespaceAlias (name); + return Parent.LookupNamespaceAlias (name); } public virtual FullNamedExpression LookupNamespaceOrType (string name, int arity, LookupMode mode, Location loc) @@ -747,7 +782,7 @@ namespace Mono.CSharp { } if ((caching_flags & Flags.ClsCompliantAttributeFalse) != 0) { - if (Parent.Kind == MemberKind.Interface && Parent.IsClsComplianceRequired ()) { + if (Parent is Interface && Parent.IsClsComplianceRequired ()) { Report.Warning (3010, 1, Location, "`{0}': CLS-compliant interfaces must have only CLS-compliant members", GetSignatureForError ()); } else if (Parent.Kind == MemberKind.Class && (ModFlags & Modifiers.ABSTRACT) != 0 && Parent.IsClsComplianceRequired ()) { Report.Warning (3011, 1, Location, "`{0}': only CLS-compliant members can be abstract", GetSignatureForError ()); @@ -756,7 +791,7 @@ namespace Mono.CSharp { return false; } - if (Parent.Parent != null && !Parent.IsClsComplianceRequired ()) { + if (Parent.Kind != MemberKind.Namespace && Parent.Kind != 0 && !Parent.IsClsComplianceRequired ()) { Attribute a = OptAttributes.Search (Module.PredefinedAttributes.CLSCompliant); Report.Warning (3018, 1, a.Location, "`{0}' cannot be marked as CLS-compliant because it is a member of non CLS-compliant type `{1}'", GetSignatureForError (), Parent.GetSignatureForError ()); @@ -766,12 +801,12 @@ namespace Mono.CSharp { if (!IsExposedFromAssembly ()) return false; - if (!Parent.PartialContainer.IsClsComplianceRequired ()) + if (!Parent.IsClsComplianceRequired ()) return false; } if (member_name.Name [0] == '_') { - Report.Warning (3008, 1, Location, "Identifier `{0}' is not CLS-compliant", GetSignatureForError () ); + Warning_IdentifierNotCompliant (); } if (member_name.TypeParameters != null) @@ -780,12 +815,27 @@ namespace Mono.CSharp { return true; } + protected void Warning_IdentifierNotCompliant () + { + Report.Warning (3008, 1, MemberName.Location, "Identifier `{0}' is not CLS-compliant", GetSignatureForError ()); + } + + public virtual string GetCallerMemberName () + { + return MemberName.Name; + } + // // Returns a string that represents the signature for this // member which should be used in XML documentation. // public abstract string GetSignatureForDocumentation (); + public virtual void GetCompletionStartingWith (string prefix, List results) + { + Parent.GetCompletionStartingWith (prefix, results); + } + // // Generates xml doc comments (if any), and if required, // handle warning report. @@ -810,10 +860,16 @@ namespace Mono.CSharp { } } + public virtual void WriteDebugSymbol (MonoSymbolFile file) + { + } + #region IMemberContext Members public virtual CompilerContext Compiler { - get { return Parent.Compiler; } + get { + return Module.Compiler; + } } public virtual TypeSpec CurrentType { @@ -1163,7 +1219,7 @@ namespace Mono.CSharp { return (state & StateFlags.CLSCompliant) != 0; } - public bool IsConditionallyExcluded (CompilerContext ctx, Location loc) + public bool IsConditionallyExcluded (IMemberContext ctx, Location loc) { if ((Kind & (MemberKind.Class | MemberKind.Method)) == 0) return false; @@ -1172,9 +1228,18 @@ namespace Mono.CSharp { if (conditions == null) return false; - foreach (var condition in conditions) { - if (loc.CompilationUnit.IsConditionalDefined (ctx, condition)) - return false; + var m = ctx.CurrentMemberDefinition; + CompilationSourceFile unit = null; + while (m != null && unit == null) { + unit = m as CompilationSourceFile; + m = m.Parent; + } + + if (unit != null) { + foreach (var condition in conditions) { + if (unit.IsConditionalDefined (condition)) + return false; + } } return true; diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/delegate.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/delegate.cs index 7730fa4c79..f0781401bb 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/delegate.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/delegate.cs @@ -28,7 +28,7 @@ namespace Mono.CSharp { // // Delegate container implementation // - public class Delegate : TypeContainer, IParametersMember + public class Delegate : TypeDefinition, IParametersMember { public FullNamedExpression ReturnType; readonly ParametersCompiled parameters; @@ -55,9 +55,9 @@ namespace Mono.CSharp { Modifiers.UNSAFE | Modifiers.PRIVATE; - public Delegate (NamespaceContainer ns, TypeContainer parent, FullNamedExpression type, Modifiers mod_flags, MemberName name, ParametersCompiled param_list, + public Delegate (TypeContainer parent, FullNamedExpression type, Modifiers mod_flags, MemberName name, ParametersCompiled param_list, Attributes attrs) - : base (ns, parent, name, attrs, MemberKind.Delegate) + : base (parent, name, attrs, MemberKind.Delegate) { this.ReturnType = type; @@ -220,7 +220,7 @@ namespace Mono.CSharp { var p = parameters[i]; compiled[i] = new Parameter (new TypeExpression (parameters.Types[i], Location), p.Name, - p.ModFlags & (Parameter.Modifier.REF | Parameter.Modifier.OUT), + p.ModFlags & Parameter.Modifier.RefOutMask, p.OptAttributes == null ? null : p.OptAttributes.Clone (), Location); } @@ -255,7 +255,7 @@ namespace Mono.CSharp { int out_params = 0; foreach (Parameter p in Parameters.FixedParameters) { - if ((p.ModFlags & Parameter.Modifier.ISBYREF) != 0) + if ((p.ModFlags & Parameter.Modifier.RefOutMask) != 0) ++out_params; } @@ -265,12 +265,12 @@ namespace Mono.CSharp { int param = 0; for (int i = 0; i < Parameters.FixedParameters.Length; ++i) { Parameter p = parameters [i]; - if ((p.ModFlags & Parameter.Modifier.ISBYREF) == 0) + if ((p.ModFlags & Parameter.Modifier.RefOutMask) == 0) continue; end_params [param++] = new Parameter (new TypeExpression (p.Type, Location), p.Name, - p.ModFlags & (Parameter.Modifier.REF | Parameter.Modifier.OUT), + p.ModFlags & Parameter.Modifier.RefOutMask, p.OptAttributes == null ? null : p.OptAttributes.Clone (), Location); } @@ -292,15 +292,17 @@ namespace Mono.CSharp { EndInvokeBuilder.Define (); } - public override void DefineConstants () + public override void PrepareEmit () { if (!Parameters.IsEmpty) { parameters.ResolveDefaultValues (this); } } - public override void EmitType () + public override void Emit () { + base.Emit (); + if (ReturnType.Type != null) { if (ReturnType.Type.BuiltinType == BuiltinTypeSpec.Type.Dynamic) { return_attributes = new ReturnParameter (this, InvokeBuilder.MethodBuilder, Location); @@ -327,12 +329,6 @@ namespace Mono.CSharp { BeginInvokeBuilder.MethodBuilder.SetImplementationFlags (MethodImplAttributes.Runtime); EndInvokeBuilder.MethodBuilder.SetImplementationFlags (MethodImplAttributes.Runtime); } - - if (OptAttributes != null) { - OptAttributes.Emit (); - } - - base.Emit (); } protected override TypeSpec[] ResolveBaseTypes (out FullNamedExpression base_class) @@ -344,9 +340,7 @@ namespace Mono.CSharp { protected override TypeAttributes TypeAttr { get { - return ModifiersExtensions.TypeAttr (ModFlags, IsTopLevel) | - TypeAttributes.Class | TypeAttributes.Sealed | - base.TypeAttr; + return base.TypeAttr | TypeAttributes.Class | TypeAttributes.Sealed; } } @@ -531,7 +525,7 @@ namespace Mono.CSharp { Error_ConversionFailed (ec, delegate_method, ret_expr); } - if (delegate_method.IsConditionallyExcluded (ec.Module.Compiler, loc)) { + if (delegate_method.IsConditionallyExcluded (ec, loc)) { ec.Report.SymbolRelatedToPreviousError (delegate_method); MethodOrOperator m = delegate_method.MemberDefinition as MethodOrOperator; if (m != null && m.IsPartialDefinition) { diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dmcs.csproj b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dmcs.csproj deleted file mode 100644 index 154cad4949..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dmcs.csproj +++ /dev/null @@ -1,154 +0,0 @@ - - - - Debug - AnyCPU - 10.0.20506 - 2.0 - {D4A01C5B-A1B5-48F5-BB5B-D2E1BD236E56} - Exe - Properties - dmcs - dmcs - v4.0 - 512 - x86 - - - true - full - false - .\ - TRACE;DEBUG;NET_4_0;MS_COMPATIBLE - prompt - 4 - true - - - pdbonly - true - TRACE;NET_2_0;MS_COMPATIBLE;GMCS_SOURCE - prompt - prompt - 4 - .\ - - - - - - - - - - CryptoConvert.cs - - - MonoSymbolFile.cs - - - MonoSymbolTable.cs - - - MonoSymbolWriter.cs - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - outline.cs - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dmcs.exe.config b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dmcs.exe.config deleted file mode 100644 index cab6cf8fa5..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dmcs.exe.config +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dmcs.exe.sources b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dmcs.exe.sources deleted file mode 100644 index 71a658ad1f..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dmcs.exe.sources +++ /dev/null @@ -1,55 +0,0 @@ -AssemblyInfo.cs -anonymous.cs -argument.cs -assign.cs -attribute.cs -cs-tokenizer.cs -cfold.cs -class.cs -codegen.cs -complete.cs -const.cs -constant.cs -convert.cs -context.cs -decl.cs -delegate.cs -doc.cs -driver.cs -dynamic.cs -ecore.cs -enum.cs -eval.cs -expression.cs -field.cs -flowanalysis.cs -generic.cs -import.cs -iterators.cs -lambda.cs -linq.cs -literal.cs -location.cs -membercache.cs -method.cs -modifiers.cs -namespace.cs -nullable.cs -parameter.cs -pending.cs -property.cs -report.cs -rootcontext.cs -roottypes.cs -statement.cs -support.cs -typemanager.cs -typespec.cs -visit.cs -symbolwriter.cs -../class/Mono.CompilerServices.SymbolWriter/MonoSymbolFile.cs -../class/Mono.CompilerServices.SymbolWriter/MonoSymbolTable.cs -../class/Mono.CompilerServices.SymbolWriter/MonoSymbolWriter.cs -../class/corlib/Mono.Security.Cryptography/CryptoConvert.cs -../build/common/Consts.cs -../tools/monop/outline.cs diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dmcs.sln b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dmcs.sln deleted file mode 100644 index ac8d1f1ad2..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dmcs.sln +++ /dev/null @@ -1,20 +0,0 @@ - -Microsoft Visual Studio Solution File, Format Version 11.00 -# Visual Studio 2010 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "dmcs", "dmcs.csproj", "{D4A01C5B-A1B5-48F5-BB5B-D2E1BD236E56}" -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Any CPU = Debug|Any CPU - Release|Any CPU = Release|Any CPU - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {D4A01C5B-A1B5-48F5-BB5B-D2E1BD236E56}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {D4A01C5B-A1B5-48F5-BB5B-D2E1BD236E56}.Debug|Any CPU.Build.0 = Debug|Any CPU - {D4A01C5B-A1B5-48F5-BB5B-D2E1BD236E56}.Release|Any CPU.ActiveCfg = Release|Any CPU - {D4A01C5B-A1B5-48F5-BB5B-D2E1BD236E56}.Release|Any CPU.Build.0 = Release|Any CPU - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection -EndGlobal diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/doc-bootstrap.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/doc-bootstrap.cs deleted file mode 100644 index f81f7e86aa..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/doc-bootstrap.cs +++ /dev/null @@ -1,59 +0,0 @@ -// -// doc-bootstrap.cs: Stub support for XML documentation. -// -// Author: -// Raja R Harinath -// -// Dual licensed under the terms of the MIT X11 or GNU GPL -// -// Copyright 2004 Novell, Inc. -// -// - -#if BOOTSTRAP_WITH_OLDLIB || NET_2_1 - -using XmlElement = System.Object; - -namespace Mono.CSharp { - public class DocUtil - { - internal static void GenerateTypeDocComment (TypeContainer t, DeclSpace ds, Report r) - { - } - - internal static void GenerateDocComment (MemberCore mc, DeclSpace ds, Report r) - { - } - - public static string GetMethodDocCommentName (MemberCore mc, ParametersCompiled p, DeclSpace ds) - { - return ""; - } - - internal static void OnMethodGenerateDocComment (MethodCore mc, XmlElement el, Report r) - { - } - - public static void GenerateEnumDocComment (Enum e, DeclSpace ds) - { - } - } - - public class Documentation - { - public Documentation (string xml_output_filename) - { - } - - public bool OutputDocComment (string asmfilename, Report r) - { - return true; - } - - public void GenerateDocComment () - { - } - } -} - -#endif diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/doc.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/doc.cs index 40edc1c929..e988178c43 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/doc.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/doc.cs @@ -32,6 +32,7 @@ namespace Mono.CSharp readonly XmlDocument XmlDocumentation; readonly ModuleContainer module; + readonly ModuleContainer doc_module; // // The output for XML documentation. @@ -48,6 +49,9 @@ namespace Mono.CSharp public DocumentationBuilder (ModuleContainer module) { + doc_module = new ModuleContainer (module.Compiler); + doc_module.DocumentationBuilder = this; + this.module = module; XmlDocumentation = new XmlDocument (); XmlDocumentation.PreserveWhitespace = false; @@ -237,7 +241,7 @@ namespace Mono.CSharp // // Handles node // - void HandleTypeParam (MemberCore mc, XmlElement node) + static void HandleTypeParam (MemberCore mc, XmlElement node) { if (!node.HasAttribute ("name")) return; @@ -258,7 +262,7 @@ namespace Mono.CSharp // // Handles node // - void HandleTypeParamRef (MemberCore mc, XmlElement node) + static void HandleTypeParamRef (MemberCore mc, XmlElement node) { if (!node.HasAttribute ("name")) return; @@ -322,13 +326,10 @@ namespace Mono.CSharp var s = new MemoryStream (encoding.GetBytes (cref)); SeekableStreamReader seekable = new SeekableStreamReader (s, encoding); - var source_file = new CompilationSourceFile ("{documentation}", "", 1); - var doc_module = new ModuleContainer (module.Compiler); - doc_module.DocumentationBuilder = this; - source_file.NamespaceContainer = new NamespaceContainer (null, doc_module, null, source_file); + var source_file = new CompilationSourceFile (doc_module); + var report = new Report (doc_module.Compiler, new NullReportPrinter ()); - Report parse_report = new Report (new NullReportPrinter ()); - var parser = new CSharpParser (seekable, source_file, parse_report); + var parser = new CSharpParser (seekable, source_file, report); ParsedParameters = null; ParsedName = null; ParsedBuiltinType = null; @@ -336,7 +337,7 @@ namespace Mono.CSharp parser.Lexer.putback_char = Tokenizer.DocumentationXref; parser.Lexer.parsing_generic_declaration_doc = true; parser.parse (); - if (parse_report.Errors > 0) { + if (report.Errors > 0) { Report.Warning (1584, 1, mc.Location, "XML comment on `{0}' has syntactically incorrect cref attribute `{1}'", mc.GetSignatureForError (), cref); @@ -396,10 +397,15 @@ namespace Mono.CSharp if (ParsedParameters != null) { var old_printer = mc.Module.Compiler.Report.SetPrinter (new NullReportPrinter ()); - foreach (var pp in ParsedParameters) { - pp.Resolve (mc); + try { + var context = new DocumentationMemberContext (mc, ParsedName ?? MemberName.Null); + + foreach (var pp in ParsedParameters) { + pp.Resolve (context); + } + } finally { + mc.Module.Compiler.Report.SetPrinter (old_printer); } - mc.Module.Compiler.Report.SetPrinter (old_printer); } if (type != null) { @@ -432,13 +438,15 @@ namespace Mono.CSharp if (m.Kind == MemberKind.Operator && !ParsedOperator.HasValue) continue; + var pm_params = pm.Parameters; + int i; for (i = 0; i < parsed_param_count; ++i) { var pparam = ParsedParameters[i]; - if (i >= pm.Parameters.Count || pparam == null || - pparam.TypeSpec != pm.Parameters.Types[i] || - (pparam.Modifier & Parameter.Modifier.SignatureMask) != (pm.Parameters.FixedParameters[i].ModFlags & Parameter.Modifier.SignatureMask)) { + if (i >= pm_params.Count || pparam == null || pparam.TypeSpec == null || + !TypeSpecComparer.Override.IsEqual (pparam.TypeSpec, pm_params.Types[i]) || + (pparam.Modifier & Parameter.Modifier.RefOutMask) != (pm_params.FixedParameters[i].ModFlags & Parameter.Modifier.RefOutMask)) { if (i > parameters_match) { parameters_match = i; @@ -458,7 +466,7 @@ namespace Mono.CSharp continue; } } else { - if (parsed_param_count != pm.Parameters.Count) + if (parsed_param_count != pm_params.Count) continue; } } @@ -611,6 +619,97 @@ namespace Mono.CSharp } } + // + // Type lookup of documentation references uses context of type where + // the reference is used but type parameters from cref value + // + sealed class DocumentationMemberContext : IMemberContext + { + readonly MemberCore host; + MemberName contextName; + + public DocumentationMemberContext (MemberCore host, MemberName contextName) + { + this.host = host; + this.contextName = contextName; + } + + public TypeSpec CurrentType { + get { + return host.CurrentType; + } + } + + public TypeParameters CurrentTypeParameters { + get { + return contextName.TypeParameters; + } + } + + public MemberCore CurrentMemberDefinition { + get { + return host.CurrentMemberDefinition; + } + } + + public bool IsObsolete { + get { + return false; + } + } + + public bool IsUnsafe { + get { + return host.IsStatic; + } + } + + public bool IsStatic { + get { + return host.IsStatic; + } + } + + public ModuleContainer Module { + get { + return host.Module; + } + } + + public string GetSignatureForError () + { + return host.GetSignatureForError (); + } + + public ExtensionMethodCandidates LookupExtensionMethod (TypeSpec extensionType, string name, int arity) + { + return null; + } + + public FullNamedExpression LookupNamespaceOrType (string name, int arity, LookupMode mode, Location loc) + { + if (arity == 0) { + var tp = CurrentTypeParameters; + if (tp != null) { + for (int i = 0; i < tp.Count; ++i) { + var t = tp[i]; + if (t.Name == name) { + t.Type.DeclaredPosition = i; + return new TypeParameterExpr (t, loc); + } + } + } + } + + return host.Parent.LookupNamespaceOrType (name, arity, mode, loc); + } + + public FullNamedExpression LookupNamespaceAlias (string name) + { + throw new NotImplementedException (); + } + } + class DocumentationParameter { public readonly Parameter.Modifier Modifier; diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/driver.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/driver.cs index bc09888f7b..e86263da6c 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/driver.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/driver.cs @@ -41,20 +41,22 @@ namespace Mono.CSharp } } - void tokenize_file (CompilationSourceFile file) + void tokenize_file (SourceFile sourceFile, ModuleContainer module) { Stream input; try { - input = File.OpenRead (file.Name); + input = File.OpenRead (sourceFile.Name); } catch { - Report.Error (2001, "Source file `" + file.Name + "' could not be found"); + Report.Error (2001, "Source file `" + sourceFile.Name + "' could not be found"); return; } using (input){ SeekableStreamReader reader = new SeekableStreamReader (input, ctx.Settings.Encoding); - Tokenizer lexer = new Tokenizer (reader, file, ctx); + var file = new CompilationSourceFile (module, sourceFile); + + Tokenizer lexer = new Tokenizer (reader, file); int token, tokens = 0, errors = 0; while ((token = lexer.token ()) != Token.EOF){ @@ -70,20 +72,21 @@ namespace Mono.CSharp void Parse (ModuleContainer module) { - Location.Initialize (module.Compiler.SourceFiles); - bool tokenize_only = module.Compiler.Settings.TokenizeOnly; var sources = module.Compiler.SourceFiles; + + Location.Initialize (sources); + for (int i = 0; i < sources.Count; ++i) { if (tokenize_only) { - tokenize_file (sources[i]); + tokenize_file (sources[i], module); } else { Parse (sources[i], module); } } } - public void Parse (CompilationSourceFile file, ModuleContainer module) + public void Parse (SourceFile file, ModuleContainer module) { Stream input; @@ -96,6 +99,7 @@ namespace Mono.CSharp // Check 'MZ' header if (input.ReadByte () == 77 && input.ReadByte () == 90) { + Report.Error (2015, "Source file `{0}' is a binary file and not a text file", file.Name); input.Close (); return; @@ -107,30 +111,33 @@ namespace Mono.CSharp Parse (reader, file, module); reader.Dispose (); input.Close (); - } - - public void Parse (SeekableStreamReader reader, CompilationSourceFile file, ModuleContainer module) + } + + public static CSharpParser Parse(SeekableStreamReader reader, SourceFile sourceFile, ModuleContainer module, int lineModifier = 0) { - file.NamespaceContainer = new NamespaceContainer (null, module, null, file); + var file = new CompilationSourceFile (module, sourceFile); + module.AddTypeContainer(file); CSharpParser parser = new CSharpParser (reader, file); + parser.Lexer.Line += lineModifier; + parser.Lexer.sbag = new SpecialsBag (); parser.parse (); + return parser; } public static int Main (string[] args) { Location.InEmacs = Environment.GetEnvironmentVariable ("EMACS") == "t"; - var r = new Report (new ConsoleReportPrinter ()); - CommandLineParser cmd = new CommandLineParser (r); + CommandLineParser cmd = new CommandLineParser (Console.Out); var settings = cmd.ParseArguments (args); - if (settings == null || r.Errors > 0) + if (settings == null) return 1; if (cmd.HasBeenStopped) return 0; - Driver d = new Driver (new CompilerContext (settings, r)); + Driver d = new Driver (new CompilerContext (settings, new ConsoleReportPrinter ())); if (d.Compile () && d.Report.Errors == 0) { if (d.Report.Warnings > 0) { @@ -207,6 +214,11 @@ namespace Mono.CSharp return false; } + if (settings.Platform == Platform.AnyCPU32Preferred && (settings.Target == Target.Library || settings.Target == Target.Module)) { + Report.Error (4023, "Platform option `anycpu32bitpreferred' is valid only for executables"); + return false; + } + TimeReporter tr = new TimeReporter (settings.Timestamps); ctx.TimeReporter = tr; tr.StartTotal (); @@ -247,6 +259,12 @@ namespace Mono.CSharp output_file = output_file_name; } else { output_file_name = Path.GetFileName (output_file); + + if (string.IsNullOrEmpty (Path.GetFileNameWithoutExtension (output_file_name)) || + output_file_name.IndexOfAny (Path.GetInvalidFileNameChars ()) >= 0) { + Report.Error (2021, "Output file name is not valid"); + return false; + } } #if STATIC @@ -263,7 +281,7 @@ namespace Mono.CSharp // loaded assembly into compiled builder to be resolved // correctly tr.Start (TimeReporter.TimerType.CreateTypeTotal); - module.CreateType (); + module.CreateContainer (); importer.AddCompiledAssembly (assembly); tr.Stop (TimeReporter.TimerType.CreateTypeTotal); @@ -292,18 +310,12 @@ namespace Mono.CSharp if (!assembly.Create (AppDomain.CurrentDomain, AssemblyBuilderAccess.Save)) return false; - module.CreateType (); + module.CreateContainer (); loader.LoadModules (assembly, module.GlobalRootNamespace); #endif module.InitializePredefinedTypes (); - tr.Start (TimeReporter.TimerType.UsingResolve); - foreach (var source_file in ctx.SourceFiles) { - source_file.NamespaceContainer.Define (); - } - tr.Stop (TimeReporter.TimerType.UsingResolve); - tr.Start (TimeReporter.TimerType.ModuleDefinitionTotal); module.Define (); tr.Stop (TimeReporter.TimerType.ModuleDefinitionTotal); @@ -331,7 +343,7 @@ namespace Mono.CSharp } tr.Start (TimeReporter.TimerType.CloseTypes); - module.CloseType (); + module.CloseContainer (); tr.Stop (TimeReporter.TimerType.CloseTypes); tr.Start (TimeReporter.TimerType.Resouces); @@ -356,26 +368,24 @@ namespace Mono.CSharp public class CompilerCompilationUnit { public ModuleContainer ModuleCompiled { get; set; } public LocationsBag LocationsBag { get; set; } - public UsingsBag UsingsBag { get; set; } public SpecialsBag SpecialsBag { get; set; } public object LastYYValue { get; set; } } - + // // This is the only public entry point // - public class CompilerCallableEntryPoint : MarshalByRefObject { - + public class CompilerCallableEntryPoint : MarshalByRefObject + { public static bool InvokeCompiler (string [] args, TextWriter error) { try { - var r = new Report (new StreamReportPrinter (error)); - CommandLineParser cmd = new CommandLineParser (r, error); + CommandLineParser cmd = new CommandLineParser (error); var setting = cmd.ParseArguments (args); - if (setting == null || r.Errors > 0) + if (setting == null) return false; - var d = new Driver (new CompilerContext (setting, r)); + var d = new Driver (new CompilerContext (setting, new StreamReportPrinter (error))); return d.Compile (); } finally { Reset (); @@ -400,74 +410,14 @@ namespace Mono.CSharp public static void Reset (bool full_flag) { - CSharpParser.yacc_verbose_flag = 0; Location.Reset (); if (!full_flag) return; - AnonymousTypeClass.Reset (); - AnonymousMethodBody.Reset (); - AnonymousMethodStorey.Reset (); - SymbolWriter.Reset (); - Switch.Reset (); Linq.QueryBlock.TransparentParameter.Reset (); TypeInfo.Reset (); } - - public static CompilerCompilationUnit ParseFile (string[] args, Stream input, string inputFile, TextWriter reportStream) - { - return ParseFile (args, input, inputFile, new StreamReportPrinter (reportStream)); - } - - internal static object parseLock = new object (); - - public static CompilerCompilationUnit ParseFile (string[] args, Stream input, string inputFile, ReportPrinter reportPrinter) - { - lock (parseLock) { - try { - // Driver d = Driver.Create (args, false, null, reportPrinter); - // if (d == null) - // return null; - - var r = new Report (reportPrinter); - CommandLineParser cmd = new CommandLineParser (r, Console.Out); - var setting = cmd.ParseArguments (args); - if (setting == null || r.Errors > 0) - return null; - setting.Version = LanguageVersion.V_5; - - CompilerContext ctx = new CompilerContext (setting, r); - - var files = new List (); - var unit = new CompilationSourceFile (inputFile, inputFile, 0); - var module = new ModuleContainer (ctx); - unit.NamespaceContainer = new NamespaceContainer (null, module, null, unit); - files.Add (unit); - Location.Initialize (files); - - // TODO: encoding from driver - SeekableStreamReader reader = new SeekableStreamReader (input, Encoding.UTF8); - - RootContext.ToplevelTypes = module; - - CSharpParser parser = new CSharpParser (reader, unit); - parser.Lexer.TabSize = 1; - parser.Lexer.sbag = new SpecialsBag (); - parser.LocationsBag = new LocationsBag (); - parser.UsingsBag = new UsingsBag (); - parser.parse (); - - return new CompilerCompilationUnit () { - ModuleCompiled = RootContext.ToplevelTypes, - LocationsBag = parser.LocationsBag, - UsingsBag = parser.UsingsBag, - SpecialsBag = parser.Lexer.sbag - }; - } finally { - Reset (); - } - } - } } + } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dynamic.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dynamic.cs index 3524196957..c9cea6927c 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dynamic.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/dynamic.cs @@ -13,7 +13,7 @@ using System; using System.Linq; using SLE = System.Linq.Expressions; -#if NET_4_0 +#if NET_4_0 || MONODROID using System.Dynamic; #endif @@ -63,7 +63,7 @@ namespace Mono.CSharp // public class RuntimeValueExpression : Expression, IDynamicAssign, IMemoryLocation { -#if !NET_4_0 +#if !NET_4_0 && !MONODROID public class DynamicMetaObject { public TypeSpec RuntimeType; @@ -146,7 +146,7 @@ namespace Mono.CSharp return base.MakeExpression (ctx); #else - #if NET_4_0 +#if NET_4_0 || MONODROID if (type.IsStruct && !obj.Expression.Type.IsValueType) return SLE.Expression.Unbox (obj.Expression, type.GetMetaInfo ()); @@ -181,7 +181,7 @@ namespace Mono.CSharp return this; } -#if NET_4_0 +#if NET_4_0 || MONODROID public override SLE.Expression MakeExpression (BuilderContext ctx) { #if STATIC @@ -430,7 +430,7 @@ namespace Mono.CSharp p[0] = new Parameter (targs[0], "p0", Parameter.Modifier.NONE, null, loc); var site = ec.CreateDynamicSite (); - int index = site.Types == null ? 0 : site.Types.Count; + int index = site.Containers == null ? 0 : site.Containers.Count; if (mutator != null) rt = mutator.Mutate (rt); @@ -439,17 +439,16 @@ namespace Mono.CSharp p[i] = new Parameter (targs[i], "p" + i.ToString ("X"), arguments[i - 1].Modifier, null, loc); } - d = new Delegate (site.NamespaceEntry, site, new TypeExpression (rt, loc), + d = new Delegate (site, new TypeExpression (rt, loc), Modifiers.INTERNAL | Modifiers.COMPILER_GENERATED, new MemberName ("Container" + index.ToString ("X")), new ParametersCompiled (p), null); - d.CreateType (); - d.DefineType (); + d.CreateContainer (); + d.DefineContainer (); d.Define (); - d.Emit (); - site.AddDelegate (d); + site.AddTypeContainer (d); del_type = new TypeExpression (d.CurrentType, loc); if (targs_for_instance != null) { del_type_instance_access = null; @@ -487,7 +486,7 @@ namespace Mono.CSharp // When site container already exists the inflated version has to be // updated manually to contain newly created field - if (gt is InflatedTypeSpec && site_container.Fields.Count > 1) { + if (gt is InflatedTypeSpec && site_container.AnonymousMethodsCounter > 1) { var tparams = gt.MemberDefinition.TypeParametersCount > 0 ? gt.MemberDefinition.TypeParameters : TypeParameterSpec.EmptyTypes; var inflator = new TypeParameterInflator (module, gt, tparams, gt.TypeArguments); gt.MemberCache.AddMember (field.InflateMember (inflator)); @@ -496,41 +495,40 @@ namespace Mono.CSharp FieldExpr site_field_expr = new FieldExpr (MemberCache.GetMember (gt, field), loc); BlockContext bc = new BlockContext (ec.MemberContext, null, ec.BuiltinTypes.Void); - SymbolWriter.OpenCompilerGeneratedBlock (ec); Arguments args = new Arguments (1); args.Add (new Argument (binder)); StatementExpression s = new StatementExpression (new SimpleAssign (site_field_expr, new Invocation (new MemberAccess (instanceAccessExprType, "Create"), args))); - - if (s.Resolve (bc)) { - Statement init = new If (new Binary (Binary.Operator.Equality, site_field_expr, new NullLiteral (loc), loc), s, loc); - init.Emit (ec); - } - - args = new Arguments (1 + dyn_args_count); - args.Add (new Argument (site_field_expr)); - if (arguments != null) { - int arg_pos = 1; - foreach (Argument a in arguments) { - if (a is NamedArgument) { - // Name is not valid in this context - args.Add (new Argument (a.Expr, a.ArgType)); - } else { - args.Add (a); - } - - if (inflate_using_mvar && a.Type != targs[arg_pos].Type) - a.Expr.Type = targs[arg_pos].Type; - ++arg_pos; + using (ec.With (BuilderContext.Options.OmitDebugInfo, true)) { + if (s.Resolve (bc)) { + Statement init = new If (new Binary (Binary.Operator.Equality, site_field_expr, new NullLiteral (loc), loc), s, loc); + init.Emit (ec); } - } - Expression target = new DelegateInvocation (new MemberAccess (site_field_expr, "Target", loc).Resolve (bc), args, loc).Resolve (bc); - if (target != null) - target.Emit (ec); + args = new Arguments (1 + dyn_args_count); + args.Add (new Argument (site_field_expr)); + if (arguments != null) { + int arg_pos = 1; + foreach (Argument a in arguments) { + if (a is NamedArgument) { + // Name is not valid in this context + args.Add (new Argument (a.Expr, a.ArgType)); + } else { + args.Add (a); + } + + if (inflate_using_mvar && a.Type != targs[arg_pos].Type) + a.Expr.Type = targs[arg_pos].Type; + + ++arg_pos; + } + } - SymbolWriter.CloseCompilerGeneratedBlock (ec); + Expression target = new DelegateInvocation (new MemberAccess (site_field_expr, "Target", loc).Resolve (bc), args, loc).Resolve (bc); + if (target != null) + target.Emit (ec); + } } public static MemberAccess GetBinderNamespace (Location loc) @@ -609,7 +607,9 @@ namespace Mono.CSharp public override void EmitStatement (EmitContext ec) { var stmt = new If (condition, new StatementExpression (invoke), new StatementExpression (assign), loc); - stmt.Emit (ec); + using (ec.With (BuilderContext.Options.OmitDebugInfo, true)) { + stmt.Emit (ec); + } } } @@ -734,15 +734,6 @@ namespace Mono.CSharp this.member = member; } - // - // When a return type is known not to be dynamic - // - public DynamicInvocation (ATypeNameExpression member, Arguments args, TypeSpec type, Location loc) - : this (member, args, loc) - { - this.type = type; - } - public static DynamicInvocation CreateSpecialNameInvoke (ATypeNameExpression member, Arguments args, Location loc) { return new DynamicInvocation (member, args, loc) { @@ -957,15 +948,15 @@ namespace Mono.CSharp sealed class DynamicSiteClass : HoistedStoreyClass { - public DynamicSiteClass (TypeContainer parent, MemberBase host, TypeParameters tparams) - : base (parent, MakeMemberName (host, "DynamicSite", parent.DynamicSitesCounter, tparams, Location.Null), tparams, Modifiers.STATIC) + public DynamicSiteClass (TypeDefinition parent, MemberBase host, TypeParameters tparams) + : base (parent, MakeMemberName (host, "DynamicSite", parent.DynamicSitesCounter, tparams, Location.Null), tparams, Modifiers.STATIC, MemberKind.Class) { parent.DynamicSitesCounter++; } public FieldSpec CreateCallSiteField (FullNamedExpression type, Location loc) { - int index = fields == null ? 0 : fields.Count; + int index = AnonymousMethodsCounter++; Field f = new HoistedField (this, type, Modifiers.PUBLIC | Modifiers.STATIC, "Site" + index.ToString ("X"), null, loc); f.Define (); diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/ecore.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/ecore.cs index b5fe92484b..4ccc3c3e92 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/ecore.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/ecore.cs @@ -118,6 +118,11 @@ namespace Mono.CSharp { bool IsFixed { get; } } + public interface IExpressionCleanup + { + void EmitCleanup (EmitContext ec); + } + /// /// Base class for expressions /// @@ -222,8 +227,7 @@ namespace Mono.CSharp { public static void Error_InvalidExpressionStatement (Report Report, Location loc) { - Report.Error (201, loc, "Only assignment, call, increment, decrement, and new object " + - "expressions can be used as a statement"); + Report.Error (201, loc, "Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement"); } public void Error_InvalidExpressionStatement (BlockContext ec) @@ -236,7 +240,7 @@ namespace Mono.CSharp { Report.Error (1547, loc, "Keyword `void' cannot be used in this context"); } - public virtual void Error_ValueCannotBeConverted (ResolveContext ec, Location loc, TypeSpec target, bool expl) + public virtual void Error_ValueCannotBeConverted (ResolveContext ec, TypeSpec target, bool expl) { Error_ValueCannotBeConvertedCore (ec, loc, target, expl); } @@ -316,7 +320,7 @@ namespace Mono.CSharp { TypeManager.CSharpName (type), name); } - public void Error_ValueAssignment (ResolveContext rc, Expression rhs) + public virtual void Error_ValueAssignment (ResolveContext rc, Expression rhs) { if (rhs == EmptyExpression.LValueMemberAccess || rhs == EmptyExpression.LValueMemberOutAccess) { rc.Report.SymbolRelatedToPreviousError (type); @@ -398,7 +402,7 @@ namespace Mono.CSharp { return e; } catch (Exception ex) { - if (loc.IsNull || ec.Module.Compiler.Settings.DebugFlags > 0 || ex is CompletionResult || ec.Report.IsDisabled) + if (loc.IsNull || ec.Module.Compiler.Settings.DebugFlags > 0 || ex is CompletionResult || ec.Report.IsDisabled || ex is FatalException) throw; ec.Report.Error (584, loc, "Internal compiler error: {0}", ex.Message); @@ -536,38 +540,40 @@ namespace Mono.CSharp { ec.EmitThis (); // Emit original code - EmitToFieldSource (ec); - - // - // Store the result to temporary field when we - // cannot load `this' directly - // - var field = ec.GetTemporaryField (type); - if (needs_temporary) { + var field = EmitToFieldSource (ec); + if (field == null) { // - // Create temporary local (we cannot load `this' before Emit) + // Store the result to temporary field when we + // cannot load `this' directly // - var temp = ec.GetTemporaryLocal (type); - ec.Emit (OpCodes.Stloc, temp); + field = ec.GetTemporaryField (type); + if (needs_temporary) { + // + // Create temporary local (we cannot load `this' before Emit) + // + var temp = ec.GetTemporaryLocal (type); + ec.Emit (OpCodes.Stloc, temp); - ec.EmitThis (); - ec.Emit (OpCodes.Ldloc, temp); - field.EmitAssignFromStack (ec); + ec.EmitThis (); + ec.Emit (OpCodes.Ldloc, temp); + field.EmitAssignFromStack (ec); - ec.FreeTemporaryLocal (temp, type); - } else { - field.EmitAssignFromStack (ec); + ec.FreeTemporaryLocal (temp, type); + } else { + field.EmitAssignFromStack (ec); + } } return field; } - protected virtual void EmitToFieldSource (EmitContext ec) + protected virtual FieldExpr EmitToFieldSource (EmitContext ec) { // // Default implementation calls Emit method // Emit (ec); + return null; } protected static void EmitExpressionsList (EmitContext ec, List expressions) @@ -751,6 +757,9 @@ namespace Mono.CSharp { public virtual void Error_OperatorCannotBeApplied (ResolveContext rc, Location loc, string oper, TypeSpec t) { + if (t == InternalType.ErrorType) + return; + rc.Report.Error (23, loc, "The `{0}' operator cannot be applied to operand of type `{1}'", oper, t.GetSignatureForError ()); } @@ -831,21 +840,11 @@ namespace Mono.CSharp { /// /// Reports that we were expecting `expr' to be of class `expected' /// - public void Error_UnexpectedKind (Report r, MemberCore mc, string expected, Location loc) + public void Error_UnexpectedKind (IMemberContext ctx, Expression memberExpr, string expected, string was, Location loc) { - Error_UnexpectedKind (r, mc, expected, ExprClassName, loc); - } + var name = memberExpr.GetSignatureForError (); - public void Error_UnexpectedKind (Report r, MemberCore mc, string expected, string was, Location loc) - { - string name; - if (mc != null) - name = mc.GetSignatureForError (); - else - name = GetSignatureForError (); - - r.Error (118, loc, "`{0}' is a `{1}' but a `{2}' was expected", - name, was, expected); + ctx.Module.Compiler.Report.Error (118, loc, "`{0}' is a `{1}' but a `{2}' was expected", name, was, expected); } public virtual void Error_UnexpectedKind (ResolveContext ec, ResolveFlags flags, Location loc) @@ -916,7 +915,7 @@ namespace Mono.CSharp { converted = Convert.ImplicitConversion (ec, source, btypes.ULong, source.loc); if (converted == null) { - source.Error_ValueCannotBeConverted (ec, source.loc, btypes.Int, false); + source.Error_ValueCannotBeConverted (ec, btypes.Int, false); return null; } } @@ -1032,6 +1031,12 @@ namespace Mono.CSharp { if (es == null) Error_InvalidExpressionStatement (ec); + if (ec.CurrentAnonymousMethod is AsyncInitializer && !(e is Assign) && + (e.Type.IsGenericTask || e.Type == ec.Module.PredefinedTypes.Task.TypeSpec)) { + ec.Report.Warning (4014, 1, e.Location, + "The statement is not awaited and execution of current method continues before the call is completed. Consider using `await' operator"); + } + return es; } @@ -1933,6 +1938,12 @@ namespace Mono.CSharp { #region Properties + public override bool IsSideEffectFree { + get { + return expr.IsSideEffectFree; + } + } + public Expression OriginalExpression { get { return orig_expr; @@ -2005,6 +2016,11 @@ namespace Mono.CSharp { expr.Emit (ec); } + public override Expression EmitToField (EmitContext ec) + { + return expr.EmitToField(ec); + } + public override void EmitBranchable (EmitContext ec, Label target, bool on_true) { expr.EmitBranchable (ec, target, on_true); @@ -2254,12 +2270,10 @@ namespace Mono.CSharp { protected virtual void Error_TypeOrNamespaceNotFound (IMemberContext ctx) { if (ctx.CurrentType != null) { - if (ctx.CurrentMemberDefinition != null) { - MemberCore mc = ctx.CurrentMemberDefinition.Parent.GetDefinition (Name); - if (mc != null) { - Error_UnexpectedKind (ctx.Module.Compiler.Report, mc, "type", GetMemberType (mc), loc); - return; - } + var member = MemberLookup (ctx, false, ctx.CurrentType, Name, 0, MemberLookupRestrictions.ExactArity, loc) as MemberExpr; + if (member != null) { + member.Error_UnexpectedKind (ctx, member, "type", member.KindName, loc); + return; } } @@ -2482,14 +2496,25 @@ namespace Mono.CSharp { ErrorIsInaccesible (rc, e.GetSignatureForError (), loc); return e; } + } else { + var me = MemberLookup (rc, false, rc.CurrentType, Name, Arity, restrictions & ~MemberLookupRestrictions.InvocableOnly, loc) as MemberExpr; + if (me != null) { + me.Error_UnexpectedKind (rc, me, "method group", me.KindName, loc); + return ErrorExpression.Instance; + } } e = rc.LookupNamespaceOrType (Name, -System.Math.Max (1, Arity), LookupMode.Probing, loc); if (e != null) { - if (!(e is TypeExpr) || (restrictions & MemberLookupRestrictions.InvocableOnly) == 0 || !e.Type.IsDelegate) { + if (e.Type.Arity != Arity) { Error_TypeArgumentsCannotBeUsed (rc, e.Type, Arity, loc); return e; } + + if (e is TypeExpr) { + e.Error_UnexpectedKind (rc, e, "variable", e.ExprClassName, loc); + return e; + } } rc.Report.Error (103, loc, "The name `{0}' does not exist in the current context", Name); @@ -2517,8 +2542,8 @@ namespace Mono.CSharp { return null; if (right_side != null) { - if (e is TypeExpr) { - e.Error_UnexpectedKind (ec, ResolveFlags.VariableOrValue, loc); + if (e is FullNamedExpression && e.eclass != ExprClass.Unresolved) { + e.Error_UnexpectedKind (ec, e, "variable", e.ExprClassName, loc); return null; } @@ -2527,7 +2552,6 @@ namespace Mono.CSharp { e = e.Resolve (ec); } - //if (ec.CurrentBlock == null || ec.CurrentBlock.CheckInvariantMeaningInBlock (Name, e, Location)) return e; } @@ -2575,7 +2599,7 @@ namespace Mono.CSharp { TypeExpr te = fne as TypeExpr; if (te == null) { - fne.Error_UnexpectedKind (mc.Module.Compiler.Report, null, "type", loc); + fne.Error_UnexpectedKind (mc, fne, "type", fne.ExprClassName, loc); return null; } @@ -2588,11 +2612,15 @@ namespace Mono.CSharp { ImportedTypeDefinition.Error_MissingDependency (mc, dep, loc); } + if (type.Kind == MemberKind.Void) { + mc.Module.Compiler.Report.Error (673, loc, "System.Void cannot be used from C#. Consider using `void'"); + } + // // Obsolete checks cannot be done when resolving base context as they // require type dependencies to be set but we are in process of resolving them // - if (!(mc is TypeContainer.BaseContext)) { + if (!(mc is TypeDefinition.BaseContext) && !(mc is UsingAliasNamespace.AliasContext)) { ObsoleteAttribute obsolete_attr = type.GetAttributeObsolete (); if (obsolete_attr != null && !mc.IsObsolete) { AttributeTester.Report_ObsoleteMessage (obsolete_attr, te.GetSignatureForError (), Location, mc.Module.Compiler.Report); @@ -2705,6 +2733,10 @@ namespace Mono.CSharp { get; } + public abstract string KindName { + get; + } + protected abstract TypeSpec DeclaringType { get; } @@ -3035,20 +3067,17 @@ namespace Mono.CSharp { public class ExtensionMethodCandidates { - NamespaceContainer container; - Namespace ns; - IList methods; + readonly NamespaceContainer container; + readonly IList methods; + readonly int index; + readonly IMemberContext context; - public ExtensionMethodCandidates (IList methods, NamespaceContainer nsContainer) - : this (methods, nsContainer, null) - { - } - - public ExtensionMethodCandidates (IList methods, NamespaceContainer nsContainer, Namespace ns) + public ExtensionMethodCandidates (IMemberContext context, IList methods, NamespaceContainer nsContainer, int lookupIndex) { + this.context = context; this.methods = methods; this.container = nsContainer; - this.ns = ns; + this.index = lookupIndex; } public NamespaceContainer Container { @@ -3057,11 +3086,15 @@ namespace Mono.CSharp { } } - public bool HasUninspectedMembers { get; set; } + public IMemberContext Context { + get { + return context; + } + } - public Namespace Namespace { + public int LookupIndex { get { - return ns; + return index; } } @@ -3104,38 +3137,7 @@ namespace Mono.CSharp { int arity = type_arguments == null ? 0 : type_arguments.Count; - // - // Here we try to resume the search for extension method at the point - // where the last bunch of candidates was found. It's more tricky than - // it seems as we have to check both namespace containers and namespace - // in correct order. - // - // Consider: - // - // namespace A { - // using N1; - // namespace B.C.D { - // ().ToList (); - } - } - - var ns_container = candidates.HasUninspectedMembers ? candidates.Container : candidates.Container.Parent; - if (ns_container == null) - return null; - - candidates = ns_container.LookupExtensionMethod (ExtensionExpression.Type, Name, arity); + candidates = candidates.Container.LookupExtensionMethod (candidates.Context, ExtensionExpression.Type, Name, arity, candidates.LookupIndex); if (candidates == null) return null; @@ -3280,6 +3282,10 @@ namespace Mono.CSharp { } } + public override string KindName { + get { return "method"; } + } + public override string Name { get { if (best_candidate != null) @@ -3321,7 +3327,7 @@ namespace Mono.CSharp { return null; } - if (best_candidate.IsConditionallyExcluded (ec.Module.Compiler, loc)) + if (best_candidate.IsConditionallyExcluded (ec, loc)) ec.Report.Error (765, loc, "Partial methods with only a defining declaration or removed conditional methods cannot be used in an expression tree"); @@ -3353,7 +3359,7 @@ namespace Mono.CSharp { call.Emit (ec, best_candidate, arguments, loc); } - public override void Error_ValueCannotBeConverted (ResolveContext ec, Location loc, TypeSpec target, bool expl) + public override void Error_ValueCannotBeConverted (ResolveContext ec, TypeSpec target, bool expl) { ec.Report.Error (428, loc, "Cannot convert method group `{0}' to non-delegate type `{1}'. Consider using parentheses to invoke the method", Name, TypeManager.CSharpName (target)); @@ -4054,10 +4060,15 @@ namespace Mono.CSharp { Arguments orig_args = arguments; if (arg_count != param_count) { - for (int i = 0; i < pd.Count; ++i) { - if (pd.FixedParameters[i].HasDefaultValue) { - optional_count = pd.Count - i; - break; + // + // No arguments expansion when doing exact match for delegates + // + if ((restrictions & Restrictions.CovariantDelegate) == 0) { + for (int i = 0; i < pd.Count; ++i) { + if (pd.FixedParameters[i].HasDefaultValue) { + optional_count = pd.Count - i; + break; + } } } @@ -4233,7 +4244,8 @@ namespace Mono.CSharp { for (int i = 0; i < arg_count; i++) { Argument a = arguments[i]; if (a == null) { - if (!pd.FixedParameters[i].HasDefaultValue) { + var fp = pd.FixedParameters[i]; + if (!fp.HasDefaultValue) { arguments = orig_args; return arg_count * 2 + 2; } @@ -4242,7 +4254,7 @@ namespace Mono.CSharp { // Get the default value expression, we can use the same expression // if the type matches // - Expression e = pd.FixedParameters[i].DefaultValue; + Expression e = fp.DefaultValue; if (!(e is Constant) || e.Type.IsGenericOrParentIsGeneric || e.Type.IsGenericParameter) { // // LAMESPEC: No idea what the exact rules are for System.Reflection.Missing.Value instead of null @@ -4257,6 +4269,19 @@ namespace Mono.CSharp { e = e.Resolve (ec); } + if ((fp.ModFlags & Parameter.Modifier.CallerMask) != 0) { + // + // LAMESPEC: Attributes can be mixed together with build-in priority + // + if ((fp.ModFlags & Parameter.Modifier.CallerLineNumber) != 0) { + e = new IntLiteral (ec.BuiltinTypes, loc.Row, loc); + } else if ((fp.ModFlags & Parameter.Modifier.CallerFilePath) != 0) { + e = new StringLiteral (ec.BuiltinTypes, loc.NameFullPath, loc); + } else if (ec.MemberContext.CurrentMemberDefinition != null) { + e = new StringLiteral (ec.BuiltinTypes, ec.MemberContext.CurrentMemberDefinition.GetCallerMemberName (), loc); + } + } + arguments[i] = new Argument (e, Argument.AType.Default); continue; } @@ -4287,7 +4312,7 @@ namespace Mono.CSharp { continue; } } else { - score = IsArgumentCompatible (ec, a, p_mod & ~Parameter.Modifier.PARAMS, pt); + score = IsArgumentCompatible (ec, a, p_mod, pt); if (score < 0) dynamicArgument = true; @@ -4348,7 +4373,7 @@ namespace Mono.CSharp { // Types have to be identical when ref or out modifer // is used and argument is not of dynamic type // - if ((argument.Modifier | param_mod) != 0) { + if (((argument.Modifier | param_mod) & Parameter.Modifier.RefOutMask) != 0) { if (argument.Type != parameter) { // // Do full equality check after quick path @@ -4357,18 +4382,18 @@ namespace Mono.CSharp { // // Using dynamic for ref/out parameter can still succeed at runtime // - if (argument.Type.BuiltinType == BuiltinTypeSpec.Type.Dynamic && argument.Modifier == 0 && (restrictions & Restrictions.CovariantDelegate) == 0) + if (argument.Type.BuiltinType == BuiltinTypeSpec.Type.Dynamic && (argument.Modifier & Parameter.Modifier.RefOutMask) == 0 && (restrictions & Restrictions.CovariantDelegate) == 0) return -1; return 2; } } - if (argument.Modifier != param_mod) { + if ((argument.Modifier & Parameter.Modifier.RefOutMask) != (param_mod & Parameter.Modifier.RefOutMask)) { // // Using dynamic for ref/out parameter can still succeed at runtime // - if (argument.Type.BuiltinType == BuiltinTypeSpec.Type.Dynamic && argument.Modifier == 0 && (restrictions & Restrictions.CovariantDelegate) == 0) + if (argument.Type.BuiltinType == BuiltinTypeSpec.Type.Dynamic && (argument.Modifier & Parameter.Modifier.RefOutMask) == 0 && (restrictions & Restrictions.CovariantDelegate) == 0) return -1; return 1; @@ -4741,9 +4766,12 @@ namespace Mono.CSharp { if (custom_errors != null && custom_errors.ArgumentMismatch (ec, method, a, idx)) return; + if (a.Type == InternalType.ErrorType) + return; + if (a is CollectionElementInitializer.ElementInitializerArgument) { ec.Report.SymbolRelatedToPreviousError (method); - if ((expected_par.FixedParameters[idx].ModFlags & Parameter.Modifier.ISBYREF) != 0) { + if ((expected_par.FixedParameters[idx].ModFlags & Parameter.Modifier.RefOutMask) != 0) { ec.Report.Error (1954, loc, "The best overloaded collection initalizer method `{0}' cannot have 'ref', or `out' modifier", TypeManager.CSharpSignature (method)); return; @@ -4762,15 +4790,14 @@ namespace Mono.CSharp { Parameter.Modifier mod = idx >= expected_par.Count ? 0 : expected_par.FixedParameters[idx].ModFlags; string index = (idx + 1).ToString (); - if (((mod & (Parameter.Modifier.REF | Parameter.Modifier.OUT)) ^ - (a.Modifier & (Parameter.Modifier.REF | Parameter.Modifier.OUT))) != 0) { - if ((mod & Parameter.Modifier.ISBYREF) == 0) + if (((mod & Parameter.Modifier.RefOutMask) ^ (a.Modifier & Parameter.Modifier.RefOutMask)) != 0) { + if ((mod & Parameter.Modifier.RefOutMask) == 0) ec.Report.Error (1615, loc, "Argument `#{0}' does not require `{1}' modifier. Consider removing `{1}' modifier", index, Parameter.GetModifierSignature (a.Modifier)); else ec.Report.Error (1620, loc, "Argument `#{0}' is missing `{1}' modifier", index, Parameter.GetModifierSignature (mod)); - } else if (a.Expr != ErrorExpression.Instance) { + } else { string p1 = a.GetSignatureForError (); string p2 = TypeManager.CSharpName (paramType); @@ -4899,8 +4926,8 @@ namespace Mono.CSharp { // // Types have to be identical when ref or out modifer is used // - if (a.Modifier != 0 || (p_mod & ~Parameter.Modifier.PARAMS) != 0) { - if ((p_mod & ~Parameter.Modifier.PARAMS) != a.Modifier) + if (((a.Modifier | p_mod) & Parameter.Modifier.RefOutMask) != 0) { + if ((a.Modifier & Parameter.Modifier.RefOutMask) != (p_mod & Parameter.Modifier.RefOutMask)) break; if (a.Expr.Type == pt || TypeSpecComparer.IsEqual (a.Expr.Type, pt)) @@ -5039,6 +5066,10 @@ namespace Mono.CSharp { get { throw new NotImplementedException (); } } + public override string KindName { + get { return "constant"; } + } + public override bool IsInstance { get { return !IsStatic; } } @@ -5139,6 +5170,10 @@ namespace Mono.CSharp { } } + public override string KindName { + get { return "field"; } + } + public FieldSpec Spec { get { return spec; @@ -5362,7 +5397,7 @@ namespace Mono.CSharp { if (ec.HasSet (ResolveContext.Options.ConstructorScope)) { // InitOnly fields cannot be assigned-to in a different constructor from their declaring type - if (ec.CurrentMemberDefinition.Parent.Definition != spec.DeclaringType.GetDefinition ()) + if (ec.CurrentMemberDefinition.Parent.PartialContainer.Definition != spec.DeclaringType.GetDefinition ()) return Report_AssignToReadonly (ec, right_side); // static InitOnly fields cannot be assigned-to in an instance constructor if (IsStatic && !ec.IsStatic) @@ -5530,7 +5565,7 @@ namespace Mono.CSharp { base.EmitSideEffect (ec); } - public void AddressOf (EmitContext ec, AddressOp mode) + public virtual void AddressOf (EmitContext ec, AddressOp mode) { if ((mode & AddressOp.Store) != 0) spec.MemberDefinition.SetIsAssigned (); @@ -5645,6 +5680,10 @@ namespace Mono.CSharp { } } + public override string KindName { + get { return "property"; } + } + public PropertySpec PropertyInfo { get { return best_candidate; @@ -5953,10 +5992,11 @@ namespace Mono.CSharp { Emit (ec, false); } - protected override void EmitToFieldSource (EmitContext ec) + protected override FieldExpr EmitToFieldSource (EmitContext ec) { has_await_arguments = true; Emit (ec, false); + return null; } public abstract SLE.Expression MakeAssignExpression (BuilderContext ctx, Expression source); @@ -6058,6 +6098,10 @@ namespace Mono.CSharp { } } + public override string KindName { + get { return "event"; } + } + public MethodSpec Operator { get { return op; @@ -6209,6 +6253,12 @@ namespace Mono.CSharp { variable.li.CreateBuilder (ec); } + public override void Emit (EmitContext ec) + { + // Don't create sequence point + DoEmit (ec); + } + protected override void CloneTo (CloneContext clonectx, Statement target) { // Nothing @@ -6250,9 +6300,10 @@ namespace Mono.CSharp { // // Don't capture temporary variables except when using - // state machine redirection + // state machine redirection and block yields // - if (ec.CurrentAnonymousMethod != null && ec.CurrentAnonymousMethod is StateMachineInitializer && ec.IsVariableCapturingRequired) { + if (ec.CurrentAnonymousMethod != null && ec.CurrentAnonymousMethod.IsIterator && + ec.CurrentBlock.Explicit.HasYield && ec.IsVariableCapturingRequired) { AnonymousMethodStorey storey = li.Block.Explicit.CreateAnonymousMethodStorey (ec); storey.CaptureLocalVariable (ec, li); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/enum.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/enum.cs index 8b0268ed18..126d2de867 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/enum.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/enum.cs @@ -102,7 +102,7 @@ namespace Mono.CSharp { /// /// Enumeration container /// - public class Enum : TypeContainer + public class Enum : TypeDefinition { // // Implicit enum member initializer, used when no constant value is provided @@ -162,10 +162,10 @@ namespace Mono.CSharp { Modifiers.INTERNAL | Modifiers.PRIVATE; - readonly TypeExpr underlying_type_expr; + readonly FullNamedExpression underlying_type_expr; - public Enum (NamespaceContainer ns, TypeContainer parent, TypeExpression type, Modifiers mod_flags, MemberName name, Attributes attrs) - : base (ns, parent, name, attrs, MemberKind.Enum) + public Enum (TypeContainer parent, FullNamedExpression type, Modifiers mod_flags, MemberName name, Attributes attrs) + : base (parent, name, attrs, MemberKind.Enum) { underlying_type_expr = type; var accmods = IsTopLevel ? Modifiers.INTERNAL : Modifiers.PRIVATE; @@ -181,7 +181,7 @@ namespace Mono.CSharp { } } - public TypeExpr BaseTypeExpression { + public FullNamedExpression BaseTypeExpression { get { return underlying_type_expr; } @@ -189,8 +189,7 @@ namespace Mono.CSharp { protected override TypeAttributes TypeAttr { get { - return ModifiersExtensions.TypeAttr (ModFlags, IsTopLevel) | - TypeAttributes.Class | TypeAttributes.Sealed | base.TypeAttr; + return base.TypeAttr | TypeAttributes.Class | TypeAttributes.Sealed; } } @@ -215,7 +214,7 @@ namespace Mono.CSharp { return; } - AddConstant (em); + AddMember (em); } public static void Error_1008 (Location loc, Report Report) @@ -224,27 +223,25 @@ namespace Mono.CSharp { "Type byte, sbyte, short, ushort, int, uint, long or ulong expected"); } - protected override bool DefineNestedTypes () + protected override void DoDefineContainer () { ((EnumSpec) spec).UnderlyingType = underlying_type_expr == null ? Compiler.BuiltinTypes.Int : underlying_type_expr.Type; TypeBuilder.DefineField (UnderlyingValueField, UnderlyingType.GetMetaInfo (), FieldAttributes.Public | FieldAttributes.SpecialName | FieldAttributes.RTSpecialName); - return true; + DefineBaseTypes (); } protected override bool DoDefineMembers () { - if (constants != null) { - for (int i = 0; i < constants.Count; ++i) { - EnumMember em = (EnumMember) constants [i]; - if (em.Initializer == null) { - em.Initializer = new ImplicitInitializer (em, i == 0 ? null : (EnumMember) constants[i - 1]); - } - - em.Define (); + for (int i = 0; i < Members.Count; ++i) { + EnumMember em = (EnumMember) Members[i]; + if (em.Initializer == null) { + em.Initializer = new ImplicitInitializer (em, i == 0 ? null : (EnumMember) Members[i - 1]); } + + em.Define (); } return true; diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/eval.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/eval.cs index 66cfb3b0d5..8b4a348a6c 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/eval.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/eval.cs @@ -72,18 +72,17 @@ namespace Mono.CSharp readonly ReflectionImporter importer; readonly CompilationSourceFile source_file; - public Evaluator (CompilerSettings settings, Report report) + public Evaluator (CompilerContext ctx) { - ctx = new CompilerContext (settings, report); + this.ctx = ctx; module = new ModuleContainer (ctx); module.Evaluator = this; - source_file = new CompilationSourceFile ("{interactive}", "", 1); - source_file.NamespaceContainer = new NamespaceContainer (null, module, null, source_file); + source_file = new CompilationSourceFile (module); + module.AddTypeContainer (source_file); startup_files = ctx.SourceFiles.Count; - ctx.SourceFiles.Add (source_file); // FIXME: Importer needs this assembly for internalsvisibleto module.SetDeclaringAssembly (new AssemblyDefinitionDynamic (module, "evaluator")); @@ -97,7 +96,6 @@ namespace Mono.CSharp { var loader = new DynamicLoader (importer, ctx); - CompilerCallableEntryPoint.Reset (); RootContext.ToplevelTypes = module; //var startup_files = new List (); @@ -118,15 +116,13 @@ namespace Mono.CSharp Location.Initialize (ctx.SourceFiles); for (int i = 0; i < startup_files; ++i) { - var sf = ctx.Settings.SourceFiles [i]; + var sf = ctx.SourceFiles [i]; d.Parse (sf, module); } } void Reset () { - CompilerCallableEntryPoint.PartialReset (); - Location.Reset (); Location.Initialize (ctx.SourceFiles); } @@ -355,8 +351,6 @@ namespace Mono.CSharp bool partial_input; CSharpParser parser = ParseString (ParseMode.GetCompletions, input, out partial_input); if (parser == null){ - if (CSharpParser.yacc_verbose_flag != 0) - Console.WriteLine ("DEBUG: No completions available"); return null; } @@ -372,10 +366,9 @@ namespace Mono.CSharp module.SetDeclaringAssembly (a); // Need to setup MemberCache - parser_result.CreateType (); - parser_result.NamespaceEntry.Define (); + parser_result.CreateContainer (); - var method = parser_result.Methods[0] as Method; + var method = parser_result.Members[0] as Method; BlockContext bc = new BlockContext (method, method.Block, ctx.BuiltinTypes.Void); try { @@ -449,7 +442,7 @@ namespace Mono.CSharp // InputKind ToplevelOrStatement (SeekableStreamReader seekable) { - Tokenizer tokenizer = new Tokenizer (seekable, source_file, ctx); + Tokenizer tokenizer = new Tokenizer (seekable, source_file); int t = tokenizer.token (); switch (t){ @@ -555,7 +548,6 @@ namespace Mono.CSharp { partial_input = false; Reset (); - Tokenizer.LocatedToken.Initialize (); var enc = ctx.Settings.Encoding; var s = new MemoryStream (enc.GetBytes (input)); @@ -578,7 +570,7 @@ namespace Mono.CSharp } seekable.Position = 0; - source_file.NamespaceContainer.DeclarationFound = false; + source_file.DeclarationFound = false; CSharpParser parser = new CSharpParser (seekable, source_file); if (kind == InputKind.StatementOrExpression){ @@ -593,7 +585,7 @@ namespace Mono.CSharp parser.Lexer.CompleteOnEOF = true; ReportPrinter old_printer = null; - if ((mode == ParseMode.Silent || mode == ParseMode.GetCompletions) && CSharpParser.yacc_verbose_flag == 0) + if ((mode == ParseMode.Silent || mode == ParseMode.GetCompletions)) old_printer = ctx.Report.SetPrinter (new StreamReportPrinter (TextWriter.Null)); try { @@ -648,18 +640,19 @@ namespace Mono.CSharp new TypeExpression (base_class_imported, host.Location) }; - host.AddBasesForPart (host, baseclass_list); + host.AddBasesForPart (baseclass_list); - host.CreateType (); - host.DefineType (); + host.CreateContainer (); + host.DefineContainer (); host.Define (); - expression_method = (Method) host.Methods[0]; + expression_method = (Method) host.Members[0]; } else { expression_method = null; } - module.CreateType (); + module.CreateContainer (); + source_file.EnableUsingClausesRedefinition (); module.Define (); if (Report.Errors != 0){ @@ -670,19 +663,19 @@ namespace Mono.CSharp } if (host != null){ - host.EmitType (); + host.EmitContainer (); } - module.Emit (); + module.EmitContainer (); if (Report.Errors != 0){ if (undo != null) undo.ExecuteUndo (); return null; } - module.CloseType (); + module.CloseContainer (); if (host != null) - host.CloseType (); + host.CloseContainer (); if (access == AssemblyBuilderAccess.RunAndSave) assembly.Save (); @@ -697,34 +690,36 @@ namespace Mono.CSharp var tt = assembly.Builder.GetType (host.TypeBuilder.Name); var mi = tt.GetMethod (expression_method.MemberName.Name); - if (host.Fields != null) { - // - // We need to then go from FieldBuilder to FieldInfo - // or reflection gets confused (it basically gets confused, and variables override each - // other). - // - foreach (Field field in host.Fields) { - var fi = tt.GetField (field.Name); - - Tuple old; - - // If a previous value was set, nullify it, so that we do - // not leak memory - if (fields.TryGetValue (field.Name, out old)) { - if (old.Item1.MemberType.IsStruct) { - // - // TODO: Clear fields for structs - // - } else { - try { - old.Item2.SetValue (null, null); - } catch { - } + // + // We need to then go from FieldBuilder to FieldInfo + // or reflection gets confused (it basically gets confused, and variables override each + // other). + // + foreach (var member in host.Members) { + var field = member as Field; + if (field == null) + continue; + + var fi = tt.GetField (field.Name); + + Tuple old; + + // If a previous value was set, nullify it, so that we do + // not leak memory + if (fields.TryGetValue (field.Name, out old)) { + if (old.Item1.MemberType.IsStruct) { + // + // TODO: Clear fields for structs + // + } else { + try { + old.Item2.SetValue (null, null); + } catch { } } - - fields[field.Name] = Tuple.Create (field.Spec, fi); } + + fields[field.Name] = Tuple.Create (field.Spec, fi); } return (CompiledMethod) System.Delegate.CreateDelegate (typeof (CompiledMethod), mi); @@ -761,7 +756,7 @@ namespace Mono.CSharp //foreach (object x in ns.using_alias_list) // sb.AppendFormat ("using {0};\n", x); - foreach (var ue in source_file.NamespaceContainer.Usings) { + foreach (var ue in source_file.Usings) { sb.AppendFormat ("using {0};", ue.ToString ()); sb.Append (Environment.NewLine); } @@ -773,7 +768,7 @@ namespace Mono.CSharp { var res = new List (); - foreach (var ue in source_file.NamespaceContainer.Usings) { + foreach (var ue in source_file.Usings) { if (ue.Alias != null || ue.ResolvedExpression == null) continue; @@ -1046,10 +1041,6 @@ namespace Mono.CSharp { } - public override void EmitSymbolInfo () - { - } - protected override FieldExpr GetFieldExpression (EmitContext ec) { return new FieldExpr (field, field.Location); @@ -1118,7 +1109,7 @@ namespace Mono.CSharp { } - public void AddTypeContainer (TypeContainer current_container, TypeContainer tc) + public void AddTypeContainer (TypeContainer current_container, TypeDefinition tc) { if (current_container == tc){ Console.Error.WriteLine ("Internal error: inserting container into itself"); @@ -1128,14 +1119,13 @@ namespace Mono.CSharp if (undo_actions == null) undo_actions = new List (); - var existing = current_container.Types.FirstOrDefault (l => l.MemberName.Basename == tc.MemberName.Basename); + var existing = current_container.Containers.FirstOrDefault (l => l.Basename == tc.Basename); if (existing != null) { - current_container.RemoveTypeContainer (existing); - existing.NamespaceEntry.SlaveDeclSpace.RemoveTypeContainer (existing); + current_container.RemoveContainer (existing); undo_actions.Add (() => current_container.AddTypeContainer (existing)); } - undo_actions.Add (() => current_container.RemoveTypeContainer (tc)); + undo_actions.Add (() => current_container.RemoveContainer (tc)); } public void ExecuteUndo () diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/expression.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/expression.cs index 94d014b017..3091426b4e 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/expression.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/expression.cs @@ -103,7 +103,12 @@ namespace Mono.CSharp protected override Expression DoResolve (ResolveContext ec) { - return expr.Resolve (ec); + var res = expr.Resolve (ec); + var constant = res as Constant; + if (constant != null && constant.IsLiteral) + return Constant.CreateConstantFromValue (res.Type, constant.GetValue (), expr.Location); + + return res; } public override Expression DoResolveLValue (ResolveContext ec, Expression right_side) @@ -142,10 +147,12 @@ namespace Mono.CSharp // This routine will attempt to simplify the unary expression when the // argument is a constant. // - Constant TryReduceConstant (ResolveContext ec, Constant e) + Constant TryReduceConstant (ResolveContext ec, Constant constant) { - if (e is EmptyConstantCast) - return TryReduceConstant (ec, ((EmptyConstantCast) e).child); + var e = constant; + + while (e is EmptyConstantCast) + e = ((EmptyConstantCast) e).child; if (e is SideEffectConstant) { Constant r = TryReduceConstant (ec, ((SideEffectConstant) e).value); @@ -220,7 +227,7 @@ namespace Mono.CSharp return new LongConstant (ec.BuiltinTypes, -lvalue, e.Location); case BuiltinTypeSpec.Type.UInt: - UIntLiteral uil = e as UIntLiteral; + UIntLiteral uil = constant as UIntLiteral; if (uil != null) { if (uil.Value == int.MaxValue + (uint) 1) return new IntLiteral (ec.BuiltinTypes, int.MinValue, e.Location); @@ -230,13 +237,13 @@ namespace Mono.CSharp case BuiltinTypeSpec.Type.ULong: - ULongLiteral ull = e as ULongLiteral; + ULongLiteral ull = constant as ULongLiteral; if (ull != null && ull.Value == 9223372036854775808) return new LongLiteral (ec.BuiltinTypes, long.MinValue, e.Location); return null; case BuiltinTypeSpec.Type.Float: - FloatLiteral fl = e as FloatLiteral; + FloatLiteral fl = constant as FloatLiteral; // For better error reporting if (fl != null) return new FloatLiteral (ec.BuiltinTypes, -fl.Value, e.Location); @@ -244,7 +251,7 @@ namespace Mono.CSharp return new FloatConstant (ec.BuiltinTypes, -((FloatConstant) e).Value, e.Location); case BuiltinTypeSpec.Type.Double: - DoubleLiteral dl = e as DoubleLiteral; + DoubleLiteral dl = constant as DoubleLiteral; // For better error reporting if (dl != null) return new DoubleLiteral (ec.BuiltinTypes, -dl.Value, e.Location); @@ -620,7 +627,7 @@ namespace Mono.CSharp return is_checked ? SLE.Expression.NegateChecked (expr) : SLE.Expression.Negate (expr); case Operator.LogicalNot: return SLE.Expression.Not (expr); -#if NET_4_0 +#if NET_4_0 || MONODROID case Operator.OnesComplement: return SLE.Expression.OnesComplement (expr); #endif @@ -1268,7 +1275,7 @@ namespace Mono.CSharp } -#if NET_4_0 +#if NET_4_0 || MONODROID public override SLE.Expression MakeExpression (BuilderContext ctx) { var target = ((RuntimeValueExpression) expr).MetaObject.Expression; @@ -1687,19 +1694,19 @@ namespace Mono.CSharp return null; } - eclass = ExprClass.Value; + if (type.IsPointer && !ec.IsUnsafe) { + UnsafeError (ec, loc); + } + eclass = ExprClass.Value; + Constant c = expr as Constant; if (c != null) { - c = c.TryReduce (ec, type, loc); + c = c.TryReduce (ec, type); if (c != null) return c; } - if (type.IsPointer && !ec.IsUnsafe) { - UnsafeError (ec, loc); - } - var res = Convert.ExplicitConversion (ec, expr, type, loc); if (res == expr) return EmptyCast.Create (res, type); @@ -1820,7 +1827,7 @@ namespace Mono.CSharp temp_storage.Release (ec); } -#if NET_4_0 && !STATIC +#if (NET_4_0 || MONODROID) && !STATIC public override SLE.Expression MakeExpression (BuilderContext ctx) { return SLE.Expression.Default (type.GetMetaInfo ()); @@ -2654,7 +2661,7 @@ namespace Mono.CSharp return left; if (left.IsZeroInteger) - return left.TryReduce (ec, right.Type, loc); + return left.TryReduce (ec, right.Type); break; @@ -3664,7 +3671,7 @@ namespace Mono.CSharp // // Merge two sets of user operators into one, they are mostly distinguish - // expect when they share base type and it contains an operator + // except when they share base type and it contains an operator // static IList CombineUserOperators (IList left, IList right) { @@ -3929,6 +3936,27 @@ namespace Mono.CSharp } } + public override Expression EmitToField (EmitContext ec) + { + if ((oper & Operator.LogicalMask) == 0) { + var await_expr = left as Await; + if (await_expr != null && right.IsSideEffectFree) { + await_expr.Statement.EmitPrologue (ec); + left = await_expr.Statement.GetResultExpression (ec); + return this; + } + + await_expr = right as Await; + if (await_expr != null && left.IsSideEffectFree) { + await_expr.Statement.EmitPrologue (ec); + right = await_expr.Statement.GetResultExpression (ec); + return this; + } + } + + return base.EmitToField (ec); + } + protected override void CloneTo (CloneContext clonectx, Expression t) { Binary target = (Binary) t; @@ -4245,7 +4273,7 @@ namespace Mono.CSharp // bool right_contains_await = ec.HasSet (BuilderContext.Options.AsyncBody) && arguments[1].Expr.ContainsEmitWithAwait (); if (right_contains_await) { - arguments[0] = arguments[0].EmitToField (ec); + arguments[0] = arguments[0].EmitToField (ec, false); arguments[0].Expr.Emit (ec); } else { arguments[0].Expr.Emit (ec); @@ -4476,7 +4504,7 @@ namespace Mono.CSharp // converted = GetOperatorTrue (ec, expr, loc); if (converted == null) { - expr.Error_ValueCannotBeConverted (ec, loc, type, false); + expr.Error_ValueCannotBeConverted (ec, type, false); return null; } @@ -4961,22 +4989,25 @@ namespace Mono.CSharp return this; } - public override Expression DoResolveLValue (ResolveContext ec, Expression right_side) + public override Expression DoResolveLValue (ResolveContext ec, Expression rhs) { - // is out param - if (right_side == EmptyExpression.OutAccess) + // + // Don't be too pedantic when variable is used as out param or for some broken code + // which uses property/indexer access to run some initialization + // + if (rhs == EmptyExpression.OutAccess || rhs.eclass == ExprClass.PropertyAccess || rhs.eclass == ExprClass.IndexerAccess) local_info.SetIsUsed (); if (local_info.IsReadonly && !ec.HasAny (ResolveContext.Options.FieldInitializerScope | ResolveContext.Options.UsingInitializerScope)) { int code; string msg; - if (right_side == EmptyExpression.OutAccess) { + if (rhs == EmptyExpression.OutAccess) { code = 1657; msg = "Cannot pass `{0}' as a ref or out argument because it is a `{1}'"; - } else if (right_side == EmptyExpression.LValueMemberAccess) { + } else if (rhs == EmptyExpression.LValueMemberAccess) { code = 1654; msg = "Cannot assign to members of `{0}' because it is a `{1}'"; - } else if (right_side == EmptyExpression.LValueMemberOutAccess) { + } else if (rhs == EmptyExpression.LValueMemberOutAccess) { code = 1655; msg = "Cannot pass members of `{0}' as ref or out arguments because it is a `{1}'"; - } else if (right_side == EmptyExpression.UnaryAddress) { + } else if (rhs == EmptyExpression.UnaryAddress) { code = 459; msg = "Cannot take the address of {1} `{0}'"; } else { code = 1656; msg = "Cannot assign to `{0}' because it is a `{1}'"; @@ -4989,7 +5020,7 @@ namespace Mono.CSharp if (eclass == ExprClass.Unresolved) DoResolveBase (ec); - return base.DoResolveLValue (ec, right_side); + return base.DoResolveLValue (ec, rhs); } public override int GetHashCode () @@ -5052,11 +5083,11 @@ namespace Mono.CSharp } public override bool IsRef { - get { return (pi.Parameter.ModFlags & Parameter.Modifier.ISBYREF) != 0; } + get { return (pi.Parameter.ModFlags & Parameter.Modifier.RefOutMask) != 0; } } bool HasOutModifier { - get { return pi.Parameter.ModFlags == Parameter.Modifier.OUT; } + get { return (pi.Parameter.ModFlags & Parameter.Modifier.OUT) != 0; } } public override HoistedVariable GetHoistedVariable (AnonymousExpression ae) @@ -5138,7 +5169,7 @@ namespace Mono.CSharp if (ec.IsVariableCapturingRequired && !pi.Block.ParametersBlock.IsExpressionTree) { AnonymousMethodStorey storey = pi.Block.Explicit.CreateAnonymousMethodStorey (ec); - storey.CaptureParameter (ec, this); + storey.CaptureParameter (ec, pi, this); } } @@ -5249,6 +5280,12 @@ namespace Mono.CSharp return expr; } } + + public MethodGroupExpr MethodGroup { + get { + return mg; + } + } #endregion protected override void CloneTo (CloneContext clonectx, Expression t) @@ -5401,7 +5438,8 @@ namespace Mono.CSharp // Any value type has to be pass as by-ref to get back the same // instance on which the member was called // - var mod = TypeSpec.IsValueType (ma.LeftExpression.Type) ? Argument.AType.Ref : Argument.AType.None; + var mod = ma.LeftExpression is IMemoryLocation && TypeSpec.IsValueType (ma.LeftExpression.Type) ? + Argument.AType.Ref : Argument.AType.None; args.Insert (0, new Argument (ma.LeftExpression.Resolve (ec), mod)); } } else { // is SimpleName @@ -5421,16 +5459,6 @@ namespace Mono.CSharp return mg.OverloadResolve (ec, ref arguments, null, OverloadResolver.Restrictions.None); } - static MetaType[] GetVarargsTypes (MethodSpec mb, Arguments arguments) - { - AParametersCollection pd = mb.Parameters; - - Argument a = arguments[pd.Count - 1]; - Arglist list = (Arglist) a.Expr; - - return list.ArgumentTypes; - } - public override string GetSignatureForError () { return mg.GetSignatureForError (); @@ -6058,18 +6086,11 @@ namespace Mono.CSharp Dictionary bounds; +#if STATIC // The number of constants in array initializers int const_initializers_count; bool only_constant_initializers; - - public List Arguments { - get { return this.arguments; } - } - - public FullNamedExpression NewType { - get { return this.requested_base_type; } - } - +#endif public ArrayCreation (FullNamedExpression requested_base_type, List exprs, ComposedTypeSpecifier rank, ArrayInitializer initializers, Location l) : this (requested_base_type, rank, initializers, l) { @@ -6124,7 +6145,11 @@ namespace Mono.CSharp return this.initializers; } } - + + public List Arguments { + get { return this.arguments; } + } + bool CheckIndices (ResolveContext ec, ArrayInitializer probe, int idx, bool specified_dims, int child_bounds) { if (initializers != null && bounds == null) { @@ -6197,7 +6222,7 @@ namespace Mono.CSharp Expression element = ResolveArrayElement (ec, o); if (element == null) continue; - +#if STATIC // Initializers with the default values can be ignored Constant c = element as Constant; if (c != null) { @@ -6207,7 +6232,7 @@ namespace Mono.CSharp } else { only_constant_initializers = false; } - +#endif array_data.Add (element); } } @@ -6310,7 +6335,9 @@ namespace Mono.CSharp protected bool ResolveInitializers (ResolveContext ec) { +#if STATIC only_constant_initializers = true; +#endif if (arguments != null) { bool res = true; @@ -6515,7 +6542,7 @@ namespace Mono.CSharp return data; } -#if NET_4_0 +#if NET_4_0 || MONODROID public override SLE.Expression MakeExpression (BuilderContext ctx) { #if STATIC @@ -6637,6 +6664,11 @@ namespace Mono.CSharp } public override void Emit (EmitContext ec) + { + EmitToFieldSource (ec); + } + + protected sealed override FieldExpr EmitToFieldSource (EmitContext ec) { if (first_emit != null) { first_emit.Emit (ec); @@ -6656,7 +6688,7 @@ namespace Mono.CSharp ec.EmitArrayNew ((ArrayContainer) type); if (initializers == null) - return; + return await_stack_field; if (await_stack_field != null) await_stack_field.EmitAssignFromStack (ec); @@ -6681,11 +6713,10 @@ namespace Mono.CSharp EmitDynamicInitializers (ec, true, await_stack_field); } - if (await_stack_field != null) - await_stack_field.Emit (ec); - if (first_emit_temp != null) first_emit_temp.Release (ec); + + return await_stack_field; } public override void EncodeAttributeValue (IMemberContext rc, AttributeEncoder enc, TypeSpec targetType) @@ -6984,15 +7015,7 @@ namespace Mono.CSharp return null; AnonymousMethodStorey storey = ae.Storey; - while (storey != null) { - AnonymousMethodStorey temp = storey.Parent as AnonymousMethodStorey; - if (temp == null) - return storey.HoistedThis; - - storey = temp; - } - - return null; + return storey != null ? storey.HoistedThis : null; } public static bool IsThisAvailable (ResolveContext ec, bool ignoreAnonymous) @@ -7021,11 +7044,20 @@ namespace Mono.CSharp var block = ec.CurrentBlock; if (block != null) { - if (block.ParametersBlock.TopBlock.ThisVariable != null) - variable_info = block.ParametersBlock.TopBlock.ThisVariable.VariableInfo; + var top = block.ParametersBlock.TopBlock; + if (top.ThisVariable != null) + variable_info = top.ThisVariable.VariableInfo; AnonymousExpression am = ec.CurrentAnonymousMethod; - if (am != null && ec.IsVariableCapturingRequired) { + if (am != null && ec.IsVariableCapturingRequired && !block.Explicit.HasCapturedThis) { + // + // Hoisted this is almost like hoisted variable but not exactly. When + // there is no variable hoisted we can simply emit an instance method + // without lifting this into a storey. Unfotunatelly this complicates + // this in other cases because we don't know where this will be hoisted + // until top-level block is fully resolved + // + top.AddThisReferenceFromChildrenBlock (block.Explicit); am.SetHasThisAccess (); } } @@ -7428,9 +7460,7 @@ namespace Mono.CSharp if (typearg == null) return null; - if (typearg.Kind == MemberKind.Void && !(QueriedType is TypeExpression)) { - ec.Report.Error (673, loc, "System.Void cannot be used from C#. Use typeof (void) to get the void type object"); - } else if (typearg.BuiltinType == BuiltinTypeSpec.Type.Dynamic) { + if (typearg.BuiltinType == BuiltinTypeSpec.Type.Dynamic) { ec.Report.Error (1962, QueriedType.Location, "The typeof operator cannot be used on the dynamic type"); } @@ -8208,9 +8238,9 @@ namespace Mono.CSharp return; } - var any_other_member = MemberLookup (rc, true, expr_type, Name, 0, MemberLookupRestrictions.None, loc); + var any_other_member = MemberLookup (rc, false, expr_type, Name, 0, MemberLookupRestrictions.None, loc); if (any_other_member != null) { - any_other_member.Error_UnexpectedKind (rc.Module.Compiler.Report, null, "type", loc); + any_other_member.Error_UnexpectedKind (rc, any_other_member, "type", any_other_member.ExprClassName, loc); return; } @@ -8434,8 +8464,11 @@ namespace Mono.CSharp return new IndexerExpr (indexers, type, this); } - ec.Report.Error (21, loc, "Cannot apply indexing with [] to an expression of type `{0}'", - type.GetSignatureForError ()); + if (type != InternalType.ErrorType) { + ec.Report.Error (21, loc, "Cannot apply indexing with [] to an expression of type `{0}'", + type.GetSignatureForError ()); + } + return null; } @@ -8746,7 +8779,7 @@ namespace Mono.CSharp public SLE.Expression MakeAssignExpression (BuilderContext ctx, Expression source) { -#if NET_4_0 +#if NET_4_0 || MONODROID return SLE.Expression.ArrayAccess (ea.Expr.MakeExpression (ctx), MakeExpressionArguments (ctx)); #else throw new NotImplementedException (); @@ -8813,6 +8846,10 @@ namespace Mono.CSharp } } + public override string KindName { + get { return "indexer"; } + } + public override string Name { get { return "this"; @@ -8914,7 +8951,7 @@ namespace Mono.CSharp #else var value = new[] { source.MakeExpression (ctx) }; var args = Arguments.MakeExpression (arguments, ctx).Concat (value); -#if NET_4_0 +#if NET_4_0 || MONODROID return SLE.Expression.Block ( SLE.Expression.Call (InstanceExpression.MakeExpression (ctx), (MethodInfo) Setter.GetMetaInfo (), args), value [0]); @@ -9253,11 +9290,15 @@ namespace Mono.CSharp return this; } + public override void Error_ValueAssignment (ResolveContext rc, Expression rhs) + { + } + public override void Error_UnexpectedKind (ResolveContext ec, ResolveFlags flags, Location loc) { } - public override void Error_ValueCannotBeConverted (ResolveContext ec, Location loc, TypeSpec target, bool expl) + public override void Error_ValueCannotBeConverted (ResolveContext ec, TypeSpec target, bool expl) { } @@ -10016,8 +10057,11 @@ namespace Mono.CSharp public override void EmitStatement (EmitContext ec) { - foreach (ExpressionStatement e in initializers) + foreach (ExpressionStatement e in initializers) { + // TODO: need location region + ec.Mark (e.Location); e.EmitStatement (ec); + } } } @@ -10245,9 +10289,8 @@ namespace Mono.CSharp return null; int errors = ec.Report.Errors; - type.CreateType (); - type.DefineType (); - type.ResolveTypeParameters (); + type.CreateContainer (); + type.DefineContainer (); type.Define (); if ((ec.Report.Errors - errors) == 0) { parent.Module.AddAnonymousType (type); @@ -10262,8 +10305,11 @@ namespace Mono.CSharp return base.CreateExpressionTree (ec); var init = new ArrayInitializer (parameters.Count, loc); - foreach (Property p in anonymous_type.Properties) - init.Add (new TypeOfMethod (MemberCache.GetMember (type, p.Get.Spec), loc)); + foreach (var m in anonymous_type.Members) { + var p = m as Property; + if (p != null) + init.Add (new TypeOfMethod (MemberCache.GetMember (type, p.Get.Spec), loc)); + } var ctor_args = new ArrayInitializer (arguments.Count, loc); foreach (Argument a in arguments) @@ -10292,7 +10338,7 @@ namespace Mono.CSharp bool error = false; arguments = new Arguments (parameters.Count); - TypeExpression [] t_args = new TypeExpression [parameters.Count]; + var t_args = new TypeSpec [parameters.Count]; for (int i = 0; i < parameters.Count; ++i) { Expression e = parameters [i].Resolve (ec); if (e == null) { @@ -10301,7 +10347,7 @@ namespace Mono.CSharp } arguments.Add (new Argument (e)); - t_args [i] = new TypeExpression (e.Type, e.Location); + t_args [i] = e.Type; } if (error) @@ -10311,8 +10357,15 @@ namespace Mono.CSharp if (anonymous_type == null) return null; - RequestedType = new GenericTypeExpr (anonymous_type.Definition, new TypeArguments (t_args), loc); - return base.DoResolve (ec); + type = anonymous_type.Definition.MakeGenericType (ec.Module, t_args); + method = (MethodSpec) MemberCache.FindMember (type, MemberFilter.Constructor (null), BindingRestriction.DeclaredOnly); + eclass = ExprClass.Value; + return this; + } + + public override void EmitStatement (EmitContext ec) + { + base.EmitStatement (ec); } public override object Accept (StructuralVisitor visitor) diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/field.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/field.cs index 9178571e78..d38ecc945a 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/field.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/field.cs @@ -62,7 +62,7 @@ namespace Mono.CSharp static readonly string[] attribute_targets = new string [] { "field" }; - protected FieldBase (TypeContainer parent, FullNamedExpression type, Modifiers mod, Modifiers allowed_mod, MemberName name, Attributes attrs) + protected FieldBase (TypeDefinition parent, FullNamedExpression type, Modifiers mod, Modifiers allowed_mod, MemberName name, Attributes attrs) : base (parent, type, mod, allowed_mod | Modifiers.ABSTRACT, Modifiers.PRIVATE, name, attrs) { if ((mod & Modifiers.ABSTRACT) != 0) @@ -118,8 +118,7 @@ namespace Mono.CSharp declarators.Add (declarator); - // TODO: This will probably break - Parent.AddMember (this, declarator.Name.Value); + Parent.AddNameToContainer (this, declarator.Name.Value); } public override void ApplyAttributeBuilder (Attribute a, MethodSpec ctor, byte[] cdata, PredefinedAttributes pa) @@ -233,12 +232,14 @@ namespace Mono.CSharp { if (member_type.BuiltinType == BuiltinTypeSpec.Type.Dynamic) { Module.PredefinedAttributes.Dynamic.EmitAttribute (FieldBuilder); - } else if (!(Parent is CompilerGeneratedClass) && member_type.HasDynamicElement) { + } else if (!Parent.IsCompilerGenerated && member_type.HasDynamicElement) { Module.PredefinedAttributes.Dynamic.EmitAttribute (FieldBuilder, member_type, Location); } if ((ModFlags & Modifiers.COMPILER_GENERATED) != 0 && !Parent.IsCompilerGenerated) Module.PredefinedAttributes.CompilerGenerated.EmitAttribute (FieldBuilder); + if ((ModFlags & Modifiers.DEBUGGER_HIDDEN) != 0) + Module.PredefinedAttributes.DebuggerBrowsable.EmitAttribute (FieldBuilder, System.Diagnostics.DebuggerBrowsableState.Never); if (OptAttributes != null) { OptAttributes.Emit (); @@ -375,7 +376,7 @@ namespace Mono.CSharp Modifiers.PRIVATE | Modifiers.UNSAFE; - public FixedField (TypeContainer parent, FullNamedExpression type, Modifiers mod, MemberName name, Attributes attrs) + public FixedField (TypeDefinition parent, FullNamedExpression type, Modifiers mod, MemberName name, Attributes attrs) : base (parent, type, mod, AllowedModifiers, name, attrs) { } @@ -407,12 +408,12 @@ namespace Mono.CSharp GetSignatureForError ()); } else if (declarators != null) { var t = new TypeExpression (MemberType, TypeExpression.Location); - int index = Parent.PartialContainer.Fields.IndexOf (this); foreach (var d in declarators) { var f = new FixedField (Parent, t, ModFlags, new MemberName (d.Name.Value, d.Name.Location), OptAttributes); f.initializer = d.Initializer; ((ConstInitializer) f.initializer).Name = d.Name.Value; - Parent.PartialContainer.Fields.Insert (++index, f); + f.Define (); + Parent.PartialContainer.Members.Add (f); } } @@ -577,7 +578,7 @@ namespace Mono.CSharp Modifiers.UNSAFE | Modifiers.READONLY; - public Field (TypeContainer parent, FullNamedExpression type, Modifiers mod, MemberName name, Attributes attrs) + public Field (TypeDefinition parent, FullNamedExpression type, Modifiers mod, MemberName name, Attributes attrs) : base (parent, type, mod, AllowedModifiers, name, attrs) { } @@ -639,19 +640,19 @@ namespace Mono.CSharp } if (initializer != null) { - ((TypeContainer) Parent).RegisterFieldForInitialization (this, + Parent.RegisterFieldForInitialization (this, new FieldInitializer (spec, initializer, this)); } if (declarators != null) { var t = new TypeExpression (MemberType, TypeExpression.Location); - int index = Parent.PartialContainer.Fields.IndexOf (this); foreach (var d in declarators) { var f = new Field (Parent, t, ModFlags, new MemberName (d.Name.Value, d.Name.Location), OptAttributes); if (d.Initializer != null) f.initializer = d.Initializer; - Parent.PartialContainer.Fields.Insert (++index, f); + f.Define (); + Parent.PartialContainer.Members.Add (f); } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/flowanalysis.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/flowanalysis.cs index 188d8f3a6f..5efeccb8fb 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/flowanalysis.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/flowanalysis.cs @@ -1213,7 +1213,6 @@ namespace Mono.CSharp class StructInfo { - public readonly TypeSpec Type; readonly List fields; public readonly TypeInfo[] StructFields; public readonly int Length; @@ -1223,14 +1222,13 @@ namespace Mono.CSharp private Dictionary struct_field_hash; private Dictionary field_hash; - protected bool InTransit; + bool InTransit; - // Private constructor. To save memory usage, we only need to create one instance - // of this class per struct type. - private StructInfo (TypeSpec type) + // + // We only need one instance per type + // + StructInfo (TypeSpec type) { - this.Type = type; - field_type_hash.Add (type, this); fields = MemberCache.GetAllFieldsForDefiniteAssignment (type); @@ -1327,7 +1325,7 @@ namespace Mono.CSharp // public class VariableInfo { readonly string Name; - public readonly TypeInfo TypeInfo; + readonly TypeInfo TypeInfo; // // The bit offset of this variable in the flow vector. @@ -1348,7 +1346,7 @@ namespace Mono.CSharp VariableInfo[] sub_info; - protected VariableInfo (string name, TypeSpec type, int offset) + VariableInfo (string name, TypeSpec type, int offset) { this.Name = name; this.Offset = offset; @@ -1359,7 +1357,7 @@ namespace Mono.CSharp Initialize (); } - protected VariableInfo (VariableInfo parent, TypeInfo type) + VariableInfo (VariableInfo parent, TypeInfo type) { this.Name = parent.Name; this.TypeInfo = type; @@ -1451,6 +1449,11 @@ namespace Mono.CSharp return !ec.DoFlowAnalysis || ec.CurrentBranching.IsStructFieldAssigned (this, name); } + public bool IsFullyInitialized (BlockContext bc, Location loc) + { + return TypeInfo.IsFullyInitialized (bc, this, loc); + } + public bool IsStructFieldAssigned (MyBitVector vector, string field_name) { int field_idx = TypeInfo.GetFieldIndex (field_name); @@ -1495,7 +1498,7 @@ namespace Mono.CSharp var complex_field = TypeInfo.GetStructField (field_name); if (complex_field != null) { - vector.SetRange (complex_field.Offset, complex_field.TotalLength); + vector.SetRange (Offset + complex_field.Offset, complex_field.TotalLength); } else { vector[Offset + field_idx] = true; } @@ -1505,7 +1508,7 @@ namespace Mono.CSharp // // Each field must be assigned // - for (int i = Offset + 1; i <= TypeInfo.TotalLength + Offset; i++) { + for (int i = Offset + 1; i < TypeInfo.TotalLength + Offset; i++) { if (!vector[i]) return; } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/generic.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/generic.cs index 81f9665bc1..6f1b92cbe1 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/generic.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/generic.cs @@ -422,6 +422,12 @@ namespace Mono.CSharp { } } + bool ITypeDefinition.IsPartial { + get { + return false; + } + } + public bool IsMethodTypeParameter { get { return spec.IsMethodOwned; @@ -479,7 +485,7 @@ namespace Mono.CSharp { // already have constraints they become our constraints. If we already // have constraints, we must check that they're the same. // - public bool AddPartialConstraints (TypeContainer part, TypeParameter tp) + public bool AddPartialConstraints (TypeDefinition part, TypeParameter tp) { if (builder == null) throw new InvalidOperationException (); @@ -1831,9 +1837,13 @@ namespace Mono.CSharp { return; } - var tc = open_type.MemberDefinition as TypeContainer; - if (tc != null && !tc.HasMembersDefined) - throw new InternalErrorException ("Inflating MemberCache with undefined members"); + var tc = open_type.MemberDefinition as TypeDefinition; + if (tc != null && !tc.HasMembersDefined) { + // + // Inflating MemberCache with undefined members + // + return; + } if ((state & StateFlags.PendingBaseTypeInflate) != 0) { BaseType = inflator.Inflate (open_type.BaseType); @@ -2094,6 +2104,11 @@ namespace Mono.CSharp { return null; } + public string[] GetAllNames () + { + return names.Select (l => l.Name).ToArray (); + } + public string GetSignatureForError () { StringBuilder sb = new StringBuilder (); @@ -2137,10 +2152,6 @@ namespace Mono.CSharp { this.args = args; } - public TypeArguments TypeArguments { - get { return args; } - } - public override string GetSignatureForError () { return TypeManager.CSharpName (type); @@ -2495,7 +2506,7 @@ namespace Mono.CSharp { return false; } - bool HasDefaultConstructor (TypeSpec atype) + static bool HasDefaultConstructor (TypeSpec atype) { var tp = atype as TypeParameterSpec; if (tp != null) { @@ -2849,16 +2860,17 @@ namespace Mono.CSharp { if (!u.IsArray) return 0; - // TODO MemberCache: GetMetaInfo () - if (u.GetMetaInfo ().GetArrayRank () != v.GetMetaInfo ().GetArrayRank ()) + var ac_u = (ArrayContainer) u; + var ac_v = (ArrayContainer) v; + if (ac_u.Rank != ac_v.Rank) return 0; - return ExactInference (TypeManager.GetElementType (u), TypeManager.GetElementType (v)); + return ExactInference (ac_u.Element, ac_v.Element); } // If V is constructed type and U is constructed type if (TypeManager.IsGenericType (v)) { - if (!TypeManager.IsGenericType (u)) + if (!TypeManager.IsGenericType (u) || v.MemberDefinition != u.MemberDefinition) return 0; TypeSpec [] ga_u = TypeManager.GetTypeArguments (u); diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.csproj b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.csproj deleted file mode 100644 index b371739189..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.csproj +++ /dev/null @@ -1,111 +0,0 @@ - - - - Debug - AnyCPU - 9.0.30729 - 2.0 - {D4A01C5B-A1B5-48F5-BB5B-D2E1BD236E56} - Library - Properties - gmcs - gmcs - v3.5 - 512 - - - true - full - false - ..\..\..\monodevelop\main\build\bin - TRACE;DEBUG;NET_2_0;MS_COMPATIBLE;FULL_AST;BOOTSTRAP_BASIC - prompt - 4 - false - - - pdbonly - true - TRACE;NET_2_0;MS_COMPATIBLE - prompt - TRACE;NET_2_0;MS_COMPATIBLE - prompt - 4 - ..\..\..\monodevelop\main\build\bin - - - - - 3.5 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.exe.config b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.exe.config deleted file mode 100644 index 4b560e2f7a..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.exe.config +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - - - - - - - - diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.exe.sources b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.exe.sources deleted file mode 100644 index 03738c5032..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.exe.sources +++ /dev/null @@ -1,56 +0,0 @@ -AssemblyInfo.cs -anonymous.cs -argument.cs -assign.cs -attribute.cs -cs-tokenizer.cs -cfold.cs -class.cs -codegen.cs -complete.cs -const.cs -constant.cs -convert.cs -context.cs -decl.cs -delegate.cs -doc.cs -doc-bootstrap.cs -driver.cs -dynamic.cs -ecore.cs -enum.cs -eval.cs -expression.cs -field.cs -flowanalysis.cs -generic.cs -import.cs -iterators.cs -lambda.cs -linq.cs -literal.cs -location.cs -membercache.cs -method.cs -modifiers.cs -namespace.cs -nullable.cs -parameter.cs -pending.cs -property.cs -report.cs -rootcontext.cs -roottypes.cs -statement.cs -support.cs -typemanager.cs -typespec.cs -visit.cs -symbolwriter.cs -../class/Mono.CompilerServices.SymbolWriter/MonoSymbolFile.cs -../class/Mono.CompilerServices.SymbolWriter/MonoSymbolTable.cs -../class/Mono.CompilerServices.SymbolWriter/MonoSymbolWriter.cs -../class/corlib/Mono.Security.Cryptography/CryptoConvert.cs -../build/common/Consts.cs -../tools/monop/outline.cs diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.sln b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.sln deleted file mode 100644 index 9977cd02f5..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.sln +++ /dev/null @@ -1,20 +0,0 @@ - -Microsoft Visual Studio Solution File, Format Version 10.00 -# Visual C# Express 2008 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "gmcs", "gmcs.csproj", "{D4A01C5B-A1B5-48F5-BB5B-D2E1BD236E56}" -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Any CPU = Debug|Any CPU - Release|Any CPU = Release|Any CPU - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {D4A01C5B-A1B5-48F5-BB5B-D2E1BD236E56}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {D4A01C5B-A1B5-48F5-BB5B-D2E1BD236E56}.Debug|Any CPU.Build.0 = Debug|Any CPU - {D4A01C5B-A1B5-48F5-BB5B-D2E1BD236E56}.Release|Any CPU.ActiveCfg = Release|Any CPU - {D4A01C5B-A1B5-48F5-BB5B-D2E1BD236E56}.Release|Any CPU.Build.0 = Release|Any CPU - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection -EndGlobal diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.userprefs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.userprefs deleted file mode 100644 index 1231ec7060..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs.userprefs +++ /dev/null @@ -1,23 +0,0 @@ - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs2.csproj b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs2.csproj deleted file mode 100644 index 26a8030e8d..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/gmcs2.csproj +++ /dev/null @@ -1,29 +0,0 @@ - - - - Exe - gmcs - v3.5 - gmcs.exe.sources - 65001 - ..\class\lib\basic\ - false - - - BOOTSTRAP_BASIC,NET_1_1,NET_2_0 - - - NET_1_1,NET_2_0 - - - - - - - - - - - - - \ No newline at end of file diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/hosting.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/hosting.cs deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/import.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/import.cs index 7a3081c7cb..541a407fa0 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/import.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/import.cs @@ -912,7 +912,7 @@ namespace Mono.CSharp // Test for a custom attribute type match. Custom attributes are not really predefined globaly // they can be assembly specific therefore we do check based on names only // - public bool HasAttribute (IList attributesData, string attrName, string attrNamespace) + public static bool HasAttribute (IList attributesData, string attrName, string attrNamespace) { if (attributesData.Count == 0) return false; @@ -1744,6 +1744,12 @@ namespace Mono.CSharp } } + bool ITypeDefinition.IsPartial { + get { + return false; + } + } + public override string Name { get { if (name == null) { @@ -1940,7 +1946,7 @@ namespace Mono.CSharp continue; // Ignore compiler generated methods - if (importer.HasAttribute (CustomAttributeData.GetCustomAttributes (mb), "CompilerGeneratedAttribute", MetadataImporter.CompilerServicesNamespace)) + if (MetadataImporter.HasAttribute (CustomAttributeData.GetCustomAttributes (mb), "CompilerGeneratedAttribute", MetadataImporter.CompilerServicesNamespace)) continue; } @@ -2068,6 +2074,12 @@ namespace Mono.CSharp } } + bool ITypeDefinition.IsPartial { + get { + return false; + } + } + public string Namespace { get { return null; diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/iterators.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/iterators.cs index 848caae65d..2586eada9d 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/iterators.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/iterators.cs @@ -11,12 +11,9 @@ // Copyright 2011 Xamarin Inc. // -// TODO: -// Flow analysis for Yield. -// - using System; using System.Collections.Generic; +using Mono.CompilerServices.SymbolWriter; #if STATIC using IKVM.Reflection.Emit; @@ -159,9 +156,10 @@ namespace Mono.CSharp Field pc_field; StateMachineMethod method; + int local_name_idx; - protected StateMachine (Block block, TypeContainer parent, MemberBase host, TypeParameters tparams, string name) - : base (block, parent, host, tparams, name) + protected StateMachine (ParametersBlock block, TypeDefinition parent, MemberBase host, TypeParameters tparams, string name, MemberKind kind) + : base (block, parent, host, tparams, name, kind) { } @@ -187,7 +185,7 @@ namespace Mono.CSharp throw new InternalErrorException (); this.method = method; - AddMethod (method); + Members.Add (method); } protected override bool DoDefineMembers () @@ -196,6 +194,14 @@ namespace Mono.CSharp return base.DoDefineMembers (); } + + protected override string GetVariableMangledName (LocalVariable local_info) + { + if (local_info.IsCompilerGenerated) + return base.GetVariableMangledName (local_info); + + return "<" + local_info.Name + ">__" + local_name_idx++.ToString ("X"); + } } class IteratorStorey : StateMachine @@ -289,10 +295,23 @@ namespace Mono.CSharp } } - public GetEnumeratorMethod (IteratorStorey host, FullNamedExpression returnType, MemberName name) + GetEnumeratorMethod (IteratorStorey host, FullNamedExpression returnType, MemberName name) : base (host, null, returnType, Modifiers.DEBUGGER_HIDDEN, name) { - Block.AddStatement (new GetEnumeratorStatement (host, this)); + } + + public static GetEnumeratorMethod Create (IteratorStorey host, FullNamedExpression returnType, MemberName name) + { + return Create (host, returnType, name, null); + } + + public static GetEnumeratorMethod Create (IteratorStorey host, FullNamedExpression returnType, MemberName name, Statement statement) + { + var m = new GetEnumeratorMethod (host, returnType, name); + var stmt = statement ?? new GetEnumeratorStatement (host, m); + m.block.AddStatement (stmt); + m.block.IsCompilerGenerated = true; + return m; } } @@ -329,9 +348,10 @@ namespace Mono.CSharp : base (host, null, new TypeExpression (host.Compiler.BuiltinTypes.Void, host.Location), Modifiers.PUBLIC | Modifiers.DEBUGGER_HIDDEN, new MemberName ("Dispose", host.Location)) { - host.AddMethod (this); + host.Members.Add (this); Block.AddStatement (new DisposeMethodStatement (host.Iterator)); + Block.IsCompilerGenerated = true; } } @@ -384,17 +404,13 @@ namespace Mono.CSharp TypeExpr iterator_type_expr; Field current_field; Field disposing_field; - int local_name_idx; - TypeExpr enumerator_type; - TypeExpr enumerable_type; - TypeArguments generic_args; - TypeExpr generic_enumerator_type; - TypeExpr generic_enumerable_type; + TypeSpec generic_enumerator_type; + TypeSpec generic_enumerable_type; public IteratorStorey (Iterator iterator) : base (iterator.Container.ParametersBlock, iterator.Host, - iterator.OriginalMethod as MemberBase, iterator.OriginalMethod.CurrentTypeParameters, "Iterator") + iterator.OriginalMethod as MemberBase, iterator.OriginalMethod.CurrentTypeParameters, "Iterator", MemberKind.Class) { this.Iterator = iterator; } @@ -422,33 +438,30 @@ namespace Mono.CSharp mtype = Mutator.Mutate (mtype); iterator_type_expr = new TypeExpression (mtype, Location); - generic_args = new TypeArguments (iterator_type_expr); - var list = new List (); + var ifaces = new List (5); if (Iterator.IsEnumerable) { - enumerable_type = new TypeExpression (Compiler.BuiltinTypes.IEnumerable, Location); - list.Add (enumerable_type); + ifaces.Add (Compiler.BuiltinTypes.IEnumerable); if (Module.PredefinedTypes.IEnumerableGeneric.Define ()) { - generic_enumerable_type = new GenericTypeExpr (Module.PredefinedTypes.IEnumerableGeneric.TypeSpec, generic_args, Location); - list.Add (generic_enumerable_type); + generic_enumerable_type = Module.PredefinedTypes.IEnumerableGeneric.TypeSpec.MakeGenericType (Module, new[] { mtype }); + ifaces.Add (generic_enumerable_type); } } - enumerator_type = new TypeExpression (Compiler.BuiltinTypes.IEnumerator, Location); - list.Add (enumerator_type); - - list.Add (new TypeExpression (Compiler.BuiltinTypes.IDisposable, Location)); + ifaces.Add (Compiler.BuiltinTypes.IEnumerator); + ifaces.Add (Compiler.BuiltinTypes.IDisposable); var ienumerator_generic = Module.PredefinedTypes.IEnumeratorGeneric; if (ienumerator_generic.Define ()) { - generic_enumerator_type = new GenericTypeExpr (ienumerator_generic.TypeSpec, generic_args, Location); - list.Add (generic_enumerator_type); + generic_enumerator_type = ienumerator_generic.TypeSpec.MakeGenericType (Module, new [] { mtype }); + ifaces.Add (generic_enumerator_type); } - type_bases = list; + base_class = null; - return base.ResolveBaseTypes (out base_class); + base_type = Compiler.BuiltinTypes.Object; + return ifaces.ToArray (); } protected override bool DoDefineMembers () @@ -479,25 +492,23 @@ namespace Mono.CSharp if (Iterator.IsEnumerable) { FullNamedExpression explicit_iface = new TypeExpression (Compiler.BuiltinTypes.IEnumerable, Location); - var name = new MemberName ("GetEnumerator", null, explicit_iface, Location); + var name = new MemberName ("GetEnumerator", null, explicit_iface, Location.Null); if (generic_enumerator_type != null) { - Method get_enumerator = new StateMachineMethod (this, null, enumerator_type, 0, name); - - explicit_iface = new GenericTypeExpr (Module.PredefinedTypes.IEnumerableGeneric.Resolve (), generic_args, Location); - name = new MemberName ("GetEnumerator", null, explicit_iface, Location); - Method gget_enumerator = new GetEnumeratorMethod (this, generic_enumerator_type, name); + explicit_iface = new TypeExpression (generic_enumerable_type, Location); + var gname = new MemberName ("GetEnumerator", null, explicit_iface, Location.Null); + Method gget_enumerator = GetEnumeratorMethod.Create (this, new TypeExpression (generic_enumerator_type, Location), gname); // // Just call generic GetEnumerator implementation // - get_enumerator.Block.AddStatement ( - new Return (new Invocation (new DynamicMethodGroupExpr (gget_enumerator, Location), null), Location)); + var stmt = new Return (new Invocation (new DynamicMethodGroupExpr (gget_enumerator, Location), null), Location); + Method get_enumerator = GetEnumeratorMethod.Create (this, new TypeExpression (Compiler.BuiltinTypes.IEnumerator, Location), name, stmt); - AddMethod (get_enumerator); - AddMethod (gget_enumerator); + Members.Add (get_enumerator); + Members.Add (gget_enumerator); } else { - AddMethod (new GetEnumeratorMethod (this, enumerator_type, name)); + Members.Add (GetEnumeratorMethod.Create (this, new TypeExpression (Compiler.BuiltinTypes.IEnumerator, Location), name)); } } @@ -510,7 +521,7 @@ namespace Mono.CSharp FullNamedExpression explicit_iface; if (is_generic) { - explicit_iface = new GenericTypeExpr (Module.PredefinedTypes.IEnumeratorGeneric.Resolve (), generic_args, Location); + explicit_iface = new TypeExpression (generic_enumerator_type, Location); type = iterator_type_expr; } else { explicit_iface = new TypeExpression (Module.Compiler.BuiltinTypes.IEnumerator, Location); @@ -519,26 +530,30 @@ namespace Mono.CSharp var name = new MemberName ("Current", null, explicit_iface, Location); - ToplevelBlock get_block = new ToplevelBlock (Compiler, Location); + ToplevelBlock get_block = new ToplevelBlock (Compiler, Location) { + IsCompilerGenerated = true + }; get_block.AddStatement (new Return (new DynamicFieldExpr (CurrentField, Location), Location)); - Property current = new Property (this, type, Modifiers.DEBUGGER_HIDDEN, name, null); - current.Get = new Property.GetMethod (current, 0, null, Location); + Property current = new Property (this, type, Modifiers.DEBUGGER_HIDDEN | Modifiers.COMPILER_GENERATED, name, null); + current.Get = new Property.GetMethod (current, Modifiers.COMPILER_GENERATED, null, Location); current.Get.Block = get_block; - AddProperty (current); + Members.Add (current); } void Define_Reset () { Method reset = new Method ( this, new TypeExpression (Compiler.BuiltinTypes.Void, Location), - Modifiers.PUBLIC | Modifiers.DEBUGGER_HIDDEN, + Modifiers.PUBLIC | Modifiers.DEBUGGER_HIDDEN | Modifiers.COMPILER_GENERATED, new MemberName ("Reset", Location), ParametersCompiled.EmptyReadOnlyParameters, null); - AddMethod (reset); + Members.Add (reset); - reset.Block = new ToplevelBlock (Compiler, Location); + reset.Block = new ToplevelBlock (Compiler, Location) { + IsCompilerGenerated = true + }; TypeSpec ex_type = Module.PredefinedTypes.NotSupportedException.Resolve (); if (ex_type == null) @@ -547,16 +562,11 @@ namespace Mono.CSharp reset.Block.AddStatement (new Throw (new New (new TypeExpression (ex_type, Location), null, Location), Location)); } - protected override void EmitHoistedParameters (EmitContext ec, IList hoisted) + protected override void EmitHoistedParameters (EmitContext ec, List hoisted) { base.EmitHoistedParameters (ec, hoisted); base.EmitHoistedParameters (ec, hoisted_params_copy); } - - protected override string GetVariableMangledName (LocalVariable local_info) - { - return "<" + local_info.Name + ">__" + local_name_idx++.ToString ("X"); - } } public class StateMachineMethod : Method @@ -568,12 +578,12 @@ namespace Mono.CSharp name, ParametersCompiled.EmptyReadOnlyParameters, null) { this.expr = expr; - Block = new ToplevelBlock (host.Compiler, ParametersCompiled.EmptyReadOnlyParameters, Location); + Block = new ToplevelBlock (host.Compiler, ParametersCompiled.EmptyReadOnlyParameters, Location.Null); } - public override EmitContext CreateEmitContext (ILGenerator ig) + public override EmitContext CreateEmitContext (ILGenerator ig, SourceMethodBuilder sourceMethod) { - EmitContext ec = new EmitContext (this, ig, MemberType); + EmitContext ec = new EmitContext (this, ig, MemberType, sourceMethod); ec.CurrentAnonymousMethod = expr; if (expr is AsyncInitializer) @@ -609,9 +619,15 @@ namespace Mono.CSharp { state_machine.EmitMoveNext (ec); } + + public override void Emit (EmitContext ec) + { + // Don't create sequence point + DoEmit (ec); + } } - public readonly TypeContainer Host; + public readonly TypeDefinition Host; protected StateMachine storey; // @@ -624,7 +640,7 @@ namespace Mono.CSharp protected LocalBuilder current_pc; protected List resume_points; - protected StateMachineInitializer (ParametersBlock block, TypeContainer host, TypeSpec returnType) + protected StateMachineInitializer (ParametersBlock block, TypeDefinition host, TypeSpec returnType) : base (block, returnType, block.StartLocation) { this.Host = host; @@ -682,8 +698,6 @@ namespace Mono.CSharp protected override Expression DoResolve (ResolveContext ec) { - storey = (StateMachine) block.Parent.ParametersBlock.AnonymousMethodStorey; - var ctx = CreateBlockContext (ec); Block.Resolve (ctx); @@ -710,12 +724,12 @@ namespace Mono.CSharp public override void Emit (EmitContext ec) { // - // Load Iterator storey instance + // Load state machine instance // storey.Instance.Emit (ec); } - void EmitMoveNext_NoResumePoints (EmitContext ec, Block original_block) + void EmitMoveNext_NoResumePoints (EmitContext ec) { ec.EmitThis (); ec.Emit (OpCodes.Ldfld, storey.PC.Spec); @@ -729,9 +743,7 @@ namespace Mono.CSharp iterator_body_end = ec.DefineLabel (); - SymbolWriter.StartIteratorBody (ec); - original_block.Emit (ec); - SymbolWriter.EndIteratorBody (ec); + block.EmitEmbedded (ec); ec.MarkLabel (iterator_body_end); @@ -751,7 +763,7 @@ namespace Mono.CSharp move_next_error = ec.DefineLabel (); if (resume_points == null) { - EmitMoveNext_NoResumePoints (ec, block); + EmitMoveNext_NoResumePoints (ec); return; } @@ -785,22 +797,16 @@ namespace Mono.CSharp if (async_init != null) ec.BeginExceptionBlock (); - SymbolWriter.StartIteratorDispatcher (ec); ec.Emit (OpCodes.Ldloc, current_pc); ec.Emit (OpCodes.Switch, labels); ec.Emit (async_init != null ? OpCodes.Leave : OpCodes.Br, move_next_error); - SymbolWriter.EndIteratorDispatcher (ec); ec.MarkLabel (labels[0]); iterator_body_end = ec.DefineLabel (); - SymbolWriter.StartIteratorBody (ec); - block.Emit (ec); - SymbolWriter.EndIteratorBody (ec); - - SymbolWriter.StartIteratorDispatcher (ec); + block.EmitEmbedded (ec); ec.MarkLabel (iterator_body_end); @@ -820,6 +826,7 @@ namespace Mono.CSharp ec.EndExceptionBlock (); } + ec.Mark (Block.Original.EndLocation); ec.EmitThis (); ec.EmitInt ((int) IteratorStorey.State.After); ec.Emit (OpCodes.Stfld, storey.PC.Spec); @@ -839,8 +846,6 @@ namespace Mono.CSharp ec.EmitInt (1); ec.Emit (OpCodes.Ret); } - - SymbolWriter.EndIteratorDispatcher (ec); } protected virtual void EmitMoveNextEpilogue (EmitContext ec) @@ -886,18 +891,53 @@ namespace Mono.CSharp ec.Emit (OpCodes.Stloc, skip_finally); } } + + public void SetStateMachine (StateMachine stateMachine) + { + this.storey = stateMachine; + } } // - // Iterators are implemented as hidden anonymous block + // Iterators are implemented as state machine blocks // public class Iterator : StateMachineInitializer { + sealed class TryFinallyBlockProxyStatement : Statement + { + TryFinallyBlock block; + Iterator iterator; + + public TryFinallyBlockProxyStatement (Iterator iterator, TryFinallyBlock block) + { + this.iterator = iterator; + this.block = block; + } + + protected override void CloneTo (CloneContext clonectx, Statement target) + { + throw new NotSupportedException (); + } + + protected override void DoEmit (EmitContext ec) + { + // + // Restore redirection for any captured variables + // + ec.CurrentAnonymousMethod = iterator; + + using (ec.With (BuilderContext.Options.OmitDebugInfo, !ec.HasMethodSymbolBuilder)) { + block.EmitFinallyBody (ec); + } + } + } + public readonly IMethodData OriginalMethod; public readonly bool IsEnumerable; public readonly TypeSpec OriginalIteratorType; + int finally_hosts_counter; - public Iterator (ParametersBlock block, IMethodData method, TypeContainer host, TypeSpec iterator_type, bool is_enumerable) + public Iterator (ParametersBlock block, IMethodData method, TypeDefinition host, TypeSpec iterator_type, bool is_enumerable) : base (block, host, host.Compiler.BuiltinTypes.Bool) { this.OriginalMethod = method; @@ -906,7 +946,9 @@ namespace Mono.CSharp this.type = method.ReturnType; } - public Block Container { + #region Properties + + public ToplevelBlock Container { get { return OriginalMethod.Block; } } @@ -918,6 +960,22 @@ namespace Mono.CSharp get { return true; } } + #endregion + + public Method CreateFinallyHost (TryFinallyBlock block) + { + var method = new Method (storey, new TypeExpression (storey.Compiler.BuiltinTypes.Void, loc), + Modifiers.COMPILER_GENERATED, new MemberName (CompilerGeneratedContainer.MakeName (null, null, "Finally", finally_hosts_counter++), loc), + ParametersCompiled.EmptyReadOnlyParameters, null); + + method.Block = new ToplevelBlock (method.Compiler, method.ParameterInfo, loc); + method.Block.IsCompilerGenerated = true; + method.Block.AddStatement (new TryFinallyBlockProxyStatement (this, block)); + + storey.AddMember (method); + return method; + } + public void EmitYieldBreak (EmitContext ec, bool unwind_protect) { ec.Emit (unwind_protect ? OpCodes.Leave : OpCodes.Br, move_next_error); @@ -953,11 +1011,13 @@ namespace Mono.CSharp public void EmitDispose (EmitContext ec) { + if (resume_points == null) + return; + Label end = ec.DefineLabel (); Label[] labels = null; - int n_resume_points = resume_points == null ? 0 : resume_points.Count; - for (int i = 0; i < n_resume_points; ++i) { + for (int i = 0; i < resume_points.Count; ++i) { ResumableStatement s = resume_points[i]; Label ret = s.PrepareForDispose (ec, end); if (ret.Equals (end) && labels == null) @@ -1025,7 +1085,7 @@ namespace Mono.CSharp return bc; } - public static void CreateIterator (IMethodData method, TypeContainer parent, Modifiers modifiers) + public static void CreateIterator (IMethodData method, TypeDefinition parent, Modifiers modifiers) { bool is_enumerable; TypeSpec iterator_type; @@ -1047,7 +1107,7 @@ namespace Mono.CSharp for (int i = 0; i < parameters.Count; i++) { Parameter p = parameters [i]; Parameter.Modifier mod = p.ModFlags; - if ((mod & Parameter.Modifier.ISBYREF) != 0) { + if ((mod & Parameter.Modifier.RefOutMask) != 0) { parent.Compiler.Report.Error (1623, p.Location, "Iterators cannot have ref or out parameters"); return; @@ -1070,7 +1130,7 @@ namespace Mono.CSharp parent.Compiler.Report.Error (1629, method.Location, "Unsafe code may not appear in iterators"); } - method.Block.WrapIntoIterator (method, parent, iterator_type, is_enumerable); + method.Block = method.Block.ConvertToIterator (method, parent, iterator_type, is_enumerable); } static bool CheckType (TypeSpec ret, TypeContainer parent, out TypeSpec original_iterator_type, out bool is_enumerable) diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/lambda.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/lambda.cs index f1cc07b195..d972450fc7 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/lambda.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/lambda.cs @@ -81,7 +81,7 @@ namespace Mono.CSharp { TypeSpec [] ptypes = new TypeSpec [Parameters.Count]; for (int i = 0; i < d_params.Count; i++) { // D has no ref or out parameters - if ((d_params.FixedParameters [i].ModFlags & Parameter.Modifier.ISBYREF) != 0) + if ((d_params.FixedParameters[i].ModFlags & Parameter.Modifier.RefOutMask) != 0) return null; TypeSpec d_param = d_params.Types [i]; @@ -191,7 +191,7 @@ namespace Mono.CSharp { return Expr.CreateExpressionTree (ec); } - public override void Emit (EmitContext ec) + protected override void DoEmit (EmitContext ec) { if (statement != null) { statement.EmitStatement (ec); @@ -203,7 +203,7 @@ namespace Mono.CSharp { return; } - base.Emit (ec); + base.DoEmit (ec); } protected override bool DoResolve (BlockContext ec) diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/lambda.todo b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/lambda.todo deleted file mode 100644 index e3a8a184cd..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/lambda.todo +++ /dev/null @@ -1,24 +0,0 @@ -Tasks for completing Lambda support: - -* Port the grammar to mcs - -* Everywhere where we use Arguments, we need to clone them. - -* We need a "CloneContext" that would keep track of mappings between -the old blocks and the new blocks, so that expression that keep -pointers to blocks can get the proper block on cloning, something like: - - CloneTo (CloneContext cc, Expression t) - { - MyClass target = (MyClass) t; - target.Block = cc.RemapBlock (Block); - } - -* Generics section support. - -* Fix the bug in the modified l1.cs that introduces two rets instead - of a single one. - -* Complete CloneTo for Statements. - -* Write an extensive test suite to exercise CloneTo \ No newline at end of file diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/linq.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/linq.cs index 60310f02c4..1c93d6046f 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/linq.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/linq.cs @@ -90,6 +90,13 @@ namespace Mono.CSharp.Linq return rmg; } + protected override Expression DoResolveDynamic (ResolveContext ec, Expression memberExpr) + { + ec.Report.Error (1979, loc, + "Query expressions with a source or join sequence of type `dynamic' are not allowed"); + return null; + } + #region IErrorHandler Members bool OverloadResolver.IErrorHandler.AmbiguousCandidates (ResolveContext ec, MemberSpec best, MemberSpec ambiguous) @@ -422,19 +429,6 @@ namespace Mono.CSharp.Linq public override Expression BuildQueryClause (ResolveContext ec, Expression lSide, Parameter parameter) { -/* - expr = expr.Resolve (ec); - if (expr == null) - return null; - - if (expr.Type == InternalType.Dynamic || expr.Type == TypeManager.void_type) { - ec.Report.Error (1979, expr.Location, - "Query expression with a source or join sequence of type `{0}' is not allowed", - TypeManager.CSharpName (expr.Type)); - return null; - } -*/ - if (IdentifierType != null) expr = CreateCastExpression (expr); @@ -850,7 +844,7 @@ namespace Mono.CSharp.Linq public void AddRangeVariable (RangeVariable variable) { variable.Block = this; - AddLocalName (variable.Name, variable); + TopBlock.AddLocalName (variable.Name, variable, true); } public override void Error_AlreadyDeclared (string name, INamedBlockVariable variable, string reason) diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/literal.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/literal.cs index bb0370914b..bdbd57a4f7 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/literal.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/literal.cs @@ -50,7 +50,7 @@ namespace Mono.CSharp { } - public override void Error_ValueCannotBeConverted (ResolveContext ec, Location loc, TypeSpec t, bool expl) + public override void Error_ValueCannotBeConverted (ResolveContext ec, TypeSpec t, bool expl) { if (t.IsGenericParameter) { ec.Report.Error(403, loc, @@ -65,7 +65,7 @@ namespace Mono.CSharp return; } - base.Error_ValueCannotBeConverted (ec, loc, t, expl); + base.Error_ValueCannotBeConverted (ec, t, expl); } public override string GetValueAsLiteral () @@ -253,7 +253,7 @@ namespace Mono.CSharp { } - public override void Error_ValueCannotBeConverted (ResolveContext ec, Location loc, TypeSpec target, bool expl) + public override void Error_ValueCannotBeConverted (ResolveContext ec, TypeSpec target, bool expl) { if (target.BuiltinType == BuiltinTypeSpec.Type.Float) { Error_664 (ec, loc, "float", "f"); @@ -265,7 +265,7 @@ namespace Mono.CSharp return; } - base.Error_ValueCannotBeConverted (ec, loc, target, expl); + base.Error_ValueCannotBeConverted (ec, target, expl); } static void Error_664 (ResolveContext ec, Location loc, string type, string suffix) diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/location.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/location.cs index 231aeae5e2..337c378e55 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/location.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/location.cs @@ -11,22 +11,47 @@ // using System; -using System.IO; using System.Collections.Generic; using Mono.CompilerServices.SymbolWriter; using System.Diagnostics; using System.Linq; -namespace Mono.CSharp { - /// - /// This is one single source file. - /// - /// - /// This is intentionally a class and not a struct since we need - /// to pass this by reference. - /// - public class SourceFile : ISourceFile, IEquatable +namespace Mono.CSharp +{ + // + // This is one single source file. + // + public class SourceFile : IEquatable { + // + // Used by #line directive to track hidden sequence point + // regions + // + struct LocationRegion : IComparable + { + public readonly Location Start; + public readonly Location End; + + public LocationRegion (Location start, Location end) + { + this.Start = start; + this.End = end; + } + + public int CompareTo (LocationRegion other) + { + if (Start.Row == other.Start.Row) + return Start.Column.CompareTo (other.Start.Column); + + return Start.Row.CompareTo (other.Start.Row); + } + + public override string ToString () + { + return Start.ToString () + " - " + End.ToString (); + } + } + public readonly string Name; public readonly string FullPathName; public readonly int Index; @@ -34,6 +59,7 @@ namespace Mono.CSharp { SourceFileEntry file; byte[] guid, checksum; + List hidden_lines; public SourceFile (string name, string path, int index) { @@ -43,11 +69,9 @@ namespace Mono.CSharp { } public SourceFileEntry SourceFileEntry { - get { return file; } - } - - SourceFileEntry ISourceFile.Entry { - get { return file; } + get { + return file; + } } public void SetChecksum (byte[] guid, byte[] checksum) @@ -56,15 +80,20 @@ namespace Mono.CSharp { this.checksum = checksum; } - public virtual void DefineSymbolInfo (MonoSymbolWriter symwriter) + public SourceFileEntry CreateSymbolInfo (MonoSymbolFile symwriter) { - if (guid != null) - file = symwriter.DefineDocument (FullPathName, guid, checksum); - else { - file = symwriter.DefineDocument (FullPathName); + if (hidden_lines != null) + hidden_lines.Sort (); + + if (guid != null) { + file = new SourceFileEntry (symwriter, FullPathName, guid, checksum); + } else { + file = new SourceFileEntry (symwriter, FullPathName); if (AutoGenerated) file.SetAutoGenerated (); } + + return file; } public bool Equals (SourceFile other) @@ -72,97 +101,33 @@ namespace Mono.CSharp { return FullPathName == other.FullPathName; } - public override string ToString () + public bool IsHiddenLocation (Location loc) { - return String.Format ("SourceFile ({0}:{1}:{2}:{3})", - Name, FullPathName, Index, SourceFileEntry); - } - } + if (hidden_lines == null) + return false; - public class CompilationSourceFile : SourceFile, ICompileUnit - { - CompileUnitEntry comp_unit; - Dictionary include_files; - Dictionary conditionals; - NamespaceContainer ns_container; - - public CompilationSourceFile (string name, string fullPathName, int index) - : base (name, fullPathName, index) - { - } - - CompileUnitEntry ICompileUnit.Entry { - get { return comp_unit; } - } - - public CompileUnitEntry CompileUnitEntry { - get { return comp_unit; } - } - - public NamespaceContainer NamespaceContainer { - get { - return ns_container; - } - set { - ns_container = value; + int index = hidden_lines.BinarySearch (new LocationRegion (loc, loc)); + index = ~index; + if (index > 0) { + var found = hidden_lines[index - 1]; + if (loc.Row < found.End.Row) + return true; } - } - - public void AddIncludeFile (SourceFile file) - { - if (file == this) - return; - - if (include_files == null) - include_files = new Dictionary (); - if (!include_files.ContainsKey (file.FullPathName)) - include_files.Add (file.FullPathName, file); + return false; } - public void AddDefine (string value) + public void RegisterHiddenScope (Location start, Location end) { - if (conditionals == null) - conditionals = new Dictionary (2); + if (hidden_lines == null) + hidden_lines = new List (); - conditionals [value] = true; + hidden_lines.Add (new LocationRegion (start, end)); } - public void AddUndefine (string value) - { - if (conditionals == null) - conditionals = new Dictionary (2); - - conditionals [value] = false; - } - - public override void DefineSymbolInfo (MonoSymbolWriter symwriter) - { - base.DefineSymbolInfo (symwriter); - - comp_unit = symwriter.DefineCompilationUnit (SourceFileEntry); - - if (include_files != null) { - foreach (SourceFile include in include_files.Values) { - include.DefineSymbolInfo (symwriter); - comp_unit.AddFile (include.SourceFileEntry); - } - } - } - - public bool IsConditionalDefined (CompilerContext ctx, string value) + public override string ToString () { - if (conditionals != null) { - bool res; - if (conditionals.TryGetValue (value, out res)) - return res; - - // When conditional was undefined - if (conditionals.ContainsKey (value)) - return false; - } - - return ctx.Settings.IsConditionalSymbolDefined (value); + return String.Format ("SourceFile ({0}:{1}:{2})", Name, FullPathName, Index); } } @@ -186,41 +151,37 @@ namespace Mono.CSharp { { struct Checkpoint { public readonly int LineOffset; - public readonly int CompilationUnit; public readonly int File; - public Checkpoint (int compile_unit, int file, int line) + public Checkpoint (int file, int line) { File = file; - CompilationUnit = compile_unit; LineOffset = line - (int) (line % (1 << line_delta_bits)); } } #if FULL_AST - long token; + readonly long token; const int column_bits = 24; const int line_delta_bits = 24; #else - int token; + readonly int token; const int column_bits = 8; const int line_delta_bits = 8; #endif const int checkpoint_bits = 16; - // -2 because the last one is used for hidden - const int max_column = (1 << column_bits) - 2; const int column_mask = (1 << column_bits) - 1; + const int max_column = column_mask; static List source_list; static int current_source; - static int current_compile_unit; static Checkpoint [] checkpoints; static int checkpoint_index; - public readonly static Location Null = new Location (-1); + public readonly static Location Null = new Location (); public static bool InEmacs; static Location () @@ -232,15 +193,12 @@ namespace Mono.CSharp { { source_list = new List (); current_source = 0; - current_compile_unit = 0; checkpoint_index = 0; } - public static SourceFile AddFile (string name, string fullName) + public static void AddFile (SourceFile file) { - var source = new SourceFile (name, fullName, source_list.Count + 1); - source_list.Add (source); - return source; + source_list.Add (file); } // @@ -249,31 +207,25 @@ namespace Mono.CSharp { // source file. We reserve some extra space for files we encounter via #line // directives while parsing. // - static public void Initialize (List files) + static public void Initialize (List files) { -#if NET_4_0 +#if NET_4_0 || MONODROID source_list.AddRange (files); #else source_list.AddRange (files.ToArray ()); #endif - checkpoints = new Checkpoint [source_list.Count * 2]; + checkpoints = new Checkpoint [System.Math.Max (1, source_list.Count * 2)]; if (checkpoints.Length > 0) - checkpoints [0] = new Checkpoint (0, 0, 0); + checkpoints [0] = new Checkpoint (0, 0); } - static public void Push (CompilationSourceFile compile_unit, SourceFile file) + static public void Push (SourceFile file) { current_source = file != null ? file.Index : -1; - current_compile_unit = compile_unit != null ? compile_unit.Index : -1; // File is always pushed before being changed. } - public Location (int row) - : this (row, 0) - { - } - public Location (int row, int column) { if (row <= 0) @@ -281,8 +233,6 @@ namespace Mono.CSharp { else { if (column > max_column) column = max_column; - else if (column < 0) - column = max_column + 1; long target = -1; long delta = 0; @@ -301,7 +251,7 @@ namespace Mono.CSharp { } } if (target == -1) { - AddCheckpoint (current_compile_unit, current_source, row); + AddCheckpoint (current_source, row); target = checkpoint_index; delta = row % (1 << line_delta_bits); } @@ -322,12 +272,12 @@ namespace Mono.CSharp { return new Location (loc.Row, loc.Column - columns); } - static void AddCheckpoint (int compile_unit, int file, int row) + static void AddCheckpoint (int file, int row) { if (checkpoints.Length == ++checkpoint_index) { Array.Resize (ref checkpoints, checkpoint_index * 2); } - checkpoints [checkpoint_index] = new Checkpoint (compile_unit, file, row); + checkpoints [checkpoint_index] = new Checkpoint (file, row); } string FormatLocation (string fileName) @@ -359,10 +309,9 @@ namespace Mono.CSharp { public string Name { get { int index = File; - if (token == 0 || index == 0) - return "Internal"; - if (source_list == null || index - 1 >= source_list.Count) - return "unknown_file"; + + if (token == 0 || index <= 0) + return null; SourceFile file = source_list [index - 1]; return file.Name; @@ -372,8 +321,8 @@ namespace Mono.CSharp { public string NameFullPath { get { int index = File; - if (token == 0 || index == 0) - return "Internal"; + if (token == 0 || index <= 0) + return null; return source_list[index - 1].FullPathName; } @@ -402,23 +351,7 @@ namespace Mono.CSharp { get { if (token == 0) return 1; - int col = (int) (token & column_mask); - return col > max_column ? 1 : col; - } - } - - public bool Hidden { - get { - return (int) (token & column_mask) == max_column + 1; - } - } - - public int CompilationUnitIndex { - get { - if (token == 0) - return 0; -if (checkpoints.Length <= CheckpointIndex) throw new Exception (String.Format ("Should not happen. Token is {0:X04}, checkpoints are {1}, index is {2}", token, checkpoints.Length, CheckpointIndex)); - return checkpoints [CheckpointIndex].CompilationUnit; + return (int) (token & column_mask); } } @@ -448,16 +381,7 @@ if (checkpoints.Length <= CheckpointIndex) throw new Exception (String.Format (" int index = File; if (index == 0) return null; - return (SourceFile) source_list [index - 1]; - } - } - - public CompilationSourceFile CompilationUnit { - get { - int index = CompilationUnitIndex; - if (index == 0) - return null; - return (CompilationSourceFile) source_list [index - 1]; + return source_list [index - 1]; } } @@ -765,173 +689,4 @@ if (checkpoints.Length <= CheckpointIndex) throw new Exception (String.Format (" return found; } } - - public class UsingsBag - { - public class Namespace { - public Location NamespaceLocation { get; set; } - public MemberName Name { get; set; } - - public Location OpenBrace { get; set; } - public Location CloseBrace { get; set; } - public Location OptSemicolon { get; set; } - - public List usings = new List (); - public List members = new List (); - - public Namespace () - { - // in case of missing close brace, set it to the highest value. - CloseBrace = new Location (int.MaxValue, int.MaxValue); - } - - public virtual void Accept (StructuralVisitor visitor) - { - visitor.Visit (this); - } - } - - public class AliasUsing - { - public readonly Location UsingLocation; - public readonly Tokenizer.LocatedToken Identifier; - public readonly Location AssignLocation; - public readonly ATypeNameExpression Nspace; - public readonly Location SemicolonLocation; - - public AliasUsing (Location usingLocation, Tokenizer.LocatedToken identifier, Location assignLocation, ATypeNameExpression nspace, Location semicolonLocation) - { - this.UsingLocation = usingLocation; - this.Identifier = identifier; - this.AssignLocation = assignLocation; - this.Nspace = nspace; - this.SemicolonLocation = semicolonLocation; - } - - public virtual void Accept (StructuralVisitor visitor) - { - visitor.Visit (this); - } - } - - public class Using - { - public readonly Location UsingLocation; - public readonly ATypeNameExpression NSpace; - public readonly Location SemicolonLocation; - - public Using (Location usingLocation, ATypeNameExpression nSpace, Location semicolonLocation) - { - this.UsingLocation = usingLocation; - this.NSpace = nSpace; - this.SemicolonLocation = semicolonLocation; - } - - public virtual void Accept (StructuralVisitor visitor) - { - visitor.Visit (this); - } - } - - public class ExternAlias - { - public readonly Location ExternLocation; - public readonly Location AliasLocation; - public readonly Tokenizer.LocatedToken Identifier; - public readonly Location SemicolonLocation; - - public ExternAlias (Location externLocation, Location aliasLocation, Tokenizer.LocatedToken identifier, Location semicolonLocation) - { - this.ExternLocation = externLocation; - this.AliasLocation = aliasLocation; - this.Identifier = identifier; - this.SemicolonLocation = semicolonLocation; - } - - public virtual void Accept (StructuralVisitor visitor) - { - visitor.Visit (this); - } - } - - public Namespace Global { - get; - set; - } - Stack curNamespace = new Stack (); - - public UsingsBag () - { - Global = new Namespace (); - Global.OpenBrace = new Location (1, 1); - Global.CloseBrace = new Location (int.MaxValue, int.MaxValue); - curNamespace.Push (Global); - } - - [Conditional ("FULL_AST")] - public void AddUsingAlias (Location usingLocation, Tokenizer.LocatedToken identifier, Location assignLocation, ATypeNameExpression nspace, Location semicolonLocation) - { - curNamespace.Peek ().usings.Add (new AliasUsing (usingLocation, identifier, assignLocation, nspace, semicolonLocation)); - } - - [Conditional ("FULL_AST")] - public void AddUsing (Location usingLocation, ATypeNameExpression nspace, Location semicolonLocation) - { - curNamespace.Peek ().usings.Add (new Using (usingLocation, nspace, semicolonLocation)); - } - - [Conditional ("FULL_AST")] - public void AddExternAlias (Location externLocation, Location aliasLocation, Tokenizer.LocatedToken identifier, Location semicolonLocation) - { - curNamespace.Peek ().usings.Add (new ExternAlias (externLocation, aliasLocation, identifier, semicolonLocation)); - } - - [Conditional ("FULL_AST")] - public void DeclareNamespace (Location namespaceLocation, MemberName nspace) - { - var newNamespace = new Namespace () { NamespaceLocation = namespaceLocation, Name = nspace }; - curNamespace.Peek ().members.Add (newNamespace); - curNamespace.Push (newNamespace); - } - - int typeLevel = 0; - [Conditional ("FULL_AST")] - public void PushTypeDeclaration (object type) - { - if (typeLevel == 0) - curNamespace.Peek ().members.Add (type); - typeLevel++; - } - - [Conditional ("FULL_AST")] - public void PopTypeDeclaration () - { - typeLevel--; - } - - [Conditional ("FULL_AST")] - public void EndNamespace (Location optSemicolon) - { - curNamespace.Peek ().OptSemicolon = optSemicolon; - curNamespace.Pop (); - } - - [Conditional ("FULL_AST")] - public void EndNamespace () - { - curNamespace.Pop (); - } - - [Conditional ("FULL_AST")] - public void OpenNamespace (Location bracketLocation) - { - curNamespace.Peek ().OpenBrace = bracketLocation; - } - - [Conditional ("FULL_AST")] - public void CloseNamespace (Location bracketLocation) - { - curNamespace.Peek ().CloseBrace = bracketLocation; - } - } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/membercache.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/membercache.cs index 6a497cc514..5374da9db9 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/membercache.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/membercache.cs @@ -41,6 +41,7 @@ namespace Mono.CSharp { InternalCompilerType = 1 << 21, MissingType = 1 << 22, Void = 1 << 23, + Namespace = 1 << 24, NestedMask = Class | Struct | Delegate | Enum | Interface, GenericMask = Method | Class | Struct | Delegate | Interface, @@ -72,15 +73,6 @@ namespace Mono.CSharp { public readonly TypeSpec MemberType; public readonly int Arity; // -1 to ignore the check - private MemberFilter (string name, MemberKind kind) - { - Name = name; - Kind = kind; - Parameters = null; - MemberType = null; - Arity = -1; - } - public MemberFilter (MethodSpec m) { Name = m.Name; @@ -303,24 +295,28 @@ namespace Mono.CSharp { { if (member.Kind == MemberKind.Operator) { var dt = member.DeclaringType; - switch (dt.BuiltinType) { - case BuiltinTypeSpec.Type.String: - case BuiltinTypeSpec.Type.Delegate: - case BuiltinTypeSpec.Type.MulticastDelegate: - // Some core types have user operators but they cannot be used as normal - // user operators as they are predefined and therefore having different - // rules (e.g. binary operators) by not setting the flag we hide them for - // user conversions - // TODO: Should I do this for all core types ? - break; - default: - if (name == Operator.GetMetadataName (Operator.OpType.Implicit) || name == Operator.GetMetadataName (Operator.OpType.Explicit)) { - state |= StateFlags.HasConversionOperator; - } else { - state |= StateFlags.HasUserOperator; - } - break; + // + // Some core types have user operators but they cannot be used like normal + // user operators as they are predefined and therefore having different + // rules (e.g. binary operators) by not setting the flag we hide them for + // user conversions + // + if (!BuiltinTypeSpec.IsPrimitiveType (dt)) { + switch (dt.BuiltinType) { + case BuiltinTypeSpec.Type.String: + case BuiltinTypeSpec.Type.Delegate: + case BuiltinTypeSpec.Type.MulticastDelegate: + break; + default: + if (name == Operator.GetMetadataName (Operator.OpType.Implicit) || name == Operator.GetMetadataName (Operator.OpType.Explicit)) { + state |= StateFlags.HasConversionOperator; + } else { + state |= StateFlags.HasUserOperator; + } + + break; + } } } @@ -468,7 +464,7 @@ namespace Mono.CSharp { // based on type definition var tc = container.MemberDefinition as TypeContainer; if (tc != null) - tc.DefineType (); + tc.DefineContainer (); if (container.MemberCacheTypes.member_hash.TryGetValue (name, out applicable)) { for (int i = applicable.Count - 1; i >= 0; i--) { @@ -792,7 +788,7 @@ namespace Mono.CSharp { while (true) { foreach (var entry in abstract_type.MemberCache.member_hash) { foreach (var name_entry in entry.Value) { - if ((name_entry.Modifiers & Modifiers.ABSTRACT) == 0) + if ((name_entry.Modifiers & (Modifiers.ABSTRACT | Modifiers.OVERRIDE)) != Modifiers.ABSTRACT) continue; if (name_entry.Kind != MemberKind.Method) @@ -841,6 +837,12 @@ namespace Mono.CSharp { if ((item.Modifiers & (Modifiers.OVERRIDE | Modifiers.VIRTUAL)) == 0) continue; + // + // Abstract override does not override anything + // + if ((item.Modifiers & Modifiers.ABSTRACT) != 0) + continue; + if (filter.Equals (item)) { --not_implemented_count; abstract_methods [i] = null; @@ -889,7 +891,7 @@ namespace Mono.CSharp { return IndexerNameAlias; if (mc is Constructor) - return Constructor.ConstructorName; + return mc.IsStatic ? Constructor.TypeConstructorName : Constructor.ConstructorName; return mc.MemberName.Name; } @@ -1158,8 +1160,9 @@ namespace Mono.CSharp { if (container.BaseType == null) { locase_members = new Dictionary (member_hash.Count); // StringComparer.OrdinalIgnoreCase); } else { - container.BaseType.MemberCache.VerifyClsCompliance (container.BaseType, report); - locase_members = new Dictionary (container.BaseType.MemberCache.locase_members); //, StringComparer.OrdinalIgnoreCase); + var btype = container.BaseType.GetDefinition (); + btype.MemberCache.VerifyClsCompliance (btype, report); + locase_members = new Dictionary (btype.MemberCache.locase_members); //, StringComparer.OrdinalIgnoreCase); } var is_imported_type = container.MemberDefinition.IsImported; @@ -1349,8 +1352,10 @@ namespace Mono.CSharp { type_a = parameters.Types [ii]; type_b = p_types [ii]; - if ((pd.FixedParameters [ii].ModFlags & Parameter.Modifier.ISBYREF) != - (parameters.FixedParameters [ii].ModFlags & Parameter.Modifier.ISBYREF)) + var a_byref = (pd.FixedParameters[ii].ModFlags & Parameter.Modifier.RefOutMask) != 0; + var b_byref = (parameters.FixedParameters[ii].ModFlags & Parameter.Modifier.RefOutMask) != 0; + + if (a_byref != b_byref) break; } while (TypeSpecComparer.Override.IsEqual (type_a, type_b) && ii-- != 0); @@ -1369,7 +1374,9 @@ namespace Mono.CSharp { // if (pd != null && member is MethodCore) { ii = method_param_count; - while (ii-- != 0 && parameters.FixedParameters[ii].ModFlags == pd.FixedParameters[ii].ModFlags && + while (ii-- != 0 && + (parameters.FixedParameters[ii].ModFlags & Parameter.Modifier.ModifierMask) == + (pd.FixedParameters[ii].ModFlags & Parameter.Modifier.ModifierMask) && parameters.ExtensionMethodType == pd.ExtensionMethodType) ; if (ii >= 0) { diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/method.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/method.cs index a25916d742..5f15beb0be 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/method.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/method.cs @@ -18,6 +18,8 @@ using System.Security; using System.Security.Permissions; using System.Text; using System.Linq; +using Mono.CompilerServices.SymbolWriter; +using System.Runtime.CompilerServices; #if NET_2_1 using XmlElement = System.Object; @@ -37,8 +39,6 @@ using System.Reflection; using System.Reflection.Emit; #endif -using Mono.CompilerServices.SymbolWriter; - namespace Mono.CSharp { public abstract class MethodCore : InterfaceMemberBase, IParametersMember @@ -47,7 +47,7 @@ namespace Mono.CSharp { protected ToplevelBlock block; protected MethodSpec spec; - public MethodCore (TypeContainer parent, FullNamedExpression type, Modifiers mod, Modifiers allowed_mod, + public MethodCore (TypeDefinition parent, FullNamedExpression type, Modifiers mod, Modifiers allowed_mod, MemberName name, Attributes attrs, ParametersCompiled parameters) : base (parent, type, mod, allowed_mod, name, attrs) { @@ -517,7 +517,7 @@ namespace Mono.CSharp { static readonly string[] attribute_targets = new string [] { "method", "return" }; - protected MethodOrOperator (TypeContainer parent, FullNamedExpression type, Modifiers mod, Modifiers allowed_mod, MemberName name, + protected MethodOrOperator (TypeDefinition parent, FullNamedExpression type, Modifiers mod, Modifiers allowed_mod, MemberName name, Attributes attrs, ParametersCompiled parameters) : base (parent, type, mod, allowed_mod, name, attrs, parameters) { @@ -534,10 +534,13 @@ namespace Mono.CSharp { } if (a.Type == pa.MethodImpl) { - is_external_implementation = a.IsInternalCall (); - } + if ((ModFlags & Modifiers.ASYNC) != 0 && (a.GetMethodImplOptions () & MethodImplOptions.Synchronized) != 0) { + Report.Error (4015, a.Location, "`{0}': Async methods cannot use `MethodImplOptions.Synchronized'", + GetSignatureForError ()); + } - if (a.Type == pa.DllImport) { + is_external_implementation = a.IsInternalCall (); + } else if (a.Type == pa.DllImport) { const Modifiers extern_static = Modifiers.EXTERN | Modifiers.STATIC; if ((ModFlags & extern_static) != extern_static) { Report.Error (601, a.Location, "The DllImport attribute must be specified on a method marked `static' and `extern'"); @@ -565,9 +568,9 @@ namespace Mono.CSharp { return Parent.MemberCache.CheckExistingMembersOverloads (this, parameters); } - public virtual EmitContext CreateEmitContext (ILGenerator ig) + public virtual EmitContext CreateEmitContext (ILGenerator ig, SourceMethodBuilder sourceMethod) { - return new EmitContext (this, ig, MemberType); + return new EmitContext (this, ig, MemberType, sourceMethod); } public override bool Define () @@ -634,7 +637,7 @@ namespace Mono.CSharp { if ((ModFlags & Modifiers.PARTIAL) != 0) { for (int i = 0; i < parameters.Count; ++i) { IParameterData p = parameters.FixedParameters [i]; - if (p.ModFlags == Parameter.Modifier.OUT) { + if ((p.ModFlags & Parameter.Modifier.OUT) != 0) { Report.Error (752, Location, "`{0}': A partial method parameters cannot use `out' modifier", GetSignatureForError ()); } @@ -691,7 +694,6 @@ namespace Mono.CSharp { MethodData.Emit (Parent); Block = null; - MethodData = null; } protected void Error_ConditionalAttributeIsNotValid () @@ -774,72 +776,12 @@ namespace Mono.CSharp { return conditions; } - public virtual void EmitExtraSymbolInfo (SourceMethod source) - { } - #endregion - } - - public class SourceMethod : IMethodDef - { - MethodBase method; - SourceMethodBuilder builder; - - protected SourceMethod (TypeContainer parent, MethodBase method, ICompileUnit file) - { - this.method = method; - - builder = SymbolWriter.OpenMethod (file, parent.NamespaceEntry.SymbolFileID, this); - } - - public string Name { - get { return method.Name; } - } - - public int Token { - get { - MethodToken token; - var mb = method as MethodBuilder; - if (mb != null) - token = mb.GetToken (); - else - token = ((ConstructorBuilder) method).GetToken (); -#if STATIC - if (token.IsPseudoToken) - return ((ModuleBuilder) method.Module).ResolvePseudoToken (token.Token); -#endif - return token.Token; - } - } - - public void CloseMethod () - { - SymbolWriter.CloseMethod (); - } - - public void SetRealMethodName (string name) - { - if (builder != null) - builder.SetRealMethodName (name); - } - - public static SourceMethod Create (TypeContainer parent, MethodBase method, Block block) + public override void WriteDebugSymbol (MonoSymbolFile file) { - if (!SymbolWriter.HasSymbolWriter) - return null; - if (block == null) - return null; - - Location start_loc = block.StartLocation; - if (start_loc.IsNull) - return null; - - ICompileUnit compile_unit = start_loc.CompilationUnit; - if (compile_unit == null) - return null; - - return new SourceMethod (parent, method, compile_unit); + if (MethodData != null) + MethodData.WriteDebugSymbol (file); } } @@ -847,7 +789,7 @@ namespace Mono.CSharp { { Method partialMethodImplementation; - public Method (TypeContainer parent, FullNamedExpression return_type, Modifiers mod, MemberName name, ParametersCompiled parameters, Attributes attrs) + public Method (TypeDefinition parent, FullNamedExpression return_type, Modifiers mod, MemberName name, ParametersCompiled parameters, Attributes attrs) : base (parent, return_type, mod, parent.PartialContainer.Kind == MemberKind.Interface ? AllowedModifiersInterface : parent.PartialContainer.Kind == MemberKind.Struct ? AllowedModifiersStruct | Modifiers.ASYNC : @@ -856,7 +798,7 @@ namespace Mono.CSharp { { } - protected Method (TypeContainer parent, FullNamedExpression return_type, Modifiers mod, Modifiers amod, + protected Method (TypeDefinition parent, FullNamedExpression return_type, Modifiers mod, Modifiers amod, MemberName name, ParametersCompiled parameters, Attributes attrs) : base (parent, return_type, mod, amod, name, attrs, parameters) { @@ -889,7 +831,7 @@ namespace Mono.CSharp { visitor.Visit (this); } - public static Method Create (TypeContainer parent, FullNamedExpression returnType, Modifiers mod, + public static Method Create (TypeDefinition parent, FullNamedExpression returnType, Modifiers mod, MemberName name, ParametersCompiled parameters, Attributes attrs, bool hasConstraints) { var m = new Method (parent, returnType, mod, name, parameters, attrs); @@ -950,7 +892,7 @@ namespace Mono.CSharp { var ac = parameters.Types [0] as ArrayContainer; return ac != null && ac.Rank == 1 && ac.Element.BuiltinType == BuiltinTypeSpec.Type.String && - (parameters[0].ModFlags & ~Parameter.Modifier.PARAMS) == Parameter.Modifier.NONE; + (parameters[0].ModFlags & Parameter.Modifier.RefOutMask) == 0; } public override FullNamedExpression LookupNamespaceOrType (string name, int arity, LookupMode mode, Location loc) @@ -998,7 +940,7 @@ namespace Mono.CSharp { } for (int i = 0; i < parameters.Count; ++i) { - if (parameters.FixedParameters [i].ModFlags == Parameter.Modifier.OUT) { + if ((parameters.FixedParameters [i].ModFlags & Parameter.Modifier.OUT) != 0) { Report.Error (685, Location, "Conditional method `{0}' cannot have an out parameter", GetSignatureForError ()); return; } @@ -1254,7 +1196,8 @@ namespace Mono.CSharp { Report.Error (1983, Location, "The return type of an async method must be void, Task, or Task"); } - AsyncInitializer.Create (this, block, parameters, Parent.PartialContainer, ReturnType, Location); + block = (ToplevelBlock) block.ConvertToAsyncTask (this, Parent.PartialContainer, parameters, ReturnType, Location); + ModFlags |= Modifiers.DEBUGGER_HIDDEN; } } @@ -1357,10 +1300,6 @@ namespace Mono.CSharp { public override bool EnableOverloadChecks (MemberCore overload) { - // TODO: It can be deleted when members will be defined in correct order - if (overload is Operator) - return overload.EnableOverloadChecks (this); - if (overload is Indexer) return false; @@ -1484,7 +1423,7 @@ namespace Mono.CSharp { ec.Report.Error (516, loc, "Constructor `{0}' cannot call itself", caller_builder.GetSignatureForError ()); } - + return this; } @@ -1494,8 +1433,6 @@ namespace Mono.CSharp { if (base_ctor == null) return; - ec.Mark (loc); - var call = new CallEmitter (); call.InstanceExpression = new CompilerGeneratedThis (type, loc); call.EmitPredefined (ec, base_ctor, argument_list); @@ -1528,11 +1465,13 @@ namespace Mono.CSharp { } } - public class Constructor : MethodCore, IMethodData { + public class Constructor : MethodCore, IMethodData + { public ConstructorBuilder ConstructorBuilder; public ConstructorInitializer Initializer; SecurityType declarative_security; bool has_compliant_args; + SourceMethodBuilder debug_builder; // // Modifiers allowed for a constructor. @@ -1551,7 +1490,7 @@ namespace Mono.CSharp { public static readonly string ConstructorName = ".ctor"; public static readonly string TypeConstructorName = ".cctor"; - public Constructor (TypeContainer parent, string name, Modifiers mod, Attributes attrs, ParametersCompiled args, Location loc) + public Constructor (TypeDefinition parent, string name, Modifiers mod, Attributes attrs, ParametersCompiled args, Location loc) : base (parent, null, mod, AllowedModifiers, new MemberName (name, loc), attrs, args) { } @@ -1569,9 +1508,9 @@ namespace Mono.CSharp { } bool IMethodData.IsAccessor { - get { - return false; - } + get { + return false; + } } // @@ -1615,6 +1554,9 @@ namespace Mono.CSharp { return false; } + if ((caching_flags & Flags.MethodOverloadsExist) != 0) + Parent.MemberCache.CheckExistingMembersOverloads (this, parameters); + // the rest can be ignored return true; } @@ -1645,14 +1587,6 @@ namespace Mono.CSharp { if (ConstructorBuilder != null) return true; - var ca = MethodAttributes.RTSpecialName | MethodAttributes.SpecialName; - - if ((ModFlags & Modifiers.STATIC) != 0) { - ca |= MethodAttributes.Static | MethodAttributes.Private; - } else { - ca |= ModifiersExtensions.MethodAttr (ModFlags); - } - if (!CheckAbstractAndExtern (block != null)) return false; @@ -1660,6 +1594,8 @@ namespace Mono.CSharp { if (!CheckBase ()) return false; + var ca = ModifiersExtensions.MethodAttr (ModFlags) | MethodAttributes.RTSpecialName | MethodAttributes.SpecialName; + ConstructorBuilder = Parent.TypeBuilder.DefineConstructor ( ca, CallingConventions, parameters.GetMetaInfo ()); @@ -1703,50 +1639,50 @@ namespace Mono.CSharp { base.Emit (); parameters.ApplyAttributes (this, ConstructorBuilder); - // - // If we use a "this (...)" constructor initializer, then - // do not emit field initializers, they are initialized in the other constructor - // - bool emit_field_initializers = ((ModFlags & Modifiers.STATIC) != 0) || - !(Initializer is ConstructorThisInitializer); BlockContext bc = new BlockContext (this, block, Compiler.BuiltinTypes.Void); bc.Set (ResolveContext.Options.ConstructorScope); - if (emit_field_initializers) + // + // If we use a "this (...)" constructor initializer, then + // do not emit field initializers, they are initialized in the other constructor + // + if (!(Initializer is ConstructorThisInitializer)) Parent.PartialContainer.ResolveFieldInitializers (bc); if (block != null) { - // If this is a non-static `struct' constructor and doesn't have any - // initializer, it must initialize all of the struct's fields. - if ((Parent.PartialContainer.Kind == MemberKind.Struct) && - ((ModFlags & Modifiers.STATIC) == 0) && (Initializer == null)) - block.AddThisVariable (bc); - - if ((ModFlags & Modifiers.STATIC) == 0){ - if (Parent.PartialContainer.Kind == MemberKind.Class && Initializer == null) - Initializer = new GeneratedBaseInitializer (Location); + if (!IsStatic) { + if (Initializer == null) { + if (Parent.PartialContainer.Kind == MemberKind.Struct) { + // + // If this is a non-static `struct' constructor and doesn't have any + // initializer, it must initialize all of the struct's fields. + // + block.AddThisVariable (bc); + } else if (Parent.PartialContainer.Kind == MemberKind.Class) { + Initializer = new GeneratedBaseInitializer (Location); + } + } if (Initializer != null) { + // + // mdb format does not support reqions. Try to workaround this by emitting the + // sequence point at initializer. Any breakpoint at constructor header should + // be adjusted to this sequence point as it's the next one which follows. + // block.AddScopeStatement (new StatementExpression (Initializer)); } } - } - - SourceMethod source = SourceMethod.Create (Parent, ConstructorBuilder, block); - if (block != null) { if (block.Resolve (null, bc, this)) { - EmitContext ec = new EmitContext (this, ConstructorBuilder.GetILGenerator (), bc.ReturnType); + debug_builder = Parent.CreateMethodSymbolEntry (); + EmitContext ec = new EmitContext (this, ConstructorBuilder.GetILGenerator (), bc.ReturnType, debug_builder); ec.With (EmitContext.Options.ConstructorScope, true); block.Emit (ec); } } - if (source != null) - source.CloseMethod (); - if (declarative_security != null) { foreach (var de in declarative_security) { #if STATIC @@ -1767,6 +1703,11 @@ namespace Mono.CSharp { return null; } + public override string GetCallerMemberName () + { + return IsStatic ? TypeConstructorName : ConstructorName; + } + public override string GetSignatureForDocumentation () { return Parent.GetSignatureForDocumentation () + ".#ctor" + parameters.GetSignatureForDocumentation (); @@ -1801,6 +1742,21 @@ namespace Mono.CSharp { return true; } + public override void WriteDebugSymbol (MonoSymbolFile file) + { + if (debug_builder == null) + return; + + var token = ConstructorBuilder.GetToken (); + int t = token.Token; +#if STATIC + if (token.IsPseudoToken) + t = Module.Builder.ResolvePseudoToken (t); +#endif + + debug_builder.DefineMethod (file, t); + } + #region IMethodData Members public MemberName MethodName { @@ -1815,19 +1771,11 @@ namespace Mono.CSharp { } } - public EmitContext CreateEmitContext (ILGenerator ig) + EmitContext IMethodData.CreateEmitContext (ILGenerator ig, SourceMethodBuilder sourceMethod) { throw new NotImplementedException (); } - public bool IsExcluded() - { - return false; - } - - void IMethodData.EmitExtraSymbolInfo (SourceMethod source) - { } - #endregion } @@ -1847,8 +1795,7 @@ namespace Mono.CSharp { Attributes OptAttributes { get; } ToplevelBlock Block { get; set; } - EmitContext CreateEmitContext (ILGenerator ig); - void EmitExtraSymbolInfo (SourceMethod source); + EmitContext CreateEmitContext (ILGenerator ig, SourceMethodBuilder sourceMethod); } // @@ -1875,6 +1822,7 @@ namespace Mono.CSharp { protected MethodAttributes flags; protected TypeSpec declaring_type; protected MethodSpec parent_method; + SourceMethodBuilder debug_builder; MethodBuilder builder; public MethodBuilder MethodBuilder { @@ -1902,16 +1850,14 @@ namespace Mono.CSharp { public MethodData (InterfaceMemberBase member, Modifiers modifiers, MethodAttributes flags, IMethodData method, MethodBuilder builder, - //GenericMethod generic, MethodSpec parent_method) : this (member, modifiers, flags, method) { this.builder = builder; - //this.GenericMethod = generic; this.parent_method = parent_method; } - public bool Define (TypeContainer container, string method_full_name) + public bool Define (TypeDefinition container, string method_full_name) { PendingImplementation pending = container.PendingImplementations; MethodSpec ambig_iface_method; @@ -2083,7 +2029,7 @@ namespace Mono.CSharp { /// /// Create the MethodBuilder for the method /// - void DefineMethodBuilder (TypeContainer container, string method_name, ParametersCompiled param) + void DefineMethodBuilder (TypeDefinition container, string method_name, ParametersCompiled param) { var return_type = method.ReturnType.GetMetaInfo (); var p_types = param.GetMetaInfo (); @@ -2119,28 +2065,37 @@ namespace Mono.CSharp { // // Emits the code // - public void Emit (TypeContainer parent) + public void Emit (TypeDefinition parent) { var mc = (IMemberContext) method; method.ParameterInfo.ApplyAttributes (mc, MethodBuilder); - SourceMethod source = SourceMethod.Create (parent, MethodBuilder, method.Block); - ToplevelBlock block = method.Block; if (block != null) { BlockContext bc = new BlockContext (mc, block, method.ReturnType); if (block.Resolve (null, bc, method)) { - EmitContext ec = method.CreateEmitContext (MethodBuilder.GetILGenerator ()); + debug_builder = member.Parent.CreateMethodSymbolEntry (); + EmitContext ec = method.CreateEmitContext (MethodBuilder.GetILGenerator (), debug_builder); block.Emit (ec); } } + } - if (source != null) { - method.EmitExtraSymbolInfo (source); - source.CloseMethod (); - } + public void WriteDebugSymbol (MonoSymbolFile file) + { + if (debug_builder == null) + return; + + var token = builder.GetToken (); + int t = token.Token; +#if STATIC + if (token.IsPseudoToken) + t = member.Module.Builder.ResolvePseudoToken (t); +#endif + + debug_builder.DefineMethod (file, t); } } @@ -2154,7 +2109,12 @@ namespace Mono.CSharp { public static readonly string MetadataName = "Finalize"; - public Destructor (TypeContainer parent, Modifiers mod, ParametersCompiled parameters, Attributes attrs, Location l) + public string Identifier { + get; + set; + } + + public Destructor (TypeDefinition parent, Modifiers mod, ParametersCompiled parameters, Attributes attrs, Location l) : base (parent, null, mod, AllowedModifiers, new MemberName (MetadataName, l), attrs, parameters) { ModFlags &= ~Modifiers.PRIVATE; @@ -2195,15 +2155,19 @@ namespace Mono.CSharp { MethodGroupExpr method_expr = MethodGroupExpr.CreatePredefined (base_dtor, base_type, Location); method_expr.InstanceExpression = new BaseThis (base_type, Location); - var try_block = new ExplicitBlock (block, block.StartLocation, block.EndLocation); - var finaly_block = new ExplicitBlock (block, Location, Location); + var try_block = new ExplicitBlock (block, block.StartLocation, block.EndLocation) { + IsCompilerGenerated = true + }; + var finaly_block = new ExplicitBlock (block, Location, Location) { + IsCompilerGenerated = true + }; // // 0-size arguments to avoid CS0250 error // TODO: Should use AddScopeStatement or something else which emits correct // debugger scope // - finaly_block.AddStatement (new StatementExpression (new Invocation (method_expr, new Arguments (0)))); + finaly_block.AddStatement (new StatementExpression (new Invocation (method_expr, new Arguments (0)), Location.Null)); var tf = new TryFinally (try_block, finaly_block, Location); block.WrapIntoDestructor (tf, try_block); @@ -2275,9 +2239,9 @@ namespace Mono.CSharp { } } - public EmitContext CreateEmitContext (ILGenerator ig) + public EmitContext CreateEmitContext (ILGenerator ig, SourceMethodBuilder sourceMethod) { - return new EmitContext (this, ig, ReturnType); + return new EmitContext (this, ig, ReturnType, sourceMethod); } public bool IsAccessor { @@ -2286,11 +2250,6 @@ namespace Mono.CSharp { } } - public bool IsExcluded () - { - return false; - } - public MemberName MethodName { get { return MemberName; @@ -2349,7 +2308,7 @@ namespace Mono.CSharp { throw new NotSupportedException (); } - public virtual void Emit (TypeContainer parent) + public virtual void Emit (TypeDefinition parent) { method_data.Emit (parent); @@ -2397,6 +2356,11 @@ namespace Mono.CSharp { return false; } + public override string GetCallerMemberName () + { + return base.GetCallerMemberName ().Substring (prefix.Length); + } + public override string GetSignatureForDocumentation () { // should not be called @@ -2408,6 +2372,12 @@ namespace Mono.CSharp { return false; } + public override void WriteDebugSymbol (MonoSymbolFile file) + { + if (method_data != null) + method_data.WriteDebugSymbol (file); + } + public MethodSpec Spec { get; protected set; } // @@ -2416,9 +2386,6 @@ namespace Mono.CSharp { public override string DocCommentHeader { get { throw new InvalidOperationException ("Unexpected attempt to get doc comment from " + this.GetType () + "."); } } - - void IMethodData.EmitExtraSymbolInfo (SourceMethod source) - { } } public class Operator : MethodOrOperator { @@ -2504,8 +2471,8 @@ namespace Mono.CSharp { names [(int) OpType.Implicit] = new string [] { "implicit", "op_Implicit" }; names [(int) OpType.Explicit] = new string [] { "explicit", "op_Explicit" }; } - - public Operator (TypeContainer parent, OpType type, FullNamedExpression ret_type, Modifiers mod_flags, ParametersCompiled parameters, + + public Operator (TypeDefinition parent, OpType type, FullNamedExpression ret_type, Modifiers mod_flags, ParametersCompiled parameters, ToplevelBlock block, Attributes attrs, Location loc) : base (parent, ret_type, mod_flags, AllowedModifiers, new MemberName (GetMetadataName (type), loc), attrs, parameters) { diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/roottypes.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/module.cs similarity index 67% rename from src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/roottypes.cs rename to src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/module.cs index a368473f2f..3117053fcf 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/roottypes.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/module.cs @@ -1,5 +1,5 @@ // -// roottypes.cs: keeps a tree representation of the generated code +// module.cs: keeps a tree representation of the generated code // // Authors: Miguel de Icaza (miguel@gnu.org) // Marek Safar (marek.safar@gmail.com) @@ -15,6 +15,7 @@ using System; using System.Collections.Generic; using System.Runtime.InteropServices; using Mono.CompilerServices.SymbolWriter; +using System.Linq; #if STATIC using IKVM.Reflection; @@ -35,23 +36,24 @@ namespace Mono.CSharp // // Compiler generated container for static data // - sealed class StaticDataContainer : CompilerGeneratedClass + sealed class StaticDataContainer : CompilerGeneratedContainer { readonly Dictionary size_types; - new int fields; + int fields; public StaticDataContainer (ModuleContainer module) - : base (module, new MemberName ("" + module.builder.ModuleVersionId.ToString ("B"), Location.Null), Modifiers.STATIC) + : base (module, new MemberName ("" + module.builder.ModuleVersionId.ToString ("B"), Location.Null), + Modifiers.STATIC | Modifiers.INTERNAL) { size_types = new Dictionary (); } - public override void CloseType () + public override void CloseContainer () { - base.CloseType (); + base.CloseContainer (); foreach (var entry in size_types) { - entry.Value.CloseType (); + entry.Value.CloseContainer (); } } @@ -64,9 +66,9 @@ namespace Mono.CSharp // DefineInitializedData because it creates public type, // and its name is not unique among modules // - size_type = new Struct (null, this, new MemberName ("$ArrayType=" + data.Length, loc), Modifiers.PRIVATE | Modifiers.COMPILER_GENERATED, null); - size_type.CreateType (); - size_type.DefineType (); + size_type = new Struct (this, new MemberName ("$ArrayType=" + data.Length, loc), Modifiers.PRIVATE | Modifiers.COMPILER_GENERATED, null); + size_type.CreateContainer (); + size_type.DefineContainer (); size_types.Add (data.Length, size_type); @@ -93,8 +95,8 @@ namespace Mono.CSharp { if (static_data == null) { static_data = new StaticDataContainer (this); - static_data.CreateType (); - static_data.DefineType (); + static_data.CreateContainer (); + static_data.DefineContainer (); AddCompilerGeneratedClass (static_data); } @@ -112,9 +114,6 @@ namespace Mono.CSharp readonly Dictionary reference_types; readonly Dictionary attrs_cache; - // Used for unique namespaces/types during parsing - Dictionary defined_type_containers; - AssemblyDefinition assembly; readonly CompilerContext context; readonly RootNamespace global_ns; @@ -131,13 +130,13 @@ namespace Mono.CSharp static readonly string[] attribute_targets = new string[] { "assembly", "module" }; public ModuleContainer (CompilerContext context) - : base (null, null, MemberName.Null, null, 0) + : base (null, MemberName.Null, null, 0) { this.context = context; caching_flags &= ~(Flags.Obsolete_Undetected | Flags.Excluded_Undetected); - types = new List (); + containers = new List (); anonymous_types = new Dictionary> (); global_ns = new GlobalRootNamespace (); alias_ns = new Dictionary (); @@ -145,8 +144,6 @@ namespace Mono.CSharp pointer_types = new Dictionary (); reference_types = new Dictionary (); attrs_cache = new Dictionary (); - - defined_type_containers = new Dictionary (); } #region Properties @@ -184,7 +181,12 @@ namespace Mono.CSharp } } - public override AssemblyDefinition DeclaringAssembly { + public int CounterAnonymousTypes { get; set; } + public int CounterAnonymousMethods { get; set; } + public int CounterAnonymousContainers { get; set; } + public int CounterSwitchTypes { get; set; } + + public AssemblyDefinition DeclaringAssembly { get { return assembly; } @@ -194,6 +196,12 @@ namespace Mono.CSharp get; set; } + public override string DocCommentHeader { + get { + throw new NotSupportedException (); + } + } + public Evaluator Evaluator { get; set; } @@ -299,9 +307,9 @@ namespace Mono.CSharp attributes.AddAttribute (attr); } - public override TypeContainer AddPartial (TypeContainer nextPart) + public override void AddTypeContainer (TypeContainer tc) { - return AddPartial (nextPart, nextPart.MemberName.GetName (true)); + containers.Add (tc); } public override void ApplyAttributeBuilder (Attribute a, MethodSpec ctor, byte[] cdata, PredefinedAttributes pa) @@ -345,21 +353,15 @@ namespace Mono.CSharp builder.SetCustomAttribute ((ConstructorInfo) ctor.GetMetaInfo (), cdata); } - public override void CloseType () + public override void CloseContainer () { - foreach (TypeContainer tc in types) { - tc.CloseType (); - } - if (anonymous_types != null) { foreach (var atypes in anonymous_types) foreach (var at in atypes.Value) - at.CloseType (); + at.CloseContainer (); } - if (compiler_generated != null) - foreach (CompilerGeneratedClass c in compiler_generated) - c.CloseType (); + base.CloseContainer (); } public TypeBuilder CreateBuilder (string name, TypeAttributes attr, int typeSize) @@ -392,43 +394,25 @@ namespace Mono.CSharp builder = moduleBuilder; } - public new void CreateType () + public override bool Define () { - // Release cache used by parser only - if (Evaluator == null) - defined_type_containers = null; - else - defined_type_containers.Clear (); + DefineContainer (); - foreach (TypeContainer tc in types) - tc.CreateType (); - } + base.Define (); - public new void Define () - { - foreach (TypeContainer tc in types) { - try { - tc.DefineType (); - } catch (Exception e) { - throw new InternalErrorException (tc, e); - } - } + HasTypesFullyDefined = true; - foreach (TypeContainer tc in types) - tc.ResolveTypeParameters (); + return true; + } - foreach (TypeContainer tc in types) { - try { - tc.Define (); - } catch (Exception e) { - throw new InternalErrorException (tc, e); - } - } + public override bool DefineContainer () + { + DefineNamespace (); - HasTypesFullyDefined = true; + return base.DefineContainer (); } - public override void Emit () + public override void EmitContainer () { if (OptAttributes != null) OptAttributes.Emit (); @@ -439,32 +423,25 @@ namespace Mono.CSharp pa.EmitAttribute (builder); } - foreach (var tc in types) - tc.DefineConstants (); - - foreach (TypeContainer tc in types) - tc.EmitType (); + foreach (var tc in containers) { + tc.PrepareEmit (); + } - if (Compiler.Report.Errors > 0) - return; + base.EmitContainer (); - foreach (TypeContainer tc in types) - tc.VerifyMembers (); + if (Compiler.Report.Errors == 0) + VerifyMembers (); if (anonymous_types != null) { foreach (var atypes in anonymous_types) foreach (var at in atypes.Value) - at.EmitType (); + at.EmitContainer (); } - - if (compiler_generated != null) - foreach (var c in compiler_generated) - c.EmitType (); } internal override void GenerateDocComment (DocumentationBuilder builder) { - foreach (var tc in types) + foreach (var tc in containers) tc.GenerateDocComment (builder); } @@ -488,6 +465,12 @@ namespace Mono.CSharp return null; } + public override void GetCompletionStartingWith (string prefix, List results) + { + var names = Evaluator.GetVarNames (); + results.AddRange (names.Where (l => l.StartsWith (prefix))); + } + public RootNamespace GetRootNamespace (string name) { RootNamespace rn; @@ -512,62 +495,6 @@ namespace Mono.CSharp return DeclaringAssembly.IsCLSCompliant; } - protected override bool AddMemberType (TypeContainer tc) - { - if (AddTypesContainer (tc)) { - if ((tc.ModFlags & Modifiers.PARTIAL) != 0) - defined_names.Add (tc.MemberName.GetName (true), tc); - - tc.NamespaceEntry.NS.AddType (this, tc.Definition); - return true; - } - - return false; - } - - public bool AddTypesContainer (ITypesContainer container) - { - var mn = container.MemberName; - ITypesContainer found; - if (!defined_type_containers.TryGetValue (mn, out found)) { - defined_type_containers.Add (mn, container); - return true; - } - - if (container is NamespaceContainer && found is NamespaceContainer) - return true; - - var container_tc = container as TypeContainer; - var found_tc = found as TypeContainer; - if (container_tc != null && found_tc != null && container_tc.Kind == found_tc.Kind) { - if ((found_tc.ModFlags & container_tc.ModFlags & Modifiers.PARTIAL) != 0) { - return false; - } - - if (((found_tc.ModFlags | container_tc.ModFlags) & Modifiers.PARTIAL) != 0) { - Report.SymbolRelatedToPreviousError (found_tc); - Error_MissingPartialModifier (container_tc); - return false; - } - } - - string ns = mn.Left != null ? mn.Left.GetSignatureForError () : Module.GlobalRootNamespace.GetSignatureForError (); - mn = new MemberName (mn.Name, mn.TypeParameters, mn.Location); - - Report.SymbolRelatedToPreviousError (found.Location, ""); - Report.Error (101, container.Location, - "The namespace `{0}' already contains a definition for `{1}'", - ns, mn.GetSignatureForError ()); - return false; - } - - protected override void RemoveMemberType (TypeContainer ds) - { - defined_type_containers.Remove (ds.MemberName); - ds.NamespaceEntry.NS.RemoveDeclSpace (ds.Basename); - base.RemoveMemberType (ds); - } - public Attribute ResolveAssemblyAttribute (PredefinedAttribute a_type) { Attribute a = OptAttributes.Search ("assembly", a_type); @@ -583,52 +510,4 @@ namespace Mono.CSharp this.assembly = assembly; } } - - sealed class RootDeclSpace : TypeContainer { - public RootDeclSpace (ModuleContainer module, NamespaceContainer ns) - : base (ns, null, MemberName.Null, null, 0) - { - PartialContainer = module; - } - - public override AttributeTargets AttributeTargets { - get { throw new InternalErrorException ("should not be called"); } - } - - public override CompilerContext Compiler { - get { - return PartialContainer.Compiler; - } - } - - public override string DocCommentHeader { - get { throw new InternalErrorException ("should not be called"); } - } - - public override ModuleContainer Module { - get { - return PartialContainer.Module; - } - } - - public override void Accept (StructuralVisitor visitor) - { - throw new InternalErrorException ("should not be called"); - } - - public override bool IsClsComplianceRequired () - { - return PartialContainer.IsClsComplianceRequired (); - } - - public override ExtensionMethodCandidates LookupExtensionMethod (TypeSpec extensionType, string name, int arity) - { - return null; - } - - public override FullNamedExpression LookupNamespaceAlias (string name) - { - return NamespaceEntry.LookupNamespaceAlias (name); - } - } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/namespace.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/namespace.cs index 9f4ba6a771..c2d4f30401 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/namespace.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/namespace.cs @@ -12,6 +12,7 @@ using System; using System.Collections.Generic; using System.Linq; +using Mono.CompilerServices.SymbolWriter; namespace Mono.CSharp { @@ -83,6 +84,7 @@ namespace Mono.CSharp { string fullname; protected Dictionary namespaces; protected Dictionary> types; + List extension_method_types; Dictionary cached_types; RootNamespace root; bool cls_checked; @@ -194,7 +196,29 @@ namespace Mono.CSharp { { return fullname; } - + + public Namespace AddNamespace (MemberName name) + { + Namespace ns_parent; + if (name.Left != null) { + if (parent != null) + ns_parent = parent.AddNamespace (name.Left); + else + ns_parent = AddNamespace (name.Left); + } else { + ns_parent = this; + } + + Namespace ns; + if (!ns_parent.namespaces.TryGetValue (name.Basename, out ns)) { + ns = new Namespace (ns_parent, name.Basename); + ns_parent.namespaces.Add (name.Basename, ns); + } + + return ns; + } + + // TODO: Replace with CreateNamespace where MemberName is created for the method call public Namespace GetNamespace (string name, bool create) { int pos = name.IndexOf ('.'); @@ -303,37 +327,6 @@ namespace Mono.CSharp { return te; } - TypeSpec LookupType (string name, int arity) - { - if (types == null) - return null; - - IList found; - if (types.TryGetValue (name, out found)) { - TypeSpec best = null; - - foreach (var ts in found) { - if (ts.Arity == arity) - return ts; - - // - // Lookup for the best candidate with closest arity match - // - if (arity < 0) { - if (best == null) { - best = ts; - } else if (System.Math.Abs (ts.Arity + arity) < System.Math.Abs (best.Arity + arity)) { - best = ts; - } - } - } - - return best; - } - - return null; - } - public FullNamedExpression LookupTypeOrNamespace (IMemberContext ctx, string name, int arity, LookupMode mode, Location loc) { var texpr = LookupType (ctx, name, arity, mode, loc); @@ -381,59 +374,55 @@ namespace Mono.CSharp { // public List LookupExtensionMethod (IMemberContext invocationContext, TypeSpec extensionType, string name, int arity) { - if (types == null) + if (extension_method_types == null) return null; List found = null; + for (int i = 0; i < extension_method_types.Count; ++i) { + var ts = extension_method_types[i]; - // TODO: Add per namespace flag when at least 1 type has extension + // + // When the list was built we didn't know what members the type + // contains + // + if ((ts.Modifiers & Modifiers.METHOD_EXTENSION) == 0) { + if (extension_method_types.Count == 1) { + extension_method_types = null; + return found; + } - foreach (var tgroup in types.Values) { - foreach (var ts in tgroup) { - if ((ts.Modifiers & Modifiers.METHOD_EXTENSION) == 0) - continue; + extension_method_types.RemoveAt (i--); + continue; + } - var res = ts.MemberCache.FindExtensionMethods (invocationContext, extensionType, name, arity); - if (res == null) - continue; + var res = ts.MemberCache.FindExtensionMethods (invocationContext, extensionType, name, arity); + if (res == null) + continue; - if (found == null) { - found = res; - } else { - found.AddRange (res); - } + if (found == null) { + found = res; + } else { + found.AddRange (res); } } return found; } - // - // Extension methods look up for dotted namespace names - // - public IList LookupExtensionMethod (IMemberContext invocationContext, TypeSpec extensionType, string name, int arity, out Namespace scope) - { - // - // Inspect parent namespaces in namespace expression - // - scope = this; - do { - var candidates = scope.LookupExtensionMethod (invocationContext, extensionType, name, arity); - if (candidates != null) - return candidates; - - scope = scope.Parent; - } while (scope != null); - - return null; - } - public void AddType (ModuleContainer module, TypeSpec ts) { if (types == null) { types = new Dictionary> (64); } + if ((ts.IsStatic || ts.MemberDefinition.IsPartial) && ts.Arity == 0 && + (ts.MemberDefinition.DeclaringAssembly == null || ts.MemberDefinition.DeclaringAssembly.HasExtensionMethod)) { + if (extension_method_types == null) + extension_method_types = new List (); + + extension_method_types.Add (ts); + } + var name = ts.Name; IList existing; if (types.TryGetValue (name, out existing)) { @@ -499,10 +488,10 @@ namespace Mono.CSharp { return null; } - public void RemoveDeclSpace (string name) + public void RemoveContainer (TypeContainer tc) { - types.Remove (name); - cached_types.Remove (name); + types.Remove (tc.Basename); + cached_types.Remove (tc.Basename); } public override FullNamedExpression ResolveAsTypeOrNamespace (IMemberContext mc) @@ -578,63 +567,161 @@ namespace Mono.CSharp { } } + public class CompilationSourceFile : NamespaceContainer + { + readonly SourceFile file; + CompileUnitEntry comp_unit; + Dictionary include_files; + Dictionary conditionals; + + public CompilationSourceFile (ModuleContainer parent, SourceFile sourceFile) + : this (parent) + { + this.file = sourceFile; + } + + public CompilationSourceFile (ModuleContainer parent) + : base (parent) + { + } + + public CompileUnitEntry SymbolUnitEntry { + get { + return comp_unit; + } + } + + public string FileName { + get { + return file.Name; + } + } + + public SourceFile SourceFile { + get { + return file; + } + } + + public void AddIncludeFile (SourceFile file) + { + if (file == this.file) + return; + + if (include_files == null) + include_files = new Dictionary (); + + if (!include_files.ContainsKey (file.FullPathName)) + include_files.Add (file.FullPathName, file); + } + + public void AddDefine (string value) + { + if (conditionals == null) + conditionals = new Dictionary (2); + + conditionals[value] = true; + } + + public void AddUndefine (string value) + { + if (conditionals == null) + conditionals = new Dictionary (2); + + conditionals[value] = false; + } + + public override void PrepareEmit () + { + var sw = Module.DeclaringAssembly.SymbolWriter; + if (sw != null) { + CreateUnitSymbolInfo (sw); + } + + base.PrepareEmit (); + } + + // + // Creates symbol file index in debug symbol file + // + void CreateUnitSymbolInfo (MonoSymbolFile symwriter) + { + var si = file.CreateSymbolInfo (symwriter); + comp_unit = new CompileUnitEntry (symwriter, si);; + + if (include_files != null) { + foreach (SourceFile include in include_files.Values) { + si = include.CreateSymbolInfo (symwriter); + comp_unit.AddFile (si); + } + } + } + + public bool IsConditionalDefined (string value) + { + if (conditionals != null) { + bool res; + if (conditionals.TryGetValue (value, out res)) + return res; + + // When conditional was undefined + if (conditionals.ContainsKey (value)) + return false; + } + + return Compiler.Settings.IsConditionalSymbolDefined (value); + } + } + + // // Namespace block as created by the parser // - public class NamespaceContainer : IMemberContext, ITypesContainer + public class NamespaceContainer : TypeContainer, IMemberContext { static readonly Namespace[] empty_namespaces = new Namespace[0]; - static readonly string[] empty_using_list = new string[0]; - - Namespace ns; - readonly ModuleContainer module; - readonly NamespaceContainer parent; - readonly CompilationSourceFile file; - readonly MemberName name; + readonly Namespace ns; - int symfile_id; + public new readonly NamespaceContainer Parent; List clauses; // Used by parsed to check for parser errors public bool DeclarationFound; - bool resolved; - - public readonly TypeContainer SlaveDeclSpace; - Namespace[] namespace_using_table; Dictionary aliases; + public readonly MemberName RealMemberName; - public NamespaceContainer (MemberName name, ModuleContainer module, NamespaceContainer parent, CompilationSourceFile sourceFile) + public NamespaceContainer (MemberName name, NamespaceContainer parent) + : base (parent, name, null, MemberKind.Namespace) { - this.module = module; - this.parent = parent; - this.file = sourceFile; - this.name = name ?? MemberName.Null; + this.RealMemberName = name; + this.Parent = parent; + this.ns = parent.NS.AddNamespace (name); - if (parent != null) - ns = parent.NS.GetNamespace (name.GetName (), true); - else if (name != null) - ns = module.GlobalRootNamespace.GetNamespace (name.GetName (), true); - else - ns = module.GlobalRootNamespace; + containers = new List (); + } - SlaveDeclSpace = new RootDeclSpace (module, this); + protected NamespaceContainer (ModuleContainer parent) + : base (parent, null, null, MemberKind.Namespace) + { + ns = parent.GlobalRootNamespace; + containers = new List (2); } #region Properties - public Location Location { + public override AttributeTargets AttributeTargets { get { - return name.Location; + throw new NotSupportedException (); } } - public MemberName MemberName { + public override string DocCommentHeader { get { - return name; + throw new NotSupportedException (); } } @@ -644,21 +731,15 @@ namespace Mono.CSharp { } } - public NamespaceContainer Parent { - get { - return parent; - } - } - - public CompilationSourceFile SourceFile { + public List Usings { get { - return file; + return clauses; } } - public List Usings { + public override string[] ValidAttributeTargets { get { - return clauses; + throw new NotSupportedException (); } } @@ -674,8 +755,6 @@ namespace Mono.CSharp { clauses = new List (); clauses.Add (un); - - resolved = false; } public void AddUsing (UsingAliasNamespace un) @@ -703,54 +782,159 @@ namespace Mono.CSharp { } clauses.Add (un); + } - resolved = false; + public override void AddPartial (TypeDefinition next_part) + { + var existing = ns.LookupType (this, next_part.MemberName.Name, next_part.MemberName.Arity, LookupMode.Probing, Location.Null); + var td = existing != null ? existing.Type.MemberDefinition as TypeDefinition : null; + AddPartial (next_part, td); } - // - // Does extension methods look up to find a method which matches name and extensionType. - // Search starts from this namespace and continues hierarchically up to top level. - // - public ExtensionMethodCandidates LookupExtensionMethod (TypeSpec extensionType, string name, int arity) + public override void AddTypeContainer (TypeContainer tc) { - List candidates = null; - foreach (Namespace n in namespace_using_table) { - var a = n.LookupExtensionMethod (this, extensionType, name, arity); - if (a == null) - continue; + string name = tc.Basename; - if (candidates == null) - candidates = a; - else - candidates.AddRange (a); + var mn = tc.MemberName; + while (mn.Left != null) { + mn = mn.Left; + name = mn.Name; + } + + MemberCore mc; + if (defined_names.TryGetValue (name, out mc)) { + if (tc is NamespaceContainer && mc is NamespaceContainer) { + containers.Add (tc); + return; + } + + Report.SymbolRelatedToPreviousError (mc); + if ((mc.ModFlags & Modifiers.PARTIAL) != 0 && (tc is ClassOrStruct || tc is Interface)) { + Error_MissingPartialModifier (tc); + } else { + Report.Error (101, tc.Location, "The namespace `{0}' already contains a definition for `{1}'", + GetSignatureForError (), mn.GetSignatureForError ()); + } + } else { + defined_names.Add (name, tc); } - if (candidates != null) - return new ExtensionMethodCandidates (candidates, this); + base.AddTypeContainer (tc); - if (parent == null) - return null; + var tdef = tc.PartialContainer; + if (tdef != null) + ns.AddType (Module, tdef.Definition); + } - Namespace ns_scope; - var ns_candidates = ns.Parent.LookupExtensionMethod (this, extensionType, name, arity, out ns_scope); - if (ns_candidates != null) - return new ExtensionMethodCandidates (ns_candidates, this, ns_scope); + public override void ApplyAttributeBuilder (Attribute a, MethodSpec ctor, byte[] cdata, PredefinedAttributes pa) + { + throw new NotSupportedException (); + } + + public override void EmitContainer () + { + VerifyClsCompliance (); + base.EmitContainer (); + } + + public ExtensionMethodCandidates LookupExtensionMethod (IMemberContext invocationContext, TypeSpec extensionType, string name, int arity, int position) + { + // + // Here we try to resume the search for extension method at the point + // where the last bunch of candidates was found. It's more tricky than + // it seems as we have to check both namespace containers and namespace + // in correct order. // - // Continue in parent container + // Consider: + // + // namespace A { + // using N1; + // namespace B.C.D { + // 0) { + mn = mn.Left; + container_ns = container_ns.Parent; + } + + while (mn != null) { + ++position; + + var methods = container_ns.LookupExtensionMethod (invocationContext, extensionType, name, arity); + if (methods != null) { + return new ExtensionMethodCandidates (invocationContext, methods, container, position); + } + + mn = mn.Left; + container_ns = container_ns.Parent; + } + + position = 0; + container = container.Parent; + } while (container != null); + + return null; + } + + ExtensionMethodCandidates LookupExtensionMethodCandidates (IMemberContext invocationContext, TypeSpec extensionType, string name, int arity, ref int position) + { + List candidates = null; + + if (position == 0) { + ++position; + + candidates = ns.LookupExtensionMethod (invocationContext, extensionType, name, arity); + if (candidates != null) { + return new ExtensionMethodCandidates (invocationContext, candidates, this, position); + } + } + + if (position == 1) { + ++position; + + foreach (Namespace n in namespace_using_table) { + var a = n.LookupExtensionMethod (invocationContext, extensionType, name, arity); + if (a == null) + continue; + + if (candidates == null) + candidates = a; + else + candidates.AddRange (a); + } + + if (candidates != null) + return new ExtensionMethodCandidates (invocationContext, candidates, this, position); + } + + return null; } - public FullNamedExpression LookupNamespaceOrType (string name, int arity, LookupMode mode, Location loc) + public override FullNamedExpression LookupNamespaceOrType (string name, int arity, LookupMode mode, Location loc) { // // Only simple names (no dots) will be looked up with this function // FullNamedExpression resolved; - for (NamespaceContainer container = this; container != null; container = container.parent) { + for (NamespaceContainer container = this; container != null; container = container.Parent) { resolved = container.Lookup (name, arity, mode, loc); - if (resolved != null) + if (resolved != null || container.MemberName == null) return resolved; var container_ns = container.ns.Parent; @@ -768,25 +952,35 @@ namespace Mono.CSharp { return null; } - public IList CompletionGetTypesStartingWith (string prefix) + public override void GetCompletionStartingWith (string prefix, List results) { + foreach (var un in Usings) { + if (un.Alias != null) + continue; + + var name = un.NamespaceExpression.Name; + if (name.StartsWith (prefix)) + results.Add (name); + } + + IEnumerable all = Enumerable.Empty (); - - for (NamespaceContainer curr_ns = this; curr_ns != null; curr_ns = curr_ns.parent){ - foreach (Namespace using_ns in namespace_using_table){ - if (prefix.StartsWith (using_ns.Name)){ - int ld = prefix.LastIndexOf ('.'); - if (ld != -1){ - string rest = prefix.Substring (ld+1); - - all = all.Concat (using_ns.CompletionGetTypesStartingWith (rest)); - } + + foreach (Namespace using_ns in namespace_using_table) { + if (prefix.StartsWith (using_ns.Name)) { + int ld = prefix.LastIndexOf ('.'); + if (ld != -1) { + string rest = prefix.Substring (ld + 1); + + all = all.Concat (using_ns.CompletionGetTypesStartingWith (rest)); } - all = all.Concat (using_ns.CompletionGetTypesStartingWith (prefix)); } + all = all.Concat (using_ns.CompletionGetTypesStartingWith (prefix)); } - return all.Distinct ().ToList (); + results.AddRange (all); + + base.GetCompletionStartingWith (prefix, results); } @@ -808,9 +1002,9 @@ namespace Mono.CSharp { // // Looks-up a alias named @name in this and surrounding namespace declarations // - public FullNamedExpression LookupNamespaceAlias (string name) + public override FullNamedExpression LookupNamespaceAlias (string name) { - for (NamespaceContainer n = this; n != null; n = n.parent) { + for (NamespaceContainer n = this; n != null; n = n.Parent) { if (n.aliases == null) continue; @@ -851,6 +1045,13 @@ namespace Mono.CSharp { if (fne != null) return fne; + // + // Lookup can be called before the namespace is defined from different namespace using alias clause + // + if (namespace_using_table == null) { + DoDefineNamespace (); + } + // // Check using entries. // @@ -880,7 +1081,7 @@ namespace Mono.CSharp { } // It can be top level accessibility only - var better = Namespace.IsImportedTypeOverride (module, texpr_match.Type, texpr_fne.Type); + var better = Namespace.IsImportedTypeOverride (Module, texpr_match.Type, texpr_fne.Type); if (better == null) { if (mode == LookupMode.Normal) { Compiler.Report.SymbolRelatedToPreviousError (texpr_match.Type); @@ -899,28 +1100,6 @@ namespace Mono.CSharp { return match; } - public int SymbolFileID { - get { - if (symfile_id == 0 && file.SourceFileEntry != null) { - int parent_id = parent == null ? 0 : parent.SymbolFileID; - - string [] using_list = empty_using_list; - if (clauses != null) { - // TODO: Why is it needed, what to do with aliases - var ul = new List (); - foreach (var c in clauses) { - ul.Add (c.ResolvedExpression.GetSignatureForError ()); - } - - using_list = ul.ToArray (); - } - - symfile_id = SymbolWriter.DefineNamespace (ns.Name, file.CompileUnitEntry, using_list, parent_id); - } - return symfile_id; - } - } - static void MsgtryRef (string s) { Console.WriteLine (" Try using -r:" + s); @@ -959,17 +1138,17 @@ namespace Mono.CSharp { } } - public void Define () + protected override void DefineNamespace () { - if (resolved) - return; + if (namespace_using_table == null) + DoDefineNamespace (); - // FIXME: Because we call Define from bottom not top - if (parent != null) - parent.Define (); + base.DefineNamespace (); + } + void DoDefineNamespace () + { namespace_using_table = empty_namespaces; - resolved = true; if (clauses != null) { var list = new List (clauses.Count); @@ -1031,46 +1210,48 @@ namespace Mono.CSharp { } } - public string GetSignatureForError () + public void EnableUsingClausesRedefinition () { - return ns.GetSignatureForError (); - } - - #region IMemberContext Members - - CompilerContext Compiler { - get { return module.Compiler; } + namespace_using_table = null; } - public TypeSpec CurrentType { - get { return SlaveDeclSpace.CurrentType; } + internal override void GenerateDocComment (DocumentationBuilder builder) + { + if (containers != null) { + foreach (var tc in containers) + tc.GenerateDocComment (builder); + } } - public MemberCore CurrentMemberDefinition { - get { return SlaveDeclSpace.CurrentMemberDefinition; } + public override string GetSignatureForError () + { + return MemberName == null ? "global::" : base.GetSignatureForError (); } - public TypeParameters CurrentTypeParameters { - get { return SlaveDeclSpace.CurrentTypeParameters; } + public override void RemoveContainer (TypeContainer cont) + { + base.RemoveContainer (cont); + NS.RemoveContainer (cont); } - public bool IsObsolete { - get { return false; } - } + protected override bool VerifyClsCompliance () + { + if (Module.IsClsComplianceRequired ()) { + if (MemberName != null && MemberName.Name[0] == '_') { + Warning_IdentifierNotCompliant (); + } - public bool IsUnsafe { - get { return SlaveDeclSpace.IsUnsafe; } - } + ns.VerifyClsCompliance (); + return true; + } - public bool IsStatic { - get { return SlaveDeclSpace.IsStatic; } + return false; } - - public ModuleContainer Module { - get { return module; } + + public override void Accept (StructuralVisitor visitor) + { + visitor.Visit (this); } - - #endregion } public class UsingNamespace @@ -1131,6 +1312,11 @@ namespace Mono.CSharp { } } } + + public virtual void Accept (StructuralVisitor visitor) + { + visitor.Visit (this); + } } public class UsingExternAlias : UsingAliasNamespace @@ -1149,13 +1335,18 @@ namespace Mono.CSharp { Alias.Value); } } + + public override void Accept (StructuralVisitor visitor) + { + visitor.Visit (this); + } } public class UsingAliasNamespace : UsingNamespace { readonly SimpleMemberName alias; - struct AliasContext : IMemberContext + public struct AliasContext : IMemberContext { readonly NamespaceContainer ns; @@ -1226,7 +1417,7 @@ namespace Mono.CSharp { // Only extern aliases are allowed in this context // fne = ns.LookupExternAlias (name); - if (fne != null) + if (fne != null || ns.MemberName == null) return fne; var container_ns = ns.NS.Parent; @@ -1278,5 +1469,10 @@ namespace Mono.CSharp { // resolved = NamespaceExpression.ResolveAsTypeOrNamespace (new AliasContext (ctx)); } + + public override void Accept (StructuralVisitor visitor) + { + visitor.Visit (this); + } } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/nullable.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/nullable.cs index c2cdd700ea..1e46767cf1 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/nullable.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/nullable.cs @@ -494,7 +494,7 @@ namespace Mono.CSharp.Nullable ec.MarkLabel (end_label); } - Expression LiftExpression (ResolveContext ec, Expression expr) + static Expression LiftExpression (ResolveContext ec, Expression expr) { var lifted_type = new NullableType (expr.Type, expr.Location); if (lifted_type.ResolveAsType (ec) == null) @@ -860,7 +860,7 @@ namespace Mono.CSharp.Nullable if (lifted_type == null) return null; - if (left is UserCast || left is TypeCast) + if (left is UserCast || left is EmptyCast || left is OpcodeCast) left.Type = lifted_type; else left = EmptyCast.Create (left, lifted_type); @@ -875,7 +875,7 @@ namespace Mono.CSharp.Nullable if (r is ReducedExpression) r = ((ReducedExpression) r).OriginalExpression; - if (r is UserCast || r is TypeCast) + if (r is UserCast || r is EmptyCast || r is OpcodeCast) r.Type = lifted_type; else right = EmptyCast.Create (right, lifted_type); diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/parameter.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/parameter.cs index 0a5590703e..365f876f0a 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/parameter.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/parameter.cs @@ -209,21 +209,23 @@ namespace Mono.CSharp { [Flags] public enum Modifier : byte { NONE = 0, - REF = REFMASK | ISBYREF, - OUT = OUTMASK | ISBYREF, - PARAMS = 4, - // This is a flag which says that it's either REF or OUT. - ISBYREF = 8, - REFMASK = 32, - OUTMASK = 64, - SignatureMask = REFMASK | OUTMASK, - This = 128 + PARAMS = 1 << 0, + REF = 1 << 1, + OUT = 1 << 2, + This = 1 << 3, + CallerMemberName = 1 << 4, + CallerLineNumber = 1 << 5, + CallerFilePath = 1 << 6, + + RefOutMask = REF | OUT, + ModifierMask = PARAMS | REF | OUT | This, + CallerMask = CallerMemberName | CallerLineNumber | CallerFilePath } static readonly string[] attribute_targets = new string[] { "param" }; FullNamedExpression texpr; - readonly Modifier modFlags; + Modifier modFlags; string name; Expression default_expr; protected TypeSpec parameter_type; @@ -233,7 +235,7 @@ namespace Mono.CSharp { TemporaryVariableReference expr_tree_variable; - HoistedVariable hoisted_variant; + HoistedParameter hoisted_variant; public Parameter (FullNamedExpression type, string name, Modifier mod, Attributes attrs, Location loc) { @@ -323,7 +325,7 @@ namespace Mono.CSharp { return; } - if (a.Type == pa.Out && (ModFlags & Modifier.REF) == Modifier.REF && + if (a.Type == pa.Out && (ModFlags & Modifier.REF) != 0 && !OptAttributes.Contains (pa.In)) { a.Report.Error (662, a.Location, "Cannot specify only `Out' attribute on a ref parameter. Use both `In' and `Out' attributes or neither"); @@ -332,9 +334,7 @@ namespace Mono.CSharp { if (a.Type == pa.CLSCompliant) { a.Report.Warning (3022, 1, a.Location, "CLSCompliant attribute has no meaning when applied to parameters. Try putting it on the method instead"); - } - - if (a.Type == pa.DefaultParameterValue || a.Type == pa.OptionalParameter) { + } else if (a.Type == pa.DefaultParameterValue || a.Type == pa.OptionalParameter) { if (HasOptionalExpression) { a.Report.Error (1745, a.Location, "Cannot specify `{0}' attribute on optional parameter `{1}'", @@ -343,6 +343,21 @@ namespace Mono.CSharp { if (a.Type == pa.DefaultParameterValue) return; + } else if (a.Type == pa.CallerMemberNameAttribute) { + if ((modFlags & Modifier.CallerMemberName) == 0) { + a.Report.Error (4022, a.Location, + "The CallerMemberName attribute can only be applied to parameters with default value"); + } + } else if (a.Type == pa.CallerLineNumberAttribute) { + if ((modFlags & Modifier.CallerLineNumber) == 0) { + a.Report.Error (4020, a.Location, + "The CallerLineNumber attribute can only be applied to parameters with default value"); + } + } else if (a.Type == pa.CallerFilePathAttribute) { + if ((modFlags & Modifier.CallerFilePath) == 0) { + a.Report.Error (4021, a.Location, + "The CallerFilePath attribute can only be applied to parameters with default value"); + } } base.ApplyAttributeBuilder (a, ctor, cdata, pa); @@ -372,15 +387,15 @@ namespace Mono.CSharp { return null; this.idx = index; - - if ((modFlags & Parameter.Modifier.ISBYREF) != 0 && parameter_type.IsSpecialRuntimeType) { + + if ((modFlags & Parameter.Modifier.RefOutMask) != 0 && parameter_type.IsSpecialRuntimeType) { rc.Module.Compiler.Report.Error (1601, Location, "Method or delegate parameter cannot be of type `{0}'", GetSignatureForError ()); return null; } TypeManager.CheckTypeVariance (parameter_type, - (modFlags & Parameter.Modifier.ISBYREF) != 0 ? Variance.None : Variance.Contravariant, + (modFlags & Parameter.Modifier.RefOutMask) != 0 ? Variance.None : Variance.Contravariant, rc); if (parameter_type.IsStatic) { @@ -397,6 +412,54 @@ namespace Mono.CSharp { return parameter_type; } + void ResolveCallerAttributes (ResolveContext rc) + { + var pa = rc.Module.PredefinedAttributes; + TypeSpec caller_type; + + foreach (var attr in attributes.Attrs) { + var atype = attr.ResolveType (); + if (atype == null) + continue; + + if (atype == pa.CallerMemberNameAttribute) { + caller_type = rc.BuiltinTypes.String; + if (caller_type != parameter_type && !Convert.ImplicitReferenceConversionExists (caller_type, parameter_type)) { + rc.Report.Error (4019, attr.Location, + "The CallerMemberName attribute cannot be applied because there is no standard conversion from `{0}' to `{1}'", + caller_type.GetSignatureForError (), parameter_type.GetSignatureForError ()); + } + + modFlags |= Modifier.CallerMemberName; + continue; + } + + if (atype == pa.CallerLineNumberAttribute) { + caller_type = rc.BuiltinTypes.Int; + if (caller_type != parameter_type && !Convert.ImplicitNumericConversionExists (caller_type, parameter_type)) { + rc.Report.Error (4017, attr.Location, + "The CallerMemberName attribute cannot be applied because there is no standard conversion from `{0}' to `{1}'", + caller_type.GetSignatureForError (), parameter_type.GetSignatureForError ()); + } + + modFlags |= Modifier.CallerLineNumber; + continue; + } + + if (atype == pa.CallerFilePathAttribute) { + caller_type = rc.BuiltinTypes.String; + if (caller_type != parameter_type && !Convert.ImplicitReferenceConversionExists (caller_type, parameter_type)) { + rc.Report.Error (4018, attr.Location, + "The CallerFilePath attribute cannot be applied because there is no standard conversion from `{0}' to `{1}'", + caller_type.GetSignatureForError (), parameter_type.GetSignatureForError ()); + } + + modFlags |= Modifier.CallerFilePath; + continue; + } + } + } + public void ResolveDefaultValue (ResolveContext rc) { // @@ -404,14 +467,17 @@ namespace Mono.CSharp { // if (default_expr != null) { ((DefaultParameterValueExpression)default_expr).Resolve (rc, this); + if (attributes != null) + ResolveCallerAttributes (rc); + return; } if (attributes == null) return; - - var opt_attr = attributes.Search (rc.Module.PredefinedAttributes.OptionalParameter); - var def_attr = attributes.Search (rc.Module.PredefinedAttributes.DefaultParameterValue); + + var pa = rc.Module.PredefinedAttributes; + var def_attr = attributes.Search (pa.DefaultParameterValue); if (def_attr != null) { if (def_attr.Resolve () == null) return; @@ -466,6 +532,7 @@ namespace Mono.CSharp { return; } + var opt_attr = attributes.Search (pa.OptionalParameter); if (opt_attr != null) { default_expr = EmptyExpression.MissingValue; } @@ -482,7 +549,7 @@ namespace Mono.CSharp { // // Hoisted parameter variant // - public HoistedVariable HoistedVariant { + public HoistedParameter HoistedVariant { get { return hoisted_variant; } @@ -611,7 +678,7 @@ namespace Mono.CSharp { public ExpressionStatement CreateExpressionTreeVariable (BlockContext ec) { - if ((modFlags & Modifier.ISBYREF) != 0) + if ((modFlags & Modifier.RefOutMask) != 0) ec.Report.Error (1951, Location, "An expression tree parameter cannot use `ref' or `out' modifier"); expr_tree_variable = TemporaryVariableReference.Create (ResolveParameterExpressionType (ec, Location).Type, ec.CurrentBlock.ParametersBlock, Location); @@ -636,7 +703,7 @@ namespace Mono.CSharp { public void EmitAddressOf (EmitContext ec) { - if ((ModFlags & Modifier.ISBYREF) != 0) { + if ((ModFlags & Modifier.RefOutMask) != 0) { ec.EmitArgumentLoad (idx); } else { ec.EmitArgumentAddress (idx); @@ -701,7 +768,7 @@ namespace Mono.CSharp { } public Parameter.Modifier ModFlags { - get { return modifiers & ~Parameter.Modifier.This; } + get { return modifiers; } } public string Name { @@ -750,7 +817,7 @@ namespace Mono.CSharp { public static ParameterAttributes GetParameterAttribute (Parameter.Modifier modFlags) { - return (modFlags & Parameter.Modifier.OUT) == Parameter.Modifier.OUT ? + return (modFlags & Parameter.Modifier.OUT) != 0 ? ParameterAttributes.Out : ParameterAttributes.None; } @@ -773,7 +840,7 @@ namespace Mono.CSharp { for (int i = 0; i < types.Length; ++i) { types[i] = Types[i].GetMetaInfo (); - if ((FixedParameters [i].ModFlags & Parameter.Modifier.ISBYREF) == 0) + if ((FixedParameters[i].ModFlags & Parameter.Modifier.RefOutMask) == 0) continue; // TODO MemberCache: Should go to MetaInfo getter @@ -808,7 +875,7 @@ namespace Mono.CSharp { sb.Append (types [i].GetSignatureForDocumentation ()); - if ((parameters[i].ModFlags & Parameter.Modifier.ISBYREF) != 0) + if ((parameters[i].ModFlags & Parameter.Modifier.RefOutMask) != 0) sb.Append ("@"); } sb.Append (")"); @@ -1027,8 +1094,7 @@ namespace Mono.CSharp { var a_type = a.Types[i]; var b_type = b.Types[i]; if (TypeSpecComparer.Override.IsEqual (a_type, b_type)) { - const Parameter.Modifier ref_out = Parameter.Modifier.REF | Parameter.Modifier.OUT; - if ((a.FixedParameters[i].ModFlags & ref_out) != (b.FixedParameters[i].ModFlags & ref_out)) + if ((a.FixedParameters[i].ModFlags & Parameter.Modifier.RefOutMask) != (b.FixedParameters[i].ModFlags & Parameter.Modifier.RefOutMask)) res |= 1; continue; @@ -1193,7 +1259,7 @@ namespace Mono.CSharp { // Each parameter expression is stored to local variable // to save some memory when referenced later. // - StatementExpression se = new StatementExpression (p.CreateExpressionTreeVariable (ec)); + StatementExpression se = new StatementExpression (p.CreateExpressionTreeVariable (ec), Location.Null); if (se.Resolve (ec)) { ec.CurrentBlock.AddScopeStatement (new TemporaryVariableReference.Declarator (p.ExpressionTreeVariableReference ())); ec.CurrentBlock.AddScopeStatement (se); diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/pending.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/pending.cs index b7403eda8e..b331286293 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/pending.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/pending.cs @@ -129,7 +129,7 @@ namespace Mono.CSharp { /// /// The container for this PendingImplementation /// - readonly TypeContainer container; + readonly TypeDefinition container; /// /// This is the array of TypeAndMethods that describes the pending implementations @@ -137,7 +137,7 @@ namespace Mono.CSharp { /// TypeAndMethods [] pending_implementations; - PendingImplementation (TypeContainer container, MissingInterfacesInfo[] missing_ifaces, MethodSpec[] abstract_methods, int total) + PendingImplementation (TypeDefinition container, MissingInterfacesInfo[] missing_ifaces, MethodSpec[] abstract_methods, int total) { var type_builder = container.Definition; @@ -189,7 +189,7 @@ namespace Mono.CSharp { static readonly MissingInterfacesInfo [] EmptyMissingInterfacesInfo = new MissingInterfacesInfo [0]; - static MissingInterfacesInfo [] GetMissingInterfaces (TypeContainer container) + static MissingInterfacesInfo [] GetMissingInterfaces (TypeDefinition container) { // // Notice that Interfaces will only return the interfaces that the Type @@ -233,7 +233,7 @@ namespace Mono.CSharp { // Register method implementations are either abstract methods // flagged as such on the base class or interface methods // - static public PendingImplementation GetPendingImplementations (TypeContainer container) + static public PendingImplementation GetPendingImplementations (TypeDefinition container) { TypeSpec b = container.BaseType; @@ -305,11 +305,10 @@ namespace Mono.CSharp { // // First check exact modifiers match // - const Parameter.Modifier ref_out = Parameter.Modifier.REF | Parameter.Modifier.OUT; - if ((cp[pi].ModFlags & ref_out) == (tp[pi].ModFlags & ref_out)) + if ((cp[pi].ModFlags & Parameter.Modifier.RefOutMask) == (tp[pi].ModFlags & Parameter.Modifier.RefOutMask)) continue; - if ((cp[pi].ModFlags & tp[pi].ModFlags & Parameter.Modifier.ISBYREF) != 0) { + if (((cp[pi].ModFlags | tp[pi].ModFlags) & Parameter.Modifier.RefOutMask) == Parameter.Modifier.RefOutMask) { ref_only_difference = true; continue; } @@ -508,7 +507,7 @@ namespace Mono.CSharp { } int top = param.Count; - var ec = new EmitContext (new ProxyMethodContext (container), proxy.GetILGenerator (), null); + var ec = new EmitContext (new ProxyMethodContext (container), proxy.GetILGenerator (), null, null); ec.EmitThis (); // TODO: GetAllParametersArguments for (int i = 0; i < top; i++) @@ -557,8 +556,7 @@ namespace Mono.CSharp { // // First check exact ref/out match // - const Parameter.Modifier ref_out = Parameter.Modifier.REF | Parameter.Modifier.OUT; - if ((parameters.FixedParameters[i].ModFlags & ref_out) == (candidate_param.FixedParameters[i].ModFlags & ref_out)) + if ((parameters.FixedParameters[i].ModFlags & Parameter.Modifier.RefOutMask) == (candidate_param.FixedParameters[i].ModFlags & Parameter.Modifier.RefOutMask)) continue; modifiers_match = false; @@ -566,7 +564,7 @@ namespace Mono.CSharp { // // Different in ref/out only // - if ((parameters.FixedParameters[i].ModFlags & candidate_param.FixedParameters[i].ModFlags & Parameter.Modifier.ISBYREF) != 0) { + if ((parameters.FixedParameters[i].ModFlags & Parameter.Modifier.RefOutMask) != (candidate_param.FixedParameters[i].ModFlags & Parameter.Modifier.RefOutMask)) { if (similar_candidate == null) { if (!candidate.IsPublic) break; diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/property.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/property.cs index 3093e061dd..c72840cceb 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/property.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/property.cs @@ -15,6 +15,7 @@ using System; using System.Collections.Generic; using System.Text; +using Mono.CompilerServices.SymbolWriter; #if NET_2_1 using XmlElement = System.Object; @@ -34,7 +35,7 @@ namespace Mono.CSharp // This includes properties, indexers, and events public abstract class PropertyBasedMember : InterfaceMemberBase { - public PropertyBasedMember (TypeContainer parent, FullNamedExpression type, Modifiers mod, Modifiers allowed_mod, MemberName name, Attributes attrs) + public PropertyBasedMember (TypeDefinition parent, FullNamedExpression type, Modifiers mod, Modifiers allowed_mod, MemberName name, Attributes attrs) : base (parent, type, mod, allowed_mod, name, attrs) { } @@ -335,7 +336,7 @@ namespace Mono.CSharp public virtual MethodBuilder Define (TypeContainer parent) { - TypeContainer container = parent.PartialContainer; + var container = parent.PartialContainer; // // Check for custom access modifier @@ -402,7 +403,7 @@ namespace Mono.CSharp PropertyMethod get, set, first; PropertyBuilder PropertyBuilder; - public PropertyBase (TypeContainer parent, FullNamedExpression type, Modifiers mod_flags, Modifiers allowed_mod, MemberName name, Attributes attrs) + public PropertyBase (TypeDefinition parent, FullNamedExpression type, Modifiers mod_flags, Modifiers allowed_mod, MemberName name, Attributes attrs) : base (parent, type, mod_flags, allowed_mod, name, attrs) { } @@ -445,7 +446,7 @@ namespace Mono.CSharp if (first == null) first = value; - Parent.AddMember (get); + Parent.AddNameToContainer (get, get.MemberName.Basename); } } @@ -458,7 +459,7 @@ namespace Mono.CSharp if (first == null) first = value; - Parent.AddMember (set); + Parent.AddNameToContainer (set, set.MemberName.Basename); } } @@ -686,6 +687,15 @@ namespace Mono.CSharp Set.UpdateName (this); } + public override void WriteDebugSymbol (MonoSymbolFile file) + { + if (get != null) + get.WriteDebugSymbol (file); + + if (set != null) + set.WriteDebugSymbol (file); + } + // // Represents header string for documentation comment. // @@ -720,7 +730,7 @@ namespace Mono.CSharp } } - public Property (TypeContainer parent, FullNamedExpression type, Modifiers mod, + public Property (TypeDefinition parent, FullNamedExpression type, Modifiers mod, MemberName name, Attributes attrs) : base (parent, type, mod, parent.PartialContainer.Kind == MemberKind.Interface ? AllowedModifiersInterface : @@ -743,21 +753,25 @@ namespace Mono.CSharp if (!field.Define ()) return; - Parent.PartialContainer.AddField (field); + Parent.PartialContainer.Members.Add (field); FieldExpr fe = new FieldExpr (field, Location); if ((field.ModFlags & Modifiers.STATIC) == 0) fe.InstanceExpression = new CompilerGeneratedThis (Parent.CurrentType, Location); - // Create get block - Get.Block = new ToplevelBlock (Compiler, ParametersCompiled.EmptyReadOnlyParameters, Location); - Return r = new Return (fe, Location); + // + // Create get block but we careful with location to + // emit only single sequence point per accessor. This allow + // to set a breakpoint on it even with no user code + // + Get.Block = new ToplevelBlock (Compiler, ParametersCompiled.EmptyReadOnlyParameters, Location.Null); + Return r = new Return (fe, Get.Location); Get.Block.AddStatement (r); // Create set block - Set.Block = new ToplevelBlock (Compiler, Set.ParameterInfo, Location); - Assign a = new SimpleAssign (fe, new SimpleName ("value", Location)); - Set.Block.AddStatement (new StatementExpression (a)); + Set.Block = new ToplevelBlock (Compiler, Set.ParameterInfo, Location.Null); + Assign a = new SimpleAssign (fe, new SimpleName ("value", Location.Null), Location.Null); + Set.Block.AddStatement (new StatementExpression (a, Set.Location)); } public override bool Define () @@ -787,7 +801,7 @@ namespace Mono.CSharp else pm = new GetMethod (this, 0, null, Location); - Parent.AddMember (pm); + Parent.AddNameToContainer (pm, pm.MemberName.Basename); } if (!CheckBase ()) @@ -850,7 +864,7 @@ namespace Mono.CSharp static readonly string[] attribute_targets = new string [] { "event" }; - public EventProperty (TypeContainer parent, FullNamedExpression type, Modifiers mod_flags, MemberName name, Attributes attrs) + public EventProperty (TypeDefinition parent, FullNamedExpression type, Modifiers mod_flags, MemberName name, Attributes attrs) : base (parent, type, mod_flags, name, attrs) { } @@ -890,10 +904,12 @@ namespace Mono.CSharp protected abstract MethodSpec GetOperation (Location loc); - public override void Emit (TypeContainer parent) + public override void Emit (TypeDefinition parent) { if ((method.ModFlags & (Modifiers.ABSTRACT | Modifiers.EXTERN)) == 0) { - block = new ToplevelBlock (Compiler, ParameterInfo, Location); + block = new ToplevelBlock (Compiler, ParameterInfo, Location) { + IsCompilerGenerated = true + }; FabricateBodyStatement (); } @@ -989,7 +1005,7 @@ namespace Mono.CSharp Field backing_field; List declarators; - public EventField (TypeContainer parent, FullNamedExpression type, Modifiers mod_flags, MemberName name, Attributes attrs) + public EventField (TypeDefinition parent, FullNamedExpression type, Modifiers mod_flags, MemberName name, Attributes attrs) : base (parent, type, mod_flags, name, attrs) { Add = new AddDelegateMethod (this); @@ -1040,8 +1056,7 @@ namespace Mono.CSharp declarators.Add (declarator); - // TODO: This will probably break - Parent.AddMember (this, declarator.Name.Value); + Parent.AddNameToContainer (this, declarator.Name.Value); } public override void ApplyAttributeBuilder (Attribute a, MethodSpec ctor, byte[] cdata, PredefinedAttributes pa) @@ -1074,14 +1089,14 @@ namespace Mono.CSharp mod_flags_src &= ~(Modifiers.AccessibilityMask | Modifiers.DEFAULT_ACCESS_MODIFER); var t = new TypeExpression (MemberType, TypeExpression.Location); - int index = Parent.PartialContainer.Events.IndexOf (this); foreach (var d in declarators) { var ef = new EventField (Parent, t, mod_flags_src, new MemberName (d.Name.Value, d.Name.Location), OptAttributes); if (d.Initializer != null) ef.initializer = d.Initializer; - Parent.PartialContainer.Events.Insert (++index, ef); + ef.Define (); + Parent.PartialContainer.Members.Add (ef); } } @@ -1098,7 +1113,7 @@ namespace Mono.CSharp Modifiers.BACKING_FIELD | Modifiers.COMPILER_GENERATED | Modifiers.PRIVATE | (ModFlags & (Modifiers.STATIC | Modifiers.UNSAFE)), MemberName, null); - Parent.PartialContainer.AddField (backing_field); + Parent.PartialContainer.Members.Add (backing_field); backing_field.Initializer = Initializer; backing_field.ModFlags &= ~Modifiers.COMPILER_GENERATED; @@ -1215,7 +1230,7 @@ namespace Mono.CSharp EventBuilder EventBuilder; protected EventSpec spec; - protected Event (TypeContainer parent, FullNamedExpression type, Modifiers mod_flags, MemberName name, Attributes attrs) + protected Event (TypeDefinition parent, FullNamedExpression type, Modifiers mod_flags, MemberName name, Attributes attrs) : base (parent, type, mod_flags, parent.PartialContainer.Kind == MemberKind.Interface ? AllowedModifiersInterface : parent.PartialContainer.Kind == MemberKind.Struct ? AllowedModifiersStruct : @@ -1238,7 +1253,7 @@ namespace Mono.CSharp } set { add = value; - Parent.AddMember (value); + Parent.AddNameToContainer (value, value.MemberName.Basename); } } @@ -1254,7 +1269,7 @@ namespace Mono.CSharp } set { remove = value; - Parent.AddMember (value); + Parent.AddNameToContainer (value, value.MemberName.Basename); } } #endregion @@ -1334,6 +1349,12 @@ namespace Mono.CSharp base.Emit (); } + public override void WriteDebugSymbol (MonoSymbolFile file) + { + add.WriteDebugSymbol (file); + remove.WriteDebugSymbol (file); + } + // // Represents header string for documentation comment. // @@ -1488,7 +1509,7 @@ namespace Mono.CSharp readonly ParametersCompiled parameters; - public Indexer (TypeContainer parent, FullNamedExpression type, MemberName name, Modifiers mod, ParametersCompiled parameters, Attributes attrs) + public Indexer (TypeDefinition parent, FullNamedExpression type, MemberName name, Modifiers mod, ParametersCompiled parameters, Attributes attrs) : base (parent, type, mod, parent.PartialContainer.Kind == MemberKind.Interface ? AllowedInterfaceModifiers : AllowedModifiers, name, attrs) @@ -1572,8 +1593,7 @@ namespace Mono.CSharp } } - if (!Parent.PartialContainer.AddMember (this)) - return false; + Parent.AddNameToContainer (this, MemberName.Basename); flags |= MethodAttributes.HideBySig | MethodAttributes.SpecialName; diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/reflection.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/reflection.cs index 5181e3f325..2de023c18f 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/reflection.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/reflection.cs @@ -166,8 +166,11 @@ namespace Mono.CSharp { [System.Runtime.InteropServices.FieldOffset (0)] int i; + +#pragma warning disable 414 [System.Runtime.InteropServices.FieldOffset (0)] float f; +#pragma warning restore 414 public static int SingleToInt32Bits (float v) { diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/repl.txt b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/repl.txt deleted file mode 100644 index 4f71772f6c..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/repl.txt +++ /dev/null @@ -1,168 +0,0 @@ -Things to do for the REPL support in MCS: - -Documentation for the REPL mode for MCS can be found here: - - http://mono-project.com/CsharpRepl - -* Embedding API - - * Booting the compiler without Main () - * Expose LoadAssembly/LoadPackage - * Register fields? - * Register a lookup function for fields? - * Register classes to expose to REPL - -* Embedded Library - - * Run a REPL on a socket (from Joe Shaw) - * Host a REPL on XSP (from Nat). - -* TODO - - Clear struct fields inside the clearing code. - -* Other ideas: - - MD addin for "csharp" - -* Supporting class-level declarations - - Currently the evaluator has this feature disabled, to enable - it edit the eval.cs file and make this be the default: - -- parser.Lexer.putback_char = Tokenizer.EvalUsingDeclarationsParserCharacter; -- //parser.Lexer.putback_char = Tokenizer.EvalCompilationUnitParserCharacter; -+ //parser.Lexer.putback_char = Tokenizer.EvalUsingDeclarationsParserCharacter; -+ parser.Lexer.putback_char = Tokenizer.EvalCompilationUnitParserCharacter; - - - It currently has a few problems: - - * Support for overwritting existing defined - classes is not supported. - - * The usability is not as useful, since the defaults - for C# are still to make members private, we should - change this default to be public in those cases. - - * The error lookup system lacks information from types, for - example this causes an unsupported call into a TypeBuilder: - - csharp>class D { void DD () {} } - csharp>var d = new D (); - csharp>d.DD (); - - Internal compiler error at Internal(1,1):: exception caught while emitting MethodBuilder [Class0::Host] - System.NotSupportedException: The invoked member is not supported in a dynamic module. - at System.Reflection.Emit.AssemblyBuilder.get_Location () [0x00000] in :0 - at Mono.CSharp.Report.SymbolRelatedToPreviousError (System.Reflection.MemberInfo mi) [0x00000] in - at Mono.CSharp.MethodGroupExpr.NoExactMatch (Mono.CSharp.ResolveContext ec, - Mono.CSharp.Arguments& Arguments, IDictionary`2 c - - - The above is caused by TypeManager.LookupDeclSpace (dt) - failing to return a value (it returns null) so our code - assumes we have an Assembly instead of an assemblybuilder. - - - -* Declaring a class twice produces an internal parse error: - - class X {} - class X {} - - The second declaration will no longer be parsed, so it could even - contain junk, and wont be flagged. We probably need to allow for - type redefinition in REPL modes, the exception from the second is: - - csharp -v -v - > class X {} - > class X {} - - System.ArgumentException: An element with the same key already exists in the dictionary. - at System.Collections.Generic.Dictionary`2[System.String,Mono.CSharp.DeclSpace].Add (System.String key, Mono.CSharp.DeclSpace value) [0x00000] in :0 - at Mono.CSharp.Namespace.AddDeclSpace (System.String name, Mono.CSharp.DeclSpace ds) [0x00000] in :0 - at Mono.CSharp.ModuleCompiled.AddMemberType (Mono.CSharp.DeclSpace ds) [0x00000] in :0 - at Mono.CSharp.TypeContainer.AddTypeContainer (Mono.CSharp.TypeContainer tc) [0x00000] in :0 - at Mono.CSharp.CSharpParser.push_current_class (Mono.CSharp.TypeContainer tc, System.Object partial_token) [0x00000] in :0 - at Mono.CSharp.CSharpParser.yyparse (yyInput yyLex) [0x00000] in :0 - at Mono.CSharp.CSharpParser.yyparse (yyInput yyLex, System.Object yyd) [0x00000] in :0 - at Mono.CSharp.CSharpParser.parse () [0x00000] in :0 - -* Mix statements with other top-level declarations. - -csharp> class Y {static void Main () {Console.WriteLine ("Foo"); }} -csharp> typeof (Y); -Y -csharp> Y.Main (); -Exception caught by the compiler while compiling: - Block that caused the problem begin at: Internal(1,1): - Block being compiled: [(1,2):,(1,11):] -System.NotSupportedException: The invoked member is not supported in a dynamic module. -Internal compiler error at Internal(1,1):: exception caught while emitting MethodBuilder [Class2::Host] -System.NotSupportedException: The invoked member is not supported in a dynamic module. - at System.Reflection.Emit.AssemblyBuilder.get_Location () [0x00000] in /second/home/cvs/mcs/class/corlib/System.Reflection.Emit/AssemblyBuilder.cs:214 - at Mono.CSharp.Report.SymbolRelatedToPreviousError (System.Reflection.MemberInfo mi) [0x00036] in /second/home/cvs/mcs/mcs/report.cs:664 - at Mono.CSharp.Expression.Error_MemberLookupFailed (System.Type container_type, System.Type qualifier_type, System.Type queried_type, System.String name, System.String class_name, MemberTypes mt, BindingFlags bf) [0x00121] in /second/home/cvs/mcs/mcs/ecore.cs:857 - at Mono.CSharp.MemberAccess.DoResolve (Mono.CSharp.EmitContext ec, Mono.CSharp.Expression right_side) [0x00230] in /second/home/cvs/mcs/mcs/expression.cs:7426 - at Mono.CSharp.MemberAccess.DoResolve (Mono.CSharp.EmitContext ec) [0x00000] in /second/home/cvs/mcs/mcs/expression.cs:7494 - at Mono.CSharp.Expression.Resolve (Mono.CSharp.EmitContext ec, ResolveFlags flags) [0x00075] in /second/home/cvs/mcs/mcs/ecore.cs:479 - at Mono.CSharp.Invocation.DoResolve (Mono.CSharp.EmitContext ec) [0x0000d] in /second/home/cvs/mcs/mcs/expression.cs:4725 - at Mono.CSharp.Expression.Resolve (Mono.CSharp.EmitContext ec, ResolveFlags flags) [0x00075] in /second/home/cvs/mcs/mcs/ecore.cs:479 - at Mono.CSharp.Expression.Resolve (Mono.CSharp.EmitContext ec) [0x00000] in /second/home/cvs/mcs/mcs/ecore.cs:506 - at Mono.CSharp.OptionalAssign.DoResolve (Mono.CSharp.EmitContext ec) [0x00013] in /second/home/cvs/mcs/mcs/repl.cs:681 - at Mono.CSharp.Expression.Resolve (Mono.CSharp.EmitContext ec, ResolveFlags flags) [0x00075] in /second/home/cvs/mcs/mcs/ecore.cs:479 - at Mono.CSharp.Expression.Resolve (Mono.CSharp.EmitContext ec) [0x00000] in /second/home/cvs/mcs/mcs/ecore.cs:506 - at Mono.CSharp.ExpressionStatement.ResolveStatement (Mono.CSharp.EmitContext ec) [0x00000] in /second/home/cvs/mcs/mcs/ecore.cs:1307 - at Mono.CSharp.StatementExpression.Resolve (Mono.CSharp.EmitContext ec) [0x0000b] in /second/home/cvs/mcs/mcs/statement.cs:743 - at Mono.CSharp.Block.Resolve (Mono.CSharp.EmitContext ec) [0x000f0] in /second/home/cvs/mcs/mcs/statement.cs:2254 - at Mono.CSharp.ExplicitBlock.Resolve (Mono.CSharp.EmitContext ec) [0x00000] in /second/home/cvs/mcs/mcs/statement.cs:2550 - at Mono.CSharp.EmitContext.ResolveTopBlock (Mono.CSharp.EmitContext anonymous_method_host, Mono.CSharp.ToplevelBlock block, Mono.CSharp.Parameters ip, IMethodData md, System.Boolean& unreachable) [0x00087] in /second/home/cvs/mcs/mcs/codegen.cs:796 -csharp> - -* Another one: - -csharp> class X { X (){ Console.WriteLine ("Called"); } } -csharp> new X (); -Exception caught by the compiler while compiling: - Block that caused the problem begin at: Internal(1,1): - Block being compiled: [(1,2):,(1,10):] -System.NotSupportedException: The invoked member is not supported in a dynamic module. -Internal compiler error at Internal(1,1):: exception caught while emitting MethodBuilder [Class0::Host] -System.NotSupportedException: The invoked member is not supported in a dynamic module. - at System.Reflection.Emit.AssemblyBuilder.get_Location () [0x00000] in /second/home/cvs/mcs/class/corlib/System.Reflection.Emit/AssemblyBuilder.cs:214 - at Mono.CSharp.Report.SymbolRelatedToPreviousError (System.Reflection.MemberInfo mi) [0x00036] in /second/home/cvs/mcs/mcs/report.cs:664 - at Mono.CSharp.Expression.Error_MemberLookupFailed (System.Type container_type, System.Type qualifier_type, System.Type queried_type, System.String name, System.String class_name, MemberTypes mt, BindingFlags bf) [0x00121] in /second/home/cvs/mcs/mcs/ecore.cs:857 - at Mono.CSharp.Expression.MemberLookupFinal (Mono.CSharp.EmitContext ec, System.Type qualifier_type, System.Type queried_type, System.String name, MemberTypes mt, BindingFlags bf, Location loc) [0x0002f] in /second/home/cvs/mcs/mcs/ecore.cs:804 - at Mono.CSharp.New.DoResolve (Mono.CSharp.EmitContext ec) [0x002ad] in /second/home/cvs/mcs/mcs/expression.cs:5486 - at Mono.CSharp.Expression.Resolve (Mono.CSharp.EmitContext ec, ResolveFlags flags) [0x00075] in /second/home/cvs/mcs/mcs/ecore.cs:479 - at Mono.CSharp.Expression.Resolve (Mono.CSharp.EmitContext ec) [0x00000] in /second/home/cvs/mcs/mcs/ecore.cs:506 - at Mono.CSharp.OptionalAssign.DoResolve (Mono.CSharp.EmitContext ec) [0x00013] in /second/home/cvs/mcs/mcs/repl.cs:687 - at Mono.CSharp.Expression.Resolve (Mono.CSharp.EmitContext ec, ResolveFlags flags) [0x00075] in /second/home/cvs/mcs/mcs/ecore.cs:479 - at Mono.CSharp.Expression.Resolve (Mono.CSharp.EmitContext ec) [0x00000] in /second/home/cvs/mcs/mcs/ecore.cs:506 - at Mono.CSharp.ExpressionStatement.ResolveStatement (Mono.CSharp.EmitContext ec) [0x00000] in /second/home/cvs/mcs/mcs/ecore.cs:1307 - at Mono.CSharp.StatementExpression.Resolve (Mono.CSharp.EmitContext ec) [0x0000b] in /second/home/cvs/mcs/mcs/statement.cs:743 - at Mono.CSharp.Block.Resolve (Mono.CSharp.EmitContext ec) [0x000f0] in /second/home/cvs/mcs/mcs/statement.cs:2254 - at Mono.CSharp.ExplicitBlock.Resolve (Mono.CSharp.EmitContext ec) [0x00000] in /second/home/cvs/mcs/mcs/statement.cs:2550 - at Mono.CSharp.EmitContext.ResolveTopBlock (Mono.CSharp.EmitContext anonymous_method_host, Mono.CSharp.ToplevelBlock block, Mono.CSharp.Parameters ip, IMethodData md, System.Boolean& unreachable) [0x00087] in /second/home/cvs/mcs/mcs/codegen.cs:796 -csharp> - -* Important: we need to replace TypeBuidlers with Types after things - have been emitted, or stuff like this happens: - -csharp> public class y {} -csharp> typeof (y); -Class1 - - -* Clearing data - - TODO: when clearing data for variables that have been overwritten - we need to check for structs and clear all the fields that contain - reference types. - -* DEBATABLE: Implement auto-insert-semicolon - - This is easy to implement, just retry the parse with a - semicolon, the question is whether this is a good idea to do - in the first place or not. diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/report.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/report.cs index 81561a5cb9..50d78f0071 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/report.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/report.cs @@ -21,27 +21,15 @@ namespace Mono.CSharp { // public class Report { - /// - /// Whether warnings should be considered errors - /// - public bool WarningsAreErrors; - List warnings_as_error; - List warnings_only; - public const int RuntimeErrorId = 10000; - // - // Keeps track of the warnings that we are ignoring - // - HashSet warning_ignore_table; - Dictionary warning_regions_table; - int warning_level; - ReportPrinter printer; int reporting_disabled; + + readonly CompilerSettings settings; /// /// List of symbols related to reported error/warning. You have to fill it before error/warning is reported. @@ -67,18 +55,21 @@ namespace Mono.CSharp { 2002, 2023, 2029, 3000, 3001, 3002, 3003, 3005, 3006, 3007, 3008, 3009, 3010, 3011, 3012, 3013, 3014, 3015, 3016, 3017, 3018, 3019, - 3021, 3022, 3023, 3024, 3026, 3027 + 3021, 3022, 3023, 3024, 3026, 3027, + 4014 }; static HashSet AllWarningsHashSet; - public Report (ReportPrinter printer) + public Report (CompilerContext context, ReportPrinter printer) { + if (context == null) + throw new ArgumentNullException ("settings"); if (printer == null) throw new ArgumentNullException ("printer"); + this.settings = context.Settings; this.printer = printer; - warning_level = 4; } public void DisableReporting () @@ -125,44 +116,6 @@ namespace Mono.CSharp { "Feature `{0}' is not supported in Mono mcs1 compiler. Consider using the `gmcs' compiler instead", feature); } - - bool IsWarningEnabled (int code, int level, Location loc) - { - if (WarningLevel < level) - return false; - - if (IsWarningDisabledGlobally (code)) - return false; - - if (warning_regions_table == null || loc.IsNull) - return true; - - WarningRegions regions; - if (!warning_regions_table.TryGetValue (loc.File, out regions)) - return true; - - return regions.IsWarningEnabled (code, loc.Row); - } - - public bool IsWarningDisabledGlobally (int code) - { - return warning_ignore_table != null && warning_ignore_table.Contains (code); - } - - bool IsWarningAsError (int code) - { - bool is_error = WarningsAreErrors; - - // Check specific list - if (warnings_as_error != null) - is_error |= warnings_as_error.Contains (code); - - // Ignore excluded warnings - if (warnings_only != null && warnings_only.Contains (code)) - is_error = false; - - return is_error; - } public void RuntimeMissingSupport (Location loc, string feature) { @@ -217,44 +170,6 @@ namespace Mono.CSharp { extra_information.Add (msg); } - public void AddWarningAsError (string warningId) - { - int id; - try { - id = int.Parse (warningId); - } catch { - CheckWarningCode (warningId, Location.Null); - return; - } - - if (!CheckWarningCode (id, Location.Null)) - return; - - if (warnings_as_error == null) - warnings_as_error = new List (); - - warnings_as_error.Add (id); - } - - public void RemoveWarningAsError (string warningId) - { - int id; - try { - id = int.Parse (warningId); - } catch { - CheckWarningCode (warningId, Location.Null); - return; - } - - if (!CheckWarningCode (id, Location.Null)) - return; - - if (warnings_only == null) - warnings_only = new List (); - - warnings_only.Add (id); - } - public bool CheckWarningCode (string code, Location loc) { Warning (1691, 1, loc, "`{0}' is not a valid warning number", code); @@ -300,11 +215,17 @@ namespace Mono.CSharp { if (reporting_disabled > 0) return; - if (!IsWarningEnabled (code, level, loc)) + if (!settings.IsWarningEnabled (code, level)) return; + if (warning_regions_table != null && !loc.IsNull) { + WarningRegions regions; + if (warning_regions_table.TryGetValue (loc.File, out regions) && !regions.IsWarningEnabled (code, loc.Row)) + return; + } + AbstractMessage msg; - if (IsWarningAsError (code)) { + if (settings.IsWarningAsError (code)) { message = "Warning as Error: " + message; msg = new ErrorMessage (code, loc, message, extra_information); } else { @@ -312,7 +233,7 @@ namespace Mono.CSharp { } extra_information.Clear (); - printer.Print (msg); + printer.Print (msg, settings.ShowFullPaths); } public void Warning (int code, int level, Location loc, string format, string arg) @@ -365,7 +286,13 @@ namespace Mono.CSharp { ErrorMessage msg = new ErrorMessage (code, loc, error, extra_information); extra_information.Clear (); - printer.Print (msg); + printer.Print (msg, settings.ShowFullPaths); + + if (settings.Stacktrace) + Console.WriteLine (FriendlyStackTrace (new StackTrace (true))); + + if (printer.ErrorsCount == settings.FatalCounter) + throw new FatalException (msg.Text); } public void Error (int code, Location loc, string format, string arg) @@ -420,14 +347,6 @@ namespace Mono.CSharp { get { return printer; } } - public void SetIgnoreWarning (int code) - { - if (warning_ignore_table == null) - warning_ignore_table = new HashSet (); - - warning_ignore_table.Add (code); - } - public ReportPrinter SetPrinter (ReportPrinter printer) { ReportPrinter old = this.printer; @@ -435,15 +354,6 @@ namespace Mono.CSharp { return old; } - public int WarningLevel { - get { - return warning_level; - } - set { - warning_level = value; - } - } - [Conditional ("MCS_DEBUG")] static public void Debug (string message, params object[] args) { @@ -498,7 +408,42 @@ namespace Mono.CSharp { sb.Append (")"); return sb.ToString (); } -*/ +*/ + static string FriendlyStackTrace (StackTrace t) + { + StringBuilder sb = new StringBuilder (); + + bool foundUserCode = false; + + for (int i = 0; i < t.FrameCount; i++) { + StackFrame f = t.GetFrame (i); + var mb = f.GetMethod (); + + if (!foundUserCode && mb.ReflectedType == typeof (Report)) + continue; + + foundUserCode = true; + + sb.Append ("\tin "); + + if (f.GetFileLineNumber () > 0) + sb.AppendFormat ("(at {0}:{1}) ", f.GetFileName (), f.GetFileLineNumber ()); + + sb.AppendFormat ("{0}.{1} (", mb.ReflectedType.Name, mb.Name); + + bool first = true; + foreach (var pi in mb.GetParameters ()) { + if (!first) + sb.Append (", "); + first = false; + + sb.Append (pi.ParameterType.FullName); + } + sb.Append (")\n"); + } + + return sb.ToString (); + } } public abstract class AbstractMessage @@ -612,17 +557,8 @@ namespace Mono.CSharp { { #region Properties - public int FatalCounter { get; set; } - public int ErrorsCount { get; protected set; } - - public bool ShowFullPaths { get; set; } - - // - // Whether to dump a stack trace on errors. - // - public bool Stacktrace { get; set; } - + public int WarningsCount { get; private set; } // @@ -640,23 +576,20 @@ namespace Mono.CSharp { return txt; } - public virtual void Print (AbstractMessage msg) + public virtual void Print (AbstractMessage msg, bool showFullPath) { if (msg.IsWarning) { ++WarningsCount; } else { ++ErrorsCount; - - if (ErrorsCount == FatalCounter) - throw new Exception (msg.Text); } } - protected void Print (AbstractMessage msg, TextWriter output) + protected void Print (AbstractMessage msg, TextWriter output, bool showFullPath) { StringBuilder txt = new StringBuilder (); if (!msg.Location.IsNull) { - if (ShowFullPaths) + if (showFullPath) txt.Append (msg.Location.ToStringFullName ()); else txt.Append (msg.Location.ToString ()); @@ -709,7 +642,9 @@ namespace Mono.CSharp { // List merged_messages; - public override void Print (AbstractMessage msg) + bool showFullPaths; + + public override void Print (AbstractMessage msg, bool showFullPath) { // // This line is useful when debugging recorded messages @@ -721,7 +656,8 @@ namespace Mono.CSharp { session_messages.Add (msg); - base.Print (msg); + this.showFullPaths = showFullPath; + base.Print (msg, showFullPath); } public void EndSession () @@ -795,7 +731,7 @@ namespace Mono.CSharp { bool error_msg = false; foreach (AbstractMessage msg in messages_to_print) { - dest.Print (msg); + dest.Print (msg, showFullPaths); error_msg |= !msg.IsWarning; } @@ -812,10 +748,10 @@ namespace Mono.CSharp { this.writer = writer; } - public override void Print (AbstractMessage msg) + public override void Print (AbstractMessage msg, bool showFullPath) { - Print (msg, writer); - base.Print (msg); + Print (msg, writer, showFullPath); + base.Print (msg, showFullPath); } } @@ -932,60 +868,6 @@ namespace Mono.CSharp { return txt; } - - static string FriendlyStackTrace (StackTrace t) - { - StringBuilder sb = new StringBuilder (); - - bool foundUserCode = false; - - for (int i = 0; i < t.FrameCount; i++) { - StackFrame f = t.GetFrame (i); - var mb = f.GetMethod (); - - if (!foundUserCode && mb.ReflectedType == typeof (Report)) - continue; - - foundUserCode = true; - - sb.Append ("\tin "); - - if (f.GetFileLineNumber () > 0) - sb.AppendFormat ("(at {0}:{1}) ", f.GetFileName (), f.GetFileLineNumber ()); - - sb.AppendFormat ("{0}.{1} (", mb.ReflectedType.Name, mb.Name); - - bool first = true; - foreach (var pi in mb.GetParameters ()) { - if (!first) - sb.Append (", "); - first = false; - - sb.Append (pi.ParameterType.FullName); - } - sb.Append (")\n"); - } - - return sb.ToString (); - } - - public override void Print (AbstractMessage msg) - { - base.Print (msg); - - if (Stacktrace) - Console.WriteLine (FriendlyStackTrace (new StackTrace (true))); - } - - public static string FriendlyStackTrace (Exception e) - { - return FriendlyStackTrace (new StackTrace (e, true)); - } - - public static void StackTrace () - { - Console.WriteLine (FriendlyStackTrace (new StackTrace (true))); - } } class TimeReporter @@ -999,7 +881,6 @@ namespace Mono.CSharp { ReferencesImporting, PredefinedTypesInit, ModuleDefinitionTotal, - UsingResolve, EmitTotal, CloseTypes, Resouces, @@ -1058,7 +939,6 @@ namespace Mono.CSharp { { TimerType.ReferencesImporting, "Referenced assemblies importing" }, { TimerType.PredefinedTypesInit, "Predefined types initialization" }, { TimerType.ModuleDefinitionTotal, "Module definition" }, - { TimerType.UsingResolve, "Top-level usings resolve" }, { TimerType.EmitTotal, "Resolving and emitting members blocks" }, { TimerType.CloseTypes, "Module types closed" }, { TimerType.Resouces, "Embedding resources" }, @@ -1114,6 +994,14 @@ namespace Mono.CSharp { } } + class FatalException : Exception + { + public FatalException (string message) + : base (message) + { + } + } + /// /// Handles #pragma warning /// @@ -1202,13 +1090,13 @@ namespace Mono.CSharp { regions.Add (new EnableAll (line)); } - public void WarningEnable (Location location, int code, Report Report) + public void WarningEnable (Location location, int code, CompilerContext context) { - if (!Report.CheckWarningCode (code, location)) + if (!context.Report.CheckWarningCode (code, location)) return; - if (Report.IsWarningDisabledGlobally (code)) - Report.Warning (1635, 1, location, "Cannot restore warning `CS{0:0000}' because it was disabled globally", code); + if (context.Settings.IsWarningDisabledGlobally (code)) + context.Report.Warning (1635, 1, location, "Cannot restore warning `CS{0:0000}' because it was disabled globally", code); regions.Add (new Enable (location.Row, code)); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/rootcontext.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/settings.cs similarity index 88% rename from src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/rootcontext.cs rename to src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/settings.cs index 648052af23..679a3ab1fe 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/rootcontext.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/settings.cs @@ -1,5 +1,5 @@ // -// rootcontext.cs: keeps track of our tree representation, and assemblies loaded. +// settings.cs: All compiler settings // // Author: Miguel de Icaza (miguel@ximian.com) // Ravi Pratap (ravi@ximian.com) @@ -47,7 +47,12 @@ namespace Mono.CSharp { public enum Platform { - AnyCPU, X86, X64, IA64 + AnyCPU, + AnyCPU32Preferred, + Arm, + X86, + X64, + IA64 } public class CompilerSettings @@ -66,6 +71,11 @@ namespace Mono.CSharp { public string StrongNameKeyContainer; public bool StrongNameDelaySign; + public int TabSize; + + public bool WarningsAreErrors; + public int WarningLevel; + // // Assemblies references to be loaded // @@ -130,9 +140,15 @@ namespace Mono.CSharp { public bool GenerateDebugInfo; - // Compiler debug flags only + #region Compiler debug flags only public bool ParseOnly, TokenizeOnly, Timestamps; public int DebugFlags; + public int VerboseParserFlag; + public int FatalCounter; + public bool Stacktrace; + #endregion + + public bool ShowFullPaths; // // Whether we are being linked against the standard libraries. @@ -145,7 +161,11 @@ namespace Mono.CSharp { readonly List conditional_symbols; - readonly List source_files; + readonly List source_files; + + List warnings_as_error; + List warnings_only; + HashSet warning_ignore_table; public CompilerSettings () { @@ -155,10 +175,15 @@ namespace Mono.CSharp { Platform = Platform.AnyCPU; Version = LanguageVersion.Default; VerifyClsCompliance = true; - Optimize = true; Encoding = Encoding.UTF8; LoadDefaultReferences = true; StdLibRuntimeVersion = RuntimeVersion.v4; + WarningLevel = 4; + + if (Environment.OSVersion.Platform == PlatformID.Win32NT) + TabSize = 4; + else + TabSize = 8; AssemblyReferences = new List (); AssemblyReferencesAliases = new List> (); @@ -171,12 +196,12 @@ namespace Mono.CSharp { // conditional_symbols.Add ("__MonoCS__"); - source_files = new List (); + source_files = new List (); } #region Properties - public CompilationSourceFile FirstSourceFile { + public SourceFile FirstSourceFile { get { return source_files.Count > 0 ? source_files [0] : null; } @@ -194,7 +219,7 @@ namespace Mono.CSharp { } } - public List SourceFiles { + public List SourceFiles { get { return source_files; } @@ -208,10 +233,62 @@ namespace Mono.CSharp { conditional_symbols.Add (symbol); } + public void AddWarningAsError (int id) + { + if (warnings_as_error == null) + warnings_as_error = new List (); + + warnings_as_error.Add (id); + } + + public void AddWarningOnly (int id) + { + if (warnings_only == null) + warnings_only = new List (); + + warnings_only.Add (id); + } + public bool IsConditionalSymbolDefined (string symbol) { return conditional_symbols.Contains (symbol); } + + public bool IsWarningAsError (int code) + { + bool is_error = WarningsAreErrors; + + // Check specific list + if (warnings_as_error != null) + is_error |= warnings_as_error.Contains (code); + + // Ignore excluded warnings + if (warnings_only != null && warnings_only.Contains (code)) + is_error = false; + + return is_error; + } + + public bool IsWarningEnabled (int code, int level) + { + if (WarningLevel < level) + return false; + + return !IsWarningDisabledGlobally (code); + } + + public bool IsWarningDisabledGlobally (int code) + { + return warning_ignore_table != null && warning_ignore_table.Contains (code); + } + + public void SetIgnoreWarning (int code) + { + if (warning_ignore_table == null) + warning_ignore_table = new HashSet (); + + warning_ignore_table.Add (code); + } } public class CommandLineParser @@ -227,22 +304,27 @@ namespace Mono.CSharp { static readonly char[] argument_value_separator = new char[] { ';', ',' }; static readonly char[] numeric_value_separator = new char[] { ';', ',', ' ' }; - readonly Report report; readonly TextWriter output; + readonly Report report; bool stop_argument; Dictionary source_file_index; public event Func UnknownOptionHandler; - public CommandLineParser (Report report) - : this (report, Console.Out) + CompilerSettings parser_settings; + + public CommandLineParser (TextWriter errorOutput) + : this (errorOutput, Console.Out) { } - public CommandLineParser (Report report, TextWriter messagesOutput) + public CommandLineParser (TextWriter errorOutput, TextWriter messagesOutput) { - this.report = report; + var rp = new StreamReportPrinter (errorOutput); + + parser_settings = new CompilerSettings (); + report = new Report (new CompilerContext (parser_settings, rp), rp); this.output = messagesOutput; } @@ -363,10 +445,13 @@ namespace Mono.CSharp { ProcessSourceFiles (arg, false, settings.SourceFiles); } + if (report.Errors > 0) + return null; + return settings; } - void ProcessSourceFiles (string spec, bool recurse, List sourceFiles) + void ProcessSourceFiles (string spec, bool recurse, List sourceFiles) { string path, pattern; @@ -460,7 +545,7 @@ namespace Mono.CSharp { settings.Resources.Add (res); } - void AddSourceFile (string fileName, List sourceFiles) + void AddSourceFile (string fileName, List sourceFiles) { string path = Path.GetFullPath (fileName); @@ -475,11 +560,43 @@ namespace Mono.CSharp { return; } - var unit = new CompilationSourceFile (fileName, path, sourceFiles.Count + 1); + var unit = new SourceFile (fileName, path, sourceFiles.Count + 1); sourceFiles.Add (unit); source_file_index.Add (path, unit.Index); } + void AddWarningAsError (string warningId, CompilerSettings settings) + { + int id; + try { + id = int.Parse (warningId); + } catch { + report.CheckWarningCode (warningId, Location.Null); + return; + } + + if (!report.CheckWarningCode (id, Location.Null)) + return; + + settings.AddWarningAsError (id); + } + + void RemoveWarningAsError (string warningId, CompilerSettings settings) + { + int id; + try { + id = int.Parse (warningId); + } catch { + report.CheckWarningCode (warningId, Location.Null); + return; + } + + if (!report.CheckWarningCode (id, Location.Null)) + return; + + settings.AddWarningOnly (id); + } + void Error_RequiresArgument (string option) { report.Error (2006, "Missing argument for `{0}' option", option); @@ -830,10 +947,18 @@ namespace Mono.CSharp { return ParseResult.Success; case "/debug": - if (value == "full" || value == "") + if (value == "full" || value == "pdbonly" || idx < 0) { settings.GenerateDebugInfo = true; + return ParseResult.Success; + } - return ParseResult.Success; + if (value.Length > 0) { + report.Error (1902, "Invalid debug option `{0}'. Valid options are `full' or `pdbonly'", value); + } else { + Error_RequiresArgument (option); + } + + return ParseResult.Error; case "/debug+": settings.GenerateDebugInfo = true; @@ -869,19 +994,20 @@ namespace Mono.CSharp { case "/warnaserror": case "/warnaserror+": if (value.Length == 0) { - report.WarningsAreErrors = true; + settings.WarningsAreErrors = true; + parser_settings.WarningsAreErrors = true; } else { foreach (string wid in value.Split (numeric_value_separator)) - report.AddWarningAsError (wid); + AddWarningAsError (wid, settings); } return ParseResult.Success; case "/warnaserror-": if (value.Length == 0) { - report.WarningsAreErrors = false; + settings.WarningsAreErrors = false; } else { foreach (string wid in value.Split (numeric_value_separator)) - report.RemoveWarningAsError (wid); + RemoveWarningAsError (wid, settings); } return ParseResult.Success; @@ -891,7 +1017,7 @@ namespace Mono.CSharp { return ParseResult.Error; } - SetWarningLevel (value); + SetWarningLevel (value, settings); return ParseResult.Success; case "/nowarn": @@ -910,7 +1036,7 @@ namespace Mono.CSharp { if (warn < 1) { throw new ArgumentOutOfRangeException ("warn"); } - report.SetIgnoreWarning (warn); + settings.SetIgnoreWarning (warn); } catch { report.Error (1904, "`{0}' is not a valid warning number", wc); return ParseResult.Error; @@ -928,7 +1054,10 @@ namespace Mono.CSharp { return ParseResult.Error; } - switch (value.ToLower (CultureInfo.InvariantCulture)) { + switch (value.ToLowerInvariant ()) { + case "arm": + settings.Platform = Platform.Arm; + break; case "anycpu": settings.Platform = Platform.AnyCPU; break; @@ -941,8 +1070,12 @@ namespace Mono.CSharp { case "itanium": settings.Platform = Platform.IA64; break; + case "anycpu32bitpreferred": + settings.Platform = Platform.AnyCPU32Preferred; + break; default: - report.Error (1672, "Invalid platform type for -platform. Valid options are `anycpu', `x86', `x64' or `itanium'"); + report.Error (1672, "Invalid -platform option `{0}'. Valid options are `anycpu', `anycpu32bitpreferred', `arm', `x86', `x64' or `itanium'", + value); return ParseResult.Error; } @@ -995,7 +1128,7 @@ namespace Mono.CSharp { return ParseResult.Success; case "/fullpaths": - report.Printer.ShowFullPaths = true; + settings.ShowFullPaths = true; return ParseResult.Success; case "/keyfile": @@ -1095,7 +1228,7 @@ namespace Mono.CSharp { { switch (arg){ case "-v": - CSharpParser.yacc_verbose_flag++; + settings.VerboseParserFlag++; return ParseResult.Success; case "--version": @@ -1155,7 +1288,7 @@ namespace Mono.CSharp { return ParseResult.Success; case "--stacktrace": - report.Printer.Stacktrace = true; + settings.Stacktrace = true; return ParseResult.Success; case "--linkresource": @@ -1263,7 +1396,7 @@ namespace Mono.CSharp { Usage (); Environment.Exit (1); } - report.SetIgnoreWarning (warn); + settings.SetIgnoreWarning (warn); return ParseResult.Success; case "--wlevel": @@ -1273,7 +1406,7 @@ namespace Mono.CSharp { return ParseResult.Error; } - SetWarningLevel (args [++i]); + SetWarningLevel (args [++i], settings); return ParseResult.Success; case "--mcs-debug": @@ -1319,12 +1452,12 @@ namespace Mono.CSharp { return ParseResult.Success; default: - if (arg.StartsWith ("--fatal")){ + if (arg.StartsWith ("--fatal", StringComparison.Ordinal)){ int fatal = 1; - if (arg.StartsWith ("--fatal=")) + if (arg.StartsWith ("--fatal=", StringComparison.Ordinal)) int.TryParse (arg.Substring (8), out fatal); - report.Printer.FatalCounter = fatal; + settings.FatalCounter = fatal; return ParseResult.Success; } if (arg.StartsWith ("--runtime:", StringComparison.Ordinal)) { @@ -1351,7 +1484,7 @@ namespace Mono.CSharp { } } - void SetWarningLevel (string s) + void SetWarningLevel (string s, CompilerSettings settings) { int level = -1; @@ -1363,7 +1496,7 @@ namespace Mono.CSharp { report.Error (1900, "Warning level must be in the range 0-4"); return; } - report.WarningLevel = level; + settings.WarningLevel = level; } // @@ -1401,7 +1534,7 @@ namespace Mono.CSharp { void Usage () { output.WriteLine ( - "Mono C# compiler, Copyright 2001 - 2011 Novell, Inc.\n" + + "Mono C# compiler, Copyright 2001-2011 Novell, Inc., Copyright 2011-2012 Xamarin, Inc\n" + "mcs [options] source-files\n" + " --about About the Mono C# compiler\n" + " -addmodule:M1[,Mn] Adds the module to the generated assembly\n" + @@ -1426,7 +1559,8 @@ namespace Mono.CSharp { " -out:FILE Specifies output assembly name\n" + " -pkg:P1[,Pn] References packages P1..Pn\n" + " -platform:ARCH Specifies the target platform of the output assembly\n" + - " ARCH can be one of: anycpu, x86, x64 or itanium\n" + + " ARCH can be one of: anycpu, anycpu32bitpreferred, arm,\n" + + " x86, x64 or itanium. The default is anycpu.\n" + " -recurse:SPEC Recursively compiles files according to SPEC pattern\n" + " -reference:A1[,An] Imports metadata from the specified assembly (short: -r)\n" + " -reference:ALIAS=A Imports metadata using specified extern alias (short: -r)\n" + diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/smcs.exe.sources b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/smcs.exe.sources deleted file mode 100644 index 208d2eee29..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/smcs.exe.sources +++ /dev/null @@ -1,53 +0,0 @@ -AssemblyInfo.cs -anonymous.cs -argument.cs -assign.cs -attribute.cs -driver.cs -cs-tokenizer.cs -cfold.cs -class.cs -codegen.cs -complete.cs -const.cs -constant.cs -convert.cs -context.cs -decl.cs -delegate.cs -doc-bootstrap.cs -dynamic.cs -enum.cs -ecore.cs -eval.cs -expression.cs -field.cs -flowanalysis.cs -generic.cs -import.cs -iterators.cs -lambda.cs -linq.cs -literal.cs -location.cs -membercache.cs -method.cs -modifiers.cs -namespace.cs -nullable.cs -parameter.cs -pending.cs -property.cs -report.cs -rootcontext.cs -roottypes.cs -statement.cs -support.cs -typemanager.cs -typespec.cs -symbolwriter.cs -../class/Mono.CompilerServices.SymbolWriter/MonoSymbolFile.cs -../class/Mono.CompilerServices.SymbolWriter/MonoSymbolTable.cs -../class/Mono.CompilerServices.SymbolWriter/MonoSymbolWriter.cs -../class/corlib/Mono.Security.Cryptography/CryptoConvert.cs -../build/common/Consts.cs diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/smcs.exe.sources-xml b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/smcs.exe.sources-xml deleted file mode 100644 index 92fc799bbd..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/smcs.exe.sources-xml +++ /dev/null @@ -1,384 +0,0 @@ -../build/common/MonoTODOAttribute.cs -../build/common/Locale.cs -../class/System.XML/Mono.Xml.Schema/XmlSchemaValidatingReader.cs -../class/System.XML/Mono.Xml.Schema/XsdIdentityPath.cs -../class/System.XML/Mono.Xml.Schema/XsdIdentityState.cs -../class/System.XML/Mono.Xml.Schema/XsdKeyTable.cs -../class/System.XML/Mono.Xml.Schema/XsdParticleValidationState.cs -../class/System.XML/Mono.Xml.Schema/XsdValidatingReader.cs -../class/System.XML/Mono.Xml.Schema/XsdWildcard.cs -../class/System.XML/Mono.Xml.XPath/DTMXPathDocument.cs -../class/System.XML/Mono.Xml.XPath/DTMXPathDocumentBuilder.cs -../class/System.XML/Mono.Xml.XPath/DTMXPathDocumentWriter.cs -../class/System.XML/Mono.Xml.XPath/DTMXPathNavigator.cs -../class/System.XML/Mono.Xml.XPath/DTMXPathNode.cs -../class/System.XML/Mono.Xml.XPath/DTMXPathDocument2.cs -../class/System.XML/Mono.Xml.XPath/DTMXPathDocumentBuilder2.cs -../class/System.XML/Mono.Xml.XPath/DTMXPathDocumentWriter2.cs -../class/System.XML/Mono.Xml.XPath/DTMXPathNavigator2.cs -../class/System.XML/Mono.Xml.XPath/DTMXPathNode2.cs -../class/System.XML/Mono.Xml.XPath/IdPattern.cs -../class/System.XML/Mono.Xml.XPath/KeyPattern.cs -../class/System.XML/Mono.Xml.XPath/LocationPathPattern.cs -../class/System.XML/Mono.Xml.XPath/Pattern.cs -../class/System.XML/Mono.Xml.XPath/UnionPattern.cs -../class/System.XML/Mono.Xml.XPath/XPathEditableDocument.cs -../class/System.XML/Mono.Xml.XPath/XPathNavigatorReader.cs -../class/System.XML/Mono.Xml/IHasXmlParserContext.cs -../class/System.XML/Mono.Xml/IHasXmlSchemaInfo.cs -../class/System.XML/Mono.Xml/SubtreeXmlReader.cs -../class/System.XML/Mono.Xml/XmlFilterReader.cs -../class/System.XML/Mono.Xml/XmlNodeWriter.cs -../class/System.XML/System.Xml/ConformanceLevel.cs -../class/System.XML/System.Xml/DTDAutomata.cs -../class/System.XML/System.Xml/DTDObjectModel.cs -../class/System.XML/System.Xml/DTDReader.cs -../class/System.XML/System.Xml/DTDValidatingReader2.cs -../class/System.XML/System.Xml/EntityResolvingXmlReader.cs -../class/System.XML/System.Xml/EntityHandling.cs -../class/System.XML/System.Xml/Formatting.cs -../class/System.XML/System.Xml/IHasXmlNode.cs -../class/System.XML/System.Xml/IXmlLineInfo.cs -../class/System.XML/System.Xml/IHasXmlChildNode.cs -../class/System.XML/System.Xml/IXmlNamespaceResolver.cs -../class/System.XML/System.Xml/MonoFIXAttribute.cs -../class/System.XML/System.Xml/NameTable.cs -../class/System.XML/System.Xml/NewLineHandling.cs -../class/System.XML/System.Xml/ReadState.cs -../class/System.XML/System.Xml/ValidationType.cs -../class/System.XML/System.Xml/WhitespaceHandling.cs -../class/System.XML/System.Xml/WriteState.cs -../class/System.XML/System.Xml/XmlEntity.cs -../class/System.XML/System.Xml/XmlAttribute.cs -../class/System.XML/System.Xml/XmlAttributeCollection.cs -../class/System.XML/System.Xml/XmlCDataSection.cs -../class/System.XML/System.Xml/XmlConstructs.cs -../class/System.XML/System.Xml/XmlChar.cs -../class/System.XML/System.Xml/XmlCharacterData.cs -../class/System.XML/System.Xml/XmlComment.cs -../class/System.XML/System.Xml/XmlNotation.cs -../class/System.XML/System.Xml/XmlDeclaration.cs -../class/System.XML/System.Xml/XmlDocument.cs -../class/System.XML/System.Xml/XmlDocumentFragment.cs -../class/System.XML/System.Xml/XmlDocumentNavigator.cs -../class/System.XML/System.Xml/XmlDocumentType.cs -../class/System.XML/System.Xml/XmlElement.cs -../class/System.XML/System.Xml/XmlEntityReference.cs -../class/System.XML/System.Xml/XmlException.cs -../class/System.XML/System.Xml/XmlImplementation.cs -../class/System.XML/System.Xml/XmlConvert.cs -../class/System.XML/System.Xml/XmlDateTimeSerializationMode.cs -../class/System.XML/System.Xml/XmlLinkedNode.cs -../class/System.XML/System.Xml/XmlNameEntry.cs -../class/System.XML/System.Xml/XmlNameEntryCache.cs -../class/System.XML/System.Xml/XmlNameTable.cs -../class/System.XML/System.Xml/XmlNamedNodeMap.cs -../class/System.XML/System.Xml/XmlNamespaceScope.cs -../class/System.XML/System.Xml/XmlNamespaceManager.cs -../class/System.XML/System.Xml/XmlNode.cs -../class/System.XML/System.Xml/XmlNodeChangedAction.cs -../class/System.XML/System.Xml/XmlNodeChangedEventArgs.cs -../class/System.XML/System.Xml/XmlNodeChangedEventHandler.cs -../class/System.XML/System.Xml/XmlNodeList.cs -../class/System.XML/System.Xml/XmlNodeListChildren.cs -../class/System.XML/System.Xml/XmlNodeArrayList.cs -../class/System.XML/System.Xml/XmlIteratorNodeList.cs -../class/System.XML/System.Xml/XmlNodeOrder.cs -../class/System.XML/System.Xml/XmlNodeReader2.cs -../class/System.XML/System.Xml/XmlNodeReaderImpl.cs -../class/System.XML/System.Xml/XmlNodeType.cs -../class/System.XML/System.Xml/XmlOutputMethod.cs -../class/System.XML/System.Xml/XmlParserContext.cs -../class/System.XML/System.Xml/XmlProcessingInstruction.cs -../class/System.XML/System.Xml/XmlQualifiedName.cs -../class/System.XML/System.Xml/XmlReader.cs -../class/System.XML/System.Xml/XmlReaderBinarySupport.cs -../class/System.XML/System.Xml/XmlReaderSettings.cs -../class/System.XML/System.Xml/XmlResolver.cs -../class/System.XML/System.Xml/XmlSecureResolver.cs -../class/System.XML/System.Xml/XmlSignificantWhitespace.cs -../class/System.XML/System.Xml/XmlSpace.cs -../class/System.XML/System.Xml/XmlText.cs -../class/System.XML/System.Xml/XmlTextReader.cs -../class/System.XML/System.Xml/XmlTextReader2.cs -../class/System.XML/System.Xml/XmlTokenizedType.cs -../class/System.XML/System.Xml/XmlUrlResolver.cs -../class/System.XML/System.Xml/XmlValidatingReader.cs -../class/System.XML/System.Xml/XmlWhitespace.cs -../class/System.XML/System.Xml/XmlWriter.cs -../class/System.XML/System.Xml/XmlWriterSettings.cs -../class/System.XML/System.Xml/XmlTextWriter2.cs -../class/System.XML/System.Xml/XmlInputStream.cs -../class/System.XML/System.Xml/XmlParserInput.cs -../class/System.XML/System.Xml.XPath/IXPathNavigable.cs -../class/System.XML/System.Xml.XPath/XPathNavigator.cs -../class/System.XML/System.Xml.XPath/XPathExpression.cs -../class/System.XML/System.Xml.XPath/XPathItem.cs -../class/System.XML/System.Xml.XPath/XPathNamespaceScope.cs -../class/System.XML/System.Xml.XPath/XPathNodeIterator.cs -../class/System.XML/System.Xml.XPath/XPathResultType.cs -../class/System.XML/System.Xml.XPath/XPathNodeType.cs -../class/System.XML/System.Xml.XPath/XmlDataType.cs -../class/System.XML/System.Xml.XPath/XmlSortOrder.cs -../class/System.XML/System.Xml.XPath/XmlCaseOrder.cs -../class/System.XML/System.Xml.XPath/XPathDocument.cs -../class/System.XML/System.Xml.XPath/XPathException.cs -../class/System.XML/System.Xml.XPath/XPathComparer.cs -../class/System.XML/System.Xml.XPath/DefaultContext.cs -../class/System.XML/System.Xml.XPath/Expression.cs -../class/System.XML/System.Xml.XPath/Iterator.cs -../class/System.XML/System.Xml.XPath/Tokenizer.cs -../class/System.XML/System.Xml.XPath/Parser.cs -../class/System.XML/System.Xml.Schema/BuiltInDatatype.cs -../class/System.XML/System.Xml.Schema/IXmlSchemaInfo.cs -../class/System.XML/System.Xml.Schema/SchemaDataValueType.cs -../class/System.XML/System.Xml.Schema/ValidationEventArgs.cs -../class/System.XML/System.Xml.Schema/XmlAtomicValue.cs -../class/System.XML/System.Xml.Schema/XmlSchema.cs -../class/System.XML/System.Xml.Schema/XmlSchemaAll.cs -../class/System.XML/System.Xml.Schema/XmlSchemaAnnotated.cs -../class/System.XML/System.Xml.Schema/XmlSchemaAnnotation.cs -../class/System.XML/System.Xml.Schema/XmlSchemaAny.cs -../class/System.XML/System.Xml.Schema/XmlSchemaAnyAttribute.cs -../class/System.XML/System.Xml.Schema/XmlSchemaAppInfo.cs -../class/System.XML/System.Xml.Schema/XmlSchemaAttribute.cs -../class/System.XML/System.Xml.Schema/XmlSchemaAttributeGroup.cs -../class/System.XML/System.Xml.Schema/XmlSchemaAttributeGroupRef.cs -../class/System.XML/System.Xml.Schema/XmlSchemaChoice.cs -../class/System.XML/System.Xml.Schema/XmlSchemaCollection.cs -../class/System.XML/System.Xml.Schema/XmlSchemaCollectionEnumerator.cs -../class/System.XML/System.Xml.Schema/XmlSchemaCompilationSettings.cs -../class/System.XML/System.Xml.Schema/XmlSchemaComplexContent.cs -../class/System.XML/System.Xml.Schema/XmlSchemaComplexContentExtension.cs -../class/System.XML/System.Xml.Schema/XmlSchemaComplexContentRestriction.cs -../class/System.XML/System.Xml.Schema/XmlSchemaComplexType.cs -../class/System.XML/System.Xml.Schema/XmlSchemaContent.cs -../class/System.XML/System.Xml.Schema/XmlSchemaContentModel.cs -../class/System.XML/System.Xml.Schema/XmlSchemaContentProcessing.cs -../class/System.XML/System.Xml.Schema/XmlSchemaContentType.cs -../class/System.XML/System.Xml.Schema/XmlSchemaDatatype.cs -../class/System.XML/System.Xml.Schema/XmlSchemaDatatypeVariety.cs -../class/System.XML/System.Xml.Schema/XmlSchemaDerivationMethod.cs -../class/System.XML/System.Xml.Schema/XmlSchemaDocumentation.cs -../class/System.XML/System.Xml.Schema/XmlSchemaElement.cs -../class/System.XML/System.Xml.Schema/XmlSchemaEnumerationFacet.cs -../class/System.XML/System.Xml.Schema/XmlSchemaException.cs -../class/System.XML/System.Xml.Schema/XmlSchemaExternal.cs -../class/System.XML/System.Xml.Schema/XmlSchemaFacet.cs -../class/System.XML/System.Xml.Schema/XmlSchemaForm.cs -../class/System.XML/System.Xml.Schema/XmlSchemaFractionDigitsFacet.cs -../class/System.XML/System.Xml.Schema/XmlSchemaGroup.cs -../class/System.XML/System.Xml.Schema/XmlSchemaGroupBase.cs -../class/System.XML/System.Xml.Schema/XmlSchemaGroupRef.cs -../class/System.XML/System.Xml.Schema/XmlSchemaIdentityConstraint.cs -../class/System.XML/System.Xml.Schema/XmlSchemaImport.cs -../class/System.XML/System.Xml.Schema/XmlSchemaInclude.cs -../class/System.XML/System.Xml.Schema/XmlSchemaInference.cs -../class/System.XML/System.Xml.Schema/XmlSchemaInferenceException.cs -../class/System.XML/System.Xml.Schema/XmlSchemaInfo.cs -../class/System.XML/System.Xml.Schema/XmlSchemaKey.cs -../class/System.XML/System.Xml.Schema/XmlSchemaKeyref.cs -../class/System.XML/System.Xml.Schema/XmlSchemaLengthFacet.cs -../class/System.XML/System.Xml.Schema/XmlSchemaMaxExclusiveFacet.cs -../class/System.XML/System.Xml.Schema/XmlSchemaMaxInclusiveFacet.cs -../class/System.XML/System.Xml.Schema/XmlSchemaMaxLengthFacet.cs -../class/System.XML/System.Xml.Schema/XmlSchemaMinExclusiveFacet.cs -../class/System.XML/System.Xml.Schema/XmlSchemaMinInclusiveFacet.cs -../class/System.XML/System.Xml.Schema/XmlSchemaMinLengthFacet.cs -../class/System.XML/System.Xml.Schema/XmlSchemaNotation.cs -../class/System.XML/System.Xml.Schema/XmlSchemaNumericFacet.cs -../class/System.XML/System.Xml.Schema/XmlSchemaObject.cs -../class/System.XML/System.Xml.Schema/XmlSchemaObjectCollection.cs -../class/System.XML/System.Xml.Schema/XmlSchemaObjectEnumerator.cs -../class/System.XML/System.Xml.Schema/XmlSchemaObjectTable.cs -../class/System.XML/System.Xml.Schema/XmlSchemaParticle.cs -../class/System.XML/System.Xml.Schema/XmlSchemaPatternFacet.cs -../class/System.XML/System.Xml.Schema/XmlSchemaRedefine.cs -../class/System.XML/System.Xml.Schema/XmlSchemaSet.cs -../class/System.XML/System.Xml.Schema/XmlSchemaSequence.cs -../class/System.XML/System.Xml.Schema/XmlSchemaSerializer.cs -../class/System.XML/System.Xml.Schema/XmlSchemaSimpleContent.cs -../class/System.XML/System.Xml.Schema/XmlSchemaSimpleContentExtension.cs -../class/System.XML/System.Xml.Schema/XmlSchemaSimpleContentRestriction.cs -../class/System.XML/System.Xml.Schema/XmlSchemaSimpleType.cs -../class/System.XML/System.Xml.Schema/XmlSchemaSimpleTypeContent.cs -../class/System.XML/System.Xml.Schema/XmlSchemaSimpleTypeList.cs -../class/System.XML/System.Xml.Schema/XmlSchemaSimpleTypeRestriction.cs -../class/System.XML/System.Xml.Schema/XmlSchemaSimpleTypeUnion.cs -../class/System.XML/System.Xml.Schema/XmlSchemaTotalDigitsFacet.cs -../class/System.XML/System.Xml.Schema/XmlSchemaType.cs -../class/System.XML/System.Xml.Schema/XmlSchemaUnique.cs -../class/System.XML/System.Xml.Schema/XmlSchemaUse.cs -../class/System.XML/System.Xml.Schema/XmlSchemaValidator.cs -../class/System.XML/System.Xml.Schema/XmlSchemaValidity.cs -../class/System.XML/System.Xml.Schema/XmlSchemaValidationException.cs -../class/System.XML/System.Xml.Schema/XmlSchemaWhiteSpaceFacet.cs -../class/System.XML/System.Xml.Schema/XmlSchemaXPath.cs -../class/System.XML/System.Xml.Schema/XmlSeverityType.cs -../class/System.XML/System.Xml.Schema/ValidationHandler.cs -../class/System.XML/System.Xml.Schema/XmlSchemaUtil.cs -../class/System.XML/System.Xml.Schema/XmlSchemaReader.cs -../class/System.XML/System.Xml.Schema/XmlSchemaValidationFlags.cs -../class/System.XML/System.Xml.Schema/XmlTypeCode.cs -../class/System.XML/System.Xml.Schema/XmlValueGetter.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslApplyImports.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslApplyTemplates.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslAttribute.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslAvt.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslCallTemplate.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslChoose.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslComment.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslCompiledElement.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslCopy.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslCopyOf.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslElement.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslFallback.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslForEach.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslIf.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslLiteralElement.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslMessage.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslNotSupportedOperation.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslNumber.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslOperation.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslProcessingInstruction.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslTemplateContent.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslText.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslValueOf.cs -../class/System.XML/Mono.Xml.Xsl.Operations/XslVariable.cs -../class/System.XML/Mono.Xml.Xsl/Attribute.cs -../class/System.XML/Mono.Xml.Xsl/Compiler.cs -../class/System.XML/Mono.Xml.Xsl/Debug.cs -../class/System.XML/Mono.Xml.Xsl/Emitter.cs -../class/System.XML/Mono.Xml.Xsl/GenericOutputter.cs -../class/System.XML/Mono.Xml.Xsl/HtmlEmitter.cs -../class/System.XML/Mono.Xml.Xsl/MSXslScriptManager.cs -../class/System.XML/Mono.Xml.Xsl/Outputter.cs -../class/System.XML/Mono.Xml.Xsl/ScriptCompilerInfo.cs -../class/System.XML/Mono.Xml.Xsl/TextEmitter.cs -../class/System.XML/Mono.Xml.Xsl/TextOutputter.cs -../class/System.XML/Mono.Xml.Xsl/PatternParser.cs -../class/System.XML/Mono.Xml.Xsl/PatternTokenizer.cs -../class/System.XML/Mono.Xml.Xsl/XmlWriterEmitter.cs -../class/System.XML/Mono.Xml.Xsl/XslAttributeSet.cs -../class/System.XML/Mono.Xml.Xsl/XslDecimalFormat.cs -../class/System.XML/Mono.Xml.Xsl/XslKey.cs -../class/System.XML/Mono.Xml.Xsl/XslOutput.cs -../class/System.XML/Mono.Xml.Xsl/XslSortEvaluator.cs -../class/System.XML/Mono.Xml.Xsl/XslStylesheet.cs -../class/System.XML/Mono.Xml.Xsl/XslTemplate.cs -../class/System.XML/Mono.Xml.Xsl/XslTransformProcessor.cs -../class/System.XML/Mono.Xml.Xsl/XsltCompiledContext.cs -../class/System.XML/Mono.Xml.Xsl/XsltDebuggerWrapper.cs -../class/System.XML/Mono.Xml.Xsl/XslFunctions.cs -../class/System.XML/System.Xml.Xsl/IXsltContextFunction.cs -../class/System.XML/System.Xml.Xsl/IXsltContextVariable.cs -../class/System.XML/System.Xml.Xsl/XslCompiledTransform.cs -../class/System.XML/System.Xml.Xsl/XslTransform.cs -../class/System.XML/System.Xml.Xsl/XsltArgumentList.cs -../class/System.XML/System.Xml.Xsl/XsltCompileException.cs -../class/System.XML/System.Xml.Xsl/XsltContext.cs -../class/System.XML/System.Xml.Xsl/XsltException.cs -../class/System.XML/System.Xml.Xsl/XsltMessageEncounteredEventArgs.cs -../class/System.XML/System.Xml.Xsl/XsltMessageEncounteredEventHandler.cs -../class/System.XML/System.Xml.Xsl/XsltSettings.cs -../class/System.XML/System.Xml/XQueryConvert.cs -../class/System.XML/System.Xml.Serialization/IXmlTextParser.cs -../class/System.XML/System.Xml.Serialization/CodeExporter.cs -../class/System.XML/System.Xml.Serialization/CodeGenerationOptions.cs -../class/System.XML/System.Xml.Serialization/CodeIdentifier.cs -../class/System.XML/System.Xml.Serialization/CodeIdentifiers.cs -../class/System.XML/System.Xml.Serialization/IXmlSerializable.cs -../class/System.XML/System.Xml.Serialization/ImportContext.cs -../class/System.XML/System.Xml.Serialization/MapCodeGenerator.cs -../class/System.XML/System.Xml.Serialization/ReflectionHelper.cs -../class/System.XML/System.Xml.Serialization/SchemaImporter.cs -../class/System.XML/System.Xml.Serialization/SchemaTypes.cs -../class/System.XML/System.Xml.Serialization/SerializationCodeGenerator.cs -../class/System.XML/System.Xml.Serialization/SerializationCodeGeneratorConfiguration.cs -../class/System.XML/System.Xml.Serialization/SerializationSource.cs -../class/System.XML/System.Xml.Serialization/SoapAttributeAttribute.cs -../class/System.XML/System.Xml.Serialization/SoapAttributeOverrides.cs -../class/System.XML/System.Xml.Serialization/SoapAttributes.cs -../class/System.XML/System.Xml.Serialization/SoapCodeExporter.cs -../class/System.XML/System.Xml.Serialization/SoapElementAttribute.cs -../class/System.XML/System.Xml.Serialization/SoapEnumAttribute.cs -../class/System.XML/System.Xml.Serialization/SoapIgnoreAttribute.cs -../class/System.XML/System.Xml.Serialization/SoapIncludeAttribute.cs -../class/System.XML/System.Xml.Serialization/SoapSchemaImporter.cs -../class/System.XML/System.Xml.Serialization/SoapSchemaExporter.cs -../class/System.XML/System.Xml.Serialization/SoapSchemaMember.cs -../class/System.XML/System.Xml.Serialization/SoapReflectionImporter.cs -../class/System.XML/System.Xml.Serialization/SoapTypeAttribute.cs -../class/System.XML/System.Xml.Serialization/TypeData.cs -../class/System.XML/System.Xml.Serialization/TypeMember.cs -../class/System.XML/System.Xml.Serialization/TypeTranslator.cs -../class/System.XML/System.Xml.Serialization/UnreferencedObjectEventArgs.cs -../class/System.XML/System.Xml.Serialization/UnreferencedObjectEventHandler.cs -../class/System.XML/System.Xml.Serialization/XmlAnyAttributeAttribute.cs -../class/System.XML/System.Xml.Serialization/XmlAnyElementAttribute.cs -../class/System.XML/System.Xml.Serialization/XmlAnyElementAttributes.cs -../class/System.XML/System.Xml.Serialization/XmlArrayAttribute.cs -../class/System.XML/System.Xml.Serialization/XmlArrayItemAttribute.cs -../class/System.XML/System.Xml.Serialization/XmlArrayItemAttributes.cs -../class/System.XML/System.Xml.Serialization/XmlAttributeAttribute.cs -../class/System.XML/System.Xml.Serialization/XmlAttributeEventArgs.cs -../class/System.XML/System.Xml.Serialization/XmlAttributeEventHandler.cs -../class/System.XML/System.Xml.Serialization/XmlAttributeOverrides.cs -../class/System.XML/System.Xml.Serialization/XmlAttributes.cs -../class/System.XML/System.Xml.Serialization/XmlCodeExporter.cs -../class/System.XML/System.Xml.Serialization/XmlChoiceIdentifierAttribute.cs -../class/System.XML/System.Xml.Serialization/XmlCustomFormatter.cs -../class/System.XML/System.Xml.Serialization/XmlDeserializationEvents.cs -../class/System.XML/System.Xml.Serialization/XmlElementAttribute.cs -../class/System.XML/System.Xml.Serialization/XmlElementAttributes.cs -../class/System.XML/System.Xml.Serialization/XmlElementEventArgs.cs -../class/System.XML/System.Xml.Serialization/XmlEnumAttribute.cs -../class/System.XML/System.Xml.Serialization/XmlIgnoreAttribute.cs -../class/System.XML/System.Xml.Serialization/XmlIncludeAttribute.cs -../class/System.XML/System.Xml.Serialization/XmlMemberMapping.cs -../class/System.XML/System.Xml.Serialization/XmlMembersMapping.cs -../class/System.XML/System.Xml.Serialization/XmlMapping.cs -../class/System.XML/System.Xml.Serialization/XmlMappingAccess.cs -../class/System.XML/System.Xml.Serialization/XmlNamespaceDeclarationsAttribute.cs -../class/System.XML/System.Xml.Serialization/XmlNodeEventArgs.cs -../class/System.XML/System.Xml.Serialization/XmlReflectionImporter.cs -../class/System.XML/System.Xml.Serialization/XmlReflectionMember.cs -../class/System.XML/System.Xml.Serialization/XmlRootAttribute.cs -../class/System.XML/System.Xml.Serialization/XmlSchemaEnumerator.cs -../class/System.XML/System.Xml.Serialization/XmlSchemaExporter.cs -../class/System.XML/System.Xml.Serialization/XmlSchemaImporter.cs -../class/System.XML/System.Xml.Serialization/XmlSchemaProviderAttribute.cs -../class/System.XML/System.Xml.Serialization/XmlSchemas.cs -../class/System.XML/System.Xml.Serialization/XmlSerializationCollectionFixupCallback.cs -../class/System.XML/System.Xml.Serialization/XmlSerializationFixupCallback.cs -../class/System.XML/System.Xml.Serialization/XmlSerializationGeneratedCode.cs -../class/System.XML/System.Xml.Serialization/XmlSerializationReadCallback.cs -../class/System.XML/System.Xml.Serialization/XmlSerializationReader.cs -../class/System.XML/System.Xml.Serialization/XmlSerializationReaderInterpreter.cs -../class/System.XML/System.Xml.Serialization/XmlSerializationWriteCallback.cs -../class/System.XML/System.Xml.Serialization/XmlSerializationWriter.cs -../class/System.XML/System.Xml.Serialization/XmlSerializationWriterInterpreter.cs -../class/System.XML/System.Xml.Serialization/XmlSerializer.cs -../class/System.XML/System.Xml.Serialization/XmlSerializerAssemblyAttribute.cs -../class/System.XML/System.Xml.Serialization/XmlSerializerFactory.cs -../class/System.XML/System.Xml.Serialization/XmlSerializerImplementation.cs -../class/System.XML/System.Xml.Serialization/XmlSerializerNamespaces.cs -../class/System.XML/System.Xml.Serialization/XmlSerializerVersionAttribute.cs -../class/System.XML/System.Xml.Serialization/XmlTextAttribute.cs -../class/System.XML/System.Xml.Serialization/XmlTypeAttribute.cs -../class/System.XML/System.Xml.Serialization/XmlTypeMapElementInfo.cs -../class/System.XML/System.Xml.Serialization/XmlTypeMapMember.cs -../class/System.XML/System.Xml.Serialization/XmlTypeMapMemberAttribute.cs -../class/System.XML/System.Xml.Serialization/XmlTypeMapMemberElement.cs -../class/System.XML/System.Xml.Serialization/XmlTypeMapMemberNamespaces.cs -../class/System.XML/System.Xml.Serialization/XmlTypeMapping.cs -../class/System.XML/System.Xml.Serialization/XmlElementEventHandler.cs -../class/System.XML/System.Xml.Serialization/XmlNodeEventHandler.cs -../class/System.XML/System.Xml.Serialization.Advanced/SchemaImporterExtension.cs -../class/System.XML/System.Xml.Serialization.Advanced/SchemaImporterExtensionCollection.cs -../class/System.XML/System.Xml.Serialization.Configuration/DateTimeSerializationSection.cs -../class/System.XML/System.Xml.Serialization.Configuration/SchemaImporterExtensionElement.cs -../class/System.XML/System.Xml.Serialization.Configuration/SchemaImporterExtensionElementCollection.cs -../class/System.XML/System.Xml.Serialization.Configuration/SchemaImporterExtensionsSection.cs -../class/System.XML/System.Xml.Serialization.Configuration/SerializationSectionGroup.cs -../class/System.XML/System.Xml.Serialization.Configuration/XmlSerializerSection.cs diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/statement.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/statement.cs index 104e15371f..4a71f027d1 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/statement.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/statement.cs @@ -68,6 +68,10 @@ namespace Mono.CSharp { { ec.Mark (loc); DoEmit (ec); + + if (ec.StatementEpilogue != null) { + ec.EmitEpilogue (); + } } // @@ -327,17 +331,21 @@ namespace Mono.CSharp { EmbeddedStatement.Emit (ec); ec.MarkLabel (ec.LoopBegin); + // Mark start of while condition + ec.Mark (expr.Location); + // // Dead code elimination // - if (expr is Constant){ + if (expr is Constant) { bool res = !((Constant) expr).IsDefaultValue; expr.EmitSideEffect (ec); if (res) - ec.Emit (OpCodes.Br, loop); - } else + ec.Emit (OpCodes.Br, loop); + } else { expr.EmitBranchable (ec, loop, true); + } ec.MarkLabel (ec.LoopEnd); @@ -427,9 +435,13 @@ namespace Mono.CSharp { // // Inform whether we are infinite or not // - if (expr is Constant){ + if (expr is Constant) { // expr is 'true', since the 'empty' case above handles the 'false' case ec.MarkLabel (ec.LoopBegin); + + if (ec.EmitAccurateDebugInfo) + ec.Emit (OpCodes.Nop); + expr.EmitSideEffect (ec); Statement.Emit (ec); ec.Emit (OpCodes.Br, ec.LoopBegin); @@ -448,8 +460,8 @@ namespace Mono.CSharp { Statement.Emit (ec); ec.MarkLabel (ec.LoopBegin); - ec.Mark (loc); + ec.Mark (expr.Location); expr.EmitBranchable (ec, while_loop, true); ec.MarkLabel (ec.LoopEnd); @@ -459,11 +471,6 @@ namespace Mono.CSharp { ec.LoopEnd = old_end; } - public override void Emit (EmitContext ec) - { - DoEmit (ec); - } - protected override void CloneTo (CloneContext clonectx, Statement t) { While target = (While) t; @@ -592,7 +599,9 @@ namespace Mono.CSharp { // If test is null, there is no test, and we are just // an infinite loop // - if (Condition != null){ + if (Condition != null) { + ec.Mark (Condition.Location); + // // The Resolve code already catches the case for // Test == Constant (false) so we know that @@ -642,6 +651,12 @@ namespace Mono.CSharp { loc = expr.Location; } + public StatementExpression (ExpressionStatement expr, Location loc) + { + this.expr = expr; + this.loc = loc; + } + public ExpressionStatement Expr { get { return this.expr; @@ -845,6 +860,8 @@ namespace Mono.CSharp { ec.Report.Error (127, loc, "`{0}': A return keyword must not be followed by any expression when method returns void", ec.GetSignatureForError ()); + + return false; } } else { if (am.IsIterator) { @@ -863,12 +880,21 @@ namespace Mono.CSharp { return true; } + // TODO: Better error message + if (async_type.Kind == MemberKind.Void) { + ec.Report.Error (127, loc, + "`{0}': A return keyword must not be followed by any expression when method returns void", + ec.GetSignatureForError ()); + + return false; + } + if (!async_type.IsGenericTask) { if (this is ContextualReturn) return true; ec.Report.Error (1997, loc, - "`{0}': A return keyword must not be followed by an expression when async method returns Task. Consider using Task", + "`{0}': A return keyword must not be followed by an expression when async method returns `Task'. Consider using `Task' return type", ec.GetSignatureForError ()); return false; } @@ -876,7 +902,13 @@ namespace Mono.CSharp { // // The return type is actually Task type argument // - block_return_type = async_type.TypeArguments[0]; + if (expr.Type == async_type) { + ec.Report.Error (4016, loc, + "`{0}': The return expression type of async method must be `{1}' rather than `Task<{1}>'", + ec.GetSignatureForError (), async_type.TypeArguments[0].GetSignatureForError ()); + } else { + block_return_type = async_type.TypeArguments[0]; + } } } else { var l = am as AnonymousMethodBody; @@ -890,7 +922,7 @@ namespace Mono.CSharp { if (expr == null) return false; - if (expr.Type != block_return_type) { + if (expr.Type != block_return_type && expr.Type != InternalType.ErrorType) { expr = Convert.ImplicitConversionRequired (ec, expr, block_return_type, loc); if (expr == null) { @@ -919,20 +951,27 @@ namespace Mono.CSharp { if (async_return != null) { async_return.EmitAssign (ec); + ec.EmitEpilogue (); + ec.Emit (unwind_protect ? OpCodes.Leave : OpCodes.Br, async_body.BodyEnd); } return; } - if (unwind_protect) + ec.EmitEpilogue (); + + if (unwind_protect || ec.EmitAccurateDebugInfo) ec.Emit (OpCodes.Stloc, ec.TemporaryReturn ()); } - if (unwind_protect) + if (unwind_protect) { ec.Emit (OpCodes.Leave, ec.CreateReturnLabel ()); - else + } else if (ec.EmitAccurateDebugInfo) { + ec.Emit (OpCodes.Br, ec.CreateReturnLabel ()); + } else { ec.Emit (OpCodes.Ret); + } } void Error_ReturnFromIterator (ResolveContext rc) @@ -1176,9 +1215,9 @@ namespace Mono.CSharp { res = c; } else { TypeSpec type = ec.Switch.SwitchType; - res = c.TryReduce (ec, type, c.Location); + res = c.TryReduce (ec, type); if (res == null) { - c.Error_ValueCannotBeConverted (ec, loc, type, true); + c.Error_ValueCannotBeConverted (ec, type, true); return false; } @@ -1451,12 +1490,12 @@ namespace Mono.CSharp { declarators.Add (decl); } - void CreateEvaluatorVariable (BlockContext bc, LocalVariable li) + static void CreateEvaluatorVariable (BlockContext bc, LocalVariable li) { if (bc.Report.Errors != 0) return; - var container = bc.CurrentMemberDefinition.Parent; + var container = bc.CurrentMemberDefinition.Parent.PartialContainer; Field f = new Field (container, new TypeExpression (li.Type, li.Location), Modifiers.PUBLIC | Modifiers.STATIC, new MemberName (li.Name, li.Location), null); @@ -1576,9 +1615,6 @@ namespace Mono.CSharp { protected override void DoEmit (EmitContext ec) { - if (li.IsConstant) - return; - li.CreateBuilder (ec); if (Initializer != null) @@ -1623,6 +1659,11 @@ namespace Mono.CSharp { { } + public override void Emit (EmitContext ec) + { + // Nothing to emit, not even sequence point + } + protected override Expression ResolveInitializer (BlockContext bc, LocalVariable li, Expression initializer) { initializer = initializer.Resolve (bc); @@ -1640,7 +1681,7 @@ namespace Mono.CSharp { if (TypeSpec.IsReferenceType (li.Type)) initializer.Error_ConstantCanBeInitializedWithNullOnly (bc, li.Type, initializer.Location, li.Name); else - initializer.Error_ValueCannotBeConverted (bc, initializer.Location, li.Type, false); + initializer.Error_ValueCannotBeConverted (bc, li.Type, false); return null; } @@ -1751,6 +1792,12 @@ namespace Mono.CSharp { } } + public bool IsCompilerGenerated { + get { + return (flags & Flags.CompilerGenerated) != 0; + } + } + public bool IsConstant { get { return (flags & Flags.Constant) != 0; @@ -1842,7 +1889,7 @@ namespace Mono.CSharp { // All fixed variabled are pinned, a slot has to be alocated // builder = ec.DeclareLocal (Type, IsFixed); - if (SymbolWriter.HasSymbolWriter) + if (!ec.HasSet (BuilderContext.Options.OmitDebugInfo) && (flags & Flags.CompilerGenerated) == 0) ec.DefineLocalVariable (name, builder); } @@ -1912,7 +1959,7 @@ namespace Mono.CSharp { if (!ec.DoFlowAnalysis || ec.CurrentBranching.IsAssigned (VariableInfo)) return true; - return VariableInfo.TypeInfo.IsFullyInitialized (ec, VariableInfo, block.StartLocation); + return VariableInfo.IsFullyInitialized (ec, block.StartLocation); } public bool IsAssigned (BlockContext ec) @@ -2042,8 +2089,13 @@ namespace Mono.CSharp { #region Properties - public bool HasRet { - get { return (flags & Flags.HasRet) != 0; } + public bool HasUnreachableClosingBrace { + get { + return (flags & Flags.HasRet) != 0; + } + set { + flags = value ? flags | Flags.HasRet : flags & ~Flags.HasRet; + } } public Block Original { @@ -2099,9 +2151,9 @@ namespace Mono.CSharp { AddLocalName (li.Name, li); } - public virtual void AddLocalName (string name, INamedBlockVariable li) + public void AddLocalName (string name, INamedBlockVariable li) { - ParametersBlock.TopBlock.AddLocalName (name, li); + ParametersBlock.TopBlock.AddLocalName (name, li, false); } public virtual void Error_AlreadyDeclared (string name, INamedBlockVariable variable, string reason) @@ -2277,7 +2329,8 @@ namespace Mono.CSharp { if (warn) ec.Report.Warning (162, 2, loc, "Unreachable code detected"); - ec.StartFlowBranching (FlowBranching.BranchingType.Block, loc); + var fb = ec.StartFlowBranching (FlowBranching.BranchingType.Block, loc); + fb.CurrentUsageVector.IsUnreachable = true; bool ok = Resolve (ec); ec.KillFlowBranching (); @@ -2296,27 +2349,13 @@ namespace Mono.CSharp { if (scope_initializers != null) EmitScopeInitializers (ec); - ec.Mark (StartLocation); DoEmit (ec); - - if (SymbolWriter.HasSymbolWriter) - EmitSymbolInfo (ec); } protected void EmitScopeInitializers (EmitContext ec) { - SymbolWriter.OpenCompilerGeneratedBlock (ec); - - using (ec.With (EmitContext.Options.OmitDebugInfo, true)) { - foreach (Statement s in scope_initializers) - s.Emit (ec); - } - - SymbolWriter.CloseCompilerGeneratedBlock (ec); - } - - protected virtual void EmitSymbolInfo (EmitContext ec) - { + foreach (Statement s in scope_initializers) + s.Emit (ec); } #if DEBUG @@ -2384,14 +2423,22 @@ namespace Mono.CSharp { } public bool HasCapturedThis { - set { flags = value ? flags | Flags.HasCapturedThis : flags & ~Flags.HasCapturedThis; } + set { + flags = value ? flags | Flags.HasCapturedThis : flags & ~Flags.HasCapturedThis; + } get { return (flags & Flags.HasCapturedThis) != 0; } } + // + // Used to indicate that the block has reference to parent + // block and cannot be made static when defining anonymous method + // public bool HasCapturedVariable { - set { flags = value ? flags | Flags.HasCapturedVariable : flags & ~Flags.HasCapturedVariable; } + set { + flags = value ? flags | Flags.HasCapturedVariable : flags & ~Flags.HasCapturedVariable; + } get { return (flags & Flags.HasCapturedVariable) != 0; } @@ -2418,11 +2465,12 @@ namespace Mono.CSharp { return ec.CurrentAnonymousMethod.Storey; // - // When referencing a variable in parent iterator/async storey - // from nested anonymous method + // When referencing a variable inside iterator where all + // variables will be captured anyway we don't need to create + // another storey context // - if (ParametersBlock.am_storey is StateMachine) { - return ParametersBlock.am_storey; + if (ParametersBlock.StateMachine is IteratorStorey) { + return ParametersBlock.StateMachine; } if (am_storey == null) { @@ -2431,7 +2479,7 @@ namespace Mono.CSharp { // // Creates anonymous method storey for this block // - am_storey = new AnonymousMethodStorey (this, ec.CurrentMemberDefinition.Parent.PartialContainer, mc, ec.CurrentTypeParameters, "AnonStorey"); + am_storey = new AnonymousMethodStorey (this, ec.CurrentMemberDefinition.Parent.PartialContainer, mc, ec.CurrentTypeParameters, "AnonStorey", MemberKind.Class); } return am_storey; @@ -2440,72 +2488,136 @@ namespace Mono.CSharp { public override void Emit (EmitContext ec) { if (am_storey != null) { - DefineAnonymousStorey (ec); + DefineStoreyContainer (ec, am_storey); am_storey.EmitStoreyInstantiation (ec, this); } - bool emit_debug_info = SymbolWriter.HasSymbolWriter && Parent != null && !(am_storey is IteratorStorey); - if (emit_debug_info) + if (scope_initializers != null) + EmitScopeInitializers (ec); + + if (ec.EmitAccurateDebugInfo && !IsCompilerGenerated && ec.Mark (StartLocation)) { + ec.Emit (OpCodes.Nop); + } + + if (Parent != null) ec.BeginScope (); - base.Emit (ec); + DoEmit (ec); - if (emit_debug_info) + if (Parent != null) ec.EndScope (); + + if (ec.EmitAccurateDebugInfo && !HasUnreachableClosingBrace && !IsCompilerGenerated && ec.Mark (EndLocation)) { + ec.Emit (OpCodes.Nop); + } } - void DefineAnonymousStorey (EmitContext ec) + protected void DefineStoreyContainer (EmitContext ec, AnonymousMethodStorey storey) { + if (ec.CurrentAnonymousMethod != null && ec.CurrentAnonymousMethod.Storey != null) { + storey.SetNestedStoryParent (ec.CurrentAnonymousMethod.Storey); + storey.Mutator = ec.CurrentAnonymousMethod.Storey.Mutator; + } + // // Creates anonymous method storey // - if (ec.CurrentAnonymousMethod != null && ec.CurrentAnonymousMethod.Storey != null) { + storey.CreateContainer (); + storey.DefineContainer (); + + if (Original.Explicit.HasCapturedThis && Original.ParametersBlock.TopBlock.ThisReferencesFromChildrenBlock != null) { + // - // Creates parent storey reference when hoisted this is accessible + // Only first storey in path will hold this reference. All children blocks will + // reference it indirectly using $ref field // - if (am_storey.OriginalSourceBlock.Explicit.HasCapturedThis) { - ExplicitBlock parent = am_storey.OriginalSourceBlock.Explicit.Parent.Explicit; + for (Block b = Original.Explicit.Parent; b != null; b = b.Parent) { + var s = b.Explicit.AnonymousMethodStorey; + if (s != null) { + storey.HoistedThis = s.HoistedThis; + break; + } + } - // - // Hoisted this exists in top-level parent storey only - // - while (parent.am_storey == null || parent.am_storey.Parent is AnonymousMethodStorey) - parent = parent.Parent.Explicit; + // + // We are the first storey on path and this has to be hoisted + // + if (storey.HoistedThis == null) { + foreach (ExplicitBlock ref_block in Original.ParametersBlock.TopBlock.ThisReferencesFromChildrenBlock) { + // + // ThisReferencesFromChildrenBlock holds all reference even if they + // are not on this path. It saves some memory otherwise it'd have to + // be in every explicit block. We run this check to see if the reference + // is valid for this storey + // + Block block_on_path = ref_block; + for (; block_on_path != null && block_on_path != Original; block_on_path = block_on_path.Parent); - am_storey.AddParentStoreyReference (ec, parent.am_storey); - } + if (block_on_path == null) + continue; - am_storey.SetNestedStoryParent (ec.CurrentAnonymousMethod.Storey); + if (storey.HoistedThis == null) + storey.AddCapturedThisField (ec); - // TODO MemberCache: Review - am_storey.Mutator = ec.CurrentAnonymousMethod.Storey.Mutator; - } + for (ExplicitBlock b = ref_block; b.AnonymousMethodStorey != storey; b = b.Parent.Explicit) { + if (b.AnonymousMethodStorey != null) { + b.AnonymousMethodStorey.AddParentStoreyReference (ec, storey); + b.AnonymousMethodStorey.HoistedThis = storey.HoistedThis; - am_storey.CreateType (); - am_storey.DefineType (); - am_storey.ResolveTypeParameters (); + // + // Stop propagation inside same top block + // + if (b.ParametersBlock == ParametersBlock.Original) + break; - var ref_blocks = am_storey.ReferencesFromChildrenBlock; + b = b.ParametersBlock; + } + + var pb = b as ParametersBlock; + if (pb != null && pb.StateMachine != null) { + if (pb.StateMachine == storey) + break; + + pb.StateMachine.AddParentStoreyReference (ec, storey); + } + + b.HasCapturedVariable = true; + } + } + } + } + + var ref_blocks = storey.ReferencesFromChildrenBlock; if (ref_blocks != null) { foreach (ExplicitBlock ref_block in ref_blocks) { - for (ExplicitBlock b = ref_block.Explicit; b.am_storey != am_storey; b = b.Parent.Explicit) { - if (b.am_storey != null) { - b.am_storey.AddParentStoreyReference (ec, am_storey); + for (ExplicitBlock b = ref_block; b.AnonymousMethodStorey != storey; b = b.Parent.Explicit) { + if (b.AnonymousMethodStorey != null) { + b.AnonymousMethodStorey.AddParentStoreyReference (ec, storey); + // // Stop propagation inside same top block - if (b.ParametersBlock.Original == ParametersBlock.Original) + // + if (b.ParametersBlock == ParametersBlock.Original) break; b = b.ParametersBlock; } + var pb = b as ParametersBlock; + if (pb != null && pb.StateMachine != null) { + if (pb.StateMachine == storey) + break; + + pb.StateMachine.AddParentStoreyReference (ec, storey); + } + b.HasCapturedVariable = true; } } } - am_storey.Define (); - am_storey.Parent.PartialContainer.AddCompilerGeneratedClass (am_storey); + storey.Define (); + storey.Parent.PartialContainer.AddCompilerGeneratedClass (storey); } public void RegisterAsyncAwait () @@ -2514,7 +2626,7 @@ namespace Mono.CSharp { while ((block.flags & Flags.AwaitBlock) == 0) { block.flags |= Flags.AwaitBlock; - if (block.Parent == null) + if (block is ParametersBlock) return; block = block.Parent.Explicit; @@ -2563,7 +2675,13 @@ namespace Mono.CSharp { #region Properties - public Block Block { + public ParametersBlock Block { + get { + return block; + } + } + + Block INamedBlockVariable.Block { get { return block; } @@ -2666,6 +2784,7 @@ namespace Mono.CSharp { bool resolved; protected bool unreachable; protected ToplevelBlock top_block; + protected StateMachine state_machine; public ParametersBlock (Block parent, ParametersCompiled parameters, Location start) : base (parent, 0, start, start) @@ -2705,6 +2824,7 @@ namespace Mono.CSharp { this.resolved = true; this.unreachable = source.unreachable; this.am_storey = source.am_storey; + this.state_machine = source.state_machine; ParametersBlock = this; @@ -2744,6 +2864,12 @@ namespace Mono.CSharp { } } + public StateMachine StateMachine { + get { + return state_machine; + } + } + public ToplevelBlock TopBlock { get { return top_block; @@ -2799,6 +2925,26 @@ namespace Mono.CSharp { return base.CreateExpressionTree (ec); } + public override void Emit (EmitContext ec) + { + if (state_machine != null && state_machine.OriginalSourceBlock != this) { + DefineStoreyContainer (ec, state_machine); + state_machine.EmitStoreyInstantiation (ec, this); + } + + base.Emit (ec); + } + + public void EmitEmbedded (EmitContext ec) + { + if (state_machine != null && state_machine.OriginalSourceBlock != this) { + DefineStoreyContainer (ec, state_machine); + state_machine.EmitStoreyInstantiation (ec, this); + } + + base.Emit (ec); + } + public ParameterInfo GetParameterInfo (Parameter p) { for (int i = 0; i < parameters.Count; ++i) { @@ -2809,7 +2955,7 @@ namespace Mono.CSharp { throw new ArgumentException ("Invalid parameter"); } - public Expression GetParameterReference (int index, Location loc) + public ParameterReference GetParameterReference (int index, Location loc) { return new ParameterReference (parameter_info[index], loc); } @@ -2860,7 +3006,7 @@ namespace Mono.CSharp { unreachable = top_level.End (); } } catch (Exception e) { - if (e is CompletionResult || rc.Report.IsDisabled) + if (e is CompletionResult || rc.Report.IsDisabled || e is FatalException) throw; if (rc.CurrentBlock != null) { @@ -2912,7 +3058,7 @@ namespace Mono.CSharp { for (int i = 0; i < orig_count; ++i) { Parameter.Modifier mod = parameters.FixedParameters[i].ModFlags; - if ((mod & Parameter.Modifier.OUT) != Parameter.Modifier.OUT) + if ((mod & Parameter.Modifier.OUT) == 0) continue; VariableInfo vi = new VariableInfo (parameters, i, ec.FlowOffset); @@ -2921,37 +3067,71 @@ namespace Mono.CSharp { } } - public void WrapIntoIterator (IMethodData method, TypeContainer host, TypeSpec iterator_type, bool is_enumerable) + public ToplevelBlock ConvertToIterator (IMethodData method, TypeDefinition host, TypeSpec iterator_type, bool is_enumerable) { - ParametersBlock pb = new ParametersBlock (this, ParametersCompiled.EmptyReadOnlyParameters, StartLocation); - pb.EndLocation = EndLocation; - pb.statements = statements; - pb.Original = this; + var iterator = new Iterator (this, method, host, iterator_type, is_enumerable); + var stateMachine = new IteratorStorey (iterator); - var iterator = new Iterator (pb, method, host, iterator_type, is_enumerable); - am_storey = new IteratorStorey (iterator); + state_machine = stateMachine; + iterator.SetStateMachine (stateMachine); - statements = new List (1); - AddStatement (new Return (iterator, iterator.Location)); - flags &= ~Flags.YieldBlock; + var tlb = new ToplevelBlock (host.Compiler, Parameters, Location.Null); + tlb.Original = this; + tlb.IsCompilerGenerated = true; + tlb.state_machine = stateMachine; + tlb.AddStatement (new Return (iterator, iterator.Location)); + return tlb; } - public void WrapIntoAsyncTask (IMemberContext context, TypeContainer host, TypeSpec returnType) + public ParametersBlock ConvertToAsyncTask (IMemberContext context, TypeDefinition host, ParametersCompiled parameters, TypeSpec returnType, Location loc) { - ParametersBlock pb = new ParametersBlock (this, ParametersCompiled.EmptyReadOnlyParameters, StartLocation); - pb.EndLocation = EndLocation; - pb.statements = statements; - pb.Original = this; + for (int i = 0; i < parameters.Count; i++) { + Parameter p = parameters[i]; + Parameter.Modifier mod = p.ModFlags; + if ((mod & Parameter.Modifier.RefOutMask) != 0) { + host.Compiler.Report.Error (1988, p.Location, + "Async methods cannot have ref or out parameters"); + return this; + } + + if (p is ArglistParameter) { + host.Compiler.Report.Error (4006, p.Location, + "__arglist is not allowed in parameter list of async methods"); + return this; + } + + if (parameters.Types[i].IsPointer) { + host.Compiler.Report.Error (4005, p.Location, + "Async methods cannot have unsafe parameters"); + return this; + } + } + + if (!HasAwait) { + host.Compiler.Report.Warning (1998, 1, loc, + "Async block lacks `await' operator and will run synchronously"); + } var block_type = host.Module.Compiler.BuiltinTypes.Void; - var initializer = new AsyncInitializer (pb, host, block_type); + var initializer = new AsyncInitializer (this, host, block_type); initializer.Type = block_type; - am_storey = new AsyncTaskStorey (context, initializer, returnType); + var stateMachine = new AsyncTaskStorey (this, context, initializer, returnType); - statements = new List (1); - AddStatement (new StatementExpression (initializer)); - flags &= ~Flags.AwaitBlock; + state_machine = stateMachine; + initializer.SetStateMachine (stateMachine); + + var b = this is ToplevelBlock ? + new ToplevelBlock (host.Compiler, Parameters, Location.Null) : + new ParametersBlock (Parent, parameters, Location.Null) { + IsAsync = true, + }; + + b.Original = this; + b.IsCompilerGenerated = true; + b.state_machine = stateMachine; + b.AddStatement (new StatementExpression (initializer)); + return b; } } @@ -2965,11 +3145,7 @@ namespace Mono.CSharp { Dictionary names; Dictionary labels; - public HoistedVariable HoistedThisVariable; - - public Report Report { - get { return compiler.Report; } - } + List this_references; public ToplevelBlock (CompilerContext ctx, Location loc) : this (ctx, ParametersCompiled.EmptyReadOnlyParameters, loc) @@ -2981,6 +3157,7 @@ namespace Mono.CSharp { { this.compiler = ctx; top_block = this; + flags |= Flags.HasRet; ProcessParameters (); } @@ -2996,6 +3173,7 @@ namespace Mono.CSharp { { this.compiler = source.TopBlock.compiler; top_block = this; + flags |= Flags.HasRet; } public bool IsIterator { @@ -3004,7 +3182,32 @@ namespace Mono.CSharp { } } - public override void AddLocalName (string name, INamedBlockVariable li) + public Report Report { + get { + return compiler.Report; + } + } + + // + // Used by anonymous blocks to track references of `this' variable + // + public List ThisReferencesFromChildrenBlock { + get { + return this_references; + } + } + + // + // Returns the "this" instance variable of this block. + // See AddThisVariable() for more information. + // + public LocalVariable ThisVariable { + get { + return this_variable; + } + } + + public void AddLocalName (string name, INamedBlockVariable li, bool ignoreChildrenBlocks) { if (names == null) names = new Dictionary (); @@ -3030,31 +3233,32 @@ namespace Mono.CSharp { // for (int i = 0; i < existing_list.Count; ++i) { existing = existing_list[i]; - Block b = existing.Block; + Block b = existing.Block.Explicit; // Collision at same level - if (li.Block == b) { + if (li.Block.Explicit == b) { li.Block.Error_AlreadyDeclared (name, li); break; } // Collision with parent - b = li.Block; - while ((b = b.Parent) != null) { - if (existing.Block == b) { + Block parent = li.Block.Explicit; + while ((parent = parent.Parent) != null) { + if (parent == b) { li.Block.Error_AlreadyDeclared (name, li, "parent or current"); i = existing_list.Count; break; } } - // Collision with with children - b = existing.Block; - while ((b = b.Parent) != null) { - if (li.Block == b) { - li.Block.Error_AlreadyDeclared (name, li, "child"); - i = existing_list.Count; - break; + if (!ignoreChildrenBlocks) { + // Collision with children + while ((b = b.Parent) != null) { + if (li.Block.Explicit == b) { + li.Block.Error_AlreadyDeclared (name, li, "child"); + i = existing_list.Count; + break; + } } } } @@ -3123,6 +3327,20 @@ namespace Mono.CSharp { existing_list.Add (label); } + public void AddThisReferenceFromChildrenBlock (ExplicitBlock block) + { + if (this_references == null) + this_references = new List (); + + if (!this_references.Contains (block)) + this_references.Add (block); + } + + public void RemoveThisReferenceFromChildrenBlock (ExplicitBlock block) + { + this_references.Remove (block); + } + // // Creates an arguments set from all parameters, useful for method proxy calls // @@ -3233,14 +3451,6 @@ namespace Mono.CSharp { return null; } - // - // Returns the "this" instance variable of this block. - // See AddThisVariable() for more information. - // - public LocalVariable ThisVariable { - get { return this_variable; } - } - // // This is used by non-static `struct' constructors which do not have an // initializer - in this case, the constructor must initialize all of the @@ -3271,36 +3481,37 @@ namespace Mono.CSharp { #if PRODUCTION try { #endif + if (IsCompilerGenerated) { + using (ec.With (BuilderContext.Options.OmitDebugInfo, true)) { + base.Emit (ec); + } + } else { + base.Emit (ec); + } - base.Emit (ec); + // + // If `HasReturnLabel' is set, then we already emitted a + // jump to the end of the method, so we must emit a `ret' + // there. + // + // Unfortunately, System.Reflection.Emit automatically emits + // a leave to the end of a finally block. This is a problem + // if no code is following the try/finally block since we may + // jump to a point after the end of the method. + // As a workaround, we're always creating a return label in + // this case. + // + if (ec.HasReturnLabel || !unreachable) { + if (ec.HasReturnLabel) + ec.MarkLabel (ec.ReturnLabel); - ec.Mark (EndLocation); + if (ec.EmitAccurateDebugInfo && !IsCompilerGenerated) + ec.Mark (EndLocation); - if (ec.HasReturnLabel) - ec.MarkLabel (ec.ReturnLabel); + if (ec.ReturnType.Kind != MemberKind.Void) + ec.Emit (OpCodes.Ldloc, ec.TemporaryReturn ()); - if (ec.return_value != null) { - ec.Emit (OpCodes.Ldloc, ec.return_value); ec.Emit (OpCodes.Ret); - } else { - // - // If `HasReturnLabel' is set, then we already emitted a - // jump to the end of the method, so we must emit a `ret' - // there. - // - // Unfortunately, System.Reflection.Emit automatically emits - // a leave to the end of a finally block. This is a problem - // if no code is following the try/finally block since we may - // jump to a point after the end of the method. - // As a workaround, we're always creating a return label in - // this case. - // - - if (ec.HasReturnLabel || !unreachable) { - if (ec.ReturnType.Kind != MemberKind.Void) - ec.Emit (OpCodes.Ldloc, ec.TemporaryReturn ()); - ec.Emit (OpCodes.Ret); - } } #if PRODUCTION @@ -3313,15 +3524,6 @@ namespace Mono.CSharp { } #endif } - - protected override void EmitSymbolInfo (EmitContext ec) - { - AnonymousExpression ae = ec.CurrentAnonymousMethod; - if ((ae != null) && (ae.Storey != null)) - SymbolWriter.DefineScopeVariable (ae.Storey.ID); - - base.EmitSymbolInfo (ec); - } } public class SwitchLabel { @@ -3552,7 +3754,6 @@ namespace Mono.CSharp { VariableReference value; ExpressionStatement string_dictionary; FieldExpr switch_cache_field; - static int unique_counter; ExplicitBlock block; // @@ -3913,11 +4114,6 @@ namespace Mono.CSharp { return null; } - public static void Reset () - { - unique_counter = 0; - } - public override bool Resolve (BlockContext ec) { Expr = Expr.Resolve (ec); @@ -4061,7 +4257,10 @@ namespace Mono.CSharp { } } - simple_stmt = new If (cond, s.Block, simple_stmt, loc); + // + // Compiler generated, hide from symbol file + // + simple_stmt = new If (cond, s.Block, simple_stmt, Location.Null); } // It's null for empty switch @@ -4090,7 +4289,7 @@ namespace Mono.CSharp { var ctype = ec.CurrentMemberDefinition.Parent.PartialContainer; Field field = new Field (ctype, string_dictionary_type, Modifiers.STATIC | Modifiers.PRIVATE | Modifiers.COMPILER_GENERATED, - new MemberName (CompilerGeneratedClass.MakeName (null, "f", "switch$map", unique_counter++), loc), null); + new MemberName (CompilerGeneratedContainer.MakeName (null, "f", "switch$map", ec.Module.CounterSwitchTypes++), loc), null); if (!field.Define ()) return; ctype.AddField (field); @@ -4149,7 +4348,9 @@ namespace Mono.CSharp { // Check if string dictionary is initialized and initialize // switch_cache_field.EmitBranchable (ec, l_initialized, true); - string_dictionary.EmitStatement (ec); + using (ec.With (BuilderContext.Options.OmitDebugInfo, true)) { + string_dictionary.EmitStatement (ec); + } ec.MarkLabel (l_initialized); LocalTemporary string_switch_variable = new LocalTemporary (ec.BuiltinTypes.Int); @@ -4193,6 +4394,9 @@ namespace Mono.CSharp { protected override void DoEmit (EmitContext ec) { + // Workaround broken flow-analysis + block.HasUnreachableClosingBrace = true; + // // Needed to emit anonymous storey initialization // Otherwise it does not contain any statements for now @@ -4288,6 +4492,7 @@ namespace Mono.CSharp { protected Statement stmt; Label dispose_try_block; bool prepared_for_dispose, emitted_dispose; + Method finally_host; protected TryFinallyBlock (Statement stmt, Location loc) : base (loc) @@ -4306,7 +4511,7 @@ namespace Mono.CSharp { #endregion protected abstract void EmitTryBody (EmitContext ec); - protected abstract void EmitFinallyBody (EmitContext ec); + public abstract void EmitFinallyBody (EmitContext ec); public override Label PrepareForDispose (EmitContext ec, Label end) { @@ -4334,7 +4539,14 @@ namespace Mono.CSharp { } ec.MarkLabel (start_finally); - EmitFinallyBody (ec); + + if (finally_host != null) { + var ce = new CallEmitter (); + ce.InstanceExpression = new CompilerGeneratedThis (ec.CurrentType, loc); + ce.EmitPredefined (ec, finally_host.Spec, new Arguments (0)); + } else { + EmitFinallyBody (ec); + } ec.EndExceptionBlock (); } @@ -4378,12 +4590,10 @@ namespace Mono.CSharp { bool emit_dispatcher = j < labels.Length; if (emit_dispatcher) { - //SymbolWriter.StartIteratorDispatcher (ec.ig); ec.Emit (OpCodes.Ldloc, pc); ec.EmitInt (first_resume_pc); ec.Emit (OpCodes.Sub); ec.Emit (OpCodes.Switch, labels); - //SymbolWriter.EndIteratorDispatcher (ec.ig); } foreach (ResumableStatement s in resume_points) @@ -4394,10 +4604,34 @@ namespace Mono.CSharp { ec.BeginFinallyBlock (); - EmitFinallyBody (ec); + if (finally_host != null) { + var ce = new CallEmitter (); + ce.InstanceExpression = new CompilerGeneratedThis (ec.CurrentType, loc); + ce.EmitPredefined (ec, finally_host.Spec, new Arguments (0)); + } else { + EmitFinallyBody (ec); + } ec.EndExceptionBlock (); } + + public override bool Resolve (BlockContext bc) + { + // + // Finally block inside iterator is called from MoveNext and + // Dispose methods that means we need to lift the block into + // newly created host method to emit the body only once. The + // original block then simply calls the newly generated method. + // + if (bc.CurrentIterator != null && !bc.IsInProbingMode) { + var b = stmt as Block; + if (b != null && b.Explicit.HasYield) { + finally_host = bc.CurrentIterator.CreateFinallyHost (this); + } + } + + return base.Resolve (bc); + } } // @@ -4586,7 +4820,7 @@ namespace Mono.CSharp { Statement.Emit (ec); } - protected override void EmitFinallyBody (EmitContext ec) + public override void EmitFinallyBody (EmitContext ec) { // // if (lock_taken) Monitor.Exit (expr_copy) @@ -5100,17 +5334,13 @@ namespace Mono.CSharp { // if (li.HoistedVariant != null) { LocalTemporary lt = new LocalTemporary (li.Type); - SymbolWriter.OpenCompilerGeneratedBlock (ec); lt.Store (ec); - SymbolWriter.CloseCompilerGeneratedBlock (ec); // switch to assigning from the temporary variable and not from top of the stack assign.UpdateSource (lt); } } else { - SymbolWriter.OpenCompilerGeneratedBlock (ec); ec.Emit (OpCodes.Pop); - SymbolWriter.CloseCompilerGeneratedBlock (ec); } Block.Emit (ec); @@ -5135,8 +5365,11 @@ namespace Mono.CSharp { if (li.Type.IsGenericParameter) source = new UnboxCast (source, li.Type); - assign = new CompilerAssign (new LocalVariableReference (li, loc), source, loc); - Block.AddScopeStatement (new StatementExpression (assign)); + // + // Uses Location.Null to hide from symbol file + // + assign = new CompilerAssign (new LocalVariableReference (li, Location.Null), source, Location.Null); + Block.AddScopeStatement (new StatementExpression (assign, Location.Null)); } } @@ -5190,6 +5423,7 @@ namespace Mono.CSharp { if (ok) ec.CurrentBranching.CreateSibling (fini, FlowBranching.SiblingType.Finally); + using (ec.With (ResolveContext.Options.FinallyScope, true)) { if (!fini.Resolve (ec)) ok = false; @@ -5207,7 +5441,7 @@ namespace Mono.CSharp { stmt.Emit (ec); } - protected override void EmitFinallyBody (EmitContext ec) + public override void EmitFinallyBody (EmitContext ec) { fini.Emit (ec); } @@ -5462,11 +5696,14 @@ namespace Mono.CSharp { new Cast (new TypeExpression (idt, loc), lvr, loc).Resolve (bc) : lvr; - Statement dispose = new StatementExpression (new Invocation (dispose_mg, null)); + // + // Hide it from symbol file via null location + // + Statement dispose = new StatementExpression (new Invocation (dispose_mg, null), Location.Null); // Add conditional call when disposing possible null variable if (!type.IsStruct || type.IsNullableType) - dispose = new If (new Binary (Binary.Operator.Inequality, lvr, new NullLiteral (loc), loc), dispose, loc); + dispose = new If (new Binary (Binary.Operator.Inequality, lvr, new NullLiteral (loc), loc), dispose, dispose.loc); return dispose; } @@ -5529,6 +5766,14 @@ namespace Mono.CSharp { #endregion + public override void Emit (EmitContext ec) + { + // + // Don't emit sequence point it will be set on variable declaration + // + DoEmit (ec); + } + protected override void EmitTryBodyPrepare (EmitContext ec) { decl.Emit (ec); @@ -5540,7 +5785,7 @@ namespace Mono.CSharp { stmt.Emit (ec); } - protected override void EmitFinallyBody (EmitContext ec) + public override void EmitFinallyBody (EmitContext ec) { decl.EmitDispose (ec); } @@ -5606,27 +5851,43 @@ namespace Mono.CSharp { /// public class Foreach : Statement { - sealed class ArrayForeach : Statement + abstract class IteratorStatement : Statement { - readonly Foreach for_each; - readonly Statement statement; + protected readonly Foreach for_each; + + protected IteratorStatement (Foreach @foreach) + { + this.for_each = @foreach; + this.loc = @foreach.expr.Location; + } + + protected override void CloneTo (CloneContext clonectx, Statement target) + { + throw new NotImplementedException (); + } + + public override void Emit (EmitContext ec) + { + if (ec.EmitAccurateDebugInfo) { + ec.Emit (OpCodes.Nop); + } - Expression conv; + base.Emit (ec); + } + } + + sealed class ArrayForeach : IteratorStatement + { TemporaryVariableReference[] lengths; Expression [] length_exprs; StatementExpression[] counter; TemporaryVariableReference[] variables; TemporaryVariableReference copy; - Expression access; - LocalVariableReference variable; public ArrayForeach (Foreach @foreach, int rank) + : base (@foreach) { - for_each = @foreach; - statement = for_each.statement; - loc = @foreach.loc; - counter = new StatementExpression[rank]; variables = new TemporaryVariableReference[rank]; length_exprs = new Expression [rank]; @@ -5639,11 +5900,6 @@ namespace Mono.CSharp { lengths = new TemporaryVariableReference [rank]; } - protected override void CloneTo (CloneContext clonectx, Statement target) - { - throw new NotImplementedException (); - } - public override bool Resolve (BlockContext ec) { Block variables_block = for_each.variable.Block; @@ -5655,7 +5911,7 @@ namespace Mono.CSharp { for (int i = 0; i < rank; i++) { var v = TemporaryVariableReference.Create (ec.BuiltinTypes.Int, variables_block, loc); variables[i] = v; - counter[i] = new StatementExpression (new UnaryMutator (UnaryMutator.Mode.PostIncrement, v, loc)); + counter[i] = new StatementExpression (new UnaryMutator (UnaryMutator.Mode.PostIncrement, v, Location.Null)); counter[i].Resolve (ec); if (rank == 1) { @@ -5672,7 +5928,7 @@ namespace Mono.CSharp { list.Add (new Argument (v)); } - access = new ElementAccess (copy, list, loc).Resolve (ec); + var access = new ElementAccess (copy, list, loc).Resolve (ec); if (access == null) return false; @@ -5682,26 +5938,30 @@ namespace Mono.CSharp { var_type = access.Type; } else { var_type = for_each.type.ResolveAsType (ec); + + if (var_type == null) + return false; + + access = Convert.ExplicitConversion (ec, access, var_type, loc); + if (access == null) + return false; } - if (var_type == null) - return false; + for_each.variable.Type = var_type; - conv = Convert.ExplicitConversion (ec, access, var_type, loc); - if (conv == null) + var variable_ref = new LocalVariableReference (for_each.variable, loc).Resolve (ec); + if (variable_ref == null) return false; + for_each.body.AddScopeStatement (new StatementExpression (new CompilerAssign (variable_ref, access, Location.Null), for_each.variable.Location)); + bool ok = true; ec.StartFlowBranching (FlowBranching.BranchingType.Loop, loc); ec.CurrentBranching.CreateSibling (); - for_each.variable.Type = conv.Type; - variable = new LocalVariableReference (for_each.variable, loc); - variable.Resolve (ec); - ec.StartFlowBranching (FlowBranching.BranchingType.Embedded, loc); - if (!statement.Resolve (ec)) + if (!for_each.body.Resolve (ec)) ok = false; ec.EndFlowBranching (); @@ -5737,12 +5997,10 @@ namespace Mono.CSharp { ec.MarkLabel (loop [i]); } - variable.local_info.CreateBuilder (ec); - variable.EmitAssign (ec, conv, false, false); - - statement.Emit (ec); + for_each.body.Emit (ec); ec.MarkLabel (ec.LoopBegin); + ec.Mark (for_each.expr.Location); for (int i = rank - 1; i >= 0; i--){ counter [i].Emit (ec); @@ -5762,59 +6020,8 @@ namespace Mono.CSharp { } } - sealed class CollectionForeach : Statement, OverloadResolver.IErrorHandler + sealed class CollectionForeach : IteratorStatement, OverloadResolver.IErrorHandler { - class Body : Statement - { - TypeSpec type; - LocalVariableReference variable; - Expression current, conv; - Statement statement; - - public Body (TypeSpec type, LocalVariable variable, - Expression current, Statement statement, - Location loc) - { - this.type = type; - this.variable = new LocalVariableReference (variable, loc); - this.current = current; - this.statement = statement; - this.loc = loc; - } - - protected override void CloneTo (CloneContext clonectx, Statement target) - { - throw new NotImplementedException (); - } - - public override bool Resolve (BlockContext ec) - { - current = current.Resolve (ec); - if (current == null) - return false; - - conv = Convert.ExplicitConversion (ec, current, type, loc); - if (conv == null) - return false; - - variable.local_info.Type = conv.Type; - variable.Resolve (ec); - - if (!statement.Resolve (ec)) - return false; - - return true; - } - - protected override void DoEmit (EmitContext ec) - { - variable.local_info.CreateBuilder (ec); - variable.EmitAssign (ec, conv, false, false); - - statement.Emit (ec); - } - } - class RuntimeDispose : Using.VariableDeclaration { public RuntimeDispose (LocalVariable lv, Location loc) @@ -5857,23 +6064,15 @@ namespace Mono.CSharp { LocalVariable variable; Expression expr; Statement statement; - Expression var_type; ExpressionStatement init; TemporaryVariableReference enumerator_variable; bool ambiguous_getenumerator_name; - public CollectionForeach (Expression var_type, LocalVariable var, Expression expr, Statement stmt, Location l) + public CollectionForeach (Foreach @foreach, LocalVariable var, Expression expr) + : base (@foreach) { - this.var_type = var_type; this.variable = var; this.expr = expr; - statement = stmt; - loc = l; - } - - protected override void CloneTo (CloneContext clonectx, Statement target) - { - throw new NotImplementedException (); } void Error_WrongEnumerator (ResolveContext rc, MethodSpec enumerator) @@ -5952,9 +6151,11 @@ namespace Mono.CSharp { } while (t != null); if (iface_candidate == null) { - rc.Report.Error (1579, loc, - "foreach statement cannot operate on variables of type `{0}' because it does not contain a definition for `{1}' or is inaccessible", - expr.Type.GetSignatureForError (), "GetEnumerator"); + if (expr.Type != InternalType.ErrorType) { + rc.Report.Error (1579, loc, + "foreach statement cannot operate on variables of type `{0}' because it does not contain a definition for `{1}' or is inaccessible", + expr.Type.GetSignatureForError (), "GetEnumerator"); + } return null; } @@ -5979,7 +6180,7 @@ namespace Mono.CSharp { return null; } - return MethodGroupExpr.CreatePredefined (ms, enumerator.ReturnType, loc); + return MethodGroupExpr.CreatePredefined (ms, enumerator.ReturnType, expr.Location); } PropertySpec ResolveCurrent (ResolveContext rc, MethodSpec enumerator) @@ -6033,7 +6234,7 @@ namespace Mono.CSharp { if (current_pe == null) return false; - VarExpr ve = var_type as VarExpr; + VarExpr ve = for_each.type as VarExpr; if (ve != null) { if (is_dynamic) { @@ -6049,16 +6250,26 @@ namespace Mono.CSharp { current_pe = EmptyCast.Create (current_pe, ec.BuiltinTypes.Dynamic); } - variable.Type = var_type.ResolveAsType (ec); + variable.Type = for_each.type.ResolveAsType (ec); + + if (variable.Type == null) + return false; + + current_pe = Convert.ExplicitConversion (ec, current_pe, variable.Type, loc); + if (current_pe == null) + return false; } - if (variable.Type == null) + var variable_ref = new LocalVariableReference (variable, loc).Resolve (ec); + if (variable_ref == null) return false; + for_each.body.AddScopeStatement (new StatementExpression (new CompilerAssign (variable_ref, current_pe, Location.Null), variable.Location)); + var init = new Invocation (get_enumerator_mg, null); statement = new While (new BooleanExpression (new Invocation (move_next_mg, null)), - new Body (variable.Type, variable, current_pe, statement, loc), loc); + for_each.body, Location.Null); var enum_type = enumerator_variable.Type; @@ -6070,23 +6281,23 @@ namespace Mono.CSharp { // // Runtime Dispose check // - var vd = new RuntimeDispose (enumerator_variable.LocalInfo, loc); + var vd = new RuntimeDispose (enumerator_variable.LocalInfo, Location.Null); vd.Initializer = init; - statement = new Using (vd, statement, loc); + statement = new Using (vd, statement, Location.Null); } else { // // No Dispose call needed // - this.init = new SimpleAssign (enumerator_variable, init); + this.init = new SimpleAssign (enumerator_variable, init, Location.Null); this.init.Resolve (ec); } } else { // // Static Dispose check // - var vd = new Using.VariableDeclaration (enumerator_variable.LocalInfo, loc); + var vd = new Using.VariableDeclaration (enumerator_variable.LocalInfo, Location.Null); vd.Initializer = init; - statement = new Using (vd, statement, loc); + statement = new Using (vd, statement, Location.Null); } return statement.Resolve (ec); @@ -6107,7 +6318,7 @@ namespace Mono.CSharp { bool OverloadResolver.IErrorHandler.AmbiguousCandidates (ResolveContext ec, MemberSpec best, MemberSpec ambiguous) { ec.Report.SymbolRelatedToPreviousError (best); - ec.Report.Warning (278, 2, loc, + ec.Report.Warning (278, 2, expr.Location, "`{0}' contains ambiguous implementation of `{1}' pattern. Method `{2}' is ambiguous with method `{3}'", expr.Type.GetSignatureForError (), "enumerable", best.GetSignatureForError (), ambiguous.GetSignatureForError ()); @@ -6138,13 +6349,15 @@ namespace Mono.CSharp { LocalVariable variable; Expression expr; Statement statement; + Block body; - public Foreach (Expression type, LocalVariable var, Expression expr, Statement stmt, Location l) + public Foreach (Expression type, LocalVariable var, Expression expr, Statement stmt, Block body, Location l) { this.type = type; this.variable = var; this.expr = expr; - statement = stmt; + this.statement = stmt; + this.body = body; loc = l; } @@ -6164,7 +6377,6 @@ namespace Mono.CSharp { get { return variable; } } - public override bool Resolve (BlockContext ec) { expr = expr.Resolve (ec); @@ -6176,6 +6388,8 @@ namespace Mono.CSharp { return false; } + body.AddStatement (statement); + if (expr.Type.BuiltinType == BuiltinTypeSpec.Type.String) { statement = new ArrayForeach (this, 1); } else if (expr.Type is ArrayContainer) { @@ -6187,7 +6401,7 @@ namespace Mono.CSharp { return false; } - statement = new CollectionForeach (type, variable, expr, statement, loc); + statement = new CollectionForeach (this, variable, expr); } return statement.Resolve (ec); @@ -6195,6 +6409,8 @@ namespace Mono.CSharp { protected override void DoEmit (EmitContext ec) { + variable.CreateBuilder (ec); + Label old_begin = ec.LoopBegin, old_end = ec.LoopEnd; ec.LoopBegin = ec.DefineLabel (); ec.LoopEnd = ec.DefineLabel (); @@ -6211,6 +6427,7 @@ namespace Mono.CSharp { target.type = type.Clone (clonectx); target.expr = expr.Clone (clonectx); + target.body = (Block) body.Clone (clonectx); target.statement = statement.Clone (clonectx); } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/support.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/support.cs index 90604ea4db..35762dfeae 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/support.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/support.cs @@ -37,7 +37,7 @@ namespace Mono.CSharp { return System.Runtime.CompilerServices.RuntimeHelpers.GetHashCode (obj); } } -#if !NET_4_0 +#if !NET_4_0 && !MONODROID public class Tuple : IEquatable> { public Tuple (T1 item1, T2 item2) diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/symbolwriter.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/symbolwriter.cs index ce19cfc492..933d69e085 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/symbolwriter.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/symbolwriter.cs @@ -92,11 +92,10 @@ namespace Mono.CSharp } } - public static SourceMethodBuilder OpenMethod (ICompileUnit file, int ns_id, - IMethodDef method) + public static SourceMethodBuilder OpenMethod (ICompileUnit file, IMethodDef method) { if (symwriter != null) - return symwriter.OpenMethod (file, ns_id, method); + return symwriter.OpenMethod (file, -1 /* Not used */, method); else return null; } @@ -125,15 +124,6 @@ namespace Mono.CSharp } } - public static int DefineNamespace (string name, CompileUnitEntry source, - string[] using_clauses, int parent) - { - if (symwriter != null) - return symwriter.DefineNamespace (name, source, using_clauses, parent); - else - return -1; - } - public static void DefineAnonymousScope (int id) { if (symwriter != null) @@ -232,8 +222,7 @@ namespace Mono.CSharp if (symwriter != null) { SourceFileEntry file = loc.SourceFile.SourceFileEntry; int offset = GetILOffset (ig); - symwriter.MarkSequencePoint ( - offset, file, loc.Row, loc.Column, loc.Hidden); + symwriter.MarkSequencePoint (offset, file, loc.Row, loc.Column, false); } } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/typemanager.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/typemanager.cs index 51bc5326bc..6eb3fc6e44 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/typemanager.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/typemanager.cs @@ -148,7 +148,7 @@ namespace Mono.CSharp if (found == null || found == p) continue; - var tc = found.MemberDefinition as TypeContainer; + var tc = found.MemberDefinition as TypeDefinition; if (tc != null) { var ns = module.GlobalRootNamespace.GetNamespace (p.Namespace, false); ns.SetBuiltinType (p); @@ -228,6 +228,9 @@ namespace Mono.CSharp public readonly PredefinedType Action; public readonly PredefinedType Task; public readonly PredefinedType TaskGeneric; + public readonly PredefinedType IAsyncStateMachine; + public readonly PredefinedType INotifyCompletion; + public readonly PredefinedType ICriticalNotifyCompletion; public PredefinedTypes (ModuleContainer module) { @@ -276,6 +279,9 @@ namespace Mono.CSharp AsyncTaskMethodBuilderGeneric = new PredefinedType (module, MemberKind.Struct, "System.Runtime.CompilerServices", "AsyncTaskMethodBuilder", 1); Task = new PredefinedType (module, MemberKind.Class, "System.Threading.Tasks", "Task"); TaskGeneric = new PredefinedType (module, MemberKind.Class, "System.Threading.Tasks", "Task", 1); + IAsyncStateMachine = new PredefinedType (module, MemberKind.Interface, "System.Runtime.CompilerServices", "IAsyncStateMachine"); + INotifyCompletion = new PredefinedType (module, MemberKind.Interface, "System.Runtime.CompilerServices", "INotifyCompletion"); + ICriticalNotifyCompletion = new PredefinedType (module, MemberKind.Interface, "System.Runtime.CompilerServices", "ICriticalNotifyCompletion"); // // Define types which are used for comparison. It does not matter @@ -312,16 +318,29 @@ namespace Mono.CSharp { public readonly PredefinedMember ActivatorCreateInstance; public readonly PredefinedMember AsyncTaskMethodBuilderCreate; + public readonly PredefinedMember AsyncTaskMethodBuilderStart; public readonly PredefinedMember AsyncTaskMethodBuilderSetResult; public readonly PredefinedMember AsyncTaskMethodBuilderSetException; + public readonly PredefinedMember AsyncTaskMethodBuilderSetStateMachine; + public readonly PredefinedMember AsyncTaskMethodBuilderOnCompleted; + public readonly PredefinedMember AsyncTaskMethodBuilderOnCompletedUnsafe; public readonly PredefinedMember AsyncTaskMethodBuilderTask; public readonly PredefinedMember AsyncTaskMethodBuilderGenericCreate; + public readonly PredefinedMember AsyncTaskMethodBuilderGenericStart; public readonly PredefinedMember AsyncTaskMethodBuilderGenericSetResult; public readonly PredefinedMember AsyncTaskMethodBuilderGenericSetException; + public readonly PredefinedMember AsyncTaskMethodBuilderGenericSetStateMachine; + public readonly PredefinedMember AsyncTaskMethodBuilderGenericOnCompleted; + public readonly PredefinedMember AsyncTaskMethodBuilderGenericOnCompletedUnsafe; public readonly PredefinedMember AsyncTaskMethodBuilderGenericTask; public readonly PredefinedMember AsyncVoidMethodBuilderCreate; + public readonly PredefinedMember AsyncVoidMethodBuilderStart; public readonly PredefinedMember AsyncVoidMethodBuilderSetException; public readonly PredefinedMember AsyncVoidMethodBuilderSetResult; + public readonly PredefinedMember AsyncVoidMethodBuilderSetStateMachine; + public readonly PredefinedMember AsyncVoidMethodBuilderOnCompleted; + public readonly PredefinedMember AsyncVoidMethodBuilderOnCompletedUnsafe; + public readonly PredefinedMember DebuggerBrowsableAttributeCtor; public readonly PredefinedMember DecimalCtor; public readonly PredefinedMember DecimalCtorInt; public readonly PredefinedMember DecimalCtorLong; @@ -362,6 +381,8 @@ namespace Mono.CSharp var atypes = module.PredefinedAttributes; var btypes = module.Compiler.BuiltinTypes; + var tp = new TypeParameter (0, new MemberName ("T"), null, null, Variance.None); + ActivatorCreateInstance = new PredefinedMember (module, types.Activator, MemberFilter.Method ("CreateInstance", 1, ParametersCompiled.EmptyReadOnlyParameters, null)); @@ -371,10 +392,52 @@ namespace Mono.CSharp AsyncTaskMethodBuilderSetResult = new PredefinedMember (module, types.AsyncTaskMethodBuilder, MemberFilter.Method ("SetResult", 0, ParametersCompiled.EmptyReadOnlyParameters, btypes.Void)); + AsyncTaskMethodBuilderSetStateMachine = new PredefinedMember (module, types.AsyncTaskMethodBuilder, + "SetStateMachine", MemberKind.Method, () => new[] { + types.IAsyncStateMachine.TypeSpec + }, btypes.Void); + AsyncTaskMethodBuilderSetException = new PredefinedMember (module, types.AsyncTaskMethodBuilder, MemberFilter.Method ("SetException", 0, ParametersCompiled.CreateFullyResolved (btypes.Exception), btypes.Void)); + AsyncTaskMethodBuilderOnCompleted = new PredefinedMember (module, types.AsyncTaskMethodBuilder, + MemberFilter.Method ("AwaitOnCompleted", 2, + new ParametersImported ( + new[] { + new ParameterData (null, Parameter.Modifier.REF), + new ParameterData (null, Parameter.Modifier.REF) + }, + new[] { + new TypeParameterSpec (0, tp, SpecialConstraint.None, Variance.None, null), + new TypeParameterSpec (1, tp, SpecialConstraint.None, Variance.None, null) + }, false), + btypes.Void)); + + AsyncTaskMethodBuilderOnCompletedUnsafe = new PredefinedMember (module, types.AsyncTaskMethodBuilder, + MemberFilter.Method ("AwaitUnsafeOnCompleted", 2, + new ParametersImported ( + new[] { + new ParameterData (null, Parameter.Modifier.REF), + new ParameterData (null, Parameter.Modifier.REF) + }, + new[] { + new TypeParameterSpec (0, tp, SpecialConstraint.None, Variance.None, null), + new TypeParameterSpec (1, tp, SpecialConstraint.None, Variance.None, null) + }, false), + btypes.Void)); + + AsyncTaskMethodBuilderStart = new PredefinedMember (module, types.AsyncTaskMethodBuilder, + MemberFilter.Method ("Start", 1, + new ParametersImported ( + new[] { + new ParameterData (null, Parameter.Modifier.REF), + }, + new[] { + new TypeParameterSpec (0, tp, SpecialConstraint.None, Variance.None, null), + }, false), + btypes.Void)); + AsyncTaskMethodBuilderTask = new PredefinedMember (module, types.AsyncTaskMethodBuilder, MemberFilter.Property ("Task", null)); @@ -384,12 +447,54 @@ namespace Mono.CSharp AsyncTaskMethodBuilderGenericSetResult = new PredefinedMember (module, types.AsyncTaskMethodBuilderGeneric, "SetResult", MemberKind.Method, () => new TypeSpec[] { types.AsyncTaskMethodBuilderGeneric.TypeSpec.MemberDefinition.TypeParameters[0] - }); + }, btypes.Void); + + AsyncTaskMethodBuilderGenericSetStateMachine = new PredefinedMember (module, types.AsyncTaskMethodBuilderGeneric, + "SetStateMachine", MemberKind.Method, () => new[] { + types.IAsyncStateMachine.TypeSpec + }, btypes.Void); AsyncTaskMethodBuilderGenericSetException = new PredefinedMember (module, types.AsyncTaskMethodBuilderGeneric, MemberFilter.Method ("SetException", 0, ParametersCompiled.CreateFullyResolved (btypes.Exception), btypes.Void)); + AsyncTaskMethodBuilderGenericOnCompleted = new PredefinedMember (module, types.AsyncTaskMethodBuilderGeneric, + MemberFilter.Method ("AwaitOnCompleted", 2, + new ParametersImported ( + new[] { + new ParameterData (null, Parameter.Modifier.REF), + new ParameterData (null, Parameter.Modifier.REF) + }, + new[] { + new TypeParameterSpec (0, tp, SpecialConstraint.None, Variance.None, null), + new TypeParameterSpec (1, tp, SpecialConstraint.None, Variance.None, null) + }, false), + btypes.Void)); + + AsyncTaskMethodBuilderGenericOnCompletedUnsafe = new PredefinedMember (module, types.AsyncTaskMethodBuilderGeneric, + MemberFilter.Method ("AwaitUnsafeOnCompleted", 2, + new ParametersImported ( + new[] { + new ParameterData (null, Parameter.Modifier.REF), + new ParameterData (null, Parameter.Modifier.REF) + }, + new[] { + new TypeParameterSpec (0, tp, SpecialConstraint.None, Variance.None, null), + new TypeParameterSpec (1, tp, SpecialConstraint.None, Variance.None, null) + }, false), + btypes.Void)); + + AsyncTaskMethodBuilderGenericStart = new PredefinedMember (module, types.AsyncTaskMethodBuilderGeneric, + MemberFilter.Method ("Start", 1, + new ParametersImported ( + new[] { + new ParameterData (null, Parameter.Modifier.REF), + }, + new[] { + new TypeParameterSpec (0, tp, SpecialConstraint.None, Variance.None, null), + }, false), + btypes.Void)); + AsyncTaskMethodBuilderGenericTask = new PredefinedMember (module, types.AsyncTaskMethodBuilderGeneric, MemberFilter.Property ("Task", null)); @@ -402,6 +507,51 @@ namespace Mono.CSharp AsyncVoidMethodBuilderSetResult = new PredefinedMember (module, types.AsyncVoidMethodBuilder, MemberFilter.Method ("SetResult", 0, ParametersCompiled.EmptyReadOnlyParameters, btypes.Void)); + AsyncVoidMethodBuilderSetStateMachine = new PredefinedMember (module, types.AsyncVoidMethodBuilder, + "SetStateMachine", MemberKind.Method, () => new[] { + types.IAsyncStateMachine.TypeSpec + }, btypes.Void); + + AsyncVoidMethodBuilderOnCompleted = new PredefinedMember (module, types.AsyncVoidMethodBuilder, + MemberFilter.Method ("AwaitOnCompleted", 2, + new ParametersImported ( + new[] { + new ParameterData (null, Parameter.Modifier.REF), + new ParameterData (null, Parameter.Modifier.REF) + }, + new[] { + new TypeParameterSpec (0, tp, SpecialConstraint.None, Variance.None, null), + new TypeParameterSpec (1, tp, SpecialConstraint.None, Variance.None, null) + }, false), + btypes.Void)); + + AsyncVoidMethodBuilderOnCompletedUnsafe = new PredefinedMember (module, types.AsyncVoidMethodBuilder, + MemberFilter.Method ("AwaitUnsafeOnCompleted", 2, + new ParametersImported ( + new[] { + new ParameterData (null, Parameter.Modifier.REF), + new ParameterData (null, Parameter.Modifier.REF) + }, + new[] { + new TypeParameterSpec (0, tp, SpecialConstraint.None, Variance.None, null), + new TypeParameterSpec (1, tp, SpecialConstraint.None, Variance.None, null) + }, false), + btypes.Void)); + + AsyncVoidMethodBuilderStart = new PredefinedMember (module, types.AsyncVoidMethodBuilder, + MemberFilter.Method ("Start", 1, + new ParametersImported ( + new[] { + new ParameterData (null, Parameter.Modifier.REF), + }, + new[] { + new TypeParameterSpec (0, tp, SpecialConstraint.None, Variance.None, null), + }, false), + btypes.Void)); + + DebuggerBrowsableAttributeCtor = new PredefinedMember (module, atypes.DebuggerBrowsable, + MemberFilter.Constructor (null)); + DecimalCtor = new PredefinedMember (module, btypes.Decimal, MemberFilter.Constructor (ParametersCompiled.CreateFullyResolved ( btypes.Int, btypes.Int, btypes.Int, btypes.Bool, btypes.Byte))); @@ -469,9 +619,9 @@ namespace Mono.CSharp new ParameterData (null, Parameter.Modifier.NONE) }, new[] { - new TypeParameterSpec (0, null, SpecialConstraint.None, Variance.None, null), - new TypeParameterSpec (0, null, SpecialConstraint.None, Variance.None, null), - new TypeParameterSpec (0, null, SpecialConstraint.None, Variance.None, null), + new TypeParameterSpec (0, tp, SpecialConstraint.None, Variance.None, null), + new TypeParameterSpec (0, tp, SpecialConstraint.None, Variance.None, null), + new TypeParameterSpec (0, tp, SpecialConstraint.None, Variance.None, null), }, false), null)); @@ -738,8 +888,8 @@ namespace Mono.CSharp }; } - public PredefinedMember (ModuleContainer module, PredefinedType type, string name, MemberKind kind, Func typesBuilder) - : this (module, type, new MemberFilter (name, 0, kind, null, null)) + public PredefinedMember (ModuleContainer module, PredefinedType type, string name, MemberKind kind, Func typesBuilder, TypeSpec returnType) + : this (module, type, new MemberFilter (name, 0, kind, null, returnType)) { filter_builder = typesBuilder; } diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/typespec.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/typespec.cs index fa642d394e..7ad55a4be4 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/typespec.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/typespec.cs @@ -292,7 +292,7 @@ namespace Mono.CSharp if (IsPointer) return ((ElementTypeSpec) this).Element.IsUnmanaged; - var ds = MemberDefinition as TypeContainer; + var ds = MemberDefinition as TypeDefinition; if (ds != null) return ds.IsUnmanagedType (); @@ -1061,8 +1061,7 @@ namespace Mono.CSharp if (!IsEqual (a.Types[i], b.Types[i])) return false; - const Parameter.Modifier ref_out = Parameter.Modifier.REF | Parameter.Modifier.OUT; - if ((a.FixedParameters[i].ModFlags & ref_out) != (b.FixedParameters[i].ModFlags & ref_out)) + if ((a.FixedParameters[i].ModFlags & Parameter.Modifier.RefOutMask) != (b.FixedParameters[i].ModFlags & Parameter.Modifier.RefOutMask)) return false; } @@ -1303,6 +1302,7 @@ namespace Mono.CSharp { IAssemblyDefinition DeclaringAssembly { get; } string Namespace { get; } + bool IsPartial { get; } int TypeParametersCount { get; } TypeParameterSpec[] TypeParameters { get; } @@ -1325,12 +1325,6 @@ namespace Mono.CSharp readonly string name; - InternalType (string name, MemberCache cache) - : this (name) - { - this.cache = cache; - } - InternalType (string name) : base (MemberKind.InternalCompilerType, null, null, null, Modifiers.PUBLIC) { @@ -1362,6 +1356,12 @@ namespace Mono.CSharp } } + bool ITypeDefinition.IsPartial { + get { + return false; + } + } + public override string Name { get { return name; @@ -1474,6 +1474,12 @@ namespace Mono.CSharp public TypeSpec Element { get; private set; } + bool ITypeDefinition.IsPartial { + get { + return false; + } + } + public override string Name { get { throw new NotSupportedException (); diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/visit.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/visit.cs index c51db66de4..dbd5709aaf 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/visit.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/visit.cs @@ -2,7 +2,7 @@ // visit.cs: Visitors for parsed dom // // Authors: Mike Krüger (mkrueger@novell.com) -// Marek Safar (marek.safar@gmail.com) +// Marek Safar (marek.safar@gmail.com) // // Dual licensed under the terms of the MIT X11 or GNU GPL // @@ -22,80 +22,49 @@ namespace Mono.CSharp } public virtual void Visit (ModuleContainer mc) - {/* - if (mc.Delegates != null) { - foreach (TypeContainer tc in mc.Delegates) { - tc.Accept (this); - } - }*/ - if (mc.Types != null) { - foreach (TypeContainer tc in mc.Types) { - tc.Accept (this); - } + { + foreach (var container in mc.Containers) { + container.Accept (this); } } - void VisitTypeContainer (TypeContainer tc) + void VisitTypeDefinition (TypeDefinition tc) { - foreach (MemberCore member in tc.OrderedAllMembers) { + foreach (var member in tc.Members) { member.Accept (this); } } - - protected void VisitNamespaceUsings (UsingsBag.Namespace nspace) - { - foreach (object u in nspace.usings) { - if (u is UsingsBag.Using) { - ((UsingsBag.Using)u).Accept (this); - } else { - ((UsingsBag.AliasUsing)u).Accept (this); - } - } - } - - protected void VisitNamespaceBody (UsingsBag.Namespace nspace) - { - foreach (object member in nspace.members) { - if (member is MemberCore) { - ((MemberCore)member).Accept (this); - } else { - ((UsingsBag.Namespace)member).Accept (this); - } - } - } - - public virtual void Visit (UsingsBag.Namespace nspace) + + public virtual void Visit (NamespaceContainer ns) { - VisitNamespaceUsings (nspace); - VisitNamespaceBody (nspace); } - - public virtual void Visit (UsingsBag.Using u) + + public virtual void Visit (UsingNamespace un) { } - - public virtual void Visit (UsingsBag.AliasUsing aliasUsing) + + public virtual void Visit (UsingAliasNamespace uan) { } - - public virtual void Visit (UsingsBag.ExternAlias externAlias) + + public virtual void Visit (UsingExternAlias uea) { } - + public virtual void Visit (Class c) { - VisitTypeContainer (c); + VisitTypeDefinition (c); } public virtual void Visit (Struct s) { - VisitTypeContainer (s); + VisitTypeDefinition (s); } public virtual void Visit (Interface i) { - VisitTypeContainer (i); + VisitTypeDefinition (i); } public virtual void Visit (Delegate d) @@ -104,7 +73,7 @@ namespace Mono.CSharp public virtual void Visit (Enum e) { - VisitTypeContainer (e); + VisitTypeDefinition (e); } public virtual void Visit (FixedField f) diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/y.output b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/y.output deleted file mode 100644 index a545cab253..0000000000 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Parser/mcs/y.output +++ /dev/null @@ -1,31920 +0,0 @@ - 0 $accept : compilation_unit $end - - 1 compilation_unit : outer_declarations opt_EOF - 2 | outer_declarations global_attributes opt_EOF - 3 | global_attributes opt_EOF - 4 | opt_EOF - - 5 $$1 : - - 6 compilation_unit : interactive_parsing $$1 opt_EOF - - 7 opt_EOF : - 8 | EOF - - 9 outer_declarations : outer_declaration - 10 | outer_declarations outer_declaration - - 11 outer_declaration : extern_alias_directive - 12 | using_directive - 13 | namespace_member_declaration - - 14 extern_alias_directives : extern_alias_directive - 15 | extern_alias_directives extern_alias_directive - - 16 extern_alias_directive : EXTERN_ALIAS IDENTIFIER IDENTIFIER SEMICOLON - 17 | EXTERN_ALIAS error - - 18 using_directives : using_directive - 19 | using_directives using_directive - - 20 using_directive : using_alias_directive - 21 | using_namespace_directive - - 22 using_alias_directive : USING IDENTIFIER ASSIGN namespace_or_type_name SEMICOLON - 23 | USING error - - 24 using_namespace_directive : USING namespace_name SEMICOLON - - 25 $$2 : - - 26 namespace_declaration : opt_attributes NAMESPACE qualified_identifier $$2 namespace_body opt_semicolon - - 27 qualified_identifier : IDENTIFIER - 28 | qualified_identifier DOT IDENTIFIER - 29 | error - - 30 opt_semicolon : - 31 | SEMICOLON - - 32 opt_comma : - 33 | COMMA - - 34 namespace_name : namespace_or_type_name - - 35 $$3 : - - 36 namespace_body : OPEN_BRACE $$3 namespace_body_body - - 37 namespace_body_body : opt_extern_alias_directives opt_using_directives opt_namespace_member_declarations CLOSE_BRACE - - 38 $$4 : - - 39 namespace_body_body : error $$4 CLOSE_BRACE - 40 | opt_extern_alias_directives opt_using_directives opt_namespace_member_declarations EOF - - 41 opt_using_directives : - 42 | using_directives - - 43 opt_extern_alias_directives : - 44 | extern_alias_directives - - 45 opt_namespace_member_declarations : - 46 | namespace_member_declarations - - 47 namespace_member_declarations : namespace_member_declaration - 48 | namespace_member_declarations namespace_member_declaration - - 49 namespace_member_declaration : type_declaration - 50 | namespace_declaration - 51 | field_declaration - 52 | method_declaration - - 53 type_declaration : class_declaration - 54 | struct_declaration - 55 | interface_declaration - 56 | enum_declaration - 57 | delegate_declaration - - 58 global_attributes : attribute_sections - - 59 opt_attributes : - 60 | attribute_sections - - 61 attribute_sections : attribute_section - 62 | attribute_sections attribute_section - - 63 attribute_section : OPEN_BRACKET attribute_target_specifier attribute_list opt_comma CLOSE_BRACKET - 64 | OPEN_BRACKET attribute_list opt_comma CLOSE_BRACKET - - 65 attribute_target_specifier : attribute_target COLON - - 66 attribute_target : IDENTIFIER - 67 | EVENT - 68 | RETURN - 69 | error - - 70 attribute_list : attribute - 71 | attribute_list COMMA attribute - - 72 $$5 : - - 73 attribute : attribute_name $$5 opt_attribute_arguments - - 74 attribute_name : namespace_or_type_name - - 75 opt_attribute_arguments : - 76 | OPEN_PARENS attribute_arguments CLOSE_PARENS - - 77 attribute_arguments : - 78 | positional_or_named_argument - 79 | named_attribute_argument - 80 | attribute_arguments COMMA positional_or_named_argument - 81 | attribute_arguments COMMA named_attribute_argument - - 82 positional_or_named_argument : expression - 83 | named_argument - - 84 $$6 : - - 85 named_attribute_argument : IDENTIFIER ASSIGN $$6 expression - - 86 named_argument : IDENTIFIER COLON opt_named_modifier expression - - 87 opt_named_modifier : - 88 | REF - 89 | OUT - - 90 opt_class_member_declarations : - 91 | class_member_declarations - - 92 class_member_declarations : class_member_declaration - 93 | class_member_declarations class_member_declaration - - 94 class_member_declaration : constant_declaration - 95 | field_declaration - 96 | method_declaration - 97 | property_declaration - 98 | event_declaration - 99 | indexer_declaration - 100 | operator_declaration - 101 | constructor_declaration - 102 | destructor_declaration - 103 | type_declaration - 104 | error - - 105 $$7 : - - 106 $$8 : - - 107 $$9 : - - 108 $$10 : - - 109 struct_declaration : opt_attributes opt_modifiers opt_partial STRUCT $$7 type_declaration_name $$8 opt_class_base opt_type_parameter_constraints_clauses $$9 struct_body $$10 opt_semicolon - 110 | opt_attributes opt_modifiers opt_partial STRUCT error - - 111 $$11 : - - 112 struct_body : OPEN_BRACE $$11 opt_struct_member_declarations CLOSE_BRACE - - 113 opt_struct_member_declarations : - 114 | struct_member_declarations - - 115 struct_member_declarations : struct_member_declaration - 116 | struct_member_declarations struct_member_declaration - - 117 struct_member_declaration : constant_declaration - 118 | field_declaration - 119 | method_declaration - 120 | property_declaration - 121 | event_declaration - 122 | indexer_declaration - 123 | operator_declaration - 124 | constructor_declaration - 125 | type_declaration - 126 | destructor_declaration - - 127 $$12 : - - 128 constant_declaration : opt_attributes opt_modifiers CONST type IDENTIFIER $$12 constant_initializer opt_constant_declarators SEMICOLON - - 129 opt_constant_declarators : - 130 | constant_declarators - - 131 constant_declarators : constant_declarator - 132 | constant_declarators constant_declarator - - 133 constant_declarator : COMMA IDENTIFIER constant_initializer - - 134 $$13 : - - 135 constant_initializer : ASSIGN $$13 constant_initializer_expr - 136 | error - - 137 constant_initializer_expr : constant_expression - 138 | array_initializer - - 139 $$14 : - - 140 field_declaration : opt_attributes opt_modifiers member_type IDENTIFIER $$14 opt_field_initializer opt_field_declarators SEMICOLON - - 141 $$15 : - - 142 field_declaration : opt_attributes opt_modifiers FIXED simple_type IDENTIFIER $$15 fixed_field_size opt_fixed_field_declarators SEMICOLON - 143 | opt_attributes opt_modifiers FIXED simple_type error SEMICOLON - - 144 opt_field_initializer : - - 145 $$16 : - - 146 opt_field_initializer : ASSIGN $$16 variable_initializer - - 147 opt_field_declarators : - 148 | field_declarators - - 149 field_declarators : field_declarator - 150 | field_declarators field_declarator - - 151 field_declarator : COMMA IDENTIFIER - - 152 $$17 : - - 153 field_declarator : COMMA IDENTIFIER ASSIGN $$17 variable_initializer - - 154 opt_fixed_field_declarators : - 155 | fixed_field_declarators - - 156 fixed_field_declarators : fixed_field_declarator - 157 | fixed_field_declarators fixed_field_declarator - - 158 fixed_field_declarator : COMMA IDENTIFIER fixed_field_size - - 159 $$18 : - - 160 fixed_field_size : OPEN_BRACKET $$18 expression CLOSE_BRACKET - 161 | OPEN_BRACKET error - - 162 local_variable_declarators : local_variable_declarator - 163 | local_variable_declarators COMMA local_variable_declarator - - 164 local_variable_declarator : IDENTIFIER ASSIGN local_variable_initializer - 165 | IDENTIFIER - 166 | IDENTIFIER variable_bad_array - - 167 local_variable_initializer : expression - 168 | array_initializer - 169 | STACKALLOC simple_type OPEN_BRACKET_EXPR expression CLOSE_BRACKET - 170 | ARGLIST - 171 | STACKALLOC simple_type - - 172 variable_bad_array : OPEN_BRACKET_EXPR opt_expression CLOSE_BRACKET - - 173 variable_initializer : expression - 174 | array_initializer - - 175 $$19 : - - 176 method_declaration : method_header $$19 method_body - - 177 $$20 : - - 178 $$21 : - - 179 method_header : opt_attributes opt_modifiers member_type method_declaration_name OPEN_PARENS $$20 opt_formal_parameter_list CLOSE_PARENS $$21 opt_type_parameter_constraints_clauses - - 180 $$22 : - - 181 $$23 : - - 182 method_header : opt_attributes opt_modifiers PARTIAL VOID method_declaration_name OPEN_PARENS $$22 opt_formal_parameter_list CLOSE_PARENS $$23 opt_type_parameter_constraints_clauses - 183 | opt_attributes opt_modifiers member_type modifiers method_declaration_name OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS - - 184 method_body : block - 185 | SEMICOLON - - 186 opt_formal_parameter_list : - 187 | formal_parameter_list - - 188 formal_parameter_list : fixed_parameters - 189 | fixed_parameters COMMA parameter_array - 190 | fixed_parameters COMMA arglist_modifier - 191 | parameter_array COMMA error - 192 | fixed_parameters COMMA parameter_array COMMA error - 193 | arglist_modifier COMMA error - 194 | fixed_parameters COMMA ARGLIST COMMA error - 195 | parameter_array - 196 | arglist_modifier - - 197 fixed_parameters : fixed_parameter - 198 | fixed_parameters COMMA fixed_parameter - - 199 fixed_parameter : opt_attributes opt_parameter_modifier parameter_type IDENTIFIER - 200 | opt_attributes opt_parameter_modifier parameter_type IDENTIFIER OPEN_BRACKET CLOSE_BRACKET - 201 | opt_attributes opt_parameter_modifier parameter_type error - - 202 $$24 : - - 203 fixed_parameter : opt_attributes opt_parameter_modifier parameter_type IDENTIFIER ASSIGN $$24 constant_expression - - 204 opt_parameter_modifier : - 205 | parameter_modifiers - - 206 parameter_modifiers : parameter_modifier - 207 | parameter_modifiers parameter_modifier - - 208 parameter_modifier : REF - 209 | OUT - 210 | THIS - - 211 parameter_array : opt_attributes params_modifier type IDENTIFIER - 212 | opt_attributes params_modifier type IDENTIFIER ASSIGN constant_expression - 213 | opt_attributes params_modifier type error - - 214 params_modifier : PARAMS - 215 | PARAMS parameter_modifier - 216 | PARAMS params_modifier - - 217 arglist_modifier : ARGLIST - - 218 $$25 : - - 219 $$26 : - - 220 $$27 : - - 221 property_declaration : opt_attributes opt_modifiers member_type member_declaration_name $$25 OPEN_BRACE $$26 accessor_declarations $$27 CLOSE_BRACE - - 222 $$28 : - - 223 $$29 : - - 224 $$30 : - - 225 indexer_declaration : opt_attributes opt_modifiers member_type indexer_declaration_name OPEN_BRACKET $$28 opt_formal_parameter_list CLOSE_BRACKET OPEN_BRACE $$29 accessor_declarations $$30 CLOSE_BRACE - - 226 accessor_declarations : get_accessor_declaration - 227 | get_accessor_declaration accessor_declarations - 228 | set_accessor_declaration - 229 | set_accessor_declaration accessor_declarations - 230 | error - - 231 $$31 : - - 232 get_accessor_declaration : opt_attributes opt_modifiers GET $$31 accessor_body - - 233 $$32 : - - 234 set_accessor_declaration : opt_attributes opt_modifiers SET $$32 accessor_body - - 235 accessor_body : block - 236 | SEMICOLON - 237 | error - - 238 $$33 : - - 239 $$34 : - - 240 $$35 : - - 241 $$36 : - - 242 interface_declaration : opt_attributes opt_modifiers opt_partial INTERFACE $$33 type_declaration_name $$34 opt_class_base opt_type_parameter_constraints_clauses $$35 OPEN_BRACE opt_interface_member_declarations CLOSE_BRACE $$36 opt_semicolon - 243 | opt_attributes opt_modifiers opt_partial INTERFACE error - - 244 opt_interface_member_declarations : - 245 | interface_member_declarations - - 246 interface_member_declarations : interface_member_declaration - 247 | interface_member_declarations interface_member_declaration - - 248 interface_member_declaration : constant_declaration - 249 | field_declaration - 250 | method_declaration - 251 | property_declaration - 252 | event_declaration - 253 | indexer_declaration - 254 | operator_declaration - 255 | constructor_declaration - 256 | type_declaration - - 257 $$37 : - - 258 operator_declaration : opt_attributes opt_modifiers operator_declarator $$37 operator_body - - 259 operator_body : block - 260 | SEMICOLON - - 261 operator_type : type_expression_or_array - 262 | VOID - - 263 $$38 : - - 264 operator_declarator : operator_type OPERATOR overloadable_operator OPEN_PARENS $$38 opt_formal_parameter_list CLOSE_PARENS - 265 | conversion_operator_declarator - - 266 overloadable_operator : BANG - 267 | TILDE - 268 | OP_INC - 269 | OP_DEC - 270 | TRUE - 271 | FALSE - 272 | PLUS - 273 | MINUS - 274 | STAR - 275 | DIV - 276 | PERCENT - 277 | BITWISE_AND - 278 | BITWISE_OR - 279 | CARRET - 280 | OP_SHIFT_LEFT - 281 | OP_SHIFT_RIGHT - 282 | OP_EQ - 283 | OP_NE - 284 | OP_GT - 285 | OP_LT - 286 | OP_GE - 287 | OP_LE - - 288 $$39 : - - 289 conversion_operator_declarator : IMPLICIT OPERATOR type OPEN_PARENS $$39 opt_formal_parameter_list CLOSE_PARENS - - 290 $$40 : - - 291 conversion_operator_declarator : EXPLICIT OPERATOR type OPEN_PARENS $$40 opt_formal_parameter_list CLOSE_PARENS - 292 | IMPLICIT error - 293 | EXPLICIT error - - 294 constructor_declaration : constructor_declarator constructor_body - - 295 $$41 : - - 296 $$42 : - - 297 constructor_declarator : opt_attributes opt_modifiers IDENTIFIER $$41 OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS $$42 opt_constructor_initializer - - 298 constructor_body : block_prepared - 299 | SEMICOLON - - 300 opt_constructor_initializer : - 301 | constructor_initializer - - 302 $$43 : - - 303 constructor_initializer : COLON BASE OPEN_PARENS $$43 opt_argument_list CLOSE_PARENS - - 304 $$44 : - - 305 constructor_initializer : COLON THIS OPEN_PARENS $$44 opt_argument_list CLOSE_PARENS - 306 | COLON error - - 307 $$45 : - - 308 destructor_declaration : opt_attributes opt_modifiers TILDE $$45 IDENTIFIER OPEN_PARENS CLOSE_PARENS method_body - - 309 $$46 : - - 310 event_declaration : opt_attributes opt_modifiers EVENT type member_declaration_name $$46 opt_event_initializer opt_event_declarators SEMICOLON - - 311 $$47 : - - 312 $$48 : - - 313 event_declaration : opt_attributes opt_modifiers EVENT type member_declaration_name OPEN_BRACE $$47 event_accessor_declarations $$48 CLOSE_BRACE - - 314 opt_event_initializer : - - 315 $$49 : - - 316 opt_event_initializer : ASSIGN $$49 event_variable_initializer - - 317 opt_event_declarators : - 318 | event_declarators - - 319 event_declarators : event_declarator - 320 | event_declarators event_declarator - - 321 event_declarator : COMMA IDENTIFIER - - 322 $$50 : - - 323 event_declarator : COMMA IDENTIFIER ASSIGN $$50 event_variable_initializer - - 324 $$51 : - - 325 event_variable_initializer : $$51 variable_initializer - - 326 event_accessor_declarations : add_accessor_declaration remove_accessor_declaration - 327 | remove_accessor_declaration add_accessor_declaration - 328 | add_accessor_declaration - 329 | remove_accessor_declaration - 330 | error - - 331 $$52 : - - 332 add_accessor_declaration : opt_attributes opt_modifiers ADD $$52 event_accessor_block - - 333 $$53 : - - 334 remove_accessor_declaration : opt_attributes opt_modifiers REMOVE $$53 event_accessor_block - - 335 event_accessor_block : opt_semicolon - 336 | block - - 337 $$54 : - - 338 $$55 : - - 339 $$56 : - - 340 enum_declaration : opt_attributes opt_modifiers ENUM type_declaration_name opt_enum_base $$54 OPEN_BRACE $$55 opt_enum_member_declarations $$56 CLOSE_BRACE opt_semicolon - - 341 opt_enum_base : - 342 | COLON type - 343 | COLON error - - 344 opt_enum_member_declarations : - 345 | enum_member_declarations - 346 | enum_member_declarations COMMA - - 347 enum_member_declarations : enum_member_declaration - 348 | enum_member_declarations COMMA enum_member_declaration - - 349 enum_member_declaration : opt_attributes IDENTIFIER - - 350 $$57 : - - 351 enum_member_declaration : opt_attributes IDENTIFIER $$57 ASSIGN constant_expression - - 352 $$58 : - - 353 $$59 : - - 354 $$60 : - - 355 delegate_declaration : opt_attributes opt_modifiers DELEGATE member_type type_declaration_name OPEN_PARENS $$58 opt_formal_parameter_list CLOSE_PARENS $$59 opt_type_parameter_constraints_clauses $$60 SEMICOLON - - 356 opt_nullable : - 357 | INTERR_NULLABLE - - 358 namespace_or_type_name : member_name - 359 | qualified_alias_member IDENTIFIER opt_type_argument_list - - 360 member_name : type_name - 361 | namespace_or_type_name DOT IDENTIFIER opt_type_argument_list - - 362 type_name : IDENTIFIER opt_type_argument_list - - 363 opt_type_argument_list : - 364 | OP_GENERICS_LT type_arguments OP_GENERICS_GT - 365 | OP_GENERICS_LT error - - 366 type_arguments : type - 367 | type_arguments COMMA type - - 368 $$61 : - - 369 type_declaration_name : IDENTIFIER $$61 opt_type_parameter_list - - 370 member_declaration_name : method_declaration_name - - 371 method_declaration_name : type_declaration_name - 372 | explicit_interface IDENTIFIER opt_type_parameter_list - - 373 indexer_declaration_name : THIS - 374 | explicit_interface THIS - - 375 explicit_interface : IDENTIFIER opt_type_argument_list DOT - 376 | qualified_alias_member IDENTIFIER opt_type_argument_list DOT - 377 | explicit_interface IDENTIFIER opt_type_argument_list DOT - - 378 opt_type_parameter_list : - 379 | OP_GENERICS_LT_DECL type_parameters OP_GENERICS_GT - - 380 type_parameters : type_parameter - 381 | type_parameters COMMA type_parameter - - 382 type_parameter : opt_attributes opt_type_parameter_variance IDENTIFIER - 383 | error - - 384 type_and_void : type_expression_or_array - 385 | VOID - - 386 member_type : type_and_void - - 387 type : type_expression_or_array - 388 | VOID - - 389 simple_type : type_expression - 390 | VOID - - 391 parameter_type : type_expression_or_array - 392 | VOID - - 393 type_expression_or_array : type_expression - 394 | type_expression rank_specifiers - - 395 type_expression : namespace_or_type_name opt_nullable - 396 | builtin_types opt_nullable - 397 | type_expression STAR - 398 | VOID STAR - - 399 type_list : base_type_name - 400 | type_list COMMA base_type_name - - 401 base_type_name : type - 402 | error - - 403 builtin_types : OBJECT - 404 | STRING - 405 | BOOL - 406 | DECIMAL - 407 | FLOAT - 408 | DOUBLE - 409 | integral_type - - 410 integral_type : SBYTE - 411 | BYTE - 412 | SHORT - 413 | USHORT - 414 | INT - 415 | UINT - 416 | LONG - 417 | ULONG - 418 | CHAR - - 419 primary_expression : primary_expression_no_array_creation - 420 | array_creation_expression - - 421 primary_expression_no_array_creation : literal - 422 | IDENTIFIER opt_type_argument_list - 423 | IDENTIFIER GENERATE_COMPLETION - 424 | parenthesized_expression - 425 | default_value_expression - 426 | member_access - 427 | invocation_expression - 428 | element_access - 429 | this_access - 430 | base_access - 431 | post_increment_expression - 432 | post_decrement_expression - 433 | object_or_delegate_creation_expression - 434 | anonymous_type_expression - 435 | typeof_expression - 436 | sizeof_expression - 437 | checked_expression - 438 | unchecked_expression - 439 | pointer_member_access - 440 | anonymous_method_expression - - 441 literal : boolean_literal - 442 | LITERAL - 443 | NULL - - 444 boolean_literal : TRUE - 445 | FALSE - - 446 open_parens_any : OPEN_PARENS - 447 | OPEN_PARENS_CAST - - 448 close_parens : CLOSE_PARENS - 449 | COMPLETE_COMPLETION - - 450 parenthesized_expression : OPEN_PARENS expression CLOSE_PARENS - 451 | OPEN_PARENS expression COMPLETE_COMPLETION - - 452 member_access : primary_expression DOT IDENTIFIER opt_type_argument_list - 453 | builtin_types DOT IDENTIFIER opt_type_argument_list - 454 | BASE DOT IDENTIFIER opt_type_argument_list - 455 | qualified_alias_member IDENTIFIER opt_type_argument_list - 456 | primary_expression DOT GENERATE_COMPLETION - 457 | primary_expression DOT IDENTIFIER GENERATE_COMPLETION - 458 | builtin_types DOT GENERATE_COMPLETION - 459 | builtin_types DOT IDENTIFIER GENERATE_COMPLETION - - 460 invocation_expression : primary_expression open_parens_any opt_argument_list close_parens - - 461 opt_object_or_collection_initializer : - 462 | object_or_collection_initializer - - 463 object_or_collection_initializer : OPEN_BRACE opt_member_initializer_list close_brace_or_complete_completion - 464 | OPEN_BRACE member_initializer_list COMMA CLOSE_BRACE - - 465 opt_member_initializer_list : - 466 | member_initializer_list - - 467 member_initializer_list : member_initializer - 468 | member_initializer_list COMMA member_initializer - 469 | member_initializer_list error - - 470 member_initializer : IDENTIFIER ASSIGN initializer_value - 471 | GENERATE_COMPLETION - 472 | non_assignment_expression opt_COMPLETE_COMPLETION - 473 | OPEN_BRACE expression_list CLOSE_BRACE - 474 | OPEN_BRACE CLOSE_BRACE - - 475 initializer_value : expression - 476 | object_or_collection_initializer - - 477 opt_argument_list : - 478 | argument_list - - 479 argument_list : argument_or_named_argument - 480 | argument_list COMMA argument - 481 | argument_list COMMA named_argument - 482 | argument_list COMMA - 483 | COMMA error - - 484 argument : expression - 485 | non_simple_argument - - 486 argument_or_named_argument : argument - 487 | named_argument - - 488 non_simple_argument : REF variable_reference - 489 | OUT variable_reference - 490 | ARGLIST OPEN_PARENS argument_list CLOSE_PARENS - 491 | ARGLIST OPEN_PARENS CLOSE_PARENS - 492 | ARGLIST - - 493 variable_reference : expression - - 494 element_access : primary_expression OPEN_BRACKET_EXPR expression_list_arguments CLOSE_BRACKET - - 495 expression_list : expression - 496 | expression_list COMMA expression - 497 | expression_list error - - 498 expression_list_arguments : expression_list_argument - 499 | expression_list_arguments COMMA expression_list_argument - - 500 expression_list_argument : expression - 501 | named_argument - - 502 this_access : THIS - - 503 base_access : BASE OPEN_BRACKET_EXPR expression_list_arguments CLOSE_BRACKET - 504 | BASE OPEN_BRACKET error - - 505 post_increment_expression : primary_expression OP_INC - - 506 post_decrement_expression : primary_expression OP_DEC - - 507 object_or_delegate_creation_expression : NEW new_expr_type open_parens_any opt_argument_list CLOSE_PARENS opt_object_or_collection_initializer - 508 | NEW new_expr_type object_or_collection_initializer - - 509 array_creation_expression : NEW new_expr_type OPEN_BRACKET_EXPR expression_list CLOSE_BRACKET opt_rank_specifier opt_array_initializer - 510 | NEW new_expr_type rank_specifiers opt_array_initializer - 511 | NEW rank_specifiers array_initializer - 512 | NEW new_expr_type OPEN_BRACKET CLOSE_BRACKET OPEN_BRACKET_EXPR error CLOSE_BRACKET - 513 | NEW new_expr_type error - - 514 $$62 : - - 515 new_expr_type : $$62 simple_type - - 516 anonymous_type_expression : NEW OPEN_BRACE anonymous_type_parameters_opt_comma CLOSE_BRACE - - 517 anonymous_type_parameters_opt_comma : anonymous_type_parameters_opt - 518 | anonymous_type_parameters COMMA - - 519 anonymous_type_parameters_opt : - 520 | anonymous_type_parameters - - 521 anonymous_type_parameters : anonymous_type_parameter - 522 | anonymous_type_parameters COMMA anonymous_type_parameter - - 523 anonymous_type_parameter : IDENTIFIER ASSIGN variable_initializer - 524 | IDENTIFIER - 525 | member_access - 526 | error - - 527 opt_rank_specifier : - 528 | rank_specifiers - - 529 opt_rank_specifier_or_nullable : opt_nullable - 530 | opt_nullable rank_specifiers - - 531 rank_specifiers : rank_specifier - 532 | rank_specifier rank_specifiers - - 533 rank_specifier : OPEN_BRACKET CLOSE_BRACKET - 534 | OPEN_BRACKET dim_separators CLOSE_BRACKET - - 535 dim_separators : COMMA - 536 | dim_separators COMMA - - 537 opt_array_initializer : - 538 | array_initializer - - 539 array_initializer : OPEN_BRACE CLOSE_BRACE - 540 | OPEN_BRACE variable_initializer_list opt_comma CLOSE_BRACE - - 541 variable_initializer_list : variable_initializer - 542 | variable_initializer_list COMMA variable_initializer - 543 | error - - 544 $$63 : - - 545 typeof_expression : TYPEOF $$63 open_parens_any typeof_type_expression CLOSE_PARENS - - 546 typeof_type_expression : type_and_void - 547 | unbound_type_name - 548 | error - - 549 unbound_type_name : IDENTIFIER generic_dimension - 550 | qualified_alias_member IDENTIFIER generic_dimension - 551 | unbound_type_name DOT IDENTIFIER - 552 | unbound_type_name DOT IDENTIFIER generic_dimension - 553 | namespace_or_type_name DOT IDENTIFIER generic_dimension - - 554 generic_dimension : GENERIC_DIMENSION - - 555 qualified_alias_member : IDENTIFIER DOUBLE_COLON - - 556 sizeof_expression : SIZEOF open_parens_any type CLOSE_PARENS - - 557 checked_expression : CHECKED open_parens_any expression CLOSE_PARENS - - 558 unchecked_expression : UNCHECKED open_parens_any expression CLOSE_PARENS - - 559 pointer_member_access : primary_expression OP_PTR IDENTIFIER - - 560 $$64 : - - 561 anonymous_method_expression : DELEGATE opt_anonymous_method_signature $$64 block - - 562 opt_anonymous_method_signature : - 563 | anonymous_method_signature - - 564 $$65 : - - 565 anonymous_method_signature : OPEN_PARENS $$65 opt_formal_parameter_list CLOSE_PARENS - - 566 default_value_expression : DEFAULT open_parens_any type CLOSE_PARENS - - 567 unary_expression : primary_expression - 568 | BANG prefixed_unary_expression - 569 | TILDE prefixed_unary_expression - 570 | cast_expression - - 571 cast_expression : OPEN_PARENS_CAST type CLOSE_PARENS prefixed_unary_expression - 572 | OPEN_PARENS builtin_types CLOSE_PARENS prefixed_unary_expression - - 573 prefixed_unary_expression : unary_expression - 574 | PLUS prefixed_unary_expression - 575 | MINUS prefixed_unary_expression - 576 | OP_INC prefixed_unary_expression - 577 | OP_DEC prefixed_unary_expression - 578 | STAR prefixed_unary_expression - 579 | BITWISE_AND prefixed_unary_expression - - 580 multiplicative_expression : prefixed_unary_expression - 581 | multiplicative_expression STAR prefixed_unary_expression - 582 | multiplicative_expression DIV prefixed_unary_expression - 583 | multiplicative_expression PERCENT prefixed_unary_expression - - 584 additive_expression : multiplicative_expression - 585 | additive_expression PLUS multiplicative_expression - 586 | additive_expression MINUS multiplicative_expression - 587 | parenthesized_expression MINUS multiplicative_expression - 588 | additive_expression AS type - 589 | additive_expression IS type - - 590 shift_expression : additive_expression - 591 | shift_expression OP_SHIFT_LEFT additive_expression - 592 | shift_expression OP_SHIFT_RIGHT additive_expression - - 593 relational_expression : shift_expression - 594 | relational_expression OP_LT shift_expression - 595 | relational_expression OP_GT shift_expression - 596 | relational_expression OP_LE shift_expression - 597 | relational_expression OP_GE shift_expression - - 598 equality_expression : relational_expression - 599 | equality_expression OP_EQ relational_expression - 600 | equality_expression OP_NE relational_expression - - 601 and_expression : equality_expression - 602 | and_expression BITWISE_AND equality_expression - - 603 exclusive_or_expression : and_expression - 604 | exclusive_or_expression CARRET and_expression - - 605 inclusive_or_expression : exclusive_or_expression - 606 | inclusive_or_expression BITWISE_OR exclusive_or_expression - - 607 conditional_and_expression : inclusive_or_expression - 608 | conditional_and_expression OP_AND inclusive_or_expression - - 609 conditional_or_expression : conditional_and_expression - 610 | conditional_or_expression OP_OR conditional_and_expression - - 611 null_coalescing_expression : conditional_or_expression - 612 | conditional_or_expression OP_COALESCING null_coalescing_expression - - 613 conditional_expression : null_coalescing_expression - 614 | null_coalescing_expression INTERR expression COLON expression - - 615 assignment_expression : prefixed_unary_expression ASSIGN expression - 616 | prefixed_unary_expression OP_MULT_ASSIGN expression - 617 | prefixed_unary_expression OP_DIV_ASSIGN expression - 618 | prefixed_unary_expression OP_MOD_ASSIGN expression - 619 | prefixed_unary_expression OP_ADD_ASSIGN expression - 620 | prefixed_unary_expression OP_SUB_ASSIGN expression - 621 | prefixed_unary_expression OP_SHIFT_LEFT_ASSIGN expression - 622 | prefixed_unary_expression OP_SHIFT_RIGHT_ASSIGN expression - 623 | prefixed_unary_expression OP_AND_ASSIGN expression - 624 | prefixed_unary_expression OP_OR_ASSIGN expression - 625 | prefixed_unary_expression OP_XOR_ASSIGN expression - - 626 lambda_parameter_list : lambda_parameter - 627 | lambda_parameter_list COMMA lambda_parameter - - 628 lambda_parameter : parameter_modifier parameter_type IDENTIFIER - 629 | parameter_type IDENTIFIER - 630 | IDENTIFIER - - 631 opt_lambda_parameter_list : - 632 | lambda_parameter_list - - 633 $$66 : - - 634 lambda_expression_body : $$66 expression - 635 | block - - 636 $$67 : - - 637 lambda_expression : IDENTIFIER ARROW $$67 lambda_expression_body - - 638 $$68 : - - 639 $$69 : - - 640 lambda_expression : OPEN_PARENS_LAMBDA $$68 opt_lambda_parameter_list CLOSE_PARENS ARROW $$69 lambda_expression_body - - 641 expression : assignment_expression - 642 | non_assignment_expression - - 643 non_assignment_expression : conditional_expression - 644 | lambda_expression - 645 | query_expression - - 646 constant_expression : expression - - 647 boolean_expression : expression - - 648 $$70 : - - 649 $$71 : - - 650 $$72 : - - 651 $$73 : - - 652 class_declaration : opt_attributes opt_modifiers opt_partial CLASS $$70 type_declaration_name $$71 opt_class_base opt_type_parameter_constraints_clauses $$72 OPEN_BRACE opt_class_member_declarations CLOSE_BRACE $$73 opt_semicolon - - 653 opt_partial : - 654 | PARTIAL - - 655 opt_modifiers : - 656 | modifiers - - 657 modifiers : modifier - 658 | modifiers modifier - - 659 modifier : NEW - 660 | PUBLIC - 661 | PROTECTED - 662 | INTERNAL - 663 | PRIVATE - 664 | ABSTRACT - 665 | SEALED - 666 | STATIC - 667 | READONLY - 668 | VIRTUAL - 669 | OVERRIDE - 670 | EXTERN - 671 | VOLATILE - 672 | UNSAFE - - 673 opt_class_base : - 674 | COLON type_list - - 675 opt_type_parameter_constraints_clauses : - 676 | type_parameter_constraints_clauses - - 677 type_parameter_constraints_clauses : type_parameter_constraints_clause - 678 | type_parameter_constraints_clauses type_parameter_constraints_clause - - 679 type_parameter_constraints_clause : WHERE IDENTIFIER COLON type_parameter_constraints - - 680 type_parameter_constraints : type_parameter_constraint - 681 | type_parameter_constraints COMMA type_parameter_constraint - - 682 type_parameter_constraint : type - 683 | NEW OPEN_PARENS CLOSE_PARENS - 684 | CLASS - 685 | STRUCT - - 686 opt_type_parameter_variance : - 687 | type_parameter_variance - - 688 type_parameter_variance : OUT - 689 | IN - - 690 $$74 : - - 691 block : OPEN_BRACE $$74 opt_statement_list block_end - - 692 block_end : CLOSE_BRACE - 693 | COMPLETE_COMPLETION - - 694 $$75 : - - 695 block_prepared : OPEN_BRACE $$75 opt_statement_list CLOSE_BRACE - - 696 opt_statement_list : - 697 | statement_list - - 698 statement_list : statement - 699 | statement_list statement - - 700 statement : declaration_statement - 701 | valid_declaration_statement - 702 | labeled_statement - - 703 interactive_statement_list : interactive_statement - 704 | interactive_statement_list interactive_statement - - 705 interactive_statement : declaration_statement - 706 | interactive_valid_declaration_statement - 707 | labeled_statement - - 708 valid_declaration_statement : block - 709 | empty_statement - 710 | expression_statement - 711 | selection_statement - 712 | iteration_statement - 713 | jump_statement - 714 | try_statement - 715 | checked_statement - 716 | unchecked_statement - 717 | lock_statement - 718 | using_statement - 719 | unsafe_statement - 720 | fixed_statement - - 721 interactive_valid_declaration_statement : block - 722 | empty_statement - 723 | interactive_expression_statement - 724 | selection_statement - 725 | iteration_statement - 726 | jump_statement - 727 | try_statement - 728 | checked_statement - 729 | unchecked_statement - 730 | lock_statement - 731 | using_statement - 732 | unsafe_statement - 733 | fixed_statement - - 734 embedded_statement : valid_declaration_statement - 735 | declaration_statement - 736 | labeled_statement - - 737 empty_statement : SEMICOLON - - 738 $$76 : - - 739 labeled_statement : IDENTIFIER COLON $$76 statement - - 740 declaration_statement : local_variable_declaration SEMICOLON - 741 | local_constant_declaration SEMICOLON - - 742 variable_type : primary_expression_no_array_creation opt_rank_specifier_or_nullable - 743 | builtin_types opt_rank_specifier_or_nullable - 744 | VOID opt_rank_specifier - - 745 local_variable_pointer_type : primary_expression_no_array_creation STAR - 746 | builtin_types STAR - 747 | VOID STAR - 748 | local_variable_pointer_type STAR - - 749 local_variable_type : variable_type - 750 | local_variable_pointer_type opt_rank_specifier - - 751 local_variable_declaration : local_variable_type local_variable_declarators - - 752 local_constant_declaration : CONST variable_type local_constant_declarators - - 753 local_constant_declarators : local_constant_declarator - 754 | local_constant_declarators COMMA local_constant_declarator - - 755 local_constant_declarator : IDENTIFIER ASSIGN constant_initializer_expr - 756 | IDENTIFIER error - - 757 expression_statement : statement_expression SEMICOLON - 758 | statement_expression COMPLETE_COMPLETION - - 759 interactive_expression_statement : interactive_statement_expression SEMICOLON - 760 | interactive_statement_expression COMPLETE_COMPLETION - - 761 statement_expression : expression - 762 | error - - 763 interactive_statement_expression : expression - 764 | error - - 765 selection_statement : if_statement - 766 | switch_statement - - 767 if_statement : IF open_parens_any boolean_expression CLOSE_PARENS embedded_statement - 768 | IF open_parens_any boolean_expression CLOSE_PARENS embedded_statement ELSE embedded_statement - - 769 $$77 : - - 770 switch_statement : SWITCH open_parens_any $$77 expression CLOSE_PARENS OPEN_BRACE opt_switch_sections CLOSE_BRACE - - 771 opt_switch_sections : - 772 | switch_sections - - 773 switch_sections : switch_section - 774 | switch_sections switch_section - - 775 $$78 : - - 776 switch_section : switch_labels $$78 statement_list - - 777 switch_labels : switch_label - 778 | switch_labels switch_label - - 779 switch_label : CASE constant_expression COLON - 780 | DEFAULT_COLON - - 781 iteration_statement : while_statement - 782 | do_statement - 783 | for_statement - 784 | foreach_statement - - 785 while_statement : WHILE open_parens_any boolean_expression CLOSE_PARENS embedded_statement - - 786 do_statement : DO embedded_statement WHILE open_parens_any boolean_expression CLOSE_PARENS SEMICOLON - - 787 $$79 : - - 788 for_statement : FOR open_parens_any opt_for_initializer SEMICOLON $$79 opt_for_condition SEMICOLON opt_for_iterator CLOSE_PARENS embedded_statement - - 789 opt_for_initializer : - 790 | for_initializer - - 791 for_initializer : local_variable_declaration - 792 | statement_expression_list - - 793 opt_for_condition : - 794 | boolean_expression - - 795 opt_for_iterator : - 796 | for_iterator - - 797 for_iterator : statement_expression_list - - 798 statement_expression_list : statement_expression - 799 | statement_expression_list COMMA statement_expression - - 800 foreach_statement : FOREACH open_parens_any type IN expression CLOSE_PARENS - - 801 $$80 : - - 802 foreach_statement : FOREACH open_parens_any type IDENTIFIER IN expression CLOSE_PARENS $$80 embedded_statement - - 803 jump_statement : break_statement - 804 | continue_statement - 805 | goto_statement - 806 | return_statement - 807 | throw_statement - 808 | yield_statement - - 809 break_statement : BREAK SEMICOLON - - 810 continue_statement : CONTINUE SEMICOLON - - 811 goto_statement : GOTO IDENTIFIER SEMICOLON - 812 | GOTO CASE constant_expression SEMICOLON - 813 | GOTO DEFAULT SEMICOLON - - 814 return_statement : RETURN opt_expression SEMICOLON - - 815 throw_statement : THROW opt_expression SEMICOLON - - 816 yield_statement : IDENTIFIER RETURN opt_expression SEMICOLON - 817 | IDENTIFIER BREAK SEMICOLON - - 818 opt_expression : - 819 | expression - - 820 try_statement : TRY block catch_clauses - 821 | TRY block FINALLY block - 822 | TRY block catch_clauses FINALLY block - 823 | TRY block error - - 824 catch_clauses : catch_clause - 825 | catch_clauses catch_clause - - 826 opt_identifier : - 827 | IDENTIFIER - - 828 $$81 : - - 829 catch_clause : CATCH opt_catch_args $$81 block - - 830 opt_catch_args : - 831 | catch_args - - 832 catch_args : open_parens_any type opt_identifier CLOSE_PARENS - 833 | open_parens_any CLOSE_PARENS - - 834 checked_statement : CHECKED block - - 835 unchecked_statement : UNCHECKED block - - 836 $$82 : - - 837 unsafe_statement : UNSAFE $$82 block - - 838 $$83 : - - 839 fixed_statement : FIXED open_parens_any type_and_void fixed_pointer_declarators CLOSE_PARENS $$83 embedded_statement - - 840 fixed_pointer_declarators : fixed_pointer_declarator - 841 | fixed_pointer_declarators COMMA fixed_pointer_declarator - - 842 fixed_pointer_declarator : IDENTIFIER ASSIGN expression - 843 | IDENTIFIER - - 844 lock_statement : LOCK open_parens_any expression CLOSE_PARENS embedded_statement - - 845 $$84 : - - 846 using_statement : USING open_parens_any local_variable_declaration CLOSE_PARENS $$84 embedded_statement - - 847 $$85 : - - 848 using_statement : USING open_parens_any expression CLOSE_PARENS $$85 embedded_statement - - 849 query_expression : first_from_clause query_body - 850 | nested_from_clause query_body - 851 | first_from_clause COMPLETE_COMPLETION - 852 | nested_from_clause COMPLETE_COMPLETION - - 853 first_from_clause : FROM_FIRST IDENTIFIER IN expression - 854 | FROM_FIRST type IDENTIFIER IN expression - - 855 nested_from_clause : FROM IDENTIFIER IN expression - 856 | FROM type IDENTIFIER IN expression - - 857 $$86 : - - 858 from_clause : FROM IDENTIFIER IN $$86 expression - - 859 $$87 : - - 860 from_clause : FROM type IDENTIFIER IN $$87 expression - - 861 query_body : opt_query_body_clauses select_or_group_clause opt_query_continuation - 862 | opt_query_body_clauses COMPLETE_COMPLETION - - 863 $$88 : - - 864 select_or_group_clause : SELECT $$88 expression - - 865 $$89 : - - 866 $$90 : - - 867 select_or_group_clause : GROUP $$89 expression $$90 BY expression - - 868 opt_query_body_clauses : - 869 | query_body_clauses - - 870 query_body_clauses : query_body_clause - 871 | query_body_clauses query_body_clause - - 872 query_body_clause : from_clause - 873 | let_clause - 874 | where_clause - 875 | join_clause - 876 | orderby_clause - - 877 $$91 : - - 878 let_clause : LET IDENTIFIER ASSIGN $$91 expression - - 879 $$92 : - - 880 where_clause : WHERE $$92 boolean_expression - - 881 $$93 : - - 882 $$94 : - - 883 $$95 : - - 884 join_clause : JOIN IDENTIFIER IN $$93 expression ON $$94 expression EQUALS $$95 expression opt_join_into - - 885 $$96 : - - 886 $$97 : - - 887 $$98 : - - 888 join_clause : JOIN type IDENTIFIER IN $$96 expression ON $$97 expression EQUALS $$98 expression opt_join_into - - 889 opt_join_into : - 890 | INTO IDENTIFIER - - 891 $$99 : - - 892 orderby_clause : ORDERBY $$99 orderings - - 893 orderings : order_by - - 894 $$100 : - - 895 orderings : order_by COMMA $$100 orderings_then_by - - 896 orderings_then_by : then_by - - 897 $$101 : - - 898 orderings_then_by : orderings_then_by COMMA $$101 then_by - - 899 order_by : expression - 900 | expression ASCENDING - 901 | expression DESCENDING - - 902 then_by : expression - 903 | expression ASCENDING - 904 | expression DESCENDING - - 905 opt_query_continuation : - - 906 $$102 : - - 907 opt_query_continuation : INTO IDENTIFIER $$102 query_body - - 908 interactive_parsing : EVAL_STATEMENT_PARSER EOF - 909 | EVAL_USING_DECLARATIONS_UNIT_PARSER using_directives - - 910 $$103 : - - 911 interactive_parsing : EVAL_STATEMENT_PARSER $$103 interactive_statement_list opt_COMPLETE_COMPLETION - - 912 $$104 : - - 913 interactive_parsing : EVAL_COMPILATION_UNIT_PARSER $$104 interactive_compilation_unit - - 914 interactive_compilation_unit : outer_declarations - 915 | outer_declarations global_attributes - 916 | global_attributes - 917 | - - 918 opt_COMPLETE_COMPLETION : - 919 | COMPLETE_COMPLETION - - 920 close_brace_or_complete_completion : CLOSE_BRACE - 921 | COMPLETE_COMPLETION - -state 0 - $accept : . compilation_unit $end (0) - opt_EOF : . (7) - opt_attributes : . (59) - - EOF shift 1 - USING shift 2 - EXTERN_ALIAS shift 3 - OPEN_BRACKET shift 4 - EVAL_STATEMENT_PARSER shift 5 - EVAL_COMPILATION_UNIT_PARSER shift 6 - EVAL_USING_DECLARATIONS_UNIT_PARSER shift 7 - $end reduce 7 - ABSTRACT reduce 59 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - CLASS reduce 59 - DECIMAL reduce 59 - DELEGATE reduce 59 - DOUBLE reduce 59 - ENUM reduce 59 - EXTERN reduce 59 - FIXED reduce 59 - FLOAT reduce 59 - INT reduce 59 - INTERFACE reduce 59 - INTERNAL reduce 59 - LONG reduce 59 - NAMESPACE reduce 59 - NEW reduce 59 - OBJECT reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - SBYTE reduce 59 - SEALED reduce 59 - SHORT reduce 59 - STATIC reduce 59 - STRING reduce 59 - STRUCT reduce 59 - UINT reduce 59 - ULONG reduce 59 - UNSAFE reduce 59 - USHORT reduce 59 - VIRTUAL reduce 59 - VOID reduce 59 - VOLATILE reduce 59 - PARTIAL reduce 59 - IDENTIFIER reduce 59 - - compilation_unit goto 8 - outer_declarations goto 9 - opt_EOF goto 10 - global_attributes goto 11 - interactive_parsing goto 12 - outer_declaration goto 13 - extern_alias_directive goto 14 - using_directive goto 15 - namespace_member_declaration goto 16 - using_alias_directive goto 17 - using_namespace_directive goto 18 - namespace_declaration goto 19 - opt_attributes goto 20 - type_declaration goto 21 - field_declaration goto 22 - method_declaration goto 23 - class_declaration goto 24 - struct_declaration goto 25 - interface_declaration goto 26 - enum_declaration goto 27 - delegate_declaration goto 28 - attribute_sections goto 29 - attribute_section goto 30 - method_header goto 31 - - -state 1 - opt_EOF : EOF . (8) - - . reduce 8 - - -state 2 - using_alias_directive : USING . IDENTIFIER ASSIGN namespace_or_type_name SEMICOLON (22) - using_alias_directive : USING . error (23) - using_namespace_directive : USING . namespace_name SEMICOLON (24) - - error shift 32 - IDENTIFIER shift 33 - . error - - namespace_or_type_name goto 34 - namespace_name goto 35 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - - -state 3 - extern_alias_directive : EXTERN_ALIAS . IDENTIFIER IDENTIFIER SEMICOLON (16) - extern_alias_directive : EXTERN_ALIAS . error (17) - - error shift 39 - IDENTIFIER shift 40 - . error - - -state 4 - attribute_section : OPEN_BRACKET . attribute_target_specifier attribute_list opt_comma CLOSE_BRACKET (63) - attribute_section : OPEN_BRACKET . attribute_list opt_comma CLOSE_BRACKET (64) - - error shift 41 - EVENT shift 42 - RETURN shift 43 - IDENTIFIER shift 44 - . error - - namespace_or_type_name goto 45 - attribute_target_specifier goto 46 - attribute_list goto 47 - attribute_target goto 48 - attribute goto 49 - attribute_name goto 50 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - - -state 5 - interactive_parsing : EVAL_STATEMENT_PARSER . EOF (908) - interactive_parsing : EVAL_STATEMENT_PARSER . $$103 interactive_statement_list opt_COMPLETE_COMPLETION (911) - $$103 : . (910) - - EOF shift 51 - error reduce 910 - BASE reduce 910 - BOOL reduce 910 - BREAK reduce 910 - BYTE reduce 910 - CHAR reduce 910 - CHECKED reduce 910 - CONST reduce 910 - CONTINUE reduce 910 - DECIMAL reduce 910 - DEFAULT reduce 910 - DELEGATE reduce 910 - DO reduce 910 - DOUBLE reduce 910 - FALSE reduce 910 - FIXED reduce 910 - FLOAT reduce 910 - FOR reduce 910 - FOREACH reduce 910 - GOTO reduce 910 - IF reduce 910 - INT reduce 910 - LOCK reduce 910 - LONG reduce 910 - NEW reduce 910 - NULL reduce 910 - OBJECT reduce 910 - RETURN reduce 910 - SBYTE reduce 910 - SHORT reduce 910 - SIZEOF reduce 910 - STRING reduce 910 - SWITCH reduce 910 - THIS reduce 910 - THROW reduce 910 - TRUE reduce 910 - TRY reduce 910 - TYPEOF reduce 910 - UINT reduce 910 - ULONG reduce 910 - UNCHECKED reduce 910 - UNSAFE reduce 910 - USHORT reduce 910 - USING reduce 910 - VOID reduce 910 - WHILE reduce 910 - FROM reduce 910 - FROM_FIRST reduce 910 - OPEN_BRACE reduce 910 - OPEN_PARENS reduce 910 - SEMICOLON reduce 910 - TILDE reduce 910 - PLUS reduce 910 - MINUS reduce 910 - BANG reduce 910 - BITWISE_AND reduce 910 - STAR reduce 910 - OP_INC reduce 910 - OP_DEC reduce 910 - LITERAL reduce 910 - IDENTIFIER reduce 910 - OPEN_PARENS_LAMBDA reduce 910 - OPEN_PARENS_CAST reduce 910 - - $$103 goto 52 - - -state 6 - interactive_parsing : EVAL_COMPILATION_UNIT_PARSER . $$104 interactive_compilation_unit (913) - $$104 : . (912) - - . reduce 912 - - $$104 goto 53 - - -state 7 - interactive_parsing : EVAL_USING_DECLARATIONS_UNIT_PARSER . using_directives (909) - - USING shift 2 - . error - - using_directive goto 54 - using_directives goto 55 - using_alias_directive goto 17 - using_namespace_directive goto 18 - - -state 8 - $accept : compilation_unit . $end (0) - - $end accept - - -state 9 - compilation_unit : outer_declarations . opt_EOF (1) - compilation_unit : outer_declarations . global_attributes opt_EOF (2) - outer_declarations : outer_declarations . outer_declaration (10) - opt_EOF : . (7) - opt_attributes : . (59) - - EOF shift 1 - USING shift 2 - EXTERN_ALIAS shift 3 - OPEN_BRACKET shift 4 - $end reduce 7 - ABSTRACT reduce 59 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - CLASS reduce 59 - DECIMAL reduce 59 - DELEGATE reduce 59 - DOUBLE reduce 59 - ENUM reduce 59 - EXTERN reduce 59 - FIXED reduce 59 - FLOAT reduce 59 - INT reduce 59 - INTERFACE reduce 59 - INTERNAL reduce 59 - LONG reduce 59 - NAMESPACE reduce 59 - NEW reduce 59 - OBJECT reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - SBYTE reduce 59 - SEALED reduce 59 - SHORT reduce 59 - STATIC reduce 59 - STRING reduce 59 - STRUCT reduce 59 - UINT reduce 59 - ULONG reduce 59 - UNSAFE reduce 59 - USHORT reduce 59 - VIRTUAL reduce 59 - VOID reduce 59 - VOLATILE reduce 59 - PARTIAL reduce 59 - IDENTIFIER reduce 59 - - opt_EOF goto 56 - global_attributes goto 57 - outer_declaration goto 58 - extern_alias_directive goto 14 - using_directive goto 15 - namespace_member_declaration goto 16 - using_alias_directive goto 17 - using_namespace_directive goto 18 - namespace_declaration goto 19 - opt_attributes goto 20 - type_declaration goto 21 - field_declaration goto 22 - method_declaration goto 23 - class_declaration goto 24 - struct_declaration goto 25 - interface_declaration goto 26 - enum_declaration goto 27 - delegate_declaration goto 28 - attribute_sections goto 29 - attribute_section goto 30 - method_header goto 31 - - -state 10 - compilation_unit : opt_EOF . (4) - - . reduce 4 - - -state 11 - compilation_unit : global_attributes . opt_EOF (3) - opt_EOF : . (7) - - EOF shift 1 - $end reduce 7 - - opt_EOF goto 59 - - -state 12 - compilation_unit : interactive_parsing . $$1 opt_EOF (6) - $$1 : . (5) - - . reduce 5 - - $$1 goto 60 - - -state 13 - outer_declarations : outer_declaration . (9) - - . reduce 9 - - -state 14 - outer_declaration : extern_alias_directive . (11) - - . reduce 11 - - -state 15 - outer_declaration : using_directive . (12) - - . reduce 12 - - -state 16 - outer_declaration : namespace_member_declaration . (13) - - . reduce 13 - - -state 17 - using_directive : using_alias_directive . (20) - - . reduce 20 - - -state 18 - using_directive : using_namespace_directive . (21) - - . reduce 21 - - -state 19 - namespace_member_declaration : namespace_declaration . (50) - - . reduce 50 - - -state 20 - namespace_declaration : opt_attributes . NAMESPACE qualified_identifier $$2 namespace_body opt_semicolon (26) - struct_declaration : opt_attributes . opt_modifiers opt_partial STRUCT $$7 type_declaration_name $$8 opt_class_base opt_type_parameter_constraints_clauses $$9 struct_body $$10 opt_semicolon (109) - struct_declaration : opt_attributes . opt_modifiers opt_partial STRUCT error (110) - field_declaration : opt_attributes . opt_modifiers member_type IDENTIFIER $$14 opt_field_initializer opt_field_declarators SEMICOLON (140) - field_declaration : opt_attributes . opt_modifiers FIXED simple_type IDENTIFIER $$15 fixed_field_size opt_fixed_field_declarators SEMICOLON (142) - field_declaration : opt_attributes . opt_modifiers FIXED simple_type error SEMICOLON (143) - method_header : opt_attributes . opt_modifiers member_type method_declaration_name OPEN_PARENS $$20 opt_formal_parameter_list CLOSE_PARENS $$21 opt_type_parameter_constraints_clauses (179) - method_header : opt_attributes . opt_modifiers PARTIAL VOID method_declaration_name OPEN_PARENS $$22 opt_formal_parameter_list CLOSE_PARENS $$23 opt_type_parameter_constraints_clauses (182) - method_header : opt_attributes . opt_modifiers member_type modifiers method_declaration_name OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS (183) - interface_declaration : opt_attributes . opt_modifiers opt_partial INTERFACE $$33 type_declaration_name $$34 opt_class_base opt_type_parameter_constraints_clauses $$35 OPEN_BRACE opt_interface_member_declarations CLOSE_BRACE $$36 opt_semicolon (242) - interface_declaration : opt_attributes . opt_modifiers opt_partial INTERFACE error (243) - enum_declaration : opt_attributes . opt_modifiers ENUM type_declaration_name opt_enum_base $$54 OPEN_BRACE $$55 opt_enum_member_declarations $$56 CLOSE_BRACE opt_semicolon (340) - delegate_declaration : opt_attributes . opt_modifiers DELEGATE member_type type_declaration_name OPEN_PARENS $$58 opt_formal_parameter_list CLOSE_PARENS $$59 opt_type_parameter_constraints_clauses $$60 SEMICOLON (355) - class_declaration : opt_attributes . opt_modifiers opt_partial CLASS $$70 type_declaration_name $$71 opt_class_base opt_type_parameter_constraints_clauses $$72 OPEN_BRACE opt_class_member_declarations CLOSE_BRACE $$73 opt_semicolon (652) - opt_modifiers : . (655) - - ABSTRACT shift 61 - EXTERN shift 62 - INTERNAL shift 63 - NAMESPACE shift 64 - NEW shift 65 - OVERRIDE shift 66 - PRIVATE shift 67 - PROTECTED shift 68 - PUBLIC shift 69 - READONLY shift 70 - SEALED shift 71 - STATIC shift 72 - UNSAFE shift 73 - VIRTUAL shift 74 - VOLATILE shift 75 - BOOL reduce 655 - BYTE reduce 655 - CHAR reduce 655 - CLASS reduce 655 - DECIMAL reduce 655 - DELEGATE reduce 655 - DOUBLE reduce 655 - ENUM reduce 655 - FIXED reduce 655 - FLOAT reduce 655 - INT reduce 655 - INTERFACE reduce 655 - LONG reduce 655 - OBJECT reduce 655 - SBYTE reduce 655 - SHORT reduce 655 - STRING reduce 655 - STRUCT reduce 655 - UINT reduce 655 - ULONG reduce 655 - USHORT reduce 655 - VOID reduce 655 - PARTIAL reduce 655 - IDENTIFIER reduce 655 - - opt_modifiers goto 76 - modifiers goto 77 - modifier goto 78 - - -state 21 - namespace_member_declaration : type_declaration . (49) - - . reduce 49 - - -state 22 - namespace_member_declaration : field_declaration . (51) - - . reduce 51 - - -state 23 - namespace_member_declaration : method_declaration . (52) - - . reduce 52 - - -state 24 - type_declaration : class_declaration . (53) - - . reduce 53 - - -state 25 - type_declaration : struct_declaration . (54) - - . reduce 54 - - -state 26 - type_declaration : interface_declaration . (55) - - . reduce 55 - - -state 27 - type_declaration : enum_declaration . (56) - - . reduce 56 - - -state 28 - type_declaration : delegate_declaration . (57) - - . reduce 57 - - -state 29 - global_attributes : attribute_sections . (58) - opt_attributes : attribute_sections . (60) - attribute_sections : attribute_sections . attribute_section (62) - - OPEN_BRACKET shift 4 - $end reduce 58 - EOF reduce 58 - ABSTRACT reduce 60 - BOOL reduce 60 - BYTE reduce 60 - CHAR reduce 60 - CLASS reduce 60 - DECIMAL reduce 60 - DELEGATE reduce 60 - DOUBLE reduce 60 - ENUM reduce 60 - EXTERN reduce 60 - FIXED reduce 60 - FLOAT reduce 60 - INT reduce 60 - INTERFACE reduce 60 - INTERNAL reduce 60 - LONG reduce 60 - NAMESPACE reduce 60 - NEW reduce 60 - OBJECT reduce 60 - OVERRIDE reduce 60 - PRIVATE reduce 60 - PROTECTED reduce 60 - PUBLIC reduce 60 - READONLY reduce 60 - SBYTE reduce 60 - SEALED reduce 60 - SHORT reduce 60 - STATIC reduce 60 - STRING reduce 60 - STRUCT reduce 60 - UINT reduce 60 - ULONG reduce 60 - UNSAFE reduce 60 - USHORT reduce 60 - VIRTUAL reduce 60 - VOID reduce 60 - VOLATILE reduce 60 - PARTIAL reduce 60 - IDENTIFIER reduce 60 - - attribute_section goto 79 - - -state 30 - attribute_sections : attribute_section . (61) - - . reduce 61 - - -state 31 - method_declaration : method_header . $$19 method_body (176) - $$19 : . (175) - - . reduce 175 - - $$19 goto 80 - - -state 32 - using_alias_directive : USING error . (23) - - . reduce 23 - - -state 33 - using_alias_directive : USING IDENTIFIER . ASSIGN namespace_or_type_name SEMICOLON (22) - type_name : IDENTIFIER . opt_type_argument_list (362) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - opt_type_argument_list : . (363) - - OP_GENERICS_LT shift 81 - ASSIGN shift 82 - DOUBLE_COLON shift 83 - DOT reduce 363 - SEMICOLON reduce 363 - - opt_type_argument_list goto 84 - - -state 34 - namespace_name : namespace_or_type_name . (34) - member_name : namespace_or_type_name . DOT IDENTIFIER opt_type_argument_list (361) - - DOT shift 85 - SEMICOLON reduce 34 - - -state 35 - using_namespace_directive : USING namespace_name . SEMICOLON (24) - - SEMICOLON shift 86 - . error - - -state 36 - namespace_or_type_name : member_name . (358) - - . reduce 358 - - -state 37 - namespace_or_type_name : qualified_alias_member . IDENTIFIER opt_type_argument_list (359) - - IDENTIFIER shift 87 - . error - - -state 38 - member_name : type_name . (360) - - . reduce 360 - - -state 39 - extern_alias_directive : EXTERN_ALIAS error . (17) - - . reduce 17 - - -state 40 - extern_alias_directive : EXTERN_ALIAS IDENTIFIER . IDENTIFIER SEMICOLON (16) - - IDENTIFIER shift 88 - . error - - -state 41 - attribute_target : error . (69) - - . reduce 69 - - -state 42 - attribute_target : EVENT . (67) - - . reduce 67 - - -state 43 - attribute_target : RETURN . (68) - - . reduce 68 - - -state 44 - attribute_target : IDENTIFIER . (66) - type_name : IDENTIFIER . opt_type_argument_list (362) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - opt_type_argument_list : . (363) - - OP_GENERICS_LT shift 81 - DOUBLE_COLON shift 83 - CLOSE_BRACKET reduce 363 - OPEN_PARENS reduce 363 - DOT reduce 363 - COMMA reduce 363 - COLON reduce 66 - - opt_type_argument_list goto 84 - - -state 45 - attribute_name : namespace_or_type_name . (74) - member_name : namespace_or_type_name . DOT IDENTIFIER opt_type_argument_list (361) - - DOT shift 85 - CLOSE_BRACKET reduce 74 - OPEN_PARENS reduce 74 - COMMA reduce 74 - - -state 46 - attribute_section : OPEN_BRACKET attribute_target_specifier . attribute_list opt_comma CLOSE_BRACKET (63) - - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 45 - attribute_list goto 90 - attribute goto 49 - attribute_name goto 50 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - - -state 47 - attribute_section : OPEN_BRACKET attribute_list . opt_comma CLOSE_BRACKET (64) - attribute_list : attribute_list . COMMA attribute (71) - opt_comma : . (32) - - COMMA shift 91 - CLOSE_BRACKET reduce 32 - - opt_comma goto 92 - - -state 48 - attribute_target_specifier : attribute_target . COLON (65) - - COLON shift 93 - . error - - -state 49 - attribute_list : attribute . (70) - - . reduce 70 - - -state 50 - attribute : attribute_name . $$5 opt_attribute_arguments (73) - $$5 : . (72) - - . reduce 72 - - $$5 goto 94 - - -state 51 - interactive_parsing : EVAL_STATEMENT_PARSER EOF . (908) - - . reduce 908 - - -state 52 - interactive_parsing : EVAL_STATEMENT_PARSER $$103 . interactive_statement_list opt_COMPLETE_COMPLETION (911) - - error shift 95 - BASE shift 96 - BOOL shift 97 - BREAK shift 98 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 101 - CONST shift 102 - CONTINUE shift 103 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DO shift 107 - DOUBLE shift 108 - FALSE shift 109 - FIXED shift 110 - FLOAT shift 111 - FOR shift 112 - FOREACH shift 113 - GOTO shift 114 - IF shift 115 - INT shift 116 - LOCK shift 117 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - RETURN shift 122 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - SWITCH shift 127 - THIS shift 128 - THROW shift 129 - TRUE shift 130 - TRY shift 131 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 135 - UNSAFE shift 136 - USHORT shift 137 - USING shift 138 - VOID shift 139 - WHILE shift 140 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 143 - OPEN_PARENS shift 144 - SEMICOLON shift 145 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 155 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 158 - block goto 159 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - declaration_statement goto 204 - labeled_statement goto 205 - interactive_statement_list goto 206 - interactive_statement goto 207 - interactive_valid_declaration_statement goto 208 - empty_statement goto 209 - selection_statement goto 210 - iteration_statement goto 211 - jump_statement goto 212 - try_statement goto 213 - checked_statement goto 214 - unchecked_statement goto 215 - lock_statement goto 216 - using_statement goto 217 - unsafe_statement goto 218 - fixed_statement goto 219 - interactive_expression_statement goto 220 - local_variable_declaration goto 221 - local_constant_declaration goto 222 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - interactive_statement_expression goto 226 - if_statement goto 227 - switch_statement goto 228 - while_statement goto 229 - do_statement goto 230 - for_statement goto 231 - foreach_statement goto 232 - break_statement goto 233 - continue_statement goto 234 - goto_statement goto 235 - return_statement goto 236 - throw_statement goto 237 - yield_statement goto 238 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 53 - interactive_parsing : EVAL_COMPILATION_UNIT_PARSER $$104 . interactive_compilation_unit (913) - opt_attributes : . (59) - interactive_compilation_unit : . (917) - - USING shift 2 - EXTERN_ALIAS shift 3 - OPEN_BRACKET shift 4 - $end reduce 917 - EOF reduce 917 - ABSTRACT reduce 59 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - CLASS reduce 59 - DECIMAL reduce 59 - DELEGATE reduce 59 - DOUBLE reduce 59 - ENUM reduce 59 - EXTERN reduce 59 - FIXED reduce 59 - FLOAT reduce 59 - INT reduce 59 - INTERFACE reduce 59 - INTERNAL reduce 59 - LONG reduce 59 - NAMESPACE reduce 59 - NEW reduce 59 - OBJECT reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - SBYTE reduce 59 - SEALED reduce 59 - SHORT reduce 59 - STATIC reduce 59 - STRING reduce 59 - STRUCT reduce 59 - UINT reduce 59 - ULONG reduce 59 - UNSAFE reduce 59 - USHORT reduce 59 - VIRTUAL reduce 59 - VOID reduce 59 - VOLATILE reduce 59 - PARTIAL reduce 59 - IDENTIFIER reduce 59 - - outer_declarations goto 241 - global_attributes goto 242 - outer_declaration goto 13 - extern_alias_directive goto 14 - using_directive goto 15 - namespace_member_declaration goto 16 - using_alias_directive goto 17 - using_namespace_directive goto 18 - namespace_declaration goto 19 - opt_attributes goto 20 - type_declaration goto 21 - field_declaration goto 22 - method_declaration goto 23 - class_declaration goto 24 - struct_declaration goto 25 - interface_declaration goto 26 - enum_declaration goto 27 - delegate_declaration goto 28 - attribute_sections goto 29 - attribute_section goto 30 - method_header goto 31 - interactive_compilation_unit goto 243 - - -state 54 - using_directives : using_directive . (18) - - . reduce 18 - - -state 55 - using_directives : using_directives . using_directive (19) - interactive_parsing : EVAL_USING_DECLARATIONS_UNIT_PARSER using_directives . (909) - - USING shift 2 - $end reduce 909 - EOF reduce 909 - - using_directive goto 244 - using_alias_directive goto 17 - using_namespace_directive goto 18 - - -state 56 - compilation_unit : outer_declarations opt_EOF . (1) - - . reduce 1 - - -state 57 - compilation_unit : outer_declarations global_attributes . opt_EOF (2) - opt_EOF : . (7) - - EOF shift 1 - $end reduce 7 - - opt_EOF goto 245 - - -state 58 - outer_declarations : outer_declarations outer_declaration . (10) - - . reduce 10 - - -state 59 - compilation_unit : global_attributes opt_EOF . (3) - - . reduce 3 - - -state 60 - compilation_unit : interactive_parsing $$1 . opt_EOF (6) - opt_EOF : . (7) - - EOF shift 1 - $end reduce 7 - - opt_EOF goto 246 - - -state 61 - modifier : ABSTRACT . (664) - - . reduce 664 - - -state 62 - modifier : EXTERN . (670) - - . reduce 670 - - -state 63 - modifier : INTERNAL . (662) - - . reduce 662 - - -state 64 - namespace_declaration : opt_attributes NAMESPACE . qualified_identifier $$2 namespace_body opt_semicolon (26) - - error shift 247 - IDENTIFIER shift 248 - . error - - qualified_identifier goto 249 - - -state 65 - modifier : NEW . (659) - - . reduce 659 - - -state 66 - modifier : OVERRIDE . (669) - - . reduce 669 - - -state 67 - modifier : PRIVATE . (663) - - . reduce 663 - - -state 68 - modifier : PROTECTED . (661) - - . reduce 661 - - -state 69 - modifier : PUBLIC . (660) - - . reduce 660 - - -state 70 - modifier : READONLY . (667) - - . reduce 667 - - -state 71 - modifier : SEALED . (665) - - . reduce 665 - - -state 72 - modifier : STATIC . (666) - - . reduce 666 - - -state 73 - modifier : UNSAFE . (672) - - . reduce 672 - - -state 74 - modifier : VIRTUAL . (668) - - . reduce 668 - - -state 75 - modifier : VOLATILE . (671) - - . reduce 671 - - -state 76 - struct_declaration : opt_attributes opt_modifiers . opt_partial STRUCT $$7 type_declaration_name $$8 opt_class_base opt_type_parameter_constraints_clauses $$9 struct_body $$10 opt_semicolon (109) - struct_declaration : opt_attributes opt_modifiers . opt_partial STRUCT error (110) - field_declaration : opt_attributes opt_modifiers . member_type IDENTIFIER $$14 opt_field_initializer opt_field_declarators SEMICOLON (140) - field_declaration : opt_attributes opt_modifiers . FIXED simple_type IDENTIFIER $$15 fixed_field_size opt_fixed_field_declarators SEMICOLON (142) - field_declaration : opt_attributes opt_modifiers . FIXED simple_type error SEMICOLON (143) - method_header : opt_attributes opt_modifiers . member_type method_declaration_name OPEN_PARENS $$20 opt_formal_parameter_list CLOSE_PARENS $$21 opt_type_parameter_constraints_clauses (179) - method_header : opt_attributes opt_modifiers . PARTIAL VOID method_declaration_name OPEN_PARENS $$22 opt_formal_parameter_list CLOSE_PARENS $$23 opt_type_parameter_constraints_clauses (182) - method_header : opt_attributes opt_modifiers . member_type modifiers method_declaration_name OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS (183) - interface_declaration : opt_attributes opt_modifiers . opt_partial INTERFACE $$33 type_declaration_name $$34 opt_class_base opt_type_parameter_constraints_clauses $$35 OPEN_BRACE opt_interface_member_declarations CLOSE_BRACE $$36 opt_semicolon (242) - interface_declaration : opt_attributes opt_modifiers . opt_partial INTERFACE error (243) - enum_declaration : opt_attributes opt_modifiers . ENUM type_declaration_name opt_enum_base $$54 OPEN_BRACE $$55 opt_enum_member_declarations $$56 CLOSE_BRACE opt_semicolon (340) - delegate_declaration : opt_attributes opt_modifiers . DELEGATE member_type type_declaration_name OPEN_PARENS $$58 opt_formal_parameter_list CLOSE_PARENS $$59 opt_type_parameter_constraints_clauses $$60 SEMICOLON (355) - class_declaration : opt_attributes opt_modifiers . opt_partial CLASS $$70 type_declaration_name $$71 opt_class_base opt_type_parameter_constraints_clauses $$72 OPEN_BRACE opt_class_member_declarations CLOSE_BRACE $$73 opt_semicolon (652) - opt_partial : . (653) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DELEGATE shift 250 - DOUBLE shift 108 - ENUM shift 251 - FIXED shift 252 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 253 - PARTIAL shift 254 - IDENTIFIER shift 89 - CLASS reduce 653 - INTERFACE reduce 653 - STRUCT reduce 653 - - namespace_or_type_name goto 255 - opt_partial goto 256 - member_type goto 257 - type_expression_or_array goto 258 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_and_void goto 259 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 77 - opt_modifiers : modifiers . (656) - modifiers : modifiers . modifier (658) - - ABSTRACT shift 61 - EXTERN shift 62 - INTERNAL shift 63 - NEW shift 65 - OVERRIDE shift 66 - PRIVATE shift 67 - PROTECTED shift 68 - PUBLIC shift 69 - READONLY shift 70 - SEALED shift 71 - STATIC shift 72 - UNSAFE shift 73 - VIRTUAL shift 74 - VOLATILE shift 75 - ADD reduce 656 - BOOL reduce 656 - BYTE reduce 656 - CHAR reduce 656 - CLASS reduce 656 - CONST reduce 656 - DECIMAL reduce 656 - DELEGATE reduce 656 - DOUBLE reduce 656 - ENUM reduce 656 - EVENT reduce 656 - EXPLICIT reduce 656 - FIXED reduce 656 - FLOAT reduce 656 - IMPLICIT reduce 656 - INT reduce 656 - INTERFACE reduce 656 - LONG reduce 656 - OBJECT reduce 656 - REMOVE reduce 656 - SBYTE reduce 656 - SHORT reduce 656 - STRING reduce 656 - STRUCT reduce 656 - UINT reduce 656 - ULONG reduce 656 - USHORT reduce 656 - VOID reduce 656 - PARTIAL reduce 656 - GET reduce 656 - SET reduce 656 - TILDE reduce 656 - IDENTIFIER reduce 656 - - modifier goto 262 - - -state 78 - modifiers : modifier . (657) - - . reduce 657 - - -state 79 - attribute_sections : attribute_sections attribute_section . (62) - - . reduce 62 - - -state 80 - method_declaration : method_header $$19 . method_body (176) - - OPEN_BRACE shift 143 - SEMICOLON shift 263 - . error - - method_body goto 264 - block goto 265 - - -state 81 - opt_type_argument_list : OP_GENERICS_LT . type_arguments OP_GENERICS_GT (364) - opt_type_argument_list : OP_GENERICS_LT . error (365) - - error shift 266 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 268 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_arguments goto 270 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 82 - using_alias_directive : USING IDENTIFIER ASSIGN . namespace_or_type_name SEMICOLON (22) - - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 271 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - - -state 83 - qualified_alias_member : IDENTIFIER DOUBLE_COLON . (555) - - . reduce 555 - - -state 84 - type_name : IDENTIFIER opt_type_argument_list . (362) - - . reduce 362 - - -state 85 - member_name : namespace_or_type_name DOT . IDENTIFIER opt_type_argument_list (361) - - IDENTIFIER shift 272 - . error - - -state 86 - using_namespace_directive : USING namespace_name SEMICOLON . (24) - - . reduce 24 - - -state 87 - namespace_or_type_name : qualified_alias_member IDENTIFIER . opt_type_argument_list (359) - opt_type_argument_list : . (363) - - OP_GENERICS_LT shift 81 - error reduce 363 - ABSTRACT reduce 363 - AS reduce 363 - EXTERN reduce 363 - IN reduce 363 - INTERNAL reduce 363 - IS reduce 363 - NEW reduce 363 - OPERATOR reduce 363 - OVERRIDE reduce 363 - PRIVATE reduce 363 - PROTECTED reduce 363 - PUBLIC reduce 363 - READONLY reduce 363 - SEALED reduce 363 - STATIC reduce 363 - THIS reduce 363 - UNSAFE reduce 363 - VIRTUAL reduce 363 - VOLATILE reduce 363 - WHERE reduce 363 - FROM reduce 363 - JOIN reduce 363 - ON reduce 363 - EQUALS reduce 363 - SELECT reduce 363 - GROUP reduce 363 - BY reduce 363 - LET reduce 363 - ORDERBY reduce 363 - ASCENDING reduce 363 - DESCENDING reduce 363 - INTO reduce 363 - INTERR_NULLABLE reduce 363 - OP_GENERICS_GT reduce 363 - OPEN_BRACE reduce 363 - CLOSE_BRACE reduce 363 - OPEN_BRACKET reduce 363 - CLOSE_BRACKET reduce 363 - OPEN_PARENS reduce 363 - CLOSE_PARENS reduce 363 - DOT reduce 363 - COMMA reduce 363 - COLON reduce 363 - SEMICOLON reduce 363 - PLUS reduce 363 - MINUS reduce 363 - OP_LT reduce 363 - OP_GT reduce 363 - BITWISE_AND reduce 363 - BITWISE_OR reduce 363 - STAR reduce 363 - CARRET reduce 363 - INTERR reduce 363 - OP_SHIFT_LEFT reduce 363 - OP_SHIFT_RIGHT reduce 363 - OP_LE reduce 363 - OP_GE reduce 363 - OP_EQ reduce 363 - OP_NE reduce 363 - OP_AND reduce 363 - OP_OR reduce 363 - OP_COALESCING reduce 363 - IDENTIFIER reduce 363 - OPEN_PARENS_CAST reduce 363 - OPEN_BRACKET_EXPR reduce 363 - COMPLETE_COMPLETION reduce 363 - - opt_type_argument_list goto 273 - - -state 88 - extern_alias_directive : EXTERN_ALIAS IDENTIFIER IDENTIFIER . SEMICOLON (16) - - SEMICOLON shift 274 - . error - - -state 89 - type_name : IDENTIFIER . opt_type_argument_list (362) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - opt_type_argument_list : . (363) - - OP_GENERICS_LT shift 81 - DOUBLE_COLON shift 83 - error reduce 363 - ABSTRACT reduce 363 - AS reduce 363 - EXTERN reduce 363 - IN reduce 363 - INTERNAL reduce 363 - IS reduce 363 - NEW reduce 363 - OVERRIDE reduce 363 - PRIVATE reduce 363 - PROTECTED reduce 363 - PUBLIC reduce 363 - READONLY reduce 363 - SEALED reduce 363 - STATIC reduce 363 - UNSAFE reduce 363 - VIRTUAL reduce 363 - VOLATILE reduce 363 - WHERE reduce 363 - FROM reduce 363 - JOIN reduce 363 - ON reduce 363 - EQUALS reduce 363 - SELECT reduce 363 - GROUP reduce 363 - BY reduce 363 - LET reduce 363 - ORDERBY reduce 363 - ASCENDING reduce 363 - DESCENDING reduce 363 - INTO reduce 363 - INTERR_NULLABLE reduce 363 - OP_GENERICS_GT reduce 363 - OPEN_BRACE reduce 363 - CLOSE_BRACE reduce 363 - OPEN_BRACKET reduce 363 - CLOSE_BRACKET reduce 363 - OPEN_PARENS reduce 363 - CLOSE_PARENS reduce 363 - DOT reduce 363 - COMMA reduce 363 - COLON reduce 363 - SEMICOLON reduce 363 - PLUS reduce 363 - MINUS reduce 363 - OP_LT reduce 363 - OP_GT reduce 363 - BITWISE_AND reduce 363 - BITWISE_OR reduce 363 - STAR reduce 363 - CARRET reduce 363 - INTERR reduce 363 - OP_SHIFT_LEFT reduce 363 - OP_SHIFT_RIGHT reduce 363 - OP_LE reduce 363 - OP_GE reduce 363 - OP_EQ reduce 363 - OP_NE reduce 363 - OP_AND reduce 363 - OP_OR reduce 363 - OP_COALESCING reduce 363 - IDENTIFIER reduce 363 - OPEN_PARENS_CAST reduce 363 - OPEN_BRACKET_EXPR reduce 363 - COMPLETE_COMPLETION reduce 363 - - opt_type_argument_list goto 84 - - -state 90 - attribute_section : OPEN_BRACKET attribute_target_specifier attribute_list . opt_comma CLOSE_BRACKET (63) - attribute_list : attribute_list . COMMA attribute (71) - opt_comma : . (32) - - COMMA shift 91 - CLOSE_BRACKET reduce 32 - - opt_comma goto 275 - - -state 91 - opt_comma : COMMA . (33) - attribute_list : attribute_list COMMA . attribute (71) - - IDENTIFIER shift 89 - CLOSE_BRACKET reduce 33 - - namespace_or_type_name goto 45 - attribute goto 276 - attribute_name goto 50 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - - -state 92 - attribute_section : OPEN_BRACKET attribute_list opt_comma . CLOSE_BRACKET (64) - - CLOSE_BRACKET shift 277 - . error - - -state 93 - attribute_target_specifier : attribute_target COLON . (65) - - . reduce 65 - - -state 94 - attribute : attribute_name $$5 . opt_attribute_arguments (73) - opt_attribute_arguments : . (75) - - OPEN_PARENS shift 278 - CLOSE_BRACKET reduce 75 - COMMA reduce 75 - - opt_attribute_arguments goto 279 - - -state 95 - interactive_statement_expression : error . (764) - - . reduce 764 - - -state 96 - member_access : BASE . DOT IDENTIFIER opt_type_argument_list (454) - base_access : BASE . OPEN_BRACKET_EXPR expression_list_arguments CLOSE_BRACKET (503) - base_access : BASE . OPEN_BRACKET error (504) - - OPEN_BRACKET shift 280 - DOT shift 281 - OPEN_BRACKET_EXPR shift 282 - . error - - -state 97 - builtin_types : BOOL . (405) - - . reduce 405 - - -state 98 - break_statement : BREAK . SEMICOLON (809) - - SEMICOLON shift 283 - . error - - -state 99 - integral_type : BYTE . (411) - - . reduce 411 - - -state 100 - integral_type : CHAR . (418) - - . reduce 418 - - -state 101 - checked_expression : CHECKED . open_parens_any expression CLOSE_PARENS (557) - checked_statement : CHECKED . block (834) - - OPEN_BRACE shift 143 - OPEN_PARENS shift 284 - OPEN_PARENS_CAST shift 285 - . error - - block goto 286 - open_parens_any goto 287 - - -state 102 - local_constant_declaration : CONST . variable_type local_constant_declarators (752) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - VOID shift 290 - OPEN_PARENS shift 291 - LITERAL shift 154 - IDENTIFIER shift 292 - . error - - qualified_alias_member goto 160 - builtin_types goto 293 - integral_type goto 162 - primary_expression goto 294 - primary_expression_no_array_creation goto 295 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - variable_type goto 297 - - -state 103 - continue_statement : CONTINUE . SEMICOLON (810) - - SEMICOLON shift 298 - . error - - -state 104 - builtin_types : DECIMAL . (406) - - . reduce 406 - - -state 105 - default_value_expression : DEFAULT . open_parens_any type CLOSE_PARENS (566) - - OPEN_PARENS shift 284 - OPEN_PARENS_CAST shift 285 - . error - - open_parens_any goto 299 - - -state 106 - anonymous_method_expression : DELEGATE . opt_anonymous_method_signature $$64 block (561) - opt_anonymous_method_signature : . (562) - - OPEN_PARENS shift 300 - OPEN_BRACE reduce 562 - - opt_anonymous_method_signature goto 301 - anonymous_method_signature goto 302 - - -state 107 - do_statement : DO . embedded_statement WHILE open_parens_any boolean_expression CLOSE_PARENS SEMICOLON (786) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BREAK shift 98 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 101 - CONST shift 102 - CONTINUE shift 103 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DO shift 107 - DOUBLE shift 108 - FALSE shift 109 - FIXED shift 110 - FLOAT shift 111 - FOR shift 112 - FOREACH shift 113 - GOTO shift 114 - IF shift 115 - INT shift 116 - LOCK shift 117 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - RETURN shift 122 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - SWITCH shift 127 - THIS shift 128 - THROW shift 129 - TRUE shift 130 - TRY shift 131 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 135 - UNSAFE shift 136 - USHORT shift 137 - USING shift 138 - VOID shift 139 - WHILE shift 140 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 143 - OPEN_PARENS shift 144 - SEMICOLON shift 145 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 155 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 304 - block goto 305 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - declaration_statement goto 306 - valid_declaration_statement goto 307 - labeled_statement goto 308 - empty_statement goto 309 - expression_statement goto 310 - selection_statement goto 311 - iteration_statement goto 312 - jump_statement goto 313 - try_statement goto 314 - checked_statement goto 315 - unchecked_statement goto 316 - lock_statement goto 317 - using_statement goto 318 - unsafe_statement goto 319 - fixed_statement goto 320 - embedded_statement goto 321 - local_variable_declaration goto 221 - local_constant_declaration goto 222 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - statement_expression goto 322 - if_statement goto 227 - switch_statement goto 228 - while_statement goto 229 - do_statement goto 230 - for_statement goto 231 - foreach_statement goto 232 - break_statement goto 233 - continue_statement goto 234 - goto_statement goto 235 - return_statement goto 236 - throw_statement goto 237 - yield_statement goto 238 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 108 - builtin_types : DOUBLE . (408) - - . reduce 408 - - -state 109 - boolean_literal : FALSE . (445) - - . reduce 445 - - -state 110 - fixed_statement : FIXED . open_parens_any type_and_void fixed_pointer_declarators CLOSE_PARENS $$83 embedded_statement (839) - - OPEN_PARENS shift 284 - OPEN_PARENS_CAST shift 285 - . error - - open_parens_any goto 323 - - -state 111 - builtin_types : FLOAT . (407) - - . reduce 407 - - -state 112 - for_statement : FOR . open_parens_any opt_for_initializer SEMICOLON $$79 opt_for_condition SEMICOLON opt_for_iterator CLOSE_PARENS embedded_statement (788) - - OPEN_PARENS shift 284 - OPEN_PARENS_CAST shift 285 - . error - - open_parens_any goto 324 - - -state 113 - foreach_statement : FOREACH . open_parens_any type IN expression CLOSE_PARENS (800) - foreach_statement : FOREACH . open_parens_any type IDENTIFIER IN expression CLOSE_PARENS $$80 embedded_statement (802) - - OPEN_PARENS shift 284 - OPEN_PARENS_CAST shift 285 - . error - - open_parens_any goto 325 - - -state 114 - goto_statement : GOTO . IDENTIFIER SEMICOLON (811) - goto_statement : GOTO . CASE constant_expression SEMICOLON (812) - goto_statement : GOTO . DEFAULT SEMICOLON (813) - - CASE shift 326 - DEFAULT shift 327 - IDENTIFIER shift 328 - . error - - -state 115 - if_statement : IF . open_parens_any boolean_expression CLOSE_PARENS embedded_statement (767) - if_statement : IF . open_parens_any boolean_expression CLOSE_PARENS embedded_statement ELSE embedded_statement (768) - - OPEN_PARENS shift 284 - OPEN_PARENS_CAST shift 285 - . error - - open_parens_any goto 329 - - -state 116 - integral_type : INT . (414) - - . reduce 414 - - -state 117 - lock_statement : LOCK . open_parens_any expression CLOSE_PARENS embedded_statement (844) - - OPEN_PARENS shift 284 - OPEN_PARENS_CAST shift 285 - . error - - open_parens_any goto 330 - - -state 118 - integral_type : LONG . (416) - - . reduce 416 - - -state 119 - object_or_delegate_creation_expression : NEW . new_expr_type open_parens_any opt_argument_list CLOSE_PARENS opt_object_or_collection_initializer (507) - object_or_delegate_creation_expression : NEW . new_expr_type object_or_collection_initializer (508) - array_creation_expression : NEW . new_expr_type OPEN_BRACKET_EXPR expression_list CLOSE_BRACKET opt_rank_specifier opt_array_initializer (509) - array_creation_expression : NEW . new_expr_type rank_specifiers opt_array_initializer (510) - array_creation_expression : NEW . rank_specifiers array_initializer (511) - array_creation_expression : NEW . new_expr_type OPEN_BRACKET CLOSE_BRACKET OPEN_BRACKET_EXPR error CLOSE_BRACKET (512) - array_creation_expression : NEW . new_expr_type error (513) - anonymous_type_expression : NEW . OPEN_BRACE anonymous_type_parameters_opt_comma CLOSE_BRACE (516) - $$62 : . (514) - - OPEN_BRACE shift 331 - OPEN_BRACKET shift 332 - BOOL reduce 514 - BYTE reduce 514 - CHAR reduce 514 - DECIMAL reduce 514 - DOUBLE reduce 514 - FLOAT reduce 514 - INT reduce 514 - LONG reduce 514 - OBJECT reduce 514 - SBYTE reduce 514 - SHORT reduce 514 - STRING reduce 514 - UINT reduce 514 - ULONG reduce 514 - USHORT reduce 514 - VOID reduce 514 - IDENTIFIER reduce 514 - - rank_specifiers goto 333 - new_expr_type goto 334 - $$62 goto 335 - rank_specifier goto 336 - - -state 120 - literal : NULL . (443) - - . reduce 443 - - -state 121 - builtin_types : OBJECT . (403) - - . reduce 403 - - -state 122 - return_statement : RETURN . opt_expression SEMICOLON (814) - opt_expression : . (818) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - SEMICOLON reduce 818 - - expression goto 338 - opt_expression goto 339 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 123 - integral_type : SBYTE . (410) - - . reduce 410 - - -state 124 - integral_type : SHORT . (412) - - . reduce 412 - - -state 125 - sizeof_expression : SIZEOF . open_parens_any type CLOSE_PARENS (556) - - OPEN_PARENS shift 284 - OPEN_PARENS_CAST shift 285 - . error - - open_parens_any goto 342 - - -state 126 - builtin_types : STRING . (404) - - . reduce 404 - - -state 127 - switch_statement : SWITCH . open_parens_any $$77 expression CLOSE_PARENS OPEN_BRACE opt_switch_sections CLOSE_BRACE (770) - - OPEN_PARENS shift 284 - OPEN_PARENS_CAST shift 285 - . error - - open_parens_any goto 343 - - -state 128 - this_access : THIS . (502) - - . reduce 502 - - -state 129 - throw_statement : THROW . opt_expression SEMICOLON (815) - opt_expression : . (818) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - SEMICOLON reduce 818 - - expression goto 338 - opt_expression goto 344 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 130 - boolean_literal : TRUE . (444) - - . reduce 444 - - -state 131 - try_statement : TRY . block catch_clauses (820) - try_statement : TRY . block FINALLY block (821) - try_statement : TRY . block catch_clauses FINALLY block (822) - try_statement : TRY . block error (823) - - OPEN_BRACE shift 143 - . error - - block goto 345 - - -state 132 - typeof_expression : TYPEOF . $$63 open_parens_any typeof_type_expression CLOSE_PARENS (545) - $$63 : . (544) - - . reduce 544 - - $$63 goto 346 - - -state 133 - integral_type : UINT . (415) - - . reduce 415 - - -state 134 - integral_type : ULONG . (417) - - . reduce 417 - - -state 135 - unchecked_expression : UNCHECKED . open_parens_any expression CLOSE_PARENS (558) - unchecked_statement : UNCHECKED . block (835) - - OPEN_BRACE shift 143 - OPEN_PARENS shift 284 - OPEN_PARENS_CAST shift 285 - . error - - block goto 347 - open_parens_any goto 348 - - -state 136 - unsafe_statement : UNSAFE . $$82 block (837) - $$82 : . (836) - - . reduce 836 - - $$82 goto 349 - - -state 137 - integral_type : USHORT . (413) - - . reduce 413 - - -state 138 - using_statement : USING . open_parens_any local_variable_declaration CLOSE_PARENS $$84 embedded_statement (846) - using_statement : USING . open_parens_any expression CLOSE_PARENS $$85 embedded_statement (848) - - OPEN_PARENS shift 284 - OPEN_PARENS_CAST shift 285 - . error - - open_parens_any goto 350 - - -state 139 - variable_type : VOID . opt_rank_specifier (744) - local_variable_pointer_type : VOID . STAR (747) - opt_rank_specifier : . (527) - - OPEN_BRACKET shift 332 - STAR shift 351 - IDENTIFIER reduce 527 - - rank_specifiers goto 352 - opt_rank_specifier goto 353 - rank_specifier goto 336 - - -state 140 - while_statement : WHILE . open_parens_any boolean_expression CLOSE_PARENS embedded_statement (785) - - OPEN_PARENS shift 284 - OPEN_PARENS_CAST shift 285 - . error - - open_parens_any goto 354 - - -state 141 - nested_from_clause : FROM . IDENTIFIER IN expression (855) - nested_from_clause : FROM . type IDENTIFIER IN expression (856) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 355 - . error - - namespace_or_type_name goto 255 - type goto 356 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 142 - first_from_clause : FROM_FIRST . IDENTIFIER IN expression (853) - first_from_clause : FROM_FIRST . type IDENTIFIER IN expression (854) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 357 - . error - - namespace_or_type_name goto 255 - type goto 358 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 143 - block : OPEN_BRACE . $$74 opt_statement_list block_end (691) - $$74 : . (690) - - . reduce 690 - - $$74 goto 359 - - -state 144 - parenthesized_expression : OPEN_PARENS . expression CLOSE_PARENS (450) - parenthesized_expression : OPEN_PARENS . expression COMPLETE_COMPLETION (451) - cast_expression : OPEN_PARENS . builtin_types CLOSE_PARENS prefixed_unary_expression (572) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 360 - qualified_alias_member goto 160 - builtin_types goto 361 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 145 - empty_statement : SEMICOLON . (737) - - . reduce 737 - - -state 146 - unary_expression : TILDE . prefixed_unary_expression (569) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 362 - cast_expression goto 188 - - -state 147 - prefixed_unary_expression : PLUS . prefixed_unary_expression (574) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 363 - cast_expression goto 188 - - -state 148 - prefixed_unary_expression : MINUS . prefixed_unary_expression (575) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 364 - cast_expression goto 188 - - -state 149 - unary_expression : BANG . prefixed_unary_expression (568) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 365 - cast_expression goto 188 - - -state 150 - prefixed_unary_expression : BITWISE_AND . prefixed_unary_expression (579) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 366 - cast_expression goto 188 - - -state 151 - prefixed_unary_expression : STAR . prefixed_unary_expression (578) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 367 - cast_expression goto 188 - - -state 152 - prefixed_unary_expression : OP_INC . prefixed_unary_expression (576) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 368 - cast_expression goto 188 - - -state 153 - prefixed_unary_expression : OP_DEC . prefixed_unary_expression (577) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 369 - cast_expression goto 188 - - -state 154 - literal : LITERAL . (442) - - . reduce 442 - - -state 155 - primary_expression_no_array_creation : IDENTIFIER . opt_type_argument_list (422) - primary_expression_no_array_creation : IDENTIFIER . GENERATE_COMPLETION (423) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - lambda_expression : IDENTIFIER . ARROW $$67 lambda_expression_body (637) - labeled_statement : IDENTIFIER . COLON $$76 statement (739) - yield_statement : IDENTIFIER . RETURN opt_expression SEMICOLON (816) - yield_statement : IDENTIFIER . BREAK SEMICOLON (817) - opt_type_argument_list : . (363) - - BREAK shift 370 - RETURN shift 371 - ARROW shift 372 - OP_GENERICS_LT shift 81 - COLON shift 373 - DOUBLE_COLON shift 83 - GENERATE_COMPLETION shift 374 - AS reduce 363 - IS reduce 363 - INTERR_NULLABLE reduce 363 - OPEN_BRACKET reduce 363 - OPEN_PARENS reduce 363 - DOT reduce 363 - SEMICOLON reduce 363 - PLUS reduce 363 - MINUS reduce 363 - ASSIGN reduce 363 - OP_LT reduce 363 - OP_GT reduce 363 - BITWISE_AND reduce 363 - BITWISE_OR reduce 363 - STAR reduce 363 - PERCENT reduce 363 - DIV reduce 363 - CARRET reduce 363 - INTERR reduce 363 - OP_INC reduce 363 - OP_DEC reduce 363 - OP_SHIFT_LEFT reduce 363 - OP_SHIFT_RIGHT reduce 363 - OP_LE reduce 363 - OP_GE reduce 363 - OP_EQ reduce 363 - OP_NE reduce 363 - OP_AND reduce 363 - OP_OR reduce 363 - OP_MULT_ASSIGN reduce 363 - OP_DIV_ASSIGN reduce 363 - OP_MOD_ASSIGN reduce 363 - OP_ADD_ASSIGN reduce 363 - OP_SUB_ASSIGN reduce 363 - OP_SHIFT_LEFT_ASSIGN reduce 363 - OP_SHIFT_RIGHT_ASSIGN reduce 363 - OP_AND_ASSIGN reduce 363 - OP_XOR_ASSIGN reduce 363 - OP_OR_ASSIGN reduce 363 - OP_PTR reduce 363 - OP_COALESCING reduce 363 - IDENTIFIER reduce 363 - OPEN_PARENS_CAST reduce 363 - OPEN_BRACKET_EXPR reduce 363 - COMPLETE_COMPLETION reduce 363 - - opt_type_argument_list goto 375 - - -state 156 - lambda_expression : OPEN_PARENS_LAMBDA . $$68 opt_lambda_parameter_list CLOSE_PARENS ARROW $$69 lambda_expression_body (640) - $$68 : . (638) - - . reduce 638 - - $$68 goto 376 - - -state 157 - cast_expression : OPEN_PARENS_CAST . type CLOSE_PARENS prefixed_unary_expression (571) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 377 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 158 - interactive_statement_expression : expression . (763) - - . reduce 763 - - -state 159 - interactive_valid_declaration_statement : block . (721) - - . reduce 721 - - -state 160 - member_access : qualified_alias_member . IDENTIFIER opt_type_argument_list (455) - - IDENTIFIER shift 378 - . error - - -state 161 - member_access : builtin_types . DOT IDENTIFIER opt_type_argument_list (453) - member_access : builtin_types . DOT GENERATE_COMPLETION (458) - member_access : builtin_types . DOT IDENTIFIER GENERATE_COMPLETION (459) - variable_type : builtin_types . opt_rank_specifier_or_nullable (743) - local_variable_pointer_type : builtin_types . STAR (746) - opt_nullable : . (356) - - INTERR_NULLABLE shift 379 - DOT shift 380 - STAR shift 381 - OPEN_BRACKET reduce 356 - IDENTIFIER reduce 356 - - opt_nullable goto 382 - opt_rank_specifier_or_nullable goto 383 - - -state 162 - builtin_types : integral_type . (409) - - . reduce 409 - - -state 163 - member_access : primary_expression . DOT IDENTIFIER opt_type_argument_list (452) - member_access : primary_expression . DOT GENERATE_COMPLETION (456) - member_access : primary_expression . DOT IDENTIFIER GENERATE_COMPLETION (457) - invocation_expression : primary_expression . open_parens_any opt_argument_list close_parens (460) - element_access : primary_expression . OPEN_BRACKET_EXPR expression_list_arguments CLOSE_BRACKET (494) - post_increment_expression : primary_expression . OP_INC (505) - post_decrement_expression : primary_expression . OP_DEC (506) - pointer_member_access : primary_expression . OP_PTR IDENTIFIER (559) - unary_expression : primary_expression . (567) - - OPEN_PARENS shift 284 - DOT shift 384 - OP_INC shift 385 - OP_DEC shift 386 - OP_PTR shift 387 - OPEN_PARENS_CAST shift 285 - OPEN_BRACKET_EXPR shift 388 - error reduce 567 - AS reduce 567 - IS reduce 567 - WHERE reduce 567 - FROM reduce 567 - JOIN reduce 567 - ON reduce 567 - EQUALS reduce 567 - SELECT reduce 567 - GROUP reduce 567 - BY reduce 567 - LET reduce 567 - ORDERBY reduce 567 - ASCENDING reduce 567 - DESCENDING reduce 567 - INTO reduce 567 - CLOSE_BRACE reduce 567 - CLOSE_BRACKET reduce 567 - CLOSE_PARENS reduce 567 - COMMA reduce 567 - COLON reduce 567 - SEMICOLON reduce 567 - PLUS reduce 567 - MINUS reduce 567 - ASSIGN reduce 567 - OP_LT reduce 567 - OP_GT reduce 567 - BITWISE_AND reduce 567 - BITWISE_OR reduce 567 - STAR reduce 567 - PERCENT reduce 567 - DIV reduce 567 - CARRET reduce 567 - INTERR reduce 567 - OP_SHIFT_LEFT reduce 567 - OP_SHIFT_RIGHT reduce 567 - OP_LE reduce 567 - OP_GE reduce 567 - OP_EQ reduce 567 - OP_NE reduce 567 - OP_AND reduce 567 - OP_OR reduce 567 - OP_MULT_ASSIGN reduce 567 - OP_DIV_ASSIGN reduce 567 - OP_MOD_ASSIGN reduce 567 - OP_ADD_ASSIGN reduce 567 - OP_SUB_ASSIGN reduce 567 - OP_SHIFT_LEFT_ASSIGN reduce 567 - OP_SHIFT_RIGHT_ASSIGN reduce 567 - OP_AND_ASSIGN reduce 567 - OP_XOR_ASSIGN reduce 567 - OP_OR_ASSIGN reduce 567 - OP_COALESCING reduce 567 - COMPLETE_COMPLETION reduce 567 - - open_parens_any goto 389 - - -164: shift/reduce conflict (shift 390, reduce 419) on STAR -state 164 - primary_expression : primary_expression_no_array_creation . (419) - variable_type : primary_expression_no_array_creation . opt_rank_specifier_or_nullable (742) - local_variable_pointer_type : primary_expression_no_array_creation . STAR (745) - opt_nullable : . (356) - - INTERR_NULLABLE shift 379 - STAR shift 390 - AS reduce 419 - IS reduce 419 - OPEN_BRACKET reduce 356 - OPEN_PARENS reduce 419 - CLOSE_PARENS reduce 419 - DOT reduce 419 - COMMA reduce 419 - SEMICOLON reduce 419 - PLUS reduce 419 - MINUS reduce 419 - ASSIGN reduce 419 - OP_LT reduce 419 - OP_GT reduce 419 - BITWISE_AND reduce 419 - BITWISE_OR reduce 419 - PERCENT reduce 419 - DIV reduce 419 - CARRET reduce 419 - INTERR reduce 419 - OP_INC reduce 419 - OP_DEC reduce 419 - OP_SHIFT_LEFT reduce 419 - OP_SHIFT_RIGHT reduce 419 - OP_LE reduce 419 - OP_GE reduce 419 - OP_EQ reduce 419 - OP_NE reduce 419 - OP_AND reduce 419 - OP_OR reduce 419 - OP_MULT_ASSIGN reduce 419 - OP_DIV_ASSIGN reduce 419 - OP_MOD_ASSIGN reduce 419 - OP_ADD_ASSIGN reduce 419 - OP_SUB_ASSIGN reduce 419 - OP_SHIFT_LEFT_ASSIGN reduce 419 - OP_SHIFT_RIGHT_ASSIGN reduce 419 - OP_AND_ASSIGN reduce 419 - OP_XOR_ASSIGN reduce 419 - OP_OR_ASSIGN reduce 419 - OP_PTR reduce 419 - OP_COALESCING reduce 419 - IDENTIFIER reduce 356 - OPEN_PARENS_CAST reduce 419 - OPEN_BRACKET_EXPR reduce 419 - COMPLETE_COMPLETION reduce 419 - - opt_nullable goto 382 - opt_rank_specifier_or_nullable goto 391 - - -state 165 - primary_expression : array_creation_expression . (420) - - . reduce 420 - - -state 166 - primary_expression_no_array_creation : literal . (421) - - . reduce 421 - - -167: shift/reduce conflict (shift 392, reduce 424) on MINUS -state 167 - primary_expression_no_array_creation : parenthesized_expression . (424) - additive_expression : parenthesized_expression . MINUS multiplicative_expression (587) - - MINUS shift 392 - error reduce 424 - AS reduce 424 - IS reduce 424 - WHERE reduce 424 - FROM reduce 424 - JOIN reduce 424 - ON reduce 424 - EQUALS reduce 424 - SELECT reduce 424 - GROUP reduce 424 - BY reduce 424 - LET reduce 424 - ORDERBY reduce 424 - ASCENDING reduce 424 - DESCENDING reduce 424 - INTO reduce 424 - INTERR_NULLABLE reduce 424 - CLOSE_BRACE reduce 424 - OPEN_BRACKET reduce 424 - CLOSE_BRACKET reduce 424 - OPEN_PARENS reduce 424 - CLOSE_PARENS reduce 424 - DOT reduce 424 - COMMA reduce 424 - COLON reduce 424 - SEMICOLON reduce 424 - PLUS reduce 424 - ASSIGN reduce 424 - OP_LT reduce 424 - OP_GT reduce 424 - BITWISE_AND reduce 424 - BITWISE_OR reduce 424 - STAR reduce 424 - PERCENT reduce 424 - DIV reduce 424 - CARRET reduce 424 - INTERR reduce 424 - OP_INC reduce 424 - OP_DEC reduce 424 - OP_SHIFT_LEFT reduce 424 - OP_SHIFT_RIGHT reduce 424 - OP_LE reduce 424 - OP_GE reduce 424 - OP_EQ reduce 424 - OP_NE reduce 424 - OP_AND reduce 424 - OP_OR reduce 424 - OP_MULT_ASSIGN reduce 424 - OP_DIV_ASSIGN reduce 424 - OP_MOD_ASSIGN reduce 424 - OP_ADD_ASSIGN reduce 424 - OP_SUB_ASSIGN reduce 424 - OP_SHIFT_LEFT_ASSIGN reduce 424 - OP_SHIFT_RIGHT_ASSIGN reduce 424 - OP_AND_ASSIGN reduce 424 - OP_XOR_ASSIGN reduce 424 - OP_OR_ASSIGN reduce 424 - OP_PTR reduce 424 - OP_COALESCING reduce 424 - IDENTIFIER reduce 424 - OPEN_PARENS_CAST reduce 424 - OPEN_BRACKET_EXPR reduce 424 - COMPLETE_COMPLETION reduce 424 - - -state 168 - primary_expression_no_array_creation : default_value_expression . (425) - - . reduce 425 - - -state 169 - primary_expression_no_array_creation : member_access . (426) - - . reduce 426 - - -state 170 - primary_expression_no_array_creation : invocation_expression . (427) - - . reduce 427 - - -state 171 - primary_expression_no_array_creation : element_access . (428) - - . reduce 428 - - -state 172 - primary_expression_no_array_creation : this_access . (429) - - . reduce 429 - - -state 173 - primary_expression_no_array_creation : base_access . (430) - - . reduce 430 - - -state 174 - primary_expression_no_array_creation : post_increment_expression . (431) - - . reduce 431 - - -state 175 - primary_expression_no_array_creation : post_decrement_expression . (432) - - . reduce 432 - - -state 176 - primary_expression_no_array_creation : object_or_delegate_creation_expression . (433) - - . reduce 433 - - -state 177 - primary_expression_no_array_creation : anonymous_type_expression . (434) - - . reduce 434 - - -state 178 - primary_expression_no_array_creation : typeof_expression . (435) - - . reduce 435 - - -state 179 - primary_expression_no_array_creation : sizeof_expression . (436) - - . reduce 436 - - -state 180 - primary_expression_no_array_creation : checked_expression . (437) - - . reduce 437 - - -state 181 - primary_expression_no_array_creation : unchecked_expression . (438) - - . reduce 438 - - -state 182 - primary_expression_no_array_creation : pointer_member_access . (439) - - . reduce 439 - - -state 183 - primary_expression_no_array_creation : anonymous_method_expression . (440) - - . reduce 440 - - -state 184 - literal : boolean_literal . (441) - - . reduce 441 - - -state 185 - expression : non_assignment_expression . (642) - - . reduce 642 - - -state 186 - prefixed_unary_expression : unary_expression . (573) - - . reduce 573 - - -state 187 - multiplicative_expression : prefixed_unary_expression . (580) - assignment_expression : prefixed_unary_expression . ASSIGN expression (615) - assignment_expression : prefixed_unary_expression . OP_MULT_ASSIGN expression (616) - assignment_expression : prefixed_unary_expression . OP_DIV_ASSIGN expression (617) - assignment_expression : prefixed_unary_expression . OP_MOD_ASSIGN expression (618) - assignment_expression : prefixed_unary_expression . OP_ADD_ASSIGN expression (619) - assignment_expression : prefixed_unary_expression . OP_SUB_ASSIGN expression (620) - assignment_expression : prefixed_unary_expression . OP_SHIFT_LEFT_ASSIGN expression (621) - assignment_expression : prefixed_unary_expression . OP_SHIFT_RIGHT_ASSIGN expression (622) - assignment_expression : prefixed_unary_expression . OP_AND_ASSIGN expression (623) - assignment_expression : prefixed_unary_expression . OP_OR_ASSIGN expression (624) - assignment_expression : prefixed_unary_expression . OP_XOR_ASSIGN expression (625) - - ASSIGN shift 393 - OP_MULT_ASSIGN shift 394 - OP_DIV_ASSIGN shift 395 - OP_MOD_ASSIGN shift 396 - OP_ADD_ASSIGN shift 397 - OP_SUB_ASSIGN shift 398 - OP_SHIFT_LEFT_ASSIGN shift 399 - OP_SHIFT_RIGHT_ASSIGN shift 400 - OP_AND_ASSIGN shift 401 - OP_XOR_ASSIGN shift 402 - OP_OR_ASSIGN shift 403 - error reduce 580 - AS reduce 580 - IS reduce 580 - WHERE reduce 580 - FROM reduce 580 - JOIN reduce 580 - ON reduce 580 - EQUALS reduce 580 - SELECT reduce 580 - GROUP reduce 580 - BY reduce 580 - LET reduce 580 - ORDERBY reduce 580 - ASCENDING reduce 580 - DESCENDING reduce 580 - INTO reduce 580 - CLOSE_BRACE reduce 580 - CLOSE_BRACKET reduce 580 - CLOSE_PARENS reduce 580 - COMMA reduce 580 - COLON reduce 580 - SEMICOLON reduce 580 - PLUS reduce 580 - MINUS reduce 580 - OP_LT reduce 580 - OP_GT reduce 580 - BITWISE_AND reduce 580 - BITWISE_OR reduce 580 - STAR reduce 580 - PERCENT reduce 580 - DIV reduce 580 - CARRET reduce 580 - INTERR reduce 580 - OP_SHIFT_LEFT reduce 580 - OP_SHIFT_RIGHT reduce 580 - OP_LE reduce 580 - OP_GE reduce 580 - OP_EQ reduce 580 - OP_NE reduce 580 - OP_AND reduce 580 - OP_OR reduce 580 - OP_COALESCING reduce 580 - COMPLETE_COMPLETION reduce 580 - - -state 188 - unary_expression : cast_expression . (570) - - . reduce 570 - - -state 189 - multiplicative_expression : multiplicative_expression . STAR prefixed_unary_expression (581) - multiplicative_expression : multiplicative_expression . DIV prefixed_unary_expression (582) - multiplicative_expression : multiplicative_expression . PERCENT prefixed_unary_expression (583) - additive_expression : multiplicative_expression . (584) - - STAR shift 404 - PERCENT shift 405 - DIV shift 406 - error reduce 584 - AS reduce 584 - IS reduce 584 - WHERE reduce 584 - FROM reduce 584 - JOIN reduce 584 - ON reduce 584 - EQUALS reduce 584 - SELECT reduce 584 - GROUP reduce 584 - BY reduce 584 - LET reduce 584 - ORDERBY reduce 584 - ASCENDING reduce 584 - DESCENDING reduce 584 - INTO reduce 584 - CLOSE_BRACE reduce 584 - CLOSE_BRACKET reduce 584 - CLOSE_PARENS reduce 584 - COMMA reduce 584 - COLON reduce 584 - SEMICOLON reduce 584 - PLUS reduce 584 - MINUS reduce 584 - OP_LT reduce 584 - OP_GT reduce 584 - BITWISE_AND reduce 584 - BITWISE_OR reduce 584 - CARRET reduce 584 - INTERR reduce 584 - OP_SHIFT_LEFT reduce 584 - OP_SHIFT_RIGHT reduce 584 - OP_LE reduce 584 - OP_GE reduce 584 - OP_EQ reduce 584 - OP_NE reduce 584 - OP_AND reduce 584 - OP_OR reduce 584 - OP_COALESCING reduce 584 - COMPLETE_COMPLETION reduce 584 - - -state 190 - additive_expression : additive_expression . PLUS multiplicative_expression (585) - additive_expression : additive_expression . MINUS multiplicative_expression (586) - additive_expression : additive_expression . AS type (588) - additive_expression : additive_expression . IS type (589) - shift_expression : additive_expression . (590) - - AS shift 407 - IS shift 408 - PLUS shift 409 - MINUS shift 410 - error reduce 590 - WHERE reduce 590 - FROM reduce 590 - JOIN reduce 590 - ON reduce 590 - EQUALS reduce 590 - SELECT reduce 590 - GROUP reduce 590 - BY reduce 590 - LET reduce 590 - ORDERBY reduce 590 - ASCENDING reduce 590 - DESCENDING reduce 590 - INTO reduce 590 - CLOSE_BRACE reduce 590 - CLOSE_BRACKET reduce 590 - CLOSE_PARENS reduce 590 - COMMA reduce 590 - COLON reduce 590 - SEMICOLON reduce 590 - OP_LT reduce 590 - OP_GT reduce 590 - BITWISE_AND reduce 590 - BITWISE_OR reduce 590 - CARRET reduce 590 - INTERR reduce 590 - OP_SHIFT_LEFT reduce 590 - OP_SHIFT_RIGHT reduce 590 - OP_LE reduce 590 - OP_GE reduce 590 - OP_EQ reduce 590 - OP_NE reduce 590 - OP_AND reduce 590 - OP_OR reduce 590 - OP_COALESCING reduce 590 - COMPLETE_COMPLETION reduce 590 - - -state 191 - shift_expression : shift_expression . OP_SHIFT_LEFT additive_expression (591) - shift_expression : shift_expression . OP_SHIFT_RIGHT additive_expression (592) - relational_expression : shift_expression . (593) - - OP_SHIFT_LEFT shift 411 - OP_SHIFT_RIGHT shift 412 - error reduce 593 - WHERE reduce 593 - FROM reduce 593 - JOIN reduce 593 - ON reduce 593 - EQUALS reduce 593 - SELECT reduce 593 - GROUP reduce 593 - BY reduce 593 - LET reduce 593 - ORDERBY reduce 593 - ASCENDING reduce 593 - DESCENDING reduce 593 - INTO reduce 593 - CLOSE_BRACE reduce 593 - CLOSE_BRACKET reduce 593 - CLOSE_PARENS reduce 593 - COMMA reduce 593 - COLON reduce 593 - SEMICOLON reduce 593 - OP_LT reduce 593 - OP_GT reduce 593 - BITWISE_AND reduce 593 - BITWISE_OR reduce 593 - CARRET reduce 593 - INTERR reduce 593 - OP_LE reduce 593 - OP_GE reduce 593 - OP_EQ reduce 593 - OP_NE reduce 593 - OP_AND reduce 593 - OP_OR reduce 593 - OP_COALESCING reduce 593 - COMPLETE_COMPLETION reduce 593 - - -state 192 - relational_expression : relational_expression . OP_LT shift_expression (594) - relational_expression : relational_expression . OP_GT shift_expression (595) - relational_expression : relational_expression . OP_LE shift_expression (596) - relational_expression : relational_expression . OP_GE shift_expression (597) - equality_expression : relational_expression . (598) - - OP_LT shift 413 - OP_GT shift 414 - OP_LE shift 415 - OP_GE shift 416 - error reduce 598 - WHERE reduce 598 - FROM reduce 598 - JOIN reduce 598 - ON reduce 598 - EQUALS reduce 598 - SELECT reduce 598 - GROUP reduce 598 - BY reduce 598 - LET reduce 598 - ORDERBY reduce 598 - ASCENDING reduce 598 - DESCENDING reduce 598 - INTO reduce 598 - CLOSE_BRACE reduce 598 - CLOSE_BRACKET reduce 598 - CLOSE_PARENS reduce 598 - COMMA reduce 598 - COLON reduce 598 - SEMICOLON reduce 598 - BITWISE_AND reduce 598 - BITWISE_OR reduce 598 - CARRET reduce 598 - INTERR reduce 598 - OP_EQ reduce 598 - OP_NE reduce 598 - OP_AND reduce 598 - OP_OR reduce 598 - OP_COALESCING reduce 598 - COMPLETE_COMPLETION reduce 598 - - -state 193 - equality_expression : equality_expression . OP_EQ relational_expression (599) - equality_expression : equality_expression . OP_NE relational_expression (600) - and_expression : equality_expression . (601) - - OP_EQ shift 417 - OP_NE shift 418 - error reduce 601 - WHERE reduce 601 - FROM reduce 601 - JOIN reduce 601 - ON reduce 601 - EQUALS reduce 601 - SELECT reduce 601 - GROUP reduce 601 - BY reduce 601 - LET reduce 601 - ORDERBY reduce 601 - ASCENDING reduce 601 - DESCENDING reduce 601 - INTO reduce 601 - CLOSE_BRACE reduce 601 - CLOSE_BRACKET reduce 601 - CLOSE_PARENS reduce 601 - COMMA reduce 601 - COLON reduce 601 - SEMICOLON reduce 601 - BITWISE_AND reduce 601 - BITWISE_OR reduce 601 - CARRET reduce 601 - INTERR reduce 601 - OP_AND reduce 601 - OP_OR reduce 601 - OP_COALESCING reduce 601 - COMPLETE_COMPLETION reduce 601 - - -state 194 - and_expression : and_expression . BITWISE_AND equality_expression (602) - exclusive_or_expression : and_expression . (603) - - BITWISE_AND shift 419 - error reduce 603 - WHERE reduce 603 - FROM reduce 603 - JOIN reduce 603 - ON reduce 603 - EQUALS reduce 603 - SELECT reduce 603 - GROUP reduce 603 - BY reduce 603 - LET reduce 603 - ORDERBY reduce 603 - ASCENDING reduce 603 - DESCENDING reduce 603 - INTO reduce 603 - CLOSE_BRACE reduce 603 - CLOSE_BRACKET reduce 603 - CLOSE_PARENS reduce 603 - COMMA reduce 603 - COLON reduce 603 - SEMICOLON reduce 603 - BITWISE_OR reduce 603 - CARRET reduce 603 - INTERR reduce 603 - OP_AND reduce 603 - OP_OR reduce 603 - OP_COALESCING reduce 603 - COMPLETE_COMPLETION reduce 603 - - -state 195 - exclusive_or_expression : exclusive_or_expression . CARRET and_expression (604) - inclusive_or_expression : exclusive_or_expression . (605) - - CARRET shift 420 - error reduce 605 - WHERE reduce 605 - FROM reduce 605 - JOIN reduce 605 - ON reduce 605 - EQUALS reduce 605 - SELECT reduce 605 - GROUP reduce 605 - BY reduce 605 - LET reduce 605 - ORDERBY reduce 605 - ASCENDING reduce 605 - DESCENDING reduce 605 - INTO reduce 605 - CLOSE_BRACE reduce 605 - CLOSE_BRACKET reduce 605 - CLOSE_PARENS reduce 605 - COMMA reduce 605 - COLON reduce 605 - SEMICOLON reduce 605 - BITWISE_OR reduce 605 - INTERR reduce 605 - OP_AND reduce 605 - OP_OR reduce 605 - OP_COALESCING reduce 605 - COMPLETE_COMPLETION reduce 605 - - -state 196 - inclusive_or_expression : inclusive_or_expression . BITWISE_OR exclusive_or_expression (606) - conditional_and_expression : inclusive_or_expression . (607) - - BITWISE_OR shift 421 - error reduce 607 - WHERE reduce 607 - FROM reduce 607 - JOIN reduce 607 - ON reduce 607 - EQUALS reduce 607 - SELECT reduce 607 - GROUP reduce 607 - BY reduce 607 - LET reduce 607 - ORDERBY reduce 607 - ASCENDING reduce 607 - DESCENDING reduce 607 - INTO reduce 607 - CLOSE_BRACE reduce 607 - CLOSE_BRACKET reduce 607 - CLOSE_PARENS reduce 607 - COMMA reduce 607 - COLON reduce 607 - SEMICOLON reduce 607 - INTERR reduce 607 - OP_AND reduce 607 - OP_OR reduce 607 - OP_COALESCING reduce 607 - COMPLETE_COMPLETION reduce 607 - - -state 197 - conditional_and_expression : conditional_and_expression . OP_AND inclusive_or_expression (608) - conditional_or_expression : conditional_and_expression . (609) - - OP_AND shift 422 - error reduce 609 - WHERE reduce 609 - FROM reduce 609 - JOIN reduce 609 - ON reduce 609 - EQUALS reduce 609 - SELECT reduce 609 - GROUP reduce 609 - BY reduce 609 - LET reduce 609 - ORDERBY reduce 609 - ASCENDING reduce 609 - DESCENDING reduce 609 - INTO reduce 609 - CLOSE_BRACE reduce 609 - CLOSE_BRACKET reduce 609 - CLOSE_PARENS reduce 609 - COMMA reduce 609 - COLON reduce 609 - SEMICOLON reduce 609 - INTERR reduce 609 - OP_OR reduce 609 - OP_COALESCING reduce 609 - COMPLETE_COMPLETION reduce 609 - - -state 198 - conditional_or_expression : conditional_or_expression . OP_OR conditional_and_expression (610) - null_coalescing_expression : conditional_or_expression . (611) - null_coalescing_expression : conditional_or_expression . OP_COALESCING null_coalescing_expression (612) - - OP_OR shift 423 - OP_COALESCING shift 424 - error reduce 611 - WHERE reduce 611 - FROM reduce 611 - JOIN reduce 611 - ON reduce 611 - EQUALS reduce 611 - SELECT reduce 611 - GROUP reduce 611 - BY reduce 611 - LET reduce 611 - ORDERBY reduce 611 - ASCENDING reduce 611 - DESCENDING reduce 611 - INTO reduce 611 - CLOSE_BRACE reduce 611 - CLOSE_BRACKET reduce 611 - CLOSE_PARENS reduce 611 - COMMA reduce 611 - COLON reduce 611 - SEMICOLON reduce 611 - INTERR reduce 611 - COMPLETE_COMPLETION reduce 611 - - -state 199 - conditional_expression : null_coalescing_expression . (613) - conditional_expression : null_coalescing_expression . INTERR expression COLON expression (614) - - INTERR shift 425 - error reduce 613 - WHERE reduce 613 - FROM reduce 613 - JOIN reduce 613 - ON reduce 613 - EQUALS reduce 613 - SELECT reduce 613 - GROUP reduce 613 - BY reduce 613 - LET reduce 613 - ORDERBY reduce 613 - ASCENDING reduce 613 - DESCENDING reduce 613 - INTO reduce 613 - CLOSE_BRACE reduce 613 - CLOSE_BRACKET reduce 613 - CLOSE_PARENS reduce 613 - COMMA reduce 613 - COLON reduce 613 - SEMICOLON reduce 613 - COMPLETE_COMPLETION reduce 613 - - -state 200 - non_assignment_expression : conditional_expression . (643) - - . reduce 643 - - -state 201 - expression : assignment_expression . (641) - - . reduce 641 - - -state 202 - non_assignment_expression : lambda_expression . (644) - - . reduce 644 - - -state 203 - non_assignment_expression : query_expression . (645) - - . reduce 645 - - -state 204 - interactive_statement : declaration_statement . (705) - - . reduce 705 - - -state 205 - interactive_statement : labeled_statement . (707) - - . reduce 707 - - -state 206 - interactive_statement_list : interactive_statement_list . interactive_statement (704) - interactive_parsing : EVAL_STATEMENT_PARSER $$103 interactive_statement_list . opt_COMPLETE_COMPLETION (911) - opt_COMPLETE_COMPLETION : . (918) - - error shift 95 - BASE shift 96 - BOOL shift 97 - BREAK shift 98 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 101 - CONST shift 102 - CONTINUE shift 103 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DO shift 107 - DOUBLE shift 108 - FALSE shift 109 - FIXED shift 110 - FLOAT shift 111 - FOR shift 112 - FOREACH shift 113 - GOTO shift 114 - IF shift 115 - INT shift 116 - LOCK shift 117 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - RETURN shift 122 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - SWITCH shift 127 - THIS shift 128 - THROW shift 129 - TRUE shift 130 - TRY shift 131 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 135 - UNSAFE shift 136 - USHORT shift 137 - USING shift 138 - VOID shift 139 - WHILE shift 140 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 143 - OPEN_PARENS shift 144 - SEMICOLON shift 145 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 155 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - COMPLETE_COMPLETION shift 426 - $end reduce 918 - EOF reduce 918 - - expression goto 158 - block goto 159 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - opt_COMPLETE_COMPLETION goto 427 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - declaration_statement goto 204 - labeled_statement goto 205 - interactive_statement goto 428 - interactive_valid_declaration_statement goto 208 - empty_statement goto 209 - selection_statement goto 210 - iteration_statement goto 211 - jump_statement goto 212 - try_statement goto 213 - checked_statement goto 214 - unchecked_statement goto 215 - lock_statement goto 216 - using_statement goto 217 - unsafe_statement goto 218 - fixed_statement goto 219 - interactive_expression_statement goto 220 - local_variable_declaration goto 221 - local_constant_declaration goto 222 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - interactive_statement_expression goto 226 - if_statement goto 227 - switch_statement goto 228 - while_statement goto 229 - do_statement goto 230 - for_statement goto 231 - foreach_statement goto 232 - break_statement goto 233 - continue_statement goto 234 - goto_statement goto 235 - return_statement goto 236 - throw_statement goto 237 - yield_statement goto 238 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 207 - interactive_statement_list : interactive_statement . (703) - - . reduce 703 - - -state 208 - interactive_statement : interactive_valid_declaration_statement . (706) - - . reduce 706 - - -state 209 - interactive_valid_declaration_statement : empty_statement . (722) - - . reduce 722 - - -state 210 - interactive_valid_declaration_statement : selection_statement . (724) - - . reduce 724 - - -state 211 - interactive_valid_declaration_statement : iteration_statement . (725) - - . reduce 725 - - -state 212 - interactive_valid_declaration_statement : jump_statement . (726) - - . reduce 726 - - -state 213 - interactive_valid_declaration_statement : try_statement . (727) - - . reduce 727 - - -state 214 - interactive_valid_declaration_statement : checked_statement . (728) - - . reduce 728 - - -state 215 - interactive_valid_declaration_statement : unchecked_statement . (729) - - . reduce 729 - - -state 216 - interactive_valid_declaration_statement : lock_statement . (730) - - . reduce 730 - - -state 217 - interactive_valid_declaration_statement : using_statement . (731) - - . reduce 731 - - -state 218 - interactive_valid_declaration_statement : unsafe_statement . (732) - - . reduce 732 - - -state 219 - interactive_valid_declaration_statement : fixed_statement . (733) - - . reduce 733 - - -state 220 - interactive_valid_declaration_statement : interactive_expression_statement . (723) - - . reduce 723 - - -state 221 - declaration_statement : local_variable_declaration . SEMICOLON (740) - - SEMICOLON shift 429 - . error - - -state 222 - declaration_statement : local_constant_declaration . SEMICOLON (741) - - SEMICOLON shift 430 - . error - - -state 223 - local_variable_type : variable_type . (749) - - . reduce 749 - - -state 224 - local_variable_pointer_type : local_variable_pointer_type . STAR (748) - local_variable_type : local_variable_pointer_type . opt_rank_specifier (750) - opt_rank_specifier : . (527) - - OPEN_BRACKET shift 332 - STAR shift 431 - IDENTIFIER reduce 527 - - rank_specifiers goto 352 - opt_rank_specifier goto 432 - rank_specifier goto 336 - - -state 225 - local_variable_declaration : local_variable_type . local_variable_declarators (751) - - IDENTIFIER shift 433 - . error - - local_variable_declarators goto 434 - local_variable_declarator goto 435 - - -state 226 - interactive_expression_statement : interactive_statement_expression . SEMICOLON (759) - interactive_expression_statement : interactive_statement_expression . COMPLETE_COMPLETION (760) - - SEMICOLON shift 436 - COMPLETE_COMPLETION shift 437 - . error - - -state 227 - selection_statement : if_statement . (765) - - . reduce 765 - - -state 228 - selection_statement : switch_statement . (766) - - . reduce 766 - - -state 229 - iteration_statement : while_statement . (781) - - . reduce 781 - - -state 230 - iteration_statement : do_statement . (782) - - . reduce 782 - - -state 231 - iteration_statement : for_statement . (783) - - . reduce 783 - - -state 232 - iteration_statement : foreach_statement . (784) - - . reduce 784 - - -state 233 - jump_statement : break_statement . (803) - - . reduce 803 - - -state 234 - jump_statement : continue_statement . (804) - - . reduce 804 - - -state 235 - jump_statement : goto_statement . (805) - - . reduce 805 - - -state 236 - jump_statement : return_statement . (806) - - . reduce 806 - - -state 237 - jump_statement : throw_statement . (807) - - . reduce 807 - - -state 238 - jump_statement : yield_statement . (808) - - . reduce 808 - - -239: shift/reduce conflict (shift 443, reduce 868) on COMPLETE_COMPLETION -state 239 - query_expression : first_from_clause . query_body (849) - query_expression : first_from_clause . COMPLETE_COMPLETION (851) - opt_query_body_clauses : . (868) - - WHERE shift 438 - FROM shift 439 - JOIN shift 440 - LET shift 441 - ORDERBY shift 442 - COMPLETE_COMPLETION shift 443 - SELECT reduce 868 - GROUP reduce 868 - - query_body goto 444 - from_clause goto 445 - opt_query_body_clauses goto 446 - query_body_clauses goto 447 - query_body_clause goto 448 - let_clause goto 449 - where_clause goto 450 - join_clause goto 451 - orderby_clause goto 452 - - -240: shift/reduce conflict (shift 453, reduce 868) on COMPLETE_COMPLETION -state 240 - query_expression : nested_from_clause . query_body (850) - query_expression : nested_from_clause . COMPLETE_COMPLETION (852) - opt_query_body_clauses : . (868) - - WHERE shift 438 - FROM shift 439 - JOIN shift 440 - LET shift 441 - ORDERBY shift 442 - COMPLETE_COMPLETION shift 453 - SELECT reduce 868 - GROUP reduce 868 - - query_body goto 454 - from_clause goto 445 - opt_query_body_clauses goto 446 - query_body_clauses goto 447 - query_body_clause goto 448 - let_clause goto 449 - where_clause goto 450 - join_clause goto 451 - orderby_clause goto 452 - - -state 241 - outer_declarations : outer_declarations . outer_declaration (10) - interactive_compilation_unit : outer_declarations . (914) - interactive_compilation_unit : outer_declarations . global_attributes (915) - opt_attributes : . (59) - - USING shift 2 - EXTERN_ALIAS shift 3 - OPEN_BRACKET shift 4 - $end reduce 914 - EOF reduce 914 - ABSTRACT reduce 59 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - CLASS reduce 59 - DECIMAL reduce 59 - DELEGATE reduce 59 - DOUBLE reduce 59 - ENUM reduce 59 - EXTERN reduce 59 - FIXED reduce 59 - FLOAT reduce 59 - INT reduce 59 - INTERFACE reduce 59 - INTERNAL reduce 59 - LONG reduce 59 - NAMESPACE reduce 59 - NEW reduce 59 - OBJECT reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - SBYTE reduce 59 - SEALED reduce 59 - SHORT reduce 59 - STATIC reduce 59 - STRING reduce 59 - STRUCT reduce 59 - UINT reduce 59 - ULONG reduce 59 - UNSAFE reduce 59 - USHORT reduce 59 - VIRTUAL reduce 59 - VOID reduce 59 - VOLATILE reduce 59 - PARTIAL reduce 59 - IDENTIFIER reduce 59 - - global_attributes goto 455 - outer_declaration goto 58 - extern_alias_directive goto 14 - using_directive goto 15 - namespace_member_declaration goto 16 - using_alias_directive goto 17 - using_namespace_directive goto 18 - namespace_declaration goto 19 - opt_attributes goto 20 - type_declaration goto 21 - field_declaration goto 22 - method_declaration goto 23 - class_declaration goto 24 - struct_declaration goto 25 - interface_declaration goto 26 - enum_declaration goto 27 - delegate_declaration goto 28 - attribute_sections goto 29 - attribute_section goto 30 - method_header goto 31 - - -state 242 - interactive_compilation_unit : global_attributes . (916) - - . reduce 916 - - -state 243 - interactive_parsing : EVAL_COMPILATION_UNIT_PARSER $$104 interactive_compilation_unit . (913) - - . reduce 913 - - -state 244 - using_directives : using_directives using_directive . (19) - - . reduce 19 - - -state 245 - compilation_unit : outer_declarations global_attributes opt_EOF . (2) - - . reduce 2 - - -state 246 - compilation_unit : interactive_parsing $$1 opt_EOF . (6) - - . reduce 6 - - -state 247 - qualified_identifier : error . (29) - - . reduce 29 - - -state 248 - qualified_identifier : IDENTIFIER . (27) - - . reduce 27 - - -state 249 - namespace_declaration : opt_attributes NAMESPACE qualified_identifier . $$2 namespace_body opt_semicolon (26) - qualified_identifier : qualified_identifier . DOT IDENTIFIER (28) - $$2 : . (25) - - DOT shift 456 - OPEN_BRACE reduce 25 - - $$2 goto 457 - - -state 250 - delegate_declaration : opt_attributes opt_modifiers DELEGATE . member_type type_declaration_name OPEN_PARENS $$58 opt_formal_parameter_list CLOSE_PARENS $$59 opt_type_parameter_constraints_clauses $$60 SEMICOLON (355) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 253 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - member_type goto 458 - type_expression_or_array goto 258 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_and_void goto 259 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 251 - enum_declaration : opt_attributes opt_modifiers ENUM . type_declaration_name opt_enum_base $$54 OPEN_BRACE $$55 opt_enum_member_declarations $$56 CLOSE_BRACE opt_semicolon (340) - - IDENTIFIER shift 459 - . error - - type_declaration_name goto 460 - - -state 252 - field_declaration : opt_attributes opt_modifiers FIXED . simple_type IDENTIFIER $$15 fixed_field_size opt_fixed_field_declarators SEMICOLON (142) - field_declaration : opt_attributes opt_modifiers FIXED . simple_type error SEMICOLON (143) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 461 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - simple_type goto 462 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 463 - builtin_types goto 261 - integral_type goto 162 - - -state 253 - type_and_void : VOID . (385) - type_expression : VOID . STAR (398) - - STAR shift 464 - ABSTRACT reduce 385 - EXTERN reduce 385 - INTERNAL reduce 385 - NEW reduce 385 - OVERRIDE reduce 385 - PRIVATE reduce 385 - PROTECTED reduce 385 - PUBLIC reduce 385 - READONLY reduce 385 - SEALED reduce 385 - STATIC reduce 385 - UNSAFE reduce 385 - VIRTUAL reduce 385 - VOLATILE reduce 385 - CLOSE_PARENS reduce 385 - IDENTIFIER reduce 385 - - -state 254 - method_header : opt_attributes opt_modifiers PARTIAL . VOID method_declaration_name OPEN_PARENS $$22 opt_formal_parameter_list CLOSE_PARENS $$23 opt_type_parameter_constraints_clauses (182) - opt_partial : PARTIAL . (654) - - VOID shift 465 - CLASS reduce 654 - INTERFACE reduce 654 - STRUCT reduce 654 - - -state 255 - member_name : namespace_or_type_name . DOT IDENTIFIER opt_type_argument_list (361) - type_expression : namespace_or_type_name . opt_nullable (395) - opt_nullable : . (356) - - INTERR_NULLABLE shift 379 - DOT shift 85 - error reduce 356 - ABSTRACT reduce 356 - AS reduce 356 - EXTERN reduce 356 - IN reduce 356 - INTERNAL reduce 356 - IS reduce 356 - NEW reduce 356 - OPERATOR reduce 356 - OVERRIDE reduce 356 - PRIVATE reduce 356 - PROTECTED reduce 356 - PUBLIC reduce 356 - READONLY reduce 356 - SEALED reduce 356 - STATIC reduce 356 - THIS reduce 356 - UNSAFE reduce 356 - VIRTUAL reduce 356 - VOLATILE reduce 356 - WHERE reduce 356 - FROM reduce 356 - JOIN reduce 356 - ON reduce 356 - EQUALS reduce 356 - SELECT reduce 356 - GROUP reduce 356 - BY reduce 356 - LET reduce 356 - ORDERBY reduce 356 - ASCENDING reduce 356 - DESCENDING reduce 356 - INTO reduce 356 - OP_GENERICS_GT reduce 356 - OPEN_BRACE reduce 356 - CLOSE_BRACE reduce 356 - OPEN_BRACKET reduce 356 - CLOSE_BRACKET reduce 356 - OPEN_PARENS reduce 356 - CLOSE_PARENS reduce 356 - COMMA reduce 356 - COLON reduce 356 - SEMICOLON reduce 356 - PLUS reduce 356 - MINUS reduce 356 - OP_LT reduce 356 - OP_GT reduce 356 - BITWISE_AND reduce 356 - BITWISE_OR reduce 356 - STAR reduce 356 - CARRET reduce 356 - INTERR reduce 356 - OP_SHIFT_LEFT reduce 356 - OP_SHIFT_RIGHT reduce 356 - OP_LE reduce 356 - OP_GE reduce 356 - OP_EQ reduce 356 - OP_NE reduce 356 - OP_AND reduce 356 - OP_OR reduce 356 - OP_COALESCING reduce 356 - IDENTIFIER reduce 356 - OPEN_PARENS_CAST reduce 356 - OPEN_BRACKET_EXPR reduce 356 - COMPLETE_COMPLETION reduce 356 - - opt_nullable goto 466 - - -state 256 - struct_declaration : opt_attributes opt_modifiers opt_partial . STRUCT $$7 type_declaration_name $$8 opt_class_base opt_type_parameter_constraints_clauses $$9 struct_body $$10 opt_semicolon (109) - struct_declaration : opt_attributes opt_modifiers opt_partial . STRUCT error (110) - interface_declaration : opt_attributes opt_modifiers opt_partial . INTERFACE $$33 type_declaration_name $$34 opt_class_base opt_type_parameter_constraints_clauses $$35 OPEN_BRACE opt_interface_member_declarations CLOSE_BRACE $$36 opt_semicolon (242) - interface_declaration : opt_attributes opt_modifiers opt_partial . INTERFACE error (243) - class_declaration : opt_attributes opt_modifiers opt_partial . CLASS $$70 type_declaration_name $$71 opt_class_base opt_type_parameter_constraints_clauses $$72 OPEN_BRACE opt_class_member_declarations CLOSE_BRACE $$73 opt_semicolon (652) - - CLASS shift 467 - INTERFACE shift 468 - STRUCT shift 469 - . error - - -state 257 - field_declaration : opt_attributes opt_modifiers member_type . IDENTIFIER $$14 opt_field_initializer opt_field_declarators SEMICOLON (140) - method_header : opt_attributes opt_modifiers member_type . method_declaration_name OPEN_PARENS $$20 opt_formal_parameter_list CLOSE_PARENS $$21 opt_type_parameter_constraints_clauses (179) - method_header : opt_attributes opt_modifiers member_type . modifiers method_declaration_name OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS (183) - - ABSTRACT shift 61 - EXTERN shift 62 - INTERNAL shift 63 - NEW shift 65 - OVERRIDE shift 66 - PRIVATE shift 67 - PROTECTED shift 68 - PUBLIC shift 69 - READONLY shift 70 - SEALED shift 71 - STATIC shift 72 - UNSAFE shift 73 - VIRTUAL shift 74 - VOLATILE shift 75 - IDENTIFIER shift 470 - . error - - type_declaration_name goto 471 - method_declaration_name goto 472 - modifiers goto 473 - qualified_alias_member goto 474 - explicit_interface goto 475 - modifier goto 78 - - -state 258 - type_and_void : type_expression_or_array . (384) - - . reduce 384 - - -state 259 - member_type : type_and_void . (386) - - . reduce 386 - - -state 260 - type_expression_or_array : type_expression . (393) - type_expression_or_array : type_expression . rank_specifiers (394) - type_expression : type_expression . STAR (397) - - OPEN_BRACKET shift 332 - STAR shift 476 - error reduce 393 - ABSTRACT reduce 393 - AS reduce 393 - EXTERN reduce 393 - IN reduce 393 - INTERNAL reduce 393 - IS reduce 393 - NEW reduce 393 - OPERATOR reduce 393 - OVERRIDE reduce 393 - PRIVATE reduce 393 - PROTECTED reduce 393 - PUBLIC reduce 393 - READONLY reduce 393 - SEALED reduce 393 - STATIC reduce 393 - THIS reduce 393 - UNSAFE reduce 393 - VIRTUAL reduce 393 - VOLATILE reduce 393 - WHERE reduce 393 - FROM reduce 393 - JOIN reduce 393 - ON reduce 393 - EQUALS reduce 393 - SELECT reduce 393 - GROUP reduce 393 - BY reduce 393 - LET reduce 393 - ORDERBY reduce 393 - ASCENDING reduce 393 - DESCENDING reduce 393 - INTO reduce 393 - OP_GENERICS_GT reduce 393 - OPEN_BRACE reduce 393 - CLOSE_BRACE reduce 393 - CLOSE_BRACKET reduce 393 - OPEN_PARENS reduce 393 - CLOSE_PARENS reduce 393 - COMMA reduce 393 - COLON reduce 393 - SEMICOLON reduce 393 - PLUS reduce 393 - MINUS reduce 393 - OP_LT reduce 393 - OP_GT reduce 393 - BITWISE_AND reduce 393 - BITWISE_OR reduce 393 - CARRET reduce 393 - INTERR reduce 393 - OP_SHIFT_LEFT reduce 393 - OP_SHIFT_RIGHT reduce 393 - OP_LE reduce 393 - OP_GE reduce 393 - OP_EQ reduce 393 - OP_NE reduce 393 - OP_AND reduce 393 - OP_OR reduce 393 - OP_COALESCING reduce 393 - IDENTIFIER reduce 393 - COMPLETE_COMPLETION reduce 393 - - rank_specifiers goto 477 - rank_specifier goto 336 - - -state 261 - type_expression : builtin_types . opt_nullable (396) - opt_nullable : . (356) - - INTERR_NULLABLE shift 379 - error reduce 356 - ABSTRACT reduce 356 - AS reduce 356 - EXTERN reduce 356 - IN reduce 356 - INTERNAL reduce 356 - IS reduce 356 - NEW reduce 356 - OPERATOR reduce 356 - OVERRIDE reduce 356 - PRIVATE reduce 356 - PROTECTED reduce 356 - PUBLIC reduce 356 - READONLY reduce 356 - SEALED reduce 356 - STATIC reduce 356 - THIS reduce 356 - UNSAFE reduce 356 - VIRTUAL reduce 356 - VOLATILE reduce 356 - WHERE reduce 356 - FROM reduce 356 - JOIN reduce 356 - ON reduce 356 - EQUALS reduce 356 - SELECT reduce 356 - GROUP reduce 356 - BY reduce 356 - LET reduce 356 - ORDERBY reduce 356 - ASCENDING reduce 356 - DESCENDING reduce 356 - INTO reduce 356 - OP_GENERICS_GT reduce 356 - OPEN_BRACE reduce 356 - CLOSE_BRACE reduce 356 - OPEN_BRACKET reduce 356 - CLOSE_BRACKET reduce 356 - OPEN_PARENS reduce 356 - CLOSE_PARENS reduce 356 - COMMA reduce 356 - COLON reduce 356 - SEMICOLON reduce 356 - PLUS reduce 356 - MINUS reduce 356 - OP_LT reduce 356 - OP_GT reduce 356 - BITWISE_AND reduce 356 - BITWISE_OR reduce 356 - STAR reduce 356 - CARRET reduce 356 - INTERR reduce 356 - OP_SHIFT_LEFT reduce 356 - OP_SHIFT_RIGHT reduce 356 - OP_LE reduce 356 - OP_GE reduce 356 - OP_EQ reduce 356 - OP_NE reduce 356 - OP_AND reduce 356 - OP_OR reduce 356 - OP_COALESCING reduce 356 - IDENTIFIER reduce 356 - OPEN_PARENS_CAST reduce 356 - OPEN_BRACKET_EXPR reduce 356 - COMPLETE_COMPLETION reduce 356 - - opt_nullable goto 478 - - -state 262 - modifiers : modifiers modifier . (658) - - . reduce 658 - - -state 263 - method_body : SEMICOLON . (185) - - . reduce 185 - - -state 264 - method_declaration : method_header $$19 method_body . (176) - - . reduce 176 - - -state 265 - method_body : block . (184) - - . reduce 184 - - -state 266 - opt_type_argument_list : OP_GENERICS_LT error . (365) - - . reduce 365 - - -state 267 - type : VOID . (388) - type_expression : VOID . STAR (398) - - STAR shift 464 - error reduce 388 - AS reduce 388 - IN reduce 388 - IS reduce 388 - WHERE reduce 388 - FROM reduce 388 - JOIN reduce 388 - ON reduce 388 - EQUALS reduce 388 - SELECT reduce 388 - GROUP reduce 388 - BY reduce 388 - LET reduce 388 - ORDERBY reduce 388 - ASCENDING reduce 388 - DESCENDING reduce 388 - INTO reduce 388 - OP_GENERICS_GT reduce 388 - OPEN_BRACE reduce 388 - CLOSE_BRACE reduce 388 - CLOSE_BRACKET reduce 388 - OPEN_PARENS reduce 388 - CLOSE_PARENS reduce 388 - COMMA reduce 388 - COLON reduce 388 - SEMICOLON reduce 388 - PLUS reduce 388 - MINUS reduce 388 - OP_LT reduce 388 - OP_GT reduce 388 - BITWISE_AND reduce 388 - BITWISE_OR reduce 388 - CARRET reduce 388 - INTERR reduce 388 - OP_SHIFT_LEFT reduce 388 - OP_SHIFT_RIGHT reduce 388 - OP_LE reduce 388 - OP_GE reduce 388 - OP_EQ reduce 388 - OP_NE reduce 388 - OP_AND reduce 388 - OP_OR reduce 388 - OP_COALESCING reduce 388 - IDENTIFIER reduce 388 - COMPLETE_COMPLETION reduce 388 - - -state 268 - type_arguments : type . (366) - - . reduce 366 - - -state 269 - type : type_expression_or_array . (387) - - . reduce 387 - - -state 270 - opt_type_argument_list : OP_GENERICS_LT type_arguments . OP_GENERICS_GT (364) - type_arguments : type_arguments . COMMA type (367) - - OP_GENERICS_GT shift 479 - COMMA shift 480 - . error - - -state 271 - using_alias_directive : USING IDENTIFIER ASSIGN namespace_or_type_name . SEMICOLON (22) - member_name : namespace_or_type_name . DOT IDENTIFIER opt_type_argument_list (361) - - DOT shift 85 - SEMICOLON shift 481 - . error - - -state 272 - member_name : namespace_or_type_name DOT IDENTIFIER . opt_type_argument_list (361) - opt_type_argument_list : . (363) - - OP_GENERICS_LT shift 81 - error reduce 363 - ABSTRACT reduce 363 - AS reduce 363 - EXTERN reduce 363 - IN reduce 363 - INTERNAL reduce 363 - IS reduce 363 - NEW reduce 363 - OPERATOR reduce 363 - OVERRIDE reduce 363 - PRIVATE reduce 363 - PROTECTED reduce 363 - PUBLIC reduce 363 - READONLY reduce 363 - SEALED reduce 363 - STATIC reduce 363 - THIS reduce 363 - UNSAFE reduce 363 - VIRTUAL reduce 363 - VOLATILE reduce 363 - WHERE reduce 363 - FROM reduce 363 - JOIN reduce 363 - ON reduce 363 - EQUALS reduce 363 - SELECT reduce 363 - GROUP reduce 363 - BY reduce 363 - LET reduce 363 - ORDERBY reduce 363 - ASCENDING reduce 363 - DESCENDING reduce 363 - INTO reduce 363 - INTERR_NULLABLE reduce 363 - OP_GENERICS_GT reduce 363 - OPEN_BRACE reduce 363 - CLOSE_BRACE reduce 363 - OPEN_BRACKET reduce 363 - CLOSE_BRACKET reduce 363 - OPEN_PARENS reduce 363 - CLOSE_PARENS reduce 363 - DOT reduce 363 - COMMA reduce 363 - COLON reduce 363 - SEMICOLON reduce 363 - PLUS reduce 363 - MINUS reduce 363 - OP_LT reduce 363 - OP_GT reduce 363 - BITWISE_AND reduce 363 - BITWISE_OR reduce 363 - STAR reduce 363 - CARRET reduce 363 - INTERR reduce 363 - OP_SHIFT_LEFT reduce 363 - OP_SHIFT_RIGHT reduce 363 - OP_LE reduce 363 - OP_GE reduce 363 - OP_EQ reduce 363 - OP_NE reduce 363 - OP_AND reduce 363 - OP_OR reduce 363 - OP_COALESCING reduce 363 - IDENTIFIER reduce 363 - OPEN_PARENS_CAST reduce 363 - OPEN_BRACKET_EXPR reduce 363 - COMPLETE_COMPLETION reduce 363 - - opt_type_argument_list goto 482 - - -state 273 - namespace_or_type_name : qualified_alias_member IDENTIFIER opt_type_argument_list . (359) - - . reduce 359 - - -state 274 - extern_alias_directive : EXTERN_ALIAS IDENTIFIER IDENTIFIER SEMICOLON . (16) - - . reduce 16 - - -state 275 - attribute_section : OPEN_BRACKET attribute_target_specifier attribute_list opt_comma . CLOSE_BRACKET (63) - - CLOSE_BRACKET shift 483 - . error - - -state 276 - attribute_list : attribute_list COMMA attribute . (71) - - . reduce 71 - - -state 277 - attribute_section : OPEN_BRACKET attribute_list opt_comma CLOSE_BRACKET . (64) - - . reduce 64 - - -state 278 - opt_attribute_arguments : OPEN_PARENS . attribute_arguments CLOSE_PARENS (76) - attribute_arguments : . (77) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 484 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - CLOSE_PARENS reduce 77 - COMMA reduce 77 - - attribute_arguments goto 485 - positional_or_named_argument goto 486 - named_attribute_argument goto 487 - expression goto 488 - named_argument goto 489 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 279 - attribute : attribute_name $$5 opt_attribute_arguments . (73) - - . reduce 73 - - -state 280 - base_access : BASE OPEN_BRACKET . error (504) - - error shift 490 - . error - - -state 281 - member_access : BASE DOT . IDENTIFIER opt_type_argument_list (454) - - IDENTIFIER shift 491 - . error - - -state 282 - base_access : BASE OPEN_BRACKET_EXPR . expression_list_arguments CLOSE_BRACKET (503) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 492 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 493 - named_argument goto 494 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - expression_list_arguments goto 495 - expression_list_argument goto 496 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 283 - break_statement : BREAK SEMICOLON . (809) - - . reduce 809 - - -state 284 - open_parens_any : OPEN_PARENS . (446) - - . reduce 446 - - -state 285 - open_parens_any : OPEN_PARENS_CAST . (447) - - . reduce 447 - - -state 286 - checked_statement : CHECKED block . (834) - - . reduce 834 - - -state 287 - checked_expression : CHECKED open_parens_any . expression CLOSE_PARENS (557) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 497 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 288 - checked_expression : CHECKED . open_parens_any expression CLOSE_PARENS (557) - - OPEN_PARENS shift 284 - OPEN_PARENS_CAST shift 285 - . error - - open_parens_any goto 287 - - -state 289 - unchecked_expression : UNCHECKED . open_parens_any expression CLOSE_PARENS (558) - - OPEN_PARENS shift 284 - OPEN_PARENS_CAST shift 285 - . error - - open_parens_any goto 348 - - -state 290 - variable_type : VOID . opt_rank_specifier (744) - opt_rank_specifier : . (527) - - OPEN_BRACKET shift 332 - IDENTIFIER reduce 527 - - rank_specifiers goto 352 - opt_rank_specifier goto 353 - rank_specifier goto 336 - - -state 291 - parenthesized_expression : OPEN_PARENS . expression CLOSE_PARENS (450) - parenthesized_expression : OPEN_PARENS . expression COMPLETE_COMPLETION (451) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 360 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 292 - primary_expression_no_array_creation : IDENTIFIER . opt_type_argument_list (422) - primary_expression_no_array_creation : IDENTIFIER . GENERATE_COMPLETION (423) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - opt_type_argument_list : . (363) - - OP_GENERICS_LT shift 81 - DOUBLE_COLON shift 83 - GENERATE_COMPLETION shift 374 - error reduce 363 - AS reduce 363 - IS reduce 363 - WHERE reduce 363 - FROM reduce 363 - JOIN reduce 363 - ON reduce 363 - EQUALS reduce 363 - SELECT reduce 363 - GROUP reduce 363 - BY reduce 363 - LET reduce 363 - ORDERBY reduce 363 - ASCENDING reduce 363 - DESCENDING reduce 363 - INTO reduce 363 - INTERR_NULLABLE reduce 363 - CLOSE_BRACE reduce 363 - OPEN_BRACKET reduce 363 - CLOSE_BRACKET reduce 363 - OPEN_PARENS reduce 363 - CLOSE_PARENS reduce 363 - DOT reduce 363 - COMMA reduce 363 - COLON reduce 363 - SEMICOLON reduce 363 - PLUS reduce 363 - MINUS reduce 363 - ASSIGN reduce 363 - OP_LT reduce 363 - OP_GT reduce 363 - BITWISE_AND reduce 363 - BITWISE_OR reduce 363 - STAR reduce 363 - PERCENT reduce 363 - DIV reduce 363 - CARRET reduce 363 - INTERR reduce 363 - OP_INC reduce 363 - OP_DEC reduce 363 - OP_SHIFT_LEFT reduce 363 - OP_SHIFT_RIGHT reduce 363 - OP_LE reduce 363 - OP_GE reduce 363 - OP_EQ reduce 363 - OP_NE reduce 363 - OP_AND reduce 363 - OP_OR reduce 363 - OP_MULT_ASSIGN reduce 363 - OP_DIV_ASSIGN reduce 363 - OP_MOD_ASSIGN reduce 363 - OP_ADD_ASSIGN reduce 363 - OP_SUB_ASSIGN reduce 363 - OP_SHIFT_LEFT_ASSIGN reduce 363 - OP_SHIFT_RIGHT_ASSIGN reduce 363 - OP_AND_ASSIGN reduce 363 - OP_XOR_ASSIGN reduce 363 - OP_OR_ASSIGN reduce 363 - OP_PTR reduce 363 - OP_COALESCING reduce 363 - IDENTIFIER reduce 363 - OPEN_PARENS_CAST reduce 363 - OPEN_BRACKET_EXPR reduce 363 - COMPLETE_COMPLETION reduce 363 - - opt_type_argument_list goto 375 - - -state 293 - member_access : builtin_types . DOT IDENTIFIER opt_type_argument_list (453) - member_access : builtin_types . DOT GENERATE_COMPLETION (458) - member_access : builtin_types . DOT IDENTIFIER GENERATE_COMPLETION (459) - variable_type : builtin_types . opt_rank_specifier_or_nullable (743) - opt_nullable : . (356) - - INTERR_NULLABLE shift 379 - DOT shift 380 - OPEN_BRACKET reduce 356 - IDENTIFIER reduce 356 - - opt_nullable goto 382 - opt_rank_specifier_or_nullable goto 383 - - -state 294 - member_access : primary_expression . DOT IDENTIFIER opt_type_argument_list (452) - member_access : primary_expression . DOT GENERATE_COMPLETION (456) - member_access : primary_expression . DOT IDENTIFIER GENERATE_COMPLETION (457) - invocation_expression : primary_expression . open_parens_any opt_argument_list close_parens (460) - element_access : primary_expression . OPEN_BRACKET_EXPR expression_list_arguments CLOSE_BRACKET (494) - post_increment_expression : primary_expression . OP_INC (505) - post_decrement_expression : primary_expression . OP_DEC (506) - pointer_member_access : primary_expression . OP_PTR IDENTIFIER (559) - - OPEN_PARENS shift 284 - DOT shift 384 - OP_INC shift 385 - OP_DEC shift 386 - OP_PTR shift 387 - OPEN_PARENS_CAST shift 285 - OPEN_BRACKET_EXPR shift 388 - . error - - open_parens_any goto 389 - - -state 295 - primary_expression : primary_expression_no_array_creation . (419) - variable_type : primary_expression_no_array_creation . opt_rank_specifier_or_nullable (742) - opt_nullable : . (356) - - INTERR_NULLABLE shift 379 - OPEN_BRACKET reduce 356 - OPEN_PARENS reduce 419 - DOT reduce 419 - OP_INC reduce 419 - OP_DEC reduce 419 - OP_PTR reduce 419 - IDENTIFIER reduce 356 - OPEN_PARENS_CAST reduce 419 - OPEN_BRACKET_EXPR reduce 419 - - opt_nullable goto 382 - opt_rank_specifier_or_nullable goto 391 - - -state 296 - primary_expression_no_array_creation : parenthesized_expression . (424) - - . reduce 424 - - -state 297 - local_constant_declaration : CONST variable_type . local_constant_declarators (752) - - IDENTIFIER shift 498 - . error - - local_constant_declarators goto 499 - local_constant_declarator goto 500 - - -state 298 - continue_statement : CONTINUE SEMICOLON . (810) - - . reduce 810 - - -state 299 - default_value_expression : DEFAULT open_parens_any . type CLOSE_PARENS (566) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 501 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 300 - anonymous_method_signature : OPEN_PARENS . $$65 opt_formal_parameter_list CLOSE_PARENS (565) - $$65 : . (564) - - . reduce 564 - - $$65 goto 502 - - -state 301 - anonymous_method_expression : DELEGATE opt_anonymous_method_signature . $$64 block (561) - $$64 : . (560) - - . reduce 560 - - $$64 goto 503 - - -state 302 - opt_anonymous_method_signature : anonymous_method_signature . (563) - - . reduce 563 - - -state 303 - statement_expression : error . (762) - - . reduce 762 - - -state 304 - statement_expression : expression . (761) - - . reduce 761 - - -state 305 - valid_declaration_statement : block . (708) - - . reduce 708 - - -state 306 - embedded_statement : declaration_statement . (735) - - . reduce 735 - - -state 307 - embedded_statement : valid_declaration_statement . (734) - - . reduce 734 - - -state 308 - embedded_statement : labeled_statement . (736) - - . reduce 736 - - -state 309 - valid_declaration_statement : empty_statement . (709) - - . reduce 709 - - -state 310 - valid_declaration_statement : expression_statement . (710) - - . reduce 710 - - -state 311 - valid_declaration_statement : selection_statement . (711) - - . reduce 711 - - -state 312 - valid_declaration_statement : iteration_statement . (712) - - . reduce 712 - - -state 313 - valid_declaration_statement : jump_statement . (713) - - . reduce 713 - - -state 314 - valid_declaration_statement : try_statement . (714) - - . reduce 714 - - -state 315 - valid_declaration_statement : checked_statement . (715) - - . reduce 715 - - -state 316 - valid_declaration_statement : unchecked_statement . (716) - - . reduce 716 - - -state 317 - valid_declaration_statement : lock_statement . (717) - - . reduce 717 - - -state 318 - valid_declaration_statement : using_statement . (718) - - . reduce 718 - - -state 319 - valid_declaration_statement : unsafe_statement . (719) - - . reduce 719 - - -state 320 - valid_declaration_statement : fixed_statement . (720) - - . reduce 720 - - -state 321 - do_statement : DO embedded_statement . WHILE open_parens_any boolean_expression CLOSE_PARENS SEMICOLON (786) - - WHILE shift 504 - . error - - -state 322 - expression_statement : statement_expression . SEMICOLON (757) - expression_statement : statement_expression . COMPLETE_COMPLETION (758) - - SEMICOLON shift 505 - COMPLETE_COMPLETION shift 506 - . error - - -state 323 - fixed_statement : FIXED open_parens_any . type_and_void fixed_pointer_declarators CLOSE_PARENS $$83 embedded_statement (839) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 253 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type_expression_or_array goto 258 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_and_void goto 507 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 324 - for_statement : FOR open_parens_any . opt_for_initializer SEMICOLON $$79 opt_for_condition SEMICOLON opt_for_iterator CLOSE_PARENS embedded_statement (788) - opt_for_initializer : . (789) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - VOID shift 139 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - SEMICOLON reduce 789 - - expression goto 304 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - local_variable_declaration goto 508 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - statement_expression goto 509 - opt_for_initializer goto 510 - for_initializer goto 511 - statement_expression_list goto 512 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 325 - foreach_statement : FOREACH open_parens_any . type IN expression CLOSE_PARENS (800) - foreach_statement : FOREACH open_parens_any . type IDENTIFIER IN expression CLOSE_PARENS $$80 embedded_statement (802) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 513 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 326 - goto_statement : GOTO CASE . constant_expression SEMICOLON (812) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 514 - constant_expression goto 515 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 327 - goto_statement : GOTO DEFAULT . SEMICOLON (813) - - SEMICOLON shift 516 - . error - - -state 328 - goto_statement : GOTO IDENTIFIER . SEMICOLON (811) - - SEMICOLON shift 517 - . error - - -state 329 - if_statement : IF open_parens_any . boolean_expression CLOSE_PARENS embedded_statement (767) - if_statement : IF open_parens_any . boolean_expression CLOSE_PARENS embedded_statement ELSE embedded_statement (768) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 518 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - boolean_expression goto 519 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 330 - lock_statement : LOCK open_parens_any . expression CLOSE_PARENS embedded_statement (844) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 520 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 331 - anonymous_type_expression : NEW OPEN_BRACE . anonymous_type_parameters_opt_comma CLOSE_BRACE (516) - anonymous_type_parameters_opt : . (519) - - error shift 521 - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 291 - LITERAL shift 154 - IDENTIFIER shift 522 - CLOSE_BRACE reduce 519 - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 294 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 523 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - anonymous_type_parameters_opt_comma goto 524 - anonymous_type_parameters_opt goto 525 - anonymous_type_parameters goto 526 - anonymous_type_parameter goto 527 - - -state 332 - rank_specifier : OPEN_BRACKET . CLOSE_BRACKET (533) - rank_specifier : OPEN_BRACKET . dim_separators CLOSE_BRACKET (534) - - CLOSE_BRACKET shift 528 - COMMA shift 529 - . error - - dim_separators goto 530 - - -state 333 - array_creation_expression : NEW rank_specifiers . array_initializer (511) - - OPEN_BRACE shift 531 - . error - - array_initializer goto 532 - - -state 334 - object_or_delegate_creation_expression : NEW new_expr_type . open_parens_any opt_argument_list CLOSE_PARENS opt_object_or_collection_initializer (507) - object_or_delegate_creation_expression : NEW new_expr_type . object_or_collection_initializer (508) - array_creation_expression : NEW new_expr_type . OPEN_BRACKET_EXPR expression_list CLOSE_BRACKET opt_rank_specifier opt_array_initializer (509) - array_creation_expression : NEW new_expr_type . rank_specifiers opt_array_initializer (510) - array_creation_expression : NEW new_expr_type . OPEN_BRACKET CLOSE_BRACKET OPEN_BRACKET_EXPR error CLOSE_BRACKET (512) - array_creation_expression : NEW new_expr_type . error (513) - - error shift 533 - OPEN_BRACE shift 534 - OPEN_BRACKET shift 535 - OPEN_PARENS shift 284 - OPEN_PARENS_CAST shift 285 - OPEN_BRACKET_EXPR shift 536 - . error - - rank_specifiers goto 537 - open_parens_any goto 538 - object_or_collection_initializer goto 539 - rank_specifier goto 336 - - -state 335 - new_expr_type : $$62 . simple_type (515) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 461 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - simple_type goto 540 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 463 - builtin_types goto 261 - integral_type goto 162 - - -state 336 - rank_specifiers : rank_specifier . (531) - rank_specifiers : rank_specifier . rank_specifiers (532) - - OPEN_BRACKET shift 332 - error reduce 531 - ABSTRACT reduce 531 - AS reduce 531 - EXTERN reduce 531 - IN reduce 531 - INTERNAL reduce 531 - IS reduce 531 - NEW reduce 531 - OPERATOR reduce 531 - OVERRIDE reduce 531 - PRIVATE reduce 531 - PROTECTED reduce 531 - PUBLIC reduce 531 - READONLY reduce 531 - SEALED reduce 531 - STATIC reduce 531 - THIS reduce 531 - UNSAFE reduce 531 - VIRTUAL reduce 531 - VOLATILE reduce 531 - WHERE reduce 531 - FROM reduce 531 - JOIN reduce 531 - ON reduce 531 - EQUALS reduce 531 - SELECT reduce 531 - GROUP reduce 531 - BY reduce 531 - LET reduce 531 - ORDERBY reduce 531 - ASCENDING reduce 531 - DESCENDING reduce 531 - INTO reduce 531 - OP_GENERICS_GT reduce 531 - OPEN_BRACE reduce 531 - CLOSE_BRACE reduce 531 - CLOSE_BRACKET reduce 531 - OPEN_PARENS reduce 531 - CLOSE_PARENS reduce 531 - DOT reduce 531 - COMMA reduce 531 - COLON reduce 531 - SEMICOLON reduce 531 - PLUS reduce 531 - MINUS reduce 531 - ASSIGN reduce 531 - OP_LT reduce 531 - OP_GT reduce 531 - BITWISE_AND reduce 531 - BITWISE_OR reduce 531 - STAR reduce 531 - PERCENT reduce 531 - DIV reduce 531 - CARRET reduce 531 - INTERR reduce 531 - OP_INC reduce 531 - OP_DEC reduce 531 - OP_SHIFT_LEFT reduce 531 - OP_SHIFT_RIGHT reduce 531 - OP_LE reduce 531 - OP_GE reduce 531 - OP_EQ reduce 531 - OP_NE reduce 531 - OP_AND reduce 531 - OP_OR reduce 531 - OP_MULT_ASSIGN reduce 531 - OP_DIV_ASSIGN reduce 531 - OP_MOD_ASSIGN reduce 531 - OP_ADD_ASSIGN reduce 531 - OP_SUB_ASSIGN reduce 531 - OP_SHIFT_LEFT_ASSIGN reduce 531 - OP_SHIFT_RIGHT_ASSIGN reduce 531 - OP_AND_ASSIGN reduce 531 - OP_XOR_ASSIGN reduce 531 - OP_OR_ASSIGN reduce 531 - OP_PTR reduce 531 - OP_COALESCING reduce 531 - IDENTIFIER reduce 531 - OPEN_PARENS_CAST reduce 531 - OPEN_BRACKET_EXPR reduce 531 - COMPLETE_COMPLETION reduce 531 - - rank_specifiers goto 541 - rank_specifier goto 336 - - -state 337 - primary_expression_no_array_creation : IDENTIFIER . opt_type_argument_list (422) - primary_expression_no_array_creation : IDENTIFIER . GENERATE_COMPLETION (423) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - lambda_expression : IDENTIFIER . ARROW $$67 lambda_expression_body (637) - opt_type_argument_list : . (363) - - ARROW shift 372 - OP_GENERICS_LT shift 81 - DOUBLE_COLON shift 83 - GENERATE_COMPLETION shift 374 - error reduce 363 - AS reduce 363 - IS reduce 363 - WHERE reduce 363 - FROM reduce 363 - JOIN reduce 363 - ON reduce 363 - EQUALS reduce 363 - SELECT reduce 363 - GROUP reduce 363 - BY reduce 363 - LET reduce 363 - ORDERBY reduce 363 - ASCENDING reduce 363 - DESCENDING reduce 363 - INTO reduce 363 - INTERR_NULLABLE reduce 363 - CLOSE_BRACE reduce 363 - OPEN_BRACKET reduce 363 - CLOSE_BRACKET reduce 363 - OPEN_PARENS reduce 363 - CLOSE_PARENS reduce 363 - DOT reduce 363 - COMMA reduce 363 - COLON reduce 363 - SEMICOLON reduce 363 - PLUS reduce 363 - MINUS reduce 363 - ASSIGN reduce 363 - OP_LT reduce 363 - OP_GT reduce 363 - BITWISE_AND reduce 363 - BITWISE_OR reduce 363 - STAR reduce 363 - PERCENT reduce 363 - DIV reduce 363 - CARRET reduce 363 - INTERR reduce 363 - OP_INC reduce 363 - OP_DEC reduce 363 - OP_SHIFT_LEFT reduce 363 - OP_SHIFT_RIGHT reduce 363 - OP_LE reduce 363 - OP_GE reduce 363 - OP_EQ reduce 363 - OP_NE reduce 363 - OP_AND reduce 363 - OP_OR reduce 363 - OP_MULT_ASSIGN reduce 363 - OP_DIV_ASSIGN reduce 363 - OP_MOD_ASSIGN reduce 363 - OP_ADD_ASSIGN reduce 363 - OP_SUB_ASSIGN reduce 363 - OP_SHIFT_LEFT_ASSIGN reduce 363 - OP_SHIFT_RIGHT_ASSIGN reduce 363 - OP_AND_ASSIGN reduce 363 - OP_XOR_ASSIGN reduce 363 - OP_OR_ASSIGN reduce 363 - OP_PTR reduce 363 - OP_COALESCING reduce 363 - IDENTIFIER reduce 363 - OPEN_PARENS_CAST reduce 363 - OPEN_BRACKET_EXPR reduce 363 - COMPLETE_COMPLETION reduce 363 - - opt_type_argument_list goto 375 - - -state 338 - opt_expression : expression . (819) - - . reduce 819 - - -state 339 - return_statement : RETURN opt_expression . SEMICOLON (814) - - SEMICOLON shift 542 - . error - - -state 340 - member_access : builtin_types . DOT IDENTIFIER opt_type_argument_list (453) - member_access : builtin_types . DOT GENERATE_COMPLETION (458) - member_access : builtin_types . DOT IDENTIFIER GENERATE_COMPLETION (459) - - DOT shift 380 - . error - - -state 341 - primary_expression : primary_expression_no_array_creation . (419) - - . reduce 419 - - -state 342 - sizeof_expression : SIZEOF open_parens_any . type CLOSE_PARENS (556) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 543 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 343 - switch_statement : SWITCH open_parens_any . $$77 expression CLOSE_PARENS OPEN_BRACE opt_switch_sections CLOSE_BRACE (770) - $$77 : . (769) - - . reduce 769 - - $$77 goto 544 - - -state 344 - throw_statement : THROW opt_expression . SEMICOLON (815) - - SEMICOLON shift 545 - . error - - -state 345 - try_statement : TRY block . catch_clauses (820) - try_statement : TRY block . FINALLY block (821) - try_statement : TRY block . catch_clauses FINALLY block (822) - try_statement : TRY block . error (823) - - error shift 546 - CATCH shift 547 - FINALLY shift 548 - . error - - catch_clauses goto 549 - catch_clause goto 550 - - -state 346 - typeof_expression : TYPEOF $$63 . open_parens_any typeof_type_expression CLOSE_PARENS (545) - - OPEN_PARENS shift 284 - OPEN_PARENS_CAST shift 285 - . error - - open_parens_any goto 551 - - -state 347 - unchecked_statement : UNCHECKED block . (835) - - . reduce 835 - - -state 348 - unchecked_expression : UNCHECKED open_parens_any . expression CLOSE_PARENS (558) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 552 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 349 - unsafe_statement : UNSAFE $$82 . block (837) - - OPEN_BRACE shift 143 - . error - - block goto 553 - - -state 350 - using_statement : USING open_parens_any . local_variable_declaration CLOSE_PARENS $$84 embedded_statement (846) - using_statement : USING open_parens_any . expression CLOSE_PARENS $$85 embedded_statement (848) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - VOID shift 139 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 554 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - local_variable_declaration goto 555 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 351 - local_variable_pointer_type : VOID STAR . (747) - - . reduce 747 - - -state 352 - opt_rank_specifier : rank_specifiers . (528) - - . reduce 528 - - -state 353 - variable_type : VOID opt_rank_specifier . (744) - - . reduce 744 - - -state 354 - while_statement : WHILE open_parens_any . boolean_expression CLOSE_PARENS embedded_statement (785) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 518 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - boolean_expression goto 556 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 355 - type_name : IDENTIFIER . opt_type_argument_list (362) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - nested_from_clause : FROM IDENTIFIER . IN expression (855) - opt_type_argument_list : . (363) - - IN shift 557 - OP_GENERICS_LT shift 81 - DOUBLE_COLON shift 83 - INTERR_NULLABLE reduce 363 - OPEN_BRACKET reduce 363 - DOT reduce 363 - STAR reduce 363 - IDENTIFIER reduce 363 - - opt_type_argument_list goto 84 - - -state 356 - nested_from_clause : FROM type . IDENTIFIER IN expression (856) - - IDENTIFIER shift 558 - . error - - -state 357 - type_name : IDENTIFIER . opt_type_argument_list (362) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - first_from_clause : FROM_FIRST IDENTIFIER . IN expression (853) - opt_type_argument_list : . (363) - - IN shift 559 - OP_GENERICS_LT shift 81 - DOUBLE_COLON shift 83 - INTERR_NULLABLE reduce 363 - OPEN_BRACKET reduce 363 - DOT reduce 363 - STAR reduce 363 - IDENTIFIER reduce 363 - - opt_type_argument_list goto 84 - - -state 358 - first_from_clause : FROM_FIRST type . IDENTIFIER IN expression (854) - - IDENTIFIER shift 560 - . error - - -state 359 - block : OPEN_BRACE $$74 . opt_statement_list block_end (691) - opt_statement_list : . (696) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BREAK shift 98 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 101 - CONST shift 102 - CONTINUE shift 103 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DO shift 107 - DOUBLE shift 108 - FALSE shift 109 - FIXED shift 110 - FLOAT shift 111 - FOR shift 112 - FOREACH shift 113 - GOTO shift 114 - IF shift 115 - INT shift 116 - LOCK shift 117 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - RETURN shift 122 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - SWITCH shift 127 - THIS shift 128 - THROW shift 129 - TRUE shift 130 - TRY shift 131 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 135 - UNSAFE shift 136 - USHORT shift 137 - USING shift 138 - VOID shift 139 - WHILE shift 140 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 143 - OPEN_PARENS shift 144 - SEMICOLON shift 145 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 155 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - CLOSE_BRACE reduce 696 - COMPLETE_COMPLETION reduce 696 - - expression goto 304 - block goto 305 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - opt_statement_list goto 561 - statement_list goto 562 - statement goto 563 - declaration_statement goto 564 - valid_declaration_statement goto 565 - labeled_statement goto 566 - empty_statement goto 309 - expression_statement goto 310 - selection_statement goto 311 - iteration_statement goto 312 - jump_statement goto 313 - try_statement goto 314 - checked_statement goto 315 - unchecked_statement goto 316 - lock_statement goto 317 - using_statement goto 318 - unsafe_statement goto 319 - fixed_statement goto 320 - local_variable_declaration goto 221 - local_constant_declaration goto 222 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - statement_expression goto 322 - if_statement goto 227 - switch_statement goto 228 - while_statement goto 229 - do_statement goto 230 - for_statement goto 231 - foreach_statement goto 232 - break_statement goto 233 - continue_statement goto 234 - goto_statement goto 235 - return_statement goto 236 - throw_statement goto 237 - yield_statement goto 238 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 360 - parenthesized_expression : OPEN_PARENS expression . CLOSE_PARENS (450) - parenthesized_expression : OPEN_PARENS expression . COMPLETE_COMPLETION (451) - - CLOSE_PARENS shift 567 - COMPLETE_COMPLETION shift 568 - . error - - -state 361 - member_access : builtin_types . DOT IDENTIFIER opt_type_argument_list (453) - member_access : builtin_types . DOT GENERATE_COMPLETION (458) - member_access : builtin_types . DOT IDENTIFIER GENERATE_COMPLETION (459) - cast_expression : OPEN_PARENS builtin_types . CLOSE_PARENS prefixed_unary_expression (572) - - CLOSE_PARENS shift 569 - DOT shift 380 - . error - - -state 362 - unary_expression : TILDE prefixed_unary_expression . (569) - - . reduce 569 - - -state 363 - prefixed_unary_expression : PLUS prefixed_unary_expression . (574) - - . reduce 574 - - -state 364 - prefixed_unary_expression : MINUS prefixed_unary_expression . (575) - - . reduce 575 - - -state 365 - unary_expression : BANG prefixed_unary_expression . (568) - - . reduce 568 - - -state 366 - prefixed_unary_expression : BITWISE_AND prefixed_unary_expression . (579) - - . reduce 579 - - -state 367 - prefixed_unary_expression : STAR prefixed_unary_expression . (578) - - . reduce 578 - - -state 368 - prefixed_unary_expression : OP_INC prefixed_unary_expression . (576) - - . reduce 576 - - -state 369 - prefixed_unary_expression : OP_DEC prefixed_unary_expression . (577) - - . reduce 577 - - -state 370 - yield_statement : IDENTIFIER BREAK . SEMICOLON (817) - - SEMICOLON shift 570 - . error - - -state 371 - yield_statement : IDENTIFIER RETURN . opt_expression SEMICOLON (816) - opt_expression : . (818) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - SEMICOLON reduce 818 - - expression goto 338 - opt_expression goto 571 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 372 - lambda_expression : IDENTIFIER ARROW . $$67 lambda_expression_body (637) - $$67 : . (636) - - . reduce 636 - - $$67 goto 572 - - -state 373 - labeled_statement : IDENTIFIER COLON . $$76 statement (739) - $$76 : . (738) - - . reduce 738 - - $$76 goto 573 - - -state 374 - primary_expression_no_array_creation : IDENTIFIER GENERATE_COMPLETION . (423) - - . reduce 423 - - -state 375 - primary_expression_no_array_creation : IDENTIFIER opt_type_argument_list . (422) - - . reduce 422 - - -state 376 - lambda_expression : OPEN_PARENS_LAMBDA $$68 . opt_lambda_parameter_list CLOSE_PARENS ARROW $$69 lambda_expression_body (640) - opt_lambda_parameter_list : . (631) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - OUT shift 574 - REF shift 575 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - THIS shift 576 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 577 - IDENTIFIER shift 578 - CLOSE_PARENS reduce 631 - - namespace_or_type_name goto 255 - parameter_type goto 579 - parameter_modifier goto 580 - type_expression_or_array goto 581 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - lambda_parameter_list goto 582 - lambda_parameter goto 583 - opt_lambda_parameter_list goto 584 - - -state 377 - cast_expression : OPEN_PARENS_CAST type . CLOSE_PARENS prefixed_unary_expression (571) - - CLOSE_PARENS shift 585 - . error - - -state 378 - member_access : qualified_alias_member IDENTIFIER . opt_type_argument_list (455) - opt_type_argument_list : . (363) - - OP_GENERICS_LT shift 81 - error reduce 363 - AS reduce 363 - IS reduce 363 - WHERE reduce 363 - FROM reduce 363 - JOIN reduce 363 - ON reduce 363 - EQUALS reduce 363 - SELECT reduce 363 - GROUP reduce 363 - BY reduce 363 - LET reduce 363 - ORDERBY reduce 363 - ASCENDING reduce 363 - DESCENDING reduce 363 - INTO reduce 363 - INTERR_NULLABLE reduce 363 - CLOSE_BRACE reduce 363 - OPEN_BRACKET reduce 363 - CLOSE_BRACKET reduce 363 - OPEN_PARENS reduce 363 - CLOSE_PARENS reduce 363 - DOT reduce 363 - COMMA reduce 363 - COLON reduce 363 - SEMICOLON reduce 363 - PLUS reduce 363 - MINUS reduce 363 - ASSIGN reduce 363 - OP_LT reduce 363 - OP_GT reduce 363 - BITWISE_AND reduce 363 - BITWISE_OR reduce 363 - STAR reduce 363 - PERCENT reduce 363 - DIV reduce 363 - CARRET reduce 363 - INTERR reduce 363 - OP_INC reduce 363 - OP_DEC reduce 363 - OP_SHIFT_LEFT reduce 363 - OP_SHIFT_RIGHT reduce 363 - OP_LE reduce 363 - OP_GE reduce 363 - OP_EQ reduce 363 - OP_NE reduce 363 - OP_AND reduce 363 - OP_OR reduce 363 - OP_MULT_ASSIGN reduce 363 - OP_DIV_ASSIGN reduce 363 - OP_MOD_ASSIGN reduce 363 - OP_ADD_ASSIGN reduce 363 - OP_SUB_ASSIGN reduce 363 - OP_SHIFT_LEFT_ASSIGN reduce 363 - OP_SHIFT_RIGHT_ASSIGN reduce 363 - OP_AND_ASSIGN reduce 363 - OP_XOR_ASSIGN reduce 363 - OP_OR_ASSIGN reduce 363 - OP_PTR reduce 363 - OP_COALESCING reduce 363 - IDENTIFIER reduce 363 - OPEN_PARENS_CAST reduce 363 - OPEN_BRACKET_EXPR reduce 363 - COMPLETE_COMPLETION reduce 363 - - opt_type_argument_list goto 586 - - -state 379 - opt_nullable : INTERR_NULLABLE . (357) - - . reduce 357 - - -state 380 - member_access : builtin_types DOT . IDENTIFIER opt_type_argument_list (453) - member_access : builtin_types DOT . GENERATE_COMPLETION (458) - member_access : builtin_types DOT . IDENTIFIER GENERATE_COMPLETION (459) - - IDENTIFIER shift 587 - GENERATE_COMPLETION shift 588 - . error - - -state 381 - local_variable_pointer_type : builtin_types STAR . (746) - - . reduce 746 - - -state 382 - opt_rank_specifier_or_nullable : opt_nullable . (529) - opt_rank_specifier_or_nullable : opt_nullable . rank_specifiers (530) - - OPEN_BRACKET shift 332 - IDENTIFIER reduce 529 - - rank_specifiers goto 589 - rank_specifier goto 336 - - -state 383 - variable_type : builtin_types opt_rank_specifier_or_nullable . (743) - - . reduce 743 - - -state 384 - member_access : primary_expression DOT . IDENTIFIER opt_type_argument_list (452) - member_access : primary_expression DOT . GENERATE_COMPLETION (456) - member_access : primary_expression DOT . IDENTIFIER GENERATE_COMPLETION (457) - - IDENTIFIER shift 590 - GENERATE_COMPLETION shift 591 - . error - - -state 385 - post_increment_expression : primary_expression OP_INC . (505) - - . reduce 505 - - -state 386 - post_decrement_expression : primary_expression OP_DEC . (506) - - . reduce 506 - - -state 387 - pointer_member_access : primary_expression OP_PTR . IDENTIFIER (559) - - IDENTIFIER shift 592 - . error - - -state 388 - element_access : primary_expression OPEN_BRACKET_EXPR . expression_list_arguments CLOSE_BRACKET (494) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 492 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 493 - named_argument goto 494 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - expression_list_arguments goto 593 - expression_list_argument goto 496 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 389 - invocation_expression : primary_expression open_parens_any . opt_argument_list close_parens (460) - opt_argument_list : . (477) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - OUT shift 594 - REF shift 595 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - ARGLIST shift 596 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - COMMA shift 597 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 492 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - CLOSE_PARENS reduce 477 - COMPLETE_COMPLETION reduce 477 - - expression goto 598 - named_argument goto 599 - opt_argument_list goto 600 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - argument_list goto 601 - argument_or_named_argument goto 602 - argument goto 603 - non_simple_argument goto 604 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 390 - local_variable_pointer_type : primary_expression_no_array_creation STAR . (745) - - . reduce 745 - - -state 391 - variable_type : primary_expression_no_array_creation opt_rank_specifier_or_nullable . (742) - - . reduce 742 - - -state 392 - additive_expression : parenthesized_expression MINUS . multiplicative_expression (587) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 606 - - -state 393 - assignment_expression : prefixed_unary_expression ASSIGN . expression (615) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 607 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 394 - assignment_expression : prefixed_unary_expression OP_MULT_ASSIGN . expression (616) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 608 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 395 - assignment_expression : prefixed_unary_expression OP_DIV_ASSIGN . expression (617) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 609 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 396 - assignment_expression : prefixed_unary_expression OP_MOD_ASSIGN . expression (618) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 610 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 397 - assignment_expression : prefixed_unary_expression OP_ADD_ASSIGN . expression (619) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 611 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 398 - assignment_expression : prefixed_unary_expression OP_SUB_ASSIGN . expression (620) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 612 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 399 - assignment_expression : prefixed_unary_expression OP_SHIFT_LEFT_ASSIGN . expression (621) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 613 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 400 - assignment_expression : prefixed_unary_expression OP_SHIFT_RIGHT_ASSIGN . expression (622) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 614 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 401 - assignment_expression : prefixed_unary_expression OP_AND_ASSIGN . expression (623) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 615 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 402 - assignment_expression : prefixed_unary_expression OP_XOR_ASSIGN . expression (625) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 616 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 403 - assignment_expression : prefixed_unary_expression OP_OR_ASSIGN . expression (624) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 617 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 404 - multiplicative_expression : multiplicative_expression STAR . prefixed_unary_expression (581) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 618 - cast_expression goto 188 - - -state 405 - multiplicative_expression : multiplicative_expression PERCENT . prefixed_unary_expression (583) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 619 - cast_expression goto 188 - - -state 406 - multiplicative_expression : multiplicative_expression DIV . prefixed_unary_expression (582) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 620 - cast_expression goto 188 - - -state 407 - additive_expression : additive_expression AS . type (588) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 621 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 408 - additive_expression : additive_expression IS . type (589) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 622 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 409 - additive_expression : additive_expression PLUS . multiplicative_expression (585) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 623 - - -state 410 - additive_expression : additive_expression MINUS . multiplicative_expression (586) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 624 - - -state 411 - shift_expression : shift_expression OP_SHIFT_LEFT . additive_expression (591) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 625 - - -state 412 - shift_expression : shift_expression OP_SHIFT_RIGHT . additive_expression (592) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 626 - - -state 413 - relational_expression : relational_expression OP_LT . shift_expression (594) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 627 - - -state 414 - relational_expression : relational_expression OP_GT . shift_expression (595) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 628 - - -state 415 - relational_expression : relational_expression OP_LE . shift_expression (596) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 629 - - -state 416 - relational_expression : relational_expression OP_GE . shift_expression (597) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 630 - - -state 417 - equality_expression : equality_expression OP_EQ . relational_expression (599) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 631 - - -state 418 - equality_expression : equality_expression OP_NE . relational_expression (600) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 632 - - -state 419 - and_expression : and_expression BITWISE_AND . equality_expression (602) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 633 - - -state 420 - exclusive_or_expression : exclusive_or_expression CARRET . and_expression (604) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 634 - - -state 421 - inclusive_or_expression : inclusive_or_expression BITWISE_OR . exclusive_or_expression (606) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 635 - - -state 422 - conditional_and_expression : conditional_and_expression OP_AND . inclusive_or_expression (608) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 636 - - -state 423 - conditional_or_expression : conditional_or_expression OP_OR . conditional_and_expression (610) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 637 - - -state 424 - null_coalescing_expression : conditional_or_expression OP_COALESCING . null_coalescing_expression (612) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 638 - - -state 425 - conditional_expression : null_coalescing_expression INTERR . expression COLON expression (614) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 639 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 426 - opt_COMPLETE_COMPLETION : COMPLETE_COMPLETION . (919) - - . reduce 919 - - -state 427 - interactive_parsing : EVAL_STATEMENT_PARSER $$103 interactive_statement_list opt_COMPLETE_COMPLETION . (911) - - . reduce 911 - - -state 428 - interactive_statement_list : interactive_statement_list interactive_statement . (704) - - . reduce 704 - - -state 429 - declaration_statement : local_variable_declaration SEMICOLON . (740) - - . reduce 740 - - -state 430 - declaration_statement : local_constant_declaration SEMICOLON . (741) - - . reduce 741 - - -state 431 - local_variable_pointer_type : local_variable_pointer_type STAR . (748) - - . reduce 748 - - -state 432 - local_variable_type : local_variable_pointer_type opt_rank_specifier . (750) - - . reduce 750 - - -state 433 - local_variable_declarator : IDENTIFIER . ASSIGN local_variable_initializer (164) - local_variable_declarator : IDENTIFIER . (165) - local_variable_declarator : IDENTIFIER . variable_bad_array (166) - - ASSIGN shift 640 - OPEN_BRACKET_EXPR shift 641 - CLOSE_PARENS reduce 165 - COMMA reduce 165 - SEMICOLON reduce 165 - - variable_bad_array goto 642 - - -state 434 - local_variable_declarators : local_variable_declarators . COMMA local_variable_declarator (163) - local_variable_declaration : local_variable_type local_variable_declarators . (751) - - COMMA shift 643 - CLOSE_PARENS reduce 751 - SEMICOLON reduce 751 - - -state 435 - local_variable_declarators : local_variable_declarator . (162) - - . reduce 162 - - -state 436 - interactive_expression_statement : interactive_statement_expression SEMICOLON . (759) - - . reduce 759 - - -state 437 - interactive_expression_statement : interactive_statement_expression COMPLETE_COMPLETION . (760) - - . reduce 760 - - -state 438 - where_clause : WHERE . $$92 boolean_expression (880) - $$92 : . (879) - - . reduce 879 - - $$92 goto 644 - - -state 439 - from_clause : FROM . IDENTIFIER IN $$86 expression (858) - from_clause : FROM . type IDENTIFIER IN $$87 expression (860) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 645 - . error - - namespace_or_type_name goto 255 - type goto 646 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 440 - join_clause : JOIN . IDENTIFIER IN $$93 expression ON $$94 expression EQUALS $$95 expression opt_join_into (884) - join_clause : JOIN . type IDENTIFIER IN $$96 expression ON $$97 expression EQUALS $$98 expression opt_join_into (888) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 647 - . error - - namespace_or_type_name goto 255 - type goto 648 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 441 - let_clause : LET . IDENTIFIER ASSIGN $$91 expression (878) - - IDENTIFIER shift 649 - . error - - -state 442 - orderby_clause : ORDERBY . $$99 orderings (892) - $$99 : . (891) - - . reduce 891 - - $$99 goto 650 - - -state 443 - query_expression : first_from_clause COMPLETE_COMPLETION . (851) - - . reduce 851 - - -state 444 - query_expression : first_from_clause query_body . (849) - - . reduce 849 - - -state 445 - query_body_clause : from_clause . (872) - - . reduce 872 - - -state 446 - query_body : opt_query_body_clauses . select_or_group_clause opt_query_continuation (861) - query_body : opt_query_body_clauses . COMPLETE_COMPLETION (862) - - SELECT shift 651 - GROUP shift 652 - COMPLETE_COMPLETION shift 653 - . error - - select_or_group_clause goto 654 - - -state 447 - opt_query_body_clauses : query_body_clauses . (869) - query_body_clauses : query_body_clauses . query_body_clause (871) - - WHERE shift 438 - FROM shift 439 - JOIN shift 440 - LET shift 441 - ORDERBY shift 442 - SELECT reduce 869 - GROUP reduce 869 - COMPLETE_COMPLETION reduce 869 - - from_clause goto 445 - query_body_clause goto 655 - let_clause goto 449 - where_clause goto 450 - join_clause goto 451 - orderby_clause goto 452 - - -state 448 - query_body_clauses : query_body_clause . (870) - - . reduce 870 - - -state 449 - query_body_clause : let_clause . (873) - - . reduce 873 - - -state 450 - query_body_clause : where_clause . (874) - - . reduce 874 - - -state 451 - query_body_clause : join_clause . (875) - - . reduce 875 - - -state 452 - query_body_clause : orderby_clause . (876) - - . reduce 876 - - -state 453 - query_expression : nested_from_clause COMPLETE_COMPLETION . (852) - - . reduce 852 - - -state 454 - query_expression : nested_from_clause query_body . (850) - - . reduce 850 - - -state 455 - interactive_compilation_unit : outer_declarations global_attributes . (915) - - . reduce 915 - - -state 456 - qualified_identifier : qualified_identifier DOT . IDENTIFIER (28) - - IDENTIFIER shift 656 - . error - - -state 457 - namespace_declaration : opt_attributes NAMESPACE qualified_identifier $$2 . namespace_body opt_semicolon (26) - - OPEN_BRACE shift 657 - . error - - namespace_body goto 658 - - -state 458 - delegate_declaration : opt_attributes opt_modifiers DELEGATE member_type . type_declaration_name OPEN_PARENS $$58 opt_formal_parameter_list CLOSE_PARENS $$59 opt_type_parameter_constraints_clauses $$60 SEMICOLON (355) - - IDENTIFIER shift 459 - . error - - type_declaration_name goto 659 - - -state 459 - type_declaration_name : IDENTIFIER . $$61 opt_type_parameter_list (369) - $$61 : . (368) - - . reduce 368 - - $$61 goto 660 - - -state 460 - enum_declaration : opt_attributes opt_modifiers ENUM type_declaration_name . opt_enum_base $$54 OPEN_BRACE $$55 opt_enum_member_declarations $$56 CLOSE_BRACE opt_semicolon (340) - opt_enum_base : . (341) - - COLON shift 661 - OPEN_BRACE reduce 341 - - opt_enum_base goto 662 - - -state 461 - simple_type : VOID . (390) - type_expression : VOID . STAR (398) - - STAR shift 464 - error reduce 390 - OPEN_BRACE reduce 390 - OPEN_BRACKET reduce 390 - OPEN_PARENS reduce 390 - CLOSE_PARENS reduce 390 - COMMA reduce 390 - SEMICOLON reduce 390 - IDENTIFIER reduce 390 - OPEN_PARENS_CAST reduce 390 - OPEN_BRACKET_EXPR reduce 390 - - -state 462 - field_declaration : opt_attributes opt_modifiers FIXED simple_type . IDENTIFIER $$15 fixed_field_size opt_fixed_field_declarators SEMICOLON (142) - field_declaration : opt_attributes opt_modifiers FIXED simple_type . error SEMICOLON (143) - - error shift 663 - IDENTIFIER shift 664 - . error - - -state 463 - simple_type : type_expression . (389) - type_expression : type_expression . STAR (397) - - STAR shift 476 - error reduce 389 - OPEN_BRACE reduce 389 - OPEN_BRACKET reduce 389 - OPEN_PARENS reduce 389 - CLOSE_PARENS reduce 389 - COMMA reduce 389 - SEMICOLON reduce 389 - IDENTIFIER reduce 389 - OPEN_PARENS_CAST reduce 389 - OPEN_BRACKET_EXPR reduce 389 - - -state 464 - type_expression : VOID STAR . (398) - - . reduce 398 - - -state 465 - method_header : opt_attributes opt_modifiers PARTIAL VOID . method_declaration_name OPEN_PARENS $$22 opt_formal_parameter_list CLOSE_PARENS $$23 opt_type_parameter_constraints_clauses (182) - - IDENTIFIER shift 665 - . error - - type_declaration_name goto 471 - method_declaration_name goto 666 - qualified_alias_member goto 474 - explicit_interface goto 475 - - -state 466 - type_expression : namespace_or_type_name opt_nullable . (395) - - . reduce 395 - - -state 467 - class_declaration : opt_attributes opt_modifiers opt_partial CLASS . $$70 type_declaration_name $$71 opt_class_base opt_type_parameter_constraints_clauses $$72 OPEN_BRACE opt_class_member_declarations CLOSE_BRACE $$73 opt_semicolon (652) - $$70 : . (648) - - . reduce 648 - - $$70 goto 667 - - -state 468 - interface_declaration : opt_attributes opt_modifiers opt_partial INTERFACE . $$33 type_declaration_name $$34 opt_class_base opt_type_parameter_constraints_clauses $$35 OPEN_BRACE opt_interface_member_declarations CLOSE_BRACE $$36 opt_semicolon (242) - interface_declaration : opt_attributes opt_modifiers opt_partial INTERFACE . error (243) - $$33 : . (238) - - error shift 668 - IDENTIFIER reduce 238 - - $$33 goto 669 - - -state 469 - struct_declaration : opt_attributes opt_modifiers opt_partial STRUCT . $$7 type_declaration_name $$8 opt_class_base opt_type_parameter_constraints_clauses $$9 struct_body $$10 opt_semicolon (109) - struct_declaration : opt_attributes opt_modifiers opt_partial STRUCT . error (110) - $$7 : . (105) - - error shift 670 - IDENTIFIER reduce 105 - - $$7 goto 671 - - -state 470 - field_declaration : opt_attributes opt_modifiers member_type IDENTIFIER . $$14 opt_field_initializer opt_field_declarators SEMICOLON (140) - type_declaration_name : IDENTIFIER . $$61 opt_type_parameter_list (369) - explicit_interface : IDENTIFIER . opt_type_argument_list DOT (375) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - $$14 : . (139) - opt_type_argument_list : . (363) - $$61 : . (368) - - OP_GENERICS_LT shift 81 - DOUBLE_COLON shift 83 - OP_GENERICS_LT_DECL reduce 368 - OPEN_BRACE reduce 368 - OPEN_PARENS reduce 368 - DOT reduce 363 - COMMA reduce 139 - SEMICOLON reduce 139 - ASSIGN reduce 139 - - $$14 goto 672 - opt_type_argument_list goto 673 - $$61 goto 660 - - -state 471 - method_declaration_name : type_declaration_name . (371) - - . reduce 371 - - -state 472 - method_header : opt_attributes opt_modifiers member_type method_declaration_name . OPEN_PARENS $$20 opt_formal_parameter_list CLOSE_PARENS $$21 opt_type_parameter_constraints_clauses (179) - - OPEN_PARENS shift 674 - . error - - -state 473 - method_header : opt_attributes opt_modifiers member_type modifiers . method_declaration_name OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS (183) - modifiers : modifiers . modifier (658) - - ABSTRACT shift 61 - EXTERN shift 62 - INTERNAL shift 63 - NEW shift 65 - OVERRIDE shift 66 - PRIVATE shift 67 - PROTECTED shift 68 - PUBLIC shift 69 - READONLY shift 70 - SEALED shift 71 - STATIC shift 72 - UNSAFE shift 73 - VIRTUAL shift 74 - VOLATILE shift 75 - IDENTIFIER shift 665 - . error - - type_declaration_name goto 471 - method_declaration_name goto 675 - qualified_alias_member goto 474 - explicit_interface goto 475 - modifier goto 262 - - -state 474 - explicit_interface : qualified_alias_member . IDENTIFIER opt_type_argument_list DOT (376) - - IDENTIFIER shift 676 - . error - - -state 475 - method_declaration_name : explicit_interface . IDENTIFIER opt_type_parameter_list (372) - explicit_interface : explicit_interface . IDENTIFIER opt_type_argument_list DOT (377) - - IDENTIFIER shift 677 - . error - - -state 476 - type_expression : type_expression STAR . (397) - - . reduce 397 - - -state 477 - type_expression_or_array : type_expression rank_specifiers . (394) - - . reduce 394 - - -state 478 - type_expression : builtin_types opt_nullable . (396) - - . reduce 396 - - -state 479 - opt_type_argument_list : OP_GENERICS_LT type_arguments OP_GENERICS_GT . (364) - - . reduce 364 - - -state 480 - type_arguments : type_arguments COMMA . type (367) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 678 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 481 - using_alias_directive : USING IDENTIFIER ASSIGN namespace_or_type_name SEMICOLON . (22) - - . reduce 22 - - -state 482 - member_name : namespace_or_type_name DOT IDENTIFIER opt_type_argument_list . (361) - - . reduce 361 - - -state 483 - attribute_section : OPEN_BRACKET attribute_target_specifier attribute_list opt_comma CLOSE_BRACKET . (63) - - . reduce 63 - - -484: shift/reduce conflict (shift 680, reduce 363) on ASSIGN -state 484 - named_attribute_argument : IDENTIFIER . ASSIGN $$6 expression (85) - named_argument : IDENTIFIER . COLON opt_named_modifier expression (86) - primary_expression_no_array_creation : IDENTIFIER . opt_type_argument_list (422) - primary_expression_no_array_creation : IDENTIFIER . GENERATE_COMPLETION (423) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - lambda_expression : IDENTIFIER . ARROW $$67 lambda_expression_body (637) - opt_type_argument_list : . (363) - - ARROW shift 372 - OP_GENERICS_LT shift 81 - COLON shift 679 - ASSIGN shift 680 - DOUBLE_COLON shift 83 - GENERATE_COMPLETION shift 374 - AS reduce 363 - IS reduce 363 - OPEN_PARENS reduce 363 - CLOSE_PARENS reduce 363 - DOT reduce 363 - COMMA reduce 363 - PLUS reduce 363 - MINUS reduce 363 - OP_LT reduce 363 - OP_GT reduce 363 - BITWISE_AND reduce 363 - BITWISE_OR reduce 363 - STAR reduce 363 - PERCENT reduce 363 - DIV reduce 363 - CARRET reduce 363 - INTERR reduce 363 - OP_INC reduce 363 - OP_DEC reduce 363 - OP_SHIFT_LEFT reduce 363 - OP_SHIFT_RIGHT reduce 363 - OP_LE reduce 363 - OP_GE reduce 363 - OP_EQ reduce 363 - OP_NE reduce 363 - OP_AND reduce 363 - OP_OR reduce 363 - OP_MULT_ASSIGN reduce 363 - OP_DIV_ASSIGN reduce 363 - OP_MOD_ASSIGN reduce 363 - OP_ADD_ASSIGN reduce 363 - OP_SUB_ASSIGN reduce 363 - OP_SHIFT_LEFT_ASSIGN reduce 363 - OP_SHIFT_RIGHT_ASSIGN reduce 363 - OP_AND_ASSIGN reduce 363 - OP_XOR_ASSIGN reduce 363 - OP_OR_ASSIGN reduce 363 - OP_PTR reduce 363 - OP_COALESCING reduce 363 - OPEN_PARENS_CAST reduce 363 - OPEN_BRACKET_EXPR reduce 363 - - opt_type_argument_list goto 375 - - -state 485 - opt_attribute_arguments : OPEN_PARENS attribute_arguments . CLOSE_PARENS (76) - attribute_arguments : attribute_arguments . COMMA positional_or_named_argument (80) - attribute_arguments : attribute_arguments . COMMA named_attribute_argument (81) - - CLOSE_PARENS shift 681 - COMMA shift 682 - . error - - -state 486 - attribute_arguments : positional_or_named_argument . (78) - - . reduce 78 - - -state 487 - attribute_arguments : named_attribute_argument . (79) - - . reduce 79 - - -state 488 - positional_or_named_argument : expression . (82) - - . reduce 82 - - -state 489 - positional_or_named_argument : named_argument . (83) - - . reduce 83 - - -state 490 - base_access : BASE OPEN_BRACKET error . (504) - - . reduce 504 - - -state 491 - member_access : BASE DOT IDENTIFIER . opt_type_argument_list (454) - opt_type_argument_list : . (363) - - OP_GENERICS_LT shift 81 - error reduce 363 - AS reduce 363 - IS reduce 363 - WHERE reduce 363 - FROM reduce 363 - JOIN reduce 363 - ON reduce 363 - EQUALS reduce 363 - SELECT reduce 363 - GROUP reduce 363 - BY reduce 363 - LET reduce 363 - ORDERBY reduce 363 - ASCENDING reduce 363 - DESCENDING reduce 363 - INTO reduce 363 - INTERR_NULLABLE reduce 363 - CLOSE_BRACE reduce 363 - OPEN_BRACKET reduce 363 - CLOSE_BRACKET reduce 363 - OPEN_PARENS reduce 363 - CLOSE_PARENS reduce 363 - DOT reduce 363 - COMMA reduce 363 - COLON reduce 363 - SEMICOLON reduce 363 - PLUS reduce 363 - MINUS reduce 363 - ASSIGN reduce 363 - OP_LT reduce 363 - OP_GT reduce 363 - BITWISE_AND reduce 363 - BITWISE_OR reduce 363 - STAR reduce 363 - PERCENT reduce 363 - DIV reduce 363 - CARRET reduce 363 - INTERR reduce 363 - OP_INC reduce 363 - OP_DEC reduce 363 - OP_SHIFT_LEFT reduce 363 - OP_SHIFT_RIGHT reduce 363 - OP_LE reduce 363 - OP_GE reduce 363 - OP_EQ reduce 363 - OP_NE reduce 363 - OP_AND reduce 363 - OP_OR reduce 363 - OP_MULT_ASSIGN reduce 363 - OP_DIV_ASSIGN reduce 363 - OP_MOD_ASSIGN reduce 363 - OP_ADD_ASSIGN reduce 363 - OP_SUB_ASSIGN reduce 363 - OP_SHIFT_LEFT_ASSIGN reduce 363 - OP_SHIFT_RIGHT_ASSIGN reduce 363 - OP_AND_ASSIGN reduce 363 - OP_XOR_ASSIGN reduce 363 - OP_OR_ASSIGN reduce 363 - OP_PTR reduce 363 - OP_COALESCING reduce 363 - IDENTIFIER reduce 363 - OPEN_PARENS_CAST reduce 363 - OPEN_BRACKET_EXPR reduce 363 - COMPLETE_COMPLETION reduce 363 - - opt_type_argument_list goto 683 - - -state 492 - named_argument : IDENTIFIER . COLON opt_named_modifier expression (86) - primary_expression_no_array_creation : IDENTIFIER . opt_type_argument_list (422) - primary_expression_no_array_creation : IDENTIFIER . GENERATE_COMPLETION (423) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - lambda_expression : IDENTIFIER . ARROW $$67 lambda_expression_body (637) - opt_type_argument_list : . (363) - - ARROW shift 372 - OP_GENERICS_LT shift 81 - COLON shift 679 - DOUBLE_COLON shift 83 - GENERATE_COMPLETION shift 374 - AS reduce 363 - IS reduce 363 - CLOSE_BRACKET reduce 363 - OPEN_PARENS reduce 363 - CLOSE_PARENS reduce 363 - DOT reduce 363 - COMMA reduce 363 - PLUS reduce 363 - MINUS reduce 363 - ASSIGN reduce 363 - OP_LT reduce 363 - OP_GT reduce 363 - BITWISE_AND reduce 363 - BITWISE_OR reduce 363 - STAR reduce 363 - PERCENT reduce 363 - DIV reduce 363 - CARRET reduce 363 - INTERR reduce 363 - OP_INC reduce 363 - OP_DEC reduce 363 - OP_SHIFT_LEFT reduce 363 - OP_SHIFT_RIGHT reduce 363 - OP_LE reduce 363 - OP_GE reduce 363 - OP_EQ reduce 363 - OP_NE reduce 363 - OP_AND reduce 363 - OP_OR reduce 363 - OP_MULT_ASSIGN reduce 363 - OP_DIV_ASSIGN reduce 363 - OP_MOD_ASSIGN reduce 363 - OP_ADD_ASSIGN reduce 363 - OP_SUB_ASSIGN reduce 363 - OP_SHIFT_LEFT_ASSIGN reduce 363 - OP_SHIFT_RIGHT_ASSIGN reduce 363 - OP_AND_ASSIGN reduce 363 - OP_XOR_ASSIGN reduce 363 - OP_OR_ASSIGN reduce 363 - OP_PTR reduce 363 - OP_COALESCING reduce 363 - OPEN_PARENS_CAST reduce 363 - OPEN_BRACKET_EXPR reduce 363 - COMPLETE_COMPLETION reduce 363 - - opt_type_argument_list goto 375 - - -state 493 - expression_list_argument : expression . (500) - - . reduce 500 - - -state 494 - expression_list_argument : named_argument . (501) - - . reduce 501 - - -state 495 - expression_list_arguments : expression_list_arguments . COMMA expression_list_argument (499) - base_access : BASE OPEN_BRACKET_EXPR expression_list_arguments . CLOSE_BRACKET (503) - - CLOSE_BRACKET shift 684 - COMMA shift 685 - . error - - -state 496 - expression_list_arguments : expression_list_argument . (498) - - . reduce 498 - - -state 497 - checked_expression : CHECKED open_parens_any expression . CLOSE_PARENS (557) - - CLOSE_PARENS shift 686 - . error - - -state 498 - local_constant_declarator : IDENTIFIER . ASSIGN constant_initializer_expr (755) - local_constant_declarator : IDENTIFIER . error (756) - - error shift 687 - ASSIGN shift 688 - . error - - -state 499 - local_constant_declaration : CONST variable_type local_constant_declarators . (752) - local_constant_declarators : local_constant_declarators . COMMA local_constant_declarator (754) - - COMMA shift 689 - SEMICOLON reduce 752 - - -state 500 - local_constant_declarators : local_constant_declarator . (753) - - . reduce 753 - - -state 501 - default_value_expression : DEFAULT open_parens_any type . CLOSE_PARENS (566) - - CLOSE_PARENS shift 690 - . error - - -state 502 - anonymous_method_signature : OPEN_PARENS $$65 . opt_formal_parameter_list CLOSE_PARENS (565) - opt_attributes : . (59) - opt_formal_parameter_list : . (186) - - ARGLIST shift 691 - OPEN_BRACKET shift 4 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - DECIMAL reduce 59 - DOUBLE reduce 59 - FLOAT reduce 59 - INT reduce 59 - LONG reduce 59 - OBJECT reduce 59 - OUT reduce 59 - PARAMS reduce 59 - REF reduce 59 - SBYTE reduce 59 - SHORT reduce 59 - STRING reduce 59 - THIS reduce 59 - UINT reduce 59 - ULONG reduce 59 - USHORT reduce 59 - VOID reduce 59 - CLOSE_PARENS reduce 186 - IDENTIFIER reduce 59 - - opt_attributes goto 692 - attribute_sections goto 693 - attribute_section goto 30 - opt_formal_parameter_list goto 694 - formal_parameter_list goto 695 - fixed_parameters goto 696 - parameter_array goto 697 - arglist_modifier goto 698 - fixed_parameter goto 699 - - -state 503 - anonymous_method_expression : DELEGATE opt_anonymous_method_signature $$64 . block (561) - - OPEN_BRACE shift 143 - . error - - block goto 700 - - -state 504 - do_statement : DO embedded_statement WHILE . open_parens_any boolean_expression CLOSE_PARENS SEMICOLON (786) - - OPEN_PARENS shift 284 - OPEN_PARENS_CAST shift 285 - . error - - open_parens_any goto 701 - - -state 505 - expression_statement : statement_expression SEMICOLON . (757) - - . reduce 757 - - -state 506 - expression_statement : statement_expression COMPLETE_COMPLETION . (758) - - . reduce 758 - - -state 507 - fixed_statement : FIXED open_parens_any type_and_void . fixed_pointer_declarators CLOSE_PARENS $$83 embedded_statement (839) - - IDENTIFIER shift 702 - . error - - fixed_pointer_declarators goto 703 - fixed_pointer_declarator goto 704 - - -state 508 - for_initializer : local_variable_declaration . (791) - - . reduce 791 - - -state 509 - statement_expression_list : statement_expression . (798) - - . reduce 798 - - -state 510 - for_statement : FOR open_parens_any opt_for_initializer . SEMICOLON $$79 opt_for_condition SEMICOLON opt_for_iterator CLOSE_PARENS embedded_statement (788) - - SEMICOLON shift 705 - . error - - -state 511 - opt_for_initializer : for_initializer . (790) - - . reduce 790 - - -state 512 - for_initializer : statement_expression_list . (792) - statement_expression_list : statement_expression_list . COMMA statement_expression (799) - - COMMA shift 706 - SEMICOLON reduce 792 - - -state 513 - foreach_statement : FOREACH open_parens_any type . IN expression CLOSE_PARENS (800) - foreach_statement : FOREACH open_parens_any type . IDENTIFIER IN expression CLOSE_PARENS $$80 embedded_statement (802) - - IN shift 707 - IDENTIFIER shift 708 - . error - - -state 514 - constant_expression : expression . (646) - - . reduce 646 - - -state 515 - goto_statement : GOTO CASE constant_expression . SEMICOLON (812) - - SEMICOLON shift 709 - . error - - -state 516 - goto_statement : GOTO DEFAULT SEMICOLON . (813) - - . reduce 813 - - -state 517 - goto_statement : GOTO IDENTIFIER SEMICOLON . (811) - - . reduce 811 - - -state 518 - boolean_expression : expression . (647) - - . reduce 647 - - -state 519 - if_statement : IF open_parens_any boolean_expression . CLOSE_PARENS embedded_statement (767) - if_statement : IF open_parens_any boolean_expression . CLOSE_PARENS embedded_statement ELSE embedded_statement (768) - - CLOSE_PARENS shift 710 - . error - - -state 520 - lock_statement : LOCK open_parens_any expression . CLOSE_PARENS embedded_statement (844) - - CLOSE_PARENS shift 711 - . error - - -state 521 - anonymous_type_parameter : error . (526) - - . reduce 526 - - -state 522 - primary_expression_no_array_creation : IDENTIFIER . opt_type_argument_list (422) - primary_expression_no_array_creation : IDENTIFIER . GENERATE_COMPLETION (423) - anonymous_type_parameter : IDENTIFIER . ASSIGN variable_initializer (523) - anonymous_type_parameter : IDENTIFIER . (524) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - opt_type_argument_list : . (363) - - OP_GENERICS_LT shift 81 - ASSIGN shift 712 - DOUBLE_COLON shift 83 - GENERATE_COMPLETION shift 374 - CLOSE_BRACE reduce 524 - OPEN_PARENS reduce 363 - DOT reduce 363 - COMMA reduce 524 - OP_INC reduce 363 - OP_DEC reduce 363 - OP_PTR reduce 363 - OPEN_PARENS_CAST reduce 363 - OPEN_BRACKET_EXPR reduce 363 - - opt_type_argument_list goto 375 - - -state 523 - primary_expression_no_array_creation : member_access . (426) - anonymous_type_parameter : member_access . (525) - - CLOSE_BRACE reduce 525 - OPEN_PARENS reduce 426 - DOT reduce 426 - COMMA reduce 525 - OP_INC reduce 426 - OP_DEC reduce 426 - OP_PTR reduce 426 - OPEN_PARENS_CAST reduce 426 - OPEN_BRACKET_EXPR reduce 426 - - -state 524 - anonymous_type_expression : NEW OPEN_BRACE anonymous_type_parameters_opt_comma . CLOSE_BRACE (516) - - CLOSE_BRACE shift 713 - . error - - -state 525 - anonymous_type_parameters_opt_comma : anonymous_type_parameters_opt . (517) - - . reduce 517 - - -state 526 - anonymous_type_parameters_opt_comma : anonymous_type_parameters . COMMA (518) - anonymous_type_parameters_opt : anonymous_type_parameters . (520) - anonymous_type_parameters : anonymous_type_parameters . COMMA anonymous_type_parameter (522) - - COMMA shift 714 - CLOSE_BRACE reduce 520 - - -state 527 - anonymous_type_parameters : anonymous_type_parameter . (521) - - . reduce 521 - - -state 528 - rank_specifier : OPEN_BRACKET CLOSE_BRACKET . (533) - - . reduce 533 - - -state 529 - dim_separators : COMMA . (535) - - . reduce 535 - - -state 530 - rank_specifier : OPEN_BRACKET dim_separators . CLOSE_BRACKET (534) - dim_separators : dim_separators . COMMA (536) - - CLOSE_BRACKET shift 715 - COMMA shift 716 - . error - - -state 531 - array_initializer : OPEN_BRACE . CLOSE_BRACE (539) - array_initializer : OPEN_BRACE . variable_initializer_list opt_comma CLOSE_BRACE (540) - - error shift 717 - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 531 - CLOSE_BRACE shift 718 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 719 - array_initializer goto 720 - variable_initializer goto 721 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - variable_initializer_list goto 722 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 532 - array_creation_expression : NEW rank_specifiers array_initializer . (511) - - . reduce 511 - - -state 533 - array_creation_expression : NEW new_expr_type error . (513) - - . reduce 513 - - -state 534 - object_or_collection_initializer : OPEN_BRACE . opt_member_initializer_list close_brace_or_complete_completion (463) - object_or_collection_initializer : OPEN_BRACE . member_initializer_list COMMA CLOSE_BRACE (464) - opt_member_initializer_list : . (465) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 723 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 724 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - GENERATE_COMPLETION shift 725 - CLOSE_BRACE reduce 465 - COMPLETE_COMPLETION reduce 465 - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - opt_member_initializer_list goto 726 - member_initializer_list goto 727 - member_initializer goto 728 - non_assignment_expression goto 729 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 535 - array_creation_expression : NEW new_expr_type OPEN_BRACKET . CLOSE_BRACKET OPEN_BRACKET_EXPR error CLOSE_BRACKET (512) - rank_specifier : OPEN_BRACKET . CLOSE_BRACKET (533) - rank_specifier : OPEN_BRACKET . dim_separators CLOSE_BRACKET (534) - - CLOSE_BRACKET shift 730 - COMMA shift 529 - . error - - dim_separators goto 530 - - -state 536 - array_creation_expression : NEW new_expr_type OPEN_BRACKET_EXPR . expression_list CLOSE_BRACKET opt_rank_specifier opt_array_initializer (509) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 731 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - expression_list goto 732 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 537 - array_creation_expression : NEW new_expr_type rank_specifiers . opt_array_initializer (510) - opt_array_initializer : . (537) - - OPEN_BRACE shift 531 - error reduce 537 - AS reduce 537 - IS reduce 537 - WHERE reduce 537 - FROM reduce 537 - JOIN reduce 537 - ON reduce 537 - EQUALS reduce 537 - SELECT reduce 537 - GROUP reduce 537 - BY reduce 537 - LET reduce 537 - ORDERBY reduce 537 - ASCENDING reduce 537 - DESCENDING reduce 537 - INTO reduce 537 - CLOSE_BRACE reduce 537 - CLOSE_BRACKET reduce 537 - OPEN_PARENS reduce 537 - CLOSE_PARENS reduce 537 - DOT reduce 537 - COMMA reduce 537 - COLON reduce 537 - SEMICOLON reduce 537 - PLUS reduce 537 - MINUS reduce 537 - ASSIGN reduce 537 - OP_LT reduce 537 - OP_GT reduce 537 - BITWISE_AND reduce 537 - BITWISE_OR reduce 537 - STAR reduce 537 - PERCENT reduce 537 - DIV reduce 537 - CARRET reduce 537 - INTERR reduce 537 - OP_INC reduce 537 - OP_DEC reduce 537 - OP_SHIFT_LEFT reduce 537 - OP_SHIFT_RIGHT reduce 537 - OP_LE reduce 537 - OP_GE reduce 537 - OP_EQ reduce 537 - OP_NE reduce 537 - OP_AND reduce 537 - OP_OR reduce 537 - OP_MULT_ASSIGN reduce 537 - OP_DIV_ASSIGN reduce 537 - OP_MOD_ASSIGN reduce 537 - OP_ADD_ASSIGN reduce 537 - OP_SUB_ASSIGN reduce 537 - OP_SHIFT_LEFT_ASSIGN reduce 537 - OP_SHIFT_RIGHT_ASSIGN reduce 537 - OP_AND_ASSIGN reduce 537 - OP_XOR_ASSIGN reduce 537 - OP_OR_ASSIGN reduce 537 - OP_PTR reduce 537 - OP_COALESCING reduce 537 - OPEN_PARENS_CAST reduce 537 - OPEN_BRACKET_EXPR reduce 537 - COMPLETE_COMPLETION reduce 537 - - array_initializer goto 733 - opt_array_initializer goto 734 - - -state 538 - object_or_delegate_creation_expression : NEW new_expr_type open_parens_any . opt_argument_list CLOSE_PARENS opt_object_or_collection_initializer (507) - opt_argument_list : . (477) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - OUT shift 594 - REF shift 595 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - ARGLIST shift 596 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - COMMA shift 597 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 492 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - CLOSE_PARENS reduce 477 - - expression goto 598 - named_argument goto 599 - opt_argument_list goto 735 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - argument_list goto 601 - argument_or_named_argument goto 602 - argument goto 603 - non_simple_argument goto 604 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 539 - object_or_delegate_creation_expression : NEW new_expr_type object_or_collection_initializer . (508) - - . reduce 508 - - -state 540 - new_expr_type : $$62 simple_type . (515) - - . reduce 515 - - -state 541 - rank_specifiers : rank_specifier rank_specifiers . (532) - - . reduce 532 - - -state 542 - return_statement : RETURN opt_expression SEMICOLON . (814) - - . reduce 814 - - -state 543 - sizeof_expression : SIZEOF open_parens_any type . CLOSE_PARENS (556) - - CLOSE_PARENS shift 736 - . error - - -state 544 - switch_statement : SWITCH open_parens_any $$77 . expression CLOSE_PARENS OPEN_BRACE opt_switch_sections CLOSE_BRACE (770) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 737 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 545 - throw_statement : THROW opt_expression SEMICOLON . (815) - - . reduce 815 - - -state 546 - try_statement : TRY block error . (823) - - . reduce 823 - - -state 547 - catch_clause : CATCH . opt_catch_args $$81 block (829) - opt_catch_args : . (830) - - OPEN_PARENS shift 284 - OPEN_PARENS_CAST shift 285 - OPEN_BRACE reduce 830 - - open_parens_any goto 738 - opt_catch_args goto 739 - catch_args goto 740 - - -state 548 - try_statement : TRY block FINALLY . block (821) - - OPEN_BRACE shift 143 - . error - - block goto 741 - - -state 549 - try_statement : TRY block catch_clauses . (820) - try_statement : TRY block catch_clauses . FINALLY block (822) - catch_clauses : catch_clauses . catch_clause (825) - - CATCH shift 547 - FINALLY shift 742 - $end reduce 820 - error reduce 820 - EOF reduce 820 - BASE reduce 820 - BOOL reduce 820 - BREAK reduce 820 - BYTE reduce 820 - CASE reduce 820 - CHAR reduce 820 - CHECKED reduce 820 - CONST reduce 820 - CONTINUE reduce 820 - DECIMAL reduce 820 - DEFAULT reduce 820 - DELEGATE reduce 820 - DO reduce 820 - DOUBLE reduce 820 - ELSE reduce 820 - FALSE reduce 820 - FIXED reduce 820 - FLOAT reduce 820 - FOR reduce 820 - FOREACH reduce 820 - GOTO reduce 820 - IF reduce 820 - INT reduce 820 - LOCK reduce 820 - LONG reduce 820 - NEW reduce 820 - NULL reduce 820 - OBJECT reduce 820 - RETURN reduce 820 - SBYTE reduce 820 - SHORT reduce 820 - SIZEOF reduce 820 - STRING reduce 820 - SWITCH reduce 820 - THIS reduce 820 - THROW reduce 820 - TRUE reduce 820 - TRY reduce 820 - TYPEOF reduce 820 - UINT reduce 820 - ULONG reduce 820 - UNCHECKED reduce 820 - UNSAFE reduce 820 - USHORT reduce 820 - USING reduce 820 - VOID reduce 820 - WHILE reduce 820 - FROM reduce 820 - FROM_FIRST reduce 820 - OPEN_BRACE reduce 820 - CLOSE_BRACE reduce 820 - OPEN_PARENS reduce 820 - SEMICOLON reduce 820 - TILDE reduce 820 - PLUS reduce 820 - MINUS reduce 820 - BANG reduce 820 - BITWISE_AND reduce 820 - STAR reduce 820 - OP_INC reduce 820 - OP_DEC reduce 820 - LITERAL reduce 820 - IDENTIFIER reduce 820 - OPEN_PARENS_LAMBDA reduce 820 - OPEN_PARENS_CAST reduce 820 - DEFAULT_COLON reduce 820 - COMPLETE_COMPLETION reduce 820 - - catch_clause goto 743 - - -state 550 - catch_clauses : catch_clause . (824) - - . reduce 824 - - -state 551 - typeof_expression : TYPEOF $$63 open_parens_any . typeof_type_expression CLOSE_PARENS (545) - - error shift 744 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 253 - IDENTIFIER shift 745 - . error - - namespace_or_type_name goto 746 - type_expression_or_array goto 258 - member_name goto 36 - qualified_alias_member goto 747 - type_name goto 38 - type_and_void goto 748 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - typeof_type_expression goto 749 - unbound_type_name goto 750 - - -state 552 - unchecked_expression : UNCHECKED open_parens_any expression . CLOSE_PARENS (558) - - CLOSE_PARENS shift 751 - . error - - -state 553 - unsafe_statement : UNSAFE $$82 block . (837) - - . reduce 837 - - -state 554 - using_statement : USING open_parens_any expression . CLOSE_PARENS $$85 embedded_statement (848) - - CLOSE_PARENS shift 752 - . error - - -state 555 - using_statement : USING open_parens_any local_variable_declaration . CLOSE_PARENS $$84 embedded_statement (846) - - CLOSE_PARENS shift 753 - . error - - -state 556 - while_statement : WHILE open_parens_any boolean_expression . CLOSE_PARENS embedded_statement (785) - - CLOSE_PARENS shift 754 - . error - - -state 557 - nested_from_clause : FROM IDENTIFIER IN . expression (855) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 755 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 558 - nested_from_clause : FROM type IDENTIFIER . IN expression (856) - - IN shift 756 - . error - - -state 559 - first_from_clause : FROM_FIRST IDENTIFIER IN . expression (853) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 757 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 560 - first_from_clause : FROM_FIRST type IDENTIFIER . IN expression (854) - - IN shift 758 - . error - - -state 561 - block : OPEN_BRACE $$74 opt_statement_list . block_end (691) - - CLOSE_BRACE shift 759 - COMPLETE_COMPLETION shift 760 - . error - - block_end goto 761 - - -state 562 - opt_statement_list : statement_list . (697) - statement_list : statement_list . statement (699) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BREAK shift 98 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 101 - CONST shift 102 - CONTINUE shift 103 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DO shift 107 - DOUBLE shift 108 - FALSE shift 109 - FIXED shift 110 - FLOAT shift 111 - FOR shift 112 - FOREACH shift 113 - GOTO shift 114 - IF shift 115 - INT shift 116 - LOCK shift 117 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - RETURN shift 122 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - SWITCH shift 127 - THIS shift 128 - THROW shift 129 - TRUE shift 130 - TRY shift 131 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 135 - UNSAFE shift 136 - USHORT shift 137 - USING shift 138 - VOID shift 139 - WHILE shift 140 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 143 - OPEN_PARENS shift 144 - SEMICOLON shift 145 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 155 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - CLOSE_BRACE reduce 697 - COMPLETE_COMPLETION reduce 697 - - expression goto 304 - block goto 305 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - statement goto 762 - declaration_statement goto 564 - valid_declaration_statement goto 565 - labeled_statement goto 566 - empty_statement goto 309 - expression_statement goto 310 - selection_statement goto 311 - iteration_statement goto 312 - jump_statement goto 313 - try_statement goto 314 - checked_statement goto 315 - unchecked_statement goto 316 - lock_statement goto 317 - using_statement goto 318 - unsafe_statement goto 319 - fixed_statement goto 320 - local_variable_declaration goto 221 - local_constant_declaration goto 222 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - statement_expression goto 322 - if_statement goto 227 - switch_statement goto 228 - while_statement goto 229 - do_statement goto 230 - for_statement goto 231 - foreach_statement goto 232 - break_statement goto 233 - continue_statement goto 234 - goto_statement goto 235 - return_statement goto 236 - throw_statement goto 237 - yield_statement goto 238 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 563 - statement_list : statement . (698) - - . reduce 698 - - -state 564 - statement : declaration_statement . (700) - - . reduce 700 - - -state 565 - statement : valid_declaration_statement . (701) - - . reduce 701 - - -state 566 - statement : labeled_statement . (702) - - . reduce 702 - - -state 567 - parenthesized_expression : OPEN_PARENS expression CLOSE_PARENS . (450) - - . reduce 450 - - -state 568 - parenthesized_expression : OPEN_PARENS expression COMPLETE_COMPLETION . (451) - - . reduce 451 - - -state 569 - cast_expression : OPEN_PARENS builtin_types CLOSE_PARENS . prefixed_unary_expression (572) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 763 - cast_expression goto 188 - - -state 570 - yield_statement : IDENTIFIER BREAK SEMICOLON . (817) - - . reduce 817 - - -state 571 - yield_statement : IDENTIFIER RETURN opt_expression . SEMICOLON (816) - - SEMICOLON shift 764 - . error - - -state 572 - lambda_expression : IDENTIFIER ARROW $$67 . lambda_expression_body (637) - $$66 : . (633) - - OPEN_BRACE shift 143 - BASE reduce 633 - BOOL reduce 633 - BYTE reduce 633 - CHAR reduce 633 - CHECKED reduce 633 - DECIMAL reduce 633 - DEFAULT reduce 633 - DELEGATE reduce 633 - DOUBLE reduce 633 - FALSE reduce 633 - FLOAT reduce 633 - INT reduce 633 - LONG reduce 633 - NEW reduce 633 - NULL reduce 633 - OBJECT reduce 633 - SBYTE reduce 633 - SHORT reduce 633 - SIZEOF reduce 633 - STRING reduce 633 - THIS reduce 633 - TRUE reduce 633 - TYPEOF reduce 633 - UINT reduce 633 - ULONG reduce 633 - UNCHECKED reduce 633 - USHORT reduce 633 - FROM reduce 633 - FROM_FIRST reduce 633 - OPEN_PARENS reduce 633 - TILDE reduce 633 - PLUS reduce 633 - MINUS reduce 633 - BANG reduce 633 - BITWISE_AND reduce 633 - STAR reduce 633 - OP_INC reduce 633 - OP_DEC reduce 633 - LITERAL reduce 633 - IDENTIFIER reduce 633 - OPEN_PARENS_LAMBDA reduce 633 - OPEN_PARENS_CAST reduce 633 - - block goto 765 - lambda_expression_body goto 766 - $$66 goto 767 - - -state 573 - labeled_statement : IDENTIFIER COLON $$76 . statement (739) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BREAK shift 98 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 101 - CONST shift 102 - CONTINUE shift 103 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DO shift 107 - DOUBLE shift 108 - FALSE shift 109 - FIXED shift 110 - FLOAT shift 111 - FOR shift 112 - FOREACH shift 113 - GOTO shift 114 - IF shift 115 - INT shift 116 - LOCK shift 117 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - RETURN shift 122 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - SWITCH shift 127 - THIS shift 128 - THROW shift 129 - TRUE shift 130 - TRY shift 131 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 135 - UNSAFE shift 136 - USHORT shift 137 - USING shift 138 - VOID shift 139 - WHILE shift 140 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 143 - OPEN_PARENS shift 144 - SEMICOLON shift 145 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 155 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 304 - block goto 305 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - statement goto 768 - declaration_statement goto 564 - valid_declaration_statement goto 565 - labeled_statement goto 566 - empty_statement goto 309 - expression_statement goto 310 - selection_statement goto 311 - iteration_statement goto 312 - jump_statement goto 313 - try_statement goto 314 - checked_statement goto 315 - unchecked_statement goto 316 - lock_statement goto 317 - using_statement goto 318 - unsafe_statement goto 319 - fixed_statement goto 320 - local_variable_declaration goto 221 - local_constant_declaration goto 222 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - statement_expression goto 322 - if_statement goto 227 - switch_statement goto 228 - while_statement goto 229 - do_statement goto 230 - for_statement goto 231 - foreach_statement goto 232 - break_statement goto 233 - continue_statement goto 234 - goto_statement goto 235 - return_statement goto 236 - throw_statement goto 237 - yield_statement goto 238 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 574 - parameter_modifier : OUT . (209) - - . reduce 209 - - -state 575 - parameter_modifier : REF . (208) - - . reduce 208 - - -state 576 - parameter_modifier : THIS . (210) - - . reduce 210 - - -state 577 - parameter_type : VOID . (392) - type_expression : VOID . STAR (398) - - STAR shift 464 - error reduce 392 - IDENTIFIER reduce 392 - - -state 578 - type_name : IDENTIFIER . opt_type_argument_list (362) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - lambda_parameter : IDENTIFIER . (630) - opt_type_argument_list : . (363) - - OP_GENERICS_LT shift 81 - DOUBLE_COLON shift 83 - INTERR_NULLABLE reduce 363 - OPEN_BRACKET reduce 363 - CLOSE_PARENS reduce 630 - DOT reduce 363 - COMMA reduce 630 - STAR reduce 363 - IDENTIFIER reduce 363 - - opt_type_argument_list goto 84 - - -state 579 - lambda_parameter : parameter_type . IDENTIFIER (629) - - IDENTIFIER shift 769 - . error - - -state 580 - lambda_parameter : parameter_modifier . parameter_type IDENTIFIER (628) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 577 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - parameter_type goto 770 - type_expression_or_array goto 581 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 581 - parameter_type : type_expression_or_array . (391) - - . reduce 391 - - -state 582 - lambda_parameter_list : lambda_parameter_list . COMMA lambda_parameter (627) - opt_lambda_parameter_list : lambda_parameter_list . (632) - - COMMA shift 771 - CLOSE_PARENS reduce 632 - - -state 583 - lambda_parameter_list : lambda_parameter . (626) - - . reduce 626 - - -state 584 - lambda_expression : OPEN_PARENS_LAMBDA $$68 opt_lambda_parameter_list . CLOSE_PARENS ARROW $$69 lambda_expression_body (640) - - CLOSE_PARENS shift 772 - . error - - -state 585 - cast_expression : OPEN_PARENS_CAST type CLOSE_PARENS . prefixed_unary_expression (571) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 292 - OPEN_PARENS_CAST shift 157 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - unary_expression goto 186 - prefixed_unary_expression goto 773 - cast_expression goto 188 - - -state 586 - member_access : qualified_alias_member IDENTIFIER opt_type_argument_list . (455) - - . reduce 455 - - -state 587 - member_access : builtin_types DOT IDENTIFIER . opt_type_argument_list (453) - member_access : builtin_types DOT IDENTIFIER . GENERATE_COMPLETION (459) - opt_type_argument_list : . (363) - - OP_GENERICS_LT shift 81 - GENERATE_COMPLETION shift 774 - error reduce 363 - AS reduce 363 - IS reduce 363 - WHERE reduce 363 - FROM reduce 363 - JOIN reduce 363 - ON reduce 363 - EQUALS reduce 363 - SELECT reduce 363 - GROUP reduce 363 - BY reduce 363 - LET reduce 363 - ORDERBY reduce 363 - ASCENDING reduce 363 - DESCENDING reduce 363 - INTO reduce 363 - INTERR_NULLABLE reduce 363 - CLOSE_BRACE reduce 363 - OPEN_BRACKET reduce 363 - CLOSE_BRACKET reduce 363 - OPEN_PARENS reduce 363 - CLOSE_PARENS reduce 363 - DOT reduce 363 - COMMA reduce 363 - COLON reduce 363 - SEMICOLON reduce 363 - PLUS reduce 363 - MINUS reduce 363 - ASSIGN reduce 363 - OP_LT reduce 363 - OP_GT reduce 363 - BITWISE_AND reduce 363 - BITWISE_OR reduce 363 - STAR reduce 363 - PERCENT reduce 363 - DIV reduce 363 - CARRET reduce 363 - INTERR reduce 363 - OP_INC reduce 363 - OP_DEC reduce 363 - OP_SHIFT_LEFT reduce 363 - OP_SHIFT_RIGHT reduce 363 - OP_LE reduce 363 - OP_GE reduce 363 - OP_EQ reduce 363 - OP_NE reduce 363 - OP_AND reduce 363 - OP_OR reduce 363 - OP_MULT_ASSIGN reduce 363 - OP_DIV_ASSIGN reduce 363 - OP_MOD_ASSIGN reduce 363 - OP_ADD_ASSIGN reduce 363 - OP_SUB_ASSIGN reduce 363 - OP_SHIFT_LEFT_ASSIGN reduce 363 - OP_SHIFT_RIGHT_ASSIGN reduce 363 - OP_AND_ASSIGN reduce 363 - OP_XOR_ASSIGN reduce 363 - OP_OR_ASSIGN reduce 363 - OP_PTR reduce 363 - OP_COALESCING reduce 363 - IDENTIFIER reduce 363 - OPEN_PARENS_CAST reduce 363 - OPEN_BRACKET_EXPR reduce 363 - COMPLETE_COMPLETION reduce 363 - - opt_type_argument_list goto 775 - - -state 588 - member_access : builtin_types DOT GENERATE_COMPLETION . (458) - - . reduce 458 - - -state 589 - opt_rank_specifier_or_nullable : opt_nullable rank_specifiers . (530) - - . reduce 530 - - -state 590 - member_access : primary_expression DOT IDENTIFIER . opt_type_argument_list (452) - member_access : primary_expression DOT IDENTIFIER . GENERATE_COMPLETION (457) - opt_type_argument_list : . (363) - - OP_GENERICS_LT shift 81 - GENERATE_COMPLETION shift 776 - error reduce 363 - AS reduce 363 - IS reduce 363 - WHERE reduce 363 - FROM reduce 363 - JOIN reduce 363 - ON reduce 363 - EQUALS reduce 363 - SELECT reduce 363 - GROUP reduce 363 - BY reduce 363 - LET reduce 363 - ORDERBY reduce 363 - ASCENDING reduce 363 - DESCENDING reduce 363 - INTO reduce 363 - INTERR_NULLABLE reduce 363 - CLOSE_BRACE reduce 363 - OPEN_BRACKET reduce 363 - CLOSE_BRACKET reduce 363 - OPEN_PARENS reduce 363 - CLOSE_PARENS reduce 363 - DOT reduce 363 - COMMA reduce 363 - COLON reduce 363 - SEMICOLON reduce 363 - PLUS reduce 363 - MINUS reduce 363 - ASSIGN reduce 363 - OP_LT reduce 363 - OP_GT reduce 363 - BITWISE_AND reduce 363 - BITWISE_OR reduce 363 - STAR reduce 363 - PERCENT reduce 363 - DIV reduce 363 - CARRET reduce 363 - INTERR reduce 363 - OP_INC reduce 363 - OP_DEC reduce 363 - OP_SHIFT_LEFT reduce 363 - OP_SHIFT_RIGHT reduce 363 - OP_LE reduce 363 - OP_GE reduce 363 - OP_EQ reduce 363 - OP_NE reduce 363 - OP_AND reduce 363 - OP_OR reduce 363 - OP_MULT_ASSIGN reduce 363 - OP_DIV_ASSIGN reduce 363 - OP_MOD_ASSIGN reduce 363 - OP_ADD_ASSIGN reduce 363 - OP_SUB_ASSIGN reduce 363 - OP_SHIFT_LEFT_ASSIGN reduce 363 - OP_SHIFT_RIGHT_ASSIGN reduce 363 - OP_AND_ASSIGN reduce 363 - OP_XOR_ASSIGN reduce 363 - OP_OR_ASSIGN reduce 363 - OP_PTR reduce 363 - OP_COALESCING reduce 363 - IDENTIFIER reduce 363 - OPEN_PARENS_CAST reduce 363 - OPEN_BRACKET_EXPR reduce 363 - COMPLETE_COMPLETION reduce 363 - - opt_type_argument_list goto 777 - - -state 591 - member_access : primary_expression DOT GENERATE_COMPLETION . (456) - - . reduce 456 - - -state 592 - pointer_member_access : primary_expression OP_PTR IDENTIFIER . (559) - - . reduce 559 - - -state 593 - element_access : primary_expression OPEN_BRACKET_EXPR expression_list_arguments . CLOSE_BRACKET (494) - expression_list_arguments : expression_list_arguments . COMMA expression_list_argument (499) - - CLOSE_BRACKET shift 778 - COMMA shift 685 - . error - - -state 594 - non_simple_argument : OUT . variable_reference (489) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 779 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - variable_reference goto 780 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 595 - non_simple_argument : REF . variable_reference (488) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 779 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - variable_reference goto 781 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 596 - non_simple_argument : ARGLIST . OPEN_PARENS argument_list CLOSE_PARENS (490) - non_simple_argument : ARGLIST . OPEN_PARENS CLOSE_PARENS (491) - non_simple_argument : ARGLIST . (492) - - OPEN_PARENS shift 782 - CLOSE_PARENS reduce 492 - COMMA reduce 492 - COMPLETE_COMPLETION reduce 492 - - -state 597 - argument_list : COMMA . error (483) - - error shift 783 - . error - - -state 598 - argument : expression . (484) - - . reduce 484 - - -state 599 - argument_or_named_argument : named_argument . (487) - - . reduce 487 - - -state 600 - invocation_expression : primary_expression open_parens_any opt_argument_list . close_parens (460) - - CLOSE_PARENS shift 784 - COMPLETE_COMPLETION shift 785 - . error - - close_parens goto 786 - - -state 601 - opt_argument_list : argument_list . (478) - argument_list : argument_list . COMMA argument (480) - argument_list : argument_list . COMMA named_argument (481) - argument_list : argument_list . COMMA (482) - - COMMA shift 787 - CLOSE_PARENS reduce 478 - COMPLETE_COMPLETION reduce 478 - - -state 602 - argument_list : argument_or_named_argument . (479) - - . reduce 479 - - -state 603 - argument_or_named_argument : argument . (486) - - . reduce 486 - - -state 604 - argument : non_simple_argument . (485) - - . reduce 485 - - -state 605 - multiplicative_expression : prefixed_unary_expression . (580) - - . reduce 580 - - -state 606 - multiplicative_expression : multiplicative_expression . STAR prefixed_unary_expression (581) - multiplicative_expression : multiplicative_expression . DIV prefixed_unary_expression (582) - multiplicative_expression : multiplicative_expression . PERCENT prefixed_unary_expression (583) - additive_expression : parenthesized_expression MINUS multiplicative_expression . (587) - - STAR shift 404 - PERCENT shift 405 - DIV shift 406 - error reduce 587 - AS reduce 587 - IS reduce 587 - WHERE reduce 587 - FROM reduce 587 - JOIN reduce 587 - ON reduce 587 - EQUALS reduce 587 - SELECT reduce 587 - GROUP reduce 587 - BY reduce 587 - LET reduce 587 - ORDERBY reduce 587 - ASCENDING reduce 587 - DESCENDING reduce 587 - INTO reduce 587 - CLOSE_BRACE reduce 587 - CLOSE_BRACKET reduce 587 - CLOSE_PARENS reduce 587 - COMMA reduce 587 - COLON reduce 587 - SEMICOLON reduce 587 - PLUS reduce 587 - MINUS reduce 587 - OP_LT reduce 587 - OP_GT reduce 587 - BITWISE_AND reduce 587 - BITWISE_OR reduce 587 - CARRET reduce 587 - INTERR reduce 587 - OP_SHIFT_LEFT reduce 587 - OP_SHIFT_RIGHT reduce 587 - OP_LE reduce 587 - OP_GE reduce 587 - OP_EQ reduce 587 - OP_NE reduce 587 - OP_AND reduce 587 - OP_OR reduce 587 - OP_COALESCING reduce 587 - COMPLETE_COMPLETION reduce 587 - - -state 607 - assignment_expression : prefixed_unary_expression ASSIGN expression . (615) - - . reduce 615 - - -state 608 - assignment_expression : prefixed_unary_expression OP_MULT_ASSIGN expression . (616) - - . reduce 616 - - -state 609 - assignment_expression : prefixed_unary_expression OP_DIV_ASSIGN expression . (617) - - . reduce 617 - - -state 610 - assignment_expression : prefixed_unary_expression OP_MOD_ASSIGN expression . (618) - - . reduce 618 - - -state 611 - assignment_expression : prefixed_unary_expression OP_ADD_ASSIGN expression . (619) - - . reduce 619 - - -state 612 - assignment_expression : prefixed_unary_expression OP_SUB_ASSIGN expression . (620) - - . reduce 620 - - -state 613 - assignment_expression : prefixed_unary_expression OP_SHIFT_LEFT_ASSIGN expression . (621) - - . reduce 621 - - -state 614 - assignment_expression : prefixed_unary_expression OP_SHIFT_RIGHT_ASSIGN expression . (622) - - . reduce 622 - - -state 615 - assignment_expression : prefixed_unary_expression OP_AND_ASSIGN expression . (623) - - . reduce 623 - - -state 616 - assignment_expression : prefixed_unary_expression OP_XOR_ASSIGN expression . (625) - - . reduce 625 - - -state 617 - assignment_expression : prefixed_unary_expression OP_OR_ASSIGN expression . (624) - - . reduce 624 - - -state 618 - multiplicative_expression : multiplicative_expression STAR prefixed_unary_expression . (581) - - . reduce 581 - - -state 619 - multiplicative_expression : multiplicative_expression PERCENT prefixed_unary_expression . (583) - - . reduce 583 - - -state 620 - multiplicative_expression : multiplicative_expression DIV prefixed_unary_expression . (582) - - . reduce 582 - - -state 621 - additive_expression : additive_expression AS type . (588) - - . reduce 588 - - -state 622 - additive_expression : additive_expression IS type . (589) - - . reduce 589 - - -state 623 - multiplicative_expression : multiplicative_expression . STAR prefixed_unary_expression (581) - multiplicative_expression : multiplicative_expression . DIV prefixed_unary_expression (582) - multiplicative_expression : multiplicative_expression . PERCENT prefixed_unary_expression (583) - additive_expression : additive_expression PLUS multiplicative_expression . (585) - - STAR shift 404 - PERCENT shift 405 - DIV shift 406 - error reduce 585 - AS reduce 585 - IS reduce 585 - WHERE reduce 585 - FROM reduce 585 - JOIN reduce 585 - ON reduce 585 - EQUALS reduce 585 - SELECT reduce 585 - GROUP reduce 585 - BY reduce 585 - LET reduce 585 - ORDERBY reduce 585 - ASCENDING reduce 585 - DESCENDING reduce 585 - INTO reduce 585 - CLOSE_BRACE reduce 585 - CLOSE_BRACKET reduce 585 - CLOSE_PARENS reduce 585 - COMMA reduce 585 - COLON reduce 585 - SEMICOLON reduce 585 - PLUS reduce 585 - MINUS reduce 585 - OP_LT reduce 585 - OP_GT reduce 585 - BITWISE_AND reduce 585 - BITWISE_OR reduce 585 - CARRET reduce 585 - INTERR reduce 585 - OP_SHIFT_LEFT reduce 585 - OP_SHIFT_RIGHT reduce 585 - OP_LE reduce 585 - OP_GE reduce 585 - OP_EQ reduce 585 - OP_NE reduce 585 - OP_AND reduce 585 - OP_OR reduce 585 - OP_COALESCING reduce 585 - COMPLETE_COMPLETION reduce 585 - - -state 624 - multiplicative_expression : multiplicative_expression . STAR prefixed_unary_expression (581) - multiplicative_expression : multiplicative_expression . DIV prefixed_unary_expression (582) - multiplicative_expression : multiplicative_expression . PERCENT prefixed_unary_expression (583) - additive_expression : additive_expression MINUS multiplicative_expression . (586) - - STAR shift 404 - PERCENT shift 405 - DIV shift 406 - error reduce 586 - AS reduce 586 - IS reduce 586 - WHERE reduce 586 - FROM reduce 586 - JOIN reduce 586 - ON reduce 586 - EQUALS reduce 586 - SELECT reduce 586 - GROUP reduce 586 - BY reduce 586 - LET reduce 586 - ORDERBY reduce 586 - ASCENDING reduce 586 - DESCENDING reduce 586 - INTO reduce 586 - CLOSE_BRACE reduce 586 - CLOSE_BRACKET reduce 586 - CLOSE_PARENS reduce 586 - COMMA reduce 586 - COLON reduce 586 - SEMICOLON reduce 586 - PLUS reduce 586 - MINUS reduce 586 - OP_LT reduce 586 - OP_GT reduce 586 - BITWISE_AND reduce 586 - BITWISE_OR reduce 586 - CARRET reduce 586 - INTERR reduce 586 - OP_SHIFT_LEFT reduce 586 - OP_SHIFT_RIGHT reduce 586 - OP_LE reduce 586 - OP_GE reduce 586 - OP_EQ reduce 586 - OP_NE reduce 586 - OP_AND reduce 586 - OP_OR reduce 586 - OP_COALESCING reduce 586 - COMPLETE_COMPLETION reduce 586 - - -state 625 - additive_expression : additive_expression . PLUS multiplicative_expression (585) - additive_expression : additive_expression . MINUS multiplicative_expression (586) - additive_expression : additive_expression . AS type (588) - additive_expression : additive_expression . IS type (589) - shift_expression : shift_expression OP_SHIFT_LEFT additive_expression . (591) - - AS shift 407 - IS shift 408 - PLUS shift 409 - MINUS shift 410 - error reduce 591 - WHERE reduce 591 - FROM reduce 591 - JOIN reduce 591 - ON reduce 591 - EQUALS reduce 591 - SELECT reduce 591 - GROUP reduce 591 - BY reduce 591 - LET reduce 591 - ORDERBY reduce 591 - ASCENDING reduce 591 - DESCENDING reduce 591 - INTO reduce 591 - CLOSE_BRACE reduce 591 - CLOSE_BRACKET reduce 591 - CLOSE_PARENS reduce 591 - COMMA reduce 591 - COLON reduce 591 - SEMICOLON reduce 591 - OP_LT reduce 591 - OP_GT reduce 591 - BITWISE_AND reduce 591 - BITWISE_OR reduce 591 - CARRET reduce 591 - INTERR reduce 591 - OP_SHIFT_LEFT reduce 591 - OP_SHIFT_RIGHT reduce 591 - OP_LE reduce 591 - OP_GE reduce 591 - OP_EQ reduce 591 - OP_NE reduce 591 - OP_AND reduce 591 - OP_OR reduce 591 - OP_COALESCING reduce 591 - COMPLETE_COMPLETION reduce 591 - - -state 626 - additive_expression : additive_expression . PLUS multiplicative_expression (585) - additive_expression : additive_expression . MINUS multiplicative_expression (586) - additive_expression : additive_expression . AS type (588) - additive_expression : additive_expression . IS type (589) - shift_expression : shift_expression OP_SHIFT_RIGHT additive_expression . (592) - - AS shift 407 - IS shift 408 - PLUS shift 409 - MINUS shift 410 - error reduce 592 - WHERE reduce 592 - FROM reduce 592 - JOIN reduce 592 - ON reduce 592 - EQUALS reduce 592 - SELECT reduce 592 - GROUP reduce 592 - BY reduce 592 - LET reduce 592 - ORDERBY reduce 592 - ASCENDING reduce 592 - DESCENDING reduce 592 - INTO reduce 592 - CLOSE_BRACE reduce 592 - CLOSE_BRACKET reduce 592 - CLOSE_PARENS reduce 592 - COMMA reduce 592 - COLON reduce 592 - SEMICOLON reduce 592 - OP_LT reduce 592 - OP_GT reduce 592 - BITWISE_AND reduce 592 - BITWISE_OR reduce 592 - CARRET reduce 592 - INTERR reduce 592 - OP_SHIFT_LEFT reduce 592 - OP_SHIFT_RIGHT reduce 592 - OP_LE reduce 592 - OP_GE reduce 592 - OP_EQ reduce 592 - OP_NE reduce 592 - OP_AND reduce 592 - OP_OR reduce 592 - OP_COALESCING reduce 592 - COMPLETE_COMPLETION reduce 592 - - -state 627 - shift_expression : shift_expression . OP_SHIFT_LEFT additive_expression (591) - shift_expression : shift_expression . OP_SHIFT_RIGHT additive_expression (592) - relational_expression : relational_expression OP_LT shift_expression . (594) - - OP_SHIFT_LEFT shift 411 - OP_SHIFT_RIGHT shift 412 - error reduce 594 - WHERE reduce 594 - FROM reduce 594 - JOIN reduce 594 - ON reduce 594 - EQUALS reduce 594 - SELECT reduce 594 - GROUP reduce 594 - BY reduce 594 - LET reduce 594 - ORDERBY reduce 594 - ASCENDING reduce 594 - DESCENDING reduce 594 - INTO reduce 594 - CLOSE_BRACE reduce 594 - CLOSE_BRACKET reduce 594 - CLOSE_PARENS reduce 594 - COMMA reduce 594 - COLON reduce 594 - SEMICOLON reduce 594 - OP_LT reduce 594 - OP_GT reduce 594 - BITWISE_AND reduce 594 - BITWISE_OR reduce 594 - CARRET reduce 594 - INTERR reduce 594 - OP_LE reduce 594 - OP_GE reduce 594 - OP_EQ reduce 594 - OP_NE reduce 594 - OP_AND reduce 594 - OP_OR reduce 594 - OP_COALESCING reduce 594 - COMPLETE_COMPLETION reduce 594 - - -state 628 - shift_expression : shift_expression . OP_SHIFT_LEFT additive_expression (591) - shift_expression : shift_expression . OP_SHIFT_RIGHT additive_expression (592) - relational_expression : relational_expression OP_GT shift_expression . (595) - - OP_SHIFT_LEFT shift 411 - OP_SHIFT_RIGHT shift 412 - error reduce 595 - WHERE reduce 595 - FROM reduce 595 - JOIN reduce 595 - ON reduce 595 - EQUALS reduce 595 - SELECT reduce 595 - GROUP reduce 595 - BY reduce 595 - LET reduce 595 - ORDERBY reduce 595 - ASCENDING reduce 595 - DESCENDING reduce 595 - INTO reduce 595 - CLOSE_BRACE reduce 595 - CLOSE_BRACKET reduce 595 - CLOSE_PARENS reduce 595 - COMMA reduce 595 - COLON reduce 595 - SEMICOLON reduce 595 - OP_LT reduce 595 - OP_GT reduce 595 - BITWISE_AND reduce 595 - BITWISE_OR reduce 595 - CARRET reduce 595 - INTERR reduce 595 - OP_LE reduce 595 - OP_GE reduce 595 - OP_EQ reduce 595 - OP_NE reduce 595 - OP_AND reduce 595 - OP_OR reduce 595 - OP_COALESCING reduce 595 - COMPLETE_COMPLETION reduce 595 - - -state 629 - shift_expression : shift_expression . OP_SHIFT_LEFT additive_expression (591) - shift_expression : shift_expression . OP_SHIFT_RIGHT additive_expression (592) - relational_expression : relational_expression OP_LE shift_expression . (596) - - OP_SHIFT_LEFT shift 411 - OP_SHIFT_RIGHT shift 412 - error reduce 596 - WHERE reduce 596 - FROM reduce 596 - JOIN reduce 596 - ON reduce 596 - EQUALS reduce 596 - SELECT reduce 596 - GROUP reduce 596 - BY reduce 596 - LET reduce 596 - ORDERBY reduce 596 - ASCENDING reduce 596 - DESCENDING reduce 596 - INTO reduce 596 - CLOSE_BRACE reduce 596 - CLOSE_BRACKET reduce 596 - CLOSE_PARENS reduce 596 - COMMA reduce 596 - COLON reduce 596 - SEMICOLON reduce 596 - OP_LT reduce 596 - OP_GT reduce 596 - BITWISE_AND reduce 596 - BITWISE_OR reduce 596 - CARRET reduce 596 - INTERR reduce 596 - OP_LE reduce 596 - OP_GE reduce 596 - OP_EQ reduce 596 - OP_NE reduce 596 - OP_AND reduce 596 - OP_OR reduce 596 - OP_COALESCING reduce 596 - COMPLETE_COMPLETION reduce 596 - - -state 630 - shift_expression : shift_expression . OP_SHIFT_LEFT additive_expression (591) - shift_expression : shift_expression . OP_SHIFT_RIGHT additive_expression (592) - relational_expression : relational_expression OP_GE shift_expression . (597) - - OP_SHIFT_LEFT shift 411 - OP_SHIFT_RIGHT shift 412 - error reduce 597 - WHERE reduce 597 - FROM reduce 597 - JOIN reduce 597 - ON reduce 597 - EQUALS reduce 597 - SELECT reduce 597 - GROUP reduce 597 - BY reduce 597 - LET reduce 597 - ORDERBY reduce 597 - ASCENDING reduce 597 - DESCENDING reduce 597 - INTO reduce 597 - CLOSE_BRACE reduce 597 - CLOSE_BRACKET reduce 597 - CLOSE_PARENS reduce 597 - COMMA reduce 597 - COLON reduce 597 - SEMICOLON reduce 597 - OP_LT reduce 597 - OP_GT reduce 597 - BITWISE_AND reduce 597 - BITWISE_OR reduce 597 - CARRET reduce 597 - INTERR reduce 597 - OP_LE reduce 597 - OP_GE reduce 597 - OP_EQ reduce 597 - OP_NE reduce 597 - OP_AND reduce 597 - OP_OR reduce 597 - OP_COALESCING reduce 597 - COMPLETE_COMPLETION reduce 597 - - -state 631 - relational_expression : relational_expression . OP_LT shift_expression (594) - relational_expression : relational_expression . OP_GT shift_expression (595) - relational_expression : relational_expression . OP_LE shift_expression (596) - relational_expression : relational_expression . OP_GE shift_expression (597) - equality_expression : equality_expression OP_EQ relational_expression . (599) - - OP_LT shift 413 - OP_GT shift 414 - OP_LE shift 415 - OP_GE shift 416 - error reduce 599 - WHERE reduce 599 - FROM reduce 599 - JOIN reduce 599 - ON reduce 599 - EQUALS reduce 599 - SELECT reduce 599 - GROUP reduce 599 - BY reduce 599 - LET reduce 599 - ORDERBY reduce 599 - ASCENDING reduce 599 - DESCENDING reduce 599 - INTO reduce 599 - CLOSE_BRACE reduce 599 - CLOSE_BRACKET reduce 599 - CLOSE_PARENS reduce 599 - COMMA reduce 599 - COLON reduce 599 - SEMICOLON reduce 599 - BITWISE_AND reduce 599 - BITWISE_OR reduce 599 - CARRET reduce 599 - INTERR reduce 599 - OP_EQ reduce 599 - OP_NE reduce 599 - OP_AND reduce 599 - OP_OR reduce 599 - OP_COALESCING reduce 599 - COMPLETE_COMPLETION reduce 599 - - -state 632 - relational_expression : relational_expression . OP_LT shift_expression (594) - relational_expression : relational_expression . OP_GT shift_expression (595) - relational_expression : relational_expression . OP_LE shift_expression (596) - relational_expression : relational_expression . OP_GE shift_expression (597) - equality_expression : equality_expression OP_NE relational_expression . (600) - - OP_LT shift 413 - OP_GT shift 414 - OP_LE shift 415 - OP_GE shift 416 - error reduce 600 - WHERE reduce 600 - FROM reduce 600 - JOIN reduce 600 - ON reduce 600 - EQUALS reduce 600 - SELECT reduce 600 - GROUP reduce 600 - BY reduce 600 - LET reduce 600 - ORDERBY reduce 600 - ASCENDING reduce 600 - DESCENDING reduce 600 - INTO reduce 600 - CLOSE_BRACE reduce 600 - CLOSE_BRACKET reduce 600 - CLOSE_PARENS reduce 600 - COMMA reduce 600 - COLON reduce 600 - SEMICOLON reduce 600 - BITWISE_AND reduce 600 - BITWISE_OR reduce 600 - CARRET reduce 600 - INTERR reduce 600 - OP_EQ reduce 600 - OP_NE reduce 600 - OP_AND reduce 600 - OP_OR reduce 600 - OP_COALESCING reduce 600 - COMPLETE_COMPLETION reduce 600 - - -state 633 - equality_expression : equality_expression . OP_EQ relational_expression (599) - equality_expression : equality_expression . OP_NE relational_expression (600) - and_expression : and_expression BITWISE_AND equality_expression . (602) - - OP_EQ shift 417 - OP_NE shift 418 - error reduce 602 - WHERE reduce 602 - FROM reduce 602 - JOIN reduce 602 - ON reduce 602 - EQUALS reduce 602 - SELECT reduce 602 - GROUP reduce 602 - BY reduce 602 - LET reduce 602 - ORDERBY reduce 602 - ASCENDING reduce 602 - DESCENDING reduce 602 - INTO reduce 602 - CLOSE_BRACE reduce 602 - CLOSE_BRACKET reduce 602 - CLOSE_PARENS reduce 602 - COMMA reduce 602 - COLON reduce 602 - SEMICOLON reduce 602 - BITWISE_AND reduce 602 - BITWISE_OR reduce 602 - CARRET reduce 602 - INTERR reduce 602 - OP_AND reduce 602 - OP_OR reduce 602 - OP_COALESCING reduce 602 - COMPLETE_COMPLETION reduce 602 - - -state 634 - and_expression : and_expression . BITWISE_AND equality_expression (602) - exclusive_or_expression : exclusive_or_expression CARRET and_expression . (604) - - BITWISE_AND shift 419 - error reduce 604 - WHERE reduce 604 - FROM reduce 604 - JOIN reduce 604 - ON reduce 604 - EQUALS reduce 604 - SELECT reduce 604 - GROUP reduce 604 - BY reduce 604 - LET reduce 604 - ORDERBY reduce 604 - ASCENDING reduce 604 - DESCENDING reduce 604 - INTO reduce 604 - CLOSE_BRACE reduce 604 - CLOSE_BRACKET reduce 604 - CLOSE_PARENS reduce 604 - COMMA reduce 604 - COLON reduce 604 - SEMICOLON reduce 604 - BITWISE_OR reduce 604 - CARRET reduce 604 - INTERR reduce 604 - OP_AND reduce 604 - OP_OR reduce 604 - OP_COALESCING reduce 604 - COMPLETE_COMPLETION reduce 604 - - -state 635 - exclusive_or_expression : exclusive_or_expression . CARRET and_expression (604) - inclusive_or_expression : inclusive_or_expression BITWISE_OR exclusive_or_expression . (606) - - CARRET shift 420 - error reduce 606 - WHERE reduce 606 - FROM reduce 606 - JOIN reduce 606 - ON reduce 606 - EQUALS reduce 606 - SELECT reduce 606 - GROUP reduce 606 - BY reduce 606 - LET reduce 606 - ORDERBY reduce 606 - ASCENDING reduce 606 - DESCENDING reduce 606 - INTO reduce 606 - CLOSE_BRACE reduce 606 - CLOSE_BRACKET reduce 606 - CLOSE_PARENS reduce 606 - COMMA reduce 606 - COLON reduce 606 - SEMICOLON reduce 606 - BITWISE_OR reduce 606 - INTERR reduce 606 - OP_AND reduce 606 - OP_OR reduce 606 - OP_COALESCING reduce 606 - COMPLETE_COMPLETION reduce 606 - - -state 636 - inclusive_or_expression : inclusive_or_expression . BITWISE_OR exclusive_or_expression (606) - conditional_and_expression : conditional_and_expression OP_AND inclusive_or_expression . (608) - - BITWISE_OR shift 421 - error reduce 608 - WHERE reduce 608 - FROM reduce 608 - JOIN reduce 608 - ON reduce 608 - EQUALS reduce 608 - SELECT reduce 608 - GROUP reduce 608 - BY reduce 608 - LET reduce 608 - ORDERBY reduce 608 - ASCENDING reduce 608 - DESCENDING reduce 608 - INTO reduce 608 - CLOSE_BRACE reduce 608 - CLOSE_BRACKET reduce 608 - CLOSE_PARENS reduce 608 - COMMA reduce 608 - COLON reduce 608 - SEMICOLON reduce 608 - INTERR reduce 608 - OP_AND reduce 608 - OP_OR reduce 608 - OP_COALESCING reduce 608 - COMPLETE_COMPLETION reduce 608 - - -state 637 - conditional_and_expression : conditional_and_expression . OP_AND inclusive_or_expression (608) - conditional_or_expression : conditional_or_expression OP_OR conditional_and_expression . (610) - - OP_AND shift 422 - error reduce 610 - WHERE reduce 610 - FROM reduce 610 - JOIN reduce 610 - ON reduce 610 - EQUALS reduce 610 - SELECT reduce 610 - GROUP reduce 610 - BY reduce 610 - LET reduce 610 - ORDERBY reduce 610 - ASCENDING reduce 610 - DESCENDING reduce 610 - INTO reduce 610 - CLOSE_BRACE reduce 610 - CLOSE_BRACKET reduce 610 - CLOSE_PARENS reduce 610 - COMMA reduce 610 - COLON reduce 610 - SEMICOLON reduce 610 - INTERR reduce 610 - OP_OR reduce 610 - OP_COALESCING reduce 610 - COMPLETE_COMPLETION reduce 610 - - -state 638 - null_coalescing_expression : conditional_or_expression OP_COALESCING null_coalescing_expression . (612) - - . reduce 612 - - -state 639 - conditional_expression : null_coalescing_expression INTERR expression . COLON expression (614) - - COLON shift 788 - . error - - -state 640 - local_variable_declarator : IDENTIFIER ASSIGN . local_variable_initializer (164) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STACKALLOC shift 789 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - ARGLIST shift 790 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 531 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 791 - array_initializer goto 792 - local_variable_initializer goto 793 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 641 - variable_bad_array : OPEN_BRACKET_EXPR . opt_expression CLOSE_BRACKET (172) - opt_expression : . (818) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - CLOSE_BRACKET reduce 818 - - expression goto 338 - opt_expression goto 794 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 642 - local_variable_declarator : IDENTIFIER variable_bad_array . (166) - - . reduce 166 - - -state 643 - local_variable_declarators : local_variable_declarators COMMA . local_variable_declarator (163) - - IDENTIFIER shift 433 - . error - - local_variable_declarator goto 795 - - -state 644 - where_clause : WHERE $$92 . boolean_expression (880) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 518 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - boolean_expression goto 796 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 645 - type_name : IDENTIFIER . opt_type_argument_list (362) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - from_clause : FROM IDENTIFIER . IN $$86 expression (858) - opt_type_argument_list : . (363) - - IN shift 797 - OP_GENERICS_LT shift 81 - DOUBLE_COLON shift 83 - INTERR_NULLABLE reduce 363 - OPEN_BRACKET reduce 363 - DOT reduce 363 - STAR reduce 363 - IDENTIFIER reduce 363 - - opt_type_argument_list goto 84 - - -state 646 - from_clause : FROM type . IDENTIFIER IN $$87 expression (860) - - IDENTIFIER shift 798 - . error - - -state 647 - type_name : IDENTIFIER . opt_type_argument_list (362) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - join_clause : JOIN IDENTIFIER . IN $$93 expression ON $$94 expression EQUALS $$95 expression opt_join_into (884) - opt_type_argument_list : . (363) - - IN shift 799 - OP_GENERICS_LT shift 81 - DOUBLE_COLON shift 83 - INTERR_NULLABLE reduce 363 - OPEN_BRACKET reduce 363 - DOT reduce 363 - STAR reduce 363 - IDENTIFIER reduce 363 - - opt_type_argument_list goto 84 - - -state 648 - join_clause : JOIN type . IDENTIFIER IN $$96 expression ON $$97 expression EQUALS $$98 expression opt_join_into (888) - - IDENTIFIER shift 800 - . error - - -state 649 - let_clause : LET IDENTIFIER . ASSIGN $$91 expression (878) - - ASSIGN shift 801 - . error - - -state 650 - orderby_clause : ORDERBY $$99 . orderings (892) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 802 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - orderings goto 803 - order_by goto 804 - - -state 651 - select_or_group_clause : SELECT . $$88 expression (864) - $$88 : . (863) - - . reduce 863 - - $$88 goto 805 - - -state 652 - select_or_group_clause : GROUP . $$89 expression $$90 BY expression (867) - $$89 : . (865) - - . reduce 865 - - $$89 goto 806 - - -state 653 - query_body : opt_query_body_clauses COMPLETE_COMPLETION . (862) - - . reduce 862 - - -654: shift/reduce conflict (shift 807, reduce 905) on INTO -state 654 - query_body : opt_query_body_clauses select_or_group_clause . opt_query_continuation (861) - opt_query_continuation : . (905) - - INTO shift 807 - error reduce 905 - WHERE reduce 905 - FROM reduce 905 - JOIN reduce 905 - ON reduce 905 - EQUALS reduce 905 - SELECT reduce 905 - GROUP reduce 905 - BY reduce 905 - LET reduce 905 - ORDERBY reduce 905 - ASCENDING reduce 905 - DESCENDING reduce 905 - CLOSE_BRACE reduce 905 - CLOSE_BRACKET reduce 905 - CLOSE_PARENS reduce 905 - COMMA reduce 905 - COLON reduce 905 - SEMICOLON reduce 905 - COMPLETE_COMPLETION reduce 905 - - opt_query_continuation goto 808 - - -state 655 - query_body_clauses : query_body_clauses query_body_clause . (871) - - . reduce 871 - - -state 656 - qualified_identifier : qualified_identifier DOT IDENTIFIER . (28) - - . reduce 28 - - -state 657 - namespace_body : OPEN_BRACE . $$3 namespace_body_body (36) - $$3 : . (35) - - . reduce 35 - - $$3 goto 809 - - -state 658 - namespace_declaration : opt_attributes NAMESPACE qualified_identifier $$2 namespace_body . opt_semicolon (26) - opt_semicolon : . (30) - - SEMICOLON shift 810 - $end reduce 30 - EOF reduce 30 - ABSTRACT reduce 30 - BOOL reduce 30 - BYTE reduce 30 - CHAR reduce 30 - CLASS reduce 30 - DECIMAL reduce 30 - DELEGATE reduce 30 - DOUBLE reduce 30 - ENUM reduce 30 - EXTERN reduce 30 - FIXED reduce 30 - FLOAT reduce 30 - INT reduce 30 - INTERFACE reduce 30 - INTERNAL reduce 30 - LONG reduce 30 - NAMESPACE reduce 30 - NEW reduce 30 - OBJECT reduce 30 - OVERRIDE reduce 30 - PRIVATE reduce 30 - PROTECTED reduce 30 - PUBLIC reduce 30 - READONLY reduce 30 - SBYTE reduce 30 - SEALED reduce 30 - SHORT reduce 30 - STATIC reduce 30 - STRING reduce 30 - STRUCT reduce 30 - UINT reduce 30 - ULONG reduce 30 - UNSAFE reduce 30 - USHORT reduce 30 - USING reduce 30 - VIRTUAL reduce 30 - VOID reduce 30 - VOLATILE reduce 30 - PARTIAL reduce 30 - EXTERN_ALIAS reduce 30 - CLOSE_BRACE reduce 30 - OPEN_BRACKET reduce 30 - IDENTIFIER reduce 30 - - opt_semicolon goto 811 - - -state 659 - delegate_declaration : opt_attributes opt_modifiers DELEGATE member_type type_declaration_name . OPEN_PARENS $$58 opt_formal_parameter_list CLOSE_PARENS $$59 opt_type_parameter_constraints_clauses $$60 SEMICOLON (355) - - OPEN_PARENS shift 812 - . error - - -state 660 - type_declaration_name : IDENTIFIER $$61 . opt_type_parameter_list (369) - opt_type_parameter_list : . (378) - - OP_GENERICS_LT_DECL shift 813 - WHERE reduce 378 - OPEN_BRACE reduce 378 - OPEN_PARENS reduce 378 - COMMA reduce 378 - COLON reduce 378 - SEMICOLON reduce 378 - ASSIGN reduce 378 - - opt_type_parameter_list goto 814 - - -state 661 - opt_enum_base : COLON . type (342) - opt_enum_base : COLON . error (343) - - error shift 815 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 816 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 662 - enum_declaration : opt_attributes opt_modifiers ENUM type_declaration_name opt_enum_base . $$54 OPEN_BRACE $$55 opt_enum_member_declarations $$56 CLOSE_BRACE opt_semicolon (340) - $$54 : . (337) - - . reduce 337 - - $$54 goto 817 - - -state 663 - field_declaration : opt_attributes opt_modifiers FIXED simple_type error . SEMICOLON (143) - - SEMICOLON shift 818 - . error - - -state 664 - field_declaration : opt_attributes opt_modifiers FIXED simple_type IDENTIFIER . $$15 fixed_field_size opt_fixed_field_declarators SEMICOLON (142) - $$15 : . (141) - - . reduce 141 - - $$15 goto 819 - - -state 665 - type_declaration_name : IDENTIFIER . $$61 opt_type_parameter_list (369) - explicit_interface : IDENTIFIER . opt_type_argument_list DOT (375) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - opt_type_argument_list : . (363) - $$61 : . (368) - - OP_GENERICS_LT shift 81 - DOUBLE_COLON shift 83 - OP_GENERICS_LT_DECL reduce 368 - OPEN_BRACE reduce 368 - OPEN_PARENS reduce 368 - DOT reduce 363 - COMMA reduce 368 - SEMICOLON reduce 368 - ASSIGN reduce 368 - - opt_type_argument_list goto 673 - $$61 goto 660 - - -state 666 - method_header : opt_attributes opt_modifiers PARTIAL VOID method_declaration_name . OPEN_PARENS $$22 opt_formal_parameter_list CLOSE_PARENS $$23 opt_type_parameter_constraints_clauses (182) - - OPEN_PARENS shift 820 - . error - - -state 667 - class_declaration : opt_attributes opt_modifiers opt_partial CLASS $$70 . type_declaration_name $$71 opt_class_base opt_type_parameter_constraints_clauses $$72 OPEN_BRACE opt_class_member_declarations CLOSE_BRACE $$73 opt_semicolon (652) - - IDENTIFIER shift 459 - . error - - type_declaration_name goto 821 - - -state 668 - interface_declaration : opt_attributes opt_modifiers opt_partial INTERFACE error . (243) - - . reduce 243 - - -state 669 - interface_declaration : opt_attributes opt_modifiers opt_partial INTERFACE $$33 . type_declaration_name $$34 opt_class_base opt_type_parameter_constraints_clauses $$35 OPEN_BRACE opt_interface_member_declarations CLOSE_BRACE $$36 opt_semicolon (242) - - IDENTIFIER shift 459 - . error - - type_declaration_name goto 822 - - -state 670 - struct_declaration : opt_attributes opt_modifiers opt_partial STRUCT error . (110) - - . reduce 110 - - -state 671 - struct_declaration : opt_attributes opt_modifiers opt_partial STRUCT $$7 . type_declaration_name $$8 opt_class_base opt_type_parameter_constraints_clauses $$9 struct_body $$10 opt_semicolon (109) - - IDENTIFIER shift 459 - . error - - type_declaration_name goto 823 - - -state 672 - field_declaration : opt_attributes opt_modifiers member_type IDENTIFIER $$14 . opt_field_initializer opt_field_declarators SEMICOLON (140) - opt_field_initializer : . (144) - - ASSIGN shift 824 - COMMA reduce 144 - SEMICOLON reduce 144 - - opt_field_initializer goto 825 - - -state 673 - explicit_interface : IDENTIFIER opt_type_argument_list . DOT (375) - - DOT shift 826 - . error - - -state 674 - method_header : opt_attributes opt_modifiers member_type method_declaration_name OPEN_PARENS . $$20 opt_formal_parameter_list CLOSE_PARENS $$21 opt_type_parameter_constraints_clauses (179) - $$20 : . (177) - - . reduce 177 - - $$20 goto 827 - - -state 675 - method_header : opt_attributes opt_modifiers member_type modifiers method_declaration_name . OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS (183) - - OPEN_PARENS shift 828 - . error - - -state 676 - explicit_interface : qualified_alias_member IDENTIFIER . opt_type_argument_list DOT (376) - opt_type_argument_list : . (363) - - OP_GENERICS_LT shift 81 - DOT reduce 363 - - opt_type_argument_list goto 829 - - -state 677 - method_declaration_name : explicit_interface IDENTIFIER . opt_type_parameter_list (372) - explicit_interface : explicit_interface IDENTIFIER . opt_type_argument_list DOT (377) - opt_type_argument_list : . (363) - opt_type_parameter_list : . (378) - - OP_GENERICS_LT shift 81 - OP_GENERICS_LT_DECL shift 813 - OPEN_BRACE reduce 378 - OPEN_PARENS reduce 378 - DOT reduce 363 - COMMA reduce 378 - SEMICOLON reduce 378 - ASSIGN reduce 378 - - opt_type_argument_list goto 830 - opt_type_parameter_list goto 831 - - -state 678 - type_arguments : type_arguments COMMA type . (367) - - . reduce 367 - - -state 679 - named_argument : IDENTIFIER COLON . opt_named_modifier expression (86) - opt_named_modifier : . (87) - - OUT shift 832 - REF shift 833 - BASE reduce 87 - BOOL reduce 87 - BYTE reduce 87 - CHAR reduce 87 - CHECKED reduce 87 - DECIMAL reduce 87 - DEFAULT reduce 87 - DELEGATE reduce 87 - DOUBLE reduce 87 - FALSE reduce 87 - FLOAT reduce 87 - INT reduce 87 - LONG reduce 87 - NEW reduce 87 - NULL reduce 87 - OBJECT reduce 87 - SBYTE reduce 87 - SHORT reduce 87 - SIZEOF reduce 87 - STRING reduce 87 - THIS reduce 87 - TRUE reduce 87 - TYPEOF reduce 87 - UINT reduce 87 - ULONG reduce 87 - UNCHECKED reduce 87 - USHORT reduce 87 - FROM reduce 87 - FROM_FIRST reduce 87 - OPEN_PARENS reduce 87 - TILDE reduce 87 - PLUS reduce 87 - MINUS reduce 87 - BANG reduce 87 - BITWISE_AND reduce 87 - STAR reduce 87 - OP_INC reduce 87 - OP_DEC reduce 87 - LITERAL reduce 87 - IDENTIFIER reduce 87 - OPEN_PARENS_LAMBDA reduce 87 - OPEN_PARENS_CAST reduce 87 - - opt_named_modifier goto 834 - - -state 680 - named_attribute_argument : IDENTIFIER ASSIGN . $$6 expression (85) - $$6 : . (84) - - . reduce 84 - - $$6 goto 835 - - -state 681 - opt_attribute_arguments : OPEN_PARENS attribute_arguments CLOSE_PARENS . (76) - - . reduce 76 - - -state 682 - attribute_arguments : attribute_arguments COMMA . positional_or_named_argument (80) - attribute_arguments : attribute_arguments COMMA . named_attribute_argument (81) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 484 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - positional_or_named_argument goto 836 - named_attribute_argument goto 837 - expression goto 488 - named_argument goto 489 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 683 - member_access : BASE DOT IDENTIFIER opt_type_argument_list . (454) - - . reduce 454 - - -state 684 - base_access : BASE OPEN_BRACKET_EXPR expression_list_arguments CLOSE_BRACKET . (503) - - . reduce 503 - - -state 685 - expression_list_arguments : expression_list_arguments COMMA . expression_list_argument (499) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 492 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 493 - named_argument goto 494 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - expression_list_argument goto 838 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 686 - checked_expression : CHECKED open_parens_any expression CLOSE_PARENS . (557) - - . reduce 557 - - -state 687 - local_constant_declarator : IDENTIFIER error . (756) - - . reduce 756 - - -state 688 - local_constant_declarator : IDENTIFIER ASSIGN . constant_initializer_expr (755) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 531 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 514 - constant_initializer_expr goto 839 - constant_expression goto 840 - array_initializer goto 841 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 689 - local_constant_declarators : local_constant_declarators COMMA . local_constant_declarator (754) - - IDENTIFIER shift 498 - . error - - local_constant_declarator goto 842 - - -state 690 - default_value_expression : DEFAULT open_parens_any type CLOSE_PARENS . (566) - - . reduce 566 - - -state 691 - arglist_modifier : ARGLIST . (217) - - . reduce 217 - - -state 692 - fixed_parameter : opt_attributes . opt_parameter_modifier parameter_type IDENTIFIER (199) - fixed_parameter : opt_attributes . opt_parameter_modifier parameter_type IDENTIFIER OPEN_BRACKET CLOSE_BRACKET (200) - fixed_parameter : opt_attributes . opt_parameter_modifier parameter_type error (201) - fixed_parameter : opt_attributes . opt_parameter_modifier parameter_type IDENTIFIER ASSIGN $$24 constant_expression (203) - parameter_array : opt_attributes . params_modifier type IDENTIFIER (211) - parameter_array : opt_attributes . params_modifier type IDENTIFIER ASSIGN constant_expression (212) - parameter_array : opt_attributes . params_modifier type error (213) - opt_parameter_modifier : . (204) - - OUT shift 574 - PARAMS shift 843 - REF shift 575 - THIS shift 576 - BOOL reduce 204 - BYTE reduce 204 - CHAR reduce 204 - DECIMAL reduce 204 - DOUBLE reduce 204 - FLOAT reduce 204 - INT reduce 204 - LONG reduce 204 - OBJECT reduce 204 - SBYTE reduce 204 - SHORT reduce 204 - STRING reduce 204 - UINT reduce 204 - ULONG reduce 204 - USHORT reduce 204 - VOID reduce 204 - IDENTIFIER reduce 204 - - opt_parameter_modifier goto 844 - parameter_modifiers goto 845 - parameter_modifier goto 846 - params_modifier goto 847 - - -state 693 - opt_attributes : attribute_sections . (60) - attribute_sections : attribute_sections . attribute_section (62) - - OPEN_BRACKET shift 4 - ABSTRACT reduce 60 - ADD reduce 60 - BOOL reduce 60 - BYTE reduce 60 - CHAR reduce 60 - CLASS reduce 60 - CONST reduce 60 - DECIMAL reduce 60 - DELEGATE reduce 60 - DOUBLE reduce 60 - ENUM reduce 60 - EVENT reduce 60 - EXPLICIT reduce 60 - EXTERN reduce 60 - FIXED reduce 60 - FLOAT reduce 60 - IMPLICIT reduce 60 - IN reduce 60 - INT reduce 60 - INTERFACE reduce 60 - INTERNAL reduce 60 - LONG reduce 60 - NAMESPACE reduce 60 - NEW reduce 60 - OBJECT reduce 60 - OUT reduce 60 - OVERRIDE reduce 60 - PARAMS reduce 60 - PRIVATE reduce 60 - PROTECTED reduce 60 - PUBLIC reduce 60 - READONLY reduce 60 - REF reduce 60 - REMOVE reduce 60 - SBYTE reduce 60 - SEALED reduce 60 - SHORT reduce 60 - STATIC reduce 60 - STRING reduce 60 - STRUCT reduce 60 - THIS reduce 60 - UINT reduce 60 - ULONG reduce 60 - UNSAFE reduce 60 - USHORT reduce 60 - VIRTUAL reduce 60 - VOID reduce 60 - VOLATILE reduce 60 - PARTIAL reduce 60 - GET reduce 60 - SET reduce 60 - TILDE reduce 60 - IDENTIFIER reduce 60 - - attribute_section goto 79 - - -state 694 - anonymous_method_signature : OPEN_PARENS $$65 opt_formal_parameter_list . CLOSE_PARENS (565) - - CLOSE_PARENS shift 848 - . error - - -state 695 - opt_formal_parameter_list : formal_parameter_list . (187) - - . reduce 187 - - -state 696 - formal_parameter_list : fixed_parameters . (188) - formal_parameter_list : fixed_parameters . COMMA parameter_array (189) - formal_parameter_list : fixed_parameters . COMMA arglist_modifier (190) - formal_parameter_list : fixed_parameters . COMMA parameter_array COMMA error (192) - formal_parameter_list : fixed_parameters . COMMA ARGLIST COMMA error (194) - fixed_parameters : fixed_parameters . COMMA fixed_parameter (198) - - COMMA shift 849 - CLOSE_BRACKET reduce 188 - CLOSE_PARENS reduce 188 - - -state 697 - formal_parameter_list : parameter_array . COMMA error (191) - formal_parameter_list : parameter_array . (195) - - COMMA shift 850 - CLOSE_BRACKET reduce 195 - CLOSE_PARENS reduce 195 - - -state 698 - formal_parameter_list : arglist_modifier . COMMA error (193) - formal_parameter_list : arglist_modifier . (196) - - COMMA shift 851 - CLOSE_BRACKET reduce 196 - CLOSE_PARENS reduce 196 - - -state 699 - fixed_parameters : fixed_parameter . (197) - - . reduce 197 - - -state 700 - anonymous_method_expression : DELEGATE opt_anonymous_method_signature $$64 block . (561) - - . reduce 561 - - -state 701 - do_statement : DO embedded_statement WHILE open_parens_any . boolean_expression CLOSE_PARENS SEMICOLON (786) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 518 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - boolean_expression goto 852 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 702 - fixed_pointer_declarator : IDENTIFIER . ASSIGN expression (842) - fixed_pointer_declarator : IDENTIFIER . (843) - - ASSIGN shift 853 - CLOSE_PARENS reduce 843 - COMMA reduce 843 - - -state 703 - fixed_statement : FIXED open_parens_any type_and_void fixed_pointer_declarators . CLOSE_PARENS $$83 embedded_statement (839) - fixed_pointer_declarators : fixed_pointer_declarators . COMMA fixed_pointer_declarator (841) - - CLOSE_PARENS shift 854 - COMMA shift 855 - . error - - -state 704 - fixed_pointer_declarators : fixed_pointer_declarator . (840) - - . reduce 840 - - -state 705 - for_statement : FOR open_parens_any opt_for_initializer SEMICOLON . $$79 opt_for_condition SEMICOLON opt_for_iterator CLOSE_PARENS embedded_statement (788) - $$79 : . (787) - - . reduce 787 - - $$79 goto 856 - - -state 706 - statement_expression_list : statement_expression_list COMMA . statement_expression (799) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 304 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - statement_expression goto 857 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 707 - foreach_statement : FOREACH open_parens_any type IN . expression CLOSE_PARENS (800) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 858 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 708 - foreach_statement : FOREACH open_parens_any type IDENTIFIER . IN expression CLOSE_PARENS $$80 embedded_statement (802) - - IN shift 859 - . error - - -state 709 - goto_statement : GOTO CASE constant_expression SEMICOLON . (812) - - . reduce 812 - - -state 710 - if_statement : IF open_parens_any boolean_expression CLOSE_PARENS . embedded_statement (767) - if_statement : IF open_parens_any boolean_expression CLOSE_PARENS . embedded_statement ELSE embedded_statement (768) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BREAK shift 98 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 101 - CONST shift 102 - CONTINUE shift 103 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DO shift 107 - DOUBLE shift 108 - FALSE shift 109 - FIXED shift 110 - FLOAT shift 111 - FOR shift 112 - FOREACH shift 113 - GOTO shift 114 - IF shift 115 - INT shift 116 - LOCK shift 117 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - RETURN shift 122 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - SWITCH shift 127 - THIS shift 128 - THROW shift 129 - TRUE shift 130 - TRY shift 131 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 135 - UNSAFE shift 136 - USHORT shift 137 - USING shift 138 - VOID shift 139 - WHILE shift 140 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 143 - OPEN_PARENS shift 144 - SEMICOLON shift 145 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 155 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 304 - block goto 305 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - declaration_statement goto 306 - valid_declaration_statement goto 307 - labeled_statement goto 308 - empty_statement goto 309 - expression_statement goto 310 - selection_statement goto 311 - iteration_statement goto 312 - jump_statement goto 313 - try_statement goto 314 - checked_statement goto 315 - unchecked_statement goto 316 - lock_statement goto 317 - using_statement goto 318 - unsafe_statement goto 319 - fixed_statement goto 320 - embedded_statement goto 860 - local_variable_declaration goto 221 - local_constant_declaration goto 222 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - statement_expression goto 322 - if_statement goto 227 - switch_statement goto 228 - while_statement goto 229 - do_statement goto 230 - for_statement goto 231 - foreach_statement goto 232 - break_statement goto 233 - continue_statement goto 234 - goto_statement goto 235 - return_statement goto 236 - throw_statement goto 237 - yield_statement goto 238 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 711 - lock_statement : LOCK open_parens_any expression CLOSE_PARENS . embedded_statement (844) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BREAK shift 98 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 101 - CONST shift 102 - CONTINUE shift 103 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DO shift 107 - DOUBLE shift 108 - FALSE shift 109 - FIXED shift 110 - FLOAT shift 111 - FOR shift 112 - FOREACH shift 113 - GOTO shift 114 - IF shift 115 - INT shift 116 - LOCK shift 117 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - RETURN shift 122 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - SWITCH shift 127 - THIS shift 128 - THROW shift 129 - TRUE shift 130 - TRY shift 131 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 135 - UNSAFE shift 136 - USHORT shift 137 - USING shift 138 - VOID shift 139 - WHILE shift 140 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 143 - OPEN_PARENS shift 144 - SEMICOLON shift 145 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 155 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 304 - block goto 305 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - declaration_statement goto 306 - valid_declaration_statement goto 307 - labeled_statement goto 308 - empty_statement goto 309 - expression_statement goto 310 - selection_statement goto 311 - iteration_statement goto 312 - jump_statement goto 313 - try_statement goto 314 - checked_statement goto 315 - unchecked_statement goto 316 - lock_statement goto 317 - using_statement goto 318 - unsafe_statement goto 319 - fixed_statement goto 320 - embedded_statement goto 861 - local_variable_declaration goto 221 - local_constant_declaration goto 222 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - statement_expression goto 322 - if_statement goto 227 - switch_statement goto 228 - while_statement goto 229 - do_statement goto 230 - for_statement goto 231 - foreach_statement goto 232 - break_statement goto 233 - continue_statement goto 234 - goto_statement goto 235 - return_statement goto 236 - throw_statement goto 237 - yield_statement goto 238 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 712 - anonymous_type_parameter : IDENTIFIER ASSIGN . variable_initializer (523) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 531 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 719 - array_initializer goto 720 - variable_initializer goto 862 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 713 - anonymous_type_expression : NEW OPEN_BRACE anonymous_type_parameters_opt_comma CLOSE_BRACE . (516) - - . reduce 516 - - -state 714 - anonymous_type_parameters_opt_comma : anonymous_type_parameters COMMA . (518) - anonymous_type_parameters : anonymous_type_parameters COMMA . anonymous_type_parameter (522) - - error shift 521 - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - OPEN_PARENS shift 291 - LITERAL shift 154 - IDENTIFIER shift 522 - CLOSE_BRACE reduce 518 - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 294 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 296 - default_value_expression goto 168 - member_access goto 523 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - anonymous_type_parameter goto 863 - - -state 715 - rank_specifier : OPEN_BRACKET dim_separators CLOSE_BRACKET . (534) - - . reduce 534 - - -state 716 - dim_separators : dim_separators COMMA . (536) - - . reduce 536 - - -state 717 - variable_initializer_list : error . (543) - - . reduce 543 - - -state 718 - array_initializer : OPEN_BRACE CLOSE_BRACE . (539) - - . reduce 539 - - -state 719 - variable_initializer : expression . (173) - - . reduce 173 - - -state 720 - variable_initializer : array_initializer . (174) - - . reduce 174 - - -state 721 - variable_initializer_list : variable_initializer . (541) - - . reduce 541 - - -state 722 - array_initializer : OPEN_BRACE variable_initializer_list . opt_comma CLOSE_BRACE (540) - variable_initializer_list : variable_initializer_list . COMMA variable_initializer (542) - opt_comma : . (32) - - COMMA shift 864 - CLOSE_BRACE reduce 32 - - opt_comma goto 865 - - -state 723 - member_initializer : OPEN_BRACE . expression_list CLOSE_BRACE (473) - member_initializer : OPEN_BRACE . CLOSE_BRACE (474) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - CLOSE_BRACE shift 866 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 731 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - expression_list goto 867 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 724 - primary_expression_no_array_creation : IDENTIFIER . opt_type_argument_list (422) - primary_expression_no_array_creation : IDENTIFIER . GENERATE_COMPLETION (423) - member_initializer : IDENTIFIER . ASSIGN initializer_value (470) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - lambda_expression : IDENTIFIER . ARROW $$67 lambda_expression_body (637) - opt_type_argument_list : . (363) - - ARROW shift 372 - OP_GENERICS_LT shift 81 - ASSIGN shift 868 - DOUBLE_COLON shift 83 - GENERATE_COMPLETION shift 374 - error reduce 363 - AS reduce 363 - IS reduce 363 - CLOSE_BRACE reduce 363 - OPEN_PARENS reduce 363 - DOT reduce 363 - COMMA reduce 363 - PLUS reduce 363 - MINUS reduce 363 - OP_LT reduce 363 - OP_GT reduce 363 - BITWISE_AND reduce 363 - BITWISE_OR reduce 363 - STAR reduce 363 - PERCENT reduce 363 - DIV reduce 363 - CARRET reduce 363 - INTERR reduce 363 - OP_INC reduce 363 - OP_DEC reduce 363 - OP_SHIFT_LEFT reduce 363 - OP_SHIFT_RIGHT reduce 363 - OP_LE reduce 363 - OP_GE reduce 363 - OP_EQ reduce 363 - OP_NE reduce 363 - OP_AND reduce 363 - OP_OR reduce 363 - OP_PTR reduce 363 - OP_COALESCING reduce 363 - OPEN_PARENS_CAST reduce 363 - OPEN_BRACKET_EXPR reduce 363 - COMPLETE_COMPLETION reduce 363 - - opt_type_argument_list goto 375 - - -state 725 - member_initializer : GENERATE_COMPLETION . (471) - - . reduce 471 - - -state 726 - object_or_collection_initializer : OPEN_BRACE opt_member_initializer_list . close_brace_or_complete_completion (463) - - CLOSE_BRACE shift 869 - COMPLETE_COMPLETION shift 870 - . error - - close_brace_or_complete_completion goto 871 - - -state 727 - object_or_collection_initializer : OPEN_BRACE member_initializer_list . COMMA CLOSE_BRACE (464) - opt_member_initializer_list : member_initializer_list . (466) - member_initializer_list : member_initializer_list . COMMA member_initializer (468) - member_initializer_list : member_initializer_list . error (469) - - error shift 872 - COMMA shift 873 - CLOSE_BRACE reduce 466 - COMPLETE_COMPLETION reduce 466 - - -state 728 - member_initializer_list : member_initializer . (467) - - . reduce 467 - - -729: shift/reduce conflict (shift 426, reduce 918) on COMPLETE_COMPLETION -state 729 - member_initializer : non_assignment_expression . opt_COMPLETE_COMPLETION (472) - opt_COMPLETE_COMPLETION : . (918) - - COMPLETE_COMPLETION shift 426 - error reduce 918 - CLOSE_BRACE reduce 918 - COMMA reduce 918 - - opt_COMPLETE_COMPLETION goto 874 - - -730: shift/reduce conflict (shift 875, reduce 533) on OPEN_BRACKET_EXPR -state 730 - array_creation_expression : NEW new_expr_type OPEN_BRACKET CLOSE_BRACKET . OPEN_BRACKET_EXPR error CLOSE_BRACKET (512) - rank_specifier : OPEN_BRACKET CLOSE_BRACKET . (533) - - OPEN_BRACKET_EXPR shift 875 - error reduce 533 - AS reduce 533 - IS reduce 533 - WHERE reduce 533 - FROM reduce 533 - JOIN reduce 533 - ON reduce 533 - EQUALS reduce 533 - SELECT reduce 533 - GROUP reduce 533 - BY reduce 533 - LET reduce 533 - ORDERBY reduce 533 - ASCENDING reduce 533 - DESCENDING reduce 533 - INTO reduce 533 - OPEN_BRACE reduce 533 - CLOSE_BRACE reduce 533 - OPEN_BRACKET reduce 533 - CLOSE_BRACKET reduce 533 - OPEN_PARENS reduce 533 - CLOSE_PARENS reduce 533 - DOT reduce 533 - COMMA reduce 533 - COLON reduce 533 - SEMICOLON reduce 533 - PLUS reduce 533 - MINUS reduce 533 - ASSIGN reduce 533 - OP_LT reduce 533 - OP_GT reduce 533 - BITWISE_AND reduce 533 - BITWISE_OR reduce 533 - STAR reduce 533 - PERCENT reduce 533 - DIV reduce 533 - CARRET reduce 533 - INTERR reduce 533 - OP_INC reduce 533 - OP_DEC reduce 533 - OP_SHIFT_LEFT reduce 533 - OP_SHIFT_RIGHT reduce 533 - OP_LE reduce 533 - OP_GE reduce 533 - OP_EQ reduce 533 - OP_NE reduce 533 - OP_AND reduce 533 - OP_OR reduce 533 - OP_MULT_ASSIGN reduce 533 - OP_DIV_ASSIGN reduce 533 - OP_MOD_ASSIGN reduce 533 - OP_ADD_ASSIGN reduce 533 - OP_SUB_ASSIGN reduce 533 - OP_SHIFT_LEFT_ASSIGN reduce 533 - OP_SHIFT_RIGHT_ASSIGN reduce 533 - OP_AND_ASSIGN reduce 533 - OP_XOR_ASSIGN reduce 533 - OP_OR_ASSIGN reduce 533 - OP_PTR reduce 533 - OP_COALESCING reduce 533 - OPEN_PARENS_CAST reduce 533 - COMPLETE_COMPLETION reduce 533 - - -state 731 - expression_list : expression . (495) - - . reduce 495 - - -state 732 - expression_list : expression_list . COMMA expression (496) - expression_list : expression_list . error (497) - array_creation_expression : NEW new_expr_type OPEN_BRACKET_EXPR expression_list . CLOSE_BRACKET opt_rank_specifier opt_array_initializer (509) - - error shift 876 - CLOSE_BRACKET shift 877 - COMMA shift 878 - . error - - -state 733 - opt_array_initializer : array_initializer . (538) - - . reduce 538 - - -state 734 - array_creation_expression : NEW new_expr_type rank_specifiers opt_array_initializer . (510) - - . reduce 510 - - -state 735 - object_or_delegate_creation_expression : NEW new_expr_type open_parens_any opt_argument_list . CLOSE_PARENS opt_object_or_collection_initializer (507) - - CLOSE_PARENS shift 879 - . error - - -state 736 - sizeof_expression : SIZEOF open_parens_any type CLOSE_PARENS . (556) - - . reduce 556 - - -state 737 - switch_statement : SWITCH open_parens_any $$77 expression . CLOSE_PARENS OPEN_BRACE opt_switch_sections CLOSE_BRACE (770) - - CLOSE_PARENS shift 880 - . error - - -state 738 - catch_args : open_parens_any . type opt_identifier CLOSE_PARENS (832) - catch_args : open_parens_any . CLOSE_PARENS (833) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - CLOSE_PARENS shift 881 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 882 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 739 - catch_clause : CATCH opt_catch_args . $$81 block (829) - $$81 : . (828) - - . reduce 828 - - $$81 goto 883 - - -state 740 - opt_catch_args : catch_args . (831) - - . reduce 831 - - -state 741 - try_statement : TRY block FINALLY block . (821) - - . reduce 821 - - -state 742 - try_statement : TRY block catch_clauses FINALLY . block (822) - - OPEN_BRACE shift 143 - . error - - block goto 884 - - -state 743 - catch_clauses : catch_clauses catch_clause . (825) - - . reduce 825 - - -state 744 - typeof_type_expression : error . (548) - - . reduce 548 - - -state 745 - type_name : IDENTIFIER . opt_type_argument_list (362) - unbound_type_name : IDENTIFIER . generic_dimension (549) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - opt_type_argument_list : . (363) - - OP_GENERICS_LT shift 81 - DOUBLE_COLON shift 83 - GENERIC_DIMENSION shift 885 - INTERR_NULLABLE reduce 363 - OPEN_BRACKET reduce 363 - CLOSE_PARENS reduce 363 - DOT reduce 363 - STAR reduce 363 - - opt_type_argument_list goto 84 - generic_dimension goto 886 - - -state 746 - member_name : namespace_or_type_name . DOT IDENTIFIER opt_type_argument_list (361) - type_expression : namespace_or_type_name . opt_nullable (395) - unbound_type_name : namespace_or_type_name . DOT IDENTIFIER generic_dimension (553) - opt_nullable : . (356) - - INTERR_NULLABLE shift 379 - DOT shift 887 - OPEN_BRACKET reduce 356 - CLOSE_PARENS reduce 356 - STAR reduce 356 - - opt_nullable goto 466 - - -state 747 - namespace_or_type_name : qualified_alias_member . IDENTIFIER opt_type_argument_list (359) - unbound_type_name : qualified_alias_member . IDENTIFIER generic_dimension (550) - - IDENTIFIER shift 888 - . error - - -state 748 - typeof_type_expression : type_and_void . (546) - - . reduce 546 - - -state 749 - typeof_expression : TYPEOF $$63 open_parens_any typeof_type_expression . CLOSE_PARENS (545) - - CLOSE_PARENS shift 889 - . error - - -state 750 - typeof_type_expression : unbound_type_name . (547) - unbound_type_name : unbound_type_name . DOT IDENTIFIER (551) - unbound_type_name : unbound_type_name . DOT IDENTIFIER generic_dimension (552) - - DOT shift 890 - CLOSE_PARENS reduce 547 - - -state 751 - unchecked_expression : UNCHECKED open_parens_any expression CLOSE_PARENS . (558) - - . reduce 558 - - -state 752 - using_statement : USING open_parens_any expression CLOSE_PARENS . $$85 embedded_statement (848) - $$85 : . (847) - - . reduce 847 - - $$85 goto 891 - - -state 753 - using_statement : USING open_parens_any local_variable_declaration CLOSE_PARENS . $$84 embedded_statement (846) - $$84 : . (845) - - . reduce 845 - - $$84 goto 892 - - -state 754 - while_statement : WHILE open_parens_any boolean_expression CLOSE_PARENS . embedded_statement (785) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BREAK shift 98 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 101 - CONST shift 102 - CONTINUE shift 103 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DO shift 107 - DOUBLE shift 108 - FALSE shift 109 - FIXED shift 110 - FLOAT shift 111 - FOR shift 112 - FOREACH shift 113 - GOTO shift 114 - IF shift 115 - INT shift 116 - LOCK shift 117 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - RETURN shift 122 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - SWITCH shift 127 - THIS shift 128 - THROW shift 129 - TRUE shift 130 - TRY shift 131 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 135 - UNSAFE shift 136 - USHORT shift 137 - USING shift 138 - VOID shift 139 - WHILE shift 140 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 143 - OPEN_PARENS shift 144 - SEMICOLON shift 145 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 155 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 304 - block goto 305 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - declaration_statement goto 306 - valid_declaration_statement goto 307 - labeled_statement goto 308 - empty_statement goto 309 - expression_statement goto 310 - selection_statement goto 311 - iteration_statement goto 312 - jump_statement goto 313 - try_statement goto 314 - checked_statement goto 315 - unchecked_statement goto 316 - lock_statement goto 317 - using_statement goto 318 - unsafe_statement goto 319 - fixed_statement goto 320 - embedded_statement goto 893 - local_variable_declaration goto 221 - local_constant_declaration goto 222 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - statement_expression goto 322 - if_statement goto 227 - switch_statement goto 228 - while_statement goto 229 - do_statement goto 230 - for_statement goto 231 - foreach_statement goto 232 - break_statement goto 233 - continue_statement goto 234 - goto_statement goto 235 - return_statement goto 236 - throw_statement goto 237 - yield_statement goto 238 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 755 - nested_from_clause : FROM IDENTIFIER IN expression . (855) - - . reduce 855 - - -state 756 - nested_from_clause : FROM type IDENTIFIER IN . expression (856) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 894 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 757 - first_from_clause : FROM_FIRST IDENTIFIER IN expression . (853) - - . reduce 853 - - -state 758 - first_from_clause : FROM_FIRST type IDENTIFIER IN . expression (854) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 895 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 759 - block_end : CLOSE_BRACE . (692) - - . reduce 692 - - -state 760 - block_end : COMPLETE_COMPLETION . (693) - - . reduce 693 - - -state 761 - block : OPEN_BRACE $$74 opt_statement_list block_end . (691) - - . reduce 691 - - -state 762 - statement_list : statement_list statement . (699) - - . reduce 699 - - -state 763 - cast_expression : OPEN_PARENS builtin_types CLOSE_PARENS prefixed_unary_expression . (572) - - . reduce 572 - - -state 764 - yield_statement : IDENTIFIER RETURN opt_expression SEMICOLON . (816) - - . reduce 816 - - -state 765 - lambda_expression_body : block . (635) - - . reduce 635 - - -state 766 - lambda_expression : IDENTIFIER ARROW $$67 lambda_expression_body . (637) - - . reduce 637 - - -state 767 - lambda_expression_body : $$66 . expression (634) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 896 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 768 - labeled_statement : IDENTIFIER COLON $$76 statement . (739) - - . reduce 739 - - -state 769 - lambda_parameter : parameter_type IDENTIFIER . (629) - - . reduce 629 - - -state 770 - lambda_parameter : parameter_modifier parameter_type . IDENTIFIER (628) - - IDENTIFIER shift 897 - . error - - -state 771 - lambda_parameter_list : lambda_parameter_list COMMA . lambda_parameter (627) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - OUT shift 574 - REF shift 575 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - THIS shift 576 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 577 - IDENTIFIER shift 578 - . error - - namespace_or_type_name goto 255 - parameter_type goto 579 - parameter_modifier goto 580 - type_expression_or_array goto 581 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - lambda_parameter goto 898 - - -state 772 - lambda_expression : OPEN_PARENS_LAMBDA $$68 opt_lambda_parameter_list CLOSE_PARENS . ARROW $$69 lambda_expression_body (640) - - ARROW shift 899 - . error - - -state 773 - cast_expression : OPEN_PARENS_CAST type CLOSE_PARENS prefixed_unary_expression . (571) - - . reduce 571 - - -state 774 - member_access : builtin_types DOT IDENTIFIER GENERATE_COMPLETION . (459) - - . reduce 459 - - -state 775 - member_access : builtin_types DOT IDENTIFIER opt_type_argument_list . (453) - - . reduce 453 - - -state 776 - member_access : primary_expression DOT IDENTIFIER GENERATE_COMPLETION . (457) - - . reduce 457 - - -state 777 - member_access : primary_expression DOT IDENTIFIER opt_type_argument_list . (452) - - . reduce 452 - - -state 778 - element_access : primary_expression OPEN_BRACKET_EXPR expression_list_arguments CLOSE_BRACKET . (494) - - . reduce 494 - - -state 779 - variable_reference : expression . (493) - - . reduce 493 - - -state 780 - non_simple_argument : OUT variable_reference . (489) - - . reduce 489 - - -state 781 - non_simple_argument : REF variable_reference . (488) - - . reduce 488 - - -state 782 - non_simple_argument : ARGLIST OPEN_PARENS . argument_list CLOSE_PARENS (490) - non_simple_argument : ARGLIST OPEN_PARENS . CLOSE_PARENS (491) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - OUT shift 594 - REF shift 595 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - ARGLIST shift 596 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - CLOSE_PARENS shift 900 - COMMA shift 597 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 492 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 598 - named_argument goto 599 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - argument_list goto 901 - argument_or_named_argument goto 602 - argument goto 603 - non_simple_argument goto 604 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 783 - argument_list : COMMA error . (483) - - . reduce 483 - - -state 784 - close_parens : CLOSE_PARENS . (448) - - . reduce 448 - - -state 785 - close_parens : COMPLETE_COMPLETION . (449) - - . reduce 449 - - -state 786 - invocation_expression : primary_expression open_parens_any opt_argument_list close_parens . (460) - - . reduce 460 - - -state 787 - argument_list : argument_list COMMA . argument (480) - argument_list : argument_list COMMA . named_argument (481) - argument_list : argument_list COMMA . (482) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - OUT shift 594 - REF shift 595 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - ARGLIST shift 596 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 492 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - CLOSE_PARENS reduce 482 - COMMA reduce 482 - COMPLETE_COMPLETION reduce 482 - - expression goto 598 - named_argument goto 902 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - argument goto 903 - non_simple_argument goto 604 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 788 - conditional_expression : null_coalescing_expression INTERR expression COLON . expression (614) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 904 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 789 - local_variable_initializer : STACKALLOC . simple_type OPEN_BRACKET_EXPR expression CLOSE_BRACKET (169) - local_variable_initializer : STACKALLOC . simple_type (171) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 461 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - simple_type goto 905 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 463 - builtin_types goto 261 - integral_type goto 162 - - -state 790 - local_variable_initializer : ARGLIST . (170) - - . reduce 170 - - -state 791 - local_variable_initializer : expression . (167) - - . reduce 167 - - -state 792 - local_variable_initializer : array_initializer . (168) - - . reduce 168 - - -state 793 - local_variable_declarator : IDENTIFIER ASSIGN local_variable_initializer . (164) - - . reduce 164 - - -state 794 - variable_bad_array : OPEN_BRACKET_EXPR opt_expression . CLOSE_BRACKET (172) - - CLOSE_BRACKET shift 906 - . error - - -state 795 - local_variable_declarators : local_variable_declarators COMMA local_variable_declarator . (163) - - . reduce 163 - - -state 796 - where_clause : WHERE $$92 boolean_expression . (880) - - . reduce 880 - - -state 797 - from_clause : FROM IDENTIFIER IN . $$86 expression (858) - $$86 : . (857) - - . reduce 857 - - $$86 goto 907 - - -state 798 - from_clause : FROM type IDENTIFIER . IN $$87 expression (860) - - IN shift 908 - . error - - -state 799 - join_clause : JOIN IDENTIFIER IN . $$93 expression ON $$94 expression EQUALS $$95 expression opt_join_into (884) - $$93 : . (881) - - . reduce 881 - - $$93 goto 909 - - -state 800 - join_clause : JOIN type IDENTIFIER . IN $$96 expression ON $$97 expression EQUALS $$98 expression opt_join_into (888) - - IN shift 910 - . error - - -state 801 - let_clause : LET IDENTIFIER ASSIGN . $$91 expression (878) - $$91 : . (877) - - . reduce 877 - - $$91 goto 911 - - -state 802 - order_by : expression . (899) - order_by : expression . ASCENDING (900) - order_by : expression . DESCENDING (901) - - ASCENDING shift 912 - DESCENDING shift 913 - WHERE reduce 899 - FROM reduce 899 - JOIN reduce 899 - SELECT reduce 899 - GROUP reduce 899 - LET reduce 899 - ORDERBY reduce 899 - COMMA reduce 899 - COMPLETE_COMPLETION reduce 899 - - -state 803 - orderby_clause : ORDERBY $$99 orderings . (892) - - . reduce 892 - - -state 804 - orderings : order_by . (893) - orderings : order_by . COMMA $$100 orderings_then_by (895) - - COMMA shift 914 - WHERE reduce 893 - FROM reduce 893 - JOIN reduce 893 - SELECT reduce 893 - GROUP reduce 893 - LET reduce 893 - ORDERBY reduce 893 - COMPLETE_COMPLETION reduce 893 - - -state 805 - select_or_group_clause : SELECT $$88 . expression (864) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 915 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 806 - select_or_group_clause : GROUP $$89 . expression $$90 BY expression (867) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 916 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 807 - opt_query_continuation : INTO . IDENTIFIER $$102 query_body (907) - - IDENTIFIER shift 917 - . error - - -state 808 - query_body : opt_query_body_clauses select_or_group_clause opt_query_continuation . (861) - - . reduce 861 - - -state 809 - namespace_body : OPEN_BRACE $$3 . namespace_body_body (36) - opt_extern_alias_directives : . (43) - - error shift 918 - EXTERN_ALIAS shift 3 - EOF reduce 43 - ABSTRACT reduce 43 - BOOL reduce 43 - BYTE reduce 43 - CHAR reduce 43 - CLASS reduce 43 - DECIMAL reduce 43 - DELEGATE reduce 43 - DOUBLE reduce 43 - ENUM reduce 43 - EXTERN reduce 43 - FIXED reduce 43 - FLOAT reduce 43 - INT reduce 43 - INTERFACE reduce 43 - INTERNAL reduce 43 - LONG reduce 43 - NAMESPACE reduce 43 - NEW reduce 43 - OBJECT reduce 43 - OVERRIDE reduce 43 - PRIVATE reduce 43 - PROTECTED reduce 43 - PUBLIC reduce 43 - READONLY reduce 43 - SBYTE reduce 43 - SEALED reduce 43 - SHORT reduce 43 - STATIC reduce 43 - STRING reduce 43 - STRUCT reduce 43 - UINT reduce 43 - ULONG reduce 43 - UNSAFE reduce 43 - USHORT reduce 43 - USING reduce 43 - VIRTUAL reduce 43 - VOID reduce 43 - VOLATILE reduce 43 - PARTIAL reduce 43 - CLOSE_BRACE reduce 43 - OPEN_BRACKET reduce 43 - IDENTIFIER reduce 43 - - extern_alias_directive goto 919 - extern_alias_directives goto 920 - namespace_body_body goto 921 - opt_extern_alias_directives goto 922 - - -state 810 - opt_semicolon : SEMICOLON . (31) - - . reduce 31 - - -state 811 - namespace_declaration : opt_attributes NAMESPACE qualified_identifier $$2 namespace_body opt_semicolon . (26) - - . reduce 26 - - -state 812 - delegate_declaration : opt_attributes opt_modifiers DELEGATE member_type type_declaration_name OPEN_PARENS . $$58 opt_formal_parameter_list CLOSE_PARENS $$59 opt_type_parameter_constraints_clauses $$60 SEMICOLON (355) - $$58 : . (352) - - . reduce 352 - - $$58 goto 923 - - -state 813 - opt_type_parameter_list : OP_GENERICS_LT_DECL . type_parameters OP_GENERICS_GT (379) - opt_attributes : . (59) - - error shift 924 - OPEN_BRACKET shift 4 - IN reduce 59 - OUT reduce 59 - IDENTIFIER reduce 59 - - opt_attributes goto 925 - attribute_sections goto 693 - attribute_section goto 30 - type_parameters goto 926 - type_parameter goto 927 - - -state 814 - type_declaration_name : IDENTIFIER $$61 opt_type_parameter_list . (369) - - . reduce 369 - - -state 815 - opt_enum_base : COLON error . (343) - - . reduce 343 - - -state 816 - opt_enum_base : COLON type . (342) - - . reduce 342 - - -state 817 - enum_declaration : opt_attributes opt_modifiers ENUM type_declaration_name opt_enum_base $$54 . OPEN_BRACE $$55 opt_enum_member_declarations $$56 CLOSE_BRACE opt_semicolon (340) - - OPEN_BRACE shift 928 - . error - - -state 818 - field_declaration : opt_attributes opt_modifiers FIXED simple_type error SEMICOLON . (143) - - . reduce 143 - - -state 819 - field_declaration : opt_attributes opt_modifiers FIXED simple_type IDENTIFIER $$15 . fixed_field_size opt_fixed_field_declarators SEMICOLON (142) - - OPEN_BRACKET shift 929 - . error - - fixed_field_size goto 930 - - -state 820 - method_header : opt_attributes opt_modifiers PARTIAL VOID method_declaration_name OPEN_PARENS . $$22 opt_formal_parameter_list CLOSE_PARENS $$23 opt_type_parameter_constraints_clauses (182) - $$22 : . (180) - - . reduce 180 - - $$22 goto 931 - - -state 821 - class_declaration : opt_attributes opt_modifiers opt_partial CLASS $$70 type_declaration_name . $$71 opt_class_base opt_type_parameter_constraints_clauses $$72 OPEN_BRACE opt_class_member_declarations CLOSE_BRACE $$73 opt_semicolon (652) - $$71 : . (649) - - . reduce 649 - - $$71 goto 932 - - -state 822 - interface_declaration : opt_attributes opt_modifiers opt_partial INTERFACE $$33 type_declaration_name . $$34 opt_class_base opt_type_parameter_constraints_clauses $$35 OPEN_BRACE opt_interface_member_declarations CLOSE_BRACE $$36 opt_semicolon (242) - $$34 : . (239) - - . reduce 239 - - $$34 goto 933 - - -state 823 - struct_declaration : opt_attributes opt_modifiers opt_partial STRUCT $$7 type_declaration_name . $$8 opt_class_base opt_type_parameter_constraints_clauses $$9 struct_body $$10 opt_semicolon (109) - $$8 : . (106) - - . reduce 106 - - $$8 goto 934 - - -state 824 - opt_field_initializer : ASSIGN . $$16 variable_initializer (146) - $$16 : . (145) - - . reduce 145 - - $$16 goto 935 - - -state 825 - field_declaration : opt_attributes opt_modifiers member_type IDENTIFIER $$14 opt_field_initializer . opt_field_declarators SEMICOLON (140) - opt_field_declarators : . (147) - - COMMA shift 936 - SEMICOLON reduce 147 - - opt_field_declarators goto 937 - field_declarators goto 938 - field_declarator goto 939 - - -state 826 - explicit_interface : IDENTIFIER opt_type_argument_list DOT . (375) - - . reduce 375 - - -state 827 - method_header : opt_attributes opt_modifiers member_type method_declaration_name OPEN_PARENS $$20 . opt_formal_parameter_list CLOSE_PARENS $$21 opt_type_parameter_constraints_clauses (179) - opt_attributes : . (59) - opt_formal_parameter_list : . (186) - - ARGLIST shift 691 - OPEN_BRACKET shift 4 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - DECIMAL reduce 59 - DOUBLE reduce 59 - FLOAT reduce 59 - INT reduce 59 - LONG reduce 59 - OBJECT reduce 59 - OUT reduce 59 - PARAMS reduce 59 - REF reduce 59 - SBYTE reduce 59 - SHORT reduce 59 - STRING reduce 59 - THIS reduce 59 - UINT reduce 59 - ULONG reduce 59 - USHORT reduce 59 - VOID reduce 59 - CLOSE_PARENS reduce 186 - IDENTIFIER reduce 59 - - opt_attributes goto 692 - attribute_sections goto 693 - attribute_section goto 30 - opt_formal_parameter_list goto 940 - formal_parameter_list goto 695 - fixed_parameters goto 696 - parameter_array goto 697 - arglist_modifier goto 698 - fixed_parameter goto 699 - - -state 828 - method_header : opt_attributes opt_modifiers member_type modifiers method_declaration_name OPEN_PARENS . opt_formal_parameter_list CLOSE_PARENS (183) - opt_attributes : . (59) - opt_formal_parameter_list : . (186) - - ARGLIST shift 691 - OPEN_BRACKET shift 4 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - DECIMAL reduce 59 - DOUBLE reduce 59 - FLOAT reduce 59 - INT reduce 59 - LONG reduce 59 - OBJECT reduce 59 - OUT reduce 59 - PARAMS reduce 59 - REF reduce 59 - SBYTE reduce 59 - SHORT reduce 59 - STRING reduce 59 - THIS reduce 59 - UINT reduce 59 - ULONG reduce 59 - USHORT reduce 59 - VOID reduce 59 - CLOSE_PARENS reduce 186 - IDENTIFIER reduce 59 - - opt_attributes goto 692 - attribute_sections goto 693 - attribute_section goto 30 - opt_formal_parameter_list goto 941 - formal_parameter_list goto 695 - fixed_parameters goto 696 - parameter_array goto 697 - arglist_modifier goto 698 - fixed_parameter goto 699 - - -state 829 - explicit_interface : qualified_alias_member IDENTIFIER opt_type_argument_list . DOT (376) - - DOT shift 942 - . error - - -state 830 - explicit_interface : explicit_interface IDENTIFIER opt_type_argument_list . DOT (377) - - DOT shift 943 - . error - - -state 831 - method_declaration_name : explicit_interface IDENTIFIER opt_type_parameter_list . (372) - - . reduce 372 - - -state 832 - opt_named_modifier : OUT . (89) - - . reduce 89 - - -state 833 - opt_named_modifier : REF . (88) - - . reduce 88 - - -state 834 - named_argument : IDENTIFIER COLON opt_named_modifier . expression (86) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 944 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 835 - named_attribute_argument : IDENTIFIER ASSIGN $$6 . expression (85) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 945 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 836 - attribute_arguments : attribute_arguments COMMA positional_or_named_argument . (80) - - . reduce 80 - - -state 837 - attribute_arguments : attribute_arguments COMMA named_attribute_argument . (81) - - . reduce 81 - - -state 838 - expression_list_arguments : expression_list_arguments COMMA expression_list_argument . (499) - - . reduce 499 - - -state 839 - local_constant_declarator : IDENTIFIER ASSIGN constant_initializer_expr . (755) - - . reduce 755 - - -state 840 - constant_initializer_expr : constant_expression . (137) - - . reduce 137 - - -state 841 - constant_initializer_expr : array_initializer . (138) - - . reduce 138 - - -state 842 - local_constant_declarators : local_constant_declarators COMMA local_constant_declarator . (754) - - . reduce 754 - - -state 843 - params_modifier : PARAMS . (214) - params_modifier : PARAMS . parameter_modifier (215) - params_modifier : PARAMS . params_modifier (216) - - OUT shift 574 - PARAMS shift 843 - REF shift 575 - THIS shift 576 - BOOL reduce 214 - BYTE reduce 214 - CHAR reduce 214 - DECIMAL reduce 214 - DOUBLE reduce 214 - FLOAT reduce 214 - INT reduce 214 - LONG reduce 214 - OBJECT reduce 214 - SBYTE reduce 214 - SHORT reduce 214 - STRING reduce 214 - UINT reduce 214 - ULONG reduce 214 - USHORT reduce 214 - VOID reduce 214 - IDENTIFIER reduce 214 - - parameter_modifier goto 946 - params_modifier goto 947 - - -state 844 - fixed_parameter : opt_attributes opt_parameter_modifier . parameter_type IDENTIFIER (199) - fixed_parameter : opt_attributes opt_parameter_modifier . parameter_type IDENTIFIER OPEN_BRACKET CLOSE_BRACKET (200) - fixed_parameter : opt_attributes opt_parameter_modifier . parameter_type error (201) - fixed_parameter : opt_attributes opt_parameter_modifier . parameter_type IDENTIFIER ASSIGN $$24 constant_expression (203) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 577 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - parameter_type goto 948 - type_expression_or_array goto 581 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 845 - opt_parameter_modifier : parameter_modifiers . (205) - parameter_modifiers : parameter_modifiers . parameter_modifier (207) - - OUT shift 574 - REF shift 575 - THIS shift 576 - BOOL reduce 205 - BYTE reduce 205 - CHAR reduce 205 - DECIMAL reduce 205 - DOUBLE reduce 205 - FLOAT reduce 205 - INT reduce 205 - LONG reduce 205 - OBJECT reduce 205 - SBYTE reduce 205 - SHORT reduce 205 - STRING reduce 205 - UINT reduce 205 - ULONG reduce 205 - USHORT reduce 205 - VOID reduce 205 - IDENTIFIER reduce 205 - - parameter_modifier goto 949 - - -state 846 - parameter_modifiers : parameter_modifier . (206) - - . reduce 206 - - -state 847 - parameter_array : opt_attributes params_modifier . type IDENTIFIER (211) - parameter_array : opt_attributes params_modifier . type IDENTIFIER ASSIGN constant_expression (212) - parameter_array : opt_attributes params_modifier . type error (213) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 950 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 848 - anonymous_method_signature : OPEN_PARENS $$65 opt_formal_parameter_list CLOSE_PARENS . (565) - - . reduce 565 - - -state 849 - formal_parameter_list : fixed_parameters COMMA . parameter_array (189) - formal_parameter_list : fixed_parameters COMMA . arglist_modifier (190) - formal_parameter_list : fixed_parameters COMMA . parameter_array COMMA error (192) - formal_parameter_list : fixed_parameters COMMA . ARGLIST COMMA error (194) - fixed_parameters : fixed_parameters COMMA . fixed_parameter (198) - opt_attributes : . (59) - - ARGLIST shift 951 - OPEN_BRACKET shift 4 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - DECIMAL reduce 59 - DOUBLE reduce 59 - FLOAT reduce 59 - INT reduce 59 - LONG reduce 59 - OBJECT reduce 59 - OUT reduce 59 - PARAMS reduce 59 - REF reduce 59 - SBYTE reduce 59 - SHORT reduce 59 - STRING reduce 59 - THIS reduce 59 - UINT reduce 59 - ULONG reduce 59 - USHORT reduce 59 - VOID reduce 59 - IDENTIFIER reduce 59 - - opt_attributes goto 692 - attribute_sections goto 693 - attribute_section goto 30 - parameter_array goto 952 - arglist_modifier goto 953 - fixed_parameter goto 954 - - -state 850 - formal_parameter_list : parameter_array COMMA . error (191) - - error shift 955 - . error - - -state 851 - formal_parameter_list : arglist_modifier COMMA . error (193) - - error shift 956 - . error - - -state 852 - do_statement : DO embedded_statement WHILE open_parens_any boolean_expression . CLOSE_PARENS SEMICOLON (786) - - CLOSE_PARENS shift 957 - . error - - -state 853 - fixed_pointer_declarator : IDENTIFIER ASSIGN . expression (842) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 958 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 854 - fixed_statement : FIXED open_parens_any type_and_void fixed_pointer_declarators CLOSE_PARENS . $$83 embedded_statement (839) - $$83 : . (838) - - . reduce 838 - - $$83 goto 959 - - -state 855 - fixed_pointer_declarators : fixed_pointer_declarators COMMA . fixed_pointer_declarator (841) - - IDENTIFIER shift 702 - . error - - fixed_pointer_declarator goto 960 - - -state 856 - for_statement : FOR open_parens_any opt_for_initializer SEMICOLON $$79 . opt_for_condition SEMICOLON opt_for_iterator CLOSE_PARENS embedded_statement (788) - opt_for_condition : . (793) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - SEMICOLON reduce 793 - - expression goto 518 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - boolean_expression goto 961 - opt_for_condition goto 962 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 857 - statement_expression_list : statement_expression_list COMMA statement_expression . (799) - - . reduce 799 - - -state 858 - foreach_statement : FOREACH open_parens_any type IN expression . CLOSE_PARENS (800) - - CLOSE_PARENS shift 963 - . error - - -state 859 - foreach_statement : FOREACH open_parens_any type IDENTIFIER IN . expression CLOSE_PARENS $$80 embedded_statement (802) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 964 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -860: shift/reduce conflict (shift 965, reduce 767) on ELSE -state 860 - if_statement : IF open_parens_any boolean_expression CLOSE_PARENS embedded_statement . (767) - if_statement : IF open_parens_any boolean_expression CLOSE_PARENS embedded_statement . ELSE embedded_statement (768) - - ELSE shift 965 - $end reduce 767 - error reduce 767 - EOF reduce 767 - BASE reduce 767 - BOOL reduce 767 - BREAK reduce 767 - BYTE reduce 767 - CASE reduce 767 - CHAR reduce 767 - CHECKED reduce 767 - CONST reduce 767 - CONTINUE reduce 767 - DECIMAL reduce 767 - DEFAULT reduce 767 - DELEGATE reduce 767 - DO reduce 767 - DOUBLE reduce 767 - FALSE reduce 767 - FIXED reduce 767 - FLOAT reduce 767 - FOR reduce 767 - FOREACH reduce 767 - GOTO reduce 767 - IF reduce 767 - INT reduce 767 - LOCK reduce 767 - LONG reduce 767 - NEW reduce 767 - NULL reduce 767 - OBJECT reduce 767 - RETURN reduce 767 - SBYTE reduce 767 - SHORT reduce 767 - SIZEOF reduce 767 - STRING reduce 767 - SWITCH reduce 767 - THIS reduce 767 - THROW reduce 767 - TRUE reduce 767 - TRY reduce 767 - TYPEOF reduce 767 - UINT reduce 767 - ULONG reduce 767 - UNCHECKED reduce 767 - UNSAFE reduce 767 - USHORT reduce 767 - USING reduce 767 - VOID reduce 767 - WHILE reduce 767 - FROM reduce 767 - FROM_FIRST reduce 767 - OPEN_BRACE reduce 767 - CLOSE_BRACE reduce 767 - OPEN_PARENS reduce 767 - SEMICOLON reduce 767 - TILDE reduce 767 - PLUS reduce 767 - MINUS reduce 767 - BANG reduce 767 - BITWISE_AND reduce 767 - STAR reduce 767 - OP_INC reduce 767 - OP_DEC reduce 767 - LITERAL reduce 767 - IDENTIFIER reduce 767 - OPEN_PARENS_LAMBDA reduce 767 - OPEN_PARENS_CAST reduce 767 - DEFAULT_COLON reduce 767 - COMPLETE_COMPLETION reduce 767 - - -state 861 - lock_statement : LOCK open_parens_any expression CLOSE_PARENS embedded_statement . (844) - - . reduce 844 - - -state 862 - anonymous_type_parameter : IDENTIFIER ASSIGN variable_initializer . (523) - - . reduce 523 - - -state 863 - anonymous_type_parameters : anonymous_type_parameters COMMA anonymous_type_parameter . (522) - - . reduce 522 - - -state 864 - opt_comma : COMMA . (33) - variable_initializer_list : variable_initializer_list COMMA . variable_initializer (542) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 531 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - CLOSE_BRACE reduce 33 - - expression goto 719 - array_initializer goto 720 - variable_initializer goto 966 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 865 - array_initializer : OPEN_BRACE variable_initializer_list opt_comma . CLOSE_BRACE (540) - - CLOSE_BRACE shift 967 - . error - - -state 866 - member_initializer : OPEN_BRACE CLOSE_BRACE . (474) - - . reduce 474 - - -state 867 - member_initializer : OPEN_BRACE expression_list . CLOSE_BRACE (473) - expression_list : expression_list . COMMA expression (496) - expression_list : expression_list . error (497) - - error shift 876 - CLOSE_BRACE shift 968 - COMMA shift 878 - . error - - -state 868 - member_initializer : IDENTIFIER ASSIGN . initializer_value (470) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 534 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 969 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - object_or_collection_initializer goto 970 - initializer_value goto 971 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 869 - close_brace_or_complete_completion : CLOSE_BRACE . (920) - - . reduce 920 - - -state 870 - close_brace_or_complete_completion : COMPLETE_COMPLETION . (921) - - . reduce 921 - - -state 871 - object_or_collection_initializer : OPEN_BRACE opt_member_initializer_list close_brace_or_complete_completion . (463) - - . reduce 463 - - -state 872 - member_initializer_list : member_initializer_list error . (469) - - . reduce 469 - - -state 873 - object_or_collection_initializer : OPEN_BRACE member_initializer_list COMMA . CLOSE_BRACE (464) - member_initializer_list : member_initializer_list COMMA . member_initializer (468) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 723 - CLOSE_BRACE shift 972 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 724 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - GENERATE_COMPLETION shift 725 - . error - - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - member_initializer goto 973 - non_assignment_expression goto 729 - unary_expression goto 186 - prefixed_unary_expression goto 605 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 874 - member_initializer : non_assignment_expression opt_COMPLETE_COMPLETION . (472) - - . reduce 472 - - -state 875 - array_creation_expression : NEW new_expr_type OPEN_BRACKET CLOSE_BRACKET OPEN_BRACKET_EXPR . error CLOSE_BRACKET (512) - - error shift 974 - . error - - -state 876 - expression_list : expression_list error . (497) - - . reduce 497 - - -state 877 - array_creation_expression : NEW new_expr_type OPEN_BRACKET_EXPR expression_list CLOSE_BRACKET . opt_rank_specifier opt_array_initializer (509) - opt_rank_specifier : . (527) - - OPEN_BRACKET shift 332 - error reduce 527 - AS reduce 527 - IS reduce 527 - WHERE reduce 527 - FROM reduce 527 - JOIN reduce 527 - ON reduce 527 - EQUALS reduce 527 - SELECT reduce 527 - GROUP reduce 527 - BY reduce 527 - LET reduce 527 - ORDERBY reduce 527 - ASCENDING reduce 527 - DESCENDING reduce 527 - INTO reduce 527 - OPEN_BRACE reduce 527 - CLOSE_BRACE reduce 527 - CLOSE_BRACKET reduce 527 - OPEN_PARENS reduce 527 - CLOSE_PARENS reduce 527 - DOT reduce 527 - COMMA reduce 527 - COLON reduce 527 - SEMICOLON reduce 527 - PLUS reduce 527 - MINUS reduce 527 - ASSIGN reduce 527 - OP_LT reduce 527 - OP_GT reduce 527 - BITWISE_AND reduce 527 - BITWISE_OR reduce 527 - STAR reduce 527 - PERCENT reduce 527 - DIV reduce 527 - CARRET reduce 527 - INTERR reduce 527 - OP_INC reduce 527 - OP_DEC reduce 527 - OP_SHIFT_LEFT reduce 527 - OP_SHIFT_RIGHT reduce 527 - OP_LE reduce 527 - OP_GE reduce 527 - OP_EQ reduce 527 - OP_NE reduce 527 - OP_AND reduce 527 - OP_OR reduce 527 - OP_MULT_ASSIGN reduce 527 - OP_DIV_ASSIGN reduce 527 - OP_MOD_ASSIGN reduce 527 - OP_ADD_ASSIGN reduce 527 - OP_SUB_ASSIGN reduce 527 - OP_SHIFT_LEFT_ASSIGN reduce 527 - OP_SHIFT_RIGHT_ASSIGN reduce 527 - OP_AND_ASSIGN reduce 527 - OP_XOR_ASSIGN reduce 527 - OP_OR_ASSIGN reduce 527 - OP_PTR reduce 527 - OP_COALESCING reduce 527 - OPEN_PARENS_CAST reduce 527 - OPEN_BRACKET_EXPR reduce 527 - COMPLETE_COMPLETION reduce 527 - - rank_specifiers goto 352 - opt_rank_specifier goto 975 - rank_specifier goto 336 - - -state 878 - expression_list : expression_list COMMA . expression (496) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 976 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 879 - object_or_delegate_creation_expression : NEW new_expr_type open_parens_any opt_argument_list CLOSE_PARENS . opt_object_or_collection_initializer (507) - opt_object_or_collection_initializer : . (461) - - OPEN_BRACE shift 534 - error reduce 461 - AS reduce 461 - IS reduce 461 - WHERE reduce 461 - FROM reduce 461 - JOIN reduce 461 - ON reduce 461 - EQUALS reduce 461 - SELECT reduce 461 - GROUP reduce 461 - BY reduce 461 - LET reduce 461 - ORDERBY reduce 461 - ASCENDING reduce 461 - DESCENDING reduce 461 - INTO reduce 461 - INTERR_NULLABLE reduce 461 - CLOSE_BRACE reduce 461 - OPEN_BRACKET reduce 461 - CLOSE_BRACKET reduce 461 - OPEN_PARENS reduce 461 - CLOSE_PARENS reduce 461 - DOT reduce 461 - COMMA reduce 461 - COLON reduce 461 - SEMICOLON reduce 461 - PLUS reduce 461 - MINUS reduce 461 - ASSIGN reduce 461 - OP_LT reduce 461 - OP_GT reduce 461 - BITWISE_AND reduce 461 - BITWISE_OR reduce 461 - STAR reduce 461 - PERCENT reduce 461 - DIV reduce 461 - CARRET reduce 461 - INTERR reduce 461 - OP_INC reduce 461 - OP_DEC reduce 461 - OP_SHIFT_LEFT reduce 461 - OP_SHIFT_RIGHT reduce 461 - OP_LE reduce 461 - OP_GE reduce 461 - OP_EQ reduce 461 - OP_NE reduce 461 - OP_AND reduce 461 - OP_OR reduce 461 - OP_MULT_ASSIGN reduce 461 - OP_DIV_ASSIGN reduce 461 - OP_MOD_ASSIGN reduce 461 - OP_ADD_ASSIGN reduce 461 - OP_SUB_ASSIGN reduce 461 - OP_SHIFT_LEFT_ASSIGN reduce 461 - OP_SHIFT_RIGHT_ASSIGN reduce 461 - OP_AND_ASSIGN reduce 461 - OP_XOR_ASSIGN reduce 461 - OP_OR_ASSIGN reduce 461 - OP_PTR reduce 461 - OP_COALESCING reduce 461 - IDENTIFIER reduce 461 - OPEN_PARENS_CAST reduce 461 - OPEN_BRACKET_EXPR reduce 461 - COMPLETE_COMPLETION reduce 461 - - opt_object_or_collection_initializer goto 977 - object_or_collection_initializer goto 978 - - -state 880 - switch_statement : SWITCH open_parens_any $$77 expression CLOSE_PARENS . OPEN_BRACE opt_switch_sections CLOSE_BRACE (770) - - OPEN_BRACE shift 979 - . error - - -state 881 - catch_args : open_parens_any CLOSE_PARENS . (833) - - . reduce 833 - - -state 882 - catch_args : open_parens_any type . opt_identifier CLOSE_PARENS (832) - opt_identifier : . (826) - - IDENTIFIER shift 980 - CLOSE_PARENS reduce 826 - - opt_identifier goto 981 - - -state 883 - catch_clause : CATCH opt_catch_args $$81 . block (829) - - OPEN_BRACE shift 143 - . error - - block goto 982 - - -state 884 - try_statement : TRY block catch_clauses FINALLY block . (822) - - . reduce 822 - - -state 885 - generic_dimension : GENERIC_DIMENSION . (554) - - . reduce 554 - - -state 886 - unbound_type_name : IDENTIFIER generic_dimension . (549) - - . reduce 549 - - -state 887 - member_name : namespace_or_type_name DOT . IDENTIFIER opt_type_argument_list (361) - unbound_type_name : namespace_or_type_name DOT . IDENTIFIER generic_dimension (553) - - IDENTIFIER shift 983 - . error - - -state 888 - namespace_or_type_name : qualified_alias_member IDENTIFIER . opt_type_argument_list (359) - unbound_type_name : qualified_alias_member IDENTIFIER . generic_dimension (550) - opt_type_argument_list : . (363) - - OP_GENERICS_LT shift 81 - GENERIC_DIMENSION shift 885 - INTERR_NULLABLE reduce 363 - OPEN_BRACKET reduce 363 - CLOSE_PARENS reduce 363 - DOT reduce 363 - STAR reduce 363 - - opt_type_argument_list goto 273 - generic_dimension goto 984 - - -state 889 - typeof_expression : TYPEOF $$63 open_parens_any typeof_type_expression CLOSE_PARENS . (545) - - . reduce 545 - - -state 890 - unbound_type_name : unbound_type_name DOT . IDENTIFIER (551) - unbound_type_name : unbound_type_name DOT . IDENTIFIER generic_dimension (552) - - IDENTIFIER shift 985 - . error - - -state 891 - using_statement : USING open_parens_any expression CLOSE_PARENS $$85 . embedded_statement (848) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BREAK shift 98 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 101 - CONST shift 102 - CONTINUE shift 103 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DO shift 107 - DOUBLE shift 108 - FALSE shift 109 - FIXED shift 110 - FLOAT shift 111 - FOR shift 112 - FOREACH shift 113 - GOTO shift 114 - IF shift 115 - INT shift 116 - LOCK shift 117 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - RETURN shift 122 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - SWITCH shift 127 - THIS shift 128 - THROW shift 129 - TRUE shift 130 - TRY shift 131 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 135 - UNSAFE shift 136 - USHORT shift 137 - USING shift 138 - VOID shift 139 - WHILE shift 140 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 143 - OPEN_PARENS shift 144 - SEMICOLON shift 145 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 155 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 304 - block goto 305 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - declaration_statement goto 306 - valid_declaration_statement goto 307 - labeled_statement goto 308 - empty_statement goto 309 - expression_statement goto 310 - selection_statement goto 311 - iteration_statement goto 312 - jump_statement goto 313 - try_statement goto 314 - checked_statement goto 315 - unchecked_statement goto 316 - lock_statement goto 317 - using_statement goto 318 - unsafe_statement goto 319 - fixed_statement goto 320 - embedded_statement goto 986 - local_variable_declaration goto 221 - local_constant_declaration goto 222 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - statement_expression goto 322 - if_statement goto 227 - switch_statement goto 228 - while_statement goto 229 - do_statement goto 230 - for_statement goto 231 - foreach_statement goto 232 - break_statement goto 233 - continue_statement goto 234 - goto_statement goto 235 - return_statement goto 236 - throw_statement goto 237 - yield_statement goto 238 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 892 - using_statement : USING open_parens_any local_variable_declaration CLOSE_PARENS $$84 . embedded_statement (846) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BREAK shift 98 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 101 - CONST shift 102 - CONTINUE shift 103 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DO shift 107 - DOUBLE shift 108 - FALSE shift 109 - FIXED shift 110 - FLOAT shift 111 - FOR shift 112 - FOREACH shift 113 - GOTO shift 114 - IF shift 115 - INT shift 116 - LOCK shift 117 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - RETURN shift 122 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - SWITCH shift 127 - THIS shift 128 - THROW shift 129 - TRUE shift 130 - TRY shift 131 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 135 - UNSAFE shift 136 - USHORT shift 137 - USING shift 138 - VOID shift 139 - WHILE shift 140 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 143 - OPEN_PARENS shift 144 - SEMICOLON shift 145 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 155 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 304 - block goto 305 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - declaration_statement goto 306 - valid_declaration_statement goto 307 - labeled_statement goto 308 - empty_statement goto 309 - expression_statement goto 310 - selection_statement goto 311 - iteration_statement goto 312 - jump_statement goto 313 - try_statement goto 314 - checked_statement goto 315 - unchecked_statement goto 316 - lock_statement goto 317 - using_statement goto 318 - unsafe_statement goto 319 - fixed_statement goto 320 - embedded_statement goto 987 - local_variable_declaration goto 221 - local_constant_declaration goto 222 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - statement_expression goto 322 - if_statement goto 227 - switch_statement goto 228 - while_statement goto 229 - do_statement goto 230 - for_statement goto 231 - foreach_statement goto 232 - break_statement goto 233 - continue_statement goto 234 - goto_statement goto 235 - return_statement goto 236 - throw_statement goto 237 - yield_statement goto 238 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 893 - while_statement : WHILE open_parens_any boolean_expression CLOSE_PARENS embedded_statement . (785) - - . reduce 785 - - -state 894 - nested_from_clause : FROM type IDENTIFIER IN expression . (856) - - . reduce 856 - - -state 895 - first_from_clause : FROM_FIRST type IDENTIFIER IN expression . (854) - - . reduce 854 - - -state 896 - lambda_expression_body : $$66 expression . (634) - - . reduce 634 - - -state 897 - lambda_parameter : parameter_modifier parameter_type IDENTIFIER . (628) - - . reduce 628 - - -state 898 - lambda_parameter_list : lambda_parameter_list COMMA lambda_parameter . (627) - - . reduce 627 - - -state 899 - lambda_expression : OPEN_PARENS_LAMBDA $$68 opt_lambda_parameter_list CLOSE_PARENS ARROW . $$69 lambda_expression_body (640) - $$69 : . (639) - - . reduce 639 - - $$69 goto 988 - - -state 900 - non_simple_argument : ARGLIST OPEN_PARENS CLOSE_PARENS . (491) - - . reduce 491 - - -state 901 - argument_list : argument_list . COMMA argument (480) - argument_list : argument_list . COMMA named_argument (481) - argument_list : argument_list . COMMA (482) - non_simple_argument : ARGLIST OPEN_PARENS argument_list . CLOSE_PARENS (490) - - CLOSE_PARENS shift 989 - COMMA shift 787 - . error - - -state 902 - argument_list : argument_list COMMA named_argument . (481) - - . reduce 481 - - -state 903 - argument_list : argument_list COMMA argument . (480) - - . reduce 480 - - -state 904 - conditional_expression : null_coalescing_expression INTERR expression COLON expression . (614) - - . reduce 614 - - -state 905 - local_variable_initializer : STACKALLOC simple_type . OPEN_BRACKET_EXPR expression CLOSE_BRACKET (169) - local_variable_initializer : STACKALLOC simple_type . (171) - - OPEN_BRACKET_EXPR shift 990 - CLOSE_PARENS reduce 171 - COMMA reduce 171 - SEMICOLON reduce 171 - - -state 906 - variable_bad_array : OPEN_BRACKET_EXPR opt_expression CLOSE_BRACKET . (172) - - . reduce 172 - - -state 907 - from_clause : FROM IDENTIFIER IN $$86 . expression (858) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 991 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 908 - from_clause : FROM type IDENTIFIER IN . $$87 expression (860) - $$87 : . (859) - - . reduce 859 - - $$87 goto 992 - - -state 909 - join_clause : JOIN IDENTIFIER IN $$93 . expression ON $$94 expression EQUALS $$95 expression opt_join_into (884) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 993 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 910 - join_clause : JOIN type IDENTIFIER IN . $$96 expression ON $$97 expression EQUALS $$98 expression opt_join_into (888) - $$96 : . (885) - - . reduce 885 - - $$96 goto 994 - - -state 911 - let_clause : LET IDENTIFIER ASSIGN $$91 . expression (878) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 995 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 912 - order_by : expression ASCENDING . (900) - - . reduce 900 - - -state 913 - order_by : expression DESCENDING . (901) - - . reduce 901 - - -state 914 - orderings : order_by COMMA . $$100 orderings_then_by (895) - $$100 : . (894) - - . reduce 894 - - $$100 goto 996 - - -state 915 - select_or_group_clause : SELECT $$88 expression . (864) - - . reduce 864 - - -state 916 - select_or_group_clause : GROUP $$89 expression . $$90 BY expression (867) - $$90 : . (866) - - . reduce 866 - - $$90 goto 997 - - -state 917 - opt_query_continuation : INTO IDENTIFIER . $$102 query_body (907) - $$102 : . (906) - - . reduce 906 - - $$102 goto 998 - - -state 918 - namespace_body_body : error . $$4 CLOSE_BRACE (39) - $$4 : . (38) - - . reduce 38 - - $$4 goto 999 - - -state 919 - extern_alias_directives : extern_alias_directive . (14) - - . reduce 14 - - -state 920 - extern_alias_directives : extern_alias_directives . extern_alias_directive (15) - opt_extern_alias_directives : extern_alias_directives . (44) - - EXTERN_ALIAS shift 3 - EOF reduce 44 - ABSTRACT reduce 44 - BOOL reduce 44 - BYTE reduce 44 - CHAR reduce 44 - CLASS reduce 44 - DECIMAL reduce 44 - DELEGATE reduce 44 - DOUBLE reduce 44 - ENUM reduce 44 - EXTERN reduce 44 - FIXED reduce 44 - FLOAT reduce 44 - INT reduce 44 - INTERFACE reduce 44 - INTERNAL reduce 44 - LONG reduce 44 - NAMESPACE reduce 44 - NEW reduce 44 - OBJECT reduce 44 - OVERRIDE reduce 44 - PRIVATE reduce 44 - PROTECTED reduce 44 - PUBLIC reduce 44 - READONLY reduce 44 - SBYTE reduce 44 - SEALED reduce 44 - SHORT reduce 44 - STATIC reduce 44 - STRING reduce 44 - STRUCT reduce 44 - UINT reduce 44 - ULONG reduce 44 - UNSAFE reduce 44 - USHORT reduce 44 - USING reduce 44 - VIRTUAL reduce 44 - VOID reduce 44 - VOLATILE reduce 44 - PARTIAL reduce 44 - CLOSE_BRACE reduce 44 - OPEN_BRACKET reduce 44 - IDENTIFIER reduce 44 - - extern_alias_directive goto 1000 - - -state 921 - namespace_body : OPEN_BRACE $$3 namespace_body_body . (36) - - . reduce 36 - - -state 922 - namespace_body_body : opt_extern_alias_directives . opt_using_directives opt_namespace_member_declarations CLOSE_BRACE (37) - namespace_body_body : opt_extern_alias_directives . opt_using_directives opt_namespace_member_declarations EOF (40) - opt_using_directives : . (41) - - USING shift 2 - EOF reduce 41 - ABSTRACT reduce 41 - BOOL reduce 41 - BYTE reduce 41 - CHAR reduce 41 - CLASS reduce 41 - DECIMAL reduce 41 - DELEGATE reduce 41 - DOUBLE reduce 41 - ENUM reduce 41 - EXTERN reduce 41 - FIXED reduce 41 - FLOAT reduce 41 - INT reduce 41 - INTERFACE reduce 41 - INTERNAL reduce 41 - LONG reduce 41 - NAMESPACE reduce 41 - NEW reduce 41 - OBJECT reduce 41 - OVERRIDE reduce 41 - PRIVATE reduce 41 - PROTECTED reduce 41 - PUBLIC reduce 41 - READONLY reduce 41 - SBYTE reduce 41 - SEALED reduce 41 - SHORT reduce 41 - STATIC reduce 41 - STRING reduce 41 - STRUCT reduce 41 - UINT reduce 41 - ULONG reduce 41 - UNSAFE reduce 41 - USHORT reduce 41 - VIRTUAL reduce 41 - VOID reduce 41 - VOLATILE reduce 41 - PARTIAL reduce 41 - CLOSE_BRACE reduce 41 - OPEN_BRACKET reduce 41 - IDENTIFIER reduce 41 - - using_directive goto 54 - using_directives goto 1001 - using_alias_directive goto 17 - using_namespace_directive goto 18 - opt_using_directives goto 1002 - - -state 923 - delegate_declaration : opt_attributes opt_modifiers DELEGATE member_type type_declaration_name OPEN_PARENS $$58 . opt_formal_parameter_list CLOSE_PARENS $$59 opt_type_parameter_constraints_clauses $$60 SEMICOLON (355) - opt_attributes : . (59) - opt_formal_parameter_list : . (186) - - ARGLIST shift 691 - OPEN_BRACKET shift 4 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - DECIMAL reduce 59 - DOUBLE reduce 59 - FLOAT reduce 59 - INT reduce 59 - LONG reduce 59 - OBJECT reduce 59 - OUT reduce 59 - PARAMS reduce 59 - REF reduce 59 - SBYTE reduce 59 - SHORT reduce 59 - STRING reduce 59 - THIS reduce 59 - UINT reduce 59 - ULONG reduce 59 - USHORT reduce 59 - VOID reduce 59 - CLOSE_PARENS reduce 186 - IDENTIFIER reduce 59 - - opt_attributes goto 692 - attribute_sections goto 693 - attribute_section goto 30 - opt_formal_parameter_list goto 1003 - formal_parameter_list goto 695 - fixed_parameters goto 696 - parameter_array goto 697 - arglist_modifier goto 698 - fixed_parameter goto 699 - - -state 924 - type_parameter : error . (383) - - . reduce 383 - - -state 925 - type_parameter : opt_attributes . opt_type_parameter_variance IDENTIFIER (382) - opt_type_parameter_variance : . (686) - - IN shift 1004 - OUT shift 1005 - IDENTIFIER reduce 686 - - opt_type_parameter_variance goto 1006 - type_parameter_variance goto 1007 - - -state 926 - opt_type_parameter_list : OP_GENERICS_LT_DECL type_parameters . OP_GENERICS_GT (379) - type_parameters : type_parameters . COMMA type_parameter (381) - - OP_GENERICS_GT shift 1008 - COMMA shift 1009 - . error - - -state 927 - type_parameters : type_parameter . (380) - - . reduce 380 - - -state 928 - enum_declaration : opt_attributes opt_modifiers ENUM type_declaration_name opt_enum_base $$54 OPEN_BRACE . $$55 opt_enum_member_declarations $$56 CLOSE_BRACE opt_semicolon (340) - $$55 : . (338) - - . reduce 338 - - $$55 goto 1010 - - -state 929 - fixed_field_size : OPEN_BRACKET . $$18 expression CLOSE_BRACKET (160) - fixed_field_size : OPEN_BRACKET . error (161) - $$18 : . (159) - - error shift 1011 - BASE reduce 159 - BOOL reduce 159 - BYTE reduce 159 - CHAR reduce 159 - CHECKED reduce 159 - DECIMAL reduce 159 - DEFAULT reduce 159 - DELEGATE reduce 159 - DOUBLE reduce 159 - FALSE reduce 159 - FLOAT reduce 159 - INT reduce 159 - LONG reduce 159 - NEW reduce 159 - NULL reduce 159 - OBJECT reduce 159 - SBYTE reduce 159 - SHORT reduce 159 - SIZEOF reduce 159 - STRING reduce 159 - THIS reduce 159 - TRUE reduce 159 - TYPEOF reduce 159 - UINT reduce 159 - ULONG reduce 159 - UNCHECKED reduce 159 - USHORT reduce 159 - FROM reduce 159 - FROM_FIRST reduce 159 - OPEN_PARENS reduce 159 - TILDE reduce 159 - PLUS reduce 159 - MINUS reduce 159 - BANG reduce 159 - BITWISE_AND reduce 159 - STAR reduce 159 - OP_INC reduce 159 - OP_DEC reduce 159 - LITERAL reduce 159 - IDENTIFIER reduce 159 - OPEN_PARENS_LAMBDA reduce 159 - OPEN_PARENS_CAST reduce 159 - - $$18 goto 1012 - - -state 930 - field_declaration : opt_attributes opt_modifiers FIXED simple_type IDENTIFIER $$15 fixed_field_size . opt_fixed_field_declarators SEMICOLON (142) - opt_fixed_field_declarators : . (154) - - COMMA shift 1013 - SEMICOLON reduce 154 - - opt_fixed_field_declarators goto 1014 - fixed_field_declarators goto 1015 - fixed_field_declarator goto 1016 - - -state 931 - method_header : opt_attributes opt_modifiers PARTIAL VOID method_declaration_name OPEN_PARENS $$22 . opt_formal_parameter_list CLOSE_PARENS $$23 opt_type_parameter_constraints_clauses (182) - opt_attributes : . (59) - opt_formal_parameter_list : . (186) - - ARGLIST shift 691 - OPEN_BRACKET shift 4 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - DECIMAL reduce 59 - DOUBLE reduce 59 - FLOAT reduce 59 - INT reduce 59 - LONG reduce 59 - OBJECT reduce 59 - OUT reduce 59 - PARAMS reduce 59 - REF reduce 59 - SBYTE reduce 59 - SHORT reduce 59 - STRING reduce 59 - THIS reduce 59 - UINT reduce 59 - ULONG reduce 59 - USHORT reduce 59 - VOID reduce 59 - CLOSE_PARENS reduce 186 - IDENTIFIER reduce 59 - - opt_attributes goto 692 - attribute_sections goto 693 - attribute_section goto 30 - opt_formal_parameter_list goto 1017 - formal_parameter_list goto 695 - fixed_parameters goto 696 - parameter_array goto 697 - arglist_modifier goto 698 - fixed_parameter goto 699 - - -state 932 - class_declaration : opt_attributes opt_modifiers opt_partial CLASS $$70 type_declaration_name $$71 . opt_class_base opt_type_parameter_constraints_clauses $$72 OPEN_BRACE opt_class_member_declarations CLOSE_BRACE $$73 opt_semicolon (652) - opt_class_base : . (673) - - COLON shift 1018 - WHERE reduce 673 - OPEN_BRACE reduce 673 - - opt_class_base goto 1019 - - -state 933 - interface_declaration : opt_attributes opt_modifiers opt_partial INTERFACE $$33 type_declaration_name $$34 . opt_class_base opt_type_parameter_constraints_clauses $$35 OPEN_BRACE opt_interface_member_declarations CLOSE_BRACE $$36 opt_semicolon (242) - opt_class_base : . (673) - - COLON shift 1018 - WHERE reduce 673 - OPEN_BRACE reduce 673 - - opt_class_base goto 1020 - - -state 934 - struct_declaration : opt_attributes opt_modifiers opt_partial STRUCT $$7 type_declaration_name $$8 . opt_class_base opt_type_parameter_constraints_clauses $$9 struct_body $$10 opt_semicolon (109) - opt_class_base : . (673) - - COLON shift 1018 - WHERE reduce 673 - OPEN_BRACE reduce 673 - - opt_class_base goto 1021 - - -state 935 - opt_field_initializer : ASSIGN $$16 . variable_initializer (146) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 531 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 719 - array_initializer goto 720 - variable_initializer goto 1022 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 936 - field_declarator : COMMA . IDENTIFIER (151) - field_declarator : COMMA . IDENTIFIER ASSIGN $$17 variable_initializer (153) - - IDENTIFIER shift 1023 - . error - - -state 937 - field_declaration : opt_attributes opt_modifiers member_type IDENTIFIER $$14 opt_field_initializer opt_field_declarators . SEMICOLON (140) - - SEMICOLON shift 1024 - . error - - -state 938 - opt_field_declarators : field_declarators . (148) - field_declarators : field_declarators . field_declarator (150) - - COMMA shift 936 - SEMICOLON reduce 148 - - field_declarator goto 1025 - - -state 939 - field_declarators : field_declarator . (149) - - . reduce 149 - - -state 940 - method_header : opt_attributes opt_modifiers member_type method_declaration_name OPEN_PARENS $$20 opt_formal_parameter_list . CLOSE_PARENS $$21 opt_type_parameter_constraints_clauses (179) - - CLOSE_PARENS shift 1026 - . error - - -state 941 - method_header : opt_attributes opt_modifiers member_type modifiers method_declaration_name OPEN_PARENS opt_formal_parameter_list . CLOSE_PARENS (183) - - CLOSE_PARENS shift 1027 - . error - - -state 942 - explicit_interface : qualified_alias_member IDENTIFIER opt_type_argument_list DOT . (376) - - . reduce 376 - - -state 943 - explicit_interface : explicit_interface IDENTIFIER opt_type_argument_list DOT . (377) - - . reduce 377 - - -state 944 - named_argument : IDENTIFIER COLON opt_named_modifier expression . (86) - - . reduce 86 - - -state 945 - named_attribute_argument : IDENTIFIER ASSIGN $$6 expression . (85) - - . reduce 85 - - -state 946 - params_modifier : PARAMS parameter_modifier . (215) - - . reduce 215 - - -state 947 - params_modifier : PARAMS params_modifier . (216) - - . reduce 216 - - -state 948 - fixed_parameter : opt_attributes opt_parameter_modifier parameter_type . IDENTIFIER (199) - fixed_parameter : opt_attributes opt_parameter_modifier parameter_type . IDENTIFIER OPEN_BRACKET CLOSE_BRACKET (200) - fixed_parameter : opt_attributes opt_parameter_modifier parameter_type . error (201) - fixed_parameter : opt_attributes opt_parameter_modifier parameter_type . IDENTIFIER ASSIGN $$24 constant_expression (203) - - error shift 1028 - IDENTIFIER shift 1029 - . error - - -state 949 - parameter_modifiers : parameter_modifiers parameter_modifier . (207) - - . reduce 207 - - -state 950 - parameter_array : opt_attributes params_modifier type . IDENTIFIER (211) - parameter_array : opt_attributes params_modifier type . IDENTIFIER ASSIGN constant_expression (212) - parameter_array : opt_attributes params_modifier type . error (213) - - error shift 1030 - IDENTIFIER shift 1031 - . error - - -state 951 - formal_parameter_list : fixed_parameters COMMA ARGLIST . COMMA error (194) - arglist_modifier : ARGLIST . (217) - - COMMA shift 1032 - CLOSE_BRACKET reduce 217 - CLOSE_PARENS reduce 217 - - -state 952 - formal_parameter_list : fixed_parameters COMMA parameter_array . (189) - formal_parameter_list : fixed_parameters COMMA parameter_array . COMMA error (192) - - COMMA shift 1033 - CLOSE_BRACKET reduce 189 - CLOSE_PARENS reduce 189 - - -state 953 - formal_parameter_list : fixed_parameters COMMA arglist_modifier . (190) - - . reduce 190 - - -state 954 - fixed_parameters : fixed_parameters COMMA fixed_parameter . (198) - - . reduce 198 - - -state 955 - formal_parameter_list : parameter_array COMMA error . (191) - - . reduce 191 - - -state 956 - formal_parameter_list : arglist_modifier COMMA error . (193) - - . reduce 193 - - -state 957 - do_statement : DO embedded_statement WHILE open_parens_any boolean_expression CLOSE_PARENS . SEMICOLON (786) - - SEMICOLON shift 1034 - . error - - -state 958 - fixed_pointer_declarator : IDENTIFIER ASSIGN expression . (842) - - . reduce 842 - - -state 959 - fixed_statement : FIXED open_parens_any type_and_void fixed_pointer_declarators CLOSE_PARENS $$83 . embedded_statement (839) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BREAK shift 98 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 101 - CONST shift 102 - CONTINUE shift 103 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DO shift 107 - DOUBLE shift 108 - FALSE shift 109 - FIXED shift 110 - FLOAT shift 111 - FOR shift 112 - FOREACH shift 113 - GOTO shift 114 - IF shift 115 - INT shift 116 - LOCK shift 117 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - RETURN shift 122 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - SWITCH shift 127 - THIS shift 128 - THROW shift 129 - TRUE shift 130 - TRY shift 131 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 135 - UNSAFE shift 136 - USHORT shift 137 - USING shift 138 - VOID shift 139 - WHILE shift 140 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 143 - OPEN_PARENS shift 144 - SEMICOLON shift 145 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 155 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 304 - block goto 305 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - declaration_statement goto 306 - valid_declaration_statement goto 307 - labeled_statement goto 308 - empty_statement goto 309 - expression_statement goto 310 - selection_statement goto 311 - iteration_statement goto 312 - jump_statement goto 313 - try_statement goto 314 - checked_statement goto 315 - unchecked_statement goto 316 - lock_statement goto 317 - using_statement goto 318 - unsafe_statement goto 319 - fixed_statement goto 320 - embedded_statement goto 1035 - local_variable_declaration goto 221 - local_constant_declaration goto 222 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - statement_expression goto 322 - if_statement goto 227 - switch_statement goto 228 - while_statement goto 229 - do_statement goto 230 - for_statement goto 231 - foreach_statement goto 232 - break_statement goto 233 - continue_statement goto 234 - goto_statement goto 235 - return_statement goto 236 - throw_statement goto 237 - yield_statement goto 238 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 960 - fixed_pointer_declarators : fixed_pointer_declarators COMMA fixed_pointer_declarator . (841) - - . reduce 841 - - -state 961 - opt_for_condition : boolean_expression . (794) - - . reduce 794 - - -state 962 - for_statement : FOR open_parens_any opt_for_initializer SEMICOLON $$79 opt_for_condition . SEMICOLON opt_for_iterator CLOSE_PARENS embedded_statement (788) - - SEMICOLON shift 1036 - . error - - -state 963 - foreach_statement : FOREACH open_parens_any type IN expression CLOSE_PARENS . (800) - - . reduce 800 - - -state 964 - foreach_statement : FOREACH open_parens_any type IDENTIFIER IN expression . CLOSE_PARENS $$80 embedded_statement (802) - - CLOSE_PARENS shift 1037 - . error - - -state 965 - if_statement : IF open_parens_any boolean_expression CLOSE_PARENS embedded_statement ELSE . embedded_statement (768) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BREAK shift 98 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 101 - CONST shift 102 - CONTINUE shift 103 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DO shift 107 - DOUBLE shift 108 - FALSE shift 109 - FIXED shift 110 - FLOAT shift 111 - FOR shift 112 - FOREACH shift 113 - GOTO shift 114 - IF shift 115 - INT shift 116 - LOCK shift 117 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - RETURN shift 122 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - SWITCH shift 127 - THIS shift 128 - THROW shift 129 - TRUE shift 130 - TRY shift 131 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 135 - UNSAFE shift 136 - USHORT shift 137 - USING shift 138 - VOID shift 139 - WHILE shift 140 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 143 - OPEN_PARENS shift 144 - SEMICOLON shift 145 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 155 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 304 - block goto 305 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - declaration_statement goto 306 - valid_declaration_statement goto 307 - labeled_statement goto 308 - empty_statement goto 309 - expression_statement goto 310 - selection_statement goto 311 - iteration_statement goto 312 - jump_statement goto 313 - try_statement goto 314 - checked_statement goto 315 - unchecked_statement goto 316 - lock_statement goto 317 - using_statement goto 318 - unsafe_statement goto 319 - fixed_statement goto 320 - embedded_statement goto 1038 - local_variable_declaration goto 221 - local_constant_declaration goto 222 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - statement_expression goto 322 - if_statement goto 227 - switch_statement goto 228 - while_statement goto 229 - do_statement goto 230 - for_statement goto 231 - foreach_statement goto 232 - break_statement goto 233 - continue_statement goto 234 - goto_statement goto 235 - return_statement goto 236 - throw_statement goto 237 - yield_statement goto 238 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 966 - variable_initializer_list : variable_initializer_list COMMA variable_initializer . (542) - - . reduce 542 - - -state 967 - array_initializer : OPEN_BRACE variable_initializer_list opt_comma CLOSE_BRACE . (540) - - . reduce 540 - - -state 968 - member_initializer : OPEN_BRACE expression_list CLOSE_BRACE . (473) - - . reduce 473 - - -state 969 - initializer_value : expression . (475) - - . reduce 475 - - -state 970 - initializer_value : object_or_collection_initializer . (476) - - . reduce 476 - - -state 971 - member_initializer : IDENTIFIER ASSIGN initializer_value . (470) - - . reduce 470 - - -state 972 - object_or_collection_initializer : OPEN_BRACE member_initializer_list COMMA CLOSE_BRACE . (464) - - . reduce 464 - - -state 973 - member_initializer_list : member_initializer_list COMMA member_initializer . (468) - - . reduce 468 - - -state 974 - array_creation_expression : NEW new_expr_type OPEN_BRACKET CLOSE_BRACKET OPEN_BRACKET_EXPR error . CLOSE_BRACKET (512) - - CLOSE_BRACKET shift 1039 - . error - - -state 975 - array_creation_expression : NEW new_expr_type OPEN_BRACKET_EXPR expression_list CLOSE_BRACKET opt_rank_specifier . opt_array_initializer (509) - opt_array_initializer : . (537) - - OPEN_BRACE shift 531 - error reduce 537 - AS reduce 537 - IS reduce 537 - WHERE reduce 537 - FROM reduce 537 - JOIN reduce 537 - ON reduce 537 - EQUALS reduce 537 - SELECT reduce 537 - GROUP reduce 537 - BY reduce 537 - LET reduce 537 - ORDERBY reduce 537 - ASCENDING reduce 537 - DESCENDING reduce 537 - INTO reduce 537 - CLOSE_BRACE reduce 537 - CLOSE_BRACKET reduce 537 - OPEN_PARENS reduce 537 - CLOSE_PARENS reduce 537 - DOT reduce 537 - COMMA reduce 537 - COLON reduce 537 - SEMICOLON reduce 537 - PLUS reduce 537 - MINUS reduce 537 - ASSIGN reduce 537 - OP_LT reduce 537 - OP_GT reduce 537 - BITWISE_AND reduce 537 - BITWISE_OR reduce 537 - STAR reduce 537 - PERCENT reduce 537 - DIV reduce 537 - CARRET reduce 537 - INTERR reduce 537 - OP_INC reduce 537 - OP_DEC reduce 537 - OP_SHIFT_LEFT reduce 537 - OP_SHIFT_RIGHT reduce 537 - OP_LE reduce 537 - OP_GE reduce 537 - OP_EQ reduce 537 - OP_NE reduce 537 - OP_AND reduce 537 - OP_OR reduce 537 - OP_MULT_ASSIGN reduce 537 - OP_DIV_ASSIGN reduce 537 - OP_MOD_ASSIGN reduce 537 - OP_ADD_ASSIGN reduce 537 - OP_SUB_ASSIGN reduce 537 - OP_SHIFT_LEFT_ASSIGN reduce 537 - OP_SHIFT_RIGHT_ASSIGN reduce 537 - OP_AND_ASSIGN reduce 537 - OP_XOR_ASSIGN reduce 537 - OP_OR_ASSIGN reduce 537 - OP_PTR reduce 537 - OP_COALESCING reduce 537 - OPEN_PARENS_CAST reduce 537 - OPEN_BRACKET_EXPR reduce 537 - COMPLETE_COMPLETION reduce 537 - - array_initializer goto 733 - opt_array_initializer goto 1040 - - -state 976 - expression_list : expression_list COMMA expression . (496) - - . reduce 496 - - -state 977 - object_or_delegate_creation_expression : NEW new_expr_type open_parens_any opt_argument_list CLOSE_PARENS opt_object_or_collection_initializer . (507) - - . reduce 507 - - -state 978 - opt_object_or_collection_initializer : object_or_collection_initializer . (462) - - . reduce 462 - - -state 979 - switch_statement : SWITCH open_parens_any $$77 expression CLOSE_PARENS OPEN_BRACE . opt_switch_sections CLOSE_BRACE (770) - opt_switch_sections : . (771) - - CASE shift 1041 - DEFAULT_COLON shift 1042 - CLOSE_BRACE reduce 771 - - opt_switch_sections goto 1043 - switch_sections goto 1044 - switch_section goto 1045 - switch_labels goto 1046 - switch_label goto 1047 - - -state 980 - opt_identifier : IDENTIFIER . (827) - - . reduce 827 - - -state 981 - catch_args : open_parens_any type opt_identifier . CLOSE_PARENS (832) - - CLOSE_PARENS shift 1048 - . error - - -state 982 - catch_clause : CATCH opt_catch_args $$81 block . (829) - - . reduce 829 - - -state 983 - member_name : namespace_or_type_name DOT IDENTIFIER . opt_type_argument_list (361) - unbound_type_name : namespace_or_type_name DOT IDENTIFIER . generic_dimension (553) - opt_type_argument_list : . (363) - - OP_GENERICS_LT shift 81 - GENERIC_DIMENSION shift 885 - INTERR_NULLABLE reduce 363 - OPEN_BRACKET reduce 363 - CLOSE_PARENS reduce 363 - DOT reduce 363 - STAR reduce 363 - - opt_type_argument_list goto 482 - generic_dimension goto 1049 - - -state 984 - unbound_type_name : qualified_alias_member IDENTIFIER generic_dimension . (550) - - . reduce 550 - - -state 985 - unbound_type_name : unbound_type_name DOT IDENTIFIER . (551) - unbound_type_name : unbound_type_name DOT IDENTIFIER . generic_dimension (552) - - GENERIC_DIMENSION shift 885 - CLOSE_PARENS reduce 551 - DOT reduce 551 - - generic_dimension goto 1050 - - -state 986 - using_statement : USING open_parens_any expression CLOSE_PARENS $$85 embedded_statement . (848) - - . reduce 848 - - -state 987 - using_statement : USING open_parens_any local_variable_declaration CLOSE_PARENS $$84 embedded_statement . (846) - - . reduce 846 - - -state 988 - lambda_expression : OPEN_PARENS_LAMBDA $$68 opt_lambda_parameter_list CLOSE_PARENS ARROW $$69 . lambda_expression_body (640) - $$66 : . (633) - - OPEN_BRACE shift 143 - BASE reduce 633 - BOOL reduce 633 - BYTE reduce 633 - CHAR reduce 633 - CHECKED reduce 633 - DECIMAL reduce 633 - DEFAULT reduce 633 - DELEGATE reduce 633 - DOUBLE reduce 633 - FALSE reduce 633 - FLOAT reduce 633 - INT reduce 633 - LONG reduce 633 - NEW reduce 633 - NULL reduce 633 - OBJECT reduce 633 - SBYTE reduce 633 - SHORT reduce 633 - SIZEOF reduce 633 - STRING reduce 633 - THIS reduce 633 - TRUE reduce 633 - TYPEOF reduce 633 - UINT reduce 633 - ULONG reduce 633 - UNCHECKED reduce 633 - USHORT reduce 633 - FROM reduce 633 - FROM_FIRST reduce 633 - OPEN_PARENS reduce 633 - TILDE reduce 633 - PLUS reduce 633 - MINUS reduce 633 - BANG reduce 633 - BITWISE_AND reduce 633 - STAR reduce 633 - OP_INC reduce 633 - OP_DEC reduce 633 - LITERAL reduce 633 - IDENTIFIER reduce 633 - OPEN_PARENS_LAMBDA reduce 633 - OPEN_PARENS_CAST reduce 633 - - block goto 765 - lambda_expression_body goto 1051 - $$66 goto 767 - - -state 989 - non_simple_argument : ARGLIST OPEN_PARENS argument_list CLOSE_PARENS . (490) - - . reduce 490 - - -state 990 - local_variable_initializer : STACKALLOC simple_type OPEN_BRACKET_EXPR . expression CLOSE_BRACKET (169) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 1052 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 991 - from_clause : FROM IDENTIFIER IN $$86 expression . (858) - - . reduce 858 - - -state 992 - from_clause : FROM type IDENTIFIER IN $$87 . expression (860) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 1053 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 993 - join_clause : JOIN IDENTIFIER IN $$93 expression . ON $$94 expression EQUALS $$95 expression opt_join_into (884) - - ON shift 1054 - . error - - -state 994 - join_clause : JOIN type IDENTIFIER IN $$96 . expression ON $$97 expression EQUALS $$98 expression opt_join_into (888) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 1055 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 995 - let_clause : LET IDENTIFIER ASSIGN $$91 expression . (878) - - . reduce 878 - - -state 996 - orderings : order_by COMMA $$100 . orderings_then_by (895) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 1056 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - orderings_then_by goto 1057 - then_by goto 1058 - - -state 997 - select_or_group_clause : GROUP $$89 expression $$90 . BY expression (867) - - BY shift 1059 - . error - - -state 998 - opt_query_continuation : INTO IDENTIFIER $$102 . query_body (907) - opt_query_body_clauses : . (868) - - WHERE shift 438 - FROM shift 439 - JOIN shift 440 - LET shift 441 - ORDERBY shift 442 - SELECT reduce 868 - GROUP reduce 868 - COMPLETE_COMPLETION reduce 868 - - query_body goto 1060 - from_clause goto 445 - opt_query_body_clauses goto 446 - query_body_clauses goto 447 - query_body_clause goto 448 - let_clause goto 449 - where_clause goto 450 - join_clause goto 451 - orderby_clause goto 452 - - -state 999 - namespace_body_body : error $$4 . CLOSE_BRACE (39) - - CLOSE_BRACE shift 1061 - . error - - -state 1000 - extern_alias_directives : extern_alias_directives extern_alias_directive . (15) - - . reduce 15 - - -state 1001 - using_directives : using_directives . using_directive (19) - opt_using_directives : using_directives . (42) - - USING shift 2 - EOF reduce 42 - ABSTRACT reduce 42 - BOOL reduce 42 - BYTE reduce 42 - CHAR reduce 42 - CLASS reduce 42 - DECIMAL reduce 42 - DELEGATE reduce 42 - DOUBLE reduce 42 - ENUM reduce 42 - EXTERN reduce 42 - FIXED reduce 42 - FLOAT reduce 42 - INT reduce 42 - INTERFACE reduce 42 - INTERNAL reduce 42 - LONG reduce 42 - NAMESPACE reduce 42 - NEW reduce 42 - OBJECT reduce 42 - OVERRIDE reduce 42 - PRIVATE reduce 42 - PROTECTED reduce 42 - PUBLIC reduce 42 - READONLY reduce 42 - SBYTE reduce 42 - SEALED reduce 42 - SHORT reduce 42 - STATIC reduce 42 - STRING reduce 42 - STRUCT reduce 42 - UINT reduce 42 - ULONG reduce 42 - UNSAFE reduce 42 - USHORT reduce 42 - VIRTUAL reduce 42 - VOID reduce 42 - VOLATILE reduce 42 - PARTIAL reduce 42 - CLOSE_BRACE reduce 42 - OPEN_BRACKET reduce 42 - IDENTIFIER reduce 42 - - using_directive goto 244 - using_alias_directive goto 17 - using_namespace_directive goto 18 - - -state 1002 - namespace_body_body : opt_extern_alias_directives opt_using_directives . opt_namespace_member_declarations CLOSE_BRACE (37) - namespace_body_body : opt_extern_alias_directives opt_using_directives . opt_namespace_member_declarations EOF (40) - opt_namespace_member_declarations : . (45) - opt_attributes : . (59) - - OPEN_BRACKET shift 4 - EOF reduce 45 - ABSTRACT reduce 59 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - CLASS reduce 59 - DECIMAL reduce 59 - DELEGATE reduce 59 - DOUBLE reduce 59 - ENUM reduce 59 - EXTERN reduce 59 - FIXED reduce 59 - FLOAT reduce 59 - INT reduce 59 - INTERFACE reduce 59 - INTERNAL reduce 59 - LONG reduce 59 - NAMESPACE reduce 59 - NEW reduce 59 - OBJECT reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - SBYTE reduce 59 - SEALED reduce 59 - SHORT reduce 59 - STATIC reduce 59 - STRING reduce 59 - STRUCT reduce 59 - UINT reduce 59 - ULONG reduce 59 - UNSAFE reduce 59 - USHORT reduce 59 - VIRTUAL reduce 59 - VOID reduce 59 - VOLATILE reduce 59 - PARTIAL reduce 59 - CLOSE_BRACE reduce 45 - IDENTIFIER reduce 59 - - namespace_member_declaration goto 1062 - namespace_declaration goto 19 - opt_attributes goto 20 - opt_namespace_member_declarations goto 1063 - namespace_member_declarations goto 1064 - type_declaration goto 21 - field_declaration goto 22 - method_declaration goto 23 - class_declaration goto 24 - struct_declaration goto 25 - interface_declaration goto 26 - enum_declaration goto 27 - delegate_declaration goto 28 - attribute_sections goto 693 - attribute_section goto 30 - method_header goto 31 - - -state 1003 - delegate_declaration : opt_attributes opt_modifiers DELEGATE member_type type_declaration_name OPEN_PARENS $$58 opt_formal_parameter_list . CLOSE_PARENS $$59 opt_type_parameter_constraints_clauses $$60 SEMICOLON (355) - - CLOSE_PARENS shift 1065 - . error - - -state 1004 - type_parameter_variance : IN . (689) - - . reduce 689 - - -state 1005 - type_parameter_variance : OUT . (688) - - . reduce 688 - - -state 1006 - type_parameter : opt_attributes opt_type_parameter_variance . IDENTIFIER (382) - - IDENTIFIER shift 1066 - . error - - -state 1007 - opt_type_parameter_variance : type_parameter_variance . (687) - - . reduce 687 - - -state 1008 - opt_type_parameter_list : OP_GENERICS_LT_DECL type_parameters OP_GENERICS_GT . (379) - - . reduce 379 - - -state 1009 - type_parameters : type_parameters COMMA . type_parameter (381) - opt_attributes : . (59) - - error shift 924 - OPEN_BRACKET shift 4 - IN reduce 59 - OUT reduce 59 - IDENTIFIER reduce 59 - - opt_attributes goto 925 - attribute_sections goto 693 - attribute_section goto 30 - type_parameter goto 1067 - - -state 1010 - enum_declaration : opt_attributes opt_modifiers ENUM type_declaration_name opt_enum_base $$54 OPEN_BRACE $$55 . opt_enum_member_declarations $$56 CLOSE_BRACE opt_semicolon (340) - opt_attributes : . (59) - opt_enum_member_declarations : . (344) - - OPEN_BRACKET shift 4 - CLOSE_BRACE reduce 344 - IDENTIFIER reduce 59 - - opt_attributes goto 1068 - attribute_sections goto 693 - attribute_section goto 30 - opt_enum_member_declarations goto 1069 - enum_member_declarations goto 1070 - enum_member_declaration goto 1071 - - -state 1011 - fixed_field_size : OPEN_BRACKET error . (161) - - . reduce 161 - - -state 1012 - fixed_field_size : OPEN_BRACKET $$18 . expression CLOSE_BRACKET (160) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 1072 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1013 - fixed_field_declarator : COMMA . IDENTIFIER fixed_field_size (158) - - IDENTIFIER shift 1073 - . error - - -state 1014 - field_declaration : opt_attributes opt_modifiers FIXED simple_type IDENTIFIER $$15 fixed_field_size opt_fixed_field_declarators . SEMICOLON (142) - - SEMICOLON shift 1074 - . error - - -state 1015 - opt_fixed_field_declarators : fixed_field_declarators . (155) - fixed_field_declarators : fixed_field_declarators . fixed_field_declarator (157) - - COMMA shift 1013 - SEMICOLON reduce 155 - - fixed_field_declarator goto 1075 - - -state 1016 - fixed_field_declarators : fixed_field_declarator . (156) - - . reduce 156 - - -state 1017 - method_header : opt_attributes opt_modifiers PARTIAL VOID method_declaration_name OPEN_PARENS $$22 opt_formal_parameter_list . CLOSE_PARENS $$23 opt_type_parameter_constraints_clauses (182) - - CLOSE_PARENS shift 1076 - . error - - -state 1018 - opt_class_base : COLON . type_list (674) - - error shift 1077 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 1078 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - type_list goto 1079 - base_type_name goto 1080 - integral_type goto 162 - - -state 1019 - class_declaration : opt_attributes opt_modifiers opt_partial CLASS $$70 type_declaration_name $$71 opt_class_base . opt_type_parameter_constraints_clauses $$72 OPEN_BRACE opt_class_member_declarations CLOSE_BRACE $$73 opt_semicolon (652) - opt_type_parameter_constraints_clauses : . (675) - - WHERE shift 1081 - OPEN_BRACE reduce 675 - - opt_type_parameter_constraints_clauses goto 1082 - type_parameter_constraints_clauses goto 1083 - type_parameter_constraints_clause goto 1084 - - -state 1020 - interface_declaration : opt_attributes opt_modifiers opt_partial INTERFACE $$33 type_declaration_name $$34 opt_class_base . opt_type_parameter_constraints_clauses $$35 OPEN_BRACE opt_interface_member_declarations CLOSE_BRACE $$36 opt_semicolon (242) - opt_type_parameter_constraints_clauses : . (675) - - WHERE shift 1081 - OPEN_BRACE reduce 675 - - opt_type_parameter_constraints_clauses goto 1085 - type_parameter_constraints_clauses goto 1083 - type_parameter_constraints_clause goto 1084 - - -state 1021 - struct_declaration : opt_attributes opt_modifiers opt_partial STRUCT $$7 type_declaration_name $$8 opt_class_base . opt_type_parameter_constraints_clauses $$9 struct_body $$10 opt_semicolon (109) - opt_type_parameter_constraints_clauses : . (675) - - WHERE shift 1081 - OPEN_BRACE reduce 675 - - opt_type_parameter_constraints_clauses goto 1086 - type_parameter_constraints_clauses goto 1083 - type_parameter_constraints_clause goto 1084 - - -state 1022 - opt_field_initializer : ASSIGN $$16 variable_initializer . (146) - - . reduce 146 - - -state 1023 - field_declarator : COMMA IDENTIFIER . (151) - field_declarator : COMMA IDENTIFIER . ASSIGN $$17 variable_initializer (153) - - ASSIGN shift 1087 - COMMA reduce 151 - SEMICOLON reduce 151 - - -state 1024 - field_declaration : opt_attributes opt_modifiers member_type IDENTIFIER $$14 opt_field_initializer opt_field_declarators SEMICOLON . (140) - - . reduce 140 - - -state 1025 - field_declarators : field_declarators field_declarator . (150) - - . reduce 150 - - -state 1026 - method_header : opt_attributes opt_modifiers member_type method_declaration_name OPEN_PARENS $$20 opt_formal_parameter_list CLOSE_PARENS . $$21 opt_type_parameter_constraints_clauses (179) - $$21 : . (178) - - . reduce 178 - - $$21 goto 1088 - - -state 1027 - method_header : opt_attributes opt_modifiers member_type modifiers method_declaration_name OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS . (183) - - . reduce 183 - - -state 1028 - fixed_parameter : opt_attributes opt_parameter_modifier parameter_type error . (201) - - . reduce 201 - - -state 1029 - fixed_parameter : opt_attributes opt_parameter_modifier parameter_type IDENTIFIER . (199) - fixed_parameter : opt_attributes opt_parameter_modifier parameter_type IDENTIFIER . OPEN_BRACKET CLOSE_BRACKET (200) - fixed_parameter : opt_attributes opt_parameter_modifier parameter_type IDENTIFIER . ASSIGN $$24 constant_expression (203) - - OPEN_BRACKET shift 1089 - ASSIGN shift 1090 - CLOSE_BRACKET reduce 199 - CLOSE_PARENS reduce 199 - COMMA reduce 199 - - -state 1030 - parameter_array : opt_attributes params_modifier type error . (213) - - . reduce 213 - - -state 1031 - parameter_array : opt_attributes params_modifier type IDENTIFIER . (211) - parameter_array : opt_attributes params_modifier type IDENTIFIER . ASSIGN constant_expression (212) - - ASSIGN shift 1091 - CLOSE_BRACKET reduce 211 - CLOSE_PARENS reduce 211 - COMMA reduce 211 - - -state 1032 - formal_parameter_list : fixed_parameters COMMA ARGLIST COMMA . error (194) - - error shift 1092 - . error - - -state 1033 - formal_parameter_list : fixed_parameters COMMA parameter_array COMMA . error (192) - - error shift 1093 - . error - - -state 1034 - do_statement : DO embedded_statement WHILE open_parens_any boolean_expression CLOSE_PARENS SEMICOLON . (786) - - . reduce 786 - - -state 1035 - fixed_statement : FIXED open_parens_any type_and_void fixed_pointer_declarators CLOSE_PARENS $$83 embedded_statement . (839) - - . reduce 839 - - -state 1036 - for_statement : FOR open_parens_any opt_for_initializer SEMICOLON $$79 opt_for_condition SEMICOLON . opt_for_iterator CLOSE_PARENS embedded_statement (788) - opt_for_iterator : . (795) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - CLOSE_PARENS reduce 795 - - expression goto 304 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - statement_expression goto 509 - opt_for_iterator goto 1094 - statement_expression_list goto 1095 - for_iterator goto 1096 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1037 - foreach_statement : FOREACH open_parens_any type IDENTIFIER IN expression CLOSE_PARENS . $$80 embedded_statement (802) - $$80 : . (801) - - . reduce 801 - - $$80 goto 1097 - - -state 1038 - if_statement : IF open_parens_any boolean_expression CLOSE_PARENS embedded_statement ELSE embedded_statement . (768) - - . reduce 768 - - -state 1039 - array_creation_expression : NEW new_expr_type OPEN_BRACKET CLOSE_BRACKET OPEN_BRACKET_EXPR error CLOSE_BRACKET . (512) - - . reduce 512 - - -state 1040 - array_creation_expression : NEW new_expr_type OPEN_BRACKET_EXPR expression_list CLOSE_BRACKET opt_rank_specifier opt_array_initializer . (509) - - . reduce 509 - - -state 1041 - switch_label : CASE . constant_expression COLON (779) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 514 - constant_expression goto 1098 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1042 - switch_label : DEFAULT_COLON . (780) - - . reduce 780 - - -state 1043 - switch_statement : SWITCH open_parens_any $$77 expression CLOSE_PARENS OPEN_BRACE opt_switch_sections . CLOSE_BRACE (770) - - CLOSE_BRACE shift 1099 - . error - - -state 1044 - opt_switch_sections : switch_sections . (772) - switch_sections : switch_sections . switch_section (774) - - CASE shift 1041 - DEFAULT_COLON shift 1042 - CLOSE_BRACE reduce 772 - - switch_section goto 1100 - switch_labels goto 1046 - switch_label goto 1047 - - -state 1045 - switch_sections : switch_section . (773) - - . reduce 773 - - -state 1046 - switch_section : switch_labels . $$78 statement_list (776) - switch_labels : switch_labels . switch_label (778) - $$78 : . (775) - - CASE shift 1041 - DEFAULT_COLON shift 1042 - error reduce 775 - BASE reduce 775 - BOOL reduce 775 - BREAK reduce 775 - BYTE reduce 775 - CHAR reduce 775 - CHECKED reduce 775 - CONST reduce 775 - CONTINUE reduce 775 - DECIMAL reduce 775 - DEFAULT reduce 775 - DELEGATE reduce 775 - DO reduce 775 - DOUBLE reduce 775 - FALSE reduce 775 - FIXED reduce 775 - FLOAT reduce 775 - FOR reduce 775 - FOREACH reduce 775 - GOTO reduce 775 - IF reduce 775 - INT reduce 775 - LOCK reduce 775 - LONG reduce 775 - NEW reduce 775 - NULL reduce 775 - OBJECT reduce 775 - RETURN reduce 775 - SBYTE reduce 775 - SHORT reduce 775 - SIZEOF reduce 775 - STRING reduce 775 - SWITCH reduce 775 - THIS reduce 775 - THROW reduce 775 - TRUE reduce 775 - TRY reduce 775 - TYPEOF reduce 775 - UINT reduce 775 - ULONG reduce 775 - UNCHECKED reduce 775 - UNSAFE reduce 775 - USHORT reduce 775 - USING reduce 775 - VOID reduce 775 - WHILE reduce 775 - FROM reduce 775 - FROM_FIRST reduce 775 - OPEN_BRACE reduce 775 - OPEN_PARENS reduce 775 - SEMICOLON reduce 775 - TILDE reduce 775 - PLUS reduce 775 - MINUS reduce 775 - BANG reduce 775 - BITWISE_AND reduce 775 - STAR reduce 775 - OP_INC reduce 775 - OP_DEC reduce 775 - LITERAL reduce 775 - IDENTIFIER reduce 775 - OPEN_PARENS_LAMBDA reduce 775 - OPEN_PARENS_CAST reduce 775 - - $$78 goto 1101 - switch_label goto 1102 - - -state 1047 - switch_labels : switch_label . (777) - - . reduce 777 - - -state 1048 - catch_args : open_parens_any type opt_identifier CLOSE_PARENS . (832) - - . reduce 832 - - -state 1049 - unbound_type_name : namespace_or_type_name DOT IDENTIFIER generic_dimension . (553) - - . reduce 553 - - -state 1050 - unbound_type_name : unbound_type_name DOT IDENTIFIER generic_dimension . (552) - - . reduce 552 - - -state 1051 - lambda_expression : OPEN_PARENS_LAMBDA $$68 opt_lambda_parameter_list CLOSE_PARENS ARROW $$69 lambda_expression_body . (640) - - . reduce 640 - - -state 1052 - local_variable_initializer : STACKALLOC simple_type OPEN_BRACKET_EXPR expression . CLOSE_BRACKET (169) - - CLOSE_BRACKET shift 1103 - . error - - -state 1053 - from_clause : FROM type IDENTIFIER IN $$87 expression . (860) - - . reduce 860 - - -state 1054 - join_clause : JOIN IDENTIFIER IN $$93 expression ON . $$94 expression EQUALS $$95 expression opt_join_into (884) - $$94 : . (882) - - . reduce 882 - - $$94 goto 1104 - - -state 1055 - join_clause : JOIN type IDENTIFIER IN $$96 expression . ON $$97 expression EQUALS $$98 expression opt_join_into (888) - - ON shift 1105 - . error - - -state 1056 - then_by : expression . (902) - then_by : expression . ASCENDING (903) - then_by : expression . DESCENDING (904) - - ASCENDING shift 1106 - DESCENDING shift 1107 - WHERE reduce 902 - FROM reduce 902 - JOIN reduce 902 - SELECT reduce 902 - GROUP reduce 902 - LET reduce 902 - ORDERBY reduce 902 - COMMA reduce 902 - COMPLETE_COMPLETION reduce 902 - - -state 1057 - orderings : order_by COMMA $$100 orderings_then_by . (895) - orderings_then_by : orderings_then_by . COMMA $$101 then_by (898) - - COMMA shift 1108 - WHERE reduce 895 - FROM reduce 895 - JOIN reduce 895 - SELECT reduce 895 - GROUP reduce 895 - LET reduce 895 - ORDERBY reduce 895 - COMPLETE_COMPLETION reduce 895 - - -state 1058 - orderings_then_by : then_by . (896) - - . reduce 896 - - -state 1059 - select_or_group_clause : GROUP $$89 expression $$90 BY . expression (867) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 1109 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1060 - opt_query_continuation : INTO IDENTIFIER $$102 query_body . (907) - - . reduce 907 - - -state 1061 - namespace_body_body : error $$4 CLOSE_BRACE . (39) - - . reduce 39 - - -state 1062 - namespace_member_declarations : namespace_member_declaration . (47) - - . reduce 47 - - -state 1063 - namespace_body_body : opt_extern_alias_directives opt_using_directives opt_namespace_member_declarations . CLOSE_BRACE (37) - namespace_body_body : opt_extern_alias_directives opt_using_directives opt_namespace_member_declarations . EOF (40) - - EOF shift 1110 - CLOSE_BRACE shift 1111 - . error - - -state 1064 - opt_namespace_member_declarations : namespace_member_declarations . (46) - namespace_member_declarations : namespace_member_declarations . namespace_member_declaration (48) - opt_attributes : . (59) - - OPEN_BRACKET shift 4 - EOF reduce 46 - ABSTRACT reduce 59 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - CLASS reduce 59 - DECIMAL reduce 59 - DELEGATE reduce 59 - DOUBLE reduce 59 - ENUM reduce 59 - EXTERN reduce 59 - FIXED reduce 59 - FLOAT reduce 59 - INT reduce 59 - INTERFACE reduce 59 - INTERNAL reduce 59 - LONG reduce 59 - NAMESPACE reduce 59 - NEW reduce 59 - OBJECT reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - SBYTE reduce 59 - SEALED reduce 59 - SHORT reduce 59 - STATIC reduce 59 - STRING reduce 59 - STRUCT reduce 59 - UINT reduce 59 - ULONG reduce 59 - UNSAFE reduce 59 - USHORT reduce 59 - VIRTUAL reduce 59 - VOID reduce 59 - VOLATILE reduce 59 - PARTIAL reduce 59 - CLOSE_BRACE reduce 46 - IDENTIFIER reduce 59 - - namespace_member_declaration goto 1112 - namespace_declaration goto 19 - opt_attributes goto 20 - type_declaration goto 21 - field_declaration goto 22 - method_declaration goto 23 - class_declaration goto 24 - struct_declaration goto 25 - interface_declaration goto 26 - enum_declaration goto 27 - delegate_declaration goto 28 - attribute_sections goto 693 - attribute_section goto 30 - method_header goto 31 - - -state 1065 - delegate_declaration : opt_attributes opt_modifiers DELEGATE member_type type_declaration_name OPEN_PARENS $$58 opt_formal_parameter_list CLOSE_PARENS . $$59 opt_type_parameter_constraints_clauses $$60 SEMICOLON (355) - $$59 : . (353) - - . reduce 353 - - $$59 goto 1113 - - -state 1066 - type_parameter : opt_attributes opt_type_parameter_variance IDENTIFIER . (382) - - . reduce 382 - - -state 1067 - type_parameters : type_parameters COMMA type_parameter . (381) - - . reduce 381 - - -state 1068 - enum_member_declaration : opt_attributes . IDENTIFIER (349) - enum_member_declaration : opt_attributes . IDENTIFIER $$57 ASSIGN constant_expression (351) - - IDENTIFIER shift 1114 - . error - - -state 1069 - enum_declaration : opt_attributes opt_modifiers ENUM type_declaration_name opt_enum_base $$54 OPEN_BRACE $$55 opt_enum_member_declarations . $$56 CLOSE_BRACE opt_semicolon (340) - $$56 : . (339) - - . reduce 339 - - $$56 goto 1115 - - -state 1070 - opt_enum_member_declarations : enum_member_declarations . (345) - opt_enum_member_declarations : enum_member_declarations . COMMA (346) - enum_member_declarations : enum_member_declarations . COMMA enum_member_declaration (348) - - COMMA shift 1116 - CLOSE_BRACE reduce 345 - - -state 1071 - enum_member_declarations : enum_member_declaration . (347) - - . reduce 347 - - -state 1072 - fixed_field_size : OPEN_BRACKET $$18 expression . CLOSE_BRACKET (160) - - CLOSE_BRACKET shift 1117 - . error - - -state 1073 - fixed_field_declarator : COMMA IDENTIFIER . fixed_field_size (158) - - OPEN_BRACKET shift 929 - . error - - fixed_field_size goto 1118 - - -state 1074 - field_declaration : opt_attributes opt_modifiers FIXED simple_type IDENTIFIER $$15 fixed_field_size opt_fixed_field_declarators SEMICOLON . (142) - - . reduce 142 - - -state 1075 - fixed_field_declarators : fixed_field_declarators fixed_field_declarator . (157) - - . reduce 157 - - -state 1076 - method_header : opt_attributes opt_modifiers PARTIAL VOID method_declaration_name OPEN_PARENS $$22 opt_formal_parameter_list CLOSE_PARENS . $$23 opt_type_parameter_constraints_clauses (182) - $$23 : . (181) - - . reduce 181 - - $$23 goto 1119 - - -state 1077 - base_type_name : error . (402) - - . reduce 402 - - -state 1078 - base_type_name : type . (401) - - . reduce 401 - - -state 1079 - type_list : type_list . COMMA base_type_name (400) - opt_class_base : COLON type_list . (674) - - COMMA shift 1120 - WHERE reduce 674 - OPEN_BRACE reduce 674 - - -state 1080 - type_list : base_type_name . (399) - - . reduce 399 - - -state 1081 - type_parameter_constraints_clause : WHERE . IDENTIFIER COLON type_parameter_constraints (679) - - IDENTIFIER shift 1121 - . error - - -state 1082 - class_declaration : opt_attributes opt_modifiers opt_partial CLASS $$70 type_declaration_name $$71 opt_class_base opt_type_parameter_constraints_clauses . $$72 OPEN_BRACE opt_class_member_declarations CLOSE_BRACE $$73 opt_semicolon (652) - $$72 : . (650) - - . reduce 650 - - $$72 goto 1122 - - -state 1083 - opt_type_parameter_constraints_clauses : type_parameter_constraints_clauses . (676) - type_parameter_constraints_clauses : type_parameter_constraints_clauses . type_parameter_constraints_clause (678) - - WHERE shift 1081 - OPEN_BRACE reduce 676 - SEMICOLON reduce 676 - - type_parameter_constraints_clause goto 1123 - - -state 1084 - type_parameter_constraints_clauses : type_parameter_constraints_clause . (677) - - . reduce 677 - - -state 1085 - interface_declaration : opt_attributes opt_modifiers opt_partial INTERFACE $$33 type_declaration_name $$34 opt_class_base opt_type_parameter_constraints_clauses . $$35 OPEN_BRACE opt_interface_member_declarations CLOSE_BRACE $$36 opt_semicolon (242) - $$35 : . (240) - - . reduce 240 - - $$35 goto 1124 - - -state 1086 - struct_declaration : opt_attributes opt_modifiers opt_partial STRUCT $$7 type_declaration_name $$8 opt_class_base opt_type_parameter_constraints_clauses . $$9 struct_body $$10 opt_semicolon (109) - $$9 : . (107) - - . reduce 107 - - $$9 goto 1125 - - -state 1087 - field_declarator : COMMA IDENTIFIER ASSIGN . $$17 variable_initializer (153) - $$17 : . (152) - - . reduce 152 - - $$17 goto 1126 - - -state 1088 - method_header : opt_attributes opt_modifiers member_type method_declaration_name OPEN_PARENS $$20 opt_formal_parameter_list CLOSE_PARENS $$21 . opt_type_parameter_constraints_clauses (179) - opt_type_parameter_constraints_clauses : . (675) - - WHERE shift 1081 - OPEN_BRACE reduce 675 - SEMICOLON reduce 675 - - opt_type_parameter_constraints_clauses goto 1127 - type_parameter_constraints_clauses goto 1083 - type_parameter_constraints_clause goto 1084 - - -state 1089 - fixed_parameter : opt_attributes opt_parameter_modifier parameter_type IDENTIFIER OPEN_BRACKET . CLOSE_BRACKET (200) - - CLOSE_BRACKET shift 1128 - . error - - -state 1090 - fixed_parameter : opt_attributes opt_parameter_modifier parameter_type IDENTIFIER ASSIGN . $$24 constant_expression (203) - $$24 : . (202) - - . reduce 202 - - $$24 goto 1129 - - -state 1091 - parameter_array : opt_attributes params_modifier type IDENTIFIER ASSIGN . constant_expression (212) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 514 - constant_expression goto 1130 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1092 - formal_parameter_list : fixed_parameters COMMA ARGLIST COMMA error . (194) - - . reduce 194 - - -state 1093 - formal_parameter_list : fixed_parameters COMMA parameter_array COMMA error . (192) - - . reduce 192 - - -state 1094 - for_statement : FOR open_parens_any opt_for_initializer SEMICOLON $$79 opt_for_condition SEMICOLON opt_for_iterator . CLOSE_PARENS embedded_statement (788) - - CLOSE_PARENS shift 1131 - . error - - -state 1095 - for_iterator : statement_expression_list . (797) - statement_expression_list : statement_expression_list . COMMA statement_expression (799) - - COMMA shift 706 - CLOSE_PARENS reduce 797 - - -state 1096 - opt_for_iterator : for_iterator . (796) - - . reduce 796 - - -state 1097 - foreach_statement : FOREACH open_parens_any type IDENTIFIER IN expression CLOSE_PARENS $$80 . embedded_statement (802) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BREAK shift 98 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 101 - CONST shift 102 - CONTINUE shift 103 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DO shift 107 - DOUBLE shift 108 - FALSE shift 109 - FIXED shift 110 - FLOAT shift 111 - FOR shift 112 - FOREACH shift 113 - GOTO shift 114 - IF shift 115 - INT shift 116 - LOCK shift 117 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - RETURN shift 122 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - SWITCH shift 127 - THIS shift 128 - THROW shift 129 - TRUE shift 130 - TRY shift 131 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 135 - UNSAFE shift 136 - USHORT shift 137 - USING shift 138 - VOID shift 139 - WHILE shift 140 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 143 - OPEN_PARENS shift 144 - SEMICOLON shift 145 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 155 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 304 - block goto 305 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - declaration_statement goto 306 - valid_declaration_statement goto 307 - labeled_statement goto 308 - empty_statement goto 309 - expression_statement goto 310 - selection_statement goto 311 - iteration_statement goto 312 - jump_statement goto 313 - try_statement goto 314 - checked_statement goto 315 - unchecked_statement goto 316 - lock_statement goto 317 - using_statement goto 318 - unsafe_statement goto 319 - fixed_statement goto 320 - embedded_statement goto 1132 - local_variable_declaration goto 221 - local_constant_declaration goto 222 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - statement_expression goto 322 - if_statement goto 227 - switch_statement goto 228 - while_statement goto 229 - do_statement goto 230 - for_statement goto 231 - foreach_statement goto 232 - break_statement goto 233 - continue_statement goto 234 - goto_statement goto 235 - return_statement goto 236 - throw_statement goto 237 - yield_statement goto 238 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1098 - switch_label : CASE constant_expression . COLON (779) - - COLON shift 1133 - . error - - -state 1099 - switch_statement : SWITCH open_parens_any $$77 expression CLOSE_PARENS OPEN_BRACE opt_switch_sections CLOSE_BRACE . (770) - - . reduce 770 - - -state 1100 - switch_sections : switch_sections switch_section . (774) - - . reduce 774 - - -state 1101 - switch_section : switch_labels $$78 . statement_list (776) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BREAK shift 98 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 101 - CONST shift 102 - CONTINUE shift 103 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DO shift 107 - DOUBLE shift 108 - FALSE shift 109 - FIXED shift 110 - FLOAT shift 111 - FOR shift 112 - FOREACH shift 113 - GOTO shift 114 - IF shift 115 - INT shift 116 - LOCK shift 117 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - RETURN shift 122 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - SWITCH shift 127 - THIS shift 128 - THROW shift 129 - TRUE shift 130 - TRY shift 131 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 135 - UNSAFE shift 136 - USHORT shift 137 - USING shift 138 - VOID shift 139 - WHILE shift 140 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 143 - OPEN_PARENS shift 144 - SEMICOLON shift 145 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 155 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 304 - block goto 305 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - statement_list goto 1134 - statement goto 563 - declaration_statement goto 564 - valid_declaration_statement goto 565 - labeled_statement goto 566 - empty_statement goto 309 - expression_statement goto 310 - selection_statement goto 311 - iteration_statement goto 312 - jump_statement goto 313 - try_statement goto 314 - checked_statement goto 315 - unchecked_statement goto 316 - lock_statement goto 317 - using_statement goto 318 - unsafe_statement goto 319 - fixed_statement goto 320 - local_variable_declaration goto 221 - local_constant_declaration goto 222 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - statement_expression goto 322 - if_statement goto 227 - switch_statement goto 228 - while_statement goto 229 - do_statement goto 230 - for_statement goto 231 - foreach_statement goto 232 - break_statement goto 233 - continue_statement goto 234 - goto_statement goto 235 - return_statement goto 236 - throw_statement goto 237 - yield_statement goto 238 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1102 - switch_labels : switch_labels switch_label . (778) - - . reduce 778 - - -state 1103 - local_variable_initializer : STACKALLOC simple_type OPEN_BRACKET_EXPR expression CLOSE_BRACKET . (169) - - . reduce 169 - - -state 1104 - join_clause : JOIN IDENTIFIER IN $$93 expression ON $$94 . expression EQUALS $$95 expression opt_join_into (884) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 1135 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1105 - join_clause : JOIN type IDENTIFIER IN $$96 expression ON . $$97 expression EQUALS $$98 expression opt_join_into (888) - $$97 : . (886) - - . reduce 886 - - $$97 goto 1136 - - -state 1106 - then_by : expression ASCENDING . (903) - - . reduce 903 - - -state 1107 - then_by : expression DESCENDING . (904) - - . reduce 904 - - -state 1108 - orderings_then_by : orderings_then_by COMMA . $$101 then_by (898) - $$101 : . (897) - - . reduce 897 - - $$101 goto 1137 - - -state 1109 - select_or_group_clause : GROUP $$89 expression $$90 BY expression . (867) - - . reduce 867 - - -state 1110 - namespace_body_body : opt_extern_alias_directives opt_using_directives opt_namespace_member_declarations EOF . (40) - - . reduce 40 - - -state 1111 - namespace_body_body : opt_extern_alias_directives opt_using_directives opt_namespace_member_declarations CLOSE_BRACE . (37) - - . reduce 37 - - -state 1112 - namespace_member_declarations : namespace_member_declarations namespace_member_declaration . (48) - - . reduce 48 - - -state 1113 - delegate_declaration : opt_attributes opt_modifiers DELEGATE member_type type_declaration_name OPEN_PARENS $$58 opt_formal_parameter_list CLOSE_PARENS $$59 . opt_type_parameter_constraints_clauses $$60 SEMICOLON (355) - opt_type_parameter_constraints_clauses : . (675) - - WHERE shift 1081 - SEMICOLON reduce 675 - - opt_type_parameter_constraints_clauses goto 1138 - type_parameter_constraints_clauses goto 1083 - type_parameter_constraints_clause goto 1084 - - -state 1114 - enum_member_declaration : opt_attributes IDENTIFIER . (349) - enum_member_declaration : opt_attributes IDENTIFIER . $$57 ASSIGN constant_expression (351) - $$57 : . (350) - - CLOSE_BRACE reduce 349 - COMMA reduce 349 - ASSIGN reduce 350 - - $$57 goto 1139 - - -state 1115 - enum_declaration : opt_attributes opt_modifiers ENUM type_declaration_name opt_enum_base $$54 OPEN_BRACE $$55 opt_enum_member_declarations $$56 . CLOSE_BRACE opt_semicolon (340) - - CLOSE_BRACE shift 1140 - . error - - -state 1116 - opt_enum_member_declarations : enum_member_declarations COMMA . (346) - enum_member_declarations : enum_member_declarations COMMA . enum_member_declaration (348) - opt_attributes : . (59) - - OPEN_BRACKET shift 4 - CLOSE_BRACE reduce 346 - IDENTIFIER reduce 59 - - opt_attributes goto 1068 - attribute_sections goto 693 - attribute_section goto 30 - enum_member_declaration goto 1141 - - -state 1117 - fixed_field_size : OPEN_BRACKET $$18 expression CLOSE_BRACKET . (160) - - . reduce 160 - - -state 1118 - fixed_field_declarator : COMMA IDENTIFIER fixed_field_size . (158) - - . reduce 158 - - -state 1119 - method_header : opt_attributes opt_modifiers PARTIAL VOID method_declaration_name OPEN_PARENS $$22 opt_formal_parameter_list CLOSE_PARENS $$23 . opt_type_parameter_constraints_clauses (182) - opt_type_parameter_constraints_clauses : . (675) - - WHERE shift 1081 - OPEN_BRACE reduce 675 - SEMICOLON reduce 675 - - opt_type_parameter_constraints_clauses goto 1142 - type_parameter_constraints_clauses goto 1083 - type_parameter_constraints_clause goto 1084 - - -state 1120 - type_list : type_list COMMA . base_type_name (400) - - error shift 1077 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 1078 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - base_type_name goto 1143 - integral_type goto 162 - - -state 1121 - type_parameter_constraints_clause : WHERE IDENTIFIER . COLON type_parameter_constraints (679) - - COLON shift 1144 - . error - - -state 1122 - class_declaration : opt_attributes opt_modifiers opt_partial CLASS $$70 type_declaration_name $$71 opt_class_base opt_type_parameter_constraints_clauses $$72 . OPEN_BRACE opt_class_member_declarations CLOSE_BRACE $$73 opt_semicolon (652) - - OPEN_BRACE shift 1145 - . error - - -state 1123 - type_parameter_constraints_clauses : type_parameter_constraints_clauses type_parameter_constraints_clause . (678) - - . reduce 678 - - -state 1124 - interface_declaration : opt_attributes opt_modifiers opt_partial INTERFACE $$33 type_declaration_name $$34 opt_class_base opt_type_parameter_constraints_clauses $$35 . OPEN_BRACE opt_interface_member_declarations CLOSE_BRACE $$36 opt_semicolon (242) - - OPEN_BRACE shift 1146 - . error - - -state 1125 - struct_declaration : opt_attributes opt_modifiers opt_partial STRUCT $$7 type_declaration_name $$8 opt_class_base opt_type_parameter_constraints_clauses $$9 . struct_body $$10 opt_semicolon (109) - - OPEN_BRACE shift 1147 - . error - - struct_body goto 1148 - - -state 1126 - field_declarator : COMMA IDENTIFIER ASSIGN $$17 . variable_initializer (153) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 531 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 719 - array_initializer goto 720 - variable_initializer goto 1149 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1127 - method_header : opt_attributes opt_modifiers member_type method_declaration_name OPEN_PARENS $$20 opt_formal_parameter_list CLOSE_PARENS $$21 opt_type_parameter_constraints_clauses . (179) - - . reduce 179 - - -state 1128 - fixed_parameter : opt_attributes opt_parameter_modifier parameter_type IDENTIFIER OPEN_BRACKET CLOSE_BRACKET . (200) - - . reduce 200 - - -state 1129 - fixed_parameter : opt_attributes opt_parameter_modifier parameter_type IDENTIFIER ASSIGN $$24 . constant_expression (203) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 514 - constant_expression goto 1150 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1130 - parameter_array : opt_attributes params_modifier type IDENTIFIER ASSIGN constant_expression . (212) - - . reduce 212 - - -state 1131 - for_statement : FOR open_parens_any opt_for_initializer SEMICOLON $$79 opt_for_condition SEMICOLON opt_for_iterator CLOSE_PARENS . embedded_statement (788) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BREAK shift 98 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 101 - CONST shift 102 - CONTINUE shift 103 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DO shift 107 - DOUBLE shift 108 - FALSE shift 109 - FIXED shift 110 - FLOAT shift 111 - FOR shift 112 - FOREACH shift 113 - GOTO shift 114 - IF shift 115 - INT shift 116 - LOCK shift 117 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - RETURN shift 122 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - SWITCH shift 127 - THIS shift 128 - THROW shift 129 - TRUE shift 130 - TRY shift 131 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 135 - UNSAFE shift 136 - USHORT shift 137 - USING shift 138 - VOID shift 139 - WHILE shift 140 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 143 - OPEN_PARENS shift 144 - SEMICOLON shift 145 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 155 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 304 - block goto 305 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - declaration_statement goto 306 - valid_declaration_statement goto 307 - labeled_statement goto 308 - empty_statement goto 309 - expression_statement goto 310 - selection_statement goto 311 - iteration_statement goto 312 - jump_statement goto 313 - try_statement goto 314 - checked_statement goto 315 - unchecked_statement goto 316 - lock_statement goto 317 - using_statement goto 318 - unsafe_statement goto 319 - fixed_statement goto 320 - embedded_statement goto 1151 - local_variable_declaration goto 221 - local_constant_declaration goto 222 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - statement_expression goto 322 - if_statement goto 227 - switch_statement goto 228 - while_statement goto 229 - do_statement goto 230 - for_statement goto 231 - foreach_statement goto 232 - break_statement goto 233 - continue_statement goto 234 - goto_statement goto 235 - return_statement goto 236 - throw_statement goto 237 - yield_statement goto 238 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1132 - foreach_statement : FOREACH open_parens_any type IDENTIFIER IN expression CLOSE_PARENS $$80 embedded_statement . (802) - - . reduce 802 - - -state 1133 - switch_label : CASE constant_expression COLON . (779) - - . reduce 779 - - -state 1134 - statement_list : statement_list . statement (699) - switch_section : switch_labels $$78 statement_list . (776) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BREAK shift 98 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 101 - CONST shift 102 - CONTINUE shift 103 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DO shift 107 - DOUBLE shift 108 - FALSE shift 109 - FIXED shift 110 - FLOAT shift 111 - FOR shift 112 - FOREACH shift 113 - GOTO shift 114 - IF shift 115 - INT shift 116 - LOCK shift 117 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - RETURN shift 122 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - SWITCH shift 127 - THIS shift 128 - THROW shift 129 - TRUE shift 130 - TRY shift 131 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 135 - UNSAFE shift 136 - USHORT shift 137 - USING shift 138 - VOID shift 139 - WHILE shift 140 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 143 - OPEN_PARENS shift 144 - SEMICOLON shift 145 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 155 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - CASE reduce 776 - CLOSE_BRACE reduce 776 - DEFAULT_COLON reduce 776 - - expression goto 304 - block goto 305 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - statement goto 762 - declaration_statement goto 564 - valid_declaration_statement goto 565 - labeled_statement goto 566 - empty_statement goto 309 - expression_statement goto 310 - selection_statement goto 311 - iteration_statement goto 312 - jump_statement goto 313 - try_statement goto 314 - checked_statement goto 315 - unchecked_statement goto 316 - lock_statement goto 317 - using_statement goto 318 - unsafe_statement goto 319 - fixed_statement goto 320 - local_variable_declaration goto 221 - local_constant_declaration goto 222 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - statement_expression goto 322 - if_statement goto 227 - switch_statement goto 228 - while_statement goto 229 - do_statement goto 230 - for_statement goto 231 - foreach_statement goto 232 - break_statement goto 233 - continue_statement goto 234 - goto_statement goto 235 - return_statement goto 236 - throw_statement goto 237 - yield_statement goto 238 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1135 - join_clause : JOIN IDENTIFIER IN $$93 expression ON $$94 expression . EQUALS $$95 expression opt_join_into (884) - - EQUALS shift 1152 - . error - - -state 1136 - join_clause : JOIN type IDENTIFIER IN $$96 expression ON $$97 . expression EQUALS $$98 expression opt_join_into (888) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 1153 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1137 - orderings_then_by : orderings_then_by COMMA $$101 . then_by (898) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 1056 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - then_by goto 1154 - - -state 1138 - delegate_declaration : opt_attributes opt_modifiers DELEGATE member_type type_declaration_name OPEN_PARENS $$58 opt_formal_parameter_list CLOSE_PARENS $$59 opt_type_parameter_constraints_clauses . $$60 SEMICOLON (355) - $$60 : . (354) - - . reduce 354 - - $$60 goto 1155 - - -state 1139 - enum_member_declaration : opt_attributes IDENTIFIER $$57 . ASSIGN constant_expression (351) - - ASSIGN shift 1156 - . error - - -state 1140 - enum_declaration : opt_attributes opt_modifiers ENUM type_declaration_name opt_enum_base $$54 OPEN_BRACE $$55 opt_enum_member_declarations $$56 CLOSE_BRACE . opt_semicolon (340) - opt_semicolon : . (30) - - SEMICOLON shift 810 - $end reduce 30 - error reduce 30 - EOF reduce 30 - ABSTRACT reduce 30 - BOOL reduce 30 - BYTE reduce 30 - CHAR reduce 30 - CLASS reduce 30 - CONST reduce 30 - DECIMAL reduce 30 - DELEGATE reduce 30 - DOUBLE reduce 30 - ENUM reduce 30 - EVENT reduce 30 - EXPLICIT reduce 30 - EXTERN reduce 30 - FIXED reduce 30 - FLOAT reduce 30 - IMPLICIT reduce 30 - INT reduce 30 - INTERFACE reduce 30 - INTERNAL reduce 30 - LONG reduce 30 - NAMESPACE reduce 30 - NEW reduce 30 - OBJECT reduce 30 - OVERRIDE reduce 30 - PRIVATE reduce 30 - PROTECTED reduce 30 - PUBLIC reduce 30 - READONLY reduce 30 - SBYTE reduce 30 - SEALED reduce 30 - SHORT reduce 30 - STATIC reduce 30 - STRING reduce 30 - STRUCT reduce 30 - UINT reduce 30 - ULONG reduce 30 - UNSAFE reduce 30 - USHORT reduce 30 - USING reduce 30 - VIRTUAL reduce 30 - VOID reduce 30 - VOLATILE reduce 30 - PARTIAL reduce 30 - EXTERN_ALIAS reduce 30 - CLOSE_BRACE reduce 30 - OPEN_BRACKET reduce 30 - TILDE reduce 30 - IDENTIFIER reduce 30 - - opt_semicolon goto 1157 - - -state 1141 - enum_member_declarations : enum_member_declarations COMMA enum_member_declaration . (348) - - . reduce 348 - - -state 1142 - method_header : opt_attributes opt_modifiers PARTIAL VOID method_declaration_name OPEN_PARENS $$22 opt_formal_parameter_list CLOSE_PARENS $$23 opt_type_parameter_constraints_clauses . (182) - - . reduce 182 - - -state 1143 - type_list : type_list COMMA base_type_name . (400) - - . reduce 400 - - -state 1144 - type_parameter_constraints_clause : WHERE IDENTIFIER COLON . type_parameter_constraints (679) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CLASS shift 1158 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 1159 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - STRUCT shift 1160 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 1161 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - type_parameter_constraints goto 1162 - type_parameter_constraint goto 1163 - - -state 1145 - class_declaration : opt_attributes opt_modifiers opt_partial CLASS $$70 type_declaration_name $$71 opt_class_base opt_type_parameter_constraints_clauses $$72 OPEN_BRACE . opt_class_member_declarations CLOSE_BRACE $$73 opt_semicolon (652) - opt_attributes : . (59) - opt_class_member_declarations : . (90) - - error shift 1164 - OPEN_BRACKET shift 4 - ABSTRACT reduce 59 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - CLASS reduce 59 - CONST reduce 59 - DECIMAL reduce 59 - DELEGATE reduce 59 - DOUBLE reduce 59 - ENUM reduce 59 - EVENT reduce 59 - EXPLICIT reduce 59 - EXTERN reduce 59 - FIXED reduce 59 - FLOAT reduce 59 - IMPLICIT reduce 59 - INT reduce 59 - INTERFACE reduce 59 - INTERNAL reduce 59 - LONG reduce 59 - NEW reduce 59 - OBJECT reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - SBYTE reduce 59 - SEALED reduce 59 - SHORT reduce 59 - STATIC reduce 59 - STRING reduce 59 - STRUCT reduce 59 - UINT reduce 59 - ULONG reduce 59 - UNSAFE reduce 59 - USHORT reduce 59 - VIRTUAL reduce 59 - VOID reduce 59 - VOLATILE reduce 59 - PARTIAL reduce 59 - CLOSE_BRACE reduce 90 - TILDE reduce 59 - IDENTIFIER reduce 59 - - opt_attributes goto 1165 - type_declaration goto 1166 - field_declaration goto 1167 - method_declaration goto 1168 - class_declaration goto 24 - struct_declaration goto 25 - interface_declaration goto 26 - enum_declaration goto 27 - delegate_declaration goto 28 - attribute_sections goto 693 - attribute_section goto 30 - opt_class_member_declarations goto 1169 - class_member_declarations goto 1170 - class_member_declaration goto 1171 - constant_declaration goto 1172 - property_declaration goto 1173 - event_declaration goto 1174 - indexer_declaration goto 1175 - operator_declaration goto 1176 - constructor_declaration goto 1177 - destructor_declaration goto 1178 - method_header goto 31 - constructor_declarator goto 1179 - - -state 1146 - interface_declaration : opt_attributes opt_modifiers opt_partial INTERFACE $$33 type_declaration_name $$34 opt_class_base opt_type_parameter_constraints_clauses $$35 OPEN_BRACE . opt_interface_member_declarations CLOSE_BRACE $$36 opt_semicolon (242) - opt_attributes : . (59) - opt_interface_member_declarations : . (244) - - OPEN_BRACKET shift 4 - ABSTRACT reduce 59 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - CLASS reduce 59 - CONST reduce 59 - DECIMAL reduce 59 - DELEGATE reduce 59 - DOUBLE reduce 59 - ENUM reduce 59 - EVENT reduce 59 - EXPLICIT reduce 59 - EXTERN reduce 59 - FIXED reduce 59 - FLOAT reduce 59 - IMPLICIT reduce 59 - INT reduce 59 - INTERFACE reduce 59 - INTERNAL reduce 59 - LONG reduce 59 - NEW reduce 59 - OBJECT reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - SBYTE reduce 59 - SEALED reduce 59 - SHORT reduce 59 - STATIC reduce 59 - STRING reduce 59 - STRUCT reduce 59 - UINT reduce 59 - ULONG reduce 59 - UNSAFE reduce 59 - USHORT reduce 59 - VIRTUAL reduce 59 - VOID reduce 59 - VOLATILE reduce 59 - PARTIAL reduce 59 - CLOSE_BRACE reduce 244 - IDENTIFIER reduce 59 - - opt_attributes goto 1180 - type_declaration goto 1181 - field_declaration goto 1182 - method_declaration goto 1183 - class_declaration goto 24 - struct_declaration goto 25 - interface_declaration goto 26 - enum_declaration goto 27 - delegate_declaration goto 28 - attribute_sections goto 693 - attribute_section goto 30 - constant_declaration goto 1184 - property_declaration goto 1185 - event_declaration goto 1186 - indexer_declaration goto 1187 - operator_declaration goto 1188 - constructor_declaration goto 1189 - method_header goto 31 - opt_interface_member_declarations goto 1190 - interface_member_declarations goto 1191 - interface_member_declaration goto 1192 - constructor_declarator goto 1179 - - -state 1147 - struct_body : OPEN_BRACE . $$11 opt_struct_member_declarations CLOSE_BRACE (112) - $$11 : . (111) - - . reduce 111 - - $$11 goto 1193 - - -state 1148 - struct_declaration : opt_attributes opt_modifiers opt_partial STRUCT $$7 type_declaration_name $$8 opt_class_base opt_type_parameter_constraints_clauses $$9 struct_body . $$10 opt_semicolon (109) - $$10 : . (108) - - . reduce 108 - - $$10 goto 1194 - - -state 1149 - field_declarator : COMMA IDENTIFIER ASSIGN $$17 variable_initializer . (153) - - . reduce 153 - - -state 1150 - fixed_parameter : opt_attributes opt_parameter_modifier parameter_type IDENTIFIER ASSIGN $$24 constant_expression . (203) - - . reduce 203 - - -state 1151 - for_statement : FOR open_parens_any opt_for_initializer SEMICOLON $$79 opt_for_condition SEMICOLON opt_for_iterator CLOSE_PARENS embedded_statement . (788) - - . reduce 788 - - -state 1152 - join_clause : JOIN IDENTIFIER IN $$93 expression ON $$94 expression EQUALS . $$95 expression opt_join_into (884) - $$95 : . (883) - - . reduce 883 - - $$95 goto 1195 - - -state 1153 - join_clause : JOIN type IDENTIFIER IN $$96 expression ON $$97 expression . EQUALS $$98 expression opt_join_into (888) - - EQUALS shift 1196 - . error - - -state 1154 - orderings_then_by : orderings_then_by COMMA $$101 then_by . (898) - - . reduce 898 - - -state 1155 - delegate_declaration : opt_attributes opt_modifiers DELEGATE member_type type_declaration_name OPEN_PARENS $$58 opt_formal_parameter_list CLOSE_PARENS $$59 opt_type_parameter_constraints_clauses $$60 . SEMICOLON (355) - - SEMICOLON shift 1197 - . error - - -state 1156 - enum_member_declaration : opt_attributes IDENTIFIER $$57 ASSIGN . constant_expression (351) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 514 - constant_expression goto 1198 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1157 - enum_declaration : opt_attributes opt_modifiers ENUM type_declaration_name opt_enum_base $$54 OPEN_BRACE $$55 opt_enum_member_declarations $$56 CLOSE_BRACE opt_semicolon . (340) - - . reduce 340 - - -state 1158 - type_parameter_constraint : CLASS . (684) - - . reduce 684 - - -state 1159 - type_parameter_constraint : NEW . OPEN_PARENS CLOSE_PARENS (683) - - OPEN_PARENS shift 1199 - . error - - -state 1160 - type_parameter_constraint : STRUCT . (685) - - . reduce 685 - - -state 1161 - type_parameter_constraint : type . (682) - - . reduce 682 - - -state 1162 - type_parameter_constraints_clause : WHERE IDENTIFIER COLON type_parameter_constraints . (679) - type_parameter_constraints : type_parameter_constraints . COMMA type_parameter_constraint (681) - - COMMA shift 1200 - WHERE reduce 679 - OPEN_BRACE reduce 679 - SEMICOLON reduce 679 - - -state 1163 - type_parameter_constraints : type_parameter_constraint . (680) - - . reduce 680 - - -state 1164 - class_member_declaration : error . (104) - - . reduce 104 - - -state 1165 - struct_declaration : opt_attributes . opt_modifiers opt_partial STRUCT $$7 type_declaration_name $$8 opt_class_base opt_type_parameter_constraints_clauses $$9 struct_body $$10 opt_semicolon (109) - struct_declaration : opt_attributes . opt_modifiers opt_partial STRUCT error (110) - constant_declaration : opt_attributes . opt_modifiers CONST type IDENTIFIER $$12 constant_initializer opt_constant_declarators SEMICOLON (128) - field_declaration : opt_attributes . opt_modifiers member_type IDENTIFIER $$14 opt_field_initializer opt_field_declarators SEMICOLON (140) - field_declaration : opt_attributes . opt_modifiers FIXED simple_type IDENTIFIER $$15 fixed_field_size opt_fixed_field_declarators SEMICOLON (142) - field_declaration : opt_attributes . opt_modifiers FIXED simple_type error SEMICOLON (143) - method_header : opt_attributes . opt_modifiers member_type method_declaration_name OPEN_PARENS $$20 opt_formal_parameter_list CLOSE_PARENS $$21 opt_type_parameter_constraints_clauses (179) - method_header : opt_attributes . opt_modifiers PARTIAL VOID method_declaration_name OPEN_PARENS $$22 opt_formal_parameter_list CLOSE_PARENS $$23 opt_type_parameter_constraints_clauses (182) - method_header : opt_attributes . opt_modifiers member_type modifiers method_declaration_name OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS (183) - property_declaration : opt_attributes . opt_modifiers member_type member_declaration_name $$25 OPEN_BRACE $$26 accessor_declarations $$27 CLOSE_BRACE (221) - indexer_declaration : opt_attributes . opt_modifiers member_type indexer_declaration_name OPEN_BRACKET $$28 opt_formal_parameter_list CLOSE_BRACKET OPEN_BRACE $$29 accessor_declarations $$30 CLOSE_BRACE (225) - interface_declaration : opt_attributes . opt_modifiers opt_partial INTERFACE $$33 type_declaration_name $$34 opt_class_base opt_type_parameter_constraints_clauses $$35 OPEN_BRACE opt_interface_member_declarations CLOSE_BRACE $$36 opt_semicolon (242) - interface_declaration : opt_attributes . opt_modifiers opt_partial INTERFACE error (243) - operator_declaration : opt_attributes . opt_modifiers operator_declarator $$37 operator_body (258) - constructor_declarator : opt_attributes . opt_modifiers IDENTIFIER $$41 OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS $$42 opt_constructor_initializer (297) - destructor_declaration : opt_attributes . opt_modifiers TILDE $$45 IDENTIFIER OPEN_PARENS CLOSE_PARENS method_body (308) - event_declaration : opt_attributes . opt_modifiers EVENT type member_declaration_name $$46 opt_event_initializer opt_event_declarators SEMICOLON (310) - event_declaration : opt_attributes . opt_modifiers EVENT type member_declaration_name OPEN_BRACE $$47 event_accessor_declarations $$48 CLOSE_BRACE (313) - enum_declaration : opt_attributes . opt_modifiers ENUM type_declaration_name opt_enum_base $$54 OPEN_BRACE $$55 opt_enum_member_declarations $$56 CLOSE_BRACE opt_semicolon (340) - delegate_declaration : opt_attributes . opt_modifiers DELEGATE member_type type_declaration_name OPEN_PARENS $$58 opt_formal_parameter_list CLOSE_PARENS $$59 opt_type_parameter_constraints_clauses $$60 SEMICOLON (355) - class_declaration : opt_attributes . opt_modifiers opt_partial CLASS $$70 type_declaration_name $$71 opt_class_base opt_type_parameter_constraints_clauses $$72 OPEN_BRACE opt_class_member_declarations CLOSE_BRACE $$73 opt_semicolon (652) - opt_modifiers : . (655) - - ABSTRACT shift 61 - EXTERN shift 62 - INTERNAL shift 63 - NEW shift 65 - OVERRIDE shift 66 - PRIVATE shift 67 - PROTECTED shift 68 - PUBLIC shift 69 - READONLY shift 70 - SEALED shift 71 - STATIC shift 72 - UNSAFE shift 73 - VIRTUAL shift 74 - VOLATILE shift 75 - BOOL reduce 655 - BYTE reduce 655 - CHAR reduce 655 - CLASS reduce 655 - CONST reduce 655 - DECIMAL reduce 655 - DELEGATE reduce 655 - DOUBLE reduce 655 - ENUM reduce 655 - EVENT reduce 655 - EXPLICIT reduce 655 - FIXED reduce 655 - FLOAT reduce 655 - IMPLICIT reduce 655 - INT reduce 655 - INTERFACE reduce 655 - LONG reduce 655 - OBJECT reduce 655 - SBYTE reduce 655 - SHORT reduce 655 - STRING reduce 655 - STRUCT reduce 655 - UINT reduce 655 - ULONG reduce 655 - USHORT reduce 655 - VOID reduce 655 - PARTIAL reduce 655 - TILDE reduce 655 - IDENTIFIER reduce 655 - - opt_modifiers goto 1201 - modifiers goto 77 - modifier goto 78 - - -state 1166 - class_member_declaration : type_declaration . (103) - - . reduce 103 - - -state 1167 - class_member_declaration : field_declaration . (95) - - . reduce 95 - - -state 1168 - class_member_declaration : method_declaration . (96) - - . reduce 96 - - -state 1169 - class_declaration : opt_attributes opt_modifiers opt_partial CLASS $$70 type_declaration_name $$71 opt_class_base opt_type_parameter_constraints_clauses $$72 OPEN_BRACE opt_class_member_declarations . CLOSE_BRACE $$73 opt_semicolon (652) - - CLOSE_BRACE shift 1202 - . error - - -state 1170 - opt_class_member_declarations : class_member_declarations . (91) - class_member_declarations : class_member_declarations . class_member_declaration (93) - opt_attributes : . (59) - - error shift 1164 - OPEN_BRACKET shift 4 - ABSTRACT reduce 59 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - CLASS reduce 59 - CONST reduce 59 - DECIMAL reduce 59 - DELEGATE reduce 59 - DOUBLE reduce 59 - ENUM reduce 59 - EVENT reduce 59 - EXPLICIT reduce 59 - EXTERN reduce 59 - FIXED reduce 59 - FLOAT reduce 59 - IMPLICIT reduce 59 - INT reduce 59 - INTERFACE reduce 59 - INTERNAL reduce 59 - LONG reduce 59 - NEW reduce 59 - OBJECT reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - SBYTE reduce 59 - SEALED reduce 59 - SHORT reduce 59 - STATIC reduce 59 - STRING reduce 59 - STRUCT reduce 59 - UINT reduce 59 - ULONG reduce 59 - UNSAFE reduce 59 - USHORT reduce 59 - VIRTUAL reduce 59 - VOID reduce 59 - VOLATILE reduce 59 - PARTIAL reduce 59 - CLOSE_BRACE reduce 91 - TILDE reduce 59 - IDENTIFIER reduce 59 - - opt_attributes goto 1165 - type_declaration goto 1166 - field_declaration goto 1167 - method_declaration goto 1168 - class_declaration goto 24 - struct_declaration goto 25 - interface_declaration goto 26 - enum_declaration goto 27 - delegate_declaration goto 28 - attribute_sections goto 693 - attribute_section goto 30 - class_member_declaration goto 1203 - constant_declaration goto 1172 - property_declaration goto 1173 - event_declaration goto 1174 - indexer_declaration goto 1175 - operator_declaration goto 1176 - constructor_declaration goto 1177 - destructor_declaration goto 1178 - method_header goto 31 - constructor_declarator goto 1179 - - -state 1171 - class_member_declarations : class_member_declaration . (92) - - . reduce 92 - - -state 1172 - class_member_declaration : constant_declaration . (94) - - . reduce 94 - - -state 1173 - class_member_declaration : property_declaration . (97) - - . reduce 97 - - -state 1174 - class_member_declaration : event_declaration . (98) - - . reduce 98 - - -state 1175 - class_member_declaration : indexer_declaration . (99) - - . reduce 99 - - -state 1176 - class_member_declaration : operator_declaration . (100) - - . reduce 100 - - -state 1177 - class_member_declaration : constructor_declaration . (101) - - . reduce 101 - - -state 1178 - class_member_declaration : destructor_declaration . (102) - - . reduce 102 - - -state 1179 - constructor_declaration : constructor_declarator . constructor_body (294) - - OPEN_BRACE shift 1204 - SEMICOLON shift 1205 - . error - - constructor_body goto 1206 - block_prepared goto 1207 - - -state 1180 - struct_declaration : opt_attributes . opt_modifiers opt_partial STRUCT $$7 type_declaration_name $$8 opt_class_base opt_type_parameter_constraints_clauses $$9 struct_body $$10 opt_semicolon (109) - struct_declaration : opt_attributes . opt_modifiers opt_partial STRUCT error (110) - constant_declaration : opt_attributes . opt_modifiers CONST type IDENTIFIER $$12 constant_initializer opt_constant_declarators SEMICOLON (128) - field_declaration : opt_attributes . opt_modifiers member_type IDENTIFIER $$14 opt_field_initializer opt_field_declarators SEMICOLON (140) - field_declaration : opt_attributes . opt_modifiers FIXED simple_type IDENTIFIER $$15 fixed_field_size opt_fixed_field_declarators SEMICOLON (142) - field_declaration : opt_attributes . opt_modifiers FIXED simple_type error SEMICOLON (143) - method_header : opt_attributes . opt_modifiers member_type method_declaration_name OPEN_PARENS $$20 opt_formal_parameter_list CLOSE_PARENS $$21 opt_type_parameter_constraints_clauses (179) - method_header : opt_attributes . opt_modifiers PARTIAL VOID method_declaration_name OPEN_PARENS $$22 opt_formal_parameter_list CLOSE_PARENS $$23 opt_type_parameter_constraints_clauses (182) - method_header : opt_attributes . opt_modifiers member_type modifiers method_declaration_name OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS (183) - property_declaration : opt_attributes . opt_modifiers member_type member_declaration_name $$25 OPEN_BRACE $$26 accessor_declarations $$27 CLOSE_BRACE (221) - indexer_declaration : opt_attributes . opt_modifiers member_type indexer_declaration_name OPEN_BRACKET $$28 opt_formal_parameter_list CLOSE_BRACKET OPEN_BRACE $$29 accessor_declarations $$30 CLOSE_BRACE (225) - interface_declaration : opt_attributes . opt_modifiers opt_partial INTERFACE $$33 type_declaration_name $$34 opt_class_base opt_type_parameter_constraints_clauses $$35 OPEN_BRACE opt_interface_member_declarations CLOSE_BRACE $$36 opt_semicolon (242) - interface_declaration : opt_attributes . opt_modifiers opt_partial INTERFACE error (243) - operator_declaration : opt_attributes . opt_modifiers operator_declarator $$37 operator_body (258) - constructor_declarator : opt_attributes . opt_modifiers IDENTIFIER $$41 OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS $$42 opt_constructor_initializer (297) - event_declaration : opt_attributes . opt_modifiers EVENT type member_declaration_name $$46 opt_event_initializer opt_event_declarators SEMICOLON (310) - event_declaration : opt_attributes . opt_modifiers EVENT type member_declaration_name OPEN_BRACE $$47 event_accessor_declarations $$48 CLOSE_BRACE (313) - enum_declaration : opt_attributes . opt_modifiers ENUM type_declaration_name opt_enum_base $$54 OPEN_BRACE $$55 opt_enum_member_declarations $$56 CLOSE_BRACE opt_semicolon (340) - delegate_declaration : opt_attributes . opt_modifiers DELEGATE member_type type_declaration_name OPEN_PARENS $$58 opt_formal_parameter_list CLOSE_PARENS $$59 opt_type_parameter_constraints_clauses $$60 SEMICOLON (355) - class_declaration : opt_attributes . opt_modifiers opt_partial CLASS $$70 type_declaration_name $$71 opt_class_base opt_type_parameter_constraints_clauses $$72 OPEN_BRACE opt_class_member_declarations CLOSE_BRACE $$73 opt_semicolon (652) - opt_modifiers : . (655) - - ABSTRACT shift 61 - EXTERN shift 62 - INTERNAL shift 63 - NEW shift 65 - OVERRIDE shift 66 - PRIVATE shift 67 - PROTECTED shift 68 - PUBLIC shift 69 - READONLY shift 70 - SEALED shift 71 - STATIC shift 72 - UNSAFE shift 73 - VIRTUAL shift 74 - VOLATILE shift 75 - BOOL reduce 655 - BYTE reduce 655 - CHAR reduce 655 - CLASS reduce 655 - CONST reduce 655 - DECIMAL reduce 655 - DELEGATE reduce 655 - DOUBLE reduce 655 - ENUM reduce 655 - EVENT reduce 655 - EXPLICIT reduce 655 - FIXED reduce 655 - FLOAT reduce 655 - IMPLICIT reduce 655 - INT reduce 655 - INTERFACE reduce 655 - LONG reduce 655 - OBJECT reduce 655 - SBYTE reduce 655 - SHORT reduce 655 - STRING reduce 655 - STRUCT reduce 655 - UINT reduce 655 - ULONG reduce 655 - USHORT reduce 655 - VOID reduce 655 - PARTIAL reduce 655 - IDENTIFIER reduce 655 - - opt_modifiers goto 1208 - modifiers goto 77 - modifier goto 78 - - -state 1181 - interface_member_declaration : type_declaration . (256) - - . reduce 256 - - -state 1182 - interface_member_declaration : field_declaration . (249) - - . reduce 249 - - -state 1183 - interface_member_declaration : method_declaration . (250) - - . reduce 250 - - -state 1184 - interface_member_declaration : constant_declaration . (248) - - . reduce 248 - - -state 1185 - interface_member_declaration : property_declaration . (251) - - . reduce 251 - - -state 1186 - interface_member_declaration : event_declaration . (252) - - . reduce 252 - - -state 1187 - interface_member_declaration : indexer_declaration . (253) - - . reduce 253 - - -state 1188 - interface_member_declaration : operator_declaration . (254) - - . reduce 254 - - -state 1189 - interface_member_declaration : constructor_declaration . (255) - - . reduce 255 - - -state 1190 - interface_declaration : opt_attributes opt_modifiers opt_partial INTERFACE $$33 type_declaration_name $$34 opt_class_base opt_type_parameter_constraints_clauses $$35 OPEN_BRACE opt_interface_member_declarations . CLOSE_BRACE $$36 opt_semicolon (242) - - CLOSE_BRACE shift 1209 - . error - - -state 1191 - opt_interface_member_declarations : interface_member_declarations . (245) - interface_member_declarations : interface_member_declarations . interface_member_declaration (247) - opt_attributes : . (59) - - OPEN_BRACKET shift 4 - ABSTRACT reduce 59 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - CLASS reduce 59 - CONST reduce 59 - DECIMAL reduce 59 - DELEGATE reduce 59 - DOUBLE reduce 59 - ENUM reduce 59 - EVENT reduce 59 - EXPLICIT reduce 59 - EXTERN reduce 59 - FIXED reduce 59 - FLOAT reduce 59 - IMPLICIT reduce 59 - INT reduce 59 - INTERFACE reduce 59 - INTERNAL reduce 59 - LONG reduce 59 - NEW reduce 59 - OBJECT reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - SBYTE reduce 59 - SEALED reduce 59 - SHORT reduce 59 - STATIC reduce 59 - STRING reduce 59 - STRUCT reduce 59 - UINT reduce 59 - ULONG reduce 59 - UNSAFE reduce 59 - USHORT reduce 59 - VIRTUAL reduce 59 - VOID reduce 59 - VOLATILE reduce 59 - PARTIAL reduce 59 - CLOSE_BRACE reduce 245 - IDENTIFIER reduce 59 - - opt_attributes goto 1180 - type_declaration goto 1181 - field_declaration goto 1182 - method_declaration goto 1183 - class_declaration goto 24 - struct_declaration goto 25 - interface_declaration goto 26 - enum_declaration goto 27 - delegate_declaration goto 28 - attribute_sections goto 693 - attribute_section goto 30 - constant_declaration goto 1184 - property_declaration goto 1185 - event_declaration goto 1186 - indexer_declaration goto 1187 - operator_declaration goto 1188 - constructor_declaration goto 1189 - method_header goto 31 - interface_member_declaration goto 1210 - constructor_declarator goto 1179 - - -state 1192 - interface_member_declarations : interface_member_declaration . (246) - - . reduce 246 - - -state 1193 - struct_body : OPEN_BRACE $$11 . opt_struct_member_declarations CLOSE_BRACE (112) - opt_attributes : . (59) - opt_struct_member_declarations : . (113) - - OPEN_BRACKET shift 4 - ABSTRACT reduce 59 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - CLASS reduce 59 - CONST reduce 59 - DECIMAL reduce 59 - DELEGATE reduce 59 - DOUBLE reduce 59 - ENUM reduce 59 - EVENT reduce 59 - EXPLICIT reduce 59 - EXTERN reduce 59 - FIXED reduce 59 - FLOAT reduce 59 - IMPLICIT reduce 59 - INT reduce 59 - INTERFACE reduce 59 - INTERNAL reduce 59 - LONG reduce 59 - NEW reduce 59 - OBJECT reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - SBYTE reduce 59 - SEALED reduce 59 - SHORT reduce 59 - STATIC reduce 59 - STRING reduce 59 - STRUCT reduce 59 - UINT reduce 59 - ULONG reduce 59 - UNSAFE reduce 59 - USHORT reduce 59 - VIRTUAL reduce 59 - VOID reduce 59 - VOLATILE reduce 59 - PARTIAL reduce 59 - CLOSE_BRACE reduce 113 - TILDE reduce 59 - IDENTIFIER reduce 59 - - opt_attributes goto 1165 - type_declaration goto 1211 - field_declaration goto 1212 - method_declaration goto 1213 - class_declaration goto 24 - struct_declaration goto 25 - interface_declaration goto 26 - enum_declaration goto 27 - delegate_declaration goto 28 - attribute_sections goto 693 - attribute_section goto 30 - constant_declaration goto 1214 - property_declaration goto 1215 - event_declaration goto 1216 - indexer_declaration goto 1217 - operator_declaration goto 1218 - constructor_declaration goto 1219 - destructor_declaration goto 1220 - opt_struct_member_declarations goto 1221 - struct_member_declarations goto 1222 - struct_member_declaration goto 1223 - method_header goto 31 - constructor_declarator goto 1179 - - -state 1194 - struct_declaration : opt_attributes opt_modifiers opt_partial STRUCT $$7 type_declaration_name $$8 opt_class_base opt_type_parameter_constraints_clauses $$9 struct_body $$10 . opt_semicolon (109) - opt_semicolon : . (30) - - SEMICOLON shift 810 - $end reduce 30 - error reduce 30 - EOF reduce 30 - ABSTRACT reduce 30 - BOOL reduce 30 - BYTE reduce 30 - CHAR reduce 30 - CLASS reduce 30 - CONST reduce 30 - DECIMAL reduce 30 - DELEGATE reduce 30 - DOUBLE reduce 30 - ENUM reduce 30 - EVENT reduce 30 - EXPLICIT reduce 30 - EXTERN reduce 30 - FIXED reduce 30 - FLOAT reduce 30 - IMPLICIT reduce 30 - INT reduce 30 - INTERFACE reduce 30 - INTERNAL reduce 30 - LONG reduce 30 - NAMESPACE reduce 30 - NEW reduce 30 - OBJECT reduce 30 - OVERRIDE reduce 30 - PRIVATE reduce 30 - PROTECTED reduce 30 - PUBLIC reduce 30 - READONLY reduce 30 - SBYTE reduce 30 - SEALED reduce 30 - SHORT reduce 30 - STATIC reduce 30 - STRING reduce 30 - STRUCT reduce 30 - UINT reduce 30 - ULONG reduce 30 - UNSAFE reduce 30 - USHORT reduce 30 - USING reduce 30 - VIRTUAL reduce 30 - VOID reduce 30 - VOLATILE reduce 30 - PARTIAL reduce 30 - EXTERN_ALIAS reduce 30 - CLOSE_BRACE reduce 30 - OPEN_BRACKET reduce 30 - TILDE reduce 30 - IDENTIFIER reduce 30 - - opt_semicolon goto 1224 - - -state 1195 - join_clause : JOIN IDENTIFIER IN $$93 expression ON $$94 expression EQUALS $$95 . expression opt_join_into (884) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 1225 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1196 - join_clause : JOIN type IDENTIFIER IN $$96 expression ON $$97 expression EQUALS . $$98 expression opt_join_into (888) - $$98 : . (887) - - . reduce 887 - - $$98 goto 1226 - - -state 1197 - delegate_declaration : opt_attributes opt_modifiers DELEGATE member_type type_declaration_name OPEN_PARENS $$58 opt_formal_parameter_list CLOSE_PARENS $$59 opt_type_parameter_constraints_clauses $$60 SEMICOLON . (355) - - . reduce 355 - - -state 1198 - enum_member_declaration : opt_attributes IDENTIFIER $$57 ASSIGN constant_expression . (351) - - . reduce 351 - - -state 1199 - type_parameter_constraint : NEW OPEN_PARENS . CLOSE_PARENS (683) - - CLOSE_PARENS shift 1227 - . error - - -state 1200 - type_parameter_constraints : type_parameter_constraints COMMA . type_parameter_constraint (681) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CLASS shift 1158 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 1159 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - STRUCT shift 1160 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 1161 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - type_parameter_constraint goto 1228 - - -state 1201 - struct_declaration : opt_attributes opt_modifiers . opt_partial STRUCT $$7 type_declaration_name $$8 opt_class_base opt_type_parameter_constraints_clauses $$9 struct_body $$10 opt_semicolon (109) - struct_declaration : opt_attributes opt_modifiers . opt_partial STRUCT error (110) - constant_declaration : opt_attributes opt_modifiers . CONST type IDENTIFIER $$12 constant_initializer opt_constant_declarators SEMICOLON (128) - field_declaration : opt_attributes opt_modifiers . member_type IDENTIFIER $$14 opt_field_initializer opt_field_declarators SEMICOLON (140) - field_declaration : opt_attributes opt_modifiers . FIXED simple_type IDENTIFIER $$15 fixed_field_size opt_fixed_field_declarators SEMICOLON (142) - field_declaration : opt_attributes opt_modifiers . FIXED simple_type error SEMICOLON (143) - method_header : opt_attributes opt_modifiers . member_type method_declaration_name OPEN_PARENS $$20 opt_formal_parameter_list CLOSE_PARENS $$21 opt_type_parameter_constraints_clauses (179) - method_header : opt_attributes opt_modifiers . PARTIAL VOID method_declaration_name OPEN_PARENS $$22 opt_formal_parameter_list CLOSE_PARENS $$23 opt_type_parameter_constraints_clauses (182) - method_header : opt_attributes opt_modifiers . member_type modifiers method_declaration_name OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS (183) - property_declaration : opt_attributes opt_modifiers . member_type member_declaration_name $$25 OPEN_BRACE $$26 accessor_declarations $$27 CLOSE_BRACE (221) - indexer_declaration : opt_attributes opt_modifiers . member_type indexer_declaration_name OPEN_BRACKET $$28 opt_formal_parameter_list CLOSE_BRACKET OPEN_BRACE $$29 accessor_declarations $$30 CLOSE_BRACE (225) - interface_declaration : opt_attributes opt_modifiers . opt_partial INTERFACE $$33 type_declaration_name $$34 opt_class_base opt_type_parameter_constraints_clauses $$35 OPEN_BRACE opt_interface_member_declarations CLOSE_BRACE $$36 opt_semicolon (242) - interface_declaration : opt_attributes opt_modifiers . opt_partial INTERFACE error (243) - operator_declaration : opt_attributes opt_modifiers . operator_declarator $$37 operator_body (258) - constructor_declarator : opt_attributes opt_modifiers . IDENTIFIER $$41 OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS $$42 opt_constructor_initializer (297) - destructor_declaration : opt_attributes opt_modifiers . TILDE $$45 IDENTIFIER OPEN_PARENS CLOSE_PARENS method_body (308) - event_declaration : opt_attributes opt_modifiers . EVENT type member_declaration_name $$46 opt_event_initializer opt_event_declarators SEMICOLON (310) - event_declaration : opt_attributes opt_modifiers . EVENT type member_declaration_name OPEN_BRACE $$47 event_accessor_declarations $$48 CLOSE_BRACE (313) - enum_declaration : opt_attributes opt_modifiers . ENUM type_declaration_name opt_enum_base $$54 OPEN_BRACE $$55 opt_enum_member_declarations $$56 CLOSE_BRACE opt_semicolon (340) - delegate_declaration : opt_attributes opt_modifiers . DELEGATE member_type type_declaration_name OPEN_PARENS $$58 opt_formal_parameter_list CLOSE_PARENS $$59 opt_type_parameter_constraints_clauses $$60 SEMICOLON (355) - class_declaration : opt_attributes opt_modifiers . opt_partial CLASS $$70 type_declaration_name $$71 opt_class_base opt_type_parameter_constraints_clauses $$72 OPEN_BRACE opt_class_member_declarations CLOSE_BRACE $$73 opt_semicolon (652) - opt_partial : . (653) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CONST shift 1229 - DECIMAL shift 104 - DELEGATE shift 250 - DOUBLE shift 108 - ENUM shift 251 - EVENT shift 1230 - EXPLICIT shift 1231 - FIXED shift 252 - FLOAT shift 111 - IMPLICIT shift 1232 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 1233 - PARTIAL shift 254 - TILDE shift 1234 - IDENTIFIER shift 1235 - CLASS reduce 653 - INTERFACE reduce 653 - STRUCT reduce 653 - - namespace_or_type_name goto 255 - opt_partial goto 256 - member_type goto 1236 - operator_declarator goto 1237 - operator_type goto 1238 - type_expression_or_array goto 1239 - conversion_operator_declarator goto 1240 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_and_void goto 259 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 1202 - class_declaration : opt_attributes opt_modifiers opt_partial CLASS $$70 type_declaration_name $$71 opt_class_base opt_type_parameter_constraints_clauses $$72 OPEN_BRACE opt_class_member_declarations CLOSE_BRACE . $$73 opt_semicolon (652) - $$73 : . (651) - - . reduce 651 - - $$73 goto 1241 - - -state 1203 - class_member_declarations : class_member_declarations class_member_declaration . (93) - - . reduce 93 - - -state 1204 - block_prepared : OPEN_BRACE . $$75 opt_statement_list CLOSE_BRACE (695) - $$75 : . (694) - - . reduce 694 - - $$75 goto 1242 - - -state 1205 - constructor_body : SEMICOLON . (299) - - . reduce 299 - - -state 1206 - constructor_declaration : constructor_declarator constructor_body . (294) - - . reduce 294 - - -state 1207 - constructor_body : block_prepared . (298) - - . reduce 298 - - -state 1208 - struct_declaration : opt_attributes opt_modifiers . opt_partial STRUCT $$7 type_declaration_name $$8 opt_class_base opt_type_parameter_constraints_clauses $$9 struct_body $$10 opt_semicolon (109) - struct_declaration : opt_attributes opt_modifiers . opt_partial STRUCT error (110) - constant_declaration : opt_attributes opt_modifiers . CONST type IDENTIFIER $$12 constant_initializer opt_constant_declarators SEMICOLON (128) - field_declaration : opt_attributes opt_modifiers . member_type IDENTIFIER $$14 opt_field_initializer opt_field_declarators SEMICOLON (140) - field_declaration : opt_attributes opt_modifiers . FIXED simple_type IDENTIFIER $$15 fixed_field_size opt_fixed_field_declarators SEMICOLON (142) - field_declaration : opt_attributes opt_modifiers . FIXED simple_type error SEMICOLON (143) - method_header : opt_attributes opt_modifiers . member_type method_declaration_name OPEN_PARENS $$20 opt_formal_parameter_list CLOSE_PARENS $$21 opt_type_parameter_constraints_clauses (179) - method_header : opt_attributes opt_modifiers . PARTIAL VOID method_declaration_name OPEN_PARENS $$22 opt_formal_parameter_list CLOSE_PARENS $$23 opt_type_parameter_constraints_clauses (182) - method_header : opt_attributes opt_modifiers . member_type modifiers method_declaration_name OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS (183) - property_declaration : opt_attributes opt_modifiers . member_type member_declaration_name $$25 OPEN_BRACE $$26 accessor_declarations $$27 CLOSE_BRACE (221) - indexer_declaration : opt_attributes opt_modifiers . member_type indexer_declaration_name OPEN_BRACKET $$28 opt_formal_parameter_list CLOSE_BRACKET OPEN_BRACE $$29 accessor_declarations $$30 CLOSE_BRACE (225) - interface_declaration : opt_attributes opt_modifiers . opt_partial INTERFACE $$33 type_declaration_name $$34 opt_class_base opt_type_parameter_constraints_clauses $$35 OPEN_BRACE opt_interface_member_declarations CLOSE_BRACE $$36 opt_semicolon (242) - interface_declaration : opt_attributes opt_modifiers . opt_partial INTERFACE error (243) - operator_declaration : opt_attributes opt_modifiers . operator_declarator $$37 operator_body (258) - constructor_declarator : opt_attributes opt_modifiers . IDENTIFIER $$41 OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS $$42 opt_constructor_initializer (297) - event_declaration : opt_attributes opt_modifiers . EVENT type member_declaration_name $$46 opt_event_initializer opt_event_declarators SEMICOLON (310) - event_declaration : opt_attributes opt_modifiers . EVENT type member_declaration_name OPEN_BRACE $$47 event_accessor_declarations $$48 CLOSE_BRACE (313) - enum_declaration : opt_attributes opt_modifiers . ENUM type_declaration_name opt_enum_base $$54 OPEN_BRACE $$55 opt_enum_member_declarations $$56 CLOSE_BRACE opt_semicolon (340) - delegate_declaration : opt_attributes opt_modifiers . DELEGATE member_type type_declaration_name OPEN_PARENS $$58 opt_formal_parameter_list CLOSE_PARENS $$59 opt_type_parameter_constraints_clauses $$60 SEMICOLON (355) - class_declaration : opt_attributes opt_modifiers . opt_partial CLASS $$70 type_declaration_name $$71 opt_class_base opt_type_parameter_constraints_clauses $$72 OPEN_BRACE opt_class_member_declarations CLOSE_BRACE $$73 opt_semicolon (652) - opt_partial : . (653) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CONST shift 1229 - DECIMAL shift 104 - DELEGATE shift 250 - DOUBLE shift 108 - ENUM shift 251 - EVENT shift 1230 - EXPLICIT shift 1231 - FIXED shift 252 - FLOAT shift 111 - IMPLICIT shift 1232 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 1233 - PARTIAL shift 254 - IDENTIFIER shift 1235 - CLASS reduce 653 - INTERFACE reduce 653 - STRUCT reduce 653 - - namespace_or_type_name goto 255 - opt_partial goto 256 - member_type goto 1236 - operator_declarator goto 1237 - operator_type goto 1238 - type_expression_or_array goto 1239 - conversion_operator_declarator goto 1240 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_and_void goto 259 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 1209 - interface_declaration : opt_attributes opt_modifiers opt_partial INTERFACE $$33 type_declaration_name $$34 opt_class_base opt_type_parameter_constraints_clauses $$35 OPEN_BRACE opt_interface_member_declarations CLOSE_BRACE . $$36 opt_semicolon (242) - $$36 : . (241) - - . reduce 241 - - $$36 goto 1243 - - -state 1210 - interface_member_declarations : interface_member_declarations interface_member_declaration . (247) - - . reduce 247 - - -state 1211 - struct_member_declaration : type_declaration . (125) - - . reduce 125 - - -state 1212 - struct_member_declaration : field_declaration . (118) - - . reduce 118 - - -state 1213 - struct_member_declaration : method_declaration . (119) - - . reduce 119 - - -state 1214 - struct_member_declaration : constant_declaration . (117) - - . reduce 117 - - -state 1215 - struct_member_declaration : property_declaration . (120) - - . reduce 120 - - -state 1216 - struct_member_declaration : event_declaration . (121) - - . reduce 121 - - -state 1217 - struct_member_declaration : indexer_declaration . (122) - - . reduce 122 - - -state 1218 - struct_member_declaration : operator_declaration . (123) - - . reduce 123 - - -state 1219 - struct_member_declaration : constructor_declaration . (124) - - . reduce 124 - - -state 1220 - struct_member_declaration : destructor_declaration . (126) - - . reduce 126 - - -state 1221 - struct_body : OPEN_BRACE $$11 opt_struct_member_declarations . CLOSE_BRACE (112) - - CLOSE_BRACE shift 1244 - . error - - -state 1222 - opt_struct_member_declarations : struct_member_declarations . (114) - struct_member_declarations : struct_member_declarations . struct_member_declaration (116) - opt_attributes : . (59) - - OPEN_BRACKET shift 4 - ABSTRACT reduce 59 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - CLASS reduce 59 - CONST reduce 59 - DECIMAL reduce 59 - DELEGATE reduce 59 - DOUBLE reduce 59 - ENUM reduce 59 - EVENT reduce 59 - EXPLICIT reduce 59 - EXTERN reduce 59 - FIXED reduce 59 - FLOAT reduce 59 - IMPLICIT reduce 59 - INT reduce 59 - INTERFACE reduce 59 - INTERNAL reduce 59 - LONG reduce 59 - NEW reduce 59 - OBJECT reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - SBYTE reduce 59 - SEALED reduce 59 - SHORT reduce 59 - STATIC reduce 59 - STRING reduce 59 - STRUCT reduce 59 - UINT reduce 59 - ULONG reduce 59 - UNSAFE reduce 59 - USHORT reduce 59 - VIRTUAL reduce 59 - VOID reduce 59 - VOLATILE reduce 59 - PARTIAL reduce 59 - CLOSE_BRACE reduce 114 - TILDE reduce 59 - IDENTIFIER reduce 59 - - opt_attributes goto 1165 - type_declaration goto 1211 - field_declaration goto 1212 - method_declaration goto 1213 - class_declaration goto 24 - struct_declaration goto 25 - interface_declaration goto 26 - enum_declaration goto 27 - delegate_declaration goto 28 - attribute_sections goto 693 - attribute_section goto 30 - constant_declaration goto 1214 - property_declaration goto 1215 - event_declaration goto 1216 - indexer_declaration goto 1217 - operator_declaration goto 1218 - constructor_declaration goto 1219 - destructor_declaration goto 1220 - struct_member_declaration goto 1245 - method_header goto 31 - constructor_declarator goto 1179 - - -state 1223 - struct_member_declarations : struct_member_declaration . (115) - - . reduce 115 - - -state 1224 - struct_declaration : opt_attributes opt_modifiers opt_partial STRUCT $$7 type_declaration_name $$8 opt_class_base opt_type_parameter_constraints_clauses $$9 struct_body $$10 opt_semicolon . (109) - - . reduce 109 - - -state 1225 - join_clause : JOIN IDENTIFIER IN $$93 expression ON $$94 expression EQUALS $$95 expression . opt_join_into (884) - opt_join_into : . (889) - - INTO shift 1246 - WHERE reduce 889 - FROM reduce 889 - JOIN reduce 889 - SELECT reduce 889 - GROUP reduce 889 - LET reduce 889 - ORDERBY reduce 889 - COMPLETE_COMPLETION reduce 889 - - opt_join_into goto 1247 - - -state 1226 - join_clause : JOIN type IDENTIFIER IN $$96 expression ON $$97 expression EQUALS $$98 . expression opt_join_into (888) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 1248 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1227 - type_parameter_constraint : NEW OPEN_PARENS CLOSE_PARENS . (683) - - . reduce 683 - - -state 1228 - type_parameter_constraints : type_parameter_constraints COMMA type_parameter_constraint . (681) - - . reduce 681 - - -state 1229 - constant_declaration : opt_attributes opt_modifiers CONST . type IDENTIFIER $$12 constant_initializer opt_constant_declarators SEMICOLON (128) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 1249 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 1230 - event_declaration : opt_attributes opt_modifiers EVENT . type member_declaration_name $$46 opt_event_initializer opt_event_declarators SEMICOLON (310) - event_declaration : opt_attributes opt_modifiers EVENT . type member_declaration_name OPEN_BRACE $$47 event_accessor_declarations $$48 CLOSE_BRACE (313) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 1250 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 1231 - conversion_operator_declarator : EXPLICIT . OPERATOR type OPEN_PARENS $$40 opt_formal_parameter_list CLOSE_PARENS (291) - conversion_operator_declarator : EXPLICIT . error (293) - - error shift 1251 - OPERATOR shift 1252 - . error - - -state 1232 - conversion_operator_declarator : IMPLICIT . OPERATOR type OPEN_PARENS $$39 opt_formal_parameter_list CLOSE_PARENS (289) - conversion_operator_declarator : IMPLICIT . error (292) - - error shift 1253 - OPERATOR shift 1254 - . error - - -state 1233 - operator_type : VOID . (262) - type_and_void : VOID . (385) - type_expression : VOID . STAR (398) - - STAR shift 464 - ABSTRACT reduce 385 - EXTERN reduce 385 - INTERNAL reduce 385 - NEW reduce 385 - OPERATOR reduce 262 - OVERRIDE reduce 385 - PRIVATE reduce 385 - PROTECTED reduce 385 - PUBLIC reduce 385 - READONLY reduce 385 - SEALED reduce 385 - STATIC reduce 385 - THIS reduce 385 - UNSAFE reduce 385 - VIRTUAL reduce 385 - VOLATILE reduce 385 - IDENTIFIER reduce 385 - - -state 1234 - destructor_declaration : opt_attributes opt_modifiers TILDE . $$45 IDENTIFIER OPEN_PARENS CLOSE_PARENS method_body (308) - $$45 : . (307) - - . reduce 307 - - $$45 goto 1255 - - -state 1235 - constructor_declarator : opt_attributes opt_modifiers IDENTIFIER . $$41 OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS $$42 opt_constructor_initializer (297) - type_name : IDENTIFIER . opt_type_argument_list (362) - qualified_alias_member : IDENTIFIER . DOUBLE_COLON (555) - $$41 : . (295) - opt_type_argument_list : . (363) - - OP_GENERICS_LT shift 81 - DOUBLE_COLON shift 83 - ABSTRACT reduce 363 - EXTERN reduce 363 - INTERNAL reduce 363 - NEW reduce 363 - OPERATOR reduce 363 - OVERRIDE reduce 363 - PRIVATE reduce 363 - PROTECTED reduce 363 - PUBLIC reduce 363 - READONLY reduce 363 - SEALED reduce 363 - STATIC reduce 363 - THIS reduce 363 - UNSAFE reduce 363 - VIRTUAL reduce 363 - VOLATILE reduce 363 - INTERR_NULLABLE reduce 363 - OPEN_BRACKET reduce 363 - OPEN_PARENS reduce 295 - DOT reduce 363 - STAR reduce 363 - IDENTIFIER reduce 363 - - $$41 goto 1256 - opt_type_argument_list goto 84 - - -state 1236 - field_declaration : opt_attributes opt_modifiers member_type . IDENTIFIER $$14 opt_field_initializer opt_field_declarators SEMICOLON (140) - method_header : opt_attributes opt_modifiers member_type . method_declaration_name OPEN_PARENS $$20 opt_formal_parameter_list CLOSE_PARENS $$21 opt_type_parameter_constraints_clauses (179) - method_header : opt_attributes opt_modifiers member_type . modifiers method_declaration_name OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS (183) - property_declaration : opt_attributes opt_modifiers member_type . member_declaration_name $$25 OPEN_BRACE $$26 accessor_declarations $$27 CLOSE_BRACE (221) - indexer_declaration : opt_attributes opt_modifiers member_type . indexer_declaration_name OPEN_BRACKET $$28 opt_formal_parameter_list CLOSE_BRACKET OPEN_BRACE $$29 accessor_declarations $$30 CLOSE_BRACE (225) - - ABSTRACT shift 61 - EXTERN shift 62 - INTERNAL shift 63 - NEW shift 65 - OVERRIDE shift 66 - PRIVATE shift 67 - PROTECTED shift 68 - PUBLIC shift 69 - READONLY shift 70 - SEALED shift 71 - STATIC shift 72 - THIS shift 1257 - UNSAFE shift 73 - VIRTUAL shift 74 - VOLATILE shift 75 - IDENTIFIER shift 470 - . error - - type_declaration_name goto 471 - method_declaration_name goto 1258 - modifiers goto 473 - member_declaration_name goto 1259 - indexer_declaration_name goto 1260 - qualified_alias_member goto 474 - explicit_interface goto 1261 - modifier goto 78 - - -state 1237 - operator_declaration : opt_attributes opt_modifiers operator_declarator . $$37 operator_body (258) - $$37 : . (257) - - . reduce 257 - - $$37 goto 1262 - - -state 1238 - operator_declarator : operator_type . OPERATOR overloadable_operator OPEN_PARENS $$38 opt_formal_parameter_list CLOSE_PARENS (264) - - OPERATOR shift 1263 - . error - - -state 1239 - operator_type : type_expression_or_array . (261) - type_and_void : type_expression_or_array . (384) - - ABSTRACT reduce 384 - EXTERN reduce 384 - INTERNAL reduce 384 - NEW reduce 384 - OPERATOR reduce 261 - OVERRIDE reduce 384 - PRIVATE reduce 384 - PROTECTED reduce 384 - PUBLIC reduce 384 - READONLY reduce 384 - SEALED reduce 384 - STATIC reduce 384 - THIS reduce 384 - UNSAFE reduce 384 - VIRTUAL reduce 384 - VOLATILE reduce 384 - IDENTIFIER reduce 384 - - -state 1240 - operator_declarator : conversion_operator_declarator . (265) - - . reduce 265 - - -state 1241 - class_declaration : opt_attributes opt_modifiers opt_partial CLASS $$70 type_declaration_name $$71 opt_class_base opt_type_parameter_constraints_clauses $$72 OPEN_BRACE opt_class_member_declarations CLOSE_BRACE $$73 . opt_semicolon (652) - opt_semicolon : . (30) - - SEMICOLON shift 810 - $end reduce 30 - error reduce 30 - EOF reduce 30 - ABSTRACT reduce 30 - BOOL reduce 30 - BYTE reduce 30 - CHAR reduce 30 - CLASS reduce 30 - CONST reduce 30 - DECIMAL reduce 30 - DELEGATE reduce 30 - DOUBLE reduce 30 - ENUM reduce 30 - EVENT reduce 30 - EXPLICIT reduce 30 - EXTERN reduce 30 - FIXED reduce 30 - FLOAT reduce 30 - IMPLICIT reduce 30 - INT reduce 30 - INTERFACE reduce 30 - INTERNAL reduce 30 - LONG reduce 30 - NAMESPACE reduce 30 - NEW reduce 30 - OBJECT reduce 30 - OVERRIDE reduce 30 - PRIVATE reduce 30 - PROTECTED reduce 30 - PUBLIC reduce 30 - READONLY reduce 30 - SBYTE reduce 30 - SEALED reduce 30 - SHORT reduce 30 - STATIC reduce 30 - STRING reduce 30 - STRUCT reduce 30 - UINT reduce 30 - ULONG reduce 30 - UNSAFE reduce 30 - USHORT reduce 30 - USING reduce 30 - VIRTUAL reduce 30 - VOID reduce 30 - VOLATILE reduce 30 - PARTIAL reduce 30 - EXTERN_ALIAS reduce 30 - CLOSE_BRACE reduce 30 - OPEN_BRACKET reduce 30 - TILDE reduce 30 - IDENTIFIER reduce 30 - - opt_semicolon goto 1264 - - -state 1242 - block_prepared : OPEN_BRACE $$75 . opt_statement_list CLOSE_BRACE (695) - opt_statement_list : . (696) - - error shift 303 - BASE shift 96 - BOOL shift 97 - BREAK shift 98 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 101 - CONST shift 102 - CONTINUE shift 103 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DO shift 107 - DOUBLE shift 108 - FALSE shift 109 - FIXED shift 110 - FLOAT shift 111 - FOR shift 112 - FOREACH shift 113 - GOTO shift 114 - IF shift 115 - INT shift 116 - LOCK shift 117 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - RETURN shift 122 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - SWITCH shift 127 - THIS shift 128 - THROW shift 129 - TRUE shift 130 - TRY shift 131 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 135 - UNSAFE shift 136 - USHORT shift 137 - USING shift 138 - VOID shift 139 - WHILE shift 140 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 143 - OPEN_PARENS shift 144 - SEMICOLON shift 145 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 155 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - CLOSE_BRACE reduce 696 - - expression goto 304 - block goto 305 - qualified_alias_member goto 160 - builtin_types goto 161 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 164 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - opt_statement_list goto 1265 - statement_list goto 562 - statement goto 563 - declaration_statement goto 564 - valid_declaration_statement goto 565 - labeled_statement goto 566 - empty_statement goto 309 - expression_statement goto 310 - selection_statement goto 311 - iteration_statement goto 312 - jump_statement goto 313 - try_statement goto 314 - checked_statement goto 315 - unchecked_statement goto 316 - lock_statement goto 317 - using_statement goto 318 - unsafe_statement goto 319 - fixed_statement goto 320 - local_variable_declaration goto 221 - local_constant_declaration goto 222 - variable_type goto 223 - local_variable_pointer_type goto 224 - local_variable_type goto 225 - statement_expression goto 322 - if_statement goto 227 - switch_statement goto 228 - while_statement goto 229 - do_statement goto 230 - for_statement goto 231 - foreach_statement goto 232 - break_statement goto 233 - continue_statement goto 234 - goto_statement goto 235 - return_statement goto 236 - throw_statement goto 237 - yield_statement goto 238 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1243 - interface_declaration : opt_attributes opt_modifiers opt_partial INTERFACE $$33 type_declaration_name $$34 opt_class_base opt_type_parameter_constraints_clauses $$35 OPEN_BRACE opt_interface_member_declarations CLOSE_BRACE $$36 . opt_semicolon (242) - opt_semicolon : . (30) - - SEMICOLON shift 810 - $end reduce 30 - error reduce 30 - EOF reduce 30 - ABSTRACT reduce 30 - BOOL reduce 30 - BYTE reduce 30 - CHAR reduce 30 - CLASS reduce 30 - CONST reduce 30 - DECIMAL reduce 30 - DELEGATE reduce 30 - DOUBLE reduce 30 - ENUM reduce 30 - EVENT reduce 30 - EXPLICIT reduce 30 - EXTERN reduce 30 - FIXED reduce 30 - FLOAT reduce 30 - IMPLICIT reduce 30 - INT reduce 30 - INTERFACE reduce 30 - INTERNAL reduce 30 - LONG reduce 30 - NAMESPACE reduce 30 - NEW reduce 30 - OBJECT reduce 30 - OVERRIDE reduce 30 - PRIVATE reduce 30 - PROTECTED reduce 30 - PUBLIC reduce 30 - READONLY reduce 30 - SBYTE reduce 30 - SEALED reduce 30 - SHORT reduce 30 - STATIC reduce 30 - STRING reduce 30 - STRUCT reduce 30 - UINT reduce 30 - ULONG reduce 30 - UNSAFE reduce 30 - USHORT reduce 30 - USING reduce 30 - VIRTUAL reduce 30 - VOID reduce 30 - VOLATILE reduce 30 - PARTIAL reduce 30 - EXTERN_ALIAS reduce 30 - CLOSE_BRACE reduce 30 - OPEN_BRACKET reduce 30 - TILDE reduce 30 - IDENTIFIER reduce 30 - - opt_semicolon goto 1266 - - -state 1244 - struct_body : OPEN_BRACE $$11 opt_struct_member_declarations CLOSE_BRACE . (112) - - . reduce 112 - - -state 1245 - struct_member_declarations : struct_member_declarations struct_member_declaration . (116) - - . reduce 116 - - -state 1246 - opt_join_into : INTO . IDENTIFIER (890) - - IDENTIFIER shift 1267 - . error - - -state 1247 - join_clause : JOIN IDENTIFIER IN $$93 expression ON $$94 expression EQUALS $$95 expression opt_join_into . (884) - - . reduce 884 - - -state 1248 - join_clause : JOIN type IDENTIFIER IN $$96 expression ON $$97 expression EQUALS $$98 expression . opt_join_into (888) - opt_join_into : . (889) - - INTO shift 1246 - WHERE reduce 889 - FROM reduce 889 - JOIN reduce 889 - SELECT reduce 889 - GROUP reduce 889 - LET reduce 889 - ORDERBY reduce 889 - COMPLETE_COMPLETION reduce 889 - - opt_join_into goto 1268 - - -state 1249 - constant_declaration : opt_attributes opt_modifiers CONST type . IDENTIFIER $$12 constant_initializer opt_constant_declarators SEMICOLON (128) - - IDENTIFIER shift 1269 - . error - - -state 1250 - event_declaration : opt_attributes opt_modifiers EVENT type . member_declaration_name $$46 opt_event_initializer opt_event_declarators SEMICOLON (310) - event_declaration : opt_attributes opt_modifiers EVENT type . member_declaration_name OPEN_BRACE $$47 event_accessor_declarations $$48 CLOSE_BRACE (313) - - IDENTIFIER shift 665 - . error - - type_declaration_name goto 471 - method_declaration_name goto 1270 - member_declaration_name goto 1271 - qualified_alias_member goto 474 - explicit_interface goto 475 - - -state 1251 - conversion_operator_declarator : EXPLICIT error . (293) - - . reduce 293 - - -state 1252 - conversion_operator_declarator : EXPLICIT OPERATOR . type OPEN_PARENS $$40 opt_formal_parameter_list CLOSE_PARENS (291) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 1272 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 1253 - conversion_operator_declarator : IMPLICIT error . (292) - - . reduce 292 - - -state 1254 - conversion_operator_declarator : IMPLICIT OPERATOR . type OPEN_PARENS $$39 opt_formal_parameter_list CLOSE_PARENS (289) - - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - DECIMAL shift 104 - DOUBLE shift 108 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - STRING shift 126 - UINT shift 133 - ULONG shift 134 - USHORT shift 137 - VOID shift 267 - IDENTIFIER shift 89 - . error - - namespace_or_type_name goto 255 - type goto 1273 - type_expression_or_array goto 269 - member_name goto 36 - qualified_alias_member goto 37 - type_name goto 38 - type_expression goto 260 - builtin_types goto 261 - integral_type goto 162 - - -state 1255 - destructor_declaration : opt_attributes opt_modifiers TILDE $$45 . IDENTIFIER OPEN_PARENS CLOSE_PARENS method_body (308) - - IDENTIFIER shift 1274 - . error - - -state 1256 - constructor_declarator : opt_attributes opt_modifiers IDENTIFIER $$41 . OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS $$42 opt_constructor_initializer (297) - - OPEN_PARENS shift 1275 - . error - - -state 1257 - indexer_declaration_name : THIS . (373) - - . reduce 373 - - -state 1258 - method_header : opt_attributes opt_modifiers member_type method_declaration_name . OPEN_PARENS $$20 opt_formal_parameter_list CLOSE_PARENS $$21 opt_type_parameter_constraints_clauses (179) - member_declaration_name : method_declaration_name . (370) - - OPEN_PARENS shift 674 - OPEN_BRACE reduce 370 - - -state 1259 - property_declaration : opt_attributes opt_modifiers member_type member_declaration_name . $$25 OPEN_BRACE $$26 accessor_declarations $$27 CLOSE_BRACE (221) - $$25 : . (218) - - . reduce 218 - - $$25 goto 1276 - - -state 1260 - indexer_declaration : opt_attributes opt_modifiers member_type indexer_declaration_name . OPEN_BRACKET $$28 opt_formal_parameter_list CLOSE_BRACKET OPEN_BRACE $$29 accessor_declarations $$30 CLOSE_BRACE (225) - - OPEN_BRACKET shift 1277 - . error - - -state 1261 - method_declaration_name : explicit_interface . IDENTIFIER opt_type_parameter_list (372) - indexer_declaration_name : explicit_interface . THIS (374) - explicit_interface : explicit_interface . IDENTIFIER opt_type_argument_list DOT (377) - - THIS shift 1278 - IDENTIFIER shift 677 - . error - - -state 1262 - operator_declaration : opt_attributes opt_modifiers operator_declarator $$37 . operator_body (258) - - OPEN_BRACE shift 143 - SEMICOLON shift 1279 - . error - - block goto 1280 - operator_body goto 1281 - - -state 1263 - operator_declarator : operator_type OPERATOR . overloadable_operator OPEN_PARENS $$38 opt_formal_parameter_list CLOSE_PARENS (264) - - FALSE shift 1282 - TRUE shift 1283 - TILDE shift 1284 - PLUS shift 1285 - MINUS shift 1286 - BANG shift 1287 - OP_LT shift 1288 - OP_GT shift 1289 - BITWISE_AND shift 1290 - BITWISE_OR shift 1291 - STAR shift 1292 - PERCENT shift 1293 - DIV shift 1294 - CARRET shift 1295 - OP_INC shift 1296 - OP_DEC shift 1297 - OP_SHIFT_LEFT shift 1298 - OP_SHIFT_RIGHT shift 1299 - OP_LE shift 1300 - OP_GE shift 1301 - OP_EQ shift 1302 - OP_NE shift 1303 - . error - - overloadable_operator goto 1304 - - -state 1264 - class_declaration : opt_attributes opt_modifiers opt_partial CLASS $$70 type_declaration_name $$71 opt_class_base opt_type_parameter_constraints_clauses $$72 OPEN_BRACE opt_class_member_declarations CLOSE_BRACE $$73 opt_semicolon . (652) - - . reduce 652 - - -state 1265 - block_prepared : OPEN_BRACE $$75 opt_statement_list . CLOSE_BRACE (695) - - CLOSE_BRACE shift 1305 - . error - - -state 1266 - interface_declaration : opt_attributes opt_modifiers opt_partial INTERFACE $$33 type_declaration_name $$34 opt_class_base opt_type_parameter_constraints_clauses $$35 OPEN_BRACE opt_interface_member_declarations CLOSE_BRACE $$36 opt_semicolon . (242) - - . reduce 242 - - -state 1267 - opt_join_into : INTO IDENTIFIER . (890) - - . reduce 890 - - -state 1268 - join_clause : JOIN type IDENTIFIER IN $$96 expression ON $$97 expression EQUALS $$98 expression opt_join_into . (888) - - . reduce 888 - - -state 1269 - constant_declaration : opt_attributes opt_modifiers CONST type IDENTIFIER . $$12 constant_initializer opt_constant_declarators SEMICOLON (128) - $$12 : . (127) - - . reduce 127 - - $$12 goto 1306 - - -state 1270 - member_declaration_name : method_declaration_name . (370) - - . reduce 370 - - -state 1271 - event_declaration : opt_attributes opt_modifiers EVENT type member_declaration_name . $$46 opt_event_initializer opt_event_declarators SEMICOLON (310) - event_declaration : opt_attributes opt_modifiers EVENT type member_declaration_name . OPEN_BRACE $$47 event_accessor_declarations $$48 CLOSE_BRACE (313) - $$46 : . (309) - - OPEN_BRACE shift 1307 - COMMA reduce 309 - SEMICOLON reduce 309 - ASSIGN reduce 309 - - $$46 goto 1308 - - -state 1272 - conversion_operator_declarator : EXPLICIT OPERATOR type . OPEN_PARENS $$40 opt_formal_parameter_list CLOSE_PARENS (291) - - OPEN_PARENS shift 1309 - . error - - -state 1273 - conversion_operator_declarator : IMPLICIT OPERATOR type . OPEN_PARENS $$39 opt_formal_parameter_list CLOSE_PARENS (289) - - OPEN_PARENS shift 1310 - . error - - -state 1274 - destructor_declaration : opt_attributes opt_modifiers TILDE $$45 IDENTIFIER . OPEN_PARENS CLOSE_PARENS method_body (308) - - OPEN_PARENS shift 1311 - . error - - -state 1275 - constructor_declarator : opt_attributes opt_modifiers IDENTIFIER $$41 OPEN_PARENS . opt_formal_parameter_list CLOSE_PARENS $$42 opt_constructor_initializer (297) - opt_attributes : . (59) - opt_formal_parameter_list : . (186) - - ARGLIST shift 691 - OPEN_BRACKET shift 4 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - DECIMAL reduce 59 - DOUBLE reduce 59 - FLOAT reduce 59 - INT reduce 59 - LONG reduce 59 - OBJECT reduce 59 - OUT reduce 59 - PARAMS reduce 59 - REF reduce 59 - SBYTE reduce 59 - SHORT reduce 59 - STRING reduce 59 - THIS reduce 59 - UINT reduce 59 - ULONG reduce 59 - USHORT reduce 59 - VOID reduce 59 - CLOSE_PARENS reduce 186 - IDENTIFIER reduce 59 - - opt_attributes goto 692 - attribute_sections goto 693 - attribute_section goto 30 - opt_formal_parameter_list goto 1312 - formal_parameter_list goto 695 - fixed_parameters goto 696 - parameter_array goto 697 - arglist_modifier goto 698 - fixed_parameter goto 699 - - -state 1276 - property_declaration : opt_attributes opt_modifiers member_type member_declaration_name $$25 . OPEN_BRACE $$26 accessor_declarations $$27 CLOSE_BRACE (221) - - OPEN_BRACE shift 1313 - . error - - -state 1277 - indexer_declaration : opt_attributes opt_modifiers member_type indexer_declaration_name OPEN_BRACKET . $$28 opt_formal_parameter_list CLOSE_BRACKET OPEN_BRACE $$29 accessor_declarations $$30 CLOSE_BRACE (225) - $$28 : . (222) - - . reduce 222 - - $$28 goto 1314 - - -state 1278 - indexer_declaration_name : explicit_interface THIS . (374) - - . reduce 374 - - -state 1279 - operator_body : SEMICOLON . (260) - - . reduce 260 - - -state 1280 - operator_body : block . (259) - - . reduce 259 - - -state 1281 - operator_declaration : opt_attributes opt_modifiers operator_declarator $$37 operator_body . (258) - - . reduce 258 - - -state 1282 - overloadable_operator : FALSE . (271) - - . reduce 271 - - -state 1283 - overloadable_operator : TRUE . (270) - - . reduce 270 - - -state 1284 - overloadable_operator : TILDE . (267) - - . reduce 267 - - -state 1285 - overloadable_operator : PLUS . (272) - - . reduce 272 - - -state 1286 - overloadable_operator : MINUS . (273) - - . reduce 273 - - -state 1287 - overloadable_operator : BANG . (266) - - . reduce 266 - - -state 1288 - overloadable_operator : OP_LT . (285) - - . reduce 285 - - -state 1289 - overloadable_operator : OP_GT . (284) - - . reduce 284 - - -state 1290 - overloadable_operator : BITWISE_AND . (277) - - . reduce 277 - - -state 1291 - overloadable_operator : BITWISE_OR . (278) - - . reduce 278 - - -state 1292 - overloadable_operator : STAR . (274) - - . reduce 274 - - -state 1293 - overloadable_operator : PERCENT . (276) - - . reduce 276 - - -state 1294 - overloadable_operator : DIV . (275) - - . reduce 275 - - -state 1295 - overloadable_operator : CARRET . (279) - - . reduce 279 - - -state 1296 - overloadable_operator : OP_INC . (268) - - . reduce 268 - - -state 1297 - overloadable_operator : OP_DEC . (269) - - . reduce 269 - - -state 1298 - overloadable_operator : OP_SHIFT_LEFT . (280) - - . reduce 280 - - -state 1299 - overloadable_operator : OP_SHIFT_RIGHT . (281) - - . reduce 281 - - -state 1300 - overloadable_operator : OP_LE . (287) - - . reduce 287 - - -state 1301 - overloadable_operator : OP_GE . (286) - - . reduce 286 - - -state 1302 - overloadable_operator : OP_EQ . (282) - - . reduce 282 - - -state 1303 - overloadable_operator : OP_NE . (283) - - . reduce 283 - - -state 1304 - operator_declarator : operator_type OPERATOR overloadable_operator . OPEN_PARENS $$38 opt_formal_parameter_list CLOSE_PARENS (264) - - OPEN_PARENS shift 1315 - . error - - -state 1305 - block_prepared : OPEN_BRACE $$75 opt_statement_list CLOSE_BRACE . (695) - - . reduce 695 - - -state 1306 - constant_declaration : opt_attributes opt_modifiers CONST type IDENTIFIER $$12 . constant_initializer opt_constant_declarators SEMICOLON (128) - - error shift 1316 - ASSIGN shift 1317 - . error - - constant_initializer goto 1318 - - -state 1307 - event_declaration : opt_attributes opt_modifiers EVENT type member_declaration_name OPEN_BRACE . $$47 event_accessor_declarations $$48 CLOSE_BRACE (313) - $$47 : . (311) - - . reduce 311 - - $$47 goto 1319 - - -state 1308 - event_declaration : opt_attributes opt_modifiers EVENT type member_declaration_name $$46 . opt_event_initializer opt_event_declarators SEMICOLON (310) - opt_event_initializer : . (314) - - ASSIGN shift 1320 - COMMA reduce 314 - SEMICOLON reduce 314 - - opt_event_initializer goto 1321 - - -state 1309 - conversion_operator_declarator : EXPLICIT OPERATOR type OPEN_PARENS . $$40 opt_formal_parameter_list CLOSE_PARENS (291) - $$40 : . (290) - - . reduce 290 - - $$40 goto 1322 - - -state 1310 - conversion_operator_declarator : IMPLICIT OPERATOR type OPEN_PARENS . $$39 opt_formal_parameter_list CLOSE_PARENS (289) - $$39 : . (288) - - . reduce 288 - - $$39 goto 1323 - - -state 1311 - destructor_declaration : opt_attributes opt_modifiers TILDE $$45 IDENTIFIER OPEN_PARENS . CLOSE_PARENS method_body (308) - - CLOSE_PARENS shift 1324 - . error - - -state 1312 - constructor_declarator : opt_attributes opt_modifiers IDENTIFIER $$41 OPEN_PARENS opt_formal_parameter_list . CLOSE_PARENS $$42 opt_constructor_initializer (297) - - CLOSE_PARENS shift 1325 - . error - - -state 1313 - property_declaration : opt_attributes opt_modifiers member_type member_declaration_name $$25 OPEN_BRACE . $$26 accessor_declarations $$27 CLOSE_BRACE (221) - $$26 : . (219) - - . reduce 219 - - $$26 goto 1326 - - -state 1314 - indexer_declaration : opt_attributes opt_modifiers member_type indexer_declaration_name OPEN_BRACKET $$28 . opt_formal_parameter_list CLOSE_BRACKET OPEN_BRACE $$29 accessor_declarations $$30 CLOSE_BRACE (225) - opt_attributes : . (59) - opt_formal_parameter_list : . (186) - - ARGLIST shift 691 - OPEN_BRACKET shift 4 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - DECIMAL reduce 59 - DOUBLE reduce 59 - FLOAT reduce 59 - INT reduce 59 - LONG reduce 59 - OBJECT reduce 59 - OUT reduce 59 - PARAMS reduce 59 - REF reduce 59 - SBYTE reduce 59 - SHORT reduce 59 - STRING reduce 59 - THIS reduce 59 - UINT reduce 59 - ULONG reduce 59 - USHORT reduce 59 - VOID reduce 59 - CLOSE_BRACKET reduce 186 - IDENTIFIER reduce 59 - - opt_attributes goto 692 - attribute_sections goto 693 - attribute_section goto 30 - opt_formal_parameter_list goto 1327 - formal_parameter_list goto 695 - fixed_parameters goto 696 - parameter_array goto 697 - arglist_modifier goto 698 - fixed_parameter goto 699 - - -state 1315 - operator_declarator : operator_type OPERATOR overloadable_operator OPEN_PARENS . $$38 opt_formal_parameter_list CLOSE_PARENS (264) - $$38 : . (263) - - . reduce 263 - - $$38 goto 1328 - - -state 1316 - constant_initializer : error . (136) - - . reduce 136 - - -state 1317 - constant_initializer : ASSIGN . $$13 constant_initializer_expr (135) - $$13 : . (134) - - . reduce 134 - - $$13 goto 1329 - - -state 1318 - constant_declaration : opt_attributes opt_modifiers CONST type IDENTIFIER $$12 constant_initializer . opt_constant_declarators SEMICOLON (128) - opt_constant_declarators : . (129) - - COMMA shift 1330 - SEMICOLON reduce 129 - - opt_constant_declarators goto 1331 - constant_declarators goto 1332 - constant_declarator goto 1333 - - -state 1319 - event_declaration : opt_attributes opt_modifiers EVENT type member_declaration_name OPEN_BRACE $$47 . event_accessor_declarations $$48 CLOSE_BRACE (313) - opt_attributes : . (59) - - error shift 1334 - OPEN_BRACKET shift 4 - ABSTRACT reduce 59 - ADD reduce 59 - EXTERN reduce 59 - INTERNAL reduce 59 - NEW reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - REMOVE reduce 59 - SEALED reduce 59 - STATIC reduce 59 - UNSAFE reduce 59 - VIRTUAL reduce 59 - VOLATILE reduce 59 - - opt_attributes goto 1335 - attribute_sections goto 693 - attribute_section goto 30 - event_accessor_declarations goto 1336 - add_accessor_declaration goto 1337 - remove_accessor_declaration goto 1338 - - -state 1320 - opt_event_initializer : ASSIGN . $$49 event_variable_initializer (316) - $$49 : . (315) - - . reduce 315 - - $$49 goto 1339 - - -state 1321 - event_declaration : opt_attributes opt_modifiers EVENT type member_declaration_name $$46 opt_event_initializer . opt_event_declarators SEMICOLON (310) - opt_event_declarators : . (317) - - COMMA shift 1340 - SEMICOLON reduce 317 - - opt_event_declarators goto 1341 - event_declarators goto 1342 - event_declarator goto 1343 - - -state 1322 - conversion_operator_declarator : EXPLICIT OPERATOR type OPEN_PARENS $$40 . opt_formal_parameter_list CLOSE_PARENS (291) - opt_attributes : . (59) - opt_formal_parameter_list : . (186) - - ARGLIST shift 691 - OPEN_BRACKET shift 4 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - DECIMAL reduce 59 - DOUBLE reduce 59 - FLOAT reduce 59 - INT reduce 59 - LONG reduce 59 - OBJECT reduce 59 - OUT reduce 59 - PARAMS reduce 59 - REF reduce 59 - SBYTE reduce 59 - SHORT reduce 59 - STRING reduce 59 - THIS reduce 59 - UINT reduce 59 - ULONG reduce 59 - USHORT reduce 59 - VOID reduce 59 - CLOSE_PARENS reduce 186 - IDENTIFIER reduce 59 - - opt_attributes goto 692 - attribute_sections goto 693 - attribute_section goto 30 - opt_formal_parameter_list goto 1344 - formal_parameter_list goto 695 - fixed_parameters goto 696 - parameter_array goto 697 - arglist_modifier goto 698 - fixed_parameter goto 699 - - -state 1323 - conversion_operator_declarator : IMPLICIT OPERATOR type OPEN_PARENS $$39 . opt_formal_parameter_list CLOSE_PARENS (289) - opt_attributes : . (59) - opt_formal_parameter_list : . (186) - - ARGLIST shift 691 - OPEN_BRACKET shift 4 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - DECIMAL reduce 59 - DOUBLE reduce 59 - FLOAT reduce 59 - INT reduce 59 - LONG reduce 59 - OBJECT reduce 59 - OUT reduce 59 - PARAMS reduce 59 - REF reduce 59 - SBYTE reduce 59 - SHORT reduce 59 - STRING reduce 59 - THIS reduce 59 - UINT reduce 59 - ULONG reduce 59 - USHORT reduce 59 - VOID reduce 59 - CLOSE_PARENS reduce 186 - IDENTIFIER reduce 59 - - opt_attributes goto 692 - attribute_sections goto 693 - attribute_section goto 30 - opt_formal_parameter_list goto 1345 - formal_parameter_list goto 695 - fixed_parameters goto 696 - parameter_array goto 697 - arglist_modifier goto 698 - fixed_parameter goto 699 - - -state 1324 - destructor_declaration : opt_attributes opt_modifiers TILDE $$45 IDENTIFIER OPEN_PARENS CLOSE_PARENS . method_body (308) - - OPEN_BRACE shift 143 - SEMICOLON shift 263 - . error - - method_body goto 1346 - block goto 265 - - -state 1325 - constructor_declarator : opt_attributes opt_modifiers IDENTIFIER $$41 OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS . $$42 opt_constructor_initializer (297) - $$42 : . (296) - - . reduce 296 - - $$42 goto 1347 - - -state 1326 - property_declaration : opt_attributes opt_modifiers member_type member_declaration_name $$25 OPEN_BRACE $$26 . accessor_declarations $$27 CLOSE_BRACE (221) - opt_attributes : . (59) - - error shift 1348 - OPEN_BRACKET shift 4 - ABSTRACT reduce 59 - EXTERN reduce 59 - INTERNAL reduce 59 - NEW reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - SEALED reduce 59 - STATIC reduce 59 - UNSAFE reduce 59 - VIRTUAL reduce 59 - VOLATILE reduce 59 - GET reduce 59 - SET reduce 59 - - opt_attributes goto 1349 - attribute_sections goto 693 - attribute_section goto 30 - accessor_declarations goto 1350 - get_accessor_declaration goto 1351 - set_accessor_declaration goto 1352 - - -state 1327 - indexer_declaration : opt_attributes opt_modifiers member_type indexer_declaration_name OPEN_BRACKET $$28 opt_formal_parameter_list . CLOSE_BRACKET OPEN_BRACE $$29 accessor_declarations $$30 CLOSE_BRACE (225) - - CLOSE_BRACKET shift 1353 - . error - - -state 1328 - operator_declarator : operator_type OPERATOR overloadable_operator OPEN_PARENS $$38 . opt_formal_parameter_list CLOSE_PARENS (264) - opt_attributes : . (59) - opt_formal_parameter_list : . (186) - - ARGLIST shift 691 - OPEN_BRACKET shift 4 - BOOL reduce 59 - BYTE reduce 59 - CHAR reduce 59 - DECIMAL reduce 59 - DOUBLE reduce 59 - FLOAT reduce 59 - INT reduce 59 - LONG reduce 59 - OBJECT reduce 59 - OUT reduce 59 - PARAMS reduce 59 - REF reduce 59 - SBYTE reduce 59 - SHORT reduce 59 - STRING reduce 59 - THIS reduce 59 - UINT reduce 59 - ULONG reduce 59 - USHORT reduce 59 - VOID reduce 59 - CLOSE_PARENS reduce 186 - IDENTIFIER reduce 59 - - opt_attributes goto 692 - attribute_sections goto 693 - attribute_section goto 30 - opt_formal_parameter_list goto 1354 - formal_parameter_list goto 695 - fixed_parameters goto 696 - parameter_array goto 697 - arglist_modifier goto 698 - fixed_parameter goto 699 - - -state 1329 - constant_initializer : ASSIGN $$13 . constant_initializer_expr (135) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 531 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 514 - constant_initializer_expr goto 1355 - constant_expression goto 840 - array_initializer goto 841 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1330 - constant_declarator : COMMA . IDENTIFIER constant_initializer (133) - - IDENTIFIER shift 1356 - . error - - -state 1331 - constant_declaration : opt_attributes opt_modifiers CONST type IDENTIFIER $$12 constant_initializer opt_constant_declarators . SEMICOLON (128) - - SEMICOLON shift 1357 - . error - - -state 1332 - opt_constant_declarators : constant_declarators . (130) - constant_declarators : constant_declarators . constant_declarator (132) - - COMMA shift 1330 - SEMICOLON reduce 130 - - constant_declarator goto 1358 - - -state 1333 - constant_declarators : constant_declarator . (131) - - . reduce 131 - - -state 1334 - event_accessor_declarations : error . (330) - - . reduce 330 - - -state 1335 - add_accessor_declaration : opt_attributes . opt_modifiers ADD $$52 event_accessor_block (332) - remove_accessor_declaration : opt_attributes . opt_modifiers REMOVE $$53 event_accessor_block (334) - opt_modifiers : . (655) - - ABSTRACT shift 61 - EXTERN shift 62 - INTERNAL shift 63 - NEW shift 65 - OVERRIDE shift 66 - PRIVATE shift 67 - PROTECTED shift 68 - PUBLIC shift 69 - READONLY shift 70 - SEALED shift 71 - STATIC shift 72 - UNSAFE shift 73 - VIRTUAL shift 74 - VOLATILE shift 75 - ADD reduce 655 - REMOVE reduce 655 - - opt_modifiers goto 1359 - modifiers goto 77 - modifier goto 78 - - -state 1336 - event_declaration : opt_attributes opt_modifiers EVENT type member_declaration_name OPEN_BRACE $$47 event_accessor_declarations . $$48 CLOSE_BRACE (313) - $$48 : . (312) - - . reduce 312 - - $$48 goto 1360 - - -state 1337 - event_accessor_declarations : add_accessor_declaration . remove_accessor_declaration (326) - event_accessor_declarations : add_accessor_declaration . (328) - opt_attributes : . (59) - - OPEN_BRACKET shift 4 - ABSTRACT reduce 59 - EXTERN reduce 59 - INTERNAL reduce 59 - NEW reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - REMOVE reduce 59 - SEALED reduce 59 - STATIC reduce 59 - UNSAFE reduce 59 - VIRTUAL reduce 59 - VOLATILE reduce 59 - CLOSE_BRACE reduce 328 - - opt_attributes goto 1361 - attribute_sections goto 693 - attribute_section goto 30 - remove_accessor_declaration goto 1362 - - -state 1338 - event_accessor_declarations : remove_accessor_declaration . add_accessor_declaration (327) - event_accessor_declarations : remove_accessor_declaration . (329) - opt_attributes : . (59) - - OPEN_BRACKET shift 4 - ABSTRACT reduce 59 - ADD reduce 59 - EXTERN reduce 59 - INTERNAL reduce 59 - NEW reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - SEALED reduce 59 - STATIC reduce 59 - UNSAFE reduce 59 - VIRTUAL reduce 59 - VOLATILE reduce 59 - CLOSE_BRACE reduce 329 - - opt_attributes goto 1363 - attribute_sections goto 693 - attribute_section goto 30 - add_accessor_declaration goto 1364 - - -state 1339 - opt_event_initializer : ASSIGN $$49 . event_variable_initializer (316) - $$51 : . (324) - - . reduce 324 - - event_variable_initializer goto 1365 - $$51 goto 1366 - - -state 1340 - event_declarator : COMMA . IDENTIFIER (321) - event_declarator : COMMA . IDENTIFIER ASSIGN $$50 event_variable_initializer (323) - - IDENTIFIER shift 1367 - . error - - -state 1341 - event_declaration : opt_attributes opt_modifiers EVENT type member_declaration_name $$46 opt_event_initializer opt_event_declarators . SEMICOLON (310) - - SEMICOLON shift 1368 - . error - - -state 1342 - opt_event_declarators : event_declarators . (318) - event_declarators : event_declarators . event_declarator (320) - - COMMA shift 1340 - SEMICOLON reduce 318 - - event_declarator goto 1369 - - -state 1343 - event_declarators : event_declarator . (319) - - . reduce 319 - - -state 1344 - conversion_operator_declarator : EXPLICIT OPERATOR type OPEN_PARENS $$40 opt_formal_parameter_list . CLOSE_PARENS (291) - - CLOSE_PARENS shift 1370 - . error - - -state 1345 - conversion_operator_declarator : IMPLICIT OPERATOR type OPEN_PARENS $$39 opt_formal_parameter_list . CLOSE_PARENS (289) - - CLOSE_PARENS shift 1371 - . error - - -state 1346 - destructor_declaration : opt_attributes opt_modifiers TILDE $$45 IDENTIFIER OPEN_PARENS CLOSE_PARENS method_body . (308) - - . reduce 308 - - -state 1347 - constructor_declarator : opt_attributes opt_modifiers IDENTIFIER $$41 OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS $$42 . opt_constructor_initializer (297) - opt_constructor_initializer : . (300) - - COLON shift 1372 - OPEN_BRACE reduce 300 - SEMICOLON reduce 300 - - opt_constructor_initializer goto 1373 - constructor_initializer goto 1374 - - -state 1348 - accessor_declarations : error . (230) - - . reduce 230 - - -state 1349 - get_accessor_declaration : opt_attributes . opt_modifiers GET $$31 accessor_body (232) - set_accessor_declaration : opt_attributes . opt_modifiers SET $$32 accessor_body (234) - opt_modifiers : . (655) - - ABSTRACT shift 61 - EXTERN shift 62 - INTERNAL shift 63 - NEW shift 65 - OVERRIDE shift 66 - PRIVATE shift 67 - PROTECTED shift 68 - PUBLIC shift 69 - READONLY shift 70 - SEALED shift 71 - STATIC shift 72 - UNSAFE shift 73 - VIRTUAL shift 74 - VOLATILE shift 75 - GET reduce 655 - SET reduce 655 - - opt_modifiers goto 1375 - modifiers goto 77 - modifier goto 78 - - -state 1350 - property_declaration : opt_attributes opt_modifiers member_type member_declaration_name $$25 OPEN_BRACE $$26 accessor_declarations . $$27 CLOSE_BRACE (221) - $$27 : . (220) - - . reduce 220 - - $$27 goto 1376 - - -state 1351 - accessor_declarations : get_accessor_declaration . (226) - accessor_declarations : get_accessor_declaration . accessor_declarations (227) - opt_attributes : . (59) - - error shift 1348 - OPEN_BRACKET shift 4 - ABSTRACT reduce 59 - EXTERN reduce 59 - INTERNAL reduce 59 - NEW reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - SEALED reduce 59 - STATIC reduce 59 - UNSAFE reduce 59 - VIRTUAL reduce 59 - VOLATILE reduce 59 - GET reduce 59 - SET reduce 59 - CLOSE_BRACE reduce 226 - - opt_attributes goto 1349 - attribute_sections goto 693 - attribute_section goto 30 - accessor_declarations goto 1377 - get_accessor_declaration goto 1351 - set_accessor_declaration goto 1352 - - -state 1352 - accessor_declarations : set_accessor_declaration . (228) - accessor_declarations : set_accessor_declaration . accessor_declarations (229) - opt_attributes : . (59) - - error shift 1348 - OPEN_BRACKET shift 4 - ABSTRACT reduce 59 - EXTERN reduce 59 - INTERNAL reduce 59 - NEW reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - SEALED reduce 59 - STATIC reduce 59 - UNSAFE reduce 59 - VIRTUAL reduce 59 - VOLATILE reduce 59 - GET reduce 59 - SET reduce 59 - CLOSE_BRACE reduce 228 - - opt_attributes goto 1349 - attribute_sections goto 693 - attribute_section goto 30 - accessor_declarations goto 1378 - get_accessor_declaration goto 1351 - set_accessor_declaration goto 1352 - - -state 1353 - indexer_declaration : opt_attributes opt_modifiers member_type indexer_declaration_name OPEN_BRACKET $$28 opt_formal_parameter_list CLOSE_BRACKET . OPEN_BRACE $$29 accessor_declarations $$30 CLOSE_BRACE (225) - - OPEN_BRACE shift 1379 - . error - - -state 1354 - operator_declarator : operator_type OPERATOR overloadable_operator OPEN_PARENS $$38 opt_formal_parameter_list . CLOSE_PARENS (264) - - CLOSE_PARENS shift 1380 - . error - - -state 1355 - constant_initializer : ASSIGN $$13 constant_initializer_expr . (135) - - . reduce 135 - - -state 1356 - constant_declarator : COMMA IDENTIFIER . constant_initializer (133) - - error shift 1316 - ASSIGN shift 1317 - . error - - constant_initializer goto 1381 - - -state 1357 - constant_declaration : opt_attributes opt_modifiers CONST type IDENTIFIER $$12 constant_initializer opt_constant_declarators SEMICOLON . (128) - - . reduce 128 - - -state 1358 - constant_declarators : constant_declarators constant_declarator . (132) - - . reduce 132 - - -state 1359 - add_accessor_declaration : opt_attributes opt_modifiers . ADD $$52 event_accessor_block (332) - remove_accessor_declaration : opt_attributes opt_modifiers . REMOVE $$53 event_accessor_block (334) - - ADD shift 1382 - REMOVE shift 1383 - . error - - -state 1360 - event_declaration : opt_attributes opt_modifiers EVENT type member_declaration_name OPEN_BRACE $$47 event_accessor_declarations $$48 . CLOSE_BRACE (313) - - CLOSE_BRACE shift 1384 - . error - - -state 1361 - remove_accessor_declaration : opt_attributes . opt_modifiers REMOVE $$53 event_accessor_block (334) - opt_modifiers : . (655) - - ABSTRACT shift 61 - EXTERN shift 62 - INTERNAL shift 63 - NEW shift 65 - OVERRIDE shift 66 - PRIVATE shift 67 - PROTECTED shift 68 - PUBLIC shift 69 - READONLY shift 70 - SEALED shift 71 - STATIC shift 72 - UNSAFE shift 73 - VIRTUAL shift 74 - VOLATILE shift 75 - REMOVE reduce 655 - - opt_modifiers goto 1385 - modifiers goto 77 - modifier goto 78 - - -state 1362 - event_accessor_declarations : add_accessor_declaration remove_accessor_declaration . (326) - - . reduce 326 - - -state 1363 - add_accessor_declaration : opt_attributes . opt_modifiers ADD $$52 event_accessor_block (332) - opt_modifiers : . (655) - - ABSTRACT shift 61 - EXTERN shift 62 - INTERNAL shift 63 - NEW shift 65 - OVERRIDE shift 66 - PRIVATE shift 67 - PROTECTED shift 68 - PUBLIC shift 69 - READONLY shift 70 - SEALED shift 71 - STATIC shift 72 - UNSAFE shift 73 - VIRTUAL shift 74 - VOLATILE shift 75 - ADD reduce 655 - - opt_modifiers goto 1386 - modifiers goto 77 - modifier goto 78 - - -state 1364 - event_accessor_declarations : remove_accessor_declaration add_accessor_declaration . (327) - - . reduce 327 - - -state 1365 - opt_event_initializer : ASSIGN $$49 event_variable_initializer . (316) - - . reduce 316 - - -state 1366 - event_variable_initializer : $$51 . variable_initializer (325) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_BRACE shift 531 - OPEN_PARENS shift 144 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 337 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - . error - - expression goto 719 - array_initializer goto 720 - variable_initializer goto 1387 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1367 - event_declarator : COMMA IDENTIFIER . (321) - event_declarator : COMMA IDENTIFIER . ASSIGN $$50 event_variable_initializer (323) - - ASSIGN shift 1388 - COMMA reduce 321 - SEMICOLON reduce 321 - - -state 1368 - event_declaration : opt_attributes opt_modifiers EVENT type member_declaration_name $$46 opt_event_initializer opt_event_declarators SEMICOLON . (310) - - . reduce 310 - - -state 1369 - event_declarators : event_declarators event_declarator . (320) - - . reduce 320 - - -state 1370 - conversion_operator_declarator : EXPLICIT OPERATOR type OPEN_PARENS $$40 opt_formal_parameter_list CLOSE_PARENS . (291) - - . reduce 291 - - -state 1371 - conversion_operator_declarator : IMPLICIT OPERATOR type OPEN_PARENS $$39 opt_formal_parameter_list CLOSE_PARENS . (289) - - . reduce 289 - - -state 1372 - constructor_initializer : COLON . BASE OPEN_PARENS $$43 opt_argument_list CLOSE_PARENS (303) - constructor_initializer : COLON . THIS OPEN_PARENS $$44 opt_argument_list CLOSE_PARENS (305) - constructor_initializer : COLON . error (306) - - error shift 1389 - BASE shift 1390 - THIS shift 1391 - . error - - -state 1373 - constructor_declarator : opt_attributes opt_modifiers IDENTIFIER $$41 OPEN_PARENS opt_formal_parameter_list CLOSE_PARENS $$42 opt_constructor_initializer . (297) - - . reduce 297 - - -state 1374 - opt_constructor_initializer : constructor_initializer . (301) - - . reduce 301 - - -state 1375 - get_accessor_declaration : opt_attributes opt_modifiers . GET $$31 accessor_body (232) - set_accessor_declaration : opt_attributes opt_modifiers . SET $$32 accessor_body (234) - - GET shift 1392 - SET shift 1393 - . error - - -state 1376 - property_declaration : opt_attributes opt_modifiers member_type member_declaration_name $$25 OPEN_BRACE $$26 accessor_declarations $$27 . CLOSE_BRACE (221) - - CLOSE_BRACE shift 1394 - . error - - -state 1377 - accessor_declarations : get_accessor_declaration accessor_declarations . (227) - - . reduce 227 - - -state 1378 - accessor_declarations : set_accessor_declaration accessor_declarations . (229) - - . reduce 229 - - -state 1379 - indexer_declaration : opt_attributes opt_modifiers member_type indexer_declaration_name OPEN_BRACKET $$28 opt_formal_parameter_list CLOSE_BRACKET OPEN_BRACE . $$29 accessor_declarations $$30 CLOSE_BRACE (225) - $$29 : . (223) - - . reduce 223 - - $$29 goto 1395 - - -state 1380 - operator_declarator : operator_type OPERATOR overloadable_operator OPEN_PARENS $$38 opt_formal_parameter_list CLOSE_PARENS . (264) - - . reduce 264 - - -state 1381 - constant_declarator : COMMA IDENTIFIER constant_initializer . (133) - - . reduce 133 - - -state 1382 - add_accessor_declaration : opt_attributes opt_modifiers ADD . $$52 event_accessor_block (332) - $$52 : . (331) - - . reduce 331 - - $$52 goto 1396 - - -state 1383 - remove_accessor_declaration : opt_attributes opt_modifiers REMOVE . $$53 event_accessor_block (334) - $$53 : . (333) - - . reduce 333 - - $$53 goto 1397 - - -state 1384 - event_declaration : opt_attributes opt_modifiers EVENT type member_declaration_name OPEN_BRACE $$47 event_accessor_declarations $$48 CLOSE_BRACE . (313) - - . reduce 313 - - -state 1385 - remove_accessor_declaration : opt_attributes opt_modifiers . REMOVE $$53 event_accessor_block (334) - - REMOVE shift 1383 - . error - - -state 1386 - add_accessor_declaration : opt_attributes opt_modifiers . ADD $$52 event_accessor_block (332) - - ADD shift 1382 - . error - - -state 1387 - event_variable_initializer : $$51 variable_initializer . (325) - - . reduce 325 - - -state 1388 - event_declarator : COMMA IDENTIFIER ASSIGN . $$50 event_variable_initializer (323) - $$50 : . (322) - - . reduce 322 - - $$50 goto 1398 - - -state 1389 - constructor_initializer : COLON error . (306) - - . reduce 306 - - -state 1390 - constructor_initializer : COLON BASE . OPEN_PARENS $$43 opt_argument_list CLOSE_PARENS (303) - - OPEN_PARENS shift 1399 - . error - - -state 1391 - constructor_initializer : COLON THIS . OPEN_PARENS $$44 opt_argument_list CLOSE_PARENS (305) - - OPEN_PARENS shift 1400 - . error - - -state 1392 - get_accessor_declaration : opt_attributes opt_modifiers GET . $$31 accessor_body (232) - $$31 : . (231) - - . reduce 231 - - $$31 goto 1401 - - -state 1393 - set_accessor_declaration : opt_attributes opt_modifiers SET . $$32 accessor_body (234) - $$32 : . (233) - - . reduce 233 - - $$32 goto 1402 - - -state 1394 - property_declaration : opt_attributes opt_modifiers member_type member_declaration_name $$25 OPEN_BRACE $$26 accessor_declarations $$27 CLOSE_BRACE . (221) - - . reduce 221 - - -state 1395 - indexer_declaration : opt_attributes opt_modifiers member_type indexer_declaration_name OPEN_BRACKET $$28 opt_formal_parameter_list CLOSE_BRACKET OPEN_BRACE $$29 . accessor_declarations $$30 CLOSE_BRACE (225) - opt_attributes : . (59) - - error shift 1348 - OPEN_BRACKET shift 4 - ABSTRACT reduce 59 - EXTERN reduce 59 - INTERNAL reduce 59 - NEW reduce 59 - OVERRIDE reduce 59 - PRIVATE reduce 59 - PROTECTED reduce 59 - PUBLIC reduce 59 - READONLY reduce 59 - SEALED reduce 59 - STATIC reduce 59 - UNSAFE reduce 59 - VIRTUAL reduce 59 - VOLATILE reduce 59 - GET reduce 59 - SET reduce 59 - - opt_attributes goto 1349 - attribute_sections goto 693 - attribute_section goto 30 - accessor_declarations goto 1403 - get_accessor_declaration goto 1351 - set_accessor_declaration goto 1352 - - -state 1396 - add_accessor_declaration : opt_attributes opt_modifiers ADD $$52 . event_accessor_block (332) - opt_semicolon : . (30) - - OPEN_BRACE shift 143 - SEMICOLON shift 810 - ABSTRACT reduce 30 - EXTERN reduce 30 - INTERNAL reduce 30 - NEW reduce 30 - OVERRIDE reduce 30 - PRIVATE reduce 30 - PROTECTED reduce 30 - PUBLIC reduce 30 - READONLY reduce 30 - REMOVE reduce 30 - SEALED reduce 30 - STATIC reduce 30 - UNSAFE reduce 30 - VIRTUAL reduce 30 - VOLATILE reduce 30 - CLOSE_BRACE reduce 30 - OPEN_BRACKET reduce 30 - - opt_semicolon goto 1404 - block goto 1405 - event_accessor_block goto 1406 - - -state 1397 - remove_accessor_declaration : opt_attributes opt_modifiers REMOVE $$53 . event_accessor_block (334) - opt_semicolon : . (30) - - OPEN_BRACE shift 143 - SEMICOLON shift 810 - ABSTRACT reduce 30 - ADD reduce 30 - EXTERN reduce 30 - INTERNAL reduce 30 - NEW reduce 30 - OVERRIDE reduce 30 - PRIVATE reduce 30 - PROTECTED reduce 30 - PUBLIC reduce 30 - READONLY reduce 30 - SEALED reduce 30 - STATIC reduce 30 - UNSAFE reduce 30 - VIRTUAL reduce 30 - VOLATILE reduce 30 - CLOSE_BRACE reduce 30 - OPEN_BRACKET reduce 30 - - opt_semicolon goto 1404 - block goto 1405 - event_accessor_block goto 1407 - - -state 1398 - event_declarator : COMMA IDENTIFIER ASSIGN $$50 . event_variable_initializer (323) - $$51 : . (324) - - . reduce 324 - - event_variable_initializer goto 1408 - $$51 goto 1366 - - -state 1399 - constructor_initializer : COLON BASE OPEN_PARENS . $$43 opt_argument_list CLOSE_PARENS (303) - $$43 : . (302) - - . reduce 302 - - $$43 goto 1409 - - -state 1400 - constructor_initializer : COLON THIS OPEN_PARENS . $$44 opt_argument_list CLOSE_PARENS (305) - $$44 : . (304) - - . reduce 304 - - $$44 goto 1410 - - -state 1401 - get_accessor_declaration : opt_attributes opt_modifiers GET $$31 . accessor_body (232) - - error shift 1411 - OPEN_BRACE shift 143 - SEMICOLON shift 1412 - . error - - block goto 1413 - accessor_body goto 1414 - - -state 1402 - set_accessor_declaration : opt_attributes opt_modifiers SET $$32 . accessor_body (234) - - error shift 1411 - OPEN_BRACE shift 143 - SEMICOLON shift 1412 - . error - - block goto 1413 - accessor_body goto 1415 - - -state 1403 - indexer_declaration : opt_attributes opt_modifiers member_type indexer_declaration_name OPEN_BRACKET $$28 opt_formal_parameter_list CLOSE_BRACKET OPEN_BRACE $$29 accessor_declarations . $$30 CLOSE_BRACE (225) - $$30 : . (224) - - . reduce 224 - - $$30 goto 1416 - - -state 1404 - event_accessor_block : opt_semicolon . (335) - - . reduce 335 - - -state 1405 - event_accessor_block : block . (336) - - . reduce 336 - - -state 1406 - add_accessor_declaration : opt_attributes opt_modifiers ADD $$52 event_accessor_block . (332) - - . reduce 332 - - -state 1407 - remove_accessor_declaration : opt_attributes opt_modifiers REMOVE $$53 event_accessor_block . (334) - - . reduce 334 - - -state 1408 - event_declarator : COMMA IDENTIFIER ASSIGN $$50 event_variable_initializer . (323) - - . reduce 323 - - -state 1409 - constructor_initializer : COLON BASE OPEN_PARENS $$43 . opt_argument_list CLOSE_PARENS (303) - opt_argument_list : . (477) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - OUT shift 594 - REF shift 595 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - ARGLIST shift 596 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - COMMA shift 597 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 492 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - CLOSE_PARENS reduce 477 - - expression goto 598 - named_argument goto 599 - opt_argument_list goto 1417 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - argument_list goto 601 - argument_or_named_argument goto 602 - argument goto 603 - non_simple_argument goto 604 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1410 - constructor_initializer : COLON THIS OPEN_PARENS $$44 . opt_argument_list CLOSE_PARENS (305) - opt_argument_list : . (477) - - BASE shift 96 - BOOL shift 97 - BYTE shift 99 - CHAR shift 100 - CHECKED shift 288 - DECIMAL shift 104 - DEFAULT shift 105 - DELEGATE shift 106 - DOUBLE shift 108 - FALSE shift 109 - FLOAT shift 111 - INT shift 116 - LONG shift 118 - NEW shift 119 - NULL shift 120 - OBJECT shift 121 - OUT shift 594 - REF shift 595 - SBYTE shift 123 - SHORT shift 124 - SIZEOF shift 125 - STRING shift 126 - THIS shift 128 - TRUE shift 130 - TYPEOF shift 132 - UINT shift 133 - ULONG shift 134 - UNCHECKED shift 289 - USHORT shift 137 - ARGLIST shift 596 - FROM shift 141 - FROM_FIRST shift 142 - OPEN_PARENS shift 144 - COMMA shift 597 - TILDE shift 146 - PLUS shift 147 - MINUS shift 148 - BANG shift 149 - BITWISE_AND shift 150 - STAR shift 151 - OP_INC shift 152 - OP_DEC shift 153 - LITERAL shift 154 - IDENTIFIER shift 492 - OPEN_PARENS_LAMBDA shift 156 - OPEN_PARENS_CAST shift 157 - CLOSE_PARENS reduce 477 - - expression goto 598 - named_argument goto 599 - opt_argument_list goto 1418 - qualified_alias_member goto 160 - builtin_types goto 340 - integral_type goto 162 - primary_expression goto 163 - primary_expression_no_array_creation goto 341 - array_creation_expression goto 165 - literal goto 166 - parenthesized_expression goto 167 - default_value_expression goto 168 - member_access goto 169 - invocation_expression goto 170 - element_access goto 171 - this_access goto 172 - base_access goto 173 - post_increment_expression goto 174 - post_decrement_expression goto 175 - object_or_delegate_creation_expression goto 176 - anonymous_type_expression goto 177 - typeof_expression goto 178 - sizeof_expression goto 179 - checked_expression goto 180 - unchecked_expression goto 181 - pointer_member_access goto 182 - anonymous_method_expression goto 183 - boolean_literal goto 184 - non_assignment_expression goto 185 - argument_list goto 601 - argument_or_named_argument goto 602 - argument goto 603 - non_simple_argument goto 604 - unary_expression goto 186 - prefixed_unary_expression goto 187 - cast_expression goto 188 - multiplicative_expression goto 189 - additive_expression goto 190 - shift_expression goto 191 - relational_expression goto 192 - equality_expression goto 193 - and_expression goto 194 - exclusive_or_expression goto 195 - inclusive_or_expression goto 196 - conditional_and_expression goto 197 - conditional_or_expression goto 198 - null_coalescing_expression goto 199 - conditional_expression goto 200 - assignment_expression goto 201 - lambda_expression goto 202 - query_expression goto 203 - first_from_clause goto 239 - nested_from_clause goto 240 - - -state 1411 - accessor_body : error . (237) - - . reduce 237 - - -state 1412 - accessor_body : SEMICOLON . (236) - - . reduce 236 - - -state 1413 - accessor_body : block . (235) - - . reduce 235 - - -state 1414 - get_accessor_declaration : opt_attributes opt_modifiers GET $$31 accessor_body . (232) - - . reduce 232 - - -state 1415 - set_accessor_declaration : opt_attributes opt_modifiers SET $$32 accessor_body . (234) - - . reduce 234 - - -state 1416 - indexer_declaration : opt_attributes opt_modifiers member_type indexer_declaration_name OPEN_BRACKET $$28 opt_formal_parameter_list CLOSE_BRACKET OPEN_BRACE $$29 accessor_declarations $$30 . CLOSE_BRACE (225) - - CLOSE_BRACE shift 1419 - . error - - -state 1417 - constructor_initializer : COLON BASE OPEN_PARENS $$43 opt_argument_list . CLOSE_PARENS (303) - - CLOSE_PARENS shift 1420 - . error - - -state 1418 - constructor_initializer : COLON THIS OPEN_PARENS $$44 opt_argument_list . CLOSE_PARENS (305) - - CLOSE_PARENS shift 1421 - . error - - -state 1419 - indexer_declaration : opt_attributes opt_modifiers member_type indexer_declaration_name OPEN_BRACKET $$28 opt_formal_parameter_list CLOSE_BRACKET OPEN_BRACE $$29 accessor_declarations $$30 CLOSE_BRACE . (225) - - . reduce 225 - - -state 1420 - constructor_initializer : COLON BASE OPEN_PARENS $$43 opt_argument_list CLOSE_PARENS . (303) - - . reduce 303 - - -state 1421 - constructor_initializer : COLON THIS OPEN_PARENS $$44 opt_argument_list CLOSE_PARENS . (305) - - . reduce 305 - - -State 164 contains 1 shift/reduce conflict. -State 167 contains 1 shift/reduce conflict. -State 239 contains 1 shift/reduce conflict. -State 240 contains 1 shift/reduce conflict. -State 484 contains 1 shift/reduce conflict. -State 654 contains 1 shift/reduce conflict. -State 729 contains 1 shift/reduce conflict. -State 730 contains 1 shift/reduce conflict. -State 860 contains 1 shift/reduce conflict. - - -170 terminals, 432 nonterminals -922 grammar rules, 1422 states diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Properties/AssemblyInfo.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Properties/AssemblyInfo.cs index c2097abec5..88b738ea91 100644 --- a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Properties/AssemblyInfo.cs +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Properties/AssemblyInfo.cs @@ -10,22 +10,4 @@ using System.Runtime.InteropServices; // set of attributes. Change these attribute values to modify the information // associated with an assembly. [assembly: AssemblyTitle("ICSharpCode.NRefactory.CSharp")] -[assembly: AssemblyDescription("")] -[assembly: AssemblyConfiguration("")] -[assembly: AssemblyCompany("ICSharpCode")] -[assembly: AssemblyProduct("SharpDevelop/MonoDevelop")] -[assembly: AssemblyCopyright("Copyright 2010-2012 AlphaSierraPapa")] -[assembly: AssemblyTrademark("")] -[assembly: AssemblyCulture("")] - -// This sets the default COM visibility of types in the assembly to invisible. -// If you need to expose a type to COM, use [ComVisible(true)] on that type. -[assembly: ComVisible(false)] - -// The assembly version has following format : -// -// Major.Minor.Build.Revision -// -// You can specify all the values or you can use the default the Revision and -// Build Numbers by using the '*' as shown below: -[assembly: AssemblyVersion("5.0.0.3")] +[assembly: AssemblyDescription("C# parser and semantic analysis")] diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/BaseRefactoringContext.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/BaseRefactoringContext.cs new file mode 100644 index 0000000000..449be597dc --- /dev/null +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/BaseRefactoringContext.cs @@ -0,0 +1,172 @@ +// +// BaseRefactoringContext.cs +// +// Author: +// Mike Krüger +// +// Copyright (c) 2012 Xamarin +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +// THE SOFTWARE. + +using System; +using System.Linq; +using System.Threading; +using ICSharpCode.NRefactory.CSharp.Resolver; +using ICSharpCode.NRefactory.CSharp.TypeSystem; +using ICSharpCode.NRefactory.Semantics; +using ICSharpCode.NRefactory.TypeSystem; +using ICSharpCode.NRefactory.TypeSystem.Implementation; +using ICSharpCode.NRefactory.Editor; +using System.ComponentModel.Design; +using ICSharpCode.NRefactory.CSharp.Analysis; + +namespace ICSharpCode.NRefactory.CSharp.Refactoring +{ + public abstract class BaseRefactoringContext : IServiceProvider + { + readonly CSharpAstResolver resolver; + readonly CancellationToken cancellationToken; + + public virtual bool Supports(Version version) + { + return true; + } + + /// + /// Gets a value indicating if 'var' keyword should be used or explicit types. + /// + public virtual bool UseExplicitTypes { + get; + set; + } + + public CancellationToken CancellationToken { + get { return cancellationToken; } + } + + public virtual AstNode RootNode { + get { + return resolver.RootNode; + } + } + + public CSharpAstResolver Resolver { + get { + return resolver; + } + } + + public virtual CSharpParsedFile ParsedFile { + get { + return resolver.ParsedFile; + } + } + + public ICompilation Compilation { + get { return resolver.Compilation; } + } + + public BaseRefactoringContext (ICSharpCode.NRefactory.CSharp.Resolver.CSharpAstResolver resolver, System.Threading.CancellationToken cancellationToken) + { + this.resolver = resolver; + this.cancellationToken = cancellationToken; + } + + + #region Resolving + public ResolveResult Resolve (AstNode node) + { + return resolver.Resolve (node, cancellationToken); + } + + public CSharpResolver GetResolverStateBefore(AstNode node) + { + return resolver.GetResolverStateBefore (node, cancellationToken); + } + + public CSharpResolver GetResolverStateAfter(AstNode node) + { + return resolver.GetResolverStateAfter (node, cancellationToken); + } + + public IType ResolveType (AstType type) + { + return resolver.Resolve (type, cancellationToken).Type; + } + + public IType GetExpectedType (Expression expression) + { + return resolver.GetExpectedType(expression, cancellationToken); + } + + public Conversion GetConversion (Expression expression) + { + return resolver.GetConversion(expression, cancellationToken); + } + #endregion + + #region Code Analyzation + /// + /// Creates a new definite assignment analysis object with a given root statement. + /// + /// + /// The definite assignment analysis object. + /// + /// + /// The root statement. + /// + public DefiniteAssignmentAnalysis CreateDefiniteAssignmentAnalysis (Statement root) + { + return new DefiniteAssignmentAnalysis (root, resolver, CancellationToken); + } + #endregion + + /// + /// Translates the english input string to the context language. + /// + /// + /// The translated string. + /// + public virtual string TranslateString(string str) + { + return str; + } + + #region IServiceProvider implementation + readonly ServiceContainer services = new ServiceContainer(); + + /// + /// Gets a service container used to associate services with this context. + /// + public ServiceContainer Services { + get { return services; } + } + + /// + /// Retrieves a service from the refactoring context. + /// If the service is not found in the container. + /// + public object GetService(Type serviceType) + { + return services.GetService(serviceType); + } + #endregion + } + +} diff --git a/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeAction.cs b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeAction.cs new file mode 100644 index 0000000000..3bc59be60d --- /dev/null +++ b/src/Libraries/NewNRefactory/ICSharpCode.NRefactory.CSharp/Refactoring/CodeAction.cs @@ -0,0 +1,73 @@ +// +// CodeAction.cs +// +// Author: +// Mike Krüger +// +// Copyright (c) 2012 Xamarin Inc. (http://xamarin.com) +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +// THE SOFTWARE. +using System; + +namespace ICSharpCode.NRefactory.CSharp.Refactoring +{ + /// + /// A code action provides a code transformation with a description. + /// + public class CodeAction + { + /// + /// Gets the description. + /// + public string Description { + get; + private set; + } + + /// + /// Gets the code transformation. + /// + public Action