├── src ├── test │ └── clojure │ │ └── .ignore └── main │ ├── dotnet │ └── packager │ │ └── clojure.core.specs.alpha.csproj │ └── clojure │ └── clojure │ └── core │ └── specs │ └── alpha.clj ├── doc └── intro.md ├── .gitignore ├── deps.edn ├── CONTRIBUTING.md ├── README.md ├── project.clj └── evl-v10.html /src/test/clojure/.ignore: -------------------------------------------------------------------------------- 1 | ;;ignore -------------------------------------------------------------------------------- /doc/intro.md: -------------------------------------------------------------------------------- 1 | # Introduction to clr.core.specs.alpha 2 | 3 | TODO: write [great documentation](http://jacobian.org/writing/great-documentation/what-to-write/) 4 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | pom.xml 2 | /lib/ 3 | /classes/ 4 | /targets/ 5 | /target 6 | /classes 7 | /checkouts 8 | *.jar 9 | *.class 10 | *.dll 11 | *.pdb 12 | *.exe 13 | .lein-deps-sum 14 | .lein-failures 15 | .lein-plugins 16 | .vs 17 | 18 | .cpcache/ 19 | 20 | #Visual Studio artifacts 21 | bin 22 | obj 23 | *.user 24 | *.suo 25 | *.nupkg -------------------------------------------------------------------------------- /deps.edn: -------------------------------------------------------------------------------- 1 | {:paths ["src/main/clojure"] 2 | :deps 3 | {io.github.clojure/clr.spec.alpha {:git/tag "v0.5.238" :git/sha "1cfe4af"}} 4 | 5 | :aliases 6 | {:test 7 | {:extra-paths ["src/test/clojure"] 8 | :extra-deps {io.github.dmiller/test-runner {:git/tag "v0.5.2clr" :git/sha "d6793a2"}} 9 | ;; :main-opts ["-m" "cognitect.test-runner" "-d" "src/test/clojure"] 10 | :exec-fn cognitect.test-runner.api/test 11 | :exec-args {:dirs ["src/test/clojure"]}}}} 12 | -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | This is a [Clojure contrib] project. 2 | 3 | Under the Clojure contrib [guidelines], this project cannot accept 4 | pull requests. All patches must be submitted via [JIRA]. 5 | 6 | See [Contributing] and the [FAQ] on the Clojure development [wiki] for 7 | more information on how to contribute. 8 | 9 | [Clojure contrib]: http://dev.clojure.org/display/doc/Clojure+Contrib 10 | [Contributing]: http://dev.clojure.org/display/community/Contributing 11 | [FAQ]: http://dev.clojure.org/display/community/Contributing+FAQ 12 | [JIRA]: http://dev.clojure.org/jira/browse/CCACHE 13 | [guidelines]: http://dev.clojure.org/display/community/Guidelines+for+Clojure+Contrib+committers 14 | [wiki]: http://dev.clojure.org/ -------------------------------------------------------------------------------- /src/main/dotnet/packager/clojure.core.specs.alpha.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | netstandard2.0;netstandard2.1 4 | Library 5 | false 6 | true 7 | 8 | 9 | clojure.core.specs.alpha 10 | clojure.core.specs 11 | clojure.core.specs.alpha 12 | clojure.core.specs.alpha 13 | clojure.core.specs.alpha 14 | ClojureCLR contributors 15 | Port of clojure.core.specs.alpha to ClojureCLR 16 | Copyright © Rich Hickey, 2024 17 | EPL-1.0 18 | https://github.com/clojure/clr.core.specs.alpha 19 | ClojureCLR contributors 20 | Clojure;ClojureCLR 21 | 0.4.74 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # clr.core.specs.alpha 2 | 3 | A port of [clojure/core.specs.alpha](https://github.com/clojure/core.specs.alpha) library to ClojureCLR. 4 | 5 | From the parent's README: 6 | 7 | > core.specs.alpha is a Clojure library containining specs to describe Clojure core macros and functions. 8 | 9 | > Clojure 1.9 & following depend on this library and provides it to users of Clojure. Thus, the recommended way to use this library is to add a dependency on the latest version of Clojure 1.9, rather than including it directly. In some cases, this library may release more frequently than Clojure. In those cases, you can explictly include the latest version of this library with the dependency info below. 10 | 11 | # Releases 12 | 13 | Latest stable release: 0.4.74 14 | 15 | [deps.edn](https://clojure.org/guides/deps_edn) dependency information: 16 | 17 | io.github.clojure/clr.core.specs.alpha {:git/tag "v0.4.74" :git/sha "e53b34f"} 18 | 19 | Nuget reference: 20 | 21 | PM> Install-Package clojure.core.specs.alpha -Version 0.4.74 22 | 23 | 24 | [Leiningen/Clojars](https://github.com/technomancy/leiningen) dependency information: 25 | 26 | [org.clojure.clr/core.specs.alpha "0.4.74"] 27 | 28 | 29 | 30 | # Copyright and License # 31 | 32 | > Copyright (c) Rich Hickey, and contributors, 2017. All rights reserved. The use and distribution terms for this software are covered by the Eclipse Public License 1.0 (http://opensource.org/licenses/eclipse-1.0.php) which can be found in the file epl-v10.html at the root of this distribution. By using this software in any fashion, you are agreeing to be bound bythe terms of this license. You must not remove this notice, or any other, from this software. 33 | -------------------------------------------------------------------------------- /project.clj: -------------------------------------------------------------------------------- 1 | (defproject org.clojure.clr/core.specs.alpha "0.4.74" 2 | :description "Port of clojure.org/core.specs.alpha to ClojureCLR" 3 | :url "https://github.com/clojure/clr.core.specs.alpha" 4 | :license {:name "Eclipse Public License" 5 | :url "http://www.eclipse.org/legal/epl-v10.html"} 6 | :dependencies [[org.clojure.clr/spec.alpha "0.5.238"]] 7 | :deploy-repositories [["clojars" {:url "https://clojars.org/repo/" 8 | :sign-releases false}]] 9 | :warn-on-reflection true 10 | :source-paths ["src/main/clojure"] 11 | :test-paths ["src/test/clojure"] 12 | :min-lein-version "2.0.0" 13 | :plugins [[lein-clr "0.2.1"]] 14 | :clr {:cmd-templates {:clj-exe [[?PATH "mono"] [CLJCLR19_40 %1]] 15 | :clj-dep [[?PATH "mono"] ["target/clr/clj/Debug 4.0" %1]] 16 | :clj-url "http://sourceforge.net/projects/clojureclr/files/clojure-clr-1.4.1-Debug-4.0.zip/download" 17 | :clj-zip "clojure-clr-1.4.1-Debug-4.0.zip" 18 | :curl ["curl" "--insecure" "-f" "-L" "-o" %1 %2] 19 | :nuget-ver [[?PATH "mono"] [*PATH "nuget.exe"] "install" %1 "-Version" %2] 20 | :nuget-any [[?PATH "mono"] [*PATH "nuget.exe"] "install" %1] 21 | :unzip ["unzip" "-d" %1 %2] 22 | :wget ["wget" "--no-check-certificate" "--no-clobber" "-O" %1 %2]} 23 | ;; for automatic download/unzip of ClojureCLR, 24 | ;; 1. make sure you have curl or wget installed and on PATH, 25 | ;; 2. uncomment deps in :deps-cmds, and 26 | ;; 3. use :clj-dep instead of :clj-exe in :main-cmd and :compile-cmd 27 | :deps-cmds [; [:wget :clj-zip :clj-url] ; edit to use :curl instead of :wget 28 | ; [:unzip "../clj" :clj-zip] 29 | ] 30 | :main-cmd [:clj-exe "Clojure.Main.exe"] 31 | :compile-cmd [:clj-exe "Clojure.Compile.exe"]}) 32 | -------------------------------------------------------------------------------- /src/main/clojure/clojure/core/specs/alpha.clj: -------------------------------------------------------------------------------- 1 | (ns clojure.core.specs.alpha 2 | (:require [clojure.spec.alpha :as s])) 3 | 4 | ;;;; destructure 5 | 6 | (s/def ::local-name (s/and simple-symbol? #(not= '& %))) 7 | 8 | (s/def ::binding-form 9 | (s/or :local-symbol ::local-name 10 | :seq-destructure ::seq-binding-form 11 | :map-destructure ::map-binding-form)) 12 | 13 | ;; sequential destructuring 14 | 15 | (s/def ::seq-binding-form 16 | (s/and vector? 17 | (s/cat :forms (s/* ::binding-form) 18 | :rest-forms (s/? (s/cat :ampersand #{'&} :form ::binding-form)) 19 | :as-form (s/? (s/cat :as #{:as} :as-sym ::local-name))))) 20 | 21 | ;; map destructuring 22 | 23 | (s/def ::keys (s/coll-of ident? :kind vector?)) 24 | (s/def ::syms (s/coll-of symbol? :kind vector?)) 25 | (s/def ::strs (s/coll-of simple-symbol? :kind vector?)) 26 | (s/def ::or (s/map-of simple-symbol? any?)) 27 | (s/def ::as ::local-name) 28 | 29 | (s/def ::map-special-binding 30 | (s/keys :opt-un [::as ::or ::keys ::syms ::strs])) 31 | 32 | (s/def ::map-binding (s/tuple ::binding-form any?)) 33 | 34 | (s/def ::ns-keys 35 | (s/tuple 36 | (s/and qualified-keyword? #(-> % name #{"keys" "syms"})) 37 | (s/coll-of simple-symbol? :kind vector?))) 38 | 39 | (s/def ::map-bindings 40 | (s/every (s/or :map-binding ::map-binding 41 | :qualified-keys-or-syms ::ns-keys 42 | :special-binding (s/tuple #{:as :or :keys :syms :strs} any?)) :kind map?)) 43 | 44 | (s/def ::map-binding-form (s/merge ::map-bindings ::map-special-binding)) 45 | 46 | ;; bindings 47 | 48 | (defn even-number-of-forms? 49 | "Returns true if there are an even number of forms in a binding vector" 50 | [forms] 51 | (even? (count forms))) 52 | 53 | (s/def ::binding (s/cat :form ::binding-form :init-expr any?)) 54 | (s/def ::bindings (s/and vector? even-number-of-forms? (s/* ::binding))) 55 | 56 | ;; let, if-let, when-let 57 | 58 | (s/fdef clojure.core/let 59 | :args (s/cat :bindings ::bindings 60 | :body (s/* any?))) 61 | 62 | (s/fdef clojure.core/if-let 63 | :args (s/cat :bindings (s/and vector? ::binding) 64 | :then any? 65 | :else (s/? any?))) 66 | 67 | (s/fdef clojure.core/when-let 68 | :args (s/cat :bindings (s/and vector? ::binding) 69 | :body (s/* any?))) 70 | 71 | ;; defn, defn-, fn 72 | 73 | (s/def ::param-list 74 | (s/and 75 | vector? 76 | (s/cat :params (s/* ::binding-form) 77 | :var-params (s/? (s/cat :ampersand #{'&} :var-form ::binding-form))))) 78 | 79 | (s/def ::params+body 80 | (s/cat :params ::param-list 81 | :body (s/alt :prepost+body (s/cat :prepost map? 82 | :body (s/+ any?)) 83 | :body (s/* any?)))) 84 | 85 | (s/def ::defn-args 86 | (s/cat :fn-name simple-symbol? 87 | :docstring (s/? string?) 88 | :meta (s/? map?) 89 | :fn-tail (s/alt :arity-1 ::params+body 90 | :arity-n (s/cat :bodies (s/+ (s/spec ::params+body)) 91 | :attr-map (s/? map?))))) 92 | 93 | (s/fdef clojure.core/defn 94 | :args ::defn-args 95 | :ret any?) 96 | 97 | (s/fdef clojure.core/defn- 98 | :args ::defn-args 99 | :ret any?) 100 | 101 | (s/fdef clojure.core/fn 102 | :args (s/cat :fn-name (s/? simple-symbol?) 103 | :fn-tail (s/alt :arity-1 ::params+body 104 | :arity-n (s/+ (s/spec ::params+body)))) 105 | :ret any?) 106 | 107 | ;;;; ns 108 | 109 | (s/def ::exclude (s/coll-of simple-symbol?)) 110 | (s/def ::only (s/coll-of simple-symbol?)) 111 | (s/def ::rename (s/map-of simple-symbol? simple-symbol?)) 112 | (s/def ::filters (s/keys* :opt-un [::exclude ::only ::rename])) 113 | 114 | (s/def ::ns-refer-clojure 115 | (s/spec (s/cat :clause #{:refer-clojure} 116 | :refer-filters ::filters))) 117 | 118 | (s/def ::refer (s/or :all #{:all} 119 | :syms (s/coll-of simple-symbol?))) 120 | 121 | (s/def ::prefix-list 122 | (s/spec 123 | (s/cat :prefix simple-symbol? 124 | :libspecs (s/+ ::libspec)))) 125 | 126 | (s/def ::as-alias simple-symbol?) 127 | 128 | (s/def ::libspec 129 | (s/alt :lib simple-symbol? 130 | :lib+opts (s/spec (s/cat :lib simple-symbol? 131 | :options (s/keys* :opt-un [::as ::refer ::as-alias]))))) 132 | 133 | (s/def ::ns-require 134 | (s/spec (s/cat :clause #{:require} 135 | :body (s/+ (s/alt :libspec ::libspec 136 | :prefix-list ::prefix-list 137 | :flag #{:reload :reload-all :verbose}))))) 138 | 139 | (s/def ::package-list 140 | (s/spec 141 | (s/cat :package simple-symbol? 142 | :classes (s/+ simple-symbol?)))) 143 | 144 | (s/def ::import-list 145 | (s/* (s/alt :class simple-symbol? 146 | :package-list ::package-list))) 147 | 148 | (s/def ::ns-import 149 | (s/spec 150 | (s/cat :clause #{:import} 151 | :classes ::import-list))) 152 | 153 | (s/def ::ns-refer 154 | (s/spec (s/cat :clause #{:refer} 155 | :lib simple-symbol? 156 | :refer-filters ::filters))) 157 | 158 | ;; same as ::prefix-list, but with ::use-libspec instead 159 | (s/def ::use-prefix-list 160 | (s/spec 161 | (s/cat :prefix simple-symbol? 162 | :libspecs (s/+ ::use-libspec)))) 163 | 164 | ;; same as ::libspec, but also supports the ::filters options in the libspec 165 | (s/def ::use-libspec 166 | (s/alt :lib simple-symbol? 167 | :lib+opts (s/spec (s/cat :lib simple-symbol? 168 | :options (s/keys* :opt-un [::as ::refer ::exclude ::only ::rename]))))) 169 | 170 | (s/def ::ns-use 171 | (s/spec (s/cat :clause #{:use} 172 | :libs (s/+ (s/alt :libspec ::use-libspec 173 | :prefix-list ::use-prefix-list 174 | :flag #{:reload :reload-all :verbose}))))) 175 | 176 | (s/def ::ns-load 177 | (s/spec (s/cat :clause #{:load} 178 | :libs (s/* string?)))) 179 | 180 | (s/def ::name simple-symbol?) 181 | (s/def ::extends simple-symbol?) 182 | (s/def ::implements (s/coll-of simple-symbol? :kind vector?)) 183 | (s/def ::init symbol?) 184 | (s/def ::class-ident (s/or :class simple-symbol? :class-name string?)) 185 | (s/def ::signature (s/coll-of ::class-ident :kind vector?)) 186 | (s/def ::constructors (s/map-of ::signature ::signature)) 187 | (s/def ::post-init symbol?) 188 | (s/def ::method (s/and vector? 189 | (s/cat :method-name simple-symbol? 190 | :param-types ::signature 191 | :return-type ::class-ident))) 192 | (s/def ::methods (s/coll-of ::method :kind vector?)) 193 | (s/def ::main boolean?) 194 | (s/def ::factory simple-symbol?) 195 | (s/def ::state simple-symbol?) 196 | (s/def ::get simple-symbol?) 197 | (s/def ::set simple-symbol?) 198 | (s/def ::expose (s/keys :opt-un [::get ::set])) 199 | (s/def ::exposes (s/map-of simple-symbol? ::expose)) 200 | (s/def ::prefix string?) 201 | (s/def ::impl-ns simple-symbol?) 202 | (s/def ::load-impl-ns boolean?) 203 | 204 | (s/def ::ns-gen-class 205 | (s/spec (s/cat :clause #{:gen-class} 206 | :options (s/keys* :opt-un [::name ::extends ::implements 207 | ::init ::constructors ::post-init 208 | ::methods ::main ::factory ::state 209 | ::exposes ::prefix ::impl-ns ::load-impl-ns])))) 210 | 211 | (s/def ::ns-clauses 212 | (s/* (s/alt :refer-clojure ::ns-refer-clojure 213 | :require ::ns-require 214 | :import ::ns-import 215 | :use ::ns-use 216 | :refer ::ns-refer 217 | :load ::ns-load 218 | :gen-class ::ns-gen-class))) 219 | 220 | (s/def ::ns-form 221 | (s/cat :ns-name simple-symbol? 222 | :docstring (s/? string?) 223 | :attr-map (s/? map?) 224 | :ns-clauses ::ns-clauses)) 225 | 226 | (s/fdef clojure.core/ns 227 | :args ::ns-form) 228 | 229 | (defmacro ^:private quotable 230 | "Returns a spec that accepts both the spec and a (quote ...) form of the spec" 231 | [spec] 232 | `(s/or :spec ~spec :quoted-spec (s/cat :quote #{'quote} :spec ~spec))) 233 | 234 | (s/def ::quotable-import-list 235 | (s/* (s/alt :class (quotable simple-symbol?) 236 | :package-list (quotable ::package-list)))) 237 | 238 | (s/fdef clojure.core/import 239 | :args ::quotable-import-list) 240 | 241 | (s/fdef clojure.core/refer-clojure 242 | :args (s/* (s/alt 243 | :exclude (s/cat :op (quotable #{:exclude}) :arg (quotable ::exclude)) 244 | :only (s/cat :op (quotable #{:only}) :arg (quotable ::only)) 245 | :rename (s/cat :op (quotable #{:rename}) :arg (quotable ::rename))))) -------------------------------------------------------------------------------- /evl-v10.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Eclipse Public License - Version 1.0 8 | 25 | 26 | 27 | 28 | 29 | 30 |

