Microsoft LINQ Books

Programming Microsoft LINQ & Introducing Microsoft LINQ
Welcome to Microsoft LINQ Books Sign in | Join | Help
in Search

errata

Last post 12-28-2007, 9.26 by Marco.Russo. 3 replies.
Sort Posts: Previous Next
  •  05-28-2007, 7.49 28

    errata

    Hi,

        Thanks for a great book!

        3 tiny things:

          In the Note at the top of page 55 the last sentence should be "In this way the object is not visible to another thread until it is not completely initialized."

         The second to last sentence on page 46 should be "When the name is not explicit it is inferred from the initialization, as in the definitions for c3, c4, c5, and c6."

           The name "Frank" Order[0] on page 76, the result list on bottom of page 89, and the first sentence of page 90 are all out of phase with last line of page 87.   The simplest fix is to change the last line of page 87 to "{Month=July, Shipped=False, IdProduct=5, Price=50}.

    Thanks,

    Mark

     

     

     

     

     

  •  06-03-2007, 6.46 29 in reply to 28

    Re: errata

    Thank you Mark,
    you're a brilliant reviewer (we will surely remember you in case of future books reviewing). What happend, in particular on your last errata on Ch.4, is that we changed the sample code after writing that page ... and we forgot to update the sample result. Sorry about that.

    We've updated the "errata corrige" document on this site.

    Thanks,
    Paolo & Marco

  •  12-27-2007, 1.03 85 in reply to 29

    Re: errata

    Actually, Mark was mistaken about his correction to p. 46. The next-to-last sentence on that page was correct in its original version and you need to reverse that "correction" in your errata corrige document.  The mistake is actually in the preceding sentence. Mark did not notice the mistake in the first sentence of the paragraph and that lead him to misinterpret what you meant to say in the second.

    The first sentence says "The generated class has a public property and an underlying private field for each argument contained in the initializer: its name and its type are inferred from the object initializer itself." The mistake is the pronoun "its". Strictly speaking this could only refer to the "generated class" which is what Mark took it to mean.  But that is not what you meant: the generated class does not have its name or type inferred from anything. It is a whole new type that is created, not inferred; and it is assigned an arbitrary name (specifically, "AnonymousType0" as shown on p. 47): its name is not "inferred" from anything.

    It is the property whose name and type is inferred from the object initializer, not the class. So the next sentence, which begins "When the name is not explicit ..." is talking about cases where the property name is not explicit in the initialization expression.  The property names for variable c3 ("Name" and "Age") are explicit in the initialization expression, so c3 should NOT be added to the "for ... " clause at the end of the sentence.

    If Mark is reading this, then he might be thinking at this point that if I'm right, then c4, c5, and c6 do not belong on the list either since it appears that the property names are also explicit in their initialization expressions; but that is not really the case. What is explicit in those expressions is the property names of the source objects (c1 and c2). The compiler uses these very same names for the properties of the new target class that it is creating. So the compiler is inferring the property names (and types) from the source object property names (and types).  

    So the correction that is actually needed for that paragraph is to replace "its" in the first sentence with "the property's".

    Rickee

     

     

  •  12-28-2007, 9.26 88 in reply to 85

    Re: errata

    Ops!

    Rickee, you're right, we hadn't looked deep at this the first time.
    The errata document is now updated and we already checked the next book we're currently writing.

    Thank you very much for your help!

    Marco & Paolo

    Filed under: ,
View as RSS news feed in XML
Powered by Community Server (Personal Edition), by Telligent Systems