-
Notifications
You must be signed in to change notification settings - Fork 388
Add uintptr_t and intptr_t data types (#134) #145
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There is no real equivalent to size_t in .NET, so I hesitated to add it. The uintptr_t can be used and mapped to size_t if required, however.
Mmm, seems like there's a minor bug. Hold off on merging until I can fix it (it's not displaying hexadecimal correctly, it shows 0x{base10} instead of base16. Seems to be an issue with the IntPtr/UIntPtr types themselves, they don't format nicely to strings like other integer types do. |
Fixed, IntPtr has its own |
@@ -617,6 +619,12 @@ private void searchForEqualValuesToolStripMenuItem_Click(object sender, EventArg | |||
case UInt64Node node: | |||
comparer = new LongMemoryComparer(ScanCompareType.Equal, (long)node.ReadValueFromMemory(selectedNode.Memory), 0); | |||
break; | |||
case UIntPtrNode node: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's not correct? If you have a x86 process it should be an IntegerMemoryComparer
and not the 64bit LongMemoryComparer
.
@@ -6,16 +6,19 @@ namespace ReClassNET.Project | |||
public class CppTypeMapping | |||
{ | |||
public string TypeBool { get; set; } = "bool"; | |||
public string TypeSize { get; set; } = "size_t"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This type is never used.
Why did you close this PR? |
Since there is no real equivalent to
size_t
in .NET, I hesitated to add it.The uintptr_t can be used and mapped to size_t if required, however.
I'm not entirely sure if I got everything, as there seems to be a lot of code relating to data types all over the place, but it seems to work for me.
If anything needs to be changed to get this merged in, just let me know and I'll fix it.