Quantcast
Channel: The Old New Thing
Browsing all 24428 articles
Browse latest View live

Image may be NSFW.
Clik here to view.

re: GUIDs are designed to be unique, not random

@Simon Buchan: Since all generations are random, you can just get two random numbers once and found they are the same. The "number of generation to make it feasible" is irrelevent (or I should say,...

View Article


Image may be NSFW.
Clik here to view.

re: GUIDs are designed to be unique, not random

Oh, I've forgotten to add the condition of "16-bit strength" to my last comment.

View Article


Image may be NSFW.
Clik here to view.

re: Why is the Close button in the upper right corner?

> Fitts's law is the reason I always advise people with multiple monitors to put the rightmost monitor slightly lower than the left one (including in the monitor settings). This allows the user to...

View Article

Image may be NSFW.
Clik here to view.

re: Why is the Close button in the upper right corner?

@Jolyon Smith: I think this is more of an "edge case" because while you're operating within allowed parameters, you're outside *recommended* ones. To you, I recommend using the old-fashioned way to...

View Article

Image may be NSFW.
Clik here to view.

re: GUIDs are designed to be unique, not random

@Nick: This looks like the sort key of a given item would vary over time, which is a big no-no (IIRC, the CRT throws or asserts when it encounters that). Was that the point?

View Article


Image may be NSFW.
Clik here to view.

re: How do I prevent unchecked checkboxes in my listview control from...

cheong00: If you're cleaning up source code in order to ask for help and not verifying that your cleaned-up source code still exhibits the behavior you're asking for help about, UR DOIN IT RONG.

View Article

Image may be NSFW.
Clik here to view.

re: GUIDs are designed to be unique, not random

@Raymond, Can I suggest that you fix the error that I pointed out in your summary of the Wikipedia article? > "The Wikipedia article for GUID contains primary research which suggests that future and...

View Article

Image may be NSFW.
Clik here to view.

re: How do I prevent unchecked checkboxes in my listview control from...

People still use SysListView32 after Vista introduced that uber-annoying full row selection for LVS_LIST view style? No empty space to click! Use your own control people. ItemsView of Windows 7...

View Article


Image may be NSFW.
Clik here to view.

re: How do I prevent unchecked checkboxes in my listview control from...

"I'm having an issue with the LVS_EX_CHECKBOXES extended list view style. Here's all the styles I'm using on my list view: [list]." Seems like the way to do it to me. Although stripping it down to the...

View Article


Image may be NSFW.
Clik here to view.

re: GUIDs are designed to be unique, not random

@cheong00: "Since all generations are random, you can just get two random numbers once and found they are the same." Yes, with a 1 in $BIGNUM (excuse me, that's $BIGBIGBIGNUM) probability!  Who cares?

View Article

Image may be NSFW.
Clik here to view.

re: The extern "C" specifier disables C++ mangling, but that doesn't mean it...

Just to give the third method some love. There is a third method to export symbols, that is the linker's /export command line option. This can be put into a source file using the #pragma directive....

View Article

Image may be NSFW.
Clik here to view.

re: GUIDs are designed to be unique, not random

The original problem is about shuffling a jury pool, so there is no need for cryptography, passwords or any such thing. If using C/C++, rand() would work just fine. Just walk the list, exchanging each...

View Article

Image may be NSFW.
Clik here to view.

re: Why is the Close button in the upper right corner?

@Medinoc:  "To you, I recommend using the old-fashioned way to close a window: Double-clicking the system menu, which is still of infinite width and height (good luck if you're using Firefox, which no...

View Article


Image may be NSFW.
Clik here to view.

re: The extern "C" specifier disables C++ mangling, but that doesn't mean it...

Private calling conventions in assembly make things _interesting_ for the debugger.

View Article

Image may be NSFW.
Clik here to view.

re: The extern "C" specifier disables C++ mangling, but that doesn't mean it...

What is "C name mangling"?   I didn't know that C did anything to the names.

View Article


Image may be NSFW.
Clik here to view.

re: The extern "C" specifier disables C++ mangling, but that doesn't mean it...

@Aaron see: gustedt.wordpress.com/.../name-mangling-in-c

View Article

Image may be NSFW.
Clik here to view.

re: The extern "C" specifier disables C++ mangling, but that doesn't mean it...

@Aaron: Mostly the number of bytes of parameters in __stdcall and __fastcall, but there's slightly more to it. Search __fastcall on MSDN and you should find the info.

View Article


Image may be NSFW.
Clik here to view.

re: GUIDs are designed to be unique, not random

This gives me an idea for an interview question: using a rand() function with RAND_MAX = 32767, write a function which returns 1, 2, or 3 with equal probability.

View Article

Image may be NSFW.
Clik here to view.

re: The extern "C" specifier disables C++ mangling, but that doesn't mean it...

@Aaron: Read the post linked to in the "C mangling" link in the third blockquote.  Each different calling convention has a slightly different name decoration in C.

View Article

Image may be NSFW.
Clik here to view.

re: The extern "C" specifier disables C++ mangling, but that doesn't mean it...

Hmm.. IIRC WINAPI(_stdcall) are mangled, while all actuall Windows API dlls exports functions as non-mangled, so they all using DEF file ?

View Article
Browsing all 24428 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>