Eclipse Public License - v 1.0

31 | 32 |

THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE 33 | PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR 34 | DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS 35 | AGREEMENT.

36 | 37 |

1. DEFINITIONS

38 | 39 |

"Contribution" means:

40 | 41 |

a) in the case of the initial Contributor, the initial 42 | code and documentation distributed under this Agreement, and

43 |

b) in the case of each subsequent Contributor:

44 |

i) changes to the Program, and

45 |

ii) additions to the Program;

46 |

where such changes and/or additions to the Program 47 | originate from and are distributed by that particular Contributor. A 48 | Contribution 'originates' from a Contributor if it was added to the 49 | Program by such Contributor itself or anyone acting on such 50 | Contributor's behalf. Contributions do not include additions to the 51 | Program which: (i) are separate modules of software distributed in 52 | conjunction with the Program under their own license agreement, and (ii) 53 | are not derivative works of the Program.

54 | 55 |

"Contributor" means any person or entity that distributes 56 | the Program.

57 | 58 |

"Licensed Patents" mean patent claims licensable by a 59 | Contributor which are necessarily infringed by the use or sale of its 60 | Contribution alone or when combined with the Program.

61 | 62 |

"Program" means the Contributions distributed in accordance 63 | with this Agreement.

64 | 65 |

"Recipient" means anyone who receives the Program under 66 | this Agreement, including all Contributors.

