diff --git a/src/Compiler/src/Compiler/XSharpCodeAnalysis/Symbols/ParameterSymbolExtensions.cs b/src/Compiler/src/Compiler/XSharpCodeAnalysis/Symbols/ParameterSymbolExtensions.cs
index 567ec1dd69..de344fad28 100644
--- a/src/Compiler/src/Compiler/XSharpCodeAnalysis/Symbols/ParameterSymbolExtensions.cs
+++ b/src/Compiler/src/Compiler/XSharpCodeAnalysis/Symbols/ParameterSymbolExtensions.cs
@@ -97,8 +97,15 @@ public static BoundExpression GetVODefaultParameter(this ParameterSymbol param,
if (arg.Type.SpecialType == SpecialType.None)
{
// Enum type? can be casted to Int32
- constant = ConstantValue.Create(arg.Value, SpecialType.System_Int32);
- var netType = compilation.GetSpecialType(SpecialType.System_Int32);
+ var specialType = SpecialType.System_Int32;
+ if (param.Type.IsEnumType())
+ {
+ var enumUnderlyingType = ((NamedTypeSymbol)param.Type).GetEnumUnderlyingType();
+ specialType = enumUnderlyingType.SpecialType;
+
+ }
+ var netType = compilation.GetSpecialType(specialType);
+ constant = ConstantValue.Create(arg.Value, specialType);
return new BoundLiteral(syntax, constant, netType);
}
else
@@ -114,6 +121,11 @@ public static BoundExpression GetVODefaultParameter(this ParameterSymbol param,
{
specialType = arg.Type.SpecialType;
}
+ if (param.Type.IsEnumType())
+ {
+ var enumUnderlyingType = ((NamedTypeSymbol)param.Type).GetEnumUnderlyingType();
+ specialType = enumUnderlyingType.SpecialType;
+ }
if (specialType != valueType)
{
switch (specialType)
diff --git a/src/CompilerTests/Applications/C591/Prg/C591.prg b/src/CompilerTests/Applications/C591/Prg/C591.prg
index 28755777ab..169fc72b96 100644
--- a/src/CompilerTests/Applications/C591/Prg/C591.prg
+++ b/src/CompilerTests/Applications/C591/Prg/C591.prg
@@ -41,7 +41,9 @@ xAssert(TestNum(u)==123)
u := NULL_OBJECT
TestNum(u)
-xAssert(TestNum(u)==123)
+// With the vulcan runtime, following returned 123. With the X# runtime, it returns NULL_OBJECT, which is the correct (VO-compatible) behavior
+//xAssert(TestNum(u)==123)
+xAssert(TestNum(u)==NULL_OBJECT)
u := "asd"
TestNum(u)
diff --git a/src/Tools/VOXporter/Dll/XIDE.Base.dll b/src/Tools/VOXporter/Dll/XIDE.Base.dll
new file mode 100644
index 0000000000..302b9b7044
Binary files /dev/null and b/src/Tools/VOXporter/Dll/XIDE.Base.dll differ
diff --git a/src/Tools/VOXporter/VOXPorter.xsproj b/src/Tools/VOXporter/VOXPorter.xsproj
index 5b3e70b083..bfa41024f0 100644
--- a/src/Tools/VOXporter/VOXPorter.xsproj
+++ b/src/Tools/VOXporter/VOXPorter.xsproj
@@ -56,26 +56,12 @@
Dll\SDK_Defines.dll
-
- XICOMMON
- XICOMMON.dll
+
+ XIDE.Base
+ XIDE.Base.dll
False
True
- Dll\XICOMMON.dll
-
-
- XIDED
- XIDED.dll
- False
- True
- Dll\XIDED.dll
-
-
- XIRES
- XIRES.dll
- False
- True
- Dll\XIRES.dll
+ Dll\XIDE.Base.dll
diff --git a/src/Tools/VOXporter/VOXporter.viproj b/src/Tools/VOXporter/VOXporter.viproj
index 42f35e7e26..8fa87bddbb 100644
--- a/src/Tools/VOXporter/VOXporter.viproj
+++ b/src/Tools/VOXporter/VOXporter.viproj
@@ -56,7 +56,7 @@ GUID = FD056C5F-6DE1-465A-90E4-0145DEB734D2
IncludeInProjectBuild = 1
IncludeInProjectSearch = 1
IncludeInProjectExport = 1
-IncludePath = C:\xSharp\Dev\src\Common
+IncludePath =
StdDefsFile =
AppToRun =
SignAssembly = 0
@@ -98,28 +98,26 @@ File = %AppPath%\VOParser.prg
FileGUID = 81056C36-30B9-42B2-B0F6-E51A9FA52F14
FileType = Code
CopyToBin = 0
-File = C:\xSharp\Dev\src\Common\commonAssemblyInfo.prg
+File = %ProjectPath%\..\..\Common\commonAssemblyInfo.prg
FileGUID = 3C0D9DC5-C981-4D3A-9A17-0574F88B13E9
FileFileGroup = AA82ABD5-9D0C-4788-976C-3313B139325F
FileType = Code
CopyToBin = 0
-File = C:\xSharp\Dev\src\Common\constants.prg
+File = %ProjectPath%\..\..\Common\constants.prg
FileGUID = 15B49D79-BAD9-4F74-B42A-DA8B005DF917
FileFileGroup = AA82ABD5-9D0C-4788-976C-3313B139325F
FileType = Code
CopyToBin = 0
[VOXPorter References]
ReferenceGAC = CLR4,System,1,0,4.0.0.0
+ReferenceGAC = CLR4,System.Core,1,0,4.0.0.0
+ReferenceGAC = CLR4,System.Xml,1,0,4.0.0.0
ReferenceGAC = CLR4,System.Drawing,1,0,4.0.0.0
ReferenceGAC = CLR4,System.Windows.Forms,1,0,4.0.0.0
ReferenceProject = D5679723-DA91-4572-B699-5FDEC084BDB5,1,0,Fab_VO_Entities
ReferenceBrowse = %ProjectPath%\Dll\SDK_Defines.dll,1,1
-ReferenceBrowse = %ProjectPath%\Dll\XICOMMON.dll,1,1
-ReferenceBrowse = %ProjectPath%\Dll\XIRES.dll,1,1
-ReferenceBrowse = %ProjectPath%\Dll\XIDED.dll,1,1
-ReferenceGAC = CLR4,System.Core,1,0,4.0.0.0
-ReferenceGAC = CLR4,System.Xml,1,0,4.0.0.0
-ReferenceBrowse = C:\xSharp\Dev\Artifacts\Common\Debug\XSharp.VoEditors.dll,1,1
+ReferenceBrowse = %ProjectPath%\Dll\XIDE.Base.dll,1,1
+ReferenceBrowse = %ProjectPath%\..\..\..\Artifacts\Common\Debug\XSharp.VoEditors.dll,1,1
[VOXPorter Resources]
ResourceFile = Designers , %AppPath%\Resources\Designers.resources
ResourceFileGuid = 369B3304-1BF5-4D80-AA97-2B60C561DEDF
@@ -169,7 +167,7 @@ ModernSyntax=0
NamedArgs=0
InitLocals=0
AllowOldStyleAssignments=0
-AllowDotOption=1
+AllowDotOption=0
ResponseOnly=0
[VOXPorter Configurations]
AppConfig = Debug,11111111-1111-1111-1111-111111111111
@@ -227,7 +225,7 @@ GUID = D5679723-DA91-4572-B699-5FDEC084BDB5
IncludeInProjectBuild = 1
IncludeInProjectSearch = 1
IncludeInProjectExport = 1
-IncludePath = C:\xSharp\Dev\src\Common
+IncludePath =
StdDefsFile =
AppToRun =
SignAssembly = 0
@@ -349,7 +347,7 @@ ModernSyntax=0
NamedArgs=0
InitLocals=0
AllowOldStyleAssignments=0
-AllowDotOption=1
+AllowDotOption=0
ResponseOnly=0
[Fab_VO_Entities Configurations]
AppConfig = Debug,11111111-1111-1111-1111-111111111111
diff --git a/src/VisualStudio/XSharpVoEditors/Designers/VODBServerEditor.prg b/src/VisualStudio/XSharpVoEditors/Designers/VODBServerEditor.prg
index 3d4606afcb..8e43587799 100644
--- a/src/VisualStudio/XSharpVoEditors/Designers/VODBServerEditor.prg
+++ b/src/VisualStudio/XSharpVoEditors/Designers/VODBServerEditor.prg
@@ -2140,6 +2140,7 @@ CLASS DBEDesignDBServer INHERIT DesignItem
SELF:AddProperty(oProp)
SELF:AddProperty(VODesignProperty{"caption","Caption","",PropertyType.Text , PropertyStyles.NoAuto})
SELF:AddProperty(VODesignProperty{"description","Description","",PropertyType.Text , PropertyStyles.NoAuto})
+ SELF:AddProperty(VODesignProperty{"helpcontext","Help Context","",PropertyType.Text , PropertyStyles.NoAuto})
SELF:AddProperty(VODesignProperty{"classname" , "FieldSpec" , "" , PropertyType.Type , PropertyStyles.NoAuto + PropertyStyles.NoNULL})
SELF:AddProperty(VODesignProperty{"superclass" , "Inherit from" , "" , PropertyType.Text , PropertyStyles.NoAuto})
diff --git a/src/VisualStudio/XSharpVoEditors/Designers/VOEditorsShared.prg b/src/VisualStudio/XSharpVoEditors/Designers/VOEditorsShared.prg
index 448756af3b..c0982b2dc4 100644
--- a/src/VisualStudio/XSharpVoEditors/Designers/VOEditorsShared.prg
+++ b/src/VisualStudio/XSharpVoEditors/Designers/VOEditorsShared.prg
@@ -151,10 +151,10 @@ PARTIAL CLASS VODBServerEditor
cValue := __ReadNextVNDBString(aBytes , REF nPos , 128)
oField:cName := cValue
oField:aProperties:Add("fldname" , cValue)
- __ReadNextVNDBString(aBytes , REF nPos , 128)
- __ReadNextVNDBString(aBytes , REF nPos , 64)
- __ReadNextVNDBString(aBytes , REF nPos , 255)
- __ReadNextVNDBString(aBytes , REF nPos , 64)
+ __ReadNextVNDBString(aBytes , REF nPos , 128) // TODO: what is this for???
+ oField:aProperties:Add("caption" , __ReadNextVNDBString(aBytes , REF nPos , 64) )
+ oField:aProperties:Add("description" , __ReadNextVNDBString(aBytes , REF nPos , 255) )
+ oField:aProperties:Add("helpcontext" , __ReadNextVNDBString(aBytes , REF nPos , 64) )
oField:aProperties:Add("included" , __ReadNextVNDBByte(aBytes , REF nPos):ToString())
m := __ReadNextVNDBInt16(aBytes , REF nPos)
DO WHILE aSorted:ContainsKey(m)