home.social

#hastail — Public Fediverse posts

Live and recent posts from across the Fediverse tagged #hastail, aggregated by home.social.

fetched live
  1. Did you know that Squeak offers declarative sorting?

    This allows you to avoid lengthy manual comparisons:

    animals sorted: [:a :b |
    a age > b age or: [
    a age = b age and: [
    a name <= b name]]].

    Instead, you can declare and chain multiple sort functions:

    animals sorted: descending , ascending.

    Since Squeak 6.1, boolean predicates are supported as well:

    animals sorted: sortedFirst , sortedLast , ascending.