Click here to Skip to main content
15,887,214 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Stack Overflow exeception Pin
Graham Breach25-Jan-22 7:47
Graham Breach25-Jan-22 7:47 
AnswerRe: Stack Overflow exeception Pin
Mircea Neacsu25-Jan-22 2:11
Mircea Neacsu25-Jan-22 2:11 
GeneralRe: Stack Overflow exeception Pin
ForNow25-Jan-22 2:20
ForNow25-Jan-22 2:20 
Questionfunction translated to ASM Pin
Calin Negru24-Jan-22 23:42
Calin Negru24-Jan-22 23:42 
AnswerRe: function translated to ASM Pin
CPallini25-Jan-22 0:10
mveCPallini25-Jan-22 0:10 
GeneralRe: function translated to ASM Pin
Calin Negru25-Jan-22 11:24
Calin Negru25-Jan-22 11:24 
GeneralRe: function translated to ASM Pin
CPallini25-Jan-22 20:00
mveCPallini25-Jan-22 20:00 
AnswerRe: function translated to ASM Pin
trønderen25-Jan-22 0:51
trønderen25-Jan-22 0:51 
As CPallini writes: Essentially correct.

But your description is so abstract that it applies as well to functions in any algorithmic language, from Fortran through Algol and Pascal and C and C#. It is certainly not ASM specific.

Actually, I'd say: Quite to the contrary ... If your title line hadn't said 'function translated to ASM'. If you hand code ASM, you have a lot more freedom. E.g. that 'sentence sequence' would not have to be that isolated: A function could have multiple entry points. (For an extreme case: Read Jumping into the middle of an instruction ...[^]).

Also, I think that parameter transfer and return of result value(s) is such an essential part of the function concept that it should be included in even the most basic definition/description of the function concept. But again, parameters are certainly not specific to ASM functions; it applies equally to ASM and high level languages.

Rant part:

I really wish that you were right about 'an isolated sentence sequence that gets an ID'. That is not the case neither in ASM nor in C style languages. The ID does not identify the sentence sequence, but the point in the code at the start of the sequence. This is one of the major fundamental flaws in the design of these languages.

In a few other algorithmic languages, such as CHILL, a label identifies a sentence sequence, that be a function, a loop, a conditional statement or whatever. Usually, a sentence sequence is termed a 'block'. You can e.g. break out of any block by stating its ID, even if it is not the innermost one. You can have compiler support for block completion by repeating the block ID at the end, improving readability a lot and catching nesting errors.

If there were a dotNET CHILL compiler out there, I'd gladly kick out C# (even if C# certainly is my favorite alternative in the C class of languages)!
GeneralRe: function translated to ASM Pin
Fly Gheorghe25-Jan-22 8:59
Fly Gheorghe25-Jan-22 8:59 
GeneralRe: function translated to ASM Pin
trønderen25-Jan-22 23:23
trønderen25-Jan-22 23:23 
GeneralRe: function translated to ASM Pin
Fly Gheorghe28-Jan-22 3:39
Fly Gheorghe28-Jan-22 3:39 
GeneralRe: function translated to ASM Pin
Richard Andrew x6430-Jan-22 4:48
professionalRichard Andrew x6430-Jan-22 4:48 
AnswerRe: function translated to ASM Pin
k505430-Jan-22 5:11
mvek505430-Jan-22 5:11 
GeneralRe: function translated to ASM Pin
Richard Andrew x6430-Jan-22 11:29
professionalRichard Andrew x6430-Jan-22 11:29 
GeneralRe: function translated to ASM Pin
Calin Negru31-Jan-22 6:49
Calin Negru31-Jan-22 6:49 
QuestionVS2019 - missing dialog editor? Pin
charlieg23-Jan-22 11:15
charlieg23-Jan-22 11:15 
SuggestionRe: VS2019 - missing dialog editor? Pin
Graham Breach23-Jan-22 21:30
Graham Breach23-Jan-22 21:30 
GeneralRe: VS2019 - missing dialog editor? Pin
charlieg24-Jan-22 2:31
charlieg24-Jan-22 2:31 
AnswerRe: VS2019 - missing dialog editor? Pin
Victor Nijegorodov23-Jan-22 21:33
Victor Nijegorodov23-Jan-22 21:33 
GeneralRe: VS2019 - missing dialog editor? Pin
charlieg24-Jan-22 2:32
charlieg24-Jan-22 2:32 
AnswerRe: VS2019 - missing dialog editor? Pin
charlieg25-Jan-22 7:34
charlieg25-Jan-22 7:34 
QuestionMessage Closed Pin
21-Jan-22 18:09
Member 1496877121-Jan-22 18:09 
AnswerRe: More about "system" call - sort of repost Pin
k505421-Jan-22 18:38
mvek505421-Jan-22 18:38 
GeneralMessage Closed Pin
22-Jan-22 4:40
Member 1496877122-Jan-22 4:40 
GeneralRe: More about "system" call - sort of repost Pin
k505422-Jan-22 5:19
mvek505422-Jan-22 5:19 

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.