commit
stringlengths
40
40
old_file
stringlengths
4
264
new_file
stringlengths
4
264
old_contents
stringlengths
0
4.24k
new_contents
stringlengths
1
5.44k
subject
stringlengths
14
778
message
stringlengths
15
9.92k
lang
stringclasses
277 values
license
stringclasses
13 values
repos
stringlengths
5
127k
2fbf6ca81bb2e555f07ead299e5ecf8db17fdd7d
benchmark/src/Main.cpp
benchmark/src/Main.cpp
#include "Output.h" #include "Parameters.h" #include "Parser.h" #include "PerformanceTracker.h" #include "Simulation.h" #include <iostream> #include <map> #include <string> using namespace pica; using namespace std; int realMain(int argc, char* argv[]); int main(int argc, char* argv[]) { try ...
#include "Output.h" #include "Parameters.h" #include "Parser.h" #include "PerformanceTracker.h" #include "Simulation.h" #include <iostream> #include <map> #include <stdexcept> #include <string> using namespace pica; using namespace std; int realMain(int argc, char* argv[]); int main(int argc, char...
Improve output of standard exceptions.
Improve output of standard exceptions.
C++
mit
pictools/pica,pictools/pica,pictools/pica
8e8221070954da06c52b27babf40561ea874c75e
test/CXX/class/class.local/p3.cpp
test/CXX/class/class.local/p3.cpp
// RUN: clang-cc -fsyntax-only -verify %s void f1() { struct X { struct Y; }; struct X::Y { void f() {} }; } void f2() { struct X { struct Y; struct Y { void f() {} }; }; } // A class nested within a local class is a local class. void f3(int a) { // expected-note{{'a' d...
// RUN: clang-cc -fsyntax-only -verify %s void f1() { struct X { struct Y; }; struct X::Y { void f() {} }; } void f2() { struct X { struct Y; struct Y { void f() {} }; }; } // A class nested within a local class is a local class. void f3(int a) { // expected-note{{'a' d...
Revert this, we have a better way to do this.
Revert this, we have a better way to do this. git-svn-id: ffe668792ed300d6c2daa1f6eba2e0aa28d7ec6c@76687 91177308-0d34-0410-b5e6-96231b3b80d8
C++
apache-2.0
apple/swift-clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,apple/swift-clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,llvm-mirror/clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,llvm-mirror/clang,llvm-mirror/clang,apple/swift-clang,llvm-mirror/clang,apple/swift-clang,llvm-mirror/cl...
27fd9bb61ae91541bbe586155a79c80177d01682
test/src/test-util.cpp
test/src/test-util.cpp
/* * SOPMQ - Scalable optionally persistent message queue * Copyright 2014 InWorldz, LLC * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-...
/* * SOPMQ - Scalable optionally persistent message queue * Copyright 2014 InWorldz, LLC * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-...
Improve hex encoder unit test
Improve hex encoder unit test
C++
apache-2.0
InWorldz/sopmq,InWorldz/sopmq,InWorldz/sopmq,zwagoth/sopmq,zwagoth/sopmq,InWorldz/sopmq,zwagoth/sopmq,zwagoth/sopmq
ecc8e146471d2d47673168465a0d880156186dbf
c++/src/problem_31.cpp
c++/src/problem_31.cpp
// Copyright 2016 Mitchell Kember. Subject to the MIT License. // Project Euler: Problem 31 // Coin sums namespace problem_31 { constexpr long n_denoms = 8; constexpr long denom_values[n_denoms] = { 1, 2, 5, 10, 20, 50, 100, 200 }; long n_coin_sums(const long sum, const long index) { if (sum < 0 || index < 0) { ...
// Copyright 2016 Mitchell Kember. Subject to the MIT License. // Project Euler: Problem 31 // Coin sums namespace problem_31 { constexpr long n_denoms = 8; constexpr long denom_values[n_denoms] = { 1, 2, 5, 10, 20, 50, 100, 200 }; long n_coin_sums(const long sum, const long index) { if (sum < 0 || index < 0) { ...
Fix solution to problem 31
Fix solution to problem 31
C++
mit
mk12/euler,mk12/euler
29adb0f188598baf996834fd4ae35e62673bee07
ReQL-expr-test.cpp
ReQL-expr-test.cpp
#include "ReQL-test.hpp" #include "catch.h" #include <limits> using namespace ReQL; TEST_CASE("Connection", "[c++][connect]") { Connection conn = connect(); REQUIRE(conn.isOpen()); } TEST_CASE("Expr", "[c][expr]") { SECTION("number") { _ReQL_Op_t num; const double val = 42.0; _reql_number_init...
#include "ReQL-test.hpp" #include "catch.h" #include <limits> using namespace ReQL; TEST_CASE("Connection", "[c++][connect]") { Connection conn = connect(); REQUIRE(conn.isOpen()); } TEST_CASE("Expr", "[c][expr]") { SECTION("null") { _ReQL_Op_t null; _reql_null_init(&null); CHECK(_reql_datum_t...
Add null c constructor test.
Add null c constructor test.
C++
apache-2.0
grandquista/ReQL-Core,grandquista/ReQL-Core,grandquista/ReQL-Core,grandquista/ReQL-Core
3ea562bd2e1d90ed8754146a14953dbe8a50df95
sample/main.cpp
sample/main.cpp
#include <QtGui/QApplication> #include "mainwindow.h" #include "fvupdater.h" int main(int argc, char *argv[]) { QApplication a(argc, argv); // Prerequisite for the Fervor updater QApplication::setOrganizationName("pypt"); QApplication::setOrganizationDomain("pypt.lt"); // Set feed URL before doing anything else...
#include <QApplication> #include "mainwindow.h" #include "fvupdater.h" int main(int argc, char *argv[]) { QApplication a(argc, argv); // Prerequisite for the Fervor updater QApplication::setOrganizationName("pypt"); QApplication::setOrganizationDomain("pypt.lt"); // Set feed URL before doing anything else FvUp...
Fix compile issue on Qt5
Fix compile issue on Qt5
C++
mit
pypt/fervor,pypt/fervor
0824ff1a20fd97666c3388ec34e82bc9545340bc
src/obstacle_avoidance.cpp
src/obstacle_avoidance.cpp
#include <ros/ros.h> #include <geometry_msgs/Twist.h> int main(int argc, char *argv[]){ ros::init(argc, argv, "quadrotor_obstacle_avoidance"); ros::NodeHandle node; ros::Publisher cmd_pub = node.advertise<geometry_msgs::Twist>("cmd_vel", 10); ros::Duration(1).sleep(); geometry_msgs::...
#include <ros/ros.h> #include <geometry_msgs/Twist.h> int main(int argc, char *argv[]){ ros::init(argc, argv, "quadrotor_obstacle_avoidance"); ros::NodeHandle node; ros::Publisher cmd_pub = node.advertise<geometry_msgs::Twist>("cmd_vel", 10); ros::Duration(1).sleep(); geometry_msgs::...
Fix parameter of the Twist
Fix parameter of the Twist
C++
bsd-3-clause
DaikiMaekawa/quadrotor_navigation
b90954b027dea683d71cc63178fc38daa1818631
client/source/main.cpp
client/source/main.cpp
#include<iostream> #include<stdlib.h> #include"filecopy.h" int main(int argc, char *argv[]) { if(argc != 3) { std::cout << "USAGE: " << argv[0] << " <filesource> <filedestination>" << std::endl; return 1; } else { filecopy target1(argv[2], argv[1]); std:...
#include<iostream> #include<stdlib.h> #include"filecopy.h" int main(int argc, char *argv[]) { if(argc != 3) { std::cout << "USAGE: " << argv[0] << " <filesource> <filedestination>" << std::endl; return 1; } else { filecopy target1(argv[2], argv[1]); std:...
Fix client for not executing fileworker
Fix client for not executing fileworker
C++
mit
paulkramme/backup
e2ebaf0ca22235e18f6e3052d23b2929d18f6079
src/matchers/be_something.cc
src/matchers/be_something.cc
#include <ccspec/matchers/be_something.h> namespace ccspec { namespace matchers { const BeSomething& be = BeSomething::instance(); const BeSomething& BeSomething::instance() { static BeSomething instance; return instance; } BeSomething::BeSomething() {} } // namespace matchers } // namespace ccspec
#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...
Add comments for public and private sections
Add comments for public and private sections
C++
mit
michaelachrisco/ccspec,zhangsu/ccspec,michaelachrisco/ccspec,michaelachrisco/ccspec,tempbottle/ccspec,zhangsu/ccspec,zhangsu/ccspec,tempbottle/ccspec,tempbottle/ccspec
5c2ac7ce8828c86bee1bc858082c489ce9bee987
example/src/ofApp.cpp
example/src/ofApp.cpp
#include "ofApp.h" void ofApp::setup() { ofBackground(0); // Add our CustomSource to list of fbo sources of the piMapper // FBO sources should be added before piMapper.setup() so the // piMapper is able to load the source if it is assigned to // a surface in XML settings. piMapper.addFboSource(customSou...
#include "ofApp.h" void ofApp::setup() { ofBackground(0); // Add our CustomSource to list of fbo sources of the piMapper // FBO sources should be added before piMapper.setup() so the // piMapper is able to load the source if it is assigned to // a surface in XML settings. piMapper.addFboSource(customSou...
Hide info on startup, but leave commented code
Hide info on startup, but leave commented code
C++
mit
PPilmeyer/ofxPiMapper
2cfa8b8ba06cce61a3b9e64f85037f2147a6a74f
excercise11/main.cpp
excercise11/main.cpp
#include <iostream> #include <string> #include "hash_table.cpp" #include <time.h> void randstr(const int length, std::string &out); int main(void) { srand(time(NULL)); hash_set<std::string> hs_str(10, 0.8, [] (const std::string entry) -> unsigned int { unsigned int hash = 0; ...
#include <iostream> #include <string> #include "hash_table.hpp" #include <time.h> void randstr(const int length, std::string &out); int main(void) { srand(time(NULL)); hash_set<std::string> hs_str(10, 0.8, [] (const std::string entry) -> unsigned int { unsigned int hash = 0; ...
Fix the path of header file
Fix the path of header file Due to commit 6c418384573acb3a4842352948c9f489043c8d51
C++
mit
kdzlvaids/algorithm_and_practice-pknu-2016,kdzlvaids/algorithm_and_practice-pknu-2016
8e7fbd604cb6b7f097d89c0d22d8af3c317d5cd0
brightray/common/content_client.cc
brightray/common/content_client.cc
// Copyright (c) 2012 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-CHROMIUM file. #include "common/content_client.h" #include "common/application_info.h" #include "base/strings/stringprintf.h" #include "base/strings/strin...
// Copyright (c) 2012 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-CHROMIUM file. #include "common/content_client.h" #include "common/application_info.h" #include "base/strings/stringprintf.h" #include "base/strings/strin...
Update for move of BuildUserAgentFromProduct in Chrome 35
Update for move of BuildUserAgentFromProduct in Chrome 35 See https://codereview.chromium.org/186883002
C++
mit
rreimann/electron,electron/electron,rajatsingla28/electron,biblerule/UMCTelnetHub,miniak/electron,bpasero/electron,gerhardberger/electron,miniak/electron,biblerule/UMCTelnetHub,gerhardberger/electron,thomsonreuters/electron,shiftkey/electron,electron/electron,wan-qy/electron,the-ress/electron,thomsonreuters/electron,Fl...
9eb27a9c54d145bc79067a7e957181a9439f1565
src/ui/QGCTCPLinkConfiguration.cc
src/ui/QGCTCPLinkConfiguration.cc
#include <QInputDialog> #include "QGCTCPLinkConfiguration.h" #include "ui_QGCTCPLinkConfiguration.h" QGCTCPLinkConfiguration::QGCTCPLinkConfiguration(TCPLink* link, QWidget *parent) : QWidget(parent), link(link), ui(new Ui::QGCTCPLinkConfiguration) { ui->setupUi(this); uint16_t port = link->getPor...
#include <QInputDialog> #include "QGCTCPLinkConfiguration.h" #include "ui_QGCTCPLinkConfiguration.h" #include <stdint.h> QGCTCPLinkConfiguration::QGCTCPLinkConfiguration(TCPLink* link, QWidget *parent) : QWidget(parent), link(link), ui(new Ui::QGCTCPLinkConfiguration) { ui->setupUi(this); uint16_t...
Add in a missing stdint.h include
Add in a missing stdint.h include
C++
agpl-3.0
diydrones/apm_planner,duststorm/apm_planner,labtoast/apm_planner,hejunbok/apm_planner,diydrones/apm_planner,mirkix/apm_planner,chen0510566/apm_planner,diydrones/apm_planner,381426068/apm_planner,381426068/apm_planner,mrpilot2/apm_planner,diydrones/apm_planner,mirkix/apm_planner,dcarpy/apm_planner,LittleBun/apm_planner,...
19273ae81427dba15525e2cd21bb1857289a43f5
tests/src/experimental/tests_ranges.cpp
tests/src/experimental/tests_ranges.cpp
#include <mart-common/experimental/ranges.h> #include <catch2/catch.hpp> TEST_CASE( "experimental_frange_compiles", "[experimental][ranges]" ) { auto r = mart::experimental::frange( 0.1, 0.3 ).step( 0.1 ); (void)r; } TEST_CASE( "experimental_vrange_compiles", "[experimental][ranges]" ) { auto r = mart::experiment...
#include <mart-common/experimental/ranges.h> #include <catch2/catch.hpp> TEST_CASE( "experimental_frange_compiles", "[experimental][ranges]" ) { auto r = mart::experimental::frange( 0.1, 0.3 ).step( 0.1 ); (void)r; } TEST_CASE( "experimental_vrange_compiles", "[experimental][ranges]" ) { auto r = mart::experiment...
Fix conversion warning in range tests
[Tests] Fix conversion warning in range tests
C++
mit
tum-ei-rcs/mart-common,tum-ei-rcs/mart-common
9811afd937c840796bba2466eac98d09f0cf1c8d
fly/logger/log.cpp
fly/logger/log.cpp
#include "fly/logger/log.h" #include "fly/logger/logger_config.h" namespace fly { //============================================================================== Log::Log() : m_level(NUM_LEVELS), m_time(-1.0), m_gameId(-1), m_line(-1), m_message() { ::memset(m_file, 0, sizeof(m_file)); :...
#include "fly/logger/log.h" #include <cstring> #include "fly/logger/logger_config.h" namespace fly { //============================================================================== Log::Log() : m_level(NUM_LEVELS), m_time(-1.0), m_gameId(-1), m_line(-1), m_message() { ::memset(m_file, 0, si...
Add missing include for linux build
Add missing include for linux build
C++
mit
trflynn89/libfly,trflynn89/libfly
8a6988bf8ee44c1fcc332186586f3a173ef924ef
src/prelude/runtime/tags.cpp
src/prelude/runtime/tags.cpp
#include <prelude/runtime/tags.h> using namespace copperhead; bool system_variant_less::operator()(const system_variant& x, const system_variant& y) const { return x.which() < y.which(); } std::string detail::system_variant_to_string::operator()(const omp_tag&) const { ret...
#include <prelude/runtime/tags.h> using namespace copperhead; bool system_variant_less::operator()(const system_variant& x, const system_variant& y) const { return x.which() < y.which(); } std::string detail::system_variant_to_string::operator()(const omp_tag&) const { ret...
Move the to_string method into the proper namespace.
Move the to_string method into the proper namespace.
C++
apache-2.0
copperhead/copperhead-compiler,copperhead/copperhead-compiler,copperhead/copperhead-compiler
8adf4da65c5559694d451be7fa82a1fe6ab8f9f7
Shape.cpp
Shape.cpp
#include "Shape.h" #include <vector> namespace CraneTranformation { using namespace System; using System::Drawing::Point; Shape::Shape(array<Point>^ shapePoint) { points = shapePoint; } array<Point>^ Shape::get_points() { return points; } }
#include "Shape.h" namespace CraneTranformation { using namespace System; using System::Drawing::Point; Shape::Shape(array<Point>^ shapePoint) { points = shapePoint; } array<Point>^ Shape::get_points() { return points; } void Shape::translate(Point^ delta) { for (int i = 0; i < points->Lengt...
Implement translation and point printing
Implement translation and point printing
C++
mit
adhikasp/crane-transformation
29740890d672e97b34bb25776996c83fd815c759
src/xmpp/qa/unittest.template/myclasstest.cpp
src/xmpp/qa/unittest.template/myclasstest.cpp
/* * Copyright (C) 2008 <Your Name> * See COPYING for license details. */ #include <QObject> #include <QtTest/QtTest> #include "qttestutil/qttestutil.h" class MyClassTest : public QObject { Q_OBJECT private slots: void initTestCase() { } void cleanupTestCase() { } void testMyMethod() { //Q...
/* * Copyright (C) 2008 <Your Name> * See COPYING for license details. */ #include <QObject> #include <QtTest/QtTest> #include "qttestutil/qttestutil.h" class MyClassTest : public QObject { Q_OBJECT private slots: void initTestCase() { } void cleanupTestCase() { } void testMyMethod() { //Q...
Fix macro in unittest example.
Fix macro in unittest example. git-svn-id: ced07d5e10f05f45759cb75bdadb6610d25656be@257 ac7a513c-5e3a-0410-af42-968c3ac6e7dc
C++
lgpl-2.1
tfar/iris-gsoc2010,psi-im/iris,harishnavnit/iris,harishnavnit/iris,psi-im/iris,orgads/iris,tfar/iris-gsoc2010,orgads/iris,drizt/iris,psi-im/iris,tfar/iris-gsoc2010,harishnavnit/iris,orgads/iris,drizt/iris,drizt/iris
d1e8433b09ec16d9d9e98fa71a51542c99a36df7
cpp/tools/parquet/parquet-dump-schema.cc
cpp/tools/parquet/parquet-dump-schema.cc
// Licensed to the Apache Software Foundation (ASF) under one // or more contributor license agreements. See the NOTICE file // distributed with this work for additional information // regarding copyright ownership. The ASF licenses this file // to you under the Apache License, Version 2.0 (the // "License"); you may...
// Licensed to the Apache Software Foundation (ASF) under one // or more contributor license agreements. See the NOTICE file // distributed with this work for additional information // regarding copyright ownership. The ASF licenses this file // to you under the Apache License, Version 2.0 (the // "License"); you may...
Use metadata builders in parquet writer
PARQUET-711: Use metadata builders in parquet writer I wrote a sample file and the metadata seems to be correct. @xhochy I fixed some missing metadata like `dictionary_page_offset`. You might want to check if this fixes the Drill problem. Author: Deepak Majeti <deepak.majeti@hpe.com> Closes #156 from majetideepak/PA...
C++
apache-2.0
kou/arrow,majetideepak/arrow,tebeka/arrow,xhochy/arrow,renesugar/arrow,apache/arrow,apache/arrow,renesugar/arrow,itaiin/arrow,pcmoritz/arrow,xhochy/arrow,wesm/arrow,majetideepak/arrow,laurentgo/arrow,kou/arrow,tebeka/arrow,laurentgo/arrow,itaiin/arrow,majetideepak/arrow,renesugar/arrow,itaiin/arrow,pcmoritz/arrow,laure...
a014cb66eb05e3d6c775aae4f3b229b9d4fa2571
src/file_listener.cpp
src/file_listener.cpp
#include <thread> #include <chrono> #include <iostream> #include "file_listener.hpp" namespace fs = std::experimental::filesystem; namespace amer { void file_listener::run() { m_listener_thread = std::thread{[this] { this->do_run(); }}; } void file_listener::do_run() { while (true) { for (auto&& ...
#include <thread> #include <chrono> #include <iostream> #include "file_listener.hpp" namespace fs = std::experimental::filesystem; static constexpr auto sleep_time = std::chrono::milliseconds(100) namespace amer { void file_listener::run() { m_listener_thread = std::thread{[this] { this->do_run(); }}; } ...
Clean up file listener code
Clean up file listener code
C++
mit
TartanLlama/amer,TartanLlama/amer,TartanLlama/amer
237b9142f90d24cefb757bd3cbe8b9a8c39ab92e
cpp/turbodbc_numpy/Library/src/set_numpy_parameters.cpp
cpp/turbodbc_numpy/Library/src/set_numpy_parameters.cpp
#include <turbodbc_numpy/set_numpy_parameters.h> #include <turbodbc/errors.h> #include <iostream> namespace turbodbc_numpy { void set_numpy_parameters(turbodbc::bound_parameter_set & parameters, std::vector<pybind11::array> const & columns) { pybind11::dtype const np_int64("int64"); pybind11::dtype const n...
#include <turbodbc_numpy/set_numpy_parameters.h> #include <turbodbc/errors.h> #include <turbodbc/make_description.h> #include <turbodbc/type_code.h> #include <iostream> #include <algorithm> #ifdef _WIN32 #include <windows.h> #endif #include <sql.h> namespace turbodbc_numpy { void set_numpy_parameters(turbodbc::bo...
Support integer parameters that fit in a single buffer
Support integer parameters that fit in a single buffer
C++
mit
blue-yonder/turbodbc,blue-yonder/turbodbc,blue-yonder/turbodbc,blue-yonder/turbodbc
83fc84f5e24d9659d9fd0d63f93c31666fe2acf1
src/runtime/android_io.cpp
src/runtime/android_io.cpp
#include "mini_stdint.h" #define WEAK __attribute__((weak)) extern "C" { extern int __android_log_vprint(int, const char *, const char *, __builtin_va_list); WEAK int halide_printf(void *user_context, const char * fmt, ...) { __builtin_va_list args; __builtin_va_start(args,fmt); int result = __android_l...
#include "mini_stdint.h" #define WEAK __attribute__((weak)) extern "C" { extern int __android_log_vprint(int, const char *, const char *, __builtin_va_list); #define ANDROID_LOG_INFO 4 WEAK int halide_printf(void *user_context, const char * fmt, ...) { __builtin_va_list args; __builtin_va_start(args,fmt); ...
Make halide_printf output to LOG_INFO, not LOG_FATAL
Make halide_printf output to LOG_INFO, not LOG_FATAL Former-commit-id: 645fa2bb2a4a579a7d0fc799814c27da4b9757e4
C++
mit
Trass3r/Halide,Trass3r/Halide,Trass3r/Halide,darkbuck/Halide,darkbuck/Halide,darkbuck/Halide,Trass3r/Halide,Trass3r/Halide,Trass3r/Halide,darkbuck/Halide,darkbuck/Halide,Trass3r/Halide,darkbuck/Halide,darkbuck/Halide
bf250ddd86a39b217facedc4fc53a87bae5b2dcd
tests/img_vol_test.cc
tests/img_vol_test.cc
#include <iostream> #include "img_vol.h" #include "operations.h" #include "img2d.h" int main(int argc, char **argv) { ImgVol img("/home/alex/Downloads/libmo815-3dvis/data/brain.scn"); std::cout << img << "\n"; std::cout << img(57, 9, 35) << "\n"; Img2D img2d = Cut(img, ImgVol::Axis::Z, 40); std::cout << i...
#include <iostream> #include "img_vol.h" #include "operations.h" #include "img2d.h" int main(int argc, char **argv) { ImgVol img("/home/alex/Downloads/libmo815-3dvis/data/brain.scn"); std::cout << img << "\n"; std::cout << img(57, 9, 35) << "\n"; Img2D img2dz = Cut(img, ImgVol::Axis::Z, 40); std::cout << ...
Test cut in all axis
Test cut in all axis
C++
apache-2.0
alexst07/volimg,alexst07/volimg
dcb3fd93562a69667a57c8d20a9c03a93541cbce
examples/demo/window.cc
examples/demo/window.cc
/* Copyright (C) 2008 The goocanvasmm Development Team * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; either * version 2.1 of the License, or (at your option) any later version. ...
/* Copyright (C) 2008 The goocanvasmm Development Team * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; either * version 2.1 of the License, or (at your option) any later version. ...
Use of range-based for loop.
C++11: Use of range-based for loop.
C++
lgpl-2.1
GNOME/goocanvasmm,GNOME/goocanvasmm,GNOME/goocanvasmm
984eab9691b5faab1bc8bc48dc30e929c608d738
views/events/event_aura.cc
views/events/event_aura.cc
// Copyright (c) 2011 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "views/events/event.h" #include "base/logging.h" #include "ui/aura/event.h" namespace views { ////////////////////////////////////////////...
// Copyright (c) 2011 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "views/events/event.h" #include "base/logging.h" #include "ui/aura/event.h" namespace views { ////////////////////////////////////////////...
Fix the KeyEvent unit test failure due to the aura implementation of GetUnmodifiedCharacter().
Fix the KeyEvent unit test failure due to the aura implementation of GetUnmodifiedCharacter(). BUG=99129 TEST=NONE Review URL: http://codereview.chromium.org/8286006 git-svn-id: de016e52bd170d2d4f2344f9bf92d50478b649e0@105549 0039d316-1c4b-4281-b951-d872f2087c98
C++
bsd-3-clause
Fireblend/chromium-crosswalk,ondra-novak/chromium.src,axinging/chromium-crosswalk,littlstar/chromium.src,crosswalk-project/chromium-crosswalk-efl,mogoweb/chromium-crosswalk,bright-sparks/chromium-spacewalk,hgl888/chromium-crosswalk-efl,mohamed--abdel-maksoud/chromium.src,fujunwei/chromium-crosswalk,pozdnyakov/chromium-...
c6a339a4b267bad46922e3f7f47f46cbe710827d
lib/sanitizer_common/tests/sanitizer_test_main.cc
lib/sanitizer_common/tests/sanitizer_test_main.cc
//===-- sanitizer_test_main.cc --------------------------------------------===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===-------------------------------------------------------...
//===-- sanitizer_test_main.cc --------------------------------------------===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===-------------------------------------------------------...
Initialize common flags to default values in unit tests.
[Sanitizer] Initialize common flags to default values in unit tests. git-svn-id: c199f293c43da69278bea8e88f92242bf3aa95f7@245363 91177308-0d34-0410-b5e6-96231b3b80d8
C++
apache-2.0
llvm-mirror/compiler-rt,llvm-mirror/compiler-rt,llvm-mirror/compiler-rt,llvm-mirror/compiler-rt,llvm-mirror/compiler-rt
9f39576c439918edbfda7743f7f991cab05286b0
src/visual.cc
src/visual.cc
#include <string> #include "configuration.hh" namespace vick { int from_visual(const std::string& cont, int x) { if(cont.size() == 0) return 0; int count = 0, til = 0; int numTab = 0; for(unsigned int i = 0; i < cont.length(); i++) { unsigned int len; if(cont[i] == '\t') { ...
#include <string> #include "configuration.hh" namespace vick { int from_visual(const std::string& cont, int x) { if(cont.size() == 0) return 0; int count = 0, til = 0; int numTab = 0; for(size_t i = 0; i < cont.length(); i++) { size_t len; if(cont[i] == '\t') { len...
Use ``size_t`` for array types
Use ``size_t`` for array types
C++
mpl-2.0
czipperz/vick,czipperz/vick
29a338318343c8af0a6e70dc9caecbd816d15f80
android/jni/InteriorsPosition/View/SenionLab/SenionLabBroadcastReceiverJni.cpp
android/jni/InteriorsPosition/View/SenionLab/SenionLabBroadcastReceiverJni.cpp
// Copyright eeGeo Ltd (2012-2017), All Rights Reserved #include <jni.h> #include "AndroidAppThreadAssertionMacros.h" #include "SenionLabBroadCastReceiver.h" #include "SenionLabBroadCastReceiverJni.h" extern "C" { JNIEXPORT void JNICALL Java_com_eegeo_interiorsposition_senionlab_SenionLabBroadcastReceiverJniMethods_...
// Copyright eeGeo Ltd (2012-2017), All Rights Reserved #include <jni.h> #include "AndroidAppThreadAssertionMacros.h" #include "SenionLabBroadcastReceiver.h" #include "SenionLabBroadcastReceiverJni.h" extern "C" { JNIEXPORT void JNICALL Java_com_eegeo_interiorsposition_senionlab_SenionLabBroadcastReceiverJniMethods_...
Fix non-portable include path in senion broadcast receiver include. Buddy: Blair
Fix non-portable include path in senion broadcast receiver include. Buddy: Blair
C++
bsd-2-clause
wrld3d/wrld-example-app,eegeo/eegeo-example-app,wrld3d/wrld-example-app,eegeo/eegeo-example-app,wrld3d/wrld-example-app,eegeo/eegeo-example-app,wrld3d/wrld-example-app,wrld3d/wrld-example-app,eegeo/eegeo-example-app,eegeo/eegeo-example-app,wrld3d/wrld-example-app,eegeo/eegeo-example-app,eegeo/eegeo-example-app,wrld3d/w...
edc85bd1cd77eb1eb5c13bbffce2414f1e6552bb
Xcode/ESP/src/user.cpp
Xcode/ESP/src/user.cpp
#include "user.h" // This is a hack. // Otherwise, we will need to create a target for each user application. #include "examples/user_audio_beat.cpp" //#include "examples/user_color_sensor.h" //#include "examples/user_accelerometer_gestures.h" //#include "examples/user_accelerometer_poses.h" //#include "examples/user_...
#include "user.h" // This is a hack. // Otherwise, we will need to create a target for each user application. #include "examples/user_audio_beat.cpp" //#include "examples/user_color_sensor.cpp" //#include "examples/user_accelerometer_gestures.cpp" //#include "examples/user_accelerometer_poses.cpp" //#include "examples...
Update example file extensions (.h to .cpp).
Update example file extensions (.h to .cpp).
C++
bsd-3-clause
damellis/ESP,damellis/ESP
df47fa9d4ae5494ef8a1e2cec1511eeaabc19629
tests/test__hnc.cpp
tests/test__hnc.cpp
// Copyright © 2012 Lénaïc Bagnères, hnc@singularity.fr // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable ...
// Copyright © 2012 Lénaïc Bagnères, hnc@singularity.fr // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable ...
Fix hnc version and codename test
Fix hnc version and codename test
C++
apache-2.0
seken/hnc
a7212b772e55e1f04493a33adb69c61db1dab8b7
common/library_main.cc
common/library_main.cc
#include "common/library_main.h" #include "common/main_delegate.h" #include "content/public/app/content_main.h" int BrightrayExampleMain(int argc, const char* argv[]) { brightray_example::MainDelegate delegate; return content::ContentMain(argc, argv, &delegate); }
#include "common/library_main.h" #include "common/main_delegate.h" #include "content/public/app/content_main.h" int BrightrayExampleMain(int argc, const char* argv[]) { brightray_example::MainDelegate delegate; content::ContentMainParams params(&delegate); params.argc = argc; params.argv = argv; return cont...
Update for changes to content::ContentMain
Update for changes to content::ContentMain
C++
mit
atom/brightray_example,atom/brightray_example,atom/brightray_example
ef906163c54a97865ca0884b52eab19b655b331f
JASP-Common/appinfo.cpp
JASP-Common/appinfo.cpp
// // Copyright (C) 2016 University of Amsterdam // // This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 2 of the License, or // (at your option) any later version. // // This progr...
// // Copyright (C) 2016 University of Amsterdam // // This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 2 of the License, or // (at your option) any later version. // // This progr...
Prepare 0.8.0 Beta 2 release
Prepare 0.8.0 Beta 2 release
C++
agpl-3.0
jasp-stats/jasp-desktop,AlexanderLyNL/jasp-desktop,jasp-stats/jasp-desktop,AlexanderLyNL/jasp-desktop,FransMeerhoff/jasp-desktop,aknight1-uva/jasp-desktop,aknight1-uva/jasp-desktop,aknight1-uva/jasp-desktop,AlexanderLyNL/jasp-desktop,boutinb/jasp-desktop,jasp-stats/jasp-desktop,raviselker/jasp-desktop,TimKDJ/jasp-deskt...
74fa2c809d7727d3ff792b7f29abd5a797be1095
atom/common/event_emitter_caller.cc
atom/common/event_emitter_caller.cc
// Copyright (c) 2015 GitHub, Inc. // Use of this source code is governed by the MIT license that can be // found in the LICENSE file. #include "atom/common/event_emitter_caller.h" #include "atom/common/node_includes.h" namespace mate { namespace internal { v8::Local<v8::Value> CallEmitWithArgs(v8::Isolate* isolat...
// Copyright (c) 2015 GitHub, Inc. // Use of this source code is governed by the MIT license that can be // found in the LICENSE file. #include "atom/common/event_emitter_caller.h" #include "base/memory/scoped_ptr.h" #include "third_party/WebKit/public/web/WebScopedMicrotaskSuppression.h" #include "atom/common/node_...
Make every JS function call is wrapped with V8RecursionScope
Make every JS function call is wrapped with V8RecursionScope
C++
mit
felixrieseberg/electron,jcblw/electron,dongjoon-hyun/electron,thomsonreuters/electron,Neron-X5/electron,sircharleswatson/electron,IonicaBizauKitchen/electron,jaanus/electron,arusakov/electron,robinvandernoord/electron,evgenyzinoviev/electron,gbn972/electron,shockone/electron,anko/electron,tylergibson/electron,bitemyapp...
279562c32afed79f4b45eefdd69b3d67a8dc372d
src/message_passing.cpp
src/message_passing.cpp
#include "message_passing.h" namespace openmc { namespace mpi { int rank; int n_procs; #ifdef OPENMC_MPI MPI_Comm intracomm; MPI_Datatype bank; #endif } // namespace mpi } // namespace openmc
#include "message_passing.h" namespace openmc { namespace mpi { int rank {0}; int n_procs {1}; #ifdef OPENMC_MPI MPI_Comm intracomm; MPI_Datatype bank; #endif } // namespace mpi } // namespace openmc
Make sure rank/nprocs is set for serial runs
Make sure rank/nprocs is set for serial runs
C++
mit
wbinventor/openmc,mit-crpg/openmc,wbinventor/openmc,mit-crpg/openmc,amandalund/openmc,liangjg/openmc,paulromano/openmc,liangjg/openmc,walshjon/openmc,walshjon/openmc,paulromano/openmc,wbinventor/openmc,paulromano/openmc,wbinventor/openmc,amandalund/openmc,shikhar413/openmc,smharper/openmc,shikhar413/openmc,johnnyliu27/...
46a20a5266a4edd7251420f11492ca5b16c26248
src/miniMAT/miniMAT.cpp
src/miniMAT/miniMAT.cpp
#include <iostream> #include <string> #include <Lexer.hpp> #include <Parser.hpp> #include <Visitors.hpp> int main() { std::string input_line; double ans = 0; while (true) { std::cout << ">>> "; std::getline(std::cin, input_line); if (input_line == "quit" || input_line == "exit")...
#include <iostream> #include <string> #include <Lexer.hpp> #include <Parser.hpp> #include <Visitors.hpp> int main() { std::string input_line; double ans = 0; std::cout << "miniMAT: It's like MATLAB, but smaller." << std::endl; std::cout << "Copyright (C) 2014 Federico Menozzi" << std::endl; std:...
Add description and copyright, and add space in between prompts
Add description and copyright, and add space in between prompts
C++
mit
fmenozzi/miniMAT,fmenozzi/miniMAT
a76b9f90d58a8ccc69e362a5982dd59bae10529c
src/ports/SkDebug_android.cpp
src/ports/SkDebug_android.cpp
/* * Copyright 2006 The Android Open Source Project * * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ #include "SkTypes.h" static const size_t kBufferSize = 256; #define LOG_TAG "skia" #include <android/log.h> void SkDebugf(const char format[], ...) { ...
/* * Copyright 2006 The Android Open Source Project * * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ #include "SkTypes.h" static const size_t kBufferSize = 256; #define LOG_TAG "skia" #include <android/log.h> static bool gSkDebugToStdOut = false; ext...
Enable Android executables (like skia_launcher) to redirect SkDebugf output to stdout as well as the system logs.
Enable Android executables (like skia_launcher) to redirect SkDebugf output to stdout as well as the system logs. Review URL: https://codereview.appspot.com/6733065
C++
bsd-3-clause
csulmone/skia,csulmone/skia,csulmone/skia,csulmone/skia
3e1bdd6d69d94565e014b1f2806659d91f4f6db2
COFF/Error.cpp
COFF/Error.cpp
//===- Error.cpp ----------------------------------------------------------===// // // The LLVM Linker // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===----------------------------------------------------------------...
//===- Error.cpp ----------------------------------------------------------===// // // The LLVM Linker // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===----------------------------------------------------------------...
Print error message header in red.
Print error message header in red. git-svn-id: f6089bf0e6284f307027cef4f64114ee9ebb0424@288110 91177308-0d34-0410-b5e6-96231b3b80d8
C++
apache-2.0
llvm-mirror/lld,llvm-mirror/lld
b71e806744bc20b2049d3fddc91aeac72fa9e8d2
programs/wanproxy/wanproxy_config_class_interface.cc
programs/wanproxy/wanproxy_config_class_interface.cc
#include <config/config_class.h> #include <config/config_object.h> #include <config/config_value.h> #include "wanproxy_config_class_interface.h" WANProxyConfigClassInterface wanproxy_config_class_interface; bool WANProxyConfigClassInterface::activate(ConfigObject *) { /* Eventually would like to do something more u...
#include <config/config_class.h> #include <config/config_object.h> #include <config/config_value.h> #include "wanproxy_config_class_interface.h" WANProxyConfigClassInterface wanproxy_config_class_interface; bool WANProxyConfigClassInterface::activate(ConfigObject *co) { if (!ConfigClassAddress::activate(co)) retu...
Call base class activation routine.
Call base class activation routine. git-svn-id: 9e2532540f1574e817ce42f20b9d0fb64899e451@198 4068ffdb-0463-0410-8185-8cc71e3bd399
C++
bsd-2-clause
diegows/wanproxy,splbio/wanproxy,diegows/wanproxy,diegows/wanproxy,splbio/wanproxy,splbio/wanproxy
bc72d205201930ab9baef8bc203395d548e600f7
cmake/usCMakeResourceDependencies.cpp
cmake/usCMakeResourceDependencies.cpp
/*============================================================================= Library: CppMicroServices Copyright (c) German Cancer Research Center, Division of Medical and Biological Informatics Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in complia...
/*============================================================================= Library: CppMicroServices Copyright (c) German Cancer Research Center, Division of Medical and Biological Informatics Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in complia...
Use more complicated dummy code to silence ranlib on MacOS.
Use more complicated dummy code to silence ranlib on MacOS.
C++
apache-2.0
CppMicroServices/CppMicroServices,ksubramz/CppMicroServices,saschazelzer/CppMicroServices,CppMicroServices/CppMicroServices,ksubramz/CppMicroServices,CppMicroServices/CppMicroServices,CppMicroServices/CppMicroServices,saschazelzer/CppMicroServices,CppMicroServices/CppMicroServices,ksubramz/CppMicroServices,ksubramz/Cpp...
43014faa21b51acaba10bb94d84def22f82f9b8c
examples/nlohmann_json/main.cpp
examples/nlohmann_json/main.cpp
#include <iostream> #include <nlohmann/json.hpp> int main (int argc, char** argv) { // for convenience using json = nlohmann::json; json j2 = { {"pi", 3.141}, {"happy", true}, {"name", "Niels"}, {"nothing", nullptr}, {"answer", { {"everything", 42} }}, {"list", {1, 0, 2}}, ...
#include <iostream> #include <json.hpp> int main (int argc, char** argv) { // for convenience using json = nlohmann::json; json j2 = { {"pi", 3.141}, {"happy", true}, {"name", "Niels"}, {"nothing", nullptr}, {"answer", { {"everything", 42} }}, {"list", {1, 0, 2}}, {"object...
FIX example nlohman_json include changed with V2.1.1
FIX example nlohman_json include changed with V2.1.1
C++
bsd-2-clause
stohrendorf/hunter,dvirtz/hunter,Knitschi/hunter,dan-42/hunter,shekharhimanshu/hunter,vdsrd/hunter,fwinnen/hunter,mchiasson/hunter,ikliashchou/hunter,dan-42/hunter,stohrendorf/hunter,madmongo1/hunter,ikliashchou/hunter,xsacha/hunter,ikliashchou/hunter,ingenue/hunter,dan-42/hunter,ErniBrown/hunter,dan-42/hunter,caseymcc...
e283a7302ee5774dee8d87fd433d7eb8b4ad1b18
badger/src/main.cpp
badger/src/main.cpp
#include <iostream> #include <stdexcept> #include "Badger.hpp" int main() { try { badger::Badger b; b.run(); return EXIT_SUCCESS; } catch(const std::exception &e) { std::cout << e.what() << std::endl; } }
#include <iostream> #include <stdexcept> #include "Badger.hpp" // Include cstdlib for EXIT_SUCCESS with MinGW #include <cstdlib> int main() { try { badger::Badger b; b.run(); return EXIT_SUCCESS; } catch(const std::exception &e) { std::cout << e.what() << std::en...
Support accrus pour la compilation avec MinGW
Support accrus pour la compilation avec MinGW
C++
bsd-3-clause
projetpeip-montp2/badger
3124b9d9cd32f608794cc4bf6ead75e9115b4821
paddle/platform/place_test.cc
paddle/platform/place_test.cc
#include "paddle/platform/place.h" #include "gtest/gtest.h" #include <sstream> TEST(Place, Equality) { paddle::platform::CpuPlace cpu; paddle::platform::GpuPlace g0(0), g1(1), gg0(0); EXPECT_EQ(cpu, cpu); EXPECT_EQ(g0, g0); EXPECT_EQ(g1, g1); EXPECT_EQ(g0, gg0); EXPECT_NE(g0, g1); EXPECT_TRUE(paddle...
#include "paddle/platform/place.h" #include <sstream> #include "gtest/gtest.h" TEST(Place, Equality) { paddle::platform::CpuPlace cpu; paddle::platform::GpuPlace g0(0), g1(1), gg0(0); EXPECT_EQ(cpu, cpu); EXPECT_EQ(g0, g0); EXPECT_EQ(g1, g1); EXPECT_EQ(g0, gg0); EXPECT_NE(g0, g1); EXPECT_TRUE(paddle...
Make Google style include order
Make Google style include order
C++
apache-2.0
hedaoyuan/Paddle,reyoung/Paddle,hedaoyuan/Paddle,jacquesqiao/Paddle,reyoung/Paddle,luotao1/Paddle,pengli09/Paddle,PaddlePaddle/Paddle,chengduoZH/Paddle,hedaoyuan/Paddle,hedaoyuan/Paddle,luotao1/Paddle,tensor-tang/Paddle,Canpio/Paddle,Canpio/Paddle,chengduoZH/Paddle,luotao1/Paddle,tensor-tang/Paddle,lcy-seso/Paddle,peng...
d38d150515480913008b0a7f196f7dc70008bae5
src/Platform.Emscripten/TimeSourceEmscripten.cpp
src/Platform.Emscripten/TimeSourceEmscripten.cpp
// Copyright (c) 2013-2021 mogemimi. Distributed under the MIT license. #include "TimeSourceEmscripten.hpp" #include <emscripten.h> namespace Pomdog::Detail::Emscripten { TimePoint TimeSourceEmscripten::Now() const { const auto now = ::emscripten_get_now(); return TimePoint{Duration{static_cast<double>(now)}...
// Copyright (c) 2013-2021 mogemimi. Distributed under the MIT license. #include "TimeSourceEmscripten.hpp" #include <emscripten.h> #include <type_traits> namespace Pomdog::Detail::Emscripten { TimePoint TimeSourceEmscripten::Now() const { const auto now = ::emscripten_get_now(); static_assert(std::is_same_v...
Fix time source for emscripten
Fix time source for emscripten
C++
mit
mogemimi/pomdog,mogemimi/pomdog,mogemimi/pomdog
d8bdeb72e7987dfba132f1d00f4f2f99c76ac90f
demo/mpi/hello/Main.cpp
demo/mpi/hello/Main.cpp
#include <mpi.h> #include <iostream> using namespace std; int main() { MPI::Init(); int rank = MPI::COMM_WORLD.Get_rank(); int size = MPI::COMM_WORLD.Get_size(); cout << "Hello from rank " << rank << " of " << size << "!" << endl; MPI::Finalize(); }
#include <cstdlib> #include <iostream> #include <mpi.h> #include <string> #ifndef HOST_NAME_MAX #define HOST_NAME_MAX 256 #endif using namespace std; int main() { MPI::Init(); int rank = MPI::COMM_WORLD.Get_rank(); int size = MPI::COMM_WORLD.Get_size(); char host[HOST_NAME_MAX]; int status = gethostname(host,...
Print hostname where hellompi runs
Print hostname where hellompi runs
C++
mit
mp13on11/dwarf_mine,mp13on11/dwarf_mine,mp13on11/dwarf_mine,mp13on11/dwarf_mine
18ccdb02e5c9f40d06526101e6d6c928447fd43e
tests/Tools/WhiteNoiseGeneratorFilter.cpp
tests/Tools/WhiteNoiseGeneratorFilter.cpp
/** * \ file WhiteNoiseGeneratorFilter.cpp */ #include <cmath> #include <ATK/Tools/WhiteNoiseGeneratorFilter.h> #include <array> #define BOOST_TEST_DYN_LINK #define BOOST_TEST_NO_MAIN #include <boost/test/unit_test.hpp> const size_t PROCESSSIZE = 1024*1024; BOOST_AUTO_TEST_CASE( WhiteNoiseGeneratorFilter_volume...
/** * \ file WhiteNoiseGeneratorFilter.cpp */ #include <cmath> #include <ATK/Tools/WhiteNoiseGeneratorFilter.h> #include <array> #define BOOST_TEST_DYN_LINK #define BOOST_TEST_NO_MAIN #include <boost/test/unit_test.hpp> const size_t PROCESSSIZE = 1024*1024; BOOST_AUTO_TEST_CASE( WhiteNoiseGeneratorFilter_volume...
Comment white noise test for now
Comment white noise test for now
C++
bsd-3-clause
mbrucher/AudioTK,mbrucher/AudioTK,mbrucher/AudioTK,mbrucher/AudioTK
387b19605d32a63657d198be445a96f82f665dee
src/RoundRobinPartitioner.cpp
src/RoundRobinPartitioner.cpp
#include "RoundRobinPartitioner.hpp" #include <vector> #include <iostream> #include "LogicalProcess.hpp" namespace warped { std::vector<std::vector<LogicalProcess*>> RoundRobinPartitioner::partition( const std::vector<LogicalProcess*>& lps, ...
#include "RoundRobinPartitioner.hpp" #include <vector> #include <iostream> #include "LogicalProcess.hpp" namespace warped { std::vector<std::vector<LogicalProcess*>> RoundRobinPartitioner::partition( const std::vector<LogicalProcess*>& lps, ...
Add upper bound on partitioning block size
Add upper bound on partitioning block size
C++
mit
wilseypa/warped2
8653b37ab97ce69e8ff81e28f702ae94e20f6dec
lib/CodeGen/Passes.cpp
lib/CodeGen/Passes.cpp
//===-- Passes.cpp - Target independent code generation passes ------------===// // // The LLVM Compiler Infrastructure // // This file was developed by the LLVM research group and is distributed under // the University of Illinois Open Source License. See LICENSE.TXT for details. // //===----------...
//===-- Passes.cpp - Target independent code generation passes ------------===// // // The LLVM Compiler Infrastructure // // This file was developed by the LLVM research group and is distributed under // the University of Illinois Open Source License. See LICENSE.TXT for details. // //===----------...
Work around a bug in gcc 3.3.5, reported by a user
Work around a bug in gcc 3.3.5, reported by a user git-svn-id: 0ff597fd157e6f4fc38580e8d64ab130330d2411@29489 91177308-0d34-0410-b5e6-96231b3b80d8
C++
apache-2.0
apple/swift-llvm,dslab-epfl/asap,llvm-mirror/llvm,apple/swift-llvm,dslab-epfl/asap,GPUOpen-Drivers/llvm,apple/swift-llvm,dslab-epfl/asap,chubbymaggie/asap,llvm-mirror/llvm,llvm-mirror/llvm,apple/swift-llvm,dslab-epfl/asap,GPUOpen-Drivers/llvm,dslab-epfl/asap,apple/swift-llvm,GPUOpen-Drivers/llvm,apple/swift-llvm,llvm-m...
c216af3d3f0e910ba95eabe6d2f5a3574f051bd4
gleri/rglrp.cc
gleri/rglrp.cc
// This file is part of the GLERI project // // Copyright (c) 2012 by Mike Sharov <msharov@users.sourceforge.net> // This file is free software, distributed under the MIT License. #include "rglrp.h" #define N(n,s) "\0" #n "\0" #s "\0" /*static*/ const char PRGLR::_cmdNames[] = N(Error,s) N(Restate,(qqqqyyyy...
// This file is part of the GLERI project // // Copyright (c) 2012 by Mike Sharov <msharov@users.sourceforge.net> // This file is free software, distributed under the MIT License. #include "rglrp.h" #define N(n,s) "\0" #n "\0" #s "\0" /*static*/ const char PRGLR::_cmdNames[] = N(GLError,s) N(Restate,(qqqqyy...
Rename Error call to GLError
Rename Error call to GLError
C++
mit
msharov/gleri,msharov/gleri
00e574878ae1b8c304a1c8eab970cbd5fd09307d
EasyCC.cpp
EasyCC.cpp
#include "lexical/Lexical.h" #include <iostream> #include <vector> #include <string> using namespace std; using namespace ecc; int main() { Lexical lexical( "/home/amir/github/EasyCC-CPP/lexical/state_machine.json", "/home/amir/github/EasyCC-CPP/lexical/config.json", "/home/amir/github/EasyCC-CPP/l...
#include "lexical/Lexical.h" #include <iostream> #include <vector> #include <string> using namespace std; using namespace ecc; int main() { Lexical lexical( "/home/amir/github/EasyCC-CPP/lexical/state_machine.json", "/home/amir/github/EasyCC-CPP/lexical/config.json", "/home/amir/github/EasyCC-CPP/l...
Exit program on lexical errors
Exit program on lexical errors
C++
mit
amirbawab/EasyCC-CPP
a207390d180fe9544a7d49d560f6d98138f8fd46
mainwindow.cpp
mainwindow.cpp
#include "mainwindow.h" #include "ui_mainwindow.h" MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent), ui(new Ui::MainWindow) { ui->setupUi(this); } MainWindow::~MainWindow() { delete ui; }
#include "mainwindow.h" #include "ui_mainwindow.h" MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent), ui(new Ui::MainWindow) { ui->setupUi(this); QStringList tauList; tauList << "1" << "0.1" << "0.01" << "0.001" << "0.0001"; ui->tauComboBox->addItems(tauList); } MainWindow::~MainWi...
Add initialize tauComboBox in MainWindow class constructor.
Add initialize tauComboBox in MainWindow class constructor.
C++
mit
ivanshchitov/solving-system-ode
aa3d4ad19f9ec72990b2a0fff828baa5b7bdde39
test/EasyRandomTest.cpp
test/EasyRandomTest.cpp
#define CATCH_CONFIG_MAIN // This tells Catch to provide a main() - only do this in one cpp file #include "catch.hpp" #include "EasyRandom.hpp" using namespace EasyRandom; TEST_CASE( "TEST_TEST", "RANDOM" ) { const auto randomNumber = Random::get( ); REQUIRE( randomNumber >= -10 ); REQUIRE( randomNumber ...
#define CATCH_CONFIG_MAIN // This tells Catch to provide a main() - only do this in one cpp file #include "catch.hpp" #include "EasyRandom.hpp" #include <limits> using namespace EasyRandom; TEST_CASE( "Test random random" ) { const auto firstRandomNumber = Random::get( std::numeric_limits<std::intmax_t>::min( ),...
Add tests for generating random integer numbers
Add tests for generating random integer numbers
C++
mit
effolkronium/EasyRandom
3cfa040a7e6df018bd32acd2ee0c5fcd9cfe3535
source/crate_demo/main.cpp
source/crate_demo/main.cpp
/* The Halfling Project - A Graphics Engine and Projects * * The Halfling Project is the legal property of Adrian Astley * Copyright Adrian Astley 2013 */ #include "halfling/halfling_engine.h" #include "crate_demo/graphics_manager.h" #include "crate_demo/game_state_manager.h" int WINAPI WinMain(HINSTANCE hInsta...
/* The Halfling Project - A Graphics Engine and Projects * * The Halfling Project is the legal property of Adrian Astley * Copyright Adrian Astley 2013 */ #include "halfling/halfling_engine.h" #include "crate_demo/graphics_manager.h" #include "crate_demo/game_state_manager.h" int WINAPI WinMain(HINSTANCE hInsta...
Create the GraphicsManager after the GameStateManager
CRATE_DEMO: Create the GraphicsManager after the GameStateManager So the GameStateManager can be passed to the GraphicsManager
C++
apache-2.0
RichieSams/thehalflingproject,RichieSams/thehalflingproject,RichieSams/thehalflingproject
04c6a29cb2934d2104d90182730fc936f0fcb8b4
source/crate_demo/main.cpp
source/crate_demo/main.cpp
/* The Halfling Project - A Graphics Engine and Projects * * The Halfling Project is the legal property of Adrian Astley * Copyright Adrian Astley 2013 */ #include "halfling/halfling_engine.h" #include "crate_demo/graphics_manager.h" #include "crate_demo/game_state_manager.h" namespace CrateDemo { int APIENTRY...
/* The Halfling Project - A Graphics Engine and Projects * * The Halfling Project is the legal property of Adrian Astley * Copyright Adrian Astley 2013 */ #include "halfling/halfling_engine.h" #include "crate_demo/graphics_manager.h" #include "crate_demo/game_state_manager.h" int WINAPI WinMain(HINSTANCE hInsta...
Remove namespace from around WinMain
CRATE_DEMO: Remove namespace from around WinMain Windows API expects WinMain to be in the global namespace
C++
apache-2.0
RichieSams/thehalflingproject,RichieSams/thehalflingproject,RichieSams/thehalflingproject
c42bc9a82844f36876da823e6fb9938f2d7dc738
src/main.cpp
src/main.cpp
#include <boost/function.hpp> #include <boost/shared_ptr.hpp> #include <boost/make_shared.hpp> #include <boost/bind.hpp> #include <boost/lambda/lambda.hpp> #include <boost/foreach.hpp> #include <boost/type_traits.hpp> #define foreach BOOST_FOREACH #include <vector> #include <string> #include <algorithm> #include <ios...
#include <boost/function.hpp> #include <boost/shared_ptr.hpp> #include <boost/make_shared.hpp> #include <boost/bind.hpp> #include <boost/lambda/lambda.hpp> #include <boost/foreach.hpp> #include <boost/type_traits.hpp> #define foreach BOOST_FOREACH #include <vector> #include <string> #include <algorithm> #include <ios...
Add item_exists to wrap find_if.
Add item_exists to wrap find_if.
C++
mit
mrts/algorithm-utils-cpp,mrts/algorithm-utils-cpp
cad7687580aaff3d0ec6632e716b01cc2b9abca1
lib/Target/Hexagon/MCTargetDesc/HexagonMCAsmInfo.cpp
lib/Target/Hexagon/MCTargetDesc/HexagonMCAsmInfo.cpp
//===-- HexagonMCAsmInfo.cpp - Hexagon asm properties ---------------------===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===-------------------------------------------------------...
//===-- HexagonMCAsmInfo.cpp - Hexagon asm properties ---------------------===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===-------------------------------------------------------...
Delete a dead store found by PVS-Studio.
Delete a dead store found by PVS-Studio. Quite sad we still aren't really using aggressive dead code warnings from Clang that we could potentially use to catch this and so many other things. git-svn-id: 0ff597fd157e6f4fc38580e8d64ab130330d2411@285936 91177308-0d34-0410-b5e6-96231b3b80d8
C++
apache-2.0
apple/swift-llvm,apple/swift-llvm,llvm-mirror/llvm,apple/swift-llvm,GPUOpen-Drivers/llvm,GPUOpen-Drivers/llvm,apple/swift-llvm,apple/swift-llvm,apple/swift-llvm,GPUOpen-Drivers/llvm,llvm-mirror/llvm,apple/swift-llvm,llvm-mirror/llvm,llvm-mirror/llvm,llvm-mirror/llvm,llvm-mirror/llvm,GPUOpen-Drivers/llvm,llvm-mirror/llv...
0d34db4dd84f93083c340c2e3251ff417986efb8
LintCode/457.cpp
LintCode/457.cpp
// Author: Shengjia Yan // Date: 2017年7月1日 // Email: sjyan@seu.edu.cn // Time Complexity: O(logn) // Space Complexity: O(1) class Solution { public: /** * @param A an integer array sorted in ascending order * @param target an integer * @return an integer */ int findPosition(vector<int>& A,...
// Author: Shengjia Yan // Date: 2017年7月1日 // Email: sjyan@seu.edu.cn // Time Complexity: O(logn) // Space Complexity: O(1) // 经典二分查找问题 class Solution { public: /** * @param A an integer array sorted in ascending order * @param target an integer * @return an integer */ int findPosition(vec...
Update the solution for the classic binary search problem
Update the solution for the classic binary search problem
C++
apache-2.0
yanMa1995/OnlineJudge,yanMa1995/OJ,yanshengjia/oj,yanshengjia/oj
d742548cbd85647132695cf7bb1b57e00273f6c3
chrome/browser/app_modal_dialog_queue.cc
chrome/browser/app_modal_dialog_queue.cc
// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "chrome/browser/app_modal_dialog_queue.h" #include "chrome/browser/browser_list.h" void AppModalDialogQueue::AddDialog(AppModalDialog*...
// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "chrome/browser/app_modal_dialog_queue.h" #include "chrome/browser/browser_list.h" void AppModalDialogQueue::AddDialog(AppModalDialog*...
Set active_dialog_ before showing it, since showing a dialog can sometimes actually move to the next one in the queue instead.
Set active_dialog_ before showing it, since showing a dialog can sometimes actually move to the next one in the queue instead. BUG=26398 TEST=Make sure alert/confirm boxes work properly. Make sure a background tab that shows a (delayed) alert box works. Same with a background browser. Especially make sure http...
C++
bsd-3-clause
wistoch/meego-app-browser,wistoch/meego-app-browser,wistoch/meego-app-browser,wistoch/meego-app-browser,wistoch/meego-app-browser,wistoch/meego-app-browser,wistoch/meego-app-browser,wistoch/meego-app-browser,wistoch/meego-app-browser,wistoch/meego-app-browser
cbc4138acaeae6b0a87defecf02f6c1021741124
source/core/search-manager/DocumentIteratorContainer.cpp
source/core/search-manager/DocumentIteratorContainer.cpp
#include "DocumentIteratorContainer.h" #include "DocumentIterator.h" #include "CombinedDocumentIterator.h" using namespace sf1r; DocumentIteratorContainer::~DocumentIteratorContainer() { for (std::vector<DocumentIterator*>::iterator it = docIters_.begin(); it != docIters_.end(); ++it) { delet...
#include "DocumentIteratorContainer.h" #include "DocumentIterator.h" #include "CombinedDocumentIterator.h" using namespace sf1r; DocumentIteratorContainer::~DocumentIteratorContainer() { for (std::vector<DocumentIterator*>::iterator it = docIters_.begin(); it != docIters_.end(); ++it) { delet...
Fix bug: Search result should be empty for specific keyword. However, when the condition is set, search result become not empty.
Fix bug: Search result should be empty for specific keyword. However, when the condition is set, search result become not empty.
C++
apache-2.0
izenecloud/sf1r-lite,pombredanne/sf1r-lite,izenecloud/sf1r-lite,izenecloud/sf1r-ad-delivery,izenecloud/sf1r-lite,izenecloud/sf1r-lite,izenecloud/sf1r-ad-delivery,izenecloud/sf1r-ad-delivery,pombredanne/sf1r-lite,izenecloud/sf1r-ad-delivery,izenecloud/sf1r-lite,pombredanne/sf1r-lite,pombredanne/sf1r-lite,pombredanne/sf1...
55dc9595a25dd135bcdeff96dee77dafcd4575b6
bottleopener/shiftrConnector.cpp
bottleopener/shiftrConnector.cpp
#include "shiftrConnector.h" #include <Bridge.h> void ShiftrConnector::init(const char* deviceLogin, const char* pwd) { client.begin("broker.shiftr.io"); this->deviceLogin = deviceLogin; this->pwd = pwd; connect(); client.subscribe("/bottle-openner"); // client.unsubscribe("/bottle-openner"); } void ...
#include "shiftrConnector.h" #include <Bridge.h> void ShiftrConnector::init(const char* deviceLogin, const char* pwd) { client.begin("broker.shiftr.io"); this->deviceLogin = deviceLogin; this->pwd = pwd; connect(); client.subscribe("/bottle-openner"); // client.unsubscribe("/bottle-openner"); } void ...
Extend log when connected to the IoT platform
Extend log when connected to the IoT platform
C++
mit
Zenika/bottleopener_iot,Zenika/bottleopener_iot,Zenika/bottleopener_iot,Zenika/bottleopener_iot
d9e9a4f6f30cd281dd6283a5b94ce7c9399a67e9
stromx/raspi/test/RaspiCamTest.cpp
stromx/raspi/test/RaspiCamTest.cpp
/* * Copyright 2014 Matthias Fuchs * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to...
/* * Copyright 2014 Matthias Fuchs * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to...
Create raspi cam in test
Create raspi cam in test
C++
apache-2.0
sparsebase/stromx,sparsebase/stromx,uboot/stromx,uboot/stromx
b36c61ed92991cb95aea27cfd69c3576e657ce26
base/posix/safe_strerror.cc
base/posix/safe_strerror.cc
// Copyright 2009 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 "base/posix/safe_strerror.h" #include <errno.h> #include <stdio.h> #include <string.h> #include "base/stl_util.h" namespace base { void safe_...
// Copyright 2009 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 "base/posix/safe_strerror.h" #include <errno.h> #include <stdio.h> #include <string.h> #include "base/stl_util.h" #include "build/build_config....
Switch to GNU-style strerror_r when needed on Android.
Switch to GNU-style strerror_r when needed on Android. Certain Android configurations use GNU-style strerror_r, signaled by _GNU_SOURCE with __ANDROID_API__ >= 23. Change-Id: Ie2e8b0c6d7f8a3d18ede379745dff0dbef61970c Reviewed-on: https://chromium-review.googlesource.com/c/chromium/mini_chromium/+/1611030 Reviewed-by:...
C++
bsd-3-clause
chromium/mini_chromium,chromium/mini_chromium,chromium/mini_chromium
7b5ff0e810f0fae659fd1850871b30ceb11dfffd
examples/OnOffSwitch/OnOffSwitch.cpp
examples/OnOffSwitch/OnOffSwitch.cpp
#include <gtest/gtest.h> #include "OnOffSwitch.h" TEST(TestOnOffSwitch, main) { using namespace antoniocoratelli; OnOffSwitch on_off_switch; std::cout << on_off_switch.info() << std::endl; EXPECT_EQ(true, on_off_switch.in<StateOff>()); EXPECT_EQ(false, on_off_switch.in<StateOn>()); on_off_sw...
#include <gtest/gtest.h> #include "OnOffSwitch.h" TEST(TestOnOffSwitch, main) { using namespace antoniocoratelli; // Initializing the switch: it's Off by default. OnOffSwitch on_off_switch; std::cout << on_off_switch.info() << std::endl; EXPECT_EQ(true, on_off_switch.in<StateOff>()); EXPECT_EQ...
Add test cases and comments
Add test cases and comments
C++
bsd-3-clause
antoniocoratelli/state-machine
af317df4bb3065ab51fa63e5e1f963ca46542393
modules/Qnite/plugin/qniteartist.cpp
modules/Qnite/plugin/qniteartist.cpp
#include "qniteartist.h" QniteArtist::QniteArtist(QQuickItem* parent): QQuickItem(parent), m_axes{nullptr}, m_selectable{false} { } QniteArtist::~QniteArtist() { } QniteAxes* QniteArtist::axes() const { return m_axes; } void QniteArtist::setAxes(QniteAxes* axes) { if (m_axes != axes) { m_axes = axes; ...
#include "qniteartist.h" #include "qniteaxes.h" QniteArtist::QniteArtist(QQuickItem* parent): QQuickItem(parent), m_axes{nullptr}, m_selectable{false} { } QniteArtist::~QniteArtist() { } QniteAxes* QniteArtist::axes() const { return m_axes; } void QniteArtist::setAxes(QniteAxes* axes) { if (m_axes != axes...
Remove boilerplate anchors.fill parent from artists
Remove boilerplate anchors.fill parent from artists
C++
mit
evonove/qnite
ab4c55ed0018c99fd6379ec8575d2fafe4998b01
examples/dot_product.cpp
examples/dot_product.cpp
#include <numeric> #include <vector> #include "bulk/bulk.hpp" #include "set_backend.hpp" int main() { environment env; env.spawn(env.available_processors(), [](bulk::world& world, int s, int p) { // block distribution int size = 10; std::vector<int> xs(size); std::vector<int>...
#include <numeric> #include <vector> #include "bulk/bulk.hpp" #include "set_backend.hpp" int main() { environment env; env.spawn(env.available_processors(), [](bulk::world& world, int s, int p) { // block distribution int size = 1000; int local_size = size / p; std::vector<in...
Fix size of dot product
Fix size of dot product
C++
mit
jwbuurlage/Bulk
1d7fd3e5cf773ffc971ac069218b677b861daa83
apps/HelloAndroidCamera2/jni/edge_detect_generator.cpp
apps/HelloAndroidCamera2/jni/edge_detect_generator.cpp
#include "Halide.h" namespace { class EdgeDetect : public Halide::Generator<EdgeDetect> { public: ImageParam input{ UInt(8), 2, "input" }; Func build() { Var x, y; Func clamped = Halide::BoundaryConditions::repeat_edge(input); // Gradients in x and y. Func gx("gx"); ...
#include "Halide.h" namespace { class EdgeDetect : public Halide::Generator<EdgeDetect> { public: ImageParam input{ UInt(8), 2, "input" }; Func build() { Var x, y; Func clamped = Halide::BoundaryConditions::repeat_edge(input); // Gradients in x and y. Func gx("gx"); ...
Fix overflow bug in edge detector
Fix overflow bug in edge detector
C++
mit
aam/Halide,adasworks/Halide,tdenniston/Halide,lglucin/Halide,jiawen/Halide,tdenniston/Halide,lglucin/Halide,kgnk/Halide,dan-tull/Halide,myrtleTree33/Halide,psuriana/Halide,ronen/Halide,adasworks/Halide,lglucin/Halide,dougkwan/Halide,smxlong/Halide,aam/Halide,myrtleTree33/Halide,psuriana/Halide,damienfir/Halide,fengzhyu...
94e0a1badf329f760bf1d3b2a3a6cce931cc0dc5
src/keytar_posix.cc
src/keytar_posix.cc
#include "keytar.h" namespace keytar { bool AddPassword(const std::string& service, const std::string& account, const std::string& password) { return false; } bool GetPassword(const std::string& service, const std::string& account, std::string* pa...
#include "keytar.h" #include <gnome-keyring.h> namespace keytar { namespace { const GnomeKeyringPasswordSchema kGnomeSchema = { GNOME_KEYRING_ITEM_GENERIC_SECRET, { { "service", GNOME_KEYRING_ATTRIBUTE_TYPE_STRING }, { "account", GNOME_KEYRING_ATTRIBUTE_TYPE_STRING }, { NULL } } }; } // namespace ...
Implement with gnome-keyring on Linux.
Implement with gnome-keyring on Linux.
C++
mit
havoc-io/keytar,havoc-io/keytar,thesbros/node-keytar,atom/node-keytar,ehealthafrica-ci/node-keytar,adelcambre/node-keytar,thesbros/node-keytar,atom/node-keytar,eHealthAfrica/node-keytar,atom/node-keytar,havoc-io/keytar,xeno-io/keytar,atom/node-keytar,eHealthAfrica/node-keytar,adelcambre/node-keytar,ehealthafrica-ci/nod...
e7f2f77756d33c6be9c8998a575b263ff2d39270
src/util/syserror.cpp
src/util/syserror.cpp
// Copyright (c) 2020-2022 The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #if defined(HAVE_CONFIG_H) #include <config/bitcoin-config.h> #endif #include <tinyformat.h> #include <util/syserror.h> #in...
// Copyright (c) 2020-2022 The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #if defined(HAVE_CONFIG_H) #include <config/bitcoin-config.h> #endif #include <tinyformat.h> #include <util/syserror.h> #in...
Use strerror_s for SysErrorString on Windows
util: Use strerror_s for SysErrorString on Windows
C++
mit
namecoin/namecoin-core,ajtowns/bitcoin,kallewoof/bitcoin,sstone/bitcoin,AkioNak/bitcoin,GroestlCoin/GroestlCoin,sstone/bitcoin,particl/particl-core,particl/particl-core,jamesob/bitcoin,AkioNak/bitcoin,namecoin/namecoin-core,bitcoinsSG/bitcoin,sstone/bitcoin,instagibbs/bitcoin,kallewoof/bitcoin,jamesob/bitcoin,particl/p...
9620295c1b7788fc5fcaf334df3e328a906e9b93
tests/ADSRTest.cpp
tests/ADSRTest.cpp
#include <iostream> #include "../src/ADSR.h" using namespace std; int main() { homu::ADSR adsr(10000); adsr.setAttack(0); adsr.setDecay(0); adsr.setSustain(1); adsr.setRelease(0); adsr.start(); for (int i = 0; i < 10000; ++i) { float s = adsr.nextSample(); if (i >= 5000) {...
#include <iostream> #include "../src/ADSR.h" using namespace std; int main() { homu::ADSR adsr(10000); adsr.setAttack(0); adsr.setDecay(0); adsr.setSustain(1); adsr.setRelease(0); adsr.start(); for (int i = 0; i < 1000; ++i) { float s = adsr.nextSample(); if (i >= 500) { ...
Test some things in ADSR.
Test some things in ADSR.
C++
mit
Penguinum/Homulib,Penguinum/Homulib
4b116cc6f717cbb453d7273a582bcdd2de10350c
test/vbyte_test.cpp
test/vbyte_test.cpp
#include <gtest/gtest.h> #include <tudocomp/util/vbyte.hpp> #include "tudocomp/tudocomp.hpp" #include "test/util.hpp" using namespace tdc; template<class int_t> void test_vbyte(const int_t& i) { std::stringstream ss; write_vbyte(ss, i); DCHECK_EQ(read_vbyte<size_t>(ss), i) << ", contents of buffer: " << vec_to_de...
#include <gtest/gtest.h> #include <tudocomp/util/vbyte.hpp> #include "test/util.hpp" using namespace tdc; template<class int_t> void test_vbyte(const int_t& i) { std::stringstream ss; write_vbyte(ss, i); DCHECK_EQ(read_vbyte<size_t>(ss), i) << ", contents of buffer: " << vec_to_debug_string(ss.str()); } TEST(VBy...
Test push hook by removing unneeded include from test file
Test push hook by removing unneeded include from test file
C++
apache-2.0
tudocomp/tudocomp,tudocomp/tudocomp,tudocomp/tudocomp,tudocomp/tudocomp,tudocomp/tudocomp
77fbe78c6b1c675ec3f38e35477f99451dd769e8
linux/epoll/tests/Response.cpp
linux/epoll/tests/Response.cpp
#define BOOST_TEST_DYN_LINK #define BOOST_TEST_MAIN #define BOOST_TEST_MODULE state #include <boost/test/unit_test.hpp> #include "response.h" BOOST_AUTO_TEST_CASE(boolean_success_false) { cJSON *id = cJSON_CreateString("request1"); cJSON *response = create_boolean_success_response(id, 0); cJSON *result = cJSON_G...
#define BOOST_TEST_DYN_LINK #define BOOST_TEST_MAIN #define BOOST_TEST_MODULE state #include <boost/test/unit_test.hpp> #include "response.h" BOOST_AUTO_TEST_CASE(boolean_success_false) { cJSON *id = cJSON_CreateString("request1"); cJSON *response = create_boolean_success_response(id, 0); cJSON *result = cJSON_G...
Create test with wrong id type.
Create test with wrong id type.
C++
mit
gatzka/cjet,mloy/cjet,gatzka/cjet,mloy/cjet,mloy/cjet,gatzka/cjet,gatzka/cjet,mloy/cjet,gatzka/cjet,mloy/cjet
64d1370353f416c4ee5f1d2ea51eb875bac7b768
src/bicg/src/BiConjugateGradient.cpp
src/bicg/src/BiConjugateGradient.cpp
#include <Spark/SparseLinearSolvers.hpp> #include <iostream> Eigen::VectorXd spark::sparse_linear_solvers::DfeBiCgSolver::solve( const Eigen::SparseMatrix<double>& A, const Eigen::VectorXd& b) { Eigen::VectorXd vd(b.size()); return vd; }
#include <Spark/SparseLinearSolvers.hpp> #include <iostream> #include <stdexcept> using Vd = Eigen::VectorXd; Eigen::VectorXd spark::sparse_linear_solvers::DfeBiCgSolver::solve( const Eigen::SparseMatrix<double>& A, const Eigen::VectorXd& b) { std::cout << "Running bicgstab!!!" << std::endl...
Add hand written preconditioned bicgstab
Add hand written preconditioned bicgstab
C++
mit
caskorg/cask,caskorg/cask,caskorg/cask,caskorg/cask,caskorg/cask
ac64fab0f0b2a9941dafc5b063de704627fb8a9d
Sources/Rosetta/Tasks/SimpleTasks/SetGameTagTask.cpp
Sources/Rosetta/Tasks/SimpleTasks/SetGameTagTask.cpp
// This code is based on Sabberstone project. // Copyright (c) 2017-2019 SabberStone Team, darkfriend77 & rnilva // RosettaStone is hearthstone simulator using C++ with reinforcement learning. // Copyright (c) 2019 Chris Ohk, Youngjoong Kim, SeungHyun Jeon #include <Rosetta/Tasks/SimpleTasks/IncludeTask.hpp> #include ...
// This code is based on Sabberstone project. // Copyright (c) 2017-2019 SabberStone Team, darkfriend77 & rnilva // RosettaStone is hearthstone simulator using C++ with reinforcement learning. // Copyright (c) 2019 Chris Ohk, Youngjoong Kim, SeungHyun Jeon #include <Rosetta/Tasks/SimpleTasks/IncludeTask.hpp> #include ...
Add code to process windfury game tag
feat(card-impl): Add code to process windfury game tag
C++
mit
Hearthstonepp/Hearthstonepp,Hearthstonepp/Hearthstonepp
ecbf86876340d6af8bc29f0e4d2be73f38ed203f
02-Medium/War/WarGen.cpp
02-Medium/War/WarGen.cpp
#ifndef WARGEN_CPP #define WARGEN_CPP #include <algorithm> #include <vector> #include <iostream> #include <fstream> int main() { std::vector<char> cards = {'1','1','1','1','2','2','2','2','3','3','3','3','4','4','4','4','5','5','5','5','6','6','6','6','7','7','7','7','8','8','8','8','9','9','9','9','T','T','T','T','...
#ifndef WARGEN_CPP #define WARGEN_CPP #include <algorithm> #include <vector> #include <iostream> #include <fstream> int main() { std::vector<char> cards = {'1','1','1','1','2','2','2','2','3','3','3','3','4','4','4','4','5','5','5','5','6','6','6','6','7','7','7','7','8','8','8','8','9','9','9','9','T','T','T','T','...
Update input generator to be in line with description
Update input generator to be in line with description
C++
mit
acmatku/ku-ipc-2016,acmatku/ku-ipc-2016,acmatku/ku-ipc-2016,acmatku/ku-ipc-2016
55081fc0bfa1963d30ceab39514a4cafc8f0c0e5
search/params.cpp
search/params.cpp
#include "params.hpp" #include "../coding/multilang_utf8_string.hpp" namespace search { SearchParams::SearchParams() : m_inputLanguageCode(StringUtf8Multilang::UNSUPPORTED_LANGUAGE_CODE), m_searchMode(ALL), m_validPos(false) { } void SearchParams::SetPosition(double lat, double lon) { m_lat = lat; m_lon = lo...
#include "params.hpp" #include "../coding/multilang_utf8_string.hpp" namespace search { SearchParams::SearchParams() : m_inputLanguageCode(StringUtf8Multilang::UNSUPPORTED_LANGUAGE_CODE), m_searchMode(ALL), m_validPos(false) { } void SearchParams::SetPosition(double lat, double lon) { m_lat = lat; m_lon = lo...
Fix bug with comparing SearchParams.
Fix bug with comparing SearchParams.
C++
apache-2.0
guard163/omim,edl00k/omim,Transtech/omim,Endika/omim,darina/omim,dkorolev/omim,stangls/omim,andrewshadura/omim,goblinr/omim,darina/omim,igrechuhin/omim,ygorshenin/omim,mgsergio/omim,AlexanderMatveenko/omim,simon247/omim,sidorov-panda/omim,krasin/omim,programming086/omim,alexzatsepin/omim,rokuz/omim,Transtech/omim,vasil...
ae5937957c2b37dc4f10130fd59a9384e22f1637
generation_tests/main.cpp
generation_tests/main.cpp
#include "grune/all.hpp" #include <boost/filesystem.hpp> #include <fstream> #define ADD_TEST(name) \ extern void name(std::ostream&); ADD_TEST(test_anbncn); ADD_TEST(test_numbers); ADD_TEST(test_numbers_simple); ADD_TEST(test_tdh); ADD_TEST(test_turtle); typedef void (*test_fcn_t)(std::ostream&); void run_test(...
#include "grune/all.hpp" #include <boost/filesystem.hpp> #include <fstream> #define ADD_TEST(name) \ extern void name(std::ostream&); ADD_TEST(test_anbncn); ADD_TEST(test_numbers); ADD_TEST(test_numbers_simple); ADD_TEST(test_tdh); ADD_TEST(test_turtle); typedef void (*test_fcn_t)(std::ostream&); void run_test...
Add test separation for generation tests.
Add test separation for generation tests.
C++
mit
Fifty-Nine/grune
98c8b760f778863fb7fcd638727a0db76c38fe7c
Gyroid.cpp
Gyroid.cpp
// // Gyroid.cpp // VolumeRenderer // // Created by Calvin Loncaric on 6/26/11. // #include "Gyroid.h" #include <cmath> float Gyroid::valueAt(float x, float y, float z) const { return (cosf(x) * sinf(y) + cosf(y) * sinf(z) + cosf(z) * sinf(x)); } vector Gyroid::gradientAt(float x, float y, float z) const { ...
// // Gyroid.cpp // VolumeRenderer // // Created by Calvin Loncaric on 6/26/11. // #include "Gyroid.h" #include <cmath> float Gyroid::valueAt(float x, float y, float z) const { return (cosf(x) * sinf(y) + cosf(y) * sinf(z) + cosf(z) * sinf(x)); } vector Gyroid::gradientAt(float x, float y, float z) const { ...
Remove a stray debug line
Remove a stray debug line
C++
mit
Calvin-L/MarchingTetrahedrons,Calvin-L/MarchingTetrahedrons
059c5dd14fbd395923174e809cbe61d2d6759616
sapi4out.cpp
sapi4out.cpp
#define WIN32_LEAN_AND_MEAN #include <windows.h> #include <string.h> #include <stdio.h> #include <excpt.h> #include "sapi4.hpp" int main(int argc, char** argv) { VOICE_INFO VoiceInfo; if (!InitializeForVoice(argv[1], &VoiceInfo)) { return 0; } UINT64 Len; LPSTR outFile = (LPSTR)malloc(17); GetTTS(&VoiceIn...
#define WIN32_LEAN_AND_MEAN #include <windows.h> #include <string.h> #include <stdio.h> #include <excpt.h> #include "sapi4.hpp" int main(int argc, char** argv) { VOICE_INFO VoiceInfo; if (!InitializeForVoice(argv[1], &VoiceInfo)) { return 0; } UINT64 Len; LPSTR outFile[17]; GetTTS(&VoiceInfo, atoi(argv[2]...
Use stack instead of malloc
Use stack instead of malloc
C++
mit
TETYYS/SAPI4,TETYYS/SAPI4
4b2c306198d135a59b434361f25fdfe30e2b7e46
sample.cpp
sample.cpp
#pragma warning( disable : 4350 ) #pragma warning(push, 3) #include <iostream> #pragma warning(pop) int main(int , char **) { std::cout << "Hello CI!" << std::endl; return 0; } #pragma warning( disable : 4710 4514)
#pragma warning( disable : 4350 4710 ) #pragma warning(push, 3) #include <iostream> #pragma warning(pop) int main(int , char **) { std::cout << "Hello CI!" << std::endl; return 0; } #pragma warning( disable : 4514)
Make MSVC release build actually work
Make MSVC release build actually work
C++
mit
kaidokert/cpp-travis-test,kaidokert/cpp-travis-test
7e39bf7533b43f6572035c14bff34f06eaeec413
examples/spdlog/foo.cpp
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"); }
#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; }
Fix missing include in the example
Fix missing include in the example
C++
bsd-2-clause
ErniBrown/hunter,mchiasson/hunter,ikliashchou/hunter,xsacha/hunter,pretyman/hunter,NeroBurner/hunter,dan-42/hunter,madmongo1/hunter,ikliashchou/hunter,NeroBurner/hunter,mchiasson/hunter,tatraian/hunter,ErniBrown/hunter,dan-42/hunter,xsacha/hunter,ingenue/hunter,ingenue/hunter,pretyman/hunter,xsacha/hunter,ruslo/hunter,...
876e48619faf45ec559dad665bb0015e0bdfeeb4
src/core/test/Format.cpp
src/core/test/Format.cpp
// // Created by Jan de Visser on 2021-09-22. // #include <core/Format.h> #include <core/StringUtil.h> #include <gtest/gtest.h> TEST(Format, format_int) { std::string formatted = Obelix::format("{}", 42); EXPECT_EQ(formatted, "42"); } TEST(Format, format_string) { std::string formatted = Obelix::format("...
// // Created by Jan de Visser on 2021-09-22. // #include <core/Format.h> #include <core/StringUtil.h> #include <gtest/gtest.h> TEST(Format, format_int) { std::string formatted = Obelix::format("{}", 42); EXPECT_EQ(formatted, "42"); } TEST(Format, format_string) { std::string formatted = Obelix::format("...
Test for { escaping in format()
Test for { escaping in format()
C++
mit
JanDeVisser/obelix,JanDeVisser/obelix,JanDeVisser/obelix
140ba9640d342b12df3c3b620d64621c1cb3b556
source/chip/STM32/STM32F0/STM32F0-lowLevelInitialization.cpp
source/chip/STM32/STM32F0/STM32F0-lowLevelInitialization.cpp
/** * \file * \brief chip::lowLevelInitialization() implementation for STM32F0 * * \author Copyright (C) 2016 Kamil Szczygiel http://www.distortec.com http://www.freddiechopin.info * * \par License * 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...
/** * \file * \brief chip::lowLevelInitialization() implementation for STM32F0 * * \author Copyright (C) 2016 Kamil Szczygiel http://www.distortec.com http://www.freddiechopin.info * * \par License * 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...
Enable flash prefetch in low-level initialization for STM32F0
Enable flash prefetch in low-level initialization for STM32F0 Flash prefetch is enabled or disabled depending on whether CONFIG_CHIP_STM32F0_FLASH_PREFETCH_ENABLE is defined or not.
C++
mpl-2.0
DISTORTEC/distortos,DISTORTEC/distortos,jasmin-j/distortos,DISTORTEC/distortos,jasmin-j/distortos,CezaryGapinski/distortos,CezaryGapinski/distortos,jasmin-j/distortos,jasmin-j/distortos,CezaryGapinski/distortos,CezaryGapinski/distortos,DISTORTEC/distortos,jasmin-j/distortos,CezaryGapinski/distortos
282602a6e9abcda0ccab0121b1af77aa4c13267d
src/sn/sn_sweeper_dd.cpp
src/sn/sn_sweeper_dd.cpp
#include "sn_sweeper_dd.hpp" namespace mocc { namespace sn { void SnSweeper_DD::sweep( int group ) { // Store the transport cross section somewhere useful for( auto &xsr: *xs_mesh_ ) { real_t xstr = xsr.xsmactr()[group]; for( auto &ireg: xsr.reg() ) { xstr_[i...
#include "sn_sweeper_dd.hpp" namespace mocc { namespace sn { void SnSweeper_DD::sweep( int group ) { // Store the transport cross section somewhere useful for( auto &xsr: *xs_mesh_ ) { real_t xstr = xsr.xsmactr()[group]; for( auto &ireg: xsr.reg() ) { xstr_[i...
Remove print statement for DD currents
Remove print statement for DD currents
C++
apache-2.0
youngmit/mocc,youngmit/mocc,youngmit/mocc,youngmit/mocc
bcbb3bcdf5187046059c45e1e33fd7a60bf35e4c
support.cc
support.cc
// Licensed under the Apache License, Version 2.0. #include "support.h" #include <clocale> #include <cstdio> #include <cwchar> #include <sys/ioctl.h> #include <unistd.h> void setup() { setlocale(LC_ALL, "en_US.UTF-8"); } void clear_screen() { fputws(L"\033[2J\033[1;1H", stdout); } std::pair<size_t, size_t> screen...
// Licensed under the Apache License, Version 2.0. #include "support.h" #include <clocale> #include <cstdio> #include <cwchar> #include <sys/ioctl.h> #include <unistd.h> void setup() { setlocale(LC_ALL, "C.UTF-8"); } void clear_screen() { fputws(L"\033[2J\033[1;1H", stdout); } std::pair<size_t, size_t> screen_siz...
Use C.UTF-8 instead of en_US.UTF-8
Use C.UTF-8 instead of en_US.UTF-8 Should be more portable.
C++
apache-2.0
jfbastien/progress,jfbastien/progress
35630b5125efebe19fe19af75c9a1227849b939c
sorterdistcpp/src/partition.cpp
sorterdistcpp/src/partition.cpp
#include "partition.hpp" namespace SorterThreadedHelper { Partition::Partition(const std::set<double>::iterator pivotsBegin, const std::set<double>::iterator pivotsEnd, const std::vector<double>::iterator chunkBegin, const std::vector<double>::it...
#include "partition.hpp" namespace SorterThreadedHelper { Partition::Partition(const std::set<double>::iterator pivotsBegin, const std::set<double>::iterator pivotsEnd, const std::vector<double>::iterator chunkBegin, const std::vector<double>::it...
Put the iterator construction inside the for loop
Put the iterator construction inside the for loop
C++
bsd-3-clause
cmcantalupo/SorterDist,cmcantalupo/SorterDist,cmcantalupo/SorterDist
06046a06fdfe4455191ea25b67266ac02e17603e
lib/notificationstate.cc
lib/notificationstate.cc
#include <node.h> #include <v8.h> #ifdef _WIN32 #include "notificationstate-query.h" #endif using namespace v8; void Method(const v8::FunctionCallbackInfo<Value>& args) { Isolate* isolate = Isolate::GetCurrent(); HandleScope scope(isolate); int returnValue = -1; #ifdef _WIN32 returnValue = queryUserNoti...
#include <node.h> #include <v8.h> #ifdef _WIN32 #include "notificationstate-query.h" #endif using namespace v8; void Method(const v8::FunctionCallbackInfo<Value>& args) { Isolate* isolate = Isolate::GetCurrent(); HandleScope scope(isolate); int returnValue = -1; #ifdef _WIN32 returnValue = queryUserNoti...
Handle -> Local for node 12 compat
fix: Handle -> Local for node 12 compat See https://electronjs.org/blog/nodejs-native-addons-and-electron-5 for details.
C++
mit
felixrieseberg/windows-notification-state,felixrieseberg/windows-notification-state,felixrieseberg/windows-notification-state,felixrieseberg/windows-notification-state
508ec0d45f2bcc8427191949a209a0d92b93a9d3
Data/Note.cpp
Data/Note.cpp
// NoteTrainer (c) 2016 Andrey Fidrya. MIT license. See LICENSE for more information. #include "Note.h" QString noteName(Note note) { switch (note) { case Note::C: return "do"; case Note::Cis: return "di"; case Note::D: return "re"; case Note::Ees: return "me"; case Note::E: return "mi";...
// NoteTrainer (c) 2016 Andrey Fidrya. MIT license. See LICENSE for more information. #include "Note.h" #include "Utils/Utils.h" QString noteName(Note note) { switch (note) { case Note::C: return "do"; case Note::Cis: return "di"; case Note::D: return "re"; case Note::Ees: return "me"; cas...
Fix incorrect display of note C in octaves 1-3
Fix incorrect display of note C in octaves 1-3
C++
mit
zmeyc/notetrainer,zmeyc/notetrainer
a1217377ef0fc50e6900f97e51ac80cba1639a83
src/main.cpp
src/main.cpp
// This is the starting point // #include <iostream> #include <fstream> #include <sstream> int main() { std::string firstInputString; std::string secondInputString; std::cout << "Enter the first string" << std::endl; std::cin >> firstInputString; std::cout << "Enter the second string" << std::endl...
// This is the starting point // #include <iostream> #include <fstream> #include <sstream> int main() { std::string first_input; std::string second_input; std::cout << "Enter the first string" << std::endl; std::cin >> first_input; std::cout << "Enter the second string" << std::endl; std::cin ...
Update identifiers to reflect consistent casing
Update identifiers to reflect consistent casing
C++
bsd-2-clause
ambidextrousTx/RGrep-CPP
3fecbf96a73fcf34f9ca2ba42a0681b1dd9cb8d0
Farmhash.Benchmarks/benchmark-farmhash.cpp
Farmhash.Benchmarks/benchmark-farmhash.cpp
#include <string> #include <benchmark/benchmark.h> #include "farmhash.h" static void BM_Farmhash(benchmark::State& state) { auto payload = std::string(state.range(0), '.'); while (state.KeepRunning()) util::Hash64(payload); state.SetBytesProcessed(int64_t(state.iterations()) * int64_t(state.range(0))); } //...
#include <string> #include <benchmark/benchmark.h> #include "farmhash.h" static void BM_Farmhash(benchmark::State& state) { auto payload = std::string(state.range(0), '.'); for (auto _ : state) util::Hash64(payload); state.SetBytesProcessed(int64_t(state.iterations()) * int64_t(state.range(0))); } // Regist...
Use recommended c++11 benchmark loop
Use recommended c++11 benchmark loop
C++
mit
nickbabcock/Farmhash.Sharp,nickbabcock/Farmhash.Sharp,nickbabcock/Farmhash.Sharp,nickbabcock/Farmhash.Sharp
5ca238aff1d0ef00a478b41c6b6e593cc8ec4223
htmlsnap.cpp
htmlsnap.cpp
#include "htmlsnap.h" #include <QPainter> #include <QDebug> #include <QWebFrame> #include <QTimer> #include <iostream> #include <QBuffer> HtmlSnap::HtmlSnap() { connect(&page, SIGNAL(loadFinished(bool)), this, SLOT(render())); } void HtmlSnap::loadHtml(char* html) { page.mainFrame()->setHtml(QString(html), QU...
#include "htmlsnap.h" #include <QPainter> #include <QDebug> #include <QWebFrame> #include <QTimer> #include <iostream> #include <QBuffer> HtmlSnap::HtmlSnap() { connect(&page, SIGNAL(loadFinished(bool)), this, SLOT(render())); } void HtmlSnap::loadHtml(char* html) { page.mainFrame()->setHtml(QString(html), QU...
Make sure the app closes on error
Make sure the app closes on error
C++
mit
jarib/htmlsnap
0b1d4afbb10f5a3aeeb604e4951605212739ed20
main/executor/executor.cpp
main/executor/executor.cpp
#include "executor.h" #include <chrono> const std::time_t Executor::waitOnNullTask; const std::time_t Executor::waitOnEndTask; Executor::Executor(int id) : Thread(id), cLog("Executor #" + std::to_string(id)) { } Executor::~Executor() { } void Executor::SetTasksPool(TasksPool& p) { tasksPool = &p; } void Ex...
#include "executor.h" #include <chrono> const std::time_t Executor::waitOnNullTask; const std::time_t Executor::waitOnEndTask; Executor::Executor(int id) : Thread(id), cLog("Executor #" + std::to_string(id)) { } Executor::~Executor() { } void Executor::SetTasksPool(TasksPool& p) { tasksPool = &p; } void Ex...
Check if tasks pool is set
Check if tasks pool is set
C++
mit
mexus/limited-executing
a8d85f9076c06df316443f41fd7946e79b8d3b54
Data/Data.cpp
Data/Data.cpp
#include "Data.hpp" #include <stdexcept> #include <string> namespace Tools { Data::BitsType getBitsFromString(const std::string& buf) { Data::BitsType bits(buf.size()); for (size_t i = 0; i < buf.size(); ++i) { if (buf[i] == '0') bits[i] = 0; else if (buf[i] == '1') bits[i] = 1; else t...
#include "Data.hpp" #include <stdexcept> #include <string> namespace Tools { Data::BitsType getBitsFromString(const std::string& buf) { Data::BitsType bits(buf.size()); for (size_t i = 0; i < buf.size(); ++i) { if (buf[i] == '0') bits[i] = 0; else if (buf[i] == '1') bits[i] = 1; else t...
Correct transaction count when reading a first line
Correct transaction count when reading a first line
C++
mit
wispwisp/associationRuleAnalysis
249469713d75090125b318f6101a8e42cba15b00
chrome/browser/extensions/extension_infobar_apitest.cc
chrome/browser/extensions/extension_infobar_apitest.cc
// Copyright (c) 2010 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 "base/command_line.h" #include "chrome/browser/extensions/extension_apitest.h" #include "chrome/common/chrome_switches.h" #if defined(TOOLKI...
// Copyright (c) 2010 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 "base/command_line.h" #include "chrome/browser/extensions/extension_apitest.h" #include "chrome/common/chrome_switches.h" #if defined(TOOLKI...
Mark a test as flaky on ChromeOS.
Mark a test as flaky on ChromeOS. BUG=40141 TEST=None Review URL: http://codereview.chromium.org/1575015 git-svn-id: dd90618784b6a4b323ea0c23a071cb1c9e6f2ac7@43384 4ff67af0-8c30-449e-8e8b-ad334ec8d88c
C++
bsd-3-clause
wistoch/meego-app-browser,wistoch/meego-app-browser,wistoch/meego-app-browser,wistoch/meego-app-browser,wistoch/meego-app-browser,wistoch/meego-app-browser,wistoch/meego-app-browser,wistoch/meego-app-browser,wistoch/meego-app-browser,wistoch/meego-app-browser
3450d4d2b463fe641c9fa81cf15d070202abd3c7
Plugins/Drift/Source/Drift/Private/Android/AndroidSecureStorage.cpp
Plugins/Drift/Source/Drift/Private/Android/AndroidSecureStorage.cpp
// Copyright 2015-2017 Directive Games Limited - All Rights Reserved #include "DriftPrivatePCH.h" #include "AndroidSecureStorage.h" #include "FileHelper.h" #if PLATFORM_ANDROID AndroidSecureStorage::AndroidSecureStorage(const FString& productName, const FString& serviceName) : productName_{ productName } , servic...
// Copyright 2015-2017 Directive Games Limited - All Rights Reserved #include "DriftPrivatePCH.h" #include "AndroidSecureStorage.h" #include "FileHelper.h" #if PLATFORM_ANDROID AndroidSecureStorage::AndroidSecureStorage(const FString& productName, const FString& serviceName) : productName_{ productName } , servic...
Fix build error on Android
Fix build error on Android
C++
mit
dgnorth/DriftUe4Plugin,dgnorth/DriftUe4Plugin,dgnorth/DriftUe4Plugin,dgnorth/DriftUe4Plugin
e9133bdac241fbe4974ba256f4b9793db2689e76
test/serializer.cpp
test/serializer.cpp
#include <cassert> #include <cmath> #include <limits> #include <serializer.h> void test(const double in) { Serializer s; writer<decltype(+in)>::write(s, in); const auto buf = s.data(); Deserializer d(s.buffer, s.buffer.size() - buf.second); const auto out = reader<decltype(+in)>::read(d); assert(in == out ...
#include <cassert> #include <cmath> #include <limits> #include <serializer.h> void test(const double in) { Serializer s; writer<decltype(+in)>::write(s, in); const auto buf = s.data(); Deserializer d(s.buffer, s.buffer.size() - buf.second); const auto out = reader<decltype(+in)>::read(d); assert(in == out ...
Test serialization of zero too
Test serialization of zero too
C++
mit
muggenhor/rapscallion,dascandy/rapscallion
29cf28d76eb722a782b2d6660cd5ddb176f745cd
src/lib/annis/queryconfig.cpp
src/lib/annis/queryconfig.cpp
#include "queryconfig.h" #include <thread> annis::QueryConfig::QueryConfig() : optimize(true), forceFallback(false), avoidNestedBySwitch(true), numOfParallelTasks(std::thread::hardware_concurrency()) { }
#include "queryconfig.h" #include <thread> annis::QueryConfig::QueryConfig() : optimize(true), forceFallback(false), avoidNestedBySwitch(true), numOfParallelTasks(std::thread::hardware_concurrency()-1) { }
Change default config to use one thread less that CPUS available for the thread pool. Since there is a thread which calles next() it makes sense to not use all CPUs for the thread pool.
Change default config to use one thread less that CPUS available for the thread pool. Since there is a thread which calles next() it makes sense to not use all CPUs for the thread pool.
C++
apache-2.0
thomaskrause/graphANNIS,thomaskrause/graphANNIS,thomaskrause/graphANNIS,thomaskrause/graphANNIS,thomaskrause/graphANNIS,thomaskrause/graphANNIS,thomaskrause/graphANNIS
406d6b30647a08115fb4d68d46efa9409040045a
luna/main.cpp
luna/main.cpp
#include <QApplication> #include <QDeclarativeView> #include <QUrl> #include <MDeclarativeCache> Q_DECL_EXPORT int main(int argc, char** argv) { QApplication* app = MDeclarativeCache::qApplication(argc, argv); QDeclarativeView viewer; viewer.setSource(QUrl("qrc:/qml/main.qml")); viewer.showFullScreen(...
#include <QApplication> #include <QDeclarativeView> #include <QUrl> #include <qplatformdefs.h> #if defined(MEEGO_EDITION_HARMATTAN) #include <MDeclarativeCache> #define NEW_QAPPLICATION(x, y) MDeclarativeCache::qApplication((x), (y)) Q_DECL_EXPORT #else #define NEW_QAPPLICATION(x, y) new QApplication((...
Use QML booster only when compiling to Harmattan target.
Use QML booster only when compiling to Harmattan target.
C++
lgpl-2.1
qtproject/qt-apps-snowshoe,qtproject/qt-apps-snowshoe,snowshoe/snowshoe,snowshoe/snowshoe,qtproject/qt-apps-snowshoe,snowshoe/snowshoe
c9997df2345b568ed428250ab9653f4d21ec87e4
test/packages/transformation/newt2_test.cc
test/packages/transformation/newt2_test.cc
#include "gtest/gtest.h" //#include <nr.h> //#include <nrutil.h> #include "packages/transformation/src/newt2.cc" #include <irtkTransformation.h> const double EPSILON = 0.001; TEST(Packages_Transformation_newt2, irtkMultiLevelFreeFormTransformation_Inverse) { irtkCifstream iStream; iStream.Open("/vol/medic02/us...
#include "gtest/gtest.h" #include <irtkTransformation.h> const double EPSILON = 0.001; TEST(Packages_Transformation_newt2, irtkMultiLevelFreeFormTransformation_Inverse) { irtkCifstream iStream; iStream.Open("/vol/medic02/users/sp2010/PhD/Tumor/dofs/gradientnreg2-NGP-HG01.dof.gz"); irtkMultiLevelFreeFormTran...
Remove redundant inclusions from newt_test.cc
Remove redundant inclusions from newt_test.cc
C++
unknown
BioMedIA/irtk-legacy,sk1712/IRTK,ghisvail/irtk-legacy,BioMedIA/irtk-legacy,BioMedIA/IRTK,ghisvail/irtk-legacy,BioMedIA/IRTK,sk1712/IRTK,ghisvail/irtk-legacy,BioMedIA/irtk-legacy,sk1712/IRTK,ghisvail/irtk-legacy,BioMedIA/IRTK,BioMedIA/irtk-legacy,BioMedIA/IRTK,sk1712/IRTK
6173b828e691dc05ad1994044fbc1f577dcd9510
apps/RubyBasicWorkspace/RubyBasic/src/rubybasic/BindApplication.cpp
apps/RubyBasicWorkspace/RubyBasic/src/rubybasic/BindApplication.cpp
#include "rubybasic/BindApplication.hpp" #include "mruby.h" #include "mrubybind.h" #include "ofAppRunner.h" namespace { static float get_frame_rate() { return ofGetFrameRate(); } static void set_window_pos(int x, int y) { ofSetWindowPosition(x, y); } static void set_window_size(int width, int height) { of...
#include "rubybasic/BindApplication.hpp" #include "mruby.h" #include "mrubybind.h" #include "ofAppRunner.h" namespace { static float get_frame_rate() { return ofGetFrameRate(); } static void set_window_pos(int x, int y) { ofSetWindowPosition(x, y); } static void set_window_size(int width, int height) { of...
Add screen_witdh, height. Change window_height, width base function.
Add screen_witdh, height. Change window_height, width base function.
C++
mit
ongaeshi/rubykokuban-osx,ongaeshi/rubykokuban-osx,ongaeshi/rubykokuban-osx,ongaeshi/rubykokuban-osx
d3a495100e85470a074345fb824f330d602b31fb
test/11-anchoring.cc
test/11-anchoring.cc
MATCH_TEST("x", UNANCHORED, "x"); MATCH_TEST("x", UNANCHORED, "xyz"); MATCH_TEST("x", UNANCHORED, "uvwx"); MATCH_TEST("x", UNANCHORED, "uvwxyz"); MATCH_TEST("x", ANCHOR_START, "x"); MATCH_TEST("x", ANCHOR_START, "xyz"); MATCH_TEST("x", ANCHOR_START, "uvwx"); MATCH_TEST("x", ANCHOR_START, "uvwxyz"); MATCH_TEST("x", AN...
MATCH_TEST("x", UNANCHORED, "x"); MATCH_TEST("x", UNANCHORED, "xyz"); MATCH_TEST("x", UNANCHORED, "uvwx"); MATCH_TEST("x", UNANCHORED, "uvwxyz"); MATCH_TEST("x", ANCHOR_START, "x"); MATCH_TEST("x", ANCHOR_START, "xyz"); MATCH_TEST("x", ANCHOR_START, "uvwx"); MATCH_TEST("x", ANCHOR_START, "uvwxyz"); MATCH_TEST("x", AN...
Add some explicit anchoring tests.
Add some explicit anchoring tests. Those are not implemented as empty-width instructions in re2, but as flags telling it to use an appropriate anchor mode even though the caller might disagree. Forgetting to check `Prog::anchor_start` or `Prog::anchor_end` is a good way to fail these tests.
C++
mit
pyos/re2jit,pyos/re2jit,pyos/re2jit
e595a6f955108bfb28b68f1004b6216e27e02cb1
unittests/Support/DebugTest.cpp
unittests/Support/DebugTest.cpp
//===- llvm/unittest/Support/DebugTest.cpp --------------------------------===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===-------------------------------------------------------...
//===- llvm/unittest/Support/DebugTest.cpp --------------------------------===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===-------------------------------------------------------...
Fix unit test in NDEBUG build
Fix unit test in NDEBUG build git-svn-id: 0ff597fd157e6f4fc38580e8d64ab130330d2411@290604 91177308-0d34-0410-b5e6-96231b3b80d8
C++
apache-2.0
apple/swift-llvm,apple/swift-llvm,apple/swift-llvm,llvm-mirror/llvm,GPUOpen-Drivers/llvm,GPUOpen-Drivers/llvm,llvm-mirror/llvm,apple/swift-llvm,GPUOpen-Drivers/llvm,llvm-mirror/llvm,llvm-mirror/llvm,GPUOpen-Drivers/llvm,GPUOpen-Drivers/llvm,apple/swift-llvm,llvm-mirror/llvm,apple/swift-llvm,llvm-mirror/llvm,llvm-mirror...