This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#/bin/env bash | |
if ! which say >/dev/null; then | |
echo "say command not found" | |
echo "you can install it using:" | |
echo " brew install espeak" | |
exit 1 | |
fi | |
if [[ $# < 1 ]];then |
This file has been truncated, but you can view the full file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"jmhVersion" : "1.20", | |
"benchmark" : "io.trino.sql.gen.BenchmarkInCodeGenerator.benchmark", | |
"mode" : "avgt", | |
"threads" : 1, | |
"forks" : 2, | |
"jvm" : "/Library/Java/JavaVirtualMachines/adoptopenjdk-11.jdk/Contents/Home/bin/java", | |
"jvmArgs" : [ | |
"-Dvisualvm.id=361297115645069", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"jmhVersion" : "1.20", | |
"benchmark" : "io.trino.sql.gen.BenchmarkInCodeGenerator.benchmark", | |
"mode" : "avgt", | |
"threads" : 1, | |
"forks" : 2, | |
"jvm" : "/Library/Java/JavaVirtualMachines/adoptopenjdk-11.jdk/Contents/Home/bin/java", | |
"jvmArgs" : [ | |
"-Dvisualvm.id=376605065787142", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Description("current time with time zone") | |
@ScalarFunction | |
@SqlType(StandardTypes.TIME_WITH_TIME_ZONE) | |
public static long currentTime(ConnectorSession session) | |
{ | |
// We do all calculation in UTC, as session.getStartTime() is in UTC | |
// and we need to have UTC millis for packDateTimeWithZone | |
long millis = UTC_CHRONOLOGY.millisOfDay().get(session.getStartTime()); | |
if (!session.isLegacyTimestamp()) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/presto-main/src/main/java/com/facebook/presto/operator/HashBuilderOperator.java b/presto-main/src/main/java/com/facebook/presto/operator/HashBuilderOperator.java | |
index 4f64850..9525c22 100644 | |
--- a/presto-main/src/main/java/com/facebook/presto/operator/HashBuilderOperator.java | |
+++ b/presto-main/src/main/java/com/facebook/presto/operator/HashBuilderOperator.java | |
@@ -17,7 +17,6 @@ import com.facebook.presto.spi.Page; | |
import com.facebook.presto.spi.type.Type; | |
import com.facebook.presto.sql.planner.Symbol; | |
import com.facebook.presto.sql.planner.plan.PlanNodeId; | |
-import com.google.common.base.Preconditions; | |
import com.google.common.collect.ImmutableList; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* 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. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static final ParametricFunction DECIMAL_ADD_OPERATOR = decimalAddOperator(); | |
private static ParametricFunction decimalAddOperator() | |
{ | |
Signature signature = Signature.builder() | |
.type(SCALAR) | |
.operatorType(ADD) | |
.argumentTypes("decimal(p, s)", "decimal(p, s)") | |
.returnType("decimal(min(38, p + 1), s)") | |
.build(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@ScalarOperator(ADD) | |
@SqlType("decimal(min(38, p + 1), s)") | |
public static long addShortShortShort(@SqlType("decimal(p,s)") long a, @SqlType("decimal(p,s)") long b) | |
{ | |
return a + b; | |
} | |
@ScalarOperator(ADD) | |
@SqlType("decimal(min(38, p + 1), s)") | |
public static Slice addShortShortLong(@SqlType("decimal(p,s)") long a, @SqlType("decimal(p,s)") long b) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.facebook.presto.type; | |
import com.facebook.presto.operator.scalar.ScalarFunction; | |
import io.airlift.slice.Slice; | |
import java.math.BigInteger; | |
import static java.math.BigInteger.TEN; | |
import static java.util.Arrays.asList; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Disable autoplay on gazeta.pl | |
// @namespace http://your.homepage/ | |
// @version 0.1 | |
// @description Disables autoplay for iframe movies coming from www.gazeta.tv | |
// @author Lukasz Osipiuk | |
// @match http://*gazeta.pl/* | |
// @match http://*.sport.pl/* | |
// @grant none | |
// ==/UserScript== |
NewerOlder