start
Go to Layout [ “budget” (budget) ]
Set Window Title [ Current Window; New Title: "Budget Research" ]
Set Zoom Level
[ 100% ]
#
#Report version number to Memory Switch Table.
Set Field [ MemorySwitch::versionBudget; Reference::version ]
#
#Show regular menus if Admin logs in only.
Show/Hide Text Ruler
[ Hide ]
If [ Get ( AccountName ) = "Admin" ]
Show/Hide Status Area
[ Hide ]
Install Menu Set [ “[Standard FileMaker Menus]” ]
Else
Show/Hide Status Area
[ Lock; Hide ]
Install Menu Set [ “Custom Menu Set 1” ]
End If
January 8, 平成26 18:44:18 Budget Research.fp7 - start -1-

start
Go to Layout [ “budget” (budget) ]
Set Window Title [ Current Window; New Title: "Budget Planner" ]
Set Zoom Level
[ 100% ]
#
#Report version number to Memory Switch Table.
Set Field [ MemorySwitch::versionBudget; Reference::version ]
#
#Show regular menus if Admin logs in only.
Show/Hide Text Ruler
[ Hide ]
If [ Get ( AccountName ) = "Admin" ]
Show/Hide Status Area
[ Hide ]
Install Menu Set [ “[Standard FileMaker Menus]” ]
Else
Show/Hide Status Area
[ Lock; Hide ]
Install Menu Set [ “Custom Menu Set 1” ]
End If
January 30, 平成26 22:13:52 Budget Planner.fp7 - start -1-

Change solution name to Budget Planner

Change solution name to Budget Planner


#include "bitboard.h"

int main(int argc, char** argv)
{
	Bitboard test = board_init();
	board_print(test);
	return 0;
}

Add a little test driver

Add a little test driver


Add a new feature, lol

Add a new feature, lol


#include "canard.h"
#include "canard_internals.h"

void canardInitPoolAllocator(CanardPoolAllocator* allocator, CanardPoolAllocatorBlock* buf, unsigned int buf_len)
{
    unsigned int current_index = 0;
    CanardPoolAllocatorBlock** current_block = &(allocator->free_list);
    while (current_index < buf_len)
    {
        *current_block = &buf[current_index];
        current_block = &((*current_block)->next);
        current_index++;
    }
    *current_block = NULL;
}

void* canardAllocateBlock(CanardPoolAllocator* allocator)
{
    /* Check if there are any blocks available in the free list. */
    if (allocator->free_list == NULL)
    {
        return NULL;
    }

    /* Take first available block and prepares next block for use. */
    void* result = allocator->free_list;
    allocator->free_list = allocator->free_list->next;

    return result;
}

void canardFreeBlock(CanardPoolAllocator* allocator, void* p)
{
    CanardPoolAllocatorBlock* block = (CanardPoolAllocatorBlock*)p;

    block->next = allocator->free_list;
    allocator->free_list = block;
}

#include "canard.h"
#include "canard_internals.h"

CANARD_INTERNAL void canardInitPoolAllocator(CanardPoolAllocator* allocator, CanardPoolAllocatorBlock* buf, unsigned int buf_len)
{
    unsigned int current_index = 0;
    CanardPoolAllocatorBlock** current_block = &(allocator->free_list);
    while (current_index < buf_len)
    {
        *current_block = &buf[current_index];
        current_block = &((*current_block)->next);
        current_index++;
    }
    *current_block = NULL;
}

CANARD_INTERNAL void* canardAllocateBlock(CanardPoolAllocator* allocator)
{
    /* Check if there are any blocks available in the free list. */
    if (allocator->free_list == NULL)
    {
        return NULL;
    }

    /* Take first available block and prepares next block for use. */
    void* result = allocator->free_list;
    allocator->free_list = allocator->free_list->next;

    return result;
}

CANARD_INTERNAL void canardFreeBlock(CanardPoolAllocator* allocator, void* p)
{
    CanardPoolAllocatorBlock* block = (CanardPoolAllocatorBlock*)p;

    block->next = allocator->free_list;
    allocator->free_list = block;
}

Apply internal API marker to declarations too


// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once

#include <vespa/vespalib/util/executor.h>
#include <vespa/vespalib/util/time.h>
#include <vector>

class FNET_Transport;

namespace vespalib {

class TimerTask;

/**
 * ScheduledExecutor is a class capable of running Tasks at a regular
 * interval. The timer can be reset to clear all tasks currently being
 * scheduled.
 */
class ScheduledExecutor
{
private:
    using TaskList = std::vector<std::unique_ptr<TimerTask>>;
    FNET_Transport & _transport;
    std::mutex _lock;
    TaskList   _taskList;

public:
    /**
     * Create a new timer, capable of scheduling tasks at fixed intervals.
     */
    ScheduledExecutor(FNET_Transport & transport);

    /**
     * Destroys this timer, finishing the current task executing and then
     * finishing.
     */
    ~ScheduledExecutor();

    /**
     * Schedule new task to be executed at specified intervals.
     *
     * @param task The task to schedule.
     * @param delay The delay to wait before first execution.
     * @param interval The interval in seconds.
     */
    void scheduleAtFixedRate(std::unique_ptr<Executor::Task> task, duration delay, duration interval);

    /**
     * Reset timer, clearing the list of task to execute.
     */
    void reset();
};

}

// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once

#include <vespa/vespalib/util/executor.h>
#include <vespa/vespalib/util/time.h>
#include <mutex>
#include <vector>

class FNET_Transport;

namespace vespalib {

class TimerTask;

/**
 * ScheduledExecutor is a class capable of running Tasks at a regular
 * interval. The timer can be reset to clear all tasks currently being
 * scheduled.
 */
class ScheduledExecutor
{
private:
    using TaskList = std::vector<std::unique_ptr<TimerTask>>;
    FNET_Transport & _transport;
    std::mutex _lock;
    TaskList   _taskList;

public:
    /**
     * Create a new timer, capable of scheduling tasks at fixed intervals.
     */
    ScheduledExecutor(FNET_Transport & transport);

    /**
     * Destroys this timer, finishing the current task executing and then
     * finishing.
     */
    ~ScheduledExecutor();

    /**
     * Schedule new task to be executed at specified intervals.
     *
     * @param task The task to schedule.
     * @param delay The delay to wait before first execution.
     * @param interval The interval in seconds.
     */
    void scheduleAtFixedRate(std::unique_ptr<Executor::Task> task, duration delay, duration interval);

    /**
     * Reset timer, clearing the list of task to execute.
     */
    void reset();
};

}

Add include to get declaration for std::mutex (staging_vespalib).


//
//  BRMenuOrderingGroupViewController.h
//  MenuKit
//
//  Created by Matt on 29/07/15.
//  Copyright (c) 2015 Blue Rocket. Distributable under the terms of the Apache License, Version 2.0.
//

#import <UIKit/UIKit.h>

#import "BRMenuOrderingDelegate.h"
#import <BRStyle/BRUIStylish.h>

@class BRMenuOrderingFlowController;

extern NSString * const BRMenuOrderingItemCellIdentifier;
extern NSString * const BRMenuOrderingItemWithoutComponentsCellIdentifier;
extern NSString * const BRMenuOrderingItemGroupHeaderCellIdentifier;

/**
 Present a list of menu item groups as sections of menu items.
 */
@interface BRMenuOrderingGroupViewController : UITableViewController <BRMenuOrderingDelegate, BRUIStylish>

@property (nonatomic, assign, getter=isUsePrototypeCells) IBInspectable BOOL usePrototypeCells;

@property (nonatomic, strong) BRMenuOrderingFlowController *flowController;
@property (nonatomic, weak) id<BRMenuOrderingDelegate> orderingDelegate;

@end

//
//  BRMenuOrderingGroupViewController.h
//  MenuKit
//
//  Created by Matt on 29/07/15.
//  Copyright (c) 2015 Blue Rocket. Distributable under the terms of the Apache License, Version 2.0.
//

#import <UIKit/UIKit.h>

#import "BRMenuOrderingDelegate.h"
#import <BRStyle/BRUIStylish.h>

@class BRMenuOrderingFlowController;
@class BRMenuStepper;

extern NSString * const BRMenuOrderingItemCellIdentifier;
extern NSString * const BRMenuOrderingItemWithoutComponentsCellIdentifier;
extern NSString * const BRMenuOrderingItemGroupHeaderCellIdentifier;

/**
 Present a list of menu item groups as sections of menu items.
 */
@interface BRMenuOrderingGroupViewController : UITableViewController <BRMenuOrderingDelegate, BRUIStylish>

@property (nonatomic, assign, getter=isUsePrototypeCells) IBInspectable BOOL usePrototypeCells;

@property (nonatomic, strong) BRMenuOrderingFlowController *flowController;
@property (nonatomic, weak) id<BRMenuOrderingDelegate> orderingDelegate;

/**
 Action sent to go backwards in the navigation flow.

 @param sender The action sender.
 */
- (IBAction)goBack:(id)sender;

/**
 Action when changes are requested to be saved into the active order.

 @param sender The action sender.
 */
- (IBAction)saveToOrder:(id)sender;

/**
 Action sent when the quantity should be adjusted via a stepper.

 @param sender The stepper.
 */
- (IBAction)didAdjustQuantity:(BRMenuStepper *)sender;

@end

Move some action methods into header for subclasses to support.


/**
 * 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 not use this file except in compliance
 * with the License.  You may obtain a copy of the License at
 *
 *  http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing,
 * software distributed under the License is distributed on an
 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
 * KIND, either express or implied.  See the License for the
 * specific language governing permissions and limitations
 * under the License.
 */

#include "hal/hal_watchdog.h"
#include "mcu/stm32f30x.h"
#include "mcu/stm32f30x_iwdg.h"

struct stm_wdt_cfg
{
    uint8_t prescaler;
    uint16_t reload
};
struct stm_wdt_cfg g_wdt_cfg;

int
hal_watchdog_init(uint32_t expire_msecs)
{
    uint32_t reload;

    /* Max prescaler is 256 */
    reload = 32768 / 256;
    reload = (reload * expire_msecs) / 1000;

    /* Check to make sure we are not trying a reload value that is too large */
    if (reload > IWDG_RLR_RL) {
        return -1;
    }

    g_wdt_cfg.prescaler = IWDG_Prescaler_256;
    g_wdt_cfg.reload = reload;

    return 0;
}

void
hal_watchdog_enable(void)
{
    FlagStatus rc;

    DBGMCU->APB1FZ |= DBGMCU_IWDG_STOP;
    IWDG_Enable();
    IWDG_WriteAccessCmd(IWDG_WriteAccess_Enable);
    IWDG_SetPrescaler(g_wdt_cfg.prescaler);
    IWDG_SetReload(g_wdt_cfg.reload);
    rc = SET;
    while (rc != RESET) {
        rc = IWDG_GetFlagStatus();
        /* XXX: need to break out of this somehow. */
    }
    IWDG_ReloadCounter();
}

void
hal_watchdog_tickle(void)
{
    HAL_IWDG_Refresh(&g_wdt_cfg);
}

Add hal watchdog for stm32f3

MYNEWT-448: Add hal watchdog for stm32f3

NOTE: there is one issue unresolved with this commit. There is no
way to exit the loop where we are waiting for the register
changes to take effect. Not sure the best way to do this at this
point so for now we just skip it. This has been noted in the ticket
and should be addressed soon.


/***************************Copyright-DO-NOT-REMOVE-THIS-LINE**
 * CONDOR Copyright Notice
 *
 * See LICENSE.TXT for additional notices and disclaimers.
 *
 * Copyright (c)1990-1998 CONDOR Team, Computer Sciences Department,
 * University of Wisconsin-Madison, Madison, WI.  All Rights Reserved.
 * No use of the CONDOR Software Program Source Code is authorized
 * without the express consent of the CONDOR Team.  For more information
 * contact: CONDOR Team, Attention: Professor Miron Livny,
 * 7367 Computer Sciences, 1210 W. Dayton St., Madison, WI 53706-1685,
 * (608) 262-0856 or miron@cs.wisc.edu.
 *
 * U.S. Government Rights Restrictions: Use, duplication, or disclosure
 * by the U.S. Government is subject to restrictions as set forth in
 * subparagraph (c)(1)(ii) of The Rights in Technical Data and Computer
 * Software clause at DFARS 252.227-7013 or subparagraphs (c)(1) and
 * (2) of Commercial Computer Software-Restricted Rights at 48 CFR
 * 52.227-19, as applicable, CONDOR Team, Attention: Professor Miron
 * Livny, 7367 Computer Sciences, 1210 W. Dayton St., Madison,
 * WI 53706-1685, (608) 262-0856 or miron@cs.wisc.edu.
****************************Copyright-DO-NOT-REMOVE-THIS-LINE**/

#ifndef _CONDOR_NFS_H
#define _CONDOR_NFS_H

#include <sys/mount.h>

#if defined(LINUX)
#	include <linux/nfs.h>
#	include <linux/ipc.h>
#	include <dirent.h>
    typedef struct fhandle fhandle_t;
#elif !defined(IRIX62)
#	include <rpc/rpc.h>
#	include <nfs/nfs.h>
#if !defined(OSF1)
#	include <nfs/export.h>
#endif
#endif

