prompt stringlengths 219 3.5k | completion stringlengths 96 1.37k | file_path stringlengths 5 168 | lang stringclasses 7
values | commit stringlengths 40 40 | text stringlengths 316 4.54k |
|---|---|---|---|---|---|
<|file_sep|>src/utils/mapped_file.cpp.diff
original:
updated:
#include <exception/elf.h>
<|file_sep|>original/src/utils/mapped_file.cpp
int fd;
struct stat buf;
char* begin;
if ((fd = open(get_path(), O_RDONLY)) == -1)
throw sasm::exception::os("open", get_path());
if (fstat(fd, &buf) == -1)
thro... | int fd;
struct stat buf;
char* begin;
if ((fd = open(get_path(), O_RDONLY)) == -1)
throw sasm::exception::os("open", get_path());
if (fstat(fd, &buf) == -1)
throw sasm::exception::os("fstat");
if (buf.st_size == 0)
throw sasm::exception::elf(_path.c_str(), "invalid ELF file");
if ((begin... | src/utils/mapped_file.cpp | C++ | c91029f2fd832db64d88ce996a42ac52616ec07d | <|file_sep|>src/utils/mapped_file.cpp.diff
original:
updated:
#include <exception/elf.h>
<|file_sep|>original/src/utils/mapped_file.cpp
int fd;
struct stat buf;
char* begin;
if ((fd = open(get_path(), O_RDONLY)) == -1)
throw sasm::exception::os("open", get_path());
if (fstat(fd, &buf) == -1)
thro... |
<|file_sep|>test/iterator_concepts_ordering.cpp.diff
original:
updated:
BOOST_MPL_ASSERT((duck::is_more_specific_than<
duck::ForwardIterator,
duck::RandomAccessIterator>));
<|file_sep|>original/test/iterator_concepts_ordering.cpp
BOOST_MPL_ASSERT((duck::is_more_specific_than<
... |
BOOST_MPL_ASSERT((duck::is_more_specific_than<
duck::ForwardIterator,
duck::RandomAccessIterator>));
BOOST_MPL_ASSERT_NOT((duck::is_more_specific_than<
duck::RandomAccessIterator,
duck::BidirectionalIterator>));
BOOST_MPL_ASSERT... | test/iterator_concepts_ordering.cpp | C++ | a625de351c3b129f11faf26330dafdb16f10b855 | <|file_sep|>test/iterator_concepts_ordering.cpp.diff
original:
updated:
BOOST_MPL_ASSERT((duck::is_more_specific_than<
duck::ForwardIterator,
duck::RandomAccessIterator>));
<|file_sep|>original/test/iterator_concepts_ordering.cpp
BOOST_MPL_ASSERT((duck::is_more_specific_than<
... |
<|file_sep|>main.cpp.diff
original:
updated:
const QString APP_ORGNAME = "PepperNote";
const QString APP_APPNAME = "PepperNote";
<|file_sep|>original/main.cpp
#include <QApplication>
#include "mainwindow.h"
int main(int argc, char *argv[])
{
QApplication a(argc, argv);
MainWindow w;
w.show();
re... | #include <QApplication>
#include "mainwindow.h"
const QString APP_ORGNAME = "PepperNote";
const QString APP_APPNAME = "PepperNote";
int main(int argc, char *argv[])
{
QCoreApplication::setOrganizationName(APP_ORGNAME);
QCoreApplication::setApplicationName(APP_APPNAME);
QApplication a(argc, argv);
Mai... | main.cpp | C++ | dbf2bac7fed179f25956d8783ab619de31131288 | <|file_sep|>main.cpp.diff
original:
updated:
const QString APP_ORGNAME = "PepperNote";
const QString APP_APPNAME = "PepperNote";
<|file_sep|>original/main.cpp
#include <QApplication>
#include "mainwindow.h"
int main(int argc, char *argv[])
{
QApplication a(argc, argv);
MainWindow w;
w.show();
re... |
<|file_sep|>engine/src/level.cpp.diff
original:
updated:
#include <iostream>
<|file_sep|>original/engine/src/level.cpp
for(auto hit : game_object->get_hitboxes()){
hit->initialize();
}
}
}
void Level::free(){
for(auto game_object : objects){
std::cout << "Freeing" << game_object->name << std::en... | }
void Level::free(){
for(auto game_object : objects){
std::cout << "Freeing" << game_object->name << std::endl;
game_object->free();
}
EventHandler::listeners.clear();
}
void Level::draw(){
for(auto game_object : objects){
if(game_object->is_active()){
if(game_object->name == "arm_left"){
... | engine/src/level.cpp | C++ | 7dc394773390abe56a0024f1f113a6f644c8e083 | <|file_sep|>engine/src/level.cpp.diff
original:
updated:
#include <iostream>
<|file_sep|>original/engine/src/level.cpp
for(auto hit : game_object->get_hitboxes()){
hit->initialize();
}
}
}
void Level::free(){
for(auto game_object : objects){
std::cout << "Freeing" << game_object->name << std::en... |
<|file_sep|>stub/src/qtfirebase.cpp.diff
original:
updated:
#include "qtfirebasemessaging.h"
<|file_sep|>original/stub/src/qtfirebase.cpp
#include "qtfirebasedatabase.h"
#ifdef QTFIREBASE_BUILD_ANALYTICS
QtFirebaseAnalytics* QtFirebaseAnalytics::self = nullptr;
#endif
#ifdef QTFIREBASE_BUILD_REMOTE_CONFIG
QtFirebase... | #endif
#ifdef QTFIREBASE_BUILD_REMOTE_CONFIG
QtFirebaseRemoteConfig* QtFirebaseRemoteConfig::self = nullptr;
#endif
#ifdef QTFIREBASE_BUILD_ADMOB
QtFirebaseAdMob *QtFirebaseAdMob::self = nullptr;
#endif
#ifdef QTFIREBASE_BUILD_AUTH
QtFirebaseAuth *QtFirebaseAuth::self = nullptr;
#endif
#ifdef QTFIREBASE_BUILD_DATAB... | stub/src/qtfirebase.cpp | C++ | 2b5eb8f79e75bd7fab3221acf806e70d468ce48a | <|file_sep|>stub/src/qtfirebase.cpp.diff
original:
updated:
#include "qtfirebasemessaging.h"
<|file_sep|>original/stub/src/qtfirebase.cpp
#include "qtfirebasedatabase.h"
#ifdef QTFIREBASE_BUILD_ANALYTICS
QtFirebaseAnalytics* QtFirebaseAnalytics::self = nullptr;
#endif
#ifdef QTFIREBASE_BUILD_REMOTE_CONFIG
QtFirebase... |
<|file_sep|>src/main.cpp.diff
original:
updated:
#include <QImageReader>
<|file_sep|>original/src/main.cpp
/*
Copyright (c), Helios
All rights reserved.
Distributed under a permissive license. See COPYING.txt for details.
*/
#include "ImageViewerApplication.h"
int main(int argc, char **argv){
try{
initialize_sup... | All rights reserved.
Distributed under a permissive license. See COPYING.txt for details.
*/
#include "ImageViewerApplication.h"
#include <QImageReader>
int main(int argc, char **argv){
try{
//Set the limit to 1 GiB.
QImageReader::setAllocationLimit(1024);
initialize_supported_extensions();
ImageViewerAppli... | src/main.cpp | C++ | 5b362013706f78b84bf205c6cf04e31065f7b732 | <|file_sep|>src/main.cpp.diff
original:
updated:
#include <QImageReader>
<|file_sep|>original/src/main.cpp
/*
Copyright (c), Helios
All rights reserved.
Distributed under a permissive license. See COPYING.txt for details.
*/
#include "ImageViewerApplication.h"
int main(int argc, char **argv){
try{
initialize_sup... |
<|file_sep|>JasonType.cpp.diff
original:
updated:
case JasonType::ArrayLong: return "array_long";
<|file_sep|>original/JasonType.cpp
char const* triagens::basics::JasonTypeName (JasonType type) {
switch (type) {
case JasonType::None: return "none";
case JasonType::Null: return "null"... | char const* triagens::basics::JasonTypeName (JasonType type) {
switch (type) {
case JasonType::None: return "none";
case JasonType::Null: return "null";
case JasonType::Bool: return "bool";
case JasonType::Double: return "double";
case JasonType::String: return "stri... | JasonType.cpp | C++ | 905cba4c0107520616c2b95515042b283aab28c4 | <|file_sep|>JasonType.cpp.diff
original:
updated:
case JasonType::ArrayLong: return "array_long";
<|file_sep|>original/JasonType.cpp
char const* triagens::basics::JasonTypeName (JasonType type) {
switch (type) {
case JasonType::None: return "none";
case JasonType::Null: return "null"... |
<|file_sep|>opencog/atoms/core/Checkers.cc.diff
original:
updated:
/// Check to see if every input atom is of Evaluatable type.
<|file_sep|>original/opencog/atoms/core/Checkers.cc
* You should have received a copy of the GNU Affero General Public License
* along with this program; if not, write to:
* Free Software ... |
#include <opencog/atoms/base/Atom.h>
#include <opencog/atoms/base/ClassServer.h>
using namespace opencog;
/// Check to see if every input atom is of Evaluatable type.
bool check_evaluatable(const Handle& bool_atom)
{
for (const Handle& h: bool_atom->getOutgoingSet())
{
if (not h->is_type(EVALUATABLE_LINK)) retur... | opencog/atoms/core/Checkers.cc | C++ | 961d8ba3e631d3fbbbb6de91e98f63d5a9a7bbb5 | <|file_sep|>opencog/atoms/core/Checkers.cc.diff
original:
updated:
/// Check to see if every input atom is of Evaluatable type.
<|file_sep|>original/opencog/atoms/core/Checkers.cc
* You should have received a copy of the GNU Affero General Public License
* along with this program; if not, write to:
* Free Software ... |
<|file_sep|>testbed/windows/runner/main.cpp.diff
original:
updated:
// Initialize COM, so that it is available for use in the library and/or plugins.
::CoInitializeEx(nullptr, COINIT_APARTMENTTHREADED);
<|file_sep|>original/testbed/windows/runner/main.cpp
}
RunLoop run_loop;
flutter::DartProject project(L... |
RunLoop run_loop;
flutter::DartProject project(L"data");
#ifndef _DEBUG
project.SetEngineSwitches({"--disable-dart-asserts"});
#endif
FlutterWindow window(&run_loop, project);
Win32Window::Point origin(kFlutterWindowOriginX, kFlutterWindowOriginY);
Win32Window::Size size(kFlutterWindowWidth, kFlutterWind... | testbed/windows/runner/main.cpp | C++ | 100bc306dd15532dbbb2b353170aea47e8173a13 | <|file_sep|>testbed/windows/runner/main.cpp.diff
original:
updated:
// Initialize COM, so that it is available for use in the library and/or plugins.
::CoInitializeEx(nullptr, COINIT_APARTMENTTHREADED);
<|file_sep|>original/testbed/windows/runner/main.cpp
}
RunLoop run_loop;
flutter::DartProject project(L... |
<|file_sep|>src/insert_mode.cc.diff
original:
updated:
contents.is_inserting = true;
<|file_sep|>src/insert_mode.cc.diff
original:
updated:
contents.is_inserting = false;
<|file_sep|>src/insert_mode.cc.diff
original:
updated:
contents.is_inserting = true;
<|file_sep|>original/src/insert_mode.cc
c... | print_contents(get_contents());
}
}
contents.is_inserting = false;
}
void enter_replace_mode(contents& contents, boost::optional<int>) {
char ch;
contents.is_inserting = true;
while((ch = getch()) != _escape) {
if(contents.x >= contents.cont[contents.y].size()) {
... | src/insert_mode.cc | C++ | e8fb48684147d54f5088194d644a1966c5421b86 | <|file_sep|>src/insert_mode.cc.diff
original:
updated:
contents.is_inserting = true;
<|file_sep|>src/insert_mode.cc.diff
original:
updated:
contents.is_inserting = false;
<|file_sep|>src/insert_mode.cc.diff
original:
updated:
contents.is_inserting = true;
<|file_sep|>original/src/insert_mode.cc
c... |
<|file_sep|>logicTest.cpp.diff
original:
updated:
std::cout << i << " {" << std::endl;
<|file_sep|>original/logicTest.cpp
int rotationTest( void )
{
for( int i = 0; i < 5; ++i )
{
auto b1 = new block( i );
printCoords( b1 );
b1->rotate();
printCoords( b1 );
b1->rotate(... | auto b1 = new block( i );
std::cout << i << " {" << std::endl;
printCoords( b1 );
b1->rotate();
printCoords( b1 );
b1->rotate();
printCoords( b1 );
b1->rotate();
printCoords( b1 );
b1->rotate();
printCoords( b1 );
std::cout << "}" << std::... | logicTest.cpp | C++ | af7ba3b71fcbda1ee1bef496c712da65712574d3 | <|file_sep|>logicTest.cpp.diff
original:
updated:
std::cout << i << " {" << std::endl;
<|file_sep|>original/logicTest.cpp
int rotationTest( void )
{
for( int i = 0; i < 5; ++i )
{
auto b1 = new block( i );
printCoords( b1 );
b1->rotate();
printCoords( b1 );
b1->rotate(... |
<|file_sep|>src/searchclient/dlgfilters.cpp.diff
original:
updated:
#include <QLabel>
<|file_sep|>src/searchclient/dlgfilters.cpp.diff
original:
updated:
QLabel* explanation = new QLabel(tr("Define filters that determine which files will be included and which will be excluded from the index, e.g. '*.html' or '.sv... | QLabel* explanation = new QLabel(tr("Define filters that determine which files will be included and which will be excluded from the index, e.g. '*.html' or '.svn/' (do not index directories called '.svn')."));
explanation->setWordWrap(true);
filterwidget = new FilterWidget();
filterwidget->setFilters(fi... | src/searchclient/dlgfilters.cpp | C++ | 250a86dc4041f75488d78653d9566b348e1b70c9 | <|file_sep|>src/searchclient/dlgfilters.cpp.diff
original:
updated:
#include <QLabel>
<|file_sep|>src/searchclient/dlgfilters.cpp.diff
original:
updated:
QLabel* explanation = new QLabel(tr("Define filters that determine which files will be included and which will be excluded from the index, e.g. '*.html' or '.sv... |
<|file_sep|>src/floaxietest.cpp.diff
original:
updated:
#if __cplusplus >= 201402L
<|file_sep|>original/src/floaxietest.cpp
#include "test.h"
#include "floaxie/ftoa.h"
void dtoa_floaxie(double v, char* buffer)
{
floaxie::ftoa(v, buffer);
}
REGISTER_TEST(floaxie);
<|file_sep|>current/src/floaxietest.cpp
#if __cplus... | #if __cplusplus >= 201402L
#include "test.h"
#include "floaxie/ftoa.h"
void dtoa_floaxie(double v, char* buffer)
{
floaxie::ftoa(v, buffer);
}
REGISTER_TEST(floaxie);
#endif | src/floaxietest.cpp | C++ | 9709d7c0d15f61f6df20c6614476ed725da9b5bc | <|file_sep|>src/floaxietest.cpp.diff
original:
updated:
#if __cplusplus >= 201402L
<|file_sep|>original/src/floaxietest.cpp
#include "test.h"
#include "floaxie/ftoa.h"
void dtoa_floaxie(double v, char* buffer)
{
floaxie::ftoa(v, buffer);
}
REGISTER_TEST(floaxie);
<|file_sep|>current/src/floaxietest.cpp
#if __cplus... |
<|file_sep|>notebooktree.cpp.diff
original:
updated:
#include <QHeaderView>
<|file_sep|>original/notebooktree.cpp
#include "notebooktree.h"
#include "treenotebookitem.h"
#include "treenotebookpageitem.h"
#include "notebookexception.h"
NotebookTree::NotebookTree(QWidget* parent) :
QTreeWidget(parent)
{
this->... | #include "treenotebookitem.h"
#include "treenotebookpageitem.h"
#include "notebookexception.h"
#include <QHeaderView>
NotebookTree::NotebookTree(QWidget* parent) :
QTreeWidget(parent)
{
this->setColumnCount(1);
this->header()->hide();
}
void NotebookTree::addNotebook(Notebook& notebook)
{
TreeNoteboo... | notebooktree.cpp | C++ | 739b903d8e5444d8dc19361fb1057f6821382c37 | <|file_sep|>notebooktree.cpp.diff
original:
updated:
#include <QHeaderView>
<|file_sep|>original/notebooktree.cpp
#include "notebooktree.h"
#include "treenotebookitem.h"
#include "treenotebookpageitem.h"
#include "notebookexception.h"
NotebookTree::NotebookTree(QWidget* parent) :
QTreeWidget(parent)
{
this->... |
<|file_sep|>Podrios.cpp.diff
original:
updated:
#include <stdlib.h>
<|file_sep|>original/Podrios.cpp
/*
* Podrios.cpp
*
* Created on: 2014年10月23日
* Author: nemo
*/
#include <iostream>
using namespace std;
int main()
{
cout << "Show Message." << endl;
return 0;
}
<|file_sep|>current/Podrios.cpp
/*
*... | /*
* Podrios.cpp
*
* Created on: 2014年10月23日
* Author: nemo
*/
#include <iostream>
#include <stdlib.h>
using namespace std;
int main()
{
cout << "Show Message." << endl;
system("pause");
return 0;
} | Podrios.cpp | C++ | d40a92f3ad086b71d0df4bca5a2d615c8b8cb380 | <|file_sep|>Podrios.cpp.diff
original:
updated:
#include <stdlib.h>
<|file_sep|>original/Podrios.cpp
/*
* Podrios.cpp
*
* Created on: 2014年10月23日
* Author: nemo
*/
#include <iostream>
using namespace std;
int main()
{
cout << "Show Message." << endl;
return 0;
}
<|file_sep|>current/Podrios.cpp
/*
*... |
<|file_sep|>libeve-api-proxy/source/Error.cpp.diff
original:
updated:
#ifdef _WIN32
<|file_sep|>original/libeve-api-proxy/source/Error.cpp
#include "Precompiled.hpp"
#include "Error.hpp"
#include "SmartPtr.hpp"
#include "String.hpp"
std::string errno_string(int err)
{
char buffer[1024];
if (!strerror_s(buffer... | #include "SmartPtr.hpp"
#include "String.hpp"
std::string errno_string(int err)
{
char buffer[1024];
#ifdef _WIN32
if (!strerror_s(buffer, sizeof(buffer), err)) throw std::runtime_error("strerror_s failed");
return buffer;
#else
return strerror_r(err, buffer, sizeof(buffer));
#endif
}
#ifdef _WIN32
s... | libeve-api-proxy/source/Error.cpp | C++ | 86b112bfa96f8e2b1771f708c3f4aabc4a0b1e94 | <|file_sep|>libeve-api-proxy/source/Error.cpp.diff
original:
updated:
#ifdef _WIN32
<|file_sep|>original/libeve-api-proxy/source/Error.cpp
#include "Precompiled.hpp"
#include "Error.hpp"
#include "SmartPtr.hpp"
#include "String.hpp"
std::string errno_string(int err)
{
char buffer[1024];
if (!strerror_s(buffer... |
<|file_sep|>main.cpp.diff
original:
updated:
#include <iostream>
<|file_sep|>original/main.cpp
#include <fstream>
using namespace std;
int main(int argc, char *argv[])
{
const string task_fname = "task_list.txt";
const size_t concurrency = 2;
ifstream task_stream{task_fname};
TaskListSimple task_lis... | using namespace std;
int main(int argc, char *argv[])
{
const string task_fname = "task_list.txt";
const size_t concurrency = 2;
ifstream task_stream{task_fname};
if ( !task_stream.is_open() )
{
cout << "Can`t open <" << task_fname << ">, break." << endl;
return 1;
}
TaskLi... | main.cpp | C++ | b6c95361843cea1a16e6a1287ce247987b668b2b | <|file_sep|>main.cpp.diff
original:
updated:
#include <iostream>
<|file_sep|>original/main.cpp
#include <fstream>
using namespace std;
int main(int argc, char *argv[])
{
const string task_fname = "task_list.txt";
const size_t concurrency = 2;
ifstream task_stream{task_fname};
TaskListSimple task_lis... |
<|file_sep|>ouzel/android/WindowAndroid.cpp.diff
original:
updated:
#include "Engine.h"
#include "opengl/RendererOGL.h"
<|file_sep|>original/ouzel/android/WindowAndroid.cpp
#include "WindowAndroid.h"
namespace ouzel
{
WindowAndroid::WindowAndroid(const Size2& pSize, bool pResizable, bool pFullscreen, uint32_t pS... | {
WindowAndroid::WindowAndroid(const Size2& pSize, bool pResizable, bool pFullscreen, uint32_t pSampleCount, const std::string& pTitle):
Window(pSize, pResizable, pFullscreen, pSampleCount, pTitle)
{
}
WindowAndroid::~WindowAndroid()
{
}
bool WindowAndroid::init()
{
s... | ouzel/android/WindowAndroid.cpp | C++ | 40d965d75defd95662f70a3ed24d99ed7fa343aa | <|file_sep|>ouzel/android/WindowAndroid.cpp.diff
original:
updated:
#include "Engine.h"
#include "opengl/RendererOGL.h"
<|file_sep|>original/ouzel/android/WindowAndroid.cpp
#include "WindowAndroid.h"
namespace ouzel
{
WindowAndroid::WindowAndroid(const Size2& pSize, bool pResizable, bool pFullscreen, uint32_t pS... |
<|file_sep|>PlasMOUL/Messages/SimulationMsg.cpp.diff
original:
updated:
MOUL::Message::read(stream);
<|file_sep|>original/PlasMOUL/Messages/SimulationMsg.cpp
* *
* dirtsand is distributed in the hope that it will be useful, ... | * but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
* GNU Affero General Public License for more details. *
* *
... | PlasMOUL/Messages/SimulationMsg.cpp | C++ | a7b06e5ad2147752b7e0a82c0c37778c72def66e | <|file_sep|>PlasMOUL/Messages/SimulationMsg.cpp.diff
original:
updated:
MOUL::Message::read(stream);
<|file_sep|>original/PlasMOUL/Messages/SimulationMsg.cpp
* *
* dirtsand is distributed in the hope that it will be useful, ... |
<|file_sep|>server/analyzer.cpp.diff
original:
updated:
DLOG(INFO) << "Starting analysis " << name;
DLOG(INFO) << "Getting facts for " << name;
<|file_sep|>server/analyzer.cpp.diff
original:
updated:
DLOG(INFO) << "Got facts for " << name;
<|file_sep|>original/server/analyzer.cpp
auto dfs = res.getDer... | bool dirty = false;
if (dal->setFacts(dfs) != 0) {
dirty = true;
}
cache.add(ctx);
return dirty;
});
}
return kj::Promise<bool>(false);
};
return kj::joinPromises(kj::mv(analResults)).then([this](kj::Array<bool> x){
bool dirty =... | server/analyzer.cpp | C++ | cbb0fd9cff4a5b73f3b2498e4ca21831892c723e | <|file_sep|>server/analyzer.cpp.diff
original:
updated:
DLOG(INFO) << "Starting analysis " << name;
DLOG(INFO) << "Getting facts for " << name;
<|file_sep|>server/analyzer.cpp.diff
original:
updated:
DLOG(INFO) << "Got facts for " << name;
<|file_sep|>original/server/analyzer.cpp
auto dfs = res.getDer... |
<|file_sep|>src/gtest/main.cpp.diff
original:
updated:
#include "sodium.h"
<|file_sep|>original/src/gtest/main.cpp
#include "gtest/gtest.h"
int main(int argc, char **argv) {
testing::InitGoogleTest(&argc, argv);
return RUN_ALL_TESTS();
}
<|file_sep|>current/src/gtest/main.cpp
#include "gtest/gtest.h"
#include "so... | #include "gtest/gtest.h"
#include "sodium.h"
int main(int argc, char **argv) {
assert(sodium_init() != -1);
testing::InitGoogleTest(&argc, argv);
return RUN_ALL_TESTS();
} | src/gtest/main.cpp | C++ | c75d6bd0fad60e1ab6421b481d5eb575f4a5ce3e | <|file_sep|>src/gtest/main.cpp.diff
original:
updated:
#include "sodium.h"
<|file_sep|>original/src/gtest/main.cpp
#include "gtest/gtest.h"
int main(int argc, char **argv) {
testing::InitGoogleTest(&argc, argv);
return RUN_ALL_TESTS();
}
<|file_sep|>current/src/gtest/main.cpp
#include "gtest/gtest.h"
#include "so... |
<|file_sep|>windows/src/InitialExperience/SdkModel/WindowsInitialExperienceModule.cpp.diff
original:
updated:
#include "WorldPinVisibility.h"
<|file_sep|>original/windows/src/InitialExperience/SdkModel/WindowsInitialExperienceModule.cpp
//, m_pInitialExperienceSearchResultAttractModeModule(NULL)
... |
}
WindowsInitialExperienceModule::~WindowsInitialExperienceModule()
{
//Eegeo_DELETE m_pInitialExperienceSearchResultAttractModeModule;
}
std::vector<IInitialExperienceStep*> WindowsInitialExperienceModule::CreateSteps(WorldAreaLoader::SdkMo... | windows/src/InitialExperience/SdkModel/WindowsInitialExperienceModule.cpp | C++ | 7b91b2c561c2cfbd28e465a29837db272a6b5137 | <|file_sep|>windows/src/InitialExperience/SdkModel/WindowsInitialExperienceModule.cpp.diff
original:
updated:
#include "WorldPinVisibility.h"
<|file_sep|>original/windows/src/InitialExperience/SdkModel/WindowsInitialExperienceModule.cpp
//, m_pInitialExperienceSearchResultAttractModeModule(NULL)
... |
<|file_sep|>media/base/run_all_unittests.cc.diff
original:
updated:
#include "base/test/main_hook.h"
<|file_sep|>original/media/base/run_all_unittests.cc
#include "media/base/media.h"
class TestSuiteNoAtExit : public base::TestSuite {
public:
TestSuiteNoAtExit(int argc, char** argv) : TestSuite(argc, argv) {}
vi... |
class TestSuiteNoAtExit : public base::TestSuite {
public:
TestSuiteNoAtExit(int argc, char** argv) : TestSuite(argc, argv) {}
virtual ~TestSuiteNoAtExit() {}
protected:
virtual void Initialize();
};
void TestSuiteNoAtExit::Initialize() {
// Run TestSuite::Initialize first so that logging is initialized.
... | media/base/run_all_unittests.cc | C++ | 88281950eed0e9fadba9d13fc68707068b5b5628 | <|file_sep|>media/base/run_all_unittests.cc.diff
original:
updated:
#include "base/test/main_hook.h"
<|file_sep|>original/media/base/run_all_unittests.cc
#include "media/base/media.h"
class TestSuiteNoAtExit : public base::TestSuite {
public:
TestSuiteNoAtExit(int argc, char** argv) : TestSuite(argc, argv) {}
vi... |
<|file_sep|>Day2/Day2.cpp.diff
original:
updated:
uint64_t Ribbon = 0;
<|file_sep|>Day2/Day2.cpp.diff
original:
updated:
uint32_t LargestDimension = std::max({ l, w, h });
<|file_sep|>Day2/Day2.cpp.diff
original:
updated:
Ribbon += l * w * h + 2 * l + 2 * w + 2 * h - 2 * LargestDimension;
<|file_sep|>original/D... | uint32_t Side1 = l * w;
uint32_t Side2 = h * w;
uint32_t Side3 = l * h;
uint32_t SmallestSide = std::min({ Side1, Side2, Side3 });
uint32_t LargestDimension = std::max({ l, w, h });
WrappingPaper += SmallestSide + 2 * Side1 + 2 * Side2 + 2 * Side3;
Ribbon += l * w * h + 2 * l + 2 * w + 2 * h - 2 * Large... | Day2/Day2.cpp | C++ | 16e678cc1869afdcffa0adffadfa4d6ce7b78d20 | <|file_sep|>Day2/Day2.cpp.diff
original:
updated:
uint64_t Ribbon = 0;
<|file_sep|>Day2/Day2.cpp.diff
original:
updated:
uint32_t LargestDimension = std::max({ l, w, h });
<|file_sep|>Day2/Day2.cpp.diff
original:
updated:
Ribbon += l * w * h + 2 * l + 2 * w + 2 * h - 2 * LargestDimension;
<|file_sep|>original/D... |
<|file_sep|>testing/test_single_agent_async_execute.cpp.diff
original:
updated:
assert(exec.valid());
<|file_sep|>original/testing/test_single_agent_async_execute.cpp
// returning int
executor_type exec;
auto f = agency::new_executor_traits<executor_type>::async_execute(exec, []
{
return 13... | // returning int
executor_type exec;
auto f = agency::new_executor_traits<executor_type>::async_execute(exec, []
{
return 13;
});
assert(f.get() == 13);
assert(exec.valid());
}
}
int main()
{
using namespace test_executors;
test<empty_executor>();
test<single_agent_when_al... | testing/test_single_agent_async_execute.cpp | C++ | 0fa689e5f7c4164088f9a3d474da286f0250a81c | <|file_sep|>testing/test_single_agent_async_execute.cpp.diff
original:
updated:
assert(exec.valid());
<|file_sep|>original/testing/test_single_agent_async_execute.cpp
// returning int
executor_type exec;
auto f = agency::new_executor_traits<executor_type>::async_execute(exec, []
{
return 13... |
<|file_sep|>config.tests/sensord/main.cpp.diff
original:
updated:
#include <abstractsensor.h>
#include <abstractsensor_i.h>
<|file_sep|>original/config.tests/sensord/main.cpp
#include <sensormanagerinterface.h>
#include <datatypes/magneticfield.h>
int main()
{
SensorManagerInterface* m_remoteSensorManager;
m_... | #include <sensormanagerinterface.h>
#include <datatypes/magneticfield.h>
#include <abstractsensor.h>
#include <abstractsensor_i.h>
int main()
{
SensorManagerInterface* m_remoteSensorManager;
m_remoteSensorManager = &SensorManagerInterface::instance();
QList<DataRange> (AbstractSensorChannelInterface::*func... | config.tests/sensord/main.cpp | C++ | a2a02703e2f3b3bb26081b605af62ac7309562a2 | <|file_sep|>config.tests/sensord/main.cpp.diff
original:
updated:
#include <abstractsensor.h>
#include <abstractsensor_i.h>
<|file_sep|>original/config.tests/sensord/main.cpp
#include <sensormanagerinterface.h>
#include <datatypes/magneticfield.h>
int main()
{
SensorManagerInterface* m_remoteSensorManager;
m_... |
<|file_sep|>src/test/fuzz/kitchen_sink.cpp.diff
original:
updated:
#include <rpc/util.h>
<|file_sep|>original/src/test/fuzz/kitchen_sink.cpp
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <test/fuzz/FuzzedDataProvider... | #include <rpc/util.h>
#include <test/fuzz/FuzzedDataProvider.h>
#include <test/fuzz/fuzz.h>
#include <test/fuzz/util.h>
#include <util/error.h>
#include <cstdint>
#include <vector>
// The fuzzing kitchen sink: Fuzzing harness for functions that need to be
// fuzzed but a.) don't belong in any existing fuzzing harness... | src/test/fuzz/kitchen_sink.cpp | C++ | e1e181fad1a73e9dee38a2bd74518e1b8d446930 | <|file_sep|>src/test/fuzz/kitchen_sink.cpp.diff
original:
updated:
#include <rpc/util.h>
<|file_sep|>original/src/test/fuzz/kitchen_sink.cpp
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <test/fuzz/FuzzedDataProvider... |
<|file_sep|>Dev/Cpp/Viewer/Utils/Logger.cpp.diff
original:
updated:
#if defined(_WIN32)
<|file_sep|>original/Dev/Cpp/Viewer/Utils/Logger.cpp
#include "Logger.h"
#include <Effekseer.h>
#include <filesystem>
#include <spdlog/sinks/basic_file_sink.h>
#include <spdlog/spdlog.h>
namespace Effekseer::Tool
{
void Logger::... | #include "Logger.h"
#include <Effekseer.h>
#if defined(_WIN32)
#include <filesystem>
#endif
#include <spdlog/sinks/basic_file_sink.h>
#include <spdlog/spdlog.h>
namespace Effekseer::Tool
{
void Logger::SetFileLogger(const char16_t* path)
{
spdlog::flush_on(spdlog::level::trace);
spdlog::set_level(spdlog::level::tr... | Dev/Cpp/Viewer/Utils/Logger.cpp | C++ | ee8a72f09fcadaaccd8df5e72fbd6afd81271082 | <|file_sep|>Dev/Cpp/Viewer/Utils/Logger.cpp.diff
original:
updated:
#if defined(_WIN32)
<|file_sep|>original/Dev/Cpp/Viewer/Utils/Logger.cpp
#include "Logger.h"
#include <Effekseer.h>
#include <filesystem>
#include <spdlog/sinks/basic_file_sink.h>
#include <spdlog/spdlog.h>
namespace Effekseer::Tool
{
void Logger::... |
<|file_sep|>projects/OG-Language/ServiceTest/stdafx.cpp.diff
original:
updated:
#include "Service/Service.h"
<|file_sep|>original/projects/OG-Language/ServiceTest/stdafx.cpp
/**
* Copyright (C) 2011 - present by OpenGamma Inc. and the OpenGamma group of companies
*
* Please see distribution for license.
*/
#inclu... | /**
* Copyright (C) 2011 - present by OpenGamma Inc. and the OpenGamma group of companies
*
* Please see distribution for license.
*/
#include "stdafx.h"
#include "Service/Service.h"
#ifndef __cplusplus_cli
int main (int argc, char **argv) {
if ((argc == 3) && !strcmp (argv[1], "jvm")) {
return ServiceTestJVM ... | projects/OG-Language/ServiceTest/stdafx.cpp | C++ | 0bb6d9499b42be340d03106dd1360cb505625059 | <|file_sep|>projects/OG-Language/ServiceTest/stdafx.cpp.diff
original:
updated:
#include "Service/Service.h"
<|file_sep|>original/projects/OG-Language/ServiceTest/stdafx.cpp
/**
* Copyright (C) 2011 - present by OpenGamma Inc. and the OpenGamma group of companies
*
* Please see distribution for license.
*/
#inclu... |
<|file_sep|>src/platform/qt/main.cpp.diff
original:
updated:
#ifdef BUILD_QT_MULTIMEDIA
<|file_sep|>original/src/platform/qt/main.cpp
/* Copyright (c) 2013-2014 Jeffrey Pfau
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
... | *
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "GBAApp.h"
#include "Window.h"
#ifdef QT_STATIC
#include <QtPlugin>
#ifdef _WIN32
Q_IMPORT_PLUGIN(QWin... | src/platform/qt/main.cpp | C++ | 59f101eb496401f64933d27e365346d03ac8c0a8 | <|file_sep|>src/platform/qt/main.cpp.diff
original:
updated:
#ifdef BUILD_QT_MULTIMEDIA
<|file_sep|>original/src/platform/qt/main.cpp
/* Copyright (c) 2013-2014 Jeffrey Pfau
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
... |
<|file_sep|>ui/message_center/message_center_util.cc.diff
original:
updated:
#if defined(OS_WIN) && defined(USE_AURA)
return false;
#else
<|file_sep|>original/ui/message_center/message_center_util.cc
// Copyright (c) 2013 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-styl... | // Copyright (c) 2013 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.
#include "ui/message_center/message_center_util.h"
#include "base/command_line.h"
#include "ui/message_center/message_center_switches.h"
namespace m... | ui/message_center/message_center_util.cc | C++ | 4f7aa49682010bf86ce82cc8d88d411d8a28ff2f | <|file_sep|>ui/message_center/message_center_util.cc.diff
original:
updated:
#if defined(OS_WIN) && defined(USE_AURA)
return false;
#else
<|file_sep|>original/ui/message_center/message_center_util.cc
// Copyright (c) 2013 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-styl... |
<|file_sep|>chrome/browser/ui/crypto_module_password_dialog_openssl.cc.diff
original:
updated:
gfx::NativeWindow parent,
<|file_sep|>original/chrome/browser/ui/crypto_module_password_dialog_openssl.cc
#include "base/logging.h"
namespace chrome {
void UnlockSlotsIfNecessary(const net::Cryp... | namespace chrome {
void UnlockSlotsIfNecessary(const net::CryptoModuleList& modules,
CryptoModulePasswordReason reason,
const std::string& host,
gfx::NativeWindow parent,
const base::Closure& callback) {
/... | chrome/browser/ui/crypto_module_password_dialog_openssl.cc | C++ | 08596f12bd48f1dd2d4958eed84cbb8c4d275e5d | <|file_sep|>chrome/browser/ui/crypto_module_password_dialog_openssl.cc.diff
original:
updated:
gfx::NativeWindow parent,
<|file_sep|>original/chrome/browser/ui/crypto_module_password_dialog_openssl.cc
#include "base/logging.h"
namespace chrome {
void UnlockSlotsIfNecessary(const net::Cryp... |
<|file_sep|>mojo/common/user_agent.cc.diff
original:
updated:
#include "build/build_config.h"
<|file_sep|>mojo/common/user_agent.cc.diff
original:
updated:
#if defined(OS_ANDROID)
return "Mozilla/5.0 (Linux; Android 5.1.1; Nexus 7 Build/LMY48G) "
"AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.68... | #include "mojo/common/user_agent.h"
#include "build/build_config.h"
namespace mojo {
namespace common {
std::string GetUserAgent() {
// TODO(jam): change depending on OS
#if defined(OS_ANDROID)
return "Mozilla/5.0 (Linux; Android 5.1.1; Nexus 7 Build/LMY48G) "
"AppleWebKit/537.36 (KHTML, like Gecko) Chr... | mojo/common/user_agent.cc | C++ | e9f3b858148ac4b1bde0e06698861cae7c6cd7eb | <|file_sep|>mojo/common/user_agent.cc.diff
original:
updated:
#include "build/build_config.h"
<|file_sep|>mojo/common/user_agent.cc.diff
original:
updated:
#if defined(OS_ANDROID)
return "Mozilla/5.0 (Linux; Android 5.1.1; Nexus 7 Build/LMY48G) "
"AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.68... |
<|file_sep|>fuzz/oss_fuzz/FuzzAPISVGCanvas.cpp.diff
original:
updated:
#include "src/core/SkFontMgrPriv.h"
#include "tools/fonts/TestFontMgr.h"
<|file_sep|>original/fuzz/oss_fuzz/FuzzAPISVGCanvas.cpp
/*
* Copyright 2020 Google, LLC
*
* Use of this source code is governed by a BSD-style license that can be
* found ... | /*
* Copyright 2020 Google, LLC
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#include "fuzz/Fuzz.h"
#include "src/core/SkFontMgrPriv.h"
#include "tools/fonts/TestFontMgr.h"
void fuzz_SVGCanvas(Fuzz* f);
extern "C" int LLVMFuzzerTestOneInput(const uin... | fuzz/oss_fuzz/FuzzAPISVGCanvas.cpp | C++ | babba97ae63a2d8de425c7cc3926d5824f647b9c | <|file_sep|>fuzz/oss_fuzz/FuzzAPISVGCanvas.cpp.diff
original:
updated:
#include "src/core/SkFontMgrPriv.h"
#include "tools/fonts/TestFontMgr.h"
<|file_sep|>original/fuzz/oss_fuzz/FuzzAPISVGCanvas.cpp
/*
* Copyright 2020 Google, LLC
*
* Use of this source code is governed by a BSD-style license that can be
* found ... |
<|file_sep|>content/app/mojo/mojo_init.cc.diff
original:
updated:
#include "mojo/edk/embedder/configuration.h"
<|file_sep|>original/content/app/mojo/mojo_init.cc
// Copyright 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENS... |
#include "content/app/mojo/mojo_init.h"
#include "base/memory/scoped_ptr.h"
#include "mojo/edk/embedder/configuration.h"
#include "mojo/edk/embedder/embedder.h"
#include "mojo/edk/embedder/simple_platform_support.h"
namespace content {
void InitializeMojo() {
// Things like content_shell and DevTools ocassionally... | content/app/mojo/mojo_init.cc | C++ | 872df152e57fe8ba6ebf668531147e482ca4f73f | <|file_sep|>content/app/mojo/mojo_init.cc.diff
original:
updated:
#include "mojo/edk/embedder/configuration.h"
<|file_sep|>original/content/app/mojo/mojo_init.cc
// Copyright 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENS... |
<|file_sep|>athena/content/content_activity_factory.cc.diff
original:
updated:
#include "ui/aura/window.h"
<|file_sep|>athena/content/content_activity_factory.cc.diff
original:
updated:
activity->GetWindow()->SetName("WebActivity");
<|file_sep|>original/athena/content/content_activity_factory.cc
Activity* ContentA... | Activity* ContentActivityFactory::CreateWebActivity(
content::WebContents* contents) {
Activity* activity = new WebActivity(contents);
ActivityManager::Get()->AddActivity(activity);
return activity;
}
Activity* ContentActivityFactory::CreateAppActivity(
const std::string& app_id,
views::WebView* web_... | athena/content/content_activity_factory.cc | C++ | 9980f312b6216fb29a7ec981306ed47ce92aa98e | <|file_sep|>athena/content/content_activity_factory.cc.diff
original:
updated:
#include "ui/aura/window.h"
<|file_sep|>athena/content/content_activity_factory.cc.diff
original:
updated:
activity->GetWindow()->SetName("WebActivity");
<|file_sep|>original/athena/content/content_activity_factory.cc
Activity* ContentA... |
<|file_sep|>tools/evm2wasm/main.cpp.diff
original:
updated:
#include <algorithm>
<|file_sep|>original/tools/evm2wasm/main.cpp
}
ifstream input(argv[1]);
if (!input.is_open()) {
cerr << "File not found: " << argv[1] << endl;
return 1;
}
string str(
(std::istreambuf_iterator... | if (!input.is_open()) {
cerr << "File not found: " << argv[1] << endl;
return 1;
}
string str(
(std::istreambuf_iterator<char>(input)),
std::istreambuf_iterator<char>()
);
// clean input of any whitespace (including space and new lines)
str.erase(remove_if(str.b... | tools/evm2wasm/main.cpp | C++ | fd10725688a0580fec6f74b8f48b3ea13d16e5ba | <|file_sep|>tools/evm2wasm/main.cpp.diff
original:
updated:
#include <algorithm>
<|file_sep|>original/tools/evm2wasm/main.cpp
}
ifstream input(argv[1]);
if (!input.is_open()) {
cerr << "File not found: " << argv[1] << endl;
return 1;
}
string str(
(std::istreambuf_iterator... |
<|file_sep|>src/Dummy.cpp.diff
original:
updated:
#include <boost/asio.hpp>
<|file_sep|>original/src/Dummy.cpp
#include <iostream>
int main () {
std::cout << "Hello word!" << std::endl;
}
<|file_sep|>current/src/Dummy.cpp
#include <iostream>
#include <boost/asio.hpp>
int main () {
std::cout << "Hello word!" ... | #include <iostream>
#include <boost/asio.hpp>
int main () {
boost::asio::io_service io_dummy;
boost::asio::deadline_timer t(io_dummy, boost::posix_time::seconds(5));
t.wait();
std::cout << "Hello word!" << std::endl;
} | src/Dummy.cpp | C++ | 5829f2561be162e8f44a7ba2b9962c80372e153c | <|file_sep|>src/Dummy.cpp.diff
original:
updated:
#include <boost/asio.hpp>
<|file_sep|>original/src/Dummy.cpp
#include <iostream>
int main () {
std::cout << "Hello word!" << std::endl;
}
<|file_sep|>current/src/Dummy.cpp
#include <iostream>
#include <boost/asio.hpp>
int main () {
std::cout << "Hello word!" ... |
<|file_sep|>src/manipulator/pattern_posture_generator/src/pattern_posture_generator_node.cpp.diff
original:
updated:
ROS_INFO("Ready. getPostureKey");
<|file_sep|>src/manipulator/pattern_posture_generator/src/pattern_posture_generator_node.cpp.diff
original:
updated:
ROS_INFO("Get map of patterns parent");
<|file... | PatternPostureGenerator::PatternPostureGenerator(){}
PatternPostureGenerator::PatternPostureGenerator(ros::NodeHandle& nh) {
if (!nh.getParam("pattern", pattern_names)) return;
ROS_INFO("Get map of patterns parent");
for (std::map<std::string, std::string >::iterator it = pattern_names.begin();
it != patt... | src/manipulator/pattern_posture_generator/src/pattern_posture_generator_node.cpp | C++ | 8020136efeaceb6e6d54fe6036446874c596e218 | <|file_sep|>src/manipulator/pattern_posture_generator/src/pattern_posture_generator_node.cpp.diff
original:
updated:
ROS_INFO("Ready. getPostureKey");
<|file_sep|>src/manipulator/pattern_posture_generator/src/pattern_posture_generator_node.cpp.diff
original:
updated:
ROS_INFO("Get map of patterns parent");
<|file... |
<|file_sep|>src/main.cpp.diff
original:
updated:
a.setApplicationName("Humbug Desktop");
a.setApplicationVersion("0.1");
<|file_sep|>original/src/main.cpp
#include "HumbugWindow.h"
#include <QApplication>
int main(int argc, char *argv[])
{
QApplication a(argc, argv);
HumbugWindow w;
if (argc == 3... | #include "HumbugWindow.h"
#include <QApplication>
int main(int argc, char *argv[])
{
QApplication a(argc, argv);
a.setApplicationName("Humbug Desktop");
a.setApplicationVersion("0.1");
HumbugWindow w;
if (argc == 3 && QString(argv[1]) == QString("--site")) {
w.setUrl(QUrl(argv[2]));
}
... | src/main.cpp | C++ | 71e2dd4cd4bf56c926ae431b84e77f5c7d6a18a2 | <|file_sep|>src/main.cpp.diff
original:
updated:
a.setApplicationName("Humbug Desktop");
a.setApplicationVersion("0.1");
<|file_sep|>original/src/main.cpp
#include "HumbugWindow.h"
#include <QApplication>
int main(int argc, char *argv[])
{
QApplication a(argc, argv);
HumbugWindow w;
if (argc == 3... |
<|file_sep|>src/common/species_dialog.cc.diff
original:
updated:
accept();
<|file_sep|>src/common/species_dialog.cc.diff
original:
updated:
reject();
<|file_sep|>src/common/species_dialog.cc.diff
original:
updated:
QListWidgetItem *current = ui_->subspeciesList->currentItem();
if(current != nullptr) {
de... |
void SpeciesDialog::on_removeSubspecies_clicked() {
QListWidgetItem *current = ui_->subspeciesList->currentItem();
if(current != nullptr) {
delete current;
}
}
void SpeciesDialog::on_addSubspecies_clicked() {
QListWidgetItem *item = new QListWidgetItem("New subspecies");
item->setFlags(item->flags() | Q... | src/common/species_dialog.cc | C++ | 84edc6edeca2d5534c12a87df90cd684dfe9918d | <|file_sep|>src/common/species_dialog.cc.diff
original:
updated:
accept();
<|file_sep|>src/common/species_dialog.cc.diff
original:
updated:
reject();
<|file_sep|>src/common/species_dialog.cc.diff
original:
updated:
QListWidgetItem *current = ui_->subspeciesList->currentItem();
if(current != nullptr) {
de... |
<|file_sep|>source/tools/cgwhite/main.cpp.diff
original:
updated:
#include <widgetzeug/dark_fusion_style.hpp>
<|file_sep|>original/source/tools/cgwhite/main.cpp
#if defined(WIN32) && !defined(_DEBUG)
#pragma comment(linker, "/SUBSYSTEM:WINDOWS /entry:mainCRTStartup")
#endif
#include "Application.h"
#include <memor... |
#include "Application.h"
#include <memory>
#include <gloperate-qtapplication/Viewer.h>
#include <widgetzeug/dark_fusion_style.hpp>
int main(int argc, char * argv[])
{
Application app(argc, argv);
widgetzeug::enableDarkFusionStyle();
std::unique_ptr<gloperate_qtapplication::Viewer> viewer(new glopera... | source/tools/cgwhite/main.cpp | C++ | 4945f164e58cbc6952225289add67b9632669ddb | <|file_sep|>source/tools/cgwhite/main.cpp.diff
original:
updated:
#include <widgetzeug/dark_fusion_style.hpp>
<|file_sep|>original/source/tools/cgwhite/main.cpp
#if defined(WIN32) && !defined(_DEBUG)
#pragma comment(linker, "/SUBSYSTEM:WINDOWS /entry:mainCRTStartup")
#endif
#include "Application.h"
#include <memor... |
<|file_sep|>2DXngine.Test/src/Integration_Tiled/ParseMapTest.cc.diff
original:
updated:
TEST_F(TiledFixture, map_should_have_TestObject_parsed)
{
auto group = _parsedMap->getObjectGroup("TestObject");
<|file_sep|>original/2DXngine.Test/src/Integration_Tiled/ParseMapTest.cc
#include "gtest\gtest.h"
#include "TiledF... |
TEST_F(TiledFixture, map_attributes_should_be_parsed)
{
ASSERT_EQ("1.0", _parsedMap->get_version());
ASSERT_EQ("1.0.3", _parsedMap->get_tiledVersion());
ASSERT_EQ(Orientation::ORTOGNAL, _parsedMap->get_orientation());
ASSERT_EQ(RenderOrder::RIGHT_DOWN, _parsedMap->get_renderOrder());
ASSERT_EQ(10,... | 2DXngine.Test/src/Integration_Tiled/ParseMapTest.cc | C++ | f7550e46ef84d35f05abb94c993d52b75af0a51c | <|file_sep|>2DXngine.Test/src/Integration_Tiled/ParseMapTest.cc.diff
original:
updated:
TEST_F(TiledFixture, map_should_have_TestObject_parsed)
{
auto group = _parsedMap->getObjectGroup("TestObject");
<|file_sep|>original/2DXngine.Test/src/Integration_Tiled/ParseMapTest.cc
#include "gtest\gtest.h"
#include "TiledF... |
<|file_sep|>QGVCore/private/QGVGraphPrivate.cpp.diff
original:
updated:
: _graph (NULL)
<|file_sep|>original/QGVCore/private/QGVGraphPrivate.cpp
#include "QGVGraphPrivate.h"
QGVGraphPrivate::QGVGraphPrivate(Agraph_t *graph)
{
setGraph(graph);
}
void QGVGraphPrivate::setGraph(Agraph_t *graph)
{
_graph = graph;
}
... | #include "QGVGraphPrivate.h"
QGVGraphPrivate::QGVGraphPrivate(Agraph_t *graph)
: _graph (NULL)
{
setGraph(graph);
}
void QGVGraphPrivate::setGraph(Agraph_t *graph)
{
if (_graph != NULL)
agclose(_graph);
_graph = graph;
}
Agraph_t* QGVGraphPrivate::graph() const
{
return _graph;
} | QGVCore/private/QGVGraphPrivate.cpp | C++ | bb33a8368a002e643dbcb9d8a43ce3bec31baa1e | <|file_sep|>QGVCore/private/QGVGraphPrivate.cpp.diff
original:
updated:
: _graph (NULL)
<|file_sep|>original/QGVCore/private/QGVGraphPrivate.cpp
#include "QGVGraphPrivate.h"
QGVGraphPrivate::QGVGraphPrivate(Agraph_t *graph)
{
setGraph(graph);
}
void QGVGraphPrivate::setGraph(Agraph_t *graph)
{
_graph = graph;
}
... |
<|file_sep|>es-general/Registration.cpp.diff
original:
updated:
#include "comp/StaticRandom.hpp"
<|file_sep|>original/es-general/Registration.cpp
{
// Register systems
registerSystem_ConstantRotation();
registerSystem_ClickBox2D();
// Register components
core.registerComponent<ConstantRotation>();
core.re... | // Register systems
registerSystem_ConstantRotation();
registerSystem_ClickBox2D();
// Register components
core.registerComponent<ConstantRotation>();
core.registerComponent<Transform>();
core.registerComponent<CameraSelect>();
core.registerComponent<ClickBox2D>();
core.registerComponent<StaticMouseI... | es-general/Registration.cpp | C++ | 8a9cbc1beeb7fba439fc9f434a45dae85e27daaf | <|file_sep|>es-general/Registration.cpp.diff
original:
updated:
#include "comp/StaticRandom.hpp"
<|file_sep|>original/es-general/Registration.cpp
{
// Register systems
registerSystem_ConstantRotation();
registerSystem_ClickBox2D();
// Register components
core.registerComponent<ConstantRotation>();
core.re... |
<|file_sep|>base/android/important_file_writer_android.cc.diff
original:
updated:
#include "base/threading/thread_restrictions.h"
<|file_sep|>original/base/android/important_file_writer_android.cc
#include "base/files/important_file_writer.h"
#include "jni/ImportantFileWriterAndroid_jni.h"
namespace base {
namespace ... | #include "jni/ImportantFileWriterAndroid_jni.h"
namespace base {
namespace android {
static jboolean WriteFileAtomically(JNIEnv* env,
jclass /* clazz */,
jstring file_name,
jbyteArray data) {
// This is calle... | base/android/important_file_writer_android.cc | C++ | 4ecbb8f86691102f2a1162677ce091d3de8c5888 | <|file_sep|>base/android/important_file_writer_android.cc.diff
original:
updated:
#include "base/threading/thread_restrictions.h"
<|file_sep|>original/base/android/important_file_writer_android.cc
#include "base/files/important_file_writer.h"
#include "jni/ImportantFileWriterAndroid_jni.h"
namespace base {
namespace ... |
<|file_sep|>alice4/software/touchscreen_tests/ts_test1.cpp.diff
original:
updated:
static bool dragging = false;
<|file_sep|>alice4/software/touchscreen_tests/ts_test1.cpp.diff
original:
updated:
if(dragging)
printf("ERROR: START WHILE ALREADY DRAGGING\n");
dragging = true;
<|file_sep|>alice4/software... | dragging = true;
break;
case TOUCHSCREEN_DRAG:
printf("drag %d %d %f\n", x, y, z);
if(!dragging)
printf("ERROR: DRAG WHILE NOT STARTED\n");
break;
case TOUCHSCREEN_STOP:
printf("stop\n");
if(!dragging)
printf("ERROR: STOP WHILE NOT STARTED\n");
dragging = false;... | alice4/software/touchscreen_tests/ts_test1.cpp | C++ | acf916b48b9f1dbe28392aa816a87cdd85157a63 | <|file_sep|>alice4/software/touchscreen_tests/ts_test1.cpp.diff
original:
updated:
static bool dragging = false;
<|file_sep|>alice4/software/touchscreen_tests/ts_test1.cpp.diff
original:
updated:
if(dragging)
printf("ERROR: START WHILE ALREADY DRAGGING\n");
dragging = true;
<|file_sep|>alice4/software... |
<|file_sep|>language.support/support.types/offsetof.pass.cpp.diff
original:
updated:
struct A
{
int x;
};
<|file_sep|>original/language.support/support.types/offsetof.pass.cpp
//===----------------------------------------------------------------------===//
//
// The LLVM Compiler Infrastructur... | // Source Licenses. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
#include <cstddef>
#ifndef offsetof
#error offsetof not defined
#endif
struct A
{
int x;
};
int main()
{
#if (__has_feature(cxx_noexcept))
static_assert(noexcept(offsetof(A, x... | language.support/support.types/offsetof.pass.cpp | C++ | cfa68bccf5b65ca4f2605dee5ffb371e3fc3af57 | <|file_sep|>language.support/support.types/offsetof.pass.cpp.diff
original:
updated:
struct A
{
int x;
};
<|file_sep|>original/language.support/support.types/offsetof.pass.cpp
//===----------------------------------------------------------------------===//
//
// The LLVM Compiler Infrastructur... |
<|file_sep|>src/placement/persistent_constraint_updater.cpp.diff
original:
updated:
#include <chrono>
#include <QLoggingCategory>
<|file_sep|>src/placement/persistent_constraint_updater.cpp.diff
original:
updated:
QLoggingCategory pcuChan("Placement.PersistentConstraintUpdater");
<|file_sep|>src/placement/persistent... | auto &placedLabel = placedLabelPair.second;
constraintUpdater->drawConstraintRegionFor(
anchorForBuffer, labelSizeForBuffer, placedLabel.anchorPosition,
placedLabel.labelPosition, placedLabel.size);
}
placedLabels[labelId] = PlacedLabelInfo{ labelSizeForBuffer, anchorForBuffer,
... | src/placement/persistent_constraint_updater.cpp | C++ | 3865fccd46223514c7ca8d23611571bf627875ab | <|file_sep|>src/placement/persistent_constraint_updater.cpp.diff
original:
updated:
#include <chrono>
#include <QLoggingCategory>
<|file_sep|>src/placement/persistent_constraint_updater.cpp.diff
original:
updated:
QLoggingCategory pcuChan("Placement.PersistentConstraintUpdater");
<|file_sep|>src/placement/persistent... |
<|file_sep|>Magick++/fuzz/encoder_fuzzer.cc.diff
original:
updated:
#define FUZZ_IMAGEMAGICK_ENCODER_WRITE 1
<|file_sep|>Magick++/fuzz/encoder_fuzzer.cc.diff
original:
updated:
#if FUZZ_IMAGEMAGICK_ENCODER_WRITE
<|file_sep|>original/Magick++/fuzz/encoder_fuzzer.cc
extern "C" int LLVMFuzzerTestOneInput(const uint8_t... | Magick::Image image;
image.magick(FUZZ_ENCODER);
image.fileName(std::string(FUZZ_ENCODER) + ":");
try {
image.read(blob);
}
catch (Magick::Exception &e) {
return 0;
}
#if FUZZ_IMAGEMAGICK_ENCODER_WRITE
Magick::Blob outBlob;
try {
image.write(&outBlob, FUZZ_ENCODER);
}
catch (Magick::... | Magick++/fuzz/encoder_fuzzer.cc | C++ | 4cc573a2327b81087eefb1eb70083486dacf58df | <|file_sep|>Magick++/fuzz/encoder_fuzzer.cc.diff
original:
updated:
#define FUZZ_IMAGEMAGICK_ENCODER_WRITE 1
<|file_sep|>Magick++/fuzz/encoder_fuzzer.cc.diff
original:
updated:
#if FUZZ_IMAGEMAGICK_ENCODER_WRITE
<|file_sep|>original/Magick++/fuzz/encoder_fuzzer.cc
extern "C" int LLVMFuzzerTestOneInput(const uint8_t... |
<|file_sep|>external/vulkancts/framework/vulkan/vkNoRenderDocUtil.cpp.diff
original:
updated:
DE_UNREF(instance);
<|file_sep|>original/external/vulkancts/framework/vulkan/vkNoRenderDocUtil.cpp
{
}
RenderDocUtil::~RenderDocUtil (void)
{
}
bool RenderDocUtil::isValid (void)
{
return false;
}
void RenderDocUtil::sta... |
RenderDocUtil::~RenderDocUtil (void)
{
}
bool RenderDocUtil::isValid (void)
{
return false;
}
void RenderDocUtil::startFrame (vk::VkInstance instance)
{
DE_UNREF(instance);
}
void RenderDocUtil::endFrame (vk::VkInstance instance)
{
DE_UNREF(instance);
}
} // vk | external/vulkancts/framework/vulkan/vkNoRenderDocUtil.cpp | C++ | f6d4c9d8c0ce4ec6d9487129f6c14ee5a3fbcf1f | <|file_sep|>external/vulkancts/framework/vulkan/vkNoRenderDocUtil.cpp.diff
original:
updated:
DE_UNREF(instance);
<|file_sep|>original/external/vulkancts/framework/vulkan/vkNoRenderDocUtil.cpp
{
}
RenderDocUtil::~RenderDocUtil (void)
{
}
bool RenderDocUtil::isValid (void)
{
return false;
}
void RenderDocUtil::sta... |
<|file_sep|>sandbox/linux/seccomp-bpf/trap_unittest.cc.diff
original:
updated:
#if !defined(THREAD_SANITIZER)
<|file_sep|>original/sandbox/linux/seccomp-bpf/trap_unittest.cc
#include "sandbox/linux/tests/unit_tests.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace sandbox {
namespace {
SANDBOX_TEST_ALLOW_... | #include "testing/gtest/include/gtest/gtest.h"
namespace sandbox {
namespace {
#if !defined(THREAD_SANITIZER)
SANDBOX_TEST_ALLOW_NOISE(Trap, SigSysAction) {
// This creates a global Trap instance, and registers the signal handler
// (Trap::SigSysAction).
Trap::Registry();
// Send SIGSYS to self. If signal ha... | sandbox/linux/seccomp-bpf/trap_unittest.cc | C++ | 6f76a1e81c7cd76d5c9c43dbd3b894e89c6a25d2 | <|file_sep|>sandbox/linux/seccomp-bpf/trap_unittest.cc.diff
original:
updated:
#if !defined(THREAD_SANITIZER)
<|file_sep|>original/sandbox/linux/seccomp-bpf/trap_unittest.cc
#include "sandbox/linux/tests/unit_tests.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace sandbox {
namespace {
SANDBOX_TEST_ALLOW_... |
<|file_sep|>Code/Apps/mpMyFirstApp.cpp.diff
original:
updated:
#include <boost/date_time/posix_time/posix_time.hpp>
#include <boost/filesystem/path.hpp>
<|file_sep|>original/Code/Apps/mpMyFirstApp.cpp
int main(int argc, char** argv)
{
#ifdef BUILD_Eigen
Eigen::MatrixXd m(2,2);
std::cout << "Printing 2x2 matrix .... | int main(int argc, char** argv)
{
#ifdef BUILD_Eigen
Eigen::MatrixXd m(2,2);
std::cout << "Printing 2x2 matrix ..." << m << std::endl;
#endif
#ifdef BUILD_Boost
std::cout << "Rounding to ... " << boost::math::round(0.123) << std::endl;
boost::posix_time::ptime startTime = boost::posix_time::second_clock::loca... | Code/Apps/mpMyFirstApp.cpp | C++ | b68ab1d5e02914932fa2f73100297e4c88821688 | <|file_sep|>Code/Apps/mpMyFirstApp.cpp.diff
original:
updated:
#include <boost/date_time/posix_time/posix_time.hpp>
#include <boost/filesystem/path.hpp>
<|file_sep|>original/Code/Apps/mpMyFirstApp.cpp
int main(int argc, char** argv)
{
#ifdef BUILD_Eigen
Eigen::MatrixXd m(2,2);
std::cout << "Printing 2x2 matrix .... |
<|file_sep|>src/vmm/src/lib/CxxAbi.cpp.diff
original:
updated:
#include <os/Board.h>
#include <cstdio>
<|file_sep|>original/src/vmm/src/lib/CxxAbi.cpp
#include <cstdlib>
extern "C" void __cxa_pure_virtual()
{
}
void* operator new(size_t size)
{
return malloc(size);
}
void* operator new[](size_t size)
{
return ma... | #include <os/Board.h>
#include <cstdio>
#include <cstdlib>
extern "C" void __cxa_pure_virtual()
{
printf("__cxa_pure_virtual() called. Probably a bad build.\n");
os::board::shutdown();
}
void* operator new(size_t size)
{
return malloc(size);
}
void* operator new[](size_t size)
{
return malloc(size);
}
| src/vmm/src/lib/CxxAbi.cpp | C++ | 067d9be9210df8fe7af40063295d175a91284f36 | <|file_sep|>src/vmm/src/lib/CxxAbi.cpp.diff
original:
updated:
#include <os/Board.h>
#include <cstdio>
<|file_sep|>original/src/vmm/src/lib/CxxAbi.cpp
#include <cstdlib>
extern "C" void __cxa_pure_virtual()
{
}
void* operator new(size_t size)
{
return malloc(size);
}
void* operator new[](size_t size)
{
return ma... |
<|file_sep|>framework/extensions.cpp.diff
original:
updated:
#include "extensions/geolocation.h"
<|file_sep|>original/framework/extensions.cpp
Extensions::Extensions(QWebView *webView) :
QObject(webView) {
m_frame = webView->page()->mainFrame();
connect(m_frame, SIGNAL(javaScriptWindowObjectCleared()), S... |
Extensions::Extensions(QWebView *webView) :
QObject(webView) {
m_frame = webView->page()->mainFrame();
connect(m_frame, SIGNAL(javaScriptWindowObjectCleared()), SLOT(attachExtensions()));
m_extensions["GapAccelerometer"] = new Accelerometer(this);
m_extensions["GapDebugConsole"] = new DebugConsol... | framework/extensions.cpp | C++ | 4f2258154251645d694823aed71827586a4c3a3e | <|file_sep|>framework/extensions.cpp.diff
original:
updated:
#include "extensions/geolocation.h"
<|file_sep|>original/framework/extensions.cpp
Extensions::Extensions(QWebView *webView) :
QObject(webView) {
m_frame = webView->page()->mainFrame();
connect(m_frame, SIGNAL(javaScriptWindowObjectCleared()), S... |
<|file_sep|>browser/browser_main_parts.cc.diff
original:
updated:
#include "ui/gfx/screen.h"
#include "ui/views/widget/desktop_aura/desktop_screen.h"
<|file_sep|>original/browser/browser_main_parts.cc
void BrowserMainParts::PreMainMessageLoopRun() {
browser_context_.reset(CreateBrowserContext());
browser_context_... |
void BrowserMainParts::PreMainMessageLoopRun() {
browser_context_.reset(CreateBrowserContext());
browser_context_->Initialize();
web_ui_controller_factory_.reset(
new WebUIControllerFactory(browser_context_.get()));
content::WebUIControllerFactory::RegisterFactory(
web_ui_controller_factory_.get()... | browser/browser_main_parts.cc | C++ | 38a0b27483c990eb504ffec0711202b0ba489f76 | <|file_sep|>browser/browser_main_parts.cc.diff
original:
updated:
#include "ui/gfx/screen.h"
#include "ui/views/widget/desktop_aura/desktop_screen.h"
<|file_sep|>original/browser/browser_main_parts.cc
void BrowserMainParts::PreMainMessageLoopRun() {
browser_context_.reset(CreateBrowserContext());
browser_context_... |
<|file_sep|>test/language.support/support.types/offsetof.pass.cpp.diff
original:
updated:
struct A
{
int x;
};
<|file_sep|>original/test/language.support/support.types/offsetof.pass.cpp
//===----------------------------------------------------------------------===//
//
// The LLVM Compiler Inf... | // Source Licenses. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
#include <cstddef>
#ifndef offsetof
#error offsetof not defined
#endif
struct A
{
int x;
};
int main()
{
#if (__has_feature(cxx_noexcept))
static_assert(noexcept(offsetof(A, x... | test/language.support/support.types/offsetof.pass.cpp | C++ | 71499ad1763cd977ad80fa92f3782971c7b4e14c | <|file_sep|>test/language.support/support.types/offsetof.pass.cpp.diff
original:
updated:
struct A
{
int x;
};
<|file_sep|>original/test/language.support/support.types/offsetof.pass.cpp
//===----------------------------------------------------------------------===//
//
// The LLVM Compiler Inf... |
<|file_sep|>src/zcash/GenerateParams.cpp.diff
original:
updated:
#include "sodium.h"
<|file_sep|>original/src/zcash/GenerateParams.cpp
#include "zcash/JoinSplit.hpp"
#include <iostream>
int main(int argc, char **argv)
{
if(argc != 3) {
std::cerr << "Usage: " << argv[0] << " provingKeyFileName verificatio... | #include "zcash/JoinSplit.hpp"
#include <iostream>
#include "sodium.h"
int main(int argc, char **argv)
{
if (sodium_init() == -1) {
return 1;
}
if(argc != 3) {
std::cerr << "Usage: " << argv[0] << " provingKeyFileName verificationKeyFileName" << std::endl;
return 1;
}
std... | src/zcash/GenerateParams.cpp | C++ | 1fad6b87e5076974168349cf2e28472922ec592c | <|file_sep|>src/zcash/GenerateParams.cpp.diff
original:
updated:
#include "sodium.h"
<|file_sep|>original/src/zcash/GenerateParams.cpp
#include "zcash/JoinSplit.hpp"
#include <iostream>
int main(int argc, char **argv)
{
if(argc != 3) {
std::cerr << "Usage: " << argv[0] << " provingKeyFileName verificatio... |
<|file_sep|>agent/src/main.cpp.diff
original:
updated:
#include "network/sniffer/SnifferManager.hpp"
<|file_sep|>original/agent/src/main.cpp
#include "controllers/main/MainModule.hpp"
#include "network/bsdsocket/Manager.hpp"
int main()
{
tin::controllers::main::ControllerQueue ctrlQueue;
tin::network::bsdsock... | #include "network/bsdsocket/Manager.hpp"
#include "network/sniffer/SnifferManager.hpp"
int main()
{
tin::controllers::main::ControllerQueue ctrlQueue;
tin::network::bsdsocket::ManagerQueue netManagerQueue;
tin::controllers::main::MainModule mainCtrl(ctrlQueue, netManagerQueue);
tin::network::bsdsocket... | agent/src/main.cpp | C++ | f70bad5dc97d7a4a2873e508887f4ad925d8cb0c | <|file_sep|>agent/src/main.cpp.diff
original:
updated:
#include "network/sniffer/SnifferManager.hpp"
<|file_sep|>original/agent/src/main.cpp
#include "controllers/main/MainModule.hpp"
#include "network/bsdsocket/Manager.hpp"
int main()
{
tin::controllers::main::ControllerQueue ctrlQueue;
tin::network::bsdsock... |
<|file_sep|>core/main.cpp.diff
original:
updated:
#include <memory/page.h>
<|file_sep|>original/core/main.cpp
/// @author Kuba Sejdak
/// @date 17.07.2016
///
/// @copyright This file is a part of cosmos OS. All rights reserved.
///
//////////////////////////////////////////////////////////////////////////... | ////////////////////////////////////////////////////////////////////////////////////////////////
#include <memory/allocator.h>
#include <memory/regions.h>
#include <memory/page.h>
using namespace Memory;
int main()
{
IAllocator::init();
MemoryRegions& regions = MemoryRegions::instance();
regions.count(... | core/main.cpp | C++ | 60d93b3d0632c467b1df55a50e33e5e46a2ef0bc | <|file_sep|>core/main.cpp.diff
original:
updated:
#include <memory/page.h>
<|file_sep|>original/core/main.cpp
/// @author Kuba Sejdak
/// @date 17.07.2016
///
/// @copyright This file is a part of cosmos OS. All rights reserved.
///
//////////////////////////////////////////////////////////////////////////... |
<|file_sep|>bullet_cpp/src/btBoost/btBoostWrapper.cpp.diff
original:
updated:
#include <btBoost/btBoostHello.hpp>
<|file_sep|>original/bullet_cpp/src/btBoost/btBoostWrapper.cpp
// File: btBoostWrapper.cpp
#ifndef _btBoostWrapper_cpp
#define _btBoostWrapper_cpp
#pragma GCC diagnostic ignored "-Wunused-variable"
#pragm... | #ifndef _btBoostWrapper_cpp
#define _btBoostWrapper_cpp
#pragma GCC diagnostic ignored "-Wunused-variable"
#pragma GCC diagnostic ignored "-Wreorder"
#include <boost/python.hpp>
#include <btBoost/btBoostLinearMath.hpp>
#include <btBoost/btBoostDynamics.hpp>
#include <btBoost/btBoostHello.hpp>
using namespace boost::... | bullet_cpp/src/btBoost/btBoostWrapper.cpp | C++ | bbe9665ee0c9eeef027945c5d1751cc47cfcecaf | <|file_sep|>bullet_cpp/src/btBoost/btBoostWrapper.cpp.diff
original:
updated:
#include <btBoost/btBoostHello.hpp>
<|file_sep|>original/bullet_cpp/src/btBoost/btBoostWrapper.cpp
// File: btBoostWrapper.cpp
#ifndef _btBoostWrapper_cpp
#define _btBoostWrapper_cpp
#pragma GCC diagnostic ignored "-Wunused-variable"
#pragm... |
<|file_sep|>test/matcherexception.cpp.diff
original:
updated:
#include <cstring>
<|file_sep|>test/matcherexception.cpp.diff
original:
updated:
REQUIRE_FALSE(strlen(e.what()) == 0);
<|file_sep|>original/test/matcherexception.cpp
}
TEST_CASE("Can be constructed from Rust error returned over FFI",
"[MatcherExceptio... | TEST_CASE("Can be constructed from Rust error returned over FFI",
"[MatcherException]")
{
SECTION("Attribute unavailable") {
const auto e = MatcherException::from_rust_error(
rs_get_test_attr_unavail_error());
REQUIRE(e.type() == MatcherException::Type::ATTRIB_UNAVAIL);
REQUIRE(e.info() == "test_attribute")... | test/matcherexception.cpp | C++ | e6a00522a394bec0866381e8241deced4ddb6191 | <|file_sep|>test/matcherexception.cpp.diff
original:
updated:
#include <cstring>
<|file_sep|>test/matcherexception.cpp.diff
original:
updated:
REQUIRE_FALSE(strlen(e.what()) == 0);
<|file_sep|>original/test/matcherexception.cpp
}
TEST_CASE("Can be constructed from Rust error returned over FFI",
"[MatcherExceptio... |
<|file_sep|>ReactCommon/fabric/components/root/RootShadowNode.cpp.diff
original:
updated:
#include <react/debug/SystraceSection.h>
<|file_sep|>original/ReactCommon/fabric/components/root/RootShadowNode.cpp
#include "RootShadowNode.h"
#include <react/components/view/conversions.h>
namespace facebook {
namespace reac... |
#include <react/components/view/conversions.h>
#include <react/debug/SystraceSection.h>
namespace facebook {
namespace react {
const char RootComponentName[] = "RootView";
void RootShadowNode::layout() {
SystraceSection s("RootShadowNode::layout");
ensureUnsealed();
layout(getProps()->layoutContext);
// Th... | ReactCommon/fabric/components/root/RootShadowNode.cpp | C++ | 3b4d6d5ef58bd6c66306152c5f62d9e09ebe1216 | <|file_sep|>ReactCommon/fabric/components/root/RootShadowNode.cpp.diff
original:
updated:
#include <react/debug/SystraceSection.h>
<|file_sep|>original/ReactCommon/fabric/components/root/RootShadowNode.cpp
#include "RootShadowNode.h"
#include <react/components/view/conversions.h>
namespace facebook {
namespace reac... |
<|file_sep|>test/SemaTemplate/default-expr-arguments.cpp.diff
original:
updated:
struct FD : F<int> { };
<|file_sep|>original/test/SemaTemplate/default-expr-arguments.cpp
f2(S());
f3(10);
f3(S()); // expected-note{{in instantiation of default argument for 'f3<struct S>' required here}}
}
template<typename T... | f3(S()); // expected-note{{in instantiation of default argument for 'f3<struct S>' required here}}
}
template<typename T> struct F {
F(T t = 10);
};
struct FD : F<int> { };
void g2() {
F<int> f;
FD fd;
}
template<typename T> struct G {
G(T) {}
};
void s(G<int> flags = 10) { }
| test/SemaTemplate/default-expr-arguments.cpp | C++ | 0b84a53412a6acac38e2d647d220ce7af851395e | <|file_sep|>test/SemaTemplate/default-expr-arguments.cpp.diff
original:
updated:
struct FD : F<int> { };
<|file_sep|>original/test/SemaTemplate/default-expr-arguments.cpp
f2(S());
f3(10);
f3(S()); // expected-note{{in instantiation of default argument for 'f3<struct S>' required here}}
}
template<typename T... |
<|file_sep|>src/test/fuzz/fees.cpp.diff
original:
updated:
#include <util/fees.h>
<|file_sep|>original/src/test/fuzz/fees.cpp
#include <optional.h>
#include <policy/fees.h>
#include <test/fuzz/FuzzedDataProvider.h>
#include <test/fuzz/fuzz.h>
#include <test/fuzz/util.h>
#include <cstdint>
#include <string>
#include <... | #include <test/fuzz/fuzz.h>
#include <test/fuzz/util.h>
#include <util/fees.h>
#include <cstdint>
#include <string>
#include <vector>
void test_one_input(const std::vector<uint8_t>& buffer)
{
FuzzedDataProvider fuzzed_data_provider(buffer.data(), buffer.size());
const CFeeRate minimal_incremental_fee{ConsumeM... | src/test/fuzz/fees.cpp | C++ | a4e3d13df6a6f48974f541de0b5b061e8078ba9a | <|file_sep|>src/test/fuzz/fees.cpp.diff
original:
updated:
#include <util/fees.h>
<|file_sep|>original/src/test/fuzz/fees.cpp
#include <optional.h>
#include <policy/fees.h>
#include <test/fuzz/FuzzedDataProvider.h>
#include <test/fuzz/fuzz.h>
#include <test/fuzz/util.h>
#include <cstdint>
#include <string>
#include <... |
<|file_sep|>src/platform/posix.cpp.diff
original:
updated:
#include "../collector.hpp"
#include <signal.h>
<|file_sep|>src/platform/posix.cpp.diff
original:
updated:
void signal_handler(int)
{
Collector::signal();
}
<|file_sep|>original/src/platform/posix.cpp
void *allocate_region(size_t bytes)
{
voi... | return result;
}
void free_region(void *region, size_t bytes)
{
munmap(region, bytes);
}
void signal_handler(int)
{
Collector::signal();
}
void initialize()
{
signal(SIGINT, signal_handler);
}
};
};
#endif | src/platform/posix.cpp | C++ | 9a287fd661bcd7ade1753a5fb8b171408fb9ec08 | <|file_sep|>src/platform/posix.cpp.diff
original:
updated:
#include "../collector.hpp"
#include <signal.h>
<|file_sep|>src/platform/posix.cpp.diff
original:
updated:
void signal_handler(int)
{
Collector::signal();
}
<|file_sep|>original/src/platform/posix.cpp
void *allocate_region(size_t bytes)
{
voi... |
<|file_sep|>src/main.cpp.diff
original:
updated:
#include <QDebug>
<|file_sep|>original/src/main.cpp
#include <QStateMachine>
#include <memory>
#include "./window.h"
#include "./demo_scene.h"
#include "./input/invoke_manager.h"
#include "./input/signal_manager.h"
#include "./input/scxml_importer.h"
int main(int argc,... | #include <memory>
#include "./window.h"
#include "./demo_scene.h"
#include "./input/invoke_manager.h"
#include "./input/signal_manager.h"
#include "./input/scxml_importer.h"
int main(int argc, char **argv)
{
qputenv("QT_MESSAGE_PATTERN",
QString("%{time [yyyy'-'MM'-'dd' 'hh':'mm':'ss]} - %{threadid} "
... | src/main.cpp | C++ | 93f9fa12954a5167090dbc3bce572c0a56d2870e | <|file_sep|>src/main.cpp.diff
original:
updated:
#include <QDebug>
<|file_sep|>original/src/main.cpp
#include <QStateMachine>
#include <memory>
#include "./window.h"
#include "./demo_scene.h"
#include "./input/invoke_manager.h"
#include "./input/signal_manager.h"
#include "./input/scxml_importer.h"
int main(int argc,... |
<|file_sep|>crypto/ec_signature_creator.cc.diff
original:
updated:
#include "base/logging.h"
<|file_sep|>original/crypto/ec_signature_creator.cc
namespace {
ECSignatureCreatorFactory* g_factory_ = NULL;
} // namespace
// static
ECSignatureCreator* ECSignatureCreator::Create(ECPrivateKey* key) {
if (g_factory_)
... | ECSignatureCreatorFactory* g_factory_ = NULL;
} // namespace
// static
ECSignatureCreator* ECSignatureCreator::Create(ECPrivateKey* key) {
if (g_factory_)
return g_factory_->Create(key);
return new ECSignatureCreatorImpl(key);
}
// static
void ECSignatureCreator::SetFactoryForTesting(
ECSignatureCreator... | crypto/ec_signature_creator.cc | C++ | 34b1289eb33a88631bbf8dc61febfe31ef3a9235 | <|file_sep|>crypto/ec_signature_creator.cc.diff
original:
updated:
#include "base/logging.h"
<|file_sep|>original/crypto/ec_signature_creator.cc
namespace {
ECSignatureCreatorFactory* g_factory_ = NULL;
} // namespace
// static
ECSignatureCreator* ECSignatureCreator::Create(ECPrivateKey* key) {
if (g_factory_)
... |
<|file_sep|>src/U8Gettext.cpp.diff
original:
updated:
static const U8GettextLanguage *
sLanguageInstance = NULL;
<|file_sep|>original/src/U8Gettext.cpp
static const char *
sU8GettextLanguage = "en_US";
const char *U8GettextSetLanguage(const char *language)
{
const char * oldLanguage = sU8GettextLanguage;
sU8Ge... |
const char *U8GettextSetLanguage(const char *language)
{
const char * oldLanguage = sU8GettextLanguage;
sU8GettextLanguage = language;
return oldLanguage;
}
const char *U8GettextGetLanguage()
{
return sU8GettextLanguage;
}
const char *U8Gettext(const char *str)
{
// TODO Implementation
if (!sLanguageIns... | src/U8Gettext.cpp | C++ | ecc62ddac66239335cf8a8d7833c6d7ce64b7ec6 | <|file_sep|>src/U8Gettext.cpp.diff
original:
updated:
static const U8GettextLanguage *
sLanguageInstance = NULL;
<|file_sep|>original/src/U8Gettext.cpp
static const char *
sU8GettextLanguage = "en_US";
const char *U8GettextSetLanguage(const char *language)
{
const char * oldLanguage = sU8GettextLanguage;
sU8Ge... |
<|file_sep|>src/common/utils.cc.diff
original:
updated:
#ifdef PISTACHE_USE_SSL
<|file_sep|>original/src/common/utils.cc
size_t to_read;
if (in == -1)
return -1;
to_read = sizeof(buffer) > count ? count : sizeof(buffer);
if (offset != NULL)
ret = pread(in, buffer, to_re... | if (in == -1)
return -1;
to_read = sizeof(buffer) > count ? count : sizeof(buffer);
if (offset != NULL)
ret = pread(in, buffer, to_read, *offset);
else
ret = read(in, buffer, to_read);
if (ret == -1)
return -1;
written = SSL_write(out, buffer, ret);
if (of... | src/common/utils.cc | C++ | 27eda3a7860e6c0835543c6fcb358d3ff90a79ad | <|file_sep|>src/common/utils.cc.diff
original:
updated:
#ifdef PISTACHE_USE_SSL
<|file_sep|>original/src/common/utils.cc
size_t to_read;
if (in == -1)
return -1;
to_read = sizeof(buffer) > count ? count : sizeof(buffer);
if (offset != NULL)
ret = pread(in, buffer, to_re... |
<|file_sep|>src/qca_systemstore_flatfile.cpp.diff
original:
updated:
#ifdef QCA_NO_SYSTEMSTORE
return false;
#else
<|file_sep|>src/qca_systemstore_flatfile.cpp.diff
original:
updated:
#endif
<|file_sep|>src/qca_systemstore_flatfile.cpp.diff
original:
updated:
#ifdef QCA_NO_SYSTEMSTORE
Q_UNUSED(provider);
return C... | bool qca_have_systemstore()
{
#ifdef QCA_NO_SYSTEMSTORE
return false;
#else
QFile f(QCA_SYSTEMSTORE_PATH);
return f.open(QFile::ReadOnly);
#endif
}
CertificateCollection qca_get_systemstore(const QString &provider)
{
#ifdef QCA_NO_SYSTEMSTORE
Q_UNUSED(provider);
return CertificateCollection();
#else
return Certi... | src/qca_systemstore_flatfile.cpp | C++ | 478eac7446d56a297405de4ab1b14da8d8e21494 | <|file_sep|>src/qca_systemstore_flatfile.cpp.diff
original:
updated:
#ifdef QCA_NO_SYSTEMSTORE
return false;
#else
<|file_sep|>src/qca_systemstore_flatfile.cpp.diff
original:
updated:
#endif
<|file_sep|>src/qca_systemstore_flatfile.cpp.diff
original:
updated:
#ifdef QCA_NO_SYSTEMSTORE
Q_UNUSED(provider);
return C... |
<|file_sep|>benchmark/src/Main.cpp.diff
original:
updated:
#include <stdexcept>
<|file_sep|>original/benchmark/src/Main.cpp
using namespace std;
int realMain(int argc, char* argv[]);
int main(int argc, char* argv[])
{
try {
return realMain(argc, argv);
}
catch (...) {
cout << "ERROR: Unh... |
int realMain(int argc, char* argv[]);
int main(int argc, char* argv[])
{
try {
return realMain(argc, argv);
}
catch (std::exception& e) {
cout << "ERROR: Unhandled exception with message '" << e.what()
<< "', benchmark terminated\n";
return EXIT_FAILURE;
}
catc... | benchmark/src/Main.cpp | C++ | 2fbf6ca81bb2e555f07ead299e5ecf8db17fdd7d | <|file_sep|>benchmark/src/Main.cpp.diff
original:
updated:
#include <stdexcept>
<|file_sep|>original/benchmark/src/Main.cpp
using namespace std;
int realMain(int argc, char* argv[]);
int main(int argc, char* argv[])
{
try {
return realMain(argc, argv);
}
catch (...) {
cout << "ERROR: Unh... |
<|file_sep|>src/matchers/be_something.cc.diff
original:
updated:
// Public methods.
<|file_sep|>original/src/matchers/be_something.cc
#include <ccspec/matchers/be_something.h>
namespace ccspec {
namespace matchers {
const BeSomething& be = BeSomething::instance();
const BeSomething& BeSomething::instance() {
s... | #include <ccspec/matchers/be_something.h>
namespace ccspec {
namespace matchers {
const BeSomething& be = BeSomething::instance();
// Public methods.
const BeSomething& BeSomething::instance() {
static BeSomething instance;
return instance;
}
// Private methods.
BeSomething::BeSomething() {}
} // namespa... | src/matchers/be_something.cc | C++ | e2ebaf0ca22235e18f6e3052d23b2929d18f6079 | <|file_sep|>src/matchers/be_something.cc.diff
original:
updated:
// Public methods.
<|file_sep|>original/src/matchers/be_something.cc
#include <ccspec/matchers/be_something.h>
namespace ccspec {
namespace matchers {
const BeSomething& be = BeSomething::instance();
const BeSomething& BeSomething::instance() {
s... |
<|file_sep|>lib/sanitizer_common/tests/sanitizer_test_main.cc.diff
original:
updated:
#include "sanitizer_common/sanitizer_flags.h"
<|file_sep|>original/lib/sanitizer_common/tests/sanitizer_test_main.cc
//
// The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Il... | //
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
//
// This file is a part of ThreadSanitizer/AddressSanitizer runtime.
//
//===----------------------------------------... | lib/sanitizer_common/tests/sanitizer_test_main.cc | C++ | c6a339a4b267bad46922e3f7f47f46cbe710827d | <|file_sep|>lib/sanitizer_common/tests/sanitizer_test_main.cc.diff
original:
updated:
#include "sanitizer_common/sanitizer_flags.h"
<|file_sep|>original/lib/sanitizer_common/tests/sanitizer_test_main.cc
//
// The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Il... |
<|file_sep|>examples/spdlog/foo.cpp.diff
original:
updated:
#include <spdlog/sinks/stdout_sinks.h>
<|file_sep|>original/examples/spdlog/foo.cpp
#include <spdlog/spdlog.h>
int main(int argc, char* argv[]) {
auto console = spdlog::stdout_logger_mt("console");
console->info("Hello from INFO");
}
<|file_sep|>current/... | #include <spdlog/spdlog.h>
#include <spdlog/sinks/stdout_sinks.h>
int main(int argc, char* argv[]) {
auto console = spdlog::stdout_logger_mt("console");
console->info("Hello from INFO");
return 0;
} | examples/spdlog/foo.cpp | C++ | 7e39bf7533b43f6572035c14bff34f06eaeec413 | <|file_sep|>examples/spdlog/foo.cpp.diff
original:
updated:
#include <spdlog/sinks/stdout_sinks.h>
<|file_sep|>original/examples/spdlog/foo.cpp
#include <spdlog/spdlog.h>
int main(int argc, char* argv[]) {
auto console = spdlog::stdout_logger_mt("console");
console->info("Hello from INFO");
}
<|file_sep|>current/... |
<|file_sep|>unittests/Support/DebugTest.cpp.diff
original:
updated:
#ifndef NDEBUG
<|file_sep|>original/unittests/Support/DebugTest.cpp
#include "gtest/gtest.h"
#include <string>
using namespace llvm;
TEST(DebugTest, Basic) {
std::string s1, s2;
raw_string_ostream os1(s1), os2(s2);
static const char *DT[] = {"... | #include <string>
using namespace llvm;
#ifndef NDEBUG
TEST(DebugTest, Basic) {
std::string s1, s2;
raw_string_ostream os1(s1), os2(s2);
static const char *DT[] = {"A", "B"};
llvm::DebugFlag = true;
setCurrentDebugTypes(DT, 2);
DEBUG_WITH_TYPE("A", os1 << "A");
DEBUG_WITH_TYPE("B", os1 << "B");
EX... | unittests/Support/DebugTest.cpp | C++ | e595a6f955108bfb28b68f1004b6216e27e02cb1 | <|file_sep|>unittests/Support/DebugTest.cpp.diff
original:
updated:
#ifndef NDEBUG
<|file_sep|>original/unittests/Support/DebugTest.cpp
#include "gtest/gtest.h"
#include <string>
using namespace llvm;
TEST(DebugTest, Basic) {
std::string s1, s2;
raw_string_ostream os1(s1), os2(s2);
static const char *DT[] = {"... |
<|file_sep|>test/utilities/meta/meta.unary.prop.query/alignment_of.pass.cpp.diff
original:
updated:
#if (defined(__ppc__) && !defined(__ppc64__))
test_alignment_of<bool, 4>(); // 32-bit PPC has four byte bool
#else
<|file_sep|>original/test/utilities/meta/meta.unary.prop.query/alignment_of.pass.cpp
static_asse... | {
public:
~Class();
};
int main()
{
test_alignment_of<int&, 4>();
test_alignment_of<Class, 1>();
test_alignment_of<int*, sizeof(intptr_t)>();
test_alignment_of<const int*, sizeof(intptr_t)>();
test_alignment_of<char[3], 1>();
test_alignment_of<int, 4>();
test_alignment_of<double, 8>();
... | test/utilities/meta/meta.unary.prop.query/alignment_of.pass.cpp | C++ | e3c9d52d6de2d59752e9c20fce34eadec6b925bd | <|file_sep|>test/utilities/meta/meta.unary.prop.query/alignment_of.pass.cpp.diff
original:
updated:
#if (defined(__ppc__) && !defined(__ppc64__))
test_alignment_of<bool, 4>(); // 32-bit PPC has four byte bool
#else
<|file_sep|>original/test/utilities/meta/meta.unary.prop.query/alignment_of.pass.cpp
static_asse... |
<|file_sep|>config/config_type_int.cc.diff
original:
updated:
#if !defined(__OPENNT)
<|file_sep|>config/config_type_int.cc.diff
original:
updated:
#endif
<|file_sep|>config/config_type_int.cc.diff
original:
updated:
#if !defined(__OPENNT)
<|file_sep|>original/config/config_type_int.cc
ConfigTypeInt config_type_int;... | ConfigTypeInt::set(ConfigValue *cv, const std::string& vstr)
{
if (ints_.find(cv) != ints_.end())
return (false);
const char *str = vstr.c_str();
char *endp;
intmax_t imax;
#if !defined(__OPENNT)
imax = strtoimax(str, &endp, 0);
#else
imax = strtoll(str, &endp, 0);
#endif
if (*endp != '\0')
return (false);... | config/config_type_int.cc | C++ | 15b2fd6e53d3642cc2ecb13ec3c9c039830cf0e4 | <|file_sep|>config/config_type_int.cc.diff
original:
updated:
#if !defined(__OPENNT)
<|file_sep|>config/config_type_int.cc.diff
original:
updated:
#endif
<|file_sep|>config/config_type_int.cc.diff
original:
updated:
#if !defined(__OPENNT)
<|file_sep|>original/config/config_type_int.cc
ConfigTypeInt config_type_int;... |
<|file_sep|>src/timermanager.cpp.diff
original:
updated:
const auto max_id = last_id;
<|file_sep|>original/src/timermanager.cpp
if (it != timers.end())
{
timers.erase(it);
}
}
void TimerManager::update(float delta)
{
for (auto it = timers.begin(); it != timers... | timers.erase(it);
}
}
void TimerManager::update(float delta)
{
const auto max_id = last_id;
for (auto it = timers.begin(); it != timers.end(); )
{
// only process timers up to current max during this frame
if ((*it)->id > max_id)
break;
(*it)->re... | src/timermanager.cpp | C++ | f2c2ac08b606a07a4de9e6071e9ae47a6d6f5792 | <|file_sep|>src/timermanager.cpp.diff
original:
updated:
const auto max_id = last_id;
<|file_sep|>original/src/timermanager.cpp
if (it != timers.end())
{
timers.erase(it);
}
}
void TimerManager::update(float delta)
{
for (auto it = timers.begin(); it != timers... |
<|file_sep|>interface/src/main.cpp.diff
original:
updated:
#include <iostream>
<|file_sep|>original/interface/src/main.cpp
#include "ofMain.h"
#include "ofApp.h"
#include <stdlib.h>
int main(int argc, char* argv[]){
if (argc < 2) {
exit(1);
return 0;
} else {
ofSetupOpenGL(1024,768,OF_... | #include "ofMain.h"
#include "ofApp.h"
#include <iostream>
#include <stdlib.h>
int main(int argc, char* argv[]){
if (argc < 2) {
cerr << "Usage: interface <socket path>";
exit(1);
return 0;
} else {
ofSetupOpenGL(1024,768,OF_FULLSCREEN);
ofRunApp(new ofApp(argv[1]));
... | interface/src/main.cpp | C++ | e2bbd39a1acf94c8749c51f047f7552314ebc72f | <|file_sep|>interface/src/main.cpp.diff
original:
updated:
#include <iostream>
<|file_sep|>original/interface/src/main.cpp
#include "ofMain.h"
#include "ofApp.h"
#include <stdlib.h>
int main(int argc, char* argv[]){
if (argc < 2) {
exit(1);
return 0;
} else {
ofSetupOpenGL(1024,768,OF_... |
<|file_sep|>views/controls/menu/menu_config_gtk.cc.diff
original:
updated:
#if defined(TOUCH_UI)
config->font = rb.GetFont(ResourceBundle::LargeFont);
#else
<|file_sep|>original/views/controls/menu/menu_config_gtk.cc
#include "views/controls/menu/menu_config.h"
#include "grit/app_resources.h"
#include "third_party/... | #include "ui/base/resource/resource_bundle.h"
namespace views {
// static
MenuConfig* MenuConfig::Create() {
MenuConfig* config = new MenuConfig();
ResourceBundle& rb = ResourceBundle::GetSharedInstance();
#if defined(TOUCH_UI)
config->font = rb.GetFont(ResourceBundle::LargeFont);
#else
config->font = rb.GetF... | views/controls/menu/menu_config_gtk.cc | C++ | 6a6579ac2dbb30ca5f86481cbdfe699ee76a47fe | <|file_sep|>views/controls/menu/menu_config_gtk.cc.diff
original:
updated:
#if defined(TOUCH_UI)
config->font = rb.GetFont(ResourceBundle::LargeFont);
#else
<|file_sep|>original/views/controls/menu/menu_config_gtk.cc
#include "views/controls/menu/menu_config.h"
#include "grit/app_resources.h"
#include "third_party/... |
<|file_sep|>tests/libport/hmac-sha1.cc.diff
original:
updated:
#include <libport/config.h>
<|file_sep|>tests/libport/hmac-sha1.cc.diff
original:
updated:
#ifdef LIBPORT_ENABLE_SSL
<|file_sep|>original/tests/libport/hmac-sha1.cc
#include <libport/unit-test.hh>
using libport::test_suite;
#include <iostream>
static voi... | using libport::test_suite;
#include <iostream>
static void test()
{
#ifdef LIBPORT_ENABLE_SSL
std::string msg =
"GET\n\n\nTue, 27 Mar 2007 19:36:42 +0000\n"
"/johnsmith/photos/puppy.jpg";
std::string key = "uV3F3YluFJax1cknvbcGwgjvx4QpvB+leU8dUj2o";
BOOST_CHECK_EQUAL(libport::base64(libport::hmac_sha1(msg... | tests/libport/hmac-sha1.cc | C++ | 6b8dfd56512a667eb84d8c6412bb9e7a4e90faae | <|file_sep|>tests/libport/hmac-sha1.cc.diff
original:
updated:
#include <libport/config.h>
<|file_sep|>tests/libport/hmac-sha1.cc.diff
original:
updated:
#ifdef LIBPORT_ENABLE_SSL
<|file_sep|>original/tests/libport/hmac-sha1.cc
#include <libport/unit-test.hh>
using libport::test_suite;
#include <iostream>
static voi... |
<|file_sep|>test/libcxx/thread/thread.mutex/thread_safety_lock_guard.pass.cpp.diff
original:
updated:
#if __cplusplus >= 201703L
<|file_sep|>original/test/libcxx/thread/thread.mutex/thread_safety_lock_guard.pass.cpp
// <mutex>
// MODULES_DEFINES: _LIBCPP_ENABLE_THREAD_SAFETY_ANNOTATIONS
#define _LIBCPP_ENABLE_THREAD... |
// MODULES_DEFINES: _LIBCPP_ENABLE_THREAD_SAFETY_ANNOTATIONS
#define _LIBCPP_ENABLE_THREAD_SAFETY_ANNOTATIONS
#include <mutex>
std::mutex m;
int foo __attribute__((guarded_by(m)));
static void scoped() {
#if __cplusplus >= 201703L
std::scoped_lock<std::mutex> lock(m);
foo++;
#endif
}
int main() {
scoped();
... | test/libcxx/thread/thread.mutex/thread_safety_lock_guard.pass.cpp | C++ | c4edc5a9128b193b171272a3eaed056fef56da89 | <|file_sep|>test/libcxx/thread/thread.mutex/thread_safety_lock_guard.pass.cpp.diff
original:
updated:
#if __cplusplus >= 201703L
<|file_sep|>original/test/libcxx/thread/thread.mutex/thread_safety_lock_guard.pass.cpp
// <mutex>
// MODULES_DEFINES: _LIBCPP_ENABLE_THREAD_SAFETY_ANNOTATIONS
#define _LIBCPP_ENABLE_THREAD... |
<|file_sep|>src/mediaplayer/main.cpp.diff
original:
updated:
qDebug() << "Xine player started";
<|file_sep|>original/src/mediaplayer/main.cpp
<< "Can't seem to register dbus service:"
<< QDBusConnection::sessionBus().lastError().message();
app.exit(-1);
}
AbstractMediaPlayer... | << QDBusConnection::sessionBus().lastError().message();
app.exit(-1);
}
AbstractMediaPlayer *player = 0;
#ifdef XINE_PLAYER
#warning using xine backend
qDebug() << "Xine player started";
player = new XinePlayer(&app);
#else
#warning using qDebug testing backend
qDebug() << "qDebu... | src/mediaplayer/main.cpp | C++ | 6ac3e7af4c18b5f8f9cb309a97d08c0a672b0417 | <|file_sep|>src/mediaplayer/main.cpp.diff
original:
updated:
qDebug() << "Xine player started";
<|file_sep|>original/src/mediaplayer/main.cpp
<< "Can't seem to register dbus service:"
<< QDBusConnection::sessionBus().lastError().message();
app.exit(-1);
}
AbstractMediaPlayer... |
<|file_sep|>src/search/util/timeout.cc.diff
original:
updated:
sa.sa_flags = 0;
sa.sa_sigaction = NULL;
sa.sa_restorer = NULL;
<|file_sep|>original/src/search/util/timeout.cc
{
cout << "No Solution" << endl
<< "cost: infinity" << endl
<< "length: infinity" << endl
<< "wall_time: infinity" << endl... | << "wall_time: infinity" << endl
<< "CPU_time: infinity" << endl
<< "generated: infinity" << endl
<< "expanded: infinity" << endl;
exit(EXIT_SUCCESS);
}
void timeout(unsigned int sec)
{
struct sigaction sa;
sa.sa_flags = 0;
sa.sa_sigaction = NULL;
sa.sa_restorer = NULL;
sa.sa_handler = ... | src/search/util/timeout.cc | C++ | 4f4fcf4969d4e233024bd0d9397facc0906db49e | <|file_sep|>src/search/util/timeout.cc.diff
original:
updated:
sa.sa_flags = 0;
sa.sa_sigaction = NULL;
sa.sa_restorer = NULL;
<|file_sep|>original/src/search/util/timeout.cc
{
cout << "No Solution" << endl
<< "cost: infinity" << endl
<< "length: infinity" << endl
<< "wall_time: infinity" << endl... |
<|file_sep|>config/config_type_int.cc.diff
original:
updated:
#if !defined(__OPENNT)
<|file_sep|>config/config_type_int.cc.diff
original:
updated:
#endif
<|file_sep|>config/config_type_int.cc.diff
original:
updated:
#if !defined(__OPENNT)
<|file_sep|>original/config/config_type_int.cc
ConfigTypeInt config_type_int;... | ConfigTypeInt::set(ConfigValue *cv, const std::string& vstr)
{
if (ints_.find(cv) != ints_.end())
return (false);
const char *str = vstr.c_str();
char *endp;
intmax_t imax;
#if !defined(__OPENNT)
imax = strtoimax(str, &endp, 0);
#else
imax = strtoll(str, &endp, 0);
#endif
if (*endp != '\0')
return (false);... | config/config_type_int.cc | C++ | a42fc98e14d57b919ce192a2d442399520b06eec | <|file_sep|>config/config_type_int.cc.diff
original:
updated:
#if !defined(__OPENNT)
<|file_sep|>config/config_type_int.cc.diff
original:
updated:
#endif
<|file_sep|>config/config_type_int.cc.diff
original:
updated:
#if !defined(__OPENNT)
<|file_sep|>original/config/config_type_int.cc
ConfigTypeInt config_type_int;... |
<|file_sep|>viewer/KVProxy.cpp.diff
original:
updated:
#include <string>
<|file_sep|>original/viewer/KVProxy.cpp
QObject(parent), p("127.0.0.1", port)
{
// Make the poll timer tell the proxy to poll; this will be started with
// a timeout of 0, so it will effectively poll on every event loop tick
connect(&pollTime... | {
// Make the poll timer tell the proxy to poll; this will be started with
// a timeout of 0, so it will effectively poll on every event loop tick
connect(&pollTimer, SIGNAL(timeout()), this, SLOT(poll()));
// Pass on new connections to a function in KVProxy_p
p.on_connection([this](HttpProxy::Connection::Ptr co... | viewer/KVProxy.cpp | C++ | 96dc7e1aecba90488cec2618f8037d36fd2bfd92 | <|file_sep|>viewer/KVProxy.cpp.diff
original:
updated:
#include <string>
<|file_sep|>original/viewer/KVProxy.cpp
QObject(parent), p("127.0.0.1", port)
{
// Make the poll timer tell the proxy to poll; this will be started with
// a timeout of 0, so it will effectively poll on every event loop tick
connect(&pollTime... |
<|file_sep|>test-cascades-lib/test-cascades-lib-xmpp/src/XmppHarness.cpp.diff
original:
updated:
#include "XmppDisconnectCommand.h"
<|file_sep|>original/test-cascades-lib/test-cascades-lib-xmpp/src/XmppHarness.cpp
}
bool XmppHarness::installHarness()
{
XMPPResourceStore::initialiseStore(this);
... | XMPPResourceStore::initialiseStore(this);
CommandFactory::installCommand(
XMPPHelpCommand::getCmd(),
&XMPPHelpCommand::create);
CommandFactory::installCommand(
XMPPConnectCommand::getCmd(),
&XMPPConnectCommand::creat... | test-cascades-lib/test-cascades-lib-xmpp/src/XmppHarness.cpp | C++ | 998581e6910ccf34390d2b021124cf449b361295 | <|file_sep|>test-cascades-lib/test-cascades-lib-xmpp/src/XmppHarness.cpp.diff
original:
updated:
#include "XmppDisconnectCommand.h"
<|file_sep|>original/test-cascades-lib/test-cascades-lib-xmpp/src/XmppHarness.cpp
}
bool XmppHarness::installHarness()
{
XMPPResourceStore::initialiseStore(this);
... |
<|file_sep|>thrift/lib/cpp2/async/ClientChannel.cpp.diff
original:
updated:
#ifdef __linux__
#include <sys/utsname.h>
#endif
<|file_sep|>thrift/lib/cpp2/async/ClientChannel.cpp.diff
original:
updated:
#ifdef __linux__
struct utsname bufs;
::uname(&bufs);
return bufs.nodename;
#else
<|file_sep|>original/thrift/... | namespace apache {
namespace thrift {
namespace {
THRIFT_PLUGGABLE_FUNC_REGISTER(std::optional<std::string>, getClientHostId) {
#ifdef __linux__
struct utsname bufs;
::uname(&bufs);
return bufs.nodename;
#else
return {};
#endif
}
} // namespace
/* static */ const std::optional<std::string>& ClientChannel::getH... | thrift/lib/cpp2/async/ClientChannel.cpp | C++ | 3909c78c547500694d66f4b33e22dd98c1574bcd | <|file_sep|>thrift/lib/cpp2/async/ClientChannel.cpp.diff
original:
updated:
#ifdef __linux__
#include <sys/utsname.h>
#endif
<|file_sep|>thrift/lib/cpp2/async/ClientChannel.cpp.diff
original:
updated:
#ifdef __linux__
struct utsname bufs;
::uname(&bufs);
return bufs.nodename;
#else
<|file_sep|>original/thrift/... |
<|file_sep|>src/geom/prep/PreparedPoint.cpp.diff
original:
updated:
#include <geos/geom/Point.h>
<|file_sep|>original/src/geom/prep/PreparedPoint.cpp
**********************************************************************/
#include <geos/geom/prep/PreparedPoint.h>
namespace geos {
namespace geom { // geos.geom
name... |
namespace geos {
namespace geom { // geos.geom
namespace prep { // geos.geom.prep
bool
PreparedPoint::intersects(const geom::Geometry* g) const
{
if (! envelopesIntersect( g)) return false;
const Point *pt_geom = dynamic_cast<const Point *>(g);
if (pt_geom)
return getGeometry().equals(g);
// This avoi... | src/geom/prep/PreparedPoint.cpp | C++ | 7017f79eb59b91d44a2fb4a50a8b329e720dacba | <|file_sep|>src/geom/prep/PreparedPoint.cpp.diff
original:
updated:
#include <geos/geom/Point.h>
<|file_sep|>original/src/geom/prep/PreparedPoint.cpp
**********************************************************************/
#include <geos/geom/prep/PreparedPoint.h>
namespace geos {
namespace geom { // geos.geom
name... |
<|file_sep|>Haxe/Templates/Source/HaxeRuntime/Private/uhx/RuntimeLibrary.cpp.diff
original:
updated:
#ifndef UHX_NO_UOBJECT
<|file_sep|>original/Haxe/Templates/Source/HaxeRuntime/Private/uhx/RuntimeLibrary.cpp
#if defined(_MSC_VER)
unreal::UIntPtr *uhx::ue::RuntimeLibrary_obj::tlsObj = nullptr;
#elif defined(__GNUC__... | #elif defined(__GNUC__)
thread_local unreal::UIntPtr *uhx::ue::RuntimeLibrary_obj::tlsObj = nullptr;
#else
static int uhx_tls_obj = FPlatformTLS::AllocTlsSlot();
unreal::UIntPtr uhx::ue::RuntimeLibrary_obj::getTlsObj() {
unreal::UIntPtr *ret = (unreal::UIntPtr *) FPlatformTLS::GetTlsValue(uhx_tls_obj);
if (!ret) {... | Haxe/Templates/Source/HaxeRuntime/Private/uhx/RuntimeLibrary.cpp | C++ | 4a8ff4784d0bec8509435d1aa55d88c0c747d322 | <|file_sep|>Haxe/Templates/Source/HaxeRuntime/Private/uhx/RuntimeLibrary.cpp.diff
original:
updated:
#ifndef UHX_NO_UOBJECT
<|file_sep|>original/Haxe/Templates/Source/HaxeRuntime/Private/uhx/RuntimeLibrary.cpp
#if defined(_MSC_VER)
unreal::UIntPtr *uhx::ue::RuntimeLibrary_obj::tlsObj = nullptr;
#elif defined(__GNUC__... |
<|file_sep|>cpp/util/testing.cc.diff
original:
updated:
#include <event2/thread.h>
<|file_sep|>original/cpp/util/testing.cc
#include <gflags/gflags.h>
#include <glog/logging.h>
#include <gtest/gtest.h>
namespace cert_trans {
namespace test {
void InitTesting(const char* name, int* argc, char*** argv,
... | #include <glog/logging.h>
#include <gtest/gtest.h>
namespace cert_trans {
namespace test {
void InitTesting(const char* name, int* argc, char*** argv,
bool remove_flags) {
// Change the defaults. Can be overridden on command line.
// Log to stderr instead of log files.
FLAGS_logtostderr = true;... | cpp/util/testing.cc | C++ | 38e4b97e6a646aa8c333956de9a7570868ed22eb | <|file_sep|>cpp/util/testing.cc.diff
original:
updated:
#include <event2/thread.h>
<|file_sep|>original/cpp/util/testing.cc
#include <gflags/gflags.h>
#include <glog/logging.h>
#include <gtest/gtest.h>
namespace cert_trans {
namespace test {
void InitTesting(const char* name, int* argc, char*** argv,
... |
<|file_sep|>src/nwg_service.cc.diff
original:
updated:
#include "nwg_basicprotocolcodec.h"
<|file_sep|>original/src/nwg_service.cc
void Service::setHandler(const std::shared_ptr<Handler> &handler)
{
_handler = handler;
}
EventLoop *Service::getEventLoop() const { return _eventLoop; }
size_t Service::getBuffSize(... | }
EventLoop *Service::getEventLoop() const { return _eventLoop; }
size_t Service::getBuffSize() { return _buffSize; }
size_t Service::getReadBuffSize() { return _readBuffSize; }
ProtocolCodec &Service::getProtocolCodec()
{
if (_protocolCodec == nullptr) {
_protocolCodec = std::make_shared<Nwg::BasicProto... | src/nwg_service.cc | C++ | 0169c849d903c80edd36ba6f73e18f1a5d9e7a3e | <|file_sep|>src/nwg_service.cc.diff
original:
updated:
#include "nwg_basicprotocolcodec.h"
<|file_sep|>original/src/nwg_service.cc
void Service::setHandler(const std::shared_ptr<Handler> &handler)
{
_handler = handler;
}
EventLoop *Service::getEventLoop() const { return _eventLoop; }
size_t Service::getBuffSize(... |
<|file_sep|>tests/themispp/main.cpp.diff
original:
updated:
#include "secure_comparator_test.hpp"
<|file_sep|>original/tests/themispp/main.cpp
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS... | * See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <common/sput.h>
#include "secure_cell_test.hpp"
#include "secure_message_test.hpp"
#include "secure_session_test.hpp"
#include "secure_comparator_test.hpp"
int main(){
sput_start_testing();
themi... | tests/themispp/main.cpp | C++ | 31da751ab34c40a065f172d2c05d50bc717e92a7 | <|file_sep|>tests/themispp/main.cpp.diff
original:
updated:
#include "secure_comparator_test.hpp"
<|file_sep|>original/tests/themispp/main.cpp
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS... |
<|file_sep|>test/t/basic/runtest.cpp.diff
original:
updated:
REQUIRE(!item); // test operator bool()
<|file_sep|>original/test/t/basic/runtest.cpp
SECTION("empty buffer is okay") {
std::string buffer;
mapbox::util::pbf item(buffer.data(), 0);
REQUIRE(!item.next());
}
SECTIO... | mapbox::util::pbf item(buffer.data(), 0);
REQUIRE(!item); // test operator bool()
REQUIRE(!item.next());
}
SECTION("check every possible value for single byte in buffer") {
char buffer[1];
for (int i = 0; i <= 255; ++i) {
*buffer = static_cast<char>(i);
... | test/t/basic/runtest.cpp | C++ | 250cac0ecbb56e5ead8dd05fe1094bd9bc2efacb | <|file_sep|>test/t/basic/runtest.cpp.diff
original:
updated:
REQUIRE(!item); // test operator bool()
<|file_sep|>original/test/t/basic/runtest.cpp
SECTION("empty buffer is okay") {
std::string buffer;
mapbox::util::pbf item(buffer.data(), 0);
REQUIRE(!item.next());
}
SECTIO... |
<|file_sep|>tests/test_lua.cpp.diff
original:
updated:
#include <QCoreApplication>
<|file_sep|>original/tests/test_lua.cpp
#include "Rainback.hpp"
#include <lua-cxx/LuaEnvironment.hpp>
#include <lua-cxx/LuaValue.hpp>
#include <QFile>
int main(int argc, char* argv[])
{
Lua lua;
rainback::Rainback rainback(lua... | #include "Rainback.hpp"
#include <lua-cxx/LuaEnvironment.hpp>
#include <lua-cxx/LuaValue.hpp>
#include <QFile>
#include <QCoreApplication>
int main(int argc, char* argv[])
{
QCoreApplication app(argc, argv);
Lua lua;
rainback::Rainback rainback(lua);
std::string srcdir(getenv("srcdir"));
QFile t... | tests/test_lua.cpp | C++ | 3a7d7381dd7dca6bbc9d5fd48d2227cb18e2ede8 | <|file_sep|>tests/test_lua.cpp.diff
original:
updated:
#include <QCoreApplication>
<|file_sep|>original/tests/test_lua.cpp
#include "Rainback.hpp"
#include <lua-cxx/LuaEnvironment.hpp>
#include <lua-cxx/LuaValue.hpp>
#include <QFile>
int main(int argc, char* argv[])
{
Lua lua;
rainback::Rainback rainback(lua... |
<|file_sep|>sdk-remote/src/libuco/urbi-main.cc.diff
original:
updated:
libport::program_initialize(argc, const_cast<char**>(argv));
<|file_sep|>sdk-remote/src/libuco/urbi-main.cc.diff
original:
updated:
libport::program_initialize(args);
<|file_sep|>original/sdk-remote/src/libuco/urbi-main.cc
int urbi_mai... |
return urbi::main(args, block, errors);
}
}
namespace urbi
{
int
main(int argc, const char* argv[], bool block, bool errors)
{
libport::program_initialize(argc, const_cast<char**>(argv));
libport::cli_args_type args;
// For some reason, I failed to use std::copy here.
for (int i = 0; i <... | sdk-remote/src/libuco/urbi-main.cc | C++ | d191a42d6e36abb1c5ad46c948f8cd92063f7eec | <|file_sep|>sdk-remote/src/libuco/urbi-main.cc.diff
original:
updated:
libport::program_initialize(argc, const_cast<char**>(argv));
<|file_sep|>sdk-remote/src/libuco/urbi-main.cc.diff
original:
updated:
libport::program_initialize(args);
<|file_sep|>original/sdk-remote/src/libuco/urbi-main.cc
int urbi_mai... |
<|file_sep|>src/test/fuzz/parse_hd_keypath.cpp.diff
original:
updated:
#include <test/fuzz/FuzzedDataProvider.h>
<|file_sep|>src/test/fuzz/parse_hd_keypath.cpp.diff
original:
updated:
#include <test/fuzz/util.h>
<|file_sep|>src/test/fuzz/parse_hd_keypath.cpp.diff
original:
updated:
#include <cstdint>
#include <vect... | // file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <test/fuzz/FuzzedDataProvider.h>
#include <test/fuzz/fuzz.h>
#include <test/fuzz/util.h>
#include <util/bip32.h>
#include <cstdint>
#include <vector>
void test_one_input(const std::vector<uint8_t>& buffer)
{
const std::string keypath... | src/test/fuzz/parse_hd_keypath.cpp | C++ | 1532259fcae8712777e1cedefc91224ee60a6aaa | <|file_sep|>src/test/fuzz/parse_hd_keypath.cpp.diff
original:
updated:
#include <test/fuzz/FuzzedDataProvider.h>
<|file_sep|>src/test/fuzz/parse_hd_keypath.cpp.diff
original:
updated:
#include <test/fuzz/util.h>
<|file_sep|>src/test/fuzz/parse_hd_keypath.cpp.diff
original:
updated:
#include <cstdint>
#include <vect... |
<|file_sep|>src/server/views/helpers.cpp.diff
original:
updated:
JsonInt i = JsonInt(errorcode);
<|file_sep|>original/src/server/views/helpers.cpp
#include "helpers.h"
using namespace std;
void sendFail(UserHandler * handler, int errorcode, string topic, string message){
JsonDict answer;
JsonBool b = Js... | #include "helpers.h"
using namespace std;
void sendFail(UserHandler * handler, int errorcode, string topic, string message){
JsonDict answer;
JsonBool b = JsonBool(false);
JsonString s = JsonString(message);
JsonInt i = JsonInt(errorcode);
answer.add("success", &b);
answer.add("reason", &s);
... | src/server/views/helpers.cpp | C++ | 100e09d11e770ae604baf678cb009c4b0c9bd2c4 | <|file_sep|>src/server/views/helpers.cpp.diff
original:
updated:
JsonInt i = JsonInt(errorcode);
<|file_sep|>original/src/server/views/helpers.cpp
#include "helpers.h"
using namespace std;
void sendFail(UserHandler * handler, int errorcode, string topic, string message){
JsonDict answer;
JsonBool b = Js... |
<|file_sep|>src/allocators/global_sbrk_allocator.cc.diff
original:
updated:
#ifdef __x86_64__
<|file_sep|>original/src/allocators/global_sbrk_allocator.cc
// Copyright (c) 2012-2013, the scalloc Project Authors. All rights reserved.
// Please see the AUTHORS file for details. Use of this source code is governed
// b... |
#include <sys/mman.h> // mmap
#include "log.h"
uintptr_t GlobalSbrkAllocator::current_;
void GlobalSbrkAllocator::InitModule() {
#ifdef __x86_64__
size_t size = 1UL << 35; // 32GiB
#endif
#ifdef __i386__
size_t size = 1UL << 31;
#endif
void* p = mmap(0, size, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANONY... | src/allocators/global_sbrk_allocator.cc | C++ | 29b75635d99a4b02079dd4c683e8c9ea71e98fd2 | <|file_sep|>src/allocators/global_sbrk_allocator.cc.diff
original:
updated:
#ifdef __x86_64__
<|file_sep|>original/src/allocators/global_sbrk_allocator.cc
// Copyright (c) 2012-2013, the scalloc Project Authors. All rights reserved.
// Please see the AUTHORS file for details. Use of this source code is governed
// b... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.