commit stringlengths 40 40 | old_file stringlengths 4 264 | new_file stringlengths 4 264 | old_contents stringlengths 0 4.24k | new_contents stringlengths 1 5.44k | subject stringlengths 14 778 | message stringlengths 15 9.92k | lang stringclasses 277
values | license stringclasses 13
values | repos stringlengths 5 127k |
|---|---|---|---|---|---|---|---|---|---|
6420adb9d93a17d3d16ae17bb67b012273fa0e8d | sbr/context_del.c | sbr/context_del.c |
/*
* context_del.c -- delete an entry from the context/profile list
*
* This code is Copyright (c) 2002, by the authors of nmh. See the
* COPYRIGHT file in the root directory of the nmh distribution for
* complete copyright information.
*/
#include <h/mh.h>
/*
* Delete a key/value pair from the context/profi... |
/*
* context_del.c -- delete an entry from the context/profile list
*
* This code is Copyright (c) 2002, by the authors of nmh. See the
* COPYRIGHT file in the root directory of the nmh distribution for
* complete copyright information.
*/
#include <h/mh.h>
#include <h/utils.h>
/*
* Delete a key/value pair f... | Replace `if (p) free(p)' with `mh_xfree(p)'. | Replace `if (p) free(p)' with `mh_xfree(p)'.
| C | bsd-3-clause | mcr/nmh,mcr/nmh |
7b2d21e3710781fa223d8200b59c841771ff73d3 | test/Analysis/array-struct.c | test/Analysis/array-struct.c | // RUN: clang -checker-simple -verify %s
// RUN: clang -checker-simple -analyzer-store-region -verify %s
struct s {
int data;
int data_array[10];
};
typedef struct {
int data;
} STYPE;
void g1(struct s* p);
void f(void) {
int a[10];
int (*p)[10];
p = &a;
(*p)[3] = 1;
struct s d;
struct s *q;
... | // RUN: clang -checker-simple -verify %s &&
// RUN: clang -checker-simple -analyzer-store-region -verify %s
struct s {
int data;
int data_array[10];
};
typedef struct {
int data;
} STYPE;
void g1(struct s* p);
void f(void) {
int a[10];
int (*p)[10];
p = &a;
(*p)[3] = 1;
struct s d;
struct s *q;... | Append the test runs with '&&'. | Append the test runs with '&&'.
git-svn-id: ffe668792ed300d6c2daa1f6eba2e0aa28d7ec6c@58851 91177308-0d34-0410-b5e6-96231b3b80d8
| C | apache-2.0 | llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,apple/swift-clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,llvm-mirror/clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,apple/swift-cl... |
f35eea985e4b20020c8a91533fcd769c5745662b | stm8/src/main.c | stm8/src/main.c | #include <stdint.h>
#include "stm8s208s.h"
void main(void)
{
MEMLOC(CLK_CKDIVR) = 0x00; // Set the frequency to 16 MHz
BITSET(CLK_PCKENR1, 7);
// Configure timer
// 1000 ticks per second
MEMLOC(TIM1_PSCRH) = (16000>>8);
MEMLOC(TIM1_PSCRL) = (uint8_t)(16000 & 0xff);
// Enable timer
MEML... | #include <stdint.h>
#include "stm8s208s.h"
void main(void)
{
MEMLOC(CLK_CKDIVR) = 0x00; /* Set the frequency to 16 MHz */
BITSET(CLK_PCKENR1, 7); /* Enable clk to TIM1 */
// Configure timer
// 250 ticks per second
MEMLOC(TIM1_PSCRH) = (64000>>8);
MEMLOC(TIM1_PSCRL) = (uint8_t)(64000 & 0xff);
... | Reduce ticks to 250 to use 8bit diff | Reduce ticks to 250 to use 8bit diff
| C | bsd-3-clause | spoorcc/docker_embedded,spoorcc/docker_embedded |
b675c4d898d18514312a867ffca73d09e438f7c0 | t/aget_value_t.c | t/aget_value_t.c | #include "maxminddb_test_helper.h"
void run_tests(int mode, const char *mode_desc)
{
const char *filename = "MaxMind-DB-test-decoder.mmdb";
const char *path = test_database_path(filename);
MMDB_s *mmdb = open_ok(path, mode, mode_desc);
free((void *)path);
const char *ip = "1.1.1.1";
MMDB_looku... | #include "maxminddb_test_helper.h"
void run_tests(int mode, const char *mode_desc)
{
const char *filename = "MaxMind-DB-test-decoder.mmdb";
const char *path = test_database_path(filename);
MMDB_s *mmdb = open_ok(path, mode, mode_desc);
free((void *)path);
const char *ip = "1.1.1.1";
MMDB_looku... | Fix typo in test description | Fix typo in test description
| C | apache-2.0 | maxmind/libmaxminddb,maxmind/libmaxminddb,maxmind/libmaxminddb |
8afc766b82b045474873b2c6365bd31b449749ef | src/os.h | src/os.h | //
// Created by dar on 1/29/16.
//
#ifndef C003_OS_H
#define C003_OS_H
enum class OS {
WIN32 = 0,
UNIX,
ANDROID,
APPLE
};
constexpr const OS OPERATING_SYTEM =
#ifdef _WIN32
OS::WIN32
#elif __APPLE__
OS::APPLE
#elif __ANDROID__
OS::ANDROID
#elif __unix__
OS::UNIX
#endif
;
constexpr c... | //
// Created by dar on 1/29/16.
//
#ifndef C003_OS_H
#define C003_OS_H
enum class OS {
WIN32 = 0,
UNIX,
ANDROID,
IOS,
MAC
};
#ifdef __APPLE__
#include "TargetConditionals.h"
#endif
constexpr const OS OPERATING_SYTEM =
#ifdef _WIN32
OS::WIN32
#elif __APPLE__
#if TARGET_IPHONE_SIMULATOR |... | Split APPLE operating system to IOS and MAC | Split APPLE operating system to IOS and MAC
| C | mit | darsto/spooky,darsto/spooky |
cd8b79f334adff93acea8dfe586d61bb7eaec3e4 | src/phys_const.h | src/phys_const.h | #ifndef LIBEFP_PHYS_CONST_H
#define LIBEFP_PHYS_CONST_H
/* Bohr radius in angstroms */
#define BOHR_RADIUS 0.52917724924
#endif /* LIBEFP_PHYS_CONST_H */
| #ifndef LIBEFP_PHYS_CONST_H
#define LIBEFP_PHYS_CONST_H
/* Bohr radius in angstroms */
#define BOHR_RADIUS 0.52917721092
#endif /* LIBEFP_PHYS_CONST_H */
| Use value from CODATA 2010. | Use value from CODATA 2010.
| C | bsd-2-clause | libefp/libefp,libefp/libefp,libefp/libefp |
fea93e818380d4d9b3b68bc47509058f60b8cdb7 | src/arch/sparc/kernel/arch.c | src/arch/sparc/kernel/arch.c | /**
* @file
* @brief Implements ARCH interface for sparc processors
*
* @date 14.02.10
* @author Eldar Abusalimov
*/
#include <hal/arch.h>
#include <asm/cache.h>
#include <hal/ipl.h>
void arch_init(void) {
cache_enable();
}
void arch_idle(void) {
}
unsigned int arch_excep_disable(void) {
unsigned int ret;
... | /**
* @file
* @brief Implements ARCH interface for sparc processors
*
* @date 14.02.10
* @author Eldar Abusalimov
*/
#include <hal/arch.h>
#include <asm/cache.h>
#include <hal/ipl.h>
void arch_init(void) {
cache_enable();
}
void arch_idle(void) {
__asm__ __volatile__ ("wr %g0, %asr19");
}
unsigned int arch_... | Add power down mode for idle circle | sparc: Add power down mode for idle circle | C | bsd-2-clause | abusalimov/embox,mike2390/embox,vrxfile/embox-trik,abusalimov/embox,Kefir0192/embox,embox/embox,embox/embox,abusalimov/embox,gzoom13/embox,gzoom13/embox,Kakadu/embox,mike2390/embox,mike2390/embox,embox/embox,gzoom13/embox,Kefir0192/embox,Kakadu/embox,Kakadu/embox,Kefir0192/embox,gzoom13/embox,mike2390/embox,Kakadu/embo... |
5527ee34788794f84b8730d01eb8383aa898fd59 | include/mintpack/random.h | include/mintpack/random.h | #ifndef __MINTPACK_RANDOM_H__
#define __MINTPACK_RANDOM_H__
#include <mintomic/mintomic.h>
//-------------------------------------
// PRNG that seeds itself using various information from the environment.
// generate() is uniformly distributed across all 32-bit integer values.
// generateUnique() returns unique i... | #ifndef __MINTPACK_RANDOM_H__
#define __MINTPACK_RANDOM_H__
#include <mintomic/mintomic.h>
//-------------------------------------
// PRNG that seeds itself using various information from the environment.
// generate32() is uniformly distributed across all 32-bit integer values.
// generateUnique32() returns uniq... | Fix function names in Random comment | Fix function names in Random comment
| C | bsd-3-clause | adream307/mintomic,UIKit0/mintomic,adream307/mintomic,mulle-nat/mintomic,mintomic/mintomic,mintomic/mintomic,mulle-nat/mintomic,UIKit0/mintomic |
a9623da05f8a2930fadafd27fe621b16886b259d | drivers/scsi/qla4xxx/ql4_version.h | drivers/scsi/qla4xxx/ql4_version.h | /*
* QLogic iSCSI HBA Driver
* Copyright (c) 2003-2013 QLogic Corporation
*
* See LICENSE.qla4xxx for copyright and licensing details.
*/
#define QLA4XXX_DRIVER_VERSION "5.03.00-k11"
| /*
* QLogic iSCSI HBA Driver
* Copyright (c) 2003-2013 QLogic Corporation
*
* See LICENSE.qla4xxx for copyright and licensing details.
*/
#define QLA4XXX_DRIVER_VERSION "5.04.00-k0"
| Update driver version to 5.04.00-k0 | [SCSI] qla4xxx: Update driver version to 5.04.00-k0
Signed-off-by: Vikas Chaudhary <c251871a64d7d31888eace0406cb3d4c419d5f73@qlogic.com>
Signed-off-by: James Bottomley <1acebbdca565c7b6b638bdc23b58b5610d1a56b8@Parallels.com>
| C | mit | KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs |
0cd78c0a12ebc84b56a58016fbcc83aefba64e1a | fitz/base_time.c | fitz/base_time.c | #ifdef _WIN32
#include <time.h>
#include <winsock2.h>
#include <windows.h>
#if defined(_MSC_VER) || defined(_MSC_EXTENSIONS)
#define DELTA_EPOCH_IN_MICROSECS 11644473600000000Ui64
#else
#define DELTA_EPOCH_IN_MICROSECS 11644473600000000ULL
#endif
struct timeval;
int gettimeofday(struct timeval *tv, struct timezone ... | #ifdef _WIN32
#include <time.h>
#ifndef METRO
#include <winsock2.h>
#endif
#include <windows.h>
#if defined(_MSC_VER) || defined(_MSC_EXTENSIONS)
#define DELTA_EPOCH_IN_MICROSECS 11644473600000000Ui64
#else
#define DELTA_EPOCH_IN_MICROSECS 11644473600000000ULL
#endif
struct timeval;
int gettimeofday(struct timeval ... | Tweak to allow building on metro. | Tweak to allow building on metro.
Limited testing seems to suggest that the only thing stopping the MuPDF
library building on metro seems to be the use of winsock.h.
| C | agpl-3.0 | hackqiang/mupdf,crow-misia/mupdf,knielsen/mupdf,lustersir/MuPDF,ArtifexSoftware/mupdf,lamemate/mupdf,flipstudio/MuPDF,FabriceSalvaire/mupdf-cmake,lolo32/mupdf-mirror,MokiMobility/muPDF,geetakaur/NewApps,sebras/mupdf,Kalp695/mupdf,kobolabs/mupdf,asbloomf/mupdf,hxx0215/MuPDFMirror,michaelcadilhac/pdfannot,tophyr/mupdf,hj... |
65a65f46dc4b8d2cf1ee83f05a280fdacbfd2416 | critmem.h | critmem.h | #ifndef CRITMEM_H
#define CRITMEM_H
#include <sys/types.h>
/*@only@*//*@out@*//*@notnull@*/ void *mycritmalloc(const char *f, long, size_t size,
const char *message);
/*@only@*//*@notnull@*/ void *mycritcalloc(const char *f, long, size_t size,
const char *message);
/*@only@*//*@out@*//*@notnull@*/ void ... | #ifndef CRITMEM_H
#define CRITMEM_H
#include "config.h"
#include <sys/types.h>
/*@only@*//*@out@*//*@notnull@*/ void *mycritmalloc(const char *f, long, size_t size,
const char *message);
/*@only@*//*@notnull@*/ void *mycritcalloc(const char *f, long, size_t size,
const char *message);
/*@only@*//*@out@*... | Include config.h, patch by Ralf Wildenhues. | Include config.h, patch by Ralf Wildenhues. | C | lgpl-2.1 | BackupTheBerlios/leafnode,BackupTheBerlios/leafnode,BackupTheBerlios/leafnode,BackupTheBerlios/leafnode |
ea88107869edaa94959d13d635d8077561942557 | test/Driver/arm-restrict-it.c | test/Driver/arm-restrict-it.c | // RUN: %clang -target arm-none-gnueabi -mrestrict-it -### %s 2> %t
// RUN: FileCheck --check-prefix=CHECK-RESTRICTED < %t %s
// RUN: %clang -target armv8a-none-gnueabi -mrestrict-it -### %s 2> %t
// RUN: FileCheck --check-prefix=CHECK-RESTRICTED < %t %s
// CHECK-RESTRICTED: "-backend-option" "-arm-restrict-it"
// R... | Add test case for r194593 | Add test case for r194593
git-svn-id: ffe668792ed300d6c2daa1f6eba2e0aa28d7ec6c@194606 91177308-0d34-0410-b5e6-96231b3b80d8
| C | apache-2.0 | apple/swift-clang,llvm-mirror/clang,apple/swift-clang,apple/swift-clang,llvm-mirror/clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,llvm-mirror/clang,apple/swift-clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,apple/swift-clang,llvm-mirror/clang,apple/swift-clang,llvm-mirror/clang,llvm-mirror/cl... | |
979b40c26118cfc50d27eed458d71020e87dc629 | mcrouter/CyclesObserver.h | mcrouter/CyclesObserver.h | /*
* Copyright (c) 2015, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*
*/
#pragma once... | /*
* Copyright (c) 2015, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*
*/
#pragma once... | Add 'runnable' callback to ExecutionObserver | Add 'runnable' callback to ExecutionObserver
Summary: Add a callback when a fiber becomes runnable
Test Plan: unit tests
Reviewed By: @andriigrynenko
Differential Revision: D2081306 | C | bsd-3-clause | synecdoche/mcrouter,yqzhang/mcrouter,tempbottle/mcrouter,easyfmxu/mcrouter,reddit/mcrouter,is00hcw/mcrouter,nvaller/mcrouter,is00hcw/mcrouter,easyfmxu/mcrouter,easyfmxu/mcrouter,tempbottle/mcrouter,leitao/mcrouter,leitao/mcrouter,facebook/mcrouter,facebook/mcrouter,nvaller/mcrouter,reddit/mcrouter,zhlong73/mcrouter,is0... |
9882794a65d52a2d39738f941709a837098f7b5f | shellcode/syscall_inline.c | shellcode/syscall_inline.c | // gcc -mpreferred-stack-boundary=2 -ggdb syscall_inline.c -o syscall_inline
// syscall.s in inline asm: print to stdout and exit from inline assembler
#include <stdio.h>
void f() {
char* str = "hi\n";
__asm__(
// write str (first local variable, at %ebp-4)
"movl $4, %eax \n\t"
"movl $1, %ebx \n\t"
... | Make syscalls from C/inline assembler | Make syscalls from C/inline assembler
| C | mit | jwhitfieldseed/sandbox,jwhitfieldseed/sandbox,jwhitfieldseed/sandbox,jwhitfieldseed/sandbox | |
e7e2501f33c89d23bd938fe9f57964cf3f2e276a | fw/libs/AdapterBoard/usb_commands.h | fw/libs/AdapterBoard/usb_commands.h | /* USB commands use the first byte as the 'type' variable.
* Subsequent bytes are generally the 'arguments'.
* So host->device usb packets usually look like:
* [command, arg1, arg2, 0, 0, ... , 0, 0]
* to which the device will respond with
* [CMD_ACK, command, 0, 0, 0 ..., 0, 0]
*
* The exception to this, are th... | /* USB commands use the first byte as the 'type' variable.
* Subsequent bytes are generally the 'arguments'.
* So host->device usb packets usually look like:
* [command, arg1, arg2, 0, 0, ... , 0, 0]
* to which the device will respond with
* [CMD_ACK, command, 0, 0, 0 ..., 0, 0]
*
* The exception to this, are th... | Add a macro to determine whether a GET command | Add a macro to determine whether a GET command
| C | bsd-3-clause | OSCARAdapter/OSCAR,OSCARAdapter/OSCAR |
392db70fa268f52058018bc3b4fe672576e384e5 | ReactiveCocoaFramework/ReactiveCocoa/NSUserDefaults+RACSupport.h | ReactiveCocoaFramework/ReactiveCocoa/NSUserDefaults+RACSupport.h | //
// NSUserDefaults+RACSupport.h
// ReactiveCocoa
//
// Created by Matt Diephouse on 12/19/13.
// Copyright (c) 2013 GitHub, Inc. All rights reserved.
//
#import <Foundation/Foundation.h>
@class RACChannelTerminal;
@interface NSUserDefaults (RACSupport)
// Creates and returns a terminal for binding the user de... | //
// NSUserDefaults+RACSupport.h
// ReactiveCocoa
//
// Created by Matt Diephouse on 12/19/13.
// Copyright (c) 2013 GitHub, Inc. All rights reserved.
//
#import <Foundation/Foundation.h>
@class RACChannelTerminal;
@interface NSUserDefaults (RACSupport)
/// Creates and returns a terminal for binding the user d... | Add a third slash for Xcode | Add a third slash for Xcode
| C | mit | dachaoisme/ReactiveCocoa,almassapargali/ReactiveCocoa,on99/ReactiveCocoa,itschaitanya/ReactiveCocoa,brightcove/ReactiveCocoa,tonyarnold/ReactiveCocoa,chao95957/ReactiveCocoa,zhiwen1024/ReactiveCocoa,Khan/ReactiveCocoa,cnbin/ReactiveCocoa,RuiAAPeres/ReactiveCocoa,bencochran/ReactiveCocoa,jeelun/ReactiveCocoa,leelili/Rea... |
e8740f26827c1aed33005aac3862e6e7840ee72d | src/Puddle.c | src/Puddle.c | #include "pebble_os.h"
#include "pebble_app.h"
#include "pebble_fonts.h"
#define MY_UUID { 0xE3, 0x7B, 0xFC, 0xE9, 0x30, 0xD7, 0x4B, 0xC3, 0x96, 0x93, 0x15, 0x0C, 0x35, 0xDC, 0xB8, 0x58 }
PBL_APP_INFO(MY_UUID,
"Template App", "Your Company",
1, 0, /* App version */
DEFAULT_MENU_... | #include "pebble_os.h"
#include "pebble_app.h"
#include "pebble_fonts.h"
#define MY_UUID { 0xE3, 0x7B, 0xFC, 0xE9, 0x30, 0xD7, 0x4B, 0xC3, 0x96, 0x93, 0x15, 0x0C, 0x35, 0xDC, 0xB8, 0x58 }
PBL_APP_INFO(MY_UUID,
"Puddle", "Jon Speicher",
0, 1, /* App version */
DEFAULT_MENU_ICON,
... | Change framework app name, comopany, version, and window debug | Change framework app name, comopany, version, and window debug
| C | mit | jonspeicher/Puddle,jonspeicher/Puddle,jonspeicher/Puddle |
9da39b0de57a9a7dfbc87379948d5c36c2c1078c | src/common.h | src/common.h | // Copyright (c) 2012-2013, the scalloc Project Authors. All rights reserved.
// Please see the AUTHORS file for details. Use of this source code is governed
// by a BSD license that can be found in the LICENSE file.
#ifndef SCALLOC_COMMON_H_
#define SCALLOC_COMMON_H_
#define UNLIKELY(x) __builtin_expect((x), 0)
... | // Copyright (c) 2012-2013, the scalloc Project Authors. All rights reserved.
// Please see the AUTHORS file for details. Use of this source code is governed
// by a BSD license that can be found in the LICENSE file.
#ifndef SCALLOC_COMMON_H_
#define SCALLOC_COMMON_H_
#define UNLIKELY(x) __builtin_expect((x), 0)
... | Add system page size constant. | Add system page size constant.
Signed-off-by: Michael Lippautz <0d543840881a2c189b4f7636b15eebd6a8f60ace@gmail.com>
| C | bsd-2-clause | cksystemsgroup/scalloc,cksystemsgroup/scalloc,cksystemsgroup/scalloc |
041a67a595d4afb732a1b5cc97843b0b05d1cff0 | include/config/SkUserConfigManual.h | include/config/SkUserConfigManual.h | /*
* Copyright 2017 Google Inc.
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#ifndef SkUserConfigManual_DEFINED
#define SkUserConfigManual_DEFINED
#define GR_TEST_UTILS 1
#define SK_BUILD_FOR_ANDROID_FRAMEWORK
#define SK_DEFAULT_FONT_CACHE_LIMIT ... | /*
* Copyright 2017 Google Inc.
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#ifndef SkUserConfigManual_DEFINED
#define SkUserConfigManual_DEFINED
#define GR_TEST_UTILS 1
#define SK_BUILD_FOR_ANDROID_FRAMEWORK
#define SK_DEFAULT_FONT_CACHE_LIMIT ... | Add flag to stage API change | Add flag to stage API change
Test: make
Bug: 178700363
Change-Id: I15d678d3896efb896d1b87f11f32df7787a53577
| C | bsd-3-clause | aosp-mirror/platform_external_skia,aosp-mirror/platform_external_skia,aosp-mirror/platform_external_skia,aosp-mirror/platform_external_skia,aosp-mirror/platform_external_skia,aosp-mirror/platform_external_skia,aosp-mirror/platform_external_skia,aosp-mirror/platform_external_skia,aosp-mirror/platform_external_skia,aosp-... |
05b95d853c0ba6c4c27755245a5cac26c9fd8937 | src/dsemem.h | src/dsemem.h | /* dsemem.h
*
* routines for managing a free list of DataStackEntry structs
*
*/
#ifndef _DSEMEM_H_
#define _DSEMEM_H_
#include "dataStackEntry.h"
DataStackEntry *dse_alloc(void);
void dse_free(DataStackEntry *dse);
#endif /* _DSEMEM_H_ */
| /*
* Copyright (c) 2013, Court of the University of Glasgow
* All rights reserved.
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
* - Redistributions of source code must retain the above copyright notice,
* thi... | Add BSD 3-clause open source header | Add BSD 3-clause open source header
| C | bsd-3-clause | fergul/Cache,jsventek/Cache,jsventek/Cache,jsventek/Cache,fergul/Cache,fergul/Cache |
e9ee6c8da6a11aed867a9eadefd7a03c3b7e0b82 | src/sw/settings/include/primitives/sw/sw.settings.program_name.h | src/sw/settings/include/primitives/sw/sw.settings.program_name.h | #include <primitives/sw/settings_program_name.h>
#if defined(SW_EXECUTABLE)
EXPORT_FROM_EXECUTABLE
std::string getProgramName()
{
// this will trigger build error if executable forget to set
// PackageDefinitions = true;
#ifndef PACKAGE_NAME_CLEAN
#error "Set '.PackageDefinitions = true;' on your target."
#end... | #include <primitives/sw/settings_program_name.h>
#if defined(SW_EXECUTABLE) && !defined(SW_CUSTOM_PROGRAM_NAME)
EXPORT_FROM_EXECUTABLE
std::string getProgramName()
{
// this will trigger build error if executable forget to set
// PackageDefinitions = true;
#ifndef PACKAGE_NAME_CLEAN
#error "Set '.PackageDefini... | Allow to define custom program name. | [sw.settings] Allow to define custom program name.
| C | mpl-2.0 | egorpugin/primitives,egorpugin/primitives |
12665d4150306223d969787e1b00ab0e99101976 | src/layers/embedding_reader.h | src/layers/embedding_reader.h | #pragma once
#include <fstream>
#include <string>
#include <vector>
#include "3rd_party/exception.h"
#include "common/definitions.h"
#include "common/utils.h"
#include "data/vocab.h"
#include "data/types.h"
#include "layers/param_initializers.h"
namespace marian {
class EmbeddingReader {
public:
EmbeddingReader()... | Add reader for embedding vectors from word2vec | Add reader for embedding vectors from word2vec
| C | mit | emjotde/amunmt,amunmt/marian,emjotde/Marian,marian-nmt/marian-train,emjotde/amunn,DianaDespa/marian-train,DianaDespa/marian-train,amunmt/marian,DianaDespa/marian-train,emjotde/Marian,marian-nmt/marian-train,emjotde/amunn,DianaDespa/marian-train,emjotde/amunmt,DianaDespa/marian-train,emjotde/amunmt,emjotde/amunn,emjotde... | |
2d6ced93beb3c575ae99f56372be7425dd197dae | service/basis/common/primitiveResource/include/internal/AssertUtils.h | service/basis/common/primitiveResource/include/internal/AssertUtils.h | //******************************************************************
//
// Copyright 2015 Samsung Electronics All Rights Reserved.
//
//-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance... | Add assertion util to handle OCStackResult code with exception | Add assertion util to handle OCStackResult code with exception
Change-Id: I574da5d88abef73bf89c800bdf2a1bc10460d1e4
Signed-off-by: coderhyme <528f34a2692ffbaf2ac758012cd3e3a426bd89e5@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1249
Tested-by: jenkins-iotivity <09cb29e8a2b473a2c978382eec13ee06fa017bda@... | C | apache-2.0 | santais/iotivity,santais/iotivity_1.1,iotivity/iotivity,WojciechLuczkow/iotivity,santais/iotivity_1.1,rzr/iotivity,santais/iotivity_1.1,tienfuc/iotivity-democlient-snap,tienfuc/iotivity-democlient-snap,santais/iotivity_1.1,rzr/iotivity,santais/iotivity_1.1.0,santais/iotivity_1.1,tienfuc/iotivity-democlient-snap,santais... | |
fb4154cc57191d47239dfa44036d50e467879373 | cpplib/mysociety_config.h | cpplib/mysociety_config.h | //
// mysociety_config.cpp:
// Read the terrible mySociety PHP format config files, as similar code for
// other languages.
//
// Copyright (c) 2010 UK Citizens Online Democracy. All rights reserved.
// Email: francis@mysociety.org; WWW: http://www.mysociety.org/
//
// $Id: mysociety_error.h,v 1.4 2009-09-24 22:00:29 f... | Include dependencies, remove excess debugging. | Include dependencies, remove excess debugging.
| C | agpl-3.0 | MorusAB/commonlib-fmg,MorusAB/commonlib-fmg,MorusAB/commonlib-fmg,MorusAB/commonlib-fmg,MorusAB/commonlib-fmg,MorusAB/commonlib-fmg,MorusAB/commonlib-fmg,MorusAB/commonlib-fmg | |
0d062b5d2f63e051cafde0eded86309fca2ad005 | 5_TimerExternalClockCounter.c | 5_TimerExternalClockCounter.c | /*
* main.c
*
* Created on: 2 Nov 2016
* Author: rafpe
*/
#include "stm32f4xx.h"
#include "stm32f407xx.h"
int main(void)
{
volatile uint32_t delay;
RCC->AHB1ENR |= RCC_AHB1ENR_GPIODEN | RCC_AHB1ENR_GPIOCEN | RCC_AHB1ENR_GPIOEEN | RCC_AHB1ENR_GPIOAEN; // enable the clock for GPIOs
RCC->APB2ENR |= RCC_... | Add timer with external clock count | Add timer with external clock count
| C | apache-2.0 | RafPe/STM32F407VGTx-examples | |
3b2a9a00dd4267fcffd370390037001f912347a3 | src/cxa_atexit.c | src/cxa_atexit.c | #ifdef __sun__
#include <pthread.h>
#include <stdlib.h>
static struct atexit_handler {
void (*f)(void *);
void *p;
void *d;
struct atexit_handler *next;
} *head;
static pthread_mutex_t lock = PTHREAD_MUTEX_INITIALIZER;
int __cxa_atexit( void (*f)(void *), void *p, void *d) {
pthread_mutex_lock(&lock);
st... | #ifdef __sun__
#include <pthread.h>
#include <stdlib.h>
static struct atexit_handler {
void (*f)(void *);
void *p;
void *d;
struct atexit_handler *next;
} *head;
static pthread_mutex_t lock = PTHREAD_MUTEX_INITIALIZER;
int __cxa_atexit( void (*f)(void *), void *p, void *d) {
pthread_mutex_lock(&lock);
st... | Fix bugs caused by writing code while half asleep. | Fix bugs caused by writing code while half asleep.
| C | bsd-2-clause | cemeyer/libcxxrt,xin3liang/platform_external_libcxxrt,sudosurootdev/external_libcxxrt,cemeyer/libcxxrt,xin3liang/platform_external_libcxxrt,vegard/libcxxrt,sudosurootdev/external_libcxxrt,vegard/libcxxrt,sudosurootdev/external_libcxxrt,cemeyer/libcxxrt,xin3liang/platform_external_libcxxrt,vegard/libcxxrt |
7fc9119df40544c5048308be5a6ff46b61213972 | src/validation.h | src/validation.h | // Copyright (c) 2009-2010 Satoshi Nakamoto
// Copyright (c) 2009-2015 The Bitcoin Core developers
// Copyright (c) 2014-2017 The Dash Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#ifndef BITCOIN_VALIDATION_H
... | // Copyright (c) 2009-2010 Satoshi Nakamoto
// Copyright (c) 2009-2015 The Bitcoin Core developers
// Copyright (c) 2014-2017 The Dash Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#ifndef BITCOIN_VALIDATION_H
... | Put back default max tip age | Put back default max tip age
| C | mit | neutroncoin/neutron,neutroncoin/neutron,neutroncoin/neutron,neutroncoin/neutron |
08622e9601da87b2c663042a06ba404e6bc1577a | Engine/source/gfx/gl/tGL/tGL.h | Engine/source/gfx/gl/tGL/tGL.h | //-----------------------------------------------------------------------------
// Copyright (c) 2012 GarageGames, LLC
//
// 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 restrictio... | //-----------------------------------------------------------------------------
// Copyright (c) 2012 GarageGames, LLC
//
// 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 restrictio... | Use different extension detection mechanism | Use different extension detection mechanism
I got this from looking at the code from the glew utility 'glewinfo' on my system it reported the following for GL_ARB_geometry_shader4: OK [MISSING]. This lead me to believe that there are two different ways of determining extensions. The first 'OK' seems to refer to the e... | C | mit | ValtoGameEngines/Torque3D,JeffProgrammer/Torque3D,Will-of-the-Wisp/Torque3D,aaravamudan2014/Torque3D,aaravamudan2014/Torque3D,ValtoGameEngines/Torque3D,Will-of-the-Wisp/Torque3D,GarageGames/Torque3D,lukaspj/Speciality,Azaezel/Torque3D,rextimmy/Torque3D,Duion/Torque3D,JeffProgrammer/Torque3D,John3/Torque3D,Bloodknight/T... |
f408c35b1716e255634a2a2e9b3366b47eb7b3d7 | test/Analysis/misc-driver.c | test/Analysis/misc-driver.c | // RUN: %clang -### --analyze %s 2>&1 | FileCheck %s
// CHECK: -D__clang_analyzer__
| // RUN: %clang --analyze %s
#ifndef __clang_analyzer__
#error __clang_analyzer__ not defined
#endif
| Revert "[static analyzer][test] Test directly that driver sets D__clang_analyzer__" | Revert "[static analyzer][test] Test directly that driver sets D__clang_analyzer__"
This reverts commit c7541903d72765a38808e9973572a8d50c9d94fb.
git-svn-id: ffe668792ed300d6c2daa1f6eba2e0aa28d7ec6c@372685 91177308-0d34-0410-b5e6-96231b3b80d8
| C | apache-2.0 | llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang |
1dec7cc40215a7f692987749e15c05062fe11d4f | delay.h | delay.h | #ifndef DELAY_H
#define DELAY_H
#include <stdlib.h>
typedef struct drand48_data delay_t;
static inline void delay_init(delay_t * state, int id)
{
srand48_r(id + 1, state);
}
static inline void delay_exec(delay_t * state)
{
long n;
lrand48_r(state, &n);
int j;
for (j = 50; j < 50 + n % 100; ++j) {
__a... | #ifndef DELAY_H
#define DELAY_H
#include <time.h>
#include <stdlib.h>
typedef struct drand48_data delay_t;
static inline void delay_init(delay_t * state, int id)
{
srand48_r(time(NULL) + id, state);
}
static inline void delay_exec(delay_t * state)
{
long n;
lrand48_r(state, &n);
int j;
for (j = 50; j < 5... | Use time based seed for generating random numbers. | Use time based seed for generating random numbers.
| C | mit | chaoran/fast-wait-free-queue,chaoran/fast-wait-free-queue,chaoran/hpc-queue,chaoran/fast-wait-free-queue,chaoran/hpc-queue,chaoran/hpc-queue |
d829f7b401a34e1b97bf473518014bce7ec606ac | src/runtime/scoped_mutex_lock.h | src/runtime/scoped_mutex_lock.h | #ifndef HALIDE_RUNTIME_MUTEX_H
#define HALIDE_RUNTIME_MUTEX_H
#include "HalideRuntime.h"
// Avoid ODR violations
namespace {
// An RAII mutex
struct ScopedMutexLock {
halide_mutex *mutex;
ScopedMutexLock(halide_mutex *mutex) : mutex(mutex) {
halide_mutex_lock(mutex);
}
~ScopedMutexLock() {
... | Add an OS mutex to Halide runtime. | Add an OS mutex to Halide runtime.
Document an issue with the POSIX thread pool.
Ensure memoization cache is cleaned up when a JITted module is
shutdown. (Also provides a way to clear the cache from AOT code.)
Former-commit-id: 67b04dc5ae26ee489f051e7ead819f482d2fccb6 | C | mit | Trass3r/Halide,Trass3r/Halide,darkbuck/Halide,darkbuck/Halide,darkbuck/Halide,Trass3r/Halide,darkbuck/Halide,Trass3r/Halide,Trass3r/Halide,Trass3r/Halide,darkbuck/Halide,darkbuck/Halide,Trass3r/Halide,darkbuck/Halide | |
7def4047c2c74d530e19e33708c890aacd243c40 | tests/regression/13-privatized/71-branched-thread-creation-priv.c | tests/regression/13-privatized/71-branched-thread-creation-priv.c | extern int __VERIFIER_nondet_int();
#include <pthread.h>
#include <assert.h>
int global = 5;
pthread_mutex_t m = PTHREAD_MUTEX_INITIALIZER;
void *t_fun(void *arg) {
return NULL;
}
int main() {
int r = __VERIFIER_nondet_int();
pthread_t id;
if (r) {
pthread_create(&id, NULL, t_fun, NULL);
}
else {
... | Add branched thread creation privatization test, where protected and mutex_inits are unsound | Add branched thread creation privatization test, where protected and mutex_inits are unsound
| C | mit | goblint/analyzer,goblint/analyzer,goblint/analyzer,goblint/analyzer,goblint/analyzer | |
c7f3302ed936837192f56accc0ad69e7504782a6 | src/libgfx/fps.h | src/libgfx/fps.h | #ifndef GFX_FPS_H
#define GFX_FPS_H
#include <chrono>
namespace GFX {
class FramesPerSecond
{
public:
FramesPerSecond() : m_millisecs(0.0), m_frames(0)
{
}
void startRender()
{
m_start = std::chrono::high_resolution_clock::now();
}
void stopRender()
{... | Add frames per second counter.. | Add frames per second counter..
| C | bsd-3-clause | timvdm/ComputerGraphics,timvdm/ComputerGraphics,timvdm/ComputerGraphics | |
429a4f4ccd8614679a2ec304bf8065c4944adfab | conceitos/basicos/gerais/0x07_loops/do_while/example_do_while.c | conceitos/basicos/gerais/0x07_loops/do_while/example_do_while.c | /*
* Author: Jhonatan Casale (jhc)
*
* Contact : jhonatan@jhonatancasale.com
* : casale.jhon@gmail.com
* : https://github.com/jhonatancasale
* : https://twitter.com/jhonatancasale
* : http://jhonatancasale.github.io/
*
* Create date Wed 1 Mar 02:02:10 BRT 2017
*
*/
#include ... | Add do while loop examples, really | Add do while loop examples, really
| C | apache-2.0 | jhonatancasale/learning-c,klaussjhc/learning-c,jhonatancasale/learning-c | |
0aaead5e49315267cd6785ec64d5b5884ae123c2 | libyaul/scu/bus/b/vdp/vdp1.h | libyaul/scu/bus/b/vdp/vdp1.h | /*
* Copyright (c) 2012-2016 Israel Jacquez
* See LICENSE for details.
*
* Israel Jacquez <mrkotfw@gmail.com>
*/
#ifndef _VDP1_H_
#define _VDP1_H_
#include <vdp1/cmdt.h>
#include <vdp1/env.h>
#include <vdp1/map.h>
#include <vdp1/vram.h>
#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */
#ifdef __cplusplu... | /*
* Copyright (c) 2012-2016 Israel Jacquez
* See LICENSE for details.
*
* Israel Jacquez <mrkotfw@gmail.com>
*/
#ifndef _VDP1_H_
#define _VDP1_H_
#include <vdp1/cmdt.h>
#include <vdp1/env.h>
#include <vdp1/map.h>
#include <vdp1/vram.h>
#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */
struct vdp1_trans... | Add VDP1 status getters for transfer end and mode status | Add VDP1 status getters for transfer end and mode status
| C | mit | ijacquez/libyaul,ijacquez/libyaul,ijacquez/libyaul,ijacquez/libyaul |
952171538ce7d5d76dabf8191e15b9ca9c9d958a | Source/DSLogger.h | Source/DSLogger.h | //
// DSLogger.h
// ControlPlane
//
// Created by David Symonds on 22/07/07.
// Modified by Vladimir Beloborodov on 01 Apr 2013.
//
@interface DSLogger : NSObject
+ (void)initialize;
+ (DSLogger *)sharedLogger;
+ (void)logFromFunction:(NSString *)fnName withInfo:(NSString *)info;
- (id)init;
- (void)dealloc;
... | //
// DSLogger.h
// ControlPlane
//
// Created by David Symonds on 22/07/07.
// Modified by Vladimir Beloborodov on 01 Apr 2013.
//
@interface DSLogger : NSObject
+ (void)initialize;
+ (DSLogger *)sharedLogger;
+ (void)logFromFunction:(NSString *)fnName withInfo:(NSString *)info;
- (id)init;
- (void)dealloc;
... | Simplify and improve definition of DSLog macro | Simplify and improve definition of DSLog macro
| C | bsd-3-clause | ajostergaard/ControlPlane,ajostergaard/ControlPlane,ajostergaard/ControlPlane,ajostergaard/ControlPlane |
062bc13039462e6f3f9baaea835ff9b863a18daf | include/cprtypes.h | include/cprtypes.h | #ifndef CPR_TYPES_H
#define CPR_TYPES_H
#include <map>
#include <string>
namespace cpr {
class CaseInsenstiveCompare {
public:
bool operator()(const std::string& a, const std::string& b) const;
private:
static void char_to_lower(char& c);
static std::string to_lower(const std... | #ifndef CPR_TYPES_H
#define CPR_TYPES_H
#include <map>
#include <string>
namespace cpr {
class CaseInsenstiveCompare {
public:
bool operator()(const std::string& a, const std::string& b) const;
private:
static void char_to_lower(char& c);
static std::string to_lower(const std... | Use C++11 `using` instead of `typedef` | Use C++11 `using` instead of `typedef` | C | mit | skystrife/cpr,msuvajac/cpr,SuperV1234/cpr,SuperV1234/cpr,skystrife/cpr,msuvajac/cpr,whoshuu/cpr,whoshuu/cpr,msuvajac/cpr,skystrife/cpr,SuperV1234/cpr,whoshuu/cpr |
4659f32c7023d6c92874e284d3c031418d634728 | t/04-nativecall/01-argless.c | t/04-nativecall/01-argless.c | #include <stdio.h>
#include <string.h>
#ifdef WIN32
#define DLLEXPORT __declspec(dllexport)
#else
#define DLLEXPORT extern
#endif
DLLEXPORT Nothing()
{
/* we don't even print something */
}
DLLEXPORT int Argless()
{
return 2;
}
DLLEXPORT int long_and_complicated_name()
{
return 3;
}
| #include <stdio.h>
#include <string.h>
#ifdef WIN32
#define DLLEXPORT __declspec(dllexport)
#else
#define DLLEXPORT extern
#endif
DLLEXPORT void Nothing()
{
/* we don't even print something */
}
DLLEXPORT int Argless()
{
return 2;
}
DLLEXPORT int long_and_complicated_name()
{
return 3;
}
| Fix compiler warnings on OS X / JVM backend | Fix compiler warnings on OS X / JVM backend
| C | artistic-2.0 | Leont/rakudo,softmoth/rakudo,salortiz/rakudo,skids/rakudo,dankogai/rakudo,laben/rakudo,ugexe/rakudo,ungrim97/rakudo,labster/rakudo,tony-o/deb-rakudodaily,salortiz/rakudo,usev6/rakudo,salortiz/rakudo,tony-o/deb-rakudodaily,teodozjan/rakudo,nbrown/rakudo,rakudo/rakudo,ungrim97/rakudo,MasterDuke17/rakudo,awwaiid/rakudo,zo... |
0afe6ff5d9626a553163739011c10c68d0a862aa | arc/arc/Model/FileObject.h | arc/arc/Model/FileObject.h | //
// FileObject.h
// arc
//
// Created by Jerome Cheng on 19/3/13.
// Copyright (c) 2013 nus.cs3217. All rights reserved.
//
#import <Foundation/Foundation.h>
@interface FileObject : NSObject {
@private
NSURL* _url;
}
// The name of this object.
@property (strong, nonatomic) NSString* name;
// The full... | //
// FileObject.h
// arc
//
// Created by Jerome Cheng on 19/3/13.
// Copyright (c) 2013 nus.cs3217. All rights reserved.
//
#import <Foundation/Foundation.h>
@interface FileObject : NSObject {
@private
NSURL* _url;
id _contents;
}
// The name of this object.
@property (strong, nonatomic) NSString* ... | Replace contents property with private array and getter. | Replace contents property with private array and getter.
| C | mit | BenTobias/arc,BenTobias/arc,BenTobias/arc,BenTobias/arc,BenTobias/arc,BenTobias/arc |
9e528bef6f5e4094e9fc497e1be3607341df7b01 | util/ncgg/main.c | util/ncgg/main.c | #ifndef NORCSID
static char rcsid[]= "$Header$";
#endif
#include <stdio.h>
char *filename;
main(argc,argv) char **argv; {
extern int nerrors;
extern int code_in_c;
extern int tabledebug;
extern int verbose;
while (argc >1 && argv[1][0]=='-') {
switch(argv[1][1]) {
case 'c':
code_in_c = 0;
break;
ca... | #ifndef NORCSID
static char rcsid[]= "$Header$";
#endif
#include <stdio.h>
char *filename;
main(argc,argv) char **argv; {
extern int nerrors;
extern int code_in_c;
extern int tabledebug;
extern int verbose;
while (argc >1 && argv[1][0]=='-') {
switch(argv[1][1]) {
case 'c':
code_in_c = 0;
break;
ca... | Allow reading from standard input | Allow reading from standard input
| C | bsd-3-clause | Godzil/ack,Godzil/ack,Godzil/ack,Godzil/ack,Godzil/ack |
c8ece79ccd6542c4a522092c02e456edc17b2355 | ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbSec.c | ArmPlatformPkg/ArmRealViewEbPkg/Library/ArmRealViewEbLibRTSM/ArmRealViewEbSec.c | /** @file
*
* Copyright (c) 2011, ARM Limited. All rights reserved.
*
* This program and the accompanying materials
* are licensed and made available under the terms and conditions of the BSD License
* which accompanies this distribution. The full text of the license may be fou... | Fix ARM RealView EB and VE builds (2) | ArmPlatformPkg: Fix ARM RealView EB and VE builds (2)
This file is missing from the earlier commit (ArmPlatformPkg: Fix ARM RealView EB and VE builds).
git-svn-id: 5648d1bec6962b0a6d1d1b40eba8cf5cdb62da3d@12235 6f19259b-4bc3-4df7-8a09-765794883524
| C | bsd-2-clause | MattDevo/edk2,MattDevo/edk2,MattDevo/edk2,MattDevo/edk2,MattDevo/edk2,MattDevo/edk2,MattDevo/edk2,MattDevo/edk2 | |
c360775fb7ed8352ca26f08c0270d21a6cb19e7f | test/Analysis/malloc.c | test/Analysis/malloc.c | // RUN: clang-cc -analyze -analyzer-experimental-internal-checks -checker-cfref -analyzer-experimental-checks -analyzer-store=region -verify %s
#include <stdlib.h>
void f1() {
int *p = malloc(10);
return; // expected-warning{{Allocated memory never released. Potential memory leak.}}
}
// THIS TEST CURRENTLY FAILS... | // RUN: clang-cc -analyze -analyzer-experimental-internal-checks -checker-cfref -analyzer-experimental-checks -analyzer-store=region -verify %s
typedef long unsigned int size_t;
void *malloc(size_t);
void free(void *);
void f1() {
int *p = malloc(10);
return; // expected-warning{{Allocated memory never released. P... | Remove test case's dependency on header file. | Remove test case's dependency on header file.
git-svn-id: ffe668792ed300d6c2daa1f6eba2e0aa28d7ec6c@88685 91177308-0d34-0410-b5e6-96231b3b80d8
| C | apache-2.0 | llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,llvm-mirror/clang,apple/swift-clang,apple/swift-clang,llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,llvm-mirror/clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,llvm-mirror/clang,apple/swift-cl... |
a0323adc1a9714c7889137413f7d59b41bfe1665 | Classes/AXKCollectionViewTools.h | Classes/AXKCollectionViewTools.h | //
// AXKCollectionViewTools.h
// Alexander Kolov
//
// Created by Alexander Kolov on 30/10/13.
// Copyright (c) 2013 Alexander Kolov. All rights reserved.
//
#import "UICollectionReusableView+ReuseIdentifier.h"
#import "UICollectionViewCell+IndexPath.h"
#import "UICollectionViewCell+ReuseIdentifier.h"
#import "UI... | //
// AXKCollectionViewTools.h
// Alexander Kolov
//
// Created by Alexander Kolov on 30/10/13.
// Copyright (c) 2013 Alexander Kolov. All rights reserved.
//
#import "UICollectionReusableView+ReuseIdentifier.h"
#import "UICollectionViewCell+IndexPath.h"
#import "UICollectionViewCell+ReuseIdentifier.h"
#import "UI... | Add files to the master header | Add files to the master header
| C | mit | akolov/AXKCollectionViewTools |
1416089f44fab6fa35e3523aed3408ee30457a7f | include/llvm/Bytecode/Reader.h | include/llvm/Bytecode/Reader.h | //===-- llvm/Bytecode/Reader.h - Reader for VM bytecode files ----*- C++ -*--=//
//
// This functionality is implemented by the lib/BytecodeReader library.
// This library is used to read VM bytecode files from an iostream.
//
// Note that performance of this library is _crucial_ for performance of the
// JIT type appl... | //===-- llvm/Bytecode/Reader.h - Reader for VM bytecode files ----*- C++ -*--=//
//
// This functionality is implemented by the lib/BytecodeReader library.
// This library is used to read VM bytecode files from an iostream.
//
// Note that performance of this library is _crucial_ for performance of the
// JIT type appl... | Fix prototype to make function. | Fix prototype to make function.
git-svn-id: 0ff597fd157e6f4fc38580e8d64ab130330d2411@2939 91177308-0d34-0410-b5e6-96231b3b80d8
| C | apache-2.0 | llvm-mirror/llvm,chubbymaggie/asap,apple/swift-llvm,chubbymaggie/asap,apple/swift-llvm,dslab-epfl/asap,GPUOpen-Drivers/llvm,dslab-epfl/asap,apple/swift-llvm,GPUOpen-Drivers/llvm,dslab-epfl/asap,apple/swift-llvm,llvm-mirror/llvm,dslab-epfl/asap,dslab-epfl/asap,GPUOpen-Drivers/llvm,chubbymaggie/asap,chubbymaggie/asap,llv... |
eda3142317dd8e9e8bfbd73da430dcba57be768c | include/kotlib/compat/msvc.h | include/kotlib/compat/msvc.h | /*!
* @file msvc.h
* @brief Provide MSVC compatibility
* @author koturn
*/
#ifndef KOTLIB_COMPAT_MSVC_H
#define KOTLIB_COMPAT_MSVC_H
#ifndef _MSC_VER
# define _declspec(x)
# define __declspec(x)
#endif
#endif // KOTLIB_COMPAT_MSVC_H
| Add header to provide MSVC compatibility | Add header to provide MSVC compatibility
| C | mit | koturn/kotlib,koturn/kotlib | |
2f9f822c764b9635807326d6fff442ce799d4438 | runtime/platform/utils_win.h | runtime/platform/utils_win.h | // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
#ifndef PLATFORM_UTILS_WIN_H_
#define PLATFORM_UTILS_WIN_H_
#include <intrin.h>
namespace dart {
inl... | // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
#ifndef PLATFORM_UTILS_WIN_H_
#define PLATFORM_UTILS_WIN_H_
#include <intrin.h>
namespace dart {
inl... | Fix the build breakage on Windows caused by CountTrailingZeros. | Fix the build breakage on Windows caused by CountTrailingZeros.
Review URL: https://chromiumcodereview.appspot.com//10818020
git-svn-id: c93d8a2297af3b929165606efe145742a534bc71@9838 260f80e4-7a28-3924-810f-c04153c831b5
| C | bsd-3-clause | dart-lang/sdk,dart-archive/dart-sdk,dart-archive/dart-sdk,dartino/dart-sdk,dartino/dart-sdk,dart-lang/sdk,dart-archive/dart-sdk,dartino/dart-sdk,dartino/dart-sdk,dartino/dart-sdk,dart-archive/dart-sdk,dart-lang/sdk,dart-lang/sdk,dartino/dart-sdk,dart-archive/dart-sdk,dart-lang/sdk,dart-archive/dart-sdk,dart-archive/dar... |
4cfaf8cd78fdf46a6a6831e2c5ff4eae34809a34 | lab_2_brightness/main_window.h | lab_2_brightness/main_window.h | #ifndef MAIN_WINDOW_H
#define MAIN_WINDOW_H
#include <QGroupBox>
#include <QVBoxLayout>
#include <base_window.h>
class MainWindow : public gui::BaseWindow {
public:
MainWindow();
virtual ~MainWindow();
protected:
/**
* Callback for resize window.
*
* @param event[in] Event params.
*/... | #ifndef MAIN_WINDOW_H
#define MAIN_WINDOW_H
#include <QGroupBox>
#include <QVBoxLayout>
#include <base_window.h>
class MainWindow : public gui::BaseWindow {
public:
MainWindow();
virtual ~MainWindow();
protected:
/**
* Callback for resize window.
*
* @param event[in] Event params.
*/... | Add slots for second lab | Add slots for second lab
| C | mit | Dmitry94/Image_Processing,Dmitry94/Image_Processing,Dmitry94/Image_Processing |
80d8a396ee09d9117594ce512ba4133a996568ae | cras/src/server/cras_volume_curve.c | cras/src/server/cras_volume_curve.c | /* Copyright (c) 2012 The Chromium OS Authors. All rights reserved.
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#include <stddef.h>
/* Default to 1dB per tick. Volume level 100 = 0dB level 0 = -100dB. */
long cras_volume_curve_get_db_for_index(size_t vo... | /* Copyright (c) 2012 The Chromium OS Authors. All rights reserved.
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#include <stddef.h>
/* Default to 1dB per tick.
* Volume = 100 -> 0dB.
* Volume = 0 -> -100dB. */
long cras_volume_curve_get_db_for_index(si... | Fix poorly worded volume comment. | CRAS: Fix poorly worded volume comment.
BUG=none
TEST=none
Change-Id: I7a5854c84bc48a393fa65c374fddd83ce7721f8d
Signed-off-by: Dylan Reid <c791bfe44996c1eed9c7149a0c5f12a86d58eb85@chromium.org>
| C | bsd-3-clause | drinkcat/adhd,drinkcat/adhd,drinkcat/adhd,drinkcat/adhd,drinkcat/adhd,drinkcat/adhd |
0d766ad199ed257aea53398011d0c833f6cc86d7 | runtime/CLSmith.h | runtime/CLSmith.h | #ifndef RANDOM_RUNTIME_H
#define RANDOM_RUNTIME_H
#include "safe_math_macros.h"
static uint32_t crc32_tab[256];
static uint32_t crc32_context = 0xFFFFFFFFUL;
/*static void
crc32_gentab (void)
{
uint32_t crc;
const uint32_t poly = 0xEDB88320UL;
int i, j;
for (i = 0; i < 256; i++) {
crc = i;
for (j = 8; j >... | Include for OpenCL progs. Similar to the csmith include. Will only work with the minimal version at the moment. | Include for OpenCL progs. Similar to the csmith include. Will only work with the minimal version at the moment.
| C | bsd-2-clause | ChrisLidbury/CLSmith,ChrisLidbury/CLSmith,ChrisLidbury/CLSmith,ChrisLidbury/CLSmith,ChrisLidbury/CLSmith | |
bb7e3ee1c8bb59b4fde439565bd1757880cbb8ec | xchainer/arithmetic_ops.h | xchainer/arithmetic_ops.h | #pragma once
#include "xchainer/macro.h"
namespace xchainer {
template <typename T>
class ArithmeticOps {
public:
XCHAINER_HOST_DEVICE static T Add(T lhs, T rhs) { return lhs + rhs; }
XCHAINER_HOST_DEVICE static T Multiply(T lhs, T rhs) { return lhs * rhs; }
XCHAINER_HOST_DEVICE static T Divide(T lhs, T ... | #pragma once
#include "xchainer/macro.h"
namespace xchainer {
template <typename T>
class ArithmeticOps {
public:
XCHAINER_HOST_DEVICE static T Add(T lhs, T rhs) { return lhs + rhs; }
XCHAINER_HOST_DEVICE static T Multiply(T lhs, T rhs) { return lhs * rhs; }
XCHAINER_HOST_DEVICE static T Divide(T lhs, T ... | Add a TODO comment about boolean division | Add a TODO comment about boolean division
| C | mit | okuta/chainer,pfnet/chainer,hvy/chainer,ktnyt/chainer,okuta/chainer,jnishi/chainer,wkentaro/chainer,keisuke-umezawa/chainer,niboshi/chainer,keisuke-umezawa/chainer,hvy/chainer,ktnyt/chainer,wkentaro/chainer,niboshi/chainer,okuta/chainer,ktnyt/chainer,jnishi/chainer,niboshi/chainer,jnishi/chainer,keisuke-umezawa/chainer... |
8accd2d73920c43de6e3859f3148ff942b85f28d | scripts/stm32/embox_stm32_it_template.c | scripts/stm32/embox_stm32_it_template.c | /**
* GENERATED FILE
*/
#include <kernel/irq.h>
#include "main.h"
#include "stm32_PLATFORM_xx_it.h"
#define EMBOX_STM32_IRQ_HANDLER(prefix) \
static irq_return_t embox_##prefix##_IRQHandler(unsigned int irq_nr, void *data) { \
prefix##_IRQHandler(); \
return IRQ_HANDLED; \
}
_IRQ_HANDLERS_DECLARE_
extern vo... | Add forgotten file for 3f2e592 | stm32: Add forgotten file for 3f2e592
| C | bsd-2-clause | embox/embox,embox/embox,embox/embox,embox/embox,embox/embox,embox/embox | |
309d7d5860070360f423f25d55cfb1d5a2e9a8ca | lib/stdarg.h | lib/stdarg.h | #ifndef __STDARG_H
#define __STDARG_H
#include "sys/types.h"
typedef void *va_list;
#define va_start(l, arg) l = (void *)&arg
#define va_arg(l, type) (*(type *)(l += __WORDSIZE / 8))
#define va_end(l)
#endif
| #ifndef __STDARG_H
#define __STDARG_H
#include "sys/types.h"
typedef void *va_list;
#define va_start(l, arg) l = (void *)&arg
/*
* va_arg assumes arguments are promoted to
* machine-word size when pushed onto the stack
*/
#define va_arg(l, type) (*(type *)(l += sizeof *l))
#define va_end(l)
#endif
| Move by machine word size | Move by machine word size
| C | mit | 8l/ucc-c-compiler,8l/ucc-c-compiler,8l/ucc-c-compiler,8l/ucc-c-compiler |
c28e0e7d97aba40968b0b9ca96cb7d3b4b7b1fef | src/mesa/drivers/dri/r600/r700_driconf.h | src/mesa/drivers/dri/r600/r700_driconf.h | /*
* Copyright (C) 2008-2009 Advanced Micro Devices, Inc.
*
* 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,... | Add missing file from local. | Add missing file from local.
| C | mit | jbarczak/glsl-optimizer,adobe/glsl2agal,KTXSoftware/glsl2agal,jbarczak/glsl-optimizer,mcanthony/glsl-optimizer,mcanthony/glsl-optimizer,benaadams/glsl-optimizer,wolf96/glsl-optimizer,metora/MesaGLSLCompiler,zeux/glsl-optimizer,mapbox/glsl-optimizer,dellis1972/glsl-optimizer,wolf96/glsl-optimizer,djreep81/glsl-optimizer... | |
afa8074ccfc405d91803f946d4dcc878886620d0 | WebDriverAgentLib/Utilities/FBConfiguration.h | WebDriverAgentLib/Utilities/FBConfiguration.h | /**
* Copyright (c) 2015-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*/
#import <F... | /**
* Copyright (c) 2015-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*/
#import <F... | Switch from class property to methods | Switch from class property to methods
Summary:
Some recent changes use class properties, which break building with Xcode 7. This exposes the same API without the new syntax.
Closes https://github.com/facebook/WebDriverAgent/pull/539
Differential Revision: D4880364
Pulled By: marekcirkos
fbshipit-source-id: dace4b24... | C | bsd-3-clause | PiranhaTeam/WebDriverAgent,ymin/WebDriverAgent,PiranhaTeam/WebDriverAgent,PiranhaTeam/WebDriverAgent,ymin/WebDriverAgent,ymin/WebDriverAgent,PiranhaTeam/WebDriverAgent,ymin/WebDriverAgent,PiranhaTeam/WebDriverAgent |
1b30978d7c553bdb9786286374f02c9e41ebb6bd | arch/sgi/include/vmparam.h | arch/sgi/include/vmparam.h | /* $OpenBSD: vmparam.h,v 1.9 2011/05/30 22:25:22 oga Exp $ */
/* public domain */
#ifndef _MACHINE_VMPARAM_H_
#define _MACHINE_VMPARAM_H_
#define VM_PHYSSEG_MAX 32 /* Max number of physical memory segments */
/*
* On Origin and Octane families, DMA to 32-bit PCI devices is restricted.
*
* Systems with physical mem... | /* $OpenBSD: vmparam.h,v 1.10 2014/07/13 15:48:32 miod Exp $ */
/* public domain */
#ifndef _MACHINE_VMPARAM_H_
#define _MACHINE_VMPARAM_H_
#define VM_PHYSSEG_MAX 32 /* Max number of physical memory segments */
#include <mips64/vmparam.h>
#endif /* _MACHINE_VMPARAM_H_ */
| Remove stale comment which used to explain why we had a special 31-bit freelist for DMA, back when this was applicable. | Remove stale comment which used to explain why we had a special 31-bit freelist
for DMA, back when this was applicable.
| C | isc | orumin/openbsd-efivars,orumin/openbsd-efivars,orumin/openbsd-efivars,orumin/openbsd-efivars |
3218e01b76602eaa399a7e43caa219d7330855d7 | iActiveRecord/Classes/class_getSubclasses.h | iActiveRecord/Classes/class_getSubclasses.h | //
// class_getSubclasses.h
// iActiveRecord
//
// Created by Alex Denisov on 21.03.12.
// Copyright (c) 2012 okolodev.org. All rights reserved.
//
#import <Foundation/Foundation.h>
#import <objc/runtime.h>
static NSArray *class_getSubclasses(Class parentClass) {
int numClasses = objc_getClassList(NULL, 0);
... | //
// class_getSubclasses.h
// iActiveRecord
//
// Created by Alex Denisov on 21.03.12.
// Copyright (c) 2012 okolodev.org. All rights reserved.
//
#import <Foundation/Foundation.h>
#import <objc/runtime.h>
static NSArray *class_getSubclasses(Class parentClass) {
int numClasses = objc_getClassList(NULL, 0);
... | Fix for crashes in iOS 10 | Fix for crashes in iOS 10 | C | mit | AlexDenisov/iActiveRecord,3dcl/iActiveRecord,3dcl/iActiveRecord,AlexDenisov/iActiveRecord,3dcl/iActiveRecord,AlexDenisov/iActiveRecord,3dcl/iActiveRecord |
2760cf5a705f1fe853cd163f534f5cc2106cdb8f | src/math/p_tanh.c | src/math/p_tanh.c | #include <pal.h>
/**
*
* Calculates the hyperbolic tangent of the input vector 'a'.
* Angles are specified in radians.
*
* @param a Pointer to input vector
*
* @param c Pointer to output vector
*
* @param n Size of 'a' and 'c' vector.
*
* @return None
*
*/
#include <math.h>
void p_tanh_f3... | #include <pal.h>
#include "p_exp.h"
/*
* tanh z = sinh z / cosh z
* = (exp z - exp -z) / (exp z + ezp -z)
* = (exp 2z - 1) / (exp 2z + 1)
*/
static inline float _p_tanh(const float z)
{
float exp_2z = _p_exp(2.f * z);
return (exp_2z - 1.f) / (exp_2z + 1.f);
}
/**
*
* Calculates the hyperb... | Implement the hyperbolic tangent function. | math:tanh: Implement the hyperbolic tangent function.
Signed-off-by: Mansour Moufid <ac5f6b12fab5e0d4efa7215e6c2dac9d55ab77dc@gmail.com>
| C | apache-2.0 | parallella/pal,debug-de-su-ka/pal,parallella/pal,olajep/pal,debug-de-su-ka/pal,mateunho/pal,8l/pal,eliteraspberries/pal,parallella/pal,aolofsson/pal,mateunho/pal,eliteraspberries/pal,olajep/pal,mateunho/pal,parallella/pal,parallella/pal,eliteraspberries/pal,olajep/pal,8l/pal,aolofsson/pal,olajep/pal,debug-de-su-ka/pal,... |
c530ab012c5f8053453e5be3c3c093cc7fba10ed | base/inc/Htypes.h | base/inc/Htypes.h | /* @(#)root/base:$Name: $:$Id: Htypes.h,v 1.1.1.1 2000/05/16 17:00:39 rdm Exp $ */
/*************************************************************************
* Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
* All rights reserved. *
* ... | /* @(#)root/base:$Name: $:$Id: Htypes.h,v 1.2 2000/06/13 12:25:52 brun Exp $ */
/*************************************************************************
* Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
* All rights reserved. *
* ... | Add more comments describing Stat_t and Axis_t | Add more comments describing Stat_t and Axis_t
git-svn-id: acec3fd5b7ea1eb9e79d6329d318e8118ee2e14f@3097 27541ba8-7e3a-0410-8455-c3a389f83636
| C | lgpl-2.1 | nilqed/root,davidlt/root,omazapa/root-old,krafczyk/root,sbinet/cxx-root,zzxuanyuan/root-compressor-dummy,esakellari/root,sirinath/root,zzxuanyuan/root,esakellari/my_root_for_test,pspe/root,karies/root,buuck/root,sbinet/cxx-root,mhuwiler/rootauto,sirinath/root,arch1tect0r/root,perovic/root,veprbl/root,mhuwiler/rootauto,... |
8c5a18cd999cfd0edc1871e5cf797ff5e04ea20e | libevmjit/Common.h | libevmjit/Common.h | #pragma once
#include <vector>
#include <boost/multiprecision/cpp_int.hpp>
namespace dev
{
namespace eth
{
namespace jit
{
using byte = uint8_t;
using bytes = std::vector<byte>;
using u256 = boost::multiprecision::uint256_t;
using bigint = boost::multiprecision::cpp_int;
struct NoteChannel {}; // FIXME: Use some lo... | #pragma once
#include <vector>
#include <boost/multiprecision/cpp_int.hpp>
namespace dev
{
namespace eth
{
namespace jit
{
using byte = uint8_t;
using bytes = std::vector<byte>;
using u256 = boost::multiprecision::uint256_t;
using bigint = boost::multiprecision::cpp_int;
struct NoteChannel {}; // FIXME: Use some lo... | Fix some GCC initialization warnings | Fix some GCC initialization warnings
| C | mit | debris/evmjit,debris/evmjit,ethcore/evmjit,ethcore/evmjit |
787355ea64fb4a8967718cb1331b7cd1fa0d02e4 | test/cases/vla/argument_eval.c | test/cases/vla/argument_eval.c | // RUN: %ocheck 0 %s
// RUN: %ocheck 0 %s -fstack-protector-all
extern void abort(void);
as, bs, fs;
static int a(){ as++; return 2; }
static int b(){ bs++; return 2; }
static int f(int p[a()][b()])
{
fs++;
return p[0][0] + p[0][1] + p[1][0] + p[1][1];
}
static void assert(_Bool b)
{
if(!b)
abort();
}
int ma... | // RUN: %ocheck 0 %s
// RUN: %ocheck 0 %s -fstack-protector-all
extern void abort(void);
as, bs, fs;
static int a(){ as++; return 2; }
static int b(){ bs++; return 2; }
static int f(int p[a()][b()])
{
fs++;
return p[0][0] // 5
+ p[0][1] // 4
+ p[1][0] // 3
+ p[1][1] // 2
+ sizeof(p) // sizeof(T (*)[...]) ... | Improve checks for vla-argument test | Improve checks for vla-argument test
| C | mit | bobrippling/ucc-c-compiler,bobrippling/ucc-c-compiler,bobrippling/ucc-c-compiler |
1f4f7b5c2796c5e950457563e6221351791958e6 | lib/int_util.h | lib/int_util.h | /* ===-- int_util.h - internal utility functions ----------------------------===
*
* The LLVM Compiler Infrastructure
*
* This file is dual licensed under the MIT and the University of Illinois Open
* Source Licenses. See LICENSE.TXT for details.
*
* ===---------------------------------------... | /* ===-- int_util.h - internal utility functions ----------------------------===
*
* The LLVM Compiler Infrastructure
*
* This file is dual licensed under the MIT and the University of Illinois Open
* Source Licenses. See LICENSE.TXT for details.
*
* ===---------------------------------------... | Remove __attribute__((weak)) on function prototype. It has a different meaning on prototypes then it does on definitions. It is not needed on the prototype and causes build failures for static codegen | Remove __attribute__((weak)) on function prototype. It has a different meaning on prototypes then it does on definitions. It is not needed on the prototype and causes build failures for static codegen
git-svn-id: c199f293c43da69278bea8e88f92242bf3aa95f7@149720 91177308-0d34-0410-b5e6-96231b3b80d8
| C | apache-2.0 | llvm-mirror/compiler-rt,llvm-mirror/compiler-rt,llvm-mirror/compiler-rt,llvm-mirror/compiler-rt,llvm-mirror/compiler-rt |
01cfab200399196583a306ad90e56349caf1925d | src/unshield-deobfuscate.c | src/unshield-deobfuscate.c | #include <stdio.h>
#include <stdlib.h>
#include "../lib/libunshield.h"
int main(int argc, char** argv)
{
unsigned seed = 0;
FILE* input = NULL;
FILE* output = NULL;
size_t size;
unsigned char buffer[16384];
if (argc != 3)
{
fprintf(stderr,
"Syntax:\n"
" %s INPUT-FILE OUTPUT-FILE\n... | #include <stdio.h>
#include <stdlib.h>
#include "../lib/libunshield.h"
int main(int argc, char** argv)
{
unsigned seed = 0;
FILE* input = NULL;
FILE* output = NULL;
size_t size;
unsigned char buffer[16384];
if (argc != 3)
{
fprintf(stderr,
"Syntax:\n"
" %s INPUT-FILE OUTPUT-FILE\n... | Fix for binary files on Windows | Fix for binary files on Windows
Thanks @Djamana
Closes #46
| C | mit | twogood/unshield,twogood/unshield |
1bd3ca1cda84cf6eb32c99d83961904fe0bbc4b2 | lispy.h | lispy.h | #ifndef _LISPY_H
#define _LISPY_H
#include "lib/mpc.h"
/* Compile these functions if we're on Windows */
#ifdef _WIN32
static char buffer[2048];
char* readline(char* prompt) {
fputs(prompt, stdout);
fgets(buffer, 2048, stdin);
char* cpy = malloc(strlen(buffer) + 1);
strcpy(cpy, buffer);
cpy[strlen(cpy) - 1] = ... | Add header file to git | Add header file to git
| C | mit | mahimahi42/lispy | |
c0d5a95745e15c8f215a66445cca5e05e46e0c10 | arc/arc/Controllers/Protocols/FolderViewControllerDelegate.h | arc/arc/Controllers/Protocols/FolderViewControllerDelegate.h | //
// FolderViewControllerDelegate.h
// arc
//
// Created by Jerome Cheng on 17/4/13.
// Copyright (c) 2013 nus.cs3217. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "File.h"
#import "Folder.h"
@class FolderViewController;
@protocol FolderViewControllerDelegate <NSObject>
- (void)folderViewC... | //
// FolderViewControllerDelegate.h
// arc
//
// Created by Jerome Cheng on 17/4/13.
// Copyright (c) 2013 nus.cs3217. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "File.h"
#import "Folder.h"
@class FolderViewController;
@protocol FolderViewControllerDelegate <NSObject>
// Allows delegate ... | Add methods to notify FolderView delegate when edit mode is toggled. | Add methods to notify FolderView delegate when edit mode is toggled.
| C | mit | BenTobias/arc,BenTobias/arc,BenTobias/arc,BenTobias/arc,BenTobias/arc,BenTobias/arc |
7f736d700feb00e8a5d39c687f1f118f067429d6 | projects/com.oracle.truffle.llvm.test/tests/c/long-to-function-ptr-call.c | projects/com.oracle.truffle.llvm.test/tests/c/long-to-function-ptr-call.c | void abort();
int add(int a, int b) { return a + b; }
int sub(int a, int b) { return a - b; }
int mul(int a, int b) { return a * b; }
int div(int a, int b) { return a / b; }
int rem(int a, int b) { return a % b; }
long arr[5] = {(long)&add, (long)&sub, (long)&mul, (long)&div, (long)&rem };
int main() {
int i;
i... | Add test case for casting longs to function pointers | Add test case for casting longs to function pointers
| C | bsd-3-clause | lxp/sulong,crbb/sulong,lxp/sulong,PrinzKatharina/sulong,lxp/sulong,crbb/sulong,lxp/sulong,PrinzKatharina/sulong,crbb/sulong,crbb/sulong,PrinzKatharina/sulong,PrinzKatharina/sulong | |
56a77a274be12217e07ca8c4b5e2dabdac3c0c2b | peertalk/PTPrivate.h | peertalk/PTPrivate.h | #if (defined(__IPHONE_OS_VERSION_MIN_REQUIRED) && (!defined(__IPHONE_6_0) || __IPHONE_OS_VERSION_MIN_REQUIRED < __IPHONE_6_0)) || \
(defined(__MAC_OS_X_VERSION_MIN_REQUIRED) && (!defined(__MAC_10_8) || __MAC_OS_X_VERSION_MIN_REQUIRED < __MAC_10_8))
#define PT_DISPATCH_RETAIN_RELEASE 1
#endif
#if (!defined(PT_DISPA... | #if (defined(__IPHONE_OS_VERSION_MIN_REQUIRED) && (!defined(__IPHONE_6_0) || __IPHONE_OS_VERSION_MIN_REQUIRED < __IPHONE_6_0)) || \
(defined(__MAC_OS_X_VERSION_MIN_REQUIRED) && (!defined(__MAC_10_8) || __MAC_OS_X_VERSION_MIN_REQUIRED < __MAC_10_8))
#define PT_DISPATCH_RETAIN_RELEASE 1
#else
#define PT_DISPATCH_RETA... | Synchronize logical grouping of defines | Synchronize logical grouping of defines
| C | mit | rsms/peertalk,rsms/peertalk,rsms/peertalk |
ae3b44ac78004f3e03173b13a0d1cc456677370a | objc/message.h | objc/message.h | #ifndef _OBJC_MESSAGE_H_
#define _OBJC_MESSAGE_H_
#if defined(__x86_64) || defined(__i386) || defined(__arm__) || \
defined(__mips_n64) || defined(__mips_n32)
/**
* Standard message sending function. This function must be cast to the
* correct types for the function before use. The first argument is the
* receiv... | Fix clang's stupid warning to work around a bug in OS X headers... | Fix clang's stupid warning to work around a bug in OS X headers...
| C | mit | darlinghq/darling-libobjc2,davidchisnall/libobjc2,darlinghq/darling-libobjc2,gnustep/libobjc2,davidchisnall/libobjc2,gnustep/libobjc2,crystax/android-vendor-libobjc2,crystax/android-vendor-libobjc2,ngrewe/libobjc2,ngrewe/libobjc2 | |
130f6f3b116db2168b0656d8e1cf4bb7053388ec | cuser/acpica/acenv_header.h | cuser/acpica/acenv_header.h | #define ACPI_MACHINE_WIDTH 64
#define ACPI_SINGLE_THREADED
#define ACPI_DEBUG_OUTPUT
#define ACPI_DISASSEMBLER
#define ACPI_USE_LOCAL_CACHE
#define ACPI_INLINE inline
#define ACPI_USE_NATIVE_DIVIDE
// Depends on threading support
#define ACPI_DEBUGGER
#define DEBUGGER_THREADING DEBUGGER_SINGLE_THREADED
// Depends on d... | #define ACPI_MACHINE_WIDTH 64
#define ACPI_SINGLE_THREADED
#define ACPI_DEBUG_OUTPUT
#define ACPI_DISASSEMBLER
#define ACPI_USE_LOCAL_CACHE
#define ACPI_INLINE inline
#define ACPI_USE_NATIVE_DIVIDE
// Depends on threading support
#define ACPI_DEBUGGER
#define DEBUGGER_THREADING DEBUGGER_SINGLE_THREADED
// Depends on d... | Use GCC's __FUNCTION__ for ACPI_GET_FUNCTION_NAME | Use GCC's __FUNCTION__ for ACPI_GET_FUNCTION_NAME
| C | mit | olsner/os,olsner/os,olsner/os,olsner/os |
1d092135d5973e22550e260c944c2c5e7678923a | src/main.c | src/main.c | #include <stdlib.h>
#include <ncurses.h>
/**
* The main function, called when atcso is started (duh).
*/
int main(int argc, char** argv) {
initscr();
raw(); // Disable line buffering
noecho(); // Don't show things the user is typing
printw("hai wurld");
refresh();
while (getch() != ... | #include <stdlib.h>
#include <ncurses.h>
#include <time.h>
typedef struct {
} AtcsoData;
void mainloop();
WINDOW *createRadarWin();
void updateRadarWin(AtcsoData *data, WINDOW *radarWin);
/**
* The main function, called when atcso is started (duh).
*/
int main(int argc, char **argv) {
initscr();
raw(); ... | Implement outline of "radar window" | Implement outline of "radar window"
The radar window is simply the "main" window, with all the planes and
stuff.
This commit draws the outline of this window, and it also adds a few
pieces of code that will serve as a framework for future inter-window
communication.
| C | mit | KeyboardFire/atcso |
07eb6bd1593c5e96c68d418ea23706e27874b7e8 | features/netsocket/nsapi.h | features/netsocket/nsapi.h |
/** \addtogroup netsocket */
/** @{*/
/* nsapi.h - The network socket API
* Copyright (c) 2015 ARM Limited
*
* 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.or... |
/** \addtogroup netsocket */
/** @{*/
/* nsapi.h - The network socket API
* Copyright (c) 2015 ARM Limited
*
* 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.or... | Add missing include for TLSSocket | Add missing include for TLSSocket
TCP and UDP sockets are automatically available when mbed.h is
included in an application.
This change lets the TLSSocket be used in the same way.
| C | apache-2.0 | andcor02/mbed-os,andcor02/mbed-os,andcor02/mbed-os,andcor02/mbed-os,andcor02/mbed-os,kjbracey-arm/mbed,kjbracey-arm/mbed,kjbracey-arm/mbed,mbedmicro/mbed,mbedmicro/mbed,mbedmicro/mbed,mbedmicro/mbed,kjbracey-arm/mbed,mbedmicro/mbed,andcor02/mbed-os |
88dd832b22b4927f9d571158c0429df0a50fd6d8 | sigaltstack.c | sigaltstack.c | #include <stdio.h>
#include <signal.h>
#include <unistd.h>
#include <assert.h>
#include <stdlib.h>
#include <setjmp.h>
jmp_buf try;
void handler(int sig) {
static int i = 0;
write(2, "stack overflow\n", 15);
longjmp(try, ++i);
_exit(1);
}
unsigned recurse(unsigned x) {
return recurse(x)+1;
}
int ma... | #include <stdio.h>
#include <signal.h>
#include <unistd.h>
#include <assert.h>
#include <stdlib.h>
#include <setjmp.h>
jmp_buf try;
void handler(int sig) {
static int i = 0;
printf("stack overflow %d\n", i);
longjmp(try, ++i);
assert(0);
}
unsigned recurse(unsigned x) {
return recurse(x)+1;
}
int m... | Add assert, more print info | Add assert, more print info
| C | apache-2.0 | danluu/setjmp-longjmp-ucontext-snippets,danluu/setjmp-longjmp-ucontext-snippets |
13bdfcd1c659359289f373052b21fb9f998dcc0b | test/Preprocessor/microsoft-import.c | test/Preprocessor/microsoft-import.c | // RUN: %clang_cc1 -E -fms-compatibility %s 2>&1 | grep 'doh.c:100:2: error: #import of type library is an unsupported Microsoft feature'
// RUN: %clang_cc1 -E -fms-compatibility %s 2>&1 | grep 'doh.c:200:2: error: #import of type library is an unsupported Microsoft feature'
// RUN: %clang_cc1 -E -fms-compatibility %s ... | // RUN: %clang_cc1 -E -verify -fms-compatibility %s
#import "pp-record.h" // expected-error {{#import of type library is an unsupported Microsoft feature}}
// Test attributes
#import "pp-record.h" no_namespace, auto_rename // expected-error {{#import of type library is an unsupported Microsoft feature}}
#import "pp-... | Migrate a test to -verify | Migrate a test to -verify
git-svn-id: ffe668792ed300d6c2daa1f6eba2e0aa28d7ec6c@173716 91177308-0d34-0410-b5e6-96231b3b80d8
| C | apache-2.0 | llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,llvm-mirror/clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,llvm-mirror/cl... |
b0e5fd7a307529651190ddd452f54b25d1c38a78 | src/ptwise/updates.h | src/ptwise/updates.h |
// Upwind updater
void updater_first_order_dimensional_splitting(real* q,
const real* aux,
const int nx,
const int ny,
const real* ... | Add first order dimensional sweep updating | Add first order dimensional sweep updating
| C | bsd-3-clause | ManyClaw/ManyClaw,ManyClaw/ManyClaw,ManyClaw/ManyClaw | |
49248d85df3037126b8282cae0610f9c499da548 | tests/compiler/cxx_runtime.h | tests/compiler/cxx_runtime.h | //
// Copyright 2013 Jeff Bush
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed t... | //
// Copyright 2013 Jeff Bush
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed t... | Make these a bit more correct | Make these a bit more correct
| C | apache-2.0 | FulcronZ/NyuziProcessor,jbush001/NyuziProcessor,FulcronZ/NyuziProcessor,FulcronZ/NyuziProcessor,FulcronZ/NyuziProcessor,jbush001/NyuziProcessor,hoangt/NyuziProcessor,jbush001/NyuziProcessor,jbush001/NyuziProcessor,hoangt/NyuziProcessor,hoangt/NyuziProcessor,hoangt/NyuziProcessor,jbush001/NyuziProcessor,jbush001/NyuziPr... |
9f51152f683a4d5f48d6dd2db66b2909fd183b3c | Wangscape/codecs/TilesetCodec.h | Wangscape/codecs/TilesetCodec.h | #pragma once
#include <spotify/json.hpp>
#include "Tileset.h"
using namespace spotify::json::codec;
namespace spotify
{
namespace json
{
template<>
struct default_codec_t<Tileset>
{
static object_t<Tileset> codec()
{
auto codec = object<Tileset>();
codec.required("resolution", &Tileset::res... | Add a codec for Tileset | Add a codec for Tileset
| C | mit | serin-delaunay/Wangscape,Wangscape/Wangscape,serin-delaunay/Wangscape,Wangscape/Wangscape,Wangscape/Wangscape | |
7fe3a44fbf3767cc27c2c91dd0f328839be714a6 | src/commands.h | src/commands.h | #ifndef LACO_COMMANDS_H
#define LACO_COMMANDS_H
struct LacoState;
/**
* Gets passed ever line to see if it matches one of the REPL command. If it
* does, that command will be executed.
*/
void laco_handle_command(struct LacoState* laco, char* line);
#endif /* LACO_COMMANDS_H */
| #ifndef LACO_COMMANDS_H
#define LACO_COMMANDS_H
struct LacoState;
typedef void (*LacoHandler)(struct LacoState* laco, const char** arguments);
struct LacoCommand {
const char** matches;
LacoHandler handler;
};
/**
* Gets passed ever line to see if it matches one of the REPL command. If it
* does, that command... | Define data types for structured command handling | Define data types for structured command handling
| C | bsd-2-clause | sourrust/laco |
97ccfa599c0479a4ea9b4df9291c564d5afd80e3 | test/Analysis/inline2.c | test/Analysis/inline2.c | // RUN: %clang_cc1 -analyze -inline-call -analyzer-store region -analyze-function f2 -verify %s
// Test parameter 'a' is registered to LiveVariables analysis data although it
// is not referenced in the function body.
int f1(int a) {
return 1;
}
void f2() {
int x;
x = f1(1);
}
| // RUN: %clang_cc1 -analyze -inline-call -analyzer-store region -analyze-function f2 -verify %s
// Test parameter 'a' is registered to LiveVariables analysis data although it
// is not referenced in the function body.
// Before processing 'return 1;', in RemoveDeadBindings(), we query the liveness
// of 'a', because ... | Add comments to test case. | Add comments to test case.
git-svn-id: ffe668792ed300d6c2daa1f6eba2e0aa28d7ec6c@97619 91177308-0d34-0410-b5e6-96231b3b80d8
| C | apache-2.0 | llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,apple/swift-clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,apple/swift-clang,llvm-mirror/clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-cl... |
aee95684b289b3a34702454fbd1fa1bbd4e48d38 | src/gfx/gl/texture.h | src/gfx/gl/texture.h | /*
* Copyright (C) 2015 Luke San Antonio
* All rights reserved.
*/
#pragma once
#include "glad/glad.h"
#include "../texture.h"
namespace game { namespace gfx { namespace gl
{
struct GL_Texture : public Texture
{
void allocate_(Vec<int> const&, Image_Format) noexcept override;
inline void blit_data_(Volu... | /*
* Copyright (C) 2015 Luke San Antonio
* All rights reserved.
*/
#pragma once
#include "glad/glad.h"
#include "../texture.h"
namespace game { namespace gfx { namespace gl
{
struct GL_Texture : public Texture
{
void allocate_(Vec<int> const&, Image_Format) noexcept override;
inline void blit_data_(Volu... | Verify array of colors is contigous | Verify array of colors is contigous
| C | bsd-3-clause | RedCraneStudio/redcrane-engine,RedCraneStudio/redcrane-engine,RedCraneStudio/redcrane-engine,RedCraneStudio/redcrane-engine |
909d0e643ab120ef34344d4b589408ac50d23570 | src/io/disk.h | src/io/disk.h | #ifndef DISK_H
#define DISK_H
#include "../process/process.h"
#ifdef __i386__
#define IOPRIO_GET 290
#elif __x86_64__
#define IOPRIO_GET 252
#endif
#define IOPRIO_WHO_PROCESS 1
#define IOPRIO_CLASS_SHIFT (13)
#define IOPRIO_PRIO_MASK ((1UL << IOPRIO_CLASS_SHIFT) - 1)
#define PRIOLEN 8
char *filesystem_type(void)... | #ifndef DISK_H
#define DISK_H
#include <stdint.h>
#include "../process/process.h"
#ifdef __i386__
#define IOPRIO_GET 290
#elif __x86_64__
#define IOPRIO_GET 252
#endif
#define IOPRIO_WHO_PROCESS 1
#define IOPRIO_CLASS_SHIFT (13)
#define IOPRIO_PRIO_MASK ((1UL << IOPRIO_CLASS_SHIFT) - 1)
#define PRIOLEN 8
char *f... | Adjust declaration for taskstats io call | Adjust declaration for taskstats io call
| C | mit | tijko/dashboard |
105129546008a77655b14ed4987baee1401d5058 | fortune_points/geom/point.h | fortune_points/geom/point.h | #pragma once
struct Point{
double x,y;
Point();
/*
first double input param: x coordinate.
second double input param: y coordinate.
*/
Point(double,double);
bool operator<(Point)const;
bool operator==(Point)const;
};
double dist(Point a,Point b); | #pragma once
class Point{
public:
double x,y;
Point();
/*
first double input param: x coordinate.
second double input param: y coordinate.
*/
Point(double,double);
bool operator<(Point)const;
bool operator==(Point)const;
};
| Remove deprecated function and use class to define a Point | Remove deprecated function and use class to define a Point
| C | mit | matheusdallrosa/voronoi-diagram-construction,matheusdallrosa/voronoi-diagram-construction |
59d679f48e3c528ed883b8d0142b2e5086b2d45c | hab/proxr/cb-set-resource.c | hab/proxr/cb-set-resource.c | #include <string.h>
#include "proxrcmds.h"
#include "sim-hab.h"
void cb_set_resource(bionet_resource_t *resource, bionet_value_t *value)
{
double data;
double content;
int id;
bionet_node_t *node;
bionet_value_get_float(value, &data);
if(data < 0 || data > 255)
return;
node = bionet_reso... | #include <string.h>
#include "proxrcmds.h"
#include "sim-hab.h"
void cb_set_resource(bionet_resource_t *resource, bionet_value_t *value)
{
double data;
double content;
int id;
bionet_node_t *node;
bionet_value_get_double(value, &data);
if(data < 0 || data > 255)
return;
node = bionet_res... | Change another float to double. | Change another float to double.
| C | lgpl-2.1 | ldm5180/hammerhead,ldm5180/hammerhead,ldm5180/hammerhead,ldm5180/hammerhead,ldm5180/hammerhead,ldm5180/hammerhead,ldm5180/hammerhead |
d8aba3bf19073a4a95a31525d049f3675f0b54ff | lib/fnv_1a.c | lib/fnv_1a.c | #include <assert.h>
#include "fnv_1a.h"
uint128_t fnv_1a(const void * restrict const buf,
const size_t len,
const size_t skip_pos,
const size_t skip_len)
{
assert((skip_pos <= len) && (skip_pos + skip_len <= len));
... | #include "fnv_1a.h"
#include "debug.h"
uint128_t fnv_1a(const void * restrict const buf,
const size_t len,
const size_t skip_pos,
const size_t skip_len)
{
assert((skip_pos <= len) && (skip_pos + skip_len <= len),
... | Use the new assert() macro | Use the new assert() macro
| C | bsd-2-clause | NTAP/quant,NTAP/quant,NTAP/quant |
19738ff61fecd49c45e9002bb79ea8c62d58bacb | Code/Support/Parsers/XML/RKXMLParserLibXML.h | Code/Support/Parsers/XML/RKXMLParserLibXML.h | //
// RKXMLParser.h
//
// Created by Jeremy Ellison on 2011-02-28.
// Copyright 2011 RestKit
//
// 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/license... | //
// RKXMLParser.h
//
// Created by Jeremy Ellison on 2011-02-28.
// Copyright 2011 RestKit
//
// 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/license... | Update outdated comments in the XML parser header | Update outdated comments in the XML parser header
| C | apache-2.0 | qingsong-xu/RestKit,dx285/RestKit,fhchina/RestKit,0dayZh/RestKit,pbogdanv/RestKit,zilaiyedaren/RestKit,common2015/RestKit,timbodeit/RestKit,fhchina/RestKit,erichedstrom/RestKit,CodewareTechnology/RestKit,HYPERHYPER/RestKit2,concreteinteractive/RestKit,braindata/RestKit-1,TimeIncOSS/RestKit,naqi/RestKit,oligriffiths/Res... |
1429550f5d9b6df0693b7cc10de4258982b6251d | include/core/SkMilestone.h | include/core/SkMilestone.h | /*
* Copyright 2016 Google Inc.
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#ifndef SK_MILESTONE
#define SK_MILESTONE 58
#endif
| /*
* Copyright 2016 Google Inc.
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#ifndef SK_MILESTONE
#define SK_MILESTONE 59
#endif
| Update Skia milestone to 59 | Update Skia milestone to 59
BUG=skia:
Change-Id: Ifa8fa20a838b2899a1230bf51cea7c4cf28971d8
Reviewed-on: https://skia-review.googlesource.com/9139
Reviewed-by: Heather Miller <2e22000c5d22374561fe5fba576a31095b72dc2e@google.com>
| C | bsd-3-clause | Hikari-no-Tenshi/android_external_skia,rubenvb/skia,aosp-mirror/platform_external_skia,rubenvb/skia,HalCanary/skia-hc,google/skia,Hikari-no-Tenshi/android_external_skia,HalCanary/skia-hc,google/skia,aosp-mirror/platform_external_skia,rubenvb/skia,HalCanary/skia-hc,google/skia,Hikari-no-Tenshi/android_external_skia,goog... |
d7347c0f845d280f8fdb65d08fffeb2f79903be8 | src/include/libbad_base.h | src/include/libbad_base.h | /**
* @file include/libbad_base.h
* @author Bryce Davis
* @date 19 November 2015
* @brief Header file for internal libbad declarations
* @copyright Copyright (c) 2015, Bryce Davis. Released under the MIT License.
* See LICENSE.txt for details.
*/
#ifndef _LIBBAD_BASE_H
#define _LIBBAD... | /**
* @file include/libbad_base.h
* @author Bryce Davis
* @date 19 November 2015
* @brief Header file for internal libbad declarations
* @copyright Copyright (c) 2015, Bryce Davis. Released under the MIT License.
* See LICENSE.txt for details.
*/
#ifndef _LIBBAD_BASE_H
#define _LIBBAD... | Restructure implementation and documentation of DATA/libbad_data_t | Restructure implementation and documentation of DATA/libbad_data_t
| C | mit | mahimahi42/libbad |
6f24862a543587f12ad33612ac4c8b29b61ab556 | include/objects.h | include/objects.h | #include <vector>
#include <map>
#include <string>
using namespace std;
#ifndef OBJECTS_H
#define OBJECTS_H
union DataValue {
string val_s;
long int val_i;
float val_f;
double val_d;
};
typedef map<string, DataValue> DataMap;
typedef map<string, DataValue>::iterator DataIterator;
class DataInstance {... | #ifndef OBJECTS_H
#define OBJECTS_H
#include <vector>
#include <map>
#include <string>
using namespace std;
class IntDataValue : public DataValue
{
private:
public:
IntDataValue(int val): value(val);
void compareWith(DataValue &I) {
if(I.value < this->value) return -1;
else if(I.value == this->valu... | Make an abstract DataValue class, and implement Double and IntegerValues | Make an abstract DataValue class, and implement Double and IntegerValues
| C | mit | Akshay809/kopSkylines,Akshay809/kopSkylines |
5d4d638f39d42ef3b1288038f319fc50d254a903 | user_modules.h | user_modules.h | // email=foo@bar.com
// branch=master
#ifndef __USER_MODULES_H__
#define __USER_MODULES_H__
#define LUA_USE_BUILTIN_STRING // for string.xxx()
#define LUA_USE_BUILTIN_TABLE // for table.xxx()
#define LUA_USE_BUILTIN_COROUTINE // for coroutine.xxx()
#define LUA_USE_BUILTIN_MATH // for math.xxx(), partially work
// #... | // email=foo@bar.com
// branch=master
#ifndef __USER_MODULES_H__
#define __USER_MODULES_H__
#define LUA_USE_BUILTIN_STRING // for string.xxx()
#define LUA_USE_BUILTIN_TABLE // for table.xxx()
#define LUA_USE_BUILTIN_COROUTINE // for coroutine.xxx()
#define LUA_USE_BUILTIN_MATH // for math.xxx(), partially work
// #... | Replace all user modules with token | Replace all user modules with token
| C | mit | marcelstoer/nodemcu-custom-build |
7ac07664b96c582b40fe43149d9f7d46a22af147 | test/Analysis/std-c-library-functions-inlined.c | test/Analysis/std-c-library-functions-inlined.c | // RUN: %clang_analyze_cc1 -analyzer-checker=unix.StdCLibraryFunctions -verify %s
// RUN: %clang_analyze_cc1 -triple i686-unknown-linux -analyzer-checker=unix.StdCLibraryFunctions -verify %s
// RUN: %clang_analyze_cc1 -triple x86_64-unknown-linux -analyzer-checker=unix.StdCLibraryFunctions -verify %s
// RUN: %clang_ana... | Add a test forgotten in r339088. | [analyzer] Add a test forgotten in r339088.
Differential Revision: https://reviews.llvm.org/D50363
git-svn-id: ffe668792ed300d6c2daa1f6eba2e0aa28d7ec6c@339726 91177308-0d34-0410-b5e6-96231b3b80d8
| C | apache-2.0 | apple/swift-clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,apple/swift-clang | |
cf3299b4a7621128279ec8a6ab928e95fd5848b3 | ldso/ldso/sh/dl-syscalls.h | ldso/ldso/sh/dl-syscalls.h | /* We can't use the real errno in ldso, since it has not yet
* been dynamicly linked in yet. */
#include "sys/syscall.h"
extern int _dl_errno;
#undef __set_errno
#define __set_errno(X) {(_dl_errno) = (X);}
| /* We can't use the real errno in ldso, since it has not yet
* been dynamicly linked in yet. */
#include "sys/syscall.h"
extern int _dl_errno;
#undef __set_errno
#define __set_errno(X) {(_dl_errno) = (X);}
#warning !!! __always_inline redefined waiting for the fixed gcc
#ifdef __always_inline
#undef __always_inline
#d... | Make sh4 build works again adding a temporary work-around iby redefining __always_inline to inline until gcc 4.x.x will get fixed. | Make sh4 build works again adding a temporary work-around
iby redefining __always_inline to inline until gcc 4.x.x will get
fixed.
Signed-off-by: Carmelo Amoroso <532378793705a04edd56deb76ad8c0442834d55d@st.com>
| C | lgpl-2.1 | hjl-tools/uClibc,kraj/uClibc,waweber/uclibc-clang,foss-xtensa/uClibc,atgreen/uClibc-moxie,OpenInkpot-archive/iplinux-uclibc,gittup/uClibc,kraj/uClibc,m-labs/uclibc-lm32,mephi42/uClibc,groundwater/uClibc,atgreen/uClibc-moxie,OpenInkpot-archive/iplinux-uclibc,ysat0/uClibc,brgl/uclibc-ng,ysat0/uClibc,ndmsystems/uClibc,gro... |
3a80b2f52f5d1e9466b378124d6ebb638734270e | source/x86/source_moss/kernel/interrupt/misc.h | source/x86/source_moss/kernel/interrupt/misc.h | #pragma once
#include "../../includes.h"
namespace MOSS { namespace Interrupts {
void disable_hw_int(void) {
__asm__ __volatile__("cli");
}
void enable_hw_int(void) {
__asm__ __volatile__("sti");
}
/*void fire(int n) {
//Adapted from http://www.brokenthorn.com/Resources/OSDev15.html
//Self-mo... | #pragma once
#include "../../includes.h"
namespace MOSS { namespace Interrupts {
inline void disable_hw_int(void) {
__asm__ __volatile__("cli");
}
inline void enable_hw_int(void) {
__asm__ __volatile__("sti");
}
/*inline void fire(int n) {
//Adapted from http://www.brokenthorn.com/Resources/OSD... | Make a few things `inline`. | Make a few things `inline`.
| C | mit | imallett/MOSS,imallett/MOSS,imallett/MOSS,imallett/MOSS |
2b42cc5ae4eba734498484d54e898a9925bea45e | src/zt_path.h | src/zt_path.h | /*!
* Filename: zt_path.h
* Description: path utils
*
* Author: Jason L. Shiffer <jshiffer@zerotao.org>
* Copyright:
* Copyright (C) 2010-2011, Jason L. Shiffer.
* See file COPYING for details
*/
#ifndef _ZT_PATH_
#define _ZT_PATH_
#ifdef HAVE_SYS_STAT_H
# include <sys/stat.h>
#endif /* HAVE_SYS_STA... | /*!
* Filename: zt_path.h
* Description: path utils
*
* Author: Jason L. Shiffer <jshiffer@zerotao.org>
* Copyright:
* Copyright (C) 2010-2011, Jason L. Shiffer.
* See file COPYING for details
*/
#ifndef _ZT_PATH_
#define _ZT_PATH_
#ifdef HAVE_SYS_STAT_H
# include <sys/stat.h>
# else
typedef unsig... | Add mode_t typedef when missing | Add mode_t typedef when missing
| C | mit | zerotao/libzt,zerotao/libzt,zerotao/libzt,zerotao/libzt |
5d23eae107c60bd48fb495950ea6da7d2176e4c0 | src/version.c | src/version.c | #include "system.h"
#include "sccs.h"
#include "logging.h"
extern int test_release;
extern unsigned build_timet;
int
version_main(int ac, char **av)
{
char buf[100];
float exp;
if (ac == 2 && streq("--help", av[1])) {
system("bk help version");
return (0);
}
if (sccs_cd2root(0, 0) == -1) {
getMsg("versio... | #include "system.h"
#include "sccs.h"
#include "logging.h"
extern int test_release;
extern unsigned build_timet;
int
version_main(int ac, char **av)
{
char buf[100];
float exp;
if (ac == 2 && streq("--help", av[1])) {
system("bk help version");
return (0);
}
lease_check(0); /* disable lease check */
if (sc... | Add some minor cleanups to the lease code. | Add some minor cleanups to the lease code.
bk: 3ea98875Om5jc1nUdXM9io0xhbkArA | C | apache-2.0 | bitkeeper-scm/bitkeeper,bitkeeper-scm/bitkeeper,bitkeeper-scm/bitkeeper,bitkeeper-scm/bitkeeper,bitkeeper-scm/bitkeeper,bitkeeper-scm/bitkeeper,bitkeeper-scm/bitkeeper,bitkeeper-scm/bitkeeper,bitkeeper-scm/bitkeeper,bitkeeper-scm/bitkeeper,bitkeeper-scm/bitkeeper,bitkeeper-scm/bitkeeper |
98c01545822d41366efc6d0af96dbdc6a4ec75e7 | src/theft_call_internal.h | src/theft_call_internal.h | #ifndef THEFT_CALL_INTERNAL_H
#define THEFT_CALL_INTERNAL_H
#include "theft_call.h"
#include "theft_bloom.h"
#include <assert.h>
#include <unistd.h>
#include <sys/wait.h>
#include <poll.h>
#include <signal.h>
#include <errno.h>
static enum theft_trial_res
theft_call_inner(struct theft_run_info *run_info, void **args... | #ifndef THEFT_CALL_INTERNAL_H
#define THEFT_CALL_INTERNAL_H
#include "theft_call.h"
#include "theft_bloom.h"
#include <assert.h>
#include <unistd.h>
#include <sys/wait.h>
#include <sys/types.h>
#include <poll.h>
#include <signal.h>
#include <errno.h>
static enum theft_trial_res
theft_call_inner(struct theft_run_info... | Add `sys/types.h` include for `pid_t`. | Add `sys/types.h` include for `pid_t`.
| C | isc | silentbicycle/theft |
01bf9c3502d0292abb5cbe54af6b787ce17a660d | src/win32/auth_file_win.c | src/win32/auth_file_win.c | /*
*The MIT License (MIT)
*
* Copyright (c) <2017> <Stephan Gatzka>
*
* 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, co... | Add stub for windows file authentication implementation. | Add stub for windows file authentication implementation.
| C | mit | gatzka/cjet,gatzka/cjet,mloy/cjet,mloy/cjet,mloy/cjet,gatzka/cjet,gatzka/cjet,mloy/cjet,gatzka/cjet,mloy/cjet | |
c45ae4a7d8a7e637ef7e344139b727ab12e9cca7 | nwg_common_socket_include.h | nwg_common_socket_include.h | #ifndef NWG_COMMON_SOCKET_INCLUDE_H_
#define NWG_COMMON_SOCKET_INCLUDE_H_
#ifdef __unix__
#include <netinet/in.h>
#include <sys/socket.h>
#endif /* __unix__ */
#ifdef _WIN32
#include <winsock2.h>
#include <windows.h>
typedef int socklen_t;
#undef FD_SETSIZE
#define FD_SETSIZE 2048
#endif /* _WIN32 */
#include <fcnt... | #ifndef NWG_COMMON_SOCKET_INCLUDE_H_
#define NWG_COMMON_SOCKET_INCLUDE_H_
#if !defined(__unix__) && (defined(__APPLE__) && defined(__MACH__))
#define __unix__ 1
#endif
#ifdef __unix__
#include <netinet/in.h>
#include <sys/socket.h>
#endif /* __unix__ */
#ifdef _WIN32
#include <winsock2.h>
#include <windows.h>
typede... | Add macro to identify apple mac os x as unix | Add macro to identify apple mac os x as unix
| C | mit | ynov/nwg,ynov/nwg |
fa33394bb70481412493fcf40d53ebdb2e738058 | test/CodeGen/ffp-contract-option.c | test/CodeGen/ffp-contract-option.c | // RUN: %clang_cc1 -O3 -ffp-contract=fast -triple=powerpc-apple-darwin10 -S -o - %s | FileCheck %s
// REQUIRES: powerpc-registered-target
float fma_test1(float a, float b, float c) {
// CHECK: fmadds
float x = a * b;
float y = x + c;
return y;
}
| // RUN: %clang_cc1 -O3 -ffp-contract=fast -triple=aarch64-apple-darwin -S -o - %s | FileCheck %s
// REQUIRES: aarch64-registered-target
float fma_test1(float a, float b, float c) {
// CHECK: fmadd
float x = a * b;
float y = x + c;
return y;
}
| Change -ffp-contract=fast test to run on Aarch64 | Change -ffp-contract=fast test to run on Aarch64
(I don't have powerpc enabled in my build and I am changing
how -ffp-contract=fast works.)
git-svn-id: ffe668792ed300d6c2daa1f6eba2e0aa28d7ec6c@298468 91177308-0d34-0410-b5e6-96231b3b80d8
| C | apache-2.0 | apple/swift-clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,apple/swift-clang,llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-cl... |
3949c3ba8cec129241ce6c47534f417d619c34e3 | ios/OAuthManager/OAuthManager.h | ios/OAuthManager/OAuthManager.h | //
// OAuthManager.h
//
// Created by Ari Lerner on 5/31/16.
// Copyright © 2016 Facebook. All rights reserved.
//
#import <Foundation/Foundation.h>
#if __has_include(<React/RCTBridgeModule.h>)
#import <React/RCTBridgeModule.h>
#else
#import "RCTBridgeModule.h"
#endif
#if __has_include("RCTLinkingManager.h")
... | //
// OAuthManager.h
//
// Created by Ari Lerner on 5/31/16.
// Copyright © 2016 Facebook. All rights reserved.
//
#import <Foundation/Foundation.h>
#if __has_include(<React/RCTBridgeModule.h>)
#import <React/RCTBridgeModule.h>
#else
#import "RCTBridgeModule.h"
#endif
#if __has_include(<React/RCTLinkingManage... | Fix duplicate React library import error conflict w/certain pods | Fix duplicate React library import error conflict w/certain pods
| C | mit | fullstackreact/react-native-oauth,fullstackreact/react-native-oauth,fullstackreact/react-native-oauth |
1d5cce6d3ac1458119383effedabc27876ab398c | A/02/09/task2.c | A/02/09/task2.c | #include <stdio.h>
#include <string.h>
#define MAX_LENGTH 400
char* find(char*, char);
int main() {
char input[MAX_LENGTH], symbol, *found;
fgets(input, MAX_LENGTH + 1, stdin);
scanf("%c", &symbol);
found = find(input, symbol);
printf("%d", (int)(found ? found - input : -1));
... | Add Task 02 for Homework 02 | Add Task 02 for Homework 02
| C | mit | elsys/po-homework | |
9feb800985250c12ed35c3934cde0ef00dc3867e | drivers/tty/serial/uart/uart_driver.c | drivers/tty/serial/uart/uart_driver.c | #include <mikoto/char_driver.h>
#include <mikoto/uart.h>
static int uart_write(const char *s);
static struct char_driver_operations uart_ops = {
.write = uart_write,
};
static struct char_driver uart_driver = {
.name = "UART",
};
void uart_init(void)
{
struct char_driver *uart = get_uart_driver_instance();
uart... | #include <mikoto/char_driver.h>
#include <mikoto/uart.h>
static int uart_write(const char *s);
static struct char_driver_operations uart_ops = {
.write = uart_write,
};
static struct char_driver uart_driver = {
.name = "UART",
};
static void
uart_init(void)
{
uart_driver.ops = &uart_ops;
}
struct char_driver *... | Fix circular reference but in uart_init() | Fix circular reference but in uart_init()
Don't call get_uart_driver_instance() from uart_init().
| C | bsd-3-clause | masami256/mini-arm-kernel |
1f5340c307e094c62534db260290f4b6044200c2 | boards/common/stm32/include/cfg_usb_otg_hs_fs.h | boards/common/stm32/include/cfg_usb_otg_hs_fs.h | /*
* Copyright (C) 2019 Koen Zandberg
*
* This file is subject to the terms and conditions of the GNU Lesser
* General Public License v2.1. See the file LICENSE in the top level
* directory for more details.
*/
/**
* @ingroup boards_common_stm32
* @{
*
* @file
* @brief Common configuration for STM... | Add default config for USB OTG HS peripheral | boards/stm32: Add default config for USB OTG HS peripheral
| C | lgpl-2.1 | jasonatran/RIOT,smlng/RIOT,miri64/RIOT,RIOT-OS/RIOT,smlng/RIOT,kaspar030/RIOT,jasonatran/RIOT,OlegHahm/RIOT,kYc0o/RIOT,kaspar030/RIOT,OlegHahm/RIOT,RIOT-OS/RIOT,smlng/RIOT,miri64/RIOT,basilfx/RIOT,authmillenon/RIOT,yogo1212/RIOT,miri64/RIOT,kaspar030/RIOT,basilfx/RIOT,yogo1212/RIOT,authmillenon/RIOT,OlegHahm/RIOT,ant90... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.