Skip to content

Commit 01e031b

Browse files
committed
Registrable: cleanup
1 parent 84b5ebf commit 01e031b

File tree

3 files changed

+6
-5
lines changed

3 files changed

+6
-5
lines changed

src/Generator/Generators/Registrable/Lua/Sol/LuaSolGeneratorOptions.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ public class LuaSolGeneratorOptions : RegistrableGeneratorOptions
44
{
55
public LuaSolNamingStrategy NamingStrategy;
66

7-
public LuaSolGeneratorOptions(LuaSolGenerator generator) : base()
7+
public LuaSolGeneratorOptions(LuaSolGenerator generator) : base(generator)
88
{
99
NamingStrategy = new LuaSolNamingStrategy(generator);
1010
}

src/Generator/Generators/Registrable/RegistrableGeneratorOptions.cs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@ public abstract class RegistrableGeneratorOptions
1313
{
1414
public delegate string Delegate(string name);
1515

16-
protected Generator generator;
16+
protected Generator Generator;
17+
1718
public virtual string OutputSubDir { get; }
1819
public virtual string RootContextType { get; }
1920
public virtual string RootContextName { get; }
@@ -58,8 +59,9 @@ public abstract class RegistrableGeneratorOptions
5859
public virtual string DefaultStaticCastFunctionTemplateFullyQualifiedName => null;
5960
public virtual string DefaultDynamicCastFunctionTemplateFullyQualifiedName => null;
6061

61-
public RegistrableGeneratorOptions()
62+
public RegistrableGeneratorOptions(Generator generator)
6263
{
64+
Generator = generator;
6365
OutputSubDir = DefaultOutputSubdir;
6466
RootContextType = DefaultRootContextType;
6567
RootContextName = DefaultRootContextName;

src/Generator/Generators/Registrable/RegistrableNamingStrategy.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
using CppSharp.Generators.Registrable.Lua.Sol;
44
using System.Collections.Generic;
55
using System.Text;
6-
using System.Xml.Linq;
76

87
namespace CppSharp.Generators.Registrable
98
{
@@ -386,7 +385,7 @@ public virtual string GetBindingContext(Declaration declaration, RegistrableGene
386385
}
387386
}
388387

389-
public string GetCppContext(Declaration entity, RegistrableGeneratorContext context, FQNOption option)
388+
public virtual string GetCppContext(Declaration entity, RegistrableGeneratorContext context, FQNOption option)
390389
{
391390
if (context != null)
392391
{

0 commit comments

Comments
 (0)