content stringlengths 4 1.04M | lang stringclasses 358
values | score int64 0 5 | repo_name stringlengths 5 114 | repo_path stringlengths 4 229 | repo_licenses listlengths 1 8 |
|---|---|---|---|---|---|
REBOL [
Title: "Emit Red/System api to html"
Author: "Peter W A Wood"
File: %emit-block.r
Version: 0.1.0
Rights: "Copyright (C) 2012-2015 Peter W A Wood. All rights reserved."
License: "BSD-3 - https://github.com/red/red/blob/master/BSD-3-License.txt"
Description: {This is a... | R | 4 | 0xflotus/red | docs/emit-block.r | [
"BSL-1.0",
"BSD-3-Clause"
] |
#declare grid = L*cos(Ze/180*pi)*df/(pi+(2*cos(Ze/180*pi)-1)*pi*df)*(10/180*pi)*(10/180*pi);
#declare n_0 = grid*sin(0/180*pi);
#declare n_10 = grid*sin(10/180*pi);
#declare n_20 = grid*sin(20/180*pi);
#declare n_30 = grid*sin(30/180*pi);
#declare n_40 = grid*sin(40/180*pi);
#declare n_50 = grid*sin(50/180*pi);... | POV-Ray SDL | 2 | lsymuyu/Digital-Plant-Phenotyping-Platform | Phenotyping/light_old.pov | [
"MIT"
] |
import io/FileReader
import structs/ArrayList
import text/Regexp
import text/StringTokenizer
addr: func (a: Int, b: Int, c: Int, r: ArrayList<Int>) -> Int { r[a] + r[b] }
addi: func (a: Int, b: Int, c: Int, r: ArrayList<Int>) -> Int { r[a] + b }
mulr: func (a: Int, b: Int, c: Int, r: ArrayList<Int>) -> Int { r[a] * r[... | ooc | 3 | Ashindustry007/competitive-programming | advent-of-code/2018/day16/part1.ooc | [
"WTFPL"
] |
HAI 1.3
HOW IZ I code YR n
n, WTF?
OMG -4, FOUND YR ":""
OMG -3, FOUND YR "::"
OMG -2, FOUND YR " OMG "
OMG -1, FOUND YR ", FOUND YR "
OMG 0, FOUND YR "HAI 1.3"
OMG 1, FOUND YR " HOW IZ I code YR n"
OMG 2, FOUND YR " n, WTF?"
OMG 3, FOUND YR "CODE"
OM... | LOLCODE | 3 | MakeNowJust/quine | quine.lol | [
"Beerware"
] |
#*****************************************************************************
# *
# Make file for VMS *
# Author : J.Jansen (joukj@hrem.nano.tudelft.nl) *
# Da... | Module Management System | 3 | madanagopaltcomcast/pxCore | examples/pxScene2d/external/WinSparkle/3rdparty/wxWidgets/samples/erase/descrip.mms | [
"Apache-2.0"
] |
TDTopezLeafNode{#name:'nodes',#contents:'browse class --hier TDNode TDAbstractComposedDirectoryNodeContents TDPathComposedDirectoryEntry',#creationTime:DateAndTime['2013-12-06T17:30:33.25754189491272-08:00'],#modificationTime:DateAndTime['2014-11-07T15:48:07.2476019859314-08:00']} | STON | 1 | dassi/tode | tode/nodes.ston | [
"MIT"
] |
<template>
<vue-file :file="`wireframes/${wireframe}`" />
</template>
<script>
// Extensions
import Documentation from './Documentation'
// Utilities
import { get } from 'vuex-pathify'
import { localeLookup } from '@/i18n/util'
async function load (route) {
const locale = localeLookup(route.params.... | Vue | 4 | mark-gene/vuetify | packages/docs/src/views/Wireframes.vue | [
"MIT"
] |
//Copyright 2017 Aaron Goodman <aaronjg@stanford.edu>. Licensed under the GPLv3 or later.
data{
int <lower=0> NSMPL;
int <lower=0> replicates;
int <lower=0> replicate_samples[replicates];
int <lower=0> value[NSMPL];
vector [NSMPL] time;
}
transformed data{
vector[NSMPL] value_vec = to_vector(value);
vecto... | Stan | 5 | stan-dev/stancon_talks | 2018/Contributed-Talks/05_goodman/state_space_noncenter.stan | [
"CC-BY-4.0",
"BSD-3-Clause"
] |
JsonReaderState struct #RefType {
source string
index int
token JsonToken
valueBuilder StringBuilder
}
JsonToken struct {
type JsonTokenType
value string
}
JsonTokenType enum {
openBrace
closeBrace
openBracket
closeBracket
colon
comma
stringLiteral
otherLiteral
... | mupad | 5 | jturner/muon | language_server/json.mu | [
"MIT"
] |
# Copyright 2015 The TensorFlow Authors. All Rights Reserved.
#
# 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 applica... | Python | 4 | KosingZhu/tensorflow | tensorflow/python/kernel_tests/listdiff_op_test.py | [
"Apache-2.0"
] |
import {PreferencesUIStore,
WorkspaceStore,
ComponentRegistry} from 'nylas-exports';
import PreferencesRoot from './preferences-root';
import PreferencesGeneral from './tabs/preferences-general';
import PreferencesAccounts from './tabs/preferences-accounts';
import PreferencesAppearance from './tabs/preferences-ap... | JSX | 4 | cnheider/nylas-mail | packages/client-app/internal_packages/preferences/lib/main.jsx | [
"MIT"
] |
.//=======================================================================
.// 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
.//
.//... | Arc | 3 | FMAY-Software/bridgepoint | src/org.xtuml.bp.core/arc/wizard.arc | [
"Apache-2.0"
] |
<?xml version="1.0" encoding="UTF-8"?>
<!-- ******************************************************************* -->
<!-- -->
<!-- Copyright IBM Corp. 2010, 2014 -->
<!-- ... | XPages | 2 | jesse-gallagher/XPagesExtensionLibrary | extlib/lwp/product/runtime/eclipse/plugins/com.ibm.xsp.extlib.controls/src/com/ibm/xsp/extlib/config/extlib-outline.xsp-config | [
"Apache-2.0"
] |
<% var x = "hello" %>
Prevent this from compiling as x(x), where the two expressions are fused ${x} ${(x)} | Gosu | 1 | tcmoore32/sheer-madness | gosu-test/src/test/gosu/gw/internal/gosu/template/SeparateExpr.gst | [
"Apache-2.0"
] |
fun main () : transaction page = return <xml><body>
{[ -1 ]}, {[ 1 + 1 ]}, {[ 9 - 3 ]}, {[ 9 * 3 ]}, {[ 9 / 3 ]}, {[ 9 % 3 ]}<br/>
{[ -1.1 ]}, {[ 1.0 + 1.1 ]}, {[ 9.1 - 3.0 ]}, {[ 9.1 * 3.0 ]},
{[ 9.1 / 3.0 ]}, {[ 9.1 % 3.0 ]}<br/>
</body></xml>
| UrWeb | 2 | apple314159/urweb | tests/num.ur | [
"BSD-3-Clause"
] |
--TEST--
assert() - set callback using ini_set()
--INI--
assert.active = 1
assert.warning = 0
assert.callback =
assert.bail = 0
assert.exception=0
--FILE--
<?php
function a($file, $line, $unused, $desc)
{
echo "assertion failed - a - $line,\"$desc\"\n";
}
function b($file, $line, $unused, $desc)
{
... | PHP | 3 | NathanFreeman/php-src | ext/standard/tests/assert/assert03.phpt | [
"PHP-3.01"
] |
package jadx.tests.integration.conditions;
import org.junit.jupiter.api.Test;
import jadx.NotYetImplemented;
import jadx.tests.api.IntegrationTest;
public class TestSwitchTryBreak2 extends IntegrationTest {
public static class TestCls {
public void test(int x) {
switch (x) {
case 0:
return;
case... | Java | 2 | Dev-kishan1999/jadx | jadx-core/src/test/java/jadx/tests/integration/conditions/TestSwitchTryBreak2.java | [
"Apache-2.0"
] |
@0x97d8c9b4831fdcbb;
struct Observation {
bytesAcked @0 :UInt64;
bytesMisordered @1 :UInt64;
ecnBytes @2 :UInt64;
packetsAcked @3 :UInt64;
packetsMisordered @4 :UInt64;
ecnPackets @5 :UInt64;
loss @6 :UInt64;
timeout ... | Cap'n Proto | 3 | utkarsh5k/park | park/envs/congestion_control/park/ccp.capnp | [
"MIT"
] |
# MMS Description file for xv
# Written by Rick Dyson (dyson@iowasp.physics.uiowa.edu)
# Last Modified: 30-APR-1992 for v2.21
# 5-OCT-1992 for v2.21 (export.lcs.mit.edu version
# of xv-2.21 seemed to change about
# 25-Sep-1992 without version number
# changing.
# 8-FEB-1993 for v2.21b
# ... | Module Management System | 4 | JavascriptID/sourcerer-app | src/test/resources/samples/langs/Module Management System/xv_makefile.mms | [
"MIT"
] |
// Reinhold P. Weicker, CACM Vol 27, No 10, 10/84 pg. 1013.
//
// Translated from ADA to C by Rick Richardson.
// Every method to preserve ADA-likeness has been used,
// at the expense of C-ness.
//
// Translated from C to Python by Guido van Rossum.
//
//
// Adapted for Grace by Richard Roberts
// 2018, June
//
im... | Grace | 3 | smarr/moth-benchmarks | benchmarks/Moth/PyStone.grace | [
"MIT"
] |
module chapter6/memory/checkCache [Addr, Data]
open chapter6/memory/cacheMemory [Addr, Data] as cache
open chapter6/memory/abstractMemory [Addr, Data] as amemory
fun alpha [c: CacheSystem]: Memory {
{m: Memory | m.data = c.main ++ c.cache}
}
// This check should not produce a counterexample
ReadOK: check {
// int... | Alloy | 4 | haslab/Electrum | electrum/src/main/resources/models/book/chapter6/memory/checkCache.als | [
"MIT"
] |
#pragma once
#include <torch/csrc/jit/codegen/cuda/arith.h>
#include <torch/csrc/jit/codegen/cuda/ops/composite.h>
#include <torch/csrc/jit/codegen/cuda/ops/normalization.h>
| C | 0 | xiaohanhuang/pytorch | torch/csrc/jit/codegen/cuda/ops/all_ops.h | [
"Intel"
] |
module decorators_demo
import typechecker
@check(isInteger(), isDouble()) (isDouble())
function IntPlusDouble = |a,b| {
return a + b
}
function main = |args| {
let a = IntPlusDouble(5, 6.9)
println(a)
let b = IntPlusDouble(5.3, 6.9)
println(b)
} | Golo | 4 | TypeUnsafe/golo-tour | 07-golo.06.RivieraJUG/04-golo-s-touch/sandbox/10-b-decorators-check-type.golo | [
"MIT"
] |
*** Settings ***
Resource rebot_resource.robot
*** Variables ***
${INPUTFILE} %{TEMPDIR}${/}rebot-test-rmkw.xml
*** Keywords ***
Keyword Should Be Empty
[Arguments] ${kw} ${name} @{args}
Should End With ${kw.doc} _Keyword data removed using --RemoveKeywords option._
Check Keyw... | RobotFramework | 4 | rdagum/robotframework | atest/robot/cli/rebot/remove_keywords/remove_keywords_resource.robot | [
"ECL-2.0",
"Apache-2.0"
] |
:- style_check( all ).
:- use_module(library(gecode/clpfd)).
:- use_module(library(maplist)).
t0 :-
test0(X),
writeln(X).
test0(X) :-
X in 1..10,
X #= 2.
t1 :-
test1(X),
writeln(X),
fail.
t1.
test1(X) :-
X in 1..10,
Y in 3..7,
Z in 1..4,
X / Y #= Z,
labeling([], [X]).
t2 :-
test2(X),
writeln(X),
f... | Prolog | 4 | ryandesign/yap | packages/gecode/clp_examples/test.yap | [
"Artistic-1.0-Perl",
"ClArtistic"
] |
<?xml version='1.0' encoding='UTF-8'?>
<Project Type="Project" LVVersion="13008000">
<Property Name="NI.LV.All.SourceOnly" Type="Bool">true</Property>
<Property Name="NI.Project.Description" Type="Str"></Property>
<Item Name="My Computer" Type="My Computer">
<Property Name="server.app.propertiesEnabled" Type="Boo... | LabVIEW | 1 | advancedplotting/aplot | examples/Examples.lvproj | [
"BSD-3-Clause"
] |
// Copyright 2021 The Google Research Authors.
//
// 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... | C++ | 3 | deepneuralmachine/google-research | sgk/sparse/ops/cc/bias_relu_launcher.cu.cc | [
"Apache-2.0"
] |
# Check that use of isolate option prevents shifted stride detection
domain: "{ A[i,j] : 0 <= i < 100 and 0 <= j < 2; B[i,j] : 0 <= i < 100 and 0 <= j < 2 }"
child:
schedule: "[{ A[i,j] -> [2i]; B[i,j] -> [2i+1] }, { A[i,j] -> [j]; B[i,j] -> [j]}]"
options: "{ isolate[[] -> [x, y]] : 10 <= x < 90 }"
| Smalltalk | 2 | chelini/isl-haystack | test_inputs/codegen/isolate5.st | [
"MIT"
] |
.class public Lothers/TestIncorrectMethodSignature;
.super Ljava/lang/RuntimeException;
.source "TestIncorrectMethodSignature.java"
.method public constructor <init>(Ljava/lang/String;)V
.registers 2
.annotation system Ldalvik/annotation/Signature;
value = {
"(J)V"
}
.end annot... | Smali | 3 | Dev-kishan1999/jadx | jadx-core/src/test/smali/others/TestIncorrectMethodSignature.smali | [
"Apache-2.0"
] |
---
page-header: RTL mode
menu: home
rtl: true
title: RTL mode
layout: homepage
---
| HTML | 1 | muhginanjar/tabler | src/pages/layout-rtl.html | [
"MIT"
] |
% Abstract given nonterminals from potential clones - C function version
% Jim Cordy, May 2010
% Using Gnu C grammar
include "c.grm"
% Redefinition for potential clones
redefine function_definition
[function_header]
[opt KR_parameter_decls]
'{ [IN][NL]
[compound_statement_body] [EX]
'}
end re... | TXL | 4 | coder-chenzhi/SQA | SourcererCC/parser/java/txl/c-abstract-functions.txl | [
"Apache-2.0"
] |
<?xml version="1.0" encoding="UTF-8"?>
<!-- ******************************************************************* -->
<!-- -->
<!-- © Copyright IBM Corp. 2010, 2011 -->
<!-- ... | XPages | 4 | jesse-gallagher/XPagesExtensionLibrary | extlib/lwp/product/runtime/eclipse/plugins/com.ibm.xsp.extlib.controls/src/com/ibm/xsp/extlib/config/raw-extlib-dialog.xsp-config | [
"Apache-2.0"
] |
<div>
<!-- display: inline -->
<p>Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long</p>
</div>
| HTML | 0 | fuelingtheweb/prettier | tests/html_magic_comments/display.html | [
"MIT"
] |
a { value: \2cx } | CSS | 1 | mengxy/swc | crates/swc_css_parser/tests/fixture/esbuild/misc/DrlXteRB-ppLVxi4_N4dhA/input.css | [
"Apache-2.0"
] |
<html>
<body>
<h2 id="redirfrag">Redir</h2>
</body>
</html>
| HTML | 3 | mbc-git/rust | src/tools/linkchecker/tests/valid/inner/redir-target.html | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] |
Rebol [
Title: "Combine"
Date: 28-March-2014 ; or thereabouts
Author: "Brian Dickens"
Version: 1.0.0
Type: module
Name: hostilefork.combine
Exports: [
combine
]
]
combine: func [
{Combine evaluated expressions and substitute block variables to produce a string}
block [... | Rebol | 5 | rgchris/Scripts | r3-alpha/combine.r3 | [
"Apache-2.0"
] |
package io.swagger.client.model {
import io.swagger.common.ListWrapper;
public class CategoryList implements ListWrapper {
// This declaration below of _Category_obj_class is to force flash compiler to include this class
private var _category_obj_class: io.swagger.client.model.Category = null;
... | ActionScript | 4 | wwadge/swagger-codegen | samples/client/petstore/flash/flash/src/io/swagger/client/model/CategoryList.as | [
"Apache-2.0"
] |
from fastapi import FastAPI
from pydantic import BaseModel
from typing import Optional
app = FastAPI()
# temp database
fakedb = []
# course model to store courses
class Course(BaseModel):
id: int
name: str
price: float
is_early_bird: Optional[bool] = None
# Home/welcome route
@app.get("/")
def read_... | Python | 5 | nicetone/Python | fastapi.py | [
"MIT"
] |
BdJ @@ | PureBasic | 0 | pchandrasekaran1595/onnx | onnx/backend/test/data/simple/test_gradient_of_add_and_mul/test_data_set_0/output_0.pb | [
"Apache-2.0"
] |
# This file is distributed under the same license as the Django package.
#
# Translators:
# Jafry Hisham, 2021
msgid ""
msgstr ""
"Project-Id-Version: django\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-01-15 09:00+0100\n"
"PO-Revision-Date: 2021-11-16 14:09+0000\n"
"Last-Translator: Jafry Hisham\n"
"Language... | Gettext Catalog | 3 | Joshua-Barawa/My-Photos | venv/lib/python3.8/site-packages/django/contrib/admindocs/locale/ms/LC_MESSAGES/django.po | [
"PostgreSQL",
"Unlicense"
] |
// input: []
// output: 121
package {
public class ClassCall {
public static function main():int{
var f:OtherClass = new OtherClass();
return f.func(100,20);
}
}
}
class OtherClass {
public function func(x: int, y: int):int {
return x+y+1;
}
}
| ActionScript | 3 | hackarada/youtube-dl | test/swftests/ClassCall.as | [
"Unlicense"
] |
sleep 2
t app appmode photo_burst
sleep 1
t app burst_settings 30-3
sleep 1
t app button shutter PR
sleep 9
t app button power P
sleep 2
t app button power R | AGS Script | 1 | waltersgrey/autoexechack | BurstHacks/BurstAndTurnOff/30:3/Hero3Black/autoexec.ash | [
"MIT"
] |
/*
* Copyright (c) 2020, Oracle and/or its affiliates. All rights reserved.
* Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl.
*/
function e(a, b) {
return a == b;
}
function main() {
println(e(4, 4));
println(e(3, "aaa"));
println(e(4, 4));
p... | Slash | 3 | CAFxX/simplelanguage | language/tests/Equal.sl | [
"UPL-1.0"
] |
/// Debugging aids
import Prim "mo:⛔";
module {
/// `print(t)` emits text `t` to the debug output stream.
/// How this stream is stored or displayed depends on the
/// execution environment.
public let print : Text -> () = Prim.debugPrint;
/// `trap(t)` traps execution with a user-provided message.
publi... | Modelica | 5 | CapuzR/prixer-fe | .vessel/base/494824a2787aee24ab4a5888aa519deb05ecfd60/src/Debug.mo | [
"MIT"
] |
enum Color { Rgb(isize, isize, isize), Rgba(isize, isize, isize, isize), }
fn main() {
let red: Color = Color::Rgb(255, 0, 0);
match red {
Color::Rgb(r, g, b) => { println!("rgb"); }
Color::Hsl(h, s, l) => { println!("hsl"); }
//~^ ERROR no variant
}
}
| Rust | 3 | Eric-Arellano/rust | src/test/ui/bogus-tag.rs | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] |
; ModuleID = 'bpftrace'
source_filename = "bpftrace"
target datalayout = "e-m:e-p:64:64-i64:64-i128:128-n32:64-S128"
target triple = "bpf-pc-linux"
; Function Attrs: nounwind
declare i64 @llvm.bpf.pseudo(i64 %0, i64 %1) #0
define i64 @"kprobe:f"(i8* %0) section "s_kprobe:f_1" {
entry:
%"@x_val" = alloca i64, align ... | LLVM | 3 | thefallentree/bpftrace | tests/codegen/llvm/map_key_string.ll | [
"Apache-2.0"
] |
%{--
- Copyright 2016 SimplifyOps, Inc. (http://simplifyops.com)
-
- 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
-
- Unles... | Groovy Server Pages | 3 | kbens/rundeck | rundeckapp/grails-app/views/reports/_baseFilters.gsp | [
"Apache-2.0"
] |
rm -f ifcreate?.log *~ .*~
| Stata | 1 | BlameJohnny/redo | t/220-ifcreate/clean.do | [
"Apache-2.0"
] |
#!/bin/sh
#
# Copyright 2020 PingCAP, Inc.
#
# 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 t... | Shell | 3 | cuishuang/tidb | br/tests/br_tiflash/run.sh | [
"Apache-2.0"
] |
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
#include "pch.h"
#include "winrt/Windows.UI.Xaml.Interop.h"
#include "HighlightedTextControl.h"
#include "HighlightedTextControl.g.cpp"
using namespace winrt;
using namespace winrt::TerminalApp;
using namespace winrt::Windows::UI::Core;
using... | C++ | 5 | sonvt1710/terminal | src/cascadia/TerminalApp/HighlightedTextControl.cpp | [
"MIT"
] |
terraform {
required_providers {
aws = {
source = "hashicorp/aws"
version = "~> 2.70"
}
}
}
####################
# Declare variables
# Variables without default values
# these variables need to be changed - see terraform.tfvars
variable "key_name" { }
variable "package_path" { }
variable "ins... | HCL | 5 | SGZW/influxdb | scripts/ci/main.tf | [
"MIT"
] |
$$ MODE TUSCRIPT
PRINT "Hello world!"
| Turing | 2 | LaudateCorpus1/RosettaCodeData | Task/Hello-world-Text/TUSCRIPT/hello-world-text.tu | [
"Info-ZIP"
] |
class Node
@left : self?
@right : self?
def initialize(@value : Char)
end
def add(x)
if x < @value
if left = @left
left.add(x)
else
@left = Node.new(x)
end
else
if right = @right
right.add(x)
else
@right = Node.new(x)
end
end
... | Crystal | 3 | jessedoyle/crystal | samples/tree.cr | [
"Apache-2.0"
] |
#N canvas 659 66 551 450 12;
#X text 321 400 updated for Pd version 0.25;
#X text 43 400 see also:;
#X obj 69 16 poly;
#X obj 121 401 route;
#X obj 175 401 makenote;
#X obj 140 257 poly 4 1;
#X obj 133 353 print;
#X text 178 352 Output is in the printout window.;
#X msg 209 225 stop;
#X msg 198 199 clear;
#X text 108 1... | Pure Data | 4 | myQwil/pure-data | doc/5.reference/poly-help.pd | [
"TCL"
] |
(defmodule example
"This is an example module."
(export (matchfun 3))
(export-macro add varargs forty-two? tricky))
(include-file "foo.lfe")
(defmacro add (x y)
"Add `x` and `y`."
`(+ ,x ,y))
(defmacro varargs args
"This is a varags macro."
`'ok)
(defmacro forty-two?
"Return `'true` iff `x` is 42."
... | LFE | 5 | haetze/lfe | test/example_SUITE_data/example.lfe | [
"Apache-2.0"
] |
import { IGatsbyState, ActionsUnion } from "../types"
export const lastActionReducer = (
_state: unknown,
action: ActionsUnion
): IGatsbyState["lastAction"] => action
| TypeScript | 3 | Pabelnedved/ghostlocoko | packages/gatsby/src/redux/reducers/last-action.ts | [
"MIT"
] |
using Uno;
using Uno.Testing;
using FuseTest;
namespace Fuse.Animations.Test
{
public class ChangeTest : TestBase
{
[Test]
/*
This basically performs the calculation that will be done through the layers of the animation
system. It should match what is done in the AverageMixer.
These tests are impor... | Uno | 5 | helilabs/fuselibs | Source/Fuse.Animations/Tests/Change.Test.uno | [
"MIT"
] |
#include "mop.h"
MODULE = Class::MOP::Mixin::AttributeCore PACKAGE = Class::MOP::Mixin::AttributeCore
PROTOTYPES: DISABLE
BOOT:
INSTALL_SIMPLE_READER(Mixin::AttributeCore, name);
INSTALL_SIMPLE_READER(Mixin::AttributeCore, accessor);
INSTALL_SIMPLE_READER(Mixin::AttributeCore, reader);
INSTALL_SIMP... | XS | 4 | skington/Moose | xs/AttributeCore.xs | [
"Artistic-1.0"
] |
=head1 NAME
POST - Parrot opcode syntax tree
=head1 DESCRIPTION
This file implements the various opcode syntax tree nodes
for compiling programs in Parrot.
=cut
.namespace [ 'POST' ]
.sub '__onload' :load :init
.local pmc p6meta, base
## create POST classes
p6meta = new 'P6metaclass'
base = p6m... | Parrot Internal Representation | 5 | winnit-myself/Wifie | compilers/pct/src/POST/Node.pir | [
"Artistic-2.0"
] |
def loading [] {
$"Loading (char newline)" | autoview
echo 0..100 | each { |tick|
sleep 50ms
# I believe '1000D' means move the cursor to the left 1000 columns
$"(ansi -e '1000D')" | autoview
$"($tick)%" | autoview
}
#show_cursor
}
def show_cursor [] {
$"(ansi -e '?2... | Nu | 4 | x3rAx/nu_scripts | progress_bar/percent_meter.nu | [
"MIT"
] |
.icon-drupal.service-icon {
display: inline-block;
width: 21px;
height: 28px;
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABUAAAAcCAYAAACOGPReAAAABGdBTUEAALGPC/xhBQAAAAZiS0dEAP8A/wD/oL2nkwAAAcNJREFUSMetlbFrFFEQh7/dJnhpDHcx6SyiRLhLkUKDsRZB8S9IWi2Syj8iVooQ0FLBNlqJRpNO8Br7FLkoRDBooQHhNCr6WTjB... | CSS | 3 | subramanir2143/Rocket.Chat | app/drupal/client/login-button.css | [
"MIT"
] |
(*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*)
(* This cache maps from spreads (indexed by spread ids, which are generated by eval_destructor
* and Statement.ml) to one of the l... | OCaml | 5 | Hans-Halverson/flow | src/typing/spread_cache.ml | [
"MIT"
] |
## Licensed to Cloudera, Inc. under one
## or more contributor license agreements. See the NOTICE file
## distributed with this work for additional information
## regarding copyright ownership. Cloudera, Inc. licenses this file
## to you under the Apache License, Version 2.0 (the
## "License"); you may not use this f... | Mako | 4 | yetsun/hue | apps/zookeeper/src/zookeeper/templates/view.mako | [
"Apache-2.0"
] |
<?xml version='1.0' encoding='UTF-8'?>
<Project Type="Project" LVVersion="14008000">
<Property Name="SMProvider.SMVersion" Type="Int">201310</Property>
<Item Name="My Computer" Type="My Computer">
<Property Name="IOScan.Faults" Type="Str"></Property>
<Property Name="IOScan.NetVarPeriod" Type="UInt">100</Property... | LabVIEW | 2 | ajnavarro/language-dataset | data/github.com/opengds/OpenGDS/9b990ecbcdeb78ebcd952fdf03efaf937daeae33/Open_GDS_Tools/Open_GDS.lvproj | [
"MIT"
] |
# This file is distributed under the same license as the Django package.
#
# Translators:
# e4db27214f7e7544f2022c647b585925_bb0e321, 2015
# e4db27214f7e7544f2022c647b585925_bb0e321, 2014
# Jannis Leidel <jannis@leidel.info>, 2011
# Uriel Medina <urimeba511@gmail.com>, 2020-2021
msgid ""
msgstr ""
"Project-Id-Version: ... | Gettext Catalog | 2 | Joshua-Barawa/My-Photos | venv/lib/python3.8/site-packages/django/contrib/redirects/locale/es/LC_MESSAGES/django.po | [
"PostgreSQL",
"Unlicense"
] |
CREATE TABLE public.article (
id integer NOT NULL,
title text NOT NULL,
user_id text NOT NULL
);
CREATE SEQUENCE public.article_id_seq
AS integer
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
ALTER SEQUENCE public.article_id_seq OWNED BY public.article.id;
CREATE TABLE... | SQL | 4 | gh-oss-contributor/graphql-engine-1 | community/sample-apps/vuejs-auth0-graphql/hasura/migrations/default/1613664247608_init/up.sql | [
"Apache-2.0",
"MIT"
] |
--TEST--
Bug #35885 (strtotime("NOW") no longer works)
--FILE--
<?php
date_default_timezone_set("UTC");
$time = time();
$ts = date(DATE_ISO8601, strtotime('NOW', $time));
$ts2 = date(DATE_ISO8601, $time);
$res = ($ts == $ts2);
var_dump($res);
if (!$res) {
var_dump($ts);
var_dump($ts2);
}
?>
--EXPECT--
bool(... | PHP | 3 | thiagooak/php-src | ext/date/tests/bug35885.phpt | [
"PHP-3.01"
] |
# Copyright (c) 2020 vesoft inc. All rights reserved.
#
# This source code is licensed under Apache 2.0 License.
Feature: Basic match
Background:
Given a graph with space named "nba_int_vid"
Scenario: Single node
When executing query:
"""
MATCH (v:player {name: "Yao Ming"}) RETURN v
"""
... | Cucumber | 5 | SuperYoko/nebula | tests/tck/features/match/Base.IntVid.feature | [
"Apache-2.0"
] |
import PropTypes from "prop-types"
import React, { Component } from "react"
import Fallback from "./fallback"
export class ErrorBoundary extends Component {
constructor(props) {
super(props)
this.state = { hasError: false, error: null }
}
static getDerivedStateFromError(error) {
return { hasError: ... | JSX | 4 | soyuka/swagger-ui | src/core/plugins/view/error-boundary.jsx | [
"Apache-2.0"
] |
TDTopezLeafNode {
#name : 'x',
#contents : 'ts debug MCFileTreeIssue72Test>>testWriteNRead'
} | STON | 0 | dalehenrich/filetree | tode/x.ston | [
"MIT"
] |
const plan9 = @import("../plan9.zig");
// TODO better inline asm
pub fn syscall1(sys: plan9.SYS, arg0: usize) usize {
return asm volatile (
\\push %%r8
\\push $0
\\syscall
\\pop %%r11
\\pop %%r11
: [ret] "={rax}" (-> usize),
: [syscall_number] "{rbp}" (@enumT... | Zig | 3 | lukekras/zig | lib/std/os/plan9/x86_64.zig | [
"MIT"
] |
--TEST--
SPL: FixedArray: adding new elements
--FILE--
<?php
$a = new SplFixedArray(10);
try {
$a[] = 1;
} catch (Error $e) {
echo $e->getMessage(), "\n";
}
?>
--EXPECT--
[] operator not supported for SplFixedArray
| PHP | 4 | NathanFreeman/php-src | ext/spl/tests/fixedarray_004.phpt | [
"PHP-3.01"
] |
from ctypes import *
import unittest, sys
from test import support
################################################################
# This section should be moved into ctypes\__init__.py, when it's ready.
from _ctypes import PyObj_FromPtr
################################################################
from sys imp... | Python | 5 | shawwn/cpython | Lib/ctypes/test/test_python_api.py | [
"0BSD"
] |
@size: 2px;
#jasmine-content {
font-size: @size;
}
| Less | 3 | pyrolabs/atom | spec/fixtures/packages/package-with-styles/styles/2.less | [
"MIT"
] |
*/Driver/Printer/* print PRINT | Max | 0 | steakknife/pcgeos | Include/driver.pat | [
"Apache-2.0"
] |
Select * From TABLE1 t Where a > 100 AND b between 12 AND 45;
SELECT t.*,j1.x,j2.y FROM TABLE1 t JOIN JT1 j1 ON j1.a = t.a
LEFT OUTER JOIN JT2 j2 ON j2.a=t.a AND j2.b=j1.b
WHERE t.xxx NOT NULL;
DELETE FROM TABLE1 WHERE a=1;
UPDATE TABLE1 SET a=2 WHERE a=1
SELECT table1.id, table2.number, SUM(table1.amount) FROM tab... | SQL | 3 | SubOptimal/dbeaver | plugins/org.jkiss.dbeaver.ui.editors.sql/src/org/jkiss/dbeaver/ui/editors/sql/preferences/format_preview.sql | [
"Apache-2.0"
] |
.class public Lfirst/A;
.super Ljava/lang/Object;
.field public first:Lfirst/A;
.field public second:Lsecond/A;
.method public test()Ljava/lang/String;
.registers 2
invoke-static {}, Lsecond/A;->call()Ljava/lang/String;
move-result-object v0
return-object v0
.end method
| Smali | 4 | DSYliangweihao/jadx | jadx-core/src/test/smali/names/TestFieldCollideWithPackage/1.smali | [
"Apache-2.0"
] |
/*****************************************************************************
*
* ALTER THING name SET SCHEMA name
*
*****************************************************************************/
AlterObjectSchemaStmt:
ALTER TABLE relation_expr SET SCHEMA name
{
PGAlterObjectSchemaStmt *n = makeNode(PG... | Yacc | 4 | AldoMyrtaj/duckdb | third_party/libpg_query/grammar/statements/alter_schema.y | [
"MIT"
] |
Rebol [
Title: "Munge functions"
Owner: "Ashley G Truter"
Version: 3.0.6
Date: 9-Apr-2019
Purpose: "Extract and manipulate tabular values in blocks, delimited files and database tables."
Licence: "MIT. Free for both commercial and non-commercial use."
Tested: {
Windows
REBOL/View 2.7.8 rebol.com
R3/... | Rebol | 5 | semarie/rebol3-oldes | src/modules/munge3.reb | [
"Apache-2.0"
] |
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT License.
Import-Module $PSScriptRoot/Apache/Apache.psm1
#list Apache Modules
Write-Host -Foreground Blue "Get installed Apache Modules like *proxy* and Sort by name"
Get-ApacheModule | Where-Object {$_.ModuleName -like "*proxy*"} | Sort-Object ModuleName... | PowerShell | 4 | rdtechie/PowerShell | demos/Apache/apache-demo.ps1 | [
"MIT"
] |
module Views.Shared.AlertListCompact exposing (view)
import Data.GettableAlert exposing (GettableAlert)
import Html exposing (Html, div)
import Html.Attributes exposing (class)
import Views.Shared.AlertCompact
import Views.Shared.Types exposing (Msg)
view : Maybe String -> List GettableAlert -> Html Msg
view activeA... | Elm | 4 | jtlisi/alertmanager | ui/app/src/Views/Shared/AlertListCompact.elm | [
"ECL-2.0",
"Apache-2.0"
] |
structure Tokens = Tokens
type pos = int
type svalue = Tokens.svalue
type ('a,'b) token = ('a,'b) Tokens.token
type lexresult = (svalue,pos) token
open Tokens
val lineNum = ref 0
val eof = fn () => EOF(!lineNum,!lineNum)
structure KeyWord : sig
val find : string ->
(int * int -> (svalue,int) token) opt... | Lex | 3 | plveir/smlsharp | src/ml-yacc/examples/pascal/pascal.lex | [
"MIT"
] |
[CustomMessages]
fr.IDP_FormCaption =Téléchargement des fichiers additionnels
fr.IDP_FormDescription =Veuillez patienter durant le téléchargement des fichiers additionnels...
fr.IDP_TotalProgress =Progression générale:
fr.IDP_CurrentFile =Fichier en cours:
fr.IDP_File ... | Inno Setup | 3 | shakeyourbunny/appget | setup/idp/unicode/idplang/french.iss | [
"Apache-2.0"
] |
-- ==============================================================
-- RTL generated by Vivado(TM) HLS - High-Level Synthesis from C, C++ and SystemC
-- Version: 2016.3
-- Copyright (C) 1986-2016 Xilinx, Inc. All Rights Reserved.
--
-- ===========================================================
library IEEE;
us... | VHDL | 4 | JimMadge/aws-fpga | hdk/common/shell_v04261818/hlx/design/ip/dds_v1_0/hdl/vhdl/dds.vhd | [
"Apache-2.0"
] |
--TEST--
addcslashes(); function test with warning
--CREDITS--
marcosptf - <marcosptf@yahoo.com.br>
#phptestfest PHPSP on Google - Sao Paulo - Brazil - 2014-06-05
--FILE--
<?php
echo addcslashes("zoo['.']","z..A");
?>
--EXPECTF--
Warning: addcslashes(): Invalid '..'-range, '..'-range needs to be incrementing in %s on ... | PHP | 3 | thiagooak/php-src | ext/standard/tests/strings/addcslashes_005.phpt | [
"PHP-3.01"
] |
void onConnect() override
{
try
{
PYBIND11_OVERLOAD(void, TdApi, onConnect);
}
catch (const error_already_set &e)
{
cout << e.what() << endl;
}
};
void onRspLogin(int error, const dict &data) override
{
try
{
PYBIND11_OVERLOAD(void, TdApi, onRspLogin, error, data);
}
catch (const error_already_set &e)
... | C++ | 3 | funrunskypalace/vnpy | vnpy/api/tap/generator/tap_td_source_on.cpp | [
"MIT"
] |
Require Import Utf8.
Section FOLD.
Context {A: Type} (f: A → A) (a: A).
Fixpoint fold (n: nat) : A :=
match n with
| O => a
| S n' => f (fold n')
end.
End FOLD.
Definition ackermann : nat → nat → nat :=
fold (λ g, fold g (g (S O))) S.
| Coq | 4 | LaudateCorpus1/RosettaCodeData | Task/Ackermann-function/Coq/ackermann-function-2.coq | [
"Info-ZIP"
] |
insert into item (item_id, item_name, item_desc, item_price) values(1,'item One', 'test 1', 35.12);
insert into item (item_id, item_name, item_desc, item_price) values(2,'Pogo stick', 'Pogo stick', 466.12);
insert into item (item_id, item_name, item_desc, item_price) values(3,'Raft', 'Raft', 345.12);
insert into ite... | SQL | 3 | flyingcanopy/tutorials | persistence-modules/spring-hibernate-5/src/test/resources/import.sql | [
"MIT"
] |
<!DOCTYPE html> <!-- -*- mode: web-mode; engine: ctemplate -*- -->
<html>
<head>
{{> plan-a/head }}
<link rel="stylesheet" type="text/css" href="stylesheets/download.css">
<meta name="description" content="Haskell Platform is a Haskell distribution with batteries included">
<script ... | mupad | 3 | TikhonJelvis/haskell-platform | website/plan-a/mac.html.mu | [
"BSD-3-Clause"
] |
#
# Aliases
#
alias glfsi='git lfs install'
alias glfst='git lfs track'
alias glfsls='git lfs ls-files'
alias glfsmi='git lfs migrate import --include='
#
# Functions
#
function gplfs() {
local b="$(git_current_branch)"
git lfs push origin "$b" --all
}
| Shell | 4 | chensanle/ohmyzsh | plugins/git-lfs/git-lfs.plugin.zsh | [
"MIT"
] |
//
// This file is part of the Simutrans project under the Artistic License.
// (see LICENSE.txt)
//
//
// Tests for wayobj
//
function test_wayobj_build_straight()
{
local pl = player_x(0)
local remover = command_x(tool_remove_wayobj)
local rail = way_desc_x.get_available_ways(wt_rail, st_flat)[0]
local overhe... | Squirrel | 5 | Andarix/simutrans_nightly | tests/tests/test_wayobj.nut | [
"Artistic-1.0"
] |
# Copyright (c) 2021 vesoft inc. All rights reserved.
#
# This source code is licensed under Apache 2.0 License.
Feature: Nebula service termination test
# All nebula services shold exit as expected after termination
Scenario: Basic termination test
Given a nebulacluster with 1 graphd and 1 metad and 1 storage... | Cucumber | 2 | liuqian1990/nebula | tests/tck/cluster/terminate.feature | [
"Apache-2.0"
] |
import React from "react"
import { graphql, Link } from "gatsby"
import Img from "gatsby-image"
import Layout from "../components/layout_1"
const Article = ({ data }) => {
return (
<Layout>
<Link to="/">Go back to index page</Link>
<div>
<h2>{data.article.title}</h2>
{data.article.met... | JavaScript | 4 | Pabelnedved/ghostlocoko | benchmarks/source-cosmicjs/src/templates/article.js | [
"MIT"
] |
{#
Copyright (C) 2017 Fabian Franz
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice,
this list of cond... | Volt | 4 | marcquark/plugins | security/tor/src/opnsense/mvc/app/views/OPNsense/Tor/diagnostics.volt | [
"BSD-2-Clause"
] |
// compile-flags: -C no-prepopulate-passes
#![crate_type = "lib"]
pub enum E {
A,
B,
}
// CHECK-LABEL: @exhaustive_match
#[no_mangle]
pub fn exhaustive_match(e: E) -> u8 {
// CHECK: switch{{.*}}, label %[[OTHERWISE:[a-zA-Z0-9_]+]] [
// CHECK-NEXT: i[[TY:[0-9]+]] [[DISCR:[0-9]+]], label %[[A:[a-zA-Z0-9_]+]]
/... | Rust | 4 | mbc-git/rust | src/test/codegen/match.rs | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] |
Prefix(:=<http://example.org/>)
Ontology(:TestEquivalentClass
EquivalentClasses(:x :y :z)
)
| Web Ontology Language | 3 | jmcmurry/SciGraph | SciGraph-core/src/test/resources/ontologies/cases/TestEquivalentClasses.owl | [
"Apache-2.0"
] |
---
prev: java.textile
next: searchbird.textile
title: An introduction to Finagle
layout: post
---
"Finagle":https://github.com/twitter/finagle 是 Twitter 研发的RPC系统。
"这篇博客":https://blog.twitter.com/2011/finagle-a-protocol-agnostic-rpc-system 解释了其动机和核心设计原则, "finagle README":https://github.com/twitter/finagle/bl... | Textile | 5 | AstronomiaDev/scala_school | web/zh_cn/finagle.textile | [
"Apache-2.0"
] |
# Finder exports the types required to find patterns
# in some files.
module finder
import matcher
import file_resolver
import reporter
import mimesniff
# Finder class puts it all together, finds matchers in the files
# and sends them to the reporter.
class Finder
# matcher to use to find hits in the files.
v... | Nit | 5 | PuerkitoBio/nitfind | finder.nit | [
"BSD-3-Clause"
] |
--TEST--
PDO Common: Bug #77849 (Unexpected segfault attempting to use cloned PDO object)
--EXTENSIONS--
pdo
--SKIPIF--
<?php
$dir = getenv('REDIR_TEST_DIR');
if (false == $dir) die('skip no driver');
require_once $dir . 'pdo_test.inc';
PDOTest::skip();
?>
--FILE--
<?php
if (getenv('REDIR_TEST_DIR') === false) putenv('... | PHP | 3 | NathanFreeman/php-src | ext/pdo/tests/bug_77849.phpt | [
"PHP-3.01"
] |
% run> gs -q -sDEVICE=nullpage postscript.ps
(Hello World\n) print quit | PostScript | 1 | Gabrielarodrigues10/ga | p/PostScript.ps | [
"MIT"
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.