GreatSyntacticShift: 'namespace' -> 'package'
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
namespace bottles;
|
||||
package bottles;
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
var bottles: Int = 99;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
namespace generics;
|
||||
package generics;
|
||||
|
||||
import java.util.*
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
namespace HelloNames
|
||||
package HelloNames
|
||||
|
||||
fun main(args : Array<String>) {
|
||||
var names = ""
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
namespace HelloNamesFaster
|
||||
package HelloNamesFaster
|
||||
|
||||
fun main(args : Array<String>) {
|
||||
var names = StringBuilder()
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
namespace HelloNamesRealistic
|
||||
package HelloNamesRealistic
|
||||
|
||||
fun main(args : Array<String>) {
|
||||
val names = args.join(", ")
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
namespace JavaInterop
|
||||
package JavaInterop
|
||||
|
||||
import java.util.*
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
namespace NullSafety
|
||||
package NullSafety
|
||||
|
||||
fun <T : Any> T?.npe() : T =
|
||||
if (this == null)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
namespace flist
|
||||
package flist
|
||||
|
||||
abstract class FList<T> {
|
||||
abstract val head : T
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
namespace lockperformance
|
||||
package lockperformance
|
||||
|
||||
import std.io.*
|
||||
import std.util.*
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
namespace quicksort
|
||||
package quicksort
|
||||
|
||||
fun IntArray.swap(i:Int, j:Int) {
|
||||
val temp = this[i]
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
namespace spectralnorm
|
||||
package spectralnorm
|
||||
|
||||
import java.text.DecimalFormat;
|
||||
import java.text.NumberFormat;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
namespace threadring
|
||||
package threadring
|
||||
|
||||
import java.util.concurrent.*;
|
||||
import java.util.concurrent.atomic.*;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
namespace jet.collections.iterable
|
||||
package jet.collections.iterable
|
||||
|
||||
import jet.collections.iterator.IIterator
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
namespace jet.collections.set
|
||||
package jet.collections.set
|
||||
|
||||
import jet.collections.sized.ISized
|
||||
import jet.collections.iterable.IIterable
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
namespace jet.collections.sized
|
||||
package jet.collections.sized
|
||||
|
||||
trait ISized {
|
||||
val size : Int
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
namespace jet.collections
|
||||
package jet.collections
|
||||
|
||||
import java.util.NoSuchElementException
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@ import org.jboss.netty.handler.codec.http.HttpResponseStatus.*
|
||||
import netty.*
|
||||
import jlstring.*
|
||||
|
||||
namespace jlstring {
|
||||
package jlstring {
|
||||
fun String.replace(c: Char, by: Char) : String = (this as java.lang.String).replace(c, by) as String
|
||||
|
||||
fun String.contains(s: String) : Boolean = (this as java.lang.String).contains(s as java.lang.CharSequence)
|
||||
@@ -24,7 +24,7 @@ namespace jlstring {
|
||||
fun java.lang.String.plus(s: Any?) : String = (this as String) + s.toString()
|
||||
}
|
||||
|
||||
namespace netty {
|
||||
package netty {
|
||||
fun ChannelPipeline.with(op: fun ChannelPipeline.() ) : ChannelPipeline {
|
||||
this.op()
|
||||
return this
|
||||
|
||||
Reference in New Issue
Block a user