#endif /* _CONDOR_NFS_H */

Put all NFS-related header files (and the platform-dependent ugliness) in one place.


/* Chapter 27, exercise 16: "improve" (obfuscate) exercise 15 by using macros */

#include<stdio.h>
#include<stdlib.h>

#define GET_PTR(type,var_name) type* var_name = (type*)malloc(sizeof(type))
#define SET_FCT_PTR(pshape,pfct,fct) pshape->shape.pvtable->pfct = &fct

typedef void (*Pfct0)(struct Shape*);
typedef void (*Pfct1int)(struct Shape*, int);

typedef struct {
    Pfct0 draw;
    Pfct1int rotate;
} Vtable;

typedef struct {
    Vtable* pvtable;
    int x;
    int y;
} Shape;

typedef struct {
    Shape shape;
    int radius;
} Circle;

void draw(Shape* this)
{
    (this->pvtable->draw)(this);
}

void rotate(Shape* this, int deg)
{
    (this->pvtable->rotate)(this,deg);
}

void draw_shape(Shape* this)
{
    printf("Drawing Shape at (%d,%d)\n",this->x,this->y);
}

void rotate_shape(Shape* this, int deg)
{
    printf("Rotating Shape at (%d,%d) by %d\n",this->x,this->y,deg);
}

void draw_circle(Shape* this)
{
    Circle* pcircle = (Circle*)this;
    printf("Drawing Circle at (%d,%d) with radius %d\n",
           this->x,this->y,pcircle->radius);
}

void rotate_circle(Shape* this, int deg)
{
    Circle* pcircle = (Circle*)this;
    printf("Rotating Circle at (%d,%d) with radius %d by %d\n",
           this->x,this->y,pcircle->radius,deg);
}

Shape* init_shape(int x, int y)
{
    GET_PTR(Shape,pshape);
    GET_PTR(Vtable,pvtable);
    pvtable->draw = &draw_shape;
    pvtable->rotate = &rotate_shape;
    pshape->pvtable = pvtable;
    pshape->x = x;
    pshape->y = y;
    return pshape;
}

Circle* init_circle(int x, int y, int radius)
{
    GET_PTR(Circle,pcircle);
    pcircle->shape = *init_shape(x,y);
    SET_FCT_PTR(pcircle,draw,draw_circle);
    SET_FCT_PTR(pcircle,rotate,rotate_circle);
    pcircle->radius = radius;
    return pcircle;
}

int main()
{
    Shape* myshape = init_shape(10,10);
    Circle* mycircle = init_circle(20,20,5);
    draw(myshape);
    draw(mycircle);
    rotate(myshape,10);
    rotate(mycircle,15);
}

Add Chapter 27, exercise 16

Add Chapter 27, exercise 16


#if defined (__GNUC__) || defined (__INTEL_COMPILER) || defined (__clang__)
#ifdef INFINITY
#undef INFINITY
#endif

#ifdef NAN
#undef NAN
#endif

#define NAN __builtin_nan("")
#define NANf __builtin_nanf("")
#define INFINITY __builtin_inf()
#define INFINITYf __builtin_inff()
#else

#include <bits/nan.h>
#include <bits/inf.h>

#endif

#if defined (__GNUC__) || defined (__INTEL_COMPILER) || defined (__clang__)
#ifdef INFINITY
#undef INFINITY
#endif

#ifdef NAN
#undef NAN
#endif

#define NAN __builtin_nan("")
#define NANf __builtin_nanf("")
#define INFINITY __builtin_inf()
#define INFINITYf __builtin_inff()
#else

#include <math.h>

#endif

Include math.h instead of bits headers.

Include math.h instead of bits headers.


#ifndef FLATCC_PORTABLE_H
#define FLATCC_PORTABLE_H
#include "flatcc/portable/portable.h"
#endif /* FLATCC_PORTABLE_H */

#ifndef FLATCC_PORTABLE_H
#define FLATCC_PORTABLE_H
#include "flatcc/portable/portable_basic.h"
#endif /* FLATCC_PORTABLE_H */

Reduce chance of include guard conflicts


#pragma once
#include <gtest/gtest.h>
#include <FileIO.h>
#include <czmq.h>

class NotifierTest : public ::testing::Test {
public:

   NotifierTest() {
   };

   ~NotifierTest() {
   }

protected:

   virtual void SetUp() {
   };

   virtual void TearDown() {
      FileIO::RemoveFileAsRoot(notifierIPCPath);
      FileIO::RemoveFileAsRoot(handshakeIPCPath);
      zctx_interrupted = false;
   };

private:
   const std::string notifierIPCPath = "/tmp/RestartServicesQueue.ipc";
   const std::string handshakeIPCPath = "/tmp/RestartServicesHandshakeQueue.ipc";

};

#pragma once
#include <gtest/gtest.h>
#include <FileIO.h>
#include <czmq.h>

class NotifierTest : public ::testing::Test {
public:

   NotifierTest() {
   };

   ~NotifierTest() {
   }

protected:

   virtual void SetUp() {
   };

   virtual void TearDown() {
      FileIO::RemoveFile(notifierIPCPath);
      FileIO::RemoveFile(handshakeIPCPath);
      zctx_interrupted = false;
   };

private:
   const std::string notifierIPCPath = "/tmp/RestartServicesQueue.ipc";
   const std::string handshakeIPCPath = "/tmp/RestartServicesHandshakeQueue.ipc";

};

Change RemoveFileAsRoot to RemoveFile per change in FileIO.


// REQUIRES: x86-registered-target
// RUN: %clang_cc1 %s -triple i386-pc-windows-msvc18.0.0 -disable-free -fms-volatile -fms-extensions -fms-compatibility -fms-compatibility-version=18 -std=c++11 -x c++

// Check that the parser catching an 'error' from forward declaration of "location" does not lexer out it's subsequent declation.

void foo() {
  __asm {
    jl         location
 location:
    ret
  }
}

Introduce inline assembly parsing test is PR30372.

git-svn-id: ffe668792ed300d6c2daa1f6eba2e0aa28d7ec6c@281753 91177308-0d34-0410-b5e6-96231b3b80d8


/*
* PBKDF2
* (C) 1999-2007 Jack Lloyd
*
* Distributed under the terms of the Botan license
*/

#ifndef BOTAN_PBKDF2_H__
#define BOTAN_PBKDF2_H__

#include <botan/pbkdf.h>
#include <botan/mac.h>

namespace Botan {

/**
* PKCS #5 PBKDF2
*/
class BOTAN_DLL PKCS5_PBKDF2 : public PBKDF
   {
   public:
      std::string name() const
         {
         return "PBKDF2(" + mac->name() + ")";
         }

      PBKDF* clone() const
         {
         return new PKCS5_PBKDF2(mac->clone());
         }

      OctetString derive_key(u32bit output_len,
                             const std::string& passphrase,
                             const byte salt[], u32bit salt_len,
                             u32bit iterations) const;

      /**
      * Create a PKCS #5 instance using the specified message auth code
      * @param mac the MAC to use
      */
      PKCS5_PBKDF2(MessageAuthenticationCode* m) : mac(m) {}

      /**
      * Destructor
      */
      ~PKCS5_PBKDF2() { delete mac; }
   private:
      MessageAuthenticationCode* mac;
   };

}

#endif

/*
* PBKDF2
* (C) 1999-2007 Jack Lloyd
*
* Distributed under the terms of the Botan license
*/

#ifndef BOTAN_PBKDF2_H__
#define BOTAN_PBKDF2_H__

#include <botan/pbkdf.h>
#include <botan/mac.h>

namespace Botan {

/**
* PKCS #5 PBKDF2
*/
class BOTAN_DLL PKCS5_PBKDF2 : public PBKDF
   {
   public:
      std::string name() const
         {
         return "PBKDF2(" + mac->name() + ")";
         }

      PBKDF* clone() const
         {
         return new PKCS5_PBKDF2(mac->clone());
         }

      OctetString derive_key(u32bit output_len,
                             const std::string& passphrase,
                             const byte salt[], u32bit salt_len,
                             u32bit iterations) const;

      /**
      * Create a PKCS #5 instance using the specified message auth code
      * @param mac_fn the MAC to use
      */
      PKCS5_PBKDF2(MessageAuthenticationCode* mac_fn) : mac(mac_fn) {}

      /**
      * Destructor
      */
      ~PKCS5_PBKDF2() { delete mac; }
   private:
      MessageAuthenticationCode* mac;
   };

}

#endif

Fix Doxygen comment in PBKDF2 constructor


#include "num2words.h"

// Language strings for Dutch
const Language LANG_DUTCH = {
	.hours = {
		"een",
		"twee",
		"drie",
		"vier",
		"vijf",
		"zes",
		"zeven",
		"acht",
		"negen",
		"tien",
		"elf",
		"twaalf"
	},

	.phrases = {
		"*$1 uur ",
		"vijf over *$1 ",
		"tien over *$1 ",
		"kwart over *$1 ",
		"tien voor half *$2 ",
		"vijf voor half *$2 ",
		"half *$2 ",
		"vijf over half *$2 ",
		"tien over half *$2 ",
		"kwart voor *$2 ",
		"tien voor *$2 ",
		"vijf voor *$2 "
	},

	.greetings = {
		"Goede- morgen ",
		"Goede- dag ",
		"Goede- avond ",
		"Goede- nacht "
	},

	.connection_lost = "Waar is je telefoon"
};

#include "num2words.h"

// Language strings for Dutch
const Language LANG_DUTCH = {
	.hours = {
		"een",
		"twee",
		"drie",
		"vier",
		"vijf",
		"zes",
		"zeven",
		"acht",
		"negen",
		"tien",
		"elf",
		"twaalf"
	},

	.phrases = {
		"*$1 uur ",
		"vijf over *$1 ",
		"tien over *$1 ",
		"kwart over *$1 ",
		"tien voor half *$2 ",
		"vijf voor half *$2 ",
		"half *$2 ",
		"vijf over half *$2 ",
		"tien over half *$2 ",
		"kwart voor *$2 ",
		"tien voor *$2 ",
		"vijf voor *$2 "
	},

	.greetings = {
		"Goede- morgen ",
		"Goede- dag ",
		"Goede- avond ",
		"Goede- nacht "
	},

	.connection_lost = "Waar is je tele- foon "
};

Adjust dutch connection lost message.

Adjust dutch connection lost message.


//
//  StarFlightPushClient.h
//
//  Created by Starcut Software on 4/30/13.
//  Copyright (c) Starcut. All rights reserved.
//

#import <Foundation/Foundation.h>

NS_ASSUME_NONNULL_BEGIN

extern NSString *const SCStarFlightClientUUIDNotification;

@interface SCStarFlightPushClient : NSObject <NSURLConnectionDelegate>

- (instancetype)initWithAppID:(NSString *)appID clientSecret:(NSString *)clientSecret;

- (void)registerWithToken:(NSString *)token;
- (void)registerWithToken:(NSString *)token clientUUID:(NSString *)clientUUID tags:(NSArray<NSString *> *)tags timePreferences:(NSDictionary *)timePreferencesDict;
- (void)registerWithToken:(NSString *)token tags:(NSArray<NSString *> *)tags;
- (void)unregisterWithToken:(NSString *)token tags:(nullable NSArray<NSString *> *)tags;
- (void)openedMessageWithUUID:(NSString *)messageUUID deviceToken:(NSString *)deviceToken;

NS_ASSUME_NONNULL_END

@end

//
//  StarFlightPushClient.h
//
//  Created by Starcut Software on 4/30/13.
//  Copyright (c) Starcut. All rights reserved.
//

#import <Foundation/Foundation.h>

NS_ASSUME_NONNULL_BEGIN

extern NSString *const SCStarFlightClientUUIDNotification;

@interface SCStarFlightPushClient : NSObject <NSURLConnectionDelegate>

- (instancetype)initWithAppID:(NSString *)appID clientSecret:(NSString *)clientSecret;

- (void)registerWithToken:(NSString *)token;
- (void)registerWithToken:(NSString *)token clientUUID:(nullable NSString *)clientUUID tags:(nullable NSArray<NSString *> *)tags timePreferences:(nullable NSDictionary *)timePreferencesDict;
- (void)registerWithToken:(NSString *)token tags:(NSArray<NSString *> *)tags;
- (void)unregisterWithToken:(NSString *)token tags:(nullable NSArray<NSString *> *)tags;
- (void)openedMessageWithUUID:(NSString *)messageUUID deviceToken:(NSString *)deviceToken;

NS_ASSUME_NONNULL_END

@end

Allow optional(nullable) parameters to register starflight-client


#pragma once

#include <age/core/MetaEnum.h>
#include <age/entity/Component.h>
#include <age/entity/Export.h>
#include <age/math/Vector.h>

namespace age
{
	namespace entity
	{
		///
		///	\struct TransformComponent
		///
		///	\brief This component is given to entities that hold a position within the scene.
		///
		///	\date June 11, 2017
		///
		///	\author Aaron Shelley
		///
		struct AGE_ENTITY_EXPORT TransformComponent : public Component
		{
			TransformComponent();

			age::math::Vector Position{};
			double Rotation{};
		};
	}
}

#pragma once

