Dafny 4.11.0 #6346
MikaelMayer
announced in
Announcements
Dafny 4.11.0
#6346
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
New features
Stabilize verifications by automatically computing triggers for the quantified proof obligations associated with
:|constructs.Manually specified triggers and warning-suppressing attributes are also supported (and mentioned in warning messages, as for other quantifiers and comprehensions).
Enhance witness guessing for the proof obligation associated for
:|assignments.(feat: Compute triggers for such-that operations #6023)
Four new Dafny standard libraries:
Std.Actions- utilities for abstract imperative actions, including enumerating and streaming valuesStd.Frames- utilities related to working with dynamic framing, often related to reads and modifies clausesStd.Ordinal- operations and properties of the ORDINAL typeStd.Termination- a datatype for representing Dafny decreases clauses and extensions(feat: Actions, Frames, Termination, and Ordinal standard libraries #6074)
Support using
--standard-librarieswith--enforce-determinism. RemovedStd.Collections.Seq.SetToSeqsince it was slow and not compatible with this mode. (https://github.com/dafny-lang/dafny/pull/6137)
With
--standard-librariesyou can now read an UTF-8 text files from the disk usingStd.FileIO.ReadUTF8FromFile(path: string): Result<string, string>.To write some content to the disk, use
Std.FileIO.WriteUTF8ToFile(path: string, content: string): Outcome<string>.Standard library breaking change: All
UnicodeEncodingFormversions ofFromUTF8Checked,FromUTF16CheckedandDecodeCodeUnitSequenceCheckednow return aResultinstead of anOptionso that the error message is clearer. Migration is easy: Use.ToOption()if you really prefer an option. Affected refining modules:Utf8EncodingFormandUtf16EncodingForm(Feat:
Std.FileIO.ReadFileandWriteFile#6198)The Dafny standard libraries now include a powerful parser combinators framework, available through
Std.Parsers.StringBuilders.Key Features
.??()(DSL) or?(...)(standard syntax)(Reinstate "Feat: Verified and easy-to-use parser combinators (#6143)" #6243)
Dafny classes and traits can now redeclare methods defined by traits they inherit from. (Allow redeclaring trait methods #6280)
Real literals now support scientific notation using lowercase
eto denote the exponent (like1.23e5for123000.0or5e-2for0.05). Real literals also support convenient trailing-dotshorthand (like
1.for1.0) and leading-dot shorthand (like.5for0.5or.5e2for50.0). Note that explicit+signs in exponents are not supported; use5e2instead of5e+2. (https://github.com/feat: Add comprehensive real literal support with scientific notation and dot shorthand #6286)
Bug fixes
Fix soundness issue that could occur when using an opaque block and old or fresh in its ensures clause (Opaque blocks allow proving false #6060)
Correctly display project files errors when using build command (Error does not mention faulty dfyconfig.toml file #6107)
Fix crash that could occur when a
forallstatement was used inside amatchcase(fix: Fix crash when a simple forall statement was placed inside a match #6121)Fix a case where a forall statement would cause Dafny to crash (Unable to cast object of type 'Microsoft.Dafny.BinaryExpr' to type 'Microsoft.Dafny.QuantifierExpr' #6129)
Fix @VerifyOnly and migrated the new code to use it (
@VerifyOnlynot working #6146)Java lambdas now accepting boxing/unboxing (Java equality between chars fails if one is unboxed. #6149)
Fix crash in resolution of structural-inclusion greater-than operator (fix: Fix crash in resolution of structural-inclusion greater-than operator #6155)
Generate alloc consequence axiom only for functions that read the heap (fixes unsoundness) (Soundness issue with constructors? #6164)
Made the language server compliant with the LSP protocol so that it can be used with other editors, such as Helix (Non-compliant LSP message prevents wider editor support #6172)
No more compilation issue when using bitvector shifts in Rust with the new resolver (Bitvector issue with
--type-system-refresh#6196)Fix handling of opaque blocks in the Dafny IDE (Opaque blocks not working in VSCode extension #6203)
JSON serialization now properly encodes unicode characters with 0 pre-pend instead of space-append.
Also, string literals ending with escaped characters are now supported as well.
(Standard Library serialization and deserialization error #6227)
Fail more gracefully when reusing names (fix: Fail more gracefully when reusing names #6262)
Escape user string literals in error messages (fix: Escape string literals in error messages #6273)
Compilation of type conversion from a
newtype-based onchartoint(fix: C# compilation of newtype-char to int conversion #6296)Fix LSP bug that cause IDE exceptions during invalid parse states (Fix LSP bug that returned a invalid range for documentSymbol #6299)
Fix two resolver crashes involving datatypes and traits (Fixes resolver crashes related to datatypes and traits #6321)
This discussion was created from the release Dafny 4.11.0.
Beta Was this translation helpful? Give feedback.
All reactions