- std::thread...too little, too late? - 12 Updates
- The effectiveness of C++14 - 1 Update
- THE SUPERIORITY OF THE MOTHER IN ISLAM - 1 Update
- pre- and post-conditions - 2 Updates
- Deriving an iterator - 2 Updates
- why not use naked delete ? - 2 Updates
- Islam prohibited women to be Unveiled....why? - 1 Update
- What is the correct template type? - 1 Update
- www.equestionanswers.com - C,C++, VC++,MFC,COM,DCOM, DLL question and answers for interviews and self-study - 1 Update
- pre- and post-conditions - 1 Update
Mr Flibble <flibble@i42.co.uk>: Dec 25 09:53PM On 25/12/2014 19:57, Öö Tiib wrote: > using lazy copying on process data (CoW of virtual memory pages). > It is still more expensive than spawning a thread but nothing to > lament about. Most forked child processes will use most of their memory as the parent process usually doesn't do much and the child process typically calls exec rendering your point invalid. My assertion remains intact: processes do not scale well, threads do. /Flibble |
woodbrian77@gmail.com: Jan 01 11:16AM -0800 On Thursday, December 25, 2014 1:58:06 PM UTC-6, Öö Tiib wrote: > form of freeing a portion of unneeded resources. You got to use > some custom 'allocator' with lot of discipline (I haven't met) > to achieve anything competitive with a thread. Thanks for mentioning std::quick_exit. I'm trying to use it and have a problem/complaint. I think you're supposed to include cstdlib to pick up quick_exit. I'm already using strtol in another part of the program and have included stdlib.h for that. There was a discussion previously in this newsgroup about whether to use the headers that start with c like cstdlib or to use stdlib.h. It seemed better to use the old form to me, but in this case, the old form doesn't have anything about quick_exit. I tend to think there should be a different header for quick_exit than cstdlib. Anyway, I could just include cstdlib or could include both: #include <cstdlib> // quick_exit #include <stdlib.h> // strtol Not sure which is better. Brian Ebenezer Enterprises - So far G-d has helped us. http://webEbenezer.net |
Mr Flibble <flibble@i42.co.uk>: Jan 01 07:38PM > previously in this newsgroup about whether to use the > headers that start with c like cstdlib or to use stdlib.h. > It seemed better to use the old form to me, but in this Well it is not better to use the old form. /Flibble |
woodbrian77@gmail.com: Jan 01 11:47AM -0800 On Thursday, January 1, 2015 1:39:41 PM UTC-6, Mr Flibble wrote: > > It seemed better to use the old form to me, but in this > Well it is not better to use the old form. > /Flibble I think it was Alf that thought it was, but I don't have a link to that thread and it would probably take me a while to find it. To make matters worse I get an error on Windows: error C2039: 'quick_exit' : is not a member of 'std' I wonder if Microsoft has done something reasonable and put the prototype in a different header. Brian Ebenezer Enterprises http://webEbenezer.net |
Ian Collins <ian-news@hotmail.com>: Jan 02 10:01AM +1300 > to include cstdlib to pick up quick_exit. I'm already > using strtol in another part of the program and have > included stdlib.h for that. It depends on whether quick_exit has made its way into your system's libC (or whatever it uses) and headers. Considering it was only added in C11, there's a good chance it hasn't. If it has, you should be able to use either header. I see the gcc <cstdlib> header includes this: # ifdef _GLIBCXX_HAVE_QUICK_EXIT extern "C" void quick_exit(int) throw() _GLIBCXX_NORETURN; # endif -- Ian Collins |
Jorgen Grahn <grahn+nntp@snipabacken.se>: Jan 01 09:37PM On Thu, 2014-12-25, Mr Flibble wrote: > On 25/12/2014 19:57, 嘱 Tiib wrote: ... > process usually doesn't do much and the child process typically calls > exec rendering your point invalid. My assertion remains intact: > processes do not scale well, threads do. I don't particularly want to be involved here, but that argument seems flawed: forked processes which replace threads probably won't do an exec. If most forked processes do an exec, perhaps that's due to the popular perception that multiprocessing is much more costly than multithreading -- not the /cause/ of that perception? /Jorgen -- // Jorgen Grahn <grahn@ Oo o. . . \X/ snipabacken.se> O o . |
woodbrian77@gmail.com: Jan 01 01:53PM -0800 On Thursday, January 1, 2015 3:01:39 PM UTC-6, Ian Collins wrote: > It depends on whether quick_exit has made its way into your system's > libC (or whatever it uses) and headers. Considering it was only added > in C11, there's a good chance it hasn't. I can understand how quick_exit is helpful in a C++ program, but am not sure how it would be useful in a C program. Some of my earlier comments assumed it was a C++ only thing. why is quick_exit helpful for C programs? Brian Ebenezer Enterprises http://webEbenezer.net |
Ian Collins <ian-news@hotmail.com>: Jan 02 11:04AM +1300 Jorgen Grahn wrote: > I don't particularly want to be involved here, but that argument seems > flawed: forked processes which replace threads probably won't do an > exec. That (not doing a exec) is true for most applications I'm aware of that spawn multiple processes. Most servers that use multiple processes simply clone an instance of themselves to do work. The parent handles incoming requests and manages its children. -- Ian Collins |
Ian Collins <ian-news@hotmail.com>: Jan 02 11:17AM +1300 > but am not sure how it would be useful in a C program. > Some of my earlier comments assumed it was a C++ only thing. > why is quick_exit helpful for C programs? The only difference I'm aware of between quick_exit use in C and C++ is static destructors. All of the other differences between exit, quick_exit() and _Exit apply. There is a big difference between the actions performed by calling exit and calling _Exit. quick_exit fills the gap by providing a means to perform limited cleanup. -- Ian Collins |
Jorgen Grahn <grahn+nntp@snipabacken.se>: Jan 01 10:58PM On Thu, 2015-01-01, Ian Collins wrote: > spawn multiple processes. Most servers that use multiple processes > simply clone an instance of themselves to do work. The parent handles > incoming requests and manages its children. Well, I'm not going to disagree with you (and it's not important to my argument). But at least on Unix it's pretty common to do something like a popen(2) to feed your data through an existing program, so it's not like doing an exec is unheard of, either. /Jorgen -- // Jorgen Grahn <grahn@ Oo o. . . \X/ snipabacken.se> O o . |
Ian Collins <ian-news@hotmail.com>: Jan 02 12:04PM +1300 Jorgen Grahn wrote: >> incoming requests and manages its children. > Well, I'm not going to disagree with you (and it's not important to my > argument). I'm not really sure how you could disagree with me agreeing with you! > But at least on Unix it's pretty common to do something > like a popen(2) to feed your data through an existing program, so it's > not like doing an exec is unheard of, either. True, but those typically aren't applications that would use threads. -- Ian Collins |
Jorgen Grahn <grahn+nntp@snipabacken.se>: Jan 01 11:14PM On Thu, 2015-01-01, Ian Collins wrote: > Jorgen Grahn wrote: >> On Thu, 2015-01-01, Ian Collins wrote: >>> Jorgen Grahn wrote: ... >> Well, I'm not going to disagree with you (and it's not important to my >> argument). > I'm not really sure how you could disagree with me agreeing with you! You made a broader statement than I did: you could have agreed with me and at the same time said something I disagreed with. (I probably shouldn't have commented on that, but I figured people here are used to everyone disagreeing with everyone, so I thought I'd better clarify that I wasn't ...) /Jorgen -- // Jorgen Grahn <grahn@ Oo o. . . \X/ snipabacken.se> O o . |
Melzzzzz <mel@zzzzz.com>: Jan 01 11:09PM +0100 On 1 Jan 2015 21:18:43 GMT > is »C++14«, according to the ISO. > When the norm is »ratified« or »adopted«, but not yet published, > I assume that it is not yet in effect. So, »C++« still is »C++11«? C++ is still C++98... By the time C++98 compilers go out of usage I will be retired... |
bv4bv4bv4@gmail.com: Jan 01 01:42PM -0800 THE SUPERIORITY OF THE MOTHER IN ISLAM #1- From Abu Hurairah -radiallaahu anhu- who said: A man came to the Messenger of Allah -sallallaahu alayhi wa sallam- and said: 'O Messenger of Allah who from the people is the most deserving of my good companionship? The Messenger -sallallaahu alayhi wa sallam- replied: 'Your mother.' The man said: 'then who?' The Messenger -sallallaahu alayhi wa sallam- replied: 'Your mother.' The man said: 'then who?' The Messenger -sallallaahu alayhi wa sallam- replied: 'Your mother.' The man said: 'then who?' The Messenger -sallallaahu alayhi wa sallam- said: 'Your father.' [In another narration: '. . . . . the next closest relative then those closest after them.'] [Collected in 'Adab al-Mufrad' no.3, Tirmidhi and 'Irwaa al-Ghaleel' 829/2232, declared Hasan by Albaani.] In another narration: 'A man came to the Prophet of Allah -sallallaahu alayhi wa sallam- and said: 'What do you order me with?' The Messenger -sallallaahu alayhi wa sallam- said: 'Be good to your mother.' [Collected by 'Adab al-Mufrad' no. 6] [Collected by Bukhari in 'Kitaab al-Adab' in the second chapter: 'Who from the people is the most deserving of my good companionship?' and also collected by Muslim in 'Kitaab al-Birr wa Silat wal Adab'] Imam Nawawi said in his explanation of this hadeeth: 'The Scholars have said: the reason for the superiority of the mother is due to her becoming tired on your account, her compassion, her serving you, suffering hardship while being pregnant with you, then giving birth to you, then suckling you, then bringing you up, serving you, nursing you and other things.' [Taken from the 'Sharh Saheeh Muslim' 16/80] Ibn Hajr quotes Ibn Battaal in the explanation of this hadeeth: Ibn Battaal said: 'Malik was asked: my father requests me to do something but my mother prevents me from it.' Imam Malik answered: 'Obey your father and do not disobey your mother.' ['Fath ul Bari'10/402] #2- 'Asma bint Abu Bakr said: 'My mother came to me and she is a Mushrikah (Non-Muslim) at the time of the Messenger of Allah -sallallaahu alayhi wa sallam-, so I asked the Messenger of Allah -sallallaahu alayhi wa sallam- about this and I said to him: 'My mother has come to me, and she is asking for me to be good to her, should I keep good relations with my mother? The Messenger of Allah -sallallaahu alayhi wa sallam- said: 'Keep good relations with her.' [Collected by Bukhari, Muslim and in the wording mentioned by Abu Dawud: 'Asma -radiallaahu anha- said: '... and she hates Islam.' 'Saheeh Targhib wa Tarhib' p.657 no. 2500] Ibn Uayainah said: Allah -Azza wa Jall- revealed: << Allah does not forbid you from dealing justly and kindly with those who did not fight against you on account of religion >> [al-Mumtahina: 8] regarding her. [Collected by Bukhari in 'Adab al-Mufrad' no. 25, declared Saheeh by Albaani in 'Saheeh Abu Dawud' (1468)] #3- It is narrated from Talha bin Muaaweeyah as-Sulamee -radiallaahu anhu- who said: I came to the Prophet -sallallaahu alayhi wa sallam- and said: 'O Messenger of Allah! Indeed I want to participate in Jihad in the path of Allah.' The Prophet -sallallaahu alayhi wa sallam- said: 'Is your mother alive?' I said: 'Yes.' The Prophet -sallallaahu alayhi wa sallam- said: 'Stay at her feet, for there is Paradise.' [Collected by Tabraani and Albaani declared it Saeeih li Ghayreehi in 'Saheeh Targhib wa Tarhib' 2/2484 p.649] In a similar narration from Muaaweeyah bin Jaahimah where the Prophet -sallallaahu alayhi wa sallam- said: 'Stick to your mother, since indeed Paradise is at her feet.' [Collected by Ibn Majah, Nisa'i and Albaani declared it Hasan Saheeh in 'Saheeh Targhib wa Tarhib' 2/2485] In a similar hadeeth the Prophet -sallallaahu alayhi wa sallam- asked: 'Do you have parents?' I said: 'Yes.' The Prophet -sallallaahu alayhi wa sallam- said: 'Stick to them, since indeed Paradise is under their feet.' [Collected by Tabrani and Albaani declared it Hasan Saheeh in 'Saheeh Targhib wa Tarhib' no. 2485] #4 - From Ibn Umar -radiallaahu anhu- who said: 'A man came to the Prophet -sallallaahu alayhi wa sallam- and said: 'Indeed I have committed a major sin, is there any repentance for me?' The Prophet -sallallaahu alayhi wa sallam- said: 'Do you have a mother?' He answered: 'No.' The Prophet -sallallaahu alayhi wa sallam- said: 'Do you have an aunt (mother's sister)?' He answered: 'Yes.' The Prophet -sallallaahu alayhi wa sallam- said: 'Then be good to her.' [Collected by Tirmidhi, and declared Saheeh by Albaani and in the wording collected by Ibn Hibban and Hakim: 'Do you have parents?' 'Saheeh Targhib wa Tarhib' p.658 no. 2504] #5- From al-Mughirah bin Shaybah -radiallaahu anhu- from the Prophet -sallallaahu alayhi wa sallam- who said: 'Indeed Allah has prohibited you from being disobedient to your mothers, and burying your daughters alive, to withhold from what Allah has allowed, claiming something which you do not have the right to claim. And Allah dislikes gossiping and excessive questioning, and wasting wealth.' [Collected by Bukhari] #6- From al-Miqdam bin Ma'adi Karb al-Kindi on the authority of the Prophet -sallallaahu alayhi wa sallam- who said: 'Indeed Allah orders you to fulfill the rights of your mothers, then to fulfill the rights of close relatives then those who are after them.' [Collected in 'Silsilah Sahihah' No.1666] From the Athaar of the Salaf #7- From Sa'id bin Abu Burdah from his father who said: Ibn Umar -radiallaahu anhu- said: he was making Tawaaf and he saw a man making Tawaaf while carrying his mother saying: Indeed I am like her submissive camel Even if her ride becomes startled I will not become startled and run away I carry her since she carried me more, do you think that I have paid her back O Ibn Umar? He said: No, not even one breath while giving birth. [Taken from 'Akhbar as-Salaf' p.268, 'Mukarim al-Akhlaaq' p.225, and 'Adab al-Mufrad' No.11and authenticated by Albaani] #8- From Abu Hazim: that Abu Huraira -radiallaahu anhu- did not perform Hajj until his mother died. [Collected in 'Mukarim al-Akhlaaq' p.80, taken from 'Akhbar as-Salaf' p.268] #9- From Muhammad who said: 'There was a date palm which bore one thousand dates, so Usamah bin Zayd -radiallaahu anhu- went to these dates and cut them off the tree due to their beauty. He was asked about it, so he said: Indeed my mother mentioned to me that she would love to have them, and there is nothing from the Dunya that my mother wants and I have the capability of getting except that I will get it for her.' [Collected in 'Mukarim al-Akhlaaq' p.225, taken from 'Akhbar as-Salaf' p. 268] #10- From Ibn Abbas -radiallaahu anhu- that a man came to him and said: 'I proposed to a woman but she refused to marry me, someone else proposed to her and she liked him and married him. I became jealous over her and I killed her, can I repent from this?' Ibn 'Abbas asked: 'Is your mother alive?' He answered: 'No.' Then Ibn Abbas said: 'Repent to Allah -Azza wa Jal- and come close to Him as much as you can.' The narrator said: I went and asked Ibn 'Abbas -radiallaahu anhu-: 'Why did you ask him whether his mother was alive?' Ibn Abbas -radiallaahu anhu- answered: 'Indeed I do not know of an action closer to Allah -Azza wa Jal- than being good to one's mother.' [Collected by Bukhari in 'Adab al-Mufrad' no.4, declared Saheeh by Albaani in 'Silsilah as-Sahihah' 2799] #11- From Abu Hazim that Abu Murrah, the freed slave of Umm Hani the daughter of Abu Taalib informed him that he rode with Abu Hurairah to al-Aqeeq where his land was. When he entered his land he yelled at the top of his voice: 'O my mother Assalamu alaykum wa Rahmatullaahi wa Baraktuhu' She replied: 'Wa alayka assalam wa Rahmatullaahi wa Baraktuhu' He said: 'May Allah have mercy upon you as you brought me up when I was small.' She said: 'O my son, and likewise to you, may Allah reward you with goodness and may He be pleased with you, as you look after me while I am old.' [Collected by Bukhari in 'Adab al-Mufrad' No.14, and Albaani declared it to have a Hasan Isnad] #12- From 'Atta that a person's mother took an oath from him that he should not pray except the obligatory prayer and not to fast except Ramadan, 'Atta said: 'Obey her!' [Collected in 'al-Birr' by Ibn al-Jawzi p.67, taken from 'Akhbar as-Salaf' p.269] #13- From Humaid who said: When Umm Eyaas bin Muaaweeyah died, Eyaas cried, it was said: 'What makes you cry?' He said: 'I used to have two doors open towards Paradise and one of them has been closed.' [Collected in 'al-Birr' by Ibn al-Jawzi p.68, taken from 'Akhbar as-Salaf' p.269] #14- Muhammad bin al-Munkadir said: 'I spent the night massaging my mother's leg and Umar spent the night praying. His night would not make me happier than my night.' [Collected in 'al-Hileeyah' 3/150, taken from 'Akhbar as-Salaf' p.269] #15- From Jafar bin Sulayman who said: Muhammad bin al-Munkadir used to place his cheek on the floor, and then say to his mother: 'place your foot upon it!' [Collected in 'Mukarim al-Akhlaaq' p.226, taken from 'Akhbar as-Salaf' p.270] #16- From Ibn 'Awn who said: 'Muhammad bin Sireen used to when he was with his mother lower his voice and speak slowly.' [Collected in 'Mukarim al-Akhlaaq' p.226, taken from 'Akhbar as-Salaf' p.270] #17- From al-Hasan that a man said to him: 'Indeed I made Hajj and indeed my mother has given me permission to perform another Hajj.' So al-Hasan said: 'To sit with her at her table is more beloved to me than your Hajj [i.e. optional Hajj].' [Collected in 'Mukarim al-Akhlaaq' p.227, taken from 'Akhbar as-Salaf' p.270] #18- From Hisham who said: Hafsah bint Sireen used to ask for Allah's mercy upon her son Huthayal and say: He would go and get reed and stalks to make a fire, he would peel them and gather them in the summer time, so when it was lit it would not produce smoke. When it came to winter time he would come and sit behind me while I prayed and he would light a small fire so that I could feel the warmth from it and so that the smoke from it would not bother me. I used to say to him, O my son it is night time go to your wife, and he would say: 'O mother I know what you want.' She continued: 'If I did not continue saying it to him perhaps he would be there till the morning time!' [Collected in 'al-Birr' by Ibn al-Jawzi p.53, taken from 'Akhbar as-Salaf' p.270] #19- From 'Ali bin al-Hussain that it was said to him that you are from the best amongst the people but I do not see you eating with your mother? He answered: 'I fear that, if I eat with her, my hand might precede her eye upon some food, so I would have been disrespectful to her!!' [Collected in 'al-Birr wa Silaah' p.82, taken from 'Akhbar as-Salaf' p.270] #20- From Mansoor who said: 'It has been said that the mother receives three quarters of al-Birr [being good to her].' [Collected in 'al-Hileeyah' 5/42, taken from 'Akhbar as-Salaf' p.271] #21- From Abu Bakr bin 'Aeeyash who said: 'I was sitting with Mansoor in his house, and his mother came and she was harsh and said: 'O Mansoor, Ibn Hubayrah wants you to be a judge and you refused!?' Mansoor did not raise his eyes up to look at her and his beard would touch his chest due to lowering his head.' [Collected in 'al-Birr' by Ibn al-Jawzi p.53, taken from 'Akhbar as-Salaf' p.271] #22- From al-Hasan bin Nuh who said: 'Khamas used to work using plaster every day for two small coins, and when the evening would approach he would buy a piece of fruit with that and bring it to his mother!' [Collected in 'al-Hileeyah' 6/212, taken from 'Akhbar as-Salaf' p.271] #23- From Mughira who said: 'Talq bin Habeeb used to help his mother with her work.' [Collected in ash-Shuyb/7543, taken from 'Akhbar as-Salaf' p.271] #24- From Hafsa bint Sireen who said: 'Umm Muhammad bin Sireen was a woman from the Hijjaz, and she loved dyed clothing. When Muhammad would buy her clothing he would buy her the softest material that could be found, and if it was close to Eid he would have her clothing dyed.' [Collected in 'Tabaqaat' by Ibn Sa'd 7/228 taken from 'Akhbar as-Salaf' p.271] #25- 'Amr bin Ubayr used to visit Khamas, he would greet him with Salaams and sit with him and his companions. So his mother said to him: 'Indeed I see this person and his companions and I dislike them, and I am not impressed by them so do not sit with them.' 'Amr and his companions came to him and he came close to them, and said: Indeed my mother dislikes you and your companions so do not visit me.' [Collected in 'al-Hileeyah' 6/212, taken from 'Akhbar as-Salaf' p.272] |
ram@zedat.fu-berlin.de (Stefan Ram): Dec 23 05:40PM >>return (j>>1)+(k>>1); >That's quite good, but possibly it does not always >give the expected result: Or, even simpler: #include <stdio.h> long long average( long long const j, long long const k ) { return (j>>1)+(k>>1); } int main( void ){ printf( "%lld\n", average( 3, 3 )); } prints: 2 |
ram@zedat.fu-berlin.de (Stefan Ram): Jan 01 09:18PM In 2014, C++14 was »ratified« or »adopted«. But it seems not to have been published by the ISO yet. So, is it in effect or not? Many ISO norms contain wordings like »This specification cancels and replaces ...«. So, when C++14 is in effect, it cancels and replaces C++11, and the meaning of the unqualified name »C++« is »C++14«, according to the ISO. When the norm is »ratified« or »adopted«, but not yet published, I assume that it is not yet in effect. So, »C++« still is »C++11«? |
Paavo Helde <myfirstname@osa.pri.ee>: Dec 28 04:36AM -0600 Nobody <nobody@nowhere.invalid> wrote in >> it hard to maintain its class invariants). > Another issue is that STL classes typically don't have virtual > destructors. This is only a (potential) issue if you allocate them dynamically, but this would not make much sense anyway. The STL containers perform any needed dynamic allocations in inside, so there is no need to allocate the container objects themselves dynamically. If I want to transfer them somehow from one memory location to another there are swap() and C++11 move operations. OK, maybe you have a point in that the people feeling an urge to derive from std::vector might feel a similar urge to allocate it dynamically (and delete unsafely) ;-) Cheers Paavo |
Paavo Helde <myfirstname@osa.pri.ee>: Dec 28 04:21AM -0600 jononanon@googlemail.com wrote in > Please give me some examples using your type pvector above. > Do some push_back and initializer list... The unique_ptr constructor is explicit, so one needs to spell it out when creating these objects. This works for me: #include <vector> #include <memory> typedef std::unique_ptr<int> pint; typedef std::vector<pint> pvector; int main() { pvector vec3; vec3.push_back(pint(new int{ 3 })); } The initializer list version is failing though. I am not so familiar with the initializer lists to say if and how they should work. Maybe my compiler (VS2013) is still deficient. >> Yip, what makes this interesting is the fact that std::unique_ptr >> cannot > be copied (in order to prevent double frees!) Yes, but it can be moved, which makes it possible to put it in (C++11- compatible) STL containers. Cheers Paavo |
Luca Risolia <luca.risolia@linux-projects.org>: Dec 30 04:10AM +0100 Il 29/12/2014 18:37, Lynn McGuire ha scritto: > We use new and delete a lot in our base classes since we are memory > constrained in the Win32 environment. std::unique_ptr has been designed so that it can take the same size as a pointer by default, isn't this the case for Win32? |
Lynn McGuire <lmc@winsim.com>: Dec 29 11:37AM -0600 On 12/26/2014 3:00 PM, Jorgen Grahn wrote: > and some people need it frequently -- but you can do /a lot/ of > programming without having to care about such things. > /Jorgen We use new and delete a lot in our base classes since we are memory constrained in the Win32 environment. We rarely use new or delete in the descendent classes since they are so powerful. Lynn |
Jack Chuge <zhuge.jack@gmail.com>: Dec 30 10:55PM +0800 BV BV 於 2014-11-14 22:05 寫道: > Woman's dress in Islam > According to religion of Islam woman should only display her face and palms of hands in front of foreigner men (indoor and outdoor) and more than that is prohibited. > Allah Almighty tells prophet Mohamed peace be upon him to order women to do the following: (And tell the believing women to lower their gaze (from looking at forbidden things), and protect their private parts (from illegal sexual acts) and not to show off their adornment except only that which is apparent (like both eyes for necessity to see the way, or outer palms of hands or one eye or dress like veil, gloves, head-cover, apron, etc.), and to draw their veils all over Juyûbihinna (i.e. their bodies, faces, necks and bosoms) and not to reveal their adornment except to their husbands, or their fathers, or their husband's fathers, or their sons, or their husband's sons, or their brothers or their brother's sons, or their sister's sons, or their (Muslim) women (i.e. their sisters in Islâm), or the (female) slaves whom their right hands possess, or old male servants who lack vigour, or small children who have no sense of feminine sex. And let them not stamp their feet so as to reve al what they hide of their adornment. And all of you beg Allâh to forgive you all, O believers, that you may be successful.){ Sûrat An-Nûr - The Light -verse31}. > * http://www.boston.com/news/nation/washington/articles/2008/07/11/skin_cancer_on_rise_in_young_women/ > * http://www.medicalnewstoday.com/articles/44764.php > Thank you It's a polite way to lower gaze from both men and women -- Jack |
JiiPee <no@notvalid.com>: Dec 28 01:11AM On 28/12/2014 00:58, Öö Tiib wrote: > The references are bad for renaming/aliasing because these take some memory. > Your derived objects will be bigger. It is better to use short accessory > functions for such aliases. Sort of like: oh. was thinking/hoping the compiler would optimize that away... why would the compiler not be able to do that? |
Ian Collins <ian-news@hotmail.com>: Dec 28 08:09PM +1300 EQuestionAnswers Inc wrote: > This is our website http://www.equestionanswers.com loaded with > C,C++, VC++,MFC,COM,DCOM, DLL question and answers, targeted for > interviews and self-study. Hope you like this forum. With examples like this: #include template T swap(T &a, T &b) { T temp; temp = a; a = b; b = temp; } void main() { int i = 10, j = 20; swap(i, j); cout << "Values i, j " << i << ", " << j; float a = 3.14, b = -6.28; swap(a, b); cout << "Values a, b " << a << ", " << b; } One to avoid. -- Ian Collins |
scott@slp53.sl.home (Scott Lurndal): Dec 23 05:08PM > postcondition: average( j, k ) is the smallest (nearest to > minus infinity) of all the long long values that are closest > to the mathematical value of (j+k)/2. return (j>>1)+(k>>1); |
You received this digest because you're subscribed to updates for this group. You can change your settings on the group membership page. To unsubscribe from this group and stop receiving emails from it send an email to comp.lang.c+++unsubscribe@googlegroups.com. |
No comments:
Post a Comment