67 | 68 |

2. GRANT OF RIGHTS

69 | 70 |

a) Subject to the terms of this Agreement, each 71 | Contributor hereby grants Recipient a non-exclusive, worldwide, 72 | royalty-free copyright license to reproduce, prepare derivative works 73 | of, publicly display, publicly perform, distribute and sublicense the 74 | Contribution of such Contributor, if any, and such derivative works, in 75 | source code and object code form.

76 | 77 |

b) Subject to the terms of this Agreement, each 78 | Contributor hereby grants Recipient a non-exclusive, worldwide, 79 | royalty-free patent license under Licensed Patents to make, use, sell, 80 | offer to sell, import and otherwise transfer the Contribution of such 81 | Contributor, if any, in source code and object code form. This patent 82 | license shall apply to the combination of the Contribution and the 83 | Program if, at the time the Contribution is added by the Contributor, 84 | such addition of the Contribution causes such combination to be covered 85 | by the Licensed Patents. The patent license shall not apply to any other 86 | combinations which include the Contribution. No hardware per se is 87 | licensed hereunder.

88 | 89 |

c) Recipient understands that although each Contributor 90 | grants the licenses to its Contributions set forth herein, no assurances 91 | are provided by any Contributor that the Program does not infringe the 92 | patent or other intellectual property rights of any other entity. Each 93 | Contributor disclaims any liability to Recipient for claims brought by 94 | any other entity based on infringement of intellectual property rights 95 | or otherwise. As a condition to exercising the rights and licenses 96 | granted hereunder, each Recipient hereby assumes sole responsibility to 97 | secure any other intellectual property rights needed, if any. For 98 | example, if a third party patent license is required to allow Recipient 99 | to distribute the Program, it is Recipient's responsibility to acquire 100 | that license before distributing the Program.