#include <age/entity/Component.h>
#include <age/entity/Export.h>
#include <age/math/Vector.h>

namespace age
{
	namespace entity
	{
		///
		///	\struct TransformComponent
		///
		///	\brief This component is given to entities that hold a position within the scene.
		///
		///	\date June 11, 2017
		///
		///	\author Aaron Shelley
		///
		struct AGE_ENTITY_EXPORT TransformComponent : public Component
		{
			TransformComponent();

			age::math::Vector Position{};
			double Rotation{};
		};
	}
}

Fix compilation error due to Meta Enum header that no longer exists.


#include "FILE.h"

extern _Thread_local int errno;

ptrdiff_t __read(int, void*, size_t);

size_t __stdio_read(void* restrict buffer, size_t size, FILE stream[restrict static 1])
{
    ptrdiff_t count = __read(stream->fd, buffer, size);

    if (count < 0) {
        stream->state |= _errbit;
        errno = -count;
        return 0;
    }

    stream->state |= (count < size) * _eofbit;
    return count;
}

Make `read` wrapper for stdio.h

Make `read` wrapper for stdio.h


#ifndef TYPES_H
#define TYPES_H

struct elf_header
{

};

#endif

#ifndef TYPES_H
#define TYPES_H

#define     unsigned char       ubyte_t
#define     unsigned int        uint_t
#define     unsigned short int  uword_t

#define     ELF_FORM    1
#define     ELF_32      0
#define     ELF_64      1
#define     ELF_ORG     1
#define     END_BIG     0
#define     END_LTL     1

struct elf_header
{
    ubyte_t elf_format       : 1;
    ubyte_t elf_format_bit   : 1;
    ubyte_t elf_endianess    : 1;
    ubyte_t elf_version      : 1;
    ubyte_t elf_os           : 5;
    ubyte_t elf_abi             ;
    ubyte_t elf_pad             ;
    ubyte_t elf_type         : 2;
    ubyte_t elf_arch            ;
    ubyte_t elf_ver          : 1;
    uint_t *elf_entry           ;
    uint_t *elf_hdr_off         ;
    uint_t *elf_sct_off         ;
    uint_t elf_flags            ;
    uword_t elf_hdr_size        ;
    uword_t elf_hdrt_entry_size ;
    uword_t elf_hdrt_entries    ;
    uword_t elf_sct_entry_size  ;
    uword_t elf_sct_entries     ;
    uword_t elf_sct_index       ;
};

typedef struct elf_header elf_hdr;

#endif

Add first version of elf header struct

Add first version of elf header struct


//PARAM: --enable ana.int.interval --enable ana.int.enums --exp.privatization "write" -v

#include<pthread.h>

// Test case that shows how avoiding reading integral globals can reduce the number of solver evaluations.
// Avoiding to evaluate integral globals when setting them reduced the number of necessary evaluations from 62 to 21 in this test case.

pthread_mutex_t mutex = PTHREAD_MUTEX_INITIALIZER;
int glob = 10;

void* t_fun(void* ptr) {
  pthread_mutex_lock(&mutex);
  glob = 3;
  glob = 4;
  glob = 1;
  pthread_mutex_unlock(&mutex);
  return NULL;
}

void bar() {
  glob = 2;
}

int main() {
  pthread_t t;

  pthread_create(&t, NULL, t_fun, NULL);
  pthread_mutex_lock(&mutex);
  bar();
  pthread_mutex_unlock(&mutex);
  pthread_join(t, NULL);
  assert(glob >= 1);
  assert(glob <= 2); //UNKNOWN
  assert(glob <= 10);
  return 0;
}

//PARAM: --enable ana.int.interval --enable ana.int.enums --exp.privatization "write" -v

#include<pthread.h>

// Test case that shows how avoiding reading integral globals can reduce the number of solver evaluations.
// Avoiding to evaluate integral globals when setting them reduced the number of necessary evaluations from 62 to 20 in this test case.

pthread_mutex_t mutex = PTHREAD_MUTEX_INITIALIZER;
int glob = 10;

void* t_fun(void* ptr) {
  pthread_mutex_lock(&mutex);
  glob = 3;
  glob = 4;
  glob = 1;
  pthread_mutex_unlock(&mutex);
  return NULL;
}

void bar() {
  glob = 2;
}

int main() {
  pthread_t t;

  pthread_create(&t, NULL, t_fun, NULL);
  pthread_mutex_lock(&mutex);
  bar();
  pthread_mutex_unlock(&mutex);
  pthread_join(t, NULL);
  assert(glob >= 1);
  assert(glob <= 10);
  return 0;
}

Remove confusing assert from test case

Remove confusing assert from test case


/*
 * Copyright 2019 Arnaud Gelas <arnaud.gelas@sensefly.com>
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

/* Use the unit test allocators */
#define UNIT_TESTING 1

#include <stdarg.h>
#include <stddef.h>
#include <setjmp.h>
#include <cmocka.h>

/* A test case that does check if float is equal. */
static void float_test_success(void **state) {
    assert_float_equal(0.5f, 1.f / 2.f, 0.000001f);
    assert_float_not_equal(0.5, 0.499f, 0.000001f);
}

int main(void) {
    const struct CMUnitTest tests[] = {
        cmocka_unit_test(float_test_success),
    };

    return cmocka_run_group_tests(tests, NULL, NULL);
}

/*
 * Copyright 2019 Arnaud Gelas <arnaud.gelas@sensefly.com>
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

/* Use the unit test allocators */
#define UNIT_TESTING 1

#include <stdarg.h>
#include <stddef.h>
#include <setjmp.h>
#include <cmocka.h>

/* A test case that does check if float is equal. */
static void float_test_success(void **state)
{
    (void)state; /* unused */

    assert_float_equal(0.5f, 1.f / 2.f, 0.000001f);
    assert_float_not_equal(0.5, 0.499f, 0.000001f);
}

int main(void) {
    const struct CMUnitTest tests[] = {
        cmocka_unit_test(float_test_success),
    };

    return cmocka_run_group_tests(tests, NULL, NULL);
}

Mark state unused in float test

tests: Mark state unused in float test

Signed-off-by: Andreas Schneider <5be00ddc76278cf6077f5047ca3384a88460c671@cryptomilk.org>


/*
 * arch/arm/mach-orion5x/include/mach/system.h
 *
 * Tzachi Perelstein <tzachi@marvell.com>
 *
 * This file is licensed under the terms of the GNU General Public
 * License version 2.  This program is licensed "as is" without any
 * warranty of any kind, whether express or implied.
 */

#ifndef __ASM_ARCH_SYSTEM_H
#define __ASM_ARCH_SYSTEM_H

#include <mach/bridge-regs.h>

static inline void arch_idle(void)
{
	cpu_do_idle();
}

static inline void arch_reset(char mode, const char *cmd)
{
	/*
	 * Enable and issue soft reset
	 */
	orion5x_setbits(RSTOUTn_MASK, (1 << 2));
	orion5x_setbits(CPU_SOFT_RESET, 1);
}

#endif

/*
 * arch/arm/mach-orion5x/include/mach/system.h
 *
 * Tzachi Perelstein <tzachi@marvell.com>
 *
 * This file is licensed under the terms of the GNU General Public
 * License version 2.  This program is licensed "as is" without any
 * warranty of any kind, whether express or implied.
 */

#ifndef __ASM_ARCH_SYSTEM_H
#define __ASM_ARCH_SYSTEM_H

#include <mach/bridge-regs.h>

static inline void arch_idle(void)
{
	cpu_do_idle();
}

static inline void arch_reset(char mode, const char *cmd)
{
	/*
	 * Enable and issue soft reset
	 */
	orion5x_setbits(RSTOUTn_MASK, (1 << 2));
	orion5x_setbits(CPU_SOFT_RESET, 1);
	mdelay(200);
	orion5x_clrbits(CPU_SOFT_RESET, 1);
}

#endif

Fix soft-reset for some platforms

[ARM] orion5x: Fix soft-reset for some platforms

Some platforms, such as the DNS-323 rev C requires the soft reset line
to be toggled on and back off for the reset to work.

Note: The choice of 200ms delay comes from the 2.6.12 based vendor kernel.
It seems to be a -lot- though and I had my device working fine with much
smaller delays but better safe...

Signed-off-by: Benjamin Herrenschmidt <a7089bb6e7e92505d88aaff006cbdd60cc9120b6@kernel.crashing.org>
Signed-off-by: Nicolas Pitre <d659c10e27d52b00987b65e85d99bce5480adcae@fluxnic.net>


// RUN: %llvmgcc -xc %s -c -o - | llvm-dis | grep llvm.memset | count 3

void *memset(void*, int, long);
void bzero(void*, int);

void test(int* X, char *Y) {
  memset(X, 4, 1000);
  bzero(Y, 100);
}

// RUN: %llvmgcc -xc %s -c -o - | llvm-dis | grep llvm.memset | count 3

void *memset(void*, int, long);
void bzero(void*, long);

void test(int* X, char *Y) {
  memset(X, 4, 1000);
  bzero(Y, 100);
}

Make the declaration of bzero match size_t on
x86-64-linux.

git-svn-id: 0ff597fd157e6f4fc38580e8d64ab130330d2411@58383 91177308-0d34-0410-b5e6-96231b3b80d8


// RUN: not --crash %clang --analyze -Xanalyzer -analyzer-checker=debug.ExprInspection %s 2>&1 | FileCheck %s

void clang_analyzer_crash(void);

void inlined() {
  clang_analyzer_crash();
}

void test() {
  inlined();
}

// CHECK: 0.	Program arguments: {{.*}}clang
// CHECK-NEXT: 1.	<eof> parser at end of file
// CHECK-NEXT: 2. While analyzing stack:
// CHECK-NEXT:  #0 void inlined()
// CHECK-NEXT:  #1 void test()
// CHECK-NEXT: 3.	{{.*}}crash-trace.c:6:3: Error evaluating statement

Add test for crash tracing (r186639)

[analyzer] Add test for crash tracing (r186639)

git-svn-id: ffe668792ed300d6c2daa1f6eba2e0aa28d7ec6c@186926 91177308-0d34-0410-b5e6-96231b3b80d8


#include "sim-hab.h"

//
// display usage
//
void usage(void)
{
    fprintf(stderr,
            "\nsim-hab must be ran with two options. -p and -a both followed\n"
            "by a file location. To determine the file locations run the\n"
            "findPort program.\n"
            "\n"
            "usage: sim-hab [OPTIONS]\n"
            " -?, --help             Show this information.\n"
            " -v, --version          Show the version number.\n"
            " -i, --id <ID>          Use ID as the HAB-ID (defaults to\n"
            "                        hostname if omitted).\n"
            " -p --proxr <FILE>      Give the ProXR file location to open.\n"
            " -a --arduino <FILE>    Give the Arduino file location to open.\n"
            );
}

#include "sim-hab.h"

//
// display usage
//
void usage(void)
{
    fprintf(stderr,
            "\ncgba-sim-arduino-hab must be ran with one option. -a followed\n"
            "by a file location.\n"
            "\n"
            "usage: cgba-sim-arduino-hab [OPTIONS]\n"
            " -?, --help             Show this information.\n"
            " -v, --version          Show the version number.\n"
            " -i, --id <ID>          Use ID as the HAB-ID (defaults to\n"
            "                        hostname if omitted).\n"
            " -a --arduino <FILE>    Give the Arduino file location to open.\n"
            );
}

Modify arduino hab help menu.

Modify arduino hab help menu.


#ifndef _GL_COMMON_H
#define _GL_COMMON_H

#if defined(USING_GLES2)
#ifdef IOS
// I guess we can soon add ES 3.0 here too
#include <OpenGLES/ES2/gl.h>
#include <OpenGLES/ES2/glext.h>
#else
#include <GLES2/gl2.h>
#include <GLES2/gl2ext.h>
#ifndef MAEMO
#include <EGL/egl.h>
#endif // !MAEMO
#endif // IOS
#if defined(ANDROID) || defined(BLACKBERRY)
// Support OpenGL ES 3.0
// This uses the "DYNAMIC" approach from the gles3jni NDK sample.
// Should work on non-Android mobile platforms too.
#include "../gfx_es2/gl3stub.h"
#define MAY_HAVE_GLES3 1
#endif
#else // OpenGL
// Now that glew is upgraded beyond 4.3, we can define MAY_HAVE_GLES3 on GL platforms
#define MAY_HAVE_GLES3 1
#include <GL/glew.h>
#if defined(__APPLE__)
#include <OpenGL/gl.h>
#else
#include <GL/gl.h>
#endif
#endif

#if !defined(GLchar) && !defined(__APPLE__)
typedef char GLchar;
#endif

#endif //_GL_COMMON_H

#ifndef _GL_COMMON_H
#define _GL_COMMON_H

