commit
stringlengths
40
40
old_file
stringlengths
4
237
new_file
stringlengths
4
237
old_contents
stringlengths
1
4.24k
new_contents
stringlengths
1
4.87k
subject
stringlengths
15
778
message
stringlengths
15
8.75k
lang
stringclasses
266 values
license
stringclasses
13 values
repos
stringlengths
5
127k
c6e1f67b17b4cb9d707af1245c1ecf00f91f23c0
utils/count/count.c
utils/count/count.c
/*===- count.c - The 'count' testing tool ---------------------------------===*\ * * The LLVM Compiler Infrastructure * * This file is distributed under the University of Illinois Open Source * License. See LICENSE.TXT for details. * \*===-------------------------------------------------------...
/*===- count.c - The 'count' testing tool ---------------------------------===*\ * * The LLVM Compiler Infrastructure * * This file is distributed under the University of Illinois Open Source * License. See LICENSE.TXT for details. * \*===-------------------------------------------------------...
Fix extra fread after EOF, non-wires-crossed version.
Fix extra fread after EOF, non-wires-crossed version. git-svn-id: 0ff597fd157e6f4fc38580e8d64ab130330d2411@105270 91177308-0d34-0410-b5e6-96231b3b80d8
C
bsd-2-clause
dslab-epfl/asap,llvm-mirror/llvm,apple/swift-llvm,GPUOpen-Drivers/llvm,llvm-mirror/llvm,dslab-epfl/asap,chubbymaggie/asap,apple/swift-llvm,llvm-mirror/llvm,apple/swift-llvm,llvm-mirror/llvm,apple/swift-llvm,GPUOpen-Drivers/llvm,GPUOpen-Drivers/llvm,dslab-epfl/asap,apple/swift-llvm,chubbymaggie/asap,GPUOpen-Drivers/llvm...
15c0a7f99f4179861dc1f77969bf2b62897e4e25
Source/BugsnagSink.h
Source/BugsnagSink.h
// // BugsnagSink.h // // Created by Conrad Irwin on 2014-10-01. // // Copyright (c) 2014 Bugsnag, Inc. All rights reserved. // // 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 r...
// // BugsnagSink.h // // Created by Conrad Irwin on 2014-10-01. // // Copyright (c) 2014 Bugsnag, Inc. All rights reserved. // // 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 r...
Update import to be compatible with KSCrash 1.8.8+
Update import to be compatible with KSCrash 1.8.8+
C
mit
bugsnag/bugsnag-cocoa,bugsnag/bugsnag-cocoa,bugsnag/bugsnag-cocoa,bugsnag/bugsnag-cocoa
31455c34d693edfbf6e29bc6c669b9178b4cb223
cocos2d/CCActionManager_Private.h
cocos2d/CCActionManager_Private.h
/* * cocos2d for iPhone: http://www.cocos2d-iphone.org * * Copyright (c) 2013-2014 Cocos2D Authors * * 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 with...
/* * cocos2d for iPhone: http://www.cocos2d-iphone.org * * Copyright (c) 2013-2014 Cocos2D Authors * * 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 with...
Remove unneeded method from private header
Remove unneeded method from private header
C
mit
TukekeSoft/cocos2d-spritebuilder,TukekeSoft/cocos2d-spritebuilder,TukekeSoft/cocos2d-spritebuilder,TukekeSoft/cocos2d-spritebuilder
3e752a6b1abdc2770c1968bed604b639cf93be09
io/file_descriptor.h
io/file_descriptor.h
#ifndef FILE_DESCRIPTOR_H #define FILE_DESCRIPTOR_H #include <io/channel.h> class FileDescriptor : public Channel { LogHandle log_; protected: int fd_; public: FileDescriptor(int); ~FileDescriptor(); virtual Action *close(EventCallback *); virtual Action *read(size_t, EventCallback *); virtual Action *write(B...
#ifndef FILE_DESCRIPTOR_H #define FILE_DESCRIPTOR_H #include <io/channel.h> class FileDescriptor : public Channel { LogHandle log_; protected: int fd_; public: FileDescriptor(int); ~FileDescriptor(); virtual Action *close(EventCallback *); virtual Action *read(size_t, EventCallback *); virtual Action *write(B...
Return success rather than failure from shutdown() on FileDescriptor, since it is entirely immaterial.
Return success rather than failure from shutdown() on FileDescriptor, since it is entirely immaterial. git-svn-id: 9e2532540f1574e817ce42f20b9d0fb64899e451@333 4068ffdb-0463-0410-8185-8cc71e3bd399
C
bsd-2-clause
splbio/wanproxy,diegows/wanproxy,diegows/wanproxy,diegows/wanproxy,splbio/wanproxy,splbio/wanproxy
58e3caf75a50a64d485b82d12d2353985413401f
src/util/bitwise.h
src/util/bitwise.h
#pragma once #include "../definitions.h" #include "log.h" namespace bitwise { inline u16 compose_bytes(const u8 high, const u8 low) { return static_cast<u16>((high << 8) + low); } inline bool check_bit(const u8 value, const u8 bit) { return (value & (1 << bit)) != 0; } inline u8 set_bit(const u8 value, con...
#pragma once #include "../definitions.h" #include "log.h" namespace bitwise { inline u16 compose_bytes(const u8 high, const u8 low) { return static_cast<u16>((high << 8) + low); } inline bool check_bit(const u8 value, const u8 bit) { return (value & (1 << bit)) != 0; } inline u8 bit_value(const u8 value, c...
Add a bit_value function for the numeric value of a single bit
Add a bit_value function for the numeric value of a single bit
C
bsd-3-clause
jgilchrist/emulator,jgilchrist/emulator,jgilchrist/emulator
5dcd7a8c429aa6f7d26cb8dfce62e4a793a6d9b5
test/Modules/DebugInfoSubmoduleImport.c
test/Modules/DebugInfoSubmoduleImport.c
// RUN: rm -rf %t // RUN: %clang_cc1 -fmodules -fmodule-format=obj -debug-info-kind=limited -dwarf-ext-refs \ // RUN: -fimplicit-module-maps -x c -fmodules-cache-path=%t -I %S/Inputs \ // RUN: %s -emit-llvm -debugger-tuning=lldb -o - | FileCheck %s #include "DebugSubmoduleA.h" #include "DebugSubmoduleB.h" // C...
// RUN: rm -rf %t // RUN: %clang_cc1 -fmodules -fmodule-format=obj -debug-info-kind=limited -dwarf-ext-refs \ // RUN: -fimplicit-module-maps -x c -fmodules-cache-path=%t -I %S/Inputs \ // RUN: %s -emit-llvm -debugger-tuning=lldb -o - | FileCheck %s // // RUN: %clang_cc1 -fmodules -fmodule-format=obj -debug-info...
Add a test that local submodule visibility has no effect on debug info
Add a test that local submodule visibility has no effect on debug info rdar://problem/27876262 git-svn-id: ffe668792ed300d6c2daa1f6eba2e0aa28d7ec6c@302809 91177308-0d34-0410-b5e6-96231b3b80d8
C
apache-2.0
llvm-mirror/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,apple/swift-clang,llvm-mirror/clang,apple/swift-clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-cl...
1abf575c1cf36df59d0673c0e5d8b326f4526a8b
example/ex-array04.c
example/ex-array04.c
#include <gmp.h> #include "m-array.h" #include "m-algo.h" ARRAY_DEF(mpz, mpz_t, M_CLASSIC_OPLIST(mpz)) ALGO_DEF(array_mpz, ARRAY_OPLIST(mpz, M_CLASSIC_OPLIST(mpz))) static inline void my_mpz_inc(mpz_t d, const mpz_t a){ mpz_add(d, d, a); } static inline void my_mpz_sqr(mpz_t d, const mpz_t a){ mpz_mul(d, a, a); ...
#include <gmp.h> #include "m-array.h" #include "m-algo.h" ARRAY_DEF(mpz, mpz_t, M_CLASSIC_OPLIST(mpz)) ALGO_DEF(array_mpz, ARRAY_OPLIST(mpz, M_CLASSIC_OPLIST(mpz))) static inline void my_mpz_inc(mpz_t *d, const mpz_t a){ mpz_add(*d, *d, a); } static inline void my_mpz_sqr(mpz_t *d, const mpz_t a){ mpz_mul(*d, a,...
Update example with new constraints on map/reduce prototype.
Update example with new constraints on map/reduce prototype.
C
bsd-2-clause
P-p-H-d/mlib,P-p-H-d/mlib
c57119c6a4ae1a666a1bc7261dd9afeee1224d02
util.h
util.h
#ifndef util_h #define util_h #define min(a,b) ((a)<(b)?(a):(b)) int warn(const char *s); void v(); #endif /*util_h*/
#ifndef util_h #define util_h #define min(a,b) ((a)<(b)?(a):(b)) int warn(const char *s); void v(); #ifdef DEBUG #define dprintf(fmt, args...) fprintf(stderr, fmt, ##args) #else #define dprintf(fmt, ...) (0) #endif #endif /*util_h*/
Add a debugging print macro.
Add a debugging print macro.
C
mit
amyvmiwei/beanstalkd,PhillipMwaniki/beanstalkd,yetone/beanstalkd,diditaxi/beanstalkd,tdg5/beanstalkd,bmhatfield/beanstalkd,naderman/beanstalkd,LomoX-Offical/beanstalkd-win,amyvmiwei/beanstalkd,CompendiumSoftware/beanstalkd,naderman/beanstalkd,pinguo-xudianyang/beanstalkd,JensRantil/beanstalkd,PhillipMwaniki/beanstalkd,...
9088e400d3196d691980e36b908548cefcbcd3e0
include/prd-fw-msg.h
include/prd-fw-msg.h
/* Copyright 2017 IBM Corp. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writin...
/* Copyright 2017 IBM Corp. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writin...
Add generic response structure inside prd_fw_msg
prd: Add generic response structure inside prd_fw_msg This patch adds generic response structure. Also sync prd_fw_msg type macros with hostboot. Next patch makes use of this structure/macro. CC: Jeremy Kerr <68a658b44bbaefab3ef5cd231967195fc0ff9d69@ozlabs.org> Signed-off-by: Vasant Hegde <a6d753843573f7bfed5075c1e8...
C
apache-2.0
open-power/skiboot,open-power/skiboot,shenki/skiboot,shenki/skiboot,shenki/skiboot,shenki/skiboot,qemu/skiboot,shenki/skiboot,stewart-ibm/skiboot,qemu/skiboot,qemu/skiboot,legoater/skiboot,legoater/skiboot,open-power/skiboot,open-power/skiboot,open-power/skiboot,qemu/skiboot,qemu/skiboot,stewart-ibm/skiboot,legoater/sk...
4b9d0d59b5436e3fc6ffe3452147e226277a3edf
program/system/mission.c
program/system/mission.c
#include "QuadCopterConfig.h" #include "mavlink.h" #define MAV_MAX_LEN 263 struct waypoint_t mission_wp_list = {0}; int waypoint_cnt = 0; int cur_waypoint = 0; mavlink_message_t msg; uint8_t buf[MAV_MAX_LEN]; void mission_read_waypoint_list() { } void mission_write_waypoint_list() { } void mission_clear_waypoint(...
#include "QuadCopterConfig.h" #include "mavlink.h" #define MAV_MAX_LEN 263 struct waypoint_t mission_wp_list = {0}; int waypoint_cnt = 0; int cur_waypoint = 0; mavlink_message_t msg; uint8_t buf[MAV_MAX_LEN]; void push_waypoint_node(struct waypoint_t *waypoint) { } void free_waypoint_list(struct waypoint_t *waypoi...
Create the waypoint structure operating function prototype
Create the waypoint structure operating function prototype
C
mit
ming6842/firmware,ming6842/firmware-new,ming6842/firmware-new,UrsusPilot/firmware,ming6842/firmware-new,UrsusPilot/firmware,fboris/firmware,fboris/firmware,UrsusPilot/firmware,ming6842/firmware,ming6842/firmware,fboris/firmware
3cbe36b63ebb3f5e782aac56c95e15018abf6cda
scripts/freetype/slimftoptions.h
scripts/freetype/slimftoptions.h
/* custom ftoption.h which selects the minimum features needed by mupdf */ #include <freetype/config/ftoption.h> #undef FT_CONFIG_OPTION_USE_LZW #undef FT_CONFIG_OPTION_USE_ZLIB #undef FT_CONFIG_OPTION_USE_BZIP2 #undef FT_CONFIG_OPTION_USE_PNG #undef FT_CONFIG_OPTION_USE_HARFBUZZ #undef FT_CONFIG_OPTION_MAC_FONTS #un...
/* custom ftoption.h which selects the minimum features needed by mupdf */ #include <freetype/config/ftoption.h> #undef FT_CONFIG_OPTION_USE_LZW #undef FT_CONFIG_OPTION_USE_ZLIB #undef FT_CONFIG_OPTION_USE_BZIP2 #undef FT_CONFIG_OPTION_USE_PNG #undef FT_CONFIG_OPTION_USE_HARFBUZZ #undef FT_CONFIG_OPTION_MAC_FONTS #un...
Disable freetype stream support, avoiding FILE interface.
Disable freetype stream support, avoiding FILE interface.
C
agpl-3.0
ArtifexSoftware/mupdf,ccxvii/mupdf,TamirEvan/mupdf,ccxvii/mupdf,sebras/mupdf,TamirEvan/mupdf,fluks/mupdf-x11-bookmarks,fluks/mupdf-x11-bookmarks,fluks/mupdf-x11-bookmarks,ArtifexSoftware/mupdf,TamirEvan/mupdf,poor-grad-student/mupdf,poor-grad-student/mupdf,fluks/mupdf-x11-bookmarks,fluks/mupdf-x11-bookmarks,fluks/mupdf...
afe9df97488c789740212a40fdca119e4845308c
src/condor_includes/condor_fix_unistd.h
src/condor_includes/condor_fix_unistd.h
#ifndef FIX_UNISTD_H #define FIX_UNISTD_H #include <unistd.h> /* For some reason the g++ include files on Ultrix 4.3 fail to provide these prototypes, even though the Ultrix 4.2 versions did... Once again, OSF1 also chokes, unless _AES_SOURCE(?) is defined JCP */ #if defined(ULTRIX43) || defined(SUNOS41) || de...
#ifndef FIX_UNISTD_H #define FIX_UNISTD_H #if defined(SUNOS41) # define read _hide_read # define write _hide_write #endif #include <unistd.h> #if defined(SUNOS41) # undef read # undef write #endif /* For some reason the g++ include files on Ultrix 4.3 fail to provide these prototypes, even though the Ultrix 4...
Fix up prototypes for read() and write() on Suns.
Fix up prototypes for read() and write() on Suns.
C
apache-2.0
djw8605/condor,clalancette/condor-dcloud,zhangzhehust/htcondor,djw8605/htcondor,djw8605/condor,bbockelm/condor-network-accounting,djw8605/condor,mambelli/osg-bosco-marco,djw8605/htcondor,djw8605/htcondor,neurodebian/htcondor,htcondor/htcondor,mambelli/osg-bosco-marco,mambelli/osg-bosco-marco,djw8605/htcondor,neurodebia...
6d77e4be436f17438dc8b8d12c75b2382040f76d
src2/hcidumpinternal.h
src2/hcidumpinternal.h
#ifndef hcidumpinternal_H #define hcidumpinternal_H #include <stdbool.h> #include <stdint.h> typedef struct beacon_info { char uuid[20]; int32_t code; int32_t manufacturer; int32_t major; int32_t minor; int32_t power; int32_t calibrated_power; int32_t rssi; int64_t time; } beacon_i...
#ifndef hcidumpinternal_H #define hcidumpinternal_H #include <stdbool.h> #include <stdint.h> typedef struct beacon_info { char uuid[36]; int32_t code; int32_t manufacturer; int32_t major; int32_t minor; int32_t power; int32_t calibrated_power; int32_t rssi; int64_t time; } beacon_i...
Correct the allowed size of the uuid code
Correct the allowed size of the uuid code
C
apache-2.0
starksm64/NativeRaspberryPiBeaconParser,starksm64/NativeRaspberryPiBeaconParser,starksm64/NativeRaspberryPiBeaconParser,starksm64/NativeRaspberryPiBeaconParser,starksm64/NativeRaspberryPiBeaconParser
d2db26f1c08242b61709d6c297ad28e02acd7abd
Wangscape/noise/module/codecs/CornerCombinerBaseWrapperCodec.h
Wangscape/noise/module/codecs/CornerCombinerBaseWrapperCodec.h
#pragma once #include <spotify/json.hpp> #include <noise/noise.h> #include "noise/module/Wrapper.h" #include "noise/module/CornerCombinerBase.h" namespace spotify { namespace json { template<> struct default_codec_t<noise::module::Wrapper<noise::module::CornerCombinerBase>> { using CornerCombinerBaseWrapper = n...
#pragma once #include <spotify/json.hpp> #include <noise/noise.h> #include "noise/module/Wrapper.h" #include "noise/module/CornerCombinerBase.h" namespace spotify { namespace json { template<> struct default_codec_t<noise::module::Wrapper<noise::module::CornerCombinerBase>> { using CornerCombinerBaseWrapper = n...
Fix find&replace error in CornerCombinerBase codec
Fix find&replace error in CornerCombinerBase codec
C
mit
Wangscape/Wangscape,serin-delaunay/Wangscape,Wangscape/Wangscape,serin-delaunay/Wangscape,Wangscape/Wangscape
8487e6a94258271b4036dcc62de05a2940d7d436
snake.c
snake.c
#include <stdlib.h> /** * @author: Hendrik Werner */ #define BOARD_HEIGHT 50 #define BOARD_WIDTH 50 typedef struct Position { int row; int col; } Position; typedef enum Cell { EMPTY ,SNAKE ,FOOD } Cell; typedef Cell Board[BOARD_HEIGHT][BOARD_WIDTH]; typedef enum Direction {LEFT, UP, RIGHT, DOWN} Direction;...
#include <stdlib.h> /** * @author: Hendrik Werner */ #define BOARD_HEIGHT 50 #define BOARD_WIDTH 50 typedef struct Position { int row; int col; } Position; typedef enum Cell { EMPTY ,SNAKE ,FOOD } Cell; typedef Cell Board[BOARD_HEIGHT][BOARD_WIDTH]; typedef enum Direction {LEFT, UP, RIGHT, DOWN} Direction;...
Add a function to represents cells as characters.
Add a function to represents cells as characters.
C
mit
Hendrikto/Snake
8edeac350ffa63e48ea86a1284111061fd3256a7
MoblicoSDK/Services/MLCSettingsService.h
MoblicoSDK/Services/MLCSettingsService.h
/* Copyright 2012 Moblico Solutions LLC Licensed under the Apache License, Version 2.0 (the "License"); you may not use this work except in compliance with the License. You may obtain a copy of the License in the LICENSE file, or at: http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable l...
/* Copyright 2012 Moblico Solutions LLC Licensed under the Apache License, Version 2.0 (the "License"); you may not use this work except in compliance with the License. You may obtain a copy of the License in the LICENSE file, or at: http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable l...
Allow overrideSettings to take a nil value.
Allow overrideSettings to take a nil value.
C
apache-2.0
Moblico/MoblicoSDK-iOS
77567b0280eb5f326b0860096f473bb69064e672
iOSNativeiPadApp/EdKeyNote/EdKeyNote/EdKeyNote/EKNAppDelegate.h
iOSNativeiPadApp/EdKeyNote/EdKeyNote/EdKeyNote/EKNAppDelegate.h
// // EKNAppDelegate.h // EdKeyNote // // Created by canviz on 9/22/14. // Copyright (c) 2014 canviz. All rights reserved. // #import <UIKit/UIKit.h> #import "EKNDeskTopViewController.h" #import "EKNLoginViewController.h" @interface EKNAppDelegate : UIResponder <UIApplicationDelegate> @property (strong, nonatomi...
// // EKNAppDelegate.h // EdKeyNote // // Created by canviz on 9/22/14. // Copyright (c) 2014 canviz. All rights reserved. // #import <UIKit/UIKit.h> #import "EKNLoginViewController.h" @interface EKNAppDelegate : UIResponder <UIApplicationDelegate> @property (strong, nonatomic) UIWindow *window; @property (stro...
Remove the import for EKNDeskTopViewController.h
Remove the import for EKNDeskTopViewController.h
C
apache-2.0
weshackett/Property-Inspection-Code-Sample,mslaugh/Property-Inspection-Code-Sample,OfficeDev/Property-Inspection-Code-Sample,weshackett/Property-Inspection-Code-Sample,OfficeDev/Property-Inspection-Code-Sample,mslaugh/Property-Inspection-Code-Sample,OfficeDev/Property-Inspection-Code-Sample,weshackett/Property-Inspecti...
4c835203b2e41aa8b7c61c9e1daaf9a6c4bfb6eb
Mac/mwerks/mwerks_plugin_config.h
Mac/mwerks/mwerks_plugin_config.h
/* ** Config file for dynamically-loaded ppc/cfm68k plugin modules. */ /* #define USE_GUSI1 /* Stdio implemented with GUSI */ #define USE_GUSI2 /* Stdio implemented with GUSI */ #define WITH_THREAD /* Use thread support (needs GUSI 2, not GUSI 1) */ #define USE_MSL /* Use MSL libraries */ #ifdef USE_MSL #define M...
/* ** Config file for dynamically-loaded ppc/cfm68k plugin modules. */ /* #define USE_GUSI1 /* Stdio implemented with GUSI */ #define USE_GUSI2 /* Stdio implemented with GUSI */ #if defined(USE_GUSI1) || defined(USE_GUSI2) #define USE_GUSI #endif #define WITH_THREAD /* Use thread support (needs GUSI 2, not GUSI 1) ...
Define USE_GUSI if USE_GUSI1 or USE_GUSI2 is defined.
Define USE_GUSI if USE_GUSI1 or USE_GUSI2 is defined.
C
mit
sk-/python2.7-type-annotator,sk-/python2.7-type-annotator,sk-/python2.7-type-annotator
d82e2c1a1f7373fe89ce854d94915ad420596aa2
include/clang/Sema/CodeCompleteOptions.h
include/clang/Sema/CodeCompleteOptions.h
//===---- CodeCompleteOptions.h - Code Completion Options -------*- C++ -*-===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===-------------------------------------------------------...
//===---- CodeCompleteOptions.h - Code Completion Options -------*- C++ -*-===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===-------------------------------------------------------...
Fix comments: these are not trailing comments
Fix comments: these are not trailing comments git-svn-id: ffe668792ed300d6c2daa1f6eba2e0aa28d7ec6c@174197 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,llvm-mirror/clang,apple/swift-clang,apple/swift-clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/cl...
1b374d72764837fb898f9b0aa4f2c83785818198
halley/net/include/halley/net/imessage.h
halley/net/include/halley/net/imessage.h
#pragma once #include <gsl/gsl_byte> #include <gsl/span> namespace Halley { class IMessage { public: virtual ~IMessage() {} virtual size_t getSerializedSize() = 0; virtual void serializeTo(gsl::span<gsl::byte> dst) = 0; }; }
#pragma once #include <gsl/gsl> namespace Halley { class IMessage { public: virtual ~IMessage() {} virtual size_t getSerializedSize() = 0; virtual void serializeTo(gsl::span<gsl::byte> dst) = 0; }; }
Change include to fix compilation.
Change include to fix compilation.
C
apache-2.0
amzeratul/halley,amzeratul/halley,amzeratul/halley
f858f7f3804ea20b80a38dab9b1b2d098e1df2a1
include/llvm/Transforms/Instrumentation.h
include/llvm/Transforms/Instrumentation.h
//===- Transforms/Instrumentation.h - Instrumentation passes ----*- C++ -*-===// // // The LLVM Compiler Infrastructure // // This file was developed by the LLVM research group and is distributed under // the University of Illinois Open Source License. See LICENSE.TXT for details. // //===--------...
//===- Transforms/Instrumentation.h - Instrumentation passes ----*- C++ -*-===// // // The LLVM Compiler Infrastructure // // This file was developed by the LLVM research group and is distributed under // the University of Illinois Open Source License. See LICENSE.TXT for details. // //===--------...
Add accessor function prototypes for reoptimizer support passes. Make accessors return FunctionPass* as appropriate.
Add accessor function prototypes for reoptimizer support passes. Make accessors return FunctionPass* as appropriate. git-svn-id: 0ff597fd157e6f4fc38580e8d64ab130330d2411@16619 91177308-0d34-0410-b5e6-96231b3b80d8
C
bsd-2-clause
dslab-epfl/asap,llvm-mirror/llvm,GPUOpen-Drivers/llvm,apple/swift-llvm,dslab-epfl/asap,GPUOpen-Drivers/llvm,GPUOpen-Drivers/llvm,apple/swift-llvm,GPUOpen-Drivers/llvm,llvm-mirror/llvm,llvm-mirror/llvm,llvm-mirror/llvm,chubbymaggie/asap,GPUOpen-Drivers/llvm,dslab-epfl/asap,apple/swift-llvm,chubbymaggie/asap,apple/swift-...
dac047db615cb36da26e5502fb430771166f251f
ports/raspberrypi/boards/adafruit_feather_rp2040/mpconfigboard.h
ports/raspberrypi/boards/adafruit_feather_rp2040/mpconfigboard.h
#define MICROPY_HW_BOARD_NAME "Adafruit Feather RP2040" #define MICROPY_HW_MCU_NAME "rp2040" #define MICROPY_HW_NEOPIXEL (&pin_GPIO16) #define DEFAULT_I2C_BUS_SCL (&pin_GPIO3) #define DEFAULT_I2C_BUS_SDA (&pin_GPIO2) #define DEFAULT_SPI_BUS_SCK (&pin_GPIO18) #define DEFAULT_SPI_BUS_MOSI (&pin_GPIO19) #define DEFAULT...
#define MICROPY_HW_BOARD_NAME "Adafruit Feather RP2040" #define MICROPY_HW_MCU_NAME "rp2040" #define MICROPY_HW_NEOPIXEL (&pin_GPIO16) #define DEFAULT_I2C_BUS_SCL (&pin_GPIO3) #define DEFAULT_I2C_BUS_SDA (&pin_GPIO2) #define DEFAULT_SPI_BUS_SCK (&pin_GPIO18) #define DEFAULT_SPI_BUS_MOSI (&pin_GPIO19) #define DEFAULT...
Update Feather RP2040 to 8MB
Update Feather RP2040 to 8MB
C
mit
adafruit/circuitpython,adafruit/circuitpython,adafruit/circuitpython,adafruit/circuitpython,adafruit/circuitpython,adafruit/circuitpython
b949183f1deda980e0ff77e067dc8d1eed2775c8
serial.h
serial.h
#ifndef _SERIAL_H_ #define _SERIAL_H_ #include "hardware/packet.h" #define SERIAL_SUCCESS 1 #define SERIAL_ERROR !SERIAL_SUCCESS unsigned int serial_connect(char device[]); unsigned int serial_transmit(struct Packet packet); unsigned int serial_close(); #endif
#ifndef _SERIAL_H_ #define _SERIAL_H_ #include "hardware/packet.h" #define SERIAL_SUCCESS 1 #define SERIAL_ERROR (!SERIAL_SUCCESS) unsigned int serial_connect(char device[]); unsigned int serial_transmit(struct Packet packet); unsigned int serial_close(); #endif
Add brackets around SERIAL_ERROR definition for compatibility
Add brackets around SERIAL_ERROR definition for compatibility
C
agpl-3.0
jackwilsdon/lightcontrol,jackwilsdon/lightcontrol
b483dd161b054adcff933fd073550bf8f7cc1c47
include/pector/malloc_allocator_compat.h
include/pector/malloc_allocator_compat.h
#ifndef PECTOR_MALLOC_ALLOCATOR_COMPAT_H #define PECTOR_MALLOC_ALLOCATOR_COMPAT_H #ifdef __APPLE__ #include <malloc/malloc.h> #else #include <malloc.h> #endif #if defined __GNUC__ || defined _WIN32 || defined __APPLE__ #define PT_SIZE_AWARE_COMPAT #if defined __GNUC__ && !defined _WIN32 && !defined __APPLE__ #defin...
#ifndef PECTOR_MALLOC_ALLOCATOR_COMPAT_H #define PECTOR_MALLOC_ALLOCATOR_COMPAT_H #ifdef __APPLE__ #include <malloc/malloc.h> #else #include <malloc.h> #endif #if defined __GNUC__ || defined _WIN32 || defined __APPLE__ || defined __FreeBSD__ #define PT_SIZE_AWARE_COMPAT #if defined _WIN32 #define PT_MALLOC_USABLE_S...
Add FreeBSD as platform supporting malloc_usable_size
Add FreeBSD as platform supporting malloc_usable_size
C
lgpl-2.1
pjump/pector,aguinet/pector,pjump/pector,aguinet/pector
1f8565900ffd65dc10e7d0341e29f284c480deab
src/include/TVector.h
src/include/TVector.h
/****************************** * AUTHOR : GUSTAVO MARTINS * USE AS YOU WISH * DATE : 11/25/2015 * LANG : ANSI C * DESCR : A VERY SIMPLE * 3D VECTOR LIBRARY ******************************/ #ifndef TVECTOR_H #define TVECTOR_H typedef struct SVector *TVector; TVector createVector(double x, double y, double z); TVector...
/****************************** * AUTHOR : GUSTAVO MARTINS * USE AS YOU WISH * DATE : 11/25/2015 * LANG : ANSI C * DESCR : A VERY SIMPLE * 3D VECTOR LIBRARY ******************************/ #ifndef TVECTOR_H #define TVECTOR_H typedef struct SVector *TVector; TVector createVector(double x, double y, double z); TVector...
Add new functions to header
Add new functions to header
C
mit
gugamm/Simple-Vector-Library
2e91ae16b74c9fe73444347640ff7a1545809844
example1.c
example1.c
#include <stdio.h> #include <stdlib.h> #include <string.h> #include "suspect.h" suspect_context("Euler's Method", suspect_test("Predicts y_{n+1} to within the expected threshhold", suspect_assert("Expected 1 < 0", -1 < 0); ) suspect_test("Does not explode", suspect_assert("Expected -1 < 0", -1 < 0); ) suspe...
#include <stdio.h> #include <stdlib.h> #include <string.h> #include "suspect.h" suspect_context("Euler's Method", suspect_test("Expect actual to be within epsilon of target", float actual = 5.426; float epsilon = 0.01; float target = 5.00; suspect_epsilon(actual,epsilon,target); ) suspect_test("Does not ex...
Include use case of epsilon
Include use case of epsilon
C
mit
robertdfrench/Suspect
63aed9a9b6c82e1c9114784721c9a2edff7d0e68
ch1/ex3/farh_to_celsius_v2.c
ch1/ex3/farh_to_celsius_v2.c
#include <stdio.h> float K_5_BY_9 = 5.0 / 9.0; float K_32 = 32; int main(void) { float fahr, celsius; int lower, upper, step; lower = 0; upper = 300; step = 20; printf("|-----------|\n"); printf("|%4s|%6s|\n", "F", "C"); printf("|-----------|\n"); fahr = lower; while (...
#include <stdio.h> float K_5_BY_9 = 5.0 / 9.0; float K_32 = 32; int SUCCESS = 0; int main(void) { float fahrenheit, celsius; int lower, upper, step; lower = 0; upper = 300; step = 20; printf("|-----------|\n"); printf("|%4s|%6s|\n", "F", "C"); printf("|-----------|\n"); f...
Update ch1/ex3 v2 exercise with more readable code
Update ch1/ex3 v2 exercise with more readable code
C
bsd-3-clause
rmk135/the-c-programming-language
21465b20594432e4d73b5eaa75e34ef00761face
subversion/libsvn_fs/txn.h
subversion/libsvn_fs/txn.h
/* node.h : interface to node functions, private to libsvn_fs * * ==================================================================== * Copyright (c) 2000 CollabNet. All rights reserved. * * This software is licensed as described in the file COPYING, which * you should have received as part of this distribution...
/* txn.h : interface to Subversion transactions, private to libsvn_fs * * ==================================================================== * Copyright (c) 2000 CollabNet. All rights reserved. * * This software is licensed as described in the file COPYING, which * you should have received as part of this dist...
Fix descriptive comment at top of file.
Fix descriptive comment at top of file.
C
apache-2.0
jmckaskill/subversion,jmckaskill/subversion,jmckaskill/subversion,jmckaskill/subversion,jmckaskill/subversion,jmckaskill/subversion,jmckaskill/subversion,jmckaskill/subversion
8a6513105010a0e334ccf8cf3f4c017abf2b44ae
src/sail/game_struct.h
src/sail/game_struct.h
/* * Copyright (C) 2015 Luke San Antonio * All rights reserved. */ #pragma once #include "../common/id_map.hpp" #include "boat.h" #include "../collisionlib/motion.h" namespace redc { namespace sail { struct Player { std::string name; bool spawned; Hull_Desc boat_config; collis::Motion boat_motio...
/* * Copyright (C) 2015 Luke San Antonio * All rights reserved. */ #pragma once #include "../common/id_map.hpp" #include "boat.h" #include "../collisionlib/motion.h" namespace redc { namespace sail { struct Player { std::string name; bool spawned; Hull_Desc boat_config; collis::Motion boat_motio...
Add user data to Game struct
Add user data to Game struct
C
bsd-3-clause
RedCraneStudio/redcrane-engine,RedCraneStudio/redcrane-engine,RedCraneStudio/redcrane-engine,RedCraneStudio/redcrane-engine
e084ce3506c805a4667aa2d32ef249c5754244cc
ext/libxml/ruby_xml_state.c
ext/libxml/ruby_xml_state.c
/* $Id$ */ #include "ruby_libxml.h" VALUE cXMLState; VALUE LIBXML_STATE = Qnil; static int dummy = 0; void ruby_xml_state_free(int dummy) { xmlCleanupParser(); LIBXML_STATE = Qnil; } VALUE ruby_xml_state_alloc() { #ifdef DEBUG fprintf(stderr, "Allocating state"); #endif xmlInitParser(); return...
/* $Id$ */ #include "ruby_libxml.h" VALUE cXMLState; VALUE LIBXML_STATE = Qnil; static int dummy = 0; void ruby_xml_state_free(int dummy) { xmlCleanupParser(); LIBXML_STATE = Qnil; } VALUE ruby_xml_state_alloc(VALUE klass) { #ifdef DEBUG fprintf(stderr, "Allocating state"); #endif xmlInitParser(); ...
Fix declaration of alloc function.
Fix declaration of alloc function.
C
mit
sferik/libxml-ruby,xml4r/libxml-ruby,sferik/libxml-ruby,sferik/libxml-ruby,xml4r/libxml-ruby,sferik/libxml-ruby,increments/libxml-ruby,xml4r/libxml-ruby,sferik/libxml-ruby,sferik/libxml-ruby,increments/libxml-ruby,increments/libxml-ruby
733710b2daccb85fb0e48a0a4dd98ca10f6e6c9d
src/keyimpl.h
src/keyimpl.h
#pragma once #include "jwtxx/jwt.h" #include <string> namespace JWTXX { struct Key::Impl { virtual std::string sign(const void* data, size_t size) const = 0; virtual bool verify(const void* data, size_t size, const std::string& signature) const = 0; }; }
#pragma once #include "jwtxx/jwt.h" #include <string> namespace JWTXX { struct Key::Impl { virtual ~Impl() {} virtual std::string sign(const void* data, size_t size) const = 0; virtual bool verify(const void* data, size_t size, const std::string& signature) const = 0; }; }
Fix memory leak in key implementations.
Fix memory leak in key implementations.
C
mit
RealImage/jwtxx,RealImage/jwtxx,madf/jwtxx,madf/jwtxx
0616049f570ad86c7d9e4064029d1340f32a4763
src/logging.h
src/logging.h
#pragma once #include <cstdio> namespace happyntrain { #define LOG(message, level, ...) \ printf("[" level "] %s-%d " message "\n", __FILE__, __LINE__, ##__VA_ARGS__); #define INFO(message, ...) LOG(message, "INFO", ##__VA_ARGS__); #define DEBUG(message, ...) LOG(message, "DEBUG", ##__VA_ARGS__); #define ERROR(mes...
#pragma once #include <cstdio> namespace happyntrain { #define LOG(message, level, ...) \ printf("[%5s] %s-%d " message "\n", level, __FILENAME__, __LINE__, \ ##__VA_ARGS__); #define INFO(message, ...) LOG(message, "INFO", ##__VA_ARGS__); #define DEBUG(message, ...) LO...
Add color for error log
Add color for error log
C
mit
emengjzs/happyntrain
a8b18b5159236f5b68e875ddf9ff0d52a0f8ea3c
swaybg/main.c
swaybg/main.c
#include <stdio.h> #include <stdlib.h> #include <wayland-client.h> #include <time.h> #include "client.h" #include "log.h" struct client_state *state; void sway_terminate(void) { client_teardown(state); exit(1); } int main(int argc, char **argv) { init_log(L_INFO); state = client_setup(); uint8_t r = 0, g = 0, ...
#include <stdio.h> #include <stdlib.h> #include <wayland-client.h> #include <time.h> #include "client.h" #include "log.h" struct client_state *state; void sway_terminate(void) { client_teardown(state); exit(1); } int main(int argc, char **argv) { init_log(L_INFO); if (!(state = client_setup())) { return -1; }...
Check the client_setup() return value
Check the client_setup() return value
C
mit
4e554c4c/sway,SirCmpwn/sway,crondog/sway,crondog/sway,taiyu-len/sway,mikkeloscar/sway,colemickens/sway,ptMuta/sway,johalun/sway,4e554c4c/sway,taiyu-len/sway,mikkeloscar/sway,sleep-walker/sway,ascent12/sway,sleep-walker/sway,1ace/sway,taiyu-len/sway,1ace/sway,colemickens/sway,christophgysin/sway,christophgysin/sway,1ace...
037b274e82319843bc95d709b9e6261f7de39c4e
tests/auto/qgsttest.h
tests/auto/qgsttest.h
/* Copyright (C) 2010 George Kiagiadakis <kiagiadakis.george@gmail.com> This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your opti...
/* Copyright (C) 2010 George Kiagiadakis <kiagiadakis.george@gmail.com> This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your opti...
Use QGst::init/cleanup in the tests to properly register the ValueVTables for the gstreamer types.
Use QGst::init/cleanup in the tests to properly register the ValueVTables for the gstreamer types.
C
lgpl-2.1
freedesktop-unofficial-mirror/gstreamer__qt-gstreamer,cyndis/qtgstreamer,detrout/qt-gstreamer,ylatuya/qt-gstreamer,GStreamer/qt-gstreamer,ylatuya/qt-gstreamer,freedesktop-unofficial-mirror/gstreamer__qt-gstreamer,GStreamer/qt-gstreamer,cyndis/qtgstreamer,iperry/qt-gstreamer,shadeslayer/qtgstreamer,iperry/qt-gstreamer,s...
b26d114c3d5d3973fe85085f61e86efa6680260f
lib/quagga/src/common.h
lib/quagga/src/common.h
/* * OLSRd Quagga plugin * * Copyright (C) 2006-2008 Immo 'FaUl' Wehrenberg <immo@chaostreff-dortmund.de> * Copyright (C) 2007-2010 Vasilis Tsiligiannis <acinonyxs@yahoo.gr> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 a...
/* * OLSRd Quagga plugin * * Copyright (C) 2006-2008 Immo 'FaUl' Wehrenberg <immo@chaostreff-dortmund.de> * Copyright (C) 2007-2010 Vasilis Tsiligiannis <acinonyxs@yahoo.gr> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 a...
Change some char type variables to unsigned char
Change some char type variables to unsigned char
C
bsd-3-clause
tdz/olsrd,duydb2/olsr,ninuxorg/olsrd,tdz/olsrd,servalproject/olsr,diogomg/olsrd-binary-heap,zioproto/olsrd-gsoc2012,duydb2/olsr,zioproto/olsrd,servalproject/olsr,ninuxorg/olsrd,acinonyx/olsrd,diogomg/olsrd-binary-heap,diogomg/olsrd,duydb2/olsr,diogomg/olsrd,servalproject/olsr,sebkur/olsrd,sebkur/olsrd,zioproto/olsrd-gs...
2bc02ed37549e09ff449860a73aa03b326910f07
bikepath/GeocodeItem.h
bikepath/GeocodeItem.h
// // GeocodeItem.h // bikepath // // Created by Farheen Malik on 8/19/14. // Copyright (c) 2014 Bike Path. All rights reserved. // #import <Foundation/Foundation.h> @interface GeocodeItem : NSObject @end
// // GeocodeItem.h // bikepath // // Created by Farheen Malik on 8/19/14. // Copyright (c) 2014 Bike Path. All rights reserved. // #import <Foundation/Foundation.h> #import <MapKit/MapKit.h> #import <GoogleMaps/GoogleMaps.h> @interface GeocodeItem : NSObject @property NSString *latitude; @property NSString *lon...
Add address property to object
Add address property to object
C
apache-2.0
hushifei/bike-path,red-spotted-newts-2014/bike-path,red-spotted-newts-2014/bike-path
c89fb451343e8acae2220881bd628e2cada8cb4a
packages/Python/lldbsuite/test/functionalities/swift-runtime-reporting/abi-v2/library.h
packages/Python/lldbsuite/test/functionalities/swift-runtime-reporting/abi-v2/library.h
// library.h // // This source file is part of the Swift.org open source project // // Copyright (c) 2014 - 2016 Apple Inc. and the Swift project authors // Licensed under Apache License v2.0 with Runtime Library Exception // // See https://swift.org/LICENSE.txt for license information // See https://swift.org/CONTRIBU...
// library.h // // This source file is part of the Swift.org open source project // // Copyright (c) 2014 - 2016 Apple Inc. and the Swift project authors // Licensed under Apache License v2.0 with Runtime Library Exception // // See https://swift.org/LICENSE.txt for license information // See https://swift.org/CONTRIBU...
Include the necessary headers to make the swift-runtime-reporting test work.
[testsuite] Include the necessary headers to make the swift-runtime-reporting test work.
C
apache-2.0
apple/swift-lldb,apple/swift-lldb,apple/swift-lldb,apple/swift-lldb,apple/swift-lldb,apple/swift-lldb
0330581ab3b9002d55ee66f377ccbbb742175c01
arch/powerpc/kernel/swsusp.c
arch/powerpc/kernel/swsusp.c
/* * Common powerpc suspend code for 32 and 64 bits * * Copyright 2007 Johannes Berg <johannes@sipsolutions.net> * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version * 2 of t...
/* * Common powerpc suspend code for 32 and 64 bits * * Copyright 2007 Johannes Berg <johannes@sipsolutions.net> * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version * 2 of t...
Fix the call trace when resumed from hibernation
powerpc/mm: Fix the call trace when resumed from hibernation In SMP mode, the kernel would produce call trace when resumed from hibernation. The reason is when the function destroy_context is called to drop the resuming mm context, the mm->context.active is 1 which is wrong and should be zero. We pass the current...
C
mit
KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,TeamVee-Kanas/android_kernel_samsung_kanas,TeamVee-Kanas/android_kernel_samsung_kanas,TeamVee-Kanas/android_kernel_samsung_kanas,KristFoundation/Programs,TeamVee-Kanas/android_kernel_samsung_kana...
a2400149f3df3b8848120d8242a12c5cc4e50eb5
src/Persist.h
src/Persist.h
/* Copyright 2016 Streampunk Media Ltd. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in wri...
/* Copyright 2016 Streampunk Media Ltd. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in wri...
Add missing include for make_unique
Add missing include for make_unique
C
apache-2.0
Streampunk/codecadon,Streampunk/codecadon,Streampunk/codecadon,Streampunk/codecadon
fca3fe6b3b8f7a918025c81597fe7e4c7e450887
tests/lists/cl_list_tests.c
tests/lists/cl_list_tests.c
#include <stdio.h> #include <stdlib.h> #include <cl_list.h> #include <cl_iterator.h> #define QTD 100
#include <stdio.h> #include <stdlib.h> #include <cl_list.h> #include <cl_iterator.h> #define QTD 100 void print_list_iter(cl_list_root *list) { iterator_c *i = cl_iter_create(list, FORWARD); printf("["); if (i != NULL) { do { printf("'%d', ", *((int *) cl_iter_item(i))); } while (cl_iter_next(i) && cl_iter...
Add list_iter for circular list test.
Add list_iter for circular list test.
C
mit
vndmtrx/libadt
40732a47d7d7e570a5124a6acf64665a0566dee9
src/h/startup.h
src/h/startup.h
typedef struct { int cluster; /* Condor Cluster # */ int proc; /* Condor Proc # */ int job_class; /* STANDARD, VANILLA, PVM, PIPE, ... */ uid_t uid; /* Execute job under this UID */ gid_t gid; /* Execute job under this pid */ pid_t virt_pid; /* PVM virt pid of this process */ int soft_ki...
typedef struct { int cluster; /* Condor Cluster # */ int proc; /* Condor Proc # */ int job_class; /* STANDARD, VANILLA, PVM, PIPE, ... */ uid_t uid; /* Execute job under this UID */ gid_t gid; /* Execute job under this pid */ pid_t virt_pid; /* PVM virt pid of this process */ int soft_ki...
Add comment saying that even though the a.out file name is here, it really shouldn't be.
Add comment saying that even though the a.out file name is here, it really shouldn't be.
C
apache-2.0
neurodebian/htcondor,mambelli/osg-bosco-marco,bbockelm/condor-network-accounting,bbockelm/condor-network-accounting,djw8605/condor,zhangzhehust/htcondor,clalancette/condor-dcloud,neurodebian/htcondor,djw8605/htcondor,mambelli/osg-bosco-marco,mambelli/osg-bosco-marco,htcondor/htcondor,zhangzhehust/htcondor,neurodebian/h...
6a5a7dff3117f2e7093fed49bbbb7b2cd1d9704e
src/lib/llist.h
src/lib/llist.h
#ifndef LLIST_H #define LLIST_H /* Doubly linked list */ #define DLLIST_PREPEND(list, item) STMT_START { \ (item)->prev = NULL; \ (item)->next = *(list); \ if (*(list) != NULL) (*(list))->prev = (item); \ *(list) = (item); \ } STMT_END #define DLLIST_REMOVE(list, item) STMT_START { \ if ((item)->prev == NULL) \...
#ifndef LLIST_H #define LLIST_H /* Doubly linked list */ #define DLLIST_PREPEND(list, item) STMT_START { \ (item)->prev = NULL; \ (item)->next = *(list); \ if (*(list) != NULL) (*(list))->prev = (item); \ *(list) = (item); \ } STMT_END #define DLLIST_REMOVE(list, item) STMT_START { \ if ((item)->prev == NULL) \...
Set removed item's prev/next pointers to NULL.
DLLIST_REMOVE(): Set removed item's prev/next pointers to NULL. --HG-- branch : HEAD
C
mit
dscho/dovecot,dscho/dovecot,dscho/dovecot,dscho/dovecot,dscho/dovecot
2c84316746fa61b35efbc0c334fcb2a6dec0d53d
src/vasprintf.c
src/vasprintf.c
#include <stdarg.h> #include <stdio.h> #include <stdlib.h> int vasprintf(char **ret, const char *fmt, va_list ap) { char *buf; int len; size_t buflen; va_list ap2; #ifdef _MSC_VER ap2 = ap; len = _vscprintf(fmt, ap2); // NOTE MS specific extension ( :-( ) #else va_copy(ap2, ap); len = vsnprintf(NULL, 0, fmt,...
#include <stdarg.h> #include <stdio.h> #include <stdlib.h> int vasprintf(char **ret, const char *fmt, va_list ap) { char *buf; int len; size_t buflen; va_list ap2; #if defined(_MSC_VER) || defined(__MINGW64_VERSION_MAJOR) ap2 = ap; len = _vscprintf(fmt, ap2); // NOTE MS specific extension ( :-( ) #else va_cop...
Use _vscprintf() for mingw-w64 compilers
Use _vscprintf() for mingw-w64 compilers The mingw-w64 compilers implement a vsnprintf() function that do not conform to the C99 standard (just like MSVC).
C
mit
mono/eglib,mono/eglib
4f1caf24100fb7a0d0c1ab8fcc10f2e9a412e0cd
CefSharp.Core/Internals/CefRequestCallbackWrapper.h
CefSharp.Core/Internals/CefRequestCallbackWrapper.h
// Copyright 2010-2015 The CefSharp Authors. All rights reserved. // // Use of this source code is governed by a BSD-style license that can be found in the LICENSE file. #pragma once #include "Stdafx.h" using namespace CefSharp; namespace CefSharp { namespace Internals { public ref class CefRequest...
// Copyright 2010-2015 The CefSharp Authors. All rights reserved. // // Use of this source code is governed by a BSD-style license that can be found in the LICENSE file. #pragma once #include "Stdafx.h" using namespace CefSharp; namespace CefSharp { namespace Internals { public ref class CefRequest...
Change to use IRequest instead (use interfaces for classes where possible)
Change to use IRequest instead (use interfaces for classes where possible)
C
bsd-3-clause
wangzheng888520/CefSharp,joshvera/CefSharp,Haraguroicha/CefSharp,Haraguroicha/CefSharp,dga711/CefSharp,rlmcneary2/CefSharp,haozhouxu/CefSharp,ruisebastiao/CefSharp,yoder/CefSharp,illfang/CefSharp,battewr/CefSharp,zhangjingpu/CefSharp,illfang/CefSharp,twxstar/CefSharp,windygu/CefSharp,ITGlobal/CefSharp,jamespearce2006/C...
d6b237df5e17eab304b62a01ff377a1e9fda0caf
win32/PlatWin.h
win32/PlatWin.h
// Scintilla source code edit control /** @file PlatWin.h ** Implementation of platform facilities on Windows. **/ // Copyright 1998-2011 by Neil Hodgson <neilh@scintilla.org> // The License.txt file describes the conditions under which this software may be distributed. extern bool IsNT(); extern void Platform_Initi...
// Scintilla source code edit control /** @file PlatWin.h ** Implementation of platform facilities on Windows. **/ // Copyright 1998-2011 by Neil Hodgson <neilh@scintilla.org> // The License.txt file describes the conditions under which this software may be distributed. extern bool IsNT(); extern void Platform_Initi...
Allow choice of D2D on compiler command line.
Allow choice of D2D on compiler command line.
C
isc
timonwong/foo_uie_wsh_panel_mod.scintilla,timonwong/foo_uie_wsh_panel_mod.scintilla,timonwong/foo_uie_wsh_panel_mod.scintilla,timonwong/foo_uie_wsh_panel_mod.scintilla,timonwong/foo_uie_wsh_panel_mod.scintilla,timonwong/foo_uie_wsh_panel_mod.scintilla,timonwong/foo_uie_wsh_panel_mod.scintilla,timonwong/foo_uie_wsh_pane...
83e16fa7755f2b4c908366d28aa83180a2d9e817
PHPHub/Constants/SecretConstant.example.h
PHPHub/Constants/SecretConstant.example.h
// // SecretConstant.example.h // PHPHub // // Created by Aufree on 9/30/15. // Copyright (c) 2015 ESTGroup. All rights reserved. // #if DEBUG #define Client_id @"kHOugsx4dmcXwvVbmLkd" #define Client_secret @"PuuFCrF94MloSbSkxpwS" #else #define Client_id @"Set up a client id for production env" #defi...
// // SecretConstant.example.h // PHPHub // // Created by Aufree on 9/30/15. // Copyright (c) 2015 ESTGroup. All rights reserved. // #if DEBUG #define Client_id @"kHOugsx4dmcXwvVbmLkd" #define Client_secret @"PuuFCrF94MloSbSkxpwS" #else #define Client_id @"" // Set up a client id for production envir...
Update comments of SecretConstant file
Update comments of SecretConstant file
C
mit
Aufree/phphub-ios
a8d2223c18dad7981b74670ef719d9dcc5833679
ann.h
ann.h
#ifndef ANN_H #define ANN_H #endif
#ifndef ANN_H #define ANN_H #define INPUTS 3 #define HIDDEN 5 #define OUTPUTS 2 #define ROWS 5 typedef struct { double input[HIDDEN][INPUTS + 1]; double hidden[ROWS - 3][HIDDEN][HIDDEN + 1]; double output[OUTPUTS][HIDDEN + 1]; } Links; typedef struct { int input[INPUTS]; int hidden[ROWS - 2][HIDD...
Create contents of .h file
Create contents of .h file
C
mit
tysonzero/c-ann
777e88ac428fa5af101a3345359fa563fd7c1e8e
IAAI.c
IAAI.c
#include <stdio.h> #include <stdlib.h> #include <string.h> #define STTY "/bin/stty " const char RAW[] = STTY "raw"; const char COOKED[] = STTY "cooked"; int main() { system(RAW); char str[] = "I AM AN IDIOT "; size_t len = strlen(str); while ( 1 ) { for ( size_t i = 0 ; i < len ; i++ ) { getchar()...
#include <stdio.h> #include <stdlib.h> #include <string.h> #define STTY "/bin/stty " const char RAW[] = STTY "raw"; const char COOKED[] = STTY "cooked"; const char default_str[] = "I AM AN IDIOT "; int main(int argc, char **argv) { system(RAW); const char *str; if ( argc == 2 ) str = argv[1]; else s...
Allow user to choose if they want :)
Allow user to choose if they want :)
C
mit
vinamarora8/IAAI
a528fce787eb40471330c0464848b8a6b9f72b44
Tokaido/TKDApp.h
Tokaido/TKDApp.h
// // TKDApp.h // Tokaido // // Created by Mucho Besos on 10/25/12. // Copyright (c) 2012 Tilde. All rights reserved. // #import <Cocoa/Cocoa.h> typedef enum : NSUInteger { TKDAppOff, TKDAppBooting, TKDAppOn, TKDAppShuttingDown } TKDAppState; @interface TKDApp : MTLModel @property (nonatomic, co...
// // TKDApp.h // Tokaido // // Created by Mucho Besos on 10/25/12. // Copyright (c) 2012 Tilde. All rights reserved. // #import <Cocoa/Cocoa.h> typedef enum : NSUInteger { TKDAppOff, TKDAppBooting, TKDAppOn, TKDAppShuttingDown } TKDAppState; typedef enum : NSUInteger { TKDAppBundling, TK...
Add booting substate for message
Add booting substate for message
C
mit
webdev1001/tokaidoapp,tokaido/tokaidoapp,tokaido/tokaidoapp,webdev1001/tokaidoapp,webdev1001/tokaidoapp,webdev1001/tokaidoapp,tokaido/tokaidoapp
30658b235a7a7b8df8164741d03dd9fc6e45129d
system/coro.c
system/coro.c
#include "coro.h" #include "stack.h" #include <assert.h> #include <stdlib.h> #include <string.h> coro *coro_spawn(coro *me, coro_func f, size_t ssize) { coro *c = (coro*)malloc(sizeof(coro)); assert(c != NULL); c->running = 0; c->base = malloc(ssize); assert(c->base != NULL); c->stack = c->base + ssize; ...
#include "coro.h" #include "stack.h" #include <assert.h> #include <stdlib.h> #include <string.h> coro *coro_spawn(coro *me, coro_func f, size_t ssize) { coro *c = (coro*)malloc(sizeof(coro)); assert(c != NULL); c->running = 0; c->base = malloc(ssize); assert(c->base != NULL); c->stack = (char*) c->base + s...
Make pointer arithmetic warning go away
Make pointer arithmetic warning go away
C
bsd-3-clause
buaasun/grappa,buaasun/grappa,alexfrolov/grappa,alexfrolov/grappa,alexfrolov/grappa,alexfrolov/grappa,uwsampa/grappa,uwsampa/grappa,uwsampa/grappa,alexfrolov/grappa,uwsampa/grappa,uwsampa/grappa,alexfrolov/grappa,buaasun/grappa,buaasun/grappa,alexfrolov/grappa,buaasun/grappa,buaasun/grappa,buaasun/grappa,uwsampa/grappa...
cfab8acf28fd7aff0b2d355c9935b028376ea08e
sequence.h
sequence.h
#ifndef SEQUENCE_H #define SEQUENCE_H #include "object.h" typedef enum IterType_ {ITERLIST, ITERVECTOR} IterType; typedef struct Iter_ { IterType type; union { struct { Object *node; bool first; } list; struct { Object *object; int inde...
#ifndef SEQUENCE_H #define SEQUENCE_H #include "object.h" typedef enum IterType_ {ITERLIST, ITERVECTOR} IterType; typedef struct Iter_ { IterType type; union { struct { Object *node; bool first; } list; struct { Object *object; int inde...
Mark some functions as pure
Mark some functions as pure
C
mit
ids1024/idslisp
d61970e389e32156543068e359c5af767bb3e549
src/main.h
src/main.h
#pragma once #include <unistd.h> #include <iostream> #include <list> #include <map> #include <mutex> #include <unordered_map> #include <queue> #include <sstream> #include <thread> #include <tuple> #include <vector>
#pragma once #include <unistd.h> #include <iostream> #include <list> #include <map> #include <mutex> #include <unordered_map> #include <queue> #include <sstream> #include <set> #include <thread> #include <tuple> #include <vector>
Include missing necessary include <set>
Include missing necessary include <set>
C
mit
ElementalAlchemist/RoBoBo,ElementalAlchemist/RoBoBo
1a16a79939e53044d07009bc746cfe9a08e878d4
IA32ABI/xabicc.c
IA32ABI/xabicc.c
/* * xabicc.c - platform-agnostic root for ALien call-outs and callbacks. * * Support for Call-outs and Call-backs from the IA32ABI Plugin. * The plgin is misnamed. It should be the AlienPlugin, but its history * dictates otherwise. */ #if i386|i486|i586|i686 # include "ia32abicc.c" #elif powerpc|ppc # include ...
/* * xabicc.c - platform-agnostic root for ALien call-outs and callbacks. * * Support for Call-outs and Call-backs from the IA32ABI Plugin. * The plgin is misnamed. It should be the AlienPlugin, but its history * dictates otherwise. */ #if i386|i486|i586|i686 # include "ia32abicc.c" #elif powerpc|ppc # include ...
Make the list of x64 processor names inclusive enough to compile the Alien plugin on 64-bit linux.
Make the list of x64 processor names inclusive enough to compile the Alien plugin on 64-bit linux. git-svn-id: http://squeakvm.org/svn/squeak/trunk@3237 fa1542d4-bde8-0310-ad64-8ed1123d492a Former-commit-id: 600bd5e36821553d6b9391d8bbd8d75d4ad10a85
C
mit
timfel/squeakvm,timfel/squeakvm,timfel/squeakvm,bencoman/pharo-vm,peteruhnak/pharo-vm,timfel/squeakvm,bencoman/pharo-vm,peteruhnak/pharo-vm,bencoman/pharo-vm,timfel/squeakvm,bencoman/pharo-vm,timfel/squeakvm,timfel/squeakvm,bencoman/pharo-vm,timfel/squeakvm,bencoman/pharo-vm,peteruhnak/pharo-vm,OpenSmalltalk/vm,OpenSma...
03aa0b50b157b97af1dbaf93461c4941bc0bbfaa
benchs/MatMulC.c
benchs/MatMulC.c
#include <stdlib.h> #include "MatMulC.h" void MatMulC(int rows, int len, double *a, double *b, double *c) { int i,j,k; for( i = 0; i < rows; i++ ) { for( j = 0; j < rows; j+=2 ) { double sum0 = 0.0; double sum1 = 0.0; for( k = 0; k < rows; k++ ) { sum0 += a[i*rows+k] * b[k*rows + j];...
#include <stdlib.h> #include "MatMulC.h" void MatMulC(int rows, int len, double *a, double *bin, double *c) { int i,j,k; double *b = malloc(len * sizeof(double)); // Transpose bin with result in b. for(int n = 0; n < len; n++ ) { b[n] = bin[rows * (n % rows) + (n / rows)]; } for( i = 0; i < rows; i++...
Transpose the second matrix in the C reference for MatMul.
Transpose the second matrix in the C reference for MatMul.
C
bsd-3-clause
emwap/feldspar-compiler,emwap/feldspar-compiler
45fb9eb248df779c8fa845dac32bcafd2c129d40
include/LinearLayout.h
include/LinearLayout.h
#ifndef _LINEARLAYOUT_H_ #define _LINEARLAYOUT_H_ #include <Element.h> #include <Command.h> #define FW_VERTICAL 1 #define FW_HORIZONTAL 2 class LinearLayout : public Element { public: LinearLayout(int _direction, int _id) : Element(_id), direction(_direction) { } bool isA(const std::string & className) overri...
#ifndef _LINEARLAYOUT_H_ #define _LINEARLAYOUT_H_ #include <Element.h> #include <Command.h> #define FW_VERTICAL 1 #define FW_HORIZONTAL 2 class LinearLayout : public Element { public: LinearLayout(int _direction, int _id = 0) : Element(_id), direction(_direction) { } bool isA(const std::string & className) ov...
Add default value to id on constructor
Add default value to id on constructor
C
mit
Sometrik/framework,Sometrik/framework,Sometrik/framework
e800dd51a625cadc087c40cd41fd31d68e4f52bc
include/scopemeasure.h
include/scopemeasure.h
#ifndef NEWSBOAT_SCOPEMEASURE_H_ #define NEWSBOAT_SCOPEMEASURE_H_ #include <sys/time.h> #include <string> #include "logger.h" namespace newsboat { class ScopeMeasure { public: ScopeMeasure(const std::string& func, Level ll = Level::DEBUG); ~ScopeMeasure(); void stopover(const std::string& son = ""); private: s...
#ifndef NEWSBOAT_SCOPEMEASURE_H_ #define NEWSBOAT_SCOPEMEASURE_H_ #include <sys/time.h> #include <string> #include "logger.h" namespace newsboat { class ScopeMeasure { public: ScopeMeasure(const std::string& func, Level ll = Level::DEBUG); ~ScopeMeasure(); void stopover(const std::string& son = ""); private: s...
Initialize all members of ScopeMeasure
Initialize all members of ScopeMeasure Problem spotted by PVS Studio.
C
mit
newsboat/newsboat,der-lyse/newsboat,newsboat/newsboat,newsboat/newsboat,der-lyse/newsboat,newsboat/newsboat,newsboat/newsboat,der-lyse/newsboat,der-lyse/newsboat,newsboat/newsboat,der-lyse/newsboat,der-lyse/newsboat,newsboat/newsboat,der-lyse/newsboat,newsboat/newsboat,der-lyse/newsboat
3b7da8cd1e2f77d73cc19533fc657ba10a80c8cd
include/tgbot/export.h
include/tgbot/export.h
#ifndef TGBOT_EXPORT_H #define TGBOT_EXPORT_H #ifndef TGBOT_API #ifdef TGBOT_DLL #if defined _WIN32 || defined __CYGWIN__ #define TGBOT_HELPER_DLL_IMPORT __declspec(dllimport) #define TGBOT_HELPER_DLL_EXPORT __declspec(dllexport) #else #if __GNUC__ >= 4 ...
#ifndef TGBOT_EXPORT_H #define TGBOT_EXPORT_H #ifndef TGBOT_API #ifdef TGBOT_DLL #if defined _WIN32 || defined __CYGWIN__ #define TGBOT_HELPER_DLL_EXPORT __declspec(dllexport) #define TGBOT_HELPER_DLL_IMPORT __declspec(dllimport) #else #if __GNUC__ >= 4 ...
Fix mistake FOX and reorder EXPORT/IMPORT
Fix mistake FOX and reorder EXPORT/IMPORT
C
mit
reo7sp/tgbot-cpp,reo7sp/tgbot-cpp,reo7sp/tgbot-cpp
37b123271739ea3a8dcd9397873b9c2e9949fe6f
packages/Python/lldbsuite/test/make/pseudo_barrier.h
packages/Python/lldbsuite/test/make/pseudo_barrier.h
#include <atomic> #include <thread> typedef std::atomic<int> pseudo_barrier_t; static inline void pseudo_barrier_wait(pseudo_barrier_t &barrier) { --barrier; while (barrier > 0) std::this_thread::yield(); } static inline void pseudo_barrier_init(pseudo_barrier_t &barrier, int count) { barrier = count; }
#include <atomic> // Note that although hogging the CPU while waiting for a variable to change // would be terrible in production code, it's great for testing since it avoids // a lot of messy context switching to get multiple threads synchronized. typedef std::atomic<int> pseudo_barrier_t; #define pseudo_barrier_wa...
Revert "[test] Address TestConcurrentMany*.py flakiness on macOS"
Revert "[test] Address TestConcurrentMany*.py flakiness on macOS" This reverts my change to pseudo_barrier.h which isn't necessary anymore after Fred's fix to debugserver and caused TestThreadStepOut to fail. git-svn-id: 4c4cc70b1ef44ba2b7963015e681894188cea27e@370963 91177308-0d34-0410-b5e6-96231b3b80d8
C
apache-2.0
llvm-mirror/lldb,apple/swift-lldb,llvm-mirror/lldb,llvm-mirror/lldb,apple/swift-lldb,llvm-mirror/lldb,apple/swift-lldb,apple/swift-lldb,apple/swift-lldb,llvm-mirror/lldb,apple/swift-lldb
0db658e796e364ebbd401d03b4b14961c59da77b
States/StatesController+DragNDrop.h
States/StatesController+DragNDrop.h
// // StatesController+DragNDrop.h // States // // Created by Dmitry Rodionov on 13/06/16. // Copyright © 2016 Internals Exposed. All rights reserved. // #import "StatesController.h" @interface StatesController (DragNDrop) @end
// // StatesController+DragNDrop.h // States // // Created by Dmitry Rodionov on 13/06/16. // Copyright © 2016 Internals Exposed. All rights reserved. // #import "StatesController.h" @interface StatesController (DragNDrop) // This category implements the following NSTableViewDataSources methods: - (BOOL)tableVi...
Add missing header into for DragNDrop category on StatesContoller
Add missing header into for DragNDrop category on StatesContoller
C
mit
edenvidal/States,edenvidal/States
3a7937af55780e9b2d38ff234d8ddbda90578313
You-GUI/stdafx.h
You-GUI/stdafx.h
//@author A0094446X #pragma once #ifndef YOU_GUI_STDAFX_H_ #define YOU_GUI_STDAFX_H_ #include <QtWidgets> #endif // YOU_GUI_STDAFX_H_
//@author A0094446X #pragma once #ifndef YOU_GUI_STDAFX_H_ #define YOU_GUI_STDAFX_H_ #include <memory> #include <QApplication> #include <QList> #include <QWidget> #include <QtWidgets> #include <boost/date_time/gregorian/greg_month.hpp> #include <boost/date_time/posix_time/posix_time.hpp> #endif // YOU_GUI_STDAFX_H_...
Add more files to the PCH for faster compiles.
Add more files to the PCH for faster compiles.
C
mit
cs2103aug2014-w10-1c/main,cs2103aug2014-w10-1c/main
e567e0d86bcabd0746ec0704ea56598d8c15d728
Settings/Controls/Controls.h
Settings/Controls/Controls.h
#pragma once #include "Control.h" #include "Button.h" #include "Checkbox.h" #include "ComboBox.h" #include "Label.h" #include "ListView.h" #include "Spinner.h" #include "EditBox.h"
#pragma once #include "Control.h" #include "Button.h" #include "Checkbox.h" #include "ComboBox.h" #include "GroupBox.h" #include "Label.h" #include "ListView.h" #include "Spinner.h" #include "EditBox.h"
Add groupbox to control header
Add groupbox to control header
C
bsd-2-clause
malensek/3RVX,Soulflare3/3RVX,Soulflare3/3RVX,malensek/3RVX,Soulflare3/3RVX,malensek/3RVX
583acd2de697ec1f6d148755fe01df3ba97d7bfd
nbtk/nbtkmodule.c
nbtk/nbtkmodule.c
#include <pygobject.h> #include <clutter/clutter.h> void pynbtk_register_classes (PyObject *d); void pynbtk_add_constants (PyObject *module, const gchar *prefix); extern PyMethodDef pynbtk_functions[]; DL_EXPORT(void) init_nbtk(void) { PyObject *m, *d; init_pygobject_check (2, 12, 0); m = Py_InitM...
#include <pygobject.h> #include <nbtk/nbtk.h> void pynbtk_register_classes (PyObject *d); void pynbtk_add_constants (PyObject *module, const gchar *prefix); extern PyMethodDef pynbtk_functions[]; static void sink_nbtkaction (GObject *object) { if (g_object_is_floating (object)) g_object_ref_sink (object); }...
Add a sink function for nbtk.Action
Add a sink function for nbtk.Action NbtkAction is a GInitiallyUnowned, so we need to register a sinkfunc.
C
lgpl-2.1
buztard/mxpy,buztard/mxpy,buztard/mxpy
bd6a64a57f85933059231789ed6ec117bd1089da
ADLivelyCollectionView.h
ADLivelyCollectionView.h
// // ADLivelyCollectionView.h // ADLivelyCollectionView // // Created by Romain Goyet on 18/04/12. // Copyright (c) 2012 Applidium. All rights reserved. // #import <UIKit/UIKit.h> extern NSTimeInterval ADLivelyDefaultDuration; typedef NSTimeInterval (^ADLivelyTransform)(CALayer * layer, float speed); extern ADL...
// // ADLivelyCollectionView.h // ADLivelyCollectionView // // Created by Romain Goyet on 18/04/12. // Copyright (c) 2012 Applidium. All rights reserved. // #import <UIKit/UIKit.h> extern NSTimeInterval ADLivelyDefaultDuration; typedef NSTimeInterval (^ADLivelyTransform)(CALayer * layer, float speed); extern ADL...
Add comment for the speed threshold
Add comment for the speed threshold
C
bsd-3-clause
applidium/ADLivelyCollectionView
22eb291b9dc8943094e143a71c3eac237f4a54c2
command_mode.c
command_mode.c
#include "mode.h" #include <stdlib.h> #include <string.h> #include <termbox.h> #include "buf.h" #include "editor.h" static void command_mode_key_pressed(editor_t *editor, struct tb_event *ev) { char ch; switch (ev->key) { case TB_KEY_ESC: buf_printf(editor->status, ""); editor->mode = normal_mode(); ...
#include "mode.h" #include <stdlib.h> #include <string.h> #include <termbox.h> #include "buf.h" #include "editor.h" // TODO(isbadawi): Command mode needs a cursor, but modes don't affect drawing. static void command_mode_key_pressed(editor_t *editor, struct tb_event *ev) { char ch; switch (ev->key) { case TB_...
Add TODO re: command mode cursor.
Add TODO re: command mode cursor. This will also be an issue for visual mode.
C
mit
isbadawi/badavi
ae5e1b42c06cf04a2fcf6ec78c4b028aa69791eb
ReactiveCocoaFramework/ReactiveCocoa/UIActionSheet+RACSignalSupport.h
ReactiveCocoaFramework/ReactiveCocoa/UIActionSheet+RACSignalSupport.h
// // UIActionSheet+RACSignalSupport.h // ReactiveCocoa // // Created by Dave Lee on 2013-06-22. // Copyright (c) 2013 GitHub, Inc. All rights reserved. // #import <UIKit/UIKit.h> @class RACDelegateProxy; @class RACSignal; @interface UIActionSheet (RACSignalSupport) // A delegate proxy which will be set as the ...
// // UIActionSheet+RACSignalSupport.h // ReactiveCocoa // // Created by Dave Lee on 2013-06-22. // Copyright (c) 2013 GitHub, Inc. All rights reserved. // #import <UIKit/UIKit.h> @class RACDelegateProxy; @class RACSignal; @interface UIActionSheet (RACSignalSupport) // A delegate proxy which will be set as the ...
Copy documentation wording from UITextView+RACSignalSupport.h
Copy documentation wording from UITextView+RACSignalSupport.h
C
mit
buildo/ReactiveCocoa,ioshger0125/ReactiveCocoa,yaoxiaoyong/ReactiveCocoa,fanghao085/ReactiveCocoa,cstars135/ReactiveCocoa,itschaitanya/ReactiveCocoa,longv2go/ReactiveCocoa,ReactiveCocoa/ReactiveSwift,paulyoung/ReactiveCocoa,itschaitanya/ReactiveCocoa,Ray0218/ReactiveCocoa,Carthage/ReactiveCocoa,qq644531343/ReactiveCoco...
9e903e78de2ca4a4b4aaa80b2dc6320e581c87da
c-in-mips.c
c-in-mips.c
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <ctype.h> #include <math.h> static int RegisterFile[32] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }; int main() { int data_memory[1024]; char string_memeory[2014]; }
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <ctype.h> #include <math.h> static int RegisterFile[32] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }; int main() { int data_memory[1024]; char* string_memory[2014]; char* instructions[100]; ...
Fix typos, add instruction memory
Fix typos, add instruction memory
C
apache-2.0
jacobbieker/MIPS-In-C
8800559e793472408e0d44efeb4642bf3808f13e
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 108 #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 109 #endif
Update Skia milestone to 109
Update Skia milestone to 109 Change-Id: I6acfef789b38f71183304cc3741c119265561b3c Reviewed-on: https://skia-review.googlesource.com/c/skia/+/591477 Reviewed-by: Rakshit Sharma <e91e6cdce3825eaad0fa11b55195605cfed87fab@google.com> Owners-Override: Kevin Lubick <7cdab2cfab351f23814786ba39716e90eed69047@google.com> Auto-...
C
bsd-3-clause
google/skia,google/skia,google/skia,google/skia,google/skia,google/skia,google/skia,google/skia,google/skia,google/skia
5cec34cba823feb1e1b47d95de433f1ac96ea873
is/ac_tlm_bus/ac_tlm_bus.h
is/ac_tlm_bus/ac_tlm_bus.h
#ifndef AC_TLM_BUS_H_ #define AC_TLM_BUS_H_ #include <systemc> #include "ac_tlm_protocol.H" #include "ac_tlm_port.H" #include "ac_memport.H" // using statements using tlm::tlm_transport_if; //#define DEBUG /// Namespace to isolate bus from ArchC namespace user { /// A TLM bus class ac_tlm_bus : public sc_module,...
#ifndef AC_TLM_BUS_H_ #define AC_TLM_BUS_H_ #include <systemc> #include "ac_tlm_protocol.H" #include "ac_tlm_port.H" #include "ac_memport.H" // using statements using tlm::tlm_transport_if; //#define DEBUG /// Namespace to isolate bus from ArchC namespace user { /// A TLM bus class ac_tlm_bus : public sc_module,...
Make room for 8 processors in the bus.
Make room for 8 processors in the bus.
C
lgpl-2.1
eggpi/mc723-p3,guilherme-pg/mc723-p3,guilherme-pg/mc723-p3,eggpi/mc723-p3,eggpi/mc723-p3,guilherme-pg/mc723-p3,guilherme-pg/mc723-p3,eggpi/mc723-p3
e40600458fdf7a84940f1de3103886173646b19b
lib/libncurses/lib_insdel.c
lib/libncurses/lib_insdel.c
/* This work is copyrighted. See COPYRIGHT.OLD & COPYRIGHT.NEW for * * details. If they are missing then this copy is in violation of * * the copyright conditions. */ /* ** lib_insdel.c ** ** The routine winsdel(win, n). ** positive n insert n lines above current line **...
/* This work is copyrighted. See COPYRIGHT.OLD & COPYRIGHT.NEW for * * details. If they are missing then this copy is in violation of * * the copyright conditions. */ /* ** lib_insdel.c ** ** The routine winsdel(win, n). ** positive n insert n lines above current line **...
Handle the condition where BS is typed while the cursor is at the first position on either of the last two lines of the screen. Ie. append contents of current line to the previous line and scroll the next line's contents up.
Handle the condition where BS is typed while the cursor is at the first position on either of the last two lines of the screen. Ie. append contents of current line to the previous line and scroll the next line's contents up. PR: 5392 Submitted by: Kouichi Hirabayashi <kh@mogami-wire.co.jp>
C
bsd-3-clause
jrobhoward/SCADAbase,jrobhoward/SCADAbase,jrobhoward/SCADAbase,jrobhoward/SCADAbase,jrobhoward/SCADAbase,jrobhoward/SCADAbase,jrobhoward/SCADAbase,jrobhoward/SCADAbase,jrobhoward/SCADAbase,jrobhoward/SCADAbase,jrobhoward/SCADAbase
217625d26001121e40c1e309321d2b9a104623f6
wisp.c
wisp.c
#include <stdio.h> #include "common.h" #include "wisp.h" #include "lisp.h" /* parser crap */ extern FILE *yyin; int yyparse (); void parser_init (); extern int interactive; extern char *prompt; /* Initilize all the systems. */ void init () { /* These *must* be called in this order. */ object_init (); symtab_ini...
#include <stdio.h> #include "common.h" #include "wisp.h" #include "lisp.h" /* parser crap */ extern FILE *yyin; int yyparse (); void parser_init (); extern int interactive; extern char *prompt; /* Initilize all the systems. */ void init () { /* These *must* be called in this order. */ object_init (); symtab_ini...
Print newline on clean exit.
Print newline on clean exit.
C
unlicense
skeeto/wisp,skeeto/wisp
dbf67e0819451323569fbdfc4280ad4cb2310d39
bugs/cpp/strip_comment.c
bugs/cpp/strip_comment.c
#define typename(x) _Generic((x), \ _Bool: "_BoolÓ, unsigned char: "unsigned charÓ, \ char: "char", signed char: "signed char", \ void *: "pointer to voidÓ, int *: "pointer to ...
#define typename(x) _Generic((x), \ _Bool: "_Bool", unsigned char: "unsigned char", \ char: "char", signed char: "signed char", \ void *: "pointer to void", int *: "pointer to ...
Remove unicode from cpp bug example
Remove unicode from cpp bug example
C
mit
bobrippling/ucc-c-compiler,bobrippling/ucc-c-compiler,bobrippling/ucc-c-compiler
8e237cddafb82de65bdca14de6a4b05d3f51b2ea
goontools.c
goontools.c
#include "goontools.h" void usage(char* prog) { fprintf(stderr, "\n"); fprintf(stderr, "Usage: %s <subcommand> <subcommand arguments>\n", prog); fprintf(stderr, "\n"); fprintf(stderr, "subcommands:\n"); fprintf(stderr, " index index file\n"); fprintf(stderr, " sort sort file\n"); ...
#include "goontools.h" void usage(char* prog) { fprintf(stderr, "\n"); fprintf(stderr, "Usage: %s <subcommand> <subcommand arguments>\n", prog); fprintf(stderr, "\n"); fprintf(stderr, "subcommands:\n"); fprintf(stderr, " index index file\n"); fprintf(stderr, " sort sort file\n"); ...
Make subcommands' argc/argv compatible with getopt
Make subcommands' argc/argv compatible with getopt
C
mit
mhyfritz/goontools,mhyfritz/goontools,mhyfritz/goontools
d1940709771ccf2835a019fc095880e3192eae93
inc/time_hao.h
inc/time_hao.h
#ifndef TIME_HAO #define TIME_HAO #include <time.h> class Timer_hao { public: double seconds; int timing_flag; time_t timerinit,timerend; Timer_hao(); Timer_hao(double); Timer_hao(const Timer_hao& ); ~Timer_hao(); Timer_hao& operator = (const Timer_hao&); void init()...
#ifndef TIME_HAO_H #define TIME_HAO_H #include <time.h> class Timer_hao { public: double seconds; int timing_flag; time_t timerinit,timerend; Timer_hao(); Timer_hao(double); Timer_hao(const Timer_hao& ); ~Timer_hao(); Timer_hao& operator = (const Timer_hao&); void in...
Set the header protection to end with _H.
Set the header protection to end with _H.
C
mit
hshi/time_lib_hao
fa64def4cb805afb0cc8d966dab534e9137f3c66
src/Settings.h
src/Settings.h
// This program is free software licenced under MIT Licence. You can // find a copy of this licence in LICENCE.txt in the top directory of // source code. // #ifndef SETTINGS_H_INCLUDED #define SETTINGS_H_INCLUDED #include <vector> #include <tuple> /** * This file contains gereral configuration and thing whoch sho...
// This program is free software licenced under MIT Licence. You can // find a copy of this licence in LICENCE.txt in the top directory of // source code. // #ifndef SETTINGS_H_INCLUDED #define SETTINGS_H_INCLUDED #include <vector> #include <tuple> /** * This file contains gereral configuration and thing whoch sho...
Update number of armies on wastelands
Update number of armies on wastelands
C
mit
calincru/Warlight-AI-Challenge-2-Bot,calincru/Warlight-AI-Challenge-2-Bot
194e314afe721d748735114c68b9a723a8f74b05
Riot/SupportingFiles/Riot-Bridging-Header.h
Riot/SupportingFiles/Riot-Bridging-Header.h
// // Use this file to import your target's public headers that you would like to expose to Swift. // @import MatrixSDK; @import MatrixKit; #import "WebViewViewController.h" #import "RiotNavigationController.h" #import "ThemeService.h" #import "TableViewCellWithCheckBoxAndLabel.h" #import "RecentsDataSource.h" #impo...
// // Use this file to import your target's public headers that you would like to expose to Swift. // @import MatrixSDK; @import MatrixKit; #import "WebViewViewController.h" #import "RiotNavigationController.h" #import "ThemeService.h" #import "TableViewCellWithCheckBoxAndLabel.h" #import "RecentsDataSource.h" #impo...
Add RoomBubbleCellData.h and MXKRoomBubbleTableViewCell+Riot.h to Objective-C bridging header.
Add RoomBubbleCellData.h and MXKRoomBubbleTableViewCell+Riot.h to Objective-C bridging header.
C
apache-2.0
vector-im/riot-ios,vector-im/riot-ios,vector-im/riot-ios,vector-im/riot-ios,vector-im/riot-ios,vector-im/vector-ios,vector-im/vector-ios,vector-im/riot-ios,vector-im/vector-ios
2af33bb34a78b1ecd91cc9f9d92351e7a762530b
src/cilkplus.h
src/cilkplus.h
#ifndef CILKPLUS_H #define CILKPLUS_H #include <cilk/cilk.h> #define fibril #define fibril_t __attribute__((unused)) int #define fibril_init(fp) #define fibril_join(fp) cilk_sync #define fibril_fork_nrt(fp, fn, ag) cilk_spawn fn ag #define fibril_fork_wrt(fp, rt, fn, ag) rt = cilk_spawn fn ag #define fibril_rt_...
#ifndef CILKPLUS_H #define CILKPLUS_H #include <cilk/cilk.h> #define fibril #define fibril_t __attribute__((unused)) int #define fibril_init(fp) #define fibril_join(fp) cilk_sync #define fibril_fork_nrt(fp, fn, ag) cilk_spawn fn ag #define fibril_fork_wrt(fp, rt, fn, ag) rt = cilk_spawn fn ag #define fibril_rt_...
Use 8MB as the default stack size in CilkPlus.
Use 8MB as the default stack size in CilkPlus.
C
mit
chaoran/fibril,chaoran/fibril,chaoran/fibril
80dadf74982bc78acb1fedd5e9e65f754d6bbee8
native/spinner_with_stacks/program.c
native/spinner_with_stacks/program.c
#include <stdio.h> void SpinYetAgain() { volatile unsigned int count = 0; for(int i=0; i<1000; i++) { count++; } } void SpinSomeMore() { volatile unsigned int count = 0; for(int i=0; i<1000; i++) { count++; } SpinYetAgain(); } void Spin() { volatile unsigned i...
#include <stdio.h> void SpinYetAgain() { volatile unsigned int count = 0; int i; for(i=0; i<1000; i++) { count++; } } void SpinSomeMore() { volatile unsigned int count = 0; int i; for(i=0; i<1000; i++) { count++; } SpinYetAgain(); } void Spin() { volat...
Fix C declaration errors on ARM.
Fix C declaration errors on ARM.
C
mit
brianrob/coretests,brianrob/coretests
cee852ab5abc167b1996043f2398e47902ca7068
project_config/lmic_project_config.h
project_config/lmic_project_config.h
// project-specific definitions for otaa sensor //#define CFG_eu868 1 //#define CFG_us915 1 //#define CFG_au921 1 #define CFG_as923 1 #define LMIC_COUNTRY_CODE LMIC_COUNTRY_CODE_JP //#define CFG_in866 1 #define CFG_sx1276_radio 1 //#define LMIC_USE_INTERRUPTS
// project-specific definitions for otaa sensor //#define CFG_eu868 1 //#define CFG_us915 1 //#define CFG_au921 1 #define CFG_as923 1 #define LMIC_COUNTRY_CODE LMIC_COUNTRY_CODE_JP //#define CFG_in866 1 #define CFG_sx1276_radio 1 //#define LMIC_USE_INTERRUPTS #define LMIC_DEBUG_LEVEL 2 #define LMIC_DEBUG_PRINTF_FN lm...
Set debug level to 2 and use a suitable printf function
Set debug level to 2 and use a suitable printf function
C
mit
mcci-catena/arduino-lmic,mcci-catena/arduino-lmic,mcci-catena/arduino-lmic
3efdee2c137bfa5a8b937fea6616fd3c57eede6a
src/kvazaar_internal.h
src/kvazaar_internal.h
#ifndef KVAZAAR_INTERNAL_H_ #define KVAZAAR_INTERNAL_H_ /***************************************************************************** * This file is part of Kvazaar HEVC encoder. * * Copyright (C) 2013-2015 Tampere University of Technology and others (see * COPYING file). * * Kvazaar is free software: you can redistri...
#ifndef KVAZAAR_INTERNAL_H_ #define KVAZAAR_INTERNAL_H_ /***************************************************************************** * This file is part of Kvazaar HEVC encoder. * * Copyright (C) 2013-2015 Tampere University of Technology and others (see * COPYING file). * * Kvazaar is free software: you can redistri...
Fix compilation warnings when using clang.
Fix compilation warnings when using clang. Removes typedef redefinitions in kvazaar_internal.h.
C
bsd-3-clause
lu-zero/kvazaar,ultravideo/kvazaar,ultravideo/kvazaar,lu-zero/kvazaar,lu-zero/kvazaar,ultravideo/kvazaar,ultravideo/kvazaar,ultravideo/kvazaar,lu-zero/kvazaar
a5bc4fdc171021daeb92d5d4a6fcf45ed3cad3e6
Amethyst/AMShortcutsPreferencesViewController.h
Amethyst/AMShortcutsPreferencesViewController.h
// // AMShortcutsPreferencesViewController.h // Amethyst // // Created by Ian Ynda-Hummel on 4/26/14. // Copyright (c) 2014 Ian Ynda-Hummel. All rights reserved. // #import <Cocoa/Cocoa.h> #import <MASPreferences/MASPreferencesViewController.h> @interface AMShortcutsPreferencesViewController : NSViewController @...
// // AMShortcutsPreferencesViewController.h // Amethyst // // Created by Ian Ynda-Hummel on 4/26/14. // Copyright (c) 2014 Ian Ynda-Hummel. All rights reserved. // #import <Cocoa/Cocoa.h> @interface AMShortcutsPreferencesViewController : NSViewController @end
Remove import from previously-removed MASPreferences
Remove import from previously-removed MASPreferences
C
mit
ianyh/Amethyst,ianyh/Amethyst,ianyh/Amethyst,ianyh/Amethyst,ianyh/Amethyst
1c1fe4b476e004017fdfc633ab60b17146f1db80
stack.h
stack.h
#include <stdlib.h> #ifndef __STACK_H__ #define __STACK_H__ struct Stack; typedef struct Stack Stack; #endif
#include <stdlib.h> #ifndef __STACK_H__ #define __STACK_H__ struct Stack; typedef struct Stack Stack; void Push(Stack s, void* e); void* Pop(Stack s); int Stack_Empty(Stack s); #endif
Add basic operation function declaration
Add basic operation function declaration
C
mit
MaxLikelihood/CADT
0fee9081555e6b8a104aa857a29df14712c5fd43
ext/opengl/gl-ext-3dfx.c
ext/opengl/gl-ext-3dfx.c
/* * Copyright (C) 2007 Jan Dvorak <jan.dvorak@kraxnet.cz> * * This program is distributed under the terms of the MIT license. * See the included MIT-LICENSE file for the terms of this license. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS * OR IMPLIED, INCLUDING BUT NOT LIMITED TO ...
/* * Copyright (C) 2007 Jan Dvorak <jan.dvorak@kraxnet.cz> * * This program is distributed under the terms of the MIT license. * See the included MIT-LICENSE file for the terms of this license. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS * OR IMPLIED, INCLUDING BUT NOT LIMITED TO ...
Change remaining glTbufferMask3DFX to an instance method.
Change remaining glTbufferMask3DFX to an instance method.
C
mit
larskanis/opengl,larskanis/opengl
815d5c9e041319cbd9660aca9097bfa9c7c257eb
prime.c
prime.c
#include <stdio.h> #include <stdlib.h> #include <math.h> int isPrime(unsigned long x) { if (sqrt(x) - (unsigned long)sqrt(x) == 0) return 0; for (unsigned long i = 2; i < ceil(sqrt(x)); i++) if (x % i == 0) return 0; return 1; } int main( int argc, char** argv) { unsigned l...
#include <stdio.h> #include <stdlib.h> #include <math.h> int isPrime(unsigned int x) { if (sqrt(x) - (unsigned int)sqrt(x) == 0) return 0; for (unsigned int i = 2; i < ceil(sqrt(x)); i++) if (x % i == 0) return 0; return 1; } int main( int argc, char** argv) { unsigned int ...
Replace long with int in the C version to improve performance.
Replace long with int in the C version to improve performance.
C
bsd-3-clause
noamknispel/ThePrimeBenchMark,noamknispel/ThePrimeBenchMark,noamknispel/ThePrimeBenchMark,noamknispel/ThePrimeBenchMark,noamknispel/ThePrimeBenchMark
47452ae7c92e4fb03416e1a870a0d586d761f5fa
Utilities/kwsys/testDynload.c
Utilities/kwsys/testDynload.c
#ifdef _WIN32 #define DL_EXPORT __declspec( dllexport ) #else #define DL_EXPORT #endif DL_EXPORT int TestDynamicLoaderData; DL_EXPORT void TestDynamicLoaderFunction() { }
#ifdef _WIN32 #define DL_EXPORT __declspec( dllexport ) #else #define DL_EXPORT #endif DL_EXPORT int TestDynamicLoaderData = 0; DL_EXPORT void TestDynamicLoaderFunction() { }
Fix compilation on MacOSX (common symbols not allowed with MH_DYLIB output format)
COMP: Fix compilation on MacOSX (common symbols not allowed with MH_DYLIB output format)
C
apache-2.0
eile/ITK,fbudin69500/ITK,wkjeong/ITK,fuentesdt/InsightToolkit-dev,fedral/ITK,stnava/ITK,Kitware/ITK,atsnyder/ITK,CapeDrew/DITK,blowekamp/ITK,InsightSoftwareConsortium/ITK,itkvideo/ITK,eile/ITK,stnava/ITK,LucasGandel/ITK,fedral/ITK,Kitware/ITK,stnava/ITK,itkvideo/ITK,InsightSoftwareConsortium/ITK,daviddoria/itkHoughTran...
614c7ace15046fd016ddcb28f61cb6cf6b30cc05
test/Preprocessor/has_c_attribute.c
test/Preprocessor/has_c_attribute.c
// RUN: %clang_cc1 -fdouble-square-bracket-attributes -std=c11 -E %s -o - | FileCheck %s // CHECK: has_fallthrough #if __has_c_attribute(fallthrough) int has_fallthrough(); #endif // CHECK: does_not_have_selectany #if !__has_c_attribute(selectany) int does_not_have_selectany(); #endif
// RUN: %clang_cc1 -fdouble-square-bracket-attributes -std=c11 -E %s -o - | FileCheck %s // CHECK: has_fallthrough #if __has_c_attribute(fallthrough) int has_fallthrough(); #endif // CHECK: does_not_have_selectany #if !__has_c_attribute(selectany) int does_not_have_selectany(); #endif
Correct line endings that got mixed up in r320088; NFC.
Correct line endings that got mixed up in r320088; NFC. git-svn-id: ffe668792ed300d6c2daa1f6eba2e0aa28d7ec6c@320115 91177308-0d34-0410-b5e6-96231b3b80d8
C
apache-2.0
llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,llvm-mirror/clang,apple/swift-clang,llvm-mirror/clang,apple/swift-clang,apple/swift-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-cl...
9b3814de8a8cbe6fda99174955f7878a5e6189bf
tests/src/test_run.c
tests/src/test_run.c
#include <stdio.h> #include <stdlib.h> #include "rxvm.h" #include "test_common.h" #include "test_modules.h" #define NUM_MODS 7 const testmod_t mods[NUM_MODS] = { test_rxvm_err, test_rxvm_match, test_rxvm_search, test_rxvm_search_nomatch, test_rxvm_compile, test_fuzz_rxvm_match, test_fuzz_full_rxv...
#include <stdio.h> #include <stdlib.h> #include "rxvm.h" #include "test_common.h" #include "test_modules.h" //#define NUM_MODS 7 #define NUM_MODS 6 const testmod_t mods[NUM_MODS] = { test_rxvm_err, test_rxvm_match, test_rxvm_search, test_rxvm_search_nomatch, test_rxvm_compile, test_fuzz_rxvm...
Disable fuzz_full test until fixed
Disable fuzz_full test until fixed
C
apache-2.0
eriknyquist/librxvm,eriknyquist/librxvm,eriknyquist/librxvm
3b6f6fefaa1f13cde4d9530a51e655059f5b15ab
texor.c
texor.c
#include <termios.h> #include <unistd.h> void enableRawMode() { struct termios raw; tcgetattr(STDIN_FILENO, &raw); raw.c_lflag &= ~(ECHO); tcsetattr(STDIN_FILENO, TCSAFLUSH, &raw); } int main() { enableRawMode(); char c; while (read(STDIN_FILENO, &c, 1) == 1 && c!= 'q'); return 0; }
#include <stdlib.h> #include <termios.h> #include <unistd.h> struct termios orig_termios; void disableRawMode() { tcsetattr(STDIN_FILENO, TCSAFLUSH, &orig_termios); } void enableRawMode() { tcgetattr(STDIN_FILENO, &orig_termios); atexit(disableRawMode); struct termios raw = orig_termios; raw.c_lflag &= ~(...
Disable raw mode when exiting
Disable raw mode when exiting
C
bsd-2-clause
kyletolle/texor
15eb88a039cda665d151f6daa280c2ad439c2c84
BBlock.h
BBlock.h
// // BBlock.h // BBlock // // Created by David Keegan on 4/10/12. // Copyright (c) 2012 David Keegan. All rights reserved. // #import <Foundation/Foundation.h> /// For when you need a weak reference of an object, example: `BBlockWeakObject(obj) wobj = obj;` #define BBlockWeakObject(o) __weak typeof(o) /// For w...
// // BBlock.h // BBlock // // Created by David Keegan on 4/10/12. // Copyright (c) 2012 David Keegan. All rights reserved. // #import <Foundation/Foundation.h> /// For when you need a weak reference of an object, example: `BBlockWeakObject(obj) wobj = obj;` #define BBlockWeakObject(o) __weak __typeof__((__typeof...
Revert "with Xcode4.4 __weak typeof(o) is all that's needed for weak references"
Revert "with Xcode4.4 __weak typeof(o) is all that's needed for weak references" This reverts commit 7689903fd592848310bf12743dcec7805cd37098.
C
mit
kgn/BBlock,cnbin/BBlock,azplanlos/BBlock
2c454a161bc6f8cbe364c5dc040cf140299b4087
src/crt/crt1.c
src/crt/crt1.c
#include <stdint.h> void __wasm_call_ctors(void); int __argc(void); void __argv(uintptr_t[static 1]); void __args(char[static 1]); int main(int, char**); void _start(void) { int argc = __argc(); char* argv[argc + 1]; __argv((uintptr_t*)argv); char args[(uintptr_t)argv[argc]]; __args(args); ...
#include <stdint.h> void __wasm_call_ctors(void); /*! * `argc` getter * * This function returns 0 if passing arguments to main() is unsupported. */ int __argc(void); /*! * `argv` builder * * This function stores `argv` as offset from `argv[0]`, * and appends `sizeof(args)`. * * For example, if the command ...
Document on getters of argc and argv
Document on getters of argc and argv
C
mit
jdh8/metallic,jdh8/metallic,jdh8/metallic,jdh8/metallic,jdh8/metallic
af6936815f344cab1cd0549172582dfa40dcd46e
infiniteloop_cmd.c
infiniteloop_cmd.c
// Copyright (c) 2016 Ed Schouten <ed@nuxi.nl> // // This file is distributed under a 2-clause BSD license. // See the LICENSE file for details. #include <stdbool.h> #include <stdio.h> #include <stdlib.h> #include "infiniteloop.h" static bool print_solution(const struct il_solution *s, void *thunk) { char buf[1024...
// Copyright (c) 2016 Ed Schouten <ed@nuxi.nl> // // This file is distributed under a 2-clause BSD license. // See the LICENSE file for details. #include <stdbool.h> #include <stdio.h> #include <stdlib.h> #include "infiniteloop.h" static unsigned int solutions_found = 0; static bool print_solution(const struct il_s...
Print the number of solutions.
Print the number of solutions.
C
bsd-2-clause
EdSchouten/infiniteloop,EdSchouten/infiniteloop
e8b78e79fe13f170083ba89b48b1c18bd3c93543
Mac/Python/macguesstabsize.c
Mac/Python/macguesstabsize.c
#include <MacHeaders> #include <string.h> /* Interface used by tokenizer.c */ guesstabsize(path) char *path; { char s[256]; int refnum; Handle h; int tabsize = 0; s[0] = strlen(path); strncpy(s+1, path, s[0]); refnum = OpenResFile(s); /* printf("%s --> refnum=%d\n", path, refnum); */ if (refnum == -1) retu...
#include <Types.h> #include <Files.h> #include <OSUtils.h> #include <Resources.h> #include <string.h> /* Interface used by tokenizer.c */ guesstabsize(path) char *path; { char s[256]; int refnum; Handle h; int tabsize = 0; s[0] = strlen(path); strncpy(s+1, path, s[0]); refnum = OpenResFile(s); /* printf("%s ...
Replace <MacHeaders> by specific required header files
Replace <MacHeaders> by specific required header files
C
mit
sk-/python2.7-type-annotator,sk-/python2.7-type-annotator,sk-/python2.7-type-annotator
16a70daa90a743729ece6bb7ecd971a55ebe4731
link-grammar/lg_assert.h
link-grammar/lg_assert.h
/* There is no include guard here - by purpose. This file can be included * after system includes that redefine the assert() macro. * The actual problem for which this file got separated from utilities.h * happens in the sat-solver code, when local include files include * Solver.h which in turn includes the system'...
/* There is no include guard here - by purpose. This file can be included * after system includes that redefine the assert() macro. * The actual problem for which this file got separated from utilities.h * happens in the sat-solver code, when local include files include * Solver.h which in turn includes the system'...
Use fprintf() to ensure message printing
assert(): Use fprintf() to ensure message printing If prt_error() is used and the error facility uses a non-default error handler, the message will get lost.
C
lgpl-2.1
ampli/link-grammar,opencog/link-grammar,linas/link-grammar,linas/link-grammar,opencog/link-grammar,opencog/link-grammar,linas/link-grammar,opencog/link-grammar,opencog/link-grammar,ampli/link-grammar,linas/link-grammar,ampli/link-grammar,opencog/link-grammar,ampli/link-grammar,opencog/link-grammar,opencog/link-grammar,...
d58d382cd1d01bc048c8bb74b184d182b36a5cfb
Application/voRemoteAnalysisConnectionDialog.h
Application/voRemoteAnalysisConnectionDialog.h
/*========================================================================= Program: Visomics Copyright (c) Kitware, Inc. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://ww...
/*========================================================================= Program: Visomics Copyright (c) Kitware, Inc. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://ww...
Fix copy/paste error in header guard
Fix copy/paste error in header guard
C
apache-2.0
Visomics/Visomics,arborworkflows/Visomics,Visomics/Visomics,Visomics/Visomics,arborworkflows/Visomics,Visomics/Visomics,Visomics/Visomics,arborworkflows/Visomics,Visomics/Visomics,arborworkflows/Visomics,arborworkflows/Visomics,arborworkflows/Visomics
947470b6ae897dd4a340944206c80e39c5e20cc9
browser/atom_browser_main_parts.h
browser/atom_browser_main_parts.h
// Copyright (c) 2013 GitHub, Inc. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #ifndef ATOM_BROWSER_ATOM_BROWSER_MAIN_PARTS_ #define ATOM_BROWSER_ATOM_BROWSER_MAIN_PARTS_ #include "brightray/browser/browser_main_parts.h" namespace atom ...
// Copyright (c) 2013 GitHub, Inc. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #ifndef ATOM_BROWSER_ATOM_BROWSER_MAIN_PARTS_ #define ATOM_BROWSER_ATOM_BROWSER_MAIN_PARTS_ #include "brightray/browser/browser_main_parts.h" namespace atom ...
Mark OS X only implementations in BrowserMainParts.
Mark OS X only implementations in BrowserMainParts.
C
mit
Jacobichou/electron,michaelchiche/electron,fritx/electron,chrisswk/electron,twolfson/electron,eriser/electron,Jacobichou/electron,John-Lin/electron,gabriel/electron,simonfork/electron,d-salas/electron,aliib/electron,GoooIce/electron,adamjgray/electron,JesselJohn/electron,Faiz7412/electron,ervinb/electron,Floato/electro...
39e3614c7136029acb6b18cd71e12ef2feaeaac7
ui/minigraph.h
ui/minigraph.h
#pragma once #include <QtGui/QMouseEvent> #include <QtGui/QPaintEvent> #include <QtWidgets/QWidget> #include "binaryninjaapi.h" #include "dockhandler.h" #include "uitypes.h" class ContextMenuManager; class DisassemblyView; class Menu; class ViewFrame; class BINARYNINJAUIAPI MiniGraph: public QWidget, public DockCon...
#pragma once #include <QtGui/QMouseEvent> #include <QtGui/QPaintEvent> #include <QtWidgets/QWidget> #include "binaryninjaapi.h" #include "dockhandler.h" #include "uitypes.h" class ContextMenuManager; class FlowGraphWidget; class Menu; class ViewFrame; class BINARYNINJAUIAPI MiniGraph: public QWidget, public DockCon...
Update MiniGraph to work with FlowGraphWidet.
Update MiniGraph to work with FlowGraphWidet.
C
mit
Vector35/binaryninja-api,Vector35/binaryninja-api,Vector35/binaryninja-api,joshwatson/binaryninja-api,Vector35/binaryninja-api,joshwatson/binaryninja-api,Vector35/binaryninja-api,Vector35/binaryninja-api,joshwatson/binaryninja-api,joshwatson/binaryninja-api,Vector35/binaryninja-api,joshwatson/binaryninja-api
2b37c13dcf9f8460bf86c4b9096dcc49aed72a44
src/lib/utils/rotate.h
src/lib/utils/rotate.h
/* * Word Rotation Operations * (C) 1999-2008 Jack Lloyd * * Botan is released under the Simplified BSD License (see license.txt) */ #ifndef BOTAN_WORD_ROTATE_H__ #define BOTAN_WORD_ROTATE_H__ #include <botan/types.h> namespace Botan { /** * Bit rotation left * @param input the input word * @param rot the number of...
/* * Word Rotation Operations * (C) 1999-2008 Jack Lloyd * * Botan is released under the Simplified BSD License (see license.txt) */ #ifndef BOTAN_WORD_ROTATE_H__ #define BOTAN_WORD_ROTATE_H__ #include <botan/types.h> namespace Botan { /** * Bit rotation left * @param input the input word * @param rot the number of...
Allow bit rotation by more than sizeof(T)*8 bits.
Allow bit rotation by more than sizeof(T)*8 bits. Currently these functions will happily bit shift by >= sizeof(T)*8 bits. However, this is undefined behavior, and results in unexpected results (0) on at least one platform I've tested. With this update, you can expect that rotate_left<uint32_t>(1, 32)==1 and rotate_r...
C
bsd-2-clause
randombit/botan,webmaster128/botan,webmaster128/botan,randombit/botan,Rohde-Schwarz-Cybersecurity/botan,randombit/botan,Rohde-Schwarz-Cybersecurity/botan,Rohde-Schwarz-Cybersecurity/botan,webmaster128/botan,Rohde-Schwarz-Cybersecurity/botan,Rohde-Schwarz-Cybersecurity/botan,randombit/botan,webmaster128/botan,Rohde-Schw...
5fffb9f49cd7b1237a0bfed0faebf16ef5cdeec1
lib/sanitizer_common/sanitizer_platform_interceptors.h
lib/sanitizer_common/sanitizer_platform_interceptors.h
//===-- sanitizer_platform_interceptors.h -----------------------*- C++ -*-===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===-------------------------------------------------------...
//===-- sanitizer_platform_interceptors.h -----------------------*- C++ -*-===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===-------------------------------------------------------...
Disable scanf interceptor on windows.
[sanitizer] Disable scanf interceptor on windows. git-svn-id: c199f293c43da69278bea8e88f92242bf3aa95f7@173037 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
9acecbbff3b0eca30b2a0f0767dad196b93d1225
3RVX/Settings.h
3RVX/Settings.h
#pragma once #include <unordered_map> #include <string> #include "TinyXml2\tinyxml2.h" class Skin; #define SETTINGS_APP L"SettingsUI.exe" class Settings { public: static Settings *Instance(); static std::wstring AppDir(); static std::wstring SettingsApp(); std::wstring LanguagesDir(); std::ws...
#pragma once #include <unordered_map> #include <string> #include "TinyXml2\tinyxml2.h" class Skin; #define SETTINGS_APP L"SettingsUI.exe" class Settings { public: static Settings *Instance(); void Reload(); static std::wstring AppDir(); static std::wstring SettingsApp(); std::wstring Language...
Reorganize and reduce visibility for raw XML access methods
Reorganize and reduce visibility for raw XML access methods These should be performed by public methods that abstract away the XML elements
C
bsd-2-clause
malensek/3RVX,Soulflare3/3RVX,Soulflare3/3RVX,Soulflare3/3RVX,malensek/3RVX,malensek/3RVX
74ce9a97e81b913f26f0353dc0d3e988af99cb5c
uranus_dp/include/uranus_dp/eigen_helper.h
uranus_dp/include/uranus_dp/eigen_helper.h
#ifndef EIGEN_HELPER_H #define EIGEN_HELPER_H #include <Eigen/Dense> template<typename Derived> inline bool isFucked(const Eigen::MatrixBase<Derived>& x) { return !((x.array() == x.array())).all() && !( (x - x).array() == (x - x).array()).all(); } #endif
#ifndef EIGEN_HELPER_H #define EIGEN_HELPER_H #include "ros/ros.h" #include <Eigen/Dense> template<typename Derived> inline bool isFucked(const Eigen::MatrixBase<Derived>& x) { return !((x.array() == x.array())).all() && !( (x - x).array() == (x - x).array()).all(); } inline Eigen::MatrixXd getMatrixParam(ros::Nod...
Move more stuff to eigen helper header
Move more stuff to eigen helper header
C
mit
vortexntnu/rov-control,vortexntnu/rov-control,vortexntnu/rov-control
3881c6907e3a18dca7878e06ef915e64021156b0
test/Analysis/taint-generic.c
test/Analysis/taint-generic.c
// RUN: %clang_cc1 -analyze -analyzer-checker=experimental.security.taint,experimental.security.ArrayBoundV2 -verify %s int scanf(const char *restrict format, ...); int getchar(void); #define BUFSIZE 10 int Buffer[BUFSIZE]; void bufferFoo1(void) { int n; scanf("%d", &n); Buffer[n] = 1; // expected-warning {{O...
// RUN: %clang_cc1 -analyze -analyzer-checker=experimental.security.taint,experimental.security.ArrayBoundV2 -verify %s int scanf(const char *restrict format, ...); int getchar(void); #define BUFSIZE 10 int Buffer[BUFSIZE]; void bufferScanfDirect(void) { int n; scanf("%d", &n); Buffer[n] = 1; // expected-warn...
Add more simple taint tests.
[analyzer] Add more simple taint tests. git-svn-id: ffe668792ed300d6c2daa1f6eba2e0aa28d7ec6c@145275 91177308-0d34-0410-b5e6-96231b3b80d8
C
apache-2.0
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,apple/swift-clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,llvm-mirror/clang,apple/swift-clang,llvm-mirror/clang,apple/swift-cl...