QB / QB64 Discussion Forum      Other Subforums, Links and Downloads      Archived Pascal Resources    Search
Respond to this messageReturn to Index
Original Message
  • ah, that fake masm crap ;-)
    • (no login)
      Posted Jul 20, 2004 8:18 PM

      oh well. I do hope you intend to learn the assembly coding that masm is hiding from you at some point.

      really, the only problem I can see is that you'r not setting eax to some value if the comparision is false. Also, while shouldn't cause a problem, i believe it would be more appropriate to have your args be BYTE PTR or something instead of DWORD. (I've worked very little with masm macros)

      How do you know something is wrong with the code? Crashes when you call it or what? Perhaps your calling convention is incorrect for whatever language you're calling this code from. If you're calling from C, you need to specify that it is a stdcall in the function declaration:

      int __stdcall CompareString(const char *str1, const char *str2);

      PROC C or PROC CDECL would be C-style calling convention, I believe.

        -/\lipha
    Your Name
    Your Email
    (Optional)
    Message Title
    Message Text
    Options Also send responses to my email address