Corrected the mapping of Byte/SByte wrappers -> entry points. Swapped CLSCompliant attribute between Byte and SByte (Bytes are, SBytes are not).

This commit is contained in:
the_fiddler 2009-03-08 22:00:13 +00:00
parent fc0ca5631f
commit 04ebcff4fb
3 changed files with 456 additions and 446 deletions

View file

@ -731,7 +731,7 @@ namespace Bind.Structures
/// <param name="f">The Function to add.</param> /// <param name="f">The Function to add.</param>
public void AddChecked(Function f) public void AddChecked(Function f)
{ {
if (f.Name.Contains("Uniform1u")) if (f.Name.Contains("Color3ub"))
{ {
} }
@ -742,6 +742,16 @@ namespace Bind.Structures
{ {
Bind.Structures.Function.Wrappers.Add(f); Bind.Structures.Function.Wrappers.Add(f);
} }
else
{
Function existing = Bind.Structures.Function.Wrappers[f.Extension][index];
if ((existing.Parameters.HasUnsignedParameters && !unsignedFunctions.IsMatch(existing.Name) && unsignedFunctions.IsMatch(f.Name)) ||
(!existing.Parameters.HasUnsignedParameters && unsignedFunctions.IsMatch(existing.Name) && !unsignedFunctions.IsMatch(f.Name)))
{
Bind.Structures.Function.Wrappers[f.Extension].RemoveAt(index);
Bind.Structures.Function.Wrappers[f.Extension].Add(f);
}
}
} }
else else
{ {

View file

@ -155,7 +155,7 @@ namespace Bind.Structures
{ {
get get
{ {
bool compliant = !Unsigned; bool compliant = !(CurrentType.Contains("UInt") || CurrentType.Contains("SByte"));
if (Pointer) if (Pointer)
{ {
compliant &= CurrentType.Contains("IntPtr"); // IntPtr's are CLSCompliant. compliant &= CurrentType.Contains("IntPtr"); // IntPtr's are CLSCompliant.
@ -189,7 +189,7 @@ namespace Bind.Structures
{ {
get get
{ {
return (CurrentType.Contains("UInt") || CurrentType.Contains("SByte")); return (CurrentType.Contains("UInt") || CurrentType.Contains("Byte"));
} }
} }

File diff suppressed because it is too large Load diff