OpenDream icon indicating copy to clipboard operation
OpenDream copied to clipboard

Fixes writing to constants, adds readonly opendream pseudo-type, and makes var overrides respect their var's type

Open Altoids1 opened this issue 3 years ago • 1 comments

image

Fixes #738, fixes #702, and fixes #535.

Summary

This bugfix stuff comes with a refactor of DMObjectBuilder into the static class it probably should be.

As a treat, this PR also has a commit that amends Content.Test so that it actually prints the message of any unexpected runtime into the log file, instead of just declaring that there was a runtime. Should be helpful :)

Changelog

  • const now works as an effective keyword, preventing writing of values, within both procs and object definitions.
  • Assignments now consistently remember the type of what they're assigning to (for implicit new calls)
  • opendream_compiletimereadonly is now a valid type marker. Allows for marking something as unwriteable, while also not requiring the value to be literally a const.
  • Content.Test now logs the message of any unexpected runtime discovered during testing.
  • Fixed statics being overridable in derived classes.
  • Miscellaneous null-safety improvements!

Altoids1 avatar Aug 21 '22 00:08 Altoids1

This pull request has conflicts, please resolve those before we can evaluate the pull request.

github-actions[bot] avatar Aug 24 '22 02:08 github-actions[bot]