Skip to content

Commit 406a095

Browse files
committed
Add reference to AX.ST.Compiler.PluginAbstractions and update launch settings for ixd profile and add analizers to prevent nre
1 parent cac6309 commit 406a095

3 files changed

Lines changed: 16 additions & 10 deletions

File tree

src/AXSharp.compiler/src/ixd/AXSharp.ixd.csproj

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,10 @@
6969
<HintPath>..\..\..\apax\stc\bin\AX.Text.dll</HintPath>
7070
<Private>False</Private>
7171
</Reference>
72+
<Reference Include="AX.ST.Compiler.PluginAbstractions">
73+
<HintPath>..\..\..\apax\stc\bin\AX.ST.Compiler.PluginAbstractions.dll</HintPath>
74+
<Private>False</Private>
75+
</Reference>
7276
</ItemGroup>
7377

7478
<ItemGroup>

src/AXSharp.compiler/src/ixd/Program.cs

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,24 @@
11
// See https://aka.ms/new-console-template for more information
22
using AX.ST.Semantic;
3+
using AX.ST.Semantic.Analyzer;
34
using AX.ST.Syntax.Parser;
45
using AX.ST.Syntax.Tree;
56
using AX.Text;
67
using AX.Text.Diagnostics;
78
using AXSharp.Compiler;
89
using AXSharp.ixc_doc;
910
using AXSharp.ixc_doc.Interfaces;
11+
using AXSharp.ixc_doc.Schemas;
1012
using AXSharp.ixc_doc.Visitors;
11-
using System;
13+
using CliWrap;
1214
using CommandLine;
13-
using AXSharp.ixc_doc.Schemas;
15+
using NuGet.Packaging;
16+
using System;
17+
using System.Collections.Generic;
1418
using System.Reflection;
15-
using System.Text;
16-
using CliWrap;
17-
using System.Runtime.InteropServices;
1819
using System.Runtime.CompilerServices;
19-
using System.Collections.Generic;
20-
using NuGet.Packaging;
20+
using System.Runtime.InteropServices;
21+
using System.Text;
2122

2223
const string Logo =
2324
@"| \ /
@@ -75,9 +76,9 @@ void GenerateYamls(Options o)
7576
//Console.WriteLine($"Compiling project {axProject.ProjectInfo.Name}...");
7677
//var projectSources = axProject.Sources.Select(p => (parseTree: STParser.ParseTextAsync(p).Result, source: p));
7778

78-
var toCompile = projectSources.Select(p => p.parseTree);
79+
var toCompile = projectSources.Select(p => p.parseTree).ToList();
7980

80-
var compilation = Compilation.Create(toCompile, null, Compilation.Settings.Default).Result;
81+
var compilation = Compilation.Create(toCompile, new List<ISemanticAnalyzer>(), Compilation.Settings.Default).Result;
8182

8283
var semanticTree = compilation.Compilation.GetSemanticTree();
8384

src/AXSharp.compiler/src/ixd/Properties/launchSettings.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@
22
"profiles": {
33
"ixd": {
44
"commandName": "Project",
5-
"commandLineArgs": "ixd -x C:\\MTS\\ix\\axsharp\\src\\AXSharp.compiler\\src\\ixd\\tests\\samples\\ax\\ -o C:\\MTS\\ix\\axsharp\\src\\AXSharp.compiler\\src\\ixd\\tests\\docfx\\docfx_project\\api\\"
5+
"commandLineArgs": "ixd -x .\\src\\abstractions\\ctrl -o .\\docfx\\apictrl\\",
6+
"workingDirectory": "c:\\W\\Develop\\gh\\inxton\\simatic-ax\\axopen.templates\\axopen\\"
67
},
78
"ixd-2": {
89
"commandName": "Project",

0 commit comments

Comments
 (0)