We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
I want to write an infix expression but I can't use {} to make it infix, but neither can I use infix dots:
define-syntax ⊢ syntax-rules (:) [(⊢ Γ e : t) (void)] ;; I didn't expect this would work {Γ ⊢ e2 : t} ;; but this doesn't work either (Γ . ⊢ . e2 : t)
The text was updated successfully, but these errors were encountered:
Infix dots would be a good thing to support. I've also wanted to use them for -> contracts.
->
But for your case, if you define an nfx macro, you can have it recognize ⊢ and transform it:
nfx
⊢
#lang sweet-exp racket define-syntax ⊢ syntax-rules (:) [(⊢ Γ e : t) (void)] define-syntax nfx syntax-rules (⊢ :) [(nfx Γ ⊢ e : t) (⊢ Γ e : t)] {Γ ⊢ e2 : t}
Sorry, something went wrong.
Oh. Hm. That seems awkward and non-local, but I suppose that works.
No branches or pull requests
I want to write an infix expression but I can't use {} to make it infix, but neither can I use infix dots:
The text was updated successfully, but these errors were encountered: