text stringlengths 84 499k | source stringclasses 6
values | slice stringclasses 1
value | est_tokens int32 24 143k | score float32 |
|---|---|---|---|---|
#include "unity.h"
#include "Types.h"
#include "TimerConductor.h"
#include "MockTimerHardware.h"
#include "MockTimerModel.h"
#include "MockTimerInterruptHandler.h"
void setUp(void)
{
}
void tearDown(void)
{
}
void testInitShouldCallHardwareInit(void)
{
TimerHardware_Init_Expect();
TimerConductor_Init();
}
void... | code_c | code | 174 | null |
<reponame>dvm-system/tsar-test
int foo(int a){
return a--;
}
int main(){
int x = 50;
while(x >0){
#pragma spf transform inline
x = foo(x);
}
return 0;
}
| code_c | code | 47 | null |
<filename>ElegantDragon/include/graphic_api_interface/VertexBufferLayout.h
#pragma once
#include <GL/glew.h>
#include <vector>
#include "projectDefines.h"
struct VertexBufferElement
{
unsigned int type;
unsigned int count;
unsigned char normalized;
static unsigned int getSizeOfType(unsigned int type... | code_c | code | 571 | null |
<reponame>iocafe/iocom
/**
@file ioc_dyn_signal.h
@brief Dynamically maintain IO network objects.
@author <NAME>
@version 1.0
@date 26.4.2021
The dynamic signal is extended signal structure, which is part of dynamic IO network
information.
Copyright 2020 <NAME>. This file is part of the ioco... | code_c | code | 1,008 | null |
//---------------------------------------------------------------------------------
// Copyright (C) 2001 <NAME>
//
// This program is free software; you can redistribute it and/or
// modify it under the terms of the Clarified Artistic License.
// In addition, to meet copyright restrictions you must also own at ... | code_c | code | 500 | null |
#pragma once
// <ip> Local accessors
#include "SYCL/access.h"
#include "SYCL/accessor.h"
#include "SYCL/accessors/device_reference.h"
#include "SYCL/buffer.h"
#include "SYCL/command_group.h"
#include "SYCL/detail/common.h"
#include "SYCL/detail/counter.h"
#include "SYCL/ranges.h"
namespace cl {
namespace sycl {
na... | code_c | code | 867 | null |
#pragma once
#include "doc/DocListener.h"
#include "charset/CodeBase.h"
class DocLineMgr;
struct SaveInfo;
class WriteManager : public ProgressSubject {
public:
CodeConvertResult WriteFile_From_CDocLineMgr(
const DocLineMgr& pcDocLineMgr, // [in]
const SaveInfo& saveInfo // [in]
);
};
| code_c | code | 89 | null |
/*
* Copyright (c) 2017 Nuvoton Technology Corp.
*
* See file CREDITS for list of people who contributed to this
* project.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either vers... | code_c | code | 1,190 | null |
//
// AKHelpers.h
// AnimationKit
//
// Created by nikan on 12/1/10.
// Copyright 2010 <NAME>. All rights reserved.
//
#import <Foundation/Foundation.h>
@interface AKHelpers : NSObject {
}
+ (CCSpriteFrame*)frameFromFile:(NSString*)file;
+ (NSArray*)imageFramesFromArray:(NSArray*)array;
+ (NSArray*)imageFrames... | code_c | code | 521 | null |
<filename>Singapore Travel Mate/Explore Singapore Tab/View/PlaceTableViewCell.h
//
// PlaceTableViewCell.h
// Singapore Travel Mate
//
// Created by <NAME> on 14/07/20.
// Copyright © 2020 <NAME>. All rights reserved.
//
#import <UIKit/UIKit.h>
#import "PlaceTableViewCellViewModel.h"
#import "PlaceTableViewCellPro... | code_c | code | 216 | null |
<gh_stars>10-100
/* SPDX-License-Identifier: BSD-3-Clause
* Copyright(c) 2017 Intel Corporation
*/
#ifndef _RTE_ETHDEV_DRIVER_H_
#define _RTE_ETHDEV_DRIVER_H_
/**
* @file
*
* RTE Ethernet Device PMD API
*
* These APIs for the use from Ethernet drivers, user applications shouldn't
* use them.
*
*/
#include ... | code_c | code | 968 | null |
// Copyright 2016 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef COMPONENTS_SAFE_BROWSING_CORE_FILE_TYPE_POLICIES_H_
#define COMPONENTS_SAFE_BROWSING_CORE_FILE_TYPE_POLICIES_H_
#include <map>
#include <memory>
... | code_c | code | 1,564 | null |
<reponame>rasidin/LimitEngineV2<filename>source/Platform/DirectX12/PrivateDefinitions_DirectX12.h
/*********************************************************************
Copyright (c) 2020 LIMITGAME
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentatio... | code_c | code | 2,020 | null |
<filename>src/vppinfra/clib_error.h
/*
* Copyright (c) 2015 Cisco and/or its affiliates.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.... | code_c | code | 278 | null |
<filename>llvm/tools/llvm-cov/CoverageViewOptions.h
//===- CoverageViewOptions.h - Code coverage display options -------------===//
//
// The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----... | code_c | code | 455 | null |
/****************************************************************************
**
** Copyright (C) 2017 TU Wien, ACIN, Vision 4 Robotics (V4R) group
** Contact: v4r.acin.tuwien.ac.at
**
** This file is part of V4R
**
** V4R is distributed under dual licenses - GPLv3 or closed source.
**
** GNU General Public License Usa... | code_c | code | 1,439 | null |
<filename>VPN/shadowsocks/VPN/yinyong/GCDWebServer/Polipo-iOS-master/libhttptunnel/acconfig.h
/* Enable debugging mode. */
#undef DEBUG_MODE
@BOTTOM@
/* Define to 'int' if <sys/socket.h> doesn't define. */
#undef socklen_t
/* Define to 0xffffffff if <netinet/in.h> doesn't define. */
#undef INADDR_NONE
| code_c | code | 87 | null |
<reponame>ghsecuritylab/Android-7.0
/*
* Copyright (c) 2008-2016 Allwinner Technology Co. Ltd.
* All rights reserved.
*
* File : omx_tsem.c
*
* Description : pthread operation
* History :
*
*/
#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */
#include <pthread.h>
#include <sys/time.h>
#include <errno.... | code_c | code | 732 | null |
/*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applic... | code_c | code | 2,693 | null |
#pragma once
#include "coord-circle.h"
#include "los-type.h"
#include <vector>
using std::vector;
class rectangle_iterator : public iterator<forward_iterator_tag, coord_def>
{
public:
rectangle_iterator(const coord_def& corner1, const coord_def& corner2);
rectangle_iterator(const coord_def& center, int half... | code_c | code | 1,388 | null |
// Licensed to the Apache Software Foundation (ASF) under one
// or more contributor license agreements. See the NOTICE file
// distributed with this work for additional information
// regarding copyright ownership. The ASF licenses this file
// to you under the Apache License, Version 2.0 (the
// "License"); you may... | code_c | code | 985 | null |
<reponame>johans1jo/TTK4235-Heislab
#pragma once
// Wrapper for libComedi Elevator control.
// These functions provides an interface to the elevators in the real time lab
//
// 2007, <NAME>
#ifndef __INCLUDE_DRIVER_H__
#define __INCLUDE_DRIVER_H__
// Number of floors
#define N_FLOORS 4
/**
Initial... | code_c | code | 780 | null |
<filename>src/tif/tiffconf.h<gh_stars>0
/* $Header: /usr/people/sam/tiff/libtiff/RCS/tiffconf.h,v 1.2 92/11/09 11:10:08 sam Exp $ */
/*
* Copyright (c) 1988, 1989, 1990, 1991, 1992 <NAME>ler
* Copyright (c) 1991, 1992 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and... | code_c | code | 1,290 | null |
#include <libopticon/var_parse.h>
#include <libopticon/var_dump.h>
#include <libopticon/log.h>
#include <stdio.h>
#include <string.h>
#include <assert.h>
void test_input (const char *txt) {
var *env = var_alloc();
var *env_collector = NULL;
var *env_colors = NULL;
const char *tstr;
assert (var_pars... | code_c | code | 700 | null |
#include <stdio.h>
#include <string.h>
#include <stdint.h>
#include "mbedtls/dhm.h"
#include "mbedtls/entropy.h"
#include "mbedtls/ctr_drbg.h"
#include "mbedtls/platform.h"
#define assert_exit(cond, ret) \
do { if (!(cond)) { \
printf(" !. assert: failed [line: %d, error: -0x%04X]\n", __LINE__, -ret); \
... | code_c | code | 1,406 | null |
/* $NetBSD: bus_defs.h,v 1.10 2014/01/29 00:42:15 matt Exp $ */
/*-
* Copyright (c) 1996, 1997, 1998, 2001 The NetBSD Foundation, Inc.
* All rights reserved.
*
* This code is derived from software contributed to The NetBSD Foundation
* by <NAME> of the Numerical Aerospace Simulation Facility,
* NASA Ames Researc... | code_c | code | 5,034 | null |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* Development of the code in this file was sponsored by Microbric Pty Ltd
*
* The MIT License (MIT)
*
* Copyright (c) 2013-2015 <NAME>
* Copyright (c) 2016 <NAME>
*
* Permission is hereby granted, free of charge, to any person obtain... | code_c | code | 4,838 | null |
<filename>BasicLight/include/glpch.h
#pragma once
// Defaults
#include <iostream>
#include <memory>
#include <string>
#include <fstream>
#include <sstream>
#include <utility>
#include <algorithm>
#include <functional>
#include <vector>
#include <unordered_map>
#include <unordered_map>
#include <unordered_set>
// Depe... | code_c | code | 116 | null |
/*
* This file is part of the GROMACS molecular simulation package.
*
* Copyright (c) 2020,2021, by the GROMACS development team, led by
* <NAME>, <NAME>, <NAME>, and <NAME>,
* and including many others, as listed in the AUTHORS file in the
* top-level source directory and at http://www.gromacs.org.
*
* GROMACS... | code_c | code | 1,864 | null |
<reponame>ashxz47/oai5g
/*
* Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The OpenAirInterface Software Alliance licenses this file to You und... | code_c | code | 41,760 | null |
<gh_stars>0
#ifndef SUDOKU_H_JTU2YWOL
#define SUDOKU_H_JTU2YWOL
#include <stdlib.h>
#include <stdbool.h>
#include <stdint.h>
typedef uint8_t val_t;
typedef uint32_t sz_t;
typedef enum {
INVALID,
MULTIPLE,
INCOMPLETE,
COMPLETE
} sudoku_res_t;
typedef struct _sudoku_t {
val_t *table;
sz_t n, n_e2, n_e4;
... | code_c | code | 542 | null |
#define FRONTGATE
#define NODEID 9 //frontgate unique for each node on same network
// limit switches currently fitted to front gate only.
#define PROXIMITY_FITTED
// #define BACKGATE
// the battery adc sense uses a 404k resistor and 100k, for attenuation of 0.198.
// Alternatively using the 3v3 rail as r... | code_c | code | 222 | null |
/* Based on src/fontfile/gunzip.c
written by <NAME> <<EMAIL>> September 1996.
intended for inclusion in X11 public releases. */
/*
* Copyright (c) 2008, Oracle and/or its affiliates. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and a... | code_c | code | 1,410 | null |
//
// JHCAppDelegate.h
// JHCToastHud
//
// Created by jihengcong on 01/13/2022.
// Copyright (c) 2022 jihengcong. All rights reserved.
//
@import UIKit;
@interface JHCAppDelegate : UIResponder <UIApplicationDelegate>
@property (strong, nonatomic) UIWindow *window;
@end
| code_c | code | 79 | null |
<gh_stars>10-100
/* The smooth Class Library
* Copyright (C) 1998-2009 <NAME> <<EMAIL>>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of "The Artistic License, Version 2.0".
*
* THIS PACKAGE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR
* IMPLIED WA... | code_c | code | 275 | null |
<gh_stars>1-10
@import Foundation;
#import "FDObjectTransformerAdapter.h"
#pragma mark - Class Interface
@interface FDDictionaryToObjectAdapter : NSObject
<
FDObjectTransformerAdapter
>
@end | code_c | code | 56 | null |
// Copyright (c) 2009-2010 <NAME>
// Copyright (c) 2009-2013 The WaykiChain developers
// Copyright (c) 2016 The Coin developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#ifndef COIN_TXDB_LEVELDB_H
#define COIN_TXDB_L... | code_c | code | 1,482 | null |
<reponame>simon-i1-h/myprintf<filename>test.c<gh_stars>0
#include <limits.h>
#include <stdio.h>
#include "myprintf.h"
int
main(void)
{
int r = myprintf("hello.\n");
printf("r: %d\n", r);
myprintf("percent: %%\n");
myprintf("answer: %d\n", 0);
myprintf("answer: %d\n", 42);
myprintf("answer: %d\n", INT_MAX);
... | code_c | code | 121 | null |
/*
** Copyright 2022 Open STEMware Foundation
** All Rights Reserved.
**
** This program is free software; you can modify and/or redistribute it under
** the terms of the GNU Affero General Public License as published by the Free
** Software Foundation; version 3 with attribution addendums as found in the
** LICE... | code_c | code | 1,318 | null |
/*******************************************************************************
* mobilebot.c
* Template Code
*
* This code is a template for completing a fully featured
* mobile robot controller
*
* Functions that need completing are marked with "TODO:"
*
***************************************... | code_c | code | 4,485 | null |
<reponame>Miaocool/MYG-NewVersion<gh_stars>0
//
// ProblemViewController.h
// yyxb
//
// Created by 杨易 on 15/11/11.
// Copyright (c) 2015年 杨易. All rights reserved.
//
#import "MaiViewController.h"
@interface ProblemViewController : MaiViewController
@end
| code_c | code | 74 | null |
<filename>libs/ms/inc/ms/util/parameter.h
#pragma once
#include "util/exported.h"
#include "util/support.h"
#include <stdexcept>
#if( defined( __GNUC__ ) && ( __GNUC__ < 8 ) ) && !( defined( __clang__ ) && ( __clang_major__ >= 10 ) )
#include <experimental/filesystem>
namespace fs = std::experimental::filesystem;
#el... | code_c | code | 17,563 | null |
/*
+----------------------------------------------------------------------+
| HipHop for PHP |
+----------------------------------------------------------------------+
| Copyright (c) 2010 Facebook, Inc. (http://www.facebook.com) |
+---------... | code_c | code | 603 | null |
/*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
#import <Foundation/Foundation.h>
#import <ABI43_0_0React/ABI43_0_0RCTAssert.h>
#import <ABI43_0_0React/ABI43_0_0RCTDefines.h>
#im... | code_c | code | 1,498 | null |
#pragma once
#include <utility>
#include "problem.h"
namespace VRP
{
struct LossMetrics
{
double dist; // distance
double time;
double load, maxLoad;
double penalty;
LossMetrics() :dist(0), time(0), load(0), maxLoad(0), penalty(0) {}
/// <summary>
/// merge the loss of two trips of one vehicle
/... | code_c | code | 372 | null |
<filename>tools/bin2c.c
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int main(int argc, char *argv[])
{
char base[1024], opath[1024], *name, *p;
FILE *ifp, *ofp;
int byte, cnt;
if (argc < 2 || argc > 3) {
fprintf(stderr, "usage: bin2c <infile> [ <outfile> ]\n");
... | code_c | code | 399 | null |
#ifndef __SIMPLE_STATS_
#define __SIMPLE_STATS_
#include <fstream>
#include <string>
#include <unordered_map>
#include <vector>
#include "configuration.h"
#include "json.hpp"
namespace dramsim3 {
class SimpleStats {
public:
SimpleStats(const Config& config, int channel_id);
// incrementing counter
vo... | code_c | code | 1,026 | null |
<filename>Fake Binary/fakebin.c
/* ************************************************************************** */
/* */
/* :::::::: */
/* fakebin.c ... | code_c | code | 437 | null |
<filename>Problema-I/problema 1.c
/***************************
Autor: <NAME>
Componente Curricular: Algoritmos I
Concluido em: 14/10/2017
Declaro que este c�digo foi elaborado por mim de forma individual e n�o cont�m nenhum
trecho de c�digo de outro colega ou de outro autor, tais como provindos de livros e
apostilas, e... | code_c | code | 3,530 | null |
/** @file
This Protocol provides services to register a platform specific reset filter
for ResetSystem(). A reset filter evaluates the parameters passed to
ResetSystem() and converts a ResetType of EfiResetPlatformSpecific to a
non-platform specific reset type. The registered filters are processed before
th... | code_c | code | 369 | null |
#pragma once
#define DELTA_CUDA_VERSION_MAJOR 0
#define DELTA_CUDA_VERSION_MINOR 1
#define DELTA_CUDA "Delta Cuda Video Decoder"
/////////////////////////////////////////////////////////
#define DO_MAKE_STR(x) #x
#define MAKE_STR(x) DO_MAKE_STR(x)
#define DELTA_CUDA_VERSION DELTA_CUDA_VERSION_MAJOR.DELTA_CUDA_VERSI... | code_c | code | 134 | null |
// SPDX-License-Identifier: GPL-2.0-or-later
/*
* Apple "Magic" Wireless Mouse driver
*
* Copyright (c) 2010 <NAME> <<EMAIL>>
* Copyright (c) 2010 <NAME> <<EMAIL>>
*/
/*
*/
#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
#include <linux/device.h>
#include <linux/hid.h>
#include <linux/input/mt.h>
#include <l... | code_c | code | 6,230 | null |
<reponame>OpenInkpot/attic-ewl<gh_stars>0
/* vim: set sw=8 ts=8 sts=8 expandtab: */
#include "Ewl_Test.h"
#include "ewl_test_private.h"
#include "ewl_filedialog.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
static int test_constructor(char *buf, int len);
Ewl_Unit_Test filedialog_unit_tests[] = {
... | code_c | code | 784 | null |
<gh_stars>1-10
#pragma once
#ifdef PIXELBOOST_PLATFORM_NACL
#include <string>
namespace pb
{
class NetworkMessage;
class GameCenterDelegate
{
public:
virtual void MatchStarted();
virtual void MatchStopped();
virtual void PlayerConnected(std::string playerId);
virtual void PlayerDisconnected... | code_c | code | 383 | null |
<reponame>roycrippen/sicxe<filename>src/fpga/loader.h
#ifndef FPGA_LOADER_H
#define FPGA_LOADER_H
#include "common/macros.h"
namespace sicxe {
class ObjectFile;
namespace fpga {
class FpgaConnection;
class FpgaLoader {
public:
DISALLOW_INSTANTIATE(FpgaLoader);
static bool LoadObjectFile(const ObjectFile& ob... | code_c | code | 123 | null |
<reponame>eharrison/AwesomeData
//
// AwesomeData-watchOS.h
// AwesomeData-watchOS
//
// Created by <NAME> on 16/03/17.
//
//
#import <WatchKit/WatchKit.h>
//! Project version number for AwesomeData-watchOS.
FOUNDATION_EXPORT double AwesomeData_watchOSVersionNumber;
//! Project version string for AwesomeData-watc... | code_c | code | 156 | null |
<filename>esphome/components/coolix/coolix.h
#pragma once
#include "esphome/components/climate_ir/climate_ir.h"
namespace esphome {
namespace coolix {
// Temperature
const uint8_t COOLIX_TEMP_MIN = 17; // Celsius
const uint8_t COOLIX_TEMP_MAX = 30; // Celsius
class CoolixClimate : public climate_ir::ClimateIR {
... | code_c | code | 474 | null |
#include "c_koans.h"
#include <stdlib.h>
/*
Linked list is a collection of elements, typically represented
through a node referencing another node by means of a pointer.
This data structure allows for efficient insertion/removal of
elements from any node in the list.
Unlike an array where elements... | code_c | code | 1,750 | null |
<reponame>hugepants/Notepad3
// grepWin - regex search and replace for Windows
// Copyright (C) 2007-2008, 2012-2013, 2019-2020 - <NAME>
// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation; eith... | code_c | code | 500 | null |
//
// Copyright (c) 2019 Open Whisper Systems. All rights reserved.
//
#import <Foundation/Foundation.h>
NS_ASSUME_NONNULL_BEGIN
@protocol SPKProtocolReadContext <NSObject>
@end
@protocol SPKProtocolWriteContext <SPKProtocolReadContext>
@end
NS_ASSUME_NONNULL_END
| code_c | code | 77 | null |
#include<stdio.h>
#include<malloc.h>
/*
1) find the length of string
2) fint the number of space of string
3) multiply the space with 2 - because already 1 can be filled %,2,0
4) traverse from last with given string length
5) with the new length decreament and add the characters
6) if space found,just append %20 three ... | code_c | code | 302 | null |
<filename>scheduler/src/libscheduler/libscheduler.c
/** @file libscheduler.c
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "libscheduler.h"
#include "../libpriqueue/libpriqueue.h"
// Priority queue for jobs
priqueue_t *queue;
// Scheme to use
scheme_t current_scheme;
// ... | code_c | code | 3,762 | null |
/*
*
* Work Hour Monitor - Main menu interactive utilities.
*
*/
#include <stdio.h>
#include <stdlib.h>
#include <errno.h>
#include <string.h>
#include "sutils.h"
#include "whm.h"
extern whm_backup_T *to_write;
/* Display the main menu to stdout. */
void whm_print_main_menu(void)
{
puts("\n\nWork Hour ... | code_c | code | 3,853 | null |
// Note: Copy-Paste from segatools.
/* Win32 user-mode API */
#define WIN32_NO_STATUS
#include <windows.h>
#undef WIN32_NO_STATUS
#include <winternl.h>
#include <setupapi.h>
#include <unknwn.h>
#include <windns.h>
#include <ws2tcpip.h>
#include <dinput.h>
#include <xinput.h>
#include <d3d9.h>
/* Win32 kernel-mode def... | code_c | code | 223 | null |
#include <vector>
#include "Eigen/Dense"
#ifndef __RT_PHOTON_MAP__
#define __RT_PHOTON_MAP__
class PhotonMap
{
private:
void emit_photon(class IAccel* meshes, class Ray* r, Eigen::Vector3f energy, float max_dist, int pass);
std::vector<class Photon*> photons;
public:
void generate(const class Scene *scene, class ... | code_c | code | 162 | null |
<reponame>anant0301/Sem5<gh_stars>1-10
#ifndef header_q7
#define header_q7
#define MAX_THREADS 1000
struct q7_parameter
{
unsigned long int in_circle;
unsigned long int in_square;
unsigned long int radius;
unsigned long int square;
};
#endif | code_c | code | 74 | null |
<reponame>davidxwwang/ALISJsBridgeKit
//
// NBSession.h
// NBService
//
// Created by chenwenhong on 15/8/25.
// Copyright (c) 2015年 Alipay. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "NBSessionContext.h"
@class NBSessionDelegate;
@interface NBSession : NSObject
@property(nonatomic, stron... | code_c | code | 138 | null |
<filename>Stripe3DS2/Stripe3DS2/STDSException+Internal.h<gh_stars>1000+
//
// STDSException+Internal.h
// Stripe3DS2
//
// Created by <NAME> on 1/22/19.
// Copyright © 2019 Stripe. All rights reserved.
//
#import "STDSException.h"
NS_ASSUME_NONNULL_BEGIN
@interface STDSException (Internal)
+ (instancetype)excep... | code_c | code | 111 | null |
<gh_stars>0
/*
* Words! book-words! what are you?
* Words no more, for hearken and see,
* My song is there in the open air - and I must sing,
* With the banner and pennant a-flapping.
*
* "The Song of the Banner at Daybreak" (st. II) - <NAME>
*/
#include <xcb/xcb_icccm.h>
#include <xcb/xcb_ewmh.h>
#include <xcb... | code_c | code | 4,854 | null |
<filename>Ch12/dyn_arr.c
/* dyn_arr.c -- dynamically allocated array */
#include <stdio.h>
#include <stdlib.h> /* for malloc(), free() */
int main(void)
{
double * ptd;
int max;
int number;
int i = 0;
puts("What is the maximum number of type double entries?");
if (scanf("%d", &max) != 1)
... | code_c | code | 291 | null |
#ifndef PHYSICSOBJ_H
#define PHYSICSOBJ_H
#include "../base.h"
#include "terrain.h"
class physicsObj : public Object {
protected:
Vector2 col;
Vector2 vel;
public:
void setCol(float x, float y);
physicsObj(GameWindow* gw);
//~physicsObj();
void update(terrain* ter);
void accelerate(float x, float y);
... | code_c | code | 135 | null |
<filename>core/drivers/cdns_uart.c<gh_stars>1-10
// SPDX-License-Identifier: BSD-2-Clause
/*
* Copyright (c) 2016, Xilinx Inc.
* 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. Redistr... | code_c | code | 1,146 | null |
#pragma once
#include <Arduino.h>
enum COMMANDS {
error,
pulse5,
pulse6,
pulse7,
pulse8,
pulse9,
pulse10,
pulse11,
flash,
backward,
rest
};
class Communication
{
public:
virtual void Begin() = 0;
virtual COMMANDS readCommand(int id) = 0;
virtual int sendCommand(int id, String mes... | code_c | code | 132 | null |
<reponame>PuercoPop/maiko
/* $Id: ubf3.c,v 1.3 1999/05/31 23:35:45 sybalsky Exp $ (C) Copyright Venue, All Rights Reserved */
static char *id = "$Id: ubf3.c,v 1.3 1999/05/31 23:35:45 sybalsky Exp $ Copyright (C) Venue";
/* ubf3.c
*/
/************************************************************************/
/* ... | code_c | code | 437 | null |
/* IDirectMusicBand Implementation
*
* Copyright (C) 2003-2004 <NAME>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later ve... | code_c | code | 4,901 | null |
/*
// Copyright (c) 2016 Intel Corporation
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law o... | code_c | code | 356 | null |
<gh_stars>0
#ifndef SIMLib_Motor_h
#define SIMLib_Motor_h
#include "Arduino.h"
#include "LedControl.h"
#define LEFT 1
#define RIGHT 2
#define FORWARD 4
#define BACKWARD -1
#define GO 1
#define BRAKE 0
class MotorControl
{
public:
MotorControl();
void init();
void drive(byte Motor, int Spe... | code_c | code | 199 | null |
/****************************************************************************
* drivers/1wire/1wire.c
*
* Copyright (C) 2018 Haltian Ltd. All rights reserved.
* Author: <NAME> <<EMAIL>>
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the foll... | code_c | code | 4,752 | null |
#pragma once
#include <cstdint>
namespace SightJacker {
bool isEnabled();
void enable();
void disable(bool surpress = false);
void toggle();
void switchPlayer(const unsigned char* pMouseBuffer, unsigned char* pKeyboardBuffer);
void draw();
void lost();
void reset();
void playerDied(std::uint32_t index);
}; | code_c | code | 90 | null |
<reponame>JakubHazik/amr_fleet<gh_stars>1-10
//
// Created by jakub on 21.2.2020.
//
#ifndef PROJECT_GRAPH_H
#define PROJECT_GRAPH_H
#include <ros/ros.h>
#include <boost/graph/astar_search.hpp>
#include <boost/graph/adjacency_list.hpp>
#include <boost/graph/random.hpp>
#include <boost/graph/connected_components.hpp>
... | code_c | code | 1,116 | null |
<gh_stars>0
/*
* insert_event.c - C implementation of pgq.insert_event_raw().
*
* Copyright (c) 2007 <NAME>, Skype Technologies OÜ
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permiss... | code_c | code | 1,909 | null |
/*
* SPDX-FileCopyrightText: 2021-2022 Espressif Systems (Shanghai) CO LTD
*
* SPDX-License-Identifier: Apache-2.0
*/
#include "esp_log.h"
#include "esp_check.h"
#include "freertos/FreeRTOS.h"
#include "freertos/task.h"
#include "driver/temperature_sensor.h"
static const char *TAG = "example";
void tempsensor_ex... | code_c | code | 327 | null |
<filename>third_party/sqlite/src/src/test_backup.c
/*
** 2009 January 28
**
** The author disclaims copyright to this source code. In place of
** a legal notice, here is a blessing:
**
** May you do good and not evil.
** May you find forgiveness for yourself and forgive others.
** May you share freely, never ... | code_c | code | 1,182 | null |
<filename>client/terminal.h
#pragma once
#include <stddef.h>
#include <inttypes.h>
#include <termios.h>
#include <string>
class Terminal
{
static Terminal* m_terminal;
volatile bool m_sizeChanged, m_quit;
size_t m_cols, m_rows;
struct termios m_startupTerminalSettings;
bool m_queue;
std::string m_queueContent... | code_c | code | 360 | null |
#ifdef __OBJC__
#import <UIKit/UIKit.h>
#else
#ifndef FOUNDATION_EXPORT
#if defined(__cplusplus)
#define FOUNDATION_EXPORT extern "C"
#else
#define FOUNDATION_EXPORT extern
#endif
#endif
#endif
#import "FSCalendar.h"
#import "FSCalendarAppearance.h"
#import "FSCalendarCalculator.h"
#import "FSCalendarCell.h"
#import "... | code_c | code | 251 | null |
// Copyright 2018 Google LLC
// Copyright 2018-present Open Networking Foundation
// SPDX-License-Identifier: Apache-2.0
#ifndef STRATUM_GLUE_STATUS_STATUS_H_
#define STRATUM_GLUE_STATUS_STATUS_H_
#include <atomic>
#include <iosfwd>
#include <string>
#include "absl/base/attributes.h"
#include "absl/strings/str_cat.h... | code_c | code | 4,679 | null |
<filename>include/orz/utils/log.h
//
// Created by Lby on 2017/6/6.
//
#ifndef ORZ_UTILS_LOG_H
#define ORZ_UTILS_LOG_H
#include <iostream>
#include <sstream>
#include "format.h"
#include "except.h"
#include <cstring>
#undef NONE
#undef DEBUG
#undef STATUS
#undef INFO
#undef ERROR
#undef FATAL
#if ORZ_PLATFORM_OS_AN... | code_c | code | 1,334 | null |
<reponame>BenjaminHCheung/lumberyard
/*
* All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
* its licensors.
*
* For complete copyright and license terms please see the LICENSE at the root of this
* distribution (the "License"). All use of this software is governed by the License,
* or, i... | code_c | code | 751 | null |
/*
* Written by Solar Designer <solar at openwall.com> in 2000-2011.
* No copyright is claimed, and the software is hereby placed in the public
* domain. In case this attempt to disclaim copyright and place the software
* in the public domain is deemed null and void, then the software is
* Copyright (c) 2000-2011... | code_c | code | 4,361 | null |
<reponame>androdev4u/sysdb
/*
* SysDB - t/unit/utils/strings_test.c
* Copyright (C) 2016 Sebastian 'tokkee' Harl <<EMAIL>>
* 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. Redistribu... | code_c | code | 1,510 | null |
<reponame>shuaiAdmin/learnDemo
//
// BezierDemoView.h
// search
//
// Created by 王帅 on 16/6/23.
// Copyright © 2016年 shuai. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface BezierDemoView : UIView
@end
| code_c | code | 62 | null |
<reponame>ffteja/cgal
namespace CGAL {
/*!
\ingroup PkgKernelDKernelObjs
An instance of data type `Point_d<Kernel>` is a point of Euclidean
space in dimension \f$ d\f$. A point \f$ p = (p_0,\ldots,p_{ d - 1 })\f$ in
\f$ d\f$-dimensional space can be represented by homogeneous coordinates
\f$ (h_0,h_1,\ldots,h_d)\f$ o... | code_c | code | 1,722 | null |
<reponame>katema-official/Universita_magistrale_anno_1.1
/*
* Code for class SED_MEDIUM_READER_WRITER
*/
#include "eif_eiffel.h"
#include "../E1/estructure.h"
#ifdef __cplusplus
extern "C" {
#endif
extern void F126_1873(EIF_REFERENCE, EIF_TYPED_VALUE);
extern void F126_1874(EIF_REFERENCE, EIF_TYPED_VALUE);
extern... | code_c | code | 15,021 | null |
<reponame>marangisto/corona
#pragma once
////
//
// STM32G4 FMC peripherals
//
///
// FMC: Flexible memory controller
struct stm32g473xx_fmc_t
{
volatile uint32_t BCR1; // SRAM/NOR-Flash chip-select control register 1
volatile uint32_t BTR1; // SRAM/NOR-Flash chip-select timing register 1
volatile u... | code_c | code | 4,700 | null |
/*
* Copyright (C) 2015 <NAME>
* http://www.christianbenjaminries.de
* https://github.com/cbries
*/
#ifndef __ENGINE_H__
#define __ENGINE_H__
#include "Arduino.h"
//#define MAXVOLTAGE_FOR_5 // ATmega328 (5V, 16 MHz)
#define MAXVOLTAGE_FOR_3_3 // tbd
#ifdef MAXVOLTAGE_FOR_5
const float MaxVoltage = 5.0f;
#el... | code_c | code | 434 | null |
<filename>arch/xtensa/src/esp32/esp32_spiflash.c
/****************************************************************************
* arch/xtensa/src/esp32/esp32_spiflash.c
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* th... | code_c | code | 15,274 | null |
<reponame>mpberk/cse531-projects<gh_stars>0
// (c) <NAME> 2009
// permission to use and distribute granted.
#include <stdio.h>
#include <stdlib.h>
#include "threads.h"
int x;
func1()
{int i = 0;
printf("Thread 1 - running\n");
for (i=0; i<100000000; i++) x++;
printf("Thread 1: x = %d\n", x);
printf("... | code_c | code | 202 | null |
/* GStreamer
* Copyright (C) 2013 <NAME> <<EMAIL>>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
*... | code_c | code | 2,275 | null |
#include "alpha/fileio.h"
#include "errno.h"
int fstat(int fd, struct stat *st)
{
t_fileio_errno errnum;
t_fileio_int32 rc;
FILEIO_FSTAT(fd, (t_fileio_stat*) st, &errnum, &rc);
if (rc == -1) {
errno = errnum;
}
return rc;
}
| code_c | code | 69 | null |
// C++/WinRT v2.0.200609.3
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#ifndef WINRT_Windows_Services_Cortana_0_H
#define WINRT_Windows_Services_Cortana_0_H
WINRT_EXPORT namespace winrt::Windows::ApplicationModel::DataTransfer
{
struct DataPackage;
}
WINRT_EXPOR... | code_c | code | 4,633 | null |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.