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
class: draw; dpi: 96; size: A6*; text { text: "TEST"; font: "Roboto Slab"; font-size: 48pt; }
CLIPS
2
asmuth-archive/travistest
test/draw/text_custom_font.clp
[ "Apache-2.0" ]
Red [ Title: "Red VID simple test script" Author: "Nenad Rakocevic" File: %vid6.red Needs: 'View ] system/view/VID/debug?: yes view [ at 320x1 base 1x400 black below left base 200x1 button 50x50 button "OK" text "text" cyan field drop-down check yellow radio yellow drop-list progress slider return below center base 200x1 button 50x50 button "OK" text "text" cyan field drop-down check yellow radio yellow drop-list progress slider return below right base 200x1 button 50x50 button "OK" text "text" cyan field drop-down check yellow radio yellow drop-list progress slider ] system/view/VID/debug?: no
Red
3
0xflotus/red
tests/vid6.red
[ "BSL-1.0", "BSD-3-Clause" ]
 ; https://autohotkey.com/board/topic/33506-read-ini-file-in-one-go/ ReadIni( filename = 0 ) ; Read a whole .ini file and creates variables like this: ; %Section%%Key% = %value% { Local s, c, p, key, k if not filename filename := SubStr( A_ScriptName, 1, -3 ) . "ini" FileRead, s, %filename% Loop, Parse, s, `n`r, %A_Space%%A_Tab% { c := SubStr(A_LoopField, 1, 1) if (c="[") key := SubStr(A_LoopField, 2, -1) else if (c=";") continue else { p := InStr(A_LoopField, "=") if p { k := SubStr(A_LoopField, 1, p-1) %key%%k% := SubStr(A_LoopField, p+1) } } } }
AutoHotkey
4
seresta/Win-Virtual-Desktop-Enhancer
libraries/read-ini.ahk
[ "MIT" ]
import io/File import os/Env import text/StringTokenizer /** * Utilities for launching processes */ ShellUtils: class { /** * @return the path of an executable, if it can be found. It looks in the PATH * environment variable. */ findExecutable: static func (executableName: String, crucial := false) -> File { file: File version (windows) { file = _findInPath("%s.exe" format(executableName)) if (file) return file } file = _findInPath(executableName) if (file) return file if (crucial) { Exception new("Command not found: " + executableName) throw() } null } _findInPath: static func (executableName: String) -> File { simple := File new(executableName) if(simple exists?() && simple file?()) { return simple } pathVar := Env get("PATH") if (pathVar == null) { pathVar = Env get("Path") if (pathVar == null) { pathVar = Env get("path") } } if (pathVar == null) { "PATH environment variable not found!" println() return null } st := pathVar split(File pathDelimiter) for(foo in st) { path := foo + File separator + executableName file := File new(path) if (file exists?()) { return file } } null } }
ooc
4
fredrikbryntesson/launchtest
sdk/os/ShellUtils.ooc
[ "MIT" ]
CREATE TABLE `tb_ygyyvdctrs` ( `col_hirzxaomit` varbinary(145) NOT NULL, `col_rpxmbgbwos` longblob, `col_emexlkeymz` enum('enum_or_set_0','enum_or_set_1','enum_or_set_2') CHARACTER SET utf8mb4 DEFAULT 'enum_or_set_0', `col_ibmogxgtyp` set('enum_or_set_0','enum_or_set_1','enum_or_set_2') CHARACTER SET latin1 DEFAULT 'enum_or_set_0', `col_yzbwkjwzqw` int(10) unsigned zerofill NOT NULL, `col_dmdpojzsct` varbinary(166) DEFAULT NULL, `col_oxgbfbgzov` double(112,2) DEFAULT NULL, `col_zkdwjtabnw` smallint(5) unsigned NOT NULL, `col_dxgsghrizm` tinyblob, `col_bowjbzwvyw` date DEFAULT NULL, `col_inneappfsm` varchar(112) CHARACTER SET utf8mb4 DEFAULT NULL, UNIQUE KEY `col_emexlkeymz` (`col_emexlkeymz`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
SQL
3
yuanweikang2020/canal
parse/src/test/resources/ddl/alter/mysql_17.sql
[ "Apache-2.0" ]
-- enable under the main muc component local queue = require "util.queue"; local new_throttle = require "util.throttle".create; local timer = require "util.timer"; -- we max to 500 participants per meeting so this should be enough, we are not suppose to handle all -- participants in one meeting local PRESENCE_QUEUE_MAX_SIZE = 1000; -- default to 5 participants per second local join_rate_per_conference = module:get_option_number("muc_rate_joins", 5); -- Measure/monitor the room rate limiting queue local measure = require "core.statsmanager".measure; local measure_longest_queue = measure("distribution", "/mod_" .. module.name .. "/longest_queue"); local measure_rooms_with_queue = measure("rate", "/mod_" .. module.name .. "/rooms_with_queue"); -- throws a stat that the queue was full, counts the total number of times we hit it local measure_full_queue = measure("rate", "/mod_" .. module.name .. "/full_queue"); -- keeps track of the total times we had an error processing the queue local measure_errors_processing_queue = measure("rate", "/mod_" .. module.name .. "/errors_processing_queue"); -- we keep track here what was the longest queue we have seen local stat_longest_queue = 0; -- Adds item to the queue -- @returns false if queue is full and item was not added, true otherwise local function add_item_to_queue(joining_queue, item, room, from) if not joining_queue:push(item) then module:log('error', 'Error pushing presence in queue for %s in %s', from, room.jid); measure_full_queue(); return false; else -- check is this the longest queue and if so throws a stat if joining_queue:count() > stat_longest_queue then stat_longest_queue = joining_queue:count(); measure_longest_queue(stat_longest_queue); end return true; end end -- process join_rate_presence_queue in the room and pops element passing them to handle_normal_presence -- returns 1 if we want to reschedule it after 1 second local function timer_process_queue_elements (room) local presence_queue = room.join_rate_presence_queue; if not presence_queue or presence_queue:count() == 0 then return; end for _ = 1, join_rate_per_conference do local ev = presence_queue:pop(); if ev then -- we mark what we pass here so we can skip it on the next muc-occupant-pre-join event ev.stanza.delayed_join_skip = true; room:handle_normal_presence(ev.origin, ev.stanza); end end -- if there are elements left, schedule an execution in a second if presence_queue:count() > 0 then return 1; else room.join_rate_queue_timer = false; end end -- we check join rate before occupant joins. If rate is exceeded we queue the events and start a timer -- that will run every second processing the events passing them to the room handling function handle_normal_presence -- from where those arrived, this way we keep a maximum rate of joining module:hook("muc-occupant-pre-join", function (event) local room, stanza = event.room, event.stanza; -- skipping events we had produced and clear our flag if stanza.delayed_join_skip == true then event.stanza.delayed_join_skip = nil; return false; end local throttle = room.join_rate_throttle; if not room.join_rate_throttle then throttle = new_throttle(join_rate_per_conference, 1); -- rate per one second room.join_rate_throttle = throttle; end if not throttle:poll(1) then if not room.join_rate_presence_queue then -- if this is the first item for a room we increment the stat for rooms with queues measure_rooms_with_queue(); room.join_rate_presence_queue = queue.new(PRESENCE_QUEUE_MAX_SIZE); end if not add_item_to_queue(room.join_rate_presence_queue, event, room, stanza.attr.from) then -- let's not stop processing the event return false; end if not room.join_rate_queue_timer then timer.add_task(1, function () local status, result = pcall(timer_process_queue_elements, room); if not status then -- there was an error in the timer function module:log('error', 'Error processing queue: %s', result); measure_errors_processing_queue(); -- let's re-schedule timer so we do not lose the queue return 1; end return result; end); room.join_rate_queue_timer = true; end return true; -- we stop execution, so we do not process this join at the moment end if room.join_rate_queue_timer then -- there is timer so we need to order the presences, put it in the queue -- if add fails as queue is full we return false and the event will continue processing, we risk re-order -- but not losing it return add_item_to_queue(room.join_rate_presence_queue, event, room, stanza.attr.from); end end, 9); -- as we will rate limit joins we need to be the first to execute -- we ran it after muc_max_occupants which is with priority 10, there is nothing to rate limit -- if max number of occupants is reached -- clear queue on room destroy so timer will skip next run if any module:hook('muc-room-destroyed',function(event) event.room.join_rate_presence_queue = nil; end);
Lua
4
seabass-labrax/jitsi-meet
resources/prosody-plugins/mod_muc_rate_limit.lua
[ "Apache-2.0" ]
/// <reference path='fourslash.ts' /> // @jsx: preserve // @filename: foo.tsx ////interface P { //// a: number; //// b: string; //// c: number[]; //// d: any; ////} ////const A = ({ a, b, c, d }: P) => //// <div>{a}{b}{c}{d}</div>; ////const props = { a: 1, b: "" }; //// ////const C1 = () => //// <A a={1} b={""}></A> ////const C2 = () => //// <A {...props}></A> ////const C3 = () => //// <A c={[]} {...props}></A> ////const C4 = () => //// <A></A> goTo.file("foo.tsx"); verify.codeFixAll({ fixId: "fixMissingAttributes", fixAllDescription: ts.Diagnostics.Add_all_missing_attributes.message, newFileContent: `interface P { a: number; b: string; c: number[]; d: any; } const A = ({ a, b, c, d }: P) => <div>{a}{b}{c}{d}</div>; const props = { a: 1, b: "" }; const C1 = () => <A a={1} b={""} c={[]} d={undefined}></A> const C2 = () => <A c={[]} d={undefined} {...props}></A> const C3 = () => <A d={undefined} c={[]} {...props}></A> const C4 = () => <A a={0} b={""} c={[]} d={undefined}></A>` });
TypeScript
4
monciego/TypeScript
tests/cases/fourslash/codeFixAddMissingAttributes_all.ts
[ "Apache-2.0" ]
: LIST ( size -- ) CREATE DUP , CELLS ALLOT ; : LIST@ ( index list -- value ) SWAP 1 + CELLS + @ ; : LIST! ( value index list -- ) SWAP 1 + CELLS + ! ; : STALINSORT ( list -- sorted-list ) 0 OVER LIST@ SWAP 1 SWAP DUP @ 1 DO I OVER LIST@ ROT ROT >R >R 2DUP > IF DROP 0 ELSE 1 THEN R> + R> LOOP 2DUP ! SWAP 0 SWAP 1 - DO I OVER >R SWAP LIST! R> -1 +LOOP ;
Forth
3
twofist/stalin-sort
forth/stalin-sort.fth
[ "MIT" ]
#include <ATen/cuda/cub.cuh> #include <gtest/gtest.h> TEST(NumBits, CubTest) { using at::cuda::cub::get_num_bits; ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000000000000000UL), 1); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000000000000001UL), 1); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000000000000010UL), 2); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000000000000011UL), 2); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000000000000100UL), 3); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000000000000111UL), 3); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000000000001000UL), 4); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000000000001111UL), 4); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000000000010000UL), 5); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000000000011111UL), 5); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000000000100000UL), 6); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000000000111111UL), 6); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000000001000000UL), 7); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000000001111111UL), 7); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000000010000000UL), 8); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000000011111111UL), 8); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000000100000000UL), 9); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000000111111111UL), 9); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000001000000000UL), 10); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000001111111111UL), 10); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000010000000000UL), 11); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000011111111111UL), 11); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000100000000000UL), 12); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000000111111111111UL), 12); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000001000000000000UL), 13); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000001111111111111UL), 13); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000010000000000000UL), 14); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000011111111111111UL), 14); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000100000000000000UL), 15); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000000111111111111111UL), 15); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000001000000000000000UL), 16); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000001111111111111111UL), 16); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000010000000000000000UL), 17); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000011111111111111111UL), 17); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000100000000000000000UL), 18); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000000111111111111111111UL), 18); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000001000000000000000000UL), 19); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000001111111111111111111UL), 19); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000010000000000000000000UL), 20); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000011111111111111111111UL), 20); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000100000000000000000000UL), 21); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000000111111111111111111111UL), 21); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000001000000000000000000000UL), 22); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000001111111111111111111111UL), 22); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000010000000000000000000000UL), 23); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000011111111111111111111111UL), 23); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000100000000000000000000000UL), 24); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000000111111111111111111111111UL), 24); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000001000000000000000000000000UL), 25); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000001111111111111111111111111UL), 25); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000010000000000000000000000000UL), 26); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000011111111111111111111111111UL), 26); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000100000000000000000000000000UL), 27); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000000111111111111111111111111111UL), 27); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000001000000000000000000000000000UL), 28); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000001111111111111111111111111111UL), 28); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000010000000000000000000000000000UL), 29); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000011111111111111111111111111111UL), 29); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000100000000000000000000000000000UL), 30); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000000111111111111111111111111111111UL), 30); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000001000000000000000000000000000000UL), 31); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000001111111111111111111111111111111UL), 31); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000010000000000000000000000000000000UL), 32); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000011111111111111111111111111111111UL), 32); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000100000000000000000000000000000000UL), 33); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000000111111111111111111111111111111111UL), 33); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000001000000000000000000000000000000000UL), 34); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000001111111111111111111111111111111111UL), 34); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000010000000000000000000000000000000000UL), 35); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000011111111111111111111111111111111111UL), 35); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000100000000000000000000000000000000000UL), 36); ASSERT_EQ(get_num_bits(0b0000000000000000000000000000111111111111111111111111111111111111UL), 36); ASSERT_EQ(get_num_bits(0b0000000000000000000000000001000000000000000000000000000000000000UL), 37); ASSERT_EQ(get_num_bits(0b0000000000000000000000000001111111111111111111111111111111111111UL), 37); ASSERT_EQ(get_num_bits(0b0000000000000000000000000010000000000000000000000000000000000000UL), 38); ASSERT_EQ(get_num_bits(0b0000000000000000000000000011111111111111111111111111111111111111UL), 38); ASSERT_EQ(get_num_bits(0b0000000000000000000000000100000000000000000000000000000000000000UL), 39); ASSERT_EQ(get_num_bits(0b0000000000000000000000000111111111111111111111111111111111111111UL), 39); ASSERT_EQ(get_num_bits(0b0000000000000000000000001000000000000000000000000000000000000000UL), 40); ASSERT_EQ(get_num_bits(0b0000000000000000000000001111111111111111111111111111111111111111UL), 40); ASSERT_EQ(get_num_bits(0b0000000000000000000000010000000000000000000000000000000000000000UL), 41); ASSERT_EQ(get_num_bits(0b0000000000000000000000011111111111111111111111111111111111111111UL), 41); ASSERT_EQ(get_num_bits(0b0000000000000000000000100000000000000000000000000000000000000000UL), 42); ASSERT_EQ(get_num_bits(0b0000000000000000000000111111111111111111111111111111111111111111UL), 42); ASSERT_EQ(get_num_bits(0b0000000000000000000001000000000000000000000000000000000000000000UL), 43); ASSERT_EQ(get_num_bits(0b0000000000000000000001111111111111111111111111111111111111111111UL), 43); ASSERT_EQ(get_num_bits(0b0000000000000000000010000000000000000000000000000000000000000000UL), 44); ASSERT_EQ(get_num_bits(0b0000000000000000000011111111111111111111111111111111111111111111UL), 44); ASSERT_EQ(get_num_bits(0b0000000000000000000100000000000000000000000000000000000000000000UL), 45); ASSERT_EQ(get_num_bits(0b0000000000000000000111111111111111111111111111111111111111111111UL), 45); ASSERT_EQ(get_num_bits(0b0000000000000000001000000000000000000000000000000000000000000000UL), 46); ASSERT_EQ(get_num_bits(0b0000000000000000001111111111111111111111111111111111111111111111UL), 46); ASSERT_EQ(get_num_bits(0b0000000000000000010000000000000000000000000000000000000000000000UL), 47); ASSERT_EQ(get_num_bits(0b0000000000000000011111111111111111111111111111111111111111111111UL), 47); ASSERT_EQ(get_num_bits(0b0000000000000000100000000000000000000000000000000000000000000000UL), 48); ASSERT_EQ(get_num_bits(0b0000000000000000111111111111111111111111111111111111111111111111UL), 48); ASSERT_EQ(get_num_bits(0b0000000000000001000000000000000000000000000000000000000000000000UL), 49); ASSERT_EQ(get_num_bits(0b0000000000000001111111111111111111111111111111111111111111111111UL), 49); ASSERT_EQ(get_num_bits(0b0000000000000010000000000000000000000000000000000000000000000000UL), 50); ASSERT_EQ(get_num_bits(0b0000000000000011111111111111111111111111111111111111111111111111UL), 50); ASSERT_EQ(get_num_bits(0b0000000000000100000000000000000000000000000000000000000000000000UL), 51); ASSERT_EQ(get_num_bits(0b0000000000000111111111111111111111111111111111111111111111111111UL), 51); ASSERT_EQ(get_num_bits(0b0000000000001000000000000000000000000000000000000000000000000000UL), 52); ASSERT_EQ(get_num_bits(0b0000000000001111111111111111111111111111111111111111111111111111UL), 52); ASSERT_EQ(get_num_bits(0b0000000000010000000000000000000000000000000000000000000000000000UL), 53); ASSERT_EQ(get_num_bits(0b0000000000011111111111111111111111111111111111111111111111111111UL), 53); ASSERT_EQ(get_num_bits(0b0000000000100000000000000000000000000000000000000000000000000000UL), 54); ASSERT_EQ(get_num_bits(0b0000000000111111111111111111111111111111111111111111111111111111UL), 54); ASSERT_EQ(get_num_bits(0b0000000001000000000000000000000000000000000000000000000000000000UL), 55); ASSERT_EQ(get_num_bits(0b0000000001111111111111111111111111111111111111111111111111111111UL), 55); ASSERT_EQ(get_num_bits(0b0000000010000000000000000000000000000000000000000000000000000000UL), 56); ASSERT_EQ(get_num_bits(0b0000000011111111111111111111111111111111111111111111111111111111UL), 56); ASSERT_EQ(get_num_bits(0b0000000100000000000000000000000000000000000000000000000000000000UL), 57); ASSERT_EQ(get_num_bits(0b0000000111111111111111111111111111111111111111111111111111111111UL), 57); ASSERT_EQ(get_num_bits(0b0000001000000000000000000000000000000000000000000000000000000000UL), 58); ASSERT_EQ(get_num_bits(0b0000001111111111111111111111111111111111111111111111111111111111UL), 58); ASSERT_EQ(get_num_bits(0b0000010000000000000000000000000000000000000000000000000000000000UL), 59); ASSERT_EQ(get_num_bits(0b0000011111111111111111111111111111111111111111111111111111111111UL), 59); ASSERT_EQ(get_num_bits(0b0000100000000000000000000000000000000000000000000000000000000000UL), 60); ASSERT_EQ(get_num_bits(0b0000111111111111111111111111111111111111111111111111111111111111UL), 60); ASSERT_EQ(get_num_bits(0b0001000000000000000000000000000000000000000000000000000000000000UL), 61); ASSERT_EQ(get_num_bits(0b0001111111111111111111111111111111111111111111111111111111111111UL), 61); ASSERT_EQ(get_num_bits(0b0010000000000000000000000000000000000000000000000000000000000000UL), 62); ASSERT_EQ(get_num_bits(0b0011111111111111111111111111111111111111111111111111111111111111UL), 62); ASSERT_EQ(get_num_bits(0b0100000000000000000000000000000000000000000000000000000000000000UL), 63); ASSERT_EQ(get_num_bits(0b0111111111111111111111111111111111111111111111111111111111111111UL), 63); ASSERT_EQ(get_num_bits(0b1000000000000000000000000000000000000000000000000000000000000000UL), 64); ASSERT_EQ(get_num_bits(0b1111111111111111111111111111111111111111111111111111111111111111UL), 64); }
Cuda
4
Hacky-DH/pytorch
aten/src/ATen/test/cuda_cub_test.cu
[ "Intel" ]
<?xml version='1.0' encoding='UTF-8'?> <Project Type="Project" LVVersion="12008004"> <Item Name="My Computer" Type="My Computer"> <Property Name="NI.SortType" Type="Int">3</Property> <Property Name="server.app.propertiesEnabled" Type="Bool">true</Property> <Property Name="server.control.propertiesEnabled" Type="Bool">true</Property> <Property Name="server.tcp.enabled" Type="Bool">false</Property> <Property Name="server.tcp.port" Type="Int">0</Property> <Property Name="server.tcp.serviceName" Type="Str">My Computer/VI Server</Property> <Property Name="server.tcp.serviceName.default" Type="Str">My Computer/VI Server</Property> <Property Name="server.vi.callsEnabled" Type="Bool">true</Property> <Property Name="server.vi.propertiesEnabled" Type="Bool">true</Property> <Property Name="specify.custom.address" Type="Bool">false</Property> <Item Name="Unindex and Unbundle.xnode" Type="XNode" URL="../Unindex and Unbundle.xnode"/> <Item Name="Dependencies" Type="Dependencies"> <Item Name="vi.lib" Type="Folder"> <Item Name="VariantType.lvlib" Type="Library" URL="/&lt;vilib&gt;/Utility/VariantDataType/VariantType.lvlib"/> <Item Name="NI_XNodeSupport.lvlib" Type="Library" URL="/&lt;vilib&gt;/XNodeSupport/NI_XNodeSupport.lvlib"/> <Item Name="LVPositionTypeDef.ctl" Type="VI" URL="/&lt;vilib&gt;/Utility/miscctls.llb/LVPositionTypeDef.ctl"/> <Item Name="Read BMP File.vi" Type="VI" URL="/&lt;vilib&gt;/picture/bmp.llb/Read BMP File.vi"/> <Item Name="Read BMP File Data.vi" Type="VI" URL="/&lt;vilib&gt;/picture/bmp.llb/Read BMP File Data.vi"/> <Item Name="Read BMP Header Info.vi" Type="VI" URL="/&lt;vilib&gt;/picture/bmp.llb/Read BMP Header Info.vi"/> <Item Name="Calc Long Word Padded Width.vi" Type="VI" URL="/&lt;vilib&gt;/picture/bmp.llb/Calc Long Word Padded Width.vi"/> <Item Name="Flip and Pad for Picture Control.vi" Type="VI" URL="/&lt;vilib&gt;/picture/bmp.llb/Flip and Pad for Picture Control.vi"/> <Item Name="imagedata.ctl" Type="VI" URL="/&lt;vilib&gt;/picture/picture.llb/imagedata.ctl"/> <Item Name="Unflatten Pixmap.vi" Type="VI" URL="/&lt;vilib&gt;/picture/pixmap.llb/Unflatten Pixmap.vi"/> <Item Name="Draw True-Color Pixmap.vi" Type="VI" URL="/&lt;vilib&gt;/picture/picture.llb/Draw True-Color Pixmap.vi"/> <Item Name="Move Pen.vi" Type="VI" URL="/&lt;vilib&gt;/picture/picture.llb/Move Pen.vi"/> <Item Name="Draw Line.vi" Type="VI" URL="/&lt;vilib&gt;/picture/picture.llb/Draw Line.vi"/> <Item Name="Set Pen State.vi" Type="VI" URL="/&lt;vilib&gt;/picture/picture.llb/Set Pen State.vi"/> <Item Name="Draw Unflattened Pixmap.vi" Type="VI" URL="/&lt;vilib&gt;/picture/picture.llb/Draw Unflattened Pixmap.vi"/> <Item Name="Draw 4-Bit Pixmap.vi" Type="VI" URL="/&lt;vilib&gt;/picture/picture.llb/Draw 4-Bit Pixmap.vi"/> <Item Name="Draw 8-Bit Pixmap.vi" Type="VI" URL="/&lt;vilib&gt;/picture/picture.llb/Draw 8-Bit Pixmap.vi"/> <Item Name="Draw 1-Bit Pixmap.vi" Type="VI" URL="/&lt;vilib&gt;/picture/picture.llb/Draw 1-Bit Pixmap.vi"/> <Item Name="LVRectTypeDef.ctl" Type="VI" URL="/&lt;vilib&gt;/Utility/miscctls.llb/LVRectTypeDef.ctl"/> <Item Name="TRef Traverse for References.vi" Type="VI" URL="/&lt;vilib&gt;/Utility/traverseref.llb/TRef Traverse for References.vi"/> <Item Name="TRef TravTarget.ctl" Type="VI" URL="/&lt;vilib&gt;/Utility/traverseref.llb/TRef TravTarget.ctl"/> <Item Name="LVPointTypeDef.ctl" Type="VI" URL="/&lt;vilib&gt;/Utility/miscctls.llb/LVPointTypeDef.ctl"/> <Item Name="LVBoundsTypeDef.ctl" Type="VI" URL="/&lt;vilib&gt;/Utility/miscctls.llb/LVBoundsTypeDef.ctl"/> <Item Name="LVNumericRepresentation.ctl" Type="VI" URL="/&lt;vilib&gt;/Numeric/LVNumericRepresentation.ctl"/> </Item> <Item Name="user.lib" Type="Folder"> <Item Name="Scripting Tools.lvlib" Type="Library" URL="/&lt;userlib&gt;/_LAVAcr/Scripting Tools/Scripting Tools.lvlib"/> </Item> <Item Name="Create a constant from terminal.vi" Type="VI" URL="../../../../VI Scripting/Scripting Tools/Public/Create a constant from terminal.vi"/> <Item Name="Create a constant from variant.vi" Type="VI" URL="../../../../VI Scripting/Scripting Tools/Public/Create a constant from variant.vi"/> <Item Name="Create a control from variant.vi" Type="VI" URL="../../../../VI Scripting/Scripting Tools/Public/Create a control from variant.vi"/> <Item Name="Create Array Size.vi" Type="VI" URL="../../../../VI Scripting/Scripting Tools/Primatives/Array/Create Array Size.vi"/> <Item Name="Create Index Array Multiple.vi" Type="VI" URL="../../../../VI Scripting/Scripting Tools/Primatives/Array/Create Index Array Multiple.vi"/> <Item Name="Delete LV Object.vi" Type="VI" URL="../../../../VI Scripting/Scripting Tools/Public/Delete LV Object.vi"/> <Item Name="Scripting Tools.lvlib" Type="Library" URL="../../../../VI Scripting/Scripting Tools/Scripting Tools.lvlib"/> <Item Name="Unidenx and undbundle template.vi" Type="VI" URL="../Unidenx and undbundle template.vi"/> <Item Name="Wire 2 terminal function.vi" Type="VI" URL="../../../../VI Scripting/Scripting Tools/Public/Wire 2 terminal function.vi"/> <Item Name="Wire n terminal function.vi" Type="VI" URL="../../../../VI Scripting/Scripting Tools/Public/Wire n terminal function.vi"/> </Item> <Item Name="Build Specifications" Type="Build"/> </Item> </Project>
LabVIEW
2
gb119/LabVIEW-Bits
LabVIEW API/XNodes/Array XNodes/Unindex and unbundle/Unindex and Unbundle.lvproj
[ "BSD-3-Clause" ]
exec("swigtest.start", -1); testString = "Scilab test string"; checkequal(UCharFunction(testString), testString, "UCharFunction(testString)"); checkequal(SCharFunction(testString), testString, "SCharFunction(testString)"); checkequal(CUCharFunction(testString), testString, "CUCharFunction(testString)"); checkequal(CSCharFunction(testString), testString, "CSCharFunction(testString)"); //checkequal(CharFunction(testString), testString, "CharFunction(testString)"); //checkequal(CCharFunction(testString), testString, "CCharFunction(testString)"); try tNum = new_TNum(); catch swigtesterror(); end //TNumber_DigitsMemberA_get() //TNumber_DigitsMemberA_set //TNumber_DigitsMemberB_get() //TNumber_DigitsMemberB_set try delete_TNum(tNum); catch swigtesterror(); end try dirTest = new_DirTest(); catch swigtesterror(); end checkequal(DirTest_UCharFunction(dirTest, testString), testString, "DirTest_UCharFunction"); checkequal(DirTest_SCharFunction(dirTest, testString), testString, "DirTest_SCharFunction(dirTest, testString)"); checkequal(DirTest_CUCharFunction(dirTest, testString), testString, "DirTest_CUCharFunction(dirTest, testString)"); checkequal(DirTest_CSCharFunction(dirTest, testString), testString, "DirTest_CSharFunction(dirTest, testString)"); //checkequal(DirTest_CharFunction(dirTest, testString), testString, "DirTest_CharFunction(dirTest, testString)"); //checkequal(DirTest_CCharFunction(dirTest, testString), testString, "DirTest_CCharFunction(dirTest, testString)"); try delete_DirTest(dirTest); catch swigtesterror(); end exec("swigtest.quit", -1);
Scilab
2
kyletanyag/LL-Smartcard
cacreader/swig-4.0.2/Examples/test-suite/scilab/apply_strings_runme.sci
[ "BSD-3-Clause" ]
(module (type $t0 (func (param i64) (result i64))) (type $t1 (func (result i32))) (import "./other1.wat" "getI64" (func $getI641 (type $t0))) (import "./other2.wat" "getI64" (func $getI642 (type $t0))) (func $testI64 (type $t1) (result i32) i64.const 1152921504606846976 call $getI641 call $getI642 i64.const 1152921504606846976 i64.sub i32.wrap/i64) (export "testI64" (func $testI64)))
WebAssembly
4
1shenxi/webpack
test/cases/wasm/imports-many-direct/wasm.wat
[ "MIT" ]
Rebol [Title: "Google Code Prettify Datatypes"] re: func [s /i] [rejoin compose ["/^^" (s) "/" either i ["i"][""]]] ; little helper for standard grammar regex used date-re: "\d{1,2}[\-\/](\d{1,2}|\w{3,9})[\-\/]\d{2,4}" ; naive date! regex string-re: {\"(?:[^^\"\\]|\\[\s\S])*(?:\"|$)} brace-re: "\{(?:[^^\}\^^]|\^^[\s\S])*(?:\}|$)" ; TODO - could build this from string-re block-re: "\[(?:[^^\]\\]|\\[\s\S])*(?:\]|$)" tag-re: "\<(?:[^^\>\\]|\\[\s\S])*(?:\>|$)" ; TODO - could build this from string-re number-re: "(?:[.,]\d+|\d+['\d]*(?:[.,]\d*)?)(?:e[-+]?\d+)?" word-re: "[A-Za-z=\-?!_*+.`~&][A-Za-z0-9=\-!?_*+.`~&]*" |: "|" types: compose/deep [ ; comments comment! [ PR_LITERAL ; comment_shebang -- Script tag (shebang!) (re/i "#![^^\r\n]+") ; comment_line -- A line comment that starts with ; (re ";[^^\r\n]*") ; comment_multiline_string -- Multi-line comment (re ["comment\s*" brace-re]) ; comment_multiline_block (re ["comment\s*" block-re]) ] ; type_literal ; logic logic! [ PR_LITERAL (re "#\[(?:true|false|yes|no|on|off)\]") ] ; none none! [ PR_LITERAL (re "#\[none\]") ] ; strings ; character char! [ PR_LITERAL (re/i "#^"(?:[^^^^^"]|\^^(?:[\^^^"\/\-A-Z]|\((?:[0-9A-F]{2,4}|tab|newline)\)))^"") ] string! [ PR_LITERAL ; string_quoted (re "^"(?:[^^^"\\]|\\[\s\S])*(?:^"|$)") ; string_multiline -- Multi-line string {braces} - allowed within: { ^{ ^} (re brace-re) ] ; string_tag_comment comment! [ PR_LITERAL (re "<!--(?:[^^-]|-(?!->))+-->") ] ; string_tag tag! [ PR_LITERAL (re "<[^^^"<=>\x00\x09\x0A\x0D\x20\u005D\u007F][^^>\x00]*>") ] file! [ PR_LITERAL ; string_file (re "%(?:[a-zA-Z?!.*&|=_~0-9'+\-,:\/\\@]|%[0-9A-F]{2})+") ; string_file_quoted (re "%^"(?:[^^^"])*^"") ] url! [ PR_LITERAL ; string_url (re "[a-zA-Z?!.*&|=_~][a-zA-Z?!.*&|=_~0-9'+-,]*:(?:[a-zA-Z?!.*&|=_~0-9'+\-,:\/@]|%[0-9A-F]{2})+") ] email! [ PR_LITERAL ; string_email (re "[\w\d\+\-\.]+\@[\w\d\+\-\.]+\b") ] binary! [ PR_LITERAL ; binary_base_two (re "2#\{(?:[01\r\n\t ])*\}") ; binary_base_sixty_four (re "64#\{(?:[0-9+\/a-yA-Z=\r\n\t ])*\}") ; binary_base_sixteen (re/i "(?:16)?#\{(?:[0-9a-f\r\n\t ])*\}") ] issue! [ PR_LITERAL ; string_issue (re "#[\w\d\-]+(?=[\s\n\t]|$)") ] ; values date! [ PR_LITERAL ; value_date (re [date-re "\/\d{1,2}\:\d{1,2}\:\d{1,2}(\+|\-)\d{1,2}\:(00|30)\b"]) (re [date-re "\/\d{1,2}\:\d{1,2}\:\d{1,2}\b"]) (re [date-re "\b"]) (re "\d{2,4}[\/\-](\d{1,2}|\w{3,9})[\/\-]\d{1,2}(?:\/\d{1,2}\:\d{1,2}(?:\:\d{1,2})?(?:[-+]\d{1,2}:[03]0)?)?") ] time! [ PR_LITERAL ; value_time (re "[-+]?\d{1,2}:\d{1,2}(?::\d{1,2}(?:\.\d+)?)?\b") ] tuple! [ PR_LITERAL ; value_tuple (re "\d+(?:\.\d+){2,9}") ] pair! [ PR_LITERAL ; value_pair (re/i ["[-+]?" number-re "x[-+]?" number-re]) ] ; [PR['PR_LITERAL'], /^\d(?:[\.\,\'\d]*)x\d(?:[\.\,\'\d]*)\b/] money! [ PR_LITERAL ; value_money (re ["[-+]?[A-Z]{0,3}\$" number-re]) ; [PR['PR_LITERAL'], /^\$\d[\d\.\,\']*\b/] ; [PR['PR_LITERAL'], /^[\+\-\w]{1,4}\$\d[\d\.\,\']*\b/] ] ; value_number number! [ PR_LITERAL (re/i ["[-+]?" number-re "%?"]) ; percent! [PR_LITERAL (re "(\+|\-|\d)(?:[\.\,\'\d]*)\%\b")] ; decimal! [PR_LITERAL (re "(\+|\-|\d)\d*(?:[\.\,]\d+)\b")] ; integer! [PR_LITERAL (re "(\+|\-|\d)\d*\b")] ] ; words datatype! [ PR_LITERAL ; word_datatype (re "(?:[A-Za-z\-]+)\!(?![A-Za-z0-9\-])") ] set-word! [ PR_LITERAL ; word_set (re [word-re "(?:\/" word-re "|\/\d+)*:"]) ] ; -- get-word! get-word! [ PR_LITERAL ; word_get (re [":" word-re]) ] ; -- lit-word! lit-word! [ PR_LITERAL ; word_lit (re ["'" word-re]) ] refinement! [ PR_LITERAL ; word_refine (re reduce ["\/" replace copy find next word-re "[" "]*" "]+" "(?![A-Za-z0-9\-])"]) ] op! [ PR_LITERAL ; word_native (re "(?:!=?=?|\*\*?|[+-]|\/\/?|<[=>]?|=[=?]?|>=?)(?![A-Za-z0-9\-])") ] function! [ PR_LITERAL (re make-keywords-string) ; [REB['function!'], /\b(?:to\-relative\-file\/as\-local|or\~|pwd|abs|map|not|rm|at|do|dp|ds|dt|cd|in|ls|to|or|if)\s/] ] rebol! [ PR_LITERAL ; word_header (re/i "(?:rebol|red(?:\/system)?|world|topaz)$") ] logic! [ PR_LITERAL ; word_logic (re "(?:true|false|yes|no|on|off)$") ] ; word_none none! [PR_LITERAL (re "none$")] ; word word! [PR_LITERAL (re word-re)] ; -- literal! ; literal! [PR_LITERAL (re ["#" block-re])] ]
R
4
JavascriptID/sourcerer-app
src/test/resources/samples/langs/Rebol/GCP-datatypes.r
[ "MIT" ]
<div class="container"> <h2>Please place a new Order!</h2> </div> <div class="container" *ngIf="response !== null"> <h3>Your order {{response.id}} was successfully placed, please check the status of order.</h3> </div> <div class="container" *ngIf="error !== null"> <h3>Your order could not be placed at the moment: {{error.message}}</h3> </div> <div class="container"> <form [formGroup]="form" *ngIf="this.form" (ngSubmit)="createOrder()"> <h3 class="container">Product Quantities:</h3> <div class="container" formArrayName="lineItems" *ngFor="let item of form.get('lineItems')['controls']; let i = index;"> <li class="form-group input-group-lg" [formGroupName]="i"> {{ form.controls.lineItems['controls'][i].controls.name.value }}: <input formControlName='quantity' placeholder='10'> <p>Only {{ form.controls.lineItems['controls'][i].controls.stock.value }} left in the stock!</p> </li> </div> &nbsp; <div class="container"> <h3>Payment Mode: <select class="form-group input-group-lg" formControlName="paymentMode"> <option *ngFor="let paymentMode of paymentModes"> {{paymentMode}} </option> </select> </h3> </div> &nbsp; <div class="container" formGroupName="shippingAddress"> <h3>Address:</h3> <input class="form-control" placeholder="Name" formControlName="name"> <input class="form-control" placeholder="House" formControlName="house"> <input class="form-control" placeholder="Street" formControlName="street"> <input class="form-control" placeholder="City" formControlName="city"> <input class="form-control" placeholder="Zip" formControlName="zip"> </div> &nbsp; <div class="form-group"> <button class="btn btn-danger btn-block btn-lg">Place Order</button> </div> </form> </div> <div class="container"> <button class="btn btn-danger btn-block btn-lg" (click)="getOrders()">Get Previous Orders</button> </div> <div class="container"> <button class="btn btn-danger btn-block btn-lg" (click)="getOrderStream()">Get Previous Order Stream </button> </div> <div class="container" *ngIf="previousOrders !== null"> <h2>Your orders placed so far:</h2> <ul> <li *ngFor="let order of previousOrders | async"> <p>Order ID: {{ order.id }}, Order Status: {{order.orderStatus}}, Order Message: {{order.responseMessage}}</p> </li> </ul> </div>
HTML
3
DBatOWL/tutorials
reactive-systems/frontend/src/app/orders/orders.component.html
[ "MIT" ]
local data_util = {} require 'torch' -- options = require '../options.lua' -- load dataset from the file system -- |name|: name of the dataset. It's currently either 'A' or 'B' function data_util.load_dataset(name, opt, nc) local tensortype = torch.getdefaulttensortype() torch.setdefaulttensortype('torch.FloatTensor') local new_opt = options.clone(opt) new_opt.manualSeed = torch.random(1, 10000) -- fix seed new_opt.nc = nc torch.manualSeed(new_opt.manualSeed) local data_loader = paths.dofile('../data/data.lua') new_opt.phase = new_opt.phase .. name local data = data_loader.new(new_opt.nThreads, new_opt) print("Dataset Size " .. name .. ": ", data:size()) torch.setdefaulttensortype(tensortype) return data end return data_util
Lua
4
uk0/CycleGAN
data/data_util.lua
[ "BSD-3-Clause" ]
Module: common-dylan-test-suite Synopsis: Tests for simple-random:common-dylan /*---*** andrewa: not used yet... define method chi-square (N :: <integer>, range :: <integer>) => (chi-square :: <integer>) let f = make(<simple-object-vector>, size: range, fill: 0); for (i from 0 below N) let rand = random(range); f[rand] := f[rand] + 1; end; let t = 0; for (i from 0 below range) t := t + f[i] * f[i] end; floor/(range * t, N) - N end method chi-square; */ define test test-random () // We should use chi-square somehow, but we don't want it to be slow. // Also, what value should it be returning? //---*** Fill this in... end test; define test test-<random> () //---*** Fill this in... end test; define suite simple-random-test-suite () test test-random; test test-<random>; end suite;
Dylan
4
lenoil98/opendylan
sources/common-dylan/tests/random-tests.dylan
[ "BSD-2-Clause" ]
/* * Copyright (c) 2020, Shannon Booth <shannon.ml.booth@gmail.com> * * SPDX-License-Identifier: BSD-2-Clause */ #pragma once #include <AK/Forward.h> #include <LibGfx/Point.h> namespace Gfx { class Triangle { public: Triangle(IntPoint a, IntPoint b, IntPoint c) : m_a(a) , m_b(b) , m_c(c) { m_det = (m_b.x() - m_a.x()) * (m_c.y() - m_a.y()) - (m_b.y() - m_a.y()) * (m_c.x() - m_a.x()); } IntPoint a() const { return m_a; } IntPoint b() const { return m_b; } IntPoint c() const { return m_c; } bool contains(IntPoint p) const { int x = p.x(); int y = p.y(); int ax = m_a.x(); int bx = m_b.x(); int cx = m_c.x(); int ay = m_a.y(); int by = m_b.y(); int cy = m_c.y(); if (m_det * ((bx - ax) * (y - ay) - (by - ay) * (x - ax)) <= 0) return false; if (m_det * ((cx - bx) * (y - by) - (cy - by) * (x - bx)) <= 0) return false; if (m_det * ((ax - cx) * (y - cy) - (ay - cy) * (x - cx)) <= 0) return false; return true; } String to_string() const; private: int m_det; IntPoint m_a; IntPoint m_b; IntPoint m_c; }; }
C
4
r00ster91/serenity
Userland/Libraries/LibGfx/Triangle.h
[ "BSD-2-Clause" ]
{{ IR_Remote_NewCog.spin Tom Doyle 2 March 2007 Panasonic IR Receiver - Parallax #350-00014 Receive and display codes sent from a Sony TV remote control. See "Infrared Decoding and Detection appnote" and "IR Remote for the Boe-Bot Book v1.1" on Parallax website for additional info on TV remotes. The procedure uses counter A to measure the pulse width of the signals received by the Panasonic IR Receiver. The procedure waits for a start pulse and then decodes the next 12 bits. The entire 12 bit result is returned. The lower 7 bits contain the actual key code. The upper 5 bits contain the device information (TV, VCR etc.) and are masked off for the display. Most TV Remotes send the code over and over again as long as the key is pressed. This allows auto repeat for TV operations like increasing volume. The volume continues to increase as long as you hold the 'volume up' key down. Even if the key is pressed for a very short time there is often more than one code sent. The best way to eliminate the auto key repeat is to look for an idle gap in the IR receiver output. There is a period of idle time (20-30 ms) between packets. The getSonyCode procedure will wait for an idle period controlled by the gapMin constant. This value can be adjusted to eliminate auto repeat while maintaining a fast response to a new keypress. If auto repeat is desired the indicated section of code at the start of the getSonyCode procedure can be commented out. The procedure sets a tolerance for the width of the start bit and the logic level 1 bit to allow for variation in the pulse widths sent out by different remotes. It is assumed that a bit is 0 if it is not a 1. The procedure to read the keycode ( getSonyCode ) is run in a separate cog. This allows the main program loop to continue without waiting for a key to be pressed. The getSonyCode procedure writes the NoNewCode value (255) into the keycode variable in main memory to indicate that no new keycode is available. When a keycode is received it writes the keycode into the main memory variable and terminates. With only 8 cogs available it seems to be a good idea to free up cogs rather than let them run forever. The main program can fire off the procedure if and when it is interested in a new keycode. }} CON _CLKMODE = XTAL1 + PLL16X ' 80 Mhz clock _XINFREQ = 5_000_000 NoNewCode = 255 ' indicates no new keycode received gapMin = 2000 ' minimum idle gap - adjust to eliminate auto repeat startBitMin = 2000 ' minimum length of start bit in us (2400 us reference) startBitMax = 2800 ' maximum length of start bit in us (2400 us reference) oneBitMin = 1000 ' minimum length of 1 (1200 us reference) oneBitMax = 1400 ' maximum length of 1 (1200 us reference) ' Sony TV remote key codes ' these work for the remotes I tested however your mileage may vary one = 0 two = 1 three = 2 four = 3 five = 4 six = 5 seven = 6 eight = 7 nine = 8 zero = 9 chUp = 16 chDn = 17 volUp = 18 volDn = 19 mute = 20 power = 21 last = 59 VAR byte cog long Stack[20] PUB Start(Pin, addrMainCode) : result {{ Pin - propeller pin connected to IR receiver addrMainCode - address of keycode variable in main memory }} stop byte[addrMainCode] := NoNewCode cog := cognew(getSonycode(Pin, addrMainCode), @Stack) + 1 result := cog PUB Stop {{ stop cog if in use }} if cog cogstop(cog~ -1) PUB getSonyCode(pin, addrMainCode) | irCode, index, pulseWidth, lockID {{ Decode the Sony TV Remote key code from pulses received by the IR receiver }} ' wait for idle period (ir receiver output = 1 for gapMin) ' comment out "auto repeat" code if auto key repeat is desired ' start of "auto repeat" code section dira[pin]~ index := 0 repeat if ina[Pin] == 1 index++ else index := 0 while index < gapMin ' end of "auto repeat" code section frqa := 1 ctra := 0 dira[pin]~ ' wait for a start pulse ( width > startBitMin and < startBitMax ) repeat ctra := (%10101 << 26 ) | (PIN) ' accumulate while A = 0 waitpne(0 << pin, |< Pin, 0) phsa:=0 ' zero width waitpeq(0 << pin, |< Pin, 0) ' start counting waitpne(0 << pin, |< Pin, 0) ' stop counting pulseWidth := phsa / (clkfreq / 1_000_000) + 1 while ((pulseWidth < startBitMin) OR (pulseWidth > startBitMax)) ' read in next 12 bits index := 0 irCode := 0 repeat ctra := (%10101 << 26 ) | (PIN) ' accumulate while A = 0 waitpne(0 << pin, |< Pin, 0) phsa:=0 ' zero width waitpeq(0 << pin, |< Pin, 0) ' start counting waitpne(0 << pin, |< Pin, 0) ' stop counting pulseWidth := phsa / (clkfreq / 1_000_000) + 1 if (pulseWidth > oneBitMin) AND (pulseWidth < oneBitMax) irCode := irCode + (1 << index) index++ while index < 11 irCode := irCode & $7f ' mask off upper 5 bits byte[addrMainCode] := irCode
Propeller Spin
5
deets/propeller
libraries/community/p1/All/IR Transmit/IR_Remote.spin
[ "MIT" ]
package com.alibaba.json.bvt.util; import java.util.HashMap; import org.junit.Assert; import junit.framework.TestCase; import com.alibaba.fastjson.util.ASMUtils; public class JSONASMUtilTest extends TestCase { public void test_0() throws Exception { Assert.assertEquals("()I", ASMUtils.desc(HashMap.class.getMethod("size"))); Assert.assertEquals("(Ljava/lang/Object;)Ljava/lang/Object;", ASMUtils.desc(HashMap.class.getMethod("get", Object.class))); Assert.assertEquals("(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;", ASMUtils.desc(HashMap.class.getMethod("put", Object.class, Object.class))); } public void test_1() throws Exception { Assert.assertEquals("I", ASMUtils.type(int.class)); Assert.assertEquals("java/lang/Integer", ASMUtils.type(Integer.class)); } public void test_2() throws Exception { Assert.assertEquals("[I", ASMUtils.type(int[].class)); Assert.assertEquals("[Ljava/lang/Integer;", ASMUtils.type(Integer[].class)); } }
Java
3
Czarek93/fastjson
src/test/java/com/alibaba/json/bvt/util/JSONASMUtilTest.java
[ "Apache-2.0" ]
enum Quux<T> { Bar } fn foo(c: Quux) { assert!((false)); } //~ ERROR missing generics for enum `Quux` fn main() { panic!(); }
Rust
1
mbc-git/rust
src/test/ui/tag-type-args.rs
[ "ECL-2.0", "Apache-2.0", "MIT-0", "MIT" ]
[[ require "lapis.config" ("development", { server = "cqueues"; }) ]]
MoonScript
2
tommy-mor/lapis
lapis/cmd/cqueues/templates/config.moon
[ "MIT", "Unlicense" ]
*** Test Cases *** Match all allowed [Documentation] FAIL Keyword '\${catch all}' expected 0 arguments, got 1. Exact match hello kitty Matches catch all Matches catch all Illegal with argument *** Keywords *** ${catch all} BuiltIn.Log x Exact match [Arguments] ${foo} BuiltIn.Log ${foo}
RobotFramework
3
phil-davis/robotframework
atest/testdata/keywords/embedded_arguments_match_all.robot
[ "ECL-2.0", "Apache-2.0" ]
#!/bin/csh -x # NB: at the point when this script is run, vagrant's shell is csh set echo #Set the time correctly ntpdate -v -b in.pool.ntp.org date > /etc/vagrant_box_build_time # allow freebsd-update to run fetch without stdin attached to a terminal sed 's/\[ ! -t 0 \]/false/' /usr/sbin/freebsd-update > /tmp/freebsd-update chmod +x /tmp/freebsd-update # update FreeBSD env PAGER=/bin/cat /tmp/freebsd-update fetch env PAGER=/bin/cat /tmp/freebsd-update install # allow portsnap to run fetch without stdin attached to a terminal sed 's/\[ ! -t 0 \]/false/' /usr/sbin/portsnap > /tmp/portsnap chmod +x /tmp/portsnap # reduce the ports we extract to a minimum cat >> /etc/portsnap.conf << EOT REFUSE accessibility arabic archivers astro audio benchmarks biology cad REFUSE chinese comms databases deskutils distfiles dns editors finance french REFUSE ftp games german graphics hebrew hungarian irc japanese java korean REFUSE mail math multimedia net net-im net-mgmt net-p2p news packages palm REFUSE polish portuguese print russian science sysutils ukrainian REFUSE vietnamese www x11 x11-clocks x11-drivers x11-fm x11-fonts x11-servers REFUSE x11-themes x11-toolkits x11-wm EOT # get new ports /tmp/portsnap fetch extract # install sudo and bash pkg_delete -af cd /usr/ports/security/sudo make -DBATCH install clean cd /usr/ports/shells/bash-static make -DBATCH install clean #Off to rubygems to get first ruby running cd /usr/ports/devel/ruby-gems make install -DBATCH #Need ruby iconv in order for chef to run cd /usr/ports/converters/ruby-iconv make install -DBATCH #Installing chef & Puppet /usr/local/bin/gem install chef --no-ri --no-rdoc /usr/local/bin/gem install puppet --no-ri --no-rdoc #Installing vagrant keys mkdir /home/vagrant/.ssh chmod 700 /home/vagrant/.ssh cd /home/vagrant/.ssh fetch -am -o authorized_keys 'https://raw.github.com/mitchellh/vagrant/master/keys/vagrant.pub' chown -R vagrant /home/vagrant/.ssh chmod -R go-rwsx /home/vagrant/.ssh # Cleaning portstree to save space # http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/ports-using.html cd /usr/ports/ports-mgmt/portupgrade make install -DBATCH clean /usr/local/sbin/portsclean -C # As sharedfolders are not in defaults ports tree # We will use vagrant via NFS # Enable NFS echo 'rpcbind_enable="YES"' >> /etc/rc.conf echo 'nfs_server_enable="YES"' >> /etc/rc.conf echo 'mountd_flags="-r"' >> /etc/rc.conf # Enable passwordless sudo echo "vagrant ALL=(ALL) NOPASSWD: ALL" >> /usr/local/etc/sudoers # Restore correct su permissions # I'll leave that up to the reader :) cd /usr/ports/devel/libtool make clean make install -DBATCH # disable X11 because vagrants are (usually) headless cat >> /etc/make.conf << EOT WITHOUT_X11="YES" EOT cd /usr/ports/emulators/virtualbox-ose-additions make -DBATCH install clean cd /usr/ports/emulators/virtio-kmod make -DBATCH install # undo our customizations sed -i '' -e '/^REFUSE /d' /etc/portsnap.conf sed -i '' -e '/^PermitRootLogin /d' /etc/ssh/sshd_config /usr/sbin/service sshd reload echo 'vboxdrv_load="YES"' >> /boot/loader.conf echo 'vboxnet_enable="YES"' >> /etc/rc.conf echo 'vboxguest_enable="YES"' >> /etc/rc.conf echo 'vboxservice_enable="YES"' >> /etc/rc.conf cat >> /boot/loader.conf << EOT virtio_load="YES" virtio_pci_load="YES" virtio_blk_load="YES" if_vtnet_load="YES" virtio_balloon_load="YES" EOT echo 'ifconfig_vtnet0_name="em0"' >> /etc/rc.conf echo 'ifconfig_vtnet1_name="em1"' >> /etc/rc.conf echo 'ifconfig_vtnet2_name="em2"' >> /etc/rc.conf echo 'ifconfig_vtnet3_name="em3"' >> /etc/rc.conf pw groupadd vboxusers pw groupmod vboxusers -m vagrant #Bash needs to be the shell for tests to validate pw usermod vagrant -s /usr/local/bin/bash echo "==============================================================================" echo "NOTE: FreeBSD - Vagrant" echo "When using this basebox you need to do some special stuff in your Vagrantfile" echo "1) Enable HostOnly network" echo " config.vm.network ...." echo "2) Use nfs instead of shared folders" echo ' config.vm.share_folder("v-root", "/vagrant", ".", :nfs => true)' echo "=============================================================================" exit
Tcsh
4
ibizaman/veewee
templates/freebsd-9.1-RELEASE-amd64/postinstall.csh
[ "MIT" ]
#!/bin/tcsh set nl=10 set N=128 set M=128 echo nl=$nl echo N=$N echo M=$M #compile covariance chpl --fast covariance.chpl -o covariance echo 'Cyclic (C)' ./covariance -nl $nl --dist=C --N=$N --M=$M --messages ./covariance -nl $nl --dist=C --N=$N --M=$M --timeit echo 'Cyclic with modulo unrolling (CM)' ./covariance -nl $nl --dist=CM --N=$N --M=$M --correct ./covariance -nl $nl --dist=CM --N=$N --M=$M --messages ./covariance -nl $nl --dist=CM --N=$N --M=$M --timeit echo 'Block (B)' ./covariance -nl $nl --dist=B --N=$N --M=$M --messages ./covariance -nl $nl --dist=B --N=$N --M=$M --timeit echo 'No distribution (NONE)' ./covariance -nl $nl --dist=NONE --N=$N --M=$M --timeit
Tcsh
4
jhh67/chapel
test/users/aroonsharma/docovariancebench.tcsh
[ "ECL-2.0", "Apache-2.0" ]
$(OBJDIR)/formatparse.cmi: $(OBJDIR)/cil.cmi
D
1
heechul/crest-z3
cil/obj/.depend/formatparse.di
[ "BSD-3-Clause" ]
/** * This file is part of the Phalcon Framework. * * (c) Phalcon Team <team@phalcon.io> * * For the full copyright and license information, please view the LICENSE.txt * file that was distributed with this source code. */ namespace Phalcon\Cli\Router; /** * Interface for Phalcon\Cli\Router\Route */ interface RouteInterface { /** * Replaces placeholders from pattern returning a valid PCRE regular * expression */ public function compilePattern(string! pattern) -> string; /** * Set the routing delimiter */ public static function delimiter(string! delimiter = null); /** * Returns the route's pattern */ public function getCompiledPattern() -> string; /** * Get routing delimiter */ public static function getDelimiter() -> string; /** * Returns the route's description */ public function getDescription() -> string; /** * Returns the route's name */ public function getName() -> string; /** * Returns the paths */ public function getPaths() -> array; /** * Returns the route's pattern */ public function getPattern() -> string; /** * Returns the paths using positions as keys and names as values */ public function getReversedPaths() -> array; /** * Returns the route's id */ public function getRouteId() -> string; /** * Reconfigure the route adding a new pattern and a set of paths * * @param string pattern * @param array|string|null paths * * @return void */ public function reConfigure(string! pattern, var paths = null) -> void; /** * Resets the internal route id generator */ public static function reset() -> void; /** * Sets the route's description */ public function setDescription(string! description) -> <RouteInterface>; /** * Sets the route's name */ public function setName(string name) -> <RouteInterface>; }
Zephir
3
tidytrax/cphalcon
phalcon/Cli/Router/RouteInterface.zep
[ "BSD-3-Clause" ]
' Licensed to the .NET Foundation under one or more agreements. ' The .NET Foundation licenses this file to you under the MIT license. ' See the LICENSE file in the project root for more information. Imports Microsoft.CodeAnalysis.Test.Utilities Imports Microsoft.CodeAnalysis.VisualBasic.Syntax Imports Roslyn.Test.Utilities Namespace Microsoft.CodeAnalysis.VisualBasic.UnitTests.Semantics Partial Public Class IOperationTests Inherits SemanticModelTestBase <CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)> <Fact()> Public Sub LambdaFlow_01() Dim source = <![CDATA[ Class C Public Property A As System.Func(Of Integer) Sub M()'BIND:"Sub M" Dim c1, c2 As New C With {.A = Function() 1} End Sub End Class]]>.Value Dim expectedDiagnostics = String.Empty Dim expectedFlowGraph = <![CDATA[ Block[B0] - Entry Statements (0) Next (Regular) Block[B1] Entering: {R1} {R2} .locals {R1} { Locals: [c1 As C] [c2 As C] .locals {R2} { CaptureIds: [0] Block[B1] - Block Predecessors: [B0] Statements (3) IFlowCaptureOperation: 0 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'New C With ... nction() 1}') Value: IObjectCreationOperation (Constructor: Sub C..ctor()) (OperationKind.ObjectCreation, Type: C) (Syntax: 'New C With ... nction() 1}') Arguments(0) Initializer: null ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: System.Void) (Syntax: '.A = Function() 1') Left: IPropertyReferenceOperation: Property C.A As System.Func(Of System.Int32) (OperationKind.PropertyReference, Type: System.Func(Of System.Int32)) (Syntax: 'A') Instance Receiver: IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: C, IsImplicit) (Syntax: 'New C With ... nction() 1}') Right: IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Func(Of System.Int32), IsImplicit) (Syntax: 'Function() 1') Target: IFlowAnonymousFunctionOperation (Symbol: Function () As System.Int32) (OperationKind.FlowAnonymousFunction, Type: null) (Syntax: 'Function() 1') { Block[B0#A0] - Entry Statements (0) Next (Regular) Block[B1#A0] Entering: {R1#A0} .locals {R1#A0} { Locals: [<anonymous local> As System.Int32] Block[B1#A0] - Block Predecessors: [B0#A0] Statements (0) Next (Return) Block[B2#A0] ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1') Leaving: {R1#A0} } Block[B2#A0] - Exit Predecessors: [B1#A0] Statements (0) } ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: C, IsImplicit) (Syntax: 'c1, c2 As N ... nction() 1}') Left: ILocalReferenceOperation: c1 (IsDeclaration: True) (OperationKind.LocalReference, Type: C, IsImplicit) (Syntax: 'c1') Right: IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: C, IsImplicit) (Syntax: 'New C With ... nction() 1}') Next (Regular) Block[B2] Leaving: {R2} Entering: {R3} } .locals {R3} { CaptureIds: [1] Block[B2] - Block Predecessors: [B1] Statements (3) IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'New C With ... nction() 1}') Value: IObjectCreationOperation (Constructor: Sub C..ctor()) (OperationKind.ObjectCreation, Type: C) (Syntax: 'New C With ... nction() 1}') Arguments(0) Initializer: null ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: System.Void) (Syntax: '.A = Function() 1') Left: IPropertyReferenceOperation: Property C.A As System.Func(Of System.Int32) (OperationKind.PropertyReference, Type: System.Func(Of System.Int32)) (Syntax: 'A') Instance Receiver: IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: C, IsImplicit) (Syntax: 'New C With ... nction() 1}') Right: IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Func(Of System.Int32), IsImplicit) (Syntax: 'Function() 1') Target: IFlowAnonymousFunctionOperation (Symbol: Function () As System.Int32) (OperationKind.FlowAnonymousFunction, Type: null) (Syntax: 'Function() 1') { Block[B0#A1] - Entry Statements (0) Next (Regular) Block[B1#A1] Entering: {R1#A1} .locals {R1#A1} { Locals: [<anonymous local> As System.Int32] Block[B1#A1] - Block Predecessors: [B0#A1] Statements (0) Next (Return) Block[B2#A1] ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1') Leaving: {R1#A1} } Block[B2#A1] - Exit Predecessors: [B1#A1] Statements (0) } ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: C, IsImplicit) (Syntax: 'c1, c2 As N ... nction() 1}') Left: ILocalReferenceOperation: c2 (IsDeclaration: True) (OperationKind.LocalReference, Type: C, IsImplicit) (Syntax: 'c2') Right: IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: C, IsImplicit) (Syntax: 'New C With ... nction() 1}') Next (Regular) Block[B3] Leaving: {R3} {R1} } } Block[B3] - Exit Predecessors: [B2] Statements (0) ]]>.Value VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics) End Sub <CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)> <Fact()> Public Sub LambdaFlow_02() Dim source = <![CDATA[ Class C Public Property A As System.Func(Of Integer) Sub M(d1 As System.Action(Of Boolean, Boolean), d2 As System.Action(Of Boolean, Boolean))'BIND:"Sub M" d1 = Sub (result1, input1) result1 = input1 End Sub d2 = Sub (result2, input2) result2 = input2 End Sub End Class]]>.Value Dim expectedDiagnostics = String.Empty Dim expectedFlowGraph = <![CDATA[ Block[B0] - Entry Statements (0) Next (Regular) Block[B1] Block[B1] - Block Predecessors: [B0] Statements (2) IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'd1 = Sub (r ... End Sub') Expression: ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: System.Action(Of System.Boolean, System.Boolean), IsImplicit) (Syntax: 'd1 = Sub (r ... End Sub') Left: IParameterReferenceOperation: d1 (OperationKind.ParameterReference, Type: System.Action(Of System.Boolean, System.Boolean)) (Syntax: 'd1') Right: IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action(Of System.Boolean, System.Boolean), IsImplicit) (Syntax: 'Sub (result ... End Sub') Target: IFlowAnonymousFunctionOperation (Symbol: Sub (result1 As System.Boolean, input1 As System.Boolean)) (OperationKind.FlowAnonymousFunction, Type: null) (Syntax: 'Sub (result ... End Sub') { Block[B0#A0] - Entry Statements (0) Next (Regular) Block[B1#A0] Block[B1#A0] - Block Predecessors: [B0#A0] Statements (1) IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'result1 = input1') Expression: ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: System.Boolean, IsImplicit) (Syntax: 'result1 = input1') Left: IParameterReferenceOperation: result1 (OperationKind.ParameterReference, Type: System.Boolean) (Syntax: 'result1') Right: IParameterReferenceOperation: input1 (OperationKind.ParameterReference, Type: System.Boolean) (Syntax: 'input1') Next (Regular) Block[B2#A0] Block[B2#A0] - Exit Predecessors: [B1#A0] Statements (0) } IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'd2 = Sub (r ... t2 = input2') Expression: ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: System.Action(Of System.Boolean, System.Boolean), IsImplicit) (Syntax: 'd2 = Sub (r ... t2 = input2') Left: IParameterReferenceOperation: d2 (OperationKind.ParameterReference, Type: System.Action(Of System.Boolean, System.Boolean)) (Syntax: 'd2') Right: IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action(Of System.Boolean, System.Boolean), IsImplicit) (Syntax: 'Sub (result ... t2 = input2') Target: IFlowAnonymousFunctionOperation (Symbol: Sub (result2 As System.Boolean, input2 As System.Boolean)) (OperationKind.FlowAnonymousFunction, Type: null) (Syntax: 'Sub (result ... t2 = input2') { Block[B0#A1] - Entry Statements (0) Next (Regular) Block[B1#A1] Block[B1#A1] - Block Predecessors: [B0#A1] Statements (1) IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'result2 = input2') Expression: ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: System.Boolean, IsImplicit) (Syntax: 'result2 = input2') Left: IParameterReferenceOperation: result2 (OperationKind.ParameterReference, Type: System.Boolean) (Syntax: 'result2') Right: IParameterReferenceOperation: input2 (OperationKind.ParameterReference, Type: System.Boolean) (Syntax: 'input2') Next (Regular) Block[B2#A1] Block[B2#A1] - Exit Predecessors: [B1#A1] Statements (0) } Next (Regular) Block[B2] Block[B2] - Exit Predecessors: [B1] Statements (0) ]]>.Value VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics) End Sub <CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)> <Fact()> Public Sub LambdaFlow_03() Dim source = <![CDATA[ Class C Public Property A As System.Func(Of Integer) Sub M(d1 As System.Action(Of Integer), d2 As System.Action(Of Boolean))'BIND:"Sub M" Dim i As Integer = 0 d1 = Sub(input1) input1 = i d2 = Sub(input2) input2 = true i+=1 End Sub End Sub End Sub End Class]]>.Value Dim expectedDiagnostics = String.Empty Dim expectedFlowGraph = <![CDATA[ Block[B0] - Entry Statements (0) Next (Regular) Block[B1] Entering: {R1} .locals {R1} { Locals: [i As System.Int32] Block[B1] - Block Predecessors: [B0] Statements (2) ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: System.Int32, IsImplicit) (Syntax: 'i As Integer = 0') Left: ILocalReferenceOperation: i (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32, IsImplicit) (Syntax: 'i') Right: ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 0) (Syntax: '0') IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'd1 = Sub(in ... End Sub') Expression: ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: System.Action(Of System.Int32), IsImplicit) (Syntax: 'd1 = Sub(in ... End Sub') Left: IParameterReferenceOperation: d1 (OperationKind.ParameterReference, Type: System.Action(Of System.Int32)) (Syntax: 'd1') Right: IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action(Of System.Int32), IsImplicit) (Syntax: 'Sub(input1) ... End Sub') Target: IFlowAnonymousFunctionOperation (Symbol: Sub (input1 As System.Int32)) (OperationKind.FlowAnonymousFunction, Type: null) (Syntax: 'Sub(input1) ... End Sub') { Block[B0#A0] - Entry Statements (0) Next (Regular) Block[B1#A0] Block[B1#A0] - Block Predecessors: [B0#A0] Statements (2) IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'input1 = i') Expression: ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: System.Int32, IsImplicit) (Syntax: 'input1 = i') Left: IParameterReferenceOperation: input1 (OperationKind.ParameterReference, Type: System.Int32) (Syntax: 'input1') Right: ILocalReferenceOperation: i (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'i') IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'd2 = Sub(in ... End Sub') Expression: ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: System.Action(Of System.Boolean), IsImplicit) (Syntax: 'd2 = Sub(in ... End Sub') Left: IParameterReferenceOperation: d2 (OperationKind.ParameterReference, Type: System.Action(Of System.Boolean)) (Syntax: 'd2') Right: IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action(Of System.Boolean), IsImplicit) (Syntax: 'Sub(input2) ... End Sub') Target: IFlowAnonymousFunctionOperation (Symbol: Sub (input2 As System.Boolean)) (OperationKind.FlowAnonymousFunction, Type: null) (Syntax: 'Sub(input2) ... End Sub') { Block[B0#A0#A0] - Entry Statements (0) Next (Regular) Block[B1#A0#A0] Block[B1#A0#A0] - Block Predecessors: [B0#A0#A0] Statements (2) IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'input2 = true') Expression: ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: System.Boolean, IsImplicit) (Syntax: 'input2 = true') Left: IParameterReferenceOperation: input2 (OperationKind.ParameterReference, Type: System.Boolean) (Syntax: 'input2') Right: ILiteralOperation (OperationKind.Literal, Type: System.Boolean, Constant: True) (Syntax: 'true') IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'i+=1') Expression: ICompoundAssignmentOperation (BinaryOperatorKind.Add, Checked) (OperationKind.CompoundAssignment, Type: System.Int32, IsImplicit) (Syntax: 'i+=1') InConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null) OutConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null) Left: ILocalReferenceOperation: i (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'i') Right: ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1') Next (Regular) Block[B2#A0#A0] Block[B2#A0#A0] - Exit Predecessors: [B1#A0#A0] Statements (0) } Next (Regular) Block[B2#A0] Block[B2#A0] - Exit Predecessors: [B1#A0] Statements (0) } Next (Regular) Block[B2] Leaving: {R1} } Block[B2] - Exit Predecessors: [B1] Statements (0) ]]>.Value VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics) End Sub <CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)> <Fact()> Public Sub LambdaFlow_04() Dim source = <![CDATA[ Class C Public Property A As System.Func(Of Integer) Sub M()'BIND:"Sub M" Static c1, c2 As New C With {.A = Function() 1} End Sub End Class]]>.Value Dim expectedDiagnostics = String.Empty Dim expectedFlowGraph = <![CDATA[ Block[B0] - Entry Statements (0) Next (Regular) Block[B1] Entering: {R1} .locals {R1} { Locals: [c1 As C] [c2 As C] Block[B1] - Block Predecessors: [B0] Statements (0) Jump if False (Regular) to Block[B3] IStaticLocalInitializationSemaphoreOperation (Local Symbol: c1 As C) (OperationKind.StaticLocalInitializationSemaphore, Type: System.Boolean, IsImplicit) (Syntax: 'c1') Next (Regular) Block[B2] Entering: {R2} .static initializer {R2} { CaptureIds: [0] Block[B2] - Block Predecessors: [B1] Statements (3) IFlowCaptureOperation: 0 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'New C With ... nction() 1}') Value: IObjectCreationOperation (Constructor: Sub C..ctor()) (OperationKind.ObjectCreation, Type: C) (Syntax: 'New C With ... nction() 1}') Arguments(0) Initializer: null ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: System.Void) (Syntax: '.A = Function() 1') Left: IPropertyReferenceOperation: Property C.A As System.Func(Of System.Int32) (OperationKind.PropertyReference, Type: System.Func(Of System.Int32)) (Syntax: 'A') Instance Receiver: IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: C, IsImplicit) (Syntax: 'New C With ... nction() 1}') Right: IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Func(Of System.Int32), IsImplicit) (Syntax: 'Function() 1') Target: IFlowAnonymousFunctionOperation (Symbol: Function () As System.Int32) (OperationKind.FlowAnonymousFunction, Type: null) (Syntax: 'Function() 1') { Block[B0#A0] - Entry Statements (0) Next (Regular) Block[B1#A0] Entering: {R1#A0} .locals {R1#A0} { Locals: [<anonymous local> As System.Int32] Block[B1#A0] - Block Predecessors: [B0#A0] Statements (0) Next (Return) Block[B2#A0] ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1') Leaving: {R1#A0} } Block[B2#A0] - Exit Predecessors: [B1#A0] Statements (0) } ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: C, IsImplicit) (Syntax: 'c1, c2 As N ... nction() 1}') Left: ILocalReferenceOperation: c1 (IsDeclaration: True) (OperationKind.LocalReference, Type: C, IsImplicit) (Syntax: 'c1') Right: IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: C, IsImplicit) (Syntax: 'New C With ... nction() 1}') Next (Regular) Block[B3] Leaving: {R2} } Block[B3] - Block Predecessors: [B1] [B2] Statements (0) Jump if False (Regular) to Block[B5] IStaticLocalInitializationSemaphoreOperation (Local Symbol: c2 As C) (OperationKind.StaticLocalInitializationSemaphore, Type: System.Boolean, IsImplicit) (Syntax: 'c2') Leaving: {R1} Next (Regular) Block[B4] Entering: {R3} .static initializer {R3} { CaptureIds: [1] Block[B4] - Block Predecessors: [B3] Statements (3) IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'New C With ... nction() 1}') Value: IObjectCreationOperation (Constructor: Sub C..ctor()) (OperationKind.ObjectCreation, Type: C) (Syntax: 'New C With ... nction() 1}') Arguments(0) Initializer: null ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: System.Void) (Syntax: '.A = Function() 1') Left: IPropertyReferenceOperation: Property C.A As System.Func(Of System.Int32) (OperationKind.PropertyReference, Type: System.Func(Of System.Int32)) (Syntax: 'A') Instance Receiver: IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: C, IsImplicit) (Syntax: 'New C With ... nction() 1}') Right: IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Func(Of System.Int32), IsImplicit) (Syntax: 'Function() 1') Target: IFlowAnonymousFunctionOperation (Symbol: Function () As System.Int32) (OperationKind.FlowAnonymousFunction, Type: null) (Syntax: 'Function() 1') { Block[B0#A1] - Entry Statements (0) Next (Regular) Block[B1#A1] Entering: {R1#A1} .locals {R1#A1} { Locals: [<anonymous local> As System.Int32] Block[B1#A1] - Block Predecessors: [B0#A1] Statements (0) Next (Return) Block[B2#A1] ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1') Leaving: {R1#A1} } Block[B2#A1] - Exit Predecessors: [B1#A1] Statements (0) } ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: C, IsImplicit) (Syntax: 'c1, c2 As N ... nction() 1}') Left: ILocalReferenceOperation: c2 (IsDeclaration: True) (OperationKind.LocalReference, Type: C, IsImplicit) (Syntax: 'c2') Right: IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: C, IsImplicit) (Syntax: 'New C With ... nction() 1}') Next (Regular) Block[B5] Leaving: {R3} {R1} } } Block[B5] - Exit Predecessors: [B3] [B4] Statements (0) ]]>.Value VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics) End Sub <CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)> <Fact()> Public Sub LambdaFlow_05() Dim source = <![CDATA[ Class C Public Property A As System.Func(Of Integer) Sub M(d As System.Action(Of C, C, C), x as C, y as C, z as C)'BIND:"Sub M" x = If(y, z) d = Sub (result1, input1, input2) result1 = If(input1, input2) End Sub End Sub End Class]]>.Value Dim expectedDiagnostics = String.Empty Dim expectedFlowGraph = <![CDATA[ Block[B0] - Entry Statements (0) Next (Regular) Block[B1] Entering: {R1} .locals {R1} { CaptureIds: [0] [2] Block[B1] - Block Predecessors: [B0] Statements (1) IFlowCaptureOperation: 0 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'x') Value: IParameterReferenceOperation: x (OperationKind.ParameterReference, Type: C) (Syntax: 'x') Next (Regular) Block[B2] Entering: {R2} .locals {R2} { CaptureIds: [1] Block[B2] - Block Predecessors: [B1] Statements (1) IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'y') Value: IParameterReferenceOperation: y (OperationKind.ParameterReference, Type: C) (Syntax: 'y') Jump if True (Regular) to Block[B4] IIsNullOperation (OperationKind.IsNull, Type: System.Boolean, IsImplicit) (Syntax: 'y') Operand: IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: C, IsImplicit) (Syntax: 'y') Leaving: {R2} Next (Regular) Block[B3] Block[B3] - Block Predecessors: [B2] Statements (1) IFlowCaptureOperation: 2 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'y') Value: IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: C, IsImplicit) (Syntax: 'y') Next (Regular) Block[B5] Leaving: {R2} } Block[B4] - Block Predecessors: [B2] Statements (1) IFlowCaptureOperation: 2 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'z') Value: IParameterReferenceOperation: z (OperationKind.ParameterReference, Type: C) (Syntax: 'z') Next (Regular) Block[B5] Block[B5] - Block Predecessors: [B3] [B4] Statements (1) IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'x = If(y, z)') Expression: ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: C, IsImplicit) (Syntax: 'x = If(y, z)') Left: IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: C, IsImplicit) (Syntax: 'x') Right: IFlowCaptureReferenceOperation: 2 (OperationKind.FlowCaptureReference, Type: C, IsImplicit) (Syntax: 'If(y, z)') Next (Regular) Block[B6] Leaving: {R1} } Block[B6] - Block Predecessors: [B5] Statements (1) IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'd = Sub (re ... End Sub') Expression: ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: System.Action(Of C, C, C), IsImplicit) (Syntax: 'd = Sub (re ... End Sub') Left: IParameterReferenceOperation: d (OperationKind.ParameterReference, Type: System.Action(Of C, C, C)) (Syntax: 'd') Right: IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action(Of C, C, C), IsImplicit) (Syntax: 'Sub (result ... End Sub') Target: IFlowAnonymousFunctionOperation (Symbol: Sub (result1 As C, input1 As C, input2 As C)) (OperationKind.FlowAnonymousFunction, Type: null) (Syntax: 'Sub (result ... End Sub') { Block[B0#A0] - Entry Statements (0) Next (Regular) Block[B1#A0] Entering: {R1#A0} .locals {R1#A0} { CaptureIds: [3] [5] Block[B1#A0] - Block Predecessors: [B0#A0] Statements (1) IFlowCaptureOperation: 3 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'result1') Value: IParameterReferenceOperation: result1 (OperationKind.ParameterReference, Type: C) (Syntax: 'result1') Next (Regular) Block[B2#A0] Entering: {R2#A0} .locals {R2#A0} { CaptureIds: [4] Block[B2#A0] - Block Predecessors: [B1#A0] Statements (1) IFlowCaptureOperation: 4 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'input1') Value: IParameterReferenceOperation: input1 (OperationKind.ParameterReference, Type: C) (Syntax: 'input1') Jump if True (Regular) to Block[B4#A0] IIsNullOperation (OperationKind.IsNull, Type: System.Boolean, IsImplicit) (Syntax: 'input1') Operand: IFlowCaptureReferenceOperation: 4 (OperationKind.FlowCaptureReference, Type: C, IsImplicit) (Syntax: 'input1') Leaving: {R2#A0} Next (Regular) Block[B3#A0] Block[B3#A0] - Block Predecessors: [B2#A0] Statements (1) IFlowCaptureOperation: 5 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'input1') Value: IFlowCaptureReferenceOperation: 4 (OperationKind.FlowCaptureReference, Type: C, IsImplicit) (Syntax: 'input1') Next (Regular) Block[B5#A0] Leaving: {R2#A0} } Block[B4#A0] - Block Predecessors: [B2#A0] Statements (1) IFlowCaptureOperation: 5 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'input2') Value: IParameterReferenceOperation: input2 (OperationKind.ParameterReference, Type: C) (Syntax: 'input2') Next (Regular) Block[B5#A0] Block[B5#A0] - Block Predecessors: [B3#A0] [B4#A0] Statements (1) IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'result1 = I ... t1, input2)') Expression: ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: C, IsImplicit) (Syntax: 'result1 = I ... t1, input2)') Left: IFlowCaptureReferenceOperation: 3 (OperationKind.FlowCaptureReference, Type: C, IsImplicit) (Syntax: 'result1') Right: IFlowCaptureReferenceOperation: 5 (OperationKind.FlowCaptureReference, Type: C, IsImplicit) (Syntax: 'If(input1, input2)') Next (Regular) Block[B6#A0] Leaving: {R1#A0} } Block[B6#A0] - Exit Predecessors: [B5#A0] Statements (0) } Next (Regular) Block[B7] Block[B7] - Exit Predecessors: [B6] Statements (0) ]]>.Value VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics) End Sub End Class End Namespace
Visual Basic
4
ffMathy/roslyn
src/Compilers/VisualBasic/Test/IOperation/IOperation/IOperationTests_IAnonymousFunctionOperation.vb
[ "MIT" ]
use "buffered" class FileLines is Iterator[String iso^] """ Iterate over the lines in a file. Returns lines without trailing line breaks. Advances the file cursor to the end of each line returned from `next`. This class buffers the file contents to accumulate full lines. If the file does not contain linebreaks, the whole file content is read and buffered, which might exceed memory resources. Take care. """ let _reader: Reader = Reader let _file: File let _min_read_size: USize var _last_line_length: USize var _buffer_cursor: USize """Internal cursor for keeping track until where in the file we already buffered.""" var _cursor: USize """Keeps track of the file position we update after every returned line.""" var _has_next: Bool new create(file: File, min_read_size: USize = 256) => """ Create a FileLines instance on a given file. This instance returns lines from the position of the given `file` at the time this constructor is called. Later manipulation of the file position is not accounted for. As a result iterating with this class will always return the full file content without gaps or repeated lines. `min_read_size` determines the minimum amount of bytes to read from the file in one go. This class keeps track of the line lengths in the current file and uses the length of the last line as amount of bytes to read next, but it will never read less than `min_read_size`. """ _file = file _buffer_cursor = _file.position() _cursor = _file.position() _min_read_size = min_read_size _last_line_length = min_read_size _has_next = _file.valid() fun ref has_next(): Bool => _has_next fun ref next(): String iso^ ? => """ Returns the next line in the file. """ while true do try return _read_line()? else if not _fill_buffer() then // nothing to read from file, we can savely exit here break end end end _has_next = false if _reader.size() > 0 then // don't forget the last line _read_last_line()? else // nothing to return, we can only error here error end fun ref _read_line(): String iso^ ? => let line = _reader.line(where keep_line_breaks = true)? let len = line.size() _last_line_length = len // advance the cursor to the end of the returned line _inc_public_file_cursor(len) // strip trailing line break line.truncate( len - if (len >= 2) and (line.at_offset(-2)? == '\r') then 2 else 1 end) consume line fun ref _fill_buffer(): Bool => """ read from file and fill the reader-buffer. Returns `true` if data could be read from the file. After a successful reading operation `_buffer_cursor` is updated. """ var result = true // get back to position of last line let current_pos = _file.position() _file.seek_start(_buffer_cursor) if _file.valid() then let read_bytes = _last_line_length.max(_min_read_size) let read_buf = _file.read(read_bytes) _buffer_cursor = _file.position() let errno = _file.errno() if (read_buf.size() == 0) and (errno isnt FileOK) then result = false else // TODO: Limit size of read buffer _reader.append(consume read_buf) end else result = false end // reset position to not disturb other operations on the file // we only actually advance the cursor if the line is returned. _file.seek_start(current_pos) result fun ref _read_last_line(): String iso^ ? => let block = _reader.block(_reader.size())? _inc_public_file_cursor(block.size()) String.from_iso_array(consume block) fun ref _inc_public_file_cursor(amount: USize) => _cursor = _cursor + amount _file.seek_start(_cursor)
Pony
5
presidentbeef/ponyc
packages/files/file_lines.pony
[ "BSD-2-Clause" ]
<html> <!-- Using a <blockquote> because it's an obscure tag --> <!-- which allows us to use document.querySelector() --> <!-- with generic tags freely inside Cypress tests. --> <blockquote id="root"> <!-- This is where our test subjects will be injected. --> </blockquote> <script src="/../../packages/history/dist/cdn.js"></script> <script src="/../../packages/morph/dist/cdn.js"></script> <script src="/../../packages/persist/dist/cdn.js"></script> <script src="/../../packages/trap/dist/cdn.js"></script> <script src="/../../packages/intersect/dist/cdn.js"></script> <script src="/../../packages/collapse/dist/cdn.js"></script> <script> let root = document.querySelector('#root') // We aren't loading Alpine directly because we are expecting // Cypress to inject HTML into "#root", THEN we'll call // this function from Cypress to boot everything up. root.evalScripts = (extraJavaScript) => { // Load bespoke JavaScript. if (extraJavaScript) { let script = document.createElement('script') script.src = `data:text/javascript;base64,${btoa(` document.addEventListener('alpine:init', () => { ${extraJavaScript} }) `)}` root.after(script) } // Load all injected script tags. root.querySelectorAll('script').forEach(el => { eval(el.innerHTML) }) // Load Alpine. let script = document.createElement('script') script.src = '/../../packages/alpinejs/dist/cdn.js' root.after(script) document.addEventListener('alpine:initialized', () => { let readyEl = document.createElement('blockquote') readyEl.setAttribute('alpine-is-ready', true) readyEl.style.width = '1px' readyEl.style.height = '1px' document.querySelector('blockquote').after(readyEl) }) } </script> </html>
HTML
4
valorin/alpine
tests/cypress/spec.html
[ "MIT" ]
async control = require '../asyncControl' module.exports (terms) = for expression term = terms.term { constructor (init, test, incr, stmts) = self.is for = true self.initialization = init self.test = test self.increment = incr self.index variable = init.target self.statements = stmts self.statements = self._scoped body () _scoped body () = contains return = false for result variable = self.cg.generated variable ['for', 'result'] rewritten statements = self.statements.rewrite ( rewrite (term): if (term.is return) contains return := true terms.sub statements [ self.cg.definition (for result variable, term.expression, assignment: true) self.cg.return statement (self.cg.boolean (true)) ] limit (term, path: path): term.is closure ).serialise all statements () if (contains return) loop statements = [] loop statements.push (self.cg.definition (for result variable, self.cg.nil ())) loop statements.push ( self.cg.if expression ( [{ condition = self.cg.sub expression ( self.cg.function call (self.cg.block ([self.index variable], rewritten statements, return last statement: false), [self.index variable]) ) body = self.cg.statements ([self.cg.return statement (for result variable)]) }] ) ) self.cg.async statements (loop statements) else self.statements generate (scope) = self.code ( 'for(' self.initialization.generate (scope) ';' self.test.generate (scope) ';' self.increment.generate (scope) '){' self.statements.generate statements (scope) '}' ) generate statement (args, ...) = self.generate (args, ...) rewrite result term into (return term) = nil } for expression (init, test, incr, body) = initStatements = terms.asyncStatements [init] testStatements = terms.asyncStatements [test] incrStatements = terms.asyncStatements [incr] if ((initStatements.returnsPromise || testStatements.returnsPromise) || (incrStatements.returnsPromise || body.returnsPromise)) async for function = terms.module constants.define ['async', 'for'] as ( terms.javascript (async control.for.to string ()) ) terms.scope [ init terms.resolve( terms.function call ( async for function [ terms.closure ([], testStatements) terms.closure ([], incrStatements) terms.closure ([], body) ] ).alreadyPromise() ) ] else for expression term (init, test, incr, body)
PogoScript
2
Sotrek/Alexa
Alexa_Cookbook/Workshop/StatePop/4_IOT/tests/node_modules/aws-sdk/node_modules/cucumber/node_modules/pogo/lib/terms/forExpression.pogo
[ "MIT" ]
? my $ctx = $main::context; ? $_mt->wrapper_file("wrapper.mt", "Configure", "Redirect Directives")->(sub { <p> This document describes the configuration directives of the redirect handler. </p> ? $ctx->{directive_list}->()->(sub { <? $ctx->{directive}->( name => "redirect", levels => [ qw(path) ], desc => q{Redirects the requests to given URL.}, )->(sub { ?> <p> The directive rewrites the URL by replacing the host and path part of the URL at which the directive is used with the given URL. For example, when using the configuration below, requests to <code>http://example.com/abc.html</code> will be redirected to <code>https://example.com/abc.html</code>. </p> <p> If the argument is a scalar, the value is considered as the URL to where the requests should be redirected. </p> <p> Following properties are recognized if the argument is a mapping. <dl> <dt><code>url</code> <dd>URL to redirect to <dt><code>status</code> <dd>the three-digit status code to use (e.g. <code>301</code>) <dt><code>internal</code> <dd>either <code>YES</code> or <code>NO</code> (default); if set to <code>YES</code>, then the server performs an internal redirect and return the content at the redirected URL </dl> </p> <?= $ctx->{example}->('Redirect all HTTP to HTTPS permanently (except for the files under <code>RSS</code>)', <<'EOT'); hosts: "example.com:80": paths: "/": redirect: status: 301 url: "https://example.com/" "/rss": file.dir: /path/to/rss EOT ?> ? }) ? }) ? })
Mathematica
4
pldubouilh/h2o
srcdoc/configure/redirect_directives.mt
[ "MIT" ]
package io.swagger.client.model { import io.swagger.common.ListWrapper; import io.swagger.client.model.Category; import io.swagger.client.model.Tag; public class PetList implements ListWrapper { // This declaration below of _Pet_obj_class is to force flash compiler to include this class private var _pet_obj_class: io.swagger.client.model.Pet = null; [XmlElements(name="pet", type="io.swagger.client.model.Pet")] public var pet: Array = new Array(); public function getList(): Array{ return pet; } } }
ActionScript
4
wwadge/swagger-codegen
samples/client/petstore/flash/flash/src/io/swagger/client/model/PetList.as
[ "Apache-2.0" ]
SUMMARY = "Main program" DESCRIPTION = "Handle main function" LICENSE = "CLOSED" FILESEXTRAPATHS_prepend := "${THISDIR}/../../../../:" SRC_URI = " \ file://main.service \ file://xiaopi \ file://src/ \ file://CMakeLists.txt \ " inherit systemd cmake S = "${WORKDIR}" EXTRA_OECMAKE = "" DEPENDS = "nlohmann-json pistache openssl wpa-supplicant userland pear libice libsrtp librtp paho-mqtt-c curl" RDEPENDS_${PN} += "bash libwpa-client" SYSTEMD_PACKAGES = "${PN}" SYSTEMD_SERVICE_${PN} = "main.service" SYSTEMD_AUTO_ENABLE = "enable" SYSTEMD_AUTO_ENABLE_${PN} = "enable" INSANE_SKIP_${PN} = "ldflags" FILES_${PN} += "/opt/xiaopi" # -Wl,--as-needed cause that open pi camera failed TARGET_LDFLAGS = "-Wl,-O1 -Wl,--hash-style=gnu" do_install_append () { install -d ${D}/opt/ cp -r ${WORKDIR}/xiaopi ${D}/opt/ install -d ${D}${systemd_unitdir}/system/ install -m 0644 ${WORKDIR}/main.service ${D}${systemd_unitdir}/system }
BitBake
3
abir1999/xiaoPi
bsp/meta-xiaopi/recipes-images/main/main.bb
[ "Unlicense" ]
size: 1024px 512px; dpi: 240; limit-x: 0 7; limit-y: 0 10000; scale-y: log; axes { position: left bottom; label-placement-x: linear-interval(1 1 6); } bars { data-x: csv("test/testdata/histogram.csv" var0); data-y: csv("test/testdata/histogram.csv" var1); width: 1.8em; color: #666; }
CLIPS
3
asmuth-archive/travistest
test/examples/charts_basic_histogram.clp
[ "Apache-2.0" ]
#include <metal_stdlib> #include <simd/simd.h> using namespace metal; struct S { float f; array<float, 5> af; half4 h4; array<half4, 5> ah4; }; struct Uniforms { half4 colorGreen; }; struct Inputs { }; struct Outputs { half4 sk_FragColor [[color(0)]]; }; struct Globals { half4 globalVar; S globalStruct; }; fragment Outputs fragmentMain(Inputs _in [[stage_in]], constant Uniforms& _uniforms [[buffer(0)]], bool _frontFacing [[front_facing]], float4 _fragCoord [[position]]) { Globals _globals{{}, {}}; (void)_globals; Outputs _out; (void)_out; int i; i = 0; int4 i4; i4 = int4(1, 2, 3, 4); float3x3 f3x3; f3x3 = float3x3(float3(1.0, 2.0, 3.0), float3(4.0, 5.0, 6.0), float3(7.0, 8.0, 9.0)); half4 x; x.w = 0.0h; x.yx = half2(0.0h); array<int, 1> ai; ai[0] = 0; array<int4, 1> ai4; ai4[0] = int4(1, 2, 3, 4); array<half3x3, 1> ah2x4; ah2x4[0] = half3x3(half3(1.0h, 2.0h, 3.0h), half3(4.0h, 5.0h, 6.0h), half3(7.0h, 8.0h, 9.0h)); array<float4, 1> af4; af4[0].x = 0.0; af4[0].ywxz = float4(1.0); S s; s.f = 0.0; s.af[1] = 0.0; s.h4.zxy = half3(9.0h); s.ah4[2].yw = half2(5.0h); _globals.globalVar = half4(0.0h); _globals.globalStruct.f = 0.0; half l; l = 0.0h; ai[0] += ai4[0].x; s.f = 1.0; s.af[0] = 2.0; s.h4 = half4(1.0h); s.ah4[0] = half4(2.0h); af4[0] *= float(ah2x4[0][0].x); i4.y = i4.y * i; x.y = x.y * l; s.f *= float(l); _out.sk_FragColor = _uniforms.colorGreen; return _out; }
Metal
3
fourgrad/skia
tests/sksl/shared/Assignment.metal
[ "BSD-3-Clause" ]
- show_success_alert = local_assigns.fetch(:show_success_alert, nil) .js-2fa-recovery-codes{ data: { codes: @codes.to_json, profile_account_path: profile_account_path(two_factor_auth_enabled_successfully: show_success_alert) } }
Haml
3
glimmerhq/glimmerhq
app/views/profiles/two_factor_auths/_codes.html.haml
[ "MIT" ]
// run-rustfix // Test that we do not consider associated types to be sendable without // some applicable trait bound (and we don't ICE). #![allow(dead_code)] trait Trait { type AssocType; fn dummy(&self) { } } fn bar<T:Trait+Send>() { is_send::<T::AssocType>(); //~ ERROR E0277 } fn is_send<T:Send>() { } fn main() { }
Rust
4
Eric-Arellano/rust
src/test/ui/typeck/typeck-default-trait-impl-assoc-type.rs
[ "ECL-2.0", "Apache-2.0", "MIT-0", "MIT" ]
void main() { PostProcessInputs inputs; // Invoke user code postProcess(inputs); #if defined(TARGET_MOBILE) #if defined(FRAG_OUTPUT0) inputs.FRAG_OUTPUT0 = clamp(inputs.FRAG_OUTPUT0, -MEDIUMP_FLT_MAX, MEDIUMP_FLT_MAX); #endif #if defined(FRAG_OUTPUT1) inputs.FRAG_OUTPUT1 = clamp(inputs.FRAG_OUTPUT1, -MEDIUMP_FLT_MAX, MEDIUMP_FLT_MAX); #endif #if defined(FRAG_OUTPUT2) inputs.FRAG_OUTPUT2 = clamp(inputs.FRAG_OUTPUT2, -MEDIUMP_FLT_MAX, MEDIUMP_FLT_MAX); #endif #if defined(FRAG_OUTPUT3) inputs.FRAG_OUTPUT3 = clamp(inputs.FRAG_OUTPUT3, -MEDIUMP_FLT_MAX, MEDIUMP_FLT_MAX); #endif #if defined(FRAG_OUTPUT4) inputs.FRAG_OUTPUT4 = clamp(inputs.FRAG_OUTPUT4, -MEDIUMP_FLT_MAX, MEDIUMP_FLT_MAX); #endif #if defined(FRAG_OUTPUT5) inputs.FRAG_OUTPUT5 = clamp(inputs.FRAG_OUTPUT5, -MEDIUMP_FLT_MAX, MEDIUMP_FLT_MAX); #endif #if defined(FRAG_OUTPUT6) inputs.FRAG_OUTPUT6 = clamp(inputs.FRAG_OUTPUT6, -MEDIUMP_FLT_MAX, MEDIUMP_FLT_MAX); #endif #if defined(FRAG_OUTPUT7) inputs.FRAG_OUTPUT7 = clamp(inputs.FRAG_OUTPUT7, -MEDIUMP_FLT_MAX, MEDIUMP_FLT_MAX); #endif #endif #if defined(FRAG_OUTPUT0) FRAG_OUTPUT_AT0 FRAG_OUTPUT_SWIZZLE0 = inputs.FRAG_OUTPUT0; #endif #if defined(FRAG_OUTPUT1) FRAG_OUTPUT_AT1 FRAG_OUTPUT_SWIZZLE1 = inputs.FRAG_OUTPUT1; #endif #if defined(FRAG_OUTPUT2) FRAG_OUTPUT_AT2 FRAG_OUTPUT_SWIZZLE2 = inputs.FRAG_OUTPUT2; #endif #if defined(FRAG_OUTPUT3) FRAG_OUTPUT_AT3 FRAG_OUTPUT_SWIZZLE3 = inputs.FRAG_OUTPUT3; #endif #if defined(FRAG_OUTPUT4) FRAG_OUTPUT_AT4 FRAG_OUTPUT_SWIZZLE4 = inputs.FRAG_OUTPUT4; #endif #if defined(FRAG_OUTPUT5) FRAG_OUTPUT_AT5 FRAG_OUTPUT_SWIZZLE5 = inputs.FRAG_OUTPUT5; #endif #if defined(FRAG_OUTPUT6) FRAG_OUTPUT_AT6 FRAG_OUTPUT_SWIZZLE6 = inputs.FRAG_OUTPUT6; #endif #if defined(FRAG_OUTPUT7) FRAG_OUTPUT_AT7 FRAG_OUTPUT_SWIZZLE7 = inputs.FRAG_OUTPUT7; #endif #if defined(FRAG_OUTPUT_DEPTH) gl_FragDepth = inputs.depth; #endif }
F#
3
andykit/filament
shaders/src/post_process.fs
[ "Apache-2.0" ]
( Generated from test_statement_switch_variants_in.muv by the MUV compiler. ) ( https://github.com/revarbat/pymuv ) : _main[ _a -- ret ] begin _a @ var! _swvar _swvar @ "1" strcmp not if "One" me @ swap notify break then _swvar @ "2" strcmp not if "Two" me @ swap notify break then repeat begin _a @ var! _swvar2 _swvar2 @ "1" stringcmp not if "One" me @ swap notify break then _swvar2 @ "2" stringcmp not if "Two" me @ swap notify break then repeat begin _a @ var! _swvar3 _swvar3 @ "1" strcmp not if "One" me @ swap notify break then _swvar3 @ "2" strcmp not if "Two" me @ swap notify break then repeat begin 3 var! _swvar4 _swvar4 @ 1 = if "One" me @ swap notify break then _swvar4 @ 2 = if "Two" me @ swap notify break then repeat 0 ; : __start "me" match me ! me @ location loc ! trig trigger ! _main ;
MUF
3
revarbat/pymuv
tests/test_statement_switch_variants_cmp.muf
[ "MIT" ]
INTERFACE ILastFocus PROPERTY LastFocus AS Control GET SET END INTERFACE INTERFACE ITimer METHOD __Timer() AS VOID STRICT END INTERFACE
xBase
4
orangesocks/XSharpPublic
Runtime/VOSdkTyped/Source/VOSdk/GUI_Classes_SDK/Windows/Interfaces.prg
[ "Apache-2.0" ]
// run-pass // aux-build:auto_xc_2.rs extern crate auto_xc_2 as aux; // aux defines impls of Foo, Bar and Baz for A use aux::{Foo, Bar, Baz, A}; // We want to extend all Foo, Bar, Bazes to Quuxes pub trait Quux: Foo + Bar + Baz { } impl<T:Foo + Bar + Baz> Quux for T { } fn f<T:Quux>(a: &T) { assert_eq!(a.f(), 10); assert_eq!(a.g(), 20); assert_eq!(a.h(), 30); } pub fn main() { let a = &A { x: 3 }; f(a); }
Rust
4
mbc-git/rust
src/test/ui/traits/inheritance/auto-xc-2.rs
[ "ECL-2.0", "Apache-2.0", "MIT-0", "MIT" ]
#!perl # # test apparatus for Text::Template module # still incomplete. # use strict; use warnings; use Test::More tests => 4; use_ok 'Text::Template' or exit 1; my $templateIN = q{ This line should have a 3: {1+2} This line should have several numbers: { $t = ''; foreach $n (1 .. 20) { $t .= $n . ' ' } $t } }; my $templateOUT = q{ This line should have a 3: { $OUT = 1+2 } This line should have several numbers: { foreach $n (1 .. 20) { $OUT .= $n . ' ' } } }; # Build templates from string my $template = Text::Template->new('type' => 'STRING', 'source' => $templateIN); isa_ok $template, 'Text::Template'; $templateOUT = Text::Template->new('type' => 'STRING', 'source' => $templateOUT); isa_ok $templateOUT, 'Text::Template'; # Fill in templates my $text = $template->fill_in(); my $textOUT = $templateOUT->fill_in(); # (1) They should be the same is $text, $textOUT; # Missing: Test this feature in Safe compartments; # it's a totally different code path. # Decision: Put that into safe.t, because that file should # be skipped when Safe.pm is unavailable. exit;
Perl
4
pmesnier/openssl
external/perl/Text-Template-1.56/t/out.t
[ "Apache-2.0" ]
- dashboard: ad_performance title: Ad Performance layout: newspaper elements: - name: Progress type: text title_text: Progress subtitle_text: Current Performance Trends body_text: '' row: 0 col: 0 width: 24 height: 2 - name: Details type: text title_text: Details subtitle_text: Drill to Explore Specific Trends row: 24 col: 0 width: 24 height: 2 - title: Average cost per conversion over time name: Average cost per conversion over time model: google_adwords explore: master_stats type: looker_line fields: - master_stats.average_cost_per_conversion - master_stats._data_week sorts: - master_stats._data_week desc limit: 500 column_limit: 50 label: Average Cost per Conversion stacking: '' show_value_labels: false label_density: 25 legend_position: center x_axis_gridlines: false y_axis_gridlines: true show_view_names: false limit_displayed_rows: false y_axis_combined: true show_y_axis_labels: true show_y_axis_ticks: true y_axis_tick_density: default y_axis_tick_density_custom: 5 show_x_axis_label: true show_x_axis_ticks: true x_axis_scale: time y_axis_scale_mode: linear show_null_points: false point_style: none interpolation: linear ordering: none show_null_labels: false show_totals_labels: false show_silhouette: false totals_color: "#808080" leftAxisLabelVisible: false leftAxisLabel: '' rightAxisLabelVisible: false rightAxisLabel: '' barColors: - red - blue smoothedBars: false orientation: automatic labelPosition: left percentType: total percentPosition: inline valuePosition: right labelColorEnabled: false labelColor: "#FFF" series_types: {} show_dropoff: true y_axes: - label: '' maxValue: minValue: orientation: left showLabels: true showValues: true tickDensity: default tickDensityCustom: 5 type: log unpinAxis: false valueFormat: series: - id: master_stats.total_impressions name: Ad Stats Total Impressions __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 90 - id: master_stats.total_interactions name: Ad Stats Total Interactions __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 94 - id: master_stats.total_conversions name: Ad Stats Total Conversions __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 98 __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 78 discontinuous_nulls: false focus_on_hover: false reference_lines: [] trend_lines: - color: "#000000" label_position: right period: 7 regression_type: linear series_index: 1 show_label: false label_type: string __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 108 listen: Ad Group Name: ad_group.ad_group_name Date: master_stats._data_date Campaign Name: campaign.campaign_name row: 2 col: 0 width: 24 height: 7 - title: Top 10 keyword performance name: Top 10 keyword performance model: google_adwords explore: master_stats type: looker_column fields: - keyword.criteria - master_stats.average_cost_per_conversion - master_stats.total_impressions - master_stats.total_interactions - master_stats.total_conversions - master_stats.total_cost_usd - master_stats.average_interaction_rate - master_stats.average_conversion_rate - master_stats.average_cost_per_click sorts: - master_stats.total_cost_usd desc limit: 10 column_limit: 50 label: Top 10 Keyword Performance stacking: '' show_value_labels: false label_density: 25 legend_position: center x_axis_gridlines: false y_axis_gridlines: true show_view_names: false limit_displayed_rows: false y_axis_combined: true show_y_axis_labels: true show_y_axis_ticks: true y_axis_tick_density: default y_axis_tick_density_custom: 5 show_x_axis_label: true show_x_axis_ticks: true x_axis_scale: auto y_axis_scale_mode: linear ordering: none show_null_labels: false show_totals_labels: false show_silhouette: false totals_color: "#808080" hidden_fields: - master_stats.total_impressions - master_stats.total_interactions - master_stats.total_conversions - master_stats.average_interaction_rate - master_stats.average_conversion_rate - master_stats.average_cost_per_click y_axes: - label: '' maxValue: minValue: orientation: left showLabels: true showValues: true tickDensity: default tickDensityCustom: 5 type: linear unpinAxis: false valueFormat: series: - id: master_stats.average_cost_per_conversion name: Cost per Conversion __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 187 __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 175 - label: maxValue: minValue: orientation: right showLabels: true showValues: true tickDensity: default tickDensityCustom: 5 type: linear unpinAxis: false valueFormat: series: - id: master_stats.total_cost_usd name: Total Cost USD __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 205 __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 193 series_types: master_stats.average_cost_per_conversion: line listen: Ad Group Name: ad_group.ad_group_name Date: master_stats._data_date Campaign Name: campaign.campaign_name row: 9 col: 12 width: 12 height: 7 - title: Top 10 creative performance name: Top 10 creative performance model: google_adwords explore: master_stats type: looker_column fields: - ad.creative - master_stats.average_cost_per_conversion - master_stats.total_impressions - master_stats.total_interactions - master_stats.total_conversions - master_stats.total_cost_usd - master_stats.average_interaction_rate - master_stats.average_conversion_rate - master_stats.average_cost_per_click sorts: - master_stats.total_cost_usd desc limit: 10 column_limit: 50 label: Top 10 Creative Performance stacking: '' show_value_labels: false label_density: 25 legend_position: center x_axis_gridlines: false y_axis_gridlines: true show_view_names: false limit_displayed_rows: false y_axis_combined: true show_y_axis_labels: true show_y_axis_ticks: true y_axis_tick_density: default y_axis_tick_density_custom: 5 show_x_axis_label: true show_x_axis_ticks: true x_axis_scale: ordinal y_axis_scale_mode: linear ordering: none show_null_labels: false show_totals_labels: false show_silhouette: false totals_color: "#808080" show_row_numbers: true truncate_column_names: false hide_totals: false hide_row_totals: false table_theme: editable enable_conditional_formatting: false conditional_formatting_ignored_fields: [] conditional_formatting_include_totals: false conditional_formatting_include_nulls: false series_types: master_stats.average_cost_per_conversion: line hidden_fields: - master_stats.total_conversions - master_stats.total_interactions - master_stats.total_impressions - master_stats.average_interaction_rate - master_stats.average_conversion_rate - master_stats.average_cost_per_click y_axes: - label: maxValue: minValue: orientation: left showLabels: true showValues: true tickDensity: default tickDensityCustom: 5 type: linear unpinAxis: false valueFormat: series: - id: master_stats.average_cost_per_conversion name: Cost per Conversion __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 294 __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 282 - label: maxValue: minValue: orientation: right showLabels: true showValues: true tickDensity: default tickDensityCustom: 5 type: linear unpinAxis: false valueFormat: series: - id: master_stats.total_cost_usd name: Total Cost USD __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 312 __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 300 x_axis_datetime_label: '' y_axis_reversed: false listen: Ad Group Name: ad_group.ad_group_name Date: master_stats._data_date Campaign Name: campaign.campaign_name row: 9 col: 0 width: 12 height: 7 - title: Top 10 audience performance name: Top 10 audience performance model: google_adwords explore: master_stats type: looker_column fields: - audience.criteria - master_stats.average_cost_per_conversion - master_stats.total_cost_usd sorts: - master_stats.total_cost_usd desc limit: 10 column_limit: 50 label: Top 10 audience performance stacking: '' show_value_labels: false label_density: 25 legend_position: center x_axis_gridlines: false y_axis_gridlines: true show_view_names: true limit_displayed_rows: false y_axis_combined: true show_y_axis_labels: true show_y_axis_ticks: true y_axis_tick_density: default y_axis_tick_density_custom: 5 show_x_axis_label: true show_x_axis_ticks: true x_axis_scale: auto y_axis_scale_mode: linear ordering: none show_null_labels: false show_totals_labels: false show_silhouette: false totals_color: "#808080" y_axes: - label: '' maxValue: minValue: orientation: left showLabels: true showValues: true tickDensity: default tickDensityCustom: 5 type: linear unpinAxis: false valueFormat: series: - id: master_stats.average_cost_per_conversion name: Audience Stats Cost per Conversion __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 377 __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 365 - label: maxValue: minValue: orientation: right showLabels: true showValues: true tickDensity: default tickDensityCustom: 5 type: linear unpinAxis: false valueFormat: series: - id: master_stats.total_cost_usd name: Audience Stats Total Cost USD __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 395 __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 383 series_types: master_stats.average_cost_per_conversion: line listen: Ad Group Name: ad_group.ad_group_name Date: master_stats._data_date Campaign Name: campaign.campaign_name row: 16 col: 0 width: 12 height: 8 - title: Ad details name: Ad details model: google_adwords explore: master_stats type: table fields: - ad_group.ad_group_name - master_stats.average_cost_per_conversion - master_stats.average_interaction_rate - master_stats.average_cost_per_click - master_stats.average_conversion_rate - master_stats.total_impressions - master_stats.total_interactions - master_stats.total_conversions - master_stats.total_cost_usd sorts: - master_stats.total_cost_usd desc limit: 20 column_limit: 50 label: Ad Details query_timezone: America/Los_Angeles show_view_names: false show_row_numbers: true truncate_column_names: false hide_totals: false hide_row_totals: false table_theme: white limit_displayed_rows: false stacking: '' show_value_labels: false label_density: 25 legend_position: center x_axis_gridlines: false y_axis_gridlines: true y_axis_combined: true show_y_axis_labels: true show_y_axis_ticks: true y_axis_tick_density: default y_axis_tick_density_custom: 5 show_x_axis_label: true show_x_axis_ticks: true x_axis_scale: auto y_axis_scale_mode: linear ordering: none show_null_labels: false show_totals_labels: false show_silhouette: false totals_color: "#808080" series_types: {} enable_conditional_formatting: false conditional_formatting_ignored_fields: [] conditional_formatting_include_totals: false conditional_formatting_include_nulls: false listen: Ad Group Name: ad_group.ad_group_name Date: master_stats._data_date Campaign Name: campaign.campaign_name row: 26 col: 0 width: 24 height: 4 - title: Keyword details name: Keyword details model: google_adwords explore: master_stats type: table fields: - keyword.criteria - ad_group.ad_group_name - campaign.campaign_name - master_stats.average_cost_per_conversion - master_stats.average_interaction_rate - master_stats.average_conversion_rate - master_stats.average_cost_per_click - master_stats.total_impressions - master_stats.total_interactions - master_stats.total_conversions - master_stats.total_cost_usd sorts: - master_stats.total_cost_usd desc limit: 10 column_limit: 50 label: Top 10 Keyword Performance show_view_names: false show_row_numbers: false truncate_column_names: false hide_totals: false hide_row_totals: false table_theme: transparent limit_displayed_rows: false enable_conditional_formatting: false conditional_formatting_ignored_fields: [] conditional_formatting_include_totals: false conditional_formatting_include_nulls: false stacking: '' show_value_labels: false label_density: 25 legend_position: center x_axis_gridlines: false y_axis_gridlines: true y_axis_combined: true show_y_axis_labels: true show_y_axis_ticks: true y_axis_tick_density: default y_axis_tick_density_custom: 5 show_x_axis_label: true show_x_axis_ticks: true x_axis_scale: auto y_axis_scale_mode: linear ordering: none show_null_labels: false show_totals_labels: false show_silhouette: false totals_color: "#808080" hidden_fields: y_axes: - label: '' maxValue: minValue: orientation: left showLabels: true showValues: true tickDensity: default tickDensityCustom: 5 type: linear unpinAxis: false valueFormat: series: - id: master_stats.average_cost_per_conversion name: Keyword Stats Average Cost per Conversion __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 656 __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 644 - label: maxValue: minValue: orientation: right showLabels: true showValues: true tickDensity: default tickDensityCustom: 5 type: linear unpinAxis: false valueFormat: series: - id: master_stats.total_cost name: Keyword Stats Total Cost __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 674 __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 662 series_types: {} listen: Ad Group Name: ad_group.ad_group_name Date: master_stats._data_date Campaign Name: campaign.campaign_name row: 30 col: 0 width: 24 height: 6 - title: Bid strategy and match cost per conversion name: Bid strategy and match cost per conversion model: google_adwords explore: master_stats type: looker_column fields: - keyword.bidding_strategy_type - master_stats.average_cost_per_conversion - master_stats.total_cost_usd - keyword.keyword_match_type pivots: - keyword.keyword_match_type filters: master_stats.average_cost_per_conversion: NOT NULL sorts: - keyword.keyword_match_type desc 0 - master_stats.total_cost_usd desc 0 limit: 500 column_limit: 50 label: Top 10 Keyword Performance stacking: '' show_value_labels: false label_density: 25 legend_position: center x_axis_gridlines: false y_axis_gridlines: true show_view_names: false limit_displayed_rows: false y_axis_combined: true show_y_axis_labels: true show_y_axis_ticks: true y_axis_tick_density: default y_axis_tick_density_custom: 5 show_x_axis_label: true show_x_axis_ticks: true x_axis_scale: auto y_axis_scale_mode: linear ordering: none show_null_labels: false show_totals_labels: false show_silhouette: false totals_color: "#808080" show_null_points: true point_style: none interpolation: linear value_labels: legend label_type: labPer custom_color_enabled: false custom_color: forestgreen show_single_value_title: true show_comparison: false comparison_type: value comparison_reverse_colors: false show_comparison_label: true font_size: '12' hidden_fields: - master_stats.total_cost_usd y_axes: - label: '' maxValue: minValue: orientation: left showLabels: true showValues: true tickDensity: default tickDensityCustom: type: linear unpinAxis: false valueFormat: series: - id: PHRASE - Keyword Stats Cost per Conversion name: PHRASE - Keyword Stats Cost per Conversion __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 479 - id: EXACT - Keyword Stats Cost per Conversion name: EXACT - Keyword Stats Cost per Conversion __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 483 - id: BROAD - Keyword Stats Cost per Conversion name: BROAD - Keyword Stats Cost per Conversion __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 487 __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 467 - label: maxValue: minValue: orientation: right showLabels: true showValues: true tickDensity: default tickDensityCustom: type: linear unpinAxis: false valueFormat: series: - id: PHRASE - Keyword Stats Total Cost USD name: PHRASE - Keyword Stats Total Cost USD __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 505 - id: EXACT - Keyword Stats Total Cost USD name: EXACT - Keyword Stats Total Cost USD __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 509 - id: BROAD - Keyword Stats Total Cost USD name: BROAD - Keyword Stats Total Cost USD __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 513 __FILE: google_adwords/ad_group_performance.dashboard.lookml __LINE_NUM: 493 series_types: {} listen: Ad Group Name: ad_group.ad_group_name Date: master_stats._data_date Campaign Name: campaign.campaign_name row: 16 col: 12 width: 12 height: 8 filters: - name: Campaign Name title: Campaign Name type: field_filter default_value: '' model: google_adwords explore: campaign field: campaign.campaign_name listens_to_filters: - Ad Group Name allow_multiple_values: true required: false - name: Ad Group Name title: Ad Group Name type: field_filter default_value: '' model: google_adwords explore: ad_group field: ad_group.ad_group_name listens_to_filters: [] allow_multiple_values: true required: false - name: Date title: Date type: field_filter default_value: 2 quarters model: google_adwords explore: master_stats field: master_stats._data_date listens_to_filters: [] allow_multiple_values: true required: false
LookML
3
umesh0894/google_adwords
ad_group_performance.dashboard.lookml
[ "MIT" ]
from typing import Tuple from torch.utils.data import IterDataPipe from torch.utils.data.datapipes.utils.common import deprecation_warning_torchdata class LineReaderIterDataPipe(IterDataPipe[Tuple[str, str]]): r""" :class:`LineReaderIterDataPipe` Iterable DataPipe to load file name and stream as source IterDataPipe and yield filename and line(s). Args: datapipe: Iterable DataPipe providing file name and string file stream """ def __init__(self, datapipe): self.datapipe = datapipe deprecation_warning_torchdata(type(self).__name__) def __iter__(self): for file_name, stream in self.datapipe: for line in stream: yield file_name, line
Python
4
xiaohanhuang/pytorch
torch/utils/data/datapipes/iter/linereader.py
[ "Intel" ]
#!/usr/bin/env pike int count = 0, start, end; mapping(int:multiset(int)) graph = ([]); mapping(int:int) big = ([]); multiset(int) set = (<>); int twice = 0; void dfs(int u) { if (u == end) { count++; return; } int t = set[u] && !big[u]; set[u] = true; if (t) twice = 1; foreach (graph[u]; int k; int v) { if (big[k] || !set[k] || (k != start && !twice)) dfs(k); } if (t) twice = 0; else set[u] = false; } int main() { mapping(string:int) names = ([]); int i = 1; while (string s = Stdio.stdin.gets()) { array(string) xs = s / "-"; int u = names[xs[0]]; if (u == 0) { names[xs[0]] = i++; u = names[xs[0]]; graph[u] = (<>); big[u] = xs[0][0] < 'a'; if (xs[0] == "start") start = u; else if (xs[0] == "end") end = u; } int v = names[xs[1]]; if (v == 0) { names[xs[1]] = i++; v = names[xs[1]]; graph[v] = (<>); big[v] = xs[1][0] < 'a'; if (xs[1] == "start") start = v; else if (xs[1] == "end") end = v; } graph[u][v] = true; graph[v][u] = true; } dfs(start); write("%d\n", count); }
Pike
4
abeaumont/competitive-programming
advent-of-code/2021/day12/part2.pike
[ "WTFPL" ]
p :global(span:not(.test)) { color: green; }
CSS
3
fabiosantoscode/swc
css/parser/tests/fixture/styled-jsx/selector/2/input.css
[ "Apache-2.0", "MIT" ]
<template> <div class="main"> <p>Page with SCSS</p> <p> <NuxtLink to="/less"> LESS </NuxtLink> </p> </div> </template> <style lang="scss" scoped> /* ~/assets/variables.scss is injected automatically here */ .main { background: $main; padding: 10px; } </style>
Vue
4
ardyno/nuxt.js
examples/style-resources/pages/index.vue
[ "MIT" ]
divert(-1) postscript.m4 Initialization for Postscript output. * Circuit_macros Version 9.3, copyright (c) 2020 J. D. Aplevich under * * the LaTeX Project Public Licence in file Licence.txt. The files of * * this distribution may be redistributed or modified provided that this * * copyright notice is included and provided that modifications are clearly * * marked to distinguish them from this distribution. There is no warranty * * whatsoever for these files. * define(`m4picprocessor',dpic) define(`m4postprocessor',postscript) ifdef(`libgen_',,`include(libgen.m4)divert(-1)')dnl Color utilities define(`setrgb',`pushdef(`r_',`$1')pushdef(`g_',`$2')pushdef(`b_',`$3')dnl pushdef(`m4cl_',ifelse(`$4',,lcspec,`$4'))dnl command sprintf(" /m4cl_ {%7.5f %7.5f %7.5f} def",r_,g_,b_) command " m4cl_ setrgbcolor"') define(`resetrgb',`popdef(`m4cl_')popdef(`r_')popdef(`g_')popdef(`b_')dnl ifdef(`r_', `command sprintf(" %7.5f %7.5f %7.5f setrgbcolor",r_,g_,b_)', `command " 0 0 0 setrgbcolor"') ') `rgbdraw(color triple, drawing commands)' define(`rgbdraw',`setrgb(`$1',`$2',`$3') shift(shift(shift($@))) resetrgb') `rgbfill(color triple, closed path)' define(`rgbfill', `command " npath /npath {} def /endstroke {} def" ifm4_rgbtestcomma(`$1', `shift($@) command "gsave `$1' setrgbcolor"', `shift(shift(shift($@))) command sprintf("gsave %7.5f %7.5f %7.5f setrgbcolor", `$1',`$2',`$3')') command " fill grestore ostroke" command " /endstroke {ostroke} def /npath {newpath} def"') `Top-level test for comma' define(`ifm4_rgbtestcomma',`ifinstr(`$1',`,',`$2',`$3')') Define some primary colors define(`defineRGBprimaries',` command "/white {1 1 1} def /lightgrey {0.75 0.75 0.75} def /lightgray {0.75 0.75 0.75} def /grey {0.5 0.5 0.5} def /gray {0.5 0.5 0.5} def /darkgrey {0.25 0.25 0.25} def /darkgray {0.25 0.25 0.25} def /black {0 0 0} def /red {1 0 0} def /green {0 1 0} def /blue {0 0 1} def /cyan {0 1 1} def /magenta {1 0 1} def /yellow {1 1 0} def"') define(`thinlines_',`linethick = 0.4 arrowwid = 0.04*scale; arrowht = 0.2/3*scale command " 0.4 setlinewidth";') define(`thicklines_',`linethick = 0.8 arrowwid = 0.05*scale; arrowht = 0.1*scale command " 0.8 setlinewidth";') `linethick_(x) set line width to x pt (default 0.8) and scale arrowhead parameters' define(`linethick_',`linethick = ifelse(`$1',,`0.8',`$1'); dnl arrowwid = ifelse(`$1',,`0.05',linethick/16)*scale; dnl arrowht = ifelse(`$1',,`0.1',linethick/8)*scale;') divert(0)dnl
M4
4
gammy55/linguist
samples/M4/postscript.m4
[ "MIT" ]
//! Constants for the 128-bit signed integer type. //! //! *[See also the `i128` primitive type][i128].* //! //! New code should use the associated constants directly on the primitive type. #![stable(feature = "i128", since = "1.26.0")] #![rustc_deprecated( since = "TBD", reason = "all constants in this module replaced by associated constants on `i128`" )] int_module! { i128, #[stable(feature = "i128", since="1.26.0")] }
Rust
4
mbc-git/rust
library/core/src/num/shells/i128.rs
[ "ECL-2.0", "Apache-2.0", "MIT-0", "MIT" ]
@require 'subdir/**/*' .index color: red
Stylus
1
johanberonius/parcel
packages/core/integration-tests/test/integration/stylus-glob-import/index.styl
[ "MIT" ]
#tag Class Protected Class GKNotificationBanner Inherits NSObject #tag DelegateDeclaration, Flags = &h0 Delegate Sub BannerCompletionHandler() #tag EndDelegateDeclaration #tag Method, Flags = &h21 Private Shared Function ClassRef() As Ptr static ref as ptr = NSClassFromString("GKNotificationBanner") return ref End Function #tag EndMethod #tag Method, Flags = &h0 Shared Sub ShowBannerWithTitleMessageCompletionHandler(title as Text, message as Text, completionHandler as BannerCompletionHandler) declare sub showBannerWithTitle_ lib GameKitLib selector "showBannerWithTitle:message:completionHandler:" (clsRef as ptr, title as CFStringRef, message as CFStringRef, completionHandler as ptr) if completionHandler <> nil then dim blk as new iOSBlock(completionHandler) showBannerWithTitle_(ClassRef, title, message, blk.Handle) else showBannerWithTitle_(ClassRef, title, message, nil) end if End Sub #tag EndMethod #tag Method, Flags = &h0 Shared Sub ShowBannerWithTitleMessageDurationCompletionHandler(title as Text, message as Text, duration as double, completionHandler as BannerCompletionHandler) declare sub showBannerWithTitle_ lib GameKitLib selector "showBannerWithTitle:message:duration:completionHandler:" (clsRef as ptr, title as CFStringRef, message as CFStringRef, duration as double, completionHandler as ptr) if completionHandler <> nil Then dim blk as new iOSBlock(completionHandler) showBannerWithTitle_(ClassRef, title, message, duration, blk.Handle) else showBannerWithTitle_(ClassRef, title, message, duration, nil) end if End Sub #tag EndMethod #tag ViewBehavior #tag ViewProperty Name="Index" Visible=true Group="ID" InitialValue="-2147483648" Type="Integer" EditorType="" #tag EndViewProperty #tag ViewProperty Name="Left" Visible=true Group="Position" InitialValue="0" Type="Integer" EditorType="" #tag EndViewProperty #tag ViewProperty Name="Name" Visible=true Group="ID" InitialValue="" Type="String" EditorType="" #tag EndViewProperty #tag ViewProperty Name="Super" Visible=true Group="ID" InitialValue="" Type="String" EditorType="" #tag EndViewProperty #tag ViewProperty Name="Top" Visible=true Group="Position" InitialValue="0" Type="Integer" EditorType="" #tag EndViewProperty #tag EndViewBehavior End Class #tag EndClass
Xojo
4
kingj5/iOSKit
Modules/GameKitFolder/GameKit/GKNotificationBanner.xojo_code
[ "MIT" ]
# git describe > Rendi il nome di un oggetto Git più leggibile usando i riferimenti disponibili. > Maggiori informazioni: <https://git-scm.com/docs/git-describe>. - Crea un nome univoco per il commit corrente (il nome contiene i tag più recenti, il numero di commit aggiuntivi, e l'hash breve del commit): `git describe` - Crea un nome di 4 cifre per l'hash breve del commit: `git describe --abbrev={{4}}` - Genera un nome che includa anche il percorso di riferimento: `git describe --all` - Descrivi un tag Git: `git describe {{v1.0.0}}` - Crea un nome per l'ultimo commit di un dato ramo: `git describe {{nome_ramo}}`
Markdown
4
derNiklaas/tldr
pages.it/common/git-describe.md
[ "CC-BY-4.0" ]
<?xml version="1.0" encoding="UTF-8"?> <faces-config> <faces-config-extension> <namespace-uri>http://www.ibm.com/xsp/custom</namespace-uri> <default-prefix>xc</default-prefix> </faces-config-extension> <composite-component> <component-type>jobApplication_list</component-type> <composite-name>jobApplication_list</composite-name> <composite-file>/jobApplication_list.xsp</composite-file> <composite-extension> <designer-extension> <in-palette>true</in-palette> </designer-extension> </composite-extension> <property> <property-name>jobApplicationList</property-name> <property-class>object</property-class> <property-extension> <required>true</required> </property-extension> </property> <property> <property-name>title</property-name> <property-class>string</property-class> <property-extension> <required>true</required> </property-extension> </property> <property> <property-name>showButtons</property-name> <property-class>boolean</property-class> <property-extension> <designer-extension> <default-value>true</default-value> </designer-extension> <required>false</required> </property-extension> </property> <property> <property-name>rowCount</property-name> <property-class>int</property-class> <property-extension> <required>true</required> </property-extension> </property> </composite-component> </faces-config>
XPages
4
IBM-FMC/TESTE
nsf/CustomControls/jobApplication_list.xsp-config
[ "Apache-2.0" ]
<svg id="color-fill" xmlns="http://www.w3.org/2000/svg" version="1.1" width="300" height="300" xmlns:xlink="http://www.w3.org/1999/xlink"> <rect x="25" y="25" width="250" height="250" style="fill:#ff0000;fill-opacity:0.2;stroke:none" /> <rect x="50" y="50" width="100" height="200" style="fill:#000000;fill-opacity:1;stroke:none" /> <rect x="75" y="75" width="150" height="150" style="fill:#00ff00;fill-opacity:0.5;stroke:none" /> <rect x="100" y="100" width="100" height="100" style="fill:#000080;fill-opacity:1;stroke:none" /> </svg>
SVG
2
KostaMalsev/three.js
examples/models/svg/tests/ordering.svg
[ "MIT" ]
/*!40101 SET NAMES binary*/; /*!40014 SET FOREIGN_KEY_CHECKS=0*/; /*!40103 SET TIME_ZONE='+00:00' */; INSERT INTO `enum-set` VALUES ("g51",""), ("g5d","x25"), ("g4f","x13,x62"), ("g30","x04,x17,x51"), ("g95","x08,x40,x53,x51"), ("ged","x29,x53,x25,x58,x08"), ("g67","x59,x42,x20,x15,x28,x11"), ("gc3","x12,x45,x37,x34,x36,x50,x09"), ("gef","x34,x63,x58,x56,x28,x49,x62,x21"), ("g4b","x59,x30,x41,x39,x21,x00,x45,x03,x14"), ("g55","x47,x57,x43,x21,x34,x50,x54,x24,x22,x05"), ("g6b","x42,x34,x52,x18,x51,x50,x40,x47,x24,x39,x20"), ("g28","x13,x24,x46,x03,x57,x10,x28,x23,x18,x37,x60,x20"), ("gbe","x35,x46,x55,x63,x06,x09,x50,x39,x13,x12,x17,x62,x59"), ("gf7","x04,x25,x16,x03,x31,x61,x43,x11,x63,x39,x21,x01,x24,x42"), ("g39","x56,x36,x50,x04,x07,x62,x14,x01,x39,x25,x27,x55,x44,x61,x40"), ("g8d","x26,x27,x47,x08,x23,x30,x32,x52,x49,x02,x06,x39,x56,x18,x25,x14"), ("gc6","x29,x59,x21,x39,x33,x02,x08,x11,x04,x13,x62,x07,x55,x26,x03,x50,x63"), ("gcc","x07,x54,x09,x24,x23,x27,x37,x61,x55,x17,x49,x20,x62,x00,x06,x58,x44,x46"), ("gcf","x55,x35,x42,x57,x56,x48,x32,x28,x29,x47,x07,x17,x49,x03,x30,x15,x60,x34,x21"), ("g2b","x03,x42,x32,x02,x53,x20,x39,x35,x23,x30,x26,x00,x10,x50,x34,x07,x31,x41,x56,x62"), ("gdd","x11,x37,x10,x19,x28,x41,x35,x04,x60,x23,x56,x00,x31,x50,x03,x36,x15,x52,x63,x08,x33"), ("g4d","x18,x09,x37,x31,x15,x51,x50,x56,x63,x03,x14,x49,x16,x12,x34,x45,x38,x20,x05,x28,x30,x01"), ("g27","x01,x08,x21,x41,x29,x02,x32,x31,x06,x24,x20,x43,x48,x51,x18,x34,x30,x00,x14,x03,x09,x44,x05"), ("g98","x24,x50,x46,x61,x09,x17,x20,x26,x28,x08,x19,x43,x35,x56,x36,x27,x25,x48,x63,x30,x21,x38,x33,x07"); INSERT INTO `enum-set` VALUES (154, 11937444798263156608); -- g99 -> x07,x08,x09,x10,x11,x12,x14,x16,x17,x18,x19,x22,x25,x26,x28,x29,x30,x31,x32,x33,x35,x38,x39,x41,x44,x46,x49,x51,x53,x55,x56,x58,x61,x63 -- INSERT INTO `enum-set` VALUES (0x676639, 0x7830302C7830322C7830352C7830392C7831332C7831342C7831352C7831362C7831392C7832302C7833302C7833332C7833362C7833372C7833382C7834312C7834332C7834352C7834362C7834372C7834382C7835302C7835352C7835392C7836302C7836312C783633); -- -- re-enable once pingcap/tidb#10154 is fixed and cherry-picked into a 3.0-beta release.
SQL
2
imtbkcat/tidb-lightning
tests/various_types/data/vt.enum-set.sql
[ "Apache-2.0" ]
; CLW file contains information for the MFC ClassWizard [General Info] Version=1 LastClass=CUdmpViewDlg LastTemplate=CDialog NewFileInclude1=#include "stdafx.h" NewFileInclude2=#include "UdmpView.h" ClassCount=3 Class1=CUdmpViewApp Class2=CUdmpViewDlg Class3=CAboutDlg ResourceCount=5 Resource1=IDD_ABOUTBOX Resource2=IDR_MAINFRAME Resource3=IDD_UDMPVIEW_DIALOG Resource4=IDD_ABOUTBOX (English (U.S.)) Resource5=IDD_UDMPVIEW_DIALOG (English (U.S.)) [CLS:CUdmpViewApp] Type=0 HeaderFile=UdmpView.h ImplementationFile=UdmpView.cpp Filter=N [CLS:CUdmpViewDlg] Type=0 HeaderFile=UdmpViewDlg.h ImplementationFile=UdmpViewDlg.cpp Filter=D BaseClass=CDialog VirtualFilter=dWC LastObject=CUdmpViewDlg [CLS:CAboutDlg] Type=0 HeaderFile=UdmpViewDlg.h ImplementationFile=UdmpViewDlg.cpp Filter=D [DLG:IDD_ABOUTBOX] Type=1 ControlCount=4 Control1=IDC_STATIC,static,1342177283 Control2=IDC_STATIC,static,1342308352 Control3=IDC_STATIC,static,1342308352 Control4=IDOK,button,1342373889 Class=CAboutDlg [DLG:IDD_UDMPVIEW_DIALOG] Type=1 ControlCount=3 Control1=IDOK,button,1342242817 Control2=IDCANCEL,button,1342242816 Control3=IDC_STATIC,static,1342308352 Class=CUdmpViewDlg [DLG:IDD_UDMPVIEW_DIALOG (English (U.S.))] Type=1 Class=CUdmpViewDlg ControlCount=15 Control1=IDOK,button,1342242817 Control2=ID_OPEN,button,1342242816 Control3=IDC_LIST_INFO,listbox,1352728841 Control4=IDC_LIST_STREAM,listbox,1353777928 Control5=ID_SHOW,button,1476460544 Control6=ID_SELECT_ALL,button,1342242816 Control7=ID_CLOSE,button,1476460544 Control8=ID_COPY,button,1342242816 Control9=ID_CLEAR,button,1342242816 Control10=ID_COPY_ALL,button,1342242816 Control11=IDC_EDIT_RVA,edit,1350631552 Control12=IDC_STATIC,static,1342308352 Control13=IDC_EDIT_SIZE,edit,1350631552 Control14=IDC_STATIC,static,1342308352 Control15=ID_RAW_READ,button,1476460544 [DLG:IDD_ABOUTBOX (English (U.S.))] Type=1 Class=CAboutDlg ControlCount=4 Control1=IDC_STATIC,static,1342177283 Control2=IDC_STATIC,static,1342308480 Control3=IDC_STATIC,static,1342308352 Control4=IDOK,button,1342373889
Clarion
1
oudream/ccxx
test/dump/swdbgbk_src/chap12/UdmpView/UdmpView.clw
[ "MIT" ]
export MemCached := SERVICE DATASET MGetDataset(CONST VARSTRING servers, CONST VARSTRING key, CONST VARSTRING partitionKey = 'root') : cpp,action,context,entrypoint='MGetData'; END; STRING servers := '--SERVER=myIP:11211'; myRec := RECORD integer i1; integer i2; real r1; string name; END; ds1 := DATASET([ {2, 3, 3.14, 'pi'}, {7, 11, 1.412, 'root2'} ], myRec); output(ds1); MemCached.MGetDataset(servers, 'ds1');
ECL
3
miguelvazq/HPCC-Platform
ecl/regress/issue12122.ecl
[ "Apache-2.0" ]
#!/bin/sh PATH=/bin:/usr/bin TERM=screen [ -z "$TEST_TMUX" ] && TEST_TMUX=$(readlink -f ../tmux) TMUX="$TEST_TMUX -Ltest" $TMUX kill-server 2>/dev/null TMP=$(mktemp) trap "rm -f $TMP" 0 1 15 cat <<EOF >$TMP new -sfoo -nfoo0; neww -nfoo1; neww -nfoo2 new -sbar -nbar0; neww -nbar1; neww -nbar2 EOF $TMUX -f$TMP start </dev/null || exit 1 sleep 1 $TMUX lsw -aF '#{session_name},#{window_name}'|sort >$TMP || exit 1 $TMUX kill-server 2>/dev/null cat <<EOF|cmp -s $TMP - || exit 1 bar,bar0 bar,bar1 bar,bar2 foo,foo0 foo,foo1 foo,foo2 EOF cat <<EOF >$TMP new -sfoo -nfoo0 neww -nfoo1 neww -nfoo2 new -sbar -nbar0 neww -nbar1 neww -nbar2 EOF $TMUX -f$TMP start </dev/null || exit 1 sleep 1 $TMUX lsw -aF '#{session_name},#{window_name}'|sort >$TMP || exit 1 $TMUX kill-server 2>/dev/null cat <<EOF|cmp -s $TMP - || exit 1 bar,bar0 bar,bar1 bar,bar2 foo,foo0 foo,foo1 foo,foo2 EOF exit 0
Shell
3
SliceThePi/tmux
regress/command-order.sh
[ "ISC" ]
extern i64_to_str ; Function that converts a number to a string ; Arguments 1: ; RDI - the number ; Returns: ; The character pointer in RAX of size 20 i64_to_str: ; Save return address pop rsi ; Save number into rax mov rax, rdi ; Allocate 20 bytes for the character pointer sub rsp, 20 ; Save the character pointer mov rdi, rsp ; Load return address push rsi ; clear stack alloc mov qword [rdi], 0 mov qword [rdi+8], 0 mov dword [rdi+16], 0 ; Set up values mov rcx, 19 mov rbx, 10 ; Start looping _loop: cmp rax, 0 je _end ; Divide by 10 xor rdx, rdx div rbx ; Number digit in rdx add rdx, 48 mov byte [rdi+rcx], dl dec rcx jmp _loop _end: ; Return pointer in rax mov rax, rdi ret
Parrot Assembly
4
giag3/peng-utils
asm-lib/i64_to_str.pasm
[ "MIT" ]
2018-12-13 19:13:25 >> brett12345 (brett@96247946.C69A8C52.B0B4CEE2.IP) has joined #recovery 2018-12-13 19:13:25 -- Topic for #recovery is "ACCOUNT RECOVERY | https://orpheus.network/recovery.php | State your new username if it is not the same as your IRC nick | DO NOT PM THE MODERATORS UNLESS ASKED. | Emails might take up to 10 minutes to arrive. Be patient and check Spam folders! | Don't post your Token in Chat |" 2018-12-13 19:13:25 -- Topic set by Antithetos on Sun, 04 Nov 2018 19:27:14 2018-12-13 19:13:25 -- Channel #recovery: 16 nicks (14 ops, 0 halfops, 0 voices, 2 normals) 2018-12-13 19:13:27 -- Channel created on Thu, 01 Nov 2018 19:14:21 2018-12-13 19:42:08 >> Musaeus- (Musaeus@E77A0414.C258CFA3.DD049297.IP) has joined #recovery 2018-12-13 19:42:08 -- Mode #recovery [+o Musaeus-] by Morpheus 2018-12-13 19:42:22 << Musaeus (16@Musaeus.Moderator.orpheus.network) has quit (Ping timeout: 180 seconds) 2018-12-13 20:21:26 brett12345 Hello? 2018-12-13 20:22:21 brett12345 I wan't that ramen again 2018-12-13 20:27:06 brett12345 Wrong chat 2018-12-13 22:09:03 << borachio (quassel@5FF5C4E1.FFC7C26C.87E896A2.IP) has quit (Ping timeout: 180 seconds) 2018-12-13 22:49:41 >> noctis (620fc919@344C97A2.3F10BBFA.E64757BD.IP) has joined #recovery 2018-12-13 22:49:41 noctis Hello, I am having issues recovering 2018-12-13 22:51:32 noctis It is the same as my irc nickname 2018-12-13 23:01:46 noctis noctis 2018-12-13 23:02:11 noctis I also tried submitting my ptp info, didn't work 2018-12-13 23:30:17 << noctis (620fc919@344C97A2.3F10BBFA.E64757BD.IP) has quit (Quit: http://www.mibbit.com ajax IRC Client) 2018-12-14 00:11:17 brett12345 I also cant submit my ptp info 2018-12-14 01:01:10 >> Justaplant (1041@Justaplant.Moderator.orpheus.network) has joined #recovery 2018-12-14 01:01:11 -- Mode #recovery [+o Justaplant] by Morpheus 2018-12-14 01:01:35 @Justaplant anyone need help 2018-12-14 01:06:36 >> borachio (quassel@5FF5C4E1.FFC7C26C.87E896A2.IP) has joined #recovery 2018-12-14 01:06:36 borachio was having trouble with recovery... 2018-12-14 01:06:44 @Justaplant did you complete the form? 2018-12-14 01:06:52 borachio ya a long while ago 2018-12-14 01:07:08 borachio tried to submit again and just get an error now 2018-12-14 01:07:23 @Justaplant please pm me username and token 2018-12-14 01:27:31 << borachio (12060@borachio.User.orpheus.network) has left #recovery
IRC log
0
Brettm12345/dotfiles
weechat/logs/irc.orpheus.#recovery.weechatlog
[ "MIT" ]
- active = params[:tab] == 'health' = gl_tab_link_to clusterable.cluster_path(@cluster.id, params: { tab: 'health' }), { item_active: active, data: { testid: 'cluster-health-tab' } } do = _('Health')
Haml
4
nowkoai/test
app/views/clusters/clusters/_health_tab.html.haml
[ "MIT" ]
; -- 64BitThreeArch.iss -- ; Demonstrates how to install a program built for three different ; architectures (x86, x64, ARM64) using a single installer. ; SEE THE DOCUMENTATION FOR DETAILS ON CREATING .ISS SCRIPT FILES! [Setup] AppName=My Program AppVersion=1.5 WizardStyle=modern DefaultDirName={autopf}\My Program DefaultGroupName=My Program UninstallDisplayIcon={app}\MyProg.exe Compression=lzma2 SolidCompression=yes OutputDir=userdocs:Inno Setup Examples Output ; "ArchitecturesInstallIn64BitMode=x64 arm64" requests that the install ; be done in "64-bit mode" on x64 & ARM64, meaning it should use the ; native 64-bit Program Files directory and the 64-bit view of the ; registry. On all other architectures it will install in "32-bit mode". ArchitecturesInstallIn64BitMode=x64 arm64 [Files] ; Install MyProg-x64.exe if running on x64, MyProg-ARM64.exe if ; running on ARM64, MyProg.exe otherwise. ; Place all x64 files here Source: "MyProg-x64.exe"; DestDir: "{app}"; DestName: "MyProg.exe"; Check: InstallX64 ; Place all ARM64 files here, first one should be marked 'solidbreak' Source: "MyProg-ARM64.exe"; DestDir: "{app}"; DestName: "MyProg.exe"; Check: InstallARM64; Flags: solidbreak ; Place all x86 files here, first one should be marked 'solidbreak' Source: "MyProg.exe"; DestDir: "{app}"; Check: InstallOtherArch; Flags: solidbreak ; Place all common files here, first one should be marked 'solidbreak' Source: "MyProg.chm"; DestDir: "{app}"; Flags: solidbreak Source: "Readme.txt"; DestDir: "{app}"; Flags: isreadme [Icons] Name: "{group}\My Program"; Filename: "{app}\MyProg.exe" [Code] function InstallX64: Boolean; begin Result := Is64BitInstallMode and (ProcessorArchitecture = paX64); end; function InstallARM64: Boolean; begin Result := Is64BitInstallMode and (ProcessorArchitecture = paARM64); end; function InstallOtherArch: Boolean; begin Result := not InstallX64 and not InstallARM64; end;
Inno Setup
5
Patriccollu/issrc
Examples/64BitThreeArch.iss
[ "FSFAP" ]
"xyz" { }
JFlex
0
Mivik/jflex
javatests/jflex/testcase/include_in_rules/extra-jflex-rules.inc.jflex
[ "BSD-3-Clause" ]
_stack_size = 2K; SECTIONS { /* Second stage bootloader is prepended to the image. It must be 256 bytes and checksummed. The gap to the checksum is zero-padded. */ .boot2 : { __boot2_start__ = .; KEEP (*(.boot2)); /* Explicitly allocate space for CRC32 checksum at end of second stage bootloader */ . = __boot2_start__ + 256 - 4; LONG(0) } > BOOT2_TEXT = 0x0 /* The second stage will always enter the image at the start of .text. The debugger will use the ELF entry point, which is the _entry_point symbol if present, otherwise defaults to start of .text. This can be used to transfer control back to the bootrom on debugger launches only, to perform proper flash setup. */ } INCLUDE "targets/arm.ld"
Linker Script
4
attriaayush/tinygo
targets/rp2040.ld
[ "Apache-2.0" ]
.CodeMirror.cm-s-synthwave-84{font-family:Menlo,Consolas,'DejaVu Sans Mono',monospace;font-weight:350;font-size:18px;color:#b6b1b1;background-color:#2b213a}.cm-s-synthwave-84 .CodeMirror-selected{background-color:#1f172e!important}.cm-s-synthwave-84 .CodeMirror-gutter,.cm-s-synthwave-84 .CodeMirror-gutters{border:none;background-color:#011627}.cm-s-synthwave-84 .CodeMirror-linenumber,.cm-s-synthwave-84 .CodeMirror-linenumbers{color:#6d77b3!important;background-color:transparent}.cm-s-synthwave-84 .CodeMirror-lines{color:#b6b1b1!important;background-color:transparent}.cm-s-synthwave-84 .CodeMirror-cursor{border-left:2px solid #fa7b73!important}.cm-s-synthwave-84 .CodeMirror-matchingbracket,.cm-s-synthwave-84 .CodeMirror-matchingtag{border-bottom:2px solid #c792ea;color:#b6b1b1!important;background-color:transparent}.cm-s-synthwave-84 .CodeMirror-nonmatchingbracket{border-bottom:2px solid #fa7b73;color:#b6b1b1!important;background-color:transparent}.cm-s-synthwave-84 .CodeMirror-foldgutter,.cm-s-synthwave-84 .CodeMirror-foldgutter-folded,.cm-s-synthwave-84 .CodeMirror-foldgutter-open,.cm-s-synthwave-84 .CodeMirror-foldmarker{border:none;text-shadow:none;color:#5c6370!important;background-color:transparent}.cm-s-synthwave-84 .CodeMirror-activeline-background{background-color:#2b213a}.cm-s-synthwave-84 .cm-quote{color:#6d77b3;font-style:italic}.cm-s-synthwave-84 .cm-negative{color:#fff5f6;text-shadow:0 0 2px #000,0 0 10px #fc1f2c75,0 0 5px #fc1f2c75,0 0 25px #fc1f2c75}.cm-s-synthwave-84 .cm-positive{color:#fff5f6;text-shadow:0 0 2px #000,0 0 10px #fc1f2c75,0 0 5px #fc1f2c75,0 0 25px #fc1f2c75}.cm-s-synthwave-84 .cm-strong{color:#f97e72;font-weight:700}.cm-s-synthwave-84 .cm-em{color:#f4eee4;font-style:italic;text-shadow:0 0 2px #393a33,0 0 8px #f39f0575,0 0 2px #f39f0575}.cm-s-synthwave-84 .cm-attribute{color:#fff5f6;text-shadow:0 0 2px #000,0 0 10px #fc1f2c75,0 0 5px #fc1f2c75,0 0 25px #fc1f2c75}.cm-s-synthwave-84 .cm-link{color:#f97e72;border-bottom:solid 1px #f97e72}.cm-s-synthwave-84 .cm-keyword{color:#f4eee4;font-style:italic;text-shadow:0 0 2px #393a33,0 0 8px #f39f0575,0 0 2px #f39f0575}.cm-s-synthwave-84 .cm-def{color:#fdfdfd;text-shadow:0 0 2px #001716,0 0 3px #03edf975,0 0 5px #03edf975,0 0 8px #03edf975}.cm-s-synthwave-84 .cm-atom{color:#f97e72}.cm-s-synthwave-84 .cm-number{color:#f97e72}.cm-s-synthwave-84 .cm-property{color:#fdfdfd;text-shadow:0 0 2px #001716,0 0 3px #03edf975,0 0 5px #03edf975,0 0 8px #03edf975}.cm-s-synthwave-84 .cm-qualifier{color:#f97e72}.cm-s-synthwave-84 .cm-variable{color:#f92aad;text-shadow:0 0 2px #100c0f,0 0 5px #dc078e33,0 0 10px #fff3}.cm-s-synthwave-84 .cm-variable-2{color:#f92aad;text-shadow:0 0 2px #100c0f,0 0 5px #dc078e33,0 0 10px #fff3}.cm-s-synthwave-84 .cm-string{color:#ff8b39}.cm-s-synthwave-84 .cm-string-2{color:#ff8b39}.cm-s-synthwave-84 .cm-operator{color:#f4eee4;text-shadow:0 0 2px #393a33,0 0 8px #f39f0575,0 0 2px #f39f0575}.cm-s-synthwave-84 .cm-meta{color:#ff8b39}.cm-s-synthwave-84 .cm-comment{color:#6d77b3;font-style:italic}.cm-s-synthwave-84 .cm-error{color:#fff5f6;text-shadow:0 0 2px #000,0 0 10px #fc1f2c75,0 0 5px #fc1f2c75,0 0 25px #fc1f2c75}
CSS
3
mpepping/carbon
public/static/themes/synthwave-84.min.css
[ "MIT" ]
<template> <transition-group name="suggestion" class="suggestions"> <SuggestionBarItem v-for="(suggestion, index) of suggestions" :key="`${$i18n.locale}:${suggestion.id}`" :suggestion="suggestion" :index="suggestions.length - index - 1" ping /> </transition-group> </template> <script> export default { props: { suggestions: { type: Array, required: true } } } </script>
Vue
3
brizer/vue-cli
packages/@vue/cli-ui/src/components/suggestion/SuggestionBarList.vue
[ "MIT" ]
INSERT INTO `char` VALUES ( 0, 'ee72ae0a-ef35-4c5d-94ff-e82f696af30d'), ( 1, '2dad5648-0dbd-4a00-a1ae-d85a3fbc6c3d'), ( 2, 'a35b4b77-c453-49d7-9faa-41041efad77b'), ( 3, '950a780f-93b8-4010-9a97-a8c60304ef69'), ( 4, '73da4e0f-1171-4304-b781-c2339e5c3973'), ( 5, '0a3c47cc-54ea-4ce3-bb91-7006985bf31a'), ( 6, 'd03a918a-a545-4cfd-8400-cc37490505a9'), ( 7, '1d0f1587-4a93-418e-9b70-197594e5bc8b'), ( 8, 'd5019bd8-7219-4b86-8b5f-8d0ed4b0aed5'), ( 9, 'b292179c-df0c-4592-91dc-fb8b95afc3e8'), (10, '3f0f41aa-5468-468a-b90c-42eb02e909d2'), (11, 'a6175ce6-b6a7-4e63-a784-b1b4ab4a4c70'), (12, 'a7dae6d2-275e-4ffd-86dc-ba5c00e48fe5'), (13, 'b07b158d-4617-4c8a-9079-1667c5545cc4'), (14, '7f8e4fae-730a-4faf-86a1-a4e5b1447fab'), (15, '13364cf3-a517-4f7e-b78e-bd6177af0e93'), (16, '35a04489-3d1c-40f9-a241-4c23e5a5f5bd'), (17, '97197ef4-2804-4b84-a361-90a3384402aa'), (18, '59855557-2132-4849-8980-5b8fac90304b'), (19, 'f2e49556-fd86-4f68-a107-89eafb4009ca'), (20, 'ca63c5d0-1b69-4506-8fda-e901ed855698'), (21, '2e17ff04-fa37-4fd6-a6f9-2d09f4ef4a5f'), (22, '9d65d2fc-85d7-4c3a-88f8-cba092903980'), (23, '4b0d0e94-201a-45ac-89c4-10b4fefb8d95'), (24, 'a290faa6-ee52-4117-9702-a69961b46c3b'), (25, '61270388-bd74-4edf-9089-638806efe0a9'), (26, '6e54e72c-0878-4a88-991e-285c49945525'), (27, '308d6c26-7c3d-4b25-a68c-7a1435b1a4f6'), (28, '2944629d-7fef-4dc0-b447-2ef100718837'), (29, 'fde1328c-409c-43a8-b1b0-8c35c8000f92'), (30, 'ba4274c3-29e8-413c-be87-611e4570f999'), (31, '6bd41abb-12ea-4489-9c47-cfc4b43e1ed3'), (32, '123d7774-33c1-4dea-aead-ec5b5bae772c'), (33, '42e7ffe7-0e08-4e6f-a079-e9596d7f0b83'), (34, '115bc643-64f0-456e-8523-bd8286c39446'), (35, 'd9d02333-06bb-4e64-8820-ef426e089d8a'), (36, 'f48888bc-0d61-4963-907d-b98f3a7766b6'), (37, 'a913d4ba-cc4c-4c47-9fb9-271bede8015e'), (38, 'c567fa2b-4f8e-4f39-896d-52e59ea92e87'), (39, '4015636d-2bf5-4397-8c6b-32d145e7592c'), (40, '41832db1-8000-46be-a4f2-7f22b61bb5e7'), (41, '55dc0343-db6a-4208-9872-9096305b8c07'), (42, '22e65824-c67a-4ae1-b89d-997bc6ee29d4'), (43, '090abbb2-f22e-4f97-a4fe-a52eb1a80a0b'), (44, '90553b8a-e4c4-42e0-8fc3-f20320b1110b'), (45, '43626db9-4033-4c75-bc11-ea41099565cf'), (46, '747b4c36-6789-48a8-9217-63afbee2dd15'), (47, 'a5e015d1-3d76-447e-af8f-b834007481e9'), (48, 'b75264a7-e707-4df1-87a2-b9052ad4e36d'), (49, '45cd6508-9a06-4ab7-8140-6a84a109faef');
SQL
2
imtbkcat/tidb-lightning
tests/various_types/data/vt.char.sql
[ "Apache-2.0" ]
@echo off rem bz - Build the entire solution without cleaning it first. rem This is another script to help Microsoft developers feel at home working on rem the terminal project. call bcz no_clean %*
Batchfile
3
hessedoneen/terminal
tools/bz.cmd
[ "MIT" ]
/* Copyright © 2011 MLstate This file is part of Opa. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /* * Author : Nicolas Glondu <nicolas.glondu@mlstate.com> **/ /** * GitHub issue API module * * @category api * @author Nicolas Glondu, 2011 * @destination public */ package stdlib.apis.github.issue import stdlib.apis.github import stdlib.apis.github.lib /* Types returned by API */ type GitHub.issue_event = { url : string actor : GitHub.short_user event : string commit_id : string created_at : Date.date issue : option(GitHub.issue) } type GitHub.issue_params = { filter : {assigned} / {created} / {mentioned} / {subscribed} state : {open} / {closed} labels : list(string) sort : {created} / {updated} / {comments} direction : {asc} / {desc} since : option(Date.date) } type GitHub.valnonestar('a) = {val:'a} / {none} / {star} @private GHIp = {{ @private GP = GHParse get_event(srcmap) = m = GP.map_funs(srcmap) if m.exists("event") then res = { url = m.str("url") actor = GP.get_rec(m, "actor", GP.get_short_user) event = m.str("event") commit_id = m.str("commit_id") created_at = m.date("created_at") issue = GP.get_rec(m, "issue", GP.get_issue) } : GitHub.issue_event some(res) else none one_issue(res) = GP.dewrap_whole_obj(res, GP.get_issue) multiple_issues(res) = GP.dewrap_whole_list(res, GP.get_issue) one_issue_comment(res) = GP.dewrap_whole_obj(res, GP.get_issue_comment) multiple_comments(res) = GP.dewrap_whole_list(res, GP.get_issue_comment) one_event(res) = GP.dewrap_whole_obj(res, get_event) multiple_events(res) = GP.dewrap_whole_list(res, get_event) one_label(res) = GP.dewrap_whole_obj(res, GP.get_label) multiple_labels(res) = GP.dewrap_whole_list(res, GP.get_label) one_milestone(res) = GP.dewrap_whole_obj(res, GP.get_milestone) multiple_milestones(res) = GP.dewrap_whole_list(res, GP.get_milestone) labels(res) = GP.multiple_strings(res, "labels") }} type GitHub.issue_filter = {assigned} / {created} / {mentioned} / {subscribed} type GitHub.issue_sort = {created} / {updated} / {comments} type GitHub.issue_sort2 = {due_date} / {completeness} GHIssue = {{ @private GP = GHParse @private opt_valnonestar(name:string, vns:option(GitHub.valnonestar('a))) = match vns with | {some={~val}} -> [(name,"{val}")] | {some={none}} -> [(name,"none")] | {some={star}} -> [(name,"*")] | {none} -> [] @private opt_filter(filter) = match filter with | {some=filter} -> filter = match filter with | {assigned} -> "assigned" | {created} -> "created" | {mentioned} -> "mentioned" | {subscribed} -> "subscribed" end [("filter",filter)] | _ -> [] @private opt_labels(labels) = match labels with | [_|_] -> [("labels",String.concat(",",labels))] | _ -> [] @private opt_sort(sort) = match sort with | {some=sort} -> sort = match sort with | {created} -> "created" | {updated} -> "updated" | {comments} -> "comments" end [("sort",sort)] | _ -> [] @private opt_sort2(sort) = match sort with | {some=sort} -> sort = match sort with | {due_date} -> "due_date" | {completeness} -> "completeness" end [("sort",sort)] | _ -> [] @private opt_since(since) = match since with | {some=since} -> [("since",GHParse.date_to_string(since))] | _ -> [] @private opt_str(name:string, str:option(string)) = match str with | {some=str} -> [(name,str)] | {none} -> [] list_issues(token:string, filter:option(GitHub.issue_filter), state:option(GitHub.state), labels:list(string), sort:option(GitHub.issue_sort), direction:option(GitHub.direction), since:option(Date.date)) = options = List.flatten([opt_filter(filter),GHLib.opt_state(state),opt_labels(labels), opt_sort(sort),GHLib.opt_direction(direction),opt_since(since)]) GHLib.api_get_full("/issues", token, options, GHIp.multiple_issues) list_issues_repo(token:string, user:string, repo:string, milestone:option(GitHub.valnonestar(int)), state:option(GitHub.state), assignee:option(GitHub.valnonestar(string)), mentioned:option(string), labels:list(string), sort:option(GitHub.issue_sort), direction:option(GitHub.direction), since:option(Date.date)) = options = List.flatten([opt_valnonestar("milestone",milestone),GHLib.opt_state(state),opt_valnonestar("assignee",assignee), opt_str("mentioned",mentioned),opt_labels(labels),opt_sort(sort),GHLib.opt_direction(direction), opt_since(since)]) GHLib.api_get_full("/repos/{user}/{repo}/issues", token, options, GHIp.multiple_issues) get_issue(token:string, user:string, repo:string, number:int) = GHLib.api_get_full("/repos/{user}/{repo}/issues/{number}", token, [], GHIp.one_issue) create_issue(token:string, user:string, repo:string, title:string, body:option(string), assignee:option(string), milestone:option(int), labels:list(string)) = json = GHLib.mkopts([{sreq=("title",title)},{sopt=("body",body)},{sopt=("assignee",assignee)}, {iopt=("milestone",milestone)},{lst=("labels",labels)}]) GHLib.api_post_string("/repos/{user}/{repo}/issues", token, json, GHIp.one_issue) edit_issue(token:string, user:string, repo:string, title:option(string), body:option(string), assignee:option(string), state:option(GitHub.state), milestone:option(int), labels:list(string)) = json = GHLib.mkopts([{sopt=("title",title)},{sopt=("body",body)},{sopt=("assignee",assignee)}, {ocst=("state",GHLib.string_of_state,state)},{iopt=("milestone",milestone)},{lst=("labels",labels)}]) GHLib.api_patch_string("/repos/{user}/{repo}/issues", token, json, GHIp.one_issue) list_assignees(token:string, user:string, repo:string) = GHLib.api_get_full("/repos/{user}/{repo}/assignees", token, [], GP.multiple_short_users) check_assignee(token:string, user:string, repo:string, assignee:string) = GHLib.api_get_full("/repos/{user}/{repo}/assignees/{assignee}", token, [], GP.expect_204_404) list_comments(token:string, user:string, repo:string, number:int) = GHLib.api_get_full("/repos/{user}/{repo}/issues/{number}/comments", token, [], GHIp.multiple_comments) get_comment(token:string, user:string, repo:string, id:int) = GHLib.api_get_full("/repos/{user}/{repo}/issues/comments/{id}", token, [], GHIp.one_issue_comment) create_comment(token:string, user:string, repo:string, number:int, body:string) = json = GHLib.mkopts([{sreq=("body",body)}]) GHLib.api_post_string("/repos/{user}/{repo}/issues/{number}/comments", token, json, GHIp.one_issue_comment) edit_comment(token:string, user:string, repo:string, body:string, id:int) = json = GHLib.mkopts([{sreq=("body",body)}]) GHLib.api_post_string("/repos/{user}/{repo}/issues/comments/{id}", token, json, GHIp.one_issue_comment) delete_comment(token:string, user:string, repo:string, id:int) = GHLib.api_delete_string("/repos/{user}/{repo}/issues/comments/{id}", token, "", GP.expect_204) list_issue_events(token:string, user:string, repo:string, issue_number:int) = GHLib.api_get_full("/repos/{user}/{repo}/issues/{issue_number}/events", token, [], GHIp.multiple_events) list_repo_events(token:string, user:string, repo:string) = GHLib.api_get_full("/repos/{user}/{repo}/issues/events", token, [], GHIp.multiple_events) get_event(token:string, user:string, repo:string, id:int) = GHLib.api_get_full("/repos/{user}/{repo}/issues/events/{id}", token, [], GHIp.one_event) list_labels(token:string, user:string, repo:string) = GHLib.api_get_full("/repos/{user}/{repo}/labels", token, [], GHIp.multiple_labels) get_label(token:string, user:string, repo:string, name:string) = GHLib.api_get_full("/repos/{user}/{repo}/labels/{name}", token, [], GHIp.one_label) create_label(token:string, user:string, repo:string, name:string, color:string) = json = GHLib.mkopts([{sreq=("name",name)},{sreq=("color",color)}]) GHLib.api_post_string("/repos/{user}/{repo}/labels", token, json, GHIp.one_label) update_label(token:string, user:string, repo:string, name:string, color:string) = json = GHLib.mkopts([{sreq=("name",name)},{sreq=("color",color)}]) GHLib.api_patch_string("/repos/{user}/{repo}/labels/{name}", token, json, GHIp.one_label) delete_label(token:string, user:string, repo:string, name:string) = GHLib.api_delete_string("/repos/{user}/{repo}/labels/{name}", token, "", GP.expect_204) list_issue_labels(token:string, user:string, repo:string, number:int) = GHLib.api_get_full("/repos/{user}/{repo}/issues/{number}/labels", token, [], GHIp.multiple_labels) add_issue_labels(token:string, user:string, repo:string, number:int, labels:list(string)) = json = GHLib.mkslst(labels) GHLib.api_post_string("/repos/{user}/{repo}/issues/{number}/labels", token, json, GHIp.multiple_labels) remove_issue_label(token:string, user:string, repo:string, number:int, name:string) = GHLib.api_delete_string("/repos/{user}/{repo}/issues/{number}/labels/{name}", token, "", GHIp.multiple_labels) replace_issue_labels(token:string, user:string, repo:string, number:int, labels:list(string)) = json = GHLib.mkslst(labels) GHLib.api_put_string("/repos/{user}/{repo}/issues/{number}/labels", token, json, GHIp.multiple_labels) remove_all_issue_labels(token:string, user:string, repo:string, number:int) = GHLib.api_delete_string("/repos/{user}/{repo}/issues/{number}/labels", token, "", GP.expect_204) get_milestone_issue_labels(token:string, user:string, repo:string, number:int) = GHLib.api_get_full("/repos/{user}/{repo}/milestones/{number}/labels", token, [], GHIp.multiple_labels) list_milestones(token:string, user:string, repo:string, state:option(GitHub.state), sort:option(GitHub.issue_sort2), direction:option(GitHub.direction)) = options = List.flatten([GHLib.opt_state(state),opt_sort2(sort),GHLib.opt_direction(direction)]) GHLib.api_get_full("/repos/{user}/{repo}/milestones", token, options, GHIp.multiple_issues) get_milestone(token:string, user:string, repo:string, number:int) = GHLib.api_get_full("/repos/{user}/{repo}/milestones/{number}", token, [], GHIp.one_milestone) create_milestone(token:string, user:string, repo:string, title:string, state:option(GitHub.state), description:option(string), due_on:option(Date.date)) = json = GHLib.mkopts([{sreq=("title",title)},{ocst=("state",GHLib.string_of_state,state)}, {sopt=("description",description)},{sopt=("due_on",Option.map(GHParse.date_to_string,due_on))}]) GHLib.api_post_string("/repos/{user}/{repo}/milestones", token, json, GHIp.one_milestone) update_milestone(token:string, user:string, repo:string, number:int, title:option(string), state:option(GitHub.state), description:option(string), due_on:option(Date.date)) = json = GHLib.mkopts([{sopt=("title",title)},{ocst=("state",GHLib.string_of_state,state)}, {sopt=("description",description)},{sopt=("due_on",Option.map(GHParse.date_to_string,due_on))}]) GHLib.api_patch_string("/repos/{user}/{repo}/milestones/{number}", token, json, GHIp.one_milestone) delete_milestone(token:string, user:string, repo:string, number:int) = GHLib.api_delete_string("/repos/{user}/{repo}/milestones/{number}", token, "", GP.expect_204) }}
Opa
5
Machiaweliczny/oppailang
lib/stdlib/apis/github/issue/issue.opa
[ "MIT" ]
<#ftl output_format="plainText"> ${msg("eventUpdateTotpBody",event.date, event.ipAddress)}
FreeMarker
2
rmartinc/keycloak
themes/src/main/resources/theme/base/email/text/event-update_totp.ftl
[ "Apache-2.0" ]
#200 manaspring~ 1 0 o 167 -1 A 7 2 A 16 1 R 1206 5 # 5x an iridescent blue iris S #201 healing~ 1 0 o 167 -1 A 23 2 A 7 1 R 1300 5 # 5x a glowing green seashell S #202 fury~ 1 0 o 167 -1 A 22 2 A 7 1 R 103 5 # 5x a yellow lightning stone S #203 venom~ 1 0 o 167 -1 A 21 2 A 6 1 R 104 5 # 5x a red bloodstone S $
Augeas
1
EmpireMUD/EmpireMUD-2.0-Beta
lib/world/aug/2.aug
[ "DOC", "Unlicense" ]
dcl_settings : default_dcl_settings { audit_level = 3; } STYLES : dialog { label = "General Settings" ; : row { : boxed_column { label = "Annotations" ; : edit_box { edit_width = 15 ; key = "ala" ; label = "Area layer:" ; } : edit_box { edit_width = 15 ; key = "ats" ; label = "Area text size:" ; } : edit_box { edit_width = 15 ; key = "atsty" ; label = "Area text style:" ; } : edit_box { edit_width = 15 ; key = "lts" ; label = "Line text size:" ; } : edit_box { edit_width = 15 ; key = "ltsty" ; label = "Line text style:" ; } : edit_box { edit_width = 15 ; key = "tol" ; label = "Line layer:" ; } : edit_box { edit_width = 15 ; key = "lots" ; label = "Lot text size:" ; } : edit_box { edit_width = 15 ; key = "lotstyle" ; label = "Lot text style:" ; } : edit_box { edit_width = 15 ; key = "lol" ; label = "Lot layer:" ; } } : boxed_column { label = "Drafting" ; : edit_box { edit_width = 15 ; key = "curbla" ; label = "Curb layer" ; } : edit_box { edit_width = 15 ; key = "offla" ; label = "Offset layer" ; } spacer ; spacer ; spacer ; spacer ; } } ok_cancel ; }
Clean
4
geetarista/autocad-routines
styles.dcl
[ "MIT" ]
#tag Class Protected Class Win32MutexWFS #tag Method, Flags = &h1 Protected Sub Close() #if TargetWin32 Declare Sub CloseHandle Lib "Kernel32" ( handle as Integer ) if mHandle <> 0 then CloseHandle( mHandle ) end #endif mHandle = 0 End Sub #tag EndMethod #tag Method, Flags = &h0 Sub Constructor(name as String, globalMutex as Boolean = false) mHandle = 0 mName = name mGlobal = globalMutex End Sub #tag EndMethod #tag Method, Flags = &h0 Sub Destructor() Release Close End Sub #tag EndMethod #tag Method, Flags = &h0 Function Handle() As Integer return mHandle End Function #tag EndMethod #tag Method, Flags = &h0 Function Obtain() As Boolean #if TargetWin32 Soft Declare Function CreateMutexA Lib "Kernel32" ( security as Integer, _ owner as Boolean, name as CString ) as Integer Soft Declare Function CreateMutexW Lib "Kernel32" ( security as Integer, _ owner as Boolean, name as WString ) as Integer dim useName as String if mGlobal then useName = "Global\" + mName else useName = mName end if System.IsFunctionAvailable( "CreateMutexW", "Kernel32" ) then mHandle = CreateMutexW( 0, true, useName ) else mHandle = CreateMutexA( 0, true, useName ) end if const ERROR_ALREADY_EXISTS = 183 dim error as Integer if mHandle = 0 then return false else error = Win32DeclareLibraryWFS.GetLastError if error = ERROR_ALREADY_EXISTS then return false end return true end #endif End Function #tag EndMethod #tag Method, Flags = &h0 Sub Release() if mHandle = 0 then return #if TargetWin32 Declare Sub ReleaseMutex Lib "Kernel32" ( handle as Integer ) ReleaseMutex( mHandle ) #endif End Sub #tag EndMethod #tag Property, Flags = &h1 Protected mGlobal As Boolean #tag EndProperty #tag Property, Flags = &h1 Protected mHandle As Integer #tag EndProperty #tag Property, Flags = &h1 Protected mName As String #tag EndProperty #tag ViewBehavior #tag ViewProperty Name="Index" Visible=true Group="ID" InitialValue="-2147483648" InheritedFrom="Object" #tag EndViewProperty #tag ViewProperty Name="Left" Visible=true Group="Position" InitialValue="0" InheritedFrom="Object" #tag EndViewProperty #tag ViewProperty Name="Name" Visible=true Group="ID" InheritedFrom="Object" #tag EndViewProperty #tag ViewProperty Name="Super" Visible=true Group="ID" InheritedFrom="Object" #tag EndViewProperty #tag ViewProperty Name="Top" Visible=true Group="Position" InitialValue="0" InheritedFrom="Object" #tag EndViewProperty #tag EndViewBehavior End Class #tag EndClass
REALbasic
3
bskrtich/WFS
Windows Functionality Suite/Miscellaneous/Classes/Win32MutexWFS.rbbas
[ "MIT" ]
// SKIP_IN_RUNTIME_TEST because there's no stable way to determine if a field is initialized with a non-null value in runtime package test; public class StaticFinal { public static final String publicNonNull = "aaa"; public static final String publicNull = null; static final String packageNonNull = "bbb"; static final String packageNull = null; private static final String privateNonNull = "bbb"; private static final String privateNull = null; }
Java
3
qussarah/declare
compiler/testData/loadJava/compiledJava/static/StaticFinal.java
[ "Apache-2.0" ]
--TEST-- Bug #67072 Echoing unserialized "SplFileObject" crash --FILE-- <?php echo unserialize('O:13:"SplFileObject":1:{s:9:"*filename";s:15:"/home/flag/flag";}'); ?> ===DONE== --EXPECTF-- Fatal error: Uncaught Exception: Unserialization of 'SplFileObject' is not allowed in %s:%d Stack trace: #0 %s(%d): unserialize('O:13:"SplFileOb...') #1 {main} thrown in %s on line %d
PHP
3
NathanFreeman/php-src
ext/standard/tests/serialize/bug67072.phpt
[ "PHP-3.01" ]
{ module MixedStatefulStateless where import Komeji.Satori import Komeji.Koishi } tokens :- @reimu { simple ReimuToken } <state> { @alice { simple AliceToken } } { Stop the time! }
Logos
2
safarmer/intellij-haskell
src/test/testData/parsing/MixedStatefulStateless.x
[ "Apache-2.0" ]
$blue: #056ef0; $column: 200px; .menu { width: $column; } .menu_link { background: $blue; width: $column; }
Opal
4
jstransformers/jstransformer-opalcss
test/input.opal
[ "MIT" ]
@article{cattell2011scalable, title={Scalable SQL and NoSQL data stores}, author={Cattell, Rick}, journal={ACM SIGMOD Record}, volume={39}, number={4}, pages={12--27}, year={2011}, publisher={ACM} } @article{chang2008bigtable, title={Bigtable: A distributed storage system for structured data}, author={Chang, Fay and Dean, Jeffrey and Ghemawat, Sanjay and Hsieh, Wilson C and Wallach, Deborah A and Burrows, Mike and Chandra, Tushar and Fikes, Andrew and Gruber, Robert E}, journal={ACM Transactions on Computer Systems (TOCS)}, volume={26}, number={2}, pages={4}, year={2008}, publisher={ACM} } @inproceedings{decandia2007dynamo, title={Dynamo: amazon's highly available key-value store}, author={DeCandia, Giuseppe and Hastorun, Deniz and Jampani, Madan and Kakulapati, Gunavardhan and Lakshman, Avinash and Pilchin, Alex and Sivasubramanian, Swaminathan and Vosshall, Peter and Vogels, Werner}, booktitle={ACM SIGOPS Operating Systems Review}, volume={41}, number={6}, pages={205--220}, year={2007}, organization={ACM} } @inproceedings{abadi2008column, title={Column-Stores vs. Row-Stores: How different are they really?}, author={Abadi, Daniel J and Madden, Samuel R and Hachem, Nabil}, booktitle={Proceedings of the 2008 ACM SIGMOD international conference on Management of data}, pages={967--980}, year={2008}, organization={ACM} } @inproceedings{bear2012vertica, title={The vertica database: SQL RDBMS for managing big data}, author={Bear, Chuck and Lamb, Andrew and Tran, Nga}, booktitle={Proceedings of the 2012 workshop on Management of big data systems}, pages={37--38}, year={2012}, organization={ACM} } @article{lakshman2010cassandra, title={Cassandra—A decentralized structured storage system}, author={Lakshman, Avinash and Malik, Prashant}, journal={Operating systems review}, volume={44}, number={2}, pages={35}, year={2010} } @article{melnik2010dremel, title={Dremel: interactive analysis of web-scale datasets}, author={Melnik, Sergey and Gubarev, Andrey and Long, Jing Jing and Romer, Geoffrey and Shivakumar, Shiva and Tolton, Matt and Vassilakis, Theo}, journal={Proceedings of the VLDB Endowment}, volume={3}, number={1-2}, pages={330--339}, year={2010}, publisher={VLDB Endowment} } @article{hall2012processing, title={Processing a trillion cells per mouse click}, author={Hall, Alexander and Bachmann, Olaf and B{\"u}ssow, Robert and G{\u{a}}nceanu, Silviu and Nunkesser, Marc}, journal={Proceedings of the VLDB Endowment}, volume={5}, number={11}, pages={1436--1446}, year={2012}, publisher={VLDB Endowment} } @inproceedings{shvachko2010hadoop, title={The hadoop distributed file system}, author={Shvachko, Konstantin and Kuang, Hairong and Radia, Sanjay and Chansler, Robert}, booktitle={Mass Storage Systems and Technologies (MSST), 2010 IEEE 26th Symposium on}, pages={1--10}, year={2010}, organization={IEEE} } @article{colantonio2010concise, title={Concise: Compressed ‘n’Composable Integer Set}, author={Colantonio, Alessandro and Di Pietro, Roberto}, journal={Information Processing Letters}, volume={110}, number={16}, pages={644--650}, year={2010}, publisher={Elsevier} } @inproceedings{stonebraker2005c, title={C-store: a column-oriented DBMS}, author={Stonebraker, Mike and Abadi, Daniel J and Batkin, Adam and Chen, Xuedong and Cherniack, Mitch and Ferreira, Miguel and Lau, Edmond and Lin, Amerson and Madden, Sam and O'Neil, Elizabeth and others}, booktitle={Proceedings of the 31st international conference on Very large data bases}, pages={553--564}, year={2005}, organization={VLDB Endowment} } @inproceedings{engle2012shark, title={Shark: fast data analysis using coarse-grained distributed memory}, author={Engle, Cliff and Lupher, Antonio and Xin, Reynold and Zaharia, Matei and Franklin, Michael J and Shenker, Scott and Stoica, Ion}, booktitle={Proceedings of the 2012 international conference on Management of Data}, pages={689--692}, year={2012}, organization={ACM} } @inproceedings{zaharia2012discretized, title={Discretized streams: an efficient and fault-tolerant model for stream processing on large clusters}, author={Zaharia, Matei and Das, Tathagata and Li, Haoyuan and Shenker, Scott and Stoica, Ion}, booktitle={Proceedings of the 4th USENIX conference on Hot Topics in Cloud Computing}, pages={10--10}, year={2012}, organization={USENIX Association} } @misc{marz2013storm, author = {Marz, Nathan}, title = {Storm: Distributed and Fault-Tolerant Realtime Computation}, month = {February}, year = {2013}, howpublished = "\url{http://storm-project.net/}" } @misc{tschetter2011druid, author = {Eric Tschetter}, title = {Introducing Druid: Real-Time Analytics at a Billion Rows Per Second}, month = {April}, year = {2011}, howpublished = "\url{http://druid.io/blog/2011/04/30/introducing-druid.html}" } @article{farber2012sap, title={SAP HANA database: data management for modern business applications}, author={F{\"a}rber, Franz and Cha, Sang Kyun and Primsch, J{\"u}rgen and Bornh{\"o}vd, Christof and Sigg, Stefan and Lehner, Wolfgang}, journal={ACM Sigmod Record}, volume={40}, number={4}, pages={45--51}, year={2012}, publisher={ACM} } @misc{voltdb2010voltdb, title={VoltDB Technical Overview}, author={VoltDB, LLC}, year={2010}, howpublished = "\url{https://voltdb.com/}" } @inproceedings{macnicol2004sybase, title={Sybase IQ multiplex-designed for analytics}, author={MacNicol, Roger and French, Blaine}, booktitle={Proceedings of the Thirtieth international conference on Very large data bases-Volume 30}, pages={1227--1230}, year={2004}, organization={VLDB Endowment} } @inproceedings{singh2011introduction, title={Introduction to the IBM Netezza warehouse appliance}, author={Singh, Malcolm and Leonhardi, Ben}, booktitle={Proceedings of the 2011 Conference of the Center for Advanced Studies on Collaborative Research}, pages={385--386}, year={2011}, organization={IBM Corp.} } @inproceedings{miner2012unified, title={Unified analytics platform for big data}, author={Miner, Donald}, booktitle={Proceedings of the WICSA/ECSA 2012 Companion Volume}, pages={176--176}, year={2012}, organization={ACM} } @inproceedings{fink2012distributed, title={Distributed computation on dynamo-style distributed storage: riak pipe}, author={Fink, Bryan}, booktitle={Proceedings of the eleventh ACM SIGPLAN workshop on Erlang workshop}, pages={43--50}, year={2012}, organization={ACM} } @misc{paraccel2013, key = {ParAccel Analytic Database}, title = {ParAccel Analytic Database}, month = {March}, year = {2013}, howpublished = "\url{http://www.paraccel.com/resources/Datasheets/ParAccel-Core-Analytic-Database.pdf}" } @misc{cloudera2013, key = {Cloudera Impala}, title = {Cloudera Impala}, month = {March}, year = {2013}, url = {}, howpublished = "\url{http://blog.cloudera.com/blog}" } @inproceedings{hunt2010zookeeper, title={ZooKeeper: Wait-free coordination for Internet-scale systems}, author={Hunt, Patrick and Konar, Mahadev and Junqueira, Flavio P and Reed, Benjamin}, booktitle={USENIX ATC}, volume={10}, year={2010} } @inproceedings{kreps2011kafka, title={Kafka: A distributed messaging system for log processing}, author={Kreps, Jay and Narkhede, Neha and Rao, Jun}, booktitle={Proceedings of 6th International Workshop on Networking Meets Databases (NetDB), Athens, Greece}, year={2011} } @misc{liblzf2013, title = {LibLZF}, key = {LibLZF}, month = {March}, year = {2013}, howpublished = "\url{http://freecode.com/projects/liblzf}" } @inproceedings{tomasic1993performance, title={Performance of inverted indices in shared-nothing distributed text document information retrieval systems}, author={Tomasic, Anthony and Garcia-Molina, Hector}, booktitle={Parallel and Distributed Information Systems, 1993., Proceedings of the Second International Conference on}, pages={8--17}, year={1993}, organization={IEEE} } @inproceedings{antoshenkov1995byte, title={Byte-aligned bitmap compression}, author={Antoshenkov, Gennady}, booktitle={Data Compression Conference, 1995. DCC'95. Proceedings}, pages={476}, year={1995}, organization={IEEE} } @inproceedings{van2011memory, title={A memory efficient reachability data structure through bit vector compression}, author={van Schaik, Sebastiaan J and de Moor, Oege}, booktitle={Proceedings of the 2011 international conference on Management of data}, pages={913--924}, year={2011}, organization={ACM} } @inproceedings{o1993lru, title={The LRU-K page replacement algorithm for database disk buffering}, author={O'neil, Elizabeth J and O'neil, Patrick E and Weikum, Gerhard}, booktitle={ACM SIGMOD Record}, volume={22}, number={2}, pages={297--306}, year={1993}, organization={ACM} } @article{kim2001lrfu, title={LRFU: A spectrum of policies that subsumes the least recently used and least frequently used policies}, author={Kim, Chong Sang}, journal={IEEE Transactions on Computers}, volume={50}, number={12}, year={2001} } @article{wu2006optimizing, title={Optimizing bitmap indices with efficient compression}, author={Wu, Kesheng and Otoo, Ekow J and Shoshani, Arie}, journal={ACM Transactions on Database Systems (TODS)}, volume={31}, number={1}, pages={1--38}, year={2006}, publisher={ACM} } @misc{twitter2013, key = {Twitter Public Streams}, title = {Twitter Public Streams}, month = {March}, year = {2013}, howpublished = "\url{https://dev.twitter.com/docs/streaming-apis/streams/public}" } @article{fitzpatrick2004distributed, title={Distributed caching with memcached}, author={Fitzpatrick, Brad}, journal={Linux journal}, number={124}, pages={72--74}, year={2004} } @inproceedings{amdahl1967validity, title={Validity of the single processor approach to achieving large scale computing capabilities}, author={Amdahl, Gene M}, booktitle={Proceedings of the April 18-20, 1967, spring joint computer conference}, pages={483--485}, year={1967}, organization={ACM} } @book{sarawagi1998discovery, title={Discovery-driven exploration of OLAP data cubes}, author={Sarawagi, Sunita and Agrawal, Rakesh and Megiddo, Nimrod}, year={1998}, publisher={Springer} } @article{hu2011stream, title={Stream Database Survey}, author={Hu, Bo}, year={2011} } @article{dean2008mapreduce, title={MapReduce: simplified data processing on large clusters}, author={Dean, Jeffrey and Ghemawat, Sanjay}, journal={Communications of the ACM}, volume={51}, number={1}, pages={107--113}, year={2008}, publisher={ACM} } @misc{linkedin2013senseidb, author = {LinkedIn}, title = {SenseiDB}, month = {July}, year = {2013}, howpublished = "\url{http://www.senseidb.com/}" } @misc{apache2013solr, author = {Apache}, title = {Apache Solr}, month = {February}, year = {2013}, howpublished = "\url{http://lucene.apache.org/solr/}" } @misc{banon2013elasticsearch, author = {Banon, Shay}, title = {ElasticSearch}, month = {July}, year = {2013}, howpublished = "\url{http://www.elasticseach.com/}" } @book{oehler2012ibm, title={IBM Cognos TM1: The Official Guide}, author={Oehler, Karsten and Gruenes, Jochen and Ilacqua, Christopher and Perez, Manuel}, year={2012}, publisher={McGraw-Hill} } @book{schrader2009oracle, title={Oracle Essbase \& Oracle OLAP}, author={Schrader, Michael and Vlamis, Dan and Nader, Mike and Claterbos, Chris and Collins, Dave and Campbell, Mitch and Conrad, Floyd}, year={2009}, publisher={McGraw-Hill, Inc.} } @book{lachev2005applied, title={Applied Microsoft Analysis Services 2005: And Microsoft Business Intelligence Platform}, author={Lachev, Teo}, year={2005}, publisher={Prologika Press} } @article{o1996log, title={The log-structured merge-tree (LSM-tree)}, author={O’Neil, Patrick and Cheng, Edward and Gawlick, Dieter and O’Neil, Elizabeth}, journal={Acta Informatica}, volume={33}, number={4}, pages={351--385}, year={1996}, publisher={Springer} } @inproceedings{o1997improved, title={Improved query performance with variant indexes}, author={O'Neil, Patrick and Quass, Dallan}, booktitle={ACM Sigmod Record}, volume={26}, number={2}, pages={38--49}, year={1997}, organization={ACM} } @inproceedings{cipar2012lazybase, title={LazyBase: trading freshness for performance in a scalable database}, author={Cipar, James and Ganger, Greg and Keeton, Kimberly and Morrey III, Charles B and Soules, Craig AN and Veitch, Alistair}, booktitle={Proceedings of the 7th ACM european conference on Computer Systems}, pages={169--182}, year={2012}, organization={ACM} }
TeX
2
RomaKoks/druid
publications/whitepaper/druid.bib
[ "Apache-2.0" ]
NB. input data X =: 4 3 $ 0 0 1 0 1 1 1 0 1 1 1 1 NB. target data Y =: 4 1 $ 0 0 1 1 NB. init weights w =: 3 1 $ 0.5069797399 0.5703818579 0.9265880619 e =: 2.718281828459045 iter =: ^: dot =: +/ . * T =: |: output =: verb define 1 % 1 + e ^ 0 - X dot y ) train =: verb define l1 =: output y l1_err =: Y - l1 l1_delta =: l1_err * l1 * 1 - l1 y + (T X) dot l1_delta ) w =: (train iter 1000) w l1 =: output w l1
J
4
ghosthamlet/ann.apl
ann.ijs
[ "MIT" ]
set(OpenCV_HAL_FOUND @OpenCV_HAL_FOUND@) set(OpenCV_HAL_VERSION @OpenCV_HAL_VERSION@) set(OpenCV_HAL_LIBRARIES @OpenCV_HAL_LIBRARIES@) set(OpenCV_HAL_HEADERS @OpenCV_HAL_HEADERS@) set(OpenCV_HAL_INCLUDE_DIRS @OpenCV_HAL_INCLUDE_DIRS@)
CMake
2
thisisgopalmandal/opencv
samples/hal/slow_hal/config.cmake
[ "BSD-3-Clause" ]
#! /usr/bin/env perl # Copyright 2004-2016 The OpenSSL Project Authors. All Rights Reserved. # # Licensed under the Apache License 2.0 (the "License"). You may not use # this file except in compliance with the License. You can obtain a copy # in the file LICENSE in the source distribution or at # https://www.openssl.org/source/license.html use strict; use warnings; my @directory_vars = ( "dir", "certs", "crl_dir", "new_certs_dir" ); my @file_vars = ( "database", "certificate", "serial", "crlnumber", "crl", "private_key", "RANDFILE" ); while(<STDIN>) { s|\R$||; foreach my $d (@directory_vars) { if (/^(\s*\#?\s*${d}\s*=\s*)\.\/([^\s\#]*)([\s\#].*)$/) { $_ = "$1sys\\\$disk:\[.$2$3"; } elsif (/^(\s*\#?\s*${d}\s*=\s*)(\w[^\s\#]*)([\s\#].*)$/) { $_ = "$1sys\\\$disk:\[.$2$3"; } s/^(\s*\#?\s*${d}\s*=\s*\$\w+)\/([^\s\#]*)([\s\#].*)$/$1.$2\]$3/; while(/^(\s*\#?\s*${d}\s*=\s*(\$\w+\.|sys\\\$disk:\[\.)[\w\.]+)\/([^\]]*)\](.*)$/) { $_ = "$1.$3]$4"; } } foreach my $f (@file_vars) { s/^(\s*\#?\s*${f}\s*=\s*)\.\/(.*)$/$1sys\\\$disk:\[\/$2/; while(/^(\s*\#?\s*${f}\s*=\s*(\$\w+|sys\\\$disk:\[)[^\/]*)\/(\w+\/[^\s\#]*)([\s\#].*)$/) { $_ = "$1.$3$4"; } if (/^(\s*\#?\s*${f}\s*=\s*(\$\w+|sys\\\$disk:\[)[^\/]*)\/(\w+)([\s\#].*)$/) { $_ = "$1]$3.$4"; } elsif (/^(\s*\#?\s*${f}\s*=\s*(\$\w+|sys\\\$disk:\[)[^\/]*)\/([^\s\#]*)([\s\#].*)$/) { $_ = "$1]$3$4"; } } print $_,"\n"; }
Perl
3
pmesnier/openssl
VMS/VMSify-conf.pl
[ "Apache-2.0" ]
from .common cimport BITSET_INNER_DTYPE_C from .common cimport BITSET_DTYPE_C from .common cimport X_DTYPE_C from .common cimport X_BINNED_DTYPE_C # A bitset is a data structure used to represent sets of integers in [0, n]. We # use them to represent sets of features indices (e.g. features that go to the # left child, or features that are categorical). For familiarity with bitsets # and bitwise operations: # https://en.wikipedia.org/wiki/Bit_array # https://en.wikipedia.org/wiki/Bitwise_operation cdef inline void init_bitset(BITSET_DTYPE_C bitset) nogil: # OUT cdef: unsigned int i for i in range(8): bitset[i] = 0 cdef inline void set_bitset(BITSET_DTYPE_C bitset, # OUT X_BINNED_DTYPE_C val) nogil: bitset[val // 32] |= (1 << (val % 32)) cdef inline unsigned char in_bitset(BITSET_DTYPE_C bitset, X_BINNED_DTYPE_C val) nogil: return (bitset[val // 32] >> (val % 32)) & 1 cpdef inline unsigned char in_bitset_memoryview(const BITSET_INNER_DTYPE_C[:] bitset, X_BINNED_DTYPE_C val) nogil: return (bitset[val // 32] >> (val % 32)) & 1 cdef inline unsigned char in_bitset_2d_memoryview(const BITSET_INNER_DTYPE_C [:, :] bitset, X_BINNED_DTYPE_C val, unsigned int row) nogil: # Same as above but works on 2d memory views to avoid the creation of 1d # memory views. See https://github.com/scikit-learn/scikit-learn/issues/17299 return (bitset[row, val // 32] >> (val % 32)) & 1 cpdef inline void set_bitset_memoryview(BITSET_INNER_DTYPE_C[:] bitset, # OUT X_BINNED_DTYPE_C val): bitset[val // 32] |= (1 << (val % 32)) def set_raw_bitset_from_binned_bitset(BITSET_INNER_DTYPE_C[:] raw_bitset, # OUT BITSET_INNER_DTYPE_C[:] binned_bitset, X_DTYPE_C[:] categories): """Set the raw_bitset from the values of the binned bitset categories is a mapping from binned category value to raw category value. """ cdef: int binned_cat_value X_DTYPE_C raw_cat_value for binned_cat_value, raw_cat_value in enumerate(categories): if in_bitset_memoryview(binned_bitset, binned_cat_value): set_bitset_memoryview(raw_bitset, <X_BINNED_DTYPE_C>raw_cat_value)
Cython
4
MaiRajborirug/scikit-learn
sklearn/ensemble/_hist_gradient_boosting/_bitset.pyx
[ "BSD-3-Clause" ]
// SPDX-License-Identifier: UNLICENSED pragma solidity >=0.4.0; contract Square { function square(uint32 num) public pure returns (uint32) { return num * num; } }
Solidity
4
OfekShilon/compiler-explorer
examples/solidity/default.sol
[ "BSD-2-Clause" ]
<CsoundSynthesizer> <CsOptions> ;-odac:hw:0,0 -odac -B 2048 -b 128 ;-o wave.wav ;-+rtaudio=alsa </CsOptions> <CsInstruments> 0dbfs = 1.0 sr = 48000 ksmps = 64 nchnls = 2 instr 1 a0 = 0 a1 vco2 0.8, 200 outs a0, a1 endin </CsInstruments> <CsScore> i1 0 10 </CsScore> </CsoundSynthesizer>
Csound
4
DaveSeidel/QB_Nebulae_V2
Code/tests/test.csd
[ "MIT" ]
# Target DNS server dns_rfc2136_server = {server_address} # Target DNS port dns_rfc2136_port = {server_port} # TSIG key name dns_rfc2136_name = default-key. # TSIG key secret dns_rfc2136_secret = 91CgOwzihr0nAVEHKFXJPQCbuBBbBI19Ks5VAweUXgbF40NWTD83naeg3c5y2MPdEiFRXnRLJxL6M+AfHCGLNw== # TSIG key algorithm dns_rfc2136_algorithm = HMAC-SHA512
Smarty
2
4n3i5v74/certbot
certbot-ci/certbot_integration_tests/assets/bind-config/rfc2136-credentials-default.ini.tpl
[ "Apache-2.0" ]
/* BSD License Copyright (c) 2013, Kazunori Sakamoto Copyright (c) 2016, Alexander Alexeev (c) 2020, Steven Johnstone 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 conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. 3. Neither the NAME of Rainer Schuster nor the NAMEs of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. This grammar file derived from: Lua 5.3 Reference Manual http://www.lua.org/manual/5.3/manual.html Lua 5.2 Reference Manual http://www.lua.org/manual/5.2/manual.html Lua 5.1 grammar written by Nicolai Mainiero http://www.antlr3.org/grammar/1178608849736/Lua.g Tested by Kazunori Sakamoto with Test suite for Lua 5.2 (http://www.lua.org/tests/5.2/) Tested by Alexander Alexeev with Test suite for Lua 5.3 http://www.lua.org/tests/lua-5.3.2-tests.tar.gz Split into separate lexer and parser grammars + minor additions, Steven Johnstone. */ lexer grammar LuaLexer; channels { COMMENTS } SEMICOLON: ';'; BREAK: 'break'; GOTO: 'goto'; DO: 'do'; WHILE: 'while'; END: 'end'; REPEAT: 'repeat'; UNTIL: 'until'; FOR: 'for'; FUNCTION: 'function'; LOCAL: 'local'; IF: 'if'; THEN: 'then'; ELSEIF: 'elseif'; ELSE: 'else'; RETURN: 'return'; COLON: ':'; DCOLON: '::'; DOT: '.'; COMMA: ','; IN: 'in'; LPAREN: '('; RPAREN: ')'; LBRACK: '['; RBRACK: ']'; LBRACE: '{'; RBRACE: '}'; OR: 'or'; AND: 'and'; LT: '<'; GT: '>'; LTE: '<='; GTE: '>='; NEQ: '~='; EQ: '=='; EQUALS: '='; STRCAT: '..'; PLUS: '+'; MINUS: '-'; MUL: '*'; DIV: '/'; MOD: '%'; DIVFLOOR: '//'; BITAND: '&'; BITOR: '|'; BITNOT: '~'; BITSHL: '<<'; BITSHR: '>>'; NOT: 'not'; LEN: '#'; POWER: '^'; NIL: 'nil'; FALSE: 'false'; TRUE: 'true'; DOTS: '...'; NAME: [a-zA-Z_][a-zA-Z_0-9]*; NORMALSTRING: '"' ( EscapeSequence | ~('\\' | '"'))* '"'; CHARSTRING: '\'' ( EscapeSequence | ~('\'' | '\\'))* '\''; LONGSTRING: '[' NESTED_STR ']'; fragment NESTED_STR: '=' NESTED_STR '=' | '[' .*? ']'; INT: Digit+; HEX: '0' [xX] HexDigit+; FLOAT: Digit+ '.' Digit* ExponentPart? | '.' Digit+ ExponentPart? | Digit+ ExponentPart; HEX_FLOAT: '0' [xX] HexDigit+ '.' HexDigit* HexExponentPart? | '0' [xX] '.' HexDigit+ HexExponentPart? | '0' [xX] HexDigit+ HexExponentPart; fragment ExponentPart: [eE] [+-]? Digit+; fragment HexExponentPart: [pP] [+-]? Digit+; fragment EscapeSequence: '\\' [abfnrtvz"'\\] | '\\' '\r'? '\n' | DecimalEscape | HexEscape | UtfEscape; fragment DecimalEscape: '\\' Digit | '\\' Digit Digit | '\\' [0-2] Digit Digit; fragment HexEscape: '\\' 'x' HexDigit HexDigit; fragment UtfEscape: '\\' 'u{' HexDigit+ '}'; fragment Digit: [0-9]; fragment HexDigit: [0-9a-fA-F]; COMMENT: '--[' NESTED_STR ']' -> channel(COMMENTS); LINE_COMMENT: '--' ( // -- | '[' '='* // --[== | '[' '='* ~('=' | '[' | '\r' | '\n') ~('\r' | '\n')* // --[==AA | ~('[' | '\r' | '\n') ~('\r' | '\n')* // --AAA ) ('\r\n' | '\r' | '\n' | EOF) -> channel(COMMENTS); WS: [ \t\u000C\r\n]+ -> channel(HIDDEN); SHEBANG: '#' '!' ~('\n' | '\r')* -> channel(HIDDEN);
ANTLR
4
cmarincia/defold
com.dynamo.cr/com.dynamo.cr.bob/src/com/dynamo/bob/pipeline/antlr/LuaLexer.g4
[ "ECL-2.0", "Apache-2.0" ]
describe(`collection-routing`, () => { beforeEach(() => { cy.visit(`/collection-routing`).waitForRouteChange() }) it(`can create simplest collection route that also has a number as an identifier`, () => { cy.visit(`/collection-routing/1/`) .waitForRouteChange() cy.findByTestId(`slug`) .should(`have.text`, `/preview/1`) cy.findByTestId(`pagecontext`) .should(`have.text`, `1`) }) it(`can navigate to a collection route and see its content rendered`, () => { cy.findByTestId(`collection-routing-blog-0`) cy.should(`have.attr`, `data-testslug`, `/2018-12-14-hello-world/`) .click() cy.waitForRouteChange() .assertRoute(`/collection-routing/2018-12-14-hello-world/`) cy.findByTestId(`slug`) cy.should(`have.text`, `/2018-12-14-hello-world/`) cy.findByTestId(`pagecontext`) cy.should(`have.text`, `/2018-12-14-hello-world/`) }) it(`can navigate to a collection route that uses unions and see its content rendered`, () => { cy.findByTestId(`collection-routing-image-0`) cy.should(`have.attr`, `data-testimagename`, `gatsby-astronaut`) .click() cy.waitForRouteChange() .assertRoute(`/collection-routing/gatsby-astronaut/`) cy.findByTestId(`name`) cy.should(`have.text`, `gatsby-astronaut`) cy.findByTestId(`pagecontext`) cy.should(`have.text`, `gatsby-astronaut`) }) it(`should allow normal folder`, () => { cy.visit(`/collection-routing/hogwarts/1/`) .waitForRouteChange() cy.findByTestId(`custom-text`) .should(`have.text`, `static-folder`) cy.findByTestId(`pagecontext`) .should(`have.text`, `1`) }) it(`should allow static template`, () => { cy.visit(`/collection-routing/westworld/1/template`) .waitForRouteChange() cy.findByTestId(`custom-text`) .should(`have.text`, `Static Template`) cy.findByTestId(`pagecontext`) .should(`have.text`, `1`) }) it(`should allow nested collections`, () => { cy.visit(`/collection-routing/hello-world-1/1`) .waitForRouteChange() cy.findByTestId(`slug`) .should(`have.text`, `/preview/1 + test`) cy.findByTestId(`pagecontext`) .should(`have.text`, `1`) }) it(`supports nested collection + client-only route`, () => { cy.visit(`/collection-routing/hello-world-1/dolores`).waitForRouteChange() cy.findByTestId(`splat`) cy.should(`have.text`, `dolores`) cy.findByTestId(`title`) cy.should(`have.text`, `Named SPLAT Nested with Collection Route!`) }) })
JavaScript
4
pipaliyajaydip/gatsby
e2e-tests/development-runtime/cypress/integration/unified-routing/collection-routing.js
[ "MIT" ]
null /* Some non-comment top-level value is needed; we use null above. */
JSON5
0
leandrochomp/react-skeleton
node_modules/babelify/node_modules/babel-core/node_modules/json5/test/parse-cases/comments/block-comment-following-top-level-value.json5
[ "MIT" ]
<html> <meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale=1"> <link rel="stylesheet" href="/perf/preload_style.css" /> <!-- WARN(preload): This should be no crossorigin --> <link rel="preload" href="/perf/level-2.js?warning&delay=500" as="script" crossorigin="use-credentials"/> <!-- WARN(preconnect): This should be no crossorigin --> <link rel="preconnect" href="https://fonts.googleapis.com" crossorigin="anonymous" /> <!-- PASS(preconnect): This uses crossorigin correctly --> <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /> <body> There was nothing special about this site, nothing was left to be seen, not even a kite. <span style="font-family: 'Lobster Two'">Lobster Two!</span> <script src="/perf/preload_tester.js"></script> </body> </html>
HTML
4
ethcar/lighthouse
lighthouse-cli/test/fixtures/preload.html
[ "Apache-2.0" ]
<?xml version='1.0' encoding='UTF-8'?> <Project Type="Project" LVVersion="19008000"> <Property Name="NI.LV.All.SourceOnly" Type="Bool">true</Property> <Item Name="My Computer" Type="My Computer"> <Property Name="server.app.propertiesEnabled" Type="Bool">true</Property> <Property Name="server.control.propertiesEnabled" Type="Bool">true</Property> <Property Name="server.tcp.enabled" Type="Bool">false</Property> <Property Name="server.tcp.port" Type="Int">0</Property> <Property Name="server.tcp.serviceName" Type="Str">My Computer/VI Server</Property> <Property Name="server.tcp.serviceName.default" Type="Str">My Computer/VI Server</Property> <Property Name="server.vi.callsEnabled" Type="Bool">true</Property> <Property Name="server.vi.propertiesEnabled" Type="Bool">true</Property> <Property Name="specify.custom.address" Type="Bool">false</Property> <Item Name="Helper" Type="Folder"> <Item Name="SampleCommonLib.lvlib" Type="Library" URL="../SampleCommonLib.lvlib"/> </Item> <Item Name="ExternalLib.lvlib" Type="Library" URL="../ExternalLib.lvlib"/> <Item Name="Main.vi" Type="VI" URL="../Main.vi"/> <Item Name="SampleDependentLib.lvlib" Type="Library" URL="../SampleDependentLib.lvlib"/> <Item Name="SampleLib.lvlib" Type="Library" URL="../SampleLib.lvlib"/> <Item Name="Dependencies" Type="Dependencies"> <Item Name="vi.lib" Type="Folder"> <Item Name="NI_XML.lvlib" Type="Library" URL="/&lt;vilib&gt;/xml/NI_XML.lvlib"/> </Item> <Item Name="DOMUserDefRef.dll" Type="Document" URL="DOMUserDefRef.dll"> <Property Name="NI.PreserveRelativePath" Type="Bool">true</Property> </Item> <Item Name="ExternalDep.lvlib" Type="Library" URL="../ExternalDep/ExternalDep.lvlib"/> </Item> <Item Name="Build Specifications" Type="Build"> <Item Name="My Application" Type="EXE"> <Property Name="App_copyErrors" Type="Bool">true</Property> <Property Name="App_INI_aliasGUID" Type="Str">{4E8E512E-D219-4B46-8A7C-406B79449C5C}</Property> <Property Name="App_INI_GUID" Type="Str">{AF904062-6A7A-462B-A307-AED822932325}</Property> <Property Name="App_serverConfig.httpPort" Type="Int">8002</Property> <Property Name="Bld_buildCacheID" Type="Str">{FBB1A68B-4288-42AD-BFFC-FE39C605A6DA}</Property> <Property Name="Bld_buildSpecName" Type="Str">My Application</Property> <Property Name="Bld_excludeDependentPPLs" Type="Bool">true</Property> <Property Name="Bld_localDestDir" Type="Path">../obj/NI_AB_PROJECTNAME/My Application</Property> <Property Name="Bld_localDestDirType" Type="Str">relativeToCommon</Property> <Property Name="Bld_previewCacheID" Type="Str">{684088C1-9FAB-4D86-BB42-DE2127985CB1}</Property> <Property Name="Bld_version.major" Type="Int">1</Property> <Property Name="Destination[0].destName" Type="Str">Application.exe</Property> <Property Name="Destination[0].path" Type="Path">../obj/NI_AB_PROJECTNAME/My Application/Application.exe</Property> <Property Name="Destination[0].preserveHierarchy" Type="Bool">true</Property> <Property Name="Destination[0].type" Type="Str">App</Property> <Property Name="Destination[1].destName" Type="Str">Support Directory</Property> <Property Name="Destination[1].path" Type="Path">../obj/NI_AB_PROJECTNAME/My Application/data</Property> <Property Name="DestinationCount" Type="Int">2</Property> <Property Name="Source[0].itemID" Type="Str">{B30F32AF-1DE3-43A6-88DD-63A94AC5E5E7}</Property> <Property Name="Source[0].type" Type="Str">Container</Property> <Property Name="Source[1].destinationIndex" Type="Int">0</Property> <Property Name="Source[1].itemID" Type="Ref">/My Computer/Main.vi</Property> <Property Name="Source[1].sourceInclusion" Type="Str">TopLevel</Property> <Property Name="Source[1].type" Type="Str">VI</Property> <Property Name="SourceCount" Type="Int">2</Property> <Property Name="TgtF_companyName" Type="Str">National Instruments</Property> <Property Name="TgtF_fileDescription" Type="Str">My Application</Property> <Property Name="TgtF_internalName" Type="Str">My Application</Property> <Property Name="TgtF_legalCopyright" Type="Str">Copyright © 2021 National Instruments</Property> <Property Name="TgtF_productName" Type="Str">My Application</Property> <Property Name="TgtF_targetfileGUID" Type="Str">{7AAE21E1-BA26-43D3-8812-801B5A35E411}</Property> <Property Name="TgtF_targetfileName" Type="Str">Application.exe</Property> <Property Name="TgtF_versionIndependent" Type="Bool">true</Property> </Item> <Item Name="My File Zip File" Type="Zip File"> <Property Name="Absolute[0]" Type="Bool">false</Property> <Property Name="BuildName" Type="Str">My File Zip File</Property> <Property Name="Comments" Type="Str"></Property> <Property Name="DestinationID[0]" Type="Str">{A5927E34-CF68-43F0-935C-517CCAC5D826}</Property> <Property Name="DestinationItemCount" Type="Int">1</Property> <Property Name="DestinationName[0]" Type="Str">Destination Directory</Property> <Property Name="IncludedItemCount" Type="Int">1</Property> <Property Name="IncludedItems[0]" Type="Ref">/My Computer/Main.vi</Property> <Property Name="IncludeProject" Type="Bool">false</Property> <Property Name="Path[0]" Type="Path">../../obj/SamplePromptingProject/MyFileZipFile/MyFileZipFile.zip</Property> <Property Name="ZipBase" Type="Str">NI_zipbasedefault</Property> </Item> <Item Name="My Package" Type="{E661DAE2-7517-431F-AC41-30807A3BDA38}"> <Property Name="NIPKG_addToFeed" Type="Bool">false</Property> <Property Name="NIPKG_certificates" Type="Bool">true</Property> <Property Name="NIPKG_createInstaller" Type="Bool">false</Property> <Property Name="NIPKG_feedLocation" Type="Path">../builds/NI_AB_PROJECTNAME/My Package/Feed</Property> <Property Name="NIPKG_feedLocation.Type" Type="Str">relativeToCommon</Property> <Property Name="NIPKG_installerArtifacts" Type="Str"></Property> <Property Name="NIPKG_installerBuiltBefore" Type="Bool">false</Property> <Property Name="NIPKG_installerDestination" Type="Path">../builds/NI_AB_PROJECTNAME/My Package/Package Installer</Property> <Property Name="NIPKG_installerDestination.Type" Type="Str">relativeToCommon</Property> <Property Name="NIPKG_lastBuiltPackage" Type="Str"></Property> <Property Name="NIPKG_license" Type="Ref"></Property> <Property Name="NIPKG_releaseNotes" Type="Str"></Property> <Property Name="NIPKG_storeProduct" Type="Bool">false</Property> <Property Name="NIPKG_VisibleForRuntimeDeployment" Type="Bool">false</Property> <Property Name="PKG_actions.Count" Type="Int">0</Property> <Property Name="PKG_autoIncrementBuild" Type="Bool">false</Property> <Property Name="PKG_autoSelectDeps" Type="Bool">true</Property> <Property Name="PKG_buildNumber" Type="Int">0</Property> <Property Name="PKG_buildSpecName" Type="Str">My Package</Property> <Property Name="PKG_dependencies.Count" Type="Int">0</Property> <Property Name="PKG_description" Type="Str"></Property> <Property Name="PKG_destinations.Count" Type="Int">1</Property> <Property Name="PKG_destinations[0].ID" Type="Str">{870B4235-1F0B-4BC1-ADCC-4FBB34F7B8CA}</Property> <Property Name="PKG_destinations[0].Subdir.Directory" Type="Str">SampleProject</Property> <Property Name="PKG_destinations[0].Subdir.Parent" Type="Str">root_5</Property> <Property Name="PKG_destinations[0].Type" Type="Str">Subdir</Property> <Property Name="PKG_displayName" Type="Str">My Package</Property> <Property Name="PKG_displayVersion" Type="Str"></Property> <Property Name="PKG_feedDescription" Type="Str"></Property> <Property Name="PKG_feedName" Type="Str"></Property> <Property Name="PKG_homepage" Type="Str"></Property> <Property Name="PKG_hostname" Type="Str"></Property> <Property Name="PKG_maintainer" Type="Str">National Instruments &lt;&gt;</Property> <Property Name="PKG_output" Type="Path">../obj/NI_AB_PROJECTNAME/MyPackage</Property> <Property Name="PKG_output.Type" Type="Str">relativeToCommon</Property> <Property Name="PKG_packageName" Type="Str">sampleproject</Property> <Property Name="PKG_publishToSystemLink" Type="Bool">false</Property> <Property Name="PKG_section" Type="Str">Application Software</Property> <Property Name="PKG_shortcuts.Count" Type="Int">2</Property> <Property Name="PKG_shortcuts[0].Destination" Type="Str">root_8</Property> <Property Name="PKG_shortcuts[0].Name" Type="Str">Application</Property> <Property Name="PKG_shortcuts[0].Path" Type="Path">SampleProject</Property> <Property Name="PKG_shortcuts[0].Target.Child" Type="Str"></Property> <Property Name="PKG_shortcuts[0].Target.Destination" Type="Str"></Property> <Property Name="PKG_shortcuts[0].Target.Source" Type="Str"></Property> <Property Name="PKG_shortcuts[0].Type" Type="Str">NIPKG</Property> <Property Name="PKG_shortcuts[1].Destination" Type="Str">root_8</Property> <Property Name="PKG_shortcuts[1].Name" Type="Str">Application</Property> <Property Name="PKG_shortcuts[1].Path" Type="Path">SamplePromptingProject</Property> <Property Name="PKG_shortcuts[1].Target.Child" Type="Str">{7AAE21E1-BA26-43D3-8812-801B5A35E411}</Property> <Property Name="PKG_shortcuts[1].Target.Destination" Type="Str">root_5</Property> <Property Name="PKG_shortcuts[1].Target.Source" Type="Ref">/My Computer/Build Specifications/My Application</Property> <Property Name="PKG_shortcuts[1].Type" Type="Str">NIPKG</Property> <Property Name="PKG_sources.Count" Type="Int">1</Property> <Property Name="PKG_sources[0].Destination" Type="Str">root_5</Property> <Property Name="PKG_sources[0].ID" Type="Ref">/My Computer/Build Specifications/My Application</Property> <Property Name="PKG_sources[0].Type" Type="Str">EXE Build</Property> <Property Name="PKG_synopsis" Type="Str">SampleProject</Property> <Property Name="PKG_version" Type="Str">1.0.0</Property> </Item> <Item Name="My Package2" Type="{E661DAE2-7517-431F-AC41-30807A3BDA38}"> <Property Name="NIPKG_addToFeed" Type="Bool">false</Property> <Property Name="NIPKG_certificates" Type="Bool">true</Property> <Property Name="NIPKG_createInstaller" Type="Bool">false</Property> <Property Name="NIPKG_feedLocation" Type="Path">../builds/NI_AB_PROJECTNAME/My Package2/Feed</Property> <Property Name="NIPKG_feedLocation.Type" Type="Str">relativeToCommon</Property> <Property Name="NIPKG_installerArtifacts" Type="Str"></Property> <Property Name="NIPKG_installerBuiltBefore" Type="Bool">false</Property> <Property Name="NIPKG_installerDestination" Type="Path">../builds/NI_AB_PROJECTNAME/My Package2/Package Installer</Property> <Property Name="NIPKG_installerDestination.Type" Type="Str">relativeToCommon</Property> <Property Name="NIPKG_lastBuiltPackage" Type="Str"></Property> <Property Name="NIPKG_license" Type="Ref"></Property> <Property Name="NIPKG_releaseNotes" Type="Str"></Property> <Property Name="NIPKG_storeProduct" Type="Bool">false</Property> <Property Name="NIPKG_VisibleForRuntimeDeployment" Type="Bool">false</Property> <Property Name="PKG_actions.Count" Type="Int">0</Property> <Property Name="PKG_autoIncrementBuild" Type="Bool">false</Property> <Property Name="PKG_autoSelectDeps" Type="Bool">true</Property> <Property Name="PKG_buildNumber" Type="Int">0</Property> <Property Name="PKG_buildSpecName" Type="Str">My Package2</Property> <Property Name="PKG_dependencies.Count" Type="Int">0</Property> <Property Name="PKG_description" Type="Str"></Property> <Property Name="PKG_destinations.Count" Type="Int">1</Property> <Property Name="PKG_destinations[0].ID" Type="Str">{ACCAF770-3F69-462B-8985-43FDD8006482}</Property> <Property Name="PKG_destinations[0].Subdir.Directory" Type="Str">SamplePromptingProject</Property> <Property Name="PKG_destinations[0].Subdir.Parent" Type="Str">root_5</Property> <Property Name="PKG_destinations[0].Type" Type="Str">Subdir</Property> <Property Name="PKG_displayName" Type="Str">My Package2</Property> <Property Name="PKG_displayVersion" Type="Str"></Property> <Property Name="PKG_feedDescription" Type="Str"></Property> <Property Name="PKG_feedName" Type="Str"></Property> <Property Name="PKG_homepage" Type="Str"></Property> <Property Name="PKG_hostname" Type="Str"></Property> <Property Name="PKG_maintainer" Type="Str">National Instruments &lt;&gt;</Property> <Property Name="PKG_output" Type="Path">../obj/NI_AB_PROJECTNAME/MyPackage2</Property> <Property Name="PKG_output.Type" Type="Str">relativeToCommon</Property> <Property Name="PKG_packageName" Type="Str">sampleproject2</Property> <Property Name="PKG_publishToSystemLink" Type="Bool">false</Property> <Property Name="PKG_section" Type="Str">Application Software</Property> <Property Name="PKG_shortcuts.Count" Type="Int">1</Property> <Property Name="PKG_shortcuts[0].Destination" Type="Str">root_8</Property> <Property Name="PKG_shortcuts[0].Name" Type="Str">Application</Property> <Property Name="PKG_shortcuts[0].Path" Type="Path">SamplePromptingProject</Property> <Property Name="PKG_shortcuts[0].Target.Child" Type="Str">{7AAE21E1-BA26-43D3-8812-801B5A35E411}</Property> <Property Name="PKG_shortcuts[0].Target.Destination" Type="Str">{ACCAF770-3F69-462B-8985-43FDD8006482}</Property> <Property Name="PKG_shortcuts[0].Target.Source" Type="Ref">/My Computer/Build Specifications/My Application</Property> <Property Name="PKG_shortcuts[0].Type" Type="Str">NIPKG</Property> <Property Name="PKG_sources.Count" Type="Int">2</Property> <Property Name="PKG_sources[0].Destination" Type="Str">{ACCAF770-3F69-462B-8985-43FDD8006482}</Property> <Property Name="PKG_sources[0].ID" Type="Ref">/My Computer/Build Specifications/My Application</Property> <Property Name="PKG_sources[0].Type" Type="Str">EXE Build</Property> <Property Name="PKG_sources[1].Destination" Type="Str">{ACCAF770-3F69-462B-8985-43FDD8006482}</Property> <Property Name="PKG_sources[1].ID" Type="Ref">/My Computer/Build Specifications/My Packed Library</Property> <Property Name="PKG_sources[1].Type" Type="Str">Build</Property> <Property Name="PKG_synopsis" Type="Str">SamplePromptingProject</Property> <Property Name="PKG_version" Type="Str">1.0.0</Property> </Item> <Item Name="My Packed Library" Type="Packed Library"> <Property Name="Bld_buildCacheID" Type="Str">{8FC78DFD-AFB3-466B-810E-EA4C981ED297}</Property> <Property Name="Bld_buildSpecName" Type="Str">My Packed Library</Property> <Property Name="Bld_excludeDependentPPLs" Type="Bool">true</Property> <Property Name="Bld_localDestDir" Type="Path">../obj/NI_AB_PROJECTNAME/MyPackedLibrary</Property> <Property Name="Bld_localDestDirType" Type="Str">relativeToCommon</Property> <Property Name="Bld_previewCacheID" Type="Str">{69F90923-7A2B-4A9B-9756-9C2E0FA9363A}</Property> <Property Name="Bld_version.major" Type="Int">1</Property> <Property Name="Destination[0].destName" Type="Str">SampleDependentLib.lvlibp</Property> <Property Name="Destination[0].path" Type="Path">../obj/NI_AB_PROJECTNAME/MyPackedLibrary/SampleDependentLib.lvlibp</Property> <Property Name="Destination[0].preserveHierarchy" Type="Bool">true</Property> <Property Name="Destination[0].type" Type="Str">App</Property> <Property Name="Destination[1].destName" Type="Str">Support Directory</Property> <Property Name="Destination[1].path" Type="Path">../obj/NI_AB_PROJECTNAME/MyPackedLibrary</Property> <Property Name="DestinationCount" Type="Int">2</Property> <Property Name="PackedLib_callersAdapt" Type="Bool">true</Property> <Property Name="Source[0].itemID" Type="Str">{B30F32AF-1DE3-43A6-88DD-63A94AC5E5E7}</Property> <Property Name="Source[0].type" Type="Str">Container</Property> <Property Name="Source[1].destinationIndex" Type="Int">0</Property> <Property Name="Source[1].itemID" Type="Ref">/My Computer/SampleDependentLib.lvlib</Property> <Property Name="Source[1].Library.allowMissingMembers" Type="Bool">true</Property> <Property Name="Source[1].Library.atomicCopy" Type="Bool">true</Property> <Property Name="Source[1].Library.LVLIBPtopLevel" Type="Bool">true</Property> <Property Name="Source[1].preventRename" Type="Bool">true</Property> <Property Name="Source[1].sourceInclusion" Type="Str">TopLevel</Property> <Property Name="Source[1].type" Type="Str">Library</Property> <Property Name="SourceCount" Type="Int">2</Property> <Property Name="TgtF_companyName" Type="Str">National Instruments</Property> <Property Name="TgtF_fileDescription" Type="Str">My Packed Library</Property> <Property Name="TgtF_internalName" Type="Str">My Packed Library</Property> <Property Name="TgtF_legalCopyright" Type="Str">Copyright © 2021 National Instruments</Property> <Property Name="TgtF_productName" Type="Str">My Packed Library</Property> <Property Name="TgtF_targetfileGUID" Type="Str">{12923A85-5217-4CFF-A5E9-6E528F6698EF}</Property> <Property Name="TgtF_targetfileName" Type="Str">SampleDependentLib.lvlibp</Property> <Property Name="TgtF_versionIndependent" Type="Bool">true</Property> </Item> <Item Name="My Project Zip File" Type="Zip File"> <Property Name="Absolute[0]" Type="Bool">false</Property> <Property Name="BuildName" Type="Str">My Project Zip File</Property> <Property Name="Comments" Type="Str"></Property> <Property Name="DestinationID[0]" Type="Str">{FDF12BA5-EAA1-486B-9622-E9D3D94978A7}</Property> <Property Name="DestinationItemCount" Type="Int">1</Property> <Property Name="DestinationName[0]" Type="Str">Destination Directory</Property> <Property Name="IncludedItemCount" Type="Int">1</Property> <Property Name="IncludedItems[0]" Type="Ref">/My Computer</Property> <Property Name="IncludeProject" Type="Bool">true</Property> <Property Name="Path[0]" Type="Path">../../obj/SamplePromptingProject/MyProjectZipFile/MyProjectZipFile.zip</Property> <Property Name="ZipBase" Type="Str">NI_zipbasedefault</Property> </Item> </Item> </Item> </Project>
LabVIEW
2
jovianarts/LVSolutionBuilder
src/_tests/Tests.Assets/SamplePromptingProject.lvproj
[ "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 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. <%! import sys if sys.version_info[0] > 2: from django.utils.translation import gettext as _ else: from django.utils.translation import ugettext as _ %> <form action="{{ url }}" method="POST">> ${ csrf_token(request) | n,unicode } <div class="modal-header"> <button type="button" class="close" data-dismiss="modal" aria-label="${ _('Close') }"><span aria-hidden="true">&times;</span></button> <h2 class="modal-title">${_('Confirm action')}</h2> </div> <div class="modal-body"> <div class="alert-message block-message warning"> ${ title } </div> </div> <div class="modal-footer"> <input type="submit" class="btn primary" value="${ _('Yes') }"/> <a href="#" class="btn secondary hideModal">${ _('No') }</a> </div> </form>
Mako
3
yetsun/hue
apps/metastore/src/metastore/templates/confirm.mako
[ "Apache-2.0" ]
a ← 2.0j3.2 + 1.0j3.2 ⎕ ← a v ← 2j1 3 1 3J¯2 4 23 2 3 44 3 1 23j.3 a ← 2 3 ⍴ v ⎕ ← a a1 ← ⎕ ← a × 2 a2 ← ⎕ ← ⍉ a1 a3 ← ⎕ ← 2 ⊖ a2 a4 ← ⎕ ← ⌽ a3 b ← ⌽ 2 ⊖ ⍉ a × 2 ⎕ ← b ⎕ ← a +.× b ⎕ ← |3j4 ⍝ -> 5 0
APL
2
melsman/apltail
tests/cmplx.apl
[ "MIT" ]
{:source-paths ["src" "resources" "checkouts/helix/src"] :dependencies [[lilactown/helix "0.0.10"] [lucywang000/hashp "0.1.2"] [binaryage/devtools "1.0.0"]] :nrepl {:port 6666 :cider true :init-ns user} :builds {:app {:target :browser :dev {:output-dir "dev" :asset-path "/frameworks/keyed/helix/dev/"} :devtools {:after-load demo.main/after-reload :watch-dir "resources/demo/styles" :watch-path "/styles" :preloads [devtools.preload hashp.core]} :release {:output-dir "dist" :compiler-options {:optimizations :advanced :infer-externs true}} :modules {:main {:init-fn demo.main/init!}}}}}
edn
3
andyhasit/js-framework-benchmark
frameworks/keyed/helix/shadow-cljs.edn
[ "Apache-2.0" ]
;;Autor : Delay E. (Université de Limoges) ;;7 decembre 2012 modéliser l'article de R.DION 1952 breed [Districts District] ;les districte sont les quartiers breed [wineMarkets wineMarket] breed [foreigns foreign] undirected-link-breed [linksPrim linkPrim] undirected-link-breed [secLinks SecLink] globals [ ;des gloables qu'on va chercher a analyser en stat descriptive fitnessPatches patchbefore prodCostGlob propPatchMont propPatchPlain globalQuality sumDiffQuality meanQuality gini-index-reserve lorenz-points gini-index-patch lorenz-points-patch meanQualityTotal meanQualityMountain meanQualityPlain maxnbplots DiffExtCentral nbcentralPlots meanPatchByNetwork ;;variable for gloablSetup nbCitys nbPLots whatWord demandF priceMaxWineF standarDevPop downerQ coefUpQuality logistique ] patches-own[ alti owner ageOfPlot plotVineType grapProduction winrAmount quality RelaQualityInit RelaQuality DiffQuality ] wineMarkets-own [ popB ;population locale qui varie autour de 0 par une loi normal supplyB ;la somme des productions de chaque patches demandB ;les besoin locaux en vin stockB ;ce que la ville est capable de stoker (demandB - supplyB) myplots ;agentSet de tout mes patches distanceToMarketone ;la distance du marché centrale productionCost ;les cout de productions qui sont proportionnel à la somme des éloignement des parcelles prodCostNetWork ;les cout de production du réseau connection ;FRUE/FALSE estce que la ville est connecté networkMarket ;agentSet des marché connecté au marché principale distCostPC ;le cout de la distance eu marché principale plotsQuality ; la qualitée moyenne de myPlots supplyW demandW stockW ] Districts-own[ ownerTown bourgeois worker city ] foreigns-own[ demandForeign supplyForeign priceMax myWineMarket demandRest ] links-own [ demandFlux ] ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;; SETUP ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; to globalSetup ;this setup is not interpreted when the model run on openMole ;We need here all interface slider elements and all hard variable set nbCitys nbCitys-i set nbPLots nbPLots-i set whatWord whatWord-i set demandF demandF-i set priceMaxWineF priceMaxWineF-i set standarDevPop standarDevPop-i set downerQ downerQ-i set coefUpQuality coefUpQuality-i set logistique logistique-i end to setup clear-all globalSetup commonSetup end to commonSetup ; import-pcolors "montagne1.png" let conterColor 2 set patchbefore count patches with [owner != -9999] if whatWord = 1 [ import-pcolors "montagne5.png" ask patches [set alti pcolor] ] if whatWord = 0[ ask patches [set alti 0] ] if whatWord = 2 [ import-pcolors "montagne6.png" ask patches [set alti pcolor] ] ask patches [ set quality (alti + 0.1) * 10 set owner -9999 set plotVineType -9999 ] if not any? patches with [quality <= 0][ set meanQuality mean [quality] of patches with [owner = -9999] ask patches [ set RelaQualityInit quality / meanQuality * 100 ] ] set-default-shape wineMarkets "house" set-default-shape Districts "circle" set-default-shape foreigns "boat" ; set-default-shape parcels "plant" create-wineMarkets nbCitys [ setxy random-pxcor random-pycor set size 3 set label plotsQuality set supplyB 0 set demandB 0 set stockB 0 set popB 100 set supplyW 0 set demandW 0 set stockW 0 set networkMarket (turtle-set) ; pour que chaque marché ait une couleur différente set color conterColor set conterColor ifelse-value (conterColor < 140) [conterColor + 10] [conterColor - 139] set connection 0 ] create-foreigns 1 [ ; setxy random-pxcor random-pycor setxy -30 0 set priceMax priceMaxWineF set size 5 ] ;;creation des parcelles viticole ask wineMarkets [ set myplots n-of (random nbPLots + 1) patches in-radius 5 with [owner = -9999] ask myplots [ set pcolor [color] of myself set owner [who] of myself ] ] ;;recherche de la ville la plus proche pour établir une liaison ask foreigns [ set myWineMarket min-one-of wineMarkets [distance myself] ask myWineMarket [ set connection 1 ] create-linkPrim-with myWineMarket ] update-lorenz-and-gini reset-ticks end ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;Pour bouger n'importe quelle tortue avant de démarrer to moveMousse if mouse-down? [ let candidate min-one-of turtles [distancexy mouse-xcor mouse-ycor] if [distancexy mouse-xcor mouse-ycor] of candidate < 1 [ ;; The WATCH primitive puts a "halo" around the watched turtle. watch candidate while [mouse-down?] [ ;; If we don't force the view to update, the user won't ;; be able to see the turtle moving around. display ;; The SUBJECT primitive reports the turtle being watched. ask subject [ setxy mouse-xcor mouse-ycor ] ] ;; Undoes the effects of WATCH. Can be abbreviated RP. reset-perspective ] ] clear-links ask foreigns [ set myWineMarket min-one-of wineMarkets [distance myself] ask myWineMarket [ set connection 1 ] create-linkPrim-with myWineMarket ] end to seeQuality ifelse marketColor = TRUE [ ask patches [ set pcolor alti ] ask wineMarkets [ ask myPlots [ set pcolor [color] of myself ] ] ][ ask patches [ set pcolor scale-color red quality 0 100 ] ] end ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; RUN TO THE GRID ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; to run-to-grid [tmax] commonSetup while [ticks <= tmax] [go] reset-ticks end to-report go-stop? ; ifelse nb-viti-non-innov = 0 ; [report FALSE][report TRUE] end ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;; GO ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; to go ;;pour le calcul du fitness set patchbefore count patches with [owner != -9999] exportmonde ask wineMarkets [ dynPop] ;;demande n vin pour les étrangés ask foreigns [ marketChoice foreignNeed ] ask wineMarkets [ produce upQuality ageIncrement offer colonizePLots calculCost ] downQuality calculGlobalQuality ; updateColor ask seclinks [ killlinks ] altirob statSpat ;;;;mise a jour du graph update-fitness2 update-lorenz-and-gini updatePlot tick end to marketChoice ;;;;foreigns context ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;calule de la capacité de production du réseau de marché! let surfViti 0 let countNetworkPlots [] ask myWineMarket [ ask networkmarket [ let countMyPlots count myplots set countNetworkPlots lput countMyPlots countNetworkPlots ] set surfViti sum countNetworkPlots + count myPlots ] let capProd surfViti * 7 ;;creation des connections if [prodCostNetWork] of myWineMarket > priceMaxWineF [ ask myWineMarket [ let firtTestMarket wineMarkets with [connection = 0] if any? firtTestMarket [ let potMark 0 ;;connection au marchés les plus proches set potMark min-n-of 1 firtTestMarket [distance myself] create-secLinks-with potMark ask potMark [ set connection 1 set distanceToMarketone distance myself ] set networkMarket (secLink-neighbors with [connection = 1]) ] ] ] ;;suprimer des connextion en cas de surproduction if demandF < capProd[ ask myWineMarket [ if any? networkmarket [ let farewayMarket max-one-of networkmarket [distance myself] ask farewayMarket [ set connection 0 set distanceToMarketone 0 ] set networkMarket (secLink-neighbors with [connection = 1]) ] ] ] end to killlinks ;;;;links context if any? seclinks[ ask seclinks with [[connection] of end2 = 0][ die ] ] end to foreignNeed ;;;;foreigns context ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ask myWineMarket [ let countNetwork count networkMarket + 1 set demandB demandB + (demandF / countNetwork) ask networkMarket [ set demandB demandB + (demandF / countNetwork) ;- (distCostPC * 10) ] ] end to dynPop set popB popB + random-normal 0 standarDevPop set demandB popB end to produce ;;WineMarkets context;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ; ask myPlots [ ; set grapProduction 0 ; ;verification de l'age de la parcelle pour rentrer en production ; if ageOfPlot > 3 [ ; set grapProduction 1 ; ] ; if grapProduction = 1 [ ; set winrAmount 7 ; ] ; ; ] ask myPlots [ set winrAmount 7 ] end ;;;;;;;;;;;;;;;;;;;;;;;;;;Qualité du terrain;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; to upQuality ;;;;;;WineMarkets Context if logistique = 1 [ ask myPlots [ ;; ;set quality quality + coefUpQuality * quality * (1 - quality / 100) ;; fonction logistique de croissance de la Qualite set quality 100 * (1 / (1 + exp(- coefUpQuality * quality))) ] ] if logistique = 0 [ ask myPlots [ set quality quality + (coefUpQuality * quality) ;; fonction linéaire ] ] if any? myPlots [ set plotsQuality mean [quality] of myPlots ] end to downQuality ask patches with [owner = -9999][ if quality > 0.1 [ set quality quality - downerQ if alti > 0.1 and quality < alti[ set quality alti ] ] if quality <= 0.1 [ set quality 0.1 ] ] end ;to updateColor ; ask patches [ ; set pcolor quality ; ] ;end to ageIncrement ;;;WineMarkets context;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ask myPlots [ set ageOfPlot ageOfPlot + 1 ] end to offer ;;;WineMarkets context;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; set supplyB sum [winrAmount] of myplots set stockB demandB - supplyB end to colonizePLots ;;;WineMarkets context;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; if demandB > supplyB and priceMaxWineF > productionCost [ let potplotfinal (patch-set) ;collection de patchs pot ask myplots [ let potplot patches in-radius 2 with [owner = -9999 ] ;critère de selection, recherche de voisins potentiels set potplotfinal (patch-set potplotfinal potplot) ;renseigne la collection ] if any? potplotfinal [ let listloop [1 1 1 1 1] foreach listloop [ let newplot min-one-of (potplotfinal with-max[quality])[distance myself] ask newplot [ set pcolor [color] of myself set owner [who] of myself ] set myplots (patch-set myplots newplot) ] ] ] if demandB < supplyB or priceMaxWineF < productionCost[ if any? myplots with-max [distance myself] [ let frich n-of 1 myplots with-max [distance myself] if count frich > 0[ ask frich [ set pcolor alti set owner -9999 ] set myplots myplots with [owner = [who] of myself] ] ] ] end to calculCost ;;;;;WineMarkets context;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; let distcost 0 ask myplots [ let distplot distance myself set distcost distcost + ( distplot * 5 ) ;;;5 est le cout de l'acheminement local ] set productionCost (distcost / 200 ) ;;; on peut ajouter des cout de productions ici set prodCostNetWork productionCost / (count Seclinks + 1) ;;; s'il n'y a pas de marché networke le cout de prod myeon sont les meme que les cout de prod ;; Si on travail sur un réseau de marché if any? networkMarket [ let sumPrdCost productionCost ask networkMarket [ let distBigMarket distance myself set distCostPC distBigMarket set sumPrdCost ( sumPrdCost + productionCost + distCostPC) ] let prodCostMoy sumPrdCost / count networkMarket set prodCostNetWork prodCostMoy ] end to update-fitness2 if count patches with [owner != -9999] > 0 [ set fitnessPatches count patches with [owner != -9999] / patchBefore ] end to altirob ;;pour tracer la courbe du nombre de patches en montagne et en plaine let testAlti count patches with [alti > 0] if testAlti != 0 [ set propPatchMont (count patches with [alti >= 0.1 and owner != -9999]) / ( count patches with [alti >= 0.1] ) * 100 ] set propPatchPlain (count patches with [alti <= 0.1 and owner != -9999]) / ( count patches with [alti <= 0.1] ) * 100 end to exportmonde if export = TRUE [ if ticks = 0 [ export-view "export/quantity0.png" set marketColor FALSE seeQuality export-view "export/quality0.png" set marketColor TRUE seeQuality ] if ticks = 130 [ export-view "export/quantity130.png" set marketColor FALSE seeQuality export-view "export/quality130.png" set marketColor TRUE seeQuality ] if ticks = 300 [ export-view "export/quantity300.png" set marketColor FALSE seeQuality export-view "export/quality300.png" set marketColor TRUE seeQuality ] ] end to statSpat set meanQualityTotal mean [quality] of patches with [owner != -9999] ifelse any? patches with [alti >= 0.1 and owner != -9999] [ set meanQualityMountain mean [quality] of patches with [owner != -9999 and alti >= 0.1] set meanQualityPlain mean [quality] of patches with [owner != -9999 and alti < 0.1] ][ set meanQualityMountain 0 set meanQualityPlain mean [quality] of patches with [owner != -9999] ] ask foreigns [ ask myWineMarket [ set nbcentralPlots count myPlots if nbcentralPlots > maxnbplots [ set maxnbplots nbcentralPlots ] set DiffExtCentral maxnbplots - nbcentralPlots ] ] let listpatch [] foreach sort wineMarkets with [connection = 1][ set listpatch lput count [myPlots] of ? listpatch ] set meanPatchByNetwork mean listpatch end to calculGlobalQuality let tpsGlobalQuality [] ask wineMarkets [ set tpsGlobalQuality lput plotsQuality tpsGlobalQuality set label (precision plotsQuality 2) ] set globalQuality tpsGlobalQuality end to update-lorenz-and-gini ;;; pour avoir un gini les patches sur les patches cultivé ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; let patchOwnered patches with [owner != -9999] let countPatchOwner count patchOwnered let sorted-wealths sort [quality] of patchOwnered let total-wealth sum sorted-wealths let wealth-sum-so-far 0 let index 0 set gini-index-reserve 0 set lorenz-points [] ;pour stocker un vecteur, lupt rajoute dans la liste repeat countPatchOwner [ ; une boucle sur l'ensemble des patches cultivé set wealth-sum-so-far (wealth-sum-so-far + item index sorted-wealths) set lorenz-points lput ((wealth-sum-so-far / total-wealth) * 100) lorenz-points set index (index + 1) set gini-index-reserve gini-index-reserve + (index / countPatchOwner) - (wealth-sum-so-far / total-wealth) ] set gini-index-reserve (gini-index-reserve / countPatchOwner) / 0.5 ;;;;calcul du gini du nombre de patches let sorted-wealths-patch [] foreach sort wineMarkets [ set sorted-wealths-patch lput count[myPlots] of ? sorted-wealths-patch ] let total-wealth-patch sum sorted-wealths-patch let wealth-sum-so-far-patch 0 let index-patch 0 set gini-index-patch 0 set lorenz-points-patch [] ;pour stocker un vecteur, lupt rajoute dans la liste repeat count wineMarkets [ set wealth-sum-so-far-patch (wealth-sum-so-far-patch + item index-patch sorted-wealths-patch) set lorenz-points-patch lput ((wealth-sum-so-far-patch / total-wealth-patch) * 100) lorenz-points-patch set index-patch (index-patch + 1) set gini-index-patch gini-index-patch + ((index-patch / count wineMarkets) - (wealth-sum-so-far-patch / total-wealth-patch)) ] set gini-index-patch (gini-index-patch / count wineMarkets) / 0.5 end to updatePlot set-current-plot "demend" ask WineMarkets [ set-plot-pen-color color ;pour renvoyer la couleur du fermier plotxy ticks demandB ] set-current-plot "productionCost_WineMarkets" ask WineMarkets [ set-plot-pen-color color ;pour renvoyer la couleur du fermier plotxy ticks productionCost ] set-current-plot "global-cost" ask foreigns [ ask myWineMarket [ set-plot-pen-color color plotxy ticks prodCostNetWork ; set prodCostGlob prodCostNetWork ] ] set-current-plot "nbconection" ask foreigns [ ask myWineMarket [ set-plot-pen-color color plotxy ticks count networkMarket ] ] set-current-plot "meanQualityVineyard" ask wineMarkets [ set-plot-pen-color color if count myPlots > 0 [ plotxy ticks plotsQuality ] ] set-current-plot "mountainPlot" set-plot-pen-color gray plotxy ticks propPatchMont set-plot-pen-color red plotxy ticks propPatchPlain set-current-plot "Absolute-landscape-fitness" plotxy ticks fitnessPatches set-current-plot "Quality" ;;pour réaliser un histogram on a besoin d'une liste set-plot-x-range 0 ( (max globalQuality) + 5) histogram globalQuality let maxbar modes globalQuality let maxrange length filter [ ? = item 0 maxbar ] globalQuality set-plot-y-range 0 max list 10 maxrange set-current-plot "LorenzCurve" ask wineMarkets [ plot-pen-reset set-plot-pen-interval 100 / (count patches with [owner = -9999]) plot 0 foreach lorenz-points plot ] end to photo export-view (word "../img/exportview/espace_" ticks ".png") end @#$#@#$#@ GRAPHICS-WINDOW 210 10 609 430 32 32 5.985 1 10 1 1 1 0 0 0 1 -32 32 -32 32 0 0 1 ticks 30.0 BUTTON 15 25 88 58 NIL setup NIL 1 T OBSERVER NIL NIL NIL NIL 1 SLIDER 15 100 187 133 nbCitys-i nbCitys-i 1 100 10 1 1 NIL HORIZONTAL BUTTON 95 25 182 58 go step go NIL 1 T OBSERVER NIL NIL NIL NIL 1 SLIDER 15 135 187 168 nbPLots-i nbPLots-i 1 20 7 1 1 NIL HORIZONTAL TEXTBOX 640 10 800 46 quantité de vin demandé par le marché étranger : 7000 default 9 0.0 1 TEXTBOX 820 10 970 31 Prix max que les étrangers sont capable de payer le vin 9 0.0 1 PLOT 605 600 770 740 demend NIL NIL 0.0 10.0 0.0 10.0 true false "" "" PENS "default" 1.0 2 -16777216 true "" "" BUTTON 120 65 183 98 NIL go T 1 T OBSERVER NIL NIL NIL NIL 1 PLOT 5 595 185 745 productionCost_WineMarkets NIL NIL 0.0 10.0 0.0 10.0 true false "" "" PENS "default" 1.0 2 -16777216 true "" "" "pen-1" 1.0 0 -2674135 true "" "plot priceMaxWineF" PLOT 605 445 765 595 nbconection NIL NIL 0.0 10.0 0.0 10.0 true false "" "" PENS "default" 1.0 0 -16777216 true "" "" "pen-1" 1.0 0 -7500403 true "" "plot count seclinks" PLOT 15 175 205 335 meanQualityVineyard NIL NIL 0.0 10.0 0.0 10.0 true false "" "" PENS "default" 1.0 2 -16777216 true "" "" SLIDER 640 35 812 68 demandF-i demandF-i 0 30000 8000 100 1 NIL HORIZONTAL SLIDER 815 35 992 68 priceMaxWineF-i priceMaxWineF-i 0 150 70 10 1 NIL HORIZONTAL BUTTON 20 65 112 98 go 500 if ticks <= 500 [go] T 1 T OBSERVER NIL NIL NIL NIL 1 PLOT 630 230 870 430 Absolute-landscape-fitness NIL NIL 0.0 10.0 0.9 1.1 true false "" "" PENS "default" 1.0 0 -16777216 true "" "" "pen-1" 1.0 0 -5298144 true "" "plot 1" BUTTON 10 485 132 518 NIL moveMousse T 1 T OBSERVER NIL NIL NIL NIL 1 TEXTBOX 15 525 165 561 Si l'on veux déplacer la vache pour tester le développement d'une zone en particulé 9 0.0 1 PLOT 630 75 885 225 global-cost NIL NIL 0.0 10.0 0.0 10.0 true false "" "" PENS "default" 1.0 0 -16777216 true "" "" TEXTBOX 150 565 410 586 evolution du prix pour chaque marché locale 9 0.0 1 PLOT 875 385 1115 585 mountainPlot NIL NIL 0.0 10.0 0.0 10.0 true false "" "" PENS "default" 1.0 2 -16777216 true "" "" SWITCH 1140 15 1282 48 marketColor marketColor 1 1 -1000 BUTTON 1035 15 1137 48 NIL seeQuality NIL 1 T OBSERVER NIL NIL NIL NIL 1 PLOT 175 440 385 560 Quality NIL NIL 0.0 10.0 0.0 10.0 true false "" "" PENS "default" 1.0 1 -16777216 true "" "" SWITCH 10 445 157 478 chooseMode chooseMode 1 1 -1000 SWITCH 1135 55 1237 88 export export 1 1 -1000 INPUTBOX 1135 155 1225 215 standarDevPop-i 2 1 0 Number PLOT 905 75 1105 225 Difference mean Quality Mountain vs Plain NIL NIL 0.0 10.0 0.99 1.0 true false "" "" PENS "pen-1" 1.0 0 -7500403 true "" "plotxy ticks (meanQualityMountain - meanQualityPlain)" "zero" 1.0 0 -2674135 true "" "plot 0" PLOT 875 230 1115 380 meanQualityPlots NIL NIL 0.0 10.0 0.0 0.2 true true "" "" PENS "total" 1.0 0 -16777216 true "" "plotxy ticks meanQualityTotal" "Mountain" 1.0 0 -7500403 true "" "plotxy ticks meanQualityMountain" "Plaine" 1.0 0 -2674135 true "" "plotxy ticks meanQualityPlain" MONITOR 1135 95 1227 140 NIL meanQuality 17 1 11 INPUTBOX 1135 225 1210 285 downerQ-i 0.15 1 0 Number PLOT 395 445 595 595 LorenzCurve NIL NIL 0.0 100.0 0.0 100.0 true false "" "" PENS "default" 1.0 0 -16777216 true "" "" "pen-1" 100.0 0 -7500403 true "plot 0\nplot 100" "" PLOT 395 595 595 745 Gini-Index-Quality Gini Time 0.0 10.0 0.0 1.0 true false "" "" PENS "default" 1.0 0 -16777216 true "" "plot (gini-index-reserve)" INPUTBOX 1135 305 1225 365 coefUpQuality-i 0.01 1 0 Number SLIDER 20 345 170 378 whatWord-i whatWord-i 0 2 0 1 1 NIL HORIZONTAL TEXTBOX 20 390 170 426 WhatWord=0 isotrope\n 1 mountain rigth\n 2 mountain left 9 0.0 1 PLOT 190 595 390 745 Gini-index-Patch NIL NIL 0.0 10.0 0.0 1.0 true false "" "" PENS "default" 1.0 0 -16777216 true "" "plot (gini-index-patch)" "pen-1" 1.0 0 -2674135 true "" "plot 0" TEXTBOX 770 455 865 505 nb de connections entre le marché centrale et les marchés périfériques 8 0.0 1 TEXTBOX 780 645 870 710 Graphe qui permet d'observer quand est ce que la demande extérieur est assouvie 8 0.0 1 SLIDER 1240 55 1273 201 logistique-i logistique-i 0 1 0 1 1 NIL VERTICAL MONITOR 1135 380 1192 425 maxQ max[quality] of patches 17 1 11 BUTTON 1135 435 1207 468 NIL photo NIL 1 T OBSERVER NIL NIL NIL NIL 1 @#$#@#$#@ ## AUTEURS Etienne DELAY (GEOLAB - université de Limoges) etienne.delay[at]etu.unilim.fr Marius CHEVALIER (GEOLAB - université de Limoges) marius.chev[at]gmail.com Cyril PIOU (CIRAD, UMR CBGP, 34398 Montpellier cedex 5, France) cyril.piou[at]cirad.fr ## CREDITS AND REFERENCES Ce modèle vise à éclairer la lecture de l'article DELAY,E., CHEVALIER,M., "Roger Dion toujours vivant",Cybergeo : European Journal of Geography [En ligne], Systèmes, Modélisation, Géostatistiques. Il a été développé par les auteurs et distribué sous licence GNU-GPL V3 ## WHAT IS IT? Ce modèle vise à explorer et revisiter les conditions d'émergence et de structuration historique des territoires de production des vins de qualité décrits dans l’œuvre de Roger Dion (Dion, R., 1952. Querelle des anciens et des modernes sur les facteurs de la qualité du vin. geo 61, 417–431.). On s'intéresse particulièrement à 2 hypothèses : * la qualité du vin est une fonction du travail de la parcelle (donc une fonction temporelle). * l'émergence d'un territoire viticole est moins question des conditions initiales (caractéristiques pédoclimatiques), que de l'existence d'un marché viticole pour écouler les productions. ## HOW IT WORKS Pour plus de détails, vous pourrez vous reporter à l'article de cybergéo. Ce qu'il faut néanmoins noter ici, c'est que l'augmentation et la diminution de la qualité suivent des fonctions linéaires. Lorsqu'une parcelle est mise en culture, sa qualité augmente linéairement en fonction du nombre d'itérations du modèle. Quand les simulations sont lancées en condition anisotropique, les formes blanches représentent des coteaux qui sont considérés comme plus qualitatifs. Les parcelles de ces zones commencent donc leur évolution avec une qualité initiale plus élevée. ## HOW TO USE IT **Les variables globales** : _nbCitys_ : le nombre de marchés locaux généré à l'initialisation. _nbPLots_ : le nombre de parcelles initiales pour chaque marché local à l'initialisation. _demandF_ : la demande extérieure au territoire symbolisée par le lien entre la vache et le 1er marché. _priceMaxWineF_ : le consentement à payer par les négociants étrangers. Au-delà de cette limite économique, la production n'est pas vendue. _standarDevPop_ : la dérivée standard pour l'évolution de la population de chaque marché. Ces populations locales sont consommatrices des marchés qui ne sont pas rattachés au réseau. _downerQ_ : le coefficient de diminution de la qualité à chaque itération _coefUpQuality_ : le coefficient d'augmentation de la qualité à chaque itération **Les graphiques** : _meanQualityVineyard_ : permet d'observer l'évolution de la qualité moyenne des parcelles pour chaque marché. _Quality_ : permet sous la forme d'un histogramme d'observer la fréquence de chaque classe de qualité de parcelles _LorenzCurve_ : quand elle est linéaire et avec un coefficient directeur proche de 1, la courbe de Lorenze signifie que les valeurs étudiées sont réparties équitablement entre les agents. Dans ce cas-là, les agents sont les parcelles, et la valeur observée est la qualité. _nbconection_ : permet de suivre dans le temps le nombre de connexions établies entre le marché principal et les marchés secondaires. _productionCost_WineMarkets_ : permet de suivre les coûts de production pour chaque marché _Gini-index-Patch_ : l'indice de Gini est une valeur comprise entre 0 et 1 permettant d'évaluer l'équitable répartition d'une valeur entre tous les agents. Ici, on s'intéresse au nombre de parcelles par agent. Si la valeur de Gini est proche de 1, le système n'est pas équitable. _Gini-Index-Quality_ : s'intéresse à la répartition de la qualité entre les marchés _demend_ : permet de visualiser si la demande extérieure est assouvie (valeurs proches de 0) _global-cost_ : est la synthèse des valeurs que prennent les coûts de production à l'échelle individuelle des marchés (sommes des coûts individuels). _Difference mean Quality Mountain vs Plain_ : reporte la différence de qualité entre la montagne et la plaine _Absolute-landscape-fitness_ : représente les dynamiques du paysage viticole afin de visualiser s'il y a de grandes vagues d'extension du vignoble _meanQualityPlots_ reporte la qualité moyenne des parcelles (patches) _mountainPlot_ ## THINGS TO NOTICE * La géographie commerciale n’a pas seulement un impact à l'échelle macro, mais également au niveau micro. Si une parcelle est maintenue durablement en culture en raison de sa proximité (faibles coûts de transport) et de sa qualité progressive liée à l’ancienneté, elle peut acquérir une qualité supérieure quelles que sont les conditions pédoclimatiques initiales. * Au-delà de leur trajectoire individuelle, on peut imaginer que ces parcelles ont une fonction méso-économique stimulant la vente des parcelles voisines par effet de proximité, et ainsi à l’échelle des marchés locaux reconstituer la hiérarchie dans les appellations. * Les dynamiques mises en évidence dans ce marché "globalisé" permettent aussi d'interpréter la création de zones de protection de la qualité comme une mesure de sauvegarde des compétences acquises par les exploitants. En effet, il n'est pas acceptable de voir sa production écartée de la commercialisation (réduction de la couronne d'influence autour des marchés) sous prétexte de l'arrivée de vins moins chers. La création des AOC, cette ”arme d’un style nouveau, qu’elle [au viticulteur de qualité] a donné depuis peu la législation sur les appellations d’origine des vins” (Dion R. 1952), peut donc être envisagée comme un moyen, pour ces viticulteurs, de distordre la concurrence à leur profit. ## THINGS TO TRY * Nous vous encourageons à jouer avec le switch "marketColor" accompagné du bouton "seeQuality" afin de suivre l'évolution de la qualité sur les différentes parcelles tout au long de la simulation. * Vous pouvez également modifier les inputs "downQ" et "CoefupQuality" pour influencer la vitesse de progression ou de régression de la qualité sur les parcelles. ## EXTENDING THE MODEL * R.DION oppose dans son article les vins bourgeois des vins paysans. Nous nous sommes cantonnés à modéliser les dynamiques issues des vins bourgeois, mais il serait également intéressant d'explorer le comportement du territoire et de la qualité si une concurrence /cohabitation existait entre les vins bourgeois et paysans. * On pourrait également envisager cette modélisation en considérant que la qualité évolue suivant une fonction logistique et explorer les implications de ce changement de paradigme. @#$#@#$#@ default true 0 Polygon -7500403 true true 150 5 40 250 150 205 260 250 airplane true 0 Polygon -7500403 true true 150 0 135 15 120 60 120 105 15 165 15 195 120 180 135 240 105 270 120 285 150 270 180 285 210 270 165 240 180 180 285 195 285 165 180 105 180 60 165 15 arrow true 0 Polygon -7500403 true true 150 0 0 150 105 150 105 293 195 293 195 150 300 150 boat false 0 Polygon -7500403 true true 45 180 75 225 225 225 255 180 Line -7500403 true 150 180 150 45 Polygon -7500403 true true 150 45 60 150 150 150 Polygon -7500403 true true 150 45 225 150 150 150 box false 0 Polygon -7500403 true true 150 285 285 225 285 75 150 135 Polygon -7500403 true true 150 135 15 75 150 15 285 75 Polygon -7500403 true true 15 75 15 225 150 285 150 135 Line -16777216 false 150 285 150 135 Line -16777216 false 150 135 15 75 Line -16777216 false 150 135 285 75 bug true 0 Circle -7500403 true true 96 182 108 Circle -7500403 true true 110 127 80 Circle -7500403 true true 110 75 80 Line -7500403 true 150 100 80 30 Line -7500403 true 150 100 220 30 butterfly true 0 Polygon -7500403 true true 150 165 209 199 225 225 225 255 195 270 165 255 150 240 Polygon -7500403 true true 150 165 89 198 75 225 75 255 105 270 135 255 150 240 Polygon -7500403 true true 139 148 100 105 55 90 25 90 10 105 10 135 25 180 40 195 85 194 139 163 Polygon -7500403 true true 162 150 200 105 245 90 275 90 290 105 290 135 275 180 260 195 215 195 162 165 Polygon -16777216 true false 150 255 135 225 120 150 135 120 150 105 165 120 180 150 165 225 Circle -16777216 true false 135 90 30 Line -16777216 false 150 105 195 60 Line -16777216 false 150 105 105 60 car false 0 Polygon -7500403 true true 300 180 279 164 261 144 240 135 226 132 213 106 203 84 185 63 159 50 135 50 75 60 0 150 0 165 0 225 300 225 300 180 Circle -16777216 true false 180 180 90 Circle -16777216 true false 30 180 90 Polygon -16777216 true false 162 80 132 78 134 135 209 135 194 105 189 96 180 89 Circle -7500403 true true 47 195 58 Circle -7500403 true true 195 195 58 circle false 0 Circle -7500403 true true 0 0 300 circle 2 false 0 Circle -7500403 true true 0 0 300 Circle -16777216 true false 30 30 240 cow false 0 Polygon -7500403 true true 200 193 197 249 179 249 177 196 166 187 140 189 93 191 78 179 72 211 49 209 48 181 37 149 25 120 25 89 45 72 103 84 179 75 198 76 252 64 272 81 293 103 285 121 255 121 242 118 224 167 Polygon -7500403 true true 73 210 86 251 62 249 48 208 Polygon -7500403 true true 25 114 16 195 9 204 23 213 25 200 39 123 cylinder false 0 Circle -7500403 true true 0 0 300 dot false 0 Circle -7500403 true true 90 90 120 face happy false 0 Circle -7500403 true true 8 8 285 Circle -16777216 true false 60 75 60 Circle -16777216 true false 180 75 60 Polygon -16777216 true false 150 255 90 239 62 213 47 191 67 179 90 203 109 218 150 225 192 218 210 203 227 181 251 194 236 217 212 240 face neutral false 0 Circle -7500403 true true 8 7 285 Circle -16777216 true false 60 75 60 Circle -16777216 true false 180 75 60 Rectangle -16777216 true false 60 195 240 225 face sad false 0 Circle -7500403 true true 8 8 285 Circle -16777216 true false 60 75 60 Circle -16777216 true false 180 75 60 Polygon -16777216 true false 150 168 90 184 62 210 47 232 67 244 90 220 109 205 150 198 192 205 210 220 227 242 251 229 236 206 212 183 fish false 0 Polygon -1 true false 44 131 21 87 15 86 0 120 15 150 0 180 13 214 20 212 45 166 Polygon -1 true false 135 195 119 235 95 218 76 210 46 204 60 165 Polygon -1 true false 75 45 83 77 71 103 86 114 166 78 135 60 Polygon -7500403 true true 30 136 151 77 226 81 280 119 292 146 292 160 287 170 270 195 195 210 151 212 30 166 Circle -16777216 true false 215 106 30 flag false 0 Rectangle -7500403 true true 60 15 75 300 Polygon -7500403 true true 90 150 270 90 90 30 Line -7500403 true 75 135 90 135 Line -7500403 true 75 45 90 45 flower false 0 Polygon -10899396 true false 135 120 165 165 180 210 180 240 150 300 165 300 195 240 195 195 165 135 Circle -7500403 true true 85 132 38 Circle -7500403 true true 130 147 38 Circle -7500403 true true 192 85 38 Circle -7500403 true true 85 40 38 Circle -7500403 true true 177 40 38 Circle -7500403 true true 177 132 38 Circle -7500403 true true 70 85 38 Circle -7500403 true true 130 25 38 Circle -7500403 true true 96 51 108 Circle -16777216 true false 113 68 74 Polygon -10899396 true false 189 233 219 188 249 173 279 188 234 218 Polygon -10899396 true false 180 255 150 210 105 210 75 240 135 240 house false 0 Rectangle -7500403 true true 45 120 255 285 Rectangle -16777216 true false 120 210 180 285 Polygon -7500403 true true 15 120 150 15 285 120 Line -16777216 false 30 120 270 120 leaf false 0 Polygon -7500403 true true 150 210 135 195 120 210 60 210 30 195 60 180 60 165 15 135 30 120 15 105 40 104 45 90 60 90 90 105 105 120 120 120 105 60 120 60 135 30 150 15 165 30 180 60 195 60 180 120 195 120 210 105 240 90 255 90 263 104 285 105 270 120 285 135 240 165 240 180 270 195 240 210 180 210 165 195 Polygon -7500403 true true 135 195 135 240 120 255 105 255 105 285 135 285 165 240 165 195 line true 0 Line -7500403 true 150 0 150 300 line half true 0 Line -7500403 true 150 0 150 150 pentagon false 0 Polygon -7500403 true true 150 15 15 120 60 285 240 285 285 120 person false 0 Circle -7500403 true true 110 5 80 Polygon -7500403 true true 105 90 120 195 90 285 105 300 135 300 150 225 165 300 195 300 210 285 180 195 195 90 Rectangle -7500403 true true 127 79 172 94 Polygon -7500403 true true 195 90 240 150 225 180 165 105 Polygon -7500403 true true 105 90 60 150 75 180 135 105 plant false 0 Rectangle -7500403 true true 135 90 165 300 Polygon -7500403 true true 135 255 90 210 45 195 75 255 135 285 Polygon -7500403 true true 165 255 210 210 255 195 225 255 165 285 Polygon -7500403 true true 135 180 90 135 45 120 75 180 135 210 Polygon -7500403 true true 165 180 165 210 225 180 255 120 210 135 Polygon -7500403 true true 135 105 90 60 45 45 75 105 135 135 Polygon -7500403 true true 165 105 165 135 225 105 255 45 210 60 Polygon -7500403 true true 135 90 120 45 150 15 180 45 165 90 sheep false 0 Rectangle -7500403 true true 151 225 180 285 Rectangle -7500403 true true 47 225 75 285 Rectangle -7500403 true true 15 75 210 225 Circle -7500403 true true 135 75 150 Circle -16777216 true false 165 76 116 square false 0 Rectangle -7500403 true true 30 30 270 270 square 2 false 0 Rectangle -7500403 true true 30 30 270 270 Rectangle -16777216 true false 60 60 240 240 star false 0 Polygon -7500403 true true 151 1 185 108 298 108 207 175 242 282 151 216 59 282 94 175 3 108 116 108 target false 0 Circle -7500403 true true 0 0 300 Circle -16777216 true false 30 30 240 Circle -7500403 true true 60 60 180 Circle -16777216 true false 90 90 120 Circle -7500403 true true 120 120 60 tree false 0 Circle -7500403 true true 118 3 94 Rectangle -6459832 true false 120 195 180 300 Circle -7500403 true true 65 21 108 Circle -7500403 true true 116 41 127 Circle -7500403 true true 45 90 120 Circle -7500403 true true 104 74 152 triangle false 0 Polygon -7500403 true true 150 30 15 255 285 255 triangle 2 false 0 Polygon -7500403 true true 150 30 15 255 285 255 Polygon -16777216 true false 151 99 225 223 75 224 truck false 0 Rectangle -7500403 true true 4 45 195 187 Polygon -7500403 true true 296 193 296 150 259 134 244 104 208 104 207 194 Rectangle -1 true false 195 60 195 105 Polygon -16777216 true false 238 112 252 141 219 141 218 112 Circle -16777216 true false 234 174 42 Rectangle -7500403 true true 181 185 214 194 Circle -16777216 true false 144 174 42 Circle -16777216 true false 24 174 42 Circle -7500403 false true 24 174 42 Circle -7500403 false true 144 174 42 Circle -7500403 false true 234 174 42 turtle true 0 Polygon -10899396 true false 215 204 240 233 246 254 228 266 215 252 193 210 Polygon -10899396 true false 195 90 225 75 245 75 260 89 269 108 261 124 240 105 225 105 210 105 Polygon -10899396 true false 105 90 75 75 55 75 40 89 31 108 39 124 60 105 75 105 90 105 Polygon -10899396 true false 132 85 134 64 107 51 108 17 150 2 192 18 192 52 169 65 172 87 Polygon -10899396 true false 85 204 60 233 54 254 72 266 85 252 107 210 Polygon -7500403 true true 119 75 179 75 209 101 224 135 220 225 175 261 128 261 81 224 74 135 88 99 wheel false 0 Circle -7500403 true true 3 3 294 Circle -16777216 true false 30 30 240 Line -7500403 true 150 285 150 15 Line -7500403 true 15 150 285 150 Circle -7500403 true true 120 120 60 Line -7500403 true 216 40 79 269 Line -7500403 true 40 84 269 221 Line -7500403 true 40 216 269 79 Line -7500403 true 84 40 221 269 wolf false 0 Polygon -7500403 true true 135 285 195 285 270 90 30 90 105 285 Polygon -7500403 true true 270 90 225 15 180 90 Polygon -7500403 true true 30 90 75 15 120 90 Circle -1 true false 183 138 24 Circle -1 true false 93 138 24 x false 0 Polygon -7500403 true true 270 75 225 30 30 225 75 270 Polygon -7500403 true true 30 75 75 30 270 225 225 270 @#$#@#$#@ NetLogo 5.1.0 @#$#@#$#@ @#$#@#$#@ @#$#@#$#@ <experiments> <experiment name="exp" repetitions="50" runMetricsEveryStep="true"> <setup>setup</setup> <go>go</go> <timeLimit steps="500"/> <metric>gini-index-reserve</metric> <metric>gini-index-patch</metric> <metric>meanQualityTotal</metric> <metric>meanQualityMountain</metric> <metric>meanQualityPlain</metric> <metric>DiffExtCentral</metric> <metric>nbcentralPlots</metric> <metric>meanPatchByNetwork</metric> <metric>sum [quality] of patches with [owner != -9999 and alti &lt; 0.1]</metric> <metric>sum [quality] of patches with [owner != -9999 and alti &gt;= 0.1]</metric> <enumeratedValueSet variable="export"> <value value="false"/> </enumeratedValueSet> <enumeratedValueSet variable="downerQ"> <value value="0.15"/> </enumeratedValueSet> <steppedValueSet variable="coefUpQuality" first="0.01" step="0.01" last="0.06"/> <enumeratedValueSet variable="chooseMode"> <value value="true"/> </enumeratedValueSet> <enumeratedValueSet variable="demandF"> <value value="0"/> <value value="2000"/> <value value="7000"/> </enumeratedValueSet> <enumeratedValueSet variable="nbfrich"> <value value="1"/> </enumeratedValueSet> <enumeratedValueSet variable="nbPLots"> <value value="7"/> </enumeratedValueSet> <enumeratedValueSet variable="standarDevPop"> <value value="2"/> </enumeratedValueSet> <enumeratedValueSet variable="nbCitys"> <value value="10"/> </enumeratedValueSet> <enumeratedValueSet variable="whatWord"> <value value="0"/> <value value="1"/> <value value="2"/> </enumeratedValueSet> <enumeratedValueSet variable="priceMaxWineF"> <value value="60"/> </enumeratedValueSet> <enumeratedValueSet variable="choceOnDist"> <value value="true"/> <value value="false"/> </enumeratedValueSet> <enumeratedValueSet variable="marketColor"> <value value="true"/> </enumeratedValueSet> </experiment> <experiment name="stability" repetitions="50000" runMetricsEveryStep="false"> <setup>setup</setup> <go>go</go> <timeLimit steps="500"/> <metric>gini-index-reserve</metric> <metric>gini-index-patch</metric> <metric>meanQualityTotal</metric> <metric>meanQualityMountain</metric> <metric>meanQualityPlain</metric> <metric>DiffExtCentral</metric> <metric>nbcentralPlots</metric> <metric>meanPatchByNetwork</metric> <metric>sum [quality] of patches with [owner != -9999 and alti &lt; 0.1]</metric> <metric>sum [quality] of patches with [owner != -9999 and alti &gt;= 0.1]</metric> <enumeratedValueSet variable="export"> <value value="false"/> </enumeratedValueSet> <enumeratedValueSet variable="downerQ"> <value value="0.5"/> </enumeratedValueSet> <enumeratedValueSet variable="coefUpQuality"> <value value="0.01"/> </enumeratedValueSet> <enumeratedValueSet variable="chooseMode"> <value value="false"/> </enumeratedValueSet> <enumeratedValueSet variable="demandF"> <value value="7000"/> </enumeratedValueSet> <enumeratedValueSet variable="nbPLots"> <value value="10"/> </enumeratedValueSet> <enumeratedValueSet variable="standarDevPop"> <value value="2"/> </enumeratedValueSet> <enumeratedValueSet variable="nbCitys"> <value value="10"/> </enumeratedValueSet> <enumeratedValueSet variable="whatWord"> <value value="0"/> </enumeratedValueSet> <enumeratedValueSet variable="priceMaxWineF"> <value value="70"/> </enumeratedValueSet> <enumeratedValueSet variable="marketColor"> <value value="false"/> </enumeratedValueSet> </experiment> </experiments> @#$#@#$#@ @#$#@#$#@ default 0.0 -0.2 0 0.0 1.0 0.0 1 1.0 0.0 0.2 0 0.0 1.0 link direction true 0 Line -7500403 true 150 150 90 180 Line -7500403 true 150 150 210 180 @#$#@#$#@ 1 @#$#@#$#@
NetLogo
5
ajnavarro/language-dataset
data/github.com/ElCep/dion_still_alive/ca1df17bfbb2872b4423e4afec5a6ac6e81c00ce/Dion.1952V2.nlogo
[ "MIT" ]
Library "Roku_Ads.brs" ' ********** Copyright 2016 Roku Corp. All Rights Reserved. ********** 'Roku Advertising Framework for Video Ads Main Entry Point 'Creation and configuration of list menu and video screens. sub Main() screen = CreateObject("roSGScreen") m.port = CreateObject("roMessagePort") screen.setMessagePort(m.port) m.scene = screen.CreateScene("VideoScene") screen.show() 'AA for base video, ad and Nielsen configuration. 'For additional information please see official RAF documentation. m.videoContent = { streamFormat : "mp4", 'Lengthy (20+ min.) TED talk to allow time for testing ad pods stream: { url: "http://video.ted.com/talks/podcast/DavidKelley_2002_480.mp4", bitrate: 800, quality: false } 'Provider ad url, can be configurable with URL Parameter Macros. 'Some parameter values can be substituted dinamicly in ad request and tracking URLs. 'For example: ROKU_ADS_APP_ID - Identifies the client application making the ad request. adUrl: "http://1c6e2.v.fwmrm.net/ad/g/1?nw=116450&ssnw=116450&asnw=116450&caid=493509699603&csid=fxn_shows_roku&prof=116450:Fox_Live_Roku&resp=vast&metr=1031&flag=+exvt+emcr+sltp&;_fw_ae=d8b58f7bfce28eefcc1cdd5b95c3b663;app_id=ROKU_ADS_APP_ID", contentId: "TED", 'String value representing content to allow potential ad targeting. contentGenre: "General Variety", 'Comma-delimited string or array of genre tag strings. conntentLength: "1200", 'Integer value representing total length of content (in seconds). nielsenProgramId: "CBAA", 'String identifying content program for Nielsen DAR tags. nielsenAppId: "P2871BBFF-1A28-44AA-AF68-C7DE4B148C32", 'String identifying Nielsen-assigned application ID. nielsenGenre: "GV" 'String identifying primary content genre for Nielsen DAR tags. ' path to the file containing non-standard ads feed nonStandardAdsFilePath: "pkg:/feed/ads_nonstandard.json" } 'Array of AA for main menu bulding. m.contentList = [ { Title: "Default Ad Buffering Screen", playWithRaf: PlayContentWithFullRAFIntegration }, { Title: "Message disabled", playWithRaf: PlayContentWithFullRAFIntegration }, { Title: "Progress bar disabled", playWithRaf: PlayContentWithFullRAFIntegration }, { Title: "Custom background", playWithRaf: PlayContentWithFullRAFIntegration }, { Title: "... and poster", playWithRaf: PlayContentWithFullRAFIntegration }, { Title: "... and title with description", playWithRaf: PlayContentWithFullRAFIntegration } { Title: "Custom screen with callbacks", playWithRaf: PlayContentWithFullRAFIntegration } ] 'menu list node m.list = m.scene.findNode("MenuList") m.list.ObserveField("itemSelected", m.port) 'video node m.video = m.scene.FindNode("MainVideo") m.video.observeField("position", m.port) m.video.observeField("state", m.port) m.video.observeField("navBack", m.port) 'content node for video node contentVideoNode = CreateObject("RoSGNode", "ContentNode") contentVideoNode.URL= m.videoContent.stream.url m.video.content = contentVideoNode 'main facade creation. m.loading = m.scene.FindNode("LoadingScreen") m.loadingText = m.loading.findNode("LoadingScreenText") 'menu content m.content = createObject("RoSGNode","ContentNode") 'Populating menu with items and setting it to LabelList content addSection("") for each item in m.contentList addItem(item.title) end for m.list.content = m.content 'main while loop while(true) msg = wait(0, m.port) msgType = type(msg) if msgType = "roSGScreenEvent" if msg.isScreenClosed() then return else if msgType = "roSGNodeEvent" if (msg.GetField() = "itemSelected") menuItemTitle = m.contentList[m.list.itemSelected].title m.video.infoLabelText = "RAF sample: " + menuItemTitle 'showing facade m.list.visible = false m.loadingText.text = menuItemTitle m.loading.visible = true m.loading.setFocus(true) 'wait for 0.5 second before proceeding to RAF sleep(500) 'calling proper method based on list item selected from main menu playWithRaf = m.contentList[m.list.itemSelected].playWithRaf playWithRaf(m.list.itemSelected) 'showing main menu m.list.visible = true m.video.visible = false m.list.setFocus(true) end if end if end while end sub 'Add section for list items menu grouping. '@param sectiontext [String] title of the section. sub addSection(sectiontext as string) m.sectionContent = m.content.createChild("ContentNode") m.sectionContent.CONTENTTYPE = "SECTION" m.sectionContent.TITLE = sectiontext end sub 'Add item to list menu. '@param itemtext [String] title of the item. sub addItem(itemtext as string) item = m.sectionContent.createChild("ContentNode") item.title = itemtext end sub 'Video events handling. '@param position [Integer] video position. '@param completed [Boolean] flag if video is completed '@param started [Boolean] flag if video is started '@return [AA] object of video event in structured format. function createPlayPosMsg(position as Integer, completed = false as Boolean, started = false as Boolean) as Object videoEvent = { pos: position, done: completed, started: started, isStreamStarted : function () as Boolean return m.started end function, isFullResult : function () as Boolean return m.done end function, isPlaybackPosition : function () as Boolean return true end function, getIndex : function() as Integer return m.pos end function } return videoEvent end function
Brightscript
5
khangh/samples
advertising/CustomBufferScreenSceneGraphSample/source/main.brs
[ "MIT" ]
# <API name> <API description> # Data Structures ## Address (object) mixin w/ description ### Properties - city - street ## User (object) - id - Include Address - nick
API Blueprint
2
darkcl/drafter
test/fixtures/mson/mixin.apib
[ "MIT" ]
@import '../../style/themes/index'; @import '../../style/mixins/index'; @import '../../button/style/mixin'; @import './mixin'; @search-prefix: ~'@{ant-prefix}-input-search'; .@{search-prefix} { .@{ant-prefix}-input { &:hover, &:focus { border-color: @input-hover-border-color; + .@{ant-prefix}-input-group-addon .@{search-prefix}-button:not(.@{ant-prefix}-btn-primary) { border-left-color: @input-hover-border-color; } } } .@{ant-prefix}-input-affix-wrapper { border-radius: 0; } // fix slight height diff in Firefox: // https://ant.design/components/auto-complete-cn/#components-auto-complete-demo-certain-category .@{ant-prefix}-input-lg { line-height: @line-height-base - 0.0002; } > .@{ant-prefix}-input-group { > .@{ant-prefix}-input-group-addon:last-child { left: -1px; padding: 0; border: 0; .@{search-prefix}-button { padding-top: 0; padding-bottom: 0; border-radius: 0 @border-radius-base @border-radius-base 0; } .@{search-prefix}-button:not(.@{ant-prefix}-btn-primary) { color: @text-color-secondary; &.@{ant-prefix}-btn-loading::before { top: 0; right: 0; bottom: 0; left: 0; } } } } &-button { height: @input-height-base; &:hover, &:focus { z-index: 1; } } &-large &-button { height: @input-height-lg; } &-small &-button { height: @input-height-sm; } }
Less
4
noctis0430-open-source/ant-design-blazor
components/input/style/search-input.less
[ "MIT" ]
// Copyright 2017 The Go Authors. All rights reserved. // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. // +build !plan9,!windows #include <stdint.h> uint32_t threadExited; void setExited(void *x) { __sync_fetch_and_add(&threadExited, 1); }
C
4
Havoc-OS/androidprebuilts_go_linux-x86
src/runtime/testdata/testprogcgo/lockosthread.c
[ "BSD-3-Clause" ]
// not compliant component{ function x(){ var myStruct = { "myKey" = { mySubKey = "123" } }; } }
ColdFusion CFC
1
tonym128/CFLint
src/test/resources/com/cflint/tests/StructKeyChecker/unquotedStructKeyNested.cfc
[ "BSD-3-Clause" ]
--TEST-- Test substr_replace() function : error conditions --FILE-- <?php /* * Testing substr_replace() for error conditions */ echo "*** Testing substr_replace() : error conditions ***\n"; $s1 = "Good morning"; echo "\n-- Testing substr_replace() function with start and length as arrays but string not--\n"; try { var_dump(substr_replace($s1, "evening", array(5))); } catch (TypeError $e) { echo $e->getMessage(), "\n"; } try { var_dump(substr_replace($s1, "evening", 5, array(1))); } catch (TypeError $e) { echo $e->getMessage(), "\n"; } ?> --EXPECT-- *** Testing substr_replace() : error conditions *** -- Testing substr_replace() function with start and length as arrays but string not-- substr_replace(): Argument #3 ($offset) cannot be an array when working on a single string substr_replace(): Argument #4 ($length) cannot be an array when working on a single string
PHP
4
NathanFreeman/php-src
ext/standard/tests/strings/substr_replace_error.phpt
[ "PHP-3.01" ]