Casey == Casey Ransberger casey.obrie...@gmail.com writes:
Casey Yes, class variables will be visible to subclasses of subclasses
Casey and so on. Also, I didn't mention pool variables, but 99.9% of
Casey the time you won't want to use those.
+1
--
Randal L. Schwartz - Stonehenge Consulting
/
If you want to learn GNU Smalltalk instead, I'm sure there's an
appropriate mailing list for you to join. Please don't ask about GNU
Smalltalk here.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com/merlyn
Tobias == Tobias Pape das.li...@gmx.de writes:
Tobias Every character is just a string of the length 1 (just like you
Tobias used it in the first place).
Not really.
That would imply $a is 'a'. And it's very much not, which is what the
OP is discovering.
--
Randal L. Schwartz - Stonehenge
. The debugger proceed will come back to here,
but the original message needs to be resent, probably poking at a new
version of a method (or one of the methods it calls).
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.posterous.com/ for Smalltalk discussion
Ken == Ken G Brown kbr...@mac.com writes:
Ken And a draft chapter on Exceptions from Pharo by Example 2 at:
Ken http://pharobyexample.org/
Yes, quite nice.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com/merlyn
you get an error when you command (or option or control or alt) s to
save?
I took 4.2 trunk, and it worked for me.
And for me, it doesn't say this class has no comment. It says:
A Randal is .
Instance Variables
Are you sure you're using the system browser?
--
Randal L. Schwartz
want docs that are as alive
as the code is.
Kommentaren Sun knows what they are doing.
Hardly. Sun doesn't even exist anymore. How knowing is that?
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com/merlyn
for
Smalltalk?
My reply is Javadoc sucks compared to Smalltalk's embedded tools.
Don't confuse that with the issue that the current *image* is probably
underdocumented.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com
to this is Yes, *inside the image*, which makes
it nicely searchable and maintainable, although the current image lacks
adequate documentation. And thank goodness this is nothing like Javadoc.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com
, bay-bee.
And to see what defines max:, open a method finder,
type max: in the proper window, and you can see the three classes
that define max:. The one closest to yours is Magnitude, which
is anything that has a linear comparability.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc
problem is more general than Arrays. :)
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com
sergio == sergio 101 sergiol...@village-buzz.com writes:
sergio pulled in my data... saved it to a string..
sergio then did:
sergio json stream: jData.
I think you want a Stream there, not a String.
easy enough:
json stream: jData readStream.
--
Randal L. Schwartz - Stonehenge Consulting
class was loaded, it was already initialize. You've just asked it
to do that again.
On the *instance* side, you *must* call super initialize, because
you don't get another chance to do that.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com
sergio == sergio 101 sergiol...@village-buzz.com writes:
sergio if i have people, which is a list of person(s), how would i spit out a
sergio list sorted by last name?
collection asSortedCollection: [:a :b | a lastName = b lastName ]
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc
Andy == Andy Burnett andy.burn...@knowinnovation.com writes:
Andy I just wanted to make sure I hadn't completely misunderstood blocks!
No, not completely. :)
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com
, and, as you've discovered, BlockContext.
Browse all implementors of #renderOn: for more illumination.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy
by a background process. You can force it, but
there's generally no need. Your car bits will eventually be recycled bits. :)
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting
a specific car, like
its color or owner.
Does that help?
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http
, and therefore your tests should
use parameterized class names.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http
a block are all signs that you aren't yet thinking in terms of small,
single-purpose methods.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc
methods class side, and all of your instance
variables as class instance variables.
Then treat MyFileLibrary as if it is the only instance that ever exists,
and has a global name.
If that's not what you want, explain more.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777
and .changes file are named the same, and in
same directory (folder), and your VM and .sources file are in
the same directory as each other, which may or may not be the same
as the .image and .changes file.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer
#initialize, so someone broke the chain between there
and your classes of interest by overriding #new without respecting the
existing protocol.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl
variable.
Yes, it's a bright shiny object to want to subclass that, but just like
subclassing SmallInteger, it's both legal and dumb. :)
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix
: handler to
perform the method on the contents variable, but that can mess up your
debugging, so it's better if you don't.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting
| [n * 10]].
b := a collect: [:each | each value]
b is now #(10 20 30 40 50 60 70 80 90 100) in a closure world. In
non-closure, it would have been 100, 100, 100...
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com
are temps or instance and then plugs in the code for me.
Not the browser, the compiler. And the compiler knows all the identifiers in
scope, or it couldn't compile the code.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http
K == K K Subramaniam subb...@gmail.com writes:
K Squeak fileOuts are binary files, not text; though they contain lot of
K ASCII characters.
Really? When did they change?
In classic Squeak, fileouts were basically the classic ST80 format,
which is clearly human-readable text.
--
Randal L
.sources and .changes, not fileOuts.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk
K == K K Subramaniam subb...@gmail.com writes:
K On Monday 17 Aug 2009 12:17:25 am Randal L. Schwartz wrote:
That explanation is about .sources and .changes, not fileOuts.
K The class fileout (from browser into *.st files) uses the same format
K (sequence of data chunks) as *.sources
there.
The starting point for a fileIn is a filename, from a file/directory browser.
Hence, fileIn appears there.
Does that help?
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting
. :)
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk and Seaside discussion
Gian == Gian Holland gia...@gmail.com writes:
Gian Is it very easy to query proprietary DB systems such as Sql server or
Gian Oracle with squeak?
SqueakDBX can do some of that.
http://wiki.squeak.org/squeak/6108
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
the block anyway, passing nil for the
shorter list? Or not call the block at all?
And depending on your choice, you should name the method clearly:
withOverlappingElementsOf:do:
with:ifAbsent:do:
the latter, you could call as:
a with: b ifAbsent: nil do: [ ... ]
--
Randal L. Schwartz
K == K K Subramaniam subb...@gmail.com writes:
K In Squeak, i in the block will refer to the i in the do: block and the last
K statement will print 25 because i would be 5 when do: terminates.
Not necessarily. I could see an implementation where i would be 4.
--
Randal L. Schwartz
at the implementation of StringexpandMacrosWithArguments:
to see how to use a ReadStream on the source and WriteStream to hold the
destination.
Also, if the logic gets to be nested blocks, I try to refactor that
rather quickly.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
subsequence of one or more
message sends that can be pulled out and named separately with an
intention-revealing selector, providing both code reuse, and clarity.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
mer...@stonehenge.com URL:http://www.stonehenge.com
OpenedInterval from: aNumber to: aNumber left: aBoolean right: aBoolean
You're exposing implementation there. I suggest:
beOpenLeft
beClosedLeft
isOpenLeft
isClosedLeft
and the corresponding right methods, rather than an explicit boolean.
More flexibility later.
--
Randal L. Schwartz
Bert == Bert Freudenberg [EMAIL PROTECTED] writes:
Bert On 24.11.2008, at 17:46, Randal L. Schwartz wrote:
Filip == Filip Malczak [EMAIL PROTECTED] writes:
Filip You can always make subclass of Interval for example OpenedInterval
, add
Filip two variables: left and right.Make new methods
L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk and Seaside discussion
'.
ma serveFiles.
(HttpService startOn: 9090 named: 'httpd') plug: ma rootModule.
MyClass class shutDown
self stop.
MyClass class stop
HttpService allInstancesDo: [:each | each stop. each unregister].
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc
in that first block throws
a SpontaneousCombustionException, you get into your second block.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http
, and that doesn't seem very Smalltalk at
Andy all! So, what is the OO way to do this?
Create a visitor pattern. Teach each of strings and arrays how to
present themselves.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http
.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk and Seaside discussion
?content=2001-files-exceptions
It's a bit dated but it might give you the information you need.
Even uses #on:do: like the ANSI standard suggests.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix
.
Then go off and do something else for 10 seconds. :)
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com
? Can
you just use that?
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk and Seaside
even have to name the stream, because it has that
temporary name inside the block.
Look for the many senders of #streamContents: as examples.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix
^ aBlock value: [ :finalValue | ^finalValue ]
...
found := self valuedEscaper: [:escape |
1 to: 10 do: [ :x |
x = 3 ifTrue: [escape value: true].
]
false].
Oh geez. I think I just reinvented continuations. :)
--
Randal L. Schwartz - Stonehenge
Bert == Bert Freudenberg [EMAIL PROTECTED] writes:
Bert That would be a perfect opportunity to employ
#valueWithPossibleArgument:.
And with this, the newbies heads have exploded. :)
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http
.
That is,
'abcde' allButFirst: 2
would return 'cde'.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com
object that
intercepts all messages and looks for the dangerous ones, but that's gonna be
a bit hard to do, and won't be aware of any new code that might call the
mutating primitives directly. (*Any* method can call a primitive.)
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503
simulation as long as everyone
cooperates.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk
, hand-compiling them if necessary.
Unless you're now voting for an immutable method dictionary. :)
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc
Bert == Bert Freudenberg [EMAIL PROTECTED] writes:
Bert How would that outsider get at the class of the object?
I believe #class is NoLookup, meaning that I can't define a method of my own
to do something weird with that.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503
Randal == Randal L Schwartz [EMAIL PROTECTED] writes:
Randal I believe #class is NoLookup, meaning that I can't define a method
Randal of my own to do something weird with that.
Feh. Ignore me. I have no idea what I'm talking about. :)
--
Randal L. Schwartz - Stonehenge Consulting Services
.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk and Seaside discussion
Randal == Randal L Schwartz [EMAIL PROTECTED] writes:
Randal myStream = WriteStream new.
Sorry. (WriteStream on: '')
Randal use myStream as if it were a FileStream
Randal myString := myStream contents.
Randal That's the nice part about the various protocol families. It mostly
just
Randal
initialize, meaning that the initialize method is actually
called very explicitly once the class is loaded.
Modern code management systems simulate this in various ways.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com
.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk and Seaside discussion
Randal == Randal L Schwartz [EMAIL PROTECTED] writes:
Randal Just browse all references to the class. That's a command-N (mac)
Randal when hovering over the class name in the second pane of a standard
Randal browser.
And when I typed N, I meant shift n :).
--
Randal L. Schwartz - Stonehenge
there does nothing, since you aren't
updating the object that was originally in each.
You need to tell anyone still holding a reference to your objects
to let go. Some advice can be found at http://wiki.squeak.org/squeak/2176
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
:
aString collect: [:char | char xmlEscaped].
Internally, that uses a Stream, which extends itself nicely as new data
appears. In your version, the early string data is getting repeatedly copied
to make each new string. Ouch.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777
used it, it would save you about 1-2 characters of
typing per line. But I usually get those typed without noticing anyway. :)
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting
would be your other object. :)
The safe way to become: something innocent is often become: String new.
Even so, it's (a) very slow on Squeak and (b) a bit shocking to the holder
of the value, who still expects the old object at its referenced oop.
--
Randal L. Schwartz - Stonehenge Consulting
?
The longer answer is that we generally *don't* do that, so there's not a lot
of discussion or support for it, but there it is.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting
Randal == Randal L Schwartz [EMAIL PROTECTED] writes:
Bert == Bert Freudenberg [EMAIL PROTECTED] writes:
Bert Am 26.09.2008 um 05:12 schrieb Mark Volkmann:
Is it possible to run a Squeak program from a terminal window and have
access to the stdin and stdout streams from the Smalltalk code
, and it it
will work as advertised for unix platforms.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk
argued that automatic creation of getters and setters is wrong.
This is clearly an example of where automatic getters and setters lead you to
bizarre code.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn
Mark == Mark Volkmann [EMAIL PROTECTED] writes:
Mark Is there an equivalent of Java's enumerated values (enum) in Smalltalk?
I hope not!
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix
Alex == Alex Chi [EMAIL PROTECTED] writes:
Alex So for example if the input is 'SmallTalk' the result is ('SmallTlk'
Alex 'SmllTlk').
Presuming the input came from someone who didn't know that Smalltalk
doesn't have a capital T. :)
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc
allInstances for *real* code.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk
Steve == Steve Lloyd [EMAIL PROTECTED] writes:
Steve Is there a Squeak class to allow calling a shell command in the host OS
Steve and receiving the result?
Yes, it's called OSProcess (I think), and is installable from SqueakMap
or Universes.
--
Randal L. Schwartz - Stonehenge Consulting
have:
result := theSolver solveQuadraticEquationForA: a andB: b andC: c.
or something like that.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc
)).
And that works for me. What version are you using?
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk
: Set new.
Eventually, the newbie can learn that the cut-n-paste-and-slightly-edit that I
just did to make that can be replaced by a proper loop. But at least that
cut/paste cycle won't be repeated everywhere else in the code.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503
variables that are acted upon in
similar ways really ought to be part of a common data structure rather than
unrelated variables.
hands := IdentityDictionary newFrom:
(#(north east south west trick) collect: [:each | each - Set new]).
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1
week
where I read the week's Squeak news. It's usually near the end if you aren't
interested in the rest of the podcast, but I suggest you listen to the entire
podcast anyway, as it covers a wide variety of smalltalk topics.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777
there are clearly some shortcuts that already do this, but
to require this enmasse doesn't seem to gain much. The always ask
the canvas for a tagbrush seems like a very workable rule.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http
Jerome == Jerome Peace [EMAIL PROTECTED] writes:
Jerome So what do you suggest to solve the problem?
Use the code from the Crypto team. If you want that included in the core,
make sure it has an MIT license, and submit it as a bug/change-request.
--
Randal L. Schwartz - Stonehenge
of those particular method names, you'll get a lot of examples of how
to use them.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http
is a subject to debate (read: religious war). I hope you
haven't accidentally triggered that thread here. I tend to do the simplest
thing that works, and leave it at that.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com
, and this is what allows them to
communicate, so you can't just add new things here or change the ordering
without building a corresponding new VM.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl
of entropy by calling a 56-bit PRNG
twice.
It's not progress if it breaks it.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http
at it this way. The cycle will repeat in 2**53 calls to the random
number generator. By calling it 10 times for each result, you're using
causing it to loop 10 times as fast. You can't get 10 pounds of entropy out
of a 5 pound sack.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503
to learn, it might be best to start with an
appropriate list for that vendor, simply because you might not know whether
it's Squeak-specific or not.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix
bits on this one. :)
It's pretty likely you have a 16-bit random generator, so there just aren't
enough bits to make the low-order bits random in any way shape or form.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com
Randal == Randal L Schwartz [EMAIL PROTECTED] writes:
Timothy == Timothy J Miller [EMAIL PROTECTED] writes:
Timothy (2 raisedTo: 128) atRandom hex
Timothy Gives me results like:
Timothy B990880B73211001
Timothy BFD3A7B37FA75001
Timothy
Timothy == Timothy J Miller [EMAIL PROTECTED] writes:
Timothy It certainly is inconsistent to have an Integer method that doesn't
Timothy invisibly handle large ints.
The Integer method is fine. The problem is the lack of bits from the PRNG
from class Random.
--
Randal L. Schwartz
. There are only 56 bits in an IEEE Float. You can't get any more
random bits from that.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http
]) sum.
Well, the #detectSum: solution is even cleaner. :)
mTotal := testSets detectSum: [:each | each maternalCount].
It's just a horribly named method, which is why I didn't find it at first.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED
K == K K Subramaniam [EMAIL PROTECTED] writes:
K Entering sum in a new line in workspace or text object and then pressing
K ALT+SHIFT+W would have revealed detectSum: (it is eleventh in my list).
Yeah, I looked near the implementation of #sum instead. Ooops.
--
Randal L. Schwartz
and underutilized. :)
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk and Seaside discussion
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk and Seaside discussion
Randal == Randal L Schwartz [EMAIL PROTECTED] writes:
Randal Huh? Why the heck is that called #detectSum: instead of just #sum:?
[...]
Randal /me makes a note to look under #detectFoo: next time
In fact, now that I look at it, it's really not like #detectMax:, which
returns the *original
to the Process that others can
stuff information, so that Process allInstances can get my process watcher
what it needs instead.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting
nicolas == nicolas cellier [EMAIL PROTECTED] writes:
nicolas But maybe we have just quit the beginners rails...
I think the moment you mention Weak, you're already outside
beginner space. :)
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED
at the moment.
Absolutely. A clearly seminal book. My dog-eared copy is within reach, at
least when I'm in my home office. Too bad Kent has gone off to the Java, and
now C# realm, if I heard right.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED
a mac, and a good mike setup.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk and Seaside
1 - 100 of 133 matches
Mail list logo