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. does anyone know why

does anyone know why

Scheduled Pinned Locked Moved The Lounge
question
24 Posts 20 Posters 0 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.
  • B Offline
    B Offline
    bulg
    wrote on last edited by
    #1

    apple thinks they can get away with BOOL values of "YES" and "NO" ?

    G H R P C 13 Replies Last reply
    0
    • B bulg

      apple thinks they can get away with BOOL values of "YES" and "NO" ?

      H Offline
      H Offline
      Henry Minute
      wrote on last edited by
      #2

      Where? When? WTF!

      Henry Minute Do not read medical books! You could die of a misprint. - Mark Twain Girl: (staring) "Why do you need an icy cucumber?" “I want to report a fraud. The government is lying to us all.”

      1 Reply Last reply
      0
      • B bulg

        apple thinks they can get away with BOOL values of "YES" and "NO" ?

        G Offline
        G Offline
        Gary Wheeler
        wrote on last edited by
        #3

        It's a California thing; truth and falsehood are so, well, relative to one's life situation, you know?

        Software Zen: delete this;

        M 1 Reply Last reply
        0
        • B bulg

          apple thinks they can get away with BOOL values of "YES" and "NO" ?

          R Offline
          R Offline
          Rama Krishna Vavilala
          wrote on last edited by
          #4

          TRUE and FALSE works too. I think YES sometimes is more readable. But it is just a #define.

          1 Reply Last reply
          0
          • B bulg

            apple thinks they can get away with BOOL values of "YES" and "NO" ?

            P Offline
            P Offline
            PIEBALDconsult
            wrote on last edited by
            #5

            How it's displayed doesn't matter.

            1 Reply Last reply
            0
            • B bulg

              apple thinks they can get away with BOOL values of "YES" and "NO" ?

              C Offline
              C Offline
              Chris Losinger
              wrote on last edited by
              #6

              they take fewer keystrokes than "TRUE" and "FALSE" !

              image processing toolkits | batch image processing

              1 Reply Last reply
              0
              • B bulg

                apple thinks they can get away with BOOL values of "YES" and "NO" ?

                R Offline
                R Offline
                rastaVnuce
                wrote on last edited by
                #7

                Well, they get away with selling their stuff at hilarious prices, why not get away with this?

                Where it seems there are only borderlines, Where others turn and sigh, You shall rise!

                1 Reply Last reply
                0
                • B bulg

                  apple thinks they can get away with BOOL values of "YES" and "NO" ?

                  J Offline
                  J Offline
                  Jim Crafton
                  wrote on last edited by
                  #8

                  Because it's *specifically* used in ObjectiveC, which predates Apple's use of it, actually ask Brad Cox about it. YES and NO clearly indicate you're in ObjectiveC land, not C, so it's just a way to separate the two. Also given the style in ObjectiveC to have sentence like readability, it's not that surprising.

                  ¡El diablo está en mis pantalones! ¡Mire, mire! SELECT * FROM User WHERE Clue > 0 0 rows returned Save an Orange - Use the VCF! Personal 3D projects Just Say No to Web 2 Point Oh

                  D 1 Reply Last reply
                  0
                  • J Jim Crafton

                    Because it's *specifically* used in ObjectiveC, which predates Apple's use of it, actually ask Brad Cox about it. YES and NO clearly indicate you're in ObjectiveC land, not C, so it's just a way to separate the two. Also given the style in ObjectiveC to have sentence like readability, it's not that surprising.

                    ¡El diablo está en mis pantalones! ¡Mire, mire! SELECT * FROM User WHERE Clue > 0 0 rows returned Save an Orange - Use the VCF! Personal 3D projects Just Say No to Web 2 Point Oh

                    D Offline
                    D Offline
                    Douglas Troy
                    wrote on last edited by
                    #9

                    Jim Crafton wrote:

                    Also given the style in ObjectiveC to have sentence like readability, it's not that surprising.

                    I believe it should be updated to reflect the almost hippie like status of the Apple culture:

                    if (TotallyBogus(NSObjectDude))
                    {
                    throw BogusDude();
                    }
                    else
                    {
                    NSObjectDude.Cool = "Awesome";
                    }


                    :..::. Douglas H. Troy ::..
                    Bad Astronomy |VCF|wxWidgets|WTL

                    1 Reply Last reply
                    0
                    • B bulg

                      apple thinks they can get away with BOOL values of "YES" and "NO" ?

                      P Offline
                      P Offline
                      Paul M Watt
                      wrote on last edited by
                      #10

                      Are iYes and iNo supported? When we are forced to use those values I think we will have a problem.

                      L J 2 Replies Last reply
                      0
                      • B bulg

                        apple thinks they can get away with BOOL values of "YES" and "NO" ?

                        D Offline
                        D Offline
                        dighn
                        wrote on last edited by
                        #11

                        "does anyone know why apple thinks they can get away with BOOL values of \"YES\" and \"NO\" ?" Yes.

                        1 Reply Last reply
                        0
                        • B bulg

                          apple thinks they can get away with BOOL values of "YES" and "NO" ?

                          J Offline
                          J Offline
                          JimmyRopes
                          wrote on last edited by
                          #12

                          bulg wrote:

                          apple thinks they can get away with BOOL values of "YES" and "NO" ?

                          Because they can. :-D

                          Simply Elegant Designs JimmyRopes Designs
                          Think inside the box! ProActive Secure Systems
                          I'm on-line therefore I am. JimmyRopes

                          1 Reply Last reply
                          0
                          • B bulg

                            apple thinks they can get away with BOOL values of "YES" and "NO" ?

                            T Offline
                            T Offline
                            The Nightcoder
                            wrote on last edited by
                            #13

                            Well... in my CCBool function (a CBool replacement for VBScript), they can. I acknowledge True, T, Yes, Y and X as true, everything else as false. Or, to quoute a famous RFC... in good protocol design, you should be liberal in what you accept and pedantic about what you send (or something like that).

                            Peter the small turnip (1) It Has To Work. --RFC 1925[^]

                            1 Reply Last reply
                            0
                            • B bulg

                              apple thinks they can get away with BOOL values of "YES" and "NO" ?

                              L Offline
                              L Offline
                              Luc Pattyn
                              wrote on last edited by
                              #14

                              what is wrong with "YES" and "NO"? or do you want "YES", "NO", "Cancel"? :)

                              Luc Pattyn [Forum Guidelines] [My Articles]


                              The quality and detail of your question reflects on the effectiveness of the help you are likely to get. Show formatted code inside PRE tags, and give clear symptoms when describing a problem.


                              H 1 Reply Last reply
                              0
                              • P Paul M Watt

                                Are iYes and iNo supported? When we are forced to use those values I think we will have a problem.

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

                                As well as iDon'tKnow?

                                Visit http://www.notreadytogiveup.com/[^] and do something special today.

                                J G 2 Replies Last reply
                                0
                                • L Lost User

                                  As well as iDon'tKnow?

                                  Visit http://www.notreadytogiveup.com/[^] and do something special today.

                                  J Offline
                                  J Offline
                                  Jim Crafton
                                  wrote on last edited by
                                  #16

                                  I think that would be

                                  if ( YES == [iDont know] )
                                  {
                                  NSLog( @"I don't know" );
                                  }

                                  ¡El diablo está en mis pantalones! ¡Mire, mire! SELECT * FROM User WHERE Clue > 0 0 rows returned Save an Orange - Use the VCF! Personal 3D projects Just Say No to Web 2 Point Oh

                                  1 Reply Last reply
                                  0
                                  • G Gary Wheeler

                                    It's a California thing; truth and falsehood are so, well, relative to one's life situation, you know?

                                    Software Zen: delete this;

                                    M Offline
                                    M Offline
                                    Marc Clifton
                                    wrote on last edited by
                                    #17

                                    Gary Wheeler wrote:

                                    It's a California thing

                                    In that case, I would have assumed that a bool would equate to "Gay" and "Straight". Marc

                                    Will work for food. Interacx

                                    G 1 Reply Last reply
                                    0
                                    • L Luc Pattyn

                                      what is wrong with "YES" and "NO"? or do you want "YES", "NO", "Cancel"? :)

                                      Luc Pattyn [Forum Guidelines] [My Articles]


                                      The quality and detail of your question reflects on the effectiveness of the help you are likely to get. Show formatted code inside PRE tags, and give clear symptoms when describing a problem.


                                      H Offline
                                      H Offline
                                      Hans Dietrich
                                      wrote on last edited by
                                      #18

                                      I think he wants  YES  NO  CANCEL  with an optional checkbox  

                                      Do Not Ask Me Again
                                      . :)

                                      Best wishes, Hans


                                      [Hans Dietrich Software]

                                      B 1 Reply Last reply
                                      0
                                      • B bulg

                                        apple thinks they can get away with BOOL values of "YES" and "NO" ?

                                        R Offline
                                        R Offline
                                        Roger Wright
                                        wrote on last edited by
                                        #19

                                        Yes.

                                        "A Journey of a Thousand Rest Stops Begins with a Single Movement"

                                        1 Reply Last reply
                                        0
                                        • H Hans Dietrich

                                          I think he wants  YES  NO  CANCEL  with an optional checkbox  

                                          Do Not Ask Me Again
                                          . :)

                                          Best wishes, Hans


                                          [Hans Dietrich Software]

                                          B Offline
                                          B Offline
                                          bulg
                                          wrote on last edited by
                                          #20

                                          I want a bool to be true or false. Not Yes or No! It's Objective C not bloody Prolog!!! The only time I want something in my program to evaluate to a "Yes" is when someone buys the damn thing. >.< I also loathe the IB & IBOutlet crap. CS4 got it so much more right, that I wish I could use it for a suitable native language.

                                          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