From: Robert Dober Date: 2006-04-21T20:10:38+09:00 Subject: Re: Threading example in FAQ 4.2 is slightly broken? ------=_Part_35082_5838146.1145617835764 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline On 4/21/06, Andy Gimblett wrote: > > Hi all, > > I just ran the example at the end of FAQ 4.2 > > http://www.rubycentral.com/faq/rubyfaq-4.html#ss4.2 > > The FAQ text says this produces: > > > onetwo: : 00 > > > > onetwo: : 11 > > > > onetwo: : 33 > > This confused me, so I ran the code and got: > > > one: 0 > > two: 0 > > one: 1 > > two: 1 > > one: 3 > > two: 3 > > which made more sense. OK, so thread scheduling is nondetermininistic > and there's no mutual exclusion on stdout, so I can see how the output > given in the FAQ entry _could_ happen - however, I think the version I > saw demonstrates the FAQ's point more clearly. > > Who should I tell about this? Raise a bug? Or is raising the alarm > hereabouts sufficient? :-) > > Thanks, > > -Andy > > -- > Andy Gimblett > Computer Science Department > University of Wales Swansea > http://www.cs.swan.ac.uk/~csandy/ > > Hmm why don't you drop a mail to the FAQ maintainer mailto: dave@pragmaticprogrammer.com ? Personally I fail to see the point of the example but that might just be because I am tired. Hope that helps Robert -- Deux choses sont infinies : l'univers et la b=EAtise humaine ; en ce qui concerne l'univers, je n'en ai pas acquis la certitude absolue. - Albert Einstein ------=_Part_35082_5838146.1145617835764--