Skip to content

Commit ce69e03

Browse files
authored
Misc. Updates (#319)
* Updated doc comments * Placed KLS visualizers into the proper namespace * CHanged visibility of many types to internal that are not intended for external use.
1 parent 116c4a4 commit ce69e03

File tree

8 files changed

+19
-14
lines changed

8 files changed

+19
-14
lines changed

src/Interop/Ubiquity.NET.Llvm.Interop/ArchitectureExtensions.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,9 @@ Architecture.Arm or
2222
Architecture.Wasm => LibLLVMCodeGenTarget.CodeGenTarget_WebAssembly,
2323
Architecture.LoongArch64 => LibLLVMCodeGenTarget.CodeGenTarget_LoongArch,
2424
Architecture.Ppc64le => LibLLVMCodeGenTarget.CodeGenTarget_PowerPC,
25+
2526
#if NET9_0_OR_GREATER
26-
Architecture.RiscV64 => LibLLVMCodeGenTarget.CodeGenTarget_RISCV, // 64 vs 32 bit distinction is a CPU/Feature of the target
27+
Architecture.RiscV64 => LibLLVMCodeGenTarget.CodeGenTarget_RISCV, // 64bit is the only form supported by .NET
2728
#endif
2829
Architecture.S390x => LibLLVMCodeGenTarget.CodeGenTarget_SystemZ,
2930
_ => throw new NotSupportedException( "Native code gen target is unknown" )

src/Samples/Kaleidoscope/Kaleidoscope.Grammar/DynamicRuntimeState.cs

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,14 @@ namespace Kaleidoscope.Grammar
2222
/// <para>
2323
/// This provides storage and support methods for the runtime global state.
2424
/// The state includes:
25-
/// * The language level to use for parsing
26-
/// * The current set of operators, including any user defined operators so the
25+
/// <list type="bullet">
26+
/// <item>The language level to use for parsing</item>
27+
/// <item>The current set of operators, including any user defined operators so the
2728
/// parser knows how to resolve complex expressions with user defined operators
28-
/// and precedence.
29-
/// * The current set of external declarations
30-
/// * The current set of defined functions
29+
/// and precedence.</item>
30+
/// <item>The current set of external declarations</item>
31+
/// <item>The current set of defined functions</item>
32+
/// </list>
3133
/// </para>
3234
/// </remarks>
3335
public class DynamicRuntimeState

src/Samples/Kaleidoscope/Kaleidoscope.Grammar/OperatorInfo.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
namespace Kaleidoscope.Grammar
88
{
9-
public enum OperatorKind
9+
internal enum OperatorKind
1010
{
1111
None,
1212
InfixLeftAssociative,

src/Samples/Kaleidoscope/Kaleidoscope.Grammar/Visualizers/AstGraphGenerator.cs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,15 @@
33

44
using System.Collections.Generic;
55

6+
using Kaleidoscope.Grammar.AST;
7+
68
using OpenSoftware.DgmlTools.Model;
79

810
using Ubiquity.NET.Runtime.Utils;
911

10-
namespace Kaleidoscope.Grammar.AST
12+
namespace Kaleidoscope.Grammar.Visualizers
1113
{
12-
public class AstGraphGenerator
14+
internal class AstGraphGenerator
1315
: KaleidoscopeAstVisitorBase<object>
1416
{
1517
public AstGraphGenerator( )

src/Samples/Kaleidoscope/Kaleidoscope.Grammar/Visualizers/BlockDiagGenerator.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
using OpenSoftware.DgmlTools.Model;
99

10-
namespace Kaleidoscope.Grammar
10+
namespace Kaleidoscope.Grammar.Visualizers
1111
{
1212
/// <summary>Extension class to generate a blockdiag file from a DGML <see cref="DirectedGraph"/></summary>
1313
/// <remarks>
@@ -22,7 +22,7 @@ namespace Kaleidoscope.Grammar
2222
/// </para>
2323
/// </remarks>
2424
/// <seealso href="http://blockdiag.com"/>
25-
public static class BlockDiagGenerator
25+
internal static class BlockDiagGenerator
2626
{
2727
public static void WriteAsBlockDiag( this DirectedGraph graph, TextWriter writer )
2828
{

src/Samples/Kaleidoscope/Kaleidoscope.Grammar/Visualizers/DgmlGenerator.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414

1515
using static Kaleidoscope.Grammar.ANTLR.KaleidoscopeParser;
1616

17-
namespace Kaleidoscope.Grammar
17+
namespace Kaleidoscope.Grammar.Visualizers
1818
{
1919
/// <summary>Parse tree listener to generate a DGML Graph of the parsed syntax</summary>
2020
/// <remarks>

src/Samples/Kaleidoscope/Kaleidoscope.Grammar/Visualizers/XDocumentListener.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
using Ubiquity.NET.ANTLR.Utils;
1313

14-
namespace Kaleidoscope.Grammar
14+
namespace Kaleidoscope.Grammar.Visualizers
1515
{
1616
/// <summary>Parse listener that, when used with <see cref="ParseTreeWalker"/> generates an XML representation of the parse tree</summary>
1717
internal class XDocumentListener

src/Ubiquity.NET.InteropHelpers/ExecutionEncodingStringMarshaller.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ public static unsafe class ExecutionEncodingStringMarshaller
3131
///
3232
/// <note type="note">Even as well documented and well thought out as LLVM is, it remains silent on this point.
3333
/// Spelunking the build system generated for LLVM itself by CMake there is NOTHING to set either the source or
34-
/// execution encodings for Windows, MSVC or any other tool-set that I can see so they seem to be left at defaults.
34+
/// execution encoding for Windows, MSVC or any other tool-set that I can see so they seem to be left at defaults.
3535
/// (LLVM is just an example as it was where this library began, but it is not limited to that.)
3636
/// </note>
3737
///

0 commit comments

Comments
 (0)