#if defined(USING_GLES2)
#ifdef IOS
#include <OpenGLES/ES3/gl.h>
#include <OpenGLES/ES3/glext.h>
#include <OpenGLES/ES2/gl.h>
#include <OpenGLES/ES2/glext.h>
#else
#include <GLES2/gl2.h>
#include <GLES2/gl2ext.h>
#ifndef MAEMO
#include <EGL/egl.h>
#endif // !MAEMO
#endif // IOS
#if defined(ANDROID) || defined(BLACKBERRY)
// Support OpenGL ES 3.0
// This uses the "DYNAMIC" approach from the gles3jni NDK sample.
// Should work on non-Android mobile platforms too.
#include "../gfx_es2/gl3stub.h"
#define MAY_HAVE_GLES3 1
#endif
#else // OpenGL
// Now that glew is upgraded beyond 4.3, we can define MAY_HAVE_GLES3 on GL platforms
#define MAY_HAVE_GLES3 1
#include <GL/glew.h>
#if defined(__APPLE__)
#include <OpenGL/gl.h>
#else
#include <GL/gl.h>
#endif
#endif

#if !defined(GLchar) && !defined(__APPLE__)
typedef char GLchar;
#endif

#endif //_GL_COMMON_H

Add ES 3.0 support for iPhone

Add ES 3.0 support for iPhone


#define PY_SSIZE_T_CLEAN
#include "Python.h"

/* Return a Python long instance containing the value of the DJB hash function
 * for the given string or array. */
static PyObject *
djb_hash(PyObject *self, PyObject *args)
{
    const unsigned char *s;
    unsigned int h = 5381;
    Py_ssize_t len;

    if(! PyArg_ParseTuple(args, "t#", &s, &len))
        return NULL;

    while(len--)
        h = ((h << 5) + h) ^ *s++;

    return PyLong_FromUnsignedLong((unsigned long) h);
}

static /*const*/ PyMethodDef methods[] = {
    {"djb_hash", djb_hash, METH_VARARGS,
     "Return the value of DJB's hash function for the given 8-bit string."},
    {NULL, NULL, 0, NULL}
};

PyMODINIT_FUNC
init_cdblib(void)
{
    Py_InitModule("_cdblib", methods);
}

Fix 64-bit breakage introduced in rev 04f373b0e015

According to PEP-353:

   "The conversion codes 's#' and 't#' will output Py_ssize_t if
   the macro PY_SSIZE_T_CLEAN is defined before Python.h is included,
   and continue to output int if that macro isn't defined."


#pragma once

#include "Control.h"

class Label : public Control {
public:
    Label() {

    }

    Label(int id, HWND parent) :
    Control(id, parent) {

    }
};

Add label alias for control

Add label alias for control


#ifndef SSPAPPLICATION_GAMESTATES_GAMESTATEHANDLER_H
#define SSPAPPLICATION_GAMESTATES_GAMESTATEHANDLER_H
#include "GameState.h"
#include "StartState.h"
#include "LevelSelectState.h"
#include <vector>

#define START_WITHOUT_MENU

class GameStateHandler
{
private:
	std::vector<GameState*> m_stateStack;
	std::vector<GameState*> m_statesToRemove;
public:
	GameStateHandler();
	~GameStateHandler();

	int ShutDown();

	int Initialize(ComponentHandler* cHandler, Camera* cameraRef, std::string levelPath = NULL);

	int Update(float dt, InputHandler* inputHandler);

	//Push a state to the stack
	int PushStateToStack(GameState* state);
private:
};

#endif

#ifndef SSPAPPLICATION_GAMESTATES_GAMESTATEHANDLER_H
#define SSPAPPLICATION_GAMESTATES_GAMESTATEHANDLER_H
#include "GameState.h"
#include "StartState.h"
#include "LevelSelectState.h"
#include <vector>

//#define START_WITHOUT_MENU

class GameStateHandler
{
private:
	std::vector<GameState*> m_stateStack;
	std::vector<GameState*> m_statesToRemove;
public:
	GameStateHandler();
	~GameStateHandler();

	int ShutDown();

	int Initialize(ComponentHandler* cHandler, Camera* cameraRef, std::string levelPath = NULL);

	int Update(float dt, InputHandler* inputHandler);

	//Push a state to the stack
	int PushStateToStack(GameState* state);
private:
};

#endif

ADD commented out skip menu

ADD commented out skip menu


/**
 * @file    tasks.h
 * @brief   Macros for configuring the run time tasks
 *
 * DAPLink Interface Firmware
 * Copyright (c) 2009-2020, ARM Limited, All Rights Reserved
 * SPDX-License-Identifier: Apache-2.0
 *
 * Licensed under the Apache License, Version 2.0 (the "License"); you may
 * not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

#ifndef TASK_H
#define TASK_H

// trouble here is that reset for different targets is implemented differently so all targets
//  have to use the largest stack or these have to be defined in multiple places... Not ideal
//  may want to move away from threads for some of these behaviours to optimize mempory usage (RAM)
#define MAIN_TASK_STACK     (800)
#define MAIN_TASK_PRIORITY  (osPriorityNormal)

#endif

/**
 * @file    tasks.h
 * @brief   Macros for configuring the run time tasks
 *
 * DAPLink Interface Firmware
 * Copyright (c) 2009-2020, ARM Limited, All Rights Reserved
 * SPDX-License-Identifier: Apache-2.0
 *
 * Licensed under the Apache License, Version 2.0 (the "License"); you may
 * not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

#ifndef TASK_H
#define TASK_H

// trouble here is that reset for different targets is implemented differently so all targets
//  have to use the largest stack or these have to be defined in multiple places... Not ideal
//  may want to move away from threads for some of these behaviours to optimize mempory usage (RAM)
#define MAIN_TASK_STACK     (864)
#define MAIN_TASK_PRIORITY  (osPriorityNormal)

#endif

Fix k64f stack overflow during WebUSB flashing

When flashing via the WebUSB interface (CMSIS v2) the K64F hangs and
USB eventually times out. This is because the main stack overflows
during this operation casuing RTX to trap and loop forever in
osRtxErrorNotify.

This patch prevents a stack overflow by by increasing the main stack
size from 800 bytes to 864 bytes. Note - maximum stack usage recorded
during WebUSB flashing is 816 bytes.


/*
 * Copyright 2016 Google Inc.
 *
 * Use of this source code is governed by a BSD-style license that can be
 * found in the LICENSE file.
 */
#ifndef SK_MILESTONE
#define SK_MILESTONE 103
#endif

/*
 * Copyright 2016 Google Inc.
 *
 * Use of this source code is governed by a BSD-style license that can be
 * found in the LICENSE file.
 */
#ifndef SK_MILESTONE
#define SK_MILESTONE 104
#endif

Update Skia milestone to 104

Update Skia milestone to 104

Change-Id: Iafd9cf15ac3c42bda7fa6b6857a82dc2eae6d234
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/540296
Reviewed-by: Heather Miller <2e22000c5d22374561fe5fba576a31095b72dc2e@google.com>
Commit-Queue: Eric Boren <0e499112533c8544f0505ea0d08394fb5ad7d8fa@google.com>
Commit-Queue: Heather Miller <2e22000c5d22374561fe5fba576a31095b72dc2e@google.com>


#ifndef HL7PARSER_CONFIG_H
#define HL7PARSER_CONFIG_H

/**
* \file config.h
*
* Generic configuration directives and macros used by the HL7 parser.
*
* \internal
* Copyright (c) 2003-2011 \b Erlar (http://erlar.com)
*/

/* ------------------------------------------------------------------------
   Headers
   ------------------------------------------------------------------------ */

#include <hl7parser/bool.h>
#include <assert.h>

/* ------------------------------------------------------------------------
   Macros
   ------------------------------------------------------------------------ */

/* Macros used when the library is included in a C++ project. */
#ifdef __cplusplus

#   define BEGIN_C_DECL()  extern "C" {
#   define END_C_DECL()    }

#else

#   define BEGIN_C_DECL()
#   define END_C_DECL()

#endif /* __cplusplus */

/**
* \def HL7_ASSERT( p )
* Asserts that the predicate \a p is true; if not it aborts the program
* showing the predicate, file and line number where the assertion failed.
*/
#define HL7_ASSERT( p )     assert( p )

#endif /* HL7PARSER_CONFIG_H */

#ifndef HL7PARSER_CONFIG_H
#define HL7PARSER_CONFIG_H

/**
* \file config.h
*
* Generic configuration directives and macros used by the HL7 parser.
*
* \internal
* Copyright (c) 2003-2011 \b Erlar (http://erlar.com)
*/

/* ------------------------------------------------------------------------
   Headers
   ------------------------------------------------------------------------ */

#include <hl7parser/bool.h>
#include <assert.h>

/* ------------------------------------------------------------------------
   Macros
   ------------------------------------------------------------------------ */

/* Macros used when the library is included in a C++ project. */
#ifdef __cplusplus

#   define BEGIN_C_DECL()  extern "C" {
#   define END_C_DECL()    }

#else

#   define BEGIN_C_DECL()
#   define END_C_DECL()

#endif /* __cplusplus */

/**
* \def HL7_ASSERT( p )
* Asserts that the predicate \a p is true; if not it aborts the program
* showing the predicate, file and line number where the assertion failed.
*/
#define HL7_ASSERT( p )     assert( p )

#ifdef __GNUC__
#define HL7_UNUSED __attribute__ ((__unused__))
#else
#define HL7_UNUSED
#endif

#endif /* HL7PARSER_CONFIG_H */

Add attribute for unused arguments

Add attribute for unused arguments


#if defined(__linux__)
	#include <stdio.h>
#else
	#include "../tlibc/stdio/stdio.h"
#endif

void abort(void)
{
	// TODO: Add proper kernel panic.
	printf("Kernel Panic! abort()\n");
	while ( 1 ) { }
}

#include "kputs.c"

void abort(void)
{
	// TODO: Add proper kernel panic.
	kputs("Kernel Panic! abort()\n");
	while ( 1 ) { }
}

Replace include stdio with include terminal


//
//  APLifecycleHooks.h
//  LoyaltyRtr
//
//  Created by David Benko on 7/22/14.
//  Copyright (c) 2014 David Benko. All rights reserved.
//

#import <Foundation/Foundation.h>

@interface APLifecycleHooks : NSObject
+(void)setSDKLogging:(BOOL)shouldLog;
+(void)synchronousConnectionFinished:(void (^)(NSData *downloadedData, NSError *error))hook;
+(void)asyncConnectionStarted:(void (^)(NSURLRequest * req, NSURLConnection *conn))hook;
+(void)asyncConnectionFinished:(BOOL (^)(NSMutableData *downloadedData, NSError *error))hook;
@end

//
//  APLifecycleHooks.h
//  LoyaltyRtr
//
//  Created by David Benko on 7/22/14.
//  Copyright (c) 2014 David Benko. All rights reserved.
//

#import <Foundation/Foundation.h>

#define __VERBOSE

@interface APLifecycleHooks : NSObject

+ (void)connectionWillStart:(NSURLRequest * (^)(NSURLRequest * req))connectionWillStartCallback didStart:(void (^)(NSURLRequest * req, NSURLConnection *conn))connectionDidStartCallback;
+ (void)connectionReceievedResponse:(void (^)(NSURLConnection *connection, NSURLResponse *response))connectionReceievedResponseCallback;
+ (void)checkConnectionResponse:(BOOL (^)(NSURLResponse *response, NSError **error))checkConnectionResponseCallback;
+ (void)connectionFinished:(BOOL (^)(NSURLResponse *response, NSMutableData *downloadedData, NSError *error))connectionDidFinishCallback;
@end

Update method defs for v7

Update method defs for v7


//
//  BRMenuPlusMinusButton.h
//  Menu
//
//  Created by Matt on 4/17/13.
//  Copyright (c) 2013 Pervasent Consulting, Inc. All rights reserved.
//

#import <UIKit/UIKit.h>

@class BRMenuUIStyle;

IB_DESIGNABLE
@interface BRMenuPlusMinusButton : UIControl

@property (nonatomic, strong) BRMenuUIStyle *uiStyle;
@property (nonatomic, getter = isPlus) IBInspectable BOOL plus;

@end

//
//  BRMenuPlusMinusButton.h
//  Menu
//
//  Created by Matt on 4/17/13.
//  Copyright (c) 2013 Pervasent Consulting, Inc. All rights reserved.
//

#import <UIKit/UIKit.h>

@class BRMenuUIStyle;

IB_DESIGNABLE
@interface BRMenuPlusMinusButton : UIControl

@property (nonatomic, strong) IBOutlet BRMenuUIStyle *uiStyle;
@property (nonatomic, getter = isPlus) IBInspectable BOOL plus;

@end

Add some IB support for uiStyle.

Add some IB support for uiStyle.


//===- lib/ReaderWriter/ELF/ARM/ARMDynamicLibraryWriter.h -----------------===//
//
//                             The LLVM Linker
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
#ifndef LLD_READER_WRITER_ELF_ARM_ARM_DYNAMIC_LIBRARY_WRITER_H
#define LLD_READER_WRITER_ELF_ARM_ARM_DYNAMIC_LIBRARY_WRITER_H

#include "DynamicLibraryWriter.h"
#include "ARMLinkingContext.h"
#include "ARMTargetHandler.h"

