Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. pcWife = (CWife *)pcFiancee;

pcWife = (CWife *)pcFiancee;

Scheduled Pinned Locked Moved The Lounge
question
37 Posts 22 Posters 1 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Sam Woodward

    Sian and I will be running the following this weekend: pcWife = (CWife *)pcFiancee; :rose: Any wise advice from fellow CP folks? :laugh: S

    D Offline
    D Offline
    David Wulff
    wrote on last edited by
    #14

    Congrats Sam and Sian! :rose: Sam Woodward wrote: Any wise advice from fellow CP folks? I wonder if you could get your vicar/etc to read special "geek" vows? Can anyone come up with some good ones using casting, pointers, and all that? ;P


    David Wulff http://www.davidwulff.co.uk

    Pro wrestling is entertainment for the unentertained unentertainable.

    M 1 Reply Last reply
    0
    • S Sam Woodward

      We will be honeymooning in New England. Is anyone here from the Boston area and if so can you recommend any "don't leave without seeing xyz..." type of things please? Thanks, S

      B Offline
      B Offline
      Brigg Thorp
      wrote on last edited by
      #15

      Being from Connecticut, I get to Boston quite frequenttly. It's only an hour and a half drive for me. Here are a couple of things you should see. Touristy yes...but fun nonetheless. 1. Faneuil Hall (great place to get different kinds of food. It's like a food court on steroids) 2. Boston Aquarium 3. Museum of Science (lots of interactive exhibits) 4. Computer Museum (they have some really cool old computer stuff) 5. MIT 6. Harvard and Harvard Square 7. Cheers 8. Old North Church (actually, you can do the whole tour of the Revolutionary War era Boston. They have lines painted on the streets so you can follow them and see the sights). This should give you some things to do. Brigg Thorp Software Engineer Timex Corporation

      1 Reply Last reply
      0
      • S Stephane Rodriguez

        Sorry to bother you, but what does c mean in pcWife? I usually have it for copy pointers, so I got a bit shocked when I started thinking you were not monogam.:eek:


        sometimes it helps to look at the IL generated code a MS guy on develop.com "answering" .NET issues

        S Offline
        S Offline
        Sam Woodward
        wrote on last edited by
        #16

        I suspect everyone has their own querks and habits when it comes to naming. As for me, I use 'p' for pointer, 'c' for class (and then i for ints, etc. etc... ok so that breaks down with pointers to chars but...) Thus is my code: int *piVal; // would be a pointer to an int CString cName; // would be not be a pointer to a string! CWife *pcWife; // would be a pointer to an instance of class 'CWife' If I had a pointer to a pointer to a class it would be 'ppc' etc. I find that not only does this help with knowing the type of a variable, but also keeps them grouped more halpefully in the Class/Memebrs pane in VisualStudio. S

        1 Reply Last reply
        0
        • S Stephane Rodriguez

          Sorry to bother you, but what does c mean in pcWife? I usually have it for copy pointers, so I got a bit shocked when I started thinking you were not monogam.:eek:


          sometimes it helps to look at the IL generated code a MS guy on develop.com "answering" .NET issues

          S Offline
          S Offline
          Sam Woodward
          wrote on last edited by
          #17

          I suspect everyone has their own querks and habits when it comes to naming. As for me, I use 'p' for pointer, 'c' for class (and then i for ints, etc. etc... ok so that breaks down with pointers to chars but...) Thus is my code: int *piVal; // would be a pointer to an int CString cName; // would be not be a pointer to a string! CWife *pcWife; // would be a pointer to an instance of class 'CWife' If I had a pointer to a pointer to a class it would be 'ppc' etc. I find that not only does this help with knowing the type of a variable, but also keeps them grouped more helpfully in the Class/Memebrs pane in VisualStudio. S

          C K 3 Replies Last reply
          0
          • S Sam Woodward

            We will be honeymooning in New England. Is anyone here from the Boston area and if so can you recommend any "don't leave without seeing xyz..." type of things please? Thanks, S

            L Offline
            L Offline
            Lost User
            wrote on last edited by
            #18

            Sam Woodward wrote: Is anyone here from the Boston area and if so can you recommend any "don't leave without seeing xyz..." type of things please? I'm not from Boston (Sydney Australian actually) but visited head office in Cambridge in 1999 when I had a job. I recommend the Sunset Grill and Tap[^]. 112 beers on tap and 400 other beers available in bottles. What more can you ask for? Michael Martin Australia mjm68@tpg.com.au "I personally love it because I can get as down and dirty as I want on the backend, while also being able to dabble with fun scripting and presentation games on the front end." - Chris Maunder 15/07/2002

            1 Reply Last reply
            0
            • S Sam Woodward

              I suspect everyone has their own querks and habits when it comes to naming. As for me, I use 'p' for pointer, 'c' for class (and then i for ints, etc. etc... ok so that breaks down with pointers to chars but...) Thus is my code: int *piVal; // would be a pointer to an int CString cName; // would be not be a pointer to a string! CWife *pcWife; // would be a pointer to an instance of class 'CWife' If I had a pointer to a pointer to a class it would be 'ppc' etc. I find that not only does this help with knowing the type of a variable, but also keeps them grouped more helpfully in the Class/Memebrs pane in VisualStudio. S

              C Offline
              C Offline
              ColinDavies
              wrote on last edited by
              #19

              Your naming convention seems real similar to mine. But I use a c_ for class and ch for characters and only Cstr for CString. I thin the big rhing is consistency of names though. Regardz Colin J Davies

              Sonork ID 100.9197:Colin

              You are the intrepid one, always willing to leap into the fray! A serious character flaw, I might add, but entertaining. Said by Roger Wright about me.

              1 Reply Last reply
              0
              • D David Wulff

                Congrats Sam and Sian! :rose: Sam Woodward wrote: Any wise advice from fellow CP folks? I wonder if you could get your vicar/etc to read special "geek" vows? Can anyone come up with some good ones using casting, pointers, and all that? ;P


                David Wulff http://www.davidwulff.co.uk

                Pro wrestling is entertainment for the unentertained unentertainable.

                M Offline
                M Offline
                Michael P Butler
                wrote on last edited by
                #20

                The obvious one do { sex --; love ++; }while(death_us_do_part) Michael "Time and tide melts the snowman." -- The Doctor (Doctor Who: Time and the Rani

                L D 2 Replies Last reply
                0
                • S Sam Woodward

                  I suspect everyone has their own querks and habits when it comes to naming. As for me, I use 'p' for pointer, 'c' for class (and then i for ints, etc. etc... ok so that breaks down with pointers to chars but...) Thus is my code: int *piVal; // would be a pointer to an int CString cName; // would be not be a pointer to a string! CWife *pcWife; // would be a pointer to an instance of class 'CWife' If I had a pointer to a pointer to a class it would be 'ppc' etc. I find that not only does this help with knowing the type of a variable, but also keeps them grouped more helpfully in the Class/Memebrs pane in VisualStudio. S

                  C Offline
                  C Offline
                  ColinDavies
                  wrote on last edited by
                  #21

                  Your naming convention seems real similar to mine. But I use a c_ for class and ch for characters and only Cstr for CString. I thin the big thing is consistency of names though. Regardz Colin J Davies

                  Sonork ID 100.9197:Colin

                  You are the intrepid one, always willing to leap into the fray! A serious character flaw, I might add, but entertaining. Said by Roger Wright about me.

                  1 Reply Last reply
                  0
                  • S Shaun Wilde

                    surely the full algorithm is pcWife = (CWife*)pcFiancee; pcWife->Balance += pcHusband->Balance; pcHusband->Balance = 0; :)

                    Stupidity dies. The end of future offspring. Evolution wins. - A Darwin Awards Haiku

                    C Offline
                    C Offline
                    Christopher Duncan
                    wrote on last edited by
                    #22

                    Of course, if you don't do this check first, if (IsValidPtr(pcWife, CWife)) { ... } then you'll experience symptoms of pcWife occasionally going wild and vectoring off into unreasonable territory. At such times, a fault is imminent, and it will always be yours. :-D Chistopher Duncan Author - The Career Programmer: Guerilla Tactics for an Imperfect World (Apress)

                    1 Reply Last reply
                    0
                    • D Debs 0

                      Congratulations. I holidayed in Boston several years back, so this is a tad out of date, but I really enjoyed going to the Museum of Fine Arts (or the MFA as it gets called). Some great Monets and a lovely place. Depends on your tastes of course. Also, the Faneuil (sp?) market is well worth a visit. Note: I was a tourist, so these may well be tourist-y places and the locals may come up with some alternatives, but I did enjoy both those places. Another tip: remember that your wife is *not* to be compared to a class instantiation and treat her like a human being, won't you??? :-O Contrary to what some people on this notice board may think we are actually of the same species... Debbie

                      L Offline
                      L Offline
                      l a u r e n
                      wrote on last edited by
                      #23

                      wowwwwww! u mean we're the same species as ... *points nervously* ... them??!!?? *gasps*


                      "... and so i said to him ... if it don't dance (or code) and you can't eat it either f**k it or throw it away"
                      biz stuff   about me

                      L 1 Reply Last reply
                      0
                      • S Sam Woodward

                        I suspect everyone has their own querks and habits when it comes to naming. As for me, I use 'p' for pointer, 'c' for class (and then i for ints, etc. etc... ok so that breaks down with pointers to chars but...) Thus is my code: int *piVal; // would be a pointer to an int CString cName; // would be not be a pointer to a string! CWife *pcWife; // would be a pointer to an instance of class 'CWife' If I had a pointer to a pointer to a class it would be 'ppc' etc. I find that not only does this help with knowing the type of a variable, but also keeps them grouped more helpfully in the Class/Memebrs pane in VisualStudio. S

                        K Offline
                        K Offline
                        KaRl
                        wrote on last edited by
                        #24

                        I have the same naming habits as yours, except for strings. When I use String objects I prefix with "str", and when using character arrays I prefix by "lpsz" So I came to find To end up this way Feeling like I'm God Feeling there's no way KoRn

                        1 Reply Last reply
                        0
                        • L l a u r e n

                          Michael P Butler wrote: do { sex --; love ++; }while(death_us_do_part) ummmmm surely that last line is: }while(!death_do_us_part) unless theres something ur not telling us :)


                          "... and so i said to him ... if it don't dance (or code) and you can't eat it either f**k it or throw it away"
                          biz stuff   about me

                          K Offline
                          K Offline
                          KaRl
                          wrote on last edited by
                          #25

                          Bugs are everywhere :) So I came to find To end up this way Feeling like I'm God Feeling there's no way KoRn

                          1 Reply Last reply
                          0
                          • M Michael P Butler

                            The obvious one do { sex --; love ++; }while(death_us_do_part) Michael "Time and tide melts the snowman." -- The Doctor (Doctor Who: Time and the Rani

                            L Offline
                            L Offline
                            l a u r e n
                            wrote on last edited by
                            #26

                            Michael P Butler wrote: do { sex --; love ++; }while(death_us_do_part) ummmmm surely that last line is: }while(!death_do_us_part) unless theres something ur not telling us :)


                            "... and so i said to him ... if it don't dance (or code) and you can't eat it either f**k it or throw it away"
                            biz stuff   about me

                            K M T 3 Replies Last reply
                            0
                            • L l a u r e n

                              Michael P Butler wrote: do { sex --; love ++; }while(death_us_do_part) ummmmm surely that last line is: }while(!death_do_us_part) unless theres something ur not telling us :)


                              "... and so i said to him ... if it don't dance (or code) and you can't eat it either f**k it or throw it away"
                              biz stuff   about me

                              M Offline
                              M Offline
                              Michael P Butler
                              wrote on last edited by
                              #27

                              Thanks for the code review. :-O I can't code for shit without a debugger to hand :-D Michael "Time and tide melts the snowman." -- The Doctor (Doctor Who: Time and the Rani

                              1 Reply Last reply
                              0
                              • S Sam Woodward

                                Sian and I will be running the following this weekend: pcWife = (CWife *)pcFiancee; :rose: Any wise advice from fellow CP folks? :laugh: S

                                L Offline
                                L Offline
                                LukeV
                                wrote on last edited by
                                #28

                                delete pcWife; ASSERT( pcWife ); Congradulations :-D --------------- Concentrating on Ideas http://www.edovia.com

                                T 1 Reply Last reply
                                0
                                • C Christian Graus

                                  I believe the other thing that is likely to happen to you soon is this->sexLife = NULL; Christian Hey, at least Logo had, at it's inception, a mechanical turtle. VB has always lacked even that... - Shog9 04-09-2002 During last 10 years, with invention of VB and similar programming environments, every ill-educated moron became able to develop software. - Alex E. - 12-Sept-2002

                                  J Offline
                                  J Offline
                                  Jorgen Sigvardsson
                                  wrote on last edited by
                                  #29

                                  I don't follow your logic here. He'll be able to get some every now and then! He won't get a wide variety, but it is sex. :) -- Giles wrote: You Scandinavians invaded my home land, like 1500 (+-500) years ago, and kept coming back for more. You should be ashamed of yourselves. Viking Tour, England, 15th July 563. Ticket price: £10 Sold out!

                                  1 Reply Last reply
                                  0
                                  • L l a u r e n

                                    Michael P Butler wrote: do { sex --; love ++; }while(death_us_do_part) ummmmm surely that last line is: }while(!death_do_us_part) unless theres something ur not telling us :)


                                    "... and so i said to him ... if it don't dance (or code) and you can't eat it either f**k it or throw it away"
                                    biz stuff   about me

                                    T Offline
                                    T Offline
                                    Tomasz Sowinski
                                    wrote on last edited by
                                    #30

                                    You should have some Sleep(28800) in the loop; otherwise the 'sex' variable will quickly go into negative area :) Tomasz Sowinski -- http://www.shooltz.com

                                    *** Si fractum non sit, noli id reficere. ***

                                    1 Reply Last reply
                                    0
                                    • L LukeV

                                      delete pcWife; ASSERT( pcWife ); Congradulations :-D --------------- Concentrating on Ideas http://www.edovia.com

                                      T Offline
                                      T Offline
                                      Tomasz Sowinski
                                      wrote on last edited by
                                      #31

                                      VERIFY, not ASSERT. After all, they shouldn't spend their lives in debug configuration :) Tomasz Sowinski -- http://www.shooltz.com

                                      *** Si fractum non sit, noli id reficere. ***

                                      1 Reply Last reply
                                      0
                                      • L l a u r e n

                                        wowwwwww! u mean we're the same species as ... *points nervously* ... them??!!?? *gasps*


                                        "... and so i said to him ... if it don't dance (or code) and you can't eat it either f**k it or throw it away"
                                        biz stuff   about me

                                        L Offline
                                        L Offline
                                        Lost User
                                        wrote on last edited by
                                        #32

                                        lauren wrote: wowwwwww! u mean we're the same species as ... *points nervously* ... them??!!?? *gasps* I don't think so. I mean shopping, hairdressers, make-up, thousands of shoes... You lot must be a different breed completely. Michael Martin Australia mjm68@tpg.com.au "I personally love it because I can get as down and dirty as I want on the backend, while also being able to dabble with fun scripting and presentation games on the front end." - Chris Maunder 15/07/2002

                                        1 Reply Last reply
                                        0
                                        • S Sam Woodward

                                          Sian and I will be running the following this weekend: pcWife = (CWife *)pcFiancee; :rose: Any wise advice from fellow CP folks? :laugh: S

                                          B Offline
                                          B Offline
                                          Brian Delahunty
                                          wrote on last edited by
                                          #33

                                          Congratulations. I hope you have a good and enjoyable day. Regards, Brian Dela :-)

                                          1 Reply Last reply
                                          0
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          • Login

                                          • Don't have an account? Register

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • World
                                          • Users
                                          • Groups