diff --git a/core/builtins/src/jet/Annotations.kt b/core/builtins/src/jet/Annotations.kt index c8e7ca92fe5..4f00aebee54 100644 --- a/core/builtins/src/jet/Annotations.kt +++ b/core/builtins/src/jet/Annotations.kt @@ -1,3 +1,19 @@ +/* + * Copyright 2010-2014 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package jet public annotation class atomic diff --git a/core/builtins/src/jet/ExtensionFunctions.kt b/core/builtins/src/jet/ExtensionFunctions.kt index 87c6fa2ddc4..86371d8348f 100644 --- a/core/builtins/src/jet/ExtensionFunctions.kt +++ b/core/builtins/src/jet/ExtensionFunctions.kt @@ -1,4 +1,20 @@ -// Generated by org.jetbrains.jet.generators.runtime.functions.GenerateFunctions +/* + * Copyright 2010-2014 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// Auto-generated file. DO NOT EDIT! package jet diff --git a/core/builtins/src/jet/Functions.kt b/core/builtins/src/jet/Functions.kt index c672bb046b6..717299c93bb 100644 --- a/core/builtins/src/jet/Functions.kt +++ b/core/builtins/src/jet/Functions.kt @@ -1,4 +1,20 @@ -// Generated by org.jetbrains.jet.generators.runtime.functions.GenerateFunctions +/* + * Copyright 2010-2014 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// Auto-generated file. DO NOT EDIT! package jet diff --git a/core/builtins/src/jet/Inline.kt b/core/builtins/src/jet/Inline.kt index 919f7f02223..2dff4f2ead1 100644 --- a/core/builtins/src/jet/Inline.kt +++ b/core/builtins/src/jet/Inline.kt @@ -1,3 +1,19 @@ +/* + * Copyright 2010-2014 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package jet public annotation class noinline diff --git a/core/builtins/src/jet/Iterators.kt b/core/builtins/src/jet/Iterators.kt index 692c0ae7d53..dd0548af2cc 100644 --- a/core/builtins/src/jet/Iterators.kt +++ b/core/builtins/src/jet/Iterators.kt @@ -1,4 +1,20 @@ -// Generated by org.jetbrains.jet.generators.runtime.iterators.GenerateIterators +/* + * Copyright 2010-2014 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// Auto-generated file. DO NOT EDIT! package jet diff --git a/core/builtins/src/jet/KExtensionFunctions.kt b/core/builtins/src/jet/KExtensionFunctions.kt index 6aa62fbfb62..8d4af5b625e 100644 --- a/core/builtins/src/jet/KExtensionFunctions.kt +++ b/core/builtins/src/jet/KExtensionFunctions.kt @@ -1,4 +1,20 @@ -// Generated by org.jetbrains.jet.generators.runtime.functions.GenerateFunctions +/* + * Copyright 2010-2014 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// Auto-generated file. DO NOT EDIT! package jet diff --git a/core/builtins/src/jet/KFunctions.kt b/core/builtins/src/jet/KFunctions.kt index 0f5c7410391..3b84db9aa5a 100644 --- a/core/builtins/src/jet/KFunctions.kt +++ b/core/builtins/src/jet/KFunctions.kt @@ -1,4 +1,20 @@ -// Generated by org.jetbrains.jet.generators.runtime.functions.GenerateFunctions +/* + * Copyright 2010-2014 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// Auto-generated file. DO NOT EDIT! package jet diff --git a/core/builtins/src/jet/KMemberFunctions.kt b/core/builtins/src/jet/KMemberFunctions.kt index 91577ad6544..3bf1436242c 100644 --- a/core/builtins/src/jet/KMemberFunctions.kt +++ b/core/builtins/src/jet/KMemberFunctions.kt @@ -1,4 +1,20 @@ -// Generated by org.jetbrains.jet.generators.runtime.functions.GenerateFunctions +/* + * Copyright 2010-2014 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// Auto-generated file. DO NOT EDIT! package jet diff --git a/core/builtins/src/jet/ProgressionIterators.kt b/core/builtins/src/jet/ProgressionIterators.kt index 4ac3bcecedb..c1fe7ac41b4 100644 --- a/core/builtins/src/jet/ProgressionIterators.kt +++ b/core/builtins/src/jet/ProgressionIterators.kt @@ -1,4 +1,20 @@ -// Generated by org.jetbrains.jet.generators.runtime.progressionIterators.GenerateProgressionIterators +/* + * Copyright 2010-2014 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// Auto-generated file. DO NOT EDIT! package jet diff --git a/core/builtins/src/jet/Progressions.kt b/core/builtins/src/jet/Progressions.kt index 7fc37b01ede..e8a5d79a4e2 100644 --- a/core/builtins/src/jet/Progressions.kt +++ b/core/builtins/src/jet/Progressions.kt @@ -1,4 +1,20 @@ -// Generated by org.jetbrains.jet.generators.runtime.progressions.GenerateProgressions +/* + * Copyright 2010-2014 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// Auto-generated file. DO NOT EDIT! package jet diff --git a/core/builtins/src/jet/PropertyMetadata.kt b/core/builtins/src/jet/PropertyMetadata.kt index 80a07680d49..7b91d02b1eb 100644 --- a/core/builtins/src/jet/PropertyMetadata.kt +++ b/core/builtins/src/jet/PropertyMetadata.kt @@ -1,3 +1,19 @@ +/* + * Copyright 2010-2014 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package jet public trait PropertyMetadata { diff --git a/core/builtins/src/jet/Ranges.kt b/core/builtins/src/jet/Ranges.kt index 3beb4bed956..dad0dd7d252 100644 --- a/core/builtins/src/jet/Ranges.kt +++ b/core/builtins/src/jet/Ranges.kt @@ -1,4 +1,20 @@ -// Generated by org.jetbrains.jet.generators.runtime.ranges.GenerateRanges +/* + * Copyright 2010-2014 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// Auto-generated file. DO NOT EDIT! package jet diff --git a/core/runtime.jvm/src/jet/ExtensionFunctionsImpl.kt b/core/runtime.jvm/src/jet/ExtensionFunctionsImpl.kt index d584c3fc5d1..42b8cdb5dd1 100644 --- a/core/runtime.jvm/src/jet/ExtensionFunctionsImpl.kt +++ b/core/runtime.jvm/src/jet/ExtensionFunctionsImpl.kt @@ -1,4 +1,20 @@ -// Generated by org.jetbrains.jet.generators.runtime.functions.GenerateFunctions +/* + * Copyright 2010-2014 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// Auto-generated file. DO NOT EDIT! package jet diff --git a/core/runtime.jvm/src/jet/FunctionsImpl.kt b/core/runtime.jvm/src/jet/FunctionsImpl.kt index a3ab1067db9..c568869c254 100644 --- a/core/runtime.jvm/src/jet/FunctionsImpl.kt +++ b/core/runtime.jvm/src/jet/FunctionsImpl.kt @@ -1,4 +1,20 @@ -// Generated by org.jetbrains.jet.generators.runtime.functions.GenerateFunctions +/* + * Copyright 2010-2014 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// Auto-generated file. DO NOT EDIT! package jet diff --git a/core/runtime.jvm/src/jet/KExtensionFunctionsImpl.kt b/core/runtime.jvm/src/jet/KExtensionFunctionsImpl.kt index ab63d11da03..f207333a90a 100644 --- a/core/runtime.jvm/src/jet/KExtensionFunctionsImpl.kt +++ b/core/runtime.jvm/src/jet/KExtensionFunctionsImpl.kt @@ -1,4 +1,20 @@ -// Generated by org.jetbrains.jet.generators.runtime.functions.GenerateFunctions +/* + * Copyright 2010-2014 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// Auto-generated file. DO NOT EDIT! package jet diff --git a/core/runtime.jvm/src/jet/KFunctionsImpl.kt b/core/runtime.jvm/src/jet/KFunctionsImpl.kt index 070f9ae7f17..15bb5e7ea8f 100644 --- a/core/runtime.jvm/src/jet/KFunctionsImpl.kt +++ b/core/runtime.jvm/src/jet/KFunctionsImpl.kt @@ -1,4 +1,20 @@ -// Generated by org.jetbrains.jet.generators.runtime.functions.GenerateFunctions +/* + * Copyright 2010-2014 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// Auto-generated file. DO NOT EDIT! package jet diff --git a/core/runtime.jvm/src/jet/KMemberFunctionsImpl.kt b/core/runtime.jvm/src/jet/KMemberFunctionsImpl.kt index 3c108a46064..814f09a8194 100644 --- a/core/runtime.jvm/src/jet/KMemberFunctionsImpl.kt +++ b/core/runtime.jvm/src/jet/KMemberFunctionsImpl.kt @@ -1,4 +1,20 @@ -// Generated by org.jetbrains.jet.generators.runtime.functions.GenerateFunctions +/* + * Copyright 2010-2014 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// Auto-generated file. DO NOT EDIT! package jet diff --git a/generators/src/org/jetbrains/jet/generators/runtime/common.kt b/generators/src/org/jetbrains/jet/generators/runtime/common.kt index c02af9821a7..4367b8e90d5 100644 --- a/generators/src/org/jetbrains/jet/generators/runtime/common.kt +++ b/generators/src/org/jetbrains/jet/generators/runtime/common.kt @@ -73,11 +73,14 @@ fun generateBuiltInFile(name: String, generate: (PrintWriter) -> Unit) { } fun generateRuntimeJvmFile(name: String, generate: (PrintWriter) -> Unit) { - generateFile(BUILT_INS_DIR, name, generate) + generateFile(RUNTIME_JVM_DIR, name, generate) } -fun generatedBy(out: PrintWriter, generator: String) { - out.println("// Generated by $generator") +fun generatedBy(out: PrintWriter) { + out.println(File("injector-generator/copyright.txt").readText()) + // Don't include generator class name in the message: these are built-in sources, + // and we don't want to scare users with any internal information about our project + out.println("// Auto-generated file. DO NOT EDIT!") out.println() out.println("package jet") out.println() diff --git a/generators/src/org/jetbrains/jet/generators/runtime/functions.kt b/generators/src/org/jetbrains/jet/generators/runtime/functions.kt index b0e382cc01c..89798c4928f 100644 --- a/generators/src/org/jetbrains/jet/generators/runtime/functions.kt +++ b/generators/src/org/jetbrains/jet/generators/runtime/functions.kt @@ -42,7 +42,7 @@ enum class FunctionKind( class GenerateFunctions(val out: PrintWriter, val kind: FunctionKind) { fun generateFunctionClasses() { - generatedBy(out, javaClass.getName()) + generatedBy(out) for (i in 0..MAX_PARAM_COUNT) { out.print("public trait " + kind.getClassName(i)) generateTypeParameters(i, true) @@ -52,7 +52,7 @@ class GenerateFunctions(val out: PrintWriter, val kind: FunctionKind) { } fun generateFunctionImplClasses() { - generatedBy(out, javaClass.getName()) + generatedBy(out) for (i in 0..MAX_PARAM_COUNT) { out.print("public abstract class " + kind.getImplClassName(i)) generateTypeParameters(i, true) diff --git a/generators/src/org/jetbrains/jet/generators/runtime/iterators.kt b/generators/src/org/jetbrains/jet/generators/runtime/iterators.kt index 8e04fce622a..6bb3f5e14da 100644 --- a/generators/src/org/jetbrains/jet/generators/runtime/iterators.kt +++ b/generators/src/org/jetbrains/jet/generators/runtime/iterators.kt @@ -34,7 +34,7 @@ enum class IteratorKind { class GenerateIterators(val out: PrintWriter) { fun generate() { - generatedBy(out, javaClass.getName()) + generatedBy(out) for (kind in IteratorKind.values()) { val s = kind.capitalized out.println("public abstract class ${s}Iterator : Iterator<$s> {") diff --git a/generators/src/org/jetbrains/jet/generators/runtime/progressionIterators.kt b/generators/src/org/jetbrains/jet/generators/runtime/progressionIterators.kt index 1d65d280cce..3a20fbf4813 100644 --- a/generators/src/org/jetbrains/jet/generators/runtime/progressionIterators.kt +++ b/generators/src/org/jetbrains/jet/generators/runtime/progressionIterators.kt @@ -68,7 +68,7 @@ fun floatingPointProgressionIterator(kind: ProgressionKind): String { class GenerateProgressionIterators(val out: PrintWriter) { fun generate() { - generatedBy(out, javaClass.getName()) + generatedBy(out) out.println("import jet.runtime.ProgressionUtil") out.println() for (kind in ProgressionKind.values()) { diff --git a/generators/src/org/jetbrains/jet/generators/runtime/progressions.kt b/generators/src/org/jetbrains/jet/generators/runtime/progressions.kt index afb4d285b7b..98e1c319331 100644 --- a/generators/src/org/jetbrains/jet/generators/runtime/progressions.kt +++ b/generators/src/org/jetbrains/jet/generators/runtime/progressions.kt @@ -22,7 +22,7 @@ import java.io.PrintWriter class GenerateProgressions(val out: PrintWriter) { fun generate() { - generatedBy(out, javaClass.getName()) + generatedBy(out) for (kind in ProgressionKind.values()) { val t = kind.capitalized val progression = "${t}Progression" diff --git a/generators/src/org/jetbrains/jet/generators/runtime/ranges.kt b/generators/src/org/jetbrains/jet/generators/runtime/ranges.kt index 5a5e184d2ef..fccfd3016e5 100644 --- a/generators/src/org/jetbrains/jet/generators/runtime/ranges.kt +++ b/generators/src/org/jetbrains/jet/generators/runtime/ranges.kt @@ -22,7 +22,7 @@ import java.io.PrintWriter class GenerateRanges(val out: PrintWriter) { fun generate() { - generatedBy(out, javaClass.getName()) + generatedBy(out) for (kind in ProgressionKind.values()) { val t = kind.capitalized val range = "${t}Range"