namespace lld {
namespace elf {

class ARMDynamicLibraryWriter : public DynamicLibraryWriter<ELF32LE> {
public:
  ARMDynamicLibraryWriter(ARMLinkingContext &ctx, ARMTargetLayout &layout);

protected:
  // Add any runtime files and their atoms to the output
  void createImplicitFiles(std::vector<std::unique_ptr<File>> &) override;

private:
  ARMLinkingContext &_ctx;
  ARMTargetLayout &_armLayout;
};

ARMDynamicLibraryWriter::ARMDynamicLibraryWriter(ARMLinkingContext &ctx,
                                                 ARMTargetLayout &layout)
    : DynamicLibraryWriter(ctx, layout), _ctx(ctx), _armLayout(layout) {}

void ARMDynamicLibraryWriter::createImplicitFiles(
    std::vector<std::unique_ptr<File>> &result) {
  DynamicLibraryWriter::createImplicitFiles(result);
}

} // namespace elf
} // namespace lld

#endif // LLD_READER_WRITER_ELF_ARM_ARM_DYNAMIC_LIBRARY_WRITER_H

//===- lib/ReaderWriter/ELF/ARM/ARMDynamicLibraryWriter.h -----------------===//
//
//                             The LLVM Linker
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
#ifndef LLD_READER_WRITER_ELF_ARM_ARM_DYNAMIC_LIBRARY_WRITER_H
#define LLD_READER_WRITER_ELF_ARM_ARM_DYNAMIC_LIBRARY_WRITER_H

#include "DynamicLibraryWriter.h"
#include "ARMLinkingContext.h"
#include "ARMTargetHandler.h"

namespace lld {
namespace elf {

class ARMDynamicLibraryWriter : public DynamicLibraryWriter<ELF32LE> {
public:
  ARMDynamicLibraryWriter(ARMLinkingContext &ctx, ARMTargetLayout &layout);

protected:
  // Add any runtime files and their atoms to the output
  void createImplicitFiles(std::vector<std::unique_ptr<File>> &) override;
};

ARMDynamicLibraryWriter::ARMDynamicLibraryWriter(ARMLinkingContext &ctx,
                                                 ARMTargetLayout &layout)
    : DynamicLibraryWriter(ctx, layout) {}

void ARMDynamicLibraryWriter::createImplicitFiles(
    std::vector<std::unique_ptr<File>> &result) {
  DynamicLibraryWriter::createImplicitFiles(result);
}

} // namespace elf
} // namespace lld

#endif // LLD_READER_WRITER_ELF_ARM_ARM_DYNAMIC_LIBRARY_WRITER_H

[ARM] Remove unused fields in dynamic library writer

git-svn-id: f6089bf0e6284f307027cef4f64114ee9ebb0424@237883 91177308-0d34-0410-b5e6-96231b3b80d8


/*
 * This file is part of the OpenMV project.
 * Copyright (c) 2013/2014 Ibrahim Abdelkader <i.abdalkader@gmail.com>
 * This work is licensed under the MIT license, see the file LICENSE for details.
 *
 * Memory allocation functions.
 *
 */
#include <mp.h>
#include "mdefs.h"
#include "xalloc.h"

void *xalloc_fail()
{
    nlr_raise(mp_obj_new_exception_msg(&mp_type_OSError, "Out of Memory!!"));
    return NULL;
}

void *xalloc(uint32_t size)
{
    void *mem = gc_alloc(size, false);
    if (mem == NULL) {
        return xalloc_fail();
    }
    return mem;
}

void *xalloc0(uint32_t size)
{
    void *mem = gc_alloc(size, false);
    if (mem == NULL) {
        return xalloc_fail();
    }
    memset(mem, 0, size);
    return mem;
}

void xfree(void *ptr)
{
    gc_free(ptr);
}

void *xrealloc(void *ptr, uint32_t size)
{
    ptr = gc_realloc(ptr, size);
    if (ptr == NULL) {
        return xalloc_fail();
    }
    return ptr;
}

/*
 * This file is part of the OpenMV project.
 * Copyright (c) 2013/2014 Ibrahim Abdelkader <i.abdalkader@gmail.com>
 * This work is licensed under the MIT license, see the file LICENSE for details.
 *
 * Memory allocation functions.
 *
 */
#include <mp.h>
#include "mdefs.h"
#include "xalloc.h"

void *xalloc_fail()
{
    nlr_raise(mp_obj_new_exception_msg(&mp_type_MemoryError, "Out of Memory!!"));
    return NULL;
}

void *xalloc(uint32_t size)
{
    void *mem = gc_alloc(size, false);
    if (mem == NULL) {
        return xalloc_fail();
    }
    return mem;
}

void *xalloc0(uint32_t size)
{
    void *mem = gc_alloc(size, false);
    if (mem == NULL) {
        return xalloc_fail();
    }
    memset(mem, 0, size);
    return mem;
}

void xfree(void *ptr)
{
    gc_free(ptr);
}

void *xrealloc(void *ptr, uint32_t size)
{
    ptr = gc_realloc(ptr, size);
    if (ptr == NULL) {
        return xalloc_fail();
    }
    return ptr;
}

Change memory exception to MemoryError

Change memory exception to MemoryError


/*
* Copyright (c) 2018-2019 ARM Limited. All rights reserved.
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed under the Apache License, Version 2.0 (the License); you may
* not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an AS IS BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

#ifndef __TFM_CLIENT_H__
#define __TFM_CLIENT_H__

#include "psa_defs.h"

#ifdef __cplusplus
extern "C" {
#endif

#ifdef __cplusplus
}
#endif

#endif /* __TFM_CLIENT_H__ */

/*
* Copyright (c) 2018-2019 ARM Limited. All rights reserved.
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed under the Apache License, Version 2.0 (the License); you may
* not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an AS IS BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

#ifndef __TFM_CLIENT_H__
#define __TFM_CLIENT_H__

#include "psa/client.h"

#ifdef __cplusplus
extern "C" {
#endif

#ifdef __cplusplus
}
#endif

#endif /* __TFM_CLIENT_H__ */

Update include psa_defs -> psa/client

Update include psa_defs -> psa/client


/*
 * minunit.h
 *
 * Source: http://www.jera.com/techinfo/jtns/jtn002.html
 */

#include <stdio.h>

extern int tests_run;

#define mu_assert(message, test) do { \
	if (!(test)) { \
		return message; \
	} \
} while (0)

#define mu_run_test(test, name) do { \
	test_head(name); \
	char const * message = test(); \
	tests_run++; \
	if (message) { \
		test_failure; \
		printf(" * %s\n", message); \
	} else { \
		test_success; \
	} \
} while (0)

#define test_head(name) printf("Test %s... ", name)
#define test_success printf("[OK]\n")
#define test_failure printf("[FAIL]\n")

Add minimalist framework for unit testing in Test project.


/* Copyright (c) 2004 Timo Sirainen */

#include "lib.h"
#include "str.h"
#include "str-sanitize.h"

void str_sanitize_append(string_t *dest, const char *src, size_t max_len)
{
	const char *p;

	for (p = src; *p != '\0'; p++) {
		if ((unsigned char)*p < 32)
			break;
	}

	str_append_n(dest, src, (size_t)(p - src));
	for (; *p != '\0' && max_len > 0; p++, max_len--) {
		if ((unsigned char)*p < 32)
			str_append_c(dest, '?');
		else
			str_append_c(dest, *p);
	}

	if (*p != '\0') {
		str_truncate(dest, str_len(dest)-3);
		str_append(dest, "...");
	}
}

const char *str_sanitize(const char *src, size_t max_len)
{
	string_t *str;

	str = t_str_new(I_MIN(max_len, 256));
	str_sanitize_append(str, src, max_len);
	return str_c(str);
}

/* Copyright (c) 2004 Timo Sirainen */

#include "lib.h"
#include "str.h"
#include "str-sanitize.h"

void str_sanitize_append(string_t *dest, const char *src, size_t max_len)
{
	const char *p;

	for (p = src; *p != '\0'; p++) {
		if (((unsigned char)*p & 0x7f) < 32)
			break;
	}

	str_append_n(dest, src, (size_t)(p - src));
	for (; *p != '\0' && max_len > 0; p++, max_len--) {
		if (((unsigned char)*p & 0x7f) < 32)
			str_append_c(dest, '?');
		else
			str_append_c(dest, *p);
	}

	if (*p != '\0') {
		str_truncate(dest, str_len(dest)-3);
		str_append(dest, "...");
	}
}

const char *str_sanitize(const char *src, size_t max_len)
{
	string_t *str;

	str = t_str_new(I_MIN(max_len, 256));
	str_sanitize_append(str, src, max_len);
	return str_c(str);
}

Convert also 0x80..0x9f characters to '?'


#import "Expecta.h"

EXPMatcherInterface(_beIdenticalTo, (void *expected));

#if __has_feature(objc_arc)
#define beIdenticalTo(expected) _beIdenticalTo((__bridge void*)expected)
#else
#define beIdenticalTo _beIdenticalTo
#endif

#import "Expecta.h"

EXPMatcherInterface(_beIdenticalTo, (void *expected));
EXPMatcherInterface(beIdenticalTo, (void *expected)); // to aid code completion

#if __has_feature(objc_arc)
#define beIdenticalTo(expected) _beIdenticalTo((__bridge void*)expected)
#else
#define beIdenticalTo _beIdenticalTo
#endif

Add code completion helper for beIdenticalTo()

Like for equal() this helps discovering the matcher using code completion in Xcode.


#ifndef ALIHLTPHOSNODULECELLACCUMULATEDENERGYDATASTRUCT_H
#define ALIHLTPHOSNODULECELLACCUMULATEDENERGYDATASTRUCT_H

/***************************************************************************
 * Copyright(c) 2007, ALICE Experiment at CERN, All rights reserved.       *
 *                                                                         *
 * Author: Per Thomas Hille <perthi@fys.uio.no> for the ALICE HLT Project. *
 * Contributors are mentioned in the code where appropriate.               *
 *                                                                         *
 * Permission to use, copy, modify and distribute this software and its    *
 * documentation strictly for non-commercial purposes is hereby granted    *
 * without fee, provided that the above copyright notice appears in all    *
 * copies and that both the copyright notice and this permission notice    *
 * appear in the supporting documentation. The authors make no claims      *
 * about the suitability of this software for any purpose. It is           *
 * provided "as is" without express or implied warranty.                   *
 **************************************************************************/

#include "AliHLTPHOSCommonDefs.h"
//#include "AliHLTPHOSValidCellDataStruct.h"

struct AliHLTPHOSModuleCellAccumulatedEnergyDataStruct
{
  AliHLTUInt8_t fModuleID;

  //  Int_t fModuleID;

  //  AliHLTUInt16_t fCnt;
  //  AliHLTUInt16_t fValidData[N_ROWS_MOD*N_COLUMNS_MOD*N_GAINS];

  //  AliHLTPHOSValidCellDataStruct fValidData[N_MODULES*N_ROWS_MOD*N_COLUMNS_MOD*N_GAINS];

  //  Double_t fAccumulatedEnergies[N_ZROWS_MOD][N_XCOLUMNS_MOD][N_GAINS];
  Float_t fAccumulatedEnergies[N_ZROWS_MOD][N_XCOLUMNS_MOD][N_GAINS];
  AliHLTUInt32_t fHits[N_ZROWS_MOD][N_XCOLUMNS_MOD][N_GAINS];
};

#endif

Structure to hold information about accumualted energy in each cell (crystall) as well as the number of hits. Used by the onlinedisplay and the Histogranproducer component.


#include <config.h>

#define LIB_VERB		(USR_DIR + "/Game/lib/verb")
#define LIB_SIGHANDLER		(USR_DIR + "/Game/lib/sighandler")
#define GAME_LIB_OBJECT		(USR_DIR + "/Game/lib/object")

#define ALIASD			(USR_DIR + "/Game/sys/aliasd")
#define ACCOUNTD		(USR_DIR + "/Game/sys/accountd")
#define ROOT			(USR_DIR + "/Game/sys/root")
#define SNOOPD			(USR_DIR + "/Game/sys/snoopd")
#define GAME_HELPD		(USR_DIR + "/Game/sys/helpd")
#define GAME_DRIVER		(USR_DIR + "/Game/sys/driver")
#define GAME_USERD		(USR_DIR + "/Game/sys/userd")

#include <config.h>

#define LIB_VERB		(USR_DIR + "/Game/lib/verb")
#define LIB_SIGHANDLER		(USR_DIR + "/Game/lib/sighandler")
#define GAME_LIB_OBJECT		(USR_DIR + "/Game/lib/object")

#define ALIASD			(USR_DIR + "/Game/sys/aliasd")
#define BAND			(USR_DIR + "/Game/sys/band")
#define ACCOUNTD		(USR_DIR + "/Game/sys/accountd")
#define ROOT			(USR_DIR + "/Game/sys/root")
#define SNOOPD			(USR_DIR + "/Game/sys/snoopd")
#define GAME_HELPD		(USR_DIR + "/Game/sys/helpd")
#define GAME_DRIVER		(USR_DIR + "/Game/sys/driver")
#define GAME_USERD		(USR_DIR + "/Game/sys/userd")

Add ban manager to game object list

Add ban manager to game object list


/*
 * Copyright (c) 2021 Morwenn
 * SPDX-License-Identifier: MIT
 */
#ifndef CPPSORT_DETAIL_FUNCTIONAL_H_
#define CPPSORT_DETAIL_FUNCTIONAL_H_

