Instruction
stringlengths
14
778
input_code
stringlengths
0
4.24k
output_code
stringlengths
1
5.44k
Add missing file for ARCH = AVR.
/* * RELIC is an Efficient LIbrary for Cryptography * Copyright (C) 2007-2011 RELIC Authors * * This file is part of RELIC. RELIC is legal property of its developers, * whose names are not listed here. Please refer to the COPYRIGHT file * for contact information. * * RELIC is free software; you can redistribute...
Improve throwsException example to use hasProperty
// OCHamcrest by Jon Reid, http://qualitycoding.org/about/ // Copyright 2015 hamcrest.org. See LICENSE.txt #import <OCHamcrest/HCDiagnosingMatcher.h> /*! * @abstract Does executing a block throw an exception which satisfies a nested matcher? */ @interface HCThrowsException : HCDiagnosingMatcher - (id)initWithEx...
// OCHamcrest by Jon Reid, http://qualitycoding.org/about/ // Copyright 2015 hamcrest.org. See LICENSE.txt #import <OCHamcrest/HCDiagnosingMatcher.h> /*! * @abstract Does executing a block throw an exception which satisfies a nested matcher? */ @interface HCThrowsException : HCDiagnosingMatcher - (id)initWithEx...
Hide VDP1 even if FB hasn't been erased and changed
/* * Copyright (c) 2012-2016 Israel Jacquez * See LICENSE for details. * * Israel Jacquez <mrkotfw@gmail.com> */ #include <stdlib.h> #include <vdp1.h> #include <vdp2.h> #include <vdp2/tvmd.h> #include <vdp2/vram.h> #include <cons.h> void __noreturn internal_exception_show(const char *buffer) { /* Reset...
/* * Copyright (c) 2012-2016 Israel Jacquez * See LICENSE for details. * * Israel Jacquez <mrkotfw@gmail.com> */ #include <stdlib.h> #include <vdp1.h> #include <vdp2.h> #include <vdp2/tvmd.h> #include <vdp2/vram.h> #include <cons.h> void __noreturn internal_exception_show(const char *buffer) { /* Reset...
Add some spaces and enters
/** Author : Paul TREHIOU & Victor SENE * Date : November 2014 **/ /** * Declaration Point structure * x - real wich is the abscisse of the point * y - real wich is the ordinate of the point */ typedef struct { float x; float y; }Point; /** * Function wich create a point with a specified abscisse and...
/** Author : Paul TREHIOU & Victor SENE * Date : November 2014 **/ /** * Declaration Point structure * x - real wich is the abscisse of the point * y - real wich is the ordinate of the point */ typedef struct { float x; float y; }Point; /** * Function wich create a point with a specified abscisse and ...
Make test a bit more precise.
// RUN: clang-cc -emit-llvm %s -o - | not grep ptrtoint // Make sure we generate something sane instead of a ptrtoint union x {long long b;union x* a;} r = {.a = &r};
// RUN: clang-cc -emit-llvm %s -o - -triple i686-pc-linux-gnu | grep "bitcast (%0\* @r to %union.x\*), \[4 x i8\] zeroinitializer" // Make sure we generate something sane instead of a ptrtoint union x {long long b;union x* a;} r = {.a = &r};
Add BST find min and max value node
#include <stdio.h> #include <stdlib.h> /* This is a code for binary search tree basic implementtion */ //Contains code for PreOrder, InOrder and PostOrder Traversals i.e. Depth First typedef struct node{ int data; struct node* left; struct node* right; } node; node* head; node* create(int data){ node* temp = (...
Remove some diff file flags
// // GTDiffFile.h // ObjectiveGitFramework // // Created by Danny Greg on 30/11/2012. // Copyright (c) 2012 GitHub, Inc. All rights reserved. // #import "git2.h" // Flags which may be set on the file. // // See diff.h for individual documentation. typedef enum : git_diff_file_flag_t { GTDiffFileFlagValidOID = G...
// // GTDiffFile.h // ObjectiveGitFramework // // Created by Danny Greg on 30/11/2012. // Copyright (c) 2012 GitHub, Inc. All rights reserved. // #import "git2.h" // Flags which may be set on the file. // // See diff.h for individual documentation. typedef enum : git_diff_flag_t { GTDiffFileFlagValidOID = GIT_DI...
Add EventSystem shim missed in r588.
#ifndef EVENT_SYSTEM_H #define EVENT_SYSTEM_H #include <event/event_thread.h> /* * XXX * This is kind of an awful shim while we move * towards something thread-oriented. */ class EventSystem { EventThread td_; private: EventSystem(void) : td_() { } ~EventSystem() { } public: Action *poll(const EventPoll...
Add move-only type for testing/benchmarking.
/* * The MIT License (MIT) * * Copyright (c) 2015 Morwenn * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * in the Software without restriction, including without limitation the rights * to use, copy...
Add copy-pasted stub for future RequestContext
// Copyright (c) 2015 Yandex LLC. All rights reserved. // Author: Vasily Chekalkin <bacek@yandex-team.ru> #ifndef SDCH_REQUEST_CONTEXT_H_ #define SDCH_REQUEST_CONTEXT_H_ extern "C" { #include <ngx_config.h> #include <nginx.h> #include <ngx_core.h> #include <ngx_http.h> } namespace sdch { class Handler; // Contex...
Add ppc_function_entry() which gets the entry point for a function
#ifndef _ASM_POWERPC_CODE_PATCHING_H #define _ASM_POWERPC_CODE_PATCHING_H /* * Copyright 2008, Michael Ellerman, IBM Corporation. * * 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 v...
#ifndef _ASM_POWERPC_CODE_PATCHING_H #define _ASM_POWERPC_CODE_PATCHING_H /* * Copyright 2008, Michael Ellerman, IBM Corporation. * * 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 v...
Add POSIX files, yay. Almost fixes compile
/** * \file socket.c - Windows Socket Abstractions * * Copyright (c) 2015 Michael Casadevall * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * in the Software without restriction, including without limitatio...
Allow intrusive pointers to const objects.
#include "ug_thread_safe_counter.h" #pragma once // obsolete once intrusive_ref_counter is available everywhere namespace Moses { class reference_counter { public: friend void intrusive_ptr_add_ref(reference_counter* p) { if (p) ++p->m_refcount; } friend void intrusive_ptr_release(referenc...
#include "ug_thread_safe_counter.h" #pragma once // obsolete once intrusive_ref_counter is available everywhere namespace Moses { class reference_counter { public: friend void intrusive_ptr_add_ref(reference_counter const* p) { if (p) ++p->m_refcount; } friend void intrusive_ptr_release(re...
Rename test suite version of debug to match the header.
#include "log.h" #include <stdio.h> #include <stdarg.h> void debug(const char* format, ...) { #ifdef __DEBUG__ va_list args; va_start(args, format); vprintf(format, args); va_end(args); #endif // __DEBUG__ } void initializeLogging() { }
#include "log.h" #include <stdio.h> #include <stdarg.h> void debugNoNewline(const char* format, ...) { #ifdef __DEBUG__ va_list args; va_start(args, format); vprintf(format, args); va_end(args); #endif // __DEBUG__ } void initializeLogging() { }
Add MEMCPY and MEMCPY_N macros
#ifndef UTIL_H #define UTIL_H /*** Utility functions ***/ #define ALLOC(type) ALLOC_N(type, 1) #define ALLOC_N(type, n) ((type*) xmalloc(sizeof(type) * (n))) void *xmalloc(size_t); char *hextoa(const char *, int); #define STARTS_WITH(x, y) (strncmp((x), (y), strlen(y)) == 0) #endif /* UTIL_H */
#ifndef UTIL_H #define UTIL_H /*** Utility functions ***/ #define ALLOC(type) ALLOC_N(type, 1) #define ALLOC_N(type, n) ((type*) xmalloc(sizeof(type) * (n))) #define MEMCPY(dst, src, type) MEMCPY_N(dst, src, type, 1) #define MEMCPY_N(dst, src, type, n) (memcpy((dst), (src), sizeof(type) * (n))) void *xmalloc(size_t);...
Revert "powerpc/mm: Bump SECTION_SIZE_BITS from 16MB to 256MB"
#ifndef _ASM_POWERPC_SPARSEMEM_H #define _ASM_POWERPC_SPARSEMEM_H 1 #ifdef __KERNEL__ #ifdef CONFIG_SPARSEMEM /* * SECTION_SIZE_BITS 2^N: how big each section will be * MAX_PHYSADDR_BITS 2^N: how much physical address space we have * MAX_PHYSMEM_BITS 2^N: how much memory we can have in that space */ #define SEC...
#ifndef _ASM_POWERPC_SPARSEMEM_H #define _ASM_POWERPC_SPARSEMEM_H 1 #ifdef __KERNEL__ #ifdef CONFIG_SPARSEMEM /* * SECTION_SIZE_BITS 2^N: how big each section will be * MAX_PHYSADDR_BITS 2^N: how much physical address space we have * MAX_PHYSMEM_BITS 2^N: how much memory we can have in that space */ #define SEC...
Add compatibility header and use compatibility macros to enable builds on both R13 and R14.
#ifndef ERL_NIF_COMPAT_H_ #define ERL_NIF_COMPAT_H_ #ifdef __cplusplus extern "C" { #endif /* __cplusplus */ #include "erl_nif.h" #if ERL_NIF_MAJOR_VERSION == 1 && ERL_NIF_MINOR_VERSION == 0 #define enif_open_resource_type_compat enif_open_resource_type #define enif_alloc_resource_compat enif_alloc_resource #define...
Update relative path of includes
#ifndef GAMEMODEWIDGET_H #define GAMEMODEWIDGET_H #include <QtWidgets> #include "PlayerActivatedWidget.h" #include "PlayerControlModeWidget.h" #include "Game\Player.h" #include "Game\State.h" class GameModeWidget : public QWidget { public: GameModeWidget(QWidget * parent = 0); ~GameModeWidget(); Player currentP...
#ifndef GAMEMODEWIDGET_H #define GAMEMODEWIDGET_H #include <QtWidgets> #include "PlayerActivatedWidget.h" #include "PlayerControlModeWidget.h" #include "Game/Player.h" #include "Game/State.h" class GameModeWidget : public QWidget { public: GameModeWidget(QWidget * parent = 0); ~GameModeWidget(); Player currentP...
Add the h2o/httparser.h forgotten on previous commit
/* * Copyright (c) 2016 Domingo Alvarez Duarte * * The software is licensed under either the MIT License (below) or the Perl * license. * * 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 Softwa...
Add VIEWS_EXPORT to autoscroll constants.
// Copyright (c) 2011 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #ifndef VIEWS_VIEW_CONSTANTS_H_ #define VIEWS_VIEW_CONSTANTS_H_ #pragma once #include "views/views_export.h" namespace views { // Size (width or he...
// Copyright (c) 2011 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #ifndef VIEWS_VIEW_CONSTANTS_H_ #define VIEWS_VIEW_CONSTANTS_H_ #pragma once #include "views/views_export.h" namespace views { // Size (width or he...
Make US100 sensor get distance successfully.
/*==============================================================================================*/ /*==============================================================================================*/ #include "QuadCopterConfig.h" Ultrasonic_t Ultrasonic = { .lenHigh = 0, .lenLow = 0, .d = 0 }; /*====================...
/*==============================================================================================*/ /*==============================================================================================*/ #include "QuadCopterConfig.h" /* Connection methods of Ultrasonic */ #define ULT_USE_UART2 1 #define ULT_USE_PWM 0 Ultr...
Change date of copyright notice
#ifndef MAP_PUT_INDIVIDUAL_CONTEXT_ENTITY_ATTRIBUTE_H #define MAP_PUT_INDIVIDUAL_CONTEXT_ENTITY_ATTRIBUTE_H /* * * Copyright 2013 Telefonica Investigacion y Desarrollo, S.A.U * * This file is part of Orion Context Broker. * * Orion Context Broker is free software: you can redistribute it and/or * modify it under the t...
#ifndef MAP_PUT_INDIVIDUAL_CONTEXT_ENTITY_ATTRIBUTE_H #define MAP_PUT_INDIVIDUAL_CONTEXT_ENTITY_ATTRIBUTE_H /* * * Copyright 2014 Telefonica Investigacion y Desarrollo, S.A.U * * This file is part of Orion Context Broker. * * Orion Context Broker is free software: you can redistribute it and/or * modify it under the t...
Enable debug helpers only on debug builds.
#ifndef INLINE_DEBUG_HELPER_H #define INLINE_DEBUG_HELPER_H #include "pipe/p_compiler.h" #include "util/u_debug.h" /* Helper function to wrap a screen with * one or more debug driver: rbug, trace. */ #ifdef GALLIUM_TRACE #include "trace/tr_public.h" #endif #ifdef GALLIUM_RBUG #include "rbug/rbug_public.h" #endi...
#ifndef INLINE_DEBUG_HELPER_H #define INLINE_DEBUG_HELPER_H #include "pipe/p_compiler.h" #include "util/u_debug.h" /* Helper function to wrap a screen with * one or more debug driver: rbug, trace. */ #ifdef DEBUG #ifdef GALLIUM_TRACE #include "trace/tr_public.h" #endif #ifdef GALLIUM_RBUG #include "rbug/rbug_p...
Use : as separator between "GM" and slide name in SampleApp. This makes it easier to jump to a GM slide using command line args on windows.
/* * Copyright 2011 Google Inc. * * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ #ifndef GMSampleView_DEFINED #define GMSampleView_DEFINED #include "SampleCode.h" #include "gm.h" class GMSampleView : public SampleView { private: typedef skiagm::GM ...
/* * Copyright 2011 Google Inc. * * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ #ifndef GMSampleView_DEFINED #define GMSampleView_DEFINED #include "SampleCode.h" #include "gm.h" class GMSampleView : public SampleView { private: typedef skiagm::GM ...
Set default value of StaticMeshComponent::mesh to nullptr
#pragma once #include "pathos/actor/scene_component.h" #include "badger/types/matrix_types.h" namespace pathos { class Mesh; class MeshGeometry; class Material; // #todo-renderer: Further decompose struct StaticMeshProxy : public SceneComponentProxy { uint32 doubleSided : 1; uint32 renderInternal : 1; ma...
#pragma once #include "pathos/actor/scene_component.h" #include "badger/types/matrix_types.h" namespace pathos { class Mesh; class MeshGeometry; class Material; // #todo-renderer: Further decompose struct StaticMeshProxy : public SceneComponentProxy { uint32 doubleSided : 1; uint32 renderInternal : 1; ma...
Update code for generated asm analysis
/* * Copyright (c) 2017-2022, Patrick Pelissier * All rights reserved. * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * + Redistributions of source code must retain the above copyright * notice, this list of cond...
/* * Copyright (c) 2017-2022, Patrick Pelissier * All rights reserved. * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * + Redistributions of source code must retain the above copyright * notice, this list of cond...
Comment improvement: explain consequences of using ZLocationCell
// // ZDetailKit.h // // Created by Lukas Zeller on 15.02.13. // Copyright (c) 2013 plan44.ch. All rights reserved. // // common #import "ZDetailEditing.h" #import "ZDBGMacros.h" // ZUtils #import "ZCustomI8n.h" // controllers #import "ZDetailTableViewController.h" // cells #import "ZButtonCell.h" #import "ZSwi...
// // ZDetailKit.h // // Created by Lukas Zeller on 15.02.13. // Copyright (c) 2013 plan44.ch. All rights reserved. // // common #import "ZDetailEditing.h" #import "ZDBGMacros.h" // ZUtils #import "ZCustomI8n.h" // controllers #import "ZDetailTableViewController.h" // cells #import "ZButtonCell.h" #import "ZSwi...
Add example of how to select Japan country
// project-specific definitions for otaa sensor //#define CFG_eu868 1 #define CFG_us915 1 //#define CFG_au921 1 //#define CFG_as923 1 //#define CFG_in866 1 #define CFG_sx1276_radio 1 //#define LMIC_USE_INTERRUPTS
// project-specific definitions //#define CFG_eu868 1 #define CFG_us915 1 //#define CFG_au921 1 //#define CFG_as923 1 // #define LMIC_COUNTRY_CODE LMIC_COUNTRY_CODE_JP /* for as923-JP */ //#define CFG_in866 1 #define CFG_sx1276_radio 1 //#define LMIC_USE_INTERRUPTS
Add comments suit for formatting with idiom
#include "../libk.h" void screenTest(void) { int rows, cols; rows = glob.rows; cols = glob.cols; printf("%s", CursorToTopLeft ClearScreen );fflush(stdout); printf("Top of Screen: rows = %d cols = %d\n\r", rows,cols);fflush(stdout); int count; for (count = 2; count < rows; count ++) {prin...
#include "../libk.h" // function screenTest void screenTest(void) { // retrieve Screen rows and columns from struct glob int rows, cols; rows = glob.rows; cols = glob.cols; // Move Screen Cursor to Top Left, Then Clear Screen printf("%s", CursorToTopLeft ClearScreen );fflush(stdout); // Print the Screen He...
Fix knode superkaramba compilation on NetBSD. Patch by Mark Davies. BUG: 154730
#ifndef LMSENSOR_H #define LMSENSOR_H #include <K3Process> #include <K3ProcIO> #include "sensor.h" /** * * Hans Karlsson **/ class SensorSensor : public Sensor { Q_OBJECT public: SensorSensor(int interval, char tempUnit); ~SensorSensor(); void update(); private: K3ShellProcess ksp; QS...
#ifndef LMSENSOR_H #define LMSENSOR_H #include <K3Process> #include <K3ProcIO> #include "sensor.h" /** * * Hans Karlsson **/ class SensorSensor : public Sensor { Q_OBJECT public: SensorSensor(int interval, char tempUnit); ~SensorSensor(); void update(); private: K3ShellProcess ksp; QS...
Fix return value of main().
int x = 0; int main(int argc, char *argv[]) { int y; char *p = &x; *p = 23; y = x; x = 35; return y; }
int x = 0; int main(int argc, char *argv[]) { int y; char *p = &x; *p = 23; y = x; x = 35; return y != 23; }
Rearrange output operator declarations in tests to make old OSX clang happy
#pragma once #include <TestFramework/TestFramework.h> #include <cal3d/streamops.h> #include <cal3d/vector4.h> #include <boost/shared_ptr.hpp> #include <boost/scoped_ptr.hpp> #include <boost/lexical_cast.hpp> #include <boost/scoped_array.hpp> using boost::scoped_ptr; using boost::shared_ptr; using boost::lexical_cast;...
#pragma once // The old version of clang currently used on the Mac builder requires some // operator<<() declarations to precede their use in the UnitTest++ // templates/macros. -- jlee - 2014-11-21 #include <cal3d/streamops.h> #include <TestFramework/TestFramework.h> #include <cal3d/vector4.h> #include <boost/shared...
Make Networking run on the main thread.
/* Copyright 2011 Future Platforms 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 i...
/* Copyright 2011 Future Platforms 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 i...
Add `nonnull` and `nullable` attributes
// // EYMaskedTextField.h // // // Created by Evgeniy Yurtaev on 10/09/15. // Copyright (c) 2015 Evgeniy Yurtaev. All rights reserved. // #import <UIKit/UIKit.h> @protocol EYMaskedTextFieldDelegate <UITextFieldDelegate> @optional - (BOOL)textField:(UITextField *)textField shouldChangeUnformattedText:(NSString *)u...
// // EYMaskedTextField.h // // // Created by Evgeniy Yurtaev on 10/09/15. // Copyright (c) 2015 Evgeniy Yurtaev. All rights reserved. // #import <UIKit/UIKit.h> NS_ASSUME_NONNULL_BEGIN @protocol EYMaskedTextFieldDelegate <UITextFieldDelegate> @optional - (BOOL)textField:(nonnull UITextField *)textField shouldCh...
Remove _constantwidth as there are other was to determine that via the length of the _width_data vector
#pragma once #include <ri.h> #include <vector> #include "Types.h" typedef std::vector<RtInt> RtIntContainer; typedef std::vector<RtFloat> RtFloatContainer; /*! * \remark Alembic does not support "holes" but to be safe, we are targeting * RiPointsGeneralPolygons to future proof our code * * RtVoid...
#pragma once #include <ri.h> #include <vector> #include "Types.h" typedef std::vector<RtInt> RtIntContainer; typedef std::vector<RtFloat> RtFloatContainer; /*! * \remark Alembic does not support "holes" but to be safe, we are targeting * RiPointsGeneralPolygons to future proof our code * * RtVoid...
Fix detection of lib if we use `-Werror`
/** * @file * * @brief tests if compilation works (include and build paths set correct, etc...) * * @copyright BSD License (see LICENSE.md or https://www.libelektra.org) * */ #include <gcrypt.h> int main (void) { gcry_cipher_hd_t elektraCryptoHandle; return 0; }
/** * @file * * @brief tests if compilation works (include and build paths set correct, etc...) * * @copyright BSD License (see LICENSE.md or https://www.libelektra.org) * */ #include <gcrypt.h> gcry_cipher_hd_t nothing () { gcry_cipher_hd_t elektraCryptoHandle = NULL; return elektraCryptoHandle; } int main...
Fix unintentional tentative definitions that result in duplicate symbol definitions when building with -fno-common
/* * 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 writing, software * distributed u...
/* * 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 writing, software * distributed u...
Add new file to umbrella import.
// // WebApiClient-Core.h // WebApiClient // // Created by Matt on 21/07/15. // Copyright (c) 2015 Blue Rocket. Distributable under the terms of the Apache License, Version 2.0. // #import <WebApiClient/FileWebApiResource.h> #import <WebApiClient/NSDictionary+WebApiClient.h> #import <WebApiClient/WebApiAuthorizati...
// // WebApiClient-Core.h // WebApiClient // // Created by Matt on 21/07/15. // Copyright (c) 2015 Blue Rocket. Distributable under the terms of the Apache License, Version 2.0. // #import <WebApiClient/FileWebApiResource.h> #import <WebApiClient/NSDictionary+WebApiClient.h> #import <WebApiClient/WebApiAuthorizati...
Add portable floating point printing with optional grisu3 support
#ifndef PPRINTFP_H #define PPRINTFP_H /* * Grisu3 is not part of the portable lib per se, it must be in the * include path. Grisu3 provides much faster printing and parsing in the * typical case with fallback to sprintf for printing and strod for * parsing. * * Either define PORTABLE_USE_GRISU3, or include the ...
Add a class for the settings dialog
#pragma once #define CLASS_3RVX L"3RVXv3" static const UINT WM_3RVX_CONTROL = RegisterWindowMessage(L"WM_3RVX_CONTROL"); static const UINT WM_3RVX_SETTINGSCTRL = RegisterWindowMessage(L"WM_3RVX_SETTINGSCTRL"); #define MSG_LOAD WM_APP + 100 #define MSG_SETTINGS WM_APP + 101 #define MSG_EXIT WM_APP + 1...
#pragma once #define CLASS_3RVX L"3RVXv3" #define CLASS_3RVX_SETTINGS L"3RVX-Settings" static const UINT WM_3RVX_CONTROL = RegisterWindowMessage(L"WM_3RVX_CONTROL"); static const UINT WM_3RVX_SETTINGSCTRL = RegisterWindowMessage(L"WM_3RVX_SETTINGSCTRL"); #define MSG_LOAD WM_APP + 100 #define MSG_SETTINGS...
Fix ChromeOS build (C99 break)
/* * Copyright (c) 2011 The WebRTC project authors. All Rights Reserved. * * Use of this source code is governed by a BSD-style license * that can be found in the LICENSE file in the root of the source * tree. An additional intellectual property rights grant can be found * in the file PATENTS. All contribut...
/* * Copyright (c) 2011 The WebRTC project authors. All Rights Reserved. * * Use of this source code is governed by a BSD-style license * that can be found in the LICENSE file in the root of the source * tree. An additional intellectual property rights grant can be found * in the file PATENTS. All contribut...
Use FILE_SHARE_DELETE to fix RemoveFileOnSignal on Windows
// RUN: rm -rf %t && mkdir -p %t && cd %t // RUN: not --crash %clang_cc1 %s -emit-llvm -o foo.ll // RUN: ls . | FileCheck %s --allow-empty // CHECK-NOT: foo.ll #pragma clang __debug crash FOO
Add some color for console output
#ifndef KAI_PLATFORM_GAME_CONTROLLER_H #define KAI_PLATFORM_GAME_CONTROLLER_H #include KAI_PLATFORM_INCLUDE(GameController.h) #endif // SHATTER_PLATFORM_GAME_CONTROLLER_H //EOF
#ifndef KAI_PLATFORM_GAME_CONTROLLER_H #define KAI_PLATFORM_GAME_CONTROLLER_H #include KAI_PLATFORM_INCLUDE(GameController.h) #endif //EOF
Add supplemental __clzhi2, __ctzhi2, for old MSPGCC
/* * Copyright (C) 2016 Eistec AB * * This file is subject to the terms and conditions of the GNU Lesser * General Public License v2.1. See the file LICENSE in the top level * directory for more details. */ /** * @ingroup cpu * @{ * * @file * @brief MSPGCC supplemental functions * * @author ...
Make function inline and noexcept.
// Copyright Verizon Media. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. #pragma once #include <vespa/document/bucket/bucketid.h> #include <vespa/persistence/spi/bucket_limits.h> #include <cassert> namespace storage { /** * Returns the super bucket key of the given bucket id...
// Copyright Verizon Media. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. #pragma once #include <vespa/document/bucket/bucketid.h> #include <vespa/persistence/spi/bucket_limits.h> #include <cassert> namespace storage { /** * Returns the super bucket key of the given bucket id...
Implement the actual utility. Only does key to phrase conversion at the moment.
#include <stdio.h> #include <stdlib.h> #include <string.h> #include "constants.h" #include "funcs.h" int main(int argc, char **argv) { if (argc != 2) { return printf("usage: %s [hex key] [key phrase]\n", argv[0]); } char *wordlist[NUMWORDS]; FILE *fp = fopen(WORDFILE, "r"); if (!fp) { ...
Add a library to provide CHECK and friends.
// Copyright lowRISC contributors. // Licensed under the Apache License, Version 2.0, see LICENSE for details. // SPDX-License-Identifier: Apache-2.0` #ifndef OPENTITAN_SW_DEVICE_LIB_RUNTIME_CHECK_H_ #define OPENTITAN_SW_DEVICE_LIB_RUNTIME_CHECK_H_ #include <stdbool.h> #include "sw/device/lib/base/log.h" #include "s...
Add testcase for last llvm-gcc tweaks
// RUN: %llvmgcc -S %s -emit-llvm -o - | grep "signext" | count 4 signed char foo1() { return 1; } void foo2(signed short a) { } signed char foo3(void) { return 1; } void foo4(a) signed short a; { }
Fix typo: "Pythong" -> "Python" ;-)
// Filename: p3dReferenceCount.h // Created by: drose (09Jul09) // //////////////////////////////////////////////////////////////////// // // PANDA 3D SOFTWARE // Copyright (c) Carnegie Mellon University. All rights reserved. // // All use of this software is subject to the terms of the revised BSD // license. You s...
// Filename: p3dReferenceCount.h // Created by: drose (09Jul09) // //////////////////////////////////////////////////////////////////// // // PANDA 3D SOFTWARE // Copyright (c) Carnegie Mellon University. All rights reserved. // // All use of this software is subject to the terms of the revised BSD // license. You s...
Fix printing bug in node-counter pass
#pragma once #include "bpftrace.h" #include "log.h" #include "pass_manager.h" #include "visitors.h" namespace bpftrace { namespace ast { class NodeCounter : public Visitor { public: void Visit(Node &node) { count_++; Visitor::Visit(node); } size_t get_count() { return count_; }; private: s...
#pragma once #include "bpftrace.h" #include "log.h" #include "pass_manager.h" #include "visitors.h" namespace bpftrace { namespace ast { class NodeCounter : public Visitor { public: void Visit(Node &node) { count_++; Visitor::Visit(node); } size_t get_count() { return count_; }; private: s...
Exclude data store from controller code coverage.
#pragma once #ifndef YOU_CONTROLLER_TESTS_EXCLUSIONS_H_ #define YOU_CONTROLLER_TESTS_EXCLUSIONS_H_ // A local define since there is no way to test whether a header file exists. // If you have VS Premium, then add it to the project definition (user // properties) file #ifdef MS_CPP_CODECOVERAGE /// \file Exclusions fr...
#pragma once #ifndef YOU_CONTROLLER_TESTS_EXCLUSIONS_H_ #define YOU_CONTROLLER_TESTS_EXCLUSIONS_H_ // A local define since there is no way to test whether a header file exists. // If you have VS Premium, then add it to the project definition (user // properties) file #ifdef MS_CPP_CODECOVERAGE /// \file Exclusions fr...
Add wrapper to stop reinclude of library headers
// Wrapper to prevent multiple imports #ifndef LIBHDHOMERUN_H #define LIBHDHOMERUN_H #import "hdhomerun_os.h" #import "hdhomerun_discover.h" #import "hdhomerun_pkt.h" #endif
Change Plugin methods to static
#pragma once #include "begin_code.h" namespace _internal { /// This is just an empty class. /// Most wrapper class regard this class as a friend class. /// You can get/set raw pointers through this class. class Plugin { public: template<typename T> decltype(auto) get(const T& obj) { return obj._get...
#pragma once #include "begin_code.h" namespace _internal { /// This is just an empty class. /// Most wrapper class regard this class as a friend class. /// You can get/set raw pointers through this class. class Plugin { public: template<typename T> static decltype(auto) get(const T& obj) { return o...
Disable some compiler warnings on the boost library.
// Copyright (c) 2009-2011 Turbulenz Limited // stdafx.h : include file for standard system include files, // or project specific include files that are used frequently, but // are changed infrequently // #ifdef _MSC_VER #pragma once #endif #ifndef _WIN32_WINNT // Allow use of features specific to Windows XP or lat...
// Copyright (c) 2009-2011 Turbulenz Limited // stdafx.h : include file for standard system include files, // or project specific include files that are used frequently, but // are changed infrequently // #ifdef _MSC_VER #pragma once #endif #ifndef _WIN32_WINNT // Allow use of features specific to Windows XP or lat...
Structure to hold header information for dat that should be written to file.
#ifndef ALIHLTPHOSDATAHEADERSTRUCT_H #define ALIHLTPHOSDATAHEADERSTRUCT_H #include "AliHLTDataTypes.h" struct AliHLTPHOSDataHeaderStruct { AliHLTUInt32_t fSize; /**<Total size of datablock in bytes, incuding the header*/ AliHLTComponentDataType fDataType; /**<Data type stored in this file */ AliHLT...
Remove unnecessary lib include check
/* vl53l0x_types.h - Zephyr customization of ST vl53l0x library, * basic type definition. */ /* * Copyright (c) 2017 STMicroelectronics * * SPDX-License-Identifier: Apache-2.0 */ #ifndef ZEPHYR_DRIVERS_SENSOR_VL53L0X_VL53L0X_TYPES_H_ #define ZEPHYR_DRIVERS_SENSOR_VL53L0X_VL53L0X_TYPES_H_ /* Zephyr provides st...
/* vl53l0x_types.h - Zephyr customization of ST vl53l0x library, * basic type definition. */ /* * Copyright (c) 2017 STMicroelectronics * * SPDX-License-Identifier: Apache-2.0 */ #ifndef ZEPHYR_DRIVERS_SENSOR_VL53L0X_VL53L0X_TYPES_H_ #define ZEPHYR_DRIVERS_SENSOR_VL53L0X_VL53L0X_TYPES_H_ /* Zephyr provides st...
Add filter stub in header
/// \file api.h /// Defines the API for Query Engine. /// \author A0112054Y #pragma once #ifndef YOU_QUERYENGINE_API_H_ #define YOU_QUERYENGINE_API_H_ #include <memory> #include <boost/variant.hpp> #include "task_model.h" namespace You { namespace QueryEngine { /// A synthesized type for holding query responses typ...
/// \file api.h /// Defines the API for Query Engine. /// \author A0112054Y #pragma once #ifndef YOU_QUERYENGINE_API_H_ #define YOU_QUERYENGINE_API_H_ #include <memory> #include <boost/variant.hpp> #include "task_model.h" namespace You { namespace QueryEngine { /// A synthesized type for holding query responses typ...
Remove vi schmutz at EOF
#ifndef __EVENT_SERVICE_H__ #define __EVENT_SERVICE_H__ #include "basic_types.h" int32_t events_winopen(char *title); int32_t events_get_valuator(int32_t device); void events_qdevice(int32_t device); int32_t events_qread_start(int blocking); int32_t events_qread_continue(int16_t *value); void events_tie(int32_t butt...
#ifndef __EVENT_SERVICE_H__ #define __EVENT_SERVICE_H__ #include "basic_types.h" int32_t events_winopen(char *title); int32_t events_get_valuator(int32_t device); void events_qdevice(int32_t device); int32_t events_qread_start(int blocking); int32_t events_qread_continue(int16_t *value); void events_tie(int32_t butt...
Fix also applied to corresponding C file
#include <pony/pony.h> #include "encore.h" encore_actor_t *encore_create(encore_create_t *type) { return pony_create(type); } /// Allocate s bytes of memory, zeroed out void *encore_alloc(size_t *s) { void *mem = pony_alloc(s); memset(mem, 0, s); return mem; } /// The starting point of all Encore programs i...
#include <pony/pony.h> #include "encore.h" encore_actor_t *encore_create(encore_actor_t *type) { return pony_create(type); } /// Allocate s bytes of memory, zeroed out void *encore_alloc(size_t *s) { void *mem = pony_alloc(s); memset(mem, 0, s); return mem; } /// The starting point of all Encore programs in...
Add invariant precision worsening test for globals
// modified from 27/09 #include <assert.h> #include <pthread.h> int a = 1; int b = 1; pthread_mutex_t A = PTHREAD_MUTEX_INITIALIZER; void* t_fun(void *arg) { return NULL; } int main() { int *x; int rnd; if (rnd) x = &a; else x = &b; pthread_t id; pthread_create(&id, NULL, t_fun, NULL); // go...
Tweak RSSI tracking speed/count for better graphs
#ifndef RECEIVER_H #define RECEIVER_H #include <stdint.h> #include "settings.h" #define RECEIVER_A 0 #ifdef USE_DIVERSITY #define RECEIVER_B 1 #define RECEIVER_AUTO 2 #define DIVERSITY_AUTO 0 #define DIVERSITY_FORCE_A 1 #define DIVERSITY_FORCE_B 2 #endif #define RECEIVER_LAST_DELAY 100 #define RECEIVER_...
#ifndef RECEIVER_H #define RECEIVER_H #include <stdint.h> #include "settings.h" #define RECEIVER_A 0 #ifdef USE_DIVERSITY #define RECEIVER_B 1 #define RECEIVER_AUTO 2 #define DIVERSITY_AUTO 0 #define DIVERSITY_FORCE_A 1 #define DIVERSITY_FORCE_B 2 #endif #define RECEIVER_LAST_DELAY 50 #define RECEIVER_L...
Add function for serialize std::unique_ptr
#include <boost/serialization/version.hpp> #include <memory> namespace boost { namespace serialization { template<class Archive, class T> inline void save(Archive& ar, const std::unique_ptr<T>& t, const unsigned int){ // only the raw pointer has to be saved const T* const tx = t.get(); ar << tx; } templa...
Adjust asm-c-connect testcase for Windows
#include <stdio.h> #if defined _WIN32 && !defined __TINYC__ # define U "_" #else # define U #endif const char str[] = "x1\n"; #ifdef __x86_64__ asm(U"x1: push %rbp; mov $"U"str, %rdi; call "U"printf; pop %rbp; ret"); #elif defined (__i386__) asm(U"x1: push $"U"str; call "U"printf; pop %eax; ret"); #endif int main(in...
#include <stdio.h> #if defined _WIN32 && !defined __TINYC__ # define _ "_" #else # define _ #endif static int x1_c(void) { printf("x1\n"); return 1; } asm(".text;"_"x1: call "_"x1_c; ret"); int main(int argc, char *argv[]) { asm("call "_"x1"); asm("call "_"x2"); asm("call "_"x3"); return 0; ...
Update to add newline EOF
#pragma once #include "AuxKernel.h" #include "RadialAverage.h" /** * Auxkernel to output the averaged material value from RadialAverage */ class RadialAverageAux : public AuxKernel { public: static InputParameters validParams(); RadialAverageAux(const InputParameters & parameters); protected: virtual Real co...
#pragma once #include "AuxKernel.h" #include "RadialAverage.h" /** * Auxkernel to output the averaged material value from RadialAverage */ class RadialAverageAux : public AuxKernel { public: static InputParameters validParams(); RadialAverageAux(const InputParameters & parameters); protected: virtual Real co...
Add simple regression test for congruence domain
//PARAM: --enable ana.int.congruence --disable ana.int.def_exc --disable ana.int.enums int main() { int a = 1; int b = 2; int c = 3; int d = 4; int e = 0; while (d < 9) { b = 2 * a; d = d + 4; e = e - 4 * a; a = b - a; c = e + d; } a = d / 2; b = d % 2; assert (c == 4); // UNKNOWN! assert (d =...
Revert "Add support for the Python Stdout Log"
// Copyright 1998-2016 Epic Games, Inc. All Rights Reserved. #pragma once #include "ModuleManager.h" DECLARE_LOG_CATEGORY_EXTERN(LogPython, Log, All); class UNREALENGINEPYTHON_API FUnrealEnginePythonModule : public IModuleInterface { public: bool PythonGILAcquire(); void PythonGILRelease(); virtual void Start...
// Copyright 1998-2016 Epic Games, Inc. All Rights Reserved. #pragma once #include "ModuleManager.h" DECLARE_LOG_CATEGORY_EXTERN(LogPython, Log, All); class UNREALENGINEPYTHON_API FUnrealEnginePythonModule : public IModuleInterface { public: bool PythonGILAcquire(); void PythonGILRelease(); virtual void Start...
Add ARRAYSIZE macro for Google test environment
// (C) Copyright 2017, Google Inc. // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // http://www.apache.org/licenses/LICENSE-2.0 // Unless required by applicable law or agreed to in writing,...
// (C) Copyright 2017, Google Inc. // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // http://www.apache.org/licenses/LICENSE-2.0 // Unless required by applicable law or agreed to in writing,...
Fix some Include What You Use warnings; other minor fixes (NFC).
//===-- PPCTargetStreamer.h - PPC Target Streamer --s-----------*- C++ -*--===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===-------------------------------------------------------...
//===- PPCTargetStreamer.h - PPC Target Streamer ----------------*- C++ -*-===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===-------------------------------------------------------...
Fix including framework headers' path
#import <UIKit/UIKit.h> //! Project version number for YOChartImageKit. FOUNDATION_EXPORT double YOChartImageKitVersionNumber; //! Project version string for YOChartImageKit. FOUNDATION_EXPORT const unsigned char YOChartImageKitVersionString[]; #import <YOChartImageKit/YODonutChartImage.h> #import <YOChartImageKit/Y...
#import <UIKit/UIKit.h> //! Project version number for YOChartImageKit. FOUNDATION_EXPORT double YOChartImageKitVersionNumber; //! Project version string for YOChartImageKit. FOUNDATION_EXPORT const unsigned char YOChartImageKitVersionString[]; #import "YODonutChartImage.h" #import "YOBarChartImage.h" #import "YOLin...
Add exmpale of confusion between locals of different procedures :/
// SKIP PARAM: --set solver td3 --set ana.activated "['base','threadid','threadflag','mallocWrapper','apron','escape']" --set ana.base.privatization none --set ana.apron.privatization dummy extern int __VERIFIER_nondet_int(); void change(int *p) { int a; (*p)++; a++; assert(a == 7); //UNKNOWN! } int g...
Add 1-10 external variable example
// // Created by matti on 16.9.2015. // #include <stdio.h> #define MAXLINE 1000 int max; char line[MAXLINE]; char longest[MAXLINE]; int getline(void); void copy(void); int main() { int len; extern int max; extern char longest[]; max = 0; while((len = getline()) > 0) { if (len > max) { ...
// // Created by matti on 16.9.2015. // #include <stdio.h> #define MAXLINE 1000 int max; char line[MAXLINE]; char longest[MAXLINE]; int getnewline(void); void copy(void); int main() { int len; extern int max; extern char longest[]; max = 0; while((len = getnewline()) > 0) { if (len > m...
Move glib-object.h include inside USE_GLIB conditional
#ifndef MYPAINTBRUSHGLIB_H #define MYPAINTBRUSHGLIB_H #include <glib-object.h> #include <mypaint-config.h> #if MYPAINT_CONFIG_USE_GLIB #define MYPAINT_TYPE_BRUSH (mypaint_brush_get_type ()) #define MYPAINT_VALUE_HOLDS_BRUSH(value) (G_TYPE_CHECK_VALUE_TYPE ((value), MYPAINT_TYPE_BRUSH)) GType mypaint_b...
#ifndef MYPAINTBRUSHGLIB_H #define MYPAINTBRUSHGLIB_H #include <mypaint-config.h> #if MYPAINT_CONFIG_USE_GLIB #include <glib-object.h> #define MYPAINT_TYPE_BRUSH (mypaint_brush_get_type ()) #define MYPAINT_VALUE_HOLDS_BRUSH(value) (G_TYPE_CHECK_VALUE_TYPE ((value), MYPAINT_TYPE_BRUSH)) GType mypaint_br...
Check in header file that was missing, thus broke the build
//===-- InstLoops.h - interface to insert instrumentation --------*- C++ -*--=// // // Instrument every back edges with counters //===----------------------------------------------------------------------===// #ifndef LLVM_REOPTIMIZERINSTLOOPS_H #define LLVM_REOPTIMIZERINSTLOOPS_H class Pass; // createInstLoopsPass ...
Reduce compiled code size by storing a result of a likely-used common expression
#include "cisf.h" #include "expf.h" float _Complex cexpf(float _Complex z) { float x = z; float y = cimagf(z); if (y == 0) return CMPLXF(expf_(x), y); if (y - y) { if (x == INFINITY) return CMPLXF(x, y - y); if (x == -INFINITY) return 0; } ret...
#include "cisf.h" #include "expf.h" float _Complex cexpf(float _Complex z) { float x = z; float y = cimagf(z); double r = expf_(x); if (y == 0) return CMPLXF(r, y); if (y - y) { if (x == INFINITY) return CMPLXF(x, y - y); if (x == -INFINITY) return...
Create a class for drawing progress bars on a console window
/* The Halfling Project - A Graphics Engine and Projects * * The Halfling Project is the legal property of Adrian Astley * Copyright Adrian Astley 2013 */ #ifndef CONSOLE_PROGRESS_BAR_H #define CONSOLE_PROGRESS_BAR_H #include "common/typedefs.h" #include "rlutil.h" #include <cassert> namespace Common { class ...
Make it easy to iterate a vector
#ifndef LB_VECTOR_INCLUDED #include "lb_scalar.h" // Assume Vector to be n rows by 1 column typedef struct { Scalar* data; unsigned int length; } Vector; Vector lb_create_vector(Scalar* data, unsigned int length); Vector lb_allocate_vector(unsigned int length); void lbdp(Vector a, Vector b, Scalar* result);...
#ifndef LB_VECTOR_INCLUDED #include "lb_scalar.h" // Assume Vector to be n rows by 1 column typedef struct { Scalar* data; unsigned int length; } Vector; Vector lb_create_vector(Scalar* data, unsigned int length); Vector lb_allocate_vector(unsigned int length); void lbdp(Vector a, Vector b, Scalar* result);...
Update prefix for CW Pro1
#include <MacHeaders.h> #include <ansi_prefix.mac.h> #pragma once off #define HAVE_CONFIG_H #define PORT 1 #define MACOS 1 #define CONFIGLESS 1 #include "prefix.h"
#include <MacHeaders.h> //#include <ansi_prefix.mac.h> #pragma once off #define HAVE_CONFIG_H #define PORT 1 #define MACOS 1 #define CONFIGLESS 1 #include "prefix.h"
Restructure for code reuse and hiding implementation.
// Copyright 2018 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. #pragma once #include <cstdint> namespace search::queryeval { struct IDiversifier { virtual ~IDiversifier() {} /** * Will tell if this document should be kept, and update state for fur...
Fix compilation of constructor_global module
/* * cxx_constructors_global.c * * Created on: 30 janv. 2013 * Author: fsulima */ #include <embox/unit.h> EMBOX_UNIT_INIT(cxx_init); EMBOX_UNIT_FINI(cxx_fini); #include "cxx_invoke_constructors.h" #include "cxx_invoke_destructors.h" #include "cxx_app_startup_terminatioin.h" static int cxx_init(void) { ...
/* * cxx_constructors_global.c * * Created on: 30 janv. 2013 * Author: fsulima */ #include <embox/unit.h> #include "cxx_invoke_constructors.h" #include "cxx_invoke_destructors.h" #include "cxx_app_startup_termination.h" EMBOX_UNIT(cxx_init, cxx_fini); static int cxx_init(void) { cxx_invoke_constructors(...
Include latest class additions in umbrella include.
// // Mapping.h // Menu // // Created by Matt on 21/07/15. // Copyright (c) 2015 Blue Rocket. All rights reserved. // #import <BRMenu/UI/BRMenuPlusMinusButton.h> #import <BRMenu/UI/BRMenuStepper.h> #import <BRMenu/UI/BRMenuUIStyle.h>
// // Mapping.h // Menu // // Created by Matt on 21/07/15. // Copyright (c) 2015 Blue Rocket. All rights reserved. // #import <BRMenu/UI/BRMenuBackBarButtonItemView.h> #import <BRMenu/UI/BRMenuBarButtonItemView.h> #import <BRMenu/UI/BRMenuPlusMinusButton.h> #import <BRMenu/UI/BRMenuStepper.h> #import <BRMenu/UI/BR...
Fix compiler warning in Leap
#ifndef _LEAP_H #define _LEAP_H #include <stdbool.h> bool leap_year(int year); #endif
#ifndef _LEAP_H #define _LEAP_H #include <stdbool.h> bool is_leap_year(int year); #endif
Test is broken; XFAIL it until Argyrios gets a chance to look at it.
// RUN: %clang_cc1 %s -Wunused-macros -Dfoo -Dfoo -verify #include "warn-macro-unused.h" #define unused // expected-warning {{macro is not used}} #define unused unused // rdar://9745065 #undef unused_from_header // no warning
// RUN: %clang_cc1 %s -Wunused-macros -Dfoo -Dfoo -verify // XFAIL: * #include "warn-macro-unused.h" #define unused // expected-warning {{macro is not used}} #define unused unused // rdar://9745065 #undef unused_from_header // no warning
Fix disabled interaction on device
// // HATransparentView.h // HATransparentView // // Created by Heberti Almeida on 13/09/13. // Copyright (c) 2013 Heberti Almeida. All rights reserved. // #import <UIKit/UIKit.h> @interface HATransparentView : UIView @property (strong, nonatomic) UIColor *color; @property (nonatomic) CGFloat *alpha; - (void)op...
// // HATransparentView.h // HATransparentView // // Created by Heberti Almeida on 13/09/13. // Copyright (c) 2013 Heberti Almeida. All rights reserved. // #import <UIKit/UIKit.h> @interface HATransparentView : UIView - (void)open; - (void)close; @end
Fix the import in the bridge header file to account for changes in RN 0.48
// // InstabugReactBridge.h // instabugDemo // // Created by Yousef Hamza on 9/29/16. // Copyright © 2016 Facebook. All rights reserved. // #import <Foundation/Foundation.h> #import "RCTBridgeModule.h" #import "RCTEventEmitter.h" @interface InstabugReactBridge : RCTEventEmitter <RCTBridgeModule> @end
// // InstabugReactBridge.h // instabugDemo // // Created by Yousef Hamza on 9/29/16. // Copyright © 2016 Facebook. All rights reserved. // #import <Foundation/Foundation.h> #import <React/RCTBridgeModule.h> #import "RCTEventEmitter.h" @interface InstabugReactBridge : RCTEventEmitter <RCTBridgeModule> @end
Fix the previous commit: the 'initialize()' function wasn't declared in the 'Athena::Physics' namespace
/** @file Prerequisites.h @author Philip Abbet Declaration of the types of the Athena-Physics module */ #ifndef _ATHENA_PHYSICS_PREREQUISITES_H_ #define _ATHENA_PHYSICS_PREREQUISITES_H_ #include <Athena-Core/Prerequisites.h> #include <Athena-Physics/Config.h> #include <Bullet/btConfig.h> #include <btBu...
/** @file Prerequisites.h @author Philip Abbet Declaration of the types of the Athena-Physics module */ #ifndef _ATHENA_PHYSICS_PREREQUISITES_H_ #define _ATHENA_PHYSICS_PREREQUISITES_H_ #include <Athena-Core/Prerequisites.h> #include <Athena-Physics/Config.h> #include <Bullet/btConfig.h> #include <btBu...
Fix path to vulkan header.
/* * Copyright 2018 Google Inc. * * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ #ifndef GrVkVulkan_DEFINED #define GrVkVulkan_DEFINED #include "SkTypes.h" #ifdef VULKAN_CORE_H_ #error "Skia's private vulkan header must be included before any other vulka...
/* * Copyright 2018 Google Inc. * * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ #ifndef GrVkVulkan_DEFINED #define GrVkVulkan_DEFINED #include "SkTypes.h" #ifdef VULKAN_CORE_H_ #error "Skia's private vulkan header must be included before any other vulka...
Fix warning in PBKDF1 copy constructor
/************************************************* * PBKDF1 Header File * * (C) 1999-2007 Jack Lloyd * *************************************************/ #ifndef BOTAN_PBKDF1_H__ #define BOTAN_PBKDF1_H__ #include <botan/s2k.h> #include <botan/base.h> namespace Botan ...
/************************************************* * PBKDF1 Header File * * (C) 1999-2007 Jack Lloyd * *************************************************/ #ifndef BOTAN_PBKDF1_H__ #define BOTAN_PBKDF1_H__ #include <botan/s2k.h> #include <botan/base.h> namespace Botan ...
Convert default font name into an NSString
#ifndef AppIconOverlay_config_h #define AppIconOverlay_config_h #define DEBUG 1 #define DEFAULT_MIN_FONT_SIZE 6.0 #define DEFAULT_MAX_FONT_SIZE 18.0 #define DEFAULT_FONT_TO_USE "Arial-BoldMT" #endif
#ifndef AppIconOverlay_config_h #define AppIconOverlay_config_h #define DEBUG 1 #define DEFAULT_MIN_FONT_SIZE 6.0 #define DEFAULT_MAX_FONT_SIZE 18.0 #define DEFAULT_FONT_TO_USE @"Arial-BoldMT" #endif
Remove unused external function definitions.
/* * Copyright (c) 2010 The WebM project authors. All Rights Reserved. * * Use of this source code is governed by a BSD-style license * that can be found in the LICENSE file in the root of the source * tree. An additional intellectual property rights grant can be found * in the file PATENTS. All contributin...
/* * Copyright (c) 2010 The WebM project authors. All Rights Reserved. * * Use of this source code is governed by a BSD-style license * that can be found in the LICENSE file in the root of the source * tree. An additional intellectual property rights grant can be found * in the file PATENTS. All contributin...
Fix no-return for non-GCC and non-VS.
/* Title: No return header. Author: David C.J. Matthews Copyright (c) 2006, 2015 David C.J. Matthews This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License version 2.1 as published by the Free Software Foundation. ...
/* Title: No return header. Author: David C.J. Matthews Copyright (c) 2006, 2015 David C.J. Matthews This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License version 2.1 as published by the Free Software Foundation. ...
Fix include statement of FLTK header such that it compiles with FLTK 1.3 without requiring backwards compatible link creation.
#ifndef Fl_Value_Slider2_H #define Fl_Value_Slider2_H #include "Fl/Fl_Slider.H" class Fl_Value_Slider2 : public Fl_Slider { uchar textfont_, textsize_; unsigned textcolor_; public: void draw(); int handle(int); Fl_Value_Slider2(int x,int y,int w,int h, const char *l = 0); Fl_Font textfont() co...
#ifndef Fl_Value_Slider2_H #define Fl_Value_Slider2_H #include <FL/Fl_Slider.H> class Fl_Value_Slider2 : public Fl_Slider { uchar textfont_, textsize_; unsigned textcolor_; public: void draw(); int handle(int); Fl_Value_Slider2(int x,int y,int w,int h, const char *l = 0); Fl_Font textfont() co...
Add another / to a couple comments in Problem 14 to make intended Doxygen comments visible as such.
//===-- problems/Problem14.h ------------------------------------*- C++ -*-===// // // ProjectEuler.net solutions by Will Mitchell // // This file is distributed under the MIT License. See LICENSE for details. // //===----------------------------------------------------------------------===// /// /// \file /// \brief P...
//===-- problems/Problem14.h ------------------------------------*- C++ -*-===// // // ProjectEuler.net solutions by Will Mitchell // // This file is distributed under the MIT License. See LICENSE for details. // //===----------------------------------------------------------------------===// /// /// \file /// \brief P...
Add more assert statements to test case
//PARAM: --enable ana.int.enums --disable ana.int.def_exc int main(){ int top = rand(); int x,y; if(top){ x = 1; } else{ x = 0; } assert(x<2); return 0; }
//PARAM: --enable ana.int.enums --disable ana.int.def_exc int main(){ int top = rand(); int x,y; if(top){ x = 1; } else{ x = 0; } assert(x < 2); assert(x < 1); // UNKNOWN! assert(x < 0); // FAIL assert(x <= 2); assert(x <= 1); assert(x <= 0); // UNKNOWN! ...
Replace `if (p) free(p)' with `mh_xfree(p)'.
/* * folder_free.c -- free a folder/message structure * * This code is Copyright (c) 2002, by the authors of nmh. See the * COPYRIGHT file in the root directory of the nmh distribution for * complete copyright information. */ #include <h/mh.h> void folder_free (struct msgs *mp) { size_t i; bvector_t ...
/* * folder_free.c -- free a folder/message structure * * This code is Copyright (c) 2002, by the authors of nmh. See the * COPYRIGHT file in the root directory of the nmh distribution for * complete copyright information. */ #include <h/mh.h> #include <h/utils.h> void folder_free (struct msgs *mp) { siz...
Add the grub-specific charset functions. (dm)
/* * BRLTTY - A background process providing access to the console screen (when in * text mode) for a blind person using a refreshable braille display. * * Copyright (C) 1995-2012 by The BRLTTY Developers. * * BRLTTY comes with ABSOLUTELY NO WARRANTY. * * This is free software, placed under the terms o...
Remove rint() prototype from QNX.
#include <sys/types.h> /* for namser.h */ #include <arpa/nameser.h> /* for BYTE_ORDER */ #include <process.h> /* for execv */ #include <ioctl.h> /* for unix.h */ #include <unix.h> #include <sys/select.h> /* for select */ #define HAS_TEST_AND_SET #undef HAVE_GETRUSAGE #define strncasecmp strnicmp #ifndef ...
#include <sys/types.h> /* for namser.h */ #include <arpa/nameser.h> /* for BYTE_ORDER */ #include <process.h> /* for execv */ #include <ioctl.h> /* for unix.h */ #include <unix.h> #include <sys/select.h> /* for select */ #define HAS_TEST_AND_SET #undef HAVE_GETRUSAGE #define strncasecmp strnicmp #ifndef ...
Remove unnecessary lldb_enable_attach in TestMultilineCompletion
int main(int argc, char **argv) { lldb_enable_attach(); int to_complete = 0; return to_complete; }
int main(int argc, char **argv) { int to_complete = 0; return to_complete; }
Fix a typo, that could cause a crash on mac.
// Copyright (c) 2008 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #ifndef NET_PROXY_PROXY_RESOLVER_MAC_H_ #define NET_PROXY_PROXY_RESOLVER_MAC_H_ #pragma once #include <string> #include "googleurl/src/gurl.h" #incl...
// Copyright (c) 2008 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #ifndef NET_PROXY_PROXY_RESOLVER_MAC_H_ #define NET_PROXY_PROXY_RESOLVER_MAC_H_ #pragma once #include <string> #include "googleurl/src/gurl.h" #incl...
Make build crash early on purpose (to test test suite...)
/* ISC license. */ /* MT-unsafe */ #include <skalibs/stralloc.h> #include <skalibs/skamisc.h> #include <skalibs/djbunix.h> int sarealpath (stralloc *sa, char const *path) { return sarealpath_tmp(sa, path, &satmp) ; }
/* ISC license. */ /* MT-unsafe */ #include <skalibs/stralloc.h> #include <skalibs/skamisc.h> #include <skalibs/djbunix.h> BUG int sarealpath (stralloc *sa, char const *path) { return sarealpath_tmp(sa, path, &satmp) ; }
Add peek methods to mock queue.
#ifndef TACHYON_TEST_UTILS_MOCK_QUEUE_H_ #define TACHYON_TEST_UTILS_MOCK_QUEUE_H_ #include <stdint.h> #include "gmock/gmock.h" #include "lib/queue_interface.h" namespace tachyon { namespace testing { // Mock class for queues. template <class T> class MockQueue : public QueueInterface<T> { public: MOCK_METHOD1_T...
#ifndef TACHYON_TEST_UTILS_MOCK_QUEUE_H_ #define TACHYON_TEST_UTILS_MOCK_QUEUE_H_ #include <stdint.h> #include "gmock/gmock.h" #include "lib/queue_interface.h" namespace tachyon { namespace testing { // Mock class for queues. template <class T> class MockQueue : public QueueInterface<T> { public: MOCK_METHOD1_T...