[squeak-dev] The Inbox: Kernel-ct.1412.mcz

commits at source.squeak.org commits at source.squeak.org
Tue Sep 7 21:54:35 UTC 2021

A new version of Kernel was added to project The Inbox:

==================== Summary ====================

Name: Kernel-ct.1412
Author: ct
Time: 7 September 2021, 11:54:32.77151 pm
UUID: ca064a0e-13a5-f64f-ac9e-91ae045569a7
Ancestors: Kernel-eem.1408

Adds non-performant but existing implementation of #isPowerOfTwo on Number. Now 16s isPowerOfTwo works as expected, too. Complements Kernel-nice.1377.

=============== Diff against Kernel-eem.1408 ===============

Item was added:
+ ----- Method: Number>>isPowerOfTwo (in category 'testing') -----
+ isPowerOfTwo
+ 	^ self strictlyPositive and: [(self log2 \\ 1) isZero]!

More information about the Squeak-dev mailing list