////////////////////////////////////////////////////////////
// Headers
////////////////////////////////////////////////////////////
#include <type_traits>
#include <utility>
#include <cpp-sort/utility/as_function.h>

namespace cppsort
{
namespace detail
{
    ////////////////////////////////////////////////////////////
    // indirect

    template<typename Projection>
    class indirect_t
    {
        private:

            Projection projection;

        public:

            indirect_t() = delete;

            explicit indirect_t(Projection projection):
                projection(std::move(projection))
            {}

            template<typename T>
            auto operator()(T&& indirect_value)
                -> decltype(utility::as_function(projection)(*indirect_value))
            {
                auto&& proj = utility::as_function(projection);
                return proj(*indirect_value);
            }

            template<typename T>
            auto operator()(T&& indirect_value) const
                -> decltype(utility::as_function(projection)(*indirect_value))
            {
                auto&& proj = utility::as_function(projection);
                return proj(*indirect_value);
            }
    };

    template<typename Projection>
    auto indirect(Projection&& proj)
        -> indirect_t<std::decay_t<Projection>>
    {
        return indirect_t<std::decay_t<Projection>>(std::forward<Projection>(proj));
    }
}}

#endif // CPPSORT_DETAIL_FUNCTIONAL_H_

/*
 * Copyright (c) 2021-2022 Morwenn
 * SPDX-License-Identifier: MIT
 */
#ifndef CPPSORT_DETAIL_FUNCTIONAL_H_
#define CPPSORT_DETAIL_FUNCTIONAL_H_

////////////////////////////////////////////////////////////
// Headers
////////////////////////////////////////////////////////////
#include <type_traits>
#include <utility>
#include <cpp-sort/utility/as_function.h>
#include <cpp-sort/utility/functional.h>

namespace cppsort
{
namespace detail
{
    ////////////////////////////////////////////////////////////
    // indirect

    template<typename Projection>
    class indirect_t:
        utility::projection_base
    {
        private:

            Projection projection;

        public:

            indirect_t() = delete;

            explicit indirect_t(Projection projection):
                projection(std::move(projection))
            {}

            template<typename T>
            auto operator()(T&& indirect_value)
                -> decltype(utility::as_function(projection)(*indirect_value))
            {
                auto&& proj = utility::as_function(projection);
                return proj(*indirect_value);
            }

            template<typename T>
            auto operator()(T&& indirect_value) const
                -> decltype(utility::as_function(projection)(*indirect_value))
            {
                auto&& proj = utility::as_function(projection);
                return proj(*indirect_value);
            }
    };

    template<typename Projection>
    auto indirect(Projection&& proj)
        -> indirect_t<std::decay_t<Projection>>
    {
        return indirect_t<std::decay_t<Projection>>(std::forward<Projection>(proj));
    }
}}

#endif // CPPSORT_DETAIL_FUNCTIONAL_H_

Make indirect_t inherit from projection_base


#pragma once
#ifndef YOU_DATASTORE_INTERNAL_OPERATIONS_ERASE_OPERATION_H_
#define YOU_DATASTORE_INTERNAL_OPERATIONS_ERASE_OPERATION_H_

#include "../operation.h"

namespace You {
namespace DataStore {
namespace Internal {
class EraseOperation : public IOperation {
public:
	EraseOperation(TaskId);
	bool run();
};
}  // namespace Internal
}   // namespace DataStore
}   // namespace You
#endif  // YOU_DATASTORE_INTERNAL_OPERATIONS_ERASE_OPERATION_H_

#pragma once
#ifndef YOU_DATASTORE_INTERNAL_OPERATIONS_ERASE_OPERATION_H_
#define YOU_DATASTORE_INTERNAL_OPERATIONS_ERASE_OPERATION_H_

#include "../operation.h"

namespace You {
namespace DataStore {
namespace Internal {
class EraseOperation : public IOperation {
public:
	explicit EraseOperation(TaskId);
	bool run();
};
}  // namespace Internal
}   // namespace DataStore
}   // namespace You
#endif  // YOU_DATASTORE_INTERNAL_OPERATIONS_ERASE_OPERATION_H_

Add explicit modifier to EraseOperation ctor


#pragma once

#include "ofMain.h"
#include "ofxDatGui.h"

class ofApp : public ofBaseApp{

	public:
        void setup();
        void draw();
        void update();

        ofxDatGui* gui;
        bool mFullscreen;
        void refreshWindow();
        void toggleFullscreen();

        void keyPressed(int key);
        void onButtonEvent(ofxDatGuiButtonEvent e);
        void onSliderEvent(ofxDatGuiSliderEvent e);
        void onTextInputEvent(ofxDatGuiTextInputEvent e);
        void on2dPadEvent(ofxDatGui2dPadEvent e);
        void onDropdownEvent(ofxDatGuiDropdownEvent e);
        void onColorPickerEvent(ofxDatGuiColorPickerEvent e);
        void onMatrixEvent(ofxDatGuiMatrixEvent e);

        uint tIndex;
        vector<ofxDatGuiTheme*> themes;

};

#pragma once

#include "ofMain.h"
#include "ofxDatGui.h"

class ofApp : public ofBaseApp{

	public:
        void setup();
        void draw();
        void update();

        ofxDatGui* gui;
        bool mFullscreen;
        void refreshWindow();
        void toggleFullscreen();

        void keyPressed(int key);
        void onButtonEvent(ofxDatGuiButtonEvent e);
        void onSliderEvent(ofxDatGuiSliderEvent e);
        void onTextInputEvent(ofxDatGuiTextInputEvent e);
        void on2dPadEvent(ofxDatGui2dPadEvent e);
        void onDropdownEvent(ofxDatGuiDropdownEvent e);
        void onColorPickerEvent(ofxDatGuiColorPickerEvent e);
        void onMatrixEvent(ofxDatGuiMatrixEvent e);

        unsigned int tIndex;
        vector<ofxDatGuiTheme*> themes;

};

Fix for AllComponentsGui example under Visual Studio


#ifndef LCDManager_h
#define LCDManager_h

#include "Arduino.h"
#include <LiquidCrystalSPI.h>

class LCDManager{
	public :
		LCDManager(int line, int cols, int pin);
		LiquidCrystalSPI screen();
		void clearLine(int line);
		void backlight(bool status);
		void setBacklightPin(int pin);
		void message(String message);
		void refreshDisplay();

	private :
		void displayMessage();

		String messageBuffer;
		LiquidCrystalSPI theScreen;
		int lines;
		int cols;
		int currentTextScrollPosition;
		int currentTextChar;
		bool hasDisplayFirstLoop;
		int pinBacklight;
		long lastTimer;
        int timeBetweenRefresh;
};

#endif

#ifndef LCDManager_h
#define LCDManager_h

#include "Arduino.h"
#include <LiquidCrystalSPI.h>
#include <SPI.h>

class LCDManager{
	public :
		LCDManager(int line, int cols, int pin);
		LiquidCrystalSPI screen();
		void clearLine(int line);
		void backlight(bool status);
		void setBacklightPin(int pin);
		void message(String message);
		void refreshDisplay();

	private :
		void displayMessage();

		String messageBuffer;
		LiquidCrystalSPI theScreen;
		int lines;
		int cols;
		int currentTextScrollPosition;
		int currentTextChar;
		bool hasDisplayFirstLoop;
		int pinBacklight;
		long lastTimer;
        int timeBetweenRefresh;
};

#endif

Add the import for SPI in the library directly


#ifndef PHP_PHPIREDIS_H
#define PHP_PHPIREDIS_H 1

#define PHP_PHPIREDIS_VERSION "1.0"
#define PHP_PHPIREDIS_EXTNAME "phpiredis"

PHP_MINIT_FUNCTION(phpiredis);
PHP_FUNCTION(phpiredis_connect);
PHP_FUNCTION(phpiredis_pconnect);
PHP_FUNCTION(phpiredis_disconnect);
PHP_FUNCTION(phpiredis_command_bs);
PHP_FUNCTION(phpiredis_command);
PHP_FUNCTION(phpiredis_multi_command);
PHP_FUNCTION(phpiredis_multi_command_bs);
PHP_FUNCTION(phpiredis_format_command);
PHP_FUNCTION(phpiredis_reader_create);
PHP_FUNCTION(phpiredis_reader_reset);
PHP_FUNCTION(phpiredis_reader_feed);
PHP_FUNCTION(phpiredis_reader_get_state);
PHP_FUNCTION(phpiredis_reader_get_error);
PHP_FUNCTION(phpiredis_reader_get_reply);
PHP_FUNCTION(phpiredis_reader_destroy);
PHP_FUNCTION(phpiredis_reader_set_error_handler);
PHP_FUNCTION(phpiredis_reader_set_status_handler);

extern zend_module_entry phpiredis_module_entry;
#define phpext_phpiredis_ptr &phpiredis_module_entry

#endif

#ifndef PHP_PHPIREDIS_H
#define PHP_PHPIREDIS_H 1

#define PHP_PHPIREDIS_VERSION "1.0.0"
#define PHP_PHPIREDIS_EXTNAME "phpiredis"

PHP_MINIT_FUNCTION(phpiredis);
PHP_FUNCTION(phpiredis_connect);
PHP_FUNCTION(phpiredis_pconnect);
PHP_FUNCTION(phpiredis_disconnect);
PHP_FUNCTION(phpiredis_command_bs);
PHP_FUNCTION(phpiredis_command);
PHP_FUNCTION(phpiredis_multi_command);
PHP_FUNCTION(phpiredis_multi_command_bs);
PHP_FUNCTION(phpiredis_format_command);
PHP_FUNCTION(phpiredis_reader_create);
PHP_FUNCTION(phpiredis_reader_reset);
PHP_FUNCTION(phpiredis_reader_feed);
PHP_FUNCTION(phpiredis_reader_get_state);
PHP_FUNCTION(phpiredis_reader_get_error);
PHP_FUNCTION(phpiredis_reader_get_reply);
PHP_FUNCTION(phpiredis_reader_destroy);
PHP_FUNCTION(phpiredis_reader_set_error_handler);
PHP_FUNCTION(phpiredis_reader_set_status_handler);

extern zend_module_entry phpiredis_module_entry;
#define phpext_phpiredis_ptr &phpiredis_module_entry

#endif

Add patch release in PHP_PHPIREDIS_VERSION.


/*
 ============================================================================
 Name        : thsh.c
 Authors     : Collin Kruger, Denton Underwood, John Christensen, Jon Stacey
 Version     :
 Copyright   : Copyright 2009 Jon Stacey. All rights reserved.
 Description : Hello World in C, Ansi-style
 ============================================================================
 */

#include <stdio.h>
#include <stdlib.h>

int main(void) {
	puts("!!!Hello World!!!"); /* prints !!!Hello World!!! */
	return EXIT_SUCCESS;
}

/*
 ============================================================================
 Name        : thsh.c
 Authors     : Collin Kruger, Denton Underwood, John Christensen, Jon Stacey
 Version     :
 Copyright   : Copyright 2009 Jon Stacey. All rights reserved.
 Description : Hello World in C, Ansi-style
 ============================================================================
 */

#include <stdio.h>
#include <stdlib.h>

int main(void) {
	setvbuf(stdout, NULL, _IONBF, 0); // Disable buffering in accordance to http://homepages.tesco.net/J.deBoynePollard/FGA/capture-console-win32.html

	puts("!!!Hello World!!!"); /* prints !!!Hello World!!! */
	return EXIT_SUCCESS;
}

Disable buffering to overcome apparent Eclipse bug


#ifndef PS2AUTOTESTS_COMMON_H
#define PS2AUTOTESTS_COMMON_H

#include <stdio.h>
#include <tamtypes.h>

// Defines for MSVC highlighting.  Not intended to actually compile with msc.
#ifdef _MSC_VER
void printf(const char *s, ...);
#define __attribute__(x)
#endif

#endif

#ifndef PS2AUTOTESTS_COMMON_H
#define PS2AUTOTESTS_COMMON_H

// Defines for MSVC highlighting.  Not intended to actually compile with msc.
#ifdef _MSC_VER
#define __STDC__
#define _EE
#define __attribute__(x)
#endif

#include <stdio.h>
#include <tamtypes.h>

#endif

Adjust MSVC highlighting defines a bit.

Adjust MSVC highlighting defines a bit.


#ifndef LIBTRADING_OMX_MOLDUDP_MESSAGE_H
#define LIBTRADING_OMX_MOLDUDP_MESSAGE_H

#include "libtrading/types.h"

struct omx_moldudp_header {
	char			Session[10];
	le32			SequenceNumber;
	le16			MessageCount;
} packed;

struct omx_moldudp_message {
	le16			MessageLength;
} packed;

struct omx_moldudp_request {
	char			Session[10];
	le32			SequenceNumber;
	le16			RequestedMessageCount;
} packed;

static inline struct omx_moldudp_message *omx_moldudp_payload(struct omx_moldudp_header *msg)
{
	return (void *) msg + sizeof(struct omx_moldudp_header);
}

static inline void *omx_moldudp_message_payload(struct omx_moldudp_message *msg)
{
	return (void *) msg + sizeof(struct omx_moldudp_message);
}

#endif

