github ponylang/ponyc 0.51.3

latest releases: 0.58.6, 0.58.5, 0.58.4...
2 years ago

Fix bug in StdStream.print

When printing via StdStream.print strings containing null bytes, the standard library was printing the string until the first null byte and then padding the printed string with space characters until the string size was reached.

This bug was introduced in Pony 0.12.0 while fixing a different printing bug.

We've fixed the bug so that printing strings with null bytes works as expected.

Enhance checking for identity comparison with new objects

Consider the following program:

class C

actor Main
  new create(env: Env) =>
    env.out.print(if C is C then "C is C" else "C is NOT C" end)

This will fail to compile with the message identity comparison with a new object will always be false.

Nevertheless, the checking wasn't exhaustive and some cases weren't covered, like the one in the following example:

class C

actor Main
  new create(env: Env) =>
    env.out.print(if C.create() is C.create() then "C is C" else "C is NOT C" end)

We've made the check exhaustive and we believe it now covers all possible cases.

[0.51.3] - 2022-10-02

Fixed

  • Fix bug in StdStream.print (PR #4180)
  • Fix identity comparison check with desugared creations (PR #4182)

Don't miss a new ponyc release

NewReleases is sending notifications on new releases.