Closed elfring closed 7 years ago
Hi Markus,
This is the standard convention used Windows-based kernel programming.
Best regards, Alex Ionescu
On Sun, Feb 26, 2017 at 11:26 AM, Markus Elfring notifications@github.com wrote:
I would like to point out that identifiers like “_SHV_VP_STATE https://github.com/ionescu007/SimpleVisor/blob/f5dd1af02f22e2caf564dea4705bce2d42167061/shv.h#L35” and “_KDESCRIPTOR https://github.com/ionescu007/SimpleVisor/blob/84c5f91b4c2c86438dfa703f514c5dbf05eddf03/vmx.h#L40” do not fit https://www.securecoding.cert.org/confluence/display/c/DCL37-C.+Do+not+declare+or+define+a+reserved+identifier to the expected naming convention of the C language standard. Would you like to adjust your selection for unique names?
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/ionescu007/SimpleVisor/issues/18, or mute the thread https://github.com/notifications/unsubscribe-auth/AFxIeL636_xkJSphfVbgfsg5PY85S0yQks5rgWFRgaJpZM4MMWZB .
How do you think about to avoid that this software depends on undefined behaviour?
Markus,
Almost all C-based software in the world (Linux with its t, which the page you linked on says is a violation, and Windows with its leading ) uses underscores in its type names. It does not make any sense to me to go around changing the codebase, and making it look alien to any other developer familiar with real software, to satisfy some bureaucratic requirement that has no real life impact.
Best regards, Alex Ionescu
On Sun, Feb 26, 2017 at 6:21 PM, Markus Elfring notifications@github.com wrote:
How do you think about to avoid that this software depends on undefined behaviour https://www.securecoding.cert.org/confluence/display/c/CC.+Undefined+Behavior#CC.UndefinedBehavior-ub_106 ?
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/ionescu007/SimpleVisor/issues/18#issuecomment-282575470, or mute the thread https://github.com/notifications/unsubscribe-auth/AFxIeIalHVz8mzklni1VeAm1Z2c2BVVPks5rgcKRgaJpZM4MMWZB .
I suggest to use a few underscores less in affected identifiers.
meseems elfring is a spambot.
I would like to point out that identifiers like “
_SHV_VP_STATE
” and “_KDESCRIPTOR
” do not fit to the expected naming convention of the C language standard. Would you like to adjust your selection for unique names?