소스 검색

Remove stdbool.h from avl_tree since MSVC doesn't like it.

tags/v0.5
Ben Kurtovic 7 년 전
부모
커밋
2593675651
2개의 변경된 파일8개의 추가작업 그리고 2개의 파일을 삭제
  1. +6
    -0
      mwparserfromhell/parser/ctokenizer/avl_tree.c
  2. +2
    -2
      mwparserfromhell/parser/ctokenizer/avl_tree.h

+ 6
- 0
mwparserfromhell/parser/ctokenizer/avl_tree.c 파일 보기

@@ -3,6 +3,7 @@
* binary search tree), implementation file
*
* Written in 2014-2016 by Eric Biggers <ebiggers3@gmail.com>
* Slight changes for compatibility by Ben Kurtovic <ben.kurtovic@gmail.com>
*
* To the extent possible under law, the author(s) have dedicated all copyright
* and related and neighboring rights to this software to the public domain
@@ -17,6 +18,11 @@
* see <http://creativecommons.org/publicdomain/zero/1.0/>.
*/

#define false 0
#define true 1

typedef int bool;

#include "avl_tree.h"

/* Returns the left child (sign < 0) or the right child (sign > 0) of the


+ 2
- 2
mwparserfromhell/parser/ctokenizer/avl_tree.h 파일 보기

@@ -3,6 +3,7 @@
* binary search tree), header file
*
* Written in 2014-2016 by Eric Biggers <ebiggers3@gmail.com>
* Slight changes for compatibility by Ben Kurtovic <ben.kurtovic@gmail.com>
*
* To the extent possible under law, the author(s) have dedicated all copyright
* and related and neighboring rights to this software to the public domain
@@ -20,7 +21,6 @@
#ifndef _AVL_TREE_H_
#define _AVL_TREE_H_

#include <stdbool.h>
#include <stddef.h>
#include <inttypes.h> /* for uintptr_t */

@@ -78,7 +78,7 @@ avl_tree_node_set_unlinked(struct avl_tree_node *node)
/* Returns true iff the specified AVL tree node has been marked with
* avl_tree_node_set_unlinked() and has not subsequently been inserted into a
* tree. */
static AVL_INLINE bool
static AVL_INLINE int
avl_tree_node_is_unlinked(const struct avl_tree_node *node)
{
return node->parent_balance == (uintptr_t)node;


불러오는 중...
취소
저장