101 | 102 |

d) Each Contributor represents that to its knowledge it 103 | has sufficient copyright rights in its Contribution, if any, to grant 104 | the copyright license set forth in this Agreement.

105 | 106 |

3. REQUIREMENTS

107 | 108 |

A Contributor may choose to distribute the Program in object code 109 | form under its own license agreement, provided that:

110 | 111 |

a) it complies with the terms and conditions of this 112 | Agreement; and

113 | 114 |

b) its license agreement:

115 | 116 |

i) effectively disclaims on behalf of all Contributors 117 | all warranties and conditions, express and implied, including warranties 118 | or conditions of title and non-infringement, and implied warranties or 119 | conditions of merchantability and fitness for a particular purpose;

120 | 121 |

ii) effectively excludes on behalf of all Contributors 122 | all liability for damages, including direct, indirect, special, 123 | incidental and consequential damages, such as lost profits;

124 | 125 |

iii) states that any provisions which differ from this 126 | Agreement are offered by that Contributor alone and not by any other 127 | party; and

128 | 129 |

iv) states that source code for the Program is available 130 | from such Contributor, and informs licensees how to obtain it in a 131 | reasonable manner on or through a medium customarily used for software 132 | exchange.

133 | 134 |

When the Program is made available in source code form:

135 | 136 |

