-
-
Notifications
You must be signed in to change notification settings - Fork 12
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
Macro mistakes #270
Macro mistakes #270
Conversation
Some reference links I was using broke. 3.10 is currently the minimum supported Python version.
This makes the intention clearer.
And use tags more. https://medium.com/@tobias.talaj/decoding-python-which-standard-library-components-do-you-really-need-to-know-3ae3541bb2be informed which were "commonly used in Python code".
Expansion is shorter and more readable now. I haven't profiled, but fun definitions should be mostly top-level.
Longer bytes were of low value for the extra time they were taking.
Now uses _resolve_env() to walk up the stack like macroexpand and friends, and like evaluate/execute. It no longer makes an empty environment, you'd have to pass it explicitly.
$foo= should correspond to my.$foo
It's awesome.
100% test coverage!
Clarify that reserved identifiers are still symbols
And make macro_context env argument not optional.
_macro_ keys should be identifiers. There's no valid use for `.` in local tags, so munge as if escaped.
Add sentinel# tag
Add See also linking en# @ Add See also links for names that may be confused
And use it for intermediate expansions in macroexpand_all
Per style guide, tags should be named for their minimum arity, but it was called @## even though we had !# consistently.
Should happen right before the return, not before a preprocess call in some cases.
Ugh. Test runner floating-point hardware has different rounding errors than mine. I thought these would be more standardized. There are a lot of test examples using floats. I wonder if the precision is adjustable somehow. Maybe I can add rounding in a few places. That would make the output a bit easier to read, at the cost of some minor complication elsewhere. |
This is a lot more readable, at the cost of another distraction. The GitHub test runner was getting slightly different float answers in some cases. Rounding should fix those.
4a2c8a1
to
0021e5d
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #270 +/- ##
===========================================
+ Coverage 96.62% 100.00% +3.37%
===========================================
Files 6 6
Lines 830 833 +3
Branches 127 110 -17
===========================================
+ Hits 802 833 +31
+ Misses 20 0 -20
+ Partials 8 0 -8 ☔ View full report in Codecov by Sentry. |
This branch both fixes mistakes and maybe makes some more, in the sense of feature creep. This has taken literally months. I've added a lot more, which will (hopefully) make even standalone Hissp more practical for real-world use.
Resolves #259.
Resolves #173.
Those were my only blockers for the next release. I'll merge this in, give the docs a once over, and the next branch after that will be for the release!
Hissp's design still has a few imperfections that I don't have solutions for. I think I need to dogfood Lissp a lot and catch up Hebigo (and maybe Garden of EDN as well) before advancing Hissp any more than this. I will, of course, fix any serious bugs I discover, but Hissp will be in a feature freeze for the time being.