text stringlengths 54 60.6k |
|---|
<commit_before>/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2003 Robert Osfield
*
* This library is open source and may be redistributed and/or modified under
* the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
* (at your option) any later version. The full license is in LICENSE file
*... |
<commit_before>#include "BooPHF.h"
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
#include <string.h>
#include <sys/types.h>
#include <random>
#include <algorithm>
#include <fstream>
using namespace std;
//example with user provided custom hasher for uint64_t type :
class Custom_string_Hasher
{
public:
... |
<commit_before>/*
This code is released under the terms of the MIT license.
See COPYING.txt for details.
*/
#include <QMessageBox>
#include <algorithm>
#include "propertieswindow.h"
#include "ui_propertieswindow.h"
#include "stuff.h"
#include "level.h"
#include "graphics.h"
#include "hexspinbox.h"
#include "ti... |
<commit_before>#ifndef STAN_MATH_PRIM_MAT_PROB_ORDERED_LOGISTIC_LPMF_HPP
#define STAN_MATH_PRIM_MAT_PROB_ORDERED_LOGISTIC_LPMF_HPP
#include <stan/math/prim/mat/fun/value_of.hpp>
#include <stan/math/prim/mat/fun/size.hpp>
#include <stan/math/prim/mat/meta/vector_seq_view.hpp>
#include <stan/math/prim/mat/err/check_orde... |
<commit_before>//=- AArch64RedundantCopyElimination.cpp - Remove useless copy for AArch64 -=//
//
// The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
// This pass removes unnecessary zero copies i... |
<commit_before>/*****************************************************************************
*
* This file is part of Mapnik (c++ mapping toolkit)
*
* Copyright (C) 2011 Artem Pavlenko
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
... |
<commit_before>/*********************************************************************************
*
* Inviwo - Interactive Visualization Workshop
*
* Copyright (c) 2015-2017 Inviwo Foundation
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permit... |
<commit_before>// 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 file.
#include "content/renderer/media/mock_peer_connection_impl.h"
#include <vector>
#include "base/logging.h"
#include "content/renderer/... |
<commit_before>//=============================================================================================================
/**
* @file main.cpp
* @author Gabriel Motta <gbmotta@mgh.harvard.edu>
* @since 0.1.9
* @date September, 2021
*
* @section LICENSE
*
* Copyright (C) 2021, Gabriel Motta. A... |
<commit_before>#pragma once
#include <iostream>
#include <fstream>
#include <cstring>
#include <vector>
#include <queue>
using namespace std;
class const_string
{
const char* _M_str;
public:
explicit const_string(const char* _str): _M_str(_str){}
~const_string(){}
const char* str() const
{return this->_M_str;}... |
<commit_before>// Copyright (c) 2014-2017 Dr. Colin Hirsch and Daniel Frey
// Please see LICENSE for license or visit https://github.com/taocpp/PEGTL/
#ifndef TAOCPP_PEGTL_INCLUDE_INTERNAL_DUSELTRONIK_HPP
#define TAOCPP_PEGTL_INCLUDE_INTERNAL_DUSELTRONIK_HPP
#include "../apply_mode.hpp"
#include "../config.hpp"
#incl... |
<commit_before>/*
* AscEmu Framework based on ArcEmu MMORPG Server
* Copyright (C) 2014-2015 AscEmu Team <http://www.ascemu.org/>
* Copyright (C) 2008-2012 ArcEmu Team <http://www.ArcEmu.org/>
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General P... |
<commit_before>#include "json-to-value.hh"
#include <cstring>
namespace nix {
static void skipWhitespace(const char * & s)
{
while (*s == ' ' || *s == '\t' || *s == '\n' || *s == '\r') s++;
}
static string parseJSONString(const char * & s)
{
string res;
if (*s++ != '"') throw JSONParseError("expected ... |
<commit_before>// 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 file.
#include "content/renderer/render_widget_fullscreen_pepper.h"
#include <vector>
#include "base/bind.h"
#include "base/command_line.h"... |
<commit_before>#include <iodata/validator>
#include <iodata/storage>
#include <string>
#include <sstream>
#include <set>
#include <map>
using namespace std ;
#include "olson.h"
#include "misc.h"
#include "tzdata.h"
#if DEADCODE
struct tz_single_t ;
struct tz_distinct_t ;
struct tz_distinct_t
{
olson * guess_time... |
<commit_before>#include <iostream>
#include <string>
void run_part_one() {
}
void run_part_two() {
}
int main(int argc, char* argv[]) {
if (argc > 1) {
if (std::string(argv[1]) == "--part_two") {
run_part_two();
} else {
std::cout << "Usage: day21 [--part_two]" << std::end... |
<commit_before>//------------------------------------------------------------------------------
// CLING - the C++ LLVM-based InterpreterG :)
// author: Axel Naumann <axel@cern.ch>
//
// This file is dual-licensed: you can choose to license it under the University
// of Illinois Open Source License or the GNU Lesser G... |
<commit_before>#ifndef INCLUDE_AL_GRAPHICS_STEREOGRAPHIC_HPP
#define INCLUDE_AL_GRAPHICS_STEREOGRAPHIC_HPP
/*
* A collection of functions and classes related to application mainloops
* AlloSphere Research Group / Media Arts & Technology, UCSB, 2009
*/
/*
Copyright (C) 2006-2008. The Regents of the University of... |
<commit_before>// Copyright (c) 2010-2020, Lawrence Livermore National Security, LLC. Produced
// at the Lawrence Livermore National Laboratory. All Rights reserved. See files
// LICENSE and NOTICE for details. LLNL-CODE-806117.
//
// This file is part of the MFEM library. For more information and source code
// availa... |
<commit_before>// This file is part of the dune-gdt project:
// https://github.com/dune-community/dune-gdt
// Copyright 2010-2017 dune-gdt developers and contributors. All rights reserved.
// License: Dual licensed as BSD 2-Clause License (http://opensource.org/licenses/BSD-2-Clause)
// or GPL-2.0+ (http://open... |
<commit_before>/**
* @file density.cpp
*
* Computes desity for dry air from pressure and temperature using the ideal gas law.
*
* @date Mar 11, 2014
* @author Tack
*/
#include "density.h"
#include "plugin_factory.h"
#include "logger_factory.h"
#include <boost/lexical_cast.hpp>
#include <boost/thread.hpp>
#defi... |
<commit_before>/* Copyright 2017 The TensorFlow Authors. All Rights Reserved.
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 appl... |
<commit_before>//////////////////////////////////////////////////////////////////////////
//
// Copyright (c) 2012-2016, Image Engine Design Inc. All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// ... |
<commit_before>#ifndef GUARD_signature_hpp
#define GUARD_signature_hpp
#include <boost/noncopyable.hpp>
namespace jewel
{
/**
* The instantiation of this template for a class T is a
* non-copyable class the constructor of which is only
* accessible by
* class T. This provides a mechanism whereby a
* function ... |
<commit_before>// -*- coding: us-ascii-unix -*-
// Copyright 2012 Lukas Kemmer
//
// 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
//
// Unles... |
<commit_before>//
// video_manager.cpp
// emptyExample
//
// Created by Mark van de Korput on 16-05-03.
//
//
#include "video_manager.hpp"
#include "xml_settings.hpp"
using namespace of2030;
SINGLETON_INLINE_IMPLEMENTATION_CODE(VideoManager)
VideoManager::VideoManager(){
#ifdef __APPLE__
folder_path = "vids/... |
<commit_before>/**
* Copyright (c) Jason White
*
* MIT License
*
* Description:
* Removes comments and unnecessary whitespace from a Lua file. This is useful
* for embedding Lua scripts into an executable.
*/
#include <stdio.h>
#include <string.h>
#include <ctype.h>
const char* read_file(FILE* f, size_t* len) ... |
<commit_before>// Copyright 2015-2020 Elviss Strazdins. All rights reserved.
#include "../../../core/Setup.h"
#if defined(__ANDROID__) && OUZEL_COMPILE_OPENGL
#include "OGLRenderDeviceAndroid.hpp"
#include "../EGLErrorCategory.hpp"
#include "../../../core/Engine.hpp"
#include "../../../core/Window.hpp"
#include "../... |
<commit_before>/*****************************************************************************
*
* This file is part of Mapnik (c++ mapping toolkit)
*
* Copyright (C) 2011 Artem Pavlenko
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
... |
<commit_before>// -----------------------------------------------------------------------------
// Copyright : (C) 2014 Andreas-C. Bernstein
// License : MIT (see the file LICENSE)
// Maintainer : Andreas-C. Bernstein <andreas.bernstein@uni-weimar.de>
// Stability : experimental
//
// Renderer
// -----------------... |
<commit_before>//===-- Internalize.cpp - Mark functions internal -------------------------===//
//
// 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.
//
... |
<commit_before>#include <string>
#include <cstring>
#include <vector>
#include "math3d/math3d.h"
#include "pbge/pbge.h"
#include "Ellipsoids.h"
Ellipsoids::Ellipsoids(pbge::GraphicAPI * _gfx, int total_ellipsoids) {
std::vector<pbge::Model*> _models;
_models.push_back(pbge::Geometrics::createSphere(1.0f, 10,... |
<commit_before>// -----------------------------------------------------------------------------
// Copyright : (C) 2014 Andreas-C. Bernstein
// License : MIT (see the file LICENSE)
// Maintainer : Andreas-C. Bernstein <andreas.bernstein@uni-weimar.de>
// Stability : experimental
//
// Renderer
// -----------------... |
<commit_before>/*=========================================================================
Program: Insight Segmentation & Registration Toolkit
Module: testMetaObject.cxx
Language: C++
Date: $Date$
Version: $Revision$
Copyright (c) Insight Software Consortium. All rights reserved.
See ITKCo... |
<commit_before>/*
* Copyright (c) 2013-2014, Ford Motor Company
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* Redistributions of source code must retain the above copyright notice, th... |
<commit_before>/* Siconos is a program dedicated to modeling, simulation and control
* of non smooth dynamical systems.
*
* Copyright 2018 INRIA.
*
* 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 L... |
<commit_before>/*
Copyright (c) 2013 Microsoft Corporation. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Author: Leonardo de Moura
*/
#include "util/flet.h"
#include "util/scoped_map.h"
#include "util/interrupt.h"
#include "kernel/environment.h"
#include "kernel/normalizer.h... |
<commit_before>//
// This file is part of the Marble Desktop Globe.
//
// This program is free software licensed under the GNU LGPL. You can
// find a copy of this license in LICENSE.txt in the top directory of
// the source code.
//
// Copyright 2006-2007 Torsten Rahn <tackat@kde.org>"
// Copyright 2007 Inge Wall... |
<commit_before>#include <ros/ros.h>
#include <geometry_msgs/Twist.h>
#include <std_msgs/Int32.h>
#include <signal.h>
#include <termios.h>
#include <stdio.h>
#define KEYCODE_RA 0x43
#define KEYCODE_LA 0x44
#define KEYCODE_UA 0x41
#define KEYCODE_DA 0x42
#define KEYCODE_Q 0x71
#define KEYCODE_W 0x77
#define KEYCODE_S 0x... |
<commit_before>/**
* The Seeks proxy and plugin framework are part of the SEEKS project.
* Copyright (C) 2009 Emmanuel Benazera, juban@free.fr
*
* 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 ... |
<commit_before>//===--- TerminalDisplayWin.h - Output To Windows Console -------*- C++ -*-===//
//
// The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------... |
<commit_before>//
// PROJECT CHRONO - http://projectchrono.org
//
// Copyright (c) 2013 Project Chrono
// All rights reserved.
//
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file at the top level of the distribution
// and at http://projectchrono.org/license-chrono.... |
<commit_before>#include "TrackingWorker.hpp"
#include <boost/chrono/duration.hpp>
#include <ros/console.h>
#include <opencv2/core/core.hpp>
#include <map>
#include "../../matlab/profiling.hpp"
TrackingWorker::TrackingWorker(IPositionReceiver *receiver) : errorGraph(200, "Difference")
{
assert(receiver != 0);
thi... |
<commit_before>// Jubatus: Online machine learning framework for distributed environment
// Copyright (C) 2011,2012 Preferred Networks and Nippon Telegraph and Telephone Corporation.
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// Lice... |
<commit_before>/**
* Copyright (c) 2011-2016 libbitcoin developers (see AUTHORS)
*
* This file is part of libbitcoin.
*
* libbitcoin is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License with
* additional permissions to the one published by the Free... |
<commit_before>/*
* This file is part of Peli - universal JSON interaction library
* Copyright (C) 2014 Alexey Chernov <4ernov@gmail.com>
*
* Peli 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; ... |
<commit_before>/******************************************************************************
*
* Copyright 2008 Szymon Tomasz Stefanek <pragma@kvirc.net>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free... |
<commit_before>/***************************************************************************
konsolekalendarexports.cpp - description
-------------------
begin : Sun May 25 2003
copyright : (C) 2003 by Tuukka Pasanen
copyright : (C) 2003 by Allen Wint... |
<commit_before>/* testhhrecord.cc KPilot
**
** Copyright (C) 2007 by Bertjan Broeksema <b.broeksema@kdemail.net>
** Copyright (C) 2007 by Jason "vanRijn" Kasper <vr@movingparts.net>
*/
/*
** This program is free software; you can redistribute it and/or modify
** it under the terms of the GNU Lesser General Public Li... |
<commit_before>// Author: Jingyue
#include <cstdio>
#include <set>
using namespace std;
#include "llvm/Pass.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/raw_ostream.h"
using namespace llvm;
#include "common/PointerAnalysis.h"
using namespace rcs;
#include "dyn-aa/LogRecord.h"
#include "dyn-aa/Int... |
<commit_before>//
// Copyright 2013-2014, Bradley A. Grantham
//
// 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 require... |
<commit_before>/**
* \file
* \brief priorityTestPhases object declaration
*
* \author Copyright (C) 2014-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... |
<commit_before>// Copyright (C) 2010-2013 Joshua Boyce.
// See the file COPYING for copying permission.
#include <memory>
#include <string>
#include <vector>
#include <sstream>
#include <iostream>
#include <hadesmem/detail/warning_disable_prefix.hpp>
#include <boost/filesystem.hpp>
#include <boost/program_... |
<commit_before>// Licensed under the Apache License, Version 2.0.
// Author: Jin Qing (http://blog.csdn.net/jq0123)
// Dynamic singleton helper for manager class.
// See struct manager::dyn_singleton_helper in
// "(A dynamic) Singleton using weak_ptr and shared_ptr"
// http://boost.2283326.n4.nabble.com/A-dynamic-Si... |
<commit_before>/*
* Copyright (C) 2013
* Alessio Sclocco <a.sclocco@vu.nl>
*
* 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 3 of the License, or
* (at your option) any lat... |
<commit_before>/*
* Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
*
* Use of this source code is governed by a BSD-style license
* that can be found in the LICENSE file in the root of the source
* tree. An additional intellectual property rights grant can be found
* in the file PATENTS.... |
<commit_before>// ==Montelight==
// Tegan Brennan, Stephen Merity, Taiyo Wilson
#include <cmath>
#include <string>
#include <fstream>
#define EPSILON 0.01f
using namespace std;
struct Vector {
double x, y, z;
//
Vector(const Vector &o) : x(o.x), y(o.y), z(o.z) {}
Vector(double x_=0, double y_=0, double z_=0)... |
<commit_before>// Copyright (C) 2010-2013 Joshua Boyce.
// See the file COPYING for copying permission.
#include <memory>
#include <string>
#include <vector>
#include <sstream>
#include <iostream>
#include <hadesmem/detail/warning_disable_prefix.hpp>
#include <boost/filesystem.hpp>
#include <boost/program_... |
<commit_before>/*
* server_memory_test.cpp - Kurento Media Server
*
* Copyright (C) 2013 Kurento
* Contact: Miguel París Díaz <mparisdiaz@gmail.com>
* Contact: José Antonio Santos Cadenas <santoscadenas@kurento.com>
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of... |
<commit_before>#include "../config.h"
#include <iostream>
#include <fstream>
#include <getopt.h>
#include <netinet/in.h>
#include <ev.h>
#include <sysexits.h>
#include "../Socket/Socket.hxx"
#include "../Log/TimestampLog.hxx"
static const size_t READ_SIZE = 4096;
static const int MAX_CONN_BACKLOG = 32;
std::string ... |
<commit_before><commit_msg>planning: address code review comments<commit_after><|endoftext|> |
<commit_before><commit_msg>Update cruise_mlp_evaluator.cc<commit_after><|endoftext|> |
<commit_before>#include <algorithm>
#define NOMINMAX // Para que nadie nos redefina min max
#include <sstream>
#include "game_window.h"
#include "../model/entity_factory.h"
#include "../parser_yaml/graphics_parser.h"
#include "../parser_yaml/ruleset_parser.h"
using namespace std;
bool GameWindow::sdlInitialized = f... |
<commit_before>/*
* 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 3 of the License, or
* (at your option) any later version.
*
* Written (W) 2012 Fernando José Iglesias Garc... |
<commit_before>// Licensed GNU LGPL v3 or later: http://www.gnu.org/licenses/lgpl.html
#include "cairo-inlined/cairo.h"
#include "cairocontext.hh"
namespace Rapicorn {
/* --- Painter --- */
CairoContext::CairoContext() :
cr (NULL)
{}
CairoContext::~CairoContext()
{
set_cairo (NULL);
}
void
CairoContext::set_cair... |
<commit_before>#include <algorithm>
#define NOMINMAX // Para que nadie nos redefina min max
#include <sstream>
#include "game_window.h"
#include "../parser_yaml/graphics_parser.h"
#include "../parser_yaml/ruleset_parser.h"
using namespace std;
bool GameWindow::sdlInitialized = false;
bool GameWindow::initialize() ... |
<commit_before>/* Licensed GNU LGPL v3 or later: http://www.gnu.org/licenses/lgpl.html */
#include <rcore/testutils.hh>
#include <ui/uithread.hh>
using namespace Rapicorn;
static void
test_server_smart_handle()
{
ApplicationImpl &app = ApplicationImpl::the(); // FIXME: use Application_SmartHandle once C++ bindings a... |
<commit_before>/* -------------------------------------------------------------------------- *
* SimTK Core: SimTK Simbody(tm) *
* -------------------------------------------------------------------------- *
* This is part of the SimTK Core biosimulation toolkit origin... |
<commit_before>#include "Chunk.h"
#include <cstdlib>
uint qHash(const Int3D & coord)
{
return (coord.x * 8191 + coord.z) * 131071 + coord.y;
}
Chunk::Chunk(const Int3D &pos, const Int3D &size) :
m_pos(pos),
m_size(size),
m_blocks(m_size.x * m_size.y * m_size.z)
{
}
int Chunk::indexOf(const Int3D & c... |
<commit_before>#include "orbit_mpi.hh"
#include "pyORBIT_Object.hh"
#
#include "wrap_lspacechargecalc.hh"
#include "wrap_bunch.hh"
#include <iostream>
#include "LSpaceChargeCalc.hh"
using namespace OrbitUtils;
namespace wrap_LSpaceChargeCalc{
#ifdef __cplusplus
extern "C" {
#endif
//-----------------------------... |
<commit_before>/* This file is part of the KDE project
* Copyright (C) 2001, 2002 Rolf Magnus <ramagnus@kde.org>
* Copyright (C) 2007 Tim Beaulen <tbscope@gmail.com>
*
* 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 th... |
<commit_before>/****************************************************************************
*
* Copyright (c) 2019 PX4 Development Team. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*... |
<commit_before>//
// This file is part of the Marble Virtual Globe.
//
// This program is free software licensed under the GNU LGPL. You can
// find a copy of this license in LICENSE.txt in the top directory of
// the source code.
//
// Copyright 2011 Konstantin Oblaukhov <oblaukhov.konstantin@gmail.com>
//
#incl... |
<commit_before>////////////////////////////////////////////////////////////////////////////////
//
// Copyright 2006 - 2014, Paul Beckingham, Federico Hernandez.
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to... |
<commit_before>#include "stan/math/functions/modified_bessel_second_kind.hpp"
#include <gtest/gtest.h>
TEST(MathFunctions, modified_bessel_second_kind) {
using stan::math::modified_bessel_second_kind;
EXPECT_FLOAT_EQ(0.011159676085853024269745195979833489225,
modified_bessel_second_kin... |
<commit_before>#ifndef __TRAINING_CORE_HPP
#define __TRAINING_CORE_HPP
#include <cmath>
#include <iostream>
#include <iomanip>
#include <string>
#include <vector>
#include "nanopolish_eventalign.h"
#include "nanopolish_squiggle_read.h"
// The state training data comes in two different
// sizes Full and Minimal. The ... |
<commit_before>// -*- mode: c++ , coding: utf-8 -*-
/**
* tbrpg – Text based roll playing game
*
* Copyright © 2012, 2013 Mattias Andrée (maandree@kth.se)
*
* 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 ... |
<commit_before>#include <cstdio>
#include <cstdlib>
#include <set>
#include "Search.h"
#include "Utils.h"
using namespace std;
//
// Static Variables
//
uint64_t nextId = 1;
// TODO(gabor) this is not threadsafe
inline uint64_t generateUniqueId() {
nextId++;
}
//
// Class Path
//
Path::Path(const uint64_t id, co... |
<commit_before>#include <cstdio>
#include <cstdlib>
#include <set>
#include <cstring>
#include <ctime>
#include "Search.h"
#include "Utils.h"
using namespace std;
//
// Utilities
//
/** Check if element |index| is set in the bitmask */
inline bool isSetBit(const uint64_t bitmask[], const uint8_t& index) {
uint8_t... |
<commit_before>//
// Token.cpp
// Phantasma
//
// Created by Thomas Harte on 08/12/2013.
// Copyright (c) 2013 Thomas Harte. All rights reserved.
//
#include "Token.h"
uint32_t Token::GetValue(CGameState *gameState, uint32_t suggestedValue)
{
switch(type)
{
case CONSTANT: return value;
case VARIABLE: return... |
<commit_before>/**
* The MIT License (MIT)
*
* Copyright (c) 2015 Nathan Osman
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to
* deal in the Software without restriction, including without limitation the
... |
<commit_before>/*
Copyright (c) 2003-2010 KenamicK Entertainment
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation
files (the "Software"), to deal in the Software without
restriction, including without limitation the rights to... |
<commit_before>/*
Copyright (c) 2003, Arvid Norberg, Daniel Wallin
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
* Redistributions of source code must retain the above copyright
notice, thi... |
<commit_before>#include <iostream>
#include <cstring>
#include <cstdlib>
#include <vector>
#include <unistd.h>
#include <stdio.h>
#include <sys/unistd.h>
#include <sys/types.h>
#include <sys/wait.h>
#include <stdlib.h>
using namespace std;
bool execute (string pass)
{
char* test[80];
//valid = 1;
vector<string> ... |
<commit_before>/**
* This file is part of the CernVM File System.
*/
#include <gtest/gtest.h>
#include <unistd.h>
#include <algorithm>
#include <cstdio>
#include <cstring>
#include <string>
#include "../../cvmfs/encrypt.h"
#include "../../cvmfs/hash.h"
#include "../../cvmfs/util.h"
#include "testutil.h"
using na... |
<commit_before>#include <iostream>
#include <vector>
#include <vpr/vpr.h>
#include <vpr/System.h>
#include <vpr/Thread/Thread.h>
#include <vpr/Thread/ThreadFunctor.h>
#include <vpr/Thread/TSTable.h>
#include <vpr/Thread/TSObject.h>
#include <vpr/Thread/TSObjectProxy.h>
#include <vpr/Thread/ThreadManager.h>
#include <... |
<commit_before>/**
* \file Exception.hpp
* \brief Defines custom exceptions used in framework.
*/
#ifndef ATLAS_INCLUDE_ATLAS_CORE_EXCEPTION_HPP
#define ATLAS_INCLUDE_ATLAS_CORE_EXCEPTION_HPP
#pragma once
#include "Log.hpp"
#include <stdexcept>
namespace atlas
{
namespace core
{
/**
* \... |
<commit_before>#include "entitysystem.h"
#include "systems/movementsystem.h"
#include "systems/updatesystem.h"
#include "systems/chatsystem.h"
#include "systems/inventorysystem.h"
#include "systems/partysystem.h"
#include "systems/mapsystem.h"
#include "systems/luasystem.h"
#include "connection.h"
#include "cmapclient.... |
<commit_before>//===- DataStructureAA.cpp - Data Structure Based Alias Analysis ----------===//
//
// 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.
//... |
<commit_before>//===- DataStructureAA.cpp - Data Structure Based Alias Analysis ----------===//
//
// 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.
//... |
<commit_before>// Test that we do not poison the array cookie if the operator new is defined
// inside the class.
// RUN: %clangxx_asan %s -o %t && %run %t
//
// XFAIL: android
// XFAIL: armv7l-unknown-linux-gnueabihf
#include <new>
#include <stdlib.h>
#include <stdint.h>
#include <stdio.h>
#include <assert.h>
struct ... |
<commit_before>// Copyright (c) 2013 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#if defined(WIN32) || defined(__linux__)
#include <errno.h>
#include "nacl_io/kernel_wrap.h"
#include "nacl_io/kernel_wrap_real.h"
/... |
<commit_before>//=- NSErrorChecker.cpp - Coding conventions for uses of NSError -*- C++ -*-==//
//
// The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------... |
<commit_before>#include <opencv2/highgui/highgui.hpp>
#include <opencv2/imgproc/imgproc.hpp>
#include <iostream>
int main( int argc, char** argv ){
using namespace cv;
if(argc != 2){
std::cerr << "usage: ./blurs <filename>" << std::endl;
return -1;
}
namedWindow("Original", CV_WINDOW_KEEPRATIO);
namedWindow... |
<commit_before>/*=========================================================================
Program: Insight Segmentation & Registration Toolkit
Module: itkMaximumProjectionImageFilterTest3.cxx
Language: C++
Date: $Date$
Version: $Revision$
Copyright (c) Insight Software Consortium. All rights... |
<commit_before>#include "stdio.h"
#include "unistd.h"
#include "sys/time.h"
#include "mpi.h"
#include "master.h"
#include "failure.h"
#include "protocol.h"
#include "log.h"
#include "tools.h"
Master::Master(const std::string &program, Engine &engine, DAG &dag,
const std::string &dagfile, const std::str... |
<commit_before>/*
Copyright (c) 2007, Arvid Norberg
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
* Redistributions of source code must retain the above copyright
notice, this list of condi... |
<commit_before>#include "Class/DlOpen.hpp"
#include "Class/Parsed.hpp"
#include "ClassResolver.hpp"
#include <iostream>
static int _result = 0;
extern "C" void ZN4java4lang6System4exitEi(int code) {
std::cerr << "java/lang/System.exit(I)V called with code: " << code << std::endl;
_result = code;
}
int main(... |
<commit_before>/****************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** This file is part of the Qt Mobility Components.
**
** $QT_BEGIN_LICENSE:LG... |
<commit_before>// 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
// "Lic... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.