
This pull request is largely a renaming effort to clean up the TR codebase. There are two primary things I wanted to change: 1. Replace all occurrences of "filter" with "prop" or "proposition" - The word "filter" is a meaningless opaque term at this point in the Typed Racket implementation. If anything, it just adds confusion to why things are the way the are. We should use "proposition" instead, since that's what they actually are. 2. Avoid using "Top" and "Bottom" in both the type and proposition realm. - Currently the top type is called Univ and the bottom type is called bottom, while the top proposition is called Top and the bottom proposition is called Bot. This is just unnecessarily confusing, doesn't really line up w/ the user-space names, and doesn't line up with the names we use in TR formalisms. Worse, all of the top types of primitive types---e.g. the type of all structs, StructTop--- use Top, so it is really easy to get confused about what name to use for these sorts of things. With these issues in mind, I made the following changes to names: Top -> TrueProp Bot -> FalseProp TypeFilter -> TypeProp NotTypeFilter -> NotTypeProp AndFilter -> AndProp OrFilter -> OrProp -filter t o -> -is-type o t -not-filter t o -> -not-type o t FilterSet -> PropSet NoFilter -> #f NoObject -> #f -FS -> -PS -top -> -tt -bot -> -ff implied-atomic? q p -> implies-atomic? p q filter-rec-id -> prop-rec-id -no-filter -> -no-propset -top-filter -> -tt-propset -bot-filter -> -ff-propset -true-filter -> -true-propset -false-filter -> -false-propset PredicateFilter: -> PredicateProp: add-unconditional-filter-all-args add-unconditional-prop-all-args
48 lines
1.1 KiB
Racket
48 lines
1.1 KiB
Racket
#lang racket/base
|
|
|
|
(require
|
|
rackunit
|
|
(for-syntax racket/base syntax/parse racket/syntax))
|
|
|
|
(provide unit-tests)
|
|
|
|
(define-syntax define-tests
|
|
(syntax-parser
|
|
[(_ test-name:id files:expr ...)
|
|
(define/with-syntax (new-names ...)
|
|
(generate-temporaries #'(files ...)))
|
|
#'(begin
|
|
(require (only-in files [tests new-names]) ...)
|
|
(define test-name
|
|
(make-test-suite
|
|
"Unit Tests"
|
|
(list new-names ...))))]))
|
|
|
|
(define-tests unit-tests
|
|
"typecheck-tests.rkt"
|
|
"subtype-tests.rkt"
|
|
"type-equal-tests.rkt"
|
|
"remove-intersect-tests.rkt"
|
|
"static-contract-conversion-tests.rkt"
|
|
"static-contract-optimizer-tests.rkt"
|
|
"parse-type-tests.rkt"
|
|
"subst-tests.rkt"
|
|
"infer-tests.rkt"
|
|
"keyword-expansion-test.rkt"
|
|
"special-env-typecheck-tests.rkt"
|
|
"contract-tests.rkt"
|
|
"interactive-tests.rkt"
|
|
"type-printer-tests.rkt"
|
|
"type-alias-helper.rkt"
|
|
"class-tests.rkt"
|
|
"class-util-tests.rkt"
|
|
"check-below-tests.rkt"
|
|
"init-env-tests.rkt"
|
|
"prop-tests.rkt"
|
|
"metafunction-tests.rkt"
|
|
"generalize-tests.rkt"
|
|
"prims-tests.rkt"
|
|
"tooltip-tests.rkt"
|
|
"prefab-tests.rkt"
|
|
"typed-units-tests.rkt")
|