Click here to Skip to main content
14,662,170 members
Home » Discussions » ATL / WTL / STL
   

ATL / WTL / STL

 
GeneralRe: Can a union in standard C "skip" members? Pin
arnold_w1-Feb-19 2:08
Memberarnold_w1-Feb-19 2:08 
GeneralRe: Can a union in standard C "skip" members? Pin
Richard MacCutchan1-Feb-19 2:57
mveRichard MacCutchan1-Feb-19 2:57 
GeneralMessage Closed Pin
16-Apr-20 20:04
Memberxiaofeifei6616-Apr-20 20:04 
QuestionWhich type of Regex best to learn for programming with C? Pin
HS_C_Student17-Dec-18 3:43
MemberHS_C_Student17-Dec-18 3:43 
AnswerRe: Which type of Regex best to learn for programming with C? Pin
Richard MacCutchan17-Dec-18 3:53
mveRichard MacCutchan17-Dec-18 3:53 
GeneralRe: Which type of Regex best to learn for programming with C? Pin
HS_C_Student17-Dec-18 5:57
MemberHS_C_Student17-Dec-18 5:57 
GeneralRe: Which type of Regex best to learn for programming with C? Pin
Richard MacCutchan17-Dec-18 6:48
mveRichard MacCutchan17-Dec-18 6:48 
AnswerRe: Which type of Regex best to learn for programming with C? Pin
John R. Shaw9-Jan-20 20:50
MemberJohn R. Shaw9-Jan-20 20:50 
PCRE is a good option. It is based on the Perl regexe, although there are some minor differences under the hood (which I do not remember now). I wrote my own C++ template regex some years ago that gives me full control of behavior in my personal projects. I used other libraries like PCRE, for comparison, in my test bed, to test for speed and accuracy. That is why I know that there are some minor differences on what one considers valid and invalid syntax (implementation differences or programmers mind set - who knows?).

As for Cs ability to process strings or any other data type - it is very efficient. I used to be able to look a C-code and translate it, in my head, directly to the equivalent assembly code. What you are talking about is the standard C libraries, which were designed to provide only the simple low level functionality that programmers require to develop more complex algorithms (how many ways are there to write a 'strcmp' function?). It was left to others to provide libraries that required more than a simple 'for' or while 'loop' in their functions.

That being said, when I find my self doing contract work on old C-code, where I am not allowed to upgrade or use external libraries, I recreate some simple algorithms for parsing (hey its their money, so who am I to argue with a brick wall). Basically, I create equivalent functions for parsing sub-strings like the regex "\d*" or "[abd]" and wrap them in a function call - depending on what I am looking for. What little testing I have done has actually shown me that they were more efficient than using the MS implementation of regex (not a surprise).

Conclusion: C is the most efficient language I have ever work with - there is a reason that all of the modern operating systems, I have worked with, were written in C. (I have not checked lately, so it is possible that C++ snuck in their some were).
INTP
"Program testing can be used to show the presence of bugs, but never to show their absence." - Edsger Dijkstra
"I have never been lost, but I will admit to being confused for several weeks. " - Daniel Boone

QuestionDirectory manipulation in C++ Pin
tasumisra16-Oct-18 4:26
Membertasumisra16-Oct-18 4:26 
AnswerRe: Directory manipulation in C++ Pin
Richard MacCutchan16-Oct-18 4:34
mveRichard MacCutchan16-Oct-18 4:34 
QuestionMicrosoft Office Object Library Pin
JM225114-Oct-18 5:31
MemberJM225114-Oct-18 5:31 
QuestionUnable to find atlapp.h file in Visual Studio 2017 Pin
Krishna Rao Yekkali29-Aug-18 0:17
MemberKrishna Rao Yekkali29-Aug-18 0:17 
AnswerRe: Unable to find atlapp.h file in Visual Studio 2017 Pin
Jochen Arndt29-Aug-18 0:38
professionalJochen Arndt29-Aug-18 0:38 
GeneralRe: Unable to find atlapp.h file in Visual Studio 2017 Pin
Krishna Rao Yekkali29-Aug-18 19:41
MemberKrishna Rao Yekkali29-Aug-18 19:41 
QuestionCEditCtrl in FrameWnd Pin
john56321-Aug-18 22:24
Memberjohn56321-Aug-18 22:24 
AnswerRe: CEditCtrl in FrameWnd Pin
Jochen Arndt1-Aug-18 23:33
professionalJochen Arndt1-Aug-18 23:33 
QuestionMFC VC2015 How to build from command line both settings: Use Shared DLL and Use Static DLL Pin
Member 1024558715-Jul-18 1:37
professionalMember 1024558715-Jul-18 1:37 
AnswerRe: MFC VC2015 How to build from command line both settings: Use Shared DLL and Use Static DLL Pin
Jochen Arndt15-Jul-18 22:24
professionalJochen Arndt15-Jul-18 22:24 
GeneralRe: MFC VC2015 How to build from command line both settings: Use Shared DLL and Use Static DLL Pin
Member 1024558716-Jul-18 0:12
professionalMember 1024558716-Jul-18 0:12 
QuestionHow to use CUDA programming to calculate and process the correct number Pin
Member 1378925119-Apr-18 21:35
MemberMember 1378925119-Apr-18 21:35 
AnswerRe: How to use CUDA programming to calculate and process the correct number Pin
Richard MacCutchan19-Apr-18 21:54
mveRichard MacCutchan19-Apr-18 21:54 
Rant[REPOST] How to use CUDA programming to calculate and process the correct number Pin
Richard Deeming20-Apr-18 1:10
mveRichard Deeming20-Apr-18 1:10 
QuestionHide context menu on CScrollBar in MFC. Pin
Sampath57918-Apr-18 3:07
MemberSampath57918-Apr-18 3:07 
AnswerRe: Hide context menu on CScrollBar in MFC. Pin
Victor Nijegorodov18-Apr-18 10:10
MemberVictor Nijegorodov18-Apr-18 10:10 
GeneralRe: Hide context menu on CScrollBar in MFC. Pin
Sampath57919-Apr-18 2:10
MemberSampath57919-Apr-18 2:10 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.