Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

652 remove superscripts from rec constr #655

Merged
merged 45 commits into from
Feb 19, 2025

Conversation

carlostome
Copy link
Contributor

@carlostome carlostome commented Jan 29, 2025

Checklist

  • Commit sequence broadly makes sense and commits have useful messages
  • Any semantic changes to the specifications are documented in CHANGELOG.md
  • Code is formatted according to CONTRIBUTING.md
  • Self-reviewed the diff

Sorry, something went wrong.

@carlostome carlostome linked an issue Jan 29, 2025 that may be closed by this pull request
@carlostome carlostome force-pushed the 652-remove-superscripts-from-rec-constr branch from c56a925 to b08b87f Compare January 29, 2025 10:49
@carlostome
Copy link
Contributor Author

This is currently blocked by #653

@carlostome carlostome force-pushed the 652-remove-superscripts-from-rec-constr branch from 675be19 to ef77a0e Compare January 31, 2025 09:54
This closes issue #653.

(It may be as simple as removing the extra new line character `+ \n` from the `file.write` line in the `write_file` function.)
@carlostome carlostome self-assigned this Feb 3, 2025
@carlostome carlostome force-pushed the 652-remove-superscripts-from-rec-constr branch from 8c1cc29 to f5a6fb8 Compare February 3, 2025 16:46
@carlostome carlostome marked this pull request as ready for review February 6, 2025 12:32
Copy link
Collaborator

@WhatisRT WhatisRT left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I really like this, but it's a shame that we're losing some of the patterns here. I think some of them should be resurrected. Here's the most obvious place where things got worse. Before:
Screenshot 2025-02-06 at 14 40 52

After:
Screenshot 2025-02-06 at 14 40 24

Obviously this has other issues as well, but in the before it's really easy to see what changed and maybe more crucially what didn't change (and that e.g. the reserves and treasury didn't get swapped), and in the after this is completely gone (and just adding the vertical vectors back in isn't going to fix it). There are a few other places such as UTXOW.

It's a shame that it's not quite as powerful as Lean's ⟨ ⟩ which also functions as a pattern on the LHS, but there probably isn't much we can do about that. I think in the above cases, it would be good to keep the patterns around just to render those more nicely.

Maybe it could be a future AIM project to get such record patterns that can be used for matching as well?

@carlostome
Copy link
Contributor Author

The before/after differences are due to a bug in the agda2vec.py script (see #666) not of this PR really

@WhatisRT
Copy link
Collaborator

WhatisRT commented Feb 6, 2025

If #666 is fixed then it still doesn't resolve the problem. In the before picture, the LHS provides quite a lot of information visually, just by being able to line up matching entries on the RHS. This gets lost completely if the LHS is just applyRUpd ru epochState.

carlostome and others added 8 commits February 6, 2025 15:43
plus changes `Ratify.lagda`: experiments to improve layout of Fig 54 of cardano-ledger.pdf
@williamdemeo
Copy link
Collaborator

Update re. eliminating constructors on LHS of applyRUpd def.

Here's what the output looks like now that the agda2vec script is working with @carlostome's new constructor type class.
applyRUpd

williamdemeo and others added 7 commits February 14, 2025 14:46
…ove-superscripts-from-rec-constr
- Move open statements to where clauses
- Move some open statements to invisible code blocks
- Change some alignments
@carlostome carlostome merged commit db0b626 into master Feb 19, 2025
8 checks passed
@carlostome carlostome deleted the 652-remove-superscripts-from-rec-constr branch February 19, 2025 08:22
github-actions bot added a commit that referenced this pull request Feb 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Remove superscripts from ⟦_,...,_⟧ (probably via a typeclass)
3 participants