Skip to content

Commit

Permalink
fix unused var warnings in examples
Browse files Browse the repository at this point in the history
  • Loading branch information
stylewarning committed Oct 6, 2023
1 parent 44afa37 commit e3ba1c0
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
12 changes: 6 additions & 6 deletions examples/quil-coalton/src/quil-coalton.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
(declare parse-quil-string (Parser String))
(define parse-quil-string
(map3
(fn (a b c) (into b))
(fn (_a b _c) (into b))
(char #\")
(many0
(alt
(not-char #\")
(map2 (fn (a b) b)
(map2 (fn (_a b) b)
(char #\\)
(char #\"))))
(char #\")))
Expand Down Expand Up @@ -259,14 +259,14 @@

(declare parse-quil-comment (Parser Unit))
(define parse-quil-comment
(map3 (fn (a b c) Unit)
(map3 (fn (_a _b _c) Unit)
(many0 non-newline-whitespace)
(char #\#)
(many0 (not-char #\Newline))))

(declare parse-quil-comment-line (Parser Unit))
(define parse-quil-comment-line
(map3 (fn (_ __ ___) Unit)
(map3 (fn (_a _b _c) Unit)
(many0 whitespace)
parse-quil-comment
(alt (map (const Unit) (char #\Newline))
Expand All @@ -285,10 +285,10 @@
QuilProgram
(map2 const
(many0
(map2 (fn (a _) a)
(map2 (fn (a _b) a)
;; Quil statements
(map4
(fn (_ a __ ___) a)
(fn (_a b _c _d) b)
;; Allow leading whitespace (including newlines) and comments
(many0 (alt parse-quil-comment-line whitespace))
parse-quil-statement
Expand Down
6 changes: 3 additions & 3 deletions examples/thih/src/thih.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -399,7 +399,7 @@

(declare initialEnv ClassEnv)
(define initialEnv
(ClassEnv (fn (i) (fail "Class not defined"))
(ClassEnv (fn (_i) (fail "Class not defined"))
(make-list tInteger tDouble)))

;; (define-type-alias EnvTransformer (ClassEnv -> (Optional ClassEnv)))
Expand Down Expand Up @@ -924,7 +924,7 @@
(Ambiguity Tyvar (List Pred)))

(declare ambiguities (ClassEnv -> (List Tyvar) -> (List Pred) -> (List Ambiguity)))
(define (ambiguities ce vs ps)
(define (ambiguities _ce vs ps)
(map (fn (v)
(Ambiguity v (filter
(fn (x)
Expand Down Expand Up @@ -983,7 +983,7 @@

(declare defaultedPreds (MonadFail :m => (ClassEnv -> (List Tyvar) -> (List Pred) -> (:m (List Pred)))))
(define defaultedPreds
(withDefaults (fn (vps ts) (concat (map (fn (a)
(withDefaults (fn (vps _ts) (concat (map (fn (a)
(match a
((Ambiguity _ x) x)))
vps)))))
Expand Down

0 comments on commit e3ba1c0

Please sign in to comment.