a) it must be made available under this Agreement; and

137 | 138 |

b) a copy of this Agreement must be included with each 139 | copy of the Program.

140 | 141 |

Contributors may not remove or alter any copyright notices contained 142 | within the Program.

143 | 144 |

Each Contributor must identify itself as the originator of its 145 | Contribution, if any, in a manner that reasonably allows subsequent 146 | Recipients to identify the originator of the Contribution.

147 | 148 |

4. COMMERCIAL DISTRIBUTION

149 | 150 |

Commercial distributors of software may accept certain 151 | responsibilities with respect to end users, business partners and the 152 | like. While this license is intended to facilitate the commercial use of 153 | the Program, the Contributor who includes the Program in a commercial 154 | product offering should do so in a manner which does not create 155 | potential liability for other Contributors. Therefore, if a Contributor 156 | includes the Program in a commercial product offering, such Contributor 157 | ("Commercial Contributor") hereby agrees to defend and 158 | indemnify every other Contributor ("Indemnified Contributor") 159 | against any losses, damages and costs (collectively "Losses") 160 | arising from claims, lawsuits and other legal actions brought by a third 161 | party against the Indemnified Contributor to the extent caused by the 162 | acts or omissions of such Commercial Contributor in connection with its 163 | distribution of the Program in a commercial product offering. The 164 | obligations in this section do not apply to any claims or Losses 165 | relating to any actual or alleged intellectual property infringement. In 166 | order to qualify, an Indemnified Contributor must: a) promptly notify 167 | the Commercial Contributor in writing of such claim, and b) allow the 168 | Commercial Contributor to control, and cooperate with the Commercial 169 | Contributor in, the defense and any related settlement negotiations. The 170 | Indemnified Contributor may participate in any such claim at its own 171 | expense.