Add NASDAQ OMX MoldUDP 1.02a

Add NASDAQ OMX MoldUDP 1.02a

The protocol version is not mentioned in the implementation name because
last change was made in 2006.

Reviewed-by: Ville Aine <011d7a94c7f99119e473bfaf4cedd17c6b1552f1@iki.fi>
Signed-off-by: Jussi Virtanen <2a7e40f91a3be32dfb7e35af6e476a252ebdb4f3@gmail.com>


#ifndef PROFILEDIALOG_H
#define PROFILEDIALOG_H

#include "ui_profiledialog.h"
#include <QDialog>

namespace trace { class Profile; }

class ProfileDialog : public QDialog, public Ui_ProfileDialog
{
    Q_OBJECT

public:
    ProfileDialog(QWidget *parent = 0);
    ~ProfileDialog();

    void setProfile(trace::Profile* profile);

public slots:
    void setVerticalScrollMax(int max);
    void setHorizontalScrollMax(int max);

    void tableDoubleClicked(const QModelIndex& index);

    void selectionChanged(int64_t start, int64_t end);

signals:
    void jumpToCall(int call);

private:
    trace::Profile *m_profile;
};

#endif

#ifndef PROFILEDIALOG_H
#define PROFILEDIALOG_H

#include "ui_profiledialog.h"
#include <QDialog>

namespace trace { struct Profile; }

class ProfileDialog : public QDialog, public Ui_ProfileDialog
{
    Q_OBJECT

public:
    ProfileDialog(QWidget *parent = 0);
    ~ProfileDialog();

    void setProfile(trace::Profile* profile);

public slots:
    void setVerticalScrollMax(int max);
    void setHorizontalScrollMax(int max);

    void tableDoubleClicked(const QModelIndex& index);

    void selectionChanged(int64_t start, int64_t end);

signals:
    void jumpToCall(int call);

private:
    trace::Profile *m_profile;
};

#endif

Fix erroneous class Profile forward declaration to struct Profile.


#include "hardware/packet.h"
#include "serial.h"

void btoa(int num, char *buf, int digits) {
    int shift = digits - 1;
    int current = pow(2, shift);

    char digit[2];

    while (current > 0) {
        sprintf(digit, "%d", ((num & current) >> shift) & 1);
        strncat(buf, digit, 1);

        shift--;
        current /= 2;
    }

    strcat(buf, "\0");
}

int main(int argc, char *argv[]) {
    // 0: device
    // 1: group
    // 2: plug
    // 3: status

    char device[] = "\\\\.\\\\COM5";

    if (serial_connect(device) == SERIAL_ERROR) {
        printf("Failed to connect to serial device \"%s\"\n", device);
        return 1;
    }

    struct Packet packet = { 1, 0, 3 };

    if (serial_transmit(packet) == SERIAL_ERROR) {
        printf("Failed to send data to serial device \"%s\"\n", device);
        return 1;
    }

    serial_close();

    return 0;
}

#include "hardware/packet.h"
#include "serial.h"

void btoa(int num, char *buf, int digits) {
    int shift = digits - 1;
    int current = pow(2, shift);

    char digit[2];

    while (current > 0) {
        sprintf(digit, "%d", ((num & current) >> shift) & 1);
        strncat(buf, digit, 1);

        shift--;
        current /= 2;
    }

    strcat(buf, "\0");
}

int getvalue(char *text, char *name, int min, int max) {
    char *end;

    long result = strtol(text, &end, 10);

    if (*end != '\0' || result < min || result > max) {
        fprintf(stderr, "Invalid value for %s.\n", name);
        return -1;
    }

    return result;
}

int main(int argc, char *argv[]) {
    // 0: device
    // 1: group
    // 2: plug
    // 3: status

    char device[] = "\\\\.\\\\COM5";

    if (serial_connect(device) == SERIAL_ERROR) {
        printf("Failed to connect to serial device \"%s\"\n", device);
        return 1;
    }

    struct Packet packet = { 1, 0, 3 };

    if (serial_transmit(packet) == SERIAL_ERROR) {
        printf("Failed to send data to serial device \"%s\"\n", device);
        return 1;
    }

    serial_close();

    return 0;
}

Add function to convert a string to an integer


/*
 * 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.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
 *
 * Random.h
 * A simple random number generator.
 * Copyright (C) 2012 Simon Newton
 */

#ifndef INCLUDE_OLA_MATH_RANDOM_H_
#define INCLUDE_OLA_MATH_RANDOM_H_

namespace ola {
namespace math {

/**
 * @brief Seed the random number generator
 */
void InitRandom();

/**
 * @brief Return a random number between lower and upper, inclusive. i.e.
 * [lower, upper]
 * @param lower the lower bound of the range the random number should be within
 * @return the random number
 */
int Random(int lower, int upper);
}  // namespace math
}  // namespace ola
#endif  // INCLUDE_OLA_MATH_RANDOM_H_

/*
 * 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.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
 *
 * Random.h
 * A simple random number generator.
 * Copyright (C) 2012 Simon Newton
 */

#ifndef INCLUDE_OLA_MATH_RANDOM_H_
#define INCLUDE_OLA_MATH_RANDOM_H_

namespace ola {
namespace math {

/**
 * @brief Seed the random number generator
 */
void InitRandom();

/**
 * @brief Return a random number between lower and upper, inclusive. i.e.
 * [lower, upper]
 * @param lower the lower bound of the range the random number should be within
 * @param upper the upper bound of the range the random number should be within
 * @return the random number
 */
int Random(int lower, int upper);
}  // namespace math
}  // namespace ola
#endif  // INCLUDE_OLA_MATH_RANDOM_H_

Fix the deliberate error, Travis should go green now


@import Base;
@import ObjectiveC;

BaseClass *getBaseClassObjC();
void useBaseClassObjC(BaseClass *);

@interface UserClass : NSObject <BaseProto>
@end

id <BaseProto> getBaseProtoObjC();
void useBaseProtoObjC(id <BaseProto>);

@interface BaseClass (ObjCExtensions)
- (void)categoryMethod;
@end

[ClangImporter] Add a test for ObjC categories on Swift classes.

...that get unified by the importer.

Swift SVN r15083


#include <errno.h>

#include "extern.h"

char *
pgtypes_alloc(long size)
{
	char *new = (char *) calloc(1L, size);

	if (!new)
	{
		errno = ENOMEM;
		return NULL;
	}

	memset(new, '\0', size);
	return (new);
}

char *
pgtypes_strdup(char *str)
{
	char *new = (char *) strdup(str);

	if (!new)
		errno = ENOMEM;
	return (new);
}

#include <errno.h>
#include <stdlib.h>

#include "extern.h"

char *
pgtypes_alloc(long size)
{
	char *new = (char *) calloc(1L, size);

	if (!new)
	{
		errno = ENOMEM;
		return NULL;
	}

	memset(new, '\0', size);
	return (new);
}

char *
pgtypes_strdup(char *str)
{
	char *new = (char *) strdup(str);

	if (!new)
		errno = ENOMEM;
	return (new);
}

Add <stdlib> to add calloc() prototype.

Add <stdlib> to add calloc() prototype.


//
//  MBContactModel.h
//  MBContactPicker
//
//  Created by Matt Bowman on 12/13/13.
//  Copyright (c) 2013 Citrrus, LLC. All rights reserved.
//

#import <Foundation/Foundation.h>

@protocol MBContactPickerModelProtocol <NSObject>

@required

@property (nonatomic, copy) NSString *contactTitle;

@optional

@property (nonatomic, copy) NSString *contactSubtitle;
@property (nonatomic) UIImage *contactImage;

@end

@interface MBContactModel : NSObject <MBContactPickerModelProtocol>

@property (nonatomic, copy) NSString *contactTitle;
@property (nonatomic, copy) NSString *contactSubtitle;
@property (nonatomic) UIImage *contactImage;

@end

//
//  MBContactModel.h
//  MBContactPicker
//
//  Created by Matt Bowman on 12/13/13.
//  Copyright (c) 2013 Citrrus, LLC. All rights reserved.
//

#import <Foundation/Foundation.h>

@protocol MBContactPickerModelProtocol <NSObject>

@required

@property (readonly, nonatomic, copy) NSString *contactTitle;

@optional

@property (readonly, nonatomic, copy) NSString *contactSubtitle;
@property (readonly, nonatomic) UIImage *contactImage;

@end

@interface MBContactModel : NSObject <MBContactPickerModelProtocol>

@property (nonatomic, copy) NSString *contactTitle;
@property (nonatomic, copy) NSString *contactSubtitle;
@property (nonatomic) UIImage *contactImage;

@end

Make MBContactPickerModelProtocol properties read-only, since that is all that the picker implementation requires, and avoids implementors having to either provide setters, or ignore the Xcode warnings about them not being auto-generated.


/****************************************************************************
*
* Copyright (c) 2008 by Casey Duncan and contributors
* All Rights Reserved.
*
* This software is subject to the provisions of the MIT License
* A copy of the license should accompany this distribution.
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
*
****************************************************************************/
/* Renderer shared code
 *
 * $Id$
 */

#ifndef _RENDERER_H_
#define _RENDERER_H_

typedef struct {
	PyObject_HEAD
	Py_ssize_t size;
	float *data;
} FloatArrayObject;

/* Return true if o is a bon-a-fide FloatArrayObject */
int FloatArrayObject_Check(FloatArrayObject *o);

FloatArrayObject *
FloatArray_new(Py_ssize_t size);

FloatArrayObject *
generate_default_2D_tex_coords(GroupObject *pgroup);

/* Initialize the glew OpenGL extension manager
   If glew has already been initialized, do nothing */
int
glew_initialize(void);

#endif

// Windows lacks fminf
#ifndef fminf
#define fminf(x, y) (((x) < (y)) ? (x) : (y))
#endif

Define fminf for platforms that lack it

Define fminf for platforms that lack it


/*
 * Copyright 2014, NICTA
 *
 * This software may be distributed and modified according to the terms of
 * the BSD 2-Clause license. Note that NO WARRANTY is provided.
 * See "LICENSE_BSD2.txt" for details.
 *
 * @TAG(NICTA_BSD)
 */

#ifndef __LIBSEL4_MACROS_H
#define __LIBSEL4_MACROS_H

/*
 * Some compilers attempt to pack enums into the smallest possible type.
 * For ABI compatability with the kernel, we need to ensure they remain
 * the same size as an 'int'.
 */
#define SEL4_FORCE_LONG_ENUM(type) \
        _enum_pad_ ## type = (1U << ((sizeof(int)*8) - 1))

#ifndef CONST
#define CONST        __attribute__((__const__))
#endif

#ifndef PURE
#define PURE         __attribute__((__pure__))
#endif

#endif

/*
 * Copyright 2014, NICTA
 *
 * This software may be distributed and modified according to the terms of
 * the BSD 2-Clause license. Note that NO WARRANTY is provided.
 * See "LICENSE_BSD2.txt" for details.
 *
 * @TAG(NICTA_BSD)
 */

#ifndef __LIBSEL4_MACROS_H
#define __LIBSEL4_MACROS_H

/*
 * Some compilers attempt to pack enums into the smallest possible type.
 * For ABI compatability with the kernel, we need to ensure they remain
 * the same size as an 'int'.
 */
#define SEL4_FORCE_LONG_ENUM(type) \
        _enum_pad_ ## type = (1U << ((sizeof(int)*8) - 1)) - 1

#ifndef CONST
#define CONST        __attribute__((__const__))
#endif

#ifndef PURE
#define PURE         __attribute__((__pure__))
#endif

#endif

libsel4: Make enum padding types one less in value so that they are INT_MAX

Having the padding types as INT_MAX + 1 means C++ compilers will end up using
a signed 64 bit integer, as that is the only type that can have a value that
large, as well as the negative values our enums typically contain


//
//  Created by Vadim Shpakovski on 4/22/11.
//  Copyright 2011 Shpakovski. All rights reserved.
//

extern NSString *const kMASPreferencesWindowControllerDidChangeViewNotification;

@interface MASPreferencesWindowController : NSWindowController <NSToolbarDelegate, NSWindowDelegate>
{
@private
    NSArray *_viewControllers;
    NSString *_title;
    id _lastSelectedController;
}

@property (nonatomic, readonly) NSArray *viewControllers;
@property (nonatomic, readonly) NSUInteger indexOfSelectedController;
@property (nonatomic, readonly) NSViewController *selectedViewController;
@property (nonatomic, readonly) NSString *title;

- (id)initWithViewControllers:(NSArray *)viewControllers;
- (id)initWithViewControllers:(NSArray *)viewControllers title:(NSString *)title;

- (void)selectControllerAtIndex:(NSUInteger)controllerIndex withAnimation:(BOOL)animate;

- (IBAction)goNextTab:(id)sender;
- (IBAction)goPreviousTab:(id)sender;

- (void)resetFirstResponderInView:(NSView *)view;

@end

//
//  Created by Vadim Shpakovski on 4/22/11.
//  Copyright 2011 Shpakovski. All rights reserved.
//

extern NSString *const kMASPreferencesWindowControllerDidChangeViewNotification;

