Amazon.com Widgets Yellow Triangles !
Welcome, Guest. Please login or register.
Did you miss your activation email?
June 18, 2013, 02:31:53 PM
Home Help Search chat Login Register   
News: Read this please.The Great Kangaroo Escape Looking for reviews of the 4th ed on Amazon!   Twitter:  @skochan
                     

+  Official Forum for Programming in Objective-C (the iPhone Programming Language) - Stephen Kochan
|-+  Old Stuff
| |-+  Chapter Study
| | |-+  Chapter 2 - Programming in Objective-C
| | | |-+  Yellow Triangles !
Pages: [1]   Go Down
Print
Author Topic: Yellow Triangles !  (Read 508 times)
JackRabbit
Jr. Member
**
Posts: 54



Email




« on: November 28, 2011, 12:13:27 AM »

Greetings everyone.

This is more of a comment than a question but other comments are welcome.

On page 14, in the paragraph just before Figure 2.9, in the book it states:
Quote
Warnings are depicted by yellow triangles containing exclamation points—you can still run your program with them, but in general you should examine and correct them.

I am surprised that there are "grey area" errors in programming. Why are these yellow triangle errors allowed at run time? Any thoughts?

JR
Logged
Fred
Newbie
*
Posts: 46






« Reply #1 on: November 29, 2011, 09:17:24 AM »

JR,

The warnings are provided due to the fact the compiler can't know everything, so when there may be a problem, but it might not prevent program execution, the compiler presents the warning.  An example of a warning that does not impact program execution is declaring a variable that is not used in the program.  This does not cause any execution problems, but it does waste program resources and thus the warning.  There are others that will cause a run time error, such as calling a method from a class where the method is not defined.   This will become clearer as you progress through Steve's book and become more familiar with what produces a warning as opposed to what produces an error.

Fred
Logged

Fred
JackRabbit
Jr. Member
**
Posts: 54



Email




« Reply #2 on: November 29, 2011, 07:47:31 PM »

Thank you again Fred.

For a newbie you sure know alot!

These forums + the book + the webinars = understanding Objective-C

One day I hope to help you.

JR
Logged
Pages: [1]   Go Up
Print
Jump to:  



Login with username, password and session length

Powered by MySQL Powered by PHP Powered by SMF 1.1.11 | SMF © 2006-2009, Simple Machines LLC Valid XHTML 1.0! Valid CSS!
Entire forum contents (c) 2009 classroomM.com. All rights reserved.