172 | 173 |

For example, a Contributor might include the Program in a commercial 174 | product offering, Product X. That Contributor is then a Commercial 175 | Contributor. If that Commercial Contributor then makes performance 176 | claims, or offers warranties related to Product X, those performance 177 | claims and warranties are such Commercial Contributor's responsibility 178 | alone. Under this section, the Commercial Contributor would have to 179 | defend claims against the other Contributors related to those 180 | performance claims and warranties, and if a court requires any other 181 | Contributor to pay any damages as a result, the Commercial Contributor 182 | must pay those damages.

183 | 184 |

5. NO WARRANTY

185 | 186 |

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS 187 | PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS 188 | OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, 189 | ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY 190 | OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely 191 | responsible for determining the appropriateness of using and 192 | distributing the Program and assumes all risks associated with its 193 | exercise of rights under this Agreement , including but not limited to 194 | the risks and costs of program errors, compliance with applicable laws, 195 | damage to or loss of data, programs or equipment, and unavailability or 196 | interruption of operations.

197 | 198 |

6. DISCLAIMER OF LIABILITY

199 | 200 |

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT 201 | NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, 202 | INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING 203 | WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF 204 | LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING 205 | NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR 206 | DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED 207 | HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

208 | 209 |

7. GENERAL