#if MAC_OS_X_VERSION_MAX_ALLOWED > MAC_OS_X_VERSION_10_5
@interface MASPreferencesWindowController : NSWindowController <NSToolbarDelegate, NSWindowDelegate>
#else
@interface MASPreferencesWindowController : NSWindowController
#endif
{
@private
    NSArray *_viewControllers;
    NSString *_title;
    id _lastSelectedController;
}

@property (nonatomic, readonly) NSArray *viewControllers;
@property (nonatomic, readonly) NSUInteger indexOfSelectedController;
@property (nonatomic, readonly) NSViewController *selectedViewController;
@property (nonatomic, readonly) NSString *title;

- (id)initWithViewControllers:(NSArray *)viewControllers;
- (id)initWithViewControllers:(NSArray *)viewControllers title:(NSString *)title;

- (void)selectControllerAtIndex:(NSUInteger)controllerIndex withAnimation:(BOOL)animate;

- (IBAction)goNextTab:(id)sender;
- (IBAction)goPreviousTab:(id)sender;

- (void)resetFirstResponderInView:(NSView *)view;

@end

Allow building with the 10.5 SDK.

Allow building with the 10.5 SDK.


/*  This file is part of the KDE project
    Copyright (C) 2007 David Faure <faure@kde.org>

    This library is free software; you can redistribute it and/or
    modify it under the terms of the GNU Library General Public
    License as published by the Free Software Foundation; either
    version 2 of the License, or (at your option) any later version.

    This library is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
    Library General Public License for more details.

    You should have received a copy of the GNU Library General Public License
    along with this library; see the file COPYING.LIB.  If not, write to
    the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
    Boston, MA 02110-1301, USA.
*/

#ifndef KTEXTEDITOR_EXPORT_H
#define KTEXTEDITOR_EXPORT_H

/* needed for KDE_EXPORT and KDE_IMPORT macros */
#include <kdemacros.h>

/* We use _WIN32/_WIN64 instead of Q_OS_WIN so that this header can be used from C files too */
#if defined _WIN32 || defined _WIN64

#ifndef KTEXTEDITOR_EXPORT
# if defined(MAKE_KTEXTEDITOR_LIB)
   /* We are building this library */
#  define KTEXTEDITOR_EXPORT KDE_EXPORT
# else
   /* We are using this library */
#  define KTEXTEDITOR_EXPORT KDE_IMPORT
# endif
#endif

#else /* UNIX */

#define KTEXTEDITOR_EXPORT KDE_EXPORT

#endif

#endif

/*  This file is part of the KDE project
    Copyright (C) 2007 David Faure <faure@kde.org>

    This library is free software; you can redistribute it and/or
    modify it under the terms of the GNU Library General Public
    License as published by the Free Software Foundation; either
    version 2 of the License, or (at your option) any later version.

    This library is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
    Library General Public License for more details.

    You should have received a copy of the GNU Library General Public License
    along with this library; see the file COPYING.LIB.  If not, write to
    the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
    Boston, MA 02110-1301, USA.
*/

#ifndef KTEXTEDITOR_EXPORT_H
#define KTEXTEDITOR_EXPORT_H

/* needed for KDE_EXPORT and KDE_IMPORT macros */
#include <kdemacros.h>

#ifndef KTEXTEDITOR_EXPORT
# if defined(MAKE_KTEXTEDITOR_LIB)
   /* We are building this library */
#  define KTEXTEDITOR_EXPORT KDE_EXPORT
# else
   /* We are using this library */
#  define KTEXTEDITOR_EXPORT KDE_IMPORT
# endif
#endif

#endif

Fix up the FOO_EXPORT stuff, per our discussion on k-c-d.
CCMAIL: Ch.Ehrlicher@gmx.de,thiago@kde.org

(fingers crossed)

svn path=/trunk/KDE/kdelibs/interfaces/ktexteditor/; revision=662070


#include "power.h"

#define SLEEP_MODE_ENABLE_BIT 4

void initializePower() {
}

void updatePower() {
}

void enterLowPowerMode() {
    // When WAIT instruction is executed, go into SLEEP mode
    OSCCONSET = (1 << SLEEP_MODE_ENABLE_BIT);
    asm("wait");
    // TODO if we wake up, do we resume with the PC right here? there's an RCON
    // register with bits to indicate if we woke up from sleep. we'll need to
    // re-run setup, potentially.
    //C1CONSET / C1CONbits.x
}

#include "power.h"

void initializePower() {
}

void updatePower() {
}

void enterLowPowerMode() {
}

Remove "in progress" sleep mode code for PIC32 for now.


/**
 *  Copyright (C) 2006-2016, ARM Limited, All Rights Reserved
 *  SPDX-License-Identifier: Apache-2.0
 *
 *  Licensed under the Apache License, Version 2.0 (the "License"); you may
 *  not use this file except in compliance with the License.
 *  You may obtain a copy of the License at
 *
 *  http://www.apache.org/licenses/LICENSE-2.0
 *
 *  Unless required by applicable law or agreed to in writing, software
 *  distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
 *  WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 *  See the License for the specific language governing permissions and
 *  limitations under the License.
 *
 *  This file is part of mbed TLS (https://tls.mbed.org)
 */

#if defined(DEVICE_TRNG)
#define MBEDTLS_ENTROPY_HARDWARE_ALT
#endif

#if defined(MBEDTLS_HW_SUPPORT)
#include "mbedtls_device.h"
#endif

/**
 *  Copyright (C) 2006-2016, ARM Limited, All Rights Reserved
 *  SPDX-License-Identifier: Apache-2.0
 *
 *  Licensed under the Apache License, Version 2.0 (the "License"); you may
 *  not use this file except in compliance with the License.
 *  You may obtain a copy of the License at
 *
 *  http://www.apache.org/licenses/LICENSE-2.0
 *
 *  Unless required by applicable law or agreed to in writing, software
 *  distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
 *  WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 *  See the License for the specific language governing permissions and
 *  limitations under the License.
 *
 *  This file is part of mbed TLS (https://tls.mbed.org)
 */

#if defined(DEVICE_TRNG)
#define MBEDTLS_ENTROPY_HARDWARE_ALT
#endif

#if defined(MBEDTLS_CONFIG_HW_SUPPORT)
#include "mbedtls_device.h"
#endif

Apply new naming convention to mbed TLS macros


#ifndef RBX_CAPI_RUBY_DEFINES_H
#define RBX_CAPI_RUBY_DEFINES_H

/* Stub file provided for C extensions that expect it. All regular
 * defines and prototypes are in ruby.h
 */

#define RUBY                               1
#define RUBINIUS                           1

#define HAVE_STDARG_PROTOTYPES             1

/* These are defines directly related to MRI C-API symbols that the
 * mkmf.rb discovery code (e.g. have_func("rb_str_set_len")) would
 * attempt to find by linking against libruby. Rubinius does not
 * have an appropriate lib to link against, so we are adding these
 * explicit defines for now.
 */
#define HAVE_RB_STR_SET_LEN                1
#define HAVE_RB_STR_NEW5                   1
#define HAVE_RB_STR_NEW_WITH_CLASS         1
#define HAVE_RB_DEFINE_ALLOC_FUNC          1

#define HAVE_RB_HASH_FOREACH               1
#define HAVE_RB_HASH_ASET                  1

#define HAVE_RUBY_ENCODING_H               1

#define HAVE_RB_ENCDB_ALIAS                1

#endif

#ifndef RBX_CAPI_RUBY_DEFINES_H
#define RBX_CAPI_RUBY_DEFINES_H

/* Stub file provided for C extensions that expect it. All regular
 * defines and prototypes are in ruby.h
 */

#define RUBY                               1
#define RUBINIUS                           1

#define HAVE_STDARG_PROTOTYPES             1

/* These are defines directly related to MRI C-API symbols that the
 * mkmf.rb discovery code (e.g. have_func("rb_str_set_len")) would
 * attempt to find by linking against libruby. Rubinius does not
 * have an appropriate lib to link against, so we are adding these
 * explicit defines for now.
 */
#define HAVE_RB_STR_SET_LEN                1
#define HAVE_RB_STR_NEW5                   1
#define HAVE_RB_STR_NEW_WITH_CLASS         1
#define HAVE_RB_DEFINE_ALLOC_FUNC          1

#define HAVE_RB_HASH_FOREACH               1
#define HAVE_RB_HASH_ASET                  1

#define HAVE_RUBY_ENCODING_H               1

#define HAVE_RB_ENCDB_ALIAS                1

#define HAVE_RB_ARY_SUBSEQ                 1

#endif

Add explicit define for rb_ary_subseq

Add explicit define for rb_ary_subseq


#pragma once

#define DEFAULT_URL L"http://paulrouget.com/test/bbjs/basic/";

#pragma once

#define DEFAULT_URL L"https://servo.org/hl-home/";

Load hololens demo page by default

Load hololens demo page by default


// @(#)root/base:$Name:  $:$Id: TVersionCheck.h,v 1.2 2007/05/10 16:04:32 rdm Exp $
// Author: Fons Rademakers   9/5/2007

/*************************************************************************
 * Copyright (C) 1995-2007, Rene Brun and Fons Rademakers.               *
 * All rights reserved.                                                  *
 *                                                                       *
 * For the licensing terms see $ROOTSYS/LICENSE.                         *
 * For the list of contributors see $ROOTSYS/README/CREDITS.             *
 *************************************************************************/

#ifndef ROOT_TVersionCheck
#define ROOT_TVersionCheck

//////////////////////////////////////////////////////////////////////////
//                                                                      //
// TVersionCheck                                                        //
//                                                                      //
// Used to check if the shared library or plugin is compatible with     //
// the current version of ROOT.                                         //
//                                                                      //
//////////////////////////////////////////////////////////////////////////

#ifndef ROOT_RVersion
#include "RVersion.h"
#endif

class TVersionCheck {
public:
   TVersionCheck(int versionCode);  // implemented in TSystem.cxx
};

static TVersionCheck gVersionCheck(ROOT_VERSION_CODE);

#endif

// @(#)root/base:$Name:  $:$Id: TVersionCheck.h,v 1.3 2007/05/10 18:16:58 rdm Exp $
// Author: Fons Rademakers   9/5/2007

/*************************************************************************
 * Copyright (C) 1995-2007, Rene Brun and Fons Rademakers.               *
 * All rights reserved.                                                  *
 *                                                                       *
 * For the licensing terms see $ROOTSYS/LICENSE.                         *
 * For the list of contributors see $ROOTSYS/README/CREDITS.             *
 *************************************************************************/

#ifndef ROOT_TVersionCheck
#define ROOT_TVersionCheck

//////////////////////////////////////////////////////////////////////////
//                                                                      //
// TVersionCheck                                                        //
//                                                                      //
// Used to check if the shared library or plugin is compatible with     //
// the current version of ROOT.                                         //
//                                                                      //
//////////////////////////////////////////////////////////////////////////

#ifndef ROOT_RVersion
#include "RVersion.h"
#endif

class TVersionCheck {
public:
   TVersionCheck(int versionCode);  // implemented in TSystem.cxx
};

#ifndef __CINT__
static TVersionCheck gVersionCheck(ROOT_VERSION_CODE);
#endif

#endif

Hide a static function to CINT. With this fix g4root compiles OK.

git-svn-id: ecbadac9c76e8cf640a0bca86f6bd796c98521e3@18737 27541ba8-7e3a-0410-8455-c3a389f83636


#ifndef CLIENTVERSION_H
#define CLIENTVERSION_H

//
// client versioning
//

// These need to be macros, as version.cpp's and bitcoin-qt.rc's voodoo requires it
#define CLIENT_VERSION_MAJOR       0
#define CLIENT_VERSION_MINOR       8
#define CLIENT_VERSION_REVISION    0
#define CLIENT_VERSION_BUILD       0

// Set to true for release, false for prerelease or test build
#define CLIENT_VERSION_IS_RELEASE  true

// Converts the parameter X to a string after macro replacement on X has been performed.
// Don't merge these into one macro!
#define STRINGIZE(X) DO_STRINGIZE(X)
#define DO_STRINGIZE(X) #X

#endif // CLIENTVERSION_H

#ifndef CLIENTVERSION_H
#define CLIENTVERSION_H

//
// client versioning
//

// These need to be macros, as version.cpp's and bitcoin-qt.rc's voodoo requires it
#define CLIENT_VERSION_MAJOR       0
#define CLIENT_VERSION_MINOR       8
#define CLIENT_VERSION_REVISION    1
#define CLIENT_VERSION_BUILD       99

// Set to true for release, false for prerelease or test build
#define CLIENT_VERSION_IS_RELEASE  false

// Converts the parameter X to a string after macro replacement on X has been performed.
// Don't merge these into one macro!
#define STRINGIZE(X) DO_STRINGIZE(X)
#define DO_STRINGIZE(X) #X

#endif // CLIENTVERSION_H

Switch version numbers to 0.8.1.99

Switch version numbers to 0.8.1.99


// PARAM: --set ana.malloc.unique_address_count 1
#include<assert.h>
#include<stdlib.h>
int main() {
  int* arr = calloc(5,sizeof(int));
  arr[0] = 3;
  assert(arr[2] == 0); //UNKNOWN
}

Add example for unsoundness for calloc

Add example for unsoundness for calloc