210 | 211 |

If any provision of this Agreement is invalid or unenforceable under 212 | applicable law, it shall not affect the validity or enforceability of 213 | the remainder of the terms of this Agreement, and without further action 214 | by the parties hereto, such provision shall be reformed to the minimum 215 | extent necessary to make such provision valid and enforceable.

216 | 217 |

If Recipient institutes patent litigation against any entity 218 | (including a cross-claim or counterclaim in a lawsuit) alleging that the 219 | Program itself (excluding combinations of the Program with other 220 | software or hardware) infringes such Recipient's patent(s), then such 221 | Recipient's rights granted under Section 2(b) shall terminate as of the 222 | date such litigation is filed.

223 | 224 |

All Recipient's rights under this Agreement shall terminate if it 225 | fails to comply with any of the material terms or conditions of this 226 | Agreement and does not cure such failure in a reasonable period of time 227 | after becoming aware of such noncompliance. If all Recipient's rights 228 | under this Agreement terminate, Recipient agrees to cease use and 229 | distribution of the Program as soon as reasonably practicable. However, 230 | Recipient's obligations under this Agreement and any licenses granted by 231 | Recipient relating to the Program shall continue and survive.

232 | 233 |

Everyone is permitted to copy and distribute copies of this 234 | Agreement, but in order to avoid inconsistency the Agreement is 235 | copyrighted and may only be modified in the following manner. The 236 | Agreement Steward reserves the right to publish new versions (including 237 | revisions) of this Agreement from time to time. No one other than the 238 | Agreement Steward has the right to modify this Agreement. The Eclipse 239 | Foundation is the initial Agreement Steward. The Eclipse Foundation may 240 | assign the responsibility to serve as the Agreement Steward to a 241 | suitable separate entity. Each new version of the Agreement will be 242 | given a distinguishing version number. The Program (including 243 | Contributions) may always be distributed subject to the version of the 244 | Agreement under which it was received. In addition, after a new version 245 | of the Agreement is published, Contributor may elect to distribute the 246 | Program (including its Contributions) under the new version. Except as 247 | expressly stated in Sections 2(a) and 2(b) above, Recipient receives no 248 | rights or licenses to the intellectual property of any Contributor under 249 | this Agreement, whether expressly, by implication, estoppel or 250 | otherwise. All rights in the Program not expressly granted under this 251 | Agreement are reserved.

252 | 253 |

This Agreement is governed by the laws of the State of New York and 254 | the intellectual property laws of the United States of America. No party 255 | to this Agreement will bring a legal action under this Agreement more 256 | than one year after the cause of action arose. Each party waives its 257 | rights to a jury trial in any resulting litigation.

258 | 259 | 260 | 261 | --------------------